gnulib-tool.py: Handle module dependencies that cannot be found.
[gnulib.git] / ChangeLog
blobb752fde06552ef19425d6e5d29c340d21a4f3438
1 2024-05-07  Collin Funk  <collin.funk1@gmail.com>
3         gnulib-tool.py: Handle module dependencies that cannot be found.
4         * pygnulib/GLModuleSystem.py
5         (GLModule.getDependenciesWithoutConditions): Filter out None from the
6         module dependencies. An appropriate warning will already be printed by
7         GLModuleSystem.find().
9 2024-05-07  Paul Eggert  <eggert@cs.ucla.edu>
11         nstrftime: use clearer code for padding
12         This also works around GCC bug 114965
13         <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114965>.
14         * lib/strftime.c (enum pad_style): New type.
15         (width_add, my_strftime, __strftime_internal):
16         Use it instead of checking the raw chars.
17         * tests/test-nstrftime.h (T): Test for the GCC bug.
19 2024-05-06  Simon Josefsson  <simon@josefsson.org>
21         maintainer-makefile: Prohibit BSD4.3/SysV u_char etc types.
22         * top/maint.mk (sc_unsigned_char, sc_unsigned_short)
23         (sc_unsigned_int, sc_unsigned_long): Add.
25 2024-05-06  Simon Josefsson  <simon@josefsson.org>
27         inet-ntop, inet-pton: Avoid obsolete u_char type.
28         * lib/inet_pton.c (inet_pton6): Use unsigned char instead of u_char.
29         * lib/inet_ntop.c: Doc fix.
31 2024-05-05  Bruno Haible  <bruno@clisp.org>
33         gnulib-tool.py: Regenerate aclocal.m4 before using 'autoconf -t ...'.
34         Reported by Paul Eggert in
35         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00065.html>.
36         * pygnulib/GLImport.py (GLImport): New field m4dirs.
37         (GLImport.__init__): Accept an additional m4dirs argument.
38         (GLImport.execute): Regenerate aclocal.m4 before creating the library
39         Makefile.
40         * pygnulib/main.py (main): Pass the guessed_m4dirs to GLImport.
42 2024-05-04  Collin Funk  <collin.funk1@gmail.com>
44         gnulib-tool: Ignore autom4te.cache when using GNULIB_TOOL_IMPL=sh+py.
45         Reported by Paul Eggert in:
46         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00061.html>.
47         * gnulib-tool: Don't compare the autom4te.cache directory since requests
48         are not sorted in Autoconf version 2.71 and below.
50 2024-05-04  Bruno Haible  <bruno@clisp.org>
52         readutmp, boot-time: Work around a Cygwin 3.5.3 bug.
53         Reported by Ken Brown <kbrown@cornell.edu> in
54         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00035.html>.
55         * lib/boot-time-aux.h (get_windows_boot_time): On Cygwin, ignore
56         pagefile.sys if it appears to be a directory, and use another file as
57         a fallback.
59 2024-05-03  Collin Funk  <collin.funk1@gmail.com>
61         gnulib-tool.py: Fix an undefined function name (regression 2024-05-02).
62         * pygnulib/main.py (main_with_exception_handling): Use the tempfile
63         module prefix when calling mkdtemp(). Use the 'glpy' prefix for the
64         temporary directory that exists for the entirety of the program.
66 2024-05-03  Simon Josefsson  <simon@josefsson.org>
68         maint.mk: Don't fail on ~/.indent.pro, reported by Collin Funk.
69         * top/maint.mk (indent_args): Use --ignore-profile.
71 2024-05-02  Collin Funk  <collin.funk1@gmail.com>
73         gnulib-tool.sh: Fix program name in error message.
74         * gnulib-tool.sh: Use 'gnulib-tool' instead of 'gnulib' as the program
75         name in the error message.
77 2024-05-02  Collin Funk  <collin.funk1@gmail.com>
79         DEPENDENCIES: Add Cygwin as supported platform.
80         * DEPENDENCIES: Mention Cygwin as a supported platform for building
81         Windows binaries.
83 2024-05-02  Bruno Haible  <bruno@clisp.org>
85         doc: Add appendix about Gnulib history.
86         * doc/gnulib-history.texi: New file.
87         * doc/gnulib.texi: Include it.
89 2024-05-02  Collin Funk  <collin.funk1@gmail.com>
91         gnulib-tool.py: Don't leave temporary directories on exit.
92         * pygnulib/main.py (main_with_exception_handling): Use
93         tempfile.TemporaryDirectory as a context manager so it is removed before
94         the program exits.
95         (main): Expect a temporary directory to be passed as an argument.
96         * pygnulib/GLConfig.py (GLConfig.__init__): Accept an optional temporary
97         directory parameter instead of creating one.
98         * pygnulib/GLImport.py (GLImport.__init__): Don't remove the cache's
99         temporary directory since it doesn't create one anymore.
100         (GLImport.execute): Don't remove the temporary directory explicitly. It
101         is handled by the usage of a context manager.
102         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
103         Likewise.
105 2024-05-01  Collin Funk  <collin.funk1@gmail.com>
107         gnulib-tool.py: Quote file names passed to 'patch'.
108         * pygnulib/GLTestDir.py (_patch_test_driver): Import shlex and cleanup
109         unused imports. Use shlex.quote() on the file names passed to 'patch'.
110         * pygnulib/GLFileSystem.py (GLFileSystem.lookup): Likewise. Perform
111         redirection using sp.call() arguments instead of using the shell.
113 2024-05-01  Bruno Haible  <bruno@clisp.org>
115         readutmp, boot-time: Improve for some Cygwin installations.
116         Reported by Ken Brown <kbrown@cornell.edu> in
117         <https://lists.gnu.org/archive/html/bug-gnulib/2024-05/msg00008.html>.
118         * lib/boot-time-aux.h (get_windows_boot_time): Use /proc/cygdrive/
119         instead of /cygdrive/.
121 2024-05-01  Bruno Haible  <bruno@clisp.org>
123         stddef: A better workaround against GCC bug 114870.
124         * lib/stddef.in.h: If STDDEF_NOT_IDEMPOTENT is 1, disable the special
125         invocation convention.
126         * m4/stddef_h.m4 (gl_STDDEF_H): Set STDDEF_NOT_IDEMPOTENT.
127         (gl_STDDEF_H_DEFAULTS): Initialize STDDEF_NOT_IDEMPOTENT.
128         * modules/stddef (Makefile.am): Substitute STDDEF_NOT_IDEMPOTENT.
130 2024-05-01  Bruno Haible  <bruno@clisp.org>
132         stddef: Fix <stddef.h> behaviour on Cygwin (regression 2024-04-27).
133         Reported by Markus Mützel <markus.muetzel@gmx.de> in
134         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00522.html>.
135         * lib/stddef.in.h: Don't test _@GUARD_PREFIX@_STDDEF_H. Fix comments.
137 2024-05-01  Bruno Haible  <bruno@clisp.org>
139         doc: Reference a gcc bug.
140         * doc/posix-headers/stddef.texi: Reference a gcc bug.
142 2024-05-01  Bruno Haible  <bruno@clisp.org>
144         sprintf-posix, snprintf-posix tests: Add comment.
145         Suggested by Collin Funk in
146         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00546.html>.
147         * tests/test-sprintf-posix.h (test_function): Add comment about known
148         failures.
150 2024-05-01  Collin Funk  <collin.funk1@gmail.com>
152         gnulib-tool.py: Fix mistake in previous commit.
153         * pygnulib/GLModuleSystem.py (GLModuleSystem.exists)
154         (GLModuleSystem.find): Rename 'module' argument to 'module_name' so it
155         is clear they are not a GLModule object. Treat them as such.
157 2024-05-01  Collin Funk  <collin.funk1@gmail.com>
159         gnulib-tool.py: Use the GLModule's name variable directly.
160         * pygnulib/GLModuleSystem.py (GLModule.getName): Remove function.
161         (GLModule.__str__, GLModule.__repr__, GLModule.isNonTests)
162         (GLModule.repeatModuleInTests, GLModule.getDependenciesRecursively)
163         (GLModule.getShellFunc, GLModule.getShellVar)
164         (GLModule.getConditionalName, GLModule.getApplicability)
165         (GLModule.getDependencies, GLModule.getAutomakeSnippet_Unconditional)
166         (GLModule.getLicense, GLModuleSystem.find)
167         (GLModuleTable.transitive_closure): Use the GLModule's name instance
168         variable instead of using str() or removed getName() function.
169         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet)
170         (GLEmiter.preEarlyMacros, GLEmiter.lib_Makefile_am)
171         (GLEmiter.tests_Makefile_am): Likewise.
172         * pygnulib/GLImport.py (GLImport.gnulib_comp, GLImport.prepare):
173         Likewise.
174         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
175         Likewise.
177 2024-04-30  Paul Eggert  <eggert@cs.ucla.edu>
179         intprops: document fix for GCC bug 68193
180         * lib/intprops-internal.h (_GL__GENERIC_BOGUS):
181         GCC bug 68193 is fixed in GCC 14.  This is just for documentation,
182         as _GL__GENERIC_BOGUS is not consulted in GCC 14.
184 2024-04-30  Bruno Haible  <bruno@clisp.org>
186         *printf: Don't invoke gl_PRINTF_DIRECTIVE_N when it's not needed.
187         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): Don't require
188         gl_PRINTF_DIRECTIVE_N if gl_PRINTF_SUPPORT_N_DIRECTIVE is not defined.
189         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
190         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): Likewise.
191         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
192         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Likewise.
193         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
194         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
195         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
196         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
197         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
198         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX): Likewise.
200 2024-04-30  Bruno Haible  <bruno@clisp.org>
202         *printf: Avoid a dialog during 'configure' with MSVC in debug mode.
203         Suggested by Paul Harris <harris.pc@gmail.com> in
204         <https://lists.gnu.org/archive/html/bug-gettext/2024-04/msg00005.html>.
205         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): In the test program, include
206         <crtdbg.h> and disable the MSVC reporting for assertion failures.
208 2024-04-30  Collin Funk  <collin.funk1@gmail.com>
210         gnulib-tool.py: Remove remaining unused instance variables.
211         * pygnulib/GLModuleSystem.py (GLModule.__init__)
212         (GLModuleTable.__init__): Remove the unused GLFileSystem variable. These
213         classes perform lookups with a GLModuleSystem.
214         * pygnulib/GLTestDir.py (GLTestDir.__init__): Remove the unused
215         GLFileAssistant variable. The transformations it performs are not needed
216         in testdirs.
218 2024-04-29  Collin Funk  <collin.funk1@gmail.com>
220         gnulib-tool.py: Add type hints to classes.
221         * pygnulib/*.py: Add type hints for all instance and class variables.
222         * pygnulib/GLMakefileTable.py (GLMakefileTable.__getitem__): Fix return
223         type hint since the dictionary has str values.
225 2024-04-29  Collin Funk  <collin.funk1@gmail.com>
227         gnulib-tool.py: Emit libtests in testdirs generated Makefile.am.
228         Reported by Bruno Haible in
229         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00463.html>.
230         * pygnulib/GLTestDir.py (GLTestDir.execute): Modify the GLEmiter's
231         config variable instead of the GLTestDir's so that it can be accessed
232         when emitting the Makefile.am.
234 2024-04-28  Collin Funk  <collin.funk1@gmail.com>
236         doc: Update macro list in gnulib-cache.m4 documentation.
237         * doc/gnulib-tool.texi (Modified imports): Add missing macros from the
238         sed invocation in func_import of gnulib-tool.sh.
240 2024-04-28  Collin Funk  <collin.funk1@gmail.com>
242         doc: Mention AC_CONFIG_MACRO_DIRS in configure.ac.
243         Document the following gnulib-tool change:
244         2021-12-19  Bruno Haible  <bruno@clisp.org>
245         gnulib-tool: Don't insist on ACLOCAL_AMFLAGS.
246         * doc/gnulib-tool.texi (Initial import): Update the example gnulib-tool
247         invocation. Document the use of AC_CONFIG_MACRO_DIRS as an alternative
248         to ACLOCAL_AMFLAGS.
250 2024-04-28  Bruno Haible  <bruno@clisp.org>
252         bootstrap: Support checking out a recent GNULIB_REVISION, part 2.
253         Reported by Markus Mützel <markus.muetzel@gmx.de> in
254         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00507.html>.
255         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): If using a submodule
256         and the 'git checkout' command fails, fetch the newer commits and then
257         retry it.
258         * build-aux/bootstrap: Regenerated.
260 2024-04-27  Collin Funk  <collin.funk1@gmail.com>
262         gnulib-tool.py: Preserve module ordering in --create-megatestdir.
263         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Use a separate set to
264         remove duplicates from the original list without sorting.
266 2024-04-27  Bruno Haible  <bruno@clisp.org>
268         gnulib-tool: Simplify the Python version test.
269         Suggested by Pádraig Brady in
270         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00469.html>.
271         * gnulib-tool: Use Python's sys.version_info, not --version.
272         * gnulib-tool.py: Use the same version test here. Use --version only to
273         produce a specific error message.
275 2024-04-27  Bruno Haible  <bruno@clisp.org>
277         fcntl-h, stdio, unistd: Ensure off64_t is defined on all platforms.
278         * lib/fcntl.in.h: Update comment regarding off64_t.
279         * lib/stdio.in.h: Likewise.
280         * lib/unistd.in.h: Likewise.
281         * tests/test-fcntl-h.c: Verify that off64_t is defined.
282         * tests/test-stdio.c: Likewise.
283         * tests/test-unistd.c: Likewise.
284         * doc/posix-headers/fcntl.texi: Mention the off64_t workaround.
285         * doc/posix-headers/stdio.texi: Likewise.
286         * doc/posix-headers/unistd.texi: Likewise.
287         * doc/posix-headers/aio.texi: Mention the problem with off64_t.
289         sys_types: Ensure off64_t is defined on all platforms.
290         * m4/off64_t.m4: New file.
291         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Require gl_TYPE_OFF64_T.
292         * lib/sys_types.in.h (off64_t): New type.
293         (GNULIB_defined_off64_t): New macro.
294         * modules/sys_types (Files): Add m4/off64_t.m4.
295         (configure.ac-early): Require AC_USE_SYSTEM_EXTENSIONS.
296         (Makefile.am): Substitute HAVE_OFF64_T.
297         * tests/test-sys_types.c: Verify that off64_t is defined.
298         * doc/posix-headers/sys_types.texi: Mention the off64_t workaround.
300 2024-04-27  Paul Eggert  <eggert@cs.ucla.edu>
302         nullptr: work around GCC nullptr sentinel bug
303         * m4/nullptr.m4 (gl_NULLPTR): Work around GCC bug 114780.
305         stddef: work around GCC stddef.h bugs
306         * lib/stddef.in.h: Do nothing if _@GUARD_PREFIX@_STDDEF_H is
307         defined, as stddef.h has already been included.  This works
308         around GCC bug 114870.
309         (_GCC_NULLPTR_T): Define if needed to work around GCC bug 114869.
310         * m4/stddef_h.m4 (gl_STDDEF_H, gl_STDDEF_H_DEFAULTS):
311         * modules/stddef (stddef.h):
312         Detect the two bugs.
313         * doc/posix-headers/stddef.texi: Mention one of the two bugs.
315 2024-04-27  Bruno Haible  <bruno@clisp.org>
317         bootstrap: Support checking out a recent GNULIB_REVISION.
318         Reported by Markus Mützel <markus.muetzel@gmx.de> in
319         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00462.html>.
320         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): If the
321         'git checkout' command fails, fetch the newer commits and then retry it.
322         * build-aux/bootstrap: Regenerated.
324 2024-04-27  Bruno Haible  <bruno@clisp.org>
326         ctime, localtime, tzset, wcsftime: Fix env access (regr. 2024-02-09).
327         Reported by Markus Mützel <markus.muetzel@gmx.de> in
328         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00457.html>.
329         * lib/ctime.c (rpl_ctime): Fix logic of environment traversal.
330         * lib/localtime.c (rpl_localtime): Likewise.
331         * lib/tzset.c (rpl_tzset): Likewise.
332         * lib/wcsftime.c (rpl_wcsftime): Likewise.
334 2024-04-26  Bruno Haible  <bruno@clisp.org>
336         login_tty tests: Avoid gcc warnings.
337         * tests/test-login_tty.c: Include ignore-value.h.
338         (main): Ignore the results of the freopen calls.
339         * modules/login_tty-tests (Depends-on): Add ignore-value.
341 2024-04-26  Bruno Haible  <bruno@clisp.org>
343         Document prerequisite for gnulib-tool.
344         Suggested by Collin Funk in
345         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00450.html>.
346         * DEPENDENCIES: Add Python 3.7 as "recommended".
348 2024-04-26  Bruno Haible  <bruno@clisp.org>
350         gnulib-tool: Use the Python implementation by default.
351         * gnulib-tool: If GNULIB_TOOL_IMPL is not set: Use the Python
352         implementation if a suitable 'python3' program is found in $PATH;
353         otherwise print a warning and use the shell implementation.
355 2024-04-26  Collin Funk  <collin.funk1@gmail.com>
357         gnulib-tool.py: Remove some unused instance variables.
358         * pygnulib/GLTestDir.py (GLMegaTestDir.__init__): Don't define instance
359         variables that are never used.
361 2024-04-25  Collin Funk  <collin.funk1@gmail.com>
363         gnulib-tool.py: Reduce code duplication in file name transformations.
364         * pygnulib/functions.py: New file for shared functions between modules.
365         Add a function based on functions removed from GLImport and GLTestDir.
366         Accepts a single file name instead of a list.
367         * pygnulib/GLImport.py (GLImport.prepare): Use the new function.
368         (GLImport.rewrite_new_files, GLImport.rewrite_old_files): Remove
369         functions.
370         * pygnulib/GLTestDir.py (GLTestDir.execute): Use the new function.
371         (GLTestDir.rewrite_files): Remove functions.
372         * pygnulib/main.py (main): Remove unused function import. Use the new
373         function.
375 2024-04-25  Bruno Haible  <bruno@clisp.org>
377         doc: Remove documentation of IRIX as supported platform.
378         * doc/posix-headers/netdb.texi: Don't mention IRIX specific workarounds.
379         * doc/posix-headers/pthread.texi: Likewise.
380         * doc/posix-headers/sys_socket.texi: Likewise.
381         * doc/posix-headers/wctype.texi: Likewise.
382         * doc/posix-functions/btowc.texi: Likewise.
383         * doc/posix-functions/cbrtf.texi: Likewise.
384         * doc/posix-functions/cbrtl.texi: Likewise.
385         * doc/posix-functions/copysignf.texi: Likewise.
386         * doc/posix-functions/exp2.texi: Likewise.
387         * doc/posix-functions/exp2f.texi: Likewise.
388         * doc/posix-functions/exp2l.texi: Likewise.
389         * doc/posix-functions/expm1f.texi: Likewise.
390         * doc/posix-functions/expm1l.texi: Likewise.
391         * doc/posix-functions/fabsl.texi: Likewise.
392         * doc/posix-functions/isnan.texi: Likewise.
393         * doc/posix-functions/iswblank.texi: Likewise.
394         * doc/posix-functions/link.texi: Likewise.
395         * doc/posix-functions/log10l.texi: Likewise.
396         * doc/posix-functions/log1pf.texi: Likewise.
397         * doc/posix-functions/log2.texi: Likewise.
398         * doc/posix-functions/log2f.texi: Likewise.
399         * doc/posix-functions/log2l.texi: Likewise.
400         * doc/posix-functions/lseek.texi: Likewise.
401         * doc/posix-functions/nl_langinfo.texi: Likewise.
402         * doc/posix-functions/pthread_sigmask.texi: Likewise.
403         * doc/posix-functions/remainderf.texi: Likewise.
404         * doc/posix-functions/remainderl.texi: Likewise.
405         * doc/posix-functions/rintf.texi: Likewise.
406         * doc/posix-functions/sigaltstack.texi: Likewise.
407         * doc/posix-functions/strtod.texi: Likewise.
408         * doc/posix-functions/strtold.texi: Likewise.
409         * doc/posix-functions/vscanf.texi: Likewise.
410         * doc/posix-functions/wctob.texi: Likewise.
411         * doc/**/*.texi: Update.
413 2024-04-25  Collin Funk  <collin.funk1@gmail.com>
415         HACKING: Fix a typo.
416         * HACKING: Add missing 't' to platforms.
418 2024-04-25  Bruno Haible  <bruno@clisp.org>
420         relocatable-lib-lgpl: Allow unconditional use of set_relocation_prefix.
421         Reported by Reuben Thomas <rrt@sc3d.org> in
422         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00384.html>.
423         * lib/relocatable.h (set_relocation_prefix): Define in a dummy way if
424         ENABLE_RELOCATABLE is not defined.
426 2024-04-25  Bruno Haible  <bruno@clisp.org>
428         doc: Update target platforms list.
429         * doc/gnulib-intro.texi (Supported Platforms): Mention FreeBSD 14
430         instead of 13. Mention AIX 7.3 instead of 7.2. Mention Cygwin 3.4.
431         Don't mention IRIX.
432         (Formerly Supported Platforms): Add IRIX.
434 2024-04-25  Bruno Haible  <bruno@clisp.org>
436         largefile: Update documentation.
437         * doc/largefile.texi: Remove mention of IRIX.
439 2024-04-24  Collin Funk  <collin.funk1@gmail.com>
441         gnulib-tool.py: Add a new GLFileTable class.
442         * pygnulib/GLFileTable.py: New file. Define the GLFileTable class with
443         five attributes which can be individually typed.
444         * pygnulib/GLTestDir.py (GLTestDir.execute): Use the GLFileTable class.
445         * pygnulib/GLImport.py (GLImport.gnulib_comp, GLImport.prepare)
446         (GLImport.execute): Likewise. Update type hints and doc strings.
448 2024-04-24  Paul Eggert  <eggert@cs.ucla.edu>
450         largefile: port to C++
451         This patch is mostly taken from Autoconf master.
452         * m4/largefile.m4 (AC_SYS_YEAR2038_RECOMMENDED):
453         Undefine if unpatched Autoconf 2.72 or earlier, so that
454         later code will redefine it.
455         The remaining part of this patch is from Autoconf master.
456         (_AC_SYS_YEAR2038_PROBE, _AC_SYS_LARGEFILE_PROBE):
457         Put "$CCFLAGS" in diagnostics, not "$CC".
458         (_AC_SYS_LARGEFILE_OPTIONS): Omit -n32.
459         (AC_SYS_LARGEFILE_PROBE): Fiddle with CPPFLAGS, not CC.
460         Do not worry about -n32.
462         c32srtombs,mbsrtoc32s,mbsrtowcs,wcsrtombs: pacify GCC 14
463         * lib/c32srtombs-state.c (_gl_c32srtombs_state):
464         * lib/mbsrtoc32s-state.c (_gl_mbsrtoc32s_state):
465         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state):
466         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state):
467         Add an extern decl for a “private” extern symbol, to pacify GCC
468         14’s -Wmissing-variable-declarations option.
470 2024-04-24  Bruno Haible  <bruno@clisp.org>
472         physmem: Port better to Linux.
473         * lib/physmem.h (physmem_total, physmem_available): Add documentation.
474         (physmem_claimable): New declaration.
475         * lib/physmem.c: Include <fcntl.h>, <stdio.h>, full-read.h.
476         (get_meminfo): New function.
477         (physmem_claimable): Renamed from physmem_available. Add logic for
478         aggressivity > 0.
479         (physmem_available): New function.
480         * modules/physmem (Depends-on): Add full-read.
482 2024-04-24  Bruno Haible  <bruno@clisp.org>
484         Fix warnings triggered by including <config.h> twice (regr. 2024-04-19).
485         Reported by Collin Funk in
486         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00398.html>.
487         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use AH_VERBATIM instead
488         of AC_DEFINE.
490 2024-04-23  Paul Eggert  <eggert@cs.ucla.edu>
492         manywarnings: update C warnings for GCC 14
493         Adjust for C programs compiled by GCC 14.
494         (A C++ expert still needs to look at manywarnings-c++.m4.)
495         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 14.
496         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
497         Add -Wflex-array-member-not-at-end, -Wmissing-variable-declarations.
499 2024-04-23  Bruno Haible  <bruno@clisp.org>
501         Update HACKING.
502         Suggested by Paul Eggert in
503         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00388.html>.
504         * HACKING: Mention an alternative to gitk.
506 2024-04-23  Collin Funk  <collin.funk1@gmail.com>
508         gnulib-tool.py: Make better use of imports.
509         * pygnulib/*.py: Import functions from constants.py directly instead of
510         assigning them to module-specific variable. Keep the module prefix for
511         standard library functions.
513 2024-04-23  Bruno Haible  <bruno@clisp.org>
515         Update HACKING.
516         * HACKING: Mention the linear git history, how to work with ChangeLog,
517         how to run a testdir, where to find the gnulib-tool tests, and where are
518         the continuous integrations.
520 2024-04-22  Bruno Haible  <bruno@clisp.org>
522         gnulib-tool: Fix trouble caused by Python's bytecode cache.
523         Reported by Paul Eggert in
524         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00367.html>.
525         * gnulib-tool: In sh+py mode, ignore the __pycache__ directory during
526         comparison.
528 2024-04-22  Bruno Haible  <bruno@clisp.org>
530         gnulib-tool.py: Fix trouble caused by Python's bytecode cache.
531         Reported by Paul Eggert in
532         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00367.html>.
533         * gnulib-tool.py: Set PYTHONPYCACHEPREFIX, so as to avoid creating a
534         __pycache__ directory in the developer's gnulib checkout (only effective
535         with Python ≥ 3.8).
537 2024-04-21  Collin Funk  <collin.funk1@gmail.com>
539         gnulib-tool.py: Make temporary directories recognizable.
540         * pygnulib/GLConfig.py (GLConfig.__init__): Pass the 'glpy' prefix to
541         mkdtemp.
543 2024-04-21  Bruno Haible  <bruno@clisp.org>
545         gnulib-tool.sh: In --create-testdir, just warn about a bad module name.
546         * gnulib-tool.sh (func_create_testdir): Validate the modules list.
548 2024-04-21  Collin Funk  <collin.funk1@gmail.com>
550         gnulib-tool.py: Don't fail when given a bad module name.
551         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't include None in the
552         list of GLModule objects.
553         * pygnulib/GLModuleSystem.py (GLModuleSystem.find): Document the meaning
554         of the None return.
556 2024-04-21  Collin Funk  <collin.funk1@gmail.com>
558         gnulib-tool.py: Update type hints and docstring.
559         * pygnulib/GLImport.py (GLImport.execute): Update transformer type hint
560         to reflect change from sed expressions to re.sub() arguments.
561         (GLImport.prepare): Likewise. Don't reference sed or license
562         replacements in docstring.
564 2024-04-20  Bruno Haible  <bruno@clisp.org>
566         signed-snan: Relicense under LGPLv2+.
567         * modules/signed-snan (License): Change to LGPLv2+.
568         * lib/signed-snan.h: Update license notice.
570         snan: Relicense under LGPLv2+.
571         * modules/snan (License): Change to LGPLv2+.
572         * lib/snan.h: Update license notice.
574         signed-nan: Relicense under LGPLv2+.
575         * modules/signed-nan (License): Change to LGPLv2+.
576         * lib/signed-nan.h: Update license notice.
578         nan: Relicense under LGPLv2+.
579         Eric Blake's approval is in
580         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00290.html>.
581         Paul Eggert's approval is in
582         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00324.html>.
583         Daniel Richard G.'s approval was given in private email.
584         * modules/nan (License): Change to LGPLv2+.
585         * lib/nan.h: Update license notice.
587 2024-04-20  Bruno Haible  <bruno@clisp.org>
589         gnulib-tool: In sh+py mode, don't fail because of dangling symlinks.
590         Reported by Paul Eggert in
591         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00318.html>
592         and Pádraig Brady in
593         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00321.html>.
594         * gnulib-tool: In sh+py mode, use diff option '--no-dereference' if
595         available.
597 2024-04-20  Collin Funk  <collin.funk1@gmail.com>
599         gnulib-tool.py: Remove duplicate per-module definitions.
600         * pygnulib/constants.py: Remove duplicate __authors__, __license__, and
601         __copyright__ definitions.
602         * pygnulib/GLInfo.py: Use the value of __authors__ and __copyright__
603         from __init__.py for output.
604         * pygnulib/*.py: Remove unused references to the constant.py
605         definitions.
607 2024-04-20  Bruno Haible  <bruno@clisp.org>
609         gnulib-tool.py: Fix a bug in removed / added files handling.
610         * pygnulib/GLImport.py (GLImport.execute): When looking for files that
611         are in both filetable['old'] and filetable['new'], consider only the
612         first element of each tuple, not the entire tuple.
614 2024-04-20  Bruno Haible  <bruno@clisp.org>
616         gnulib-tool.py: Sort file lists case-sensitively.
617         * pygnulib/GLImport.py (GLImport.prepare, GLImport.execute): Omit
618         .lower() call in sort key computation.
620 2024-04-20  Bruno Haible  <bruno@clisp.org>
622         gnulib-tool.py: Fix output of --create-megatestdir.
623         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Remove stray backslash
624         from output.
626 2024-04-19  Bruno Haible  <bruno@clisp.org>
628         wcsstr: Update doc.
629         * doc/posix-functions/wcsstr.texi: Update glibc version.
631 2024-04-19  Bruno Haible  <bruno@clisp.org>
633         getlogin_r tests: Fix compilation error on some OpenSolaris derivatives.
634         * tests/test-getlogin_r.c (getlogin_r): Don't check the signature on
635         Solaris.
637 2024-04-19  Bruno Haible  <bruno@clisp.org>
639         memset_explicit: Fix compilation error on some OpenSolaris derivatives.
640         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Arrange to define
641         __STDC_WANT_LIB_EXT1__ to 1.
642         * modules/memset_explicit (Depends-on): Add extensions.
643         * m4/memset_explicit.m4 (gl_FUNC_MEMSET_EXPLICIT): Require
644         gl_USE_SYSTEM_EXTENSIONS.
645         * lib/memset_explicit.c (__STDC_WANT_LIB_EXT1__): Remove definition.
647 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
649         gnulib-tool.py: Make use of GLModule's __hash__ method.
650         * pygnulib/GLModuleSystem.py (GLModuleTable.addUnconditional)
651         (GLModuleTable.isConditional): Use the GLModule object instead of the
652         module name directly.
653         (GLModuleTable.addConditional, GLModuleTable.getCondition): Likewise.
654         Use a tuple of two GLModule objects as a key for the conditionals
655         dictionary.
657 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
659         gnulib-tool.py: Simplify data structures for dependencies.
660         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Use a defaultdict
661         for dependers to remove the base initialization case.
662         (GLModuleTable.addConditional): Use a set to disallow duplicates instead
663         of performing list lookups.
665 2024-04-19  Bruno Haible  <bruno@clisp.org>
667         gnulib-tool.py: Simplify running some commands in a given directory.
668         * pygnulib/GLImport.py (GLImport.execute): Use sp.call with a cwd
669         argument, instead of calling chdir twice.
670         * pygnulib/GLModuleSystem.py (GLModuleSystem.list): Likewise.
671         * pygnulib/main.py (mode=='find'): Likewise.
673 2024-04-19  Bruno Haible  <bruno@clisp.org>
675         gnulib-tool.py: Update authors list.
676         * pygnulib/constants.py (__author__): Add Collin Funk.
677         * pygnulib/__init__.py (__copyright__, __author__): Include years and
678         authors of the gnulib-tool shell script.
680 2024-04-19  Bruno Haible  <bruno@clisp.org>
682         getpayload* tests: Don't assume that '-' works as expected on NaN.
683         * tests/test-getpayload.c: Include signed-nan.h.
684         (main): Use minus_NaNd.
685         * tests/test-getpayloadf.c: Include signed-nan.h.
686         (main): Use minus_NaNf.
687         * tests/test-getpayloadl.c: Include signed-nan.h.
688         (main): Use minus_NaNl.
689         * modules/getpayload-tests (Depends-on): Add signed-nan.
690         * modules/getpayloadf-tests (Depends-on): Likewise.
691         * modules/getpayloadl-tests (Depends-on): Likewise.
693         signed-nan: Don't assume that '-' works as expected on NaN values.
694         * lib/signed-nan.h (minus_NaNf): New function.
695         (positive_NaNf, negative_NaNf): Use it.
696         (minus_NaNd): New function.
697         (positive_NaNd, negative_NaNd): Use it.
698         (minus_NaNl): New function.
699         (positive_NaNl, negative_NaNl): Use it.
700         * tests/test-totalorder.c (TOTALORDER_MINUS): New macro.
701         * tests/test-totalorderf.c (TOTALORDER_MINUS): New macro.
702         * tests/test-totalorderl.c (TOTALORDER_MINUS): New macro.
703         * tests/test-totalorder.h (negative_NaN_with_payload): Use it.
704         * tests/test-totalordermag.c (TOTALORDER_MINUS): New macro.
705         * tests/test-totalordermagf.c (TOTALORDER_MINUS): New macro.
706         * tests/test-totalordermagl.c (TOTALORDER_MINUS): New macro.
707         * tests/test-totalordermag.h (negative_NaN_with_payload): Use it.
709 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
711         gnulib-tool.py: Add a comment about coding style.
712         * pygnulib/main.py: Add a note about the common convention of using an
713         underscore prefix to mark a function/variable as private.
715 2024-04-19  Collin Funk  <collin.funk1@gmail.com>
717         gnulib-tool.py: Remove some unused instance variables.
718         * pygnulib/GLModuleSystem.py (GLModuleSystem.__init__)
719         (GLModule.__init__): Remove unused 'args' instance variable.
721 2024-04-19  Paul Eggert  <eggert@cs.ucla.edu>
723         fstatat, stat: document macOS st_ino pipe bug
724         * doc/posix-functions/fstatat.texi (fstatat):
725         * doc/posix-functions/stat.texi (stat):
726         Document macOS bug (see <https://bugs.gnu.org/70411>).
728 2024-04-18  Bruno Haible  <bruno@clisp.org>
730         totalordermagl: Add tests.
731         * tests/test-totalordermagl.c: New file, based on
732         tests/test-totalorderl.c.
733         * modules/totalordermagl-tests: New file, based on
734         modules/totalorderl-tests.
736         totalordermagl: New module.
737         * lib/math.in.h (totalordermagl): New declaration.
738         * lib/totalordermagl.c: New file, based on lib/totalorderl.c.
739         * m4/math_h.m4 (gl_MATH_H): Test whether totalordermagl is declared.
740         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_TOTALORDERMAGL.
741         (gl_MATH_H_DEFAULTS): Initialize HAVE_TOTALORDERMAGL,
742         REPLACE_TOTALORDERMAGL.
743         * modules/math (Makefile.am): Substitute GNULIB_TOTALORDERMAGL,
744         HAVE_TOTALORDERMAGL, REPLACE_TOTALORDERMAGL.
745         * modules/totalordermagl: New file, based on modules/totalorderl.
746         * doc/posix-functions/totalordermagl.texi: Mention the new module.
748 2024-04-18  Bruno Haible  <bruno@clisp.org>
750         totalordermagf: Add tests.
751         * tests/test-totalordermagf.c: New file, based on
752         tests/test-totalorderf.c.
753         * modules/totalordermagf-tests: New file, based on
754         modules/totalorderf-tests.
756         totalordermagf: New module.
757         * lib/math.in.h (totalordermagf): New declaration.
758         * lib/totalordermagf.c: New file, based on lib/totalorderf.c.
759         * m4/math_h.m4 (gl_MATH_H): Test whether totalordermagf is declared.
760         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_TOTALORDERMAGF.
761         (gl_MATH_H_DEFAULTS): Initialize HAVE_TOTALORDERMAGF,
762         REPLACE_TOTALORDERMAGF.
763         * modules/math (Makefile.am): Substitute GNULIB_TOTALORDERMAGF,
764         HAVE_TOTALORDERMAGF, REPLACE_TOTALORDERMAGF.
765         * modules/totalordermagf: New file, based on modules/totalorderf.
766         * doc/posix-functions/totalordermagf.texi: Mention the new module.
768 2024-04-18  Bruno Haible  <bruno@clisp.org>
770         totalordermag: Add tests.
771         * tests/test-totalordermag.c: New file, based on
772         tests/test-totalorder.c.
773         * tests/test-totalordermag.h: New file, based on
774         tests/test-totalorder.h.
775         * modules/totalordermag-tests: New file, based on
776         modules/totalorder-tests.
778         totalordermag: New module.
779         * lib/math.in.h (totalordermag): New declaration.
780         * lib/totalordermag.c: New file, based on lib/totalorder.c.
781         * m4/totalordermag.m4: New file, based on m4/totalorder.m4.
782         * m4/math_h.m4 (gl_MATH_H): Test whether totalordermag is declared.
783         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_TOTALORDERMAG.
784         (gl_MATH_H_DEFAULTS): Initialize HAVE_TOTALORDERMAG,
785         REPLACE_TOTALORDERMAG.
786         * modules/math (Makefile.am): Substitute GNULIB_TOTALORDERMAG,
787         HAVE_TOTALORDERMAG, REPLACE_TOTALORDERMAG.
788         * modules/totalordermag: New file, based on modules/totalorder.
789         * doc/posix-functions/totalordermag.texi: Mention the new module.
791 2024-04-18  Bruno Haible  <bruno@clisp.org>
793         setpayloadsig*: Support newer MIPS CPUs.
794         * lib/setpayloadsig.c (setpayloadsig): On MIPS CPUs with MIPS_NAN2008_DOUBLE,
795         reject a zero payload.
796         * lib/setpayloadsigf.c (setpayloadsigf): On MIPS CPUs with MIPS_NAN2008_FLOAT,
797         reject a zero payload.
798         * lib/setpayloadsigl.c (setpayloadsigl): On MIPS CPUs with
799         MIPS_NAN2008_LONG_DOUBLE, reject a zero payload.
801 2024-04-18  Bruno Haible  <bruno@clisp.org>
803         setpayload*: Support newer MIPS CPUs.
804         * lib/setpayload.c (setpayload): On MIPS CPUs with MIPS_NAN2008_DOUBLE,
805         accept a zero payload.
806         * lib/setpayloadf.c (setpayloadf): On MIPS CPUs with MIPS_NAN2008_FLOAT,
807         accept a zero payload.
808         * lib/setpayloadl.c (setpayloadl): On MIPS CPUs with
809         MIPS_NAN2008_LONG_DOUBLE, accept a zero payload.
810         * m4/setpayload.m4 (gl_FUNC_SETPAYLOADF, gl_FUNC_SETPAYLOAD,
811         gl_FUNC_SETPAYLOADL): Invoke gl_NAN_MIPS.
812         * modules/setpayload (Files): Add m4/nan-mips.m4.
813         * modules/setpayloadf (Files): Likewise.
814         * modules/setpayloadl (Files): Likewise.
816 2024-04-18  Bruno Haible  <bruno@clisp.org>
818         totalorder*: Support newer MIPS CPUs.
819         * lib/totalorder.c (totalorder): On MIPS CPUs with MIPS_NAN2008_DOUBLE,
820         don't invert the most significant bit of the mantissa field.
821         * lib/totalorderf.c (totalorderf): On MIPS CPUs with MIPS_NAN2008_FLOAT,
822         don't invert the most significant bit of the mantissa field.
823         * lib/totalorderl.c (totalorderl): On MIPS CPUs with
824         MIPS_NAN2008_LONG_DOUBLE, don't invert the most significant bit of the
825         mantissa field.
826         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF, gl_FUNC_TOTALORDER,
827         gl_FUNC_TOTALORDERL): Invoke gl_NAN_MIPS.
828         * modules/totalorder (Files): Add m4/nan-mips.m4.
829         * modules/totalorderf (Files): Likewise.
830         * modules/totalorderl (Files): Likewise.
832 2024-04-18  Bruno Haible  <bruno@clisp.org>
834         snan: Add support for m68k.
835         * lib/snan.h (construct_memory_SNaNl): Handle m68k specially.
837 2024-04-18  Bruno Haible  <bruno@clisp.org>
839         totalorderl: Simplify on MSVC.
840         * lib/totalorderl.c (totalorderl): If 'long double' is the same as
841         'double', just invoke totalorder. Otherwise, drop the optimized code
842         for small 'long double' since it does not occur on any platform.
843         * m4/totalorder.m4 (gl_FUNC_TOTALORDERL): Require
844         gl_LONG_DOUBLE_VS_DOUBLE. If 'long double' is the same as 'double', use
845         TOTALORDER_LIBM.
846         * modules/totalorderl (Depends-on): Add totalorder.
848 2024-04-18  Bruno Haible  <bruno@clisp.org>
850         signbit: Fix typos.
851         * lib/signbitd.c: Fix typo in comment.
852         * lib/signbitf.c: Likewise.
854 2024-04-18  Collin Funk  <collin.funk1@gmail.com>
856         gnulib-tool.py: Ignore 'attribute-defined-outside-init' warnings.
857         * pygnulib/.pylintrc: Add W0201 to the disabled warnings.
858         See discussion here:
859         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00275.html>
861 2024-04-17  Bruno Haible  <bruno@clisp.org>
863         totalorder* tests: Strengthen tests.
864         * tests/test-totalorder.h: Include <math.h>.
865         (positive_NaN_with_payload, negative_NaN_with_payload): New functions.
866         (main): Test quiet NaNs of each sign with different payload.
867         * tests/test-totalorder.c (TOTALORDER_POSITIVE_NAN,
868         TOTALORDER_NEGATIVE_NAN): Remove macros.
869         (TOTALORDER_SETPAYLOAD): New macro.
870         * tests/test-totalorderf.c (TOTALORDER_POSITIVE_NAN,
871         TOTALORDER_NEGATIVE_NAN): Remove macros.
872         (TOTALORDER_SETPAYLOAD): New macro.
873         * tests/test-totalorderl.c (TOTALORDER_POSITIVE_NAN,
874         TOTALORDER_NEGATIVE_NAN): Remove macros.
875         (TOTALORDER_SETPAYLOAD): New macro.
876         * modules/totalorder-tests (Depends-on): Add setpayload.
877         (Makefile.am): Link test-totalorder with $(SETPAYLOAD_LIBM).
878         * modules/totalorderf-tests (Depends-on): Add setpayloadf.
879         (Makefile.am): Link test-totalorderf with $(SETPAYLOADF_LIBM).
880         * modules/totalorderl-tests (Depends-on): Add setpayloadl.
881         (Makefile.am): Link test-totalorderl with $(SETPAYLOADL_LIBM).
883 2024-04-17  Bruno Haible  <bruno@clisp.org>
885         gnulib-tool.py: Use same warning style as gnulib-tool.sh.
886         * pygnulib/GLTestDir.py (GLTestDir.execute): Prefix the
887         "incompatible license" message with "gnulib-tool: warning: ".
889 2024-04-17  Bruno Haible  <bruno@clisp.org>
891         stdio, utime-h: Fix more linkage errors when using C++.
892         * lib/stdio.in.h (rpl_fwrite, rpl_fwrite_unlocked): Use _GL_EXTERN_C
893         instead of extern.
894         * lib/utime.in.h (_gl_utimens_windows): Likewise.
896 2024-04-17  Bruno Haible  <bruno@clisp.org>
898         Fix linkage errors when using C++.
899         Reported by Miro Palmu <email@miropalmu.cc> in
900         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00274.html>.
901         * lib/acl.h: Add 'extern "C" {' / '}' boilerplate.
902         * lib/alignalloc.h: Likewise.
903         * lib/aligned-malloc.h: Likewise.
904         * lib/allocator.h: Likewise.
905         * lib/arcfour.h: Likewise.
906         * lib/arctwo.h: Likewise.
907         * lib/areadlink.h: Likewise.
908         * lib/argv-iter.h: Likewise.
909         * lib/argz.in.h: Likewise.
910         * lib/binary-io.h: Likewise.
911         * lib/bitrotate.h: Likewise.
912         * lib/bitset.h: Likewise.
913         * lib/bitsetv.h: Likewise.
914         * lib/c-strcaseeq.h: Likewise.
915         * lib/canon-host.h: Likewise.
916         * lib/careadlinkat.h: Likewise.
917         * lib/chdir-long.h: Likewise.
918         * lib/check-version.h: Likewise.
919         * lib/classpath.h: Likewise.
920         * lib/cloexec.h: Likewise.
921         * lib/close-stream.h: Likewise.
922         * lib/crc.h: Likewise.
923         * lib/csharpcomp.h: Likewise.
924         * lib/csharpexec.h: Likewise.
925         * lib/cycle-check.h: Likewise.
926         * lib/des.h: Likewise.
927         * lib/dev-ino.h: Likewise.
928         * lib/di-set.h: Likewise.
929         * lib/eealloc.h: Likewise.
930         * lib/exclude.h: Likewise.
931         * lib/execinfo.in.h: Likewise.
932         * lib/execute.h: Likewise.
933         * lib/exitfail.h: Likewise.
934         * lib/fcntl-safer.h: Likewise.
935         * lib/file-set.h: Likewise.
936         * lib/file-type.h: Likewise.
937         * lib/filenamecat.h: Likewise.
938         * lib/filevercmp.h: Likewise.
939         * lib/fpending.h: Likewise.
940         * lib/fprintftime.h: Likewise.
941         * lib/fpucw.h: Likewise.
942         * lib/fsusage.h: Likewise.
943         * lib/ftoastr.h: Likewise.
944         * lib/full-read.h: Likewise.
945         * lib/gc.h: Likewise.
946         * lib/getndelim2.h: Likewise.
947         * lib/getnline.h: Likewise.
948         * lib/getugroups.h: Likewise.
949         * lib/glthread/tls.h: Likewise.
950         * lib/hamt.h: Likewise.
951         * lib/hard-locale.h: Likewise.
952         * lib/hash-pjw-bare.h: Likewise.
953         * lib/hash-pjw.h: Likewise.
954         * lib/hash-triple.h: Likewise.
955         * lib/hmac.h: Likewise.
956         * lib/human.h: Likewise.
957         * lib/i-ring.h: Likewise.
958         * lib/idcache.h: Likewise.
959         * lib/idx.h: Likewise.
960         * lib/ino-map.h: Likewise.
961         * lib/inttostr.h: Likewise.
962         * lib/isapipe.h: Likewise.
963         * lib/javacomp.h: Likewise.
964         * lib/javaexec.h: Likewise.
965         * lib/jit/cache.h: Likewise.
966         * lib/linebuffer.h: Likewise.
967         * lib/localeinfo.h: Likewise.
968         * lib/long-options.h: Likewise.
969         * lib/mbchar.h: Likewise.
970         * lib/mbfile.h: Likewise.
971         * lib/mbiter.h: Likewise.
972         * lib/mbiterf.h: Likewise.
973         * lib/mbuiter.h: Likewise.
974         * lib/mbuiterf.h: Likewise.
975         * lib/mcel.h: Likewise.
976         * lib/memcasecmp.h: Likewise.
977         * lib/memcoll.h: Likewise.
978         * lib/memxor.h: Likewise.
979         * lib/mgetgroups.h: Likewise.
980         * lib/mkdir-p.h: Likewise.
981         * lib/modechange.h: Likewise.
982         * lib/mountlist.h: Likewise.
983         * lib/mpsort.h: Likewise.
984         * lib/msvc-nothrow.h: Likewise.
985         * lib/nan.h: Likewise.
986         * lib/openat-priv.h: Likewise.
987         * lib/openat.h: Likewise.
988         * lib/opendirat.h: Likewise.
989         * lib/pagealign_alloc.h: Likewise.
990         * lib/parse-datetime.h: Likewise.
991         * lib/parse-duration.h: Likewise.
992         * lib/physmem.h: Likewise.
993         * lib/posixtm.h: Likewise.
994         * lib/posixver.h: Likewise.
995         * lib/printf-frexp.h: Likewise.
996         * lib/printf-frexpl.h: Likewise.
997         * lib/priv-set.h: Likewise.
998         * lib/quote.h: Likewise.
999         * lib/quotearg.h: Likewise.
1000         * lib/read-file.h: Likewise.
1001         * lib/readline.h: Likewise.
1002         * lib/readtokens.h: Likewise.
1003         * lib/readtokens0.h: Likewise.
1004         * lib/regex-quote.h: Likewise.
1005         * lib/renameatu.h: Likewise.
1006         * lib/rijndael-alg-fst.h: Likewise.
1007         * lib/rijndael-api-fst.h: Likewise.
1008         * lib/safe-alloc.h: Likewise.
1009         * lib/safe-write.h: Likewise.
1010         * lib/same-inode.h: Likewise.
1011         * lib/same.h: Likewise.
1012         * lib/save-cwd.h: Likewise.
1013         * lib/savedir.h: Likewise.
1014         * lib/savewd.h: Likewise.
1015         * lib/selinux-at.h: Likewise.
1016         * lib/signed-nan.h: Likewise.
1017         * lib/signed-snan.h: Likewise.
1018         * lib/snan.h: Likewise.
1019         * lib/sockets.h: Likewise.
1020         * lib/stdio-safer.h: Likewise.
1021         * lib/stdlib-safer.h: Likewise.
1022         * lib/streq.h: Likewise.
1023         * lib/strerror-override.h: Likewise.
1024         * lib/tmpdir.h: Likewise.
1025         * lib/trim.h: Likewise.
1026         * lib/u64.h: Likewise.
1027         * lib/unicase/casefold.h: Likewise.
1028         * lib/unicase/caseprop.h: Likewise.
1029         * lib/unicase/invariant.h: Likewise.
1030         * lib/unicase/special-casing.in.h: Likewise.
1031         * lib/unicase/unicasemap.h: Likewise.
1032         * lib/unicodeio.h: Likewise.
1033         * lib/unilbrk/lbrktables.h: Likewise.
1034         * lib/unilbrk/ulc-common.h: Likewise.
1035         * lib/uninorm/decompose-internal.h: Likewise.
1036         * lib/unistd-safer.h: Likewise.
1037         * lib/unitypes.in.h: Likewise.
1038         * lib/uniwbrk/wbrktable.h: Likewise.
1039         * lib/unlinkdir.h: Likewise.
1040         * lib/userspec.h: Likewise.
1041         * lib/utimecmp.h: Likewise.
1042         * lib/utimens.h: Likewise.
1043         * lib/windows-spawn.h: Likewise.
1044         * lib/write-any-file.h: Likewise.
1045         * lib/xbinary-io.h: Likewise.
1046         * lib/xgetcwd.h: Likewise.
1047         * lib/xgetdomainname.h: Likewise.
1048         * lib/xgethostname.h: Likewise.
1049         * lib/xmemcoll.h: Likewise.
1050         * lib/xprintf.h: Likewise.
1051         * lib/xreadlink.h: Likewise.
1052         * lib/xsize.h: Likewise.
1053         * lib/xstrndup.h: Likewise.
1054         * lib/xstrtod.h: Likewise.
1055         * lib/xstrtol.h: Likewise.
1056         * lib/yesno.h: Likewise.
1057         * lib/isnand-nolibm.h (isnand): Declare with C linkage.
1058         * lib/isnanf-nolibm.h (isnanf): Likewise.
1059         * lib/isnanl-nolibm.h (isnanl): Likewise.
1061 2024-04-17  Collin Funk  <collin.funk1@gmail.com>
1063         gnulib-tool.py: Make an instance variable local to a function.
1064         * pygnulib/GLImport.py (GLImport.execute): Define the GLFileAssistant as
1065         local to this function because it is unused elsewhere.
1067 2024-04-17  Collin Funk  <collin.funk1@gmail.com>
1069         gnulib-tool.py: Remove an unused instance attribute.
1070         * pygnulib/GLImport.py (GLImport.__init__): Remove the unused
1071         GLFileSystem object.
1073 2024-04-17  Collin Funk  <collin.funk1@gmail.com>
1075         gnulib-tool.py: Fix a pylint 'attribute-defined-outside-init' warning.
1076         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Don't
1077         define a 'modules' attribute since it is never used.
1079 2024-04-17  Bruno Haible  <bruno@clisp.org>
1081         getpayloadl: Add tests.
1082         * tests/test-getpayloadl.c: New file.
1083         * modules/getpayloadl-tests: New file.
1085         getpayloadl: New module.
1086         * lib/math.in.h (getpayloadl): New declaration.
1087         * lib/getpayloadl.c: New file.
1088         * m4/math_h.m4 (gl_MATH_H): Test whether getpayloadl is declared.
1089         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPAYLOADL.
1090         (gl_MATH_H_DEFAULTS): Initialize HAVE_GETPAYLOADL, REPLACE_GETPAYLOADL.
1091         * modules/math (Makefile.am): Substitute GNULIB_GETPAYLOADL,
1092         HAVE_GETPAYLOADL, REPLACE_GETPAYLOADL.
1093         * modules/getpayloadl: New file.
1094         * doc/posix-functions/getpayloadl.texi: Mention the new module and the
1095         glibc bug.
1097 2024-04-17  Bruno Haible  <bruno@clisp.org>
1099         getpayloadf: Add tests.
1100         * tests/test-getpayloadf.c: New file.
1101         * modules/getpayloadf-tests: New file.
1103         getpayloadf: New module.
1104         * lib/math.in.h (getpayloadf): New declaration.
1105         * lib/getpayloadf.c: New file.
1106         * m4/math_h.m4 (gl_MATH_H): Test whether getpayloadf is declared.
1107         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPAYLOADF.
1108         (gl_MATH_H_DEFAULTS): Initialize HAVE_GETPAYLOADF, REPLACE_GETPAYLOADF.
1109         * modules/math (Makefile.am): Substitute GNULIB_GETPAYLOADF,
1110         HAVE_GETPAYLOADF, REPLACE_GETPAYLOADF.
1111         * modules/getpayloadf: New file.
1112         * doc/posix-functions/getpayloadf.texi: Mention the new module and the
1113         glibc bug.
1115 2024-04-17  Bruno Haible  <bruno@clisp.org>
1117         getpayload: Add tests.
1118         * tests/test-getpayload.c: New file.
1119         * modules/getpayload-tests: New file.
1121         getpayload: New module.
1122         * lib/math.in.h (getpayload): New declaration.
1123         * lib/getpayload.c: New file.
1124         * m4/getpayload.m4: New file.
1125         * m4/math_h.m4 (gl_MATH_H): Test whether getpayload is declared.
1126         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPAYLOAD.
1127         (gl_MATH_H_DEFAULTS): Initialize HAVE_GETPAYLOAD, REPLACE_GETPAYLOAD.
1128         * modules/math (Makefile.am): Substitute GNULIB_GETPAYLOAD,
1129         HAVE_GETPAYLOAD, REPLACE_GETPAYLOAD.
1130         * modules/getpayload: New file.
1131         * doc/posix-functions/getpayload.texi: Mention the new module and the
1132         glibc bug.
1134 2024-04-16  Sam James  <sam@gentoo.org>
1136         wchar: Fix serial number.
1137         * m4/wchar_h.m4: Remove duplicate serial number specification and
1138         increment serial.
1140 2024-04-16  Collin Funk  <collin.funk1@gmail.com>
1142         gnulib-tool.py: Make GLModule's __eq__ and __hash__ method agree.
1143         * pygnulib/GLModuleSystem.py (GLModuleTable.__hash__): Only use the
1144         module name in hash computations.
1146 2024-04-16  Bruno Haible  <bruno@clisp.org>
1148         setpayloadsigl: Add tests.
1149         * tests/test-setpayloadsigl.c: New file, based on
1150         tests/test-setpayloadl.c.
1151         * modules/setpayloadsigl-tests: New file.
1153         setpayloadsigl: New module.
1154         * lib/math.in.h (setpayloadsigl): New declaration.
1155         * lib/setpayloadsigl.c: New file, based on lib/setpayloadl.c.
1156         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadsigl is declared.
1157         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADSIGL.
1158         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADSIGL.
1159         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADSIGL,
1160         HAVE_SETPAYLOADSIGL.
1161         * modules/setpayloadsigl: New file.
1162         * doc/posix-functions/setpayloadsigl.texi: Mention the new module.
1164 2024-04-16  Bruno Haible  <bruno@clisp.org>
1166         setpayloadsigf: Add tests.
1167         * tests/test-setpayloadf.c (PAYLOAD_BITS): New macro.
1168         (main): Use it.
1169         * tests/test-setpayloadsigf.c: New file, based on
1170         tests/test-setpayloadf.c.
1171         * modules/setpayloadsigf-tests: New file.
1173         setpayloadsigf: New module.
1174         * lib/math.in.h (setpayloadsigf): New declaration.
1175         * lib/setpayloadsigf.c: New file, based on lib/setpayloadf.c.
1176         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadsigf is declared.
1177         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADSIGF.
1178         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADSIGF.
1179         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADSIGF,
1180         HAVE_SETPAYLOADSIGF.
1181         * modules/setpayloadsigf: New file.
1182         * doc/posix-functions/setpayloadsigf.texi: Mention the new module.
1184 2024-04-16  Bruno Haible  <bruno@clisp.org>
1186         setpayloadsig: Add tests.
1187         * tests/test-setpayload.c (PAYLOAD_BITS): New macro.
1188         (main): Use it.
1189         * tests/test-setpayloadsig.c: New file, based on
1190         tests/test-setpayload.c.
1191         * modules/setpayloadsig-tests: New file.
1193         setpayloadsig: New module.
1194         * lib/math.in.h (setpayloadsig): New declaration.
1195         * lib/setpayloadsig.c: New file, based on lib/setpayload.c.
1196         * m4/setpayloadsig.m4: New file, based on m4/setpayload.m4.
1197         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadsig is declared.
1198         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADSIG.
1199         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADSIG.
1200         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADSIG,
1201         HAVE_SETPAYLOADSIG.
1202         * modules/setpayloadsig: New file.
1203         * doc/posix-functions/setpayloadsig.texi: Mention the new module.
1205 2024-04-16  Bruno Haible  <bruno@clisp.org>
1207         setpayloadl: Fix platform-specific bugs.
1208         * lib/setpayloadl.c (setpayloadl): On m68k, consider the actual memory
1209         layout of a 'long double'. On platforms with quadruple-precision
1210         'long double', store 111 bits of payload, not only 110 bits.
1212 2024-04-16  Collin Funk  <collin.funk1@gmail.com>
1214         gnulib-tool.py: Prefer 'not in' over 'not ... in'.
1215         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Change conditional.
1216         * pygnulib/GLModuleSystem.py (GLModuleTable.addConditional): Likewise.
1218 2024-04-16  Collin Funk  <collin.funk1@gmail.com>
1220         gnulib-tool.py: Make data structures more clear.
1221         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Use a set to
1222         represent the unconditional modules instead of a dictionary. Remove
1223         redundant comments.
1224         (GLModuleTable.addUnconditional): Add the module to a set instead of
1225         using it as a key to the dictionary.
1227 2024-04-16  Bruno Haible  <bruno@clisp.org>
1229         setpayloadl: Add tests.
1230         * tests/test-setpayloadl.c: New file.
1231         * modules/setpayloadl-tests: New file.
1233         setpayloadl: New module.
1234         * lib/math.in.h (setpayloadl): New declaration.
1235         * lib/setpayloadl.c: New file.
1236         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadl is declared.
1237         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADL.
1238         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADL.
1239         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADL,
1240         HAVE_SETPAYLOADL.
1241         * modules/setpayloadl: New file.
1242         * doc/posix-functions/setpayloadl.texi: Mention the new module.
1244 2024-04-16  Bruno Haible  <bruno@clisp.org>
1246         setpayloadf: Add tests.
1247         * tests/test-setpayloadf.c: New file.
1248         * modules/setpayloadf-tests: New file.
1250         setpayloadf: New module.
1251         * lib/math.in.h (setpayloadf): New declaration.
1252         * lib/setpayloadf.c: New file.
1253         * m4/math_h.m4 (gl_MATH_H): Test whether setpayloadf is declared.
1254         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOADF.
1255         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOADF.
1256         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOADF,
1257         HAVE_SETPAYLOADF.
1258         * modules/setpayloadf: New file.
1259         * doc/posix-functions/setpayloadf.texi: Mention the new module.
1261 2024-04-16  Bruno Haible  <bruno@clisp.org>
1263         setpayload: Add tests.
1264         * tests/test-setpayload.c: New file.
1265         * modules/setpayload-tests: New file.
1267         setpayload: New module.
1268         * lib/math.in.h (setpayload): New declaration.
1269         * lib/setpayload.c: New file.
1270         * m4/setpayload.m4: New file.
1271         * m4/math_h.m4 (gl_MATH_H): Test whether setpayload is declared.
1272         (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_SETPAYLOAD.
1273         (gl_MATH_H_DEFAULTS): Initialize HAVE_SETPAYLOAD.
1274         * modules/math (Makefile.am): Substitute GNULIB_SETPAYLOAD,
1275         HAVE_SETPAYLOAD.
1276         * modules/setpayload: New file.
1277         * doc/posix-functions/setpayload.texi: Mention the new module.
1279 2024-04-15  Collin Funk  <collin.funk1@gmail.com>
1281         gnulib-tool.py: Optimize directory creation.
1282         * pygnulib/GLTestDir.py (GLTestDir.execute): Use a list of possible
1283         subdirectories and create them upfront instead of checking every file.
1285 2024-04-15  Simon Josefsson  <simon@josefsson.org>
1287         gitlog-to-changelog: Revert 2024-04-12 fix and add documentation.
1288         * build-aux/gitlog-to-changelog: Use localtime.
1289         * doc/gitlog-to-changelog.texi: Add.
1290         * doc/gnulib.texi (Build Infrastructure Modules): Add.
1292 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
1294         gnulib-tool.py: Fix incorrect type hint.
1295         * pygnulib/constants.py (filter_filelist): Correct the type hint on the
1296         'filelist' argument. It is a list of strings, not a string.
1298 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
1300         gnulib-tool.py: Write newlines consistently.
1301         * pygnulib/constants.py (NL): Remove variable.
1302         * pygnulib/GLImport.py (GLImport.gnulib_comp): Use '\n' instead of
1303         constants.NL.
1304         * pygnulib/GLModuleSystem.py
1305         (GLModule.getAutomakeSnippet_Unconditional): Likewise.
1306         * pygnulib/main.py (main_with_exception_handling): Likewise.
1308 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
1310         gnulib-tool.py: Don't perform newline conversions.
1311         * pygnulib/constants.py (nlconvert): Remove function. Remove unused
1312         platform import.
1313         * pygnulib/GLImport.py (GLImport.gnulib_cache): Remove calls to
1314         nlconvert().
1315         * pygnulib/GLModuleSystem.py
1316         (GLModule.getAutomakeSnippet_Unconditional): Likewise.
1317         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
1318         Likewise.
1320 2024-04-14  Bruno Haible  <bruno@clisp.org>
1322         users.txt: Update some more entries.
1323         * users.txt: Remove cvsps, gpg, gtkreindeer, libvirt, mailfromd, msmtp,
1324         OPeNDAP. Update some existing entries.
1326 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
1328         gnulib-tool.py: Remove some unused variable assignments.
1329         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Remove unused
1330         variable.
1331         * pygnulib/GLInfo.py (GLInfo.date, GLInfo.version): Remove assignments
1332         to variables unconditionally set in try, except blocks.
1333         * pygnulib/GLModuleSystem.py (GLModule.getConditionalName)
1334         (GLModule.getShellFunc, GLModule.getShellVar): Likewise.
1336 2024-04-14  Collin Funk  <collin.funk1@gmail.com>
1338         gnulib-tool.py: Don't use mutable default arguments.
1339         * pygnulib/GLFileSystem.py (GLFileAssistant.__init__): Set the default
1340         argument for 'transformers' to None. If it is None then set it to an
1341         empty dictionary in the body.
1343 2024-04-13  Bruno Haible  <bruno@clisp.org>
1345         bootstrap: Implement phase 1 as documented in the --help output.
1346         Reported by Simon Josefsson as bug #1 in
1347         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00152.html>.
1348         * top/bootstrap: Correct indentation.
1349         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): Implement as
1350         documented:
1351         If GNULIB_SRCDIR and GNULIB_REVISION are set and there is a 'gnulib'
1352         submodule, checkout the revision GNULIB_REVISION.
1353         If GNULIB_SRCDIR and GNULIB_REVISION are set and --no-git is specified,
1354         don't checkout the revision GNULIB_REVISION.
1356 2024-04-13  Bruno Haible  <bruno@clisp.org>
1358         bootstrap: Simplify git submodule initialization.
1359         * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): Err out if git is
1360         older than version 1.6.4. Remove fallback code for older versions.
1361         * build-aux/bootstrap: Regenerated.
1363 2024-04-13  Collin Funk  <collin.funk1@gmail.com>
1365         Improve 'git diff' of Python files.
1366         * .gitattributes: Add a rule for *.py files.
1368 2024-04-13  Collin Funk  <collin.funk1@gmail.com>
1370         gnulib-tool.py: Fix extra arguments to function call.
1371         * pygnulib/GLImport.py (GLImport.execute): Add the missing joinpath call
1372         on two file name components before calling isfile().
1374 2024-04-13  Bruno Haible  <bruno@clisp.org>
1376         bootstrap: Fix --help messages.
1377         Reported by Simon Josefsson in
1378         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00162.html>.
1379         * top/bootstrap (usage): Fix the description of GNULIB_SRCDIR. Document
1380         GNULIB_REFDIR. Use full-sentences style. Tweak wording.
1381         * top/bootstrap-funclib.sh (autopull_usage): Clarify the phase. Don't
1382         mention nonexistent options --gnulib-srcdir and --gnulib-refdir. Use
1383         full-sentences style.
1384         (autogen_usage): Clarify the phase. Use full-sentences style.
1385         * build-aux/bootstrap: Regenerated.
1387 2024-04-13  Bruno Haible  <bruno@clisp.org>
1389         gnulib-tool.py: Code tweak.
1390         * pygnulib/main.py (main): Move file contents analysis out of a 'with'
1391         statement.
1393 2024-04-13  Bruno Haible  <bruno@clisp.org>
1395         gnulib-tool.py: Stop using codecs.open.
1396         * pygnulib/*.py: To open a file, consistently use
1397         open(..., mode='[rwa]', newline='\n', encoding='utf-8').
1399 2024-04-13  Bruno Haible  <bruno@clisp.org>
1401         gnulib-tool.py: Refactor directory tree removals.
1402         * pygnulib/constants.py (rmtree): New function.
1403         * pygnulib/GLImport.py (GLImport.execute): Use it instead of calling
1404         'rm -rf' directly or shutil.rmtree.
1405         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
1406         Likewise.
1407         * pygnulib/main.py (main): Likewise.
1409 2024-04-12  Collin Funk  <collin.funk1@gmail.com>
1411         gnulib-tool.py: Fix --copy-file directory creation.
1412         Reported by Bruno Haible in
1413         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00140.html>
1414         * pygnulib/main.py (main): Make sure that destdir is set in the GLConfig
1415         object before copying files.
1417 2024-04-12  Bruno Haible  <bruno@clisp.org>
1419         gnulib-tool.py: Implement --add-import --with-*-tests correctly.
1420         * pygnulib/GLConfig.py (GLConfig.update): Use list-merging for the test
1421         categories.
1422         * pygnulib/GLImport.py (GLImport.__init__): Don't merge back those
1423         values which were already considered by taking the union.
1425 2024-04-12  Bruno Haible  <bruno@clisp.org>
1427         gnulib-tool.py: Implement --add-import --avoid correctly.
1428         * pygnulib/GLConfig.py (GLConfig.update): Don't test for the unused key
1429         'tests'.
1430         (GLConfig.default): Likewise.
1431         * pygnulib/GLImport.py (GLImport.__init__): Don't merge back those
1432         values which were already considered by taking the union.
1434 2024-04-12  Bruno Haible  <bruno@clisp.org>
1436         gnulib-tool.py: Refactor.
1437         * pygnulib/GLConfig.py (GLConfig.update, GLConfig.update_key): Improve
1438         variable names and comments.
1439         * pygnulib/GLImport.py (GLImport.__init__): Improve comments.
1441 2024-04-12  Bruno Haible  <bruno@clisp.org>
1443         gnulib-tool.py: Optimize.
1444         * pygnulib/GLConfig.py (GLConfig.update, GLConfig.update_key): Avoid
1445         useless cloning of dictionaries.
1447 2024-04-12  Bruno Haible  <bruno@clisp.org>
1449         gnulib-tool.py: Implement --no-conditional-dependencies correctly.
1450         * pygnulib/GLConfig.py (GLConfig.default): For 'conddeps', return None,
1451         not False.
1452         (GLConfig.checkCondDeps): Update result type.
1453         (resetCondDeps): Reset to return None, not False.
1454         * pygnulib/GLImport.py (GLImport.actioncmd): Update.
1456 2024-04-12  Bruno Haible  <bruno@clisp.org>
1458         gnulib-tool.py: Implement --no-libtool option correctly.
1459         * pygnulib/GLConfig.py (GLConfig.default): For 'libtool', return None,
1460         not False.
1461         (GLConfig.checkLibtool): Update result type.
1462         (resetLibtool): Reset to return None, not False.
1463         * pygnulib/GLImport.py (GLImport.actioncmd): Update.
1465 2024-04-12  Bruno Haible  <bruno@clisp.org>
1467         gnulib-tool.py: Accept conditional dependencies with tests.
1468         * pygnulib/GLImport.py (GLImport.__init__): Don't reject the combination
1469         of gl_CONDITIONAL_DEPENDENCIES and gl_WITH_TESTS.
1470         * pygnulib/GLError.py (GLError.__repr__): Remove error 10.
1471         * pygnulib/main.py (main_with_exception_handling): Likewise.
1473 2024-04-12  Bruno Haible  <bruno@clisp.org>
1475         gnulib-tool.py: Fix handling of --with-obsolete.
1476         * pygnulib/constants.py (TESTS): Remove 'obsolete' category.
1477         * pygnulib/GLConfig.py (GLConfig.__init__): Add optional incobsolete
1478         parameter.
1479         (GLConfig.default): Handle 'incobsolete'.
1480         (GLConfig.checkIncObsolete, GLConfig.setIncObsolete,
1481         GLConfig.resetIncObsolete): New methods.
1482         * pygnulib/GLModuleSystem.py (GLModuleSystem.transitive_closure): For
1483         incobsolete, use new GLConfig methods.
1484         * pygnulib/GLImport.py (GLImport.__init__, GLImport.actioncmd,
1485         GLImport.gnulib_cache): Likewise.
1486         * pygnulib/main.py (main): Pass the incobsolete value to the GLConfig
1487         constructor.
1489 2024-04-12  Simon Josefsson  <simon@josefsson.org>
1491         gitlog-to-changelog: Make output reproducible.
1492         * build-aux/gitlog-to-changelog: Use gmtime instead of localtime.
1494 2024-04-12  Bruno Haible  <bruno@clisp.org>
1496         gnulib-tool.py: Fix parsing of gl_LGPL in gnulib-cache.m4.
1497         * pygnulib/GLImport.py (GLImport.__init__): Search for gl_LGPL in
1498         gnulib-cache.m4 more carefully.
1500         gnulib-tool.py: Fix parsing of gnulib-cache.m4.
1501         * pygnulib/GLImport.py (GLImport.__init__): While parsing
1502         gnulib-cache.m4, stop parsing the identifier starting with 'gl_' when
1503         encountering a character that is not a uppercase letter, digit, or
1504         underscore.
1506 2024-04-12  Bruno Haible  <bruno@clisp.org>
1508         gnulib-tool.py: Fix misspelled option in output.
1509         * pygnulib/GLImport.py (GLImport.actioncmd): Fix typo.
1511 2024-04-12  Bruno Haible  <bruno@clisp.org>
1513         gnulib-tool.py: Persist the --with-longrunning-tests option.
1514         * pygnulib/GLImport.py (GLImport.gnulib_cache): Conditionally add
1515         gl_WITH_LONGRUNNING_TESTS to gnulib-cache.m4.
1517 2024-04-12  Bruno Haible  <bruno@clisp.org>
1519         gnulib-tool.py: Print warnings just like gnulib-tool.sh.
1520         * pygnulib/main.py (main): When printing a warning, print just
1521         "gnulib-tool" instead of the absolute file name.
1523 2024-04-12  Bruno Haible  <bruno@clisp.org>
1525         gnulib-tool.sh: Accept conditional dependencies with tests.
1526         * gnulib-tool.sh (func_import): Don't reject the combination of
1527         gl_CONDITIONAL_DEPENDENCIES and gl_WITH_TESTS.
1529 2024-04-11  Bruno Haible  <bruno@clisp.org>
1531         gnulib-tool.py: Optimize module set lookups.
1532         * gnulib-tool.py (profiler_args): New variable.
1533         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Turn
1534         handledmodules into a set.
1535         (GLModuleTable.transitive_closure_separately): For the 'in' test, use
1536         a set variable main_modules_set.
1538 2024-04-11  Collin Funk  <collin.funk1@gmail.com>
1540         gnulib-tool.py: Remove redundant backslashes from regexps.
1541         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't backslash ']' when it
1542         is outside of a set.
1543         * pygnulib/GLImport.py (GLImport.__init__): Don't use a backslash when
1544         ']' is at the start of a '[...]' set. Don't backslash special characters
1545         in a '[...]' set since they have their meaning dropped.
1546         * pygnulib/main.py (main): Likewise.
1548 2024-04-11  Collin Funk  <collin.funk1@gmail.com>
1550         gnulib-tool.py: Simplify regular expressions.
1551         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
1552         (GLEmiter.tests_Makefile_am): Change occurrences of '[A-Z][A-Z]*' to
1553         '[A-Z]+'.
1555 2024-04-11  Bruno Haible  <bruno@clisp.org>
1557         users.txt: Correct some entries.
1558         * users.txt: Update some existing entries.
1560 2024-04-11  Bruno Haible  <bruno@clisp.org>
1562         gnulib-tool.sh: Improve sort order of directories.
1563         * gnulib-tool.sh (func_import): In file fileset-changes, store directory
1564         names without a trailing slash.
1566 2024-04-11  Bruno Haible  <bruno@clisp.org>
1568         gnulib-tool.sh: Remove './' prefix from file names to update or remove.
1569         * gnulib-tool.sh (func_import): Don't let rewritten file names start
1570         with './'.
1572 2024-04-11  Collin Funk  <collin.funk1@gmail.com>
1574         gnulib-tool.py: Fix sorting of the LINGUAS file.
1575         * pygnulib/GLImport.py (GLImport.execute): Sort the list of locales
1576         before writing them into the LINGUAS file.
1578 2024-04-10  Bruno Haible  <bruno@clisp.org>
1580         gnulib-tool.sh: Handle .gitignore files that do not end in a newline.
1581         * gnulib-tool.sh (func_import): If the .gitignore file ends with a
1582         character other than a newline, add a newline before adding more lines.
1584 2024-04-10  Bruno Haible  <bruno@clisp.org>
1586         gnulib-tool.py: Skip nonexistent modules instead of failing.
1587         * pygnulib/GLModuleSystem.py (GLModuleSystem.find): Use the same warning
1588         wording as gnulib-tool.sh.
1589         * pygnulib/GLImport.py (GLImport.gnulib_cache): Print the specified
1590         modules, not the base modules.
1591         (GLImport.prepare): Don't put None elements into base_modules.
1593 2024-04-10  Collin Funk  <collin.funk1@gmail.com>
1595         gnulib-tool.py: Use function arguments instead of magic numbers.
1596         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Remove the
1597         'verifier' integer flag argument. Add the 'module_filter' function
1598         argument. Use it to determine if Autoconf snippets should be printed for
1599         each module.
1600         * pygnulib/GLImport.py (GLImport.gnulib_comp): Update call to use a
1601         lambda function.
1602         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
1604 2024-04-10  Collin Funk  <collin.funk1@gmail.com>
1606         gnulib-tool: Fix a typo.
1607         * gnulib-tool.sh: Fix a typo in comment.
1608         * pygnulib/main.py (main): Likewise.
1610 2024-04-09  Collin Funk  <collin.funk1@gmail.com>
1612         gnulib-tool.py: Change the avoid list to a set for lookups.
1613         * pygnulib/GLModuleSystem.py (GLModuleSystem.__init__): Store the
1614         avoided modules in a set instead of a list. This is used only for
1615         membership checks when computing the transitive closure of the given
1616         modules, therefore prefer the O(1) average case over O(n).
1618 2024-04-09  Collin Funk  <collin.funk1@gmail.com>
1620         gnulib-tool.py: Remove unused setter and getter functions.
1621         * pygnulib/GLModuleSystem.py (GLModuleTable.getAvoids)
1622         (GLModuleTable.setAvoids): Remove these unused functions.
1624 2024-04-09  Bruno Haible  <bruno@clisp.org>
1626         totalorder, totalorderf: Avoid miscompilation by gcc on NetBSD/i386.
1627         * lib/totalorder.c (totalorder): Use the a compiler optimization barrier
1628         also for GCC.
1629         * lib/totalorderf.c (totalorderf): Likewise.
1631 2024-04-09  Collin Funk  <collin.funk1@gmail.com>
1633         gnulib-tool.py: Simplify use of GLModuleTable accessors.
1634         * pygnulib/GLModuleSystem.py (GLModuleTable.__getitem__): Remove
1635         function.
1636         * pygnulib/GLImport.py (GLImport.gnulib_cache, GLImport.gnulib_comp)
1637         (GLImport.execute): Use function calls on the GLModuleTable to access
1638         module lists instead of using keys to emulate a dictionary.
1640 2024-04-09  Bruno Haible  <bruno@clisp.org>
1642         totalorder, totalorderf: Avoid miscompilation by clang on OpenBSD/i386.
1643         * lib/totalorder.c (totalorder): Insert a compiler optimization barrier.
1644         * lib/totalorderf.c (totalorderf): Likewise.
1646 2024-04-09  Bruno Haible  <bruno@clisp.org>
1648         totalorder, totalorderf: Fix handling of SNaN on i386 and x86_64 CPUs.
1649         * lib/totalorder.c: Include <string.h>.
1650         (totalorder): Use memcpy to copy the 'double' values into the union.
1651         Drop 'volatile'.
1652         * lib/totalorderf.c: Include <string.h>.
1653         (totalorderf): Use memcpy to copy the 'float' values into the union.
1654         Drop 'volatile'.
1656 2024-04-09  Bruno Haible  <bruno@clisp.org>
1658         totalorder tests: Fix signature test.
1659         * tests/test-totalorder.c: Test the signature of totalorder, not
1660         totalorderf.
1662 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
1664         gnulib-tool.py: Use single-quotes for strings, part 2.
1665         * pygnulib/GLEmiter.py (GLEmiter.po_Makevars): Change a double-quoted
1666         string to single-quotes missed by the previous commit.
1668 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
1670         gnulib-tool.py: Use single-quotes for strings.
1671         * pygnulib/*.py: Change double-quoted strings to use single-quotes
1672         unless doing so would require adding backslashes.
1674 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
1676         gnulib-tool.py: Prefer 'list.append(item)' over 'list += [item]'.
1677         * pygnulib/*.py: Change occurrences '+= [item]' to use '.append(item)'
1678         where item is a single element added to the list.
1679         See discussion here:
1680         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00091.html>
1682 2024-04-08  Bruno Haible  <bruno@clisp.org>
1684         ptsname_r: Work around ptsname_r bug on NetBSD 10.0.
1685         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): On NetBSD, arrange to override
1686         ptsname_r.
1687         * lib/ptsname_r.c (ptsname_r): Add workaround for NetBSD bug.
1688         * doc/glibc-functions/ptsname_r.texi: Mention the NetBSD bug.
1690 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
1692         gnulib-tool.py: Fix incomplete type hint.
1693         * pygnulib/GLModuleSystem.py (GLModuleTable.getCondition): Add None to
1694         the return type hint. This is the return value when the module is not a
1695         conditional dependency.
1697 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
1699         gnulib-tool.py: Remove unnecessary conditional.
1700         * pygnulib/GLModuleSystem.py (GLModuleTable.__getitem__): Don't check if
1701         the key is valid twice.
1703 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
1705         gnulib-tool.py: Remove an unused and incorrect function.
1706         * pygnulib/GLFileSystem.py (GLFileAssistant.removeFile): Remove this
1707         unused function. The correct method of removing an element from a list
1708         is to use the remove() function, not pop() which takes an index.
1710 2024-04-08  Collin Funk  <collin.funk1@gmail.com>
1712         gnulib-tool.py: Omit some unnecessary list() calls around sorted().
1713         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Remove the list()
1714         call in the argument to sorted. The sorted() function works on any
1715         iterable and always returns a list.
1716         * pygnulib/GLImport.py (GLImport.rewrite_old_files)
1717         (GLImport.rewrite_new_files): Likewise.
1718         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure)
1719         (GLModuleTable.transitive_closure_separately): Likewise.
1720         * pygnulib/GLTestDir.py (GLTestDir.rewrite_files): Likewise.
1722 2024-04-08  Bruno Haible  <bruno@clisp.org>
1724         pthread-h: Fix configuration (regression 2024-03-28).
1725         Reported by Collin Funk in
1726         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00036.html>.
1727         * m4/pthread_h.m4 (gl_PTHREAD_H_PART1): New macro, extracted from
1728         gl_PTHREAD_H.
1729         (gl_PTHREAD_H): Require it. Define using AC_DEFUN.
1730         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Require gl_PTHREAD_H_PART1,
1731         not only gl_PTHREAD_H_DEFAULTS.
1733 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
1735         gnulib-tool.py: Don't remove duplicate avoided modules.
1736         * pygnulib/GLConfig.py (GLConfig.addAvoid): Don't remove duplicates from
1737         the modules passed with --avoid.
1739 2024-04-07  Bruno Haible  <bruno@clisp.org>
1741         sigsegv tests: Avoid a crash on NetBSD 10.0/i386.
1742         * tests/test-sigsegv-catch-stackoverflow1.c
1743         (stackoverflow_handler_continuation): On NetBSD/i386, align the stack
1744         pointer before calling longjmp.
1746 2024-04-07  Bruno Haible  <bruno@clisp.org>
1748         gnulib-tool.py: Add comment.
1749         * pygnulib/constants.py (joinpath): Document a limitation.
1751 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
1753         gnulib-tool.py: Don't allow path normalization to delete a variable.
1754         * pygnulib/GLModuleSystem.py
1755         (GLModule.getAutomakeSnippet_Unconditional): Use os.path.join() on the
1756         Makefile variable so it isn't deleted by a following '..' from
1757         os.path.norm().
1759 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
1761         gnulib-tool.py: Use auxdir as given by AC_CONFIG_AUX_DIR.
1762         * pygnulib/GLImport.py (GLImport.__init__): Don't modify the path given
1763         by AC_CONFIG_AUX_DIR by prefixing it with destdir. Use a more strict
1764         regular expression instead of cleaner().
1766 2024-04-07  Collin Funk  <collin.funk1@gmail.com>
1768         gnulib-tool.py: Locate configure.ac correctly when --dir is given.
1769         * pygnulib/GLConfig.py (GLConfig.setAutoconfFile): Don't combine the
1770         given file name argument with destdir.
1771         * pygnulib/main.py (main): Use os.path.join() instead of joinpath() when
1772         constructing the path to the configure.ac file. The latter normalizes
1773         paths which causes the test suite to fail when printed in files.
1775 2024-04-06  Bruno Haible  <bruno@clisp.org>
1777         expm1l: Work around a NetBSD 10.0/i386 bug.
1778         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Test the value of
1779         expm1l(2^LDBL_MIN_EXP).
1780         * doc/posix-functions/expm1l.texi: Mention the NetBSD 10.0/i386 bug.
1781         * tests/test-expm1.h (test_function): Allow more deviation on
1782         NetBSD/i386.
1784 2024-04-05  Bruno Haible  <bruno@clisp.org>
1786         exp2l: Work around a NetBSD 10.0/i386 bug.
1787         * m4/exp2l.m4 (gl_FUNC_EXP2L): Test the value of exp2l(LDBL_MAX_EXP-1).
1788         * doc/posix-functions/exp2l.texi: Mention the NetBSD 10.0/i386 bug.
1790 2024-04-05  Bruno Haible  <bruno@clisp.org>
1792         roundl: Fix a link error on Linux/powerpc64le.
1793         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Accept an additional TYPE
1794         argument.
1795         * m4/isfinite.m4 (gl_ISFINITE): Use the type 'double'.
1796         * m4/isinf.m4 (gl_ISINF): Likewise.
1797         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
1798         * m4/roundf.m4 (gl_FUNC_ROUNDF): Use the type 'float'.
1799         * m4/roundl.m4 (gl_FUNC_ROUNDL): Use the type 'long double'.
1801 2024-04-05  Bruno Haible  <bruno@clisp.org>
1803         exp2l tests: Enable a test for glibc versions >= 2.16.
1804         * tests/test-exp2.h (test_function): Disable a glibc bug workaround for
1805         glibc versions >= 2.16.
1807 2024-04-05  Bruno Haible  <bruno@clisp.org>
1809         expl tests: Avoid test failure on NetBSD 10.0/i386.
1810         * tests/test-exp.h (test_function): Allow more deviation on NetBSD/i386.
1812 2024-04-05  Collin Funk  <collin.funk1@gmail.com>
1814         gnulib-tool.py: Use 'Any' instead of type unions in GLConfig.
1815         * pygnulib/GLConfig.py (GLConfig.__getitem__, GLConfig.dictionary)
1816         (GLConfig.default, GLConfig.isdefault, GLConfig.values): Use 'Any' from
1817         the typing module instead of large type unions. This silences unhelpful
1818         warnings from type checkers.
1820 2024-04-05  Collin Funk  <collin.funk1@gmail.com>
1822         gnulib-tool.py: Fix 'consider-using-set-comprehension' warnings.
1823         * pygnulib/GLImport.py (GLImport.prepare): Create a set directly instead
1824         of creating a list and passing it to a call of set().
1825         (GLImport.__init__): Likewise. Use max() instead of getting the last
1826         element of a sorted list.
1828 2024-04-05  Collin Funk  <collin.funk1@gmail.com>
1830         gnulib-tool.py: Fix 'consider-using-with' pylint warnings.
1831         * pygnulib/GLModuleSystem.py (GLModuleSystem.list): Use run() instead of
1832         Popen() from the subprocess module. This function handles cleanup
1833         internally instead of as a context manager via the 'with' statement.
1835 2024-04-05  Bruno Haible  <bruno@clisp.org>
1837         Update for NetBSD 9.3 and 10.0.
1838         * doc/*/*.texi: Update for NetBSD 9.3 and 10.0.
1839         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Update comments and cross-compilation
1840         guess.
1841         * m4/log1pl.m4 (gl_FUNC_LOG1PL_WORKS): Likewise.
1842         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Likewise.
1843         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LA): Likewise.
1844         * m4/remainderl.m4 (gl_FUNC_REMAINDERL_WORKS): Likewise.
1845         * m4/fcntl.m4: Update comments.
1846         * m4/fenv-environment.m4: Likewise.
1847         * m4/fenv-exceptions-trapping.m4: Likewise.
1848         * m4/fnmatch.m4: Likewise.
1849         * m4/getcwd-abort-bug.m4: Likewise.
1850         * m4/iswdigit.m4: Likewise.
1851         * m4/iswxdigit.m4: Likewise.
1852         * m4/modfl.m4: Likewise.
1853         * m4/wcscmp.m4: Likewise.
1854         * m4/wcsncmp.m4: Likewise.
1855         * m4/wctrans.m4: Likewise.
1856         * m4/wcwidth.m4: Likewise.
1858 2024-04-04  Collin Funk  <collin.funk1@gmail.com>
1860         posix-modules, all-modules: Fix --version output using git options.
1861         * all-modules (func_version): Pass --format and --date options to git
1862         so the output does not depend on the user's configuration. Pass
1863         '-n 1' to speed up the operation, since we only need the first entry.
1864         * posix-modules (func_version): Likewise.
1866 2024-04-04  Bruno Haible  <bruno@clisp.org>
1868         all-modules: Fix errors during './all-modules --version' execution.
1869         Reported by Collin Funk in
1870         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00050.html>.
1871         * all-modules (func_exit, func_fatal_error, func_readlink,
1872         func_gnulib_dir): Include auxiliary functions from gnulib-tool.sh.
1874 2024-04-04  Bruno Haible  <bruno@clisp.org>
1876         posix-modules: Sync auxiliary functions from gnulib-tool.sh.
1877         * posix-modules (func_exit, func_fatal_error, func_readlink,
1878         func_gnulib_dir): Move before func_usage and func_version. Incorporate
1879         improvements from gnulib-tool.sh.
1881 2024-04-04  Collin Funk  <collin.funk1@gmail.com>
1883         gnulib-tool.py: Ignore 'use-dict-literal' warnings.
1884         * pygnulib/.pylintrc: Don't emit warning messages suggesting that
1885         'dict()' be converted to '{}'. This literal can be mistaken for sets,
1886         see discussion here:
1887         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00054.html>
1888         * pygnulib/main.py: Document this convention in coding style section.
1889         * pygnulib/GLFileSystem.py (GLFileAssistant.__init__): Convert an
1890         occurrence of '{}' to 'dict()'.
1892 2024-04-04  Collin Funk  <collin.funk1@gmail.com>
1894         gnulib-tool.py: Fix pylint 'raise-missing-from' warnings.
1895         * pygnulib/*.py: Use explicit exception chaining so that stack trace
1896         messages do not seem like bugs. See examples in:
1897         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00056.html>
1899 2024-04-04  Bruno Haible  <bruno@clisp.org>
1901         Add serial numbers to *.m4 files that did not have them.
1902         * m4/*.m4: Ensure the usual file header with file name and serial
1903         number.
1905         Make the file header of *.m4 files consistent:
1906         1. The file name.
1907         2. The serial number.
1908         3. The copyright and license header.
1909         * m4/*.m4: Adjust file headers.
1911         Make the serial numbers in *.m4 files effective.
1912         Reported by Sam James in
1913         <https://lists.gnu.org/archive/html/bug-gnulib/2024-04/msg00051.html>.
1914         * m4/*.m4: Apply sed -e '1s|^# \(.*[.]m4\) serial |# \1\n# serial |'.
1916 2024-04-03  Bruno Haible  <bruno@clisp.org>
1918         gnulib-tool.sh: Reduce code duplication in last commit.
1919         * gnulib-tool.sh (func_get_automake_snippet_unconditional): Refactor
1920         computation of sed_prepend_auxdir.
1922 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
1924         gnulib-tool.sh: Don't emit an unnecessary './' path component.
1925         * gnulib-tool.sh (func_get_automake_snippet_unconditional): Only prefix
1926         build-aux files with '$(top_srcdir)/' when $auxdir is the top level
1927         directory.
1929 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
1931         gnulib-tool.py: Modernize class declarations to Python 3.
1932         * pygnulib/GLConfig.py: Remove the explicit object inheritance from
1933         class declarations. This is previously required in Python 2.
1934         * pygnulib/GLEmiter.py: Likewise.
1935         * pygnulib/GLFileSystem.py: Likewise.
1936         * pygnulib/GLImport.py: Likewise.
1937         * pygnulib/GLInfo.py: Likewise.
1938         * pygnulib/GLMakefileTable.py: Likewise.
1939         * pygnulib/GLModuleSystem.py: Likewise.
1940         * pygnulib/GLTestDir.py: Likewise.
1942 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
1944         gnulib-tool.py: Ignore pylint 'unidiomatic-typecheck' warnings.
1945         * pygnulib/.pylintrc: Disable warning C0123 since we don't mind using
1946         'type() is' instead of 'isinstance'.
1948 2024-04-03  Collin Funk  <collin.funk1@gmail.com>
1950         gnulib-tool.py: Don't ignore the argument to --doc-base.
1951         * pygnulib/main.py (main): Check for the argument to --doc-base before
1952         creating the GLConfig object.
1954 2024-04-03  Pádraig Brady  <P@draigBrady.com>
1956         quotearg: fix shell-escape quoting with single quotes
1957         With shell-escape quoting, we misquoted strings
1958         where the first and last characters required escaping,
1959         while the string also contained single quotes.
1961         * lib/quotearg.c (quotearg_buffer_restyled): Ensure that
1962         pending_shell_escape_end is reset to the initial state
1963         when reprocessing input due to single quotes.
1964         * tests/test-quotearg-simple.c: Add a minimal test case.
1965         * tests/test-quotearg.c: Likewise.
1966         * tests/test-quotearg.h: Likewise.
1967         Reported by Grisha Levit
1969 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
1971         gnulib-tool.py: Use [] instead of list() to initialize empty lists.
1972         * pygnulib/*.py: Change occurrences of list() to [].
1974 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
1976         gnulib-tool.py: Fix determination whether to add the dummy module.
1977         * pygnulib/GLModuleSystem.py (GLModuleSystem.add_dummy): Only match the
1978         'lib_SOURCES' variable; stop at end-of-line.
1980 2024-04-02  Pádraig Brady  <P@draigBrady.com>
1982         renameatu: handle ENOSYS from renameatx_np
1983         * lib/renameatu.c(): Fall back to renameat() without RENAME_EXCL
1984         if "Function not implemented" is returned.  This was seen with macFUSE.
1985         Reported at https://github.com/coreutils/coreutils/issues/79
1987 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
1989         gnulib-tool.py: Accept valid make syntax for escaped newlines.
1990         * pygnulib/GLModuleSystem.py (GLModuleTable.add_dummy): Use
1991         combine_lines instead of remove remove_backslash_newline so spaces are
1992         added between each combined line.
1993         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
1994         * pygnulib/constants.py (remove_backslash_newline): Remove unused
1995         function.
1997 2024-04-02  Collin Funk  <collin.funk1@gmail.com>
1999         gnulib-tool.py: Don't default to 'build-aux' for --auxdir.
2000         * pygnulib/GLConfig.py (GLConfig.__getitem__): Don't map '' to
2001         'build-aux' for the 'auxdir' key.
2002         * pygnulib/GLImport.py (GLImport.__init__): Change conditional to use an
2003         empty string instead of None since this is returned when --auxdir is not
2004         used.
2006 2024-04-02  Bruno Haible  <bruno@clisp.org>
2008         gnulib-tool: Remove unused variables.
2009         * pygnulib/GLConfig.py: Remove unused variables.
2010         * pygnulib/GLEmiter.py: Likewise.
2011         * pygnulib/GLFileSystem.py: Likewise.
2012         * pygnulib/GLImport.py: Likewise.
2013         * pygnulib/GLInfo.py: Likewise.
2014         * pygnulib/GLModuleSystem.py: Likewise.
2015         * pygnulib/GLTestDir.py: Likewise.
2016         * pygnulib/main.py: Likewise.
2017         * gnulib-tool.sh (func_emit_tests_Makefile_am): Remove unused variable
2018         perhapsLT.
2020         gnulib-tool.py: Remove no-op statements.
2021         * pygnulib/GLConfig.py (GLConfig.update): Remove no-op statement.
2023         gnulib-tool.py: Remove unused imports.
2024         * pygnulib/GLFileSystem.py: Remove unused imports.
2025         * pygnulib/GLEmiter.py: Likewise.
2026         (GLEmiter.autoconfSnippets): Fix type assertion message.
2028         gnulib-tool.py: Fix some IDE warnings.
2029         * HACKING: Update configuration of warnings.
2031 2024-04-01  Bruno Haible  <bruno@clisp.org>
2033         gnulib-tool.py: Add developer documentation.
2034         * HACKING: New section "Debugging the Python implementation of
2035         gnulib-tool".
2037 2024-04-01  Bruno Haible  <bruno@clisp.org>
2039         gnulib-tool.py: Use a standard Python program directory structure.
2040         * pygnulib/main.py (main_with_exception_handling): New function for
2041         existing code.
2042         * .gnulib-tool.py: New file.
2043         * pygnulib/constants.py: Update the computation of APP['root'].
2044         * gnulib-tool.py: Don't set PYTHONPATH.
2046 2024-04-01  Bruno Haible  <bruno@clisp.org>
2048         gnulib-tool.py: Simplify imports.
2049         * pygnulib/enums.py: New file, extracted from pygnulib/GLFileSystem.py.
2050         * pygnulib/classes.py: Remove file.
2051         * pygnulib/GLFileSystem.py: Remove class CopyAction. Update imports.
2052         * pygnulib/GLTestDir.py: Update imports.
2053         * pygnulib/GLConfig.py: Update imports and remove 'classes.' prefix.
2054         * pygnulib/main.py: Likewise.
2056 2024-04-01  Collin Funk  <collin.funk1@gmail.com>
2058         gnulib-tool.py: Only check existence for --extract-tests-module.
2059         * pygnulib/main.py (main): Check that the test module exists instead of
2060         looking it up and patching it if diff's are found.
2062 2024-04-01  Collin Funk  <collin.funk1@gmail.com>
2064         gnulib-tool.py: Fix --extract-tests-module with a test module.
2065         * pygnulib/GLModuleSystem.py (GLModule.getTestsName): Return the module
2066         name with '-tests' appended to it unconditionally.
2068 2024-04-01  Collin Funk  <collin.funk1@gmail.com>
2070         gnulib-tool.py: Use case-sensitive sorting for file names.
2071         * pygnulib/GLImport.py (GLImport.prepare): Remove the str.lower key from
2072         the call to sorted().
2074 2024-04-01  Paul Eggert  <eggert@cs.ucla.edu>
2076         getcwd: port better to buggy file systems
2077         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
2078         Time out after 5 seconds.
2080 2024-03-31  Collin Funk  <collin.funk1@gmail.com>
2082         gnulib-tool.py: Add missing quotation mark to reminder.
2083         * pygnulib/GLImport.py (GLImport.execute): Add missing end quote around
2084         file name in AC_CONFIG_FILES reminder.
2086 2024-03-31  Bruno Haible  <bruno@clisp.org>
2088         quotearg: Improve documentation.
2089         * lib/quotearg.h: Refer to specification of $'...' syntax. Document a
2090         limitation of QA_ELIDE_OUTER_QUOTES.
2092 2024-03-31  Bruno Haible  <bruno@clisp.org>
2094         canonicalize[-lgpl] tests: Fix test failure on musl libc.
2095         Reported by Adept's Lab <adeptslab@gmail.com> via Pádraig Brady at
2096         <https://lists.gnu.org/archive/html/bug-coreutils/2024-03/msg00086.html>.
2097         * tests/test-canonicalize-lgpl.c (main): Don't special-case "//"
2098         handling for musl libc.
2099         * tests/test-canonicalize.c (main): Likewise.
2100         * modules/canonicalize-lgpl-tests (Files): Remove m4/musl.m4.
2101         (configure.ac): Don't invoke gl_MUSL_LIBC.
2103 2024-03-31  Collin Funk  <collin.funk1@gmail.com>
2105         gnulib-tool.py: Fix output of 'po/LINGUAS'.
2106         * pygnulib/GLImport.py (GLImport.execute): Only use PO files when
2107         determining the output for po/LINGUAS.
2109 2024-03-31  Collin Funk  <collin.funk1@gmail.com>
2111         gnulib-tool.py: Fix sorting of modules when --local-dir is used.
2112         * pygnulib/GLModuleSystem.py (GLModule.__eq__, GLModule.__ne__)
2113         (GLModule.__ge__, GLModule.__gt__, GLModule.__hash__, GLModule.__le__)
2114         (GLModule.__lt__): Use module names as identifiers instead of paths.
2116 2024-03-31  Bruno Haible  <bruno@clisp.org>
2118         gnulib-tool.py: Make a module's name immediately accessible.
2119         * pygnulib/GLModuleSystem.py (GLModuleSystem.find): Pass the module name
2120         to the GLModule constructor.
2121         (GLModule.__init__): Accept the module's name as argument and store it.
2122         (GLModule.getName): Simplify.
2124 2024-03-30  Collin Funk  <collin.funk1@gmail.com>
2126         gnulib-tool.py: Don't discard the 'dummy' module.
2127         * pygnulib/GLImport.py (GLImport.prepare): Don't set modules stored in
2128         the GLModuleTable until after the 'dummy' module is added.
2129         * pygnulib/GLModuleSystem.py (GLImport.setBaseModules)
2130         (GLImport.setFinalModules, GLImport.setMainModules)
2131         (GLImport.setTestsModules): Don't sort modules since the 'dummy' module
2132         should be placed last in the Makefiles.
2134 2024-03-30  Collin Funk  <collin.funk1@gmail.com>
2136         gnulib-tool.py: Fix reading of 'gl_VC_FILES' in gnulib-cache.m4.
2137         * pygnulib/GLImport.py (GLImport.__init__): Check for an empty string
2138         explicitly in conditional so False is not ignored.
2140 2024-03-30  Bruno Haible  <bruno@clisp.org>
2142         time_r tests: Avoid misleading skip message on native Windows.
2143         * tests/test-localtime_r.c (main): Use the macro FRENCH_TZ.
2144         * tests/test-localtime_r-mt.c (main): Likewise.
2146 2024-03-30  Paul Eggert  <eggert@cs.ucla.edu>
2148         time_r-tests: skip French tests if no Europe/Paris
2149         * tests/test-localtime_r.c (main):
2150         * tests/test-localtime_r-mt.c (main):
2151         If TZ='Europe/Paris' does not work, skip these tests.
2153 2024-03-29  Paul Eggert  <eggert@cs.ucla.edu>
2155         intprops: pacify GCC < 10 -Wsign-compare
2156         Problem reported by Martin Dorey in:
2157         https://savannah.gnu.org/bugs/index.php?65537
2158         * lib/intprops-internal.h (_GL_INT_MULTIPLY_WRAPV):
2159         When working around GCC bug 91450, pacify -Wsign-compare by
2160         casting 0 to the result type.
2162 2024-03-29  Bruno Haible  <bruno@clisp.org>
2164         gnulib-tool: Use bold output on Linux, NetBSD, OpenBSD, OmniOS consoles.
2165         Reported by Pádraig Brady in
2166         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00399.html>.
2167         * gnulib-tool.sh (func_show_module_list): Use 'tput' to determine the
2168         "bold" capability of terminal types other than xterm*.
2169         * pygnulib/constants.py (get_terminfo_string, bold_escapes): New
2170         functions.
2171         * pygnulib/GLTestDir.py (GLTestDir.execute): Invoke
2172         constants.bold_escapes.
2173         * pygnulib/GLImport.py (GLImport.prepare): Likewise.
2175 2024-03-29  Collin Funk  <collin.funk1@gmail.com>
2177         gnulib-tool.py: Display specified modules in bold.
2178         * pygnulib/GLImport.py (GLImport.prepare): Detect terminals starting
2179         with 'xterm'. Change hexadecimal numbers to octal, matching
2180         gnulib-tool.sh.
2181         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
2183 2024-03-29  Bruno Haible  <bruno@clisp.org>
2185         attribute: Work around compiler bug of Oracle cc 12.6.
2186         * m4/gnulib-common.m4 (gl_COMMON_BODY): Expand _GL_ATTRIBUTE_PACKED to
2187         empty on SunPRO C.
2189 2024-03-29  Bruno Haible  <bruno@clisp.org>
2191         gnulib-tool.py: Don't print Makefile.am edits that are already done.
2192         * pygnulib/GLMakefileTable.py (GLMakefileTable): Improve comments.
2193         (GLMakefileTable.__getitem__): Do not clone the result.
2194         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am, tests_Makefile_am):
2195         Avoid a KeyError when testing for 'var'.
2196         Use 'del' to remove a dictionary entry.
2197         * pygnulib/GLImport.py (GLImport.execute): Avoid a KeyError when
2198         testing for 'var'. Simplify loop over makefiletable.
2200 2024-03-28  Bruno Haible  <bruno@clisp.org>
2202         fenv-exceptions-state-c99: Fix test failures with Oracle cc 12.6.
2203         * lib/fenv-except-state-set.c (mask387cw): New function.
2204         (fesetexceptflag): Use it on glibc.
2206 2024-03-28  Bruno Haible  <bruno@clisp.org>
2208         mcel tests: Fix test failure with Oracle cc 12.6.
2209         * tests/test-mcel.c (main): Explicitly return 0 at the end.
2211 2024-03-28  Bruno Haible  <bruno@clisp.org>
2213         gnulib-tool: Drop workarounds for Automake < 1.14.
2214         Reported by Collin Funk in
2215         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00384.html>.
2216         * gnulib-tool.sh (func_emit_lib_Makefile_am): Emit pkgdata_DATA
2217         initialization always.
2218         (func_emit_tests_Makefile_am): Likewise.
2219         (func_import): Don't emit 'AC_REQUIRE([AM_PROG_CC_C_O])' into
2220         gnulib-comp.m4.
2221         (func_create_testdir): Don't emit AM_PROG_CC_C_O into configure.ac.
2222         Bump required Automake version to 1.14.
2223         (func_create_megatestdir): Bump required Automake version to 1.14.
2224         * pygnulib/constants.py: Update comments.
2225         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Emit pkgdata_DATA
2226         initialization always. Don't return uses_subdirs.
2227         (GLEmiter.tests_Makefile_am): Likewise.
2228         * pygnulib/GLImport.py (GLImport.gnulib_comp): Don't emit
2229         'AC_REQUIRE([AM_PROG_CC_C_O])'.
2230         (GLImport.execute): Update.
2231         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't emit AM_PROG_CC_C_O
2232         into configure.ac. Bump required Automake version to 1.14.
2233         (GLMegaTestDir.execute): Bump required Automake version to 1.14.
2235 2024-03-28  Bruno Haible  <bruno@clisp.org>
2237         pthread-h: Fix override of pthread_spinlock_t with non-GNU compilers.
2238         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Define through AC_DEFUN_ONCE.
2239         Require gl_PTHREAD_H_DEFAULTS, not gl_PTHREAD_H.
2240         * m4/pthread_h.m4 (gl_PTHREAD_H): Invoke gl_PTHREAD_SPIN.
2241         * lib/pthread.in.h (pthread_spinlock_t,
2242         GNULIB_defined_pthread_spin_types): Don't define if
2243         HAVE_PTHREAD_SPIN_INIT && !REPLACE_PTHREAD_SPIN_INIT.
2244         * modules/pthread-h (Files): Add m4/pthread-spin.m4.
2246 2024-03-28  Bruno Haible  <bruno@clisp.org>
2248         havelib: Recognize ELF platform despite SunPRO C on Linux.
2249         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Recognize Linux as an ELF
2250         platform, even with the SunPRO C compiler that does not define __ELF__.
2252 2024-03-28  Collin Funk  <collin.funk1@gmail.com>
2254         gnulib-tool.py: Fix missing 'gnulib-cache.m4' in EXTRA_DIST.
2255         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Fix the loop
2256         condition so that it matches gnulib-tool.sh.
2258 2024-03-28  Collin Funk  <collin.funk1@gmail.com>
2260         gnulib-tool.py: Fix whitespace in gnulib-comp.m4.
2261         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Prefix each line with
2262         the indentation string instead of using regular expressions.
2264 2024-03-27  Collin Funk  <collin.funk1@gmail.com>
2266         gnulib-tool.py: Inline 'sed' invocations used on library files.
2267         * pygnulib/GLFileSystem.py (GLFileAssistant.__init__): Update type hints
2268         and docstrings to reflect changes necessary for using re.sub() instead
2269         of 'sed'.
2270         (GLFileAssistant.add_or_update): Use re.sub() instead of invoking 'sed'.
2271         * pygnulib/GLImport.py (GLImport.prepare): Update transformation
2272         variables to reflect changes to GLFileAssistant.
2274 2024-03-27  Bruno Haible  <bruno@clisp.org>
2276         obstack: Work around ICE with Oracle cc 12.6 (regr. 2023-12-01).
2277         * lib/obstack.in.h (__PTR_ALIGN): Use SMALL_PTRDIFF_T, instead of
2278         testing sizeof (ptrdiff_t) < sizeof (void *) at compile time.
2279         * m4/obstack.m4 (gl_FUNC_OBSTACK): Set SMALL_PTRDIFF_T.
2280         * modules/obstack (Makefile.am): Substitute SMALL_PTRDIFF_T.
2282 2024-03-27  Collin Funk  <collin.funk1@gmail.com>
2284         gnulib-tool.py: Add type hints to all functions.
2285         * pygnulib/*.py: Add type hints and remove duplicate function signatures
2286         from docstrings.
2288 2024-03-26  Collin Funk  <collin.funk1@gmail.com>
2290         gnulib-tool.py: Allow the use of both configure.ac and configure.in.
2291         * pygnulib/GLImport.py (GLImport.__init__): Remove redundant checks for
2292         configure.ac and configure.in.
2293         * pygnulib/main.py (main): Check for configure.ac and configure.in
2294         before reading it. Pass it to GLImport using the GLConfig object.
2296 2024-03-26  Bruno Haible  <bruno@clisp.org>
2298         gettime-res: Fix test failure on Solaris 11.4/SPARC.
2299         * lib/gettime-res.c (gettime_res): On Solaris/SPARC, just return 1 ns.
2301 2024-03-25  Bruno Haible  <bruno@clisp.org>
2303         jit/cache: Fix a compilation error on Solaris 11.4/SPARC.
2304         * lib/jit/cache.h: On Solaris, include <stddef.h>.
2306 2024-03-25  Bruno Haible  <bruno@clisp.org>
2308         gnulib-tool.py: Print "executing mkdir ..." messages.
2309         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
2310         Print a message before creating a 'build-aux' directory.
2312 2024-03-25  Bruno Haible  <bruno@clisp.org>
2314         gnulib-tool.py: Tweak last change.
2315         * pygnulib/GLImport.py (GLImport.execute): Recognize #if also at the
2316         beginning of an Include snippet.
2318 2024-03-25  Collin Funk  <collin.funk1@gmail.com>
2320         gnulib-tool.py: Fix output of #include directive advice.
2321         * pygnulib/GLImport.py (GLImport.execute): Copy comment from
2322         gnulib-tool.sh with modified variable names. Search the 'Include:' as a
2323         whole instead of each individual line.
2325 2024-03-25  Bruno Haible  <bruno@clisp.org>
2327         gnulib-tool.py: Simplify last change.
2328         * pygnulib/GLImport.py (GLImport.execute): Remove unnecessary list to
2329         set and set to list conversion.
2331 2024-03-25  Collin Funk  <collin.funk1@gmail.com>
2333         gnulib-tool.py: Fix "Creating directory" output.
2334         * pygnulib/GLImport.py (GLImport.execute): Reorder directories. Use
2335         os.path.join instead of joinpath to avoid path normalization.
2337 2024-03-25  Bruno Haible  <bruno@clisp.org>
2339         gnulib-tool.py: Tweak last change.
2340         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Rename some local
2341         variables. Use rstrip built-in function.
2343 2024-03-25  Collin Funk  <collin.funk1@gmail.com>
2345         gnulib-tool.py: Handle removed files in the vc ignore files.
2346         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Handle removed
2347         files. Check whether the original lines should be removed too.
2349 2024-03-24  Collin Funk  <collin.funk1@gmail.com>
2351         gnulib-tool.py: Fix filetable construction for ignorelist.
2352         * pygnulib/GLImport.py (GLImport.execute): Fix typo in dictionary key
2353         that overwrites removed files. Sort ignorelist by directory.
2355 2024-03-24  Bruno Haible  <bruno@clisp.org>
2357         gnulib-tool.py: Use Python raw strings for regular expressions.
2358         * pygnulib/*.py: Use raw string syntax for regular expression pattern
2359         strings and repl strings.
2361 2024-03-24  Bruno Haible  <bruno@clisp.org>
2363         gnulib-tool.py: Bring the output into the right order.
2364         * pygnulib/constants.py (force_output): New function.
2365         (execute): Flush stdout after printing the "executing ..." line.
2366         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
2367         Invoke force_output.
2368         * pygnulib/main.py (test, megatest): Likewise.
2370 2024-03-24  Bruno Haible  <bruno@clisp.org>
2372         nstrtime, c-nstrftime: Fix %c directive's result on glibc ≤ 2.30.
2373         * lib/strftime.c (__strftime_internal): On glibc ≤ 2.30, like on NetBSD
2374         and Solaris, remove the last word of the %c directive's result if it
2375         looks like a time zone.
2376         * doc/posix-functions/strftime.texi: Update platforms list.
2378 2024-03-24  Bruno Haible  <bruno@clisp.org>
2380         gnulib-tool.py: Fix output of notices.
2381         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't print notices if the
2382         verbosity is < -1. Strip newlines from each notice.
2383         * pygnulib/GLImport.py (GLImport.prepare): Don't print notices if the
2384         verbosity is < -1. Strip only newlines, not spaces.
2386 2024-03-23  Bruno Haible  <bruno@clisp.org>
2388         gnulib-tool.py: Fix the modules indentation in --create-testdir' output.
2389         * pygnulib/GLTestDir.py (GLTestDir.execute): Use specified_modules
2390         instead of self.config.getModules(), since the latter may be empty.
2392 2024-03-23  Bruno Haible  <bruno@clisp.org>
2394         gnulib-tool.sh: Use a default auxdir in --extract-automake-snippet.
2395         * gnulib-tool.sh (extract-automake-snippet): Set auxdir to 'build-aux'
2396         if it is not set.
2398 2024-03-23  Bruno Haible  <bruno@clisp.org>
2400         gnulib-tool.py: Don't unnecessarily sort an EXTRA_DIST augmentation.
2401         * pygnulib/GLModuleSystem.py
2402         (GLModule.getAutomakeSnippet_Unconditional): Don't remove duplicates or
2403         sort the filenames in the EXTRA_lib_SOURCES augmentation or the
2404         EXTRA_DIST augmentation for build-aux.
2406 2024-03-23  Collin Funk  <collin.funk1@gmail.com>
2408         gnulib-tool.py: Don't print Python bools in gnulib-cache.m4.
2409         * pygnulib/GLImport.py (GLImport.gnulib_cache): Convert Python bools to
2410         lowercase before printing.
2412 2024-03-23  Bruno Haible  <bruno@clisp.org>
2414         gnulib-tool.py: Don't unnecessarily run configure && make in testdirs.
2415         * pygnulib/GLTestDir.py (GLTestDir.execute): Correct the value of
2416         tests_distributed_built_sources.
2418 2024-03-23  Bruno Haible  <bruno@clisp.org>
2420         gnulib-tool.py: Fix autoconf snippets inclusion if --single-configure.
2421         * pygnulib/GLTestDir.py (GLTestDir.execute): Correct the arguments
2422         passed to autoconfSnippets.
2424 2024-03-23  Bruno Haible  <bruno@clisp.org>
2426         gnulib-tool.py: Produce same diagnostics regardless of Automake version.
2427         * pygnulib/GLTestDir.py (_patch_test_driver): Suppress the diagnostics
2428         from 'patch', and instead provide our own diagnostics.
2430 2024-03-23  Bruno Haible  <bruno@clisp.org>
2432         gnulib-tool.py: Print "executing touch config.h.in".
2433         * pygnulib/GLTestDir.py (GLTestDir.execute): Print
2434         "executing touch config.h.in", like gnulib-tool.sh does.
2436 2024-03-23  Bruno Haible  <bruno@clisp.org>
2438         gnulib-tool.py: Refactor.
2439         * pygnulib/GLImport.py (GLImport._done_dir_,
2440         GLImport._update_ignorelist_, GLImport.execute): Rename some variables.
2441         (GLImport._update_ignorelist_): Use constants.substart.
2443 2024-03-23  Collin Funk  <collin.funk1@gmail.com>
2445         gnulib-tool.py: Follow gnulib-tool changes, part 69.
2446         Follow gnulib-tool change
2447         2012-08-19  Bruno Haible  <bruno@clisp.org>
2448         gnulib-tool: Remove old file names from .cvsignore, .gitignore.
2449         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Add
2450         gnulib-comp.m4 to the added file list.
2451         (GLImport.execute): Remove unused variables. Use sets to match the
2452         'join' invocations in gnulib-tool.sh.
2454 2024-03-22  Collin Funk  <collin.funk1@gmail.com>
2456         gnulib-tool.py: Don't remove newlines in testdir's Automake snippets.
2457         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't strip newlines from
2458         Automake snippets.
2460 2024-03-22  Collin Funk  <collin.funk1@gmail.com>
2462         gnulib-tool.py: Fix empty newline output in test directories.
2463         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
2464         Match newlines printed by gnulib-tool.sh.
2466 2024-03-22  Collin Funk  <collin.funk1@gmail.com>
2468         gnulib-tool.py: Fix unconditional Automake snippets for non-tests.
2469         * pygnulib/GLModuleSystem.py
2470         (GLModule.getAutomakeSnippet_Unconditional): Fix the file lookups used
2471         to determine the EXTRA_DIST and EXTRA_lib_SOURCES Automake variables.
2472         Update comment to match gnulib-tool.sh.
2473         * pygnulib/constants.py (filter_filelist): Fix misleading return type in
2474         docstring. Return an empty string if no files were found.
2476 2024-03-22  Bruno Haible  <bruno@clisp.org>
2478         gnulib-tool.sh: Produce same diagnostics regardless of Automake version.
2479         * gnulib-tool.sh (func_create_testdir, func_create_megatestdir):
2480         Suppress the diagnostics from 'patch', and instead provide our own
2481         diagnostics.
2483 2024-03-22  Bruno Haible  <bruno@clisp.org>
2485         gnulib-tool: Remove test-driver.{orig,rej} if patching succeeded.
2486         * gnulib-tool.sh (func_create_testdir, func_create_megatestdir): After
2487         a 'patch' command failed, remove the leftover files test-driver.orig and
2488         test-driver.rej.
2489         * pygnulib/GLTestDir.py (_patch_test_driver): Likewise.
2491 2024-03-22  Bruno Haible  <bruno@clisp.org>
2493         gnulib-tool.py: Fix an error in --create-testdir.
2494         * pygnulib/GLTestDir.py (GLTestDir.execute): Fix chdir calls at the end.
2496 2024-03-21  Collin Funk  <collin.funk1@gmail.com>
2498         gnulib-tool.sh: Avoid a redundant space in gl_AVOID in gnulib-cache.m4.
2499         * gnulib-tool.sh (avoidlist): Don't add a space before the first module
2500         name.
2502 2024-03-21  Collin Funk  <collin.funk1@gmail.com>
2504         gnulib-tool.py: Fix --extract-recursive-link-directive.
2505         * pygnulib/GLModuleSystem.py (GLModule.getLinkDirectiveRecursively):
2506         Check the 'Link:' section of each individual module. Use sets instead of
2507         lists to remove duplicates.
2509 2024-03-21  Collin Funk  <collin.funk1@gmail.com>
2511         gnulib-tool.py: Make --extract-filelist match gnulib-tool.sh.
2512         * pygnulib/GLModuleSystem.py (GLModule.getFiles_Raw): New function which
2513         returns the 'Files:' section from a module unchanged.
2514         (GLModule.getFiles): Use it.
2515         * pygnulib/main.py (main): Use it and match the output of gnulib-tool.sh
2516         for --extract-filelist.
2518 2024-03-21  Bruno Haible  <bruno@clisp.org>
2520         gnulib-tool: Make the .gitignore files handling more consistent.
2521         * gnulib-tool.sh (func_done_dir): Ignore the presence or absence of a
2522         .git directory if there is a .gitignore file in the same place.
2523         * pygnulib/GLImport.py (GLImport._done_dir_): Likewise.
2525 2024-03-20  Bruno Haible  <bruno@clisp.org>
2527         gnulib-tool.sh: Undocument the --[no-]cache-modules options.
2528         Reported by Collin Funk in
2529         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00234.html>.
2530         Rationale:
2531         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00243.html>.
2532         * gnulib-tool.sh (func_usage): Don't mention --cache-modules,
2533         --no-cache-modules.
2535 2024-03-20  Collin Funk  <collin.funk1@gmail.com>
2537         gnulib-tool.py: Don't print empty Automake snippets.
2538         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
2539         (GLEmiter.tests_Makefile_am): Handle empty strings when checking if the
2540         snippet should be printed.
2542 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
2544         gnulib-tool.py: Follow gnulib-tool changes, part 68.
2545         Follow gnulib-tool change
2546         2022-07-31  Akim Demaille  <akim@lrde.epita.fr>
2547         gnulib-tool: add support for --automake-subdir-tests
2548         * pygnulib/main.py (main): Add support for --automake-subdir-tests.
2549         * pygnulib/GLInfo.py (GLInfo.usage): Add --automake-subdir-tests to the
2550         help message.
2551         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'automake_subdir_tests'
2552         to the parameter list. Initialize it.
2553         (GLConfig.default): Default --automake-subdir-tests to False.
2554         (GLConfig.resetAutomakeSubdir): Fix misleading docstring.
2555         (GLConfig.getAutomakeSubdirTests, GLConfig.setAutomakeSubdirTests)
2556         (GLConfig.resetAutomakeSubdirTests): New functions to manipulate and
2557         access whether --automake-subdir-tests is in use.
2558         * pygnulib/GLEmiter.py (GLEmiter.shellvars_init)
2559         (GLEmiter.initmacro_end): Use sourcebase when handling tests and
2560         --automake-subdir-tests is given.
2561         * pygnulib/GLError.py (GLError.__repr__): Update error message to
2562         include --automake-subdir-tests.
2563         * pygnulib/GLImport.py (GLImport.__init__): Check for the
2564         'subdir-objects' Automake option when --automake-subdir-tests is in use.
2565         (GLImport.actioncmd): Add --automake-subdir-tests to the actioncmd
2566         printed in generated files.
2568 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
2570         gnulib-tool.py: Fix incorrect assignment operator.
2571         * pygnulib/GLImport.py (GLImport.actioncmd): Use '+=' instead of '=' to
2572         append the string to the actioncmd instead of overwriting it.
2574 2024-03-19  Bruno Haible  <bruno@clisp.org>
2576         gnulib-tool: Make it work in the test suite.
2577         * gnulib-tool.sh (gnulib_dir): Make absolute.
2578         (func_create_megatestdir): If .git/refs/heads/master does not exist, use
2579         ChangeLog instead.
2580         * pygnulib/main.py (main): Make gnulib_dir absolute.
2581         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): If
2582         .git/refs/heads/master does not exist, use ChangeLog instead.
2584 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
2586         gnulib-tool.py: Make sure temporary files are removed.
2587         * pygnulib/GLImport.py (GLImport.execute): Fix nesting of statement so
2588         that both temporary files are removed.
2590 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
2592         gnulib-tool.py: Follow gnulib-tool changes, part 67.
2593         Follow gnulib-tool change
2594         2022-03-01  Paul Eggert  <eggert@cs.ucla.edu>
2595         Create lib/Makefile.am after gnulib-comp.m4
2596         * pygnulib/GLImport.py (GLImport.execute): Create library makefile after
2597         creating gnulib-comp.m4.
2599 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
2601         gnulib-tool.py: Follow gnulib-tool changes, part 66.
2602         Follow gnulib-tool change
2603         2021-12-25  Bruno Haible  <bruno@clisp.org>
2604         gnulib-tool: Fix handling of module libtextstyle-optional.
2605         * pygnulib/GLModuleSystem.py (GLModule.repeatModuleInTests): New function.
2606         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Use it for creating
2607         the tests/Makefile.am.
2608         * pygnulib/GLTestDir.py (GLTestDir.execute): Use it when creating the
2609         file list.
2611 2024-03-19  Collin Funk  <collin.funk1@gmail.com>
2613         gnulib-tool.py: Follow gnulib-tool changes, part 65.
2614         Follow gnulib-tool change
2615         2021-12-19  Bruno Haible  <bruno@clisp.org>
2616         gnulib-tool: Don't insist on ACLOCAL_AMFLAGS.
2617         * pygnulib/GLImport.py (GLImport.execute): Don't add extra '-I' before
2618         m4 directory in ACLOCAL_AMFLAGS. Prefer '0' instead of 'int()'. Mention
2619         the use of AC_CONFIG_MACRO_DIRS in configure.ac as an alternative to
2620         augmenting ACLOCAL_AMFLAGS.
2621         * pygnulib/main.py (main): To find the m4 directories, look also for
2622         AC_CONFIG_MACRO_DIR and AC_CONFIG_MACRO_DIRS invocations in
2623         configure.ac. Remove unnecessary call to 'joinpath' since it accepts a
2624         variable length of arguments.
2626 2024-03-18  Bruno Haible  <bruno@clisp.org>
2628         gnulib-tool.py: Tweak last change.
2629         * pygnulib/GLModuleSystem.py (GLModule.isTests, GLModule.isNonTests):
2630         Update comments.
2632 2024-03-18  Collin Funk  <collin.funk1@gmail.com>
2634         gnulib-tool.py: Follow gnulib-tool changes, part 64.
2635         Follow gnulib-tool change
2636         2021-12-25  Bruno Haible  <bruno@clisp.org>
2637         gnulib-tool: Respect applicability 'all' without --single-configure.
2638         * pygnulib/GLModuleSystem.py (GLModule.isTests): Treat modules with
2639         applicability 'all' like 'tests' modules, not like 'main' modules.
2640         (GLModule.isNonTests): Treat all modules not ending in '-tests' as
2641         non-test modules.
2642         (GLModule.getApplicability): Don't use GLModule.isTests(). Because it
2643         depends on the result of this function, using it would cause a
2644         RecursionError exception.
2645         (GLModule.getDependencies): Respect the difference between
2646         module.isTests(), module.isNonTests(), and
2647         module.getName().endswith('-tests').
2648         (GLModule.getAutomakeSnippet_Unconditional, GLModule.getLicense)
2649         (GLModuleTable.add_dummy): Likewise.
2650         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Likewise.
2652 2024-03-17  Bruno Haible  <bruno@clisp.org>
2654         gnulib-tool.py: Handle empty lists of lines consistently.
2655         * pygnulib/constants.py (lines_to_multiline): New function.
2656         (nlremove): Remove unused function.
2657         * pygnulib/GLEmiter.py (_eliminate_NMD): Use lines_to_multiline instead
2658         of the '\n'.join idiom.
2659         (GLEmiter.autoconfSnippet, GLEmiter.autoconfSnippets,
2660         GLEmiter.lib_Makefile_am): Likewise.
2661         * pygnulib/GLImport.py (GLImport._update_ignorelist_, GLImport.execute):
2662         Likewise.
2663         * pygnulib/GLModuleSystem.py (GLModule.getDependenciesRecursively,
2664         GLModule.getLinkDirectiveRecursively, GLModuleTable.remove_if_blocks):
2665         Likewise.
2666         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
2667         * pygnulib/main.py (main): Likewise.
2669 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
2671         gnulib-tool.py: Follow gnulib-tool changes, part 63.
2672         Follow gnulib-tool change
2673         2020-12-28  Bruno Haible  <bruno@clisp.org>
2674         gnulib-tool: Fix logic whether to add a dummy.c.
2675         * pygnulib/GLModuleSystem.py (GLModuleTable.remove_if_blocks): New
2676         function.
2677         (GLModuleTable.add_dummy): Use it to eliminate all conditional
2678         statements from the automake snippet.
2680 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
2682         gnulib-tool.py: Don't print extra newlines.
2683         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Don't print extra
2684         newline that are not printed by gnulib-tool.sh.
2686 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
2688         gnulib-tool.py: Follow gnulib-tool changes, part 62.
2689         Follow gnulib-tool change
2690         2020-02-22  Bruno Haible  <bruno@clisp.org>
2691         gnulib-tool: Ensure copied files are writable.
2692         * pygnulib/constants.py (ensure_writable): New function. Make sure files
2693         are writable.
2694         (symlink_relative, hardlink): Use it.
2695         * pygnulib/GLFileSystem.py (GLFileSystem.lookup)
2696         (GLFileAssistant.add_or_update): Likewise.
2697         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
2698         * pygnulib/main.py (main): Likewise.
2700 2024-03-17  Bruno Haible  <bruno@clisp.org>
2702         gnulib-tool: Add undocumented option --gnulib-dir.
2703         * gnulib-tool.sh: Accept --gnulib-dir=... option.
2704         * pygnulib/constants.py (init_DIRS): New function.
2705         * pygnulib/main.py (main): Accept --gnulib-dir=... option. Invoke
2706         init_DIRS. Expect .git directory to be present in DIRS['root'], not
2707         APP['root'].
2708         * pygnulib/GLImport.py (GLImport.execute): Use DIRS['root'], not
2709         APP['root'].
2711 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
2713         gnulib-tool.py: Follow gnulib-tool changes, part 61.
2714         Follow gnulib-tool change
2715         2022-01-09  Bruno Haible  <bruno@clisp.org>
2716         Remove influence of Automake conditionals on conditional dependencies.
2717         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Don't
2718         inhibit conditional dependencies processing on a module that uses an
2719         Automake conditional.
2721 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
2723         gnulib-tool.py: Follow gnulib-tool changes, part 60.
2724         Follow gnulib-tool change
2725         2019-11-18  Bruno Haible  <bruno@clisp.org>
2726         gnulib-tool: Fix build error on macOS with --conditional-dependencies.
2727         * pygnulib/GLModuleSystem.py (GLModuleTable.add_dummy): Ignore modules
2728         that are conditionally enabled.
2730 2024-03-17  Collin Funk  <collin.funk1@gmail.com>
2732         gnulib-tool.py: Don't try to remove files that don't exist.
2733         * pygnulib/GLFileSystem.py (GLFileSystem.add_or_update): Check if the
2734         temporary file exists before trying to remove it.
2736 2024-03-16  Paul Eggert  <eggert@cs.ucla.edu>
2738         renameatu: support RENAME_EXCHANGE on macOS
2739         * lib/renameatu.c (renameat2ish, renameatu) [RENAME_SWAP]:
2740         Use macOS RENAME_SWAP to implement GNU/Linux RENAME_EXCHANGE.
2741         * tests/test-renameatu.c (main): Add a test for RENAME_EXCHANGE.
2743 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
2745         gnulib-tool.py: Follow gnulib-tool changes, part 59.
2746         Follow gnulib-tool change
2747         2017-10-29  Bruno Haible  <bruno@clisp.org>
2748         gnulib-tool: Avoid unnecessary config.h.in remaking in testdirs.
2749         * pygnulib/GLTestDir.py (GLTestDir.execute): Touch the 'config.h.in'
2750         file after executing 'autoheader' to update it's timestamps.
2752 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
2754         gnulib-tool.py: Fix 'git update-index' call when using hard links.
2755         * pygnulib/main.py: Fix conditional used to check whether 'git
2756         update-index' should be called. Only catch FileNotFoundError exceptions
2757         thrown when no 'git' program exists.
2759 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
2761         gnulib-tool.py: Coding style: Avoid not().
2762         * pygnulib/GLModuleSystem.py (isNonTests): Avoid not(). Write
2763         'not condition' instead of 'not(condition)'.
2765 2024-03-16  Bruno Haible  <bruno@clisp.org>
2767         gnulib-tool.py: Coding style: Avoid bool().
2768         * pygnulib/GLModuleSystem.py (GLModule): Write False instead of bool().
2770 2024-03-16  Collin Funk  <collin.funk1@gmail.com>
2772         gnulib-tool.py: Follow gnulib-tool changes, part 58.
2773         Follow gnulib-tool change
2774         2017-05-21  Bruno Haible  <bruno@clisp.org>
2775         gnulib-tool: Add options to create hard links.
2776         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'copymode' and
2777         'lcopymode' to the parameter list. Initialize them.
2778         (GLConfig.default): Don't use symbolic or hard links by default.
2779         (GLConfig.checkCopyMode, GLConfig.setCopyMode, GLConfig.resetCopyMode):
2780         New functions to modify and check the method for copying non --local-dir
2781         files.
2782         (GLConfig.checkLCopyMode, GLConfig.setLCopyMode)
2783         (GLConfig.resetLCopyMode): New functions to modify and check the method
2784         for copying --local-dir files.
2785         (GLConfig.checkSymbolic, GLConfig.resetSymbolic, GLConfig.setSymbolic)
2786         (GLConfig.checkLSymbolic, GLConfig.resetLSymbolic)
2787         (GLConfig.setLSymbolic): Remove unused functions. The functionality of
2788         these are now implemented in the *CopyMode() and *LCopyMode() variants.
2789         * pygnulib/GLFileSystem.py (CopyAction.Hardlink): New Enum value to
2790         describe hard links.
2791         (GLFileSystem.shouldLink): Check if hard links should be used.
2792         (GLFileAssistant.add, GLFileAssistant.update): Try to hard link if
2793         enabled. Copy the file if linking fails.
2794         (GLFileAssistant.add_or_update): Remove temporary files unconditionally.
2795         * pygnulib/GLInfo.py (GLInfo.usage): Document new options in the usage
2796         message.
2797         * pygnulib/GLTestDir.py (GLTestDir.execute): Try to hard link if
2798         enabled. Copy the file if linking fails.
2799         * pygnulib/classes.py: Importy the CopyAction Enum.
2800         * pygnulib/constants.py (hardlink): New function based on
2801         symlink_relative.
2802         * pygnulib/main.py (main): Add new options --hardlink and
2803         --local-hardlink. Invoke 'git update-index --refresh' to mitigate the
2804         effects of the hard links on git.
2806 2024-03-16  Bruno Haible  <bruno@clisp.org>
2808         gnulib-tool.sh: Make --local-dir options in gnulib-cache.m4 look nicer.
2809         * gnulib-tool.sh (func_import): Append the --local-dir=... options
2810         through func_append_actionarg.
2812 2024-03-16  Bruno Haible  <bruno@clisp.org>
2814         gnulib-tool.py: Don't lose the gl_LGPL value from gnulib-cache.m4.
2815         Reported by Simon Josefsson in
2816         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00152.html>.
2817         * pygnulib/GLConfig.py (GLConfig.default): For the 'lgpl' property,
2818         return None, not False.
2820 2024-03-15  Bruno Haible  <bruno@clisp.org>
2822         gnulib-tool.py: Don't lose the gl_LOCAL_DIR value from gnulib-cache.m4.
2823         Reported by Simon Josefsson in
2824         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00152.html>.
2825         * pygnulib/GLConfig.py (GLConfig.default): For the 'localpath' property,
2826         return [], not ''.
2828 2024-03-15  Bruno Haible  <bruno@clisp.org>
2830         gnulib-tool: Enhance last patch.
2831         * gnulib-tool: If gnulib-tool.sh failed but gnulib-tool.py succeeded,
2832         report that and don't erase the outputs and log files.
2834 2024-03-14  Collin Funk  <collin.funk1@gmail.com>
2836         gnulib-tool.py: Follow gnulib-tool changes, part 57.
2837         Follow gnulib-tool change
2838         2019-01-04  Bruno Haible  <bruno@clisp.org>
2839         gnulib-tool: New option --extract-recursive-link-directive.
2840         * pygnulib/GLModuleSystem.py (GLModule.getDependenciesRecursively): New
2841         function. Implements the --extract-recursive-dependencies option.
2842         (GLModule.getLinkDirectiveRecursively): New function. Implements the
2843         --extract-recursive-link-directive.
2844         * pygnulib/main.py (main): Add the --extract-recursive-dependencies and
2845         --extract-recursive-link-directive options.
2846         * pygnulib/GLInfo.py (GLInfo.usage): Add new options to help message.
2848 2024-03-14  Bruno Haible  <bruno@clisp.org>
2850         gnulib-tool: Obey environment variable GNULIB_TOOL_IMPL.
2851         * gnulib-tool.sh: Renamed from gnulib-tool.
2852         * gnulib-tool: New file, based on gnulib-tool.sh.
2853         * gnulib-tool.py: Check the Python version.
2855 2024-03-14  Collin Funk  <collin.funk1@gmail.com>
2857         gnulib-tool.py: Fix write failure due to bad sourcebase.
2858         * pygnulib/constants.py (cleaner): Only call strip() on string objects.
2859         * pygnulib/main.py (main): Fix parsing of AMLOCAL_AMFLAGS from
2860         Makefile.am. Add some comments from gnulib-tool.
2862 2024-03-13  Bruno Haible  <bruno@clisp.org>
2864         sig2str tests: Refactor.
2865         * tests/test-sig2str.c (test_sig2str, test_str2sig): New functions,
2866         extracted from main.
2867         (main): Invoke them.
2869 2024-03-13  Collin Funk  <collin.funk1@gmail.com>
2871         sig2str: Add tests.
2872         * tests/test-sig2str.c: New file.
2873         * modules/sig2str-tests: New file.
2875 2024-03-12  Collin Funk  <collin.funk1@gmail.com>
2877         gnulib-tool.py: Follow gnulib-tool changes, part 56.
2878         Follow gnulib-tool change
2879         2021-04-26  Paul Eggert  <eggert@cs.ucla.edu>
2880         gnulib-tool: port better to current Autoconf
2881         * pygnulib/GLImport.py (GLImport.execute): Remove exit() call before
2882         printing reminders. Suggest replacing AC_PROG_CC_STDC and
2883         AC_PROG_CC_C99, as per current Autoconf.
2885 2024-03-12  Collin Funk  <collin.funk1@gmail.com>
2887         gnulib-tool.py: Fix last commit.
2888         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Silence Python
2889         warnings about invalid escape. Make sure to escape the backslash
2890         character we want to print.
2892 2024-03-12  Collin Funk  <collin.funk1@gmail.com>
2894         gnulib-tool.py: Follow gnulib-tool changes, part 55.
2895         Follow gnulib-tool changes
2896         2022-01-05  Bruno Haible  <bruno@clisp.org>
2897         gnulib-tool: Avoid known warnings that reflect Gnulib's coding style.
2898         2022-01-08  Bruno Haible  <bruno@clisp.org>
2899         gnulib-tool: Remove all *.Po files upon distclean (regr. 2022-01-05).
2900         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Collect the *.Po or
2901         *.Plo files to remove into an AC_SUBSTed variable gl_LIBOBJDEPS. Use
2902         Python f-strings instead of string replacements.
2903         (GLEmiter.lib_Makefile_am): Add the GL_CFLAG_GNULIB_WARNINGS to the
2904         CFLAGS of all the compilation units of the library. Extend the distclean
2905         and maintainer-clean rules.
2906         (GLEmiter.tests_Makefile_am): Add the GL_CFLAG_GNULIB_WARNINGS to the
2907         CFLAGS.
2908         * pygnulib/GLImport.py (GLImport.gnulib_comp): Emit an invocation of
2909         gl_CC_GNULIB_WARNINGS.
2911 2024-03-11  Collin Funk  <collin.funk1@gmail.com>
2913         gnulib-tool.py: Follow gnulib-tool changes, part 54.
2914         Follow gnulib-tool change
2915         2021-12-24  Paul Eggert  <eggert@cs.ucla.edu>
2916         maint: avoid empty lines in recipes
2917         * pygnulib/GLEmiter.py (_eliminate_NMD_from_line): Eliminate occurrences
2918         of @!NMD@ too. Document parameters in docstring.
2919         (_eliminate_NMD): Update docstring to reflect changes. Document
2920         parameters.
2922 2024-03-11  Bruno Haible  <bruno@clisp.org>
2924         gnulib-tool.py: Tweak last commit.
2925         * pygnulib/GLEmiter.py (_eliminate_NMD): Don't add an extra newline when
2926         the result should be empty.
2928 2024-03-11  Collin Funk  <collin.funk1@gmail.com>
2930         gnulib-tool.py: Follow gnulib-tool changes, part 53.
2931         Follow gnulib-tool change
2932         2021-12-21  Bruno Haible  <bruno@clisp.org>
2933         Optimize redundant 'mkdir -p .' invocations.
2934         * pygnulib/GLEmiter.py (_eliminate_NMD_from_line): New private function
2935         to remove @NMD@ occurrences from the line of an Automake snippet.
2936         (_eliminate_NMD): New private function which uses
2937         _eliminate_NMD_from_line on each line of the Automake snippet.
2938         (GLEmiter.lib_Makefile_am, GLEmiter.tests_Makefile_am): Use
2939         _eliminate_NMD on the Automake snippet.
2941 2024-03-11  Bruno Haible  <bruno@clisp.org>
2943         gnulib-tool.py: Make some code more straightforward.
2944         * pygnulib/GLImport.py (GLImport.__init__): Reorder assignments and
2945         conditions slightly.
2947 2024-03-11  Collin Funk  <collin.funk1@gmail.com>
2949         gnulib-tool.py: Follow gnulib-tool changes, part 52.
2950         Follow gnulib-tool change
2951         2021-12-15  Bruno Haible  <bruno@clisp.org>
2952         automake-subdir support: Look for 'subdir-objects' also in configure.ac.
2953         * pygnulib/GLImport.py (GLImport.__init__): Check for 'subdir-objects'
2954         in the AM_INIT_AUTOMAKE macro of configure.ac.
2956 2024-03-10  Bruno Haible  <bruno@clisp.org>
2958         gnulib-tool.py: Tweak last commit.
2959         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Avoid an implicit str
2960         to bool conversion.
2961         * pygnulib/GLImport.py (GLImport.__init__): Add a comment. Don't allow
2962         a '|' in place of whitespace. Don't emit redundant gl_source_base
2963         assignments.
2965 2024-03-10  Collin Funk  <collin.funk1@gmail.com>
2967         gnulib-tool.py: Follow gnulib-tool changes, part 51.
2968         Follow gnulib-tool change
2969         2021-12-15  Bruno Haible  <bruno@clisp.org>
2970         Accommodate non-recursive Automake in a less hacky way.
2971         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'automake_subdir' to the
2972         parameter list.
2973         (GLConfig.default): Set the default value of automake_subdir to a
2974         boolean False.
2975         (GLConfig.getAutomakeSubdir, GLConfig.setAutomakeSubdir)
2976         (GLConfig.resetAutomakeSubdir): New functions to access and manipulate
2977         the automake_subdir option.
2978         * pygnulib/GLEmiter.py (GLEmiter.shellvars_init): New function.
2979         (GLEmiter.initmacro_end): Add second parameter 'gentests'. Use it to prefix each
2980         object file name in *_LIBOBJS and *_LTLIBOBJS.
2981         * pygnulib/GLError.py (GLError.__init__, GLError.__repr__): Add new
2982         error for if --automake-subdir is used without the 'subdir-objects'
2983         Automake option.
2984         * pygnulib/GLImport.py (GLImport.__init__): Check for 'subdir-objects'
2985         in Makefile.am.
2986         (GLImport.actioncmd): Emit --automake-subdir in actioncmd.
2987         (GLImport.gnulib_cache): Add gl_AUTOMAKE_SUBDIR to gnulib-cache.m4 if
2988         --automake-subdir is used.
2989         (GLImport.gnulib_comp): Update calls to GLEmiter.initmacro_end. Call
2990         GLEmiter.shellvars_init.
2991         (GLImport.execute): Likewise. Use the build-aux/prefix-gnulib-mk script.
2992         * pygnulib/GLInfo.py (GLInfo.usage): Add --automake-subdir to the usage
2993         message.
2994         * pygnulib/GLTestDir.py (GLTestDir.execute): Update calls to
2995         GLEmiter.initmacro_end. Call GLEmiter.shellvars_init.
2996         * pygnulib/main.py (main): Add support for --automake-subdir.
2998 2024-03-10  Collin Funk  <collin.funk1@gmail.com>
3000         gnulib-tool: Don't remove comments referencing @NMD@, part 2.
3001         * gnulib-tool (func_emit_tests_Makefile_am): Replace lines that start
3002         with @NMD@ or @!NMD@ instead of lines that contain them.
3004 2024-03-10  Bruno Haible  <bruno@clisp.org>
3006         gnulib-tool.py: One more comment regarding coding style.
3007         * pygnulib/main.py: Add comment regarding conditional expressions.
3009 2024-03-09  Collin Funk  <collin.funk1@gmail.com>
3011         gnulib-tool.py: Follow gnulib-tool changes, part 50.
3012         Follow gnulib-tool changes
3013         2021-12-12  Bruno Haible  <bruno@clisp.org>
3014         gnulib-tool: Try to support non-recursive-gnulib-prefix-hack with tests.
3015         2021-12-13  Bruno Haible  <bruno@clisp.org>
3016         gnulib-tool: Fix mistake in last commit.
3017         * pygnulib/GLImport.py (GLImport.gnulib_comp): Expect the filetable as a
3018         parameter instead of a list of all files. Add type checks. Invoke
3019         AC_CONFIG_LIBOBJ_DIR based on the location of alloca.c.
3020         (GLImport.execute): Adjust call to GLImport.gnulib_comp to reflect
3021         parameter changes.
3023 2024-03-09  Collin Funk  <collin.funk1@gmail.com>
3025         gnulib-tool.py: Follow gnulib-tool changes, part 49.
3026         Follow gnulib-tool change
3027         2021-08-07  Bruno Haible  <bruno@clisp.org>
3028         gnulib-tool: Add support for Automake 1.16.4.
3029         * pygnulib/GLTestDir.py (_patch_test_driver): If patching
3030         build-aux/test-driver fails with build-aux/test-driver.diff try again
3031         with build-aux/test-driver-1.16.3.diff.
3033 2024-03-09  Bruno Haible  <bruno@clisp.org>
3035         unistr/u16-to-u32: Relicense under LGPLv2+.
3036         * modules/unistr/u16-to-u32 (License): Change to LGPLv2+.
3037         * lib/unistr/u16-to-u32.c: Update license notice.
3039         unistr/u16-mbtoucr: Relicense under LGPLv2+.
3040         * modules/unistr/u16-mbtoucr (License): Change to LGPLv2+.
3041         * lib/unistr/u16-mbtoucr.c: Update license notice.
3043         unistr/u16-strlen: Relicense under LGPLv2+.
3044         * modules/unistr/u16-strlen (License): Change to LGPLv2+.
3045         * lib/unistr/u16-strlen.c: Update license notice.
3047 2024-03-09  Bruno Haible  <bruno@clisp.org>
3049         parse-datetime: Simplify.
3050         * modules/parse-datetime (Makefile.am): Don't generate
3051         parse-datetime-gen.h.
3053 2024-03-09  Bruno Haible  <bruno@clisp.org>
3055         parse-datetime: Simplify.
3056         * lib/parse-datetime.y (yyerror): Change return type to 'void'.
3058 2024-03-09  Collin Funk  <collin.funk1@gmail.com>
3060         gnulib-tool.py: Follow gnulib-tool changes, part 48.
3061         Follow gnulib-tool change
3062         2019-01-23  Bruno Haible  <bruno@clisp.org>
3063         gnulib-tool: Support running testdirs on Android.
3064         * pygnulib/GLError.py (GLError.__init__, GLError.__repr__): Add errno 20
3065         to print an error if patching build-aux/test-driver fails.
3066         * pygnulib/main.py (main): Likewise.
3067         * pygnulib/GLTestDir.py (_patch_test_driver): New private function which
3068         runs patch on build-aux/test-driver with build-aux/test-driver.diff.
3069         (GLTestDir.execute, GLMegaTestDir.execute): Check for
3070         build-aux/test-driver in each testdir and patch it after running
3071         automake.
3073 2024-03-08  Collin Funk  <collin.funk1@gmail.com>
3075         gnulib-tool: Don't remove comments referencing @NMD@.
3076         * gnulib-tool (func_emit_lib_Makefile_am): Replace lines that start with
3077         @NMD@ or @!NMD@ instead of lines that contain them.
3079 2024-03-08  Collin Funk  <collin.funk1@gmail.com>
3081         gnulib-tool.py: Follow gnulib-tool changes, part 47.
3082         Follow gnulib-tool changes
3083         2021-12-15  Bruno Haible  <bruno@clisp.org>
3084         Fix creation of build directories with non-recursive-gnulib-prefix-hack.
3085         2021-12-18  Bruno Haible  <bruno@clisp.org>
3086         Fix support for --gnu-make in tests (regression 2021-12-15).
3087         * pygnulib/GLEmiter.py (_CONVERT_TO_GNU_MAKE): New variable which is a
3088         list of tuples which are used with re.sub.
3089         (_convert_to_gnu_make): New function which converts an input snippet
3090         from Automake to GNU Make syntax using the regular expressions stored in
3091         _CONVERT_TO_GNU_MAKE.
3092         (GLEmiter.lib_Makefile_am): Use _convert_to_gnu_make. Replace '%reldir%'
3093         tokens.
3094         (GLEmiter.tests_Makefile_am): Likewise.
3096 2024-03-07  Collin Funk  <collin.funk1@gmail.com>
3098         gnulib-tool.py: Fix errors when executing --create-megatestdir.
3099         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Create a testdir for
3100         each module in its own subdirectory. Create a testdir with all modules
3101         in 'ALL'. Add missing join call on str object. Don't emit 'configure.ac'
3102         into 'Makefile.am'. Make sure commands are executed in the proper
3103         directory.
3105 2024-03-07  Collin Funk  <collin.funk1@gmail.com>
3107         gnulib-tool.py: Follow gnulib-tool changes, part 46.
3108         Follow gnulib-tool change
3109         2022-02-22  Simon Josefsson  <simon@josefsson.org>
3110         gnulib-tool: Bump automake dependency.
3111         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
3112         (GLEmiter.tests_Makefile_am): Require Automake >= 1.14, for %reldir%
3113         support.
3115 2024-03-07  Collin Funk  <collin.funk1@gmail.com>
3117         gnulib-tool.py: Follow gnulib-tool changes, part 45.
3118         Follow gnulib-tool changes
3119         2021-12-12  Bruno Haible  <bruno@clisp.org>
3120         gnulib-tool: Support different basenames for the lib/,tests/ Makefiles.
3121         2022-01-08  Bruno Haible  <bruno@clisp.org>
3122         gnulib-tool: Fix "Don't forget" messages (regression 2021-12-12).
3123         * pygnulib/GLConfig.py (GLConfig.__init__): Add 'tests_makefile_name'
3124         argument.
3125         (GLConfig.getMakefileName, GLConfig.setMakefileName)
3126         (GLConfig.resetMakefileName): Remove references to tests Makefile.am in
3127         doc strings.
3128         (GLConfig.getTestsMakefileNamem, GLConfig.setTestsMakefileName)
3129         (GLConfig.resetTestsMakefileName): New methods used to access value
3130         passed with the '--tests-makefile-name' option.
3131         * pygnulib/GLImport.py (GLImport.__init__): Check for
3132         'gl_TESTS_MAKEFILE_NAME' in cache.
3133         (GLImport.actioncmd): Output --tests-makefile-name when describing
3134         gnulib-tool invocation.
3135         (GLImport.gnulib_cache): Output 'gl_TESTS_MAKEFILE_NAME' to cache.
3136         (GLImport.execute): Use two local variables, source_makefile_am and
3137         tests_makefile_am, which are passed to gnulib-tool.py or given default
3138         values.
3139         * pygnulib/GLInfo.py (GLInfo.usage): Add '--tests-makefile-name' to
3140         usage message.
3141         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Reduce code
3142         duplication by expecting Makefile names passed as arguments.
3143         * pygnulib/main.py (main): Add support for '--tests-makefile-name'.
3145 2024-03-06  Bruno Haible  <bruno@clisp.org>
3147         gnulib-tool: Search for a working 'join' program.
3148         Reported by Reuben Thomas <rrt@sc3d.org> in
3149         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00044.html>.
3150         * gnulib-tool (JOIN): New variable. Use it everywhere instead of 'join'.
3152 2024-03-06  Bruno Haible  <bruno@clisp.org>
3154         c-strtof, c-strtod, c-strtold: Comment.
3155         * lib/c-strtod.c: Mention me as co-author.
3157 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
3159         gnulib-tool.py: Fix value of LDADD for libtests.
3160         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Fix value of LDADD
3161         to match gnulib-tool.
3163 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
3165         gnulib-tool.py: Follow gnulib-tool changes, part 44.
3166         Follow gnulib-tool changes
3167         2021-06-10  Bruno Haible  <bruno@clisp.org>
3168         Clarify where to report test failures from Gnulib tests.
3169         2021-06-11  Bruno Haible  <bruno@clisp.org>
3170         Make message in last commit more precise.
3171         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Emit a dependency
3172         of 'check-am' on 'check-notice' that prints a notice describing where to
3173         report test failures.
3175 2024-03-06  Bruno Haible  <bruno@clisp.org>
3177         gnulib-tool.py: Tweak comment location.
3178         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Move a comment.
3180 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
3182         gnulib-tool.py: Follow gnulib-tool changes, part 43.
3183         Follow gnulib-tool change
3184         2021-06-10  Bruno Haible  <bruno@clisp.org>
3185         Clarify that compiler warnings in the Gnulib tests can be ignored.
3186         * pygnulib/GLEmiter.py (GLEmiter.initmacro_start): Add boolean argument
3187         to control whether gl_CC_ALLOW_WARNINGS and gl_CXX_ALLOW_WARNINGS should
3188         be required.
3189         (GLEmiter.tests_Makefile_am): Emit overrides for CFLAGS and CXXFLAGS.
3190         Emit a dependency of 'all' on 'all-notice' that prints a warning that
3191         compiler warnings can be ignored for tests.
3192         * pygnulib/GLImport.py (GLImport.gnulib_comp): Add boolean argument to
3193         tell whether a tests Makefile.am is being emitted. Update calls to
3194         GLEmiter.initmacro_start.
3195         (GLImport.execute): Update calls to GLEmiter.initmacro_start.
3196         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
3198 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
3200         gnulib-tool.py: Fix gnulib-cache.m4 output.
3201         * pygnulib/GLImport.py (GLImport.gnulib_cache): Don't emit an extra '#'
3202         to start the actioncmd comment.
3204 2024-03-06  Bruno Haible  <bruno@clisp.org>
3206         gnulib-tool.py: Tweak comment.
3207         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Tweak 'gentests'
3208         description.
3210 2024-03-06  Collin Funk  <collin.funk1@gmail.com>
3212         gnulib-tool.py: Follow gnulib-tool changes, part 42.
3213         Follow gnulib-tool change
3214         2019-02-15  Bruno Haible  <bruno@clisp.org>
3215         gnulib-tool: Support --import with just a few tests, not --with-tests.
3216         * pygnulib/GLImport.py (GLImport.execute): Use 'gentests' instead of
3217         'inctests' when generating files.
3218         * pygnulib/GLMakefileTable.py (GLMakefileTable.parent): Add 'gentests'
3219         argument and use it instead of 'inctests'.
3221 2024-03-05  Collin Funk  <collin.funk1@gmail.com>
3223         gnulib-tool.py: Follow gnulib-tool changes, part 41.
3224         Follow gnulib-tool change
3225         2018-09-03  Bruno Haible  <bruno@clisp.org>
3226         gnulib-tool: Fix build order when $testsbase is a subdir of $sourcebase.
3227         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Consider the dotfirst
3228         flag.
3229         (GLEmiter.tests_Makefile_am): Don't consider the dotfirst flag.
3230         * pygnulib/GLImport.py (GLImport.execute): Set the dotfirst for tests.
3231         * pygnulib/GLMakefileTable.py (GLMakefileTable.editor): Add optional
3232         dotfirst flag to fix build order when $testsbase is a subdir of
3233         $sourcebase.
3235 2024-03-05  Collin Funk  <collin.funk1@gmail.com>
3237         gnulib-tool.py: Follow gnulib-tool changes, part 40.
3238         Follow gnulib-tool change
3239         2021-12-18  Bruno Haible  <bruno@clisp.org>
3240         stdint: Fix handling of limits.h (regression 2021-12-16).
3241         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
3242         (GLEmiter.tests_Makefile_am): If --gnu-make is used, assume that
3243         AC_SUBSTed variables for conditionals are constructed by appending the
3244         suffix '_CONDITION'.
3246 2024-03-05  Collin Funk  <collin.funk1@gmail.com>
3248         gnulib-tool.py: Fix incorrect tests Makefile.am generation.
3249         * pygnulib/GLImport.py: Call GLEmiter.tests_Makefile_am instead of
3250         GLEmiter.lib_Makefile_am when creating the tests Makefile. Replace
3251         incorrect actioncmd argument with witness_macro.
3253 2024-03-05  Bruno Haible  <bruno@clisp.org>
3255         doc: Update info about fopencookie.
3256         Reported by Michael Ford <fanquake@gmail.com>.
3257         * doc/glibc-functions/fopencookie.texi: Update platforms list.
3259 2024-03-05  Bruno Haible  <bruno@clisp.org>
3261         doc: Fix a typo.
3262         Reported by Tim Rice in
3263         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00023.html>.
3264         * doc/build-automation.texi (Building gnulib): Fix typo.
3266 2024-03-05  Bruno Haible  <bruno@clisp.org>
3268         c-strtof, c-strtod, c-strtold: Make multithread-safe.
3269         * lib/c-strtod.c: Include <langinfo.h>, c-ctype.h.
3270         (decimal_point_char): New function, copied from lib/vasnprintf.c.
3271         (C_STRTOD): On platforms that don't have STRTOD_L nor a working
3272         uselocale(), pre-parse the number and call STRTOD after having replaced
3273         the '.' with the locale-dependent decimal point character.
3274         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOF, gl_C_STRTOLD): Test for
3275         nl_langinfo().
3276         * modules/c-strtof (Depends-on): Add c-ctype. Remove strdup-posix.
3277         * modules/c-strtod (Depends-on): Likewise.
3278         * modules/c-strtold (Depends-on): Likewise.
3280 2024-03-05  Bruno Haible  <bruno@clisp.org>
3282         c-strtold: Add multithread-safety test.
3283         * tests/test-c-strtold-mt.c: New file.
3284         * tests/test-c-strtold-mt.sh: New file, based on
3285         tests/test-c-strtold1.sh.
3286         * modules/c-strtold-tests (Files): Add them.
3287         (Depends-on): Add thread, nanosleep.
3288         (Makefile.am): Arrange to build test-c-strtold-mt and run
3289         test-c-strtold-mt.sh.
3291 2024-03-05  Bruno Haible  <bruno@clisp.org>
3293         c-strtod: Add multithread-safety test.
3294         * tests/test-c-strtod-mt.c: New file.
3295         * tests/test-c-strtod-mt.sh: New file, based on tests/test-c-strtod1.sh.
3296         * modules/c-strtod-tests (Files): Add them.
3297         (Depends-on): Add thread, nanosleep.
3298         (Makefile.am): Arrange to build test-c-strtod-mt and run
3299         test-c-strtod-mt.sh.
3301 2024-03-05  Bruno Haible  <bruno@clisp.org>
3303         c-strtof: Add multithread-safety test.
3304         * tests/test-c-strtof-mt.c: New file.
3305         * tests/test-c-strtof-mt.sh: New file, based on tests/test-c-strtof1.sh.
3306         * modules/c-strtof-tests (Files): Add them.
3307         (Depends-on): Add thread, nanosleep.
3308         (Makefile.am): Arrange to build test-c-strtof-mt and run
3309         test-c-strtof-mt.sh.
3311 2024-03-05  Bruno Haible  <bruno@clisp.org>
3313         locale-*.m4: Update comments.
3314         * m4/locale-ar.m4: Update comments for Solaris 10.
3315         * m4/locale-fr.m4: Likewise.
3316         * m4/locale-ja.m4: Likewise.
3317         * m4/locale-tr.m4: Likewise.
3319 2024-03-05  Bruno Haible  <bruno@clisp.org>
3321         c-strtold: Add tests.
3322         * tests/test-strtold.h: New file, extracted from tests/test-strtold.c.
3323         * tests/test-strtold.c: Include test-strtold.h.
3324         (FABSL): Remove unused macro.
3325         (main): Just invoke test_function.
3326         * tests/test-strtold1.c: Add comment.
3327         * modules/strtold-tests (Files): Add tests/test-strtold.h.
3328         * tests/test-c-strtold.c: New file, based on tests/test-strtold.c.
3329         * tests/test-c-strtold1.c: New file, based on tests/test-strtold1.c.
3330         * tests/test-c-strtold1.sh: New file, based on tests/test-strtold1.sh.
3331         * modules/c-strtold-tests: New file, based on modules/strtold-tests.
3333 2024-03-05  Bruno Haible  <bruno@clisp.org>
3335         c-strtod: Add tests.
3336         * tests/test-strtod.h: New file, extracted from tests/test-strtod.c.
3337         * tests/test-strtod.c: Include test-strtod.h.
3338         (FABS): Remove unused macro.
3339         (main): Just invoke test_function.
3340         * tests/test-strtod1.c: Add comment.
3341         * modules/strtod-tests (Files): Add tests/test-strtod.h.
3342         * tests/test-c-strtod.c: New file, based on tests/test-strtod.c.
3343         * tests/test-c-strtod1.c: New file, based on tests/test-strtod1.c.
3344         * tests/test-c-strtod1.sh: New file, based on tests/test-strtod1.sh.
3345         * modules/c-strtod-tests: New file, based on modules/strtod-tests.
3347 2024-03-05  Bruno Haible  <bruno@clisp.org>
3349         c-strtof: Add tests.
3350         * tests/test-strtof.h: New file, extracted from tests/test-strtof.c.
3351         * tests/test-strtof.c: Include test-strtof.h.
3352         (FABS): Remove unused macro.
3353         (main): Just invoke test_function.
3354         * tests/test-strtof1.c: Add comment.
3355         * modules/strtof-tests (Files): Add tests/test-strtof.h.
3356         * tests/test-c-strtof.c: New file, based on tests/test-strtof.c.
3357         * tests/test-c-strtof1.c: New file, based on tests/test-strtof1.c.
3358         * tests/test-c-strtof1.sh: New file, based on tests/test-strtof1.sh.
3359         * modules/c-strtof-tests: New file, based on modules/strtof-tests.
3361 2024-03-04  Collin Funk  <collin.funk1@gmail.com>
3363         gnulib-tool.py: Follow gnulib-tool changes, part 39.
3364         Follow gnulib-tool change
3365         2017-12-28  Bruno Haible  <bruno@clisp.org>
3366         gnulib-tool: Make --conditional-dependencies work better.
3367         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Add argument
3368         referenceable_modules. Use referencable_modules for dependencies.
3369         * pygnulib/GLImport.py (GLImport.__init__): Don't reject the combination
3370         of --conditional-dependencies with --with-tests when mode is 'import'.
3371         (GLImport.gnulib_comp): Pass it.
3372         * pygnulib/GLTestDir.py (GLTestDir.execute): Pass it.
3374 2024-03-04  Bruno Haible  <bruno@clisp.org>
3376         doc: Tweak last commit.
3377         * doc/gnulib-tool.texi (Style of #include statements): Use
3378         @itemize @asis{}. Recommended by Patrice Dumas.
3380 2024-03-04  Collin Funk  <collin.funk1@gmail.com>
3382         doc: Fix build errors.
3383         * doc/gnulib-tool.texi (Style of #include statements): Use @itemize w{}
3384         instead of the incorrect @itemize @asis.
3386 2024-03-04  Collin Funk  <collin.funk1@gmail.com>
3388         gnulib-tool.py: Adjust construction of configure.ac path.
3389         * pygnulib/GLConfig.py (GLConfig.setAutoconfFile): Join destdir and
3390         configure.ac instead of using relativize.
3392 2024-03-03  Collin Funk  <collin.funk1@gmail.com>
3393             Bruno Haible  <bruno@clisp.org>
3395         gnulib-tool.py: Fix output of gnulib-comp.m4.
3396         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Fix indentation.
3397         Don't print nonstring values into gnulib-comp.m4.
3399 2024-03-03  Collin Funk  <collin.funk1@gmail.com>
3401         gnulib-tool.py: Make output of test Makefile.am match gnulib-tool.
3402         * pygnulib/GLModuleSystem.py
3403         (GLModule.getAutomakeSnippet_Unconditional): Don't sort EXTRA_DIST file
3404         names for test modules.
3406 2024-03-03  Bruno Haible  <bruno@clisp.org>
3408         gnulib-tool.py: Fix last commit.
3409         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Ignore libname and
3410         libext here.
3412 2024-03-03  Collin Funk  <collin.funk1@gmail.com>
3414         gnulib-tool.py: Follow gnulib-tool changes, part 38.
3415         Follow gnulib-tool change
3416         2020-12-26  Bruno Haible  <bruno@clisp.org>
3417         gnulib-tool: Make --conditional-dependencies work with --with-tests.
3418         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Add missing
3419         moduletable argument. Handle conditional dependencies like
3420         GLEmiter.lib_Makefile_am.
3421         * pygnulib/GLTestDir.py (GLTestDir.execute): Adjust arguments.
3423 2024-03-03  Bruno Haible  <bruno@clisp.org>
3425         doc: Update regarding --create-megatestdir.
3426         Reported by Alexei Sholomitskiy <asholomitskiy84@gmail.com> in
3427         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00071.html>
3428         and by Collin Funk <collin.funk1@gmail.com> in
3429         <https://lists.gnu.org/archive/html/bug-gnulib/2024-03/msg00007.html>.
3430         * doc/build-automation.texi (Building gnulib): Discourage the use of
3431         --create-megatestdir with all modules.
3433 2024-03-01  Bruno Haible  <bruno@clisp.org>
3435         gnulib-tool.py: Clarify minimum supported Python version.
3436         * pygnulib/main.py: Add comment regarding the Python version.
3438 2024-03-01  Collin Funk  <collin.funk1@gmail.com>
3440         gnulib-tool.py: Follow gnulib-tool changes, part 37.
3441         Follow gnulib-tool change
3442         2018-10-22  Bruno Haible  <bruno@clisp.org>
3443         Assume Automake >= 1.11.
3444         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am)
3445         (GLEmiter.tests_Makefile_am): Emit a Makefile.am that requires Automake
3446         >= 1.11.
3447         * pygnulib/GLTestDir.py (GLTestDir.execute, GLMegaTestDir.execute):
3448         Likewise.
3449         * pygnulib/constants.py: Update comment.
3451 2024-03-01  Collin Funk  <collin.funk1@gmail.com>
3453         gnulib-tool.py: Fix GNU Make conversion regular expressions.
3454         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Reduce code
3455         duplication. Use re.MULTILINE so '^' matches the start of each line
3456         instead of only the start of a string.
3458 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
3460         gnulib-tool.py: Follow gnulib-tool changes, part 36.
3461         Follow gnulib-tool change
3462         2017-03-14  Mathieu Lirzin  <mthl@gnu.org>
3463         gnulib-tool: don't automatically distribute files from top/
3464         * pygnulib/GLModuleSystem.py
3465         (GLModule.getAutomakeSnippet_Unconditional): Don't distribute files from
3466         top/ automatically.
3468 2024-02-29  Bruno Haible  <bruno@clisp.org>
3470         xalloc: Don't use identifier 'nonnull'.
3471         * lib/xmalloc.c (check_nonnull): Renamed from nonnull.
3473 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
3475         gnulib-tool.py: Follow gnulib-tool changes, part 35.
3476         Follow gnulib-tool change
3477         2023-05-28  Bruno Haible  <bruno@clisp.org>
3478         warnings, manywarnings: Assume autoconf >= 2.64.
3479         * pygnulib/GLConfig.py (GLConfig.default, GLConfig.getAutoconfVersion)
3480         (GLConfig.setAutoconfVersion, resetAutoconfVersion): Set required
3481         Autoconf version to 2.64.
3482         * pygnulib/GLError.py (GLError.__init__, GLError.__repr__): Likewise.
3483         * pygnulib/GLImport.py (GLImport.__init__): Likewise.
3484         * pygnulib/constants.py (DEFAULT_AUTOCONF_MINVERSION): Likewise.
3485         * pygnulib/main.py: Likewise.
3487 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
3489         gnulib-tool.py: Follow gnulib-tool changes, part 34.
3490         Follow gnulib-tool change
3491         2017-05-15  Bruno Haible  <bruno@clisp.org>
3492         gnulib-tool: Fix generated code when libtests contains module 'alloca'.
3493         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Use @ALLOCA@ for
3494         libtests.a instead of @LTALLOCA@.
3496 2024-02-29  Collin Funk  <collin.funk1@gmail.com>
3498         gnulib-tool.py: Follow gnulib-tool changes, part 33.
3499         Follow gnulib-tool change
3500         2017-03-14  Bruno Haible  <bruno@clisp.org>
3501         gnulib-tool: Don't produce a tests directory with only snippet .h files.
3502         * pygnulib/GLModuleSystem.py
3503         (GLModuleTable.transitive_closure_separately): Don't create a test
3504         directory if all test related modules have applicability 'all'.
3506 2024-02-28  Collin Funk  <collin.funk1@gmail.com>
3508         gnulib-tool.py: Follow gnulib-tool changes, part 32.
3509         Follow gnulib-tool change
3510         2018-10-22  Bruno Haible  <bruno@clisp.org>
3511         Fix failure of 'gnulib-tool --create-testdir' with all modules.
3512         * pygnulib/GLTestDir.py (GLTestDir.execute): Exclude the 'timevar'
3513         module from --create-testdir with all modules. Update comment.
3515 2024-02-28  Collin Funk  <collin.funk1@gmail.com>
3517         gnulib-tool.py: Emit year range on file copyright notices.
3518         * pygnulib/GLInfo.py (GLInfo.copyright_range): New function. Return a
3519         copyright string with a year range.
3520         * pygnulib/GLEmiter.py (GLEmiter.copyright_notice): Use the new function
3521         for file copyright headers.
3523 2024-02-28  Collin Funk  <collin.funk1@gmail.com>
3525         gnulib-tool.py: Make module sorting more similar to gnulib-tool.
3526         * pygnulib/GLImport.py (GLImport.__init__): Sort modules when mode is
3527         'import'.
3528         (GLImport.actioncmd): Don't sort modules while creating actioncmd. Use
3529         preferred quoting style.
3531 2024-02-28  Bruno Haible  <bruno@clisp.org>
3533         gnulib-tool: Make --version output independent of git's configuration.
3534         Reported by Collin Funk <collin.funk1@gmail.com> in
3535         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00268.html>.
3536         * pygnulib/GLInfo.py (GLInfo.date): Pass --format and --date options, to
3537         override the user's git configuration.
3538         * gnulib-tool (func_version): Likewise. Also pass options '-n 1', to
3539         speed up the operation.
3541 2024-02-28  Bruno Haible  <bruno@clisp.org>
3543         gnulib-tool.py: Avoid exception when 'git log' output is unexpected.
3544         * pygnulib/GLInfo.py (GLInfo.date): When the 'git log' output does not
3545         contain a line with the expected 'Date:' pattern, pass the empty string
3546         to GNU date.
3548 2024-02-28  Bruno Haible  <bruno@clisp.org>
3550         gnulib-tool: Avoid references to functions that get defined later.
3551         * gnulib-tool (func_fatal_error, func_warning, func_readlink): Move
3552         before func_gnulib_dir.
3554 2024-02-27  Bruno Haible  <bruno@clisp.org>
3556         isnan: Fix compilation error in C++ mode on OpenBSD 7.5-beta.
3557         Reported by Christian Weisgerber <naddy@mips.inka.de> in
3558         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00261.html>.
3559         * lib/math.in.h (GNULIB_NAMESPACE_LACKS_ISNAN): Define on all platforms
3560         with clang ≥ 14.
3562 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
3564         gnulib-tool.py: Fix configure.ac output.
3565         * pygnulib/GLEmiter.py (GLEmiter.initmacro_end): Fix backslash escapes
3566         in raw string.
3568 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
3570         gnulib-tool.py: Follow gnulib-tool changes, part 31.
3571         Follow gnulib-tool change
3572         2021-06-04  Bruno Haible  <bruno@clisp.org>
3573         gnulib-tool: Stop doing license notice replacements.
3574         * pygnulib/GLConfig.py (GLConfig.default): Remove 'copyrights' key.
3575         (checkCopyrights): Remove function.
3576         (setSymbolic, resetSymbolic): Remove 'copyrights' key.
3577         * pygnulib/GLImport.py (GLImport.prepare): Remove copyrights variable.
3578         Don't modify license notice on source files.
3579         (GLImport.execute): Remove copyrights variable.
3581 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
3583         gnulib-tool.py: Small fix of part 27.
3584         * pygnulib/GLConfig.py (GLConfig.default): Add 'gnu_make' key which
3585         returns False.
3587 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
3589         gnulib-tool.py: Follow gnulib-tool changes, part 30.
3590         Follow gnulib-tool change
3591         2021-05-30  Bruno Haible  <bruno@clisp.org>
3592         Write 'LGPLv3+ or GPLv2+' instead of 'LGPLv3+ or GPLv2'.
3593         * pygnulib/GLImport.py (GLImport.prepare): Change.
3594         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
3596 2024-02-27  Collin Funk  <collin.funk1@gmail.com>
3598         gnulib-tool.py: Follow gnulib-tool changes, part 29.
3599         Follow gnulib-tool change
3600         2021-03-06  Paul Eggert  <eggert@cs.ucla.edu>
3601         parse-datetime2: fix licensing
3602         * pygnulib/GLModuleSystem.py (GLModule.getLicense): Handle the special
3603         licensing case for parse-datetime2 or any other module starting with
3604         "parse-datetime". Update comment.
3606 2024-02-26  Bruno Haible  <bruno@clisp.org>
3608         gnulib-tool.py: Add more comments.
3609         * pygnulib/main.py: Add comments regarding code style. Mention the
3610         pycodestyle and pylint configurations.
3612 2024-02-26  Collin Funk  <collin.funk1@gmail.com>
3614         gnulib-tool.py: Add configuration files for Python tools.
3615         * pygnulib/.pylintrc: New file, used by pylintrc.
3616         * pygnulib/setup.cfg: New file, currently only used for pycodestyle
3617         options.
3619 2024-02-26  Collin Funk  <collin.funk1@gmail.com>
3621         gnulib-tool.py: Fix undefined variable access.
3622         * pygnulib/main.py (main): Don't use gnu_make before it is defined.
3624 2024-02-26  Bruno Haible  <bruno@clisp.org>
3626         gnulib-tool.py: Reorganize code.
3627         * pygnulib/main.py: New file, moved here from gnulib-tool.py.
3628         * pygnulib/constants.py: Change the way APP['name'] and DIRS['root'] are
3629         computed.
3630         * gnulib-tool.py: New file, based on gnulib-tool.
3632 2024-02-25  Bruno Haible  <bruno@clisp.org>
3634         bitset: Don't access errno when it's not set.
3635         * lib/bitset/stats.c (bitset_stats_read): Don't use errno after neither
3636         fread() nor ferror() has set it. On native Windows, don't use errno
3637         after fclose().
3639 2024-02-25  Bruno Haible  <bruno@clisp.org>
3641         bitset: Avoid newlines at the end of translatable strings.
3642         * lib/bitset/stats.c (bitset_percent_histogram_print,
3643         bitset_log_histogram_print): Print a newline after msg.
3644         (bitset_stats_print_1): Don't include a newline in the argument of
3645         bitset_percent_histogram_print or bitset_log_histogram_print.
3646         (bitset_stats_print): Move newlines outside of translatable strings.
3648 2024-02-24  Collin Funk  <collin.funk1@gmail.com>
3650         gnulib-tool.py: Follow gnulib-tool changes, part 28.
3651         Follow gnulib-tool change
3652         2018-07-17  Paul Eggert  <eggert@cs.ucla.edu>
3653         gnulib-tool: limit line length for git send-email
3654         * pygnulib/GLImport.py (GLImport.actioncmd): Break actioncmd into
3655         multiple lines. Reorder emitting of arguments to match gnulib-tool. Emit
3656         "--witness-c-macro" instead of "--witness_c_macro". Emit "--po-domain"
3657         instead of "--podomain". Document ordering of unimplemented options. Add
3658         updated comments documenting line length limitations of git send-email
3659         and some implementations of AWK.
3660         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Remove comment which
3661         was moved to pygnulib/GLImport.py. Remove length limitation on actioncmd
3662         since it now spans multiple lines.
3664 2024-02-24  Bruno Haible  <bruno@clisp.org>
3666         gnulib-tool.py: Further fix last commit.
3667         * gnulib-tool.py (main): Make the mode test match for 'create-testdir',
3668         'create-megatestdir', 'test', 'megatest'.
3670 2024-02-24  Collin Funk  <collin.funk1@gmail.com>
3672         gnulib-tool.py: Fix conditional checking the incorrect variable.
3673         Reported by Bruno Haible <bruno@clisp.org> in
3674         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00207.html>.
3675         * gnulib-tool.py (main): Fix incorrect conditional. Check that mode, not
3676         modules, is not None before treating it as a string.
3678 2024-02-24  Bruno Haible  <bruno@clisp.org>
3680         striconveha tests: Avoid test failure on macOS 12.5.
3681         * tests/test-striconveha.c (main): Skip transliteration tests when using
3682         Apple's modified GNU libiconv or the bastard Apple iconv.
3684 2024-02-23  Bruno Haible  <bruno@clisp.org>
3686         DEPENDENCIES: Update entry about gperf.
3687         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
3688         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00201.html>.
3689         * DEPENDENCIES (gperf): Mention some more modules which require 'gperf'.
3691 2024-02-23  Bruno Haible  <bruno@clisp.org>
3693         unictype/mirror: Update to Unicode 15.1.0.
3694         Reported by Daurnimator <quae@daurnimator.com> in
3695         <https://lists.gnu.org/archive/html/bug-libunistring/2016-11/msg00010.html>.
3696         * lib/gen-uni-tables.c (struct mirror_pair): New type.
3697         (mirror_pairs): Don't initialize statically.
3698         (mirror_pairs_count): New variable.
3699         (fill_mirror): New function.
3700         (get_mirror_value): Update.
3701         (main): Expect the file name of BidiMirroring.txt as command-line
3702         argument. Invoke fill_mirror.
3703         * lib/unictype/mirror.h: Regenerated.
3704         * modules/unictype/mirror (configure.ac): Bump required libunistring
3705         version.
3707 2024-02-23  Bruno Haible  <bruno@clisp.org>
3709         gen-uni-tables: Keep line number better up-to-date.
3710         * lib/gen-uni-tables.c (fill_width, fill_org_lbp): Increase lineno by 1
3711         when reading a blank line.
3713 2024-02-23  Collin Funk  <collin.funk1@gmail.com>
3715         gnulib-tool.py: Follow gnulib-tool changes, part 27.
3716         Follow gnulib-tool changes
3717         2017-03-12  Paul Eggert  <eggert@cs.ucla.edu>
3718         gnulib-tool: new option --gnu-make
3719         2017-03-13  Paul Eggert  <eggert@cs.ucla.edu>
3720         gnulib-tool: minor --gnu-make fixups
3721         2017-03-14  Paul Eggert  <eggert@cs.ucla.edu>
3722         gnulib-tool: fix typo in comment output
3723         2017-05-14  Paul Eggert  <eggert@cs.ucla.edu>
3724         gnulib-tool: improve GNU Make debugging
3725         2018-07-04  Paul Eggert  <eggert@cs.ucla.edu>
3726         gnulib-tool: minor tweaks for --gnu-make
3727         * gnulib-tool.py (main): Add --gnu-make option. Do not allow --gnu-make
3728         in test modes, since they all require Automake.
3729         * pygnulib/GLConfig.py: Add gnu_make argument to constructor.
3730         (getGnuMake, setGnuMake, resetGnuMake): New methods for accessing the
3731         gnu_make instance variable.
3732         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Use the "+=" operator
3733         with GNU Make and Automake. Transform conditionals to GNU Make syntax if
3734         --gnu-make is in use. Use a Autoconf subprocess to define values and
3735         check the return code for errors.
3736         (GLEmiter.tests_Makefile_am): Likewise.
3737         * pygnulib/GLImport.py (GLImport.actioncmd): Add "--gnu-make" to the
3738         output comment if it is in use.
3739         (GLImport.gnulib_comp): Don't require "AM_PROG_CC_C_O" when using GNU
3740         Make.
3741         * pygnulib/GLInfo.py (GLInfo.usage): Update help message to reflect
3742         addition of --gnu-make.
3743         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Don't
3744         add Automake snippets as unconditional dependencies when using
3745         --gnu-make.
3747 2024-02-23  Bruno Haible  <bruno@clisp.org>
3749         unistdio/*printf tests: Update expected test results regarding %n.
3750         * tests/unistdio/test-u8-printf1.h (test_xfunction): If
3751         NEED_PRINTF_WITH_N_DIRECTIVE is not defined, expect a NULL result in the
3752         %n test.
3753         * tests/unistdio/test-u16-printf1.h (test_xfunction): Likewise.
3754         * tests/unistdio/test-u32-printf1.h (test_xfunction): Likewise.
3755         * tests/unistdio/test-ulc-printf1.h (test_xfunction): Likewise.
3757 2024-02-22  Collin Funk  <collin.funk1@gmail.com>
3759         gnulib-tool.py: Follow gnulib-tool changes, part 26.
3760         Follow gnulib-tool change
3761         2017-04-20  Bruno Haible  <bruno@clisp.org>
3762         verify tests: Fix spurious failure with parallel make.
3763         * pygnulib/GLEmiter.py (GLEmiter.tests_Makefile_am): Emit initialization
3764         of EXTRA_PROGRAMS so that the verify-tests module does not cause
3765         Automake to warn about the use of "+=" instead of "=".
3767 2024-02-22  Collin Funk  <collin.funk1@gmail.com>
3769         gnulib-tool.py: Follow gnulib-tool changes, part 25.
3770         Follow gnulib-tool change
3771         2017-06-11  Bruno Haible  <bruno@clisp.org>
3772         gnulib-tool: Clean up after autotools.
3773         * pygnulib/GLTestDir.py (GLTestDir.execute): Remove
3774         unnessecary autom4te.cache directory generated by Autotools.
3775         (GLMegaTestDir.execute): Likewise.
3777 2024-02-21  Bruno Haible  <bruno@clisp.org>
3779         c-strtof: New module.
3780         * lib/c-strtod.h (c_strtof): New declaration.
3781         * lib/c-strtod.c: Support FLOAT.
3782         * lib/c-strtof.c: New file.
3783         * m4/c-strtod.m4 (gl_C_STRTOF): New macro.
3784         * modules/c-strtof: New file.
3786 2024-02-21  Bruno Haible  <bruno@clisp.org>
3788         c-strtold: Use strtold_l when available (regr. 2019-01-31).
3789         * lib/c-strtod.c: Fix typo: HAVE_GOOD_STRTOLD_L was never defined.
3791 2024-02-21  Bruno Haible  <bruno@clisp.org>
3793         strtof: Add tests.
3794         * tests/test-strtof.c: New file, based on tests/test-strtod.c.
3795         * tests/test-strtof1.sh: New file, based on tests/test-strtod1.sh.
3796         * tests/test-strtof1.c: New file, based on tests/test-strtod1.c.
3797         * modules/strtof-tests: New file, based on modules/strtod-tests.
3799         strtof: New module.
3800         * lib/stdlib.in.h (strtof): New declaration.
3801         * lib/strtod.c: Support USE_FLOAT.
3802         * lib/strtof.c: New file.
3803         * m4/strtof.m4: New file, based on m4/strtod.m4.
3804         * m4/ldexpf.m4 (gl_CHECK_LDEXPF_NO_LIBM): New macro, based on
3805         m4/ldexp.m4.
3806         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize
3807         GNULIB_STRTOF.
3808         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOF, HAVE_STRTOF,
3809         REPLACE_STRTOF.
3810         * modules/strtof: New file.
3811         * tests/test-stdlib-c++.cc (strtof): Check signature.
3812         * doc/posix-functions/strtof.texi: Mention the new module and the bugs
3813         that it fixes.
3814         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_STRTOF, REPLACE_STRTOF.
3816 2024-02-21  Bruno Haible  <bruno@clisp.org>
3818         strtod, strtold tests: Avoid a test failure on native Windows.
3819         * modules/strtod-tests (Depends-on): Add setlocale.
3820         * modules/strtold-tests (Depends-on): Likewise.
3822 2024-02-21  Collin Funk  <collin.funk1@gmail.com>
3824         gnulib-tool.py: Fix undefined variable while emitting testdir.
3825         * pygnulib/GLTestDir.py (GLTestDir.execute): Fix undefined
3826         variable refrence caused by commit
3827         01cd78f9d682ff75cc5ab1c2d21b911bdd9215b8.
3828         Restore the previous auxdir when finished writing the
3829         configure.ac file in the test directory.
3831 2024-02-21  Bruno Haible  <bruno@clisp.org>
3833         *printf-posix: Disable support for the 'n' directive by default.
3834         * m4/printf-with-n-directive.m4: New file.
3835         * modules/printf-with-n-directive: New file.
3836         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): If
3837         gl_PRINTF_SUPPORT_N_DIRECTIVE is not defined, ignore the value of the
3838         gl_cv_func_printf_directive_n variable.
3839         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
3840         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX): Likewise.
3841         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
3842         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Likewise.
3843         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
3844         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
3845         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
3846         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
3847         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): If
3848         gl_PRINTF_SUPPORT_N_DIRECTIVE is not defined, ignore the values of the
3849         gl_cv_func_printf_directive_n and gl_cv_func_snprintf_directive_n
3850         variables.
3851         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
3852         * lib/printf-parse.c (PRINTF_PARSE): If NEED_PRINTF_WITH_N_DIRECTIVE is
3853         not defined, treat the 'n' directive like an unknown directive.
3854         * lib/vasnprintf.c (VASNPRINTF): If NEED_PRINTF_WITH_N_DIRECTIVE is not
3855         defined, disable the processing of the 'n' directive.
3856         * tests/test-snprintf-posix.h (test_function): If
3857         NEED_PRINTF_WITH_N_DIRECTIVE is not defined, skip the %n test.
3858         * tests/test-sprintf-posix.h (test_function): Likewise.
3859         * tests/test-vasnprintf-posix.c (test_function): Likewise.
3860         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
3861         * tests/test-vasprintf-posix.c (test_function): Likewise.
3862         * doc/posix-functions/dprintf.texi: Mention that support for the 'n'
3863         directive is only enabled together with the module
3864         'printf-with-n-directive'.
3865         * doc/posix-functions/fprintf.texi: Likewise.
3866         * doc/posix-functions/printf.texi: Likewise.
3867         * doc/posix-functions/snprintf.texi: Likewise.
3868         * doc/posix-functions/sprintf.texi: Likewise.
3869         * doc/posix-functions/vdprintf.texi: Likewise.
3870         * doc/posix-functions/vfprintf.texi: Likewise.
3871         * doc/posix-functions/vprintf.texi: Likewise.
3872         * doc/posix-functions/vsnprintf.texi: Likewise.
3873         * doc/posix-functions/vsprintf.texi: Likewise.
3874         * doc/glibc-functions/obstack_printf.texi: Likewise.
3875         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
3876         * NEWS: Mention the change.
3878 2024-02-21  Bruno Haible  <bruno@clisp.org>
3880         *printf-posix: Avoid crash in another configure test.
3881         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): In the test program, catch the
3882         SIGABRT signal, so that the program does not dump core.
3884 2024-02-20  Bruno Haible  <bruno@clisp.org>
3886         unimetadata/u-version: Add tests.
3887         * tests/unimetadata/test-u-version.c: New file.
3888         * modules/unimetadata/u-version-tests: New file.
3890         unimetadata/u-version: New module.
3891         * lib/gen-uni-tables.c (output_version): New function.
3892         (main): Invoke it.
3893         * lib/unimetadata/u-version.c: New generated file.
3894         * modules/unimetadata/u-version: New file.
3896         unimetadata/base: New module.
3897         * lib/unimetadata.in.h: New file.
3898         * m4/unimetadata_h.m4: New file.
3899         * modules/unimetadata/base: New file.
3901 2024-02-20  Collin Funk  <collin.funk1@gmail.com>
3903         maint.mk: Fix include header typo.
3904         * top/maint.mk: Change arpa_inet.h to arpa/inet.h.
3906 2024-02-20  Bruno Haible  <bruno@clisp.org>
3908         *printf-posix: Avoid crash in a configure test.
3909         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): In the test program, catch the
3910         SIGABRT signal, so that the program does not dump core.
3912 2024-02-18  Jim Meyering  <meyering@meta.com>
3914         maint.mk: improve new syntax-check rule
3915         * top/maint.mk (sc_prefer_angle_bracket_headers): Rename from
3916         sc_verify_absolute_include_headers.  Simplify to run a single
3917         invocation of grep, rather than usually many.  Derive a regular
3918         expression matching the selected headers, and warn about any
3919         offending matches via what is usually a single grep invocation.
3921 2024-02-18  Collin Funk  <collin.funk1@gmail.com>
3923         gnulib-tool.py: Fix function call on incorrect object.
3924         * pygnulib/GLImport.py: Call checkInclTestCategory on the
3925         GLConfig member instead of the GLImport object itself.
3926         * pygnulib/__init__.py: Update copyright dates.
3927         * pygnulib/constants.py: Update copyright dates.
3929 2024-02-18  Bruno Haible  <bruno@clisp.org>
3931         maint.mk: Add more comments.
3932         * top/maint.mk: Reference the Gnulib documentation where suitable.
3934 2024-02-18  Collin Funk  <collin.funk1@gmail.com>
3936         maint.mk: Add syntax-check rule to check for #include syntax.
3937         * top/maint.mk (sc_verify_absolute_include_headers): New rule
3938         to check for #includes that might cause
3939         -Winclude-next-absolute-path warnings.
3941 2024-02-18  Bruno Haible  <bruno@clisp.org>
3943         doc: Mention requirement regarding #include syntax.
3944         * doc/gnulib-tool.texi (-I options, Include <config.h>,
3945         Style of #include statements): New subsections.
3947 2024-02-17  Paul Eggert  <eggert@cs.ucla.edu>
3949         qsort_r-tests: minor visibility cleanup
3950         * tests/test-qsort_r.c (cmp): Now static.
3952         savedir: work around GCC bug 113963
3953         * lib/savedir.c: Ignore -Wanalyzer-malloc-leak and
3954         -Wanalyzer-null-dereference.
3956         Solaris EOL update
3957         * doc/solaris-versions: Solaris 11.4 EOL update.  Also mention 11.3.
3959 2024-02-17  Collin Funk  <collin.funk1@gmail.com>
3961         math: More clang -Winclude-next-absolute-path silencing.
3962         * lib/math.c: Write #include <math.h> instead of #include "math.h".
3964 2024-02-17  Bruno Haible  <bruno@clisp.org>
3966         error: More clang -Winclude-next-absolute-path silencing.
3967         * modules/error-h (Include): Suggest <error.h>, not "error.h".
3968         * m4/error_h.m4: Write #include <error.h>.
3970 2024-02-15  Bruno Haible  <bruno@clisp.org>
3972         nstrftime: Optimize module dependencies.
3973         * modules/nstrftime (Depends-on): Remove localename-unsafe. Add
3974         localename-unsafe-limited.
3976 2024-02-15  Bruno Haible  <bruno@clisp.org>
3978         localename-unsafe-limited: New module.
3979         * m4/localename.m4 (gl_LOCALENAME_UNSAFE_LIMITED): New macro.
3980         * modules/localename-unsafe-limited: New file.
3981         * modules/localename-unsafe (Depends-on): Add localename-unsafe-limited.
3982         (Makefile.am): Compile localename-unsafe.c only if the module
3983         localename-unsafe-limited does not already do it.
3985 2024-02-15  Bruno Haible  <bruno@clisp.org>
3987         nstrftime, fprintftime: Optimize.
3988         * lib/strftime.c (should_remove_ampm): Call gl_locale_name_unsafe
3989         instead of gl_locale_name.
3990         * modules/nstrftime (Depends-on): Remove localename. Add
3991         localename-unsafe.
3993 2024-02-15  Bruno Haible  <bruno@clisp.org>
3995         localename-unsafe: Optimize.
3996         * lib/localename-unsafe.c (gl_locale_name_posix_unsafe): Call
3997         setlocale_null_unlocked instead of setlocale_null.
3998         * modules/localename-unsafe (Depends-on): Add setlocale-null-unlocked.
4000 2024-02-15  Bruno Haible  <bruno@clisp.org>
4002         setlocale_null-unlocked: Add tests.
4003         * tests/test-setlocale_null-unlocked.c: New file, based on
4004         tests/test-setlocale_null.c.
4005         * modules/setlocale-null-unlocked-tests: New file.
4007         setlocale_null-unlocked: New module.
4008         * lib/setlocale_null.h (setlocale_null_r_unlocked,
4009         setlocale_null_unlocked): New declarations.
4010         * lib/setlocale_null-unlocked.c: New file, based on
4011         lib/setlocale_null.c.
4012         * lib/setlocale_null.c: Don't include <wchar.h>.
4013         (setlocale_null_unlocked, setlocale_null_r_unlocked): Remove functions.
4014         * modules/setlocale-null-unlocked: New file.
4015         * modules/setlocale-null (Depends-on): Add setlocale-null-unlocked.
4017 2024-02-15  Bruno Haible  <bruno@clisp.org>
4019         setlocale-null: Refactor.
4020         * lib/setlocale_null.c
4021         (setlocale_null_r_with_lock): Renamed from setlocale_null_with_lock.
4022         (setlocale_null_r_unlocked): Renamed from setlocale_null_unlocked.
4023         (setlocale_null_unlocked): Renamed from setlocale_null_androidfix.
4025 2024-02-15  Bruno Haible  <bruno@clisp.org>
4027         localename-unsafe: New module.
4028         * lib/localename.h (gl_locale_name_unsafe, gl_locale_name_thread_unsafe,
4029         gl_locale_name_posix_unsafe): New declarations.
4030         * lib/localename-unsafe.c: New file, based on lib/localename.c.
4031         (gl_locale_name_thread_unsafe): Renamed from gl_locale_name_thread.
4032         (gl_locale_name_posix_unsafe): Renamed from gl_locale_name_posix.
4033         (gl_locale_name_unsafe): Renamed from gl_locale_name.
4034         (struniq): Define only on platforms that need it.
4035         * lib/localename.c: Remove code that was moved to
4036         lib/localename-unsafe.c.
4037         (gl_locale_name_thread): Just call gl_locale_name_thread_unsafe and
4038         struniq.
4039         (gl_locale_name_posix): Just call gl_locale_name_posix_unsafe and
4040         struniq.
4041         * lib/locale.in.h: Test @GNULIB_LOCALENAME_UNSAFE@ instead of
4042         @GNULIB_LOCALENAME@.
4043         * m4/locale_h.m4 (gl_LOCALE_H_REQUIRE_DEFAULTS): Initialize
4044         GNULIB_LOCALENAME_UNSAFE instead of GNULIB_LOCALENAME.
4045         * modules/locale (Makefile.am): Substitute GNULIB_LOCALENAME_UNSAFE
4046         instead of GNULIB_LOCALENAME.
4047         * m4/localename.m4 (gl_LOCALENAME_UNSAFE): Renamed from gl_LOCALENAME.
4048         * modules/localename-unsafe: New file, based on modules/localename.
4049         * modules/localename: Greatly simplify.
4050         (Depends-on): Add localename-unsafe.
4052 2024-02-15  Bruno Haible  <bruno@clisp.org>
4054         localename: Refactor.
4055         * lib/struniq.h: New file, extracted from lib/localename.c.
4056         * lib/localename.c: Include it.
4057         * modules/localename (Files): Add lib/struniq.h.
4059 2024-02-15  Bruno Haible  <bruno@clisp.org>
4061         localename: Speed up lookup of the LC_MESSAGES name on AIX ≥ 7.2.
4062         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): On AIX, test
4063         for the 'locale_name' member.
4064         * lib/localename.c (get_locale_t_name): For the LC_MESSAGES category,
4065         use the 'locale_name' member if available.
4067 2024-02-15  Bruno Haible  <bruno@clisp.org>
4069         localename: Add more comments.
4070         * m4/intl-thread-locale.m4: Document expected configuration results.
4071         * doc/posix-functions/uselocale.texi: Update platforms list.
4072         * lib/localename.c: Likewise.
4074 2024-02-15  Bruno Haible  <bruno@clisp.org>
4076         localename: Add parameter validation.
4077         * lib/localename.c (get_locale_t_name, gl_locale_name_thread_unsafe,
4078         gl_locale_name_thread, gl_locale_name_posix, gl_locale_name): Verify
4079         that the category argument is not LC_ALL.
4081 2024-02-14  Bruno Haible  <bruno@clisp.org>
4083         localename: Notice setlocale() invocations on more platforms.
4084         * lib/localename.c (HAVE_LOCALE_NULL): Define also on musl, FreeBSD,
4085         NetBSD, Solaris, Haiku.
4086         * modules/localename (Files): Add m4/musl.m4.
4087         (configure.ac): Invoke gl_MUSL_LIBC.
4088         * tests/test-localename.c (C_CANONICALIZED): New macro, for Haiku.
4089         (is_default): New function, for musl libc and Haiku.
4090         (test_locale_name, test_locale_name_posix): Use these definitions.
4091         * modules/localename-tests (Files): Add m4/musl.m4.
4092         (configure.ac): Invoke gl_MUSL_LIBC.
4094 2024-02-14  Bruno Haible  <bruno@clisp.org>
4096         Don't treat Apple's new Citrus/FreeBSD-based iconv like GNU libiconv.
4097         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Don't treat the bastard Apple
4098         iconv like GNU libiconv.
4099         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Likewise.
4100         * lib/striconveh.c (iconv_carefully, iconv_carefully_1,
4101         mem_cd_iconveh_internal): Likewise.
4102         * lib/propername.c (proper_name_utf8): Likewise.
4103         * lib/unicodeio.c (unicode_to_mb): Likewise.
4104         * lib/uniconv/u16-conv-from-enc.c (UTF16_NAME): Likewise.
4105         * lib/uniconv/u16-conv-to-enc.c (UTF16_NAME): Likewise.
4106         * lib/uniconv/u16-strconv-to-enc.c (UTF16_NAME): Likewise.
4107         * lib/uniconv/u32-conv-from-enc.c (UTF32_NAME): Likewise.
4108         * lib/uniconv/u32-conv-to-enc.c (UTF32_NAME): Likewise.
4109         * lib/uniconv/u32-strconv-to-enc.c (UTF32_NAME): Likewise.
4110         * tests/test-striconveh.c (main): Likewise.
4111         * tests/test-striconveha.c (main): Likewise.
4112         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
4113         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
4114         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
4115         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
4116         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
4117         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
4119 2024-02-14  Bruno Haible  <bruno@clisp.org>
4121         Improve support of Citrus/FreeBSD iconv.
4122         * lib/striconveh.c (iconveh_open): Use //TRANSLIT with all iconv
4123         implementations that support it.
4124         * lib/striconveha.c (mem_iconveha, str_iconveha): Likewise.
4125         * lib/propername.c (proper_name_utf8): Likewise.
4127 2024-02-14  Bruno Haible  <bruno@clisp.org>
4129         isnan: Fix compilation error in C++ mode on macOS 14.4 / Xcode 15.2.
4130         Reported by Paul E Reimer <reimer@anl.gov> in
4131         <https://lists.gnu.org/archive/html/bug-gettext/2024-02/msg00002.html>.
4132         * lib/math.in.h (GNULIB_NAMESPACE_LACKS_ISNAN): Define also on macOS
4133         with clang ≥ 14.
4135 2024-02-13  Paul Eggert  <eggert@cs.ucla.edu>
4137         nstrftime: allow opt-out of AM/PM adjustment
4138         For Emacs I would rather avoid bringing in the Gnulib locking code,
4139         since Emacs has its own idea about locks and its main engine is
4140         single-threaded anyway.
4141         Provide a way to use the nstrftime module while avoiding its
4142         recently-added localename dependency, which entails locking code.
4143         (It’s not clear to me that the locking code is needed for nstrftime,
4144         as NetBSD has strftime_z and Solaris locales could be inspected in
4145         some thread-safe way, e.g., by probing strftime month names.
4146         Anyway, all that’s more hassle than I want to put up with right now
4147         for the trivial matter of AM/PM behavior.)
4148         * lib/strftime.c (REQUIRE_GNUISH_STRFTIME_AM_PM):
4149         New macro, which can be overridden by config.h.
4150         (should_remove_ampm, __strftime_internal):
4151         Use it instead of !USE_C_LOCALE when deciding to
4152         implement Gnuish AM/PM behavior.
4154 2024-02-13  Bruno Haible  <bruno@clisp.org>
4156         uniwidth/width tests: Update unit test for last commit.
4157         * tests/uniwidth/test-uc_width2.sh: Update expected test result.
4159 2024-02-12  Bruno Haible  <bruno@clisp.org>
4161         uniwidth/width: Assign width 1 to prepended concatenation marks.
4162         Suggested by Jules Bertholet <julesbertholet@quoi.xyz> in
4163         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00093.html>.
4164         * lib/gen-uni-tables.c (is_nonspacing): For characters with property
4165         Prepended_Concatenation_Mark, return false instead of true.
4166         * lib/uniwidth/width0.h: Regenerated. This assigns width 1 to the
4167         characters U+0600..U+0605, U+06DD, U+070F, U+0890..U+0891, U+08E2,
4168         U+110BD, U+110CD.
4169         * modules/uniwidth/width (configure.ac): Bump required libunistring
4170         version.
4171         * modules/uniwidth/u8-width (configure.ac): Likewise.
4172         * modules/uniwidth/u8-strwidth (configure.ac): Likewise.
4173         * modules/uniwidth/u16-width (configure.ac): Likewise.
4174         * modules/uniwidth/u16-strwidth (configure.ac): Likewise.
4175         * modules/uniwidth/u32-width (configure.ac): Likewise.
4176         * modules/uniwidth/u32-strwidth (configure.ac): Likewise.
4178 2024-02-12  Bruno Haible  <bruno@clisp.org>
4180         Implement a new property, added by Unicode 9.0.0.
4181         * lib/gen-uni-tables.c (is_property_prepended_concatenation_mark): New
4182         function.
4183         (output_properties): Output also the property
4184         prepended_concatenation_mark.
4185         * lib/unictype.in.h (UC_PROPERTY_PREPENDED_CONCATENATION_MARK,
4186         uc_is_property_prepended_concatenation_mark): New declarations.
4187         * m4/unictype_h.m4 (gl_UNICTYPE_H_REQUIRE_DEFAULTS): Initialize
4188         GNULIB_UNICTYPE_PROPERTY_PREPENDED_CONCATENATION_MARK.
4189         * modules/unictype/base (Makefile.am): Substitute
4190         GNULIB_UNICTYPE_PROPERTY_PREPENDED_CONCATENATION_MARK.
4191         * lib/unictype/pr_prepended_concatenation_mark.c: New file.
4192         * lib/unictype/pr_prepended_concatenation_mark.h: New generated file.
4193         * modules/unictype/property-prepended-concatenation-mark: New file.
4194         * tests/unictype/test-pr_prepended_concatenation_mark.c: New generated
4195         file.
4196         * modules/unictype/property-prepended-concatenation-mark-tests: New
4197         file.
4198         * lib/unictype/pr_byname.gperf: Add prepended_concatenation_mark.
4199         * lib/unictype/pr_byname.c
4200         (UC_PROPERTY_INDEX_PREPENDED_CONCATENATION_MARK): New enum item.
4201         (uc_property_byname): Handle it.
4202         * modules/unictype/property-byname (Depends-on): Add
4203         unictype/property-prepended-concatenation-mark.
4204         * modules/unictype/property-all (Depends-on): Likewise.
4205         * MODULES.html.sh (func_all_modules): Add
4206         unictype/property-prepended-concatenation-mark.
4208 2024-02-12  Bruno Haible  <bruno@clisp.org>
4210         posixtm tests: Fix reference to undefined module (regr. 2024-02-09).
4211         * modules/posixtm-tests (Depends-on): Remove strftime. Add
4212         strftime-fixes.
4214 2024-02-12  Bruno Haible  <bruno@clisp.org>
4216         limits-h: Fix BOOL_MAX value.
4217         * lib/limits.in.h (BOOL_MAX): Define to 1, not to 2^BOOL_WIDTH-1.
4218         * tests/test-limits-h.c (main): Change expected value of BOOL_MAX.
4220 2024-02-12  Bruno Haible  <bruno@clisp.org>
4222         stdalign: Document a clang 17 bug.
4223         * doc/posix-headers/stdalign.texi: Mention a clang 17 bug.
4225 2024-02-12  Bruno Haible  <bruno@clisp.org>
4227         getcwd, getcwd-lgpl: Fix configure test.
4228         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Don't redeclare getcwd().
4230 2024-02-12  Florian Weimer  <fweimer@redhat.com>
4232         pthread_mutex_timedlock, pthread-spin: Fix configure test.
4233         * m4/pthread_mutex_timedlock.m4 (gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK): Pass
4234         a pointer of the correct type to pthread_mutex_timedlock.
4235         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Pass a pointer of the correct
4236         type to pthread_spin_init.
4238 2024-02-11  Bruno Haible  <bruno@clisp.org>
4240         Fulfil the obligations of the Unicode license.
4241         * lib/gen-uni-tables.c: Prepend the Unicode license when copying
4242         NameAliases.txt, UnicodeData.txt, NormalizationTest.txt,
4243         GraphemeBreakTest.txt, WordBreakTest.txt.
4244         * tests/unigbrk/GraphemeBreakTest.txt: Prepend the Unicode license.
4245         * tests/uniname/NameAliases.txt: Likewise.
4246         * tests/uniname/UnicodeData.txt: Likewise.
4247         * tests/uninorm/NormalizationTest.txt: Likewise.
4248         * tests/uniwbrk/WordBreakTest.txt: Likewise.
4249         * tests/uniname/HangulSyllableNames.txt: Add public-domain notice.
4251 2024-02-11  Bruno Haible  <bruno@clisp.org>
4253         time_r: Add tests.
4254         * lib/time_r.c: Add comment.
4255         * tests/test-gmtime_r.c: New file.
4256         * tests/test-gmtime_r-mt.c: New file, based on
4257         tests/test-nl_langinfo-mt.c.
4258         * tests/test-localtime_r.c: New file.
4259         * tests/test-localtime_r-mt.c: New file, based on
4260         tests/test-nl_langinfo-mt.c.
4261         * modules/time_r-tests: New file.
4263 2024-02-10  Paul Eggert  <eggert@cs.ucla.edu>
4265         doc: improve warnings about ctime etc.
4266         * doc/posix-functions/asctime.texi (asctime):
4267         * doc/posix-functions/asctime_r.texi (asctime_r):
4268         Say why these functions are typically used mistakenly.
4269         * doc/posix-functions/ctime.texi (ctime):
4270         * doc/posix-functions/ctime_r.texi (ctimef):
4271         Say that they can dump core due to an internal null pointer, too.
4272         * doc/posix-functions/ctime.texi (ctime):
4273         Don’t recommend ctime_r.
4275 2024-02-10  Bruno Haible  <bruno@clisp.org>
4277         havelib: Add support for NetBSD/sparc64.
4278         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On NetBSD/sparc64 in
4279         32-bit mode, search for libraries in /usr/lib/sparc.
4281 2024-02-09  Bruno Haible  <bruno@clisp.org>
4283         ctime, localtime, tzset, wcsftime: Make multithread-safe.
4284         * lib/ctime.c: Include <wchar.h>.
4285         (rpl_ctime): Modify _environ and _wenviron without using _putenv.
4286         * lib/localtime.c: Include <wchar.h>.
4287         (rpl_localtime): Modify _environ and _wenviron without using _putenv.
4288         * lib/tzset.c: Include <wchar.h>.
4289         (rpl_tzset): Modify _environ and _wenviron without using _putenv.
4290         * lib/wcsftime.c (rpl_wcsftime): Likewise.
4292 2024-02-09  Bruno Haible  <bruno@clisp.org>
4294         strftime: Remove module, deprecated in 2017.
4295         * modules/strftime: Remove file.
4296         * NEWS: Mention it.
4298 2024-02-09  Bruno Haible  <bruno@clisp.org>
4300         Avoid suboptimal definition of _GL_HAS_ATTRIBUTE on FreeBSD/sparc64.
4301         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _GL_HAS_ATTRIBUTE only
4302         once.
4304 2024-02-08  Bruno Haible  <bruno@clisp.org>
4306         nstrtime, c-nstrftime tests: Strengthen the tests.
4307         * tests/test-nstrftime.h (FUNC_CHECKED): New function.
4308         (posixtm_test, tzalloc_test, quarter_test, errno_test, locales_test):
4309         Invoke FUNC_CHECKED instead of FUNC.
4311 2024-02-08  Bruno Haible  <bruno@clisp.org>
4313         nstrtime: Fix %p, %P, %r directives' results on NetBSD, Solaris.
4314         * lib/strftime.c: Include <locale.h>, localename.h.
4315         (should_remove_ampm): New function.
4316         (__strftime_internal): On NetBSD and Solaris, remove the AM/PM indicator
4317         from the %p, %r directives' results in specific locales.
4318         * modules/nstrftime (Depends-on): Add localename.
4319         * tests/test-nstrftime.h (locales_test): Update the expected result of
4320         the %r directive.
4321         * doc/posix-functions/strftime.texi: Mention the problem of the %p and
4322         %r directives on NetBSD and Solaris.
4324 2024-02-08  Bruno Haible  <bruno@clisp.org>
4326         nstrtime, c-nstrftime: Fix %c directive's result on NetBSD, Solaris.
4327         * lib/strftime.c (__strftime_internal): On NetBSD and Solaris, remove
4328         the last word of the %c directive's result if it looks like a time zone.
4329         * doc/posix-functions/strftime.texi: Mention this as a restriction of
4330         strftime.
4332 2024-02-07  Bruno Haible  <bruno@clisp.org>
4334         c-nstrftime: Add tests.
4335         * tests/test-c-nstrftime.c: New file, based on tests/test-nstrftime.c.
4336         * tests/test-c-nstrftime-1.sh: New file, based on
4337         tests/test-nstrftime-1.sh.
4338         * tests/test-c-nstrftime-2.sh: New file, based on
4339         tests/test-nstrftime-2.sh.
4340         * modules/c-nstrftime-tests: New file.
4342         c-nstrftime: New module.
4343         Suggested by Paul Eggert.
4344         * lib/strftime.h (c_nstrftime): New declaration.
4345         * lib/c-nstrftime.c: New file.
4346         * lib/strftime.c (FPRINTFTIME): Move fallback definition before its
4347         first use.
4348         (USE_C_LOCALE): Add fallback definition.
4349         If USE_C_LOCALE is set, include c-ctype.h instead of <ctype.h>.
4350         Conditionally include <locale.h>.
4351         (TOUPPER, TOLOWER): Define differently if USE_C_LOCALE is set.
4352         (c_locale_cache, c_locale): New definitions, copied from lib/c-strtod.c.
4353         (c_weekday_names, c_month_names): New variables, based on
4354         glibc/time/strftime_l.c.
4355         (__strftime_internal): Define a_wkday, aw_len, f_wkday, a_month, am_len,
4356         f_month, ampm, ap_len differently for USE_C_LOCALE. Avoid a
4357         'goto underlying_strftime' if USE_C_LOCALE && !HAVE_STRFTIME_L. If
4358         USE_C_LOCALE, use strftime_l() with the C locale object instead of
4359         strftime().
4360         * m4/c-nstrftime.m4: New file, based on m4/nstrftime.m4.
4361         * modules/c-nstrftime: New file, based on modules/nstrftime.
4363 2024-02-07  Bruno Haible  <bruno@clisp.org>
4365         nstrftime: Add tests of all directives, also in non-trivial locales.
4366         * tests/test-nstrftime.h (language_t): New type.
4367         (locales_test): New function.
4368         * tests/test-nstrftime.c: Include <locale.h>, <stdlib.h>.
4369         (main): Invoke setlocale and locales_test.
4370         * tests/test-nstrftime-1.sh: New file.
4371         * tests/test-nstrftime-2.sh: New file, based on tests/test-strtod1.sh.
4372         * modules/nstrftime-tests (Files): Add them. Add m4/locale-fr.m4,
4373         m4/codeset.m4, m4/musl.m4.
4374         (configure.ac): Invoke gt_LOCALE_FR, gt_LOCALE_FR_UTF8, gl_MUSL_LIBC.
4375         (Makefile.am): Link test-nstrftime with $(SETLOCALE_LIB). Test
4376         test-nstrftime-*.sh instead of test-nstrftime.
4378 2024-02-07  Bruno Haible  <bruno@clisp.org>
4380         nstrftime: Work around strftime bug with %r on macOS and FreeBSD.
4381         * lib/strftime.c (__strftime_internal): For %r, don't use the underlying
4382         strftime() directly.
4383         * doc/posix-functions/strftime.texi: Mention the %r bug.
4385 2024-02-07  Paul Eggert  <eggert@cs.ucla.edu>
4387         Assume ‘long long’ support
4388         * modules/strtoimax, modules/strtoumax (Depends-on):
4389         Assume the compiler supports ‘long long’.
4390         This was overlooked in the 2019-12-22 patch
4391         <https://lists.gnu.org/r/bug-gnulib/2019-12/msg00190.html>.
4393 2024-02-07  Bruno Haible  <bruno@clisp.org>
4395         nstrftime: Fix typo in documentation.
4396         Reported by Tim Rice <tim@multitalents.net>.
4397         * lib/strftime.h (nstrftime): Fix typo in comment.
4399 2024-02-07  Bruno Haible  <bruno@clisp.org>
4401         nstrftime tests: Avoid test failures on DragonFly BSD.
4402         * tests/test-nstrftime.h (LT): Disable specific test cases also on
4403         DragonFly BSD.
4405 2024-02-07  Bruno Haible  <bruno@clisp.org>
4407         nstrftime: Modernize.
4408         * lib/strftime.c (__strftime_internal): Make the strftime fallback
4409         declaration ISO C 23 compliant.
4411 2024-02-07  Bruno Haible  <bruno@clisp.org>
4413         nstrftime tests: Avoid test failures on FreeBSD, NetBSD, Android.
4414         * tests/test-nstrftime.h (LT): Disable specific test cases on FreeBSD,
4415         NetBSD, Android.
4417 2024-02-07  Bruno Haible  <bruno@clisp.org>
4419         nstrftime tests: Allow reuse with another function.
4420         * tests/test-nstrftime.h: New file, extracted from
4421         tests/test-nstrftime.c.
4422         (FUNC_NAME, STRINGIFY): New macros.
4423         (posixtm_test, tzalloc_test, quarter_test, errno_test): Use FUNC or
4424         FUNC_NAME instead of nstrftime.
4425         (quarter_test): Rename local variable 'result' to 'fail'.
4426         * tests/test-nstrftime.c: Remove code that moved to test-nstrftime.h.
4427         Include test-nstrftime.h.
4428         (STREQ): Remove redundant macro.
4429         * modules/nstrftime-tests (Files): Add tests/test-nstrftime.h.
4431 2024-02-07  Bruno Haible  <bruno@clisp.org>
4433         nstrftime: Document the nstrftime function.
4434         * lib/strftime.h (nstrftime): Add more comments.
4436 2024-02-06  Bruno Haible  <bruno@clisp.org>
4438         nl_langinfo: Fix fallback list of month names (regression 2014-07-07).
4439         * lib/nl_langinfo.c (nl_langinfo): In the implementation for native
4440         Windows, fix the results for MON_8..MON_12, ALTMON_8..ALTMON_12,
4441         ABMON_8..ABMON_12.
4443 2024-02-06  Bruno Haible  <bruno@clisp.org>
4445         nstrftime: Merge glibc strftime changes.
4446         This incorporates:
4447         2023-02-07 Use 64-bit time_t interfaces in strftime and strptime
4448         * lib/strftime.c [_LIBC] (time_t, __gmtime_r, mktime): Define as macros.
4449         * config/srclist.txt: Update comment regarding glibc/time/strftime_l.c.
4451 2024-02-06  Bruno Haible  <bruno@clisp.org>
4453         nstrftime, fprintftime: Simplify.
4454         * lib/strftime.c: Renamed from lib/nstrftime.c.
4455         (my_strftime): Don't define here.
4456         * lib/nstrftime.c: New file.
4457         * lib/fprintftime.c (my_strftime): New macro.
4458         Include strftime.c, not nstrftime.c.
4459         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Don't define my_strftime in
4460         config.h.
4461         * modules/nstrftime (Files): Add lib/strftime.c.
4462         * modules/fprintftime (Files): Likewise.
4463         * config/srclist.txt: Update comment regarding glibc/time/strftime.c.
4465 2024-02-06  Bruno Haible  <bruno@clisp.org>
4467         Further improve cross-compilation for midipix.
4468         Reported by Ørjan Malde <red@foxi.me>.
4469         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Improve cross-compilation guess
4470         for midipix.
4472 2024-02-05  Paul Eggert  <eggert@cs.ucla.edu>
4474         ctime: improve doc
4475         * doc/posix-functions/asctime.texi (asctime):
4476         * doc/posix-functions/asctime_r.texi (asctime_r):
4477         * doc/posix-functions/ctime_r.texi (ctime_r):
4478         * doc/posix-functions/ctime.texi (ctime):
4479         Mention locale problem of strftime more consistently.  Improve
4480         wording.  For ctime and ctime_r, mention that localtime_r can
4481         fail.
4482         * doc/posix-functions/ctime.texi (ctime): Move history section
4483         to end and spiff up a bit.
4484         * doc/posix-functions/ctime_r.texi (ctime_r): Omit commentary that
4485         assumes traditional SunOS ctime_r API; it was confusing and not
4486         useful for Gnulib apps, which assume the POSIX API.
4488 2024-02-05  Bruno Haible  <bruno@clisp.org>
4490         Further improve cross-compilation for midipix.
4491         Based on patch by Ørjan Malde <red@foxi.me> from
4492         <https://lists.gnu.org/archive/html/bug-gnulib/2024-02/msg00004.html>.
4493         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Add cross-compilation guess for
4494         midipix.
4495         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
4496         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Likewise.
4497         * m4/utime.m4 (gl_FUNC_UTIME): Likewise.
4498         * m4/utimens.m4 (gl_UTIMENS): Likewise.
4499         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
4501 2024-02-05  Paul Eggert  <eggert@cs.ucla.edu>
4503         doc: Extend doc of *ctime functions.
4504         * doc/posix-functions/ctime.texi (ctime): Document why we got into
4505         this mess.
4506         * doc/posix-functions/asctime.texi (asctime):
4507         * doc/posix-functions/asctime_r.texi (asctime_r):
4508         * doc/posix-functions/ctime_r.texi (ctime_r):
4509         Refer to ctime’s buffer overflow doc.
4511 2024-02-05  Bruno Haible  <bruno@clisp.org>
4513         snippet/warn-on-use: Add comment.
4514         * lib/warn-on-use.h: Document a restriction of _GL_WARN_ON_USE.
4516 2024-02-03  Paul Eggert  <eggert@cs.ucla.edu>
4518         xalloc-oversized: omit unnecessary cast
4519         * lib/xalloc-oversized.h (__xalloc_oversized): Omit unnecessary
4520         cast of a positive in-range value to size_t.  This seems to be
4521         left over from an older version of the code.
4523         glob: port better to C23
4524         * lib/glob.c: Include <stdckdint.h>.
4525         (size_add_wrapv): Remove.  All uses replaced by ckd_add.
4526         * modules/glob: Depend on stdckdint.
4528         ctime: fix false positive
4529         Problem reported by Bjarni Ingi Gislason in:
4530         https://lists.gnu.org/r/bug-gnulib/2024-02/msg00006.html
4531         * lib/time.in.h (ctime): Do not warn about ctime portability,
4532         as there is a more serious warning about it crashing,
4533         and the two warning directives can cause false alarms.
4535 2024-01-31  Bruno Haible  <bruno@clisp.org>
4537         Implement 3 new properties, added by Unicode 15.1.0.
4538         * lib/gen-uni-tables.c (is_property_id_compat_math_start,
4539         is_property_id_compat_math_continue, is_property_ids_unary_operator):
4540         New functions.
4541         (output_properties): Output also the properties id_compat_math_start,
4542         id_compat_math_continue, ids_unary_operator.
4543         * lib/unictype.in.h (UC_PROPERTY_ID_COMPAT_MATH_START,
4544         UC_PROPERTY_ID_COMPAT_MATH_CONTINUE, UC_PROPERTY_IDS_UNARY_OPERATOR,
4545         uc_is_property_id_compat_math_start,
4546         uc_is_property_id_compat_math_continue,
4547         uc_is_property_ids_unary_operator): New declarations.
4548         * m4/unictype_h.m4 (gl_UNICTYPE_H_REQUIRE_DEFAULTS): Initialize
4549         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_START_DLL_VARIABLE,
4550         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_CONTINUE_DLL_VARIABLE,
4551         GNULIB_UNICTYPE_PROPERTY_IDS_UNARY_OPERATOR_DLL_VARIABLE.
4552         * modules/unictype/base (Makefile.am): Substitute
4553         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_START_DLL_VARIABLE,
4554         GNULIB_UNICTYPE_PROPERTY_ID_COMPAT_MATH_CONTINUE_DLL_VARIABLE,
4555         GNULIB_UNICTYPE_PROPERTY_IDS_UNARY_OPERATOR_DLL_VARIABLE.
4556         * lib/unictype/pr_id_compat_math_continue.c: New file.
4557         * lib/unictype/pr_id_compat_math_continue.h: New generated file.
4558         * lib/unictype/pr_id_compat_math_start.c: New file.
4559         * lib/unictype/pr_id_compat_math_start.h: New generated file.
4560         * lib/unictype/pr_ids_unary_operator.c: New file.
4561         * modules/unictype/property-id-compat-math-continue: New file.
4562         * modules/unictype/property-id-compat-math-start: New file.
4563         * modules/unictype/property-ids-unary-operator: New file.
4564         * tests/unictype/test-pr_id_compat_math_continue.c: New generated file.
4565         * tests/unictype/test-pr_id_compat_math_start.c: New generated file.
4566         * tests/unictype/test-pr_ids_unary_operator.c: New generated file.
4567         * modules/unictype/property-id-compat-math-continue-tests: New file.
4568         * modules/unictype/property-id-compat-math-start-tests: New file.
4569         * modules/unictype/property-ids-unary-operator-tests: New file.
4570         * lib/unictype/pr_byname.gperf: Add id_compat_math_start,
4571         id_compat_math_continue, ids_unary_operator.
4572         * lib/unictype/pr_byname.c (UC_PROPERTY_INDEX_ID_COMPAT_MATH_START,
4573         UC_PROPERTY_INDEX_ID_COMPAT_MATH_CONTINUE,
4574         UC_PROPERTY_INDEX_IDS_UNARY_OPERATOR): New enum items.
4575         (uc_property_byname): Handle them.
4576         * modules/unictype/property-byname (Depends-on): Add
4577         unictype/property-id-compat-math-continue,
4578         unictype/property-id-compat-math-start,
4579         unictype/property-ids-unary-operator.
4580         * modules/unictype/property-all (Depends-on): Likewise.
4581         * MODULES.html.sh (func_all_modules): Add
4582         unictype/property-id-compat-math-continue,
4583         unictype/property-id-compat-math-start,
4584         unictype/property-ids-unary-operator.
4586 2024-01-30  Bruno Haible  <bruno@clisp.org>
4588         Update to Unicode 15.1.0.
4590         * lib/gen-uni-tables.c (PROP_SENTENCE_TERMINAL): Renamed from
4591         PROP_STERM.
4592         (PROP_IDS_UNARY_OPERATOR, PROP_ID_COMPAT_MATH_CONTINUE,
4593         PROP_ID_COMPAT_MATH_START): New enum items.
4594         (UC_INDIC_CONJUNCT_BREAK_*): New enum items.
4595         (unicode_indic_conjunct_break): New variable.
4596         (fill_properties): Rename local variable propvalue to propcode. Handle
4597         the properties IDS_Unary_Operator, ID_Compat_Math_Continue,
4598         ID_Compat_Math_Start. Parse the InCB values from file
4599         DerivedCoreProperties.txt.
4600         (indic_conjunct_break_as_c_identifier,
4601         output_indic_conjunct_break_test): New functions.
4602         (indic_conjunct_break_table): New variable.
4603         (output_indic_conjunct_break): New function.
4604         (fill_width): Accept spaces at the end of field0 and at the start and
4605         end of field1.
4606         (LBP_QU1, LBP_QU2, LBP_QU3): New enum items, for Unicode TR #14 rules
4607         (LB15a) and (LB15b).
4608         (LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF): New enum items, for Brahmic
4609         scripts.
4610         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
4611         (debug_output_lbp): Print either LBP_QU1 or LBP_QU2 or LBP_QU3 as
4612         LBP_QU. Handle LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
4613         (fill_org_lbp): Accept spaces at the end of field0 and at the start and
4614         end of field1. Recognize LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
4615         (debug_output_org_lbp): Handle LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
4616         (lbp_value_to_string): Handle LBP_QU1, LBP_QU2, LBP_QU3 instead of
4617         LBP_QU. Handle LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF.
4618         (output_lbrk_rules_as_tables): Treat LBP_QU as macro that maps to three
4619         table rows/columns. Replace rule (LB15) with rules (LB15b) and (LB15a).
4620         (get_wbp): Update such that uniwbrk/wbrkprop.txt comes out as expected.
4621         (main): Invoke output_indic_conjunct_break_test and
4622         output_indic_conjunct_break.
4624         * All generated files under lib/uni* and tests/uni*: Regenerate.
4625         * tests/uniname/NameAliases.txt: Update.
4626         * tests/uniname/UnicodeData.txt: Update.
4627         * tests/uninorm/NormalizationTest.txt: Update.
4628         * tests/unigbrk/GraphemeBreakTest.txt: Update.
4629         * tests/uniwbrk/WordBreakTest.txt: Update.
4631         * lib/unilbrk/lbrktables.h (LBP_QU1, LBP_QU2, LBP_QU3): New enum items,
4632         for Unicode TR #14 rules (LB15a) and (LB15b).
4633         (LBP_QU): Remove enum item.
4634         (LBP_AP, LBP_AK, LBP_AS, LBP_VI, LBP_VF): New enum items, for Brahmic
4635         scripts.
4636         (unilbrk_table): Update array bounds.
4637         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks_loop):
4638         Conditionally replace LBP_QU2 with LBP_QU1, for rule (LB15a).
4639         Conditionally replace LBP_QU3 with LBP_QU1, for rule (LB15b).
4640         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks_loop):
4641         Likewise.
4642         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks_loop):
4643         Likewise.
4645         * lib/unictype.in.h (UC_INDIC_CONJUNCT_BREAK_*): New enum values.
4646         (uc_indic_conjunct_break_name, uc_indic_conjunct_break_byname,
4647         uc_indic_conjunct_break): New declarations.
4648         * lib/unictype/incb_byname.c: New file.
4649         * lib/unictype/incb_byname.gperf: New file.
4650         * lib/unictype/incb_name.c: New file.
4651         * lib/unictype/incb_name.h: New file.
4652         * lib/unictype/incb_of.c: New file.
4653         * lib/unictype/incb_of.h: New generated file.
4654         * modules/unictype/incb-all: New file.
4655         * modules/unictype/incb-byname: New file.
4656         * modules/unictype/incb-name: New file.
4657         * modules/unictype/incb-of: New file.
4658         * tests/unictype/test-incb_byname.c: New file.
4659         * tests/unictype/test-incb_name.c: New file.
4660         * tests/unictype/test-incb_of.c: New file.
4661         * tests/unictype/test-incb_of.h: New generated file.
4662         * modules/unictype/incb-byname-tests: New file.
4663         * modules/unictype/incb-name-tests: New file.
4664         * modules/unictype/incb-of-tests: New file.
4666         * lib/unigbrk.in.h (uc_is_grapheme_break, u*_grapheme_next,
4667         u*_grapheme_prev): Add comments.
4668         * lib/unigbrk/u-grapheme-breaks.h (FUNC): Add local variables
4669         incb_consonant_extended, incb_consonant_extended_linker,
4670         incb_consonant_extended_linker_extended. Implement rule (GB9c).
4671         * modules/unigbrk/u8-grapheme-breaks (Depends-on): Add unictype/incb-of.
4672         * modules/unigbrk/u16-grapheme-breaks (Depends-on): Likewise.
4673         * modules/unigbrk/u32-grapheme-breaks (Depends-on): Likewise.
4674         * modules/unigbrk/uc-grapheme-breaks (Depends-on): Likewise.
4675         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Add local variables
4676         incb_consonant_extended, incb_consonant_extended_linker,
4677         incb_consonant_extended_linker_extended. Skip test cases that match rule
4678         (GB9c).
4679         * modules/unigbrk/uc-is-grapheme-break-tests (Depends-on): Add
4680         unictype/incb-of.
4682         * All the affected modules: Bump required libunistring version.
4684 2024-01-30  Bruno Haible  <bruno@clisp.org>
4686         unigbrk/uc-is-grapheme-break tests: Reduce verbosity.
4687         * tests/unigbrk/test-uc-is-grapheme-break.c
4688         (graphemebreakproperty_to_string): Don't print gbp to stdout.
4690 2024-01-30  Bruno Haible  <bruno@clisp.org>
4692         gen-uni-tables: Update copyright year in output.
4693         * lib/gen-uni-tables.c (output_predicate_test, output_predicate,
4694         output_category, output_combclass, output_bidi_category,
4695         output_decimal_digit_test, output_decimal_digit, output_digit_test,
4696         output_digit, output_numeric_test, output_numeric, output_mirror,
4697         output_joining_type_test, output_joining_type,
4698         output_joining_group_test, output_joining_group, output_scripts,
4699         output_scripts_byname, output_blocks, output_ident_category,
4700         output_nonspacing_property, output_lbrk_tables,
4701         output_lbrk_rules_as_tables, output_wbrk_tables, output_gbp_test,
4702         output_gbp_table, output_decomposition_tables,
4703         output_composition_tables, output_simple_mapping_test,
4704         output_simple_mapping, output_casing_rules): Bump copyright year in
4705         output.
4706         * lib/uniname/gen-uninames.lisp (main): Likewise.
4708 2024-01-30  Bruno Haible  <bruno@clisp.org>
4710         gen-uni-tables: Refactor, based on UAX #14 version 49.
4711         * lib/gen-uni-tables.c (get_lbp): Reorder, based on
4712         <https://www.unicode.org/reports/tr14/tr14-49.html#DescriptionOfProperties>.
4713         For LBP_EB, use the "emoji modifier base" property.
4715 2024-01-30  Bruno Haible  <bruno@clisp.org>
4717         unigbrk tests: Tweak error reporting.
4718         * tests/unigbrk/test-ulc-grapheme-breaks.c (main): Print byte values in
4719         upper-case hexadecimal.
4720         * tests/unigbrk/test-u8-grapheme-breaks.c (test_u8_grapheme_breaks):
4721         Print unit values in upper-case hexadecimal.
4722         * tests/unigbrk/test-u16-grapheme-breaks.c (test_u16_grapheme_breaks):
4723         Print unit values with at least 4 hexadecimal digits.
4724         * tests/unigbrk/test-u32-grapheme-breaks.c (test_u32_grapheme_breaks):
4725         Likewise.
4726         * tests/unigbrk/test-uc-grapheme-breaks.c (test_uc_grapheme_breaks):
4727         Print characters with at least 4 hexadecimal digits.
4729 2024-01-30  Bruno Haible  <bruno@clisp.org>
4731         Update copyright year in tests/unictype/*.
4732         * tests/unictype/*: Bump copyright years range to include 2024.
4733         * Makefile (update-copyright): Don't exclude the tests/unictype
4734         directory.
4736 2024-01-29  Patrice Dumas  <pertusus@free.fr>
4738         gendocs: get only targetted manual source and includes, when possible
4739         * build-aux/gendocs.sh: if makeinfo, based on version, has the
4740         --trace-includes option, gather only the targetted manual srcfile and
4741         the included files obtained with makeinfo --trace-includes. In that
4742         case output include files to tar stdin and use -T-. Bruno Haible for
4743         the version comparison and use of tar.
4745 2024-01-29  Bruno Haible  <bruno@clisp.org>
4747         Port FALLTHROUGH to Mac OS X 10.9.
4748         Report and fix by Ryan Carsten Schmidt <gnulib@ryandesign.com>
4749         at <https://savannah.gnu.org/bugs/?63866>.
4750         * m4/gnulib-common.m4 (gl_COMMON_BODY): For _GL_HAS_ATTRIBUTE, don't use
4751         __has_attribute for Apple clang versions < 7000000.
4752         * lib/cdefs.h (__glibc_has_attribute): Don't use __has_attribute for
4753         Apple clang versions < 7000000.
4755 2024-01-29  Bruno Haible  <bruno@clisp.org>
4757         libc-config: Apply lesson learned on 2023-01-13.
4758         * lib/cdefs.h (__glibc_has_attribute): On non-Apple platforms, don't
4759         use __has_attribute for clang versions < 5.0.
4761 2024-01-28  Bruno Haible  <bruno@clisp.org>
4763         host-cpu-c-abi: Let gl_HOST_CPU_C_ABI_32BIT never return 'unknown'.
4764         Reported by Mohammad-Reza Nabipoor <mnabipoor@gnu.org>.
4765         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): Use the list of
4766         always-32-bit CPUs and the list of always-64-bit CPUs also when
4767         gl_HOST_CPU_C_ABI has already been run. As a fallback, use a test of
4768         'sizeof (void *)' to always return 'yes' or 'no', never 'unknown'.
4770 2024-01-27  Paul Eggert  <eggert@cs.ucla.edu>
4772         gendocs: allow other chars in source file names
4773         * build-aux/gendocs.sh: Generalize to also allow leading ‘-’
4774         and newlines (!) in source file names.  Exit if there
4775         is an error creating the tarball.
4777 2024-01-27  Patrice Dumas  <pertusus@free.fr>
4779         gendocs: allow spaces, metacharacters and quotes in source file names
4780         * build-aux/gendocs.sh: output files to tar stdin and use -T- to allow
4781         spaces, metacharacters and quotes in file names.  Bruno Haible
4782         solution.
4784 2024-01-27  Patrice Dumas  <pertusus@free.fr>
4786         gendocs: fix --no-html
4787         * build-aux/gendocs.sh: fix typo in variable name set by --no-html.
4789 2024-01-25  Bruno Haible  <bruno@clisp.org>
4791         execute tests: Avoid test failure on macOS 14.
4792         Reported by Guangyu Li <gl343@cornell.edu> in
4793         <https://lists.gnu.org/archive/html/bug-gettext/2024-01/msg00006.html>.
4794         * tests/test-execute-main.c (main): In the tests 17, 18, 19, 20, use the
4795         file descriptors 15, 16 instead of 10, 11, respectively.
4796         * tests/test-execute-child.c (main): Likewise.
4798 2024-01-25  Bruno Haible  <bruno@clisp.org>
4800         Resolve conflicts for functions introduced in Android API level 35.
4802         * lib/time.in.h (timespec_getres): Consider REPLACE_TIMESPEC_GETRES.
4803         * m4/time_h.m4 (gl_TIME_H_DEFAULTS): Initialize REPLACE_TIMESPEC_GETRES.
4804         * modules/time-h (Makefile.am): Substitute REPLACE_TIMESPEC_GETRES.
4805         * m4/timespec_getres.m4 (gl_FUNC_TIMESPEC_GETRES): Test for
4806         timespec_getres using gl_CHECK_FUNCS_ANDROID instead of
4807         AC_CHECK_FUNCS_ONCE. Conditionally set REPLACE_TIMESPEC_GETRES.
4808         * modules/timespec_getres (Depends-on, configure.ac): Consider
4809         REPLACE_TIMESPEC_GETRES.
4810         * m4/gettime.m4 (gl_GETTIME_RES): Test for timespec_getres using
4811         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
4812         * doc/posix-functions/timespec_getres.texi: Mention the Android API
4813         levels.
4815 2024-01-25  Bruno Haible  <bruno@clisp.org>
4817         Resolve conflicts for functions introduced in Android API level 34.
4819         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE): On platforms without
4820         glibc, test for copy_file_range using gl_CHECK_FUNCS_ANDROID instead of
4821         AC_CHECK_FUNCS_ONCE. Conditionally set REPLACE_COPY_FILE_RANGE.
4822         * doc/glibc-functions/copy_file_range.texi: Mention the Android API
4823         levels.
4825         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test for
4826         posix_spawn_file_actions_addchdir_np and
4827         posix_spawn_file_actions_addfchdir_np using gl_CHECK_FUNCS_ANDROID
4828         instead of AC_CHECK_FUNCS_ONCE.
4829         * m4/posix_spawn_faction_addchdir.m4
4830         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR): Test for
4831         posix_spawn_file_actions_addchdir_np using gl_CHECK_FUNCS_ANDROID
4832         instead of AC_CHECK_FUNCS_ONCE.
4833         * m4/posix_spawn_faction_addfchdir.m4
4834         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR): Test for
4835         posix_spawn_file_actions_addfchdir_np using gl_CHECK_FUNCS_ANDROID
4836         instead of AC_CHECK_FUNCS_ONCE.
4837         * doc/glibc-functions/posix_spawn_file_actions_addchdir_np.texi: Mention
4838         the Android API levels.
4839         * doc/glibc-functions/posix_spawn_file_actions_addfchdir_np.texi:
4840         Likewise.
4842         * lib/string.in.h (memset_explicit): Consider REPLACE_MEMSET_EXPLICIT.
4843         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize
4844         REPLACE_MEMSET_EXPLICIT.
4845         * modules/string (Makefile.am): Substitute REPLACE_MEMSET_EXPLICIT.
4846         * m4/memset_explicit.m4 (gl_FUNC_MEMSET_EXPLICIT): Test for
4847         memset_explicit using gl_CHECK_FUNCS_ANDROID instead of
4848         AC_CHECK_FUNCS_ONCE. Conditionally set REPLACE_MEMSET_EXPLICIT.
4849         * modules/memset_explicit (configure.ac): Consider
4850         REPLACE_MEMSET_EXPLICIT.
4851         * doc/posix-functions/memset_explicit.texi: Mention the Android API
4852         levels.
4854         * m4/freadahead.m4 (gl_FUNC_FREADAHEAD): Test for __freadahead using
4855         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
4856         * lib/freadahead.h: Update comment.
4858 2024-01-25  Bruno Haible  <bruno@clisp.org>
4860         Doc regarding functions introduced in Android API level 33.
4861         * doc/glibc-functions/backtrace.texi: Mention the Android API levels.
4862         * doc/glibc-functions/backtrace_symbols.texi: Likewise.
4863         * doc/glibc-functions/backtrace_symbols_fd.texi: Likewise.
4864         * doc/glibc-functions/preadv2.texi: Likewise.
4865         * doc/glibc-functions/pwritev2.texi: Likewise.
4867 2024-01-25  Bruno Haible  <bruno@clisp.org>
4869         Resolve conflicts for functions introduced in Android API level 30.
4871         * doc/glibc-functions/memfd_create.texi: Mention the Android API levels.
4872         * doc/glibc-functions/mlock2.texi: Likewise.
4873         * doc/glibc-functions/pthread_cond_clockwait.texi: Likewise.
4874         * doc/glibc-functions/pthread_mutex_clocklock.texi: Likewise.
4875         * doc/glibc-functions/pthread_rwlock_clockrdlock.texi: Likewise.
4876         * doc/glibc-functions/pthread_rwlock_clockwrlock.texi: Likewise.
4877         * doc/glibc-functions/renameat2.texi: Likewise.
4878         * doc/glibc-functions/sem_clockwait.texi: Likewise.
4879         * doc/glibc-functions/statx.texi: Likewise.
4881         * lib/threads.in.h (thrd_sleep): Consider REPLACE_THRD_SLEEP.
4882         (thrd_yield): Consider REPLACE_THRD_YIELD.
4883         (mtx_init): Consider REPLACE_MTX_INIT.
4884         (mtx_lock): Consider REPLACE_MTX_LOCK.
4885         (mtx_trylock): Consider REPLACE_MTX_TRYLOCK.
4886         (mtx_timedlock): Consider REPLACE_MTX_TIMEDLOCK.
4887         (mtx_unlock): Consider REPLACE_MTX_UNLOCK.
4888         (mtx_destroy): Consider REPLACE_MTX_DESTROY.
4889         (call_once): Consider REPLACE_CALL_ONCE. Fix warning message.
4890         (cnd_init): Consider REPLACE_CND_INIT.
4891         (cnd_wait): Consider REPLACE_CND_WAIT.
4892         (cnd_timedwait): Consider REPLACE_CND_TIMEDWAIT.
4893         (cnd_signal): Consider REPLACE_CND_SIGNAL.
4894         (cnd_broadcast): Consider REPLACE_CND_BROADCAST.
4895         (cnd_destroy): Consider REPLACE_CND_DESTROY.
4896         (tss_create): Consider REPLACE_TSS_CREATE.
4897         (tss_set): Consider REPLACE_TSS_SET.
4898         (tss_get): Consider REPLACE_TSS_GET.
4899         (tss_delete): Consider REPLACE_TSS_DELETE.
4900         * m4/threads_h.m4 (gl_THREADS_H_DEFAULTS): Initialize REPLACE_CALL_ONCE,
4901         REPLACE_CND_BROADCAST, REPLACE_CND_DESTROY, REPLACE_CND_INIT,
4902         REPLACE_CND_SIGNAL, REPLACE_CND_TIMEDWAIT, REPLACE_CND_WAIT,
4903         REPLACE_MTX_DESTROY, REPLACE_MTX_INIT, REPLACE_MTX_LOCK,
4904         REPLACE_MTX_TIMEDLOCK, REPLACE_MTX_TRYLOCK, REPLACE_MTX_UNLOCK,
4905         REPLACE_THRD_SLEEP, REPLACE_THRD_YIELD, REPLACE_TSS_CREATE,
4906         REPLACE_TSS_DELETE, REPLACE_TSS_GET, REPLACE_TSS_SET.
4907         * modules/threads-h (Makefile.am): Substitute REPLACE_CALL_ONCE,
4908         REPLACE_CND_BROADCAST, REPLACE_CND_DESTROY, REPLACE_CND_INIT,
4909         REPLACE_CND_SIGNAL, REPLACE_CND_TIMEDWAIT, REPLACE_CND_WAIT,
4910         REPLACE_MTX_DESTROY, REPLACE_MTX_INIT, REPLACE_MTX_LOCK,
4911         REPLACE_MTX_TIMEDLOCK, REPLACE_MTX_TRYLOCK, REPLACE_MTX_UNLOCK,
4912         REPLACE_THRD_SLEEP, REPLACE_THRD_YIELD, REPLACE_TSS_CREATE,
4913         REPLACE_TSS_DELETE, REPLACE_TSS_GET, REPLACE_TSS_SET.
4914         * m4/thrd.m4 (gl_FUNC_THRD_CREATE): New macro.
4915         * modules/thrd (configure.ac): Invoke gl_FUNC_THRD_CREATE.
4916         * m4/call_once.m4: New file.
4917         * modules/call_once (Files): Add m4/call_once.m4.
4918         (configure.ac): Invoke gl_FUNC_CALL_ONCE. Consider REPLACE_CALL_ONCE.
4919         * m4/cnd.m4: New file.
4920         * modules/cnd (Files): Add m4/cnd.m4.
4921         (configure.ac): Invoke gl_FUNC_CND_INIT. Consider REPLACE_CND_INIT.
4922         * m4/mtx.m4: New file.
4923         * modules/mtx (Files): Add m4/mtx.m4.
4924         (configure.ac): Invoke gl_FUNC_MTX_INIT. Consider REPLACE_MTX_INIT.
4925         * m4/tss.m4: New file.
4926         * modules/tss (Files): Add m4/tss.m4.
4927         (configure.ac): Invoke gl_FUNC_TSS_CREATE. Consider REPLACE_TSS_CREATE.
4928         * doc/posix-functions/call_once.texi: Mention the Android API levels.
4929         * doc/posix-functions/cnd_broadcast.texi: Likewise.
4930         * doc/posix-functions/cnd_destroy.texi: Likewise.
4931         * doc/posix-functions/cnd_init.texi: Likewise.
4932         * doc/posix-functions/cnd_signal.texi: Likewise.
4933         * doc/posix-functions/cnd_timedwait.texi: Likewise.
4934         * doc/posix-functions/cnd_wait.texi: Likewise.
4935         * doc/posix-functions/mtx_destroy.texi: Likewise.
4936         * doc/posix-functions/mtx_init.texi: Likewise.
4937         * doc/posix-functions/mtx_lock.texi: Likewise.
4938         * doc/posix-functions/mtx_timedlock.texi: Likewise.
4939         * doc/posix-functions/mtx_trylock.texi: Likewise.
4940         * doc/posix-functions/mtx_unlock.texi: Likewise.
4941         * doc/posix-functions/thrd_create.texi: Likewise.
4942         * doc/posix-functions/thrd_current.texi: Likewise.
4943         * doc/posix-functions/thrd_detach.texi: Likewise.
4944         * doc/posix-functions/thrd_equal.texi: Likewise.
4945         * doc/posix-functions/thrd_exit.texi: Likewise.
4946         * doc/posix-functions/thrd_join.texi: Likewise.
4947         * doc/posix-functions/thrd_sleep.texi: Likewise.
4948         * doc/posix-functions/thrd_yield.texi: Likewise.
4949         * doc/posix-functions/tss_create.texi: Likewise.
4950         * doc/posix-functions/tss_delete.texi: Likewise.
4951         * doc/posix-functions/tss_get.texi: Likewise.
4952         * doc/posix-functions/tss_set.texi: Likewise.
4954 2024-01-21  Bruno Haible  <bruno@clisp.org>
4956         readutmp, boot-time: Port to Android NDK r26.
4957         Reported by Po Lu <luangruo@yahoo.com> in
4958         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00063.html>.
4959         * lib/readutmp.h: Update comments.
4960         (UTMP_NAME_FUNCTION): Define as a no-op for Android with HAVE_UTMPX_H.
4962 2024-01-21  Bruno Haible  <bruno@clisp.org>
4964         asyncsafe-spin: Fix link error on various platforms.
4965         * m4/atomic-cas.m4: New file.
4966         * lib/asyncsafe-spin.c: Test HAVE_ATOMIC_COMPARE_AND_SWAP_GCC41 instead
4967         of a condition that considers only __sparc__, __ANDROID__, __ibmxl__.
4968         * lib/pthread-spin.c: Likewise.
4969         * lib/simple-atomic.c: Likewise.
4970         * modules/asyncsafe-spin (Files): Add m4/atomic-cas.m4.
4971         (configure.ac): Require gl_ATOMIC_COMPARE_AND_SWAP.
4972         * modules/pthread-spin: Likewise.
4973         * modules/simple-atomic: Likewise.
4975 2024-01-19  Bruno Haible  <bruno@clisp.org>
4977         fenv-environment: Fix for NetBSD/powerpc.
4978         * m4/fenv-environment.m4 (gl_FENV_ENVIRONMENT): For feupdateenv, use
4979         the same configure test on NetBSD/powerpc as on glibc/hppa.
4980         * doc/posix-functions/feupdateenv.texi: Mention the NetBSD/powerpc bug.
4982         fenv-exceptions-trapping: Avoid a test failure on *BSD/powerpc*.
4983         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests also on
4984         FreeBSD/powerpc* and NetBSD/powerpc*.
4986         fenv-exceptions-state-c99: Fix for FreeBSD/powerpc64 and NetBSD/powerpc.
4987         * m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): On
4988         FreeBSD/powerpc64 and NetBSD/powerpc, set REPLACE_FESETEXCEPTFLAG.
4989         * doc/posix-functions/fesetexceptflag.texi: Mention the FreeBSD and
4990         NetBSD bug.
4992         fenv-*: Avoid test failures on FreeBSD/powerpc64 and NetBSD/powerpc.
4993         On these platforms, FE_ALL_EXCEPT contains additional bits.
4994         * tests/test-fenv-except-tracking-1.c (FE_VXSOFT, FE_VXZDZ): Define
4995         fallbacks.
4996         (main): Allow fetestexcept(FE_ALL_EXCEPT) to contain FE_VXSOFT or
4997         FE_VXZDZ in addition to FE_INVALID.
4998         * tests/test-fenv-except-tracking-4.c (FE_VXSOFT): Define fallback.
4999         (main): Allow fetestexcept(FE_ALL_EXCEPT) to contain FE_VXSOFT in
5000         addition to FE_INVALID.
5001         * tests/test-fenv-env-2.c: Likewise.
5002         * tests/test-fenv-env-3.c: Likewise.
5003         * tests/test-fenv-env-4.c: Likewise.
5004         * tests/test-fenv-env-5.c: Likewise.
5006 2024-01-19  Bruno Haible  <bruno@clisp.org>
5008         fenv-*: Fix test failures on NetBSD 9.3/arm64.
5009         * m4/fenv-exceptions-trapping.m4 (gl_FENV_EXCEPTIONS_TRAPPING): Override
5010         feenableexcept() also on NetBSD/arm64.
5011         * doc/glibc-functions/feenableexcept.texi: Update platforms list.
5013 2024-01-19  Bruno Haible  <bruno@clisp.org>
5015         fenv-*: Avoid test failures on OpenBSD/sparc64.
5016         * tests/test-fenv-except-tracking-2.c (main): On OpenBSD/sparc64, skip
5017         the 'long double' test.
5018         * tests/test-fenv-except-trapping-2.c (main): Skip the 'long double'
5019         tests also on OpenBSD/sparc64.
5021 2024-01-18  Bruno Haible  <bruno@clisp.org>
5023         fenv-rounding: Avoid a test failure on OpenBSD/arm64.
5024         * tests/test-fenv-round.c (test_towardzero, test_upward, test_downward):
5025         Skip the 'long double' tests on OpenBSD/arm64.
5026         * doc/posix-functions/fesetround.texi: Update platforms list.
5028 2024-01-18  Bruno Haible  <bruno@clisp.org>
5030         Avoid test failures in FreeBSD's GB18030 locale.
5031         The FreeBSD 14.0 iconv converter (GB18030 → UTF-8) cannot convert e.g.
5032         0x94 0x32 0xBB 0x34 to U+1D100.
5033         * tests/test-c32isalnum.c (main): Skip the GB18030 locale tests on
5034         FreeBSD, if GL_CHAR32_T_IS_UNICODE (or, equivalently,
5035         GL_CHAR32_T_VS_WCHAR_T_NEEDS_CONVERSION) is defined.
5036         * tests/test-c32isalpha.c (main): Likewise.
5037         * tests/test-c32isblank.c (main): Likewise.
5038         * tests/test-c32iscntrl.c (main): Likewise.
5039         * tests/test-c32isdigit.c (main): Likewise.
5040         * tests/test-c32islower.c (main): Likewise.
5041         * tests/test-c32ispunct.c (main): Likewise.
5042         * tests/test-c32isspace.c (main): Likewise.
5043         * tests/test-c32isupper.c (main): Likewise.
5044         * tests/test-c32isxdigit.c (main): Likewise.
5045         * tests/test-c32rtomb.c (main): Likewise.
5046         * tests/test-c32snrtombs.c (main): Likewise.
5047         * tests/test-c32srtombs.c (main): Likewise.
5048         * tests/test-c32stombs.c (main): Likewise.
5049         * tests/test-c32tolower.c (main): Likewise.
5050         * tests/test-c32toupper.c (main): Likewise.
5051         * tests/test-mbrtoc16.c (main): Likewise.
5052         * tests/test-mbrtoc32.c (main): Likewise.
5053         * tests/test-mbsnrtoc32s.c (main): Likewise.
5054         * tests/test-mbsrtoc32s.c (main): Likewise.
5055         * tests/test-mbstoc32s.c (main): Likewise.
5057 2024-01-18  Bruno Haible  <bruno@clisp.org>
5059         get-rusage-data: Avoid test failure on NetBSD 9.3.
5060         * tests/test-get-rusage-data.c (main): Don't expect a strict increase on
5061         NetBSD systems.
5063 2024-01-18  Bruno Haible  <bruno@clisp.org>
5065         log10l: Work around bug on NetBSD 9.3/arm64.
5066         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Add another test case, taken from
5067         the unit test.
5069 2024-01-18  Bruno Haible  <bruno@clisp.org>
5071         doc: Update regarding <math.h> *l functions on NetBSD 9.3.
5072         * doc/posix-functions/acoshl.texi: Mention the buggy implementation on
5073         NetBSD.
5074         * doc/posix-functions/acosl.texi: Likewise.
5075         * doc/posix-functions/asinhl.texi: Likewise.
5076         * doc/posix-functions/asinl.texi: Likewise.
5077         * doc/posix-functions/atan2l.texi: Likewise.
5078         * doc/posix-functions/atanhl.texi: Likewise.
5079         * doc/posix-functions/atanl.texi: Likewise.
5080         * doc/posix-functions/coshl.texi: Likewise.
5081         * doc/posix-functions/cosl.texi: Likewise.
5082         * doc/posix-functions/erfcl.texi: Likewise.
5083         * doc/posix-functions/erfl.texi: Likewise.
5084         * doc/posix-functions/powl.texi: Likewise.
5085         * doc/posix-functions/sinhl.texi: Likewise.
5086         * doc/posix-functions/sinl.texi: Likewise.
5087         * doc/posix-functions/tanhl.texi: Likewise.
5088         * doc/posix-functions/tanl.texi: Likewise.
5089         * doc/posix-functions/expl.texi: Update NetBSD version info.
5090         * doc/posix-functions/exp2l.texi: Likewise.
5091         * doc/posix-functions/hypotl.texi: Likewise.
5092         * doc/posix-functions/logl.texi: Likewise.
5093         * doc/posix-functions/log10l.texi: Likewise.
5094         * m4/expl.m4 (gl_FUNC_EXPL): Update comments.
5095         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
5096         * m4/hypotl.m4 (gl_FUNC_HYPOTL_WORKS): Likewise.
5097         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
5098         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Likewise.
5100 2024-01-18  Bruno Haible  <bruno@clisp.org>
5102         modfl: Work around bug on NetBSD 9.3/arm64.
5103         * m4/modfl.m4 (gl_FUNC_MODFL): Add test whether modfl basically works.
5104         * doc/posix-functions/modfl.texi: Mention the NetBSD bug.
5106 2024-01-18  Bruno Haible  <bruno@clisp.org>
5108         isnanl: Avoid autoconf warning.
5109         * m4/isnanl.m4 (gl_FUNC_ISNANL): Declare through AC_DEFUN_ONCE.
5111 2024-01-18  Bruno Haible  <bruno@clisp.org>
5113         fmaf, fma, fmal: Work around bugs on OpenBSD 7.4/arm64.
5114         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Use a volatile function pointer
5115         variable to disable clang's inlining.
5116         * m4/fma.m4 (gl_FUNC_FMA_WORKS): Likewise.
5117         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Likewise.
5118         * doc/posix-functions/fmaf.texi: Mention the OpenBSD bug.
5119         * doc/posix-functions/fma.texi: Likewise.
5120         * doc/posix-functions/fmal.texi: Likewise.
5122 2024-01-18  Bruno Haible  <bruno@clisp.org>
5124         doc: Update regarding stable branches.
5125         * doc/gnulib-readme.texi (Stable Branches): Mention new branch
5126         stable-202401. Mention that stable-202301 is no longer updated.
5128 2024-01-17  Bruno Haible  <bruno@clisp.org>
5130         getopt-gnu: Fix out-of-bounds access (regression 2023-12-11).
5131         * lib/getopt.c (process_long_option): Don't set ambig_set[option_index]
5132         if ambig_set is &ambig_fallback.
5134 2024-01-17  Bruno Haible  <bruno@clisp.org>
5136         Improve naming of local variables.
5137         * gnulib-tool, posix-modules, build-aux/relocatable.sh.in,
5138         build-aux/reloc-ldflags, build-aux/install-reloc, tests/init.sh,
5139         m4/argz.m4: Rename save_IFS to saved_IFS.
5140         * m4/*.m4: Rename save_LIBS to saved_LIBS.
5141         * m4/00gnulib.m4, m4/gnulib-common.m4, m4/warn-on-use.m4, m4/wchar_h.m4:
5142         Rename save_ac_compile to saved_ac_compile.
5143         * m4/00gnulib.m4: Rename ac_save_ac_compile to ac_saved_ac_compile.
5144         * m4/gnulib-common.m4: Rename save_ac_compile_for_check_decl to
5145         saved_ac_compile_for_check_decl.
5146         * m4/assert_h.m4, m4/manywarnings.m4, m4/stdalign.m4, m4/visibility.m4:
5147         Rename gl_save_CFLAGS to gl_saved_CFLAGS.
5148         * m4/dirfd.m4: Rename dirfd_save_CFLAGS to gl_saved_CFLAGS.
5149         * m4/include_next.m4, m4/pread.m4, m4/pwrite.m4, m4/termcap.m4,
5150         m4/terminfo.m4: Rename gl_save_CPPFLAGS to gl_saved_CPPFLAGS.
5151         * m4/lib-link.m4: Rename ac_save_CPPFLAGS to acl_save_CPPFLAGS.
5152         * m4/iconv.m4, m4/readline.m4: Rename am_save_CPPFLAGS to
5153         gl_saved_CPPFLAGS.
5154         * m4/gettext.m4: Rename gt_save_CPPFLAGS to gt_saved_CPPFLAGS.
5155         * m4/ansi-c++.m4: Rename gl_save_CXX to gl_saved_CXX.
5156         * m4/manywarnings-c++.m4: Rename gl_save_CXXFLAGS to gl_saved_CXXFLAGS.
5157         * m4/lib-link.m4: Rename acl_save_ifs to acl_saved_IFS.
5158         * m4/lib-prefix.m4: Rename acl_save_IFS to acl_saved_IFS.
5159         * m4/progtest.m4: Rename ac_save_IFS to gt_saved_IFS.
5160         * m4/lib-link.m4: Rename save_libdir to saved_libdir, acl_save_libdir to
5161         acl_saved_libdir.
5162         * m4/ld-version-script.m4: Rename save_LDFLAGS to saved_LDFLAGS.
5163         * m4/acl.m4, m4/getgroups.m4: Rename ac_save_LIBS to gl_saved_LIBS.
5164         * m4/lib-link.m4: Rename ac_save_LIBS to acl_saved_LIBS.
5165         * m4/getdomainname.m4, m4/gethostname.m4, m4/getloadavg.m4,
5166         m4/hostent.m4, m4/inet_ntop.m4, m4/inet_pton.m4,
5167         m4/pthread_mutex_timedlock.m4, m4/pthread_sigmask.m4,
5168         m4/pthread-spin.m4, m4/readutmp.m4, m4/selinux-selinux-h.m4,
5169         m4/servent.m4, m4/socketlib.m4, m4/termcap.m4, m4/terminfo.m4,
5170         m4/thread.m4: Rename gl_save_LIBS to gl_saved_LIBS.
5171         * m4/getaddrinfo.m4, m4/iconv.m4, m4/readline.m4: Rename am_save_LIBS to
5172         gl_saved_LIBS.
5173         * m4/gettext.m4, m4/intlmacosx.m4: Rename gt_save_LIBS to gt_saved_LIBS.
5174         * m4/libunistring.m4: Rename glus_save_LIBS to glus_saved_LIBS.
5175         * m4/nanosleep.m4: Rename nanosleep_save_libs to gl_saved_LIBS.
5176         * m4/lib-prefix.m4: Rename acl_save_prefix to acl_saved_prefix,
5177         acl_save_exec_prefix to acl_saved_exec_prefix.
5178         * m4/configmake.m4: Rename gl_save_<variable> to gl_saved_<variable>.
5179         * m4/terminfo.m4: Likewise.
5180         * m4/gettext.m4: Rename gt_save_<variable> to gt_saved_<variable>.
5181         * m4/javaexec.m4: Rename save_CLASSPATH to gt_saved_CLASSPATH.
5182         * m4/warnings.m4: Rename gl_save_compiler_FLAGS to
5183         gl_saved_compiler_FLAGS.
5184         * lib/pread.c, lib/pwrite.c, lib/read-file.c, lib/tempname.c: Rename
5185         save_errno to saved_errno.
5186         * lib/read-file.c: Rename save_alloc to saved_alloc.
5187         * lib/strptime.c: Rename save_wday to saved_wday, save_mday to
5188         saved_mday, save_mon to saved_mon.
5190 2024-01-16  Paul Eggert  <eggert@cs.ucla.edu>
5192         posixtm: pacify clang 18
5193         Problem reported by Khem Raj in:
5194         https://lists.gnu.org/r/bug-gnulib/2024-01/msg00045.html
5195         * lib/posixtm.c (posixtime): Pacify clang 18 by converting bool to int.
5196         Arguably this is a bug in draft C2x, since the non-pointer args to
5197         ckd_add should promote just like any other expressions do;
5198         but that’s not clang’s fault.
5200 2024-01-07  Jim Meyering  <meyering@meta.com>
5202         update-copyright: handle more cases
5203         * build-aux/update-copyright: Handle cases like gunzip.in
5204         with its two copyright lines.
5205         Making it work required two changes: don't stop upon first match.
5206         And then, when continuing, a little trickiness: knowing that the
5207         final substitution would reset m{}g's "pos()", so save and restore
5208         that, to avoid an infinite loop in some cases.
5209         * tests/test-update-copyright.sh: Add a test for this.
5211 2024-01-15  Paul Eggert  <eggert@cs.ucla.edu>
5213         test-framework-sh: fix spelling typo
5214         * tests/init.sh (setup_): Name local var consistently with
5215         elsewhere in Gnulib, fixing a typo.
5217 2024-01-15  Bruno Haible  <bruno@clisp.org>
5219         test-framework-sh: Improve portability to native Windows and OS/2.
5220         Reported by KO Myung-Hun <komh78@gmail.com> in
5221         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00037.html>.
5222         * tests/init.sh (setup_): Test for an absolute directory name like
5223         Autoconf does.
5225         test-framework-sh: Improve portability to native Windows and OS/2.
5226         Reported by KO Myung-Hun <komh78@gmail.com> in
5227         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00037.html>.
5228         * tests/init.sh (setup_): In new_PATH, use $PATH_SEPARATOR instead of
5229         ':'.
5231         test-framework-sh: Improve portability to native Windows and OS/2.
5232         Reported by KO Myung-Hun <komh78@gmail.com> in
5233         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00037.html>.
5234         * tests/init.sh (setup_): Set IFS, like in Autoconf's _AS_PATH_WALK and
5235         in build-aux/relocatable.sh.in.
5237 2024-01-12  Bruno Haible  <bruno@clisp.org>
5239         jit/cache tests: Fix link error.
5240         * modules/jit/cache-tests (Makefile.am): Link test-cache with
5241         $(LIBINTL).
5243 2024-01-12  Bruno Haible  <bruno@clisp.org>
5245         qsort_r: Fix compilation error in C++ mode on FreeBSD 14.0/powerpc64.
5246         * lib/stdlib.in.h (qsort_r): Enable the C++ alias warning only on glibc
5247         systems.
5249 2024-01-11  Bruno Haible  <bruno@clisp.org>
5251         time: Fix test failure on FreeBSD 12.2/sparc64.
5252         * m4/time.m4 (gl_FUNC_TIME): Guess that it does not work on
5253         FreeBSD/sparc.
5254         * doc/posix-functions/time.texi: Mention the bug on FreeBSD/sparc.
5256 2024-01-11  Bruno Haible  <bruno@clisp.org>
5258         gnulib-tool: Reject broken 'join' program as seen in macOS, FreeBSD etc.
5259         Reported by Avinash Sonawane <rootkea@gmail.com> in
5260         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00028.html>.
5261         * gnulib-tool: Move the func_gnulib_dir and func_tmpdir invocations
5262         ahead. If the 'join' program exists but does not handle missing fields,
5263         bail out.
5265 2024-01-10  Bruno Haible  <bruno@clisp.org>
5267         jit/cache tests: Fix for powerpc64le CPUs.
5268         * tests/jit/test-cache.c: Treat Linux/powerpc64le *not* like AIX.
5270 2024-01-10  Bruno Haible  <bruno@clisp.org>
5272         jit/cache tests: Avoid gcc -Wstrict-aliasing warning on Linux/powerpc64.
5273         * tests/jit/test-cache.c (funcptr_to_structptr): Turn into an inline
5274         function.
5276 2024-01-10  Bruno Haible  <bruno@clisp.org>
5278         jit/cache tests: Fix for arm CPUs with GCC target arm-linux-gnueabihf.
5279         * tests/jit/test-cache.c (CODE): Define differently on arm.
5280         (SET_CODE, IS, SET_IS): New macros.
5281         (main): New variables is_of_return1, is_of_return2. Use the SET_CODE and
5282         SET_IS macros.
5284 2024-01-10  Bruno Haible  <bruno@clisp.org>
5286         jit/cache tests: Avoid compiler warnings on OpenBSD.
5287         * tests/jit/test-cache.c (main): New variables size_of_return1,
5288         size_of_return2.
5290 2024-01-09  Bruno Haible  <bruno@clisp.org>
5292         jit/cache: Fix for ia64 CPUs.
5293         * lib/jit/cache.h (clear_cache): On ia64 CPUs, use the 'fc', 'sync',
5294         'srlz' instructions.
5296 2024-01-09  Bruno Haible  <bruno@clisp.org>
5298         jit/cache: Fix for hppa CPUs.
5299         * lib/jit/cache.h (clear_cache): On hppa CPUs, use the 'fdc' and 'fic'
5300         instructions.
5302         jit/cache tests: Avoid test failure on OpenBSD.
5303         * tests/jit/test-cache.c (return1_code, return2_code): New constants.
5304         (main): On OpenBSD, use return1_code and return2_code instead of
5305         CODE (return1) and CODE (return2), since the latter may not be in a
5306         readable memory area.
5308         jit/cache tests: Avoid test failure on hppa CPUs.
5309         * tests/jit/test-cache.c (FUNCPTR_BIAS): New macro.
5310         (structptr_to_funcptr, funcptr_to_structptr): New functions/macros.
5311         (xcopy_structptr): Renamed from xcopy_funcptr. Mark as inline.
5312         (COPY_FUNCPTR, CODE): Use structptr_to_funcptr, funcptr_to_structptr.
5313         * modules/jit/cache-tests (configure.ac): Require AC_C_INLINE.
5315 2024-01-08  Bruno Haible  <bruno@clisp.org>
5317         jit/cache tests: Fix for powerpc*, ia64, hppa* CPUs.
5318         * modules/jit/cache-tests (Depends-on): Add xalloc.
5319         * tests/jit/test-cache.c: Include xalloc.h.
5320         (FUNCPTR_POINTS_TO_CODE, COPY_FUNCPTR): New macros.
5321         (xcopy_funcptr): New function.
5322         (main): Create a copy of the function pointer return1, so as not to
5323         destructively modify return1. Fix memcpy argument.
5325 2024-01-08  Bruno Haible  <bruno@clisp.org>
5327         jit/cache tests: Port to native Windows.
5328         * tests/jit/test-cache.c (main): On native Windows, use VirtualAlloc
5329         instead of mmap.
5331 2024-01-08  Bruno Haible  <bruno@clisp.org>
5333         jit/cache tests: Avoid test failure on OpenBSD.
5334         * modules/jit/cache-tests (Files): Add m4/warnings.m4.
5335         (configure.ac): Set and substitute DISABLE_OPENBSD_RETGUARD.
5336         (Makefile.am): Set test_cache_CFLAGS.
5337         * tests/jit/test-cache.c (main): If the compiler defines _RET_PROTECTOR,
5338         skip the test.
5340 2024-01-08  Bruno Haible  <bruno@clisp.org>
5342         jit/cache tests: Avoid test failure on CentOS, *BSD, macOS.
5343         * tests/jit/test-cache.c: Include <fcntl.h>, <stdio.h>, <stdlib.h>.
5344         Don't include pagealign_alloc.h. Include clean-temp-simple.h. Don't test
5345         HAVE_MPROTECT.
5346         (struct func): Fix #if conditions.
5347         (main): Don't invoke pagealign_xalloc and mprotect. Instead, invoke mmap,
5348         using a temporary file if needed.
5349         * modules/jit/cache-tests (Files): Add m4/mmap-anon.m4.
5350         (Depends-on): Add clean-temp-simple. Remove pagealign_alloc.
5351         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Don't test for mprotect.
5353 2024-01-07  Paul Eggert  <eggert@cs.ucla.edu>
5355         doc: adjust to texinfo 7.1
5356         * doc/Makefile (MAKEINFO): Adjust to texinfo 7.1, where makeinfo
5357         by default outputs ASCII approximations to characters.
5359 2024-01-02  Bruno Haible  <bruno@clisp.org>
5361         strverscmp: Work around bug in musl libc 1.2.3 and in Cygwin.
5362         Reported by Dmitry Bogatov <KAction@gnu.org> via Simon Josefsson in
5363         <https://lists.gnu.org/archive/html/bug-gnulib/2024-01/msg00002.html>.
5364         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize REPLACE_STRVERSCMP.
5365         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Test whether strverscmp works
5366         and set REPLACE_STRVERSCMP if not.
5367         * lib/string.in.h (strverscmp): Consider REPLACE_STRVERSCMP.
5368         * modules/strverscmp (Depends-on, configure.ac): Likewise.
5369         * modules/string (Makefile.am): Substitute REPLACE_STRVERSCMP.
5370         * tests/test-strverscmp.c (main): Add test cases suggested by Dmitry
5371         Bogatov and by Simon Josefsson.
5372         * doc/glibc-functions/strverscmp.texi: Mention the musl and Cygwin bug.
5373         Update version info regarding FreeBSD.
5375 2024-01-01  Paul Eggert  <eggert@cs.ucla.edu>
5377         update-copyright-tests: immunize against self
5378         Problem reported by Bernhard Voelker in:
5379         https://lists.gnu.org/r/bug-gnulib/2024-01/msg00003.html
5380         * tests/test-update-copyright.sh (ight): New var.
5381         Use it in tests, to prevent update-copyright from
5382         messing with the test data.
5384 2023-12-29  Paul Eggert  <eggert@cs.ucla.edu>
5386         tests: don’t skip if LONG_MAX < pid
5387         * modules/pthread_sigmask-tests, modules/sigprocmask-tests:
5388         (Depends-on): Add inttypes.
5389         * tests/test-pthread_sigmask1.c, tests/test-sigprocmask.c:
5390         Include inttypes.h.
5391         (main): Don’t skip test if pid exceeds LONG_MAX.
5393         Omit no-longer-needed pragmas
5394         * lib/anytostr.c, lib/poll.c, lib/regex.c:
5395         Omit pragmas that should no longer be needed.
5397         gnulib-common: suppress -Wtautological-constant-out-of-range-compare
5398         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Pass
5399         -Wno-tautological-constant-out-of-range-compare to clang, as it’s
5400         the warning is enabled by default and in portable code where type
5401         ranges are platform dependent it is generally more trouble than
5402         it’s worth.
5404 2023-12-29  Simon Josefsson  <simon@josefsson.org>
5406         announce-gen: Improve links.
5407         * build-aux/announce-gen: Use https:// URLs.
5409 2023-12-29  Bruno Haible  <bruno@clisp.org>
5411         error: More clang -Winclude-next-absolute-path silencing.
5412         * modules/error (Include): Suggest <error.h>, not "error.h".
5413         * tests/test-error.c: Write #include <error.h>.
5414         * tests/test-exclude.c: Likewise.
5415         * tests/test-verror.c: Likewise.
5416         * tests/test-xstrtol.c: Likewise.
5418 2023-12-28  Paul Eggert  <eggert@cs.ucla.edu>
5420         include_next: pacify clang -Winclude-next-absolute-path
5421         Without this change, Ubuntu clang version 16.0.6 (15) issues
5422         warnings like this: “In file included from xalloc-die.c:25:
5423         ./error.h:28:3: warning: #include_next in file found relative to
5424         primary source file or found by absolute path; will search from
5425         start of include path [-Winclude-next-absolute-path]”.
5426         And sure enough, each file includes itself rather than the
5427         next include file and it’s only the subsidiary include that
5428         gets around to including the next include file.
5429         * lib/argmatch.c, lib/chdir-long.c, lib/clean-temp-simple.c:
5430         * lib/clean-temp.c, lib/closein.c, lib/closeout.c, lib/copy-acl.c:
5431         * lib/copy-file.c, lib/creat.c, lib/csharpcomp.c:
5432         * lib/csharpexec.c, lib/error.c, lib/exclude.c, lib/execute.c:
5433         * lib/faccessat.c, lib/fopen.c, lib/freopen.c, lib/getopt.c:
5434         * lib/getopt1.c, lib/git-merge-changelog.c, lib/javacomp.c:
5435         * lib/javaexec.c, lib/javaversion.c, lib/mkdir-p.c, lib/open.c:
5436         * lib/openat-die.c, lib/openat.c, lib/os2-spawn.c:
5437         * lib/pagealign_alloc.c, lib/pipe-filter-gi.c:
5438         * lib/pipe-filter-ii.c, lib/same.c, lib/set-acl.c:
5439         * lib/sigpipe-die.c, lib/spawn-pipe.c, lib/sys_socket.c, lib/truncate.c:
5440         * lib/unistd.c, lib/verror.c, lib/wait-process.c, lib/wctype-h.c:
5441         * lib/xalloc-die.c, lib/xfreopen.c, lib/xmemcoll.c, lib/xprintf.c:
5442         * lib/xsetenv.c, lib/xstdopen.c, lib/xstrtol-error.c:
5443         Use ‘#include <foo.h>’ instead of ‘#include "foo.h"’ if foo.h
5444         possibly uses #include_next.  (However, don’t do this on OSF/1
5445         which has its own problems.)
5447         stat-time: fix macOS bug with negative file times
5448         macOS has a bug similar (but not identical) to Solaris when
5449         file timestamps are negative: tv_nsec might go negative.
5450         Problem reported on Darwin 8.11.0 for GNU Tar by Gordon Steemson in:
5451         https://lists.gnu.org/r/bug-tar/2023-12/msg00001.html
5452         This was evidently Mac OS X 10.4.11; I reproduced it on
5453         Darwin 21.6.0 (macOS 12.6 build 21G115).
5454         * lib/stat-time.h (STAT_TIMESPEC_OFFSETOF): New macro.
5455         (stat_time_normalize): Also normalize timestamps on macOS.
5456         * m4/fstat.m4 (gl_FUNC_FSTAT):
5457         * m4/fstatat.m4 (gl_FUNC_FSTATAT):
5458         * m4/lstat.m4 (gl_FUNC_LSTAT):
5459         * m4/stat.m4 (gl_FUNC_STAT):
5460         Also replace on macOS.
5462 2023-12-19  Bruno Haible  <bruno@clisp.org>
5464         jit/cache: Fix compilation error on m68k, sparc, etc.
5465         * lib/jit/cache.h: Include <stdint.h>.
5466         * modules/jit/cache (Depends-on): Add stdint.
5468 2023-12-19  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
5470         jit/cache tests: Make more portable.
5471         * tests/jit/test-cache.c (CODE): New macro.
5472         (struct func): New type.
5473         (main): Initialize f more carefully.
5474         * modules/jit/cache-tests (Depends-on): Add host-cpu-c-abi.
5476 2023-12-19  Christian Göttsche  <cgzones@googlemail.com>
5478         selinux-h: add stubs and wrappers for raw counterparts
5479         Add stubs and wrappers of already covered libselinux interfaces for
5480         their `raw` counterparts.  These counterparts perform the same
5481         operation except for context translation.  Context translation is used
5482         to convert SELinux labels to human readable form, see mcstransd(8).
5483         * lib/se-selinux.in.h: Add declarations for raw variants.
5484         * lib/se-label.in.h: Likewise.
5485         * lib/getfilecon.c: Add wrappers for problematic raw variants.
5486         * m4/selinux-selinux-h.m4: Use wrappers for problematic raw variants.
5488 2023-12-14  Paul Eggert  <eggert@cs.ucla.edu>
5490         mcel-tests: fix thinko in test
5491         * tests/test-mcel.c (main): Fix typo in mcel_scanz test.
5492         Problem reported by Bruno Haible in:
5493         https://lists.gnu.org/r/bug-gnulib/2023-12/msg00034.html
5495 2023-12-11  Paul Eggert  <eggert@cs.ucla.edu>
5497         savedir: scale better when sorting by name
5498         * lib/savedir.c: Include attribute.h.
5499         (direntry_t): The ‘name’ member is now idx_t, not char *,
5500         so that it survives name_space relocation.
5501         (direntry_cmp_name, direntry_cmp_inode, comparison_function):
5502         Adjust to qsort_r API, and to direntry_t layout change.
5503         (streamsavedir): Redo to avoid need for xstrdup on each directory
5504         entry.  Instead, copy the string data into name_space; this
5505         typically scales better as the memory allocator is called O(log N)
5506         rather than O(N) times.  Use qsort_r so that name_space can be
5507         passed to the comparison functions.  Simplify calls to ‘free’ so
5508         that lack of leakage is more obvious.
5509         * modules/savedir (Depends-on): Add attribute, qsort_r.
5511         getopt: pacify gcc -Wanalyzer-null-dereference
5512         * lib/getopt.c (process_long_option): Simplify logic slightly.
5513         This pacifies gcc -flto -Wanalyzer-null-dereference when compiling
5514         GNU tar on x86-64 with gcc 13.2.1 20231205 (Red Hat 13.2.1-6).
5516 2023-12-10  Pádraig Brady  <P@draigBrady.com>
5518         bootstrap: fix option propagation with --bootstrap-sync
5519         * top/bootstrap: Ensure options are propagated through
5520         upgrade_bootstrap().
5521         * top/bootstrap-funclib.sh: Likewise.
5522         * build-aux/bootstrap: Auto generated with `make build-aux/bootstrap`.
5523         Fixes https://bugs.gnu.org/67731
5525 2023-12-01  Paul Eggert  <eggert@cs.ucla.edu>
5527         frexp, frexpf: pacify clang re address-of-volatile
5528         Problem reported by Sam James in:
5529         https://lists.gnu.org/r/bug-gnulib/2023-12/msg00013.html
5530         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Don’t try to convert
5531         ‘double volatile *’ to ‘void const *’ as the C standard
5532         doesn’t allow accessing volatile variables through
5533         pointer-to-nonvolatile.
5534         * m4/frexpf.m4 (gl_FUNC_FREXPF_WORKS): Likewise.
5536         Update portability doc for CHERI, C23
5537         * doc/gnulib-readme.texi:
5538         Prefer “null pointer” to “@code{NULL}” since C23 has nullptr.
5539         (Portability guidelines): Mention C99 instead of C89 for what
5540         Gnulib assumes of headers.
5541         (C99 features avoided): Mention CHERI issue with intptr_t etc.
5542         (Other portability assumptions): Say that C23 requires two’s
5543         complement.  Mention CHERI’s holes.
5545 2023-12-01  Bruno Haible  <bruno@clisp.org>
5547         obstack: Avoid undefined behaviour.
5548         Reported by Alexey Palienko <Alexey.Palienko@cma.se> in
5549         <https://lists.gnu.org/archive/html/bug-m4/2023-02/msg00000.html>.
5550         * lib/obstack.in.h: Include <stdint.h>.
5551         (__BPTR_ALIGN): Remove macro.
5552         (__PTR_ALIGN): For the optimized case, compute the alignment through
5553         uintptr_t, instead of computing NULL + something.
5555 2023-12-01  Bruno Haible  <bruno@clisp.org>
5557         doc: Update for FreeBSD 14.0.
5558         * doc/posix-headers/*.texi: Update.
5559         * doc/glibc-headers/*.texi: Likewise.
5560         * doc/posix-functions/*.texi: Likewise.
5561         * doc/pastposix-functions/*.texi: Likewise.
5562         * doc/glibc-functions/*.texi: Likewise.
5563         * m4/printf.m4: Update comments.
5565 2023-12-01  Bruno Haible  <bruno@clisp.org>
5567         sethostname tests: Fix a compilation error on FreeBSD 14.0.
5568         * tests/test-sethostname1.c: Skip the SIGNATURE_CHECK on some platforms.
5569         * doc/glibc-functions/sethostname.texi: Update platforms list.
5571 2023-11-27  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
5573         stack: Fix documentation in header file.
5574         * lib/stack.h: Correct documentation on `stack_current_base'.
5576 2023-11-27  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
5578         jit/cache-tests: Fix include guard.
5579         * tests/jit/test-cache.c (main): Extend range of include guard.
5581 2023-11-25  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
5583         jit/cache-tests: New module.
5584         * tests/jit/test-cache.c: New file.
5585         * modules/jit/cache-tests: New file.  Mark the test as unportable
5586         for now.
5588 2023-11-25  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
5590         jit/cache: Fix configure error.
5591         * m4/valgrind-helper.m4: Unconditionally set support_valgrind.
5593 2023-11-24  Bruno Haible  <bruno@clisp.org>
5595         floorf, ceilf tests: Strengthen against compiler optimizations.
5596         Reported by René Rebe <rene@t2-project.org>.
5597         * tests/test-floorf1.c (main): Mark my_floorf as 'volatile'.
5598         * tests/test-floorf-ieee.c (main): Likewise.
5599         * tests/test-ceilf1.c (main): Mark my_ceilf as 'volatile'.
5600         * tests/test-ceilf-ieee.c (main): Likewise.
5602 2023-11-21  Bruno Haible  <bruno@clisp.org>
5604         strerrorname_np: Work around glibc bug on HPPA systems.
5605         * m4/strerrorname_np.m4 (gl_FUNC_STRERRORNAME_NP): Test also
5606         strerrorname_np (ENOSYM).
5607         * lib/strerrorname_np.c (strerrorname_np): Update comments.
5608         * tests/test-strerrorname_np.c (main): Likewise.
5609         * doc/glibc-functions/strerrorname_np.texi: Mention that glibc 2.37
5610         still needs a workaround.
5612 2023-11-21  Bruno Haible  <bruno@clisp.org>
5614         rand: Use the usual patterns for overriding a function.
5615         * lib/stdlib.in.h (RAND_MAX): Override also if module 'rand' is present.
5616         (rand): New declaration.
5617         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_RAND.
5618         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_RAND.
5619         * modules/stdlib (Makefile.am): Substitute GNULIB_RAND and REPLACE_RAND.
5621 2023-11-18  Bruno Haible  <bruno@clisp.org>
5623         nan, snan tests: Don't include these tests by default.
5624         * modules/nan-tests (Status): Mark the test as unportable.
5625         * modules/snan-tests (Status): Likewise.
5627 2023-11-17  Bruno Haible  <bruno@clisp.org>
5629         realloc-gnu: Fix wrong configure test result with optimizing ibm-clang.
5630         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Use 'volatile', to defeat an
5631         ibm-clang optimization.
5632         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Likewise.
5634 2023-11-17  Bruno Haible  <bruno@clisp.org>
5636         mbrtowc, mbrtoc32, nl_langinfo, setlocale-null: Obey --disable-threads.
5637         Reported by David Edelsohn <dje.gcc@gmail.com> in
5638         <https://gcc.gnu.org/pipermail/gcc-patches/2023-November/636830.html>,
5639         <https://gcc.gnu.org/pipermail/gcc-patches/2023-November/636843.html>.
5640         * m4/threadlib.m4 (gl_THREADLIB_BODY): If --disable-threads was
5641         specified, define AVOID_ANY_THREADS to 1.
5642         * lib/mbtowc-lock.c: Omit all code if --disable-threads was specified.
5643         * lib/nl_langinfo-lock.c: Likewise.
5644         * lib/setlocale-lock.c: Likewise.
5645         * lib/mbtowc-lock.h: Omit locking code if --disable-threads was
5646         specified.
5647         * lib/nl_langinfo.c: Likewise.
5648         * lib/setlocale_null.c: Likewise.
5649         * lib/mbrtowc.c: Don't include any multithreading headers if
5650         --disable-threads was specified.
5651         * lib/mbrtoc32.c: Likewise.
5653 2023-11-17  Bruno Haible  <bruno@clisp.org>
5655         gettext: Recognize a statically built libintl on macOS and AIX.
5656         Reported by David Edelsohn <dje.gcc@gmail.com> in
5657         <https://gcc.gnu.org/pipermail/gcc-patches/2023-November/636558.html>.
5658         * m4/gettext.m4 (AM_GNU_GETTEXT): In the
5659         "checking for GNU gettext in libintl..." test, add also the special
5660         system library dependencies needed on macOS and AIX.
5662 2023-11-16  Bruno Haible  <bruno@clisp.org>
5664         boot-time: Make it work on Adélie Linux.
5665         * lib/boot-time.c (get_boot_time_uncached): Invoke Linux fallbacks also
5666         on Linux systems that have neither <utmp.h> nor <utmpx.h>.
5668 2023-11-15  Bruno Haible  <bruno@clisp.org>
5670         obstack: Modernize, fixing several problems.
5671         * lib/obstack.in.h: Renamed from lib/obstack.h. Add reference to the
5672         glibc documentation.
5673         (_OBSTACK_INTERFACE_VERSION): Remove macro.
5674         (_OBSTACK_SIZE_T, _CHUNK_SIZE_T, _OBSTACK_CAST): Mark old values with
5675         _LIBC.
5676         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
5677         _obstack_memory_used, _obstack_allocated_p): Override if REPLACE_OBSTACK
5678         is 1.
5679         * lib/obstack.c: Don't include <gnu-versions.h>.
5680         (_OBSTACK_ELIDE_CODE): Remove macro.
5681         * m4/obstack.m4 (gl_FUNC_OBSTACK): Test whether obstack.h exists. Don't
5682         define HAVE_OBSTACK any more. Set HAVE_OBSTACK, REPLACE_OBSTACK,
5683         GL_GENERATE_OBSTACK_H.
5684         * modules/obstack (Files): Remove obstack.h. Add obstack.in.h.
5685         (Depends-on): Add gen-header. Add conditions.
5686         (configure.ac): Consider HAVE_OBSTACK, REPLACE_OBSTACK. Invoke
5687         gl_CONDITIONAL_HEADER and AC_PROG_MKDIR_P.
5688         (Makefile.am): Generate obstack.h. Augment BUILT_SOURCES and
5689         MOSTLYCLEANFILES.
5691 2023-11-15  Paul Eggert  <eggert@cs.ucla.edu>
5693         striconveha: pacify gcc -Wcast-align
5694         * lib/striconveha.c (uniconv_register_autodetect): Rewrite to
5695         avoid the need to cast from char * to a pointer to a more strictly
5696         aligned type.  Use decls after statements to avoid some repetition.
5698 2023-11-14  Bruno Haible  <bruno@clisp.org>
5700         doc: Mention a 'random' limitation on OpenBSD.
5701         Reported by Corinna Vinschen <vinschen@redhat.com>.
5702         * doc/posix-functions/random.texi: Mention the OpenBSD limitation.
5704 2023-11-14  Bruno Haible  <bruno@clisp.org>
5706         rand: Mark as obsolete.
5707         * modules/rand (Status, Notice): New sections.
5709 2023-11-14  Bruno Haible  <bruno@clisp.org>
5711         *printf-posix: Revert expectations of %lc of 0.
5712         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LC): Expect a NUL byte in the
5713         output.
5714         * lib/vasnprintf.c (VASNPRINTF): In the %lc implementation, don't
5715         special-case the NUL wide character.
5716         * tests/test-vasnprintf-posix.c (test_function): Change expected result
5717         for %lc of L'\0'.
5718         * tests/test-vasprintf-posix.c (test_function): Likewise.
5719         * tests/test-snprintf-posix.h (test_function): Likewise.
5720         * tests/test-sprintf-posix.h (test_function): Likewise.
5721         * doc/posix-functions/dprintf.texi: Update platform list regarding %lc
5722         of 0 bug.
5723         * doc/posix-functions/fprintf.texi: Likewise.
5724         * doc/posix-functions/printf.texi: Likewise.
5725         * doc/posix-functions/snprintf.texi: Likewise.
5726         * doc/posix-functions/sprintf.texi: Likewise.
5727         * doc/posix-functions/vdprintf.texi: Likewise.
5728         * doc/posix-functions/vfprintf.texi: Likewise.
5729         * doc/posix-functions/vprintf.texi: Likewise.
5730         * doc/posix-functions/vsnprintf.texi: Likewise.
5731         * doc/posix-functions/vsprintf.texi: Likewise.
5732         * doc/glibc-functions/asprintf.texi: Likewise.
5733         * doc/glibc-functions/vasprintf.texi: Likewise.
5734         * doc/glibc-functions/obstack_printf.texi: Likewise.
5735         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
5737 2023-11-13  Bruno Haible  <bruno@clisp.org>
5739         doc: Add a note.
5740         * doc/posix-headers/stdatomic.texi: Add a note about the memory model.
5742 2023-11-13  Bruno Haible  <bruno@clisp.org>
5744         Don't use CHERI facilities with CC="clang -march=morello".
5745         Suggested by Jessica Clarke <jrtc27@jrtc27.com> in
5746         <https://lists.gnu.org/archive/html/bug-gnulib/2023-11/msg00116.html>.
5747         * lib/alignalloc.h (alignalloc): Test __CHERI_PURE_CAPABILITY__, not
5748         __CHERI__.
5749         * lib/eealloc.h (eemalloc, eerealloc): Likewise.
5750         * lib/ialloc.h (irealloc, ireallocarray): Likewise.
5751         * lib/malloca.h (malloca): Likewise.
5752         * lib/malloca.c (small_t, mmalloca, freea): Likewise.
5753         * lib/rawmemchr.c (rawmemchr): Likewise.
5754         * lib/safe-alloc.h (safe_alloc_realloc_n): Likewise.
5755         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): Likewise.
5756         * lib/ssfmalloc.h (struct dissected_page_header, init_small_block_page,
5757         init_medium_block_page, free_block_from_pool, allocate_block): Likewise.
5758         * tests/test-stdint.c: Likewise.
5760 2023-11-13  Bruno Haible  <bruno@clisp.org>
5762         jit/cache: Fix configure test.
5763         * m4/valgrind-helper.m4 (gl_VALGRIND_HELPER): Check already at configure
5764         time whether <valgrind/valgrind.h> exists. Fix AC_DEFINE_UNQUOTED
5765         invocation.
5767 2023-11-12  Paul Eggert  <eggert@cs.ucla.edu>
5769         rawmemchr: speed up, particularly on CHERI
5770         * lib/rawmemchr.c (rawmemchr) [__CHERI__]: Use memchr instead of
5771         one-byte reads.  This sped up a simple benchmark (rawmemchr on
5772         100,000 bytes) by 6x on a Research Morello SoC r0p0 on CheriBSD 14.
5773         [!__CHERI__]: Use sizeof, not alignof, as better alignment
5774         should help performance a bit on some platforms.
5775         * modules/rawmemchr (Depends-on): Remove alignasof.
5777 2023-11-12  Bruno Haible  <bruno@clisp.org>
5779         jit/cache: New module.
5780         * lib/jit/cache.h: New file.
5781         * m4/valgrind-helper.m4: New file.
5782         * modules/jit/cache: New file.
5784 2023-11-11  Bruno Haible  <bruno@clisp.org>
5786         ssfmalloc: Take advantage of CHERI bounds-checking.
5787         * lib/ssfmalloc.h: Include <cheri.h>.
5788         (struct dissected_page_header) [CHERI]: Add field 'whole_page'.
5789         (init_small_block_page, init_medium_block_page) [CHERI]: Initialize it.
5790         (free_block_from_pool) [CHERI]: Use this field to initialize
5791         pool->freeable_page.
5792         (allocate_block) [CHERI]: Return a pointer with a tight upper bound.
5794 2023-11-11  Johannes Schindelin  <johannes.schindelin@gmx.de>
5796         vasnprintf: Re-enable parsing of directive with I64 (regr. 2023-03-24).
5797         * lib/printf-parse.c (PRINTF_PARSE): When parsing a size specifier
5798         "I64", increment cp by 3, not 1.
5800 2023-11-11  Bruno Haible  <bruno@clisp.org>
5802         malloca: Take advantage of CHERI bounds-checking.
5803         * lib/malloca.h: Include <cheri.h>.
5804         (malloca) [CHERI]: In the stack-allocation case, return a pointer with
5805         a tight lower bound and a tight upper bound.
5806         * lib/malloca.c: Include <cheri.h>.
5807         (small_t) [CHERI]: Define as uintptr_t.
5808         (mmalloca) [CHERI]: Return a pointer with a tight upper bound.
5809         (freea) [CHERI]: Update.
5811 2023-11-11  Bruno Haible  <bruno@clisp.org>
5813         safe-alloc: Take advantage of CHERI bounds-checking.
5814         * lib/safe-alloc.h: Include <cheri.h>.
5815         (safe_alloc_realloc_n): When count or size is 0, return a pointer whose
5816         bounds are of size 0, not 1.
5818 2023-11-11  Bruno Haible  <bruno@clisp.org>
5820         ialloc: Take advantage of CHERI bounds-checking.
5821         * lib/ialloc.h: Include <cheri.h>.
5822         (irealloc): When s is 0, return a pointer whose bounds are of size 0,
5823         not 1.
5824         (ireallocarray): When n or s is 0, return a pointer whose bounds are of
5825         size 0, not 1.
5827 2023-11-11  Bruno Haible  <bruno@clisp.org>
5829         eealloc: Take advantage of CHERI bounds-checking.
5830         * lib/eealloc.h: Include <cheri.h>.
5831         (eemalloc): When n is 0, return a pointer whose bounds are of size 0,
5832         not 1.
5833         (eerealloc): Likewise.
5835 2023-11-11  Bruno Haible  <bruno@clisp.org>
5837         alignalloc: Take advantage of CHERI bounds-checking.
5838         * lib/alignalloc.h: Include <cheri.h>.
5839         (alignalloc): When size is 0, return a pointer whose bounds are of
5840         size 0, not 1.
5842 2023-11-11  Bruno Haible  <bruno@clisp.org>
5844         rawmemchr tests: Add test case for last commit.
5845         * tests/test-rawmemchr.c (main): Add test case for aligned oversized
5846         read.
5848 2023-11-11  Paul Eggert  <eggert@cs.ucla.edu>
5850         rawmemchr: port better to CHERI
5851         * lib/rawmemchr.c (rawmemchr): Use unsigned char for longword,
5852         since CHERI doesn’t allow the aligned-word trick to speed up
5853         performance.
5855 2023-11-10  Paul Eggert  <eggert@cs.ucla.edu>
5857         di-set: port better to CHERI-64
5858         * lib/di-set.c: Include stdint.h.
5859         (hashint): Make it uintptr_t, not size_t, since it’s for use
5860         when converting to pointer and back again.  This suppresses
5861         a false positive on CHERI-64.
5862         * modules/di-set (Depends-on): Add stdint.
5864         stdio: fix port to older macOS
5865         * lib/stdio.in.h: It’s pre macOS 13, not pre macOS 10.13.
5866         Problem reported by Sevan Janiyan in:
5867         https://lists.gnu.org/r/bug-gnulib/2023-11/msg00066.html
5868         et seq.
5870 2023-11-10  Bruno Haible  <bruno@clisp.org>
5872         doc: Mention rand and srand limitations.
5873         * doc/posix-functions/rand.texi: Mention multithread-safety problem.
5874         * doc/posix-functions/srand.texi: Mention a Cygwin bug.
5876 2023-11-10  Bruno Haible  <bruno@clisp.org>
5878         tests: In multithreaded tests, use random() instead of rand().
5879         * tests/test-asyncsafe-spin2.c (random_account, lock_mutator_thread):
5880         Use random() instead of rand().
5881         * tests/test-lock.c (random_account, lock_mutator_thread,
5882         rwlock_mutator_thread, recshuffle): Likewise.
5883         * tests/test-mtx.c (random_account, lock_mutator_thread, recshuffle):
5884         Likewise.
5885         * tests/test-pthread-mutex.c (random_account, lock_mutator_thread,
5886         recshuffle): Likewise.
5887         * tests/test-pthread-rwlock.c (random_account, rwlock_mutator_thread):
5888         Likewise.
5889         * tests/test-pthread-spin.c (random_account, lock_mutator_thread):
5890         Likewise.
5891         * tests/test-pthread-tss.c (perhaps_yield, worker_thread,
5892         racecheck_thread): Likewise.
5893         * tests/test-thread_local.c (perhaps_yield, worker_thread): Likewise.
5894         * tests/test-tls.c (perhaps_yield, worker_thread, racecheck_thread):
5895         Likewise.
5896         * tests/test-tss.c (perhaps_yield, worker_thread, racecheck_thread):
5897         Likewise.
5898         * asyncsafe-spin-tests (Depends-on): Add random.
5899         * lock-tests (Depends-on): Likewise.
5900         * mtx-tests (Depends-on): Likewise.
5901         * pthread-mutex-tests (Depends-on): Likewise.
5902         * pthread-rwlock-tests (Depends-on): Likewise.
5903         * pthread-spin-tests (Depends-on): Likewise.
5904         * pthread-tss-tests (Depends-on): Likewise.
5905         * threads-h-tests (Depends-on): Likewise.
5906         * tls-tests (Depends-on): Likewise.
5907         * tss-tests (Depends-on): Likewise.
5909 2023-11-10  Bruno Haible  <bruno@clisp.org>
5911         doc: Mention an srandom limitation on OpenBSD.
5912         * doc/posix-functions/srandom.texi: Mention the OpenBSD limitation.
5914 2023-11-10  Bruno Haible  <bruno@clisp.org>
5916         random tests: Add multithread-safety test.
5917         * tests/test-random-mt.c: New file.
5918         * modules/random-tests (Files): Add it.
5919         (Depends-on): Add xalloc, thread, yield.
5920         (Makefile.am): Also build and test test-random-mt.
5922         random: Fix multithread-safety bug in general.
5923         * m4/random.m4 (gl_FUNC_RANDOM): Override also macOS, FreeBSD, Solaris,
5924         Cygwin, Haiku.
5925         * doc/posix-functions/random.texi: Mention the wider scope of the
5926         multithread-safety bug.
5928 2023-11-09  Bruno Haible  <bruno@clisp.org>
5930         sigsegv: Improve port to CHERI.
5931         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): Define also on CheriBSD.
5933         sigsegv: Port to CHERI.
5934         * lib/sigsegv.c: Treat __aarch64__ like __arm64__.
5935         (SIGSEGV_FOR_ALL_SIGNALS): Treat SIGPROT like SIGSEGV and SIGBUS.
5937 2023-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5939         stdio: port better to older macOS
5940         * lib/stdio.in.h: Do not define _POSIX_C_SOURCE on older macOS,
5941         as it is not needed and defining it causes other problems.
5942         Problem reported by Sevan Janiyan in:
5943         https://mail.gnu.org/r/bug-gnulib/2023-11/msg00039.html
5945 2023-11-09  Bruno Haible  <bruno@clisp.org>
5947         rand: Add tests.
5948         * tests/test-rand.c: New file.
5949         * modules/rand-tests: New file.
5951         rand: New module.
5952         * lib/rand.c: New file, based on glibc/stdlib/rand.c.
5953         * m4/rand.m4: New file.
5954         * modules/rand: New file.
5955         * doc/posix-functions/rand.texi: Mention the new module.
5957 2023-11-09  Bruno Haible  <bruno@clisp.org>
5959         random: Fix multithread-safety bug on CheriBSD.
5960         * m4/random.m4 (gl_FUNC_RANDOM): Override on CheriBSD.
5961         * lib/random.c: Include glthread/lock.h.
5962         (__libc_lock_define_initialized, __libc_lock_lock, __libc_lock_unlock):
5963         Define to do real locking.
5964         * modules/random (Depends-on): Add lock.
5965         * doc/posix-functions/random.texi: Mention the multithread-safety
5966         problem.
5968 2023-11-09  Bruno Haible  <bruno@clisp.org>
5970         host-cpu-c-abi: Port to CHERI.
5971         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): Treat aarch64c like
5972         aarch64.
5974 2023-11-08  Bruno Haible  <bruno@clisp.org>
5976         pthread-rwlock: Port to Mac OS X 10.4.
5977         Reported by Sevan Janiyan <venture37@geeklan.co.uk>.
5978         * m4/pthread-rwlock.m4 (gl_PTHREAD_RWLOCK): On macOS, test for the
5979         presence of PTHREAD_RWLOCK_INITIALIZER. If it is not defined, don't
5980         attempt to use pthread_rwlock_init.
5982 2023-11-07  Bruno Haible  <bruno@clisp.org>
5984         fenv-environment tests: Add a test of the link dependencies.
5985         * tests/test-fenv-env-6.c: Renamed from tests/test-fenv-env-5.c.
5986         * tests/test-fenv-env-5.c: Renamed from tests/test-fenv-env-4.c.
5987         * tests/test-fenv-env-4.c: Renamed from tests/test-fenv-env-3.c.
5988         * tests/test-fenv-env-3.c: Renamed from tests/test-fenv-env-2.c.
5989         * tests/test-fenv-env-2.c: Renamed from tests/test-fenv-env-1.c.
5990         * tests/test-fenv-env-1.c: New file.
5991         * tests/test-fenv-env-6.sh: Renamed from tests/test-fenv-env-5.sh. Update.
5992         * modules/fenv-environment-tests: Update. Add test-fenv-env-1 unit test.
5994 2023-11-07  Bruno Haible  <bruno@clisp.org>
5996         fenv-exceptions-state-c99 tests: Add a test of the link dependencies.
5997         * tests/test-fenv-except-state-4.c: Renamed from
5998         tests/test-fenv-except-state-3.c.
5999         * tests/test-fenv-except-state-3.c: Renamed from
6000         tests/test-fenv-except-state-2.c.
6001         * tests/test-fenv-except-state-2.c: Renamed from
6002         tests/test-fenv-except-state-1.c.
6003         * tests/test-fenv-except-state-1.c: New file.
6004         * modules/fenv-exceptions-state-c23-tests: Update.
6005         * modules/fenv-exceptions-state-c99-tests: Update. Add
6006         test-fenv-except-state-1 unit test.
6008 2023-11-07  Bruno Haible  <bruno@clisp.org>
6010         fenv-exceptions-trapping tests: Comments.
6011         * tests/test-fenv-except-trapping-1.c (main): Add a comment.
6013 2023-11-07  Paul Eggert  <eggert@cs.ucla.edu>
6015         malloca: pacify -Wcheri-provenance
6016         This shouldn’t affect generated code when optimizing.
6017         * lib/malloca.c (mmalloca): Pacify -Wcheri-provenance on CHERI-64 cc.
6018         (freea): Assign to temporaries to simplify debugging and avoid casts.
6020 2023-11-07  Bruno Haible  <bruno@clisp.org>
6022         rawmemchr: Port to CHERI.
6023         * lib/rawmemchr.c (rawmemchr): Use 'unsigned long' instead of uintptr_t.
6025 2023-11-06  Paul Eggert  <eggert@cs.ucla.edu>
6027         stdint: port intptr_t to CHERI
6028         * lib/stdint.in.h: Do not redefine intptr_t/uintptr_t
6029         if __INTPTR_WIDTH__ says otherwise.  This is needed on CHERI.
6031         stdint-tests: port to CHERI etc
6032         * tests/test-stdint.c: Test intptr_t only if INTPTR_MAX is
6033         defined, since the type is optional.  Similarly for uintptr_t.
6034         If CHERI, don’t assume TYPE_MINIMUM and TYPE_MAXIMUM works on
6035         intptr_t, and similarly for TYPE_MAXIMUM and uintptr_t.
6037         posix_memalign-tests: port to CHERI-64
6038         * tests/test-posix_memalign.c (main):
6039         Don’t assume sizeof (void *) <= 8.
6041         mcel-tests: fix read overrun in test case
6042         * tests/test-mcel.c (main): Don’t overrun test input buffer.
6043         Problem reported by Bruno Haible; found on CHERI-64.
6045 2023-11-06  Bruno Haible  <bruno@clisp.org>
6047         fenv-exceptions-tracking-c99 tests: Fix typo.
6048         Found by coverity.
6049         * tests/test-fenv-except-tracking-1.c (main): Write & ~, not & !.
6051 2023-11-06  Bruno Haible  <bruno@clisp.org>
6053         snan: Avoid test failures on OpenBSD/mips64.
6054         * tests/test-snan-1.c (main): Skip the 'long double' test on
6055         OpenBSD/mips64.
6056         * tests/test-snan-2.c (main): Likewise.
6058         fenv-*: Avoid test failures on OpenBSD/mips64.
6059         * tests/test-fenv-round.c (test_towardzero, test_upward, test_downward):
6060         Skip the 'long double' tests on OpenBSD/mips64.
6061         * tests/test-fenv-except-tracking-2.c (main): On OpenBSD/mips64, skip
6062         the 'long double' test.
6063         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests and the
6064         'long double' tests also on OpenBSD/mips64.
6065         * doc/posix-functions/fesetround.texi: Mention OpenBSD/mips64 here too.
6067         fenv-exceptions-tracking-c99: Fix test failures on OpenBSD/mips64.
6068         * m4/fenv-exceptions-tracking.m4 (gl_FENV_EXCEPTIONS_TRACKING): On
6069         OpenBSD/mips, set REPLACE_FECLEAREXCEPT to 1.
6070         * doc/posix-functions/feclearexcept.texi: Mention the OpenBSD/mips64
6071         bug.
6072         * m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): No need to set
6073         gl_cv_func_fesetexceptflag_works1 to 'no' on OpenBSD/mips.
6075 2023-11-06  Bruno Haible  <bruno@clisp.org>
6077         nan: Defeat clang's incorrect -O2 optimization on mips64.
6078         * lib/nan.h (NaNf, NaNd, NaNl): Use 'volatile' to disable a clang
6079         optimization.
6081 2023-11-06  Bruno Haible  <bruno@clisp.org>
6083         nan: Work around clang's incorrect constant-folding on mips64.
6084         * lib/nan.h (NaNf, NaNd, NaNl): On mips platforms, avoid the compiler's
6085         constant-folding for 0.0f/0.0f, 0.0/0.0, 0.0L/0.0L.
6087 2023-11-06  Bruno Haible  <bruno@clisp.org>
6089         snan: Add more info for mips-based platforms.
6090         * m4/nan-mips.m4: New file.
6091         * lib/snan.h: Add comments regarding mips.
6092         * modules/snan (Files): Add m4/nan-mips.m4.
6093         (configure.ac): Invoke gl_NAN_MIPS.
6094         * m4/snan.m4: Update comment.
6096 2023-11-06  Bruno Haible  <bruno@clisp.org>
6098         fenv-exceptions-state-c99: Update doc regarding Minix.
6099         * doc/posix-functions/fesetexceptflag.texi: Mention the Minix bug.
6101 2023-11-05  Bruno Haible  <bruno@clisp.org>
6103         fenv-exceptions-trapping: Avoid test failure on Minix.
6104         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests also on
6105         Minix.
6107         fenv-exceptions-tracking-c99: Fix test failures on Minix.
6108         * m4/fenv-exceptions-tracking.m4 (gl_FENV_EXCEPTIONS_TRACKING): On
6109         Minix, set REPLACE_FECLEAREXCEPT and REPLACE_FETESTEXCEPT to 1.
6110         * doc/posix-functions/feclearexcept.texi: Mention the Minix bug.
6111         * doc/posix-functions/fetestexcept.texi: Likewise.
6113 2023-11-05  Bruno Haible  <bruno@clisp.org>
6115         fenv-exceptions-trapping: Avoid test failure on Haiku/i386.
6116         * tests/test-fenv-except-trapping-2.c (main): Skip the '4' tests also on
6117         Haiku/i386.
6119         fenv-exceptions-state: Fix test failure on Haiku/i386 and Haiku/x86_64.
6120         * m4/fenv-exceptions-state.m4 (gl_FENV_EXCEPTIONS_STATE): Arrange to
6121         override fesetexceptflag() on Haiku.
6122         * doc/posix-functions/fesetexceptflag.texi: Mention the Haiku bug.
6124 2023-11-05  Bruno Haible  <bruno@clisp.org>
6126         fenv: Add C++ tests.
6127         * tests/test-fenv-c++.cc: New file.
6128         * modules/fenv-c++-tests: New file.
6129         * modules/fenv-tests (Depends-on): Add it.
6131 2023-11-05  Bruno Haible  <bruno@clisp.org>
6133         fenv-environment: Add tests.
6134         * tests/test-fenv-env-1.c: New file.
6135         * tests/test-fenv-env-2.c: New file.
6136         * tests/test-fenv-env-3.c: New file.
6137         * tests/test-fenv-env-4.c: New file.
6138         * tests/test-fenv-env-5.sh: New file.
6139         * tests/test-fenv-env-5.c: New file.
6140         * modules/fenv-environment-tests: New file.
6142         fenv-environment: New module.
6143         * lib/fenv.in.h (fenv_t) [hppa]: Remove the __exception field.
6144         (FE_DFL_ENV): Override if <fenv.h> exists but HAVE_FE_DFL_ENV is not
6145         defined.
6146         (fegetenv, fesetenv, feupdateenv, feholdexcept): New declarations.
6147         * lib/fenv-env.c: New file, based on glibc.
6148         * lib/fenv-env-hold.c: New file.
6149         * lib/fenv-env-update.c: New file.
6150         * m4/fenv-environment.m4: New file.
6151         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the 'fenv_t *' type.
6152         * m4/fenv_h.m4 (gl_FENV_H_DEFAULTS): Initialize REPLACE_FEGETENV,
6153         REPLACE_FEHOLDEXCEPT, REPLACE_FESETENV, REPLACE_FEUPDATEENV.
6154         * modules/fenv (Makefile.am): Substitute REPLACE_FEGETENV,
6155         REPLACE_FEHOLDEXCEPT, REPLACE_FESETENV, REPLACE_FEUPDATEENV.
6156         * modules/fenv-environment: New file.
6157         * doc/posix-functions/fegetenv.texi: Mention the new module and the bugs
6158         on glibc, macOS, AIX.
6159         * doc/posix-functions/feholdexcept.texi: Mention the new module and the
6160         bugs on glibc, musl libc, FreeBSD, AIX, mingw, MSVC.
6161         * doc/posix-functions/fesetenv.texi: Mention the new module and the bugs
6162         on musl libc, FreeBSD, NetBSD, AIX, Solaris, Cygwin, mingw, MSVC.
6163         * doc/posix-functions/feupdateenv.texi: Mention the new module and the
6164         bugs on glibc, musl libc, macOS, FreeBSD, AIX, Solaris, mingw, MSVC.
6166 2023-11-05  Bruno Haible  <bruno@clisp.org>
6168         fenv-exceptions-tracking-c99 tests: Enhance tests.
6169         * tests/test-fenv-except-tracking-3.sh: Test not only FE_INVALID, but
6170         also FE_DIVBYZERO, FE_OVERFLOW, FE_UNDERFLOW, FE_INEXACT.
6171         * tests/test-fenv-except-tracking-3.c: Include <stdlib.h>, <string.h>.
6172         Don't include fpe-trapping.h. Assume HAVE_FPE_TRAPPING is 1.
6173         (main): Receive the exception to test as first argument.
6175 2023-11-05  Bruno Haible  <bruno@clisp.org>
6177         fpe-trapping: Simplify.
6178         * lib/fpe-trapping.h (sigfpe_on_invalid): Remove all platform specific
6179         code. Just rely on feclearexcept and feenableexcept.
6180         * m4/fpe-trapping.m4: Renamed from m4/fpe.m4.
6181         (gl_FPE_TRAPPING): Greatly simplify.
6182         * modules/fpe-trapping (Files): Use m4/fpe-trapping.m4 instead of
6183         m4/fpe.m4. Remove m4/mathfunc.m4, m4/musl.m4.
6184         (Depends-on): Add fenv-exceptions-trapping.
6185         * tests/test-fenv-except-state-2.c (main): Update skip message.
6186         * tests/test-fenv-except-tracking-2.c (main): Likewise.
6187         * tests/test-fenv-except-tracking-3.c (main): Likewise.
6188         * tests/test-fenv-except-tracking-5.c (main): Likewise.
6189         * tests/test-nan-2.c (main): Likewise.
6190         * tests/test-snan-2.c (main): Likewise.
6192 2023-11-05  Bruno Haible  <bruno@clisp.org>
6194         fpe-tracking: Remove module.
6195         * modules/fpe-tracking: Remove file.
6196         * m4/fpe.m4 (gl_FPE_TRACKING): Remove macro.
6197         (gl_FPE_TRAPPING): Require gl_FENV_EXCEPTIONS_TRACKING instead of
6198         gl_FPE_TRACKING. Use FENV_EXCEPTIONS_TRACKING_LIBM instead of
6199         FPE_TRACKING_LIBM.
6200         * modules/nan-tests (Depends-on): Add fenv-exceptions-tracking-c99.
6201         Remove fpe-tracking.
6202         (Makefile.am): Use FENV_EXCEPTIONS_TRACKING_LIBM instead of
6203         FPE_TRACKING_LIBM.
6204         * modules/snan-tests (Depends-on): Add fenv-exceptions-tracking-c99.
6205         Remove fpe-tracking.
6206         (Makefile.am): Use FENV_EXCEPTIONS_TRACKING_LIBM instead of
6207         FPE_TRACKING_LIBM.
6208         * tests/test-nan-1.c: Assume HAVE_FE_INVALID is 1.
6209         * tests/test-snan-1.c: Likewise.
6211 2023-11-05  Bruno Haible  <bruno@clisp.org>
6213         fenv-exceptions-trapping: Avoid test failure on NetBSD/sparc.
6214         * tests/test-fenv-except-trapping-2.c (main): Skip the 'long double'
6215         tests also on NetBSD/sparc.
6217 2023-11-05  Bruno Haible  <bruno@clisp.org>
6219         fenv-exceptions-trapping: Update documentation.
6220         * doc/glibc-functions/feenableexcept.texi: Document the Linux/hppa
6221         problem.
6223 2023-11-05  Bruno Haible  <bruno@clisp.org>
6225         fenv-exceptions-trapping: Avoid test failure on older systems.
6226         * tests/test-fenv-except-trapping-2.c (main): Skip the test also on x86
6227         systems with gcc < 8.
6229 2023-11-04  Bruno Haible  <bruno@clisp.org>
6231         fenv-exceptions-trapping: Fix for powerpc* platforms.
6232         * lib/fenv-except-trapping.c (feenableexcept, fedisableexcept)
6233         [powerpc]: Use the correct bit mask for the trap bits.
6234         * tests/test-fenv-except-trapping-2.c (main): Reenable the '9' tests on
6235         powerpc platforms.
6237 2023-11-04  Bruno Haible  <bruno@clisp.org>
6239         fenv-exceptions-state-c99: Fix compilation error on FreeBSD.
6240         * lib/fenv.in.h (fegetexceptflag, fesetexceptflag): On FreeBSD, use an
6241         rpl_ prefix, to avoid a conflict with an inline definition in FreeBSD's
6242         <fenv.h>.
6244 2023-11-04  Bruno Haible  <bruno@clisp.org>
6246         doc: Update info about Cygwin feraiseexcept bug.
6247         * doc/posix-functions/feraiseexcept.texi: Update info regarding Cygwin.
6249 2023-11-04  Bruno Haible  <bruno@clisp.org>
6251         fenv-exceptions-tracking-c99 tests: Avoid test failure on NetBSD/sparc.
6252         * tests/test-fenv-except-tracking-2.c (main): On NetBSD/sparc, skip the
6253         'long double' test.
6255 2023-11-04  Bruno Haible  <bruno@clisp.org>
6257         fenv-exceptions-tracking-c99: Fix fetestexcept() override for AIX.
6258         * lib/fenv-except-tracking-test.c (fetestexcept): On AIX, use
6259         fp_read_flag() rather than the fpscr register.
6261 2023-11-04  Bruno Haible  <bruno@clisp.org>
6263         fenv-exceptions-tracking-c99: Work around a NetBSD/x86_64 bug.
6264         * m4/fenv-exceptions-tracking.m4 (gl_FENV_EXCEPTIONS_TRACKING): On
6265         NetBSD/x86_64, set REPLACE_FETESTEXCEPT to 1.
6266         * doc/posix-functions/fetestexcept.texi: Document the NetBSD bug.
6268 2023-11-04  Bruno Haible  <bruno@clisp.org>
6270         fenv-rounding: Avoid a test failure on NetBSD/sparc64.
6271         * tests/test-fenv-round.c (test_towardzero, test_upward, test_downward):
6272         Skip the 'long double' tests on NetBSD/sparc64.
6273         * doc/posix-functions/fesetround.texi: Mention the problem with
6274         'long double' operations on some platforms.
6276 2023-11-04  Bruno Haible  <bruno@clisp.org>
6278         fenv-rounding: Improve code for MSVC.
6279         * lib/fenv-round.c (fegetround) [MSVC]: Use the rounding direction from
6280         the SSE unit. Don't assume stable values for FE_UPWARD and FE_DOWNWARD.
6281         (fesetround) [MSVC]: Set the rounding direction only in the SSE unit.
6282         Don't assume stable values for FE_UPWARD and FE_DOWNWARD.
6284 2023-11-04  Bruno Haible  <bruno@clisp.org>
6286         fenv-rounding et al.: Require AC_CANONICAL_HOST before accessing $host.
6287         * m4/fenv-rounding.m4 (gl_FENV_ROUNDING): Require AC_CANONICAL_HOST.
6288         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Likewise.
6289         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
6290         * m4/iswdigit.m4 (gl_FUNC_ISWDIGIT): Likewise.
6291         * m4/iswpunct.m4 (gl_FUNC_ISWPUNCT): Likewise.
6292         * m4/iswxdigit.m4 (gl_FUNC_ISWXDIGIT): Likewise.
6293         * m4/strerrorname_np.m4 (gl_FUNC_STRERRORNAME_NP): Likewise.
6294         * m4/strfmon_l.m4 (gl_FUNC_STRFMON_L): Likewise.
6295         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
6296         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Likewise.
6297         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Likewise.
6298         * m4/wcsncmp.m4 (gl_FUNC_WCSNCMP): Likewise.
6300 2023-11-04  Bruno Haible  <bruno@clisp.org>
6302         fenv: Document an ABI break on MSVC.
6303         * doc/posix-headers/fenv.texi: Document why fegetround and fesetround
6304         are seemingly broken on MSVC.
6306 2023-10-31  Bruno Haible  <bruno@clisp.org>
6308         fenv-exceptions-trapping: Add tests.
6309         * tests/test-fenv-except-trapping-1.c: New file.
6310         * tests/test-fenv-except-trapping-2.sh: New file.
6311         * tests/test-fenv-except-trapping-2.c: New file.
6312         * modules/fenv-exceptions-trapping-tests: New file.
6314         fenv-exceptions-trapping: New module.
6315         * lib/fenv.in.h (feenableexcept, fedisableexcept, fegetexcept): New
6316         declarations.
6317         * lib/fenv-except-trapping.c: New file, based on glibc.
6318         * m4/fenv_h.m4 (gl_FENV_H): Test also whether fegetexcept is declared.
6319         * m4/fenv-exceptions-trapping.m4: New file.
6320         * modules/fenv-exceptions-trapping: New file.
6321         * doc/glibc-functions/fegetexcept.texi: Mention the new module.
6322         * doc/glibc-functions/fedisableexcept.texi: Likewise.
6323         * doc/glibc-functions/feenableexcept.texi: Likewise. Mention the glibc,
6324         macOS, FreeBSD bugs.
6326 2023-10-30  Bruno Haible  <bruno@clisp.org>
6328         fenv-exceptions-state-c99: Fix the x86_64 and i386 case.
6329         * lib/fenv-except-state-set.c (fesetexceptflag): Make sure to restore
6330         the exception trap bits in all cases.
6332 2023-10-30  Bruno Haible  <bruno@clisp.org>
6334         fenv-exceptions-state-c23: Add tests.
6335         * tests/test-fenv-except-state-3.c: New file.
6336         * modules/fenv-exceptions-state-c23-tests: New file.
6338         fenv-exceptions-state-c23: New module.
6339         * lib/fenv.in.h (fetestexceptflag): New declaration.
6340         * lib/fenv-except-state-test.c: New file, based on glibc.
6341         * m4/fenv-exceptions-state-c23.m4: New file.
6342         * modules/fenv-exceptions-state-c23: New file.
6343         * doc/posix-functions/fetestexceptflag.texi: Mention the new module.
6345 2023-10-30  Bruno Haible  <bruno@clisp.org>
6347         fenv-exceptions-state-c99: Add tests.
6348         * tests/test-fenv-except-state-1.c: New file.
6349         * tests/test-fenv-except-state-2.c: New file.
6350         * modules/fenv-exceptions-state-c99-tests: New file.
6352         fenv-exceptions-state-c99: New module.
6353         * lib/fenv.in.h (fegetexceptflag, fesetexceptflag): New declarations.
6354         * lib/fenv-except-state-get.c: New file, based on glibc.
6355         * lib/fenv-except-state-set.c: New file, based on glibc.
6356         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the 'fexcept_t *' type.
6357         * m4/fenv-exceptions-state.m4: New file.
6358         * modules/fenv-exceptions-state-c99: New file.
6359         * doc/posix-functions/fegetexceptflag.texi: Mention the new module.
6360         * doc/posix-functions/fesetexceptflag.texi: Mention the new module and
6361         the glibc, musl libc, macOS, AIX, mingw bugs.
6363 2023-10-30  Bruno Haible  <bruno@clisp.org>
6365         fenv-exceptions-tracking-{c99,c23}: Fix the x86_64 and i386 case.
6366         * lib/fenv-except-tracking-clear.c (feclearexcept): Make sure to restore
6367         the exception trap bits in all cases.
6368         * lib/fenv-except-tracking-raise.c (feraiseexcept): Likewise.
6369         * lib/fenv-except-tracking-set.c (fesetexcept): Likewise.
6371 2023-10-29  Bruno Haible  <bruno@clisp.org>
6373         fenv-exceptions-tracking-c23: Add tests.
6374         * tests/test-fenv-except-tracking-4.c: New file.
6375         * tests/test-fenv-except-tracking-5.c: New file.
6376         * modules/fenv-exceptions-tracking-c23-tests: New file.
6378         fenv-exceptions-tracking-c23: New module.
6379         * lib/fenv.in.h (fesetexcept): New declaration.
6380         * lib/fenv-except-tracking-set.c: New file, based on glibc.
6381         * lib/fenv-private.h (_GETMSR, _SETMSR, MSR_FP_EXC_MASK, PR_SET_FPEXC,
6382         PR_FP_EXC_DISABLED, PR_FP_EXC_NONRECOV, PR_FP_EXC_ASYNC,
6383         PR_FP_EXC_PRECISE, prctl) [NetBSD/powerpc]: New macros.
6384         * m4/fenv-exceptions-tracking-c23.m4: New file.
6385         * modules/fenv-exceptions-tracking-c23: New file.
6386         * doc/posix-functions/fesetexcept.texi: Mention the new module and the
6387         glibc bugs.
6389 2023-10-28  Bruno Haible  <bruno@clisp.org>
6391         fenv-exceptions-tracking-c99: Fix feraiseexcept (FE_OVERFLOW) on MSVC.
6392         * lib/fenv-except-tracking-raise.c (feraiseexcept): Use the generic
6393         approach for all exceptions.
6395 2023-10-28  Bruno Haible  <bruno@clisp.org>
6397         fpe-trapping: Always clear the FE_INVALID exception flag first.
6398         * lib/fpe-trapping.h: Include <fenv.h> on all platforms.
6399         (sigfpe_on_invalid) [AIX, HP-UX, IRIX, Solaris] : Clear the FE_INVALID
6400         exception flag first.
6401         * modules/fpe-trapping (Depends-on): Add fenv-exceptions-tracking-c99.
6403 2023-10-28  Bruno Haible  <bruno@clisp.org>
6405         fenv-exceptions-tracking-c99: Add tests.
6406         * tests/test-fenv-except-tracking-1.c: New file.
6407         * tests/test-fenv-except-tracking-2.sh: New file.
6408         * tests/test-fenv-except-tracking-2.c: New file.
6409         * tests/test-fenv-except-tracking-3.sh: New file.
6410         * tests/test-fenv-except-tracking-3.c: New file.
6411         * modules/fenv-exceptions-tracking-c99-tests: New file.
6413         fenv-exceptions-tracking-c99: New module.
6414         * lib/fenv.in.h (feclearexcept, feraiseexcept, fetestexcept): New
6415         declarations.
6416         * lib/fenv-except-tracking-clear.c: New file, based on glibc.
6417         * lib/fenv-except-tracking-raise.c: New file, based on glibc.
6418         * lib/fenv-except-tracking-test.c: New file, based on glibc.
6419         * m4/fenv-exceptions-tracking.m4: New file.
6420         * m4/fenv-exceptions.m4: New file.
6421         * modules/fenv-exceptions-tracking-c99: New file.
6422         * doc/posix-functions/feclearexcept.texi: Mention the new module.
6423         * doc/posix-functions/fetestexcept.texi: Likewise.
6424         * doc/posix-functions/feraiseexcept.texi: Likewise. Mention the glibc
6425         and Cygwin bugs.
6427 2023-10-27  Bruno Haible  <bruno@clisp.org>
6429         fenv-rounding: Add tests.
6430         * tests/test-fenv-round.c: New file.
6431         * modules/fenv-rounding-tests: New file.
6433         fenv-rounding: New module.
6434         * lib/fenv.in.h (fegetround, fesetround): New declarations.
6435         * lib/fenv-private.h: New file, based on glibc.
6436         * lib/fenv-round.c: New file, based on glibc.
6437         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the type fp_rnd.
6438         * m4/fenv-rounding.m4: New file.
6439         * modules/fenv (Depends-on): Add snippet/c++defs.
6440         (Makefile.am): Substitute $(CXXDEFS_H) into fenv.h.
6441         * modules/fenv-rounding: New file.
6442         * doc/posix-functions/fegetround.texi: Mention the new module.
6443         * doc/posix-functions/fesetround.texi: Likewise.
6445 2023-10-27  Bruno Haible  <bruno@clisp.org>
6447         tests: Use C99 initializer syntax for memory_long_double.
6448         * tests/test-isfinite.c (test_isfinitel): Use '.word = ...' syntax when
6449         initializing memory_long_double variables.
6450         * tests/test-isinf.c (test_isinfl): Likewise.
6451         * tests/test-isnan.c (test_long_double): Likewise.
6452         * tests/test-snprintf-posix.h (test_function): Likewise.
6453         * tests/test-sprintf-posix.h (test_function): Likewise.
6454         * tests/test-vasnprintf-posix.c (test_function): Likewise.
6455         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
6456         * tests/test-vasprintf-posix.c (test_function): Likewise.
6457         * modules/isfinite-tests (Depends-on): Add c99.
6458         * modules/isinf-tests (Depends-on): Likewise.
6459         * modules/isnan-tests (Depends-on): Likewise.
6460         * modules/isnanl-nolibm-tests (Depends-on): Likewise.
6461         * modules/isnanl-tests (Depends-on): Likewise.
6462         * modules/pipe-filter-gi-tests (Depends-on): Likewise.
6463         * modules/pipe-filter-ii-tests (Depends-on): Likewise.
6464         * modules/snprintf-posix-tests (Depends-on): Likewise.
6465         * modules/sprintf-posix-tests (Depends-on): Likewise.
6466         * modules/vasnprintf-posix-tests (Depends-on): Likewise.
6467         * modules/vasnwprintf-posix-tests (Depends-on): Likewise.
6468         * modules/vasprintf-posix-tests (Depends-on): Likewise.
6469         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
6470         * modules/vsprintf-posix-tests (Depends-on): Likewise.
6472 2023-10-26  Pádraig Brady  <P@draigBrady.com>
6474         base32, base64: disallow non-canonical encodings
6475         * lib/base32.c: Check that discarded bits in the encoding are zero.
6476         * lib/base64.c: Likewise.
6477         * tests/test-base32.c: Add test cases.
6478         * tests/test-base64.c: Likewise.
6480 2023-10-26  Bruno Haible  <bruno@clisp.org>
6482         fenv: Add tests.
6483         * tests/test-fenv.c: New file.
6484         * modules/fenv-tests: New file.
6486         fenv: New module.
6487         * lib/fenv.in.h: New file, based on glibc.
6488         * m4/fenv_h.m4: New file.
6489         * modules/fenv: New file.
6490         * doc/posix-headers/fenv.texi: Mention the new module.
6492 2023-10-25  Paul Eggert  <eggert@cs.ucla.edu>
6494         base32: new function isubase32; also, tune.
6495         * lib/base32.c (BASE32_INLINE): Define.
6496         (base32_to_int): Rename from b32 and make it extern.  All uses changed.
6497         (uchar_in_range): Remove.  All uses removed.
6498         (isbase32, base32_decode_ctx_init):
6499         Move to lib/base32.h and make inline.
6500         * lib/base32.h: Ignore -Wtype-limits, so that we needn’t
6501         worry about uchar_in_range.
6502         (BASE32_INLINE): Define, and use _GL_INLINE_HEADER_BEGIN.
6503         (isubase32): New function, useful as it as a different signature.
6504         (isbase32): Define in terms of isubase32.
6505         * modules/base32 (Depends-on): Add extern-inline.
6507         base64: new function isubase64; also, tune.
6508         * lib/base64.c (BASE64_INLINE): Define.
6509         (base64_to_int): Rename from b64 and make it extern.  All uses changed.
6510         (uchar_in_range): Remove.  All uses removed.
6511         (isbase64, base64_decode_ctx_init):
6512         Move to lib/base64.h and make inline.
6513         * lib/base64.h: Ignore -Wtype-limits, so that we needn’t
6514         worry about uchar_in_range.
6515         (BASE64_INLINE): Define, and use _GL_INLINE_HEADER_BEGIN.
6516         (isubase64): New function, useful as it as a different signature.
6517         (isbase64): Define in terms of isubase64.
6518         * modules/base64 (Depends-on): Add extern-inline.
6520 2023-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6522         tests/unistr/u16-chr-tests: pacify -Wcast-align
6523         * tests/unistr/test-chr.h (main): Redo types to pacify
6524         gcc -Wcast-align.
6526         isnanl-tests, stdio-tests: pacify GCC -Wshadow
6527         * tests/test-isnanl.h (NWORDS): Remove.
6528         (memory_long_double): Do not redefine in an inner scope.
6529         All uses changed to use the snan.h memory_long_double.
6530         * tests/test-stdio.c (NWORDS): Remove.
6531         (memory_long_double): Do not redefine in an inner scope.
6532         The snan.h memory_long_double is fine here.
6534         explicit_bzero-tests: pacify GCC 13.2.1
6535         * tests/test-explicit_bzero.c:
6536         * tests/test-memset_explicit.c:
6537         Ignore -Wdangling pointer.
6539 2023-10-22  Bruno Haible  <bruno@clisp.org>
6541         memset_explicit, explicit_bzero tests: Fix test failures with new gcc.
6542         Reported by Sam James <sam@gentoo.org> in
6543         <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111904>.
6544         Fix by Alexandre Oliva <aoliva@gcc.gnu.org>.
6545         * tests/test-memset_explicit.c (do_secret_stuff): Declare with
6546         attributes 'noclone' and 'noipa'.
6547         * tests/test-explicit_bzero.c (do_secret_stuff): Likewise.
6549 2023-10-15  Bruno Haible  <bruno@clisp.org>
6551         net_if tests: Fix gcc warning.
6552         * tests/test-net_if.c: Include <string.h>.
6554 2023-10-15  Bruno Haible  <bruno@clisp.org>
6556         mbspbrk: Fix gcc warning (regression 2023-09-26).
6557         * lib/mbspbrk.c (mbspbrk): Fix gcc warning in GNULIB_MCEL_PREFER mode.
6559 2023-10-15  Bruno Haible  <bruno@clisp.org>
6561         pthread-spin: Fix warnings on FreeBSD 5.2.1/i386.
6562         * lib/pthread.in.h (pthread_spinlock_t): Override if <pthread.h> defines
6563         pthread_spinlock_t but we need to approximate spinlocks with mutexes.
6564         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): When the pthread_spin_*
6565         functions are declared but don't exist, mark them as REPLACEd.
6567         pthread-spin: Fix link errors on FreeBSD 5.2.1/i386.
6568         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Test not only whether
6569         <pthread.h> defines the pthread_spinlock_t type, but also whether the
6570         function pthread_spin_init is actually defined.
6572 2023-10-15  Bruno Haible  <bruno@clisp.org>
6574         pthread_mutex_timedlock: Fix link errors on FreeBSD 5.2.1/i386.
6575         * m4/pthread_mutex_timedlock.m4 (gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK): Test
6576         not only whether pthread_mutex_timedlock is declared, but also whether
6577         it is actually defined.
6579 2023-10-15  Bruno Haible  <bruno@clisp.org>
6581         threadlib: Fix link errors on FreeBSD 5.2.1/i386.
6582         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): When pthread_kill could not be
6583         found in -lpthread, try -lthr.
6585 2023-10-15  Bruno Haible  <bruno@clisp.org>
6587         lock: Make Autoconf macro more robust.
6588         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
6589         Require gl_THREADLIB, not gl_THREADLIB_EARLY. Needed to get the value of
6590         LIBMULTITHREAD.
6592 2023-10-15  Bruno Haible  <bruno@clisp.org>
6594         totalorder-bench-tests: New module.
6595         * tests/bench-totalorder.c: New file, based on tests/test-totalorder.h.
6596         * modules/totalorder-bench-tests: New file.
6598 2023-10-15  Bruno Haible  <bruno@clisp.org>
6600         snan: Simplify a type.
6601         * lib/snan.h (memory_long_double): Put the 'value' field first.
6602         * tests/test-totalorder.h (main): No need for designated initializer
6603         syntax any more.
6605 2023-10-15  Bruno Haible  <bruno@clisp.org>
6607         vma-iter: Fix compilation error on FreeBSD 5.2.1.
6608         * lib/vma-iter.c [FreeBSD]: Include <sys/param.h>.
6610 2023-10-14  Bruno Haible  <bruno@clisp.org>
6612         totalorder*: Document glibc bug on SH4.
6613         * doc/posix-functions/totalorder.texi: Mention the glibc bug on SH4.
6614         * doc/posix-functions/totalorderf.texi: Likewise.
6615         * doc/posix-functions/totalorderl.texi: Likewise.
6617         totalorder*: Fix test failures on SH4.
6618         * lib/snan.h: Update comment.
6619         * lib/totalorderf.c (totalorderf): On sh4, invert bit 22 before
6620         comparing two NaNs.
6621         * lib/totalorder.c (totalorder): On sh4, invert bit 51 before comparing
6622         two NaNs.
6623         * lib/totalorderl.c (totalorderl): On sh4, invert bit 51 or 47 of the
6624         xhi, yhi parts before comparing two NaNs.
6626         totalorder*: Fix test failures on PA-RISC and MIPS CPUs.
6627         * lib/totalorderf.c (totalorderf): On hppa and mips, invert bit 22
6628         before comparing two NaNs.
6629         * lib/totalorder.c (totalorder): On hppa and mips, invert bit 51 before
6630         comparing two NaNs.
6631         * lib/totalorderl.c: Include <float.h>.
6632         (totalorderl): On hppa and mips, invert bit 51 or 47 of the xhi, yhi
6633         parts before comparing two NaNs.
6634         * modules/totalorderl (Depends-on): Add 'float'.
6636 2023-10-14  Bruno Haible  <bruno@clisp.org>
6638         totalorder* tests: Test also the signalling NaNs.
6639         * tests/test-totalorder.h: Include signed-snan.h.
6640         (main): Change the array initializer to contain memory_* objects rather
6641         than floating-point numbers. This is needed for i386 and x86_64 CPUs.
6642         * tests/test-totalorder.c (TOTALORDER_TYPE): Use memory_double.
6643         (TOTALORDER_HAVE_SNAN, TOTALORDER_POSITIVE_SNAN,
6644         TOTALORDER_NEGATIVE_SNAN): New macros.
6645         * tests/test-totalorderf.c (TOTALORDER_TYPE): Use memory_float.
6646         (TOTALORDER_HAVE_SNAN, TOTALORDER_POSITIVE_SNAN,
6647         TOTALORDER_NEGATIVE_SNAN): New macros.
6648         * tests/test-totalorderl.c (TOTALORDER_TYPE): Use memory_long_double.
6649         (TOTALORDER_HAVE_SNAN, TOTALORDER_POSITIVE_SNAN,
6650         TOTALORDER_NEGATIVE_SNAN): New macros.
6651         * modules/totalorder-tests (Depends-on): Add signed-snan.
6652         * modules/totalorderf-tests (Depends-on): Likewise.
6653         * modules/totalorderl-tests (Depends-on): Likewise.
6655 2023-10-14  Bruno Haible  <bruno@clisp.org>
6657         totalorder* tests: Make it easier to debug failures.
6658         * tests/test-totalorder.h: Include <stdio.h>.
6659         (main): Print array indices of all failures.
6661 2023-10-14  Bruno Haible  <bruno@clisp.org>
6663         totalorder* tests: Verify also the function signatures.
6664         * tests/test-totalorder.h: New file, based on tests/test-totalorder.c.
6665         * tests/test-totalorder.c: Check the signature. Include
6666         test-totalorder.h for the rest.
6667         * tests/test-totalorderf.c: Include <config.h>, <math.h>. Check the
6668         signature. Include test-totalorder.h instead of test-totalorder.c.
6669         * tests/test-totalorderl.c: Likewise.
6670         * modules/totalorder-tests (Files): Add test-totalorder.h, signature.h.
6671         * modules/totalorderf-tests (Files): Add test-totalorder.h, signature.h.
6672         Remove test-totalorder.c.
6673         * modules/totalorderl-tests (Files): Likewise.
6675 2023-10-14  Bruno Haible  <bruno@clisp.org>
6677         totalorder*: Improve documentation.
6678         * doc/posix-functions/totalorder.texi: Reference the specification.
6679         * doc/posix-functions/totalorderf.texi: Likewise.
6680         * doc/posix-functions/totalorderl.texi: Likewise.
6682 2023-10-14  Bruno Haible  <bruno@clisp.org>
6684         snan, signed-snan: Add API that works also on x86 and x86_64 CPUs.
6685         * lib/snan.h (memory_float, memory_double, memory_long_double): New
6686         types.
6687         (construct_memory_SNaNf, memory_SNaNf, construct_memory_SNaNd,
6688         memory_SNaNd, construct_memory_SNaNl, memory_SNaNl): New functions.
6689         * lib/signed-snan.h (memory_positive_SNaNf, memory_negative_SNaNf,
6690         memory_positive_SNaNd, memory_negative_SNaNd, memory_positive_SNaNl,
6691         memory_negative_SNaNl): New functions.
6693 2023-10-14  Bruno Haible  <bruno@clisp.org>
6695         snan tests: Fix "unused variable" warnings on i386.
6696         * tests/test-snan-1.c (main): Mark nanf, nand, nanl as possibly unused.
6697         * tests/test-snan-2.c (main): Likewise.
6699 2023-10-14  Bruno Haible  <bruno@clisp.org>
6701         snan: Avoid test failures with CC="gcc -mfpmath=387".
6702         * tests/test-snan-1.c (main): Treat x86_64 CPU with
6703         __FLT_EVAL_METHOD__ == 2 like i386 CPU. Update comments.
6704         * tests/test-snan-2.c (main): Likewise.
6706 2023-10-14  Bruno Haible  <bruno@clisp.org>
6708         snan: Fix the value of SNaNl() on i386, x86_64, ia64 CPUs.
6709         * lib/snan.h (construct_SNaNl): On i386, x86_64, ia64 CPUs, invert
6710         bit 62, not bit 63, of the mantissa.
6711         * m4/snan.m4 (gl_SNAN): Require gl_LONG_DOUBLE_VS_DOUBLE.
6712         * modules/snan (Files): Add m4/math_h.m4.
6714 2023-10-13  Bruno Haible  <bruno@clisp.org>
6716         tests: Make use of signed signalling NaNs.
6717         * tests/test-signbit.c: Include signed-snan.h instead of snan.h.
6718         (test_signbitf): Test positive_SNaNf, negative_SNaNf, instead of only
6719         SNaNf.
6720         (test_signbitd): Test positive_SNaNd, negative_SNaNd, instead of only
6721         SNaNd.
6722         (test_signbitl): Test positive_SNaNl, negative_SNaNl, instead of only
6723         SNaNl.
6724         * tests/test-stdio.c: Include signed-snan.h instead of snan.h.
6725         (main): Test positive_SNaNd, negative_SNaNd, instead of only SNaNd.
6726         Also, test positive_NaNd, negative_NaNd, instead of NaNd.
6727         * modules/signbit-tests (Depends-on): Add signed-snan. Remove snan.
6728         * modules/stdio-tests (Depends-on): Likewise.
6730 2023-10-13  Bruno Haible  <bruno@clisp.org>
6732         signed-snan: New module.
6733         * lib/snan.h (construct_SNaNf): New function, extracted from SNaNf.
6734         (SNaNf): Use it.
6735         (construct_SNaNd): New function, extracted from SNaNd.
6736         (SNaNd): Use it.
6737         (construct_SNaNl): New function, extracted from SNaNl.
6738         (SNaNl): Use it.
6739         * lib/signed-snan.h: New file.
6740         * modules/signed-snan: New file.
6742 2023-10-13  Bruno Haible  <bruno@clisp.org>
6744         signed-nan: New module, renamed from qnan.
6745         * lib/signed-nan.h: Renamed from lib/qnan.h. Update double-inclusion
6746         guard.
6747         * modules/signed-nan: Renamed from modules/qnan. Update.
6748         * tests/test-signbit.c: Update.
6749         * tests/test-stdio.c: Likewise.
6750         * tests/test-totalorder.c: Likewise.
6751         * modules/*-tests: Update.
6753 2023-10-13  Bruno Haible  <bruno@clisp.org>
6755         access: Fix test failure on native Windows.
6756         * lib/access.c (access): Do the trailing slash workaround also on
6757         native Windows.
6758         * modules/access (Depends-on): Add stat.
6760 2023-10-13  Bruno Haible  <bruno@clisp.org>
6762         isnanf, isnand: Fix conflict with Solaris <ieeefp.h>.
6763         * lib/math.in.h (isnanf, isnand): On Solaris and IRIX, declare this
6764         function, instead of defining it as a macro.
6766 2023-10-12  Bruno Haible  <bruno@clisp.org>
6768         *printf tests: Test printing of signalling NaNs.
6769         These tests run without sigfpe_on_invalid(), therefore they won't crash.
6770         * tests/test-vasnprintf-posix.c: Include snan.h.
6771         (test_function): For each test case that uses NaNd or NaNl, add a test
6772         case with SNaNd or SNaNl, respectively.
6773         * tests/test-vasprintf-posix.c: Likewise.
6774         * tests/test-snprintf-posix.h: Likewise.
6775         * tests/test-sprintf-posix.h: Likewise.
6776         * tests/test-vasnwprintf-posix.c: Likewise.
6777         * modules/vasnprintf-posix-tests (Depends-on): Add snan.
6778         * modules/vasprintf-posix-tests (Depends-on): Likewise.
6779         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
6780         * modules/snprintf-posix-tests (Depends-on): Likewise.
6781         * modules/vsprintf-posix-tests (Depends-on): Likewise.
6782         * modules/sprintf-posix-tests (Depends-on): Likewise.
6783         * modules/vasnwprintf-posix-tests (Depends-on): Likewise.
6784         * modules/pipe-filter-gi-tests (Depends-on): Likewise.
6785         * modules/pipe-filter-ii-tests (Depends-on): Likewise.
6787 2023-10-12  Bruno Haible  <bruno@clisp.org>
6789         nan, snan tests: Avoid test failures.
6790         * tests/test-nan-1.c (main): Special handling of arm CPUs with software
6791         floating-point emulation.
6792         * tests/test-snan-1.c (main): Likewise. Disable tests that are known to
6793         fail.
6794         * tests/test-snan-2.c (main): Skip tests that are known to fail.
6795         * modules/snan-tests (Files): Add m4/math_h.m4.
6796         (configure.ac): Require gl_LONG_DOUBLE_VS_DOUBLE.
6797         * m4/math_h.m4 (gl_LONG_DOUBLE_VS_DOUBLE): Mention also NetBSD/sparc32.
6799 2023-10-12  Bruno Haible  <bruno@clisp.org>
6801         snan: Add tests.
6802         * tests/test-snan-1.c: New file.
6803         * tests/test-snan-2.sh: New file.
6804         * tests/test-snan-2.c: New file.
6805         * modules/snan-tests: New file.
6807 2023-10-12  Bruno Haible  <bruno@clisp.org>
6809         nan: Add tests.
6810         * tests/test-nan-1.c: New file.
6811         * tests/test-nan-2.c: New file.
6812         * modules/nan-tests: New file.
6814 2023-10-12  Bruno Haible  <bruno@clisp.org>
6816         fpe-tracking, fpe-trapping: New modules.
6817         * lib/fpe-trapping.h: New file.
6818         * m4/mathfunc.m4 (gl_MATHFUNC): Handle also the type fp_except_t.
6819         * m4/fpe.m4: New file.
6820         * modules/fpe-tracking: New file.
6821         * modules/fpe-trapping: New file.
6823 2023-10-12  Bruno Haible  <bruno@clisp.org>
6825         snan: Comments.
6826         * lib/snan.h: Add more comments.
6828 2023-10-12  Bruno Haible  <bruno@clisp.org>
6830         snan: New module.
6831         * lib/snan.h: Renamed from tests/snan.h. Add double-inclusion guard.
6832         * m4/snan.m4: New file.
6833         * modules/snan: New file.
6834         * isfinite-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
6835         (Depends-on): Add snan.
6836         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
6837         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
6838         * isinf-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
6839         (Depends-on): Add snan.
6840         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
6841         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
6842         * isnan-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
6843         (Depends-on): Add snan.
6844         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
6845         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
6846         * isnanf-nolibm-tests (Files): Remove tests/snan.h, m4/exponentf.m4.
6847         (Depends-on): Add snan.
6848         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION.
6849         * isnanf-tests (Files): Remove tests/snan.h, m4/exponentf.m4.
6850         (Depends-on): Add snan.
6851         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION.
6852         * isnand-nolibm-tests (Files): Remove tests/snan.h, m4/exponentd.m4.
6853         (Depends-on): Add snan.
6854         (configure.ac): Don't invoke gl_DOUBLE_EXPONENT_LOCATION.
6855         * isnand-tests (Files): Remove tests/snan.h, m4/exponentd.m4.
6856         (Depends-on): Add snan.
6857         (configure.ac): Don't invoke gl_DOUBLE_EXPONENT_LOCATION.
6858         * isnanl-nolibm-tests (Files): Remove tests/snan.h, m4/exponentl.m4.
6859         (Depends-on): Add snan.
6860         (configure.ac): Don't invoke gl_LONG_DOUBLE_EXPONENT_LOCATION.
6861         * isnanl-tests (Files): Remove tests/snan.h, m4/exponentl.m4.
6862         (Depends-on): Add snan.
6863         (configure.ac): Don't invoke gl_LONG_DOUBLE_EXPONENT_LOCATION.
6864         * signbit-tests (Files): Remove tests/snan.h, m4/exponent*.m4.
6865         (Depends-on): Add snan.
6866         (configure.ac): Don't invoke gl_FLOAT_EXPONENT_LOCATION,
6867         gl_DOUBLE_EXPONENT_LOCATION, gl_LONG_DOUBLE_EXPONENT_LOCATION.
6868         * stdio-tests (Files): Remove tests/snan.h
6869         (Depends-on): Add snan.
6871 2023-10-12  Bruno Haible  <bruno@clisp.org>
6873         qnan: New module.
6874         * lib/qnan.h: Renamed from tests/qnan.h. Add double-inclusion guard.
6875         * modules/qnan: New file.
6876         * modules/signbit-tests (Files): Remove tests/qnan.h.
6877         (Depends-on): Add qnan. Remove nan.
6878         * modules/stdio-tests (Files): Remove tests/qnan.h.
6879         (Depends-on): Add qnan. Remove nan.
6880         * modules/totalorder-tests (Files): Remove tests/qnan.h.
6881         (Depends-on): Add qnan. Remove nan, signbit.
6882         * modules/totalorderf-tests (Files): Remove tests/qnan.h.
6883         (Depends-on): Add qnan. Remove nan, signbit.
6884         * modules/totalorderl-tests (Files): Remove tests/qnan.h.
6885         (Depends-on): Add qnan. Remove nan, signbit.
6887 2023-10-12  Bruno Haible  <bruno@clisp.org>
6889         nan: New module.
6890         * lib/nan.h: Renamed from tests/nan.h. Change double-inclusion guard.
6891         * modules/nan: New file.
6892         * modules/*-tests: Depend on this module instead of embedding
6893         tests/nan.h.
6895 2023-10-11  Bruno Haible  <bruno@clisp.org>
6897         unictype/category-and-not: Add more tests.
6898         Suggested by Arindam Sharma <arindam.sharma@imperial.ac.uk>.
6899         * tests/unictype/test-categ_and_not.c (main): Add two more test cases.
6900         * modules/unictype/category-and-not-tests (Depends-on): Add
6901         unictype/category-Cc.
6903 2023-10-09  Bruno Haible  <bruno@clisp.org>
6905         tests: Refactor functions for signalling NaNs.
6906         * tests/snan.h: New file, based on tests/test-isnanf.h,
6907         tests/test-isnand.h, tests/test-isnanl.h.
6908         * tests/test-isfinite.c: Include snan.h.
6909         (test_isfinitef, test_isfinited, test_isfinitel): Simplify.
6910         * tests/test-isinf.c: Include snan.h.
6911         (test_isinff, test_isinfd, test_isinfl): Simplify.
6912         * tests/test-isnan.c: Include snan.h.
6913         (test_float, test_double, test_long_double): Simplify.
6914         * tests/test-isnanf.h: Include snan.h.
6915         (main): Simplify.
6916         * tests/test-isnand.h: Include snan.h.
6917         (main): Simplify.
6918         * tests/test-isnanl.h: Include snan.h.
6919         (main): Simplify.
6920         * tests/test-signbit.c: Include snan.h.
6921         (test_signbitf, test_signbitd, test_signbitl): Simplify.
6922         * tests/test-stdio.c: Include qnan.h, snan.h instead of nan.h.
6923         (main): Test quiet NaNs always. Also test a signalling NaN.
6924         * modules/isfinite-tests (Files): Add tests/nan.h, tests/snan.h.
6925         * modules/isinf-tests (Files): Likewise.
6926         * modules/isnan-tests (Files): Add tests/snan.h.
6927         * modules/isnanf-tests (Files): Likewise.
6928         * modules/isnanf-nolibm-tests (Files): Likewise.
6929         * modules/isnand-tests (Files): Likewise.
6930         * modules/isnand-nolibm-tests (Files): Likewise.
6931         * modules/isnanl-tests (Files): Likewise.
6932         * modules/isnanl-nolibm-tests (Files): Likewise.
6933         * modules/signbit-tests (Files): Likewise.
6934         * modules/stdio-tests (Files): Add tests/qnan.h, tests/snan.h.
6936 2023-10-08  Bruno Haible  <bruno@clisp.org>
6938         isfinite: Work around a bug with 'long double' in glibc 2.5/ia64.
6939         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Require
6940         gl_LONG_DOUBLE_EXPONENT_LOCATION. Test also another NaN value.
6941         * modules/isfinite (Files): Add m4/exponentl.m4.
6942         * doc/posix-functions/isfinite.texi: Mention also a 'long double'
6943         problem on ia64.
6945 2023-10-07  Bruno Haible  <bruno@clisp.org>
6947         tests: Refactor functions for quiet NaNs.
6948         * tests/qnan.h: New file, based on tests/totalorder.c.
6949         * tests/nan.h: Add double-inclusion guard.
6950         * tests/test-signbit.c: Include qnan.h.
6951         (test_signbitf, test_signbitd, test_signbitl): Simplify.
6952         * tests/test-totalorder.c: Include qnan.h instead of NaN.h.
6953         (TOTALORDER_NAN): Remove macro.
6954         (TOTALORDER_POSITIVE_NAN, TOTALORDER_NEGATIVE_NAN): New macros.
6955         (positive_nan, negative_nan): Remove functions.
6956         (main): Update.
6957         * tests/test-totalorderf.c (TOTALORDER_NAN): Remove macro.
6958         (TOTALORDER_POSITIVE_NAN, TOTALORDER_NEGATIVE_NAN): New macros.
6959         * tests/test-totalorderl.c (TOTALORDER_NAN): Remove macro.
6960         (TOTALORDER_POSITIVE_NAN, TOTALORDER_NEGATIVE_NAN): New macros.
6961         * modules/signbit-tests (Files): Add tests/nan.h, tests/qnan.h.
6962         * modules/totalorder-tests (Files): Add tests/qnan.h.
6963         (Depends-on): Add signbit.
6964         * modules/totalorderf-tests (Files): Add tests/qnan.h.
6965         (Depends-on): Add signbit.
6966         * modules/totalorderl-tests (Files): Add tests/qnan.h.
6967         (Depends-on): Add signbit.
6969 2023-10-07  Bruno Haible  <bruno@clisp.org>
6971         totalorder*: Fix compilation error on glibc 2.25..2.30.
6972         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF): Test whether <math.h> has an
6973         incompatible declaration of totalorderf, and set REPLACE_TOTALORDERF
6974         to 1 if so.
6975         (gl_FUNC_TOTALORDER): Test whether <math.h> has an incompatible
6976         declaration of totalorder, and set REPLACE_TOTALORDER to 1 if so.
6977         (gl_FUNC_TOTALORDERL): Test whether <math.h> has an incompatible
6978         declaration of totalorderl, and set REPLACE_TOTALORDERL to 1 if so.
6980 2023-10-07  Bruno Haible  <bruno@clisp.org>
6982         isnan: Avoid dangerous shell coding pattern.
6983         * m4/isnand.m4 (gl_FUNC_ISNAND): Use 'test -n "$arg"', not
6984         'test "$arg"'.
6985         * m4/isnanf.m4 (gl_FUNC_ISNANF): Likewise.
6986         * m4/isnanl.m4 (gl_FUNC_ISNANL): Likewise.
6988 2023-10-05  Bruno Haible  <bruno@clisp.org>
6990         doc: Mention xstrerror.
6991         * doc/posix-functions/strerror_r.texi: Mention xstrerror.
6993         xstrerror: Add tests.
6994         * tests/test-xstrerror.c: New file.
6995         * modules/xstrerror-tests: New file.
6997         xstrerror: New module.
6998         * lib/xstrerror.h: New file.
6999         * lib/xstrerror.c: New file.
7000         * modules/xstrerror: New file.
7001         * modules/strerror_r-posix (configure.ac): Update comment.
7003 2023-10-05  Paul Eggert  <eggert@cs.ucla.edu>
7005         isnan: slightly simplify configuration
7006         * m4/isnand.m4 (gl_FUNC_ISNAND):
7007         * m4/isnanf.m4 (gl_FUNC_ISNANF):
7008         * m4/isnanl.m4 (gl_FUNC_ISNANL):
7009         Slightly simplify shell ‘if’.  This should simplify future changes.
7011         totalorder: speed up configuration
7012         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF, gl_FUNC_TOTALORDER)
7013         (gl_FUNC_TOTALORDERL): Avoid unnecessary call to AC_SEARCH_LIBS,
7014         since the information is already available in shell vars.
7016         totalorderl: minor porting fixes
7017         * lib/totalorderl.c (LDBL_SIGNBIT_WORD): Define to -1 if not defined.
7018         (totalorderl): Avoid unused local zu by preferring ‘if’ to ‘ifdef’.
7019         Don’t assume sizeof (unsigned long long) == 2 * sizeof (unsigned).
7021 2023-10-04  Bruno Haible  <bruno@clisp.org>
7023         totalorder* tests: Refactor.
7024         * tests/test-totalorder.c (positive_nan, negative_nan): New functions,
7025         extracted from main.
7026         (main): Use them when initializing the array.
7028 2023-10-04  Bruno Haible  <bruno@clisp.org>
7030         totalorderl: Optimize.
7031         * modules/totalorderl (Files): Add m4/signbit.m4.
7032         * m4/totalorder.m4 (gl_FUNC_TOTALORDERL): Invoke
7033         gl_LONG_DOUBLE_SIGN_LOCATION.
7034         * lib/totalorderl.c (totalorderl): If LDBL_SIGNBIT_WORD is known,
7035         use it, so that 'bigendian' becomes a constant.
7037 2023-10-04  Bruno Haible  <bruno@clisp.org>
7039         totalorderl: Work around Solaris cc bug.
7040         * lib/totalorderl.c (totalorderl): Initialize xu, yu, zu using a
7041         different syntax.
7043 2023-10-04  Bruno Haible  <bruno@clisp.org>
7045         signbit tests: Strengthen tests.
7046         * tests/test-signbit.c (test_signbitf, test_signbitd, test_signbitl):
7047         Test the sign bit both of a NaN value and of its negative.
7049 2023-10-03  Bruno Haible  <bruno@clisp.org>
7051         doc: Document portability of __VA_ARGS__.
7052         * doc/gnulib-readme.texi (C99 features assumed): Add a note about
7053         __VA_ARGS__.
7055 2023-10-03  Bruno Haible  <bruno@clisp.org>
7057         ilogb: Document a Mac OS X bug.
7058         * doc/posix-functions/ilogb.texi: Mention a bug that affects Mac OS X.
7059         * m4/ilogb.m4 (gl_FUNC_ILOGB): Update comments.
7061 2023-10-03  Bruno Haible  <bruno@clisp.org>
7063         *printf-posix: Work around bug with %#.0x on Mac OS X 10.6.
7064         * lib/vasnprintf.c (VASNPRINTF): Enable NEED_PRINTF_UNBOUNDED_PRECISION-
7065         guarded code also for NEED_PRINTF_FLAG_ALT_PRECISION_ZERO. Set
7066         prec_ourselves to 1 if NEED_PRINTF_FLAG_ALT_PRECISION_ZERO, precision is
7067         0, and the directive is 'x' or 'X'. If prec_ourselves, remove the "0"
7068         output if required.
7069         * m4/printf.m4 (gl_PRINTF_FLAG_ALT_PRECISION_ZERO): New macro.
7070         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ALT_PRECISION_ZERO): New
7071         macro.
7072         (gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS): Invoke it.
7073         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): Require
7074         gl_PRINTF_FLAG_ALT_PRECISION_ZERO and test its result.
7075         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
7076         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX):
7077         Likewise.
7078         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): Likewise.
7079         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
7080         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Likewise.
7081         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
7082         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
7083         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
7084         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
7085         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
7086         * doc/glibc-functions/asprintf.texi: Mention the %#.0x bug.
7087         * doc/glibc-functions/obstack_printf.texi: Likewise.
7088         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
7089         * doc/glibc-functions/vasprintf.texi: Likewise.
7090         * doc/posix-functions/dprintf.texi: Likewise.
7091         * doc/posix-functions/fprintf.texi: Likewise.
7092         * doc/posix-functions/fwprintf.texi: Likewise.
7093         * doc/posix-functions/printf.texi: Likewise.
7094         * doc/posix-functions/snprintf.texi: Likewise.
7095         * doc/posix-functions/sprintf.texi: Likewise.
7096         * doc/posix-functions/swprintf.texi: Likewise.
7097         * doc/posix-functions/vdprintf.texi: Likewise.
7098         * doc/posix-functions/vfprintf.texi: Likewise.
7099         * doc/posix-functions/vfwprintf.texi: Likewise.
7100         * doc/posix-functions/vprintf.texi: Likewise.
7101         * doc/posix-functions/vsnprintf.texi: Likewise.
7102         * doc/posix-functions/vsprintf.texi: Likewise.
7103         * doc/posix-functions/vswprintf.texi: Likewise.
7104         * doc/posix-functions/vwprintf.texi: Likewise.
7105         * doc/posix-functions/wprintf.texi: Likewise.
7107 2023-10-03  Bruno Haible  <bruno@clisp.org>
7109         faccessat tests: Strengthen tests.
7110         * tests/test-faccessat.c (main): Test other modes than F_OK. Check errno
7111         values.
7113 2023-10-03  Bruno Haible  <bruno@clisp.org>
7115         euidaccess: Reject trailing slashes on symlinks to non-directories.
7116         * modules/euidaccess (Depends-on): Add access.
7118         euidaccess: Add tests.
7119         * tests/test-access.h: New file, extracted from tests/test-access.c.
7120         * tests/test-access.c: Moved most code to tests/test-access.h.
7121         Include test-access.h.
7122         (main): Invoke test_access.
7123         * tests/test-euidaccess.c: New file, based on tests/test-access.c.
7124         * modules/access-tests (Files): Add tests/test-access.h.
7125         * modules/euidaccess-tests: New file, based on modules/access-tests.
7127 2023-10-03  Bruno Haible  <bruno@clisp.org>
7129         access: Make last change work also when module 'stat' is in use.
7130         * lib/access.c (access): When stat() returns -1 with errno != EOVERFLOW,
7131         fail.
7133         access: Work around trailing slash bug on Mac OS X 10.5.
7134         * m4/access.m4 (gl_FUNC_ACCESS): Test whether access honors a trailing
7135         slash. Set REPLACE_ACCESS to 1 and define ACCESS_TRAILING_SLASH_BUG if
7136         not.
7137         * lib/access.c (access): Add an implementation for Unix-like platforms.
7138         * tests/test-access.c (main): Test for result if the argument has a
7139         trailing slash.
7140         * modules/access-tests (Depends-on): Add 'symlink'.
7141         * doc/posix-functions/access.texi: Mention the Mac OS X bug.
7143 2023-10-03  Bruno Haible  <bruno@clisp.org>
7145         update-copyright tests: Fix test failure (regression 2023-06-18).
7146         * build-aux/update-copyright: Add "use re 'eval';" declaration.
7148 2023-10-03  Bruno Haible  <bruno@clisp.org>
7150         Update re *-*-windows*-gnu* config triplets, withdrawn on 2023-09-19.
7151         * m4/*.m4: Don't recognize windows*-gnu* as equivalent to mingw*.
7153 2023-10-03  Bruno Haible  <bruno@clisp.org>
7155         string-c++-tests, uchar-c++-tests: Fix link errors on Mac OS X.
7156         * modules/string-c++-tests (Makefile.am): Link test-string-c++ with
7157         $(LIBC32CONV).
7158         * modules/uchar-c++-tests (Makefile.am): Link test-uchar-c++ with
7159         $(LIBC32CONV).
7161 2023-10-03  Bruno Haible  <bruno@clisp.org>
7163         mcel tests: Fix link error.
7164         * modules/mcel-tests (Makefile.am): Link test-mcel with $(LIBUNISTRING)
7165         $(SETLOCALE_LIB) $(MBRTOWC_LIB) $(LIBC32CONV).
7167 2023-10-03  Bruno Haible  <bruno@clisp.org>
7169         mcel: Fix compilation error in tests.
7170         * lib/mcel.h (mcel_scan): Undefine 'mbs' after use.
7172 2023-10-02  Bruno Haible  <bruno@clisp.org>
7174         localename, gettext: Avoid crash on macOS 14.
7175         Reported by Shupeng Xue <dspxue@gmail.com> at
7176         <https://lists.gnu.org/archive/html/bug-gettext/2023-10/msg00001.html>.
7177         Cf <https://github.com/aria2/aria2/issues/2083#issuecomment-1694662007>.
7178         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Link with the CoreServices
7179         framework in addition to the CoreFoundation framework.
7181 2023-10-02  Bruno Haible  <bruno@clisp.org>
7183         localcharset: Avoid internal compiler error with -Wextra on macOS 10.5.
7184         * lib/localcharset.c (locale_charset): Use an empty compound statement
7185         instead of a null statement.
7187 2023-10-02  KO Myung-Hun  <komh78@gmail.com>
7189         fchdir: Fix a compilation error on OS/2 kLIBC (regression 2023-09-29).
7190         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Define REPLACE_FCHDIR macro to 1 if
7191         REPLACE_FCHDIR is 1.
7193 2023-10-02  Bruno Haible  <bruno@clisp.org>
7195         totalorder, totalorderf, totalorderl: Fix some typos.
7196         * m4/totalorder.m4 (gl_FUNC_TOTALORDERF): Assign TOTALORDERF_LIBM, not
7197         TOTALORDER_LIBM.
7198         * modules/totalorder (Description): Fix copy&paste mistake.
7199         (Depends-on): Fix conditions.
7200         * modules/totalorderf (Depends-on): Likewise.
7201         * modules/totalorderl (Depends-on): Likewise.
7203 2023-10-01  Paul Eggert  <eggert@cs.ucla.edu>
7205         totalorder, totalorderf, totalorderl: new modules
7206         * lib/math.in.h: Declare totalorderf, totalorder, totalorderl.
7207         * lib/totalorder.c, lib/totalorderf.c, lib/totalorderl.c:
7208         * m4/totalorder.m4, modules/totalorder, modules/totalorder-tests:
7209         * modules/totalorderf, modules/totalorderf-tests:
7210         * modules/totalorderl, modules/totalorderl-tests:
7211         * tests/test-totalorder.c, tests/test-totalorderf.c:
7212         * tests/test-totalorderl.c: New files.
7213         * m4/math_h.m4 (gl_MATH_H, gl_MATH_H_REQUIRE_DEFAULTS)
7214         (gl_MATH_H_DEFAULTS):
7215         * modules/math (math.h): Set up totalorder, totalorderf, totalorderl.
7216         * m4/mathfunc.m4 (gl_MATHFUNC): Also support pointer-to-const.
7218 2023-09-30  Paul Eggert  <eggert@cs.ucla.edu>
7220         regex-quote: fix recently-introduced typo
7221         Problem reported by Bruno Haible in:
7222         https://lists.gnu.org/r/bug-gnulib/2023-09/msg00146.html
7223         * lib/regex-quote.c (regex_quote_copy): Add missing #endif.
7225 2023-09-30  Bruno Haible  <bruno@clisp.org>
7227         wgetcwd-lgpl: Add tests.
7228         * tests/test-wgetcwd-lgpl.c: New file, based on
7229         tests/test-getcwd-lgpl.c.
7230         * modules/wgetcwd-lgpl-tests: New file, based on
7231         modules/getcwd-lgpl-tests.
7233         wgetcwd-lgpl: New module.
7234         * lib/wchar.in.h (wgetcwd): New declaration.
7235         * lib/wgetcwd-lgpl.c: New file, based on lib/getcwd-lgpl.c.
7236         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Initialize
7237         GNULIB_WGETCWD.
7238         * modules/wchar (Makefile.am): Substitute GNULIB_WGETCWD.
7239         * modules/wgetcwd-lgpl: New file.
7241 2023-09-30  Bruno Haible  <bruno@clisp.org>
7243         getcwd-lgpl: Tweaks.
7244         * lib/unistd.in.h (getcwd): Mention the module 'getcwd-lgpl'.
7245         * lib/getcwd-lgpl.c (rpl_getcwd): Minimize scope of local variables.
7246         * tests/test-getcwd-lgpl.c (main): Use GNU coding style.
7248 2023-09-29  Bruno Haible  <bruno@clisp.org>
7250         Allow different --libtool options from multiple gnulib-tool invocations.
7251         * modules/crypto/gc (Makefile.am): Don't test GL_COND_LIBTOOL, since
7252         gnulib-tool already eliminates lib_LDFLAGS augmentations for non-libtool
7253         libraries.
7254         * modules/striconv (Makefile.am): Likewise.
7255         * modules/striconveh (Makefile.am): Likewise.
7256         * modules/termcap (Makefile.am): Likewise.
7257         * modules/terminfo (Makefile.am): Likewise.
7259 2023-09-29  KO Myung-Hun  <komh78@gmail.com>
7261         stdlib: Cast putenv() on OS/2 kLIBC
7262         * lib/stdlib.in.h (putenv) [kLIBC]: Cast with _GL_CXXALIAS_SYS_CAST().
7264 2023-09-29  Bruno Haible  <bruno@clisp.org>
7266         fchdir: Override properly on OS/2 kLIBC.
7267         * lib/unistd.in.h (fchdir): Override if REPLACE_FCHDIR is 1.
7268         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_FCHDIR.
7269         * modules/unistd (Makefile.am): Substitute REPLACE_FCHDIR.
7270         * modules/fchdir (Depends-on, configure.ac): Test REPLACE_FCHDIR.
7271         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Instead of setting HAVE_FCHDIR to 0,
7272         set REPLACE_FCHDIR to 1.
7274 2023-09-29  KO Myung-Hun  <komh78@gmail.com>
7276         fdopendir: Use Windows code path on OS/2 kLIBC
7277         * lib/closedir.c (closedir): Use Windows code path.
7278         * lib/dirent.in.h (_gl_register_dirp_fd, _gl_unregister_dirp_fd):
7279         Remove.
7280         * lib/dirfd.c (_gl_register_dirp_fd, _gl_unregister_dirp_fd): Remove.
7281         (dirfd): Use Windows code path.
7282         * lib/fdopendir.c (fdopendir): Use Windows code path.
7283         * lib/opendir.c (opendir): Use Windows code path.
7284         * m4/closedir.m4 (REPLACE_CLOSEDIR): Use Windows code path.
7285         * m4/dirent_h.m4 (DIR_HAS_FD_MEMBER): Use Windows code path.
7286         * m4/dirfd.m4 (REPLACE_DIRFD): Use Windows code path.
7287         * m4/fchdir.m4 (HAVE_FCHDIR): Replace fchdir() if dirfd() does not work.
7288         * m4/opendir.m4 (REPLACE_OPENDIR): Use Windows code path.
7289         * m4/readdir.m4 (REPLACE_READDIR): Use Windows code path.
7290         * m4/rewinddir.m4 (REPLACE_REWINDDIR): Use Windows code path.
7291         * modules/fchdir (Depends-on): Include dirent always.
7293 2023-09-26  Paul Eggert  <eggert@cs.ucla.edu>
7295         mcel-bench-tests: fix typo
7296         * tests/bench-mcel.c (main): Fix typo in usage message.
7298         Remaining support for GNULIB_MCEL_PREFER
7299         Support mcel API in remaining modules where this might matter,
7300         for apps that prefer it.
7301         * lib/mbmemcasecmp.c, lib/mbscspn.c, lib/mbsncasecmp.c, lib/mbsnlen.c:
7302         * lib/mbspbrk.c, lib/mbspcasecmp.c, lib/mbssep.c, lib/mbsspn.c:
7303         * lib/regex-quote.c:
7304         Include mcel.h instead of mbiterf.h or mbuiterf.h,
7305         if GNULIB_MCEL_PREFER.
7306         * lib/mbmemcasecmp.c (mbmemcasecmp), lib/mbscspn.c (mbscspn):
7307         * lib/mbsncasecmp.c (mbsncasecmp), lib/mbsnlen.c (mbsnlen):
7308         * lib/mbspbrk.c (mbspbrk), lib/mbspcasecmp.c (mbspcasecmp):
7309         * lib/mbssep.c (mbssep), lib/mbsspn.c (mbsspn):
7310         * lib/regex-quote.c (regex_quote_length, regex_quote_copy):
7311         Use mcel API, if GNULIB_MCEL_PREFER.
7312         * lib/mbscspn.c, lib/mbspbrk.c, lib/mbspcasecmp.c, lib/mbsspn.c:
7313         Include stdlib.h, for MB_CUR_MAX.
7314         * modules/mbmemcasecmp, modules/mbsncasecmp, modules/mbspcasecmp:
7315         Depend on c32tolower.
7316         * modules/regex-quote: Depend on mempcpy.
7318 2023-09-25  Paul Eggert  <eggert@cs.ucla.edu>
7320         mbscasestr: support GNULIB_MCEL_PREFER
7321         Support mcel API for apps that prefer it.
7322         This mirrors the recent changes to mbsstr.
7323         * lib/mbscasestr.c [GNULIB_MCEL_PREFER]: Include mcel.h not mbuiter.h.
7324         (mbchar_t, mb_equal) [GNULIB_MCEL_PREFER]: New type and function,
7325         to make it easier to use common code.
7326         (knuth_morris_pratt_multibyte): Don't assume mbchar_t's alignment
7327         is at least that of size_t.
7328         (knuth_morris_pratt_multibyte, mbscasestr) [GNULIB_MCEL_PREFER]:
7329         Use mcel API.
7330         * modules/mbscasestr (Depends-on): Add alignasof.
7332 2023-09-24  Bernhard Voelker  <mail@bernhard-voelker.de>
7334         maintainer-makefile: Fix syntax-check rules wrt README.
7335         * top/maint.mk (sc_readme_link_install): Change the value of the
7336         variable in_vc_files to contain a pattern for the README file.
7337         (sc_readme_link_copying): Likewise.
7338         Previously, the above rules always passed, because the generated
7339         list of files was empty.  Bug introduced when adding the rules
7340         in commit 53b4bf3018.
7342 2023-09-22  Bruno Haible  <bruno@clisp.org>
7344         striconveh, *vasnprintf, vasnwprintf: Make more virtual-memory friendly.
7345         * lib/striconveh.c (mem_cd_iconveh_internal): Mark hex as 'const'.
7346         * lib/vasnprintf.c (wctomb_fallback): Likewise.
7348 2023-09-21  Paul Eggert  <eggert@cs.ucla.edu>
7350         mbschr, mbsrchr: support GNULIB_MCEL_PREFER
7351         Support mcel API for apps that prefer it.
7352         The following changes are in effect only if GNULIB_MCEL_PREFER.
7353         * lib/mbschr.c, lib/mbsrchr.c: Include stdlib.h, for MB_CUR_MAX.
7354         [GNULIB_MCEL_PREFER]: Include mcel.h instead of mbuiterf.h.
7355         (mbschr, mbsrchr) [GNULIB_MCEL_PREFER]: Use mcel API.
7357         gnulib-common: don’t suppress -Wpedantic
7358         Problem reported by Pádraig Brady in:
7359         https://lists.gnu.org/r/bug-gnulib/2023-09/msg00130.html
7360         * m4/gnulib-common.m4 (_GL_HAVE___HAS_C_ATTRIBUTE): New macro.
7361         Use it instead of ‘defined __has_c_attribute’.
7363         crypto/sm3: rename gl_cv_* variable for clarity
7364         * m4/gc-sm3.m4 (gl_cv_libgcrypt_md_sm3):
7365         Rename from gl_cv_libcrypt_md_sm3 since this is unrelated to libcrypt.
7367 2023-09-17  Paul Eggert  <eggert@cs.ucla.edu>
7369         intprops: pacify GCC -Wtype-limits
7370         * lib/intprops-internal.h: Pacify gcc (GCC) 13.2.1 20230728 (Red
7371         Hat 13.2.1-1) x86-64 -Wtype-limits on bleeding-edge diffutils.
7373 2023-09-16  Bruno Haible  <bruno@clisp.org>
7375         lib-symbol-visibility: Fix a misnomer.
7376         * doc/lib-symbol-visibility.texi: Rename LIBFOO_DLL_EXPORTED to
7377         LIBFOO_SHLIB_EXPORTED. Prefer the term "shared library", since the term
7378         "DLL" applies only to Windows.
7379         * lib/relocatable.h (RELOCATABLE_SHLIB_EXPORTED): Renamed from
7380         RELOCATABLE_DLL_EXPORTED. Prefer the term "shared library", since the
7381         term "DLL" applies only to Windows.
7382         * lib/mbtowc-lock.c (SHLIB_EXPORTED): Renamed from DLL_EXPORTED.
7383         * lib/nl_langinfo-lock.c (SHLIB_EXPORTED): Likewise.
7384         * lib/setlocale-lock.c (SHLIB_EXPORTED): Likewise.
7386 2023-09-15  Bruno Haible  <bruno@clisp.org>
7388         acl-permissions: Fix compilation error on Solaris 11 (regr. 2023-09-04).
7389         * lib/set-permissions.c: Include minmax.h.
7390         * modules/acl-permissions (Depends-on): Add minmax.
7392 2023-09-15  Bruno Haible  <bruno@clisp.org>
7394         readutmp: Fix crash when gdm is in use.
7395         Reported by Thorsten Kukuk <kukuk@suse.com> in
7396         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00093.html>.
7397         * lib/readutmp.c (read_utmp_from_systemd): Don't use the value returned
7398         by sd_session_get_display if it is NULL.
7400 2023-09-14  Bruno Haible  <bruno@clisp.org>
7402         doc: Mention libucontext.
7403         * doc/pastposix-functions/getcontext.texi: Mention libucontext.
7404         * doc/pastposix-functions/makecontext.texi: Likewise.
7405         * doc/pastposix-functions/setcontext.texi: Likewise.
7406         * doc/pastposix-functions/swapcontext.texi: Likewise.
7408 2023-09-13  Bruno Haible  <bruno@clisp.org>
7410         mbfile: Add tests.
7411         * tests/test-mbfile.sh: New file.
7412         * tests/test-mbfile.c: New file.
7413         * modules/mbfile-tests: New file.
7415         mbfile: Fix major bug (regression 2023-07-04).
7416         Reported by Gleb Fotengauer-Malinovskiy <glebfm@altlinux.org> in
7417         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00088.html>.
7418         * lib/mbfile.h (mbfile_multi_getc): If bytes != -1, -2, -3, add the
7419         previous mbf->bufcount to bytes.
7421 2023-09-11  Pádraig Brady  <P@draigBrady.com>
7423         gnu-web-doc-update: fix updating of manual directory
7424         * build-aux/gnu-web-doc-update: Change to the 'manual' directory,
7425         since $tmp is a relative path.  This avoids removing files
7426         outside of the 'manual' directory.
7428 2023-09-10  Bruno Haible  <bruno@clisp.org>
7430         Fix clang errors "different exception specifier" (regr. 2023-09-04).
7431         * lib/malloc.in.h (memalign): Don't use _GL_ATTRIBUTE_NOTHROW on
7432         platforms other than glibc systems.
7433         * lib/stdio.in.h (fdopen): Likewise.
7434         * lib/stdlib.in.h (aligned_alloc, calloc, canonicalize_file_name,
7435         malloc, realloc): Likewise.
7436         * lib/string.in.h (strdup, strndup): Likewise.
7437         * lib/sys_stat.in.h (getumask): Likewise.
7438         * lib/wchar.in.h (wcsdup): Likewise.
7440 2023-09-09  Paul Eggert  <eggert@cs.ucla.edu>
7442         propername: support GNULIB_MCEL_PREFER
7443         Support mcel API for apps that prefer it.
7444         The following changes are in effect only if GNULIB_MCEL_PREFER.
7445         * lib/propername.c: Include mcel.h, not mbchar.h and mbuiter.h.
7446         (mbsstr_trimmed_wordbounded): Use mcel API.
7447         * modules/propername (Depends-on): Add c32isalnum.
7449         trim: support GNULIB_MCEL_PREFER
7450         Support mcel API for apps that prefer it.
7451         The following changes are in effect only if GNULIB_MCEL_PREFER.
7452         * lib/trim.c: Include mcel.h, not mbchar.h and mbuiterf.h.
7453         (trim2): Use mcel API.
7454         * modules/trim (Depends-on): Add c32isspace.
7456         mbsstr: support GNULIB_MCEL_PREFER
7457         Support mcel API for apps that prefer it.
7458         * lib/mbsstr.c [GNULIB_MCEL_PREFER]: Include mcel.h not mbuiter.h.
7459         (mbchar_t, mb_equal) [GNULIB_MCEL_PREFER]: New type and function,
7460         to make it easier to use common code.
7461         (knuth_morris_pratt_multibyte): Don't assume mbchar_t's alignment
7462         is at least that of size_t.
7463         (knuth_morris_pratt_multibyte, mbsstr) [GNULIB_MCEL_PREFER]:
7464         Use mcel API.
7465         * modules/mbsstr (Depends-on): Add alignasof.
7467         mbslen: support GNULIB_MCEL_PREFER
7468         Support mcel API for apps that prefer it.
7469         The following changes are in effect only if GNULIB_MCEL_PREFER.
7470         * lib/mbslen.c: Include mcel.h instead of mbuiterf.h.
7471         (mbslen): Use mcel API.
7473         chown: work around symlink issues on odd platforms
7474         Problem reported by Jordi Sanfeliu in:
7475         https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00116.html
7476         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
7477         Do not declare unused locals st, stat_valid.
7478         Redo to just call chown if arg is a symlink.
7479         This induces a race but is perhaps the best we can do easily
7480         on oddball platforms where chown does not follow symlinks.
7482 2023-09-09  Bruno Haible  <bruno@clisp.org>
7484         chown, lchown: Revisit platforms.
7485         * doc/posix-functions/chown.texi: Update platforms list.
7486         * doc/posix-functions/lchown.texi: Likewise.
7487         * lib/chown.c (rpl_chown): Add platform comments.
7488         * lib/lchown.c: Likewise.
7490 2023-09-07  Paul Eggert  <eggert@cs.ucla.edu>
7492         mbscasecmp: support GNULIB_MCEL_PREFER
7493         * lib/mbscasecmp.c: Include stdlib.h, since we use MB_CUR_MAX.
7494         Include uchar.h, for c32tolower.
7495         (GNULIB_MCEL_PREFER): Include mcel.h instead of mbuiterf.h.
7496         (mbscasecmp) [GNULIB_MCEL_PREFER]: Use mcel instead of mbuiterf.
7497         * modules/mbscasecmp (Depends-on): Add c32tolower, stdlib, uchar.
7498         Depend on mbuiterf only if not preferring mcel.
7500         exclude: support GNULIB_MCEL_PREFER
7501         Support mcel API for apps that prefer it.
7502         The following changes are in effect only if GNULIB_MCEL_PREFER.
7503         * lib/exclude.c: Include mcel.h instead of mbuiter.h.
7504         (string_hasher_ci): Use mcel_scanz instead of mbui_init,
7505         mbui_avail, mbui_cur, and mbui_advance.
7506         * modules/exclude: Do not depend on mbuiter.
7508         mcel-prefer: new module
7509         * modules/mcel-prefer: New file.
7511         mcel-bench-tests: new module
7512         * modules/mcel-bench-tests, tests/bench-mcel.c: New files.
7513         * tests/bench-multibyte.h (TEXT_LATIN_ASCII_LINE1)
7514         (TEXT_FRENCH_UTF8_LINE1, TEXT_GREEK_UTF8_LINE1)
7515         (TEXT_CHINESE_UTF8_LINE1): New macros.
7516         (text_random_bytes): New constant.
7517         * tests/bench.h (timing_output): Mark with _GL_UNUSED,
7518         since bench-mcel.c does not use it.
7520         mcel-tests: new module
7521         * modules/mcel-tests, tests/test-mcel.c: New files
7523         mcel: new module
7524         * lib/mcel.c, lib/mcel.h, modules/mcel: New files.
7526 2023-09-07  Bruno Haible  <bruno@clisp.org>
7528         Don't use 'throw ()' in C++ 11 or newer.
7529         * lib/stddef.in.h (_GL_ATTRIBUTE_NOTHROW):  Provide fallback definition.
7530         (abort): Declare with _GL_ATTRIBUTE_NOTHROW instead of throw().
7531         * lib/malloc.in.h (rpl_free, free): Likewise.
7532         * lib/stdlib.in.h (free): Likewise.
7533         * lib/string.in.h (rpl_free, free, memchr, memrchr, rawmemchr,
7534         strchrnul, strpbrk, strstr, strcasestr): Likewise.
7535         * lib/wchar.in.h (rpl_free, free): Likewise.
7536         * lib/getopt-cdefs.in.h (__THROW): Define to noexcept(true) for C++ 11
7537         or newer.
7538         * lib/md5.h (__THROW): Likewise.
7540 2023-09-07  Bruno Haible  <bruno@clisp.org>
7542         Add info about recommended warning options with clang.
7543         * HACKING (Warning Options): Add info regarding clang.
7545 2023-09-07  Bruno Haible  <bruno@clisp.org>
7547         uchar: Fix references to overridden functions with GNULIB_NAMESPACE.
7548         * lib/uchar.in.h (btoc32, c32isalnum, c32isalpha, c32isblank,
7549         c32iscntrl, c32isdigit, c32isgraph, c32islower, c32isprint, c32ispunct,
7550         c32isspace, c32isupper, c32isxdigit, c32tolower, c32toupper, c32width,
7551         c32snrtombs, c32srtombs, c32swidth, c32tob, mbsnrtoc32s, mbsrtoc32s,
7552         c32_get_type_test, c32_apply_type_test, c32_get_mapping,
7553         c32_apply_mapping): Use GNULIB_NAMESPACE:: prefix to refer to the gnulib
7554         overridden function.
7555         * modules/uchar (Depends-on): Add wctype-h.
7556         (Makefile.am): Substitute GNULIB_BTOWC, GNULIB_ISWDIGIT,
7557         GNULIB_ISWXDIGIT, GNULIB_WCWIDTH, GNULIB_WCSNRTOMBS, GNULIB_WCSRTOMBS,
7558         GNULIB_WCSWIDTH, GNULIB_WCTOB, GNULIB_MBSNRTOWCS, GNULIB_MBSRTOWCS,
7559         GNULIB_WCTYPE, GNULIB_ISWCTYPE, GNULIB_WCTRANS, GNULIB_TOWCTRANS.
7561 2023-09-07  Bruno Haible  <bruno@clisp.org>
7563         tests: Fix some clang -Wimplicit-fallthrough warnings.
7564         * tests/test-execute-main.c (main): Add 'break' statement.
7565         * tests/test-sys_file.c (main): Likewise.
7567         unictype/category-none: Fix clang -Wpedantic warning.
7568         * lib/unictype/categ_none.c (_UC_CATEGORY_NONE): Use ISO C designated
7569         initializer syntax to initialize the intended field of the union.
7571         c-*snprintf: Fix some clang -Wmissing-prototypes warnings.
7572         * lib/c-snprintf.c: Include c-snprintf.h instead of <stdio.h>.
7573         * lib/c-vsnprintf.c: Include c-vsnprintf.h instead of <stdio.h>.
7574         * lib/c-vasnprintf.c: Include c-vasnprintf.h.
7576 2023-09-06  Bruno Haible  <bruno@clisp.org>
7578         argp: Fix clang -Wextra-semi-stmt warning.
7579         * lib/argp-help.c (SKIPWS): Remove trailing semicolon.
7581 2023-09-06  Bruno Haible  <bruno@clisp.org>
7583         doc: Refine documentation of MSVC support for shared libraries.
7584         * doc/lib-symbol-visibility.texi (Exported Symbols of Shared Libraries):
7585         Recommend to define BUILDING_SHARED as an Autoconf variable. Recommend
7586         to test DLL_EXPORT.
7588 2023-09-06  Bruno Haible  <bruno@clisp.org>
7590         doc: Fix syntax error (regression 2023-09-03).
7591         * doc/posix-headers/sys_stat.texi: Correct @itemize / @end itemize
7592         nesting.
7594 2023-09-05  Bruno Haible  <bruno@clisp.org>
7596         relocatable-lib-lgpl: Don't export symbols from static MSVC .obj files.
7597         Reported by Dmitry Bely <dmitry.bely@gmail.com> in
7598         <https://lists.gnu.org/archive/html/bug-gnu-libiconv/2023-08/msg00002.html>.
7599         * lib/relocatable.h (RELOCATABLE_DLL_EXPORTED): Don't use
7600         __declspec(dllexport) when creating static .obj files with MSVC.
7602 2023-09-05  Bruno Haible  <bruno@clisp.org>
7604         unigbrk/u8-grapheme-{next,prev} tests: Fix gcc -Wformat warnings.
7605         * tests/unigbrk/test-u8-grapheme-next.c (test_u8_grapheme_next): Use
7606         %tu, not %zu, to print a pointer difference.
7607         * tests/unigbrk/test-u16-grapheme-next.c (test_u16_grapheme_next):
7608         Likewise.
7609         * tests/unigbrk/test-u32-grapheme-next.c (test_u32_grapheme_next):
7610         Likewise.
7611         * tests/unigbrk/test-u8-grapheme-prev.c (test_u8_grapheme_prev):
7612         Likewise.
7613         * tests/unigbrk/test-u16-grapheme-prev.c (test_u16_grapheme_prev):
7614         Likewise.
7615         * tests/unigbrk/test-u32-grapheme-prev.c (test_u32_grapheme_prev):
7616         Likewise.
7618 2023-09-05  Bruno Haible  <bruno@clisp.org>
7620         stdint, *printf: Update doc about MSVC.
7621         * doc/posix-headers/stdint.texi: MSVC 14 has <stdint.h>.
7622         * doc/posix-functions/*printf.texi: Current mingw and MSVC 14 support
7623         the j, t, z size specifiers.
7624         * doc/glibc-functions/obstack_*printf.texi: Likewise.
7626 2023-09-05  Bruno Haible  <bruno@clisp.org>
7628         tests: Ensure stderr output is displayed before abort().
7629         * tests/atomic-int-gnulib.h (init_atomic_int): Call fflush(stderr)
7630         before abort().
7631         * tests/atomic-int-isoc.h (init_atomic_int): Likewise.
7632         * tests/atomic-int-posix.h (init_atomic_int): Likewise.
7633         * tests/unigbrk/test-u8-grapheme-breaks.c (test_u8_grapheme_breaks):
7634         Likewise.
7635         * tests/unigbrk/test-u16-grapheme-breaks.c (test_u16_grapheme_breaks):
7636         Likewise.
7637         * tests/unigbrk/test-u32-grapheme-breaks.c (test_u32_grapheme_breaks):
7638         Likewise.
7639         * tests/unigbrk/test-uc-grapheme-breaks.c (test_uc_grapheme_breaks):
7640         Likewise.
7641         * tests/unigbrk/test-ulc-grapheme-breaks.c (main): Likewise.
7642         * tests/unigbrk/test-u8-grapheme-next.c (test_u8_grapheme_next):
7643         Likewise.
7644         * tests/unigbrk/test-u16-grapheme-next.c (test_u16_grapheme_next):
7645         Likewise.
7646         * tests/unigbrk/test-u32-grapheme-next.c (test_u32_grapheme_next):
7647         Likewise.
7648         * tests/unigbrk/test-u8-grapheme-prev.c (test_u8_grapheme_prev):
7649         Likewise.
7650         * tests/unigbrk/test-u16-grapheme-prev.c (test_u16_grapheme_prev):
7651         Likewise.
7652         * tests/unigbrk/test-u32-grapheme-prev.c (test_u32_grapheme_prev):
7653         Likewise.
7655 2023-09-05  Bruno Haible  <bruno@clisp.org>
7657         threads-h: Modernize configure test.
7658         * m4/threads_h.m4 (gl_THREADS_H): In the test program, put the
7659         '_Thread_local' storage class specifier before the type.
7661 2023-09-05  Bruno Haible  <bruno@clisp.org>
7663         Add info about recommended warning options.
7664         * HACKING: New section "Warning Options".
7666 2023-09-04  Bruno Haible  <bruno@clisp.org>
7668         string-buffer tests: Fix a compilation error (regression from today).
7669         * tests/test-string-buffer.c: Include <wchar.h>.
7671         unistr/u{8,16,32}-strtok tests: Fix -Wanalyzer-allocation-size warnings.
7672         * tests/unistr/test-u-strtok.h (test_u_strtok): Correct values of
7673         input_len and delim_len.
7675         sigpipe tests: Fix -Wanalyzer-unsafe-call-within-signal-handler warning.
7676         * tests/test-sigpipe.c (handler): Invoke _exit, not exit.
7677         * tests/test-raise.c (handler): Update comments after 2020-11-25 change.
7679         argp: Distinguish NULL and '\0' from 0.
7680         * lib/argp-pin.c: Include <stddef.h>.
7681         (program_invocation_short_name, program_invocation_name): Use NULL
7682         instead of 0.
7683         * lib/argp-parse.c (convert_options, __argp_parse, __argp_input):
7684         Likewise.
7685         * lib/argp-fmtstream.c (__argp_make_fmtstream): Likewise.
7686         * lib/argp-help.c (make_hol, hol_entry_first_long, hol_find_entry,
7687         hol_append, hol_entry_help, argp_doc, _help): Likewise.
7688         (hol_usage): Use '\0' instead of 0.
7690         argp: Fix gcc -Wanalyzer-use-of-uninitialized-value warning.
7691         * lib/argp-help.c (hol_find_entry): Access hol->entries only after
7692         having verified that hol->num_entries > 0.
7694         unictype/category-byname tests: Fix gcc -Wunused-value warning.
7695         * tests/unictype/test-categ_byname.c (main): Add some tests for category
7696         Nl.
7698         unigbrk/uc-grapheme-breaks tests: Fix gcc -Wunused-function warning.
7699         * tests/unigbrk/test-uc-grapheme-breaks.c
7700         (graphemebreakproperty_to_string): Mark as possibly unused.
7702         bitset, nonblocking-* tests: Fix gcc -Wunused-but-set-variable warnings.
7703         * tests/test-bitset.c (check_zero): Mark 'i' as possibly unused.
7704         * tests/test-nonblocking-reader.h (full_read): Mark 'spent_time' as
7705         possibly unused.
7707 2023-09-04  Bruno Haible  <bruno@clisp.org>
7709         Use statement-expressions without warnings, even in strict ISO C mode.
7710         Suggested by Eric Blake <eblake@redhat.com> in
7711         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00025.html>.
7712         * lib/error.in.h (__gl_error_call): Use the variant with obvious control
7713         flow also with clang. Use '__extension__' to avoid -Wpedantic warnings.
7714         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Define as
7715         macros even when __STRICT_ANSI__ is defined. But use '__extension__' to
7716         avoid -Wpedantic warnings.
7717         * lib/setenv.c (KNOWN_VALUE): Use '__extension__' to avoid -Wpedantic
7718         warnings.
7719         * lib/xalloc-oversized.h (xalloc_oversized): Use optimized variant even
7720         when __STRICT_ANSI__ is defined. But use '__extension__' to avoid
7721         -Wpedantic warnings.
7723 2023-09-04  Bruno Haible  <bruno@clisp.org>
7725         Fix some g++ warnings "has a different exception specifier".
7726         * m4/gnulib-common.m4 (gl_COMMON_BODY): Make _GL_ATTRIBUTE_NOTHROW
7727         effective in C++ mode.
7728         * lib/attribute.h (ATTRIBUTE_NOTHROW): Add a comment.
7729         * lib/malloc.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
7730         (memalign): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
7731         * lib/stdio.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
7732         (fdopen): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
7733         * lib/stdlib.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
7734         (aligned_alloc, calloc, canonicalize_file_name, malloc, realloc): Invoke
7735         _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
7736         * lib/string.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
7737         (strdup, strndup): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
7738         * lib/sys_stat.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback
7739         definition.
7740         (getumask): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
7741         * lib/wchar.in.h (_GL_ATTRIBUTE_NOTHROW): Provide fallback definition.
7742         (wcsdup): Invoke _GL_FUNCDECL_SYS with _GL_ATTRIBUTE_NOTHROW.
7744 2023-09-04  Bruno Haible  <bruno@clisp.org>
7746         unistr/u{8,16,32}-strchr tests: Fix some gcc -Wshadow warnings.
7747         * tests/unistr/test-strchr.h (test_strchr): Reduce of scope of local
7748         variable 'i'.
7750         unistr/u{8,16,32}-chr tests: Fix some gcc -Wshadow warnings.
7751         * tests/unistr/test-chr.h (main): Reduce of scope of local variables
7752         'i' and 'page_boundary'.
7754         pipe-filter-gi, pipe-filter-ii tests: Fix some gcc -Wshadow warnings.
7755         * tests/test-pipe-filter-gi1.c (main): Rename local variable 'argv' to
7756         'tr_argv'.
7757         * tests/test-pipe-filter-ii1.c (main): Likewise.
7759         argv-iter tests: Avoid gcc -Wanalyzer-out-of-bounds warning.
7760         * tests/test-argv-iter.c (main): Simplify logic.
7762         crypto/{gc-rijndael,rijndael} tests: Fix some gcc -Wshadow warnings.
7763         * tests/test-gc-rijndael.c (main): Rename local variable 'i' to 'round'.
7764         * tests/test-rijndael.c (main): Likewise.
7766         threads-h tests: Fix gcc -Wold-style-declaration warning.
7767         * tests/test-thread_local.c (value0, value1, value2, value3): Put the
7768         'thread_local' storage class specifier before the type.
7770         ieee754-h tests: Fix some gcc -Wmissing-field-initializers warnings.
7771         * tests/test-ieee754-h.c (float_tests): Use float literals.
7772         (double_tests): Use double literals. Initialize frac_lo.
7774         string-buffer tests: Fix a gcc -Wformat warning.
7775         * tests/test-string-buffer.c: Don't assume that wint_t has the same size
7776         as 'int'.
7778         crypto/* tests: Fix some gcc -Wdiscarded-qualifiers warnings.
7779         * tests/test-gc-hmac-md5.c (main): Change type of variables with a
7780         string literal initializer to 'const char *'.
7781         * tests/test-gc-hmac-sha1.c (main): Likewise.
7782         * tests/test-gc-hmac-sha256.c (main): Likewise.
7783         * tests/test-gc-hmac-sha512.c (main): Likewise.
7784         * tests/test-gc-md2.c (main): Likewise.
7785         * tests/test-gc-md5.c (main): Likewise.
7786         * tests/test-gc-sha1.c (main): Likewise.
7787         * tests/test-gc-sha256.c (main): Likewise.
7788         * tests/test-gc-sha512.c (main): Likewise.
7789         * tests/test-hmac-md5.c (main): Likewise.
7790         * tests/test-hmac-sha1.c (main): Likewise.
7791         * tests/test-hmac-sha256.c (main): Likewise.
7792         * tests/test-hmac-sha512.c (main): Likewise.
7794         file-has-acl: Avoid gcc warning.
7795         * lib/acl-internal.h (MIN): Remove definition.
7797 2023-09-03  Paul Eggert  <eggert@cs.ucla.edu>
7799         same-inode, stat-size: support pointers too
7800         Add functions and macros so that we can test pointers to struct
7801         stat as well as plain struct stat.  This lets coreutils deal with
7802         structs that are only partly initialized, without relying on
7803         undefined behavior.
7804         * NEWS: Mention this.
7805         * doc/posix-headers/sys_stat.texi, doc/stat-size.texi:
7806         Mention this and modernize.
7807         * lib/at-func2.c (at_func2):
7808         * lib/fts.c (same_fd):
7809         * lib/rename.c (rpl_rename) [RENAME_HARD_LINK_BUG]:
7810         * lib/same-inode.c: New file.
7811         * lib/same.c (same_nameat):
7812         * lib/term-style-control.c (activate_term_style_controller):
7813         Prefer psame_inode (a, b) to SAME_INODE (*a, *b).
7814         * lib/hash-triple-simple.c (triple_compare_ino_str):
7815         * lib/hash-triple.c (triple_compare):
7816         Prefer PSAME_INODE (a, b) to SAME_INODE (*a, *b).
7817         psame_inode is not suitable since the args are not struct stat *.
7818         * lib/same-inode.h: Check that config.h is included first.
7819         (SAME_INODE_INLINE, PSAME_INODE): New macros.
7820         (SAME_INODE): Reimplement in terms of PSAME_INODE.
7821         (psame_inode): New function.
7822         * lib/stat-size.h (STP_BLKSIZE, STP_NBLOCKS): New macros.
7823         (ST_BLKSIZE, ST_NBLOCKS): Use them.
7824         * lib/term-style-control.c (log_signal_handler_called):
7825         Always define as a function, to pacify -Wunused*.
7826         * modules/canonicalize-lgpl-tests (Files): Add m4/musl.m4.
7827         (Depends-on): Call gl_MUSL_LIBC.
7828         * modules/same-inode (Files): Add same-inode.c.
7829         (Depends-on): Add extern-inline, stdbool.
7830         (lib_SOURCES): New macro.
7831         * tests/test-binary-io.c, tests/test-canonicalize-lgpl.c:
7832         * tests/test-canonicalize.c, tests/test-cloexec.c:
7833         * tests/test-dup-safer.c, tests/test-dup2.c, tests/test-error.c:
7834         * tests/test-fcntl.c, tests/test-fdopendir.c, tests/test-fgetc.c:
7835         * tests/test-fputc.c, tests/test-fread.c, tests/test-fstat.c:
7836         * tests/test-fstatat.c, tests/test-ftruncate.c:
7837         * tests/test-fwrite.c, tests/test-getcwd.c:
7838         * tests/test-getdtablesize.c, tests/test-isblank.c:
7839         * tests/test-linkat.c, tests/test-lock.c, tests/test-lstat.h:
7840         * tests/test-malloc-gnu.c, tests/test-openat.c:
7841         * tests/test-pthread-thread.c, tests/test-pthread_sigmask1.c:
7842         * tests/test-pthread_sigmask2.c, tests/test-ptsname.c:
7843         * tests/test-ptsname_r.c, tests/test-raise.c:
7844         * tests/test-realloc-gnu.c, tests/test-rwlock1.c:
7845         * tests/test-sigprocmask.c, tests/test-snprintf.c:
7846         * tests/test-stat.h, tests/test-term-style-control-hello.c:
7847         * tests/test-term-style-control-yes.c, tests/test-thread_create.c:
7848         * tests/test-unlinkat.c, tests/test-vasnprintf.c:
7849         * tests/test-xalloc-die.c:
7850         Adjust to these changes, and fix some warnings elicited by
7851         -Wall -Wextra that I ran into while testing.
7852         * top/maint.mk (sc_prohibit_stat_st_blocks): Mention STP_NBLOCKS.
7854 2023-09-02  Bruno Haible  <bruno@clisp.org>
7856         alignalloc: Fix license header.
7857         Suggested by Paul Eggert in
7858         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00170.html>.
7859         * lib/alignalloc.h: Make license header consistent with module
7860         description.
7861         * lib/alignalloc.c: Likewise.
7863 2023-09-01  Bruno Haible  <bruno@clisp.org>
7865         crypto/{sha*,md5}-buffer: Add comment.
7866         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Add comment regarding license.
7868 2023-09-01  Bruno Haible  <bruno@clisp.org>
7870         crypto/{sha*,md5,sm3}-buffer: Fix --with-openssl (regr. 2023-08-26).
7871         Reported by Agostino Sarubbo via Sam James <sam@gentoo.org> in
7872         <https://lists.gnu.org/archive/html/bug-gnulib/2023-09/msg00000.html>.
7873         * lib/sha1.h: Test the OpenSSL major version before attempting to
7874         include <openssl/configuration.h>.
7875         * lib/sha256.h: Likewise.
7876         * lib/sha512.h: Likewise.
7877         * lib/md5.h: Likewise.
7878         * lib/sm3.h: Likewise.
7880 2023-08-31  Bruno Haible  <bruno@clisp.org>
7882         readutmp: Fix memory leak introduced by last commit.
7883         * lib/readutmp.c (read_utmp_from_systemd): If num_sessions == 0 and
7884         sessions != NULL, do call free (sessions).
7886 2023-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7888         readutmp: fix core dump if --enable-systemd
7889         Problem reported by Thorsten Kukuk <https://bugs.gnu.org/65617>.
7890         * lib/readutmp.c (read_utmp_from_systemd):
7891         Don’t assume session_ptr != NULL if num_sessions == 0.
7892         In practice it can be null, and the man page OKs this behavior.
7894 2023-08-30  Bruno Haible  <bruno@clisp.org>
7896         doc: Mention the module 'wchar-single'.
7897         * doc/multithread.texi: Mention the module 'wchar-single'.
7899 2023-08-30  Paul Eggert  <eggert@cs.ucla.edu>
7901         wchar-single: fix module broken since 2021
7902         Adjust to 2021-03-07 change “Rename GNULIB_WCHAR_SINGLE to
7903         GNULIB_WCHAR_SINGLE_LOCALE”.  Apparently nobody noticed that
7904         the module was broken.  Perhaps we should obsolete the module?
7905         * modules/wchar-single (GNULIB_WCHAR_SINGLE_LOCALE): Define.
7907 2023-08-29  Bruno Haible  <bruno@clisp.org>
7909         wctype: Rely on module iswpunct.
7910         * m4/wctype.m4 (gl_FUNC_WCTYPE): Also test whether the "punct" class
7911         works.
7912         * modules/wctype (Depends-on): Add iswpunct.
7913         * tests/test-iswctype.c (main): Add more tests of the "punct" class.
7914         * doc/posix-functions/wctype.texi: Mention the Android problem.
7916         c32ispunct: Rely on module iswpunct.
7917         * modules/c32ispunct (Depends-on): Add iswpunct.
7918         * tests/test-c32ispunct.c (main): Add a few more tests in the "C"
7919         locale.
7921         iswpunct: Add tests.
7922         * tests/test-iswpunct.c: New file, based on tests/test-iswdigit.c and
7923         tests/test-c32ispunct.c.
7924         * tests/test-iswpunct.sh: New file, based on tests/test-iswdigit.sh.
7925         * modules/iswpunct-tests: New file.
7927         iswpunct: New module.
7928         * lib/wctype.in.h (iswpunct): New declaration.
7929         * lib/iswpunct.c: New file.
7930         * m4/iswpunct.m4: New file.
7931         * m4/wctype_h.m4 (gl_WCTYPE_H_REQUIRE_DEFAULTS): Initialize
7932         GNULIB_ISWPUNCT.
7933         (gl_WCTYPE_H_DEFAULTS): Initialize REPLACE_ISWPUNCT.
7934         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWPUNCT,
7935         REPLACE_ISWPUNCT.
7936         * modules/iswpunct: New file.
7937         * doc/posix-functions/iswpunct.texi: Mention the new module.
7939         wctype-h tests: Add more tests.
7940         * tests/test-wctype-h.c (main): Add a sanity check of iswpunct.
7942 2023-08-29  Bruno Haible  <bruno@clisp.org>
7944         iswdigit, iswxdigit: Fix documentation.
7945         * doc/posix-functions/iswdigit.texi: Mention the module 'iswdigit'.
7946         * doc/posix-functions/iswxdigit.texi: Mention the module 'iswxdigit'.
7948 2023-08-29  Bruno Haible  <bruno@clisp.org>
7950         wctype: Fix documentation (mistake 2023-07-26).
7951         * doc/posix-functions/wctype.texi: The "blank" argument problem on mingw
7952         is now worked around by Gnulib.
7954 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
7956         trim: do not over-allocate result
7957         * lib/trim.c: Include mbuiterf.h, not mbiterf.h, since we no
7958         longer compute strlen at first.
7959         (trim2): Do not over-allocate result and then trim the parts we
7960         don’t want.  Instead, skip unwanted input before allocating,
7961         so that the result is just the right size.  Use mempcpy
7962         instead of memmove.  Simplify.
7963         * modules/trim (Depends-on): Remove mbiterf, memmove, strdup, xalloc.
7964         Add mbuiterf, mempcpy, xalloc-die.
7966 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
7968         propername: tune single-byte code
7969         * lib/propername.c (mbsstr_trimmed_wordbounded): Cache MB_CUR_MAX.
7970         Simplify word boundary detection in single-byte code.
7972 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
7974         Tune single-byte code involving tolower
7975         * lib/mbmemcasecmp.c (mbmemcasecmp):
7976         * lib/mbscasecmp.c (mbscasecmp):
7977         * lib/mbscasestr.c (mbscasestr):
7978         * lib/mbsncasecmp.c (mbsncasecmp):
7979         * lib/mbspcasecmp.c (mbspcasecmp):
7980         Avoid some unnecessary calls to tolower.  For example, if the two
7981         single-byte characters are equal before downcasing there is no
7982         need to call tolower on either character.
7984 2023-08-26  Bruno Haible  <bruno@clisp.org>
7986         c32width tests: Avoid failure on FreeBSD 12.
7987         * tests/test-c32width.c (main): Skip two tests on FreeBSD < 13.
7989 2023-08-26  Bruno Haible  <bruno@clisp.org>
7991         crypto/{sha*,md5,sm3}-buffer: Ignore too old OpenSSL versions.
7992         * lib/sha1.h: If <openssl/macros.h> would give a compile-time error,
7993         undefine HAVE_OPENSSL_SHA1.
7994         * lib/sha256.h: If <openssl/macros.h> would give a compile-time error,
7995         undefine HAVE_OPENSSL_SHA256.
7996         * lib/sha512.h: If <openssl/macros.h> would give a compile-time error,
7997         undefine HAVE_OPENSSL_SHA512.
7998         * lib/md5.h: If <openssl/macros.h> would give a compile-time error,
7999         undefine HAVE_OPENSSL_MD5.
8000         * lib/sm3.h: If <openssl/macros.h> would give a compile-time error,
8001         undefine HAVE_OPENSSL_SM3.
8003 2023-08-26  Bruno Haible  <bruno@clisp.org>
8005         selinux-h: Add a comment.
8006         * lib/se-selinux.in.h: Clarify which #endif belongs to the
8007         double-inclusion guard.
8009 2023-08-26  Bruno Haible  <bruno@clisp.org>
8011         sys_utsname: Make double-inclusion guard more robust.
8012         * lib/sys_utsname.in.h: Test the guard symbol a second time.
8014 2023-08-26  Bruno Haible  <bruno@clisp.org>
8016         sys_times: Make double-inclusion guard more robust.
8017         * lib/sys_times.in.h: Test the guard symbol a second time.
8019 2023-08-26  Bruno Haible  <bruno@clisp.org>
8021         uchar: Make #include_next work right.
8022         * lib/uchar.in.h: Use a split double-inclusion guard.
8024 2023-08-26  Paul Eggert  <eggert@cs.ucla.edu>
8026         utimens: update FIXME date
8027         * lib/utimens.c (fdutimens): Change FIXME date to agree with
8028         similar FIXME in utimensat.c.
8030 2023-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8032         exclude: refactor for more-modern style
8033         * lib/exclude.c: Sort include directives.
8034         (fnmatch_pattern_has_wildcards, file_name_matches):
8035         Prefer ‘true’ to ‘1’.
8036         (string_hasher, string_compare, string_compare_ci):
8037         Avoid unnecessary locals.
8038         (string_free): Remove.  All callers changed to just use ‘free’.
8039         (new_exclude_segment): Prefer xmalloc to xzalloc when it’s
8040         clearer to initialize ourselves.
8041         (new_exclude_segment, exclude_patopts, add_exclude_fp):
8042         Prefer nullptr to NULL.
8043         (free_exclude_segment, file_pattern_matches):
8044         Avoid unnecessary nesting.
8045         (free_exclude, fnmatch_no_wildcards, exclude_fnmatch)
8046         (excluded_file_name, add_exclude, add_exclude_fp):
8047         Assume C99 decl syntax.
8048         (fnmatch_no_wildcards): Prefer idx_t to size_t.
8049         (exclude_fnmatch, add_exclude_fp): Prefer ‘f (x)’ to ‘(*f) (x)’.
8050         (add_exclude): Help compiler by refactoring search for
8051         trailing slashes.  Avoid unnecessary cast to char *.
8052         * modules/exclude (Depends-on): Add nullptr.
8054 2023-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8056         unlocked-io: fix getc_unlocked typo
8057         * lib/unlocked-io.h (getc): Fix misspelling of ‘getc_unlocked’.
8059 2023-08-21  Bruno Haible  <bruno@clisp.org>
8061         alignasof, stdalign: Fix a compilation error in C++ mode on FreeBSD 12.
8062         * m4/stdalign.m4 (gl_ALIGNASOF): In C++ mode, prefer __builtin_offsetof
8063         over offsetof when possible, since __builtin_offsetof works also when
8064         <stddef.h> has not been fully included yet.
8066 2023-08-21  Bruno Haible  <bruno@clisp.org>
8068         wcsstr: Relicense under LGPLv2+.
8069         * modules/wcsstr (License): Change to LGPLv2+.
8071         wcsstr-simple: Relicense under LGPLv2+.
8072         * modules/wcsstr-simple (License): Change to LGPLv2+.
8073         * lib/wcsstr.c: Update license notice.
8074         * lib/wcsstr-impl.h: Update license notice. The code added here on
8075         2023-03-27 was under LGPLv2+.
8077         wmemcmp: Relicense under LGPLv2+.
8078         * modules/wmemcmp (License): Change to LGPLv2+.
8079         * lib/wmemcmp.c: Update license notice.
8080         * lib/wmemcmp-impl.h: Likewise.
8082         wcschr: Relicense under LGPLv2+.
8083         * modules/wcschr (License): Change to LGPLv2+.
8084         * lib/wcschr.c: Update license notice.
8085         * lib/wcschr-impl.h: Likewise.
8087 2023-08-21  Bruno Haible  <bruno@clisp.org>
8089         unistr/u32-strlen: Complete license change from 2023-07-23.
8090         * lib/unistr/u-strlen.h: Update license notice.
8092 2023-08-21  Bruno Haible  <bruno@clisp.org>
8094         isnanl: Relicense under LGPLv2+.
8095         * modules/isnanl (License): Change to LGPLv2+.
8097 2023-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8099         ldexp: port to non-two’s complement
8100         * lib/ldexp.c (FUNC): Don’t assume two’s-complement.
8102 2023-08-20  Bruno Haible  <bruno@clisp.org>
8104         readutmp, boot-time: Fix the result on runit and s6 init systems.
8105         * lib/boot-time-aux.h (get_linux_boot_time_fallback): Try also
8106         /var/lib/urandom/random-seed. Try /var/run/utmp last.
8108 2023-08-20  Paul Eggert  <eggert@cs.ucla.edu>
8110         ldexp: fix INT_MIN infloop
8111         * lib/ldexp.c (FUNC): Instead of converting EXP to unsigned,
8112         work on it directly.  This simplifies the code and avoids
8113         an infinite loop when EXP == INT_MIN.
8114         * modules/ldexp, modules/ldexpl: Depend on stdbool.
8115         * tests/test-ldexp.h: Include <limits.h> for INT_MIN.
8116         (test_function): Test for infloop.
8118 2023-08-20  Bruno Haible  <bruno@clisp.org>
8120         ldexp: Fix compilation error in C++ mode.
8121         * lib/math.in.h (ldexp): Use _GL_CXXALIASWARN1, not _GL_CXXALIASWARN.
8123 2023-08-19  Bruno Haible  <bruno@clisp.org>
8125         ldexp: Work around OpenBSD/mips64 bug.
8126         * lib/math.in.h (ldexp): New declaration.
8127         * lib/ldexp.c: New file, based on lib/ldexpl.c.
8128         * lib/ldexpl.c: Moved the implementation to lib/ldexp.c. Just include
8129         it.
8130         * m4/math_h.m4 (gl_MATH_H_REQUIRE_DEFAULTS): Initialize GNULIB_LDEXP.
8131         (gl_MATH_H_DEFAULTS): Initialize REPLACE_LDEXP.
8132         * m4/ldexp.m4 (gl_FUNC_LDEXP): Require gl_MATH_H_DEFAULTS and
8133         gl_FUNC_ISNAND. Invoke gl_FUNC_LDEXP_WORKS. Set REPLACE_LDEXP. Consider
8134         it when setting LDEXP_LIBM.
8135         (gl_FUNC_LDEXP_WORKS): New macro.
8136         * modules/math (Makefile.am): Substitute GNULIB_LDEXP, REPLACE_LDEXP.
8137         * modules/ldexp (Files): Add lib/ldexp.c.
8138         (Depends-on): Add math, isnand.
8139         (configure.ac): Set GL_COND_OBJ_LDEXP. Invoke gl_MATH_MODULE_INDICATOR.
8140         (Makefile.am): Conditionally compile ldexp.c.
8141         * modules/ldexpl (Files): Add lib/ldexp.c.
8142         * doc/posix-functions/ldexp.texi: Mention the OpenBSD bug.
8144 2023-08-19  Bruno Haible  <bruno@clisp.org>
8146         ldexpl: Relicense under LGPLv2+.
8147         * modules/ldexpl (License): Change to LGPLv2+.
8148         * lib/ldexpl.c: Update license notice.
8150 2023-08-19  Bruno Haible  <bruno@clisp.org>
8152         isnand: Relicense under LGPLv2+.
8153         * modules/isnand (License): Change to LGPLv2+.
8155 2023-08-19  Bruno Haible  <bruno@clisp.org>
8157         ldexpl: Avoid possible -Wshadow warning.
8158         * lib/ldexpl.c (exp): Locally rename to 'exponent'.
8160         ldexpl: Fix signed integer overflow.
8161         * lib/ldexpl.c (ldexpl): Use an 'unsigned int' variable to represent the
8162         absolute value of exp without overflow.
8164 2023-08-19  Bruno Haible  <bruno@clisp.org>
8166         logbl: Work around endless loop on OpenBSD 7.3/mips64.
8167         * m4/logbl.m4 (gl_FUNC_LOGBL_WORKS): Terminate the test program if it
8168         takes longer than 5 seconds.
8169         * doc/posix-functions/logbl.texi: Mention the OpenBSD bug.
8171 2023-08-18  Bruno Haible  <bruno@clisp.org>
8173         thrd: Work around thrd_join bug on AIX 7.3.1.
8174         * m4/threads_h.m4 (gl_THREADS_H): Test against AIX 7 thrd_join bug. Set
8175         BROKEN_THRD_JOIN.
8176         (gl_THREADS_H_DEFAULTS): Initialize BROKEN_THRD_JOIN.
8177         * m4/thrd.m4 (gl_FUNC_THRD_JOIN): Set REPLACE_THRD_* to 1 also if
8178         BROKEN_THRD_JOIN is 1. Define BROKEN_THRD_START_T_OR_JOIN instead of
8179         BROKEN_THRD_START_T.
8180         * modules/threads-h (Makefile.am): Substitute BROKEN_THRD_JOIN.
8181         * lib/threads.in.h (rpl_thrd_t, thrd_t): Define also if BROKEN_THRD_JOIN
8182         is 1.
8183         * lib/thrd.c: Test BROKEN_THRD_START_T_OR_JOIN instead of
8184         BROKEN_THRD_START_T.
8185         * doc/posix-functions/thrd_join.texi: Update.
8186         * doc/posix-functions/thrd_exit.texi: Likewise.
8188         thrd: Refactor.
8189         * m4/thrd.m4 (gl_FUNC_THRD_JOIN): Define BROKEN_THRD_JOIN_NULL, not
8190         BROKEN_THRD_JOIN. Rename gl_cv_func_thrd_join_works to
8191         gl_cv_func_thrd_join_null_works.
8192         * lib/thrd.c: Test BROKEN_THRD_JOIN_NULL instead of BROKEN_THRD_JOIN.
8194 2023-08-18  Bruno Haible  <bruno@clisp.org>
8196         thrd tests: Add unit test for thrd_exit.
8197         * tests/test-thrd_exit.c: New file, based on tests/test-thrd_create.c.
8198         * modules/thrd-tests (Files): Add it.
8199         (Makefile.am): Compile and run it.
8201         thrd: On AIX 7.1 and 7.2, override also thrd_exit.
8202         * lib/threads.in.h (thrd_exit): Consider REPLACE_THRD_EXIT.
8203         * lib/thrd.c (rpl_thrd_exit): New function.
8204         * m4/threads_h.m4 (gl_THREADS_H_DEFAULTS): Initialize REPLACE_THRD_EXIT.
8205         * m4/thrd.m4 (gl_FUNC_THRD_JOIN): Set also REPLACE_THRD_EXIT and adjust
8206         LIBSTDTHREAD.
8207         * modules/threads-h (Makefile.am): Substitute REPLACE_THRD_EXIT.
8208         * doc/posix-functions/thrd_exit.texi: Mention the AIX thrd_join problem
8209         also here.
8211 2023-08-18  Bruno Haible  <bruno@clisp.org>
8213         aligned_alloc: Fix test failure on AIX 7.3 with ibm-clang.
8214         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Use 'volatile', to
8215         disable optimization of ibm-clang -O2.
8216         * doc/posix-functions/aligned_alloc.texi: Update version info.
8218 2023-08-18  Bruno Haible  <bruno@clisp.org>
8220         sys_socket: Fix compilation errors in C++ mode on AIX 7.3 with gcc.
8221         * lib/sys_socket.in.h (accept, getpeername, getsockname, recvfrom):
8222         Disable _GL_CXXALIASWARN invocation on non-glibc systems.
8224 2023-08-18  Bruno Haible  <bruno@clisp.org>
8226         stddef: Don't unnecessarily override max_align_t on AIX 7.3 with gcc.
8227         * lib/stddef.in.h (max_align_t, GNULIB_defined_max_align_t): Don't
8228         define or override if HAVE_MAX_ALIGN_T is 1.
8230 2023-08-18  Bruno Haible  <bruno@clisp.org>
8232         uptime: Deprecate.
8233         Suggested by Paul Eggert in
8234         <https://lists.gnu.org/archive/html/bug-coreutils/2023-08/msg00070.html>.
8235         * modules/uptime (Status, Notice): New sections.
8237 2023-08-17  Bruno Haible  <bruno@clisp.org>
8239         Recognize the *-*-windows* config triplets introduced on 2023-06-26.
8240         * m4/*.m4: Treat windows* as equivalent to mingw*.
8241         * modules/*: Likewise.
8243 2023-08-16  Bruno Haible  <bruno@clisp.org>
8245         mbrtoc32-regular: Make it work as expected on glibc 2.12.
8246         * lib/mbrtoc32.c (mbrtoc32): If necessary, clear the mbstate_t after
8247         mbrtowc() returned.
8249 2023-08-16  Bruno Haible  <bruno@clisp.org>
8251         fnmatch: Override fnmatch from glibc versions < 2.22.
8252         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Force REPLACE_FNMATCH=1 in
8253         glibc versions < 2.22.
8255 2023-08-16  Bruno Haible  <bruno@clisp.org>
8257         tests: Avoid some test failures on Slackware 13.37.
8258         * tests/test-c32isalnum.c (main): Disable GB18030 tests on
8259         glibc 2.13..2.15.
8260         * tests/test-c32isalpha.c (main): Likewise.
8261         * tests/test-c32isblank.c (main): Likewise.
8262         * tests/test-c32iscntrl.c (main): Likewise.
8263         * tests/test-c32isdigit.c (main): Likewise.
8264         * tests/test-c32isgraph.c (main): Likewise.
8265         * tests/test-c32islower.c (main): Likewise.
8266         * tests/test-c32isprint.c (main): Likewise.
8267         * tests/test-c32ispunct.c (main): Likewise.
8268         * tests/test-c32isspace.c (main): Likewise.
8269         * tests/test-c32isupper.c (main): Likewise.
8270         * tests/test-c32isxdigit.c (main): Likewise.
8271         * tests/test-c32rtomb.c (main): Likewise.
8272         * tests/test-c32snrtombs.c (main): Likewise.
8273         * tests/test-c32srtombs.c (main): Likewise.
8274         * tests/test-c32stombs.c (main): Likewise.
8275         * tests/test-c32tolower.c (main): Likewise.
8276         * tests/test-c32toupper.c (main): Likewise.
8277         * tests/test-fnmatch.c (main): Likewise.
8278         * tests/test-mbrtoc16.c (main): Likewise.
8279         * tests/test-mbrtoc32.c (main): Likewise.
8280         * tests/test-mbsnrtoc32s.c (main): Likewise.
8281         * tests/test-mbsrtoc32s.c (main): Likewise.
8282         * tests/test-mbstoc32s.c (main): Likewise.
8284 2023-08-15  Bruno Haible  <bruno@clisp.org>
8286         readutmp tests: Add test against today's bug.
8287         * tests/test-readutmp.c (main): Verify that there is exactly one
8288         BOOT_TIME entry.
8290         readutmp: Fix for platforms without ut_type (regression 2023-08-08).
8291         * lib/readutmp.h (UT_TYPE_BOOT_TIME, UT_TYPE_USER_PROCESS): Don't use
8292         UT_TYPE_EQ macro.
8293         (IS_USER_PROCESS): Don't use UT_USER, UT_TYPE_NOT_DEFINED macros.
8294         * lib/readutmp.c (IS_USER_PROCESS): Don't override.
8296 2023-08-14  Bruno Haible  <bruno@clisp.org>
8298         readutmp, boot-time: Don't use __UT_* symbols (regression 2023-08-11).
8299         * lib/readutmp.h (_GL_UT_USER_SIZE, _GL_UT_ID_SIZE, _GL_UT_LINE_SIZE,
8300         _GL_UT_HOST_SIZE): New macros.
8301         (struct utmpx32): Use them.
8303 2023-08-14  Bruno Haible  <bruno@clisp.org>
8305         readutmp, boot-time: Fix build on 32-bit glibc (regression 2023-08-11).
8306         Reported by Andreas Schwab <schwab@suse.de> in
8307         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00125.html>.
8308         * lib/readutmp.h (struct utmpx32): Reference __UT_NAMESIZE, not
8309         __UT_USERSIZE.
8311 2023-08-13  Bruno Haible  <bruno@clisp.org>
8313         stdint: Fix configure test result with gcc 4.7 or 4.8.
8314         * m4/stdint.m4 (gl_STDINT_H): Don't assume that _Generic works with
8315         GCC versions < 4.9 with -std=gnu11.
8317 2023-08-13  Bruno Haible  <bruno@clisp.org>
8319         Fix some test module descriptions.
8320         * modules/boot-time-tests (Files): Add tests/macros.h.
8321         * modules/dprintf-gnu-tests (Files): Likewise.
8322         * modules/fclose-tests (Files): Likewise.
8323         * modules/getcwd-tests (Files): Likewise.
8324         * modules/lock-tests (Files): Likewise.
8325         * modules/nullptr-c++-tests (Files): Likewise.
8326         * modules/posix_spawn-tests (Files): Likewise.
8327         * modules/posix_spawnp-tests (Files): Likewise.
8328         * modules/readutmp-tests (Files): Likewise.
8329         * modules/sh-quote-tests (Files): Likewise.
8330         * modules/unigbrk/u16-grapheme-breaks-tests (Files): Likewise.
8331         * modules/unigbrk/u16-grapheme-next-tests (Files): Likewise.
8332         * modules/unigbrk/u16-grapheme-prev-tests (Files): Likewise.
8333         * modules/unigbrk/u32-grapheme-breaks-tests (Files): Likewise.
8334         * modules/unigbrk/u32-grapheme-next-tests (Files): Likewise.
8335         * modules/unigbrk/u32-grapheme-prev-tests (Files): Likewise.
8336         * modules/unigbrk/u8-grapheme-breaks-tests (Files): Likewise.
8337         * modules/unigbrk/u8-grapheme-next-tests (Files): Likewise.
8338         * modules/unigbrk/u8-grapheme-prev-tests (Files): Likewise.
8339         * modules/unigbrk/uc-grapheme-breaks-tests (Files): Likewise.
8341 2023-08-13  Bruno Haible  <bruno@clisp.org>
8343         nproc, physmem: Use sysctl() as a fallback on GNU/kFreeBSD.
8344         * lib/nproc.c: Do include <sys/sysctl.h> on GNU/kFreeBSD.
8345         (num_processors_ignoring_omp): Call sysctl on GNU/kFreeBSD.
8346         * lib/physmem.c: Do include <sys/sysctl.h> on GNU/kFreeBSD.
8347         (physmem_total, physmem_available): Call sysctl on GNU/kFreeBSD.
8349 2023-08-13  Bruno Haible  <bruno@clisp.org>
8351         physmem: Add tests.
8352         * tests/test-physmem.c: New file.
8353         * modules/physmem-tests: New file.
8355 2023-08-13  Bruno Haible  <bruno@clisp.org>
8357         readutmp, boot-time: Fix warning on glibc 2.30..2.31 on Linux.
8358         Reported by Pádraig Brady in
8359         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00110.html>.
8360         * lib/readutmp.c: Don't include <sys/sysctl.h> on glibc/Linux.
8361         * lib/boot-time.c: Likewise.
8363 2023-08-13  Paul Eggert  <eggert@cs.ucla.edu>
8365         fts: improve memory-allocation errno handling
8366         * lib/fts.c (fts_read, fts_build): When enter_dir or setup_dir
8367         fails, report its errno value back to the user.
8368         (internal_function): Preserve errno.
8369         * modules/fts (Depends-on): Add calloc-posix, free-posix,
8370         malloc-posix, and realloc-posix, for better errno handling
8371         on allocation failures.
8373         hash: set errno on failure
8374         * lib/hash.c: Include errno.h.
8375         (compute_bucket_size, hash_initialize, hash_rehash)
8376         (hash_insert_if_absent): Set errno reliably on failure.
8377         (hash_free): Preserve errno, like plain 'free'.
8378         * modules/hash (Depends-on): Depend on calloc-posix,
8379         free-posix, malloc-posix, so that errno is set reliably.
8381 2023-08-13  Bruno Haible  <bruno@clisp.org>
8383         readutmp, boot-time: Fix compilation error on old Android.
8384         Reported by Po Lu in
8385         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00108.html>.
8386         * lib/readutmp.h (BOOT_TIME): Add fallback.
8388 2023-08-13  Bruno Haible  <bruno@clisp.org>
8390         readutmp, boot-time: Fix compilation error on Android API 8.
8391         Reported by Po Lu in
8392         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00108.html>.
8393         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test whether sysinfo is
8394         declared.
8395         * lib/boot-time-aux.h (get_linux_uptime): Invoke sysinfo only if it is
8396         declared.
8397         * doc/glibc-functions/sysinfo.texi: Mention the Android problem.
8399 2023-08-13  Bruno Haible  <bruno@clisp.org>
8401         readutmp, boot-time: Fix compilation error on old Android.
8402         Reported by Po Lu in
8403         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00108.html>.
8404         * lib/readutmp.c (endutent): New fallback declaration, for Android.
8405         (getutent): Remove Ultrix workaround from 2000-04-05.
8406         * lib/boot-time.c: Likewise.
8407         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test whether endutent is
8408         declared, not getutent.
8409         * doc/glibc-functions/endutent.texi: Mention the Android bug.
8411 2023-08-12  Paul Eggert  <eggert@cs.ucla.edu>
8413         boot-time,readutmp: do not depend on c-strtod
8414         * lib/boot-time-aux.h (get_linux_uptime): Compute struct timespec
8415         using integer arithmetic rather than double.
8416         * lib/boot-time.c, lib/readutmp.c: Don’t include c-strtod.h.
8417         * modules/boot-time, modules/readutmp (Depends-on): Remove c-strtod.
8419         boot-time,readutmp: remove -lrt usage
8420         This code uses clock-relevant functions only on platforms
8421         that do not need -lrt.
8422         * m4/readutmp.m4 (gl_READUTMP): Do not require gl_CLOCK_TIME
8423         or add CLOCK_TIME_LIB to READUTMP_LIB.
8424         * modules/boot-time (Link): No need to link with CLOCK_TIME_LIB.
8426         boot-time,readutmp: do not depend on fopen-gnu
8427         These modules should work well enough even if fopen is not fixed
8428         to conform to fopen-gnu standards.  The only gotcha I can see is
8429         older fopen implementations that lack support for "e", and
8430         a potential O_CLOEXEC leak is not worth worrying about.
8431         * modules/boot-time (Depends-on):
8432         * modules/readutmp (Depends-on):
8433         Remove fopen-gnu.
8435         readutmp: do not depend on timespec_get
8436         boot-time code no longer needs it.
8437         * modules/readutmp (Depends-on): Remove timespec_get.
8439         boot-time: do not depend on timespec_get
8440         This is for Emacs, which does not use timespec_get now
8441         and which likes to minimize dependencies.
8442         Also, treat musl libc like recent glibc,
8443         and fix a timespec_get return value typo.
8444         * lib/boot-time-aux.h (get_linux_uptime):
8445         Assume musl libc supports CLOCK_BOOTTIME.
8446         (get_linux_boot_time_final_fallback):
8447         Likewise for musl libc and CLOCK_REALTIME.
8448         Do not rely on the timespec_get module, to break the dependency.
8449         Consider 0 to be a failure return from timespec_get.
8450         Fall back on gettimeofday if timespec_get does not exist.
8451         * modules/boot-time (Depends-on): Remove timespec_get.
8453 2023-08-12  Bruno Haible  <bruno@clisp.org>
8455         readutmp, boot-time: Fix parsing of /proc/uptime.
8456         * lib/boot-time-aux.h (get_linux_uptime): Use c_strtod, not strtod.
8457         * lib/readutmp.c: Include c-strtod.h.
8458         * lib/boot-time.c: Likewise.
8459         * modules/readutmp (Depends-on): Add c-strtod.
8460         * modules/boot-time (Depends-on): Likewise.
8462 2023-08-12  Bruno Haible  <bruno@clisp.org>
8464         readutmp: On Linux, don't fail if /var/run/utmp is not accessible.
8465         * lib/boot-time-aux.h (get_linux_boot_time_final_fallback): Don't test
8466         NEED_BOOT_TIME_FINAL_FALLBACK.
8467         * lib/boot-time.c (NEED_BOOT_TIME_FINAL_FALLBACK): Remove macro.
8468         * lib/readutmp.c (NEED_BOOT_TIME_FINAL_FALLBACK): Remove macro.
8469         (read_utmp_from_file): As a fallback on Linux, invoke
8470         get_linux_boot_time_final_fallback.
8471         (get_boot_time_uncached): Don't do it here.
8472         * m4/readutmp.m4 (gl_READUTMP): Add $CLOCK_TIME_LIB to READUTMP_LIB.
8474 2023-08-12  Bruno Haible  <bruno@clisp.org>
8476         readutmp, boot-time: On Haiku, return the boot time.
8477         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test whether <OS.h> exists.
8478         * lib/boot-time-aux.h (get_haiku_boot_time,
8479         get_haiku_boot_time_final_fallback): New functions.
8480         * lib/readutmp.c: Include <OS.h>.
8481         (read_utmp_from_file): If opening UTMP_FILE fails, continue processing
8482         instead of failing. Invoke get_haiku_boot_time and
8483         get_haiku_boot_time_final_fallback.
8484         * lib/boot-time.c: Include <OS.h>.
8485         (get_boot_time_uncached): Invoke get_haiku_boot_time and
8486         get_haiku_boot_time_final_fallback.
8488 2023-08-12  Bruno Haible  <bruno@clisp.org>
8490         readutmp: Reduce code duplication.
8491         * lib/readutmp.c (have_boot_time): New function.
8492         (read_utmp_from_file): Invoke it, instead of duplicating the same loop.
8494 2023-08-12  Paul Eggert  <eggert@cs.ucla.edu>
8496         c-file-type: new module
8497         * lib/c-file-type.c: New file, containing all of the
8498         old file-type except for the gettext call.
8499         * lib/file-type.c (_): Remove; no longer used.
8500         (file_type): Call c_file_type for most of the work.
8501         * modules/c-file-type: New module.
8502         * modules/file-type (Depends-on): Add c-file-type.
8504 2023-08-12  Bruno Haible  <bruno@clisp.org>
8506         readutmp, boot-time: Use the BSD sysctl as fallback.
8507         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): Test for <sys/param.h>,
8508         <sys/sysctl.h>, sysctl.
8509         * lib/boot-time-aux.h (get_bsd_boot_time_final_fallback): New function.
8510         * lib/readutmp.c: Include <sys/param.h> and <sys/sysctl.h>.
8511         (read_utmp_from_file): Invoke get_bsd_boot_time_final_fallback as a
8512         fallback.
8513         * lib/boot-time.c: Include <sys/param.h> and <sys/sysctl.h>.
8514         (get_boot_time_uncached): Invoke get_bsd_boot_time_final_fallback as a
8515         fallback.
8517 2023-08-12  Bruno Haible  <bruno@clisp.org>
8519         readutmp: Fix compilation error on OpenBSD (regression 2023-08-11).
8520         * lib/readutmp.c (read_utmp_from_file): Remove extraneous 'break'
8521         statement.
8523 2023-08-11  Bruno Haible  <bruno@clisp.org>
8525         boot-time: Add comment about multithread-safety.
8526         * lib/boot-time.h (get_boot_time): Add comment, same as in readutmp.h.
8528 2023-08-11  Bruno Haible  <bruno@clisp.org>
8530         boot-time: Simplify execution.
8531         * lib/boot-time.c: Include <stdio.h>, <string.h>, <sys/types.h>,
8532         <sys/stat.h>, <sys/sysinfo.h>, <time.h>, stat-time.h, unlocked-io.h,
8533         boot-time-aux.h.
8534         (UT_USER): New macro, from lib/readutmp.c.
8535         (getutent): New declaration.
8536         (get_boot_time_uncached): New function, containing a simplified code
8537         from lib/readutmp.c.
8538         (get_boot_time): Don't invoke read_utmp. Instead, invoke
8539         get_boot_time_uncached and cache the result.
8540         * modules/boot-time (Files): Add lib/boot-time-aux.h, lib/readutmp.h,
8541         m4/readutmp.m4.
8542         (Depends-on): Remove readutmp. Add extensions, fopen-gnu, stat-time,
8543         stdbool, time-h, timespec_get, unlocked-io-internal.
8544         (configure.ac): Invoke gl_PREREQ_READUTMP_H.
8545         (Link): Remove $(READUTMP_LIB). Add $(CLOCK_TIME_LIB).
8546         * modules/boot-time-tests (Makefile.am): Link test-boot-time with
8547         $(CLOCK_TIME_LIB), not with $(READUTMP_LIB).
8549 2023-08-11  Bruno Haible  <bruno@clisp.org>
8551         readutmp: Refactor boot time determination code.
8552         * lib/boot-time-aux.h: New file, extracted from lib/readutmp.c.
8553         * lib/readutmp.c: On Linux, include <sys/sysinfo.h> even if
8554         !READUTMP_USE_SYSTEMD.
8555         Include boot-time-aux.h.
8556         (SIZEOF): Remove macro, moved to boot-time-aux.h.
8557         (get_linux_uptime): Remove function, moved to boot-time-aux.h.
8558         (read_utmp_from_file): Invoke get_linux_boot_time_fallback,
8559         get_android_boot_time, get_openbsd_boot_time, get_windows_boot_time.
8560         Code moved to boot-time-aux.h.
8561         (get_boot_time_uncached: Invoke get_linux_boot_time_final_fallback.
8562         Code moved to boot-time-aux.h.
8563         * m4/readutmp.m4 (gl_PREREQ_READUTMP_H): New macro, extracted from
8564         gl_READUTMP.
8565         (gl_READUTMP): Invoke it.
8566         * modules/readutmp (Files): Add lib/boot-time-aux.h.
8568 2023-08-11  Bruno Haible  <bruno@clisp.org>
8570         readutmp: Make 'struct utmpx32' usable by other code.
8571         * lib/readutmp.h (struct utmpx32): Moved to here from lib/readutmp.c.
8572         (UTMP_STRUCT_NAME): Define as utmpx32 if needed.
8573         * lib/readutmp.c (read_utmp_from_file): Simply use UTMP_STRUCT_NAME.
8575 2023-08-11  Bruno Haible  <bruno@clisp.org>
8577         readutmp tests: Fix link error.
8578         * modules/readutmp-tests (Makefile.am): Link test-readutmp with
8579         $(LIBINTL).
8581 2023-08-11  Bruno Haible  <bruno@clisp.org>
8583         readutmp: Fix the boot time returned on Minix.
8584         * lib/readutmp.c (read_utmp_from_file): [__minix] When the time of the
8585         BOOT_TIME entry is very close to the Epoch, replace it with the time
8586         from the "run-level m" entry.
8588 2023-08-11  Bruno Haible  <bruno@clisp.org>
8590         readutmp: On Cygwin and Windows, return the boot time.
8591         * lib/readutmp.h (READ_UTMP_SUPPORTED): Define also on native Windows.
8592         * lib/readutmp.c (desirable_utmp_entry): Ignore READ_UTMP_CHECK_PIDS on
8593         Windows.
8594         (read_utmp_from_file): Add a BOOT_TIME entry on Windows.
8596 2023-08-11  Bruno Haible  <bruno@clisp.org>
8598         clock-time: On mingw, avoid buggy clock_gettime from libwinpthread.
8599         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_CANONICAL_HOST. On
8600         native Windows, avoid using clock_getres clock_gettime clock_settime
8601         from mingw's libwinpthread.
8602         * doc/posix-functions/clock_gettime.texi: Mention the mingw bug.
8604 2023-08-10  Bruno Haible  <bruno@clisp.org>
8606         readutmp: Make the header file includable from C++.
8607         * lib/readutmp.h: Add extern "C" block.
8609 2023-08-10  Bruno Haible  <bruno@clisp.org>
8611         readutmp: Tweak the Android specific addition.
8612         * lib/readutmp.c (read_utmp_from_file) [__ANDROID__]: Don't fake a
8613         BOOT_TIME entry if the options request to omit it or if a BOOT_TIME
8614         entry is already present.
8616 2023-08-10  Bruno Haible  <bruno@clisp.org>
8618         readutmp: Fix the boot time returned on Raspbian.
8619         * lib/readutmp.c (read_utmp_from_file): When the time of the BOOT_TIME
8620         entry is very close to the Epoch, replace it with the time from the
8621         "runlevel"/"~" entry.
8623 2023-08-10  Bruno Haible  <bruno@clisp.org>
8625         boot-time: Add tests.
8626         * tests/test-boot-time.c: New file.
8627         * modules/boot-time-tests: New file.
8629         boot-time: New module.
8630         * lib/boot-time.h: New file.
8631         * lib/boot-time.c: New file.
8632         * modules/boot-time: New file.
8634 2023-08-10  Bruno Haible  <bruno@clisp.org>
8636         readutmp: Return a boot time also on Android.
8637         * lib/readutmp.c (get_linux_uptime): New function, extracted from
8638         get_boot_time_uncached.
8639         (read_utmp_from_file): Don't look for file time stamps on Android.
8640         Instead, use get_linux_uptime.
8641         (get_boot_time_uncached): Use get_linux_uptime.
8643 2023-08-09  Bruno Haible  <bruno@clisp.org>
8645         readutmp: Fix a mistake (regression 2023-08-08).
8646         * lib/readutmp.c (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED): Fix a typo.
8648         readutmp: Return a boot time also on OpenBSD.
8649         * lib/readutmp.h (BOOT_TIME, USER_PROCESS): Provide fallback
8650         definitions.
8651         * lib/readutmp.c (read_utmp_from_file) [__OpenBSD__]: Fake a BOOT_TIME
8652         entry by looking at the time stamp of a specific file.
8654         readutmp: Return a boot time also on Alpine Linux.
8655         * lib/readutmp.c: Include stat-time.h.
8656         (SIZEOF): New macro.
8657         (read_utmp_from_file) [__linux__]: Fake a BOOT_TIME entry by looking
8658         at the time stamp of a specific file.
8659         * modules/readutmp (Depends-on): Add stat-time.
8661         readutmp: Fix boot time in VMs after sleep state and date update.
8662         * lib/readutmp.c (read_utmp_from_file): New function, extracted from
8663         read_utmp.
8664         (get_boot_time_uncached): Before all other approaches, try to find the
8665         boot time in the /var/run/utmp file.
8666         (read_utmp): Invoke read_utmp_from_file.
8668         readutmp: Make it easier to filter for/against the boot-time entry.
8669         * lib/readutmp.h (READ_UTMP_BOOT_TIME, READ_UTMP_NO_BOOT_TIME): New
8670         enum items.
8671         * lib/readutmp.c (desirable_utmp_entry, read_utmp_from_systemd):
8672         Implement them.
8673         (read_utmp): If no entries can match the given options, return
8674         immediately.
8676 2023-08-08  Paul Eggert  <eggert@cs.ucla.edu>
8678         readutmp: omit pragma
8679         * lib/readutmp.c: Omit -Wstringop-overread pragma.
8680         It’s no longer needed now that extract_trimmed_name
8681         no longer calls strnlen.
8683 2023-08-08  Bruno Haible  <bruno@clisp.org>
8685         readutmp: Use classical implementation for files != /var/run/utmp.
8686         * lib/readutmp.c (read_utmp_from_systemd): Renamed from read_utmp
8687         [READUTMP_USE_SYSTEMD]. Remove file argument.
8688         (read_utmp): Call it when the file argument is "/var/run/utmp".
8690 2023-08-08  Bruno Haible  <bruno@clisp.org>
8692         readutmp: Get the boot time with higher precision.
8693         Suggested by Thorsten Kukuk <kukuk@suse.com> in
8694         <https://github.com/thkukuk/utmpx/blob/main/utmp-to-logind.md#determine-boot-time>.
8695         * lib/readutmp.c (get_boot_time_uncached): Try clock_gettime first.
8697 2023-08-08  Bruno Haible  <bruno@clisp.org>
8699         readutmp: Add comment about multithread-safety.
8700         * lib/readutmp.h (read_utmp): Add comment.
8702 2023-08-08  Bruno Haible  <bruno@clisp.org>
8704         readutmp: Return entries with unbounded strings on all platforms.
8705         Suggested  by Paul Eggert in
8706         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00165.html>.
8707         * m4/readutmp.m4 (gl_READUTMP): Test also whether struct utmp has an
8708         ut_tv member, and whether struct utmp and struct utmpx have an
8709         ut_session member.
8710         * lib/readutmp.h (struct gl_utmp): Define always. Add ut_exit field.
8711         (HAVE_GL_UTMP): Remove macro.
8712         (UT_USER, UT_TIME_MEMBER, UT_PID, UT_TYPE_EQ, UT_TYPE_NOT_DEFINED,
8713         UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT, STRUCT_UTMP): Define w.r.t.
8714         struct gl_utmp.
8715         (UT_USER_SIZE, UT_ID_SIZE, UT_LINE_SIZE, UT_HOST_SIZE): Define to -1
8716         always.
8717         (getutent): Remove declaration.
8718         (HAVE_STRUCT_XTMP_UT_EXIT): Remove unused macro.
8719         (HAVE_STRUCT_XTMP_UT_ID, HAVE_STRUCT_XTMP_UT_PID,
8720         HAVE_STRUCT_XTMP_UT_HOST): Change to match the way coreutils uses these
8721         macros.
8722         * lib/readutmp.c (UT_USER, UT_TIME_MEMBER, UT_PID, UT_TYPE_EQ,
8723         UT_TYPE_NOT_DEFINED, IS_USER_PROCESS, UT_EXIT_E_TERMINATION,
8724         UT_EXIT_E_EXIT, UT_USER_SIZE, UT_ID_SIZE, UT_LINE_SIZE, UT_HOST_SIZE):
8725         Define w.r.t. struct utmpx or struct utmp.
8726         (extract_trimmed_name): Don't use UT_USER or UT_USER_SIZE here.
8727         (desirable_utmp_entry): Don't use UT_TIME_MEMBER or UT_USER here.
8728         (struct utmp_alloc): Define always.
8729         (add_utmp): Likewise. Add user_len, id_len, line_len, host_len,
8730         termination, exit arguments. Don't require that user, id, line, host are
8731         NUL-terminated. Assume user and host are non-NULL.
8732         (finish_utmp): New function, extracted from read_utmp.
8733         (read_utmp) [READUTMP_USE_SYSTEMD]: Update add_utmp invocations. Pass a
8734         non-NULL user and a non-NULL host. Call finish_utmp.
8735         (getutent): Move declaration from readutmp.h to here.
8736         (copy_utmp_entry): Remove function.
8737         (read_utmp) [UTMP_NAME_FUNCTION]: Replace variables n_read, n_alloc,
8738         utmp with a 'struct utmp_alloc'. Use 'struct utmpx32' from
8739         copy_utmp_entry here. Invoke add_utmp and finish_utmp.
8740         (read_utmp) [!UTMP_NAME_FUNCTION]: Replace variables n_read, n_alloc,
8741         utmp with a 'struct utmp_alloc'. Invoke add_utmp and finish_utmp.
8742         * NEWS: Mention the API change.
8744 2023-08-08  Bruno Haible  <bruno@clisp.org>
8746         readutmp: Fix compilation error on OpenBSD and AIX (regr. 2023-08-03).
8747         * lib/readutmp.h (UT_TIME_MEMBER) [HAVE_UTMP_H]: Revert last change.
8749 2023-08-08  Bruno Haible  <bruno@clisp.org>
8751         readutmp: Fix compilation error on OpenBSD (regr. 2023-08-02).
8752         * lib/readutmp.h (UT_ID_SIZE): Define to a dummy if there is no ut_id
8753         field.
8755 2023-08-07  Paul Eggert  <eggert@cs.ucla.edu>
8757         quotearg: fix obsolete comment
8758         * lib/quotearg.h: Fix comment to match behavior.
8759         This fixes a commentary bug introduced in
8760         commit 1a43a982c927eaf26bbc2701a872009d9be4b33b
8761         "quotearg: do not use grave accent for left quote"
8762         dated 2011-12-18 15:44:17+01, where the comment
8763         was not updated to match the changed behavior.
8765 2023-08-06  Paul Eggert  <eggert@cs.ucla.edu>
8767         readutmp: fix comment bug ID
8768         * lib/readutmp.c: Fix comment (thanks to Bruno Haible).
8770         doc: Document lack of printf "%n" on Android, OpenBSD.
8771         * doc/posix/functions/*printf.texi: Document that the POSIX-specified
8772         printf functions do not support the %n format on Android and OpenBSD.
8773         This lack of support is deliberate, as %n is a common target of attacks
8774         on security.
8776 2023-08-05  Paul Eggert  <eggert@cs.ucla.edu>
8778         readutmp: anticipate Y2038 hack for utmp
8779         * lib/readutmp.c (struct utmpx32): Use unsigned int for tv_sec,
8780         not int, as that is more likely to work after 2038.
8781         Suggested by Andreas Schwab in:
8782         https://sourceware.org/pipermail/libc-alpha/2023-August/150661.html
8784         diffseq: simplify lint removal
8785         * lib/diffseq.h (IF_LINT): Remove.
8786         Instead, always ignore the diagnostic, as that’s simpler
8787         now that we have the pragma change installed in May.
8788         This removes the last IF_LINT from diffutils, though not
8789         the last use of GCC_LINT.
8791 2023-08-04  Bruno Haible  <bruno@clisp.org>
8793         unistr/{u8-mbtouc,u8-mbsnlen}: Fix test failures (regr. 2023-07-25).
8794         * modules/unistr/u8-mbtouc (configure.ac): Compile this code if the
8795         preinstalled libunistring version is >= 0.9.4, < 1.2.
8796         * modules/unistr/u8-mbsnlen (configure.ac): Likewise.
8798         unistr/*-pcpy: Fix compilation errors (regression 2023-07-21).
8799         * modules/unistr/base (configure.ac): Generate unistr.h if the
8800         preinstalled libunistring version is >= 0.9.11, < 1.2.
8802 2023-08-04  Bruno Haible  <bruno@clisp.org>
8804         readutmp: In systemd mode, fix the ut_host contents (regr. yesterday).
8805         * lib/readutmp.c (add_utmp): Fix ut_host contents.
8806         * tests/test-readutmp.c (main): Show also the contents of the ut_host
8807         field.
8809 2023-08-04  Bruno Haible  <bruno@clisp.org>
8811         readutmp: Ensure multithread-safety.
8812         * lib/readutmp.c (get_boot_time): Initialize 'cached' after 'boot_time',
8813         not before. Also declare both as volatile.
8815 2023-08-04  Bruno Haible  <bruno@clisp.org>
8817         readutmp tests: Fix gcc warning (regression from yesterday).
8818         * tests/test-readutmp.c: Include idx.h.
8819         (main): Use idx_t instead of size_t.
8821 2023-08-03  Paul Eggert  <eggert@cs.ucla.edu>
8823         readutmp: systemd supports only UTMP_FILE
8824         * lib/readutmp.c (read_utmp): Fail if not UTMP_FILE.
8825         * m4/systemd.m4 (gl_SYSTEMD_CHOICE): Default to no for now,
8826         since yes means "who /var/log/wtmp" stops working.
8828         readutmp: switch new struct to struct timespec
8829         * lib/readutmp.c (get_boot_time_uncached, get_boot_time)
8830         (add_utmp, read_utmp):
8831         Use struct timespec, not struct timeval.
8832         * lib/readutmp.h: Always include <time.h>, for struct timespec.
8833         Simplify when utmp.h and utmpx.h are included.
8834         (struct gl_utmp): Use the same struct for both the
8835         systemd and the dummy version.  Reorder members, and
8836         use proper pid_t type for ut_session.  Rename ut_tv to ut_ts
8837         and make it a struct timespec.  All uses changed.
8838         (HAVE_GL_UTMP): New macro.  Use it where appropriate, instead
8839         of READUTMP_USE_SYSTEMD.
8840         (UT_USER, HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID)
8841         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_HOST):
8842         Simplify.
8843         * modules/readutmp (Depends-on): Add time-h, timespec_get.
8844         Remove sys_type.  Sort.
8846         readutmp: fix # indentation
8847         * lib/readutmp.h: Change # indentation to standard Gnulib style.
8849         readutmp: pacify -Wstrict-prototypes
8850         * lib/readutmp.c (get_boot_time_uncached, get_boot_time):
8851         Pacify gcc 13 -Wstrict-prototypes.
8853         readutmp: fix idx_t FIXME in API
8854         * lib/readutmp.c (read_utmp): 2nd arg is now idx_t *, not
8855         size_t *.
8856         * lib/readutmp.h: Include idx.h, for idx_t.
8857         * modules/readutmp (Depends-on): Add idx.
8859         readutmp: go back to simple ‘free’
8860         Omit the new free_utmp function.  Instead, allocate storage
8861         in one block, so that using code can still just call ‘free’.
8862         * lib/readutmp.c (struct utmp_alloc) [READUTMP_USE_SYSTEMD]: New type.
8863         (add_utmp) [READUTMP_USE_SYSTEMD]: New function.
8864         (read_utmp) [READUTMP_USE_SYSTEMD]: Use it.
8865         Also, use malloc a bit less heavily.
8866         (free_utmp): Remove.
8867         * tests/test-readutmp.c (main): Call free, not free_utmp.
8869         readutmp: simplify extract_trimmed_name via ximemdup0
8870         * lib/readutmp.c (extract_trimmed_name): Simplify.
8871         * modules/readutmp (Depends-on):
8872         Add strnlen, which was a missing dependency.
8874 2023-08-03  Bruno Haible  <bruno@clisp.org>
8876         alignasof, stdalign: Avoid some -Wundef warnings from config.h.
8877         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
8878         <https://lists.gnu.org/archive/html/bug-gnulib/2023-08/msg00012.html>.
8879         * m4/stdalign.m4 (gl_ALIGNASOF): Test whether __cplusplus is defined
8880         before evaluating it. Assume HAVE_STDALIGN_H, _GL_STDALIGN_NEEDS_STDDEF
8881         are never defined to 0.
8883 2023-08-03  Bruno Haible  <bruno@clisp.org>
8885         doc: More platform detail.
8886         * doc/posix-functions/fnmatch.texi: Mention Solaris OpenIndiana here,
8887         since it behaves differently than Solaris 11.4.
8889 2023-08-03  Bruno Haible  <bruno@clisp.org>
8891         doc: Add references to FreeBSD bugs.
8892         * doc/posix-functions/fnmatch.texi: Add commented reference to FreeBSD
8893         bug.
8894         * doc/posix-functions/wcscmp.texi: Likewise.
8895         * doc/posix-functions/wcsncmp.texi: Likewise.
8897 2023-08-02  Bruno Haible  <bruno@clisp.org>
8899         readutmp: In systemd mode, put the X11 display into the ut_host field.
8900         * lib/readutmp.c (read_utmp): In sessions of type "x11", use the X11
8901         display as host.
8903 2023-08-02  Bruno Haible  <bruno@clisp.org>
8905         readutmp: Small change to reduce the code size on the coreutils side.
8906         * lib/readutmp.h (UT_ID_SIZE): New constant and macro.
8908 2023-08-01  Bruno Haible  <bruno@clisp.org>
8910         readutmp: Small changes to reduce the code size on the coreutils side.
8911         * m4/readutmp.m4 (gl_READUTMP): Test also for the ut_host field in
8912         'struct utmpx' and 'struct utmp'.
8913         * lib/readutmp.h (HAVE_STRUCT_XTMP_UT_HOST): New macro.
8914         (UT_USER_SIZE): Define also as a macro. Set to -1 if
8915         READUTMP_USE_SYSTEMD.
8916         (UT_LINE_SIZE, UT_HOST_SIZE): New constants and macros.
8918 2023-08-01  Bruno Haible  <bruno@clisp.org>
8920         readutmp: For year-2038 safety on Linux/{x86,arm}, use systemd APIs.
8921         Suggested by Thorsten Kukuk <kukuk@suse.com> in
8922         <https://www.thkukuk.de/blog/Y2038_glibc_utmp_64bit/> and
8923         <https://github.com/thkukuk/utmpx/blob/main/utmp-to-logind.md>.
8924         * m4/systemd.m4: New file.
8925         * m4/readutmp.m4 (gl_READUTMP): Require gl_SYSTEMD_CHOICE. Set
8926         READUTMP_LIB. Conditionally define READUTMP_USE_SYSTEMD.
8927         * lib/readutmp.h: For READUTMP_USE_SYSTEMD, include <sys/time.h> and
8928         <utmpx.h>.
8929         (struct gl_utmp): New type.
8930         (UTMP_STRUCT_NAME, UT_TIME_MEMBER, UT_EXIT_E_TERMINATION,
8931         UT_EXIT_E_EXIT, UT_USER, HAVE_STRUCT_XTMP_UT_EXIT,
8932         HAVE_STRUCT_XTMP_UT_ID, HAVE_STRUCT_XTMP_UT_PID): Define differently for
8933         READUTMP_USE_SYSTEMD.
8934         (UT_USER_SIZE): Don't define for READUTMP_USE_SYSTEMD.
8935         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, READ_UTMP_SUPPORTED): Define also for
8936         READUTMP_USE_SYSTEMD.
8937         (free_utmp): New declaration.
8938         * lib/readutmp.c: Add new includes for READUTMP_USE_SYSTEMD.
8939         (extract_trimmed_name): Adapt to READUTMP_USE_SYSTEMD.
8940         (get_boot_time_uncached, get_boot_time, guess_pty_name): New functions.
8941         (read_utmp): New implementation for READUTMP_USE_SYSTEMD.
8942         (free_utmp): New function.
8943         * tests/test-readutmp.c (main): At the end, invoke free_utmp.
8944         * modules/readutmp (Files): Add m4/systemd.m4.
8945         (Link): New section.
8946         * modules/readutmp-tests (Makefile.am): Link test-readutmp with
8947         READUTMP_LIB.
8948         * NEWS: Mention the free_utmp function and the READUTMP_LIB link
8949         requirement.
8951 2023-08-01  Bruno Haible  <bruno@clisp.org>
8953         readutmp: Trivial simplification.
8954         * lib/readutmp.c (extract_trimmed_name): Use constant UT_USER_SIZE.
8956 2023-07-31  Bruno Haible  <bruno@clisp.org>
8958         readutmp tests: Show also the ut_line field.
8959         * tests/test-readutmp.c (main): Add a "Device" column to the table.
8960         Adjust the column widths. Flush stdout before possibly calling abort().
8962 2023-07-31  Bruno Haible  <bruno@clisp.org>
8964         readutmp: Fix test failure on OpenBSD.
8965         * lib/readutmp.c (desirable_utmp_entry): On OpenBSD, eliminate entirely
8966         empty entries.
8968 2023-07-31  Bruno Haible  <bruno@clisp.org>
8970         readutmp: Revisit portability.
8971         * m4/readutmp.m4 (gl_READUTMP): Don't test for struct utmp.ut_exit.ut_*,
8972         since no platform has these.
8973         * lib/readutmp.h (UT_EXIT_E_TERMINATION): Don't test
8974         HAVE_STRUCT_UTMP_UT_EXIT_UT_TERMINATION.
8975         (UT_EXIT_E_EXIT): Don't test HAVE_STRUCT_UTMP_UT_EXIT_UT_EXIT.
8976         * doc/posix-headers/utmpx.texi: Update platforms list. Mention
8977         portability problems of specific 'struct utmpx' fields.
8978         * doc/glibc-headers/utmp.texi: Update platforms list. Mention
8979         portability problems of specific 'struct utmp' fields.
8981 2023-07-31  Bruno Haible  <bruno@clisp.org>
8983         readutmp: Make argument names consistent.
8984         * lib/readutmp.h (UT_TIME_MEMBER, UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT,
8985         UT_USER, UT_PID, UT_TYPE_EQ, UT_TYPE_BOOT_TIME, UT_TYPE_USER_PROCESS,
8986         IS_USER_PROCESS): Rename parameter to 'UT'.
8987         * lib/readutmp.c (desirable_utmp_entry, read_utmp): Rename local
8988         variable 'u' to 'ut'.
8990 2023-07-31  Bruno Haible  <bruno@clisp.org>
8992         readutmp: Make the header file and function usable on all platforms.
8993         * lib/readutmp.h (struct gl_utmp, UTMP_STRUCT_NAME, UT_TIME_MEMBER,
8994         UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT, UT_USER): Provide fallback
8995         definitions.
8996         (READ_UTMP_SUPPORTED): New macro.
8997         * lib/readutmp.c (read_utmp) [!READ_UTMP_SUPPORTED]: Provide a dummy
8998         definition.
8999         * modules/readutmp (Depends-on): Add sys_time.
9000         (configure.ac): Remove conditional.
9001         (Makefile.am): Compile readutmp.c on all platforms.
9002         (Include): Include readutmp.h on all platforms.
9003         * tests/test-readutmp.c: Include readutmp.h on all platforms.
9004         (main): Invoke read_utmp on all platforms.
9006 2023-07-30  Bruno Haible  <bruno@clisp.org>
9008         readutmp: Add tests.
9009         * tests/test-readutmp.c: New file.
9010         * modules/readutmp-tests: New file.
9012         readutmp: Improve comments. Fix module description.
9013         * lib/readutmp.h (extract_trimmed_name): Add specification comment.
9014         (read_utmp): Move specification comment from lib/readutmp.c to here.
9015         Mention also UTMP_FILE and READ_UTMP_USER_PROCESS.
9016         * lib/readutmp.c (extract_trimmed_name): Fix comment.
9017         * modules/readutmp (Include): Only include the .h file if
9018         HAVE_UTMPX_H || HAVE_UTMP_H.
9020 2023-07-29  Paul Eggert  <eggert@cs.ucla.edu>
9022         readutmp: work around glibc utmpx bug
9023         When compiled with _TIME_BITS=64, glibc <utmpx.h> does not work,
9024         because the files use 32-bit time_t and the code passes this to
9025         the user unmodified, but <utmpx.h> defines a struct with 64-bit
9026         time_t.  Work around this compatibility bug.
9027         * lib/readutmp.c (copy_utmp_entry): New function.
9028         (read_utmp): Use it.
9030 2023-07-29  Bruno Haible  <bruno@clisp.org>
9032         wcsrtombs tests: Renumber tests.
9033         * tests/test-wcsrtombs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
9034         * tests/test-wcsrtombs.c: Update.
9035         * modules/wcsrtombs-tests: Update.
9037         wcsnrtombs tests: Renumber tests.
9038         * tests/test-wcsnrtombs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
9039         * tests/test-wcsnrtombs.c: Update.
9040         * modules/wcsnrtombs-tests: Update.
9042         wcrtomb tests: Renumber tests.
9043         * tests/test-wcrtomb.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9044         * tests/test-wcrtomb.c: Update.
9045         * tests/test-wcrtomb-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
9046         -> 8.
9047         * tests/test-wcrtomb-w32.c: Update.
9048         * modules/wcrtomb-tests: Update.
9050         mbstoc32s tests: Renumber tests.
9051         * tests/test-mbstoc32s-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9052         * tests/test-mbstoc32s.c: Update.
9054         mbsrtoc32s tests: Renumber tests.
9055         * tests/test-mbsrtoc32s-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9056         * tests/test-mbsrtoc32s.c: Update.
9058         mbsnrtoc32s tests: Renumber tests.
9059         * tests/test-mbsnrtoc32s-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9060         * tests/test-mbsnrtoc32s.c: Update.
9062         mbstowcs tests: Renumber tests.
9063         * tests/test-mbstowcs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9064         * tests/test-mbstowcs.c: Update.
9065         * modules/mbstowcs-tests: Update.
9067         mbsrtowcs tests: Renumber tests.
9068         * tests/test-mbsrtowcs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9069         * tests/test-mbsrtowcs.c: Update.
9070         * modules/mbsrtowcs-tests: Update.
9072         mbsnrtowcs tests: Renumber tests.
9073         * tests/test-mbsnrtowcs*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9074         * tests/test-mbsnrtowcs.c: Update.
9075         * modules/mbsnrtowcs-tests: Update.
9077         mbrtoc16 tests: Renumber tests.
9078         * tests/test-mbrtoc16-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9079         * tests/test-mbrtoc16.c: Update.
9080         * tests/test-mbrtoc16-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
9081         -> 8.
9082         * tests/test-mbrtoc16-w32.c: Update.
9083         * modules/mbrtoc16-tests: Update.
9085         mbrtoc32 tests: Renumber tests.
9086         * tests/test-mbrtoc32-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9087         * tests/test-mbrtoc32.c: Update.
9088         * tests/test-mbrtoc32-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
9089         -> 8.
9090         * tests/test-mbrtoc32-w32.c: Update.
9091         * modules/mbrtoc32-tests: Update.
9093         mbrtowc tests: Renumber tests.
9094         * tests/test-mbrtowc*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9095         * tests/test-mbrtowc.c: Update.
9096         * tests/test-mbrtowc-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
9097         -> 8.
9098         * tests/test-mbrtowc-w32.c: Update.
9099         * modules/mbrtowc-tests: Update.
9101         mbrlen tests: Renumber tests.
9102         * tests/test-mbrlen*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9103         * tests/test-mbrlen.c: Update.
9104         * tests/test-mbrlen-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
9105         -> 8.
9106         * tests/test-mbrlen-w32.c: Update.
9107         * modules/mbrlen-tests: Update.
9109         mbmemcasecoll tests: Renumber tests.
9110         * tests/test-mbmemcasecoll*.sh: Renamed 1 -> 2 -> 3 -> 4.
9111         * tests/test-mbmemcasecoll.c: Update.
9112         * modules/mbmemcasecoll-tests: Update.
9114         mbmemcasecmp tests: Renumber tests.
9115         * tests/test-mbmemcasecmp*.sh: Renamed 1 -> 2 -> 3 -> 4.
9116         * tests/test-mbmemcasecmp.c: Update.
9117         * modules/mbmemcasecmp-tests: Update.
9119         fnmatch tests: Renumber tests.
9120         * tests/test-fnmatch-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
9121         -> 8.
9122         * tests/test-fnmatch-w32.c: Update.
9123         * modules/fnmatch-tests: Update.
9125         c32stombs tests: Renumber tests.
9126         * tests/test-c32stombs-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
9127         * tests/test-c32stombs.c: Update.
9128         * modules/c32stombs-tests: Update.
9130         c32srtombs tests: Renumber tests.
9131         * tests/test-c32srtombs-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
9132         * tests/test-c32srtombs.c: Update.
9133         * modules/c32srtombs-tests: Update.
9135         c32snrtombs tests: Renumber tests.
9136         * tests/test-c32snrtombs-*.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5.
9137         * tests/test-c32snrtombs.c: Update.
9138         * modules/c32snrtombs-tests: Update.
9140         c32rtomb tests: Renumber tests.
9141         * tests/test-c32rtomb.sh: Renamed 1 -> 2 -> 3 -> 4 -> 5 -> 1.
9142         * tests/test-c32rtomb.c: Update.
9143         * tests/test-c32rtomb-w32-*.sh: Renamed 1 -> 2 -> 3 -> 5 -> 7 -> 4 -> 6
9144         -> 8.
9145         * tests/test-c32rtomb-w32.c: Update.
9146         * modules/c32rtomb-tests: Update.
9148         btoc32 tests: Renumber tests.
9149         * tests/test-btoc32-*.sh: Renamed 1 -> 2 -> 3 -> 1.
9150         * tests/test-btoc32.c: Update.
9152         btowc tests: Renumber tests.
9153         * tests/test-btowc*.sh: Renamed 1 -> 2 -> 3 -> 1.
9154         * tests/test-btowc.c: Update.
9155         * modules/btowc-tests: Update.
9157 2023-07-29  Bruno Haible  <bruno@clisp.org>
9159         time-h: Simplify after 2017-05-01 change.
9160         * m4/time_h.m4 (gl_TIME_H_DEFAULTS): Don't provide a default value for
9161         GNULIB_GETTIMEOFDAY.
9163         time-h: Obey GNULIB_POSIXCHECK, not GNULIB_PORTCHECK.
9164         * lib/time.in.h (timespec_get, timespec_getres, time, nanosleep, tzset,
9165         mktime, localtime_r, gmtime_r, localtime, strptime, ctime, strftime,
9166         timegm): Add _GL_WARN_ON_USE invocation.
9167         (asctime, ctime): Don't assume that these functions are declared, since
9168         POSIX obsoletes them.
9169         * m4/time_h.m4 (gl_TIME_H): Test for the declarations of asctime, ctime,
9170         gmtime_r, localtime, localtime_r, mktime, nanosleep, strftime, strptime,
9171         time, timegm, timespec_get, timespec_getres, tzset.
9172         (gl_TIME_H_DEFAULTS): Initialize REPLACE_CTIME, REPLACE_LOCALTIME_R,
9173         REPLACE_MKTIME, REPLACE_NANOSLEEP, REPLACE_STRFTIME, REPLACE_TIMEGM,
9174         REPLACE_TIMESPEC_GET, REPLACE_TZSET with 0 instead of GNULIB_PORTCHECK.
9175         * m4/ctime.m4 (gl_FUNC_CTIME): Don't re-initialize REPLACE_CTIME.
9176         * m4/time_r.m4 (gl_TIME_R): Don't re-initialize REPLACE_LOCALTIME_R.
9177         * m4/mktime.m4 (gl_FUNC_MKTIME): Don't re-initialize REPLACE_MKTIME.
9178         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Don't re-initialize
9179         REPLACE_NANOSLEEP.
9180         * m4/strftime-fixes.m4 (gl_FUNC_STRFTIME): Don't re-initialize
9181         REPLACE_STRFTIME.
9182         * m4/timegm.m4 (gl_FUNC_TIMEGM): Don't re-initialize REPLACE_TIMEGM.
9183         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET): Don't re-initialize
9184         REPLACE_TIMESPEC_GET.
9185         * m4/tzset.m4 (gl_FUNC_TZSET: Don't re-initialize REPLACE_TZSET.
9187 2023-07-28  Bruno Haible  <bruno@clisp.org>
9189         fnmatch: Ensure that on Cygwin ≥ 3.5.0, Cygwin's native fnmatch is used.
9190         Tested by Corinna Vinschen in
9191         <https://cygwin.com/pipermail/cygwin/2023-July/254036.html>.
9192         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): On Cygwin, don't force
9193         REPLACE_FNMATCH to 1 just because wchar_t is small.
9195 2023-07-28  Bruno Haible  <bruno@clisp.org>
9197         posixcheck: Fix dependencies.
9198         * modules/posixcheck (Depends-on): Add malloc-h, pthread-h, sched,
9199         sys_random, threads-h, uchar, utmp.
9201 2023-07-28  Bruno Haible  <bruno@clisp.org>
9203         uchar: Include the necessary snippets.
9204         * lib/uchar.in.h: Add insertion points for _GL_ARG_NONNULL and
9205         _GL_WARN_ON_USE.
9206         * modules/uchar (Depends-on): Add snippet/arg-nonnull,
9207         snippet/warn-on-use.
9208         (Makefile.am): In uchar.h, include the ARG_NONNULL_H and WARN_ON_USE_H
9209         snippets.
9211 2023-07-28  Bruno Haible  <bruno@clisp.org>
9213         mbmemcasecmp, mbmemcasecoll: Avoid test failure on MSVC.
9214         * tests/test-mbmemcasecmp.h (test_utf_8): Disable two tests on platforms
9215         that don't have the upper/lower mappings for 'ü'/'Ü'.
9216         * tests/test-mbmemcasecmp.c: Include <wchar.h>, <wctype.h>.
9217         * tests/test-mbmemcasecoll.c: Likewise.
9218         * modules/mbmemcasecmp-tests (Depends-on): Add mbrtowc, wctype-h.
9219         * modules/mbmemcasecoll-tests (Depends-on): Likewise.
9221 2023-07-27  Bruno Haible  <bruno@clisp.org>
9223         gnulib-tool: Include ftruncate in testdirs.
9224         * gnulib-tool (func_create_testdir): Don't exclude module 'ftruncate'
9225         from testdirs by default.
9226         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
9228 2023-07-27  Bruno Haible  <bruno@clisp.org>
9230         fnmatch-h, glob-h tests: Fix link errors (regression 2023-07-24).
9231         * modules/fnmatch-h-c++-tests (Makefile.am): Link test-fnmatch-h-c++
9232         with $(LIBUNISTRING).
9233         * modules/glob-h-c++-tests (Makefile.am): Link test-glob-h-c++ with
9234         $(LIBUNISTRING).
9236         fnmatch, glob tests: Fix link errors (regression 2023-07-24).
9237         * modules/fnmatch-tests (Makefile.am): Link test-fnmatch-w32 with the
9238         same libraries as test-fnmatch.
9239         * modules/glob (Link): Add $(LIBUNISTRING).
9240         * modules/glob-tests (Makefile.am): Link test-glob with $(LIBUNISTRING).
9242 2023-07-26  Bruno Haible  <bruno@clisp.org>
9244         wctrans: Work around bug on NetBSD.
9245         * lib/wctype.in.h (rpl_wctrans_t, wctrans_t, GNULIB_defined_wctrans_t):
9246         Define if REPLACE_WCTRANS is 1.
9247         (wctrans): Consider REPLACE_WCTRANS.
9248         (towctrans): Override if REPLACE_WCTRANS is 1.
9249         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize REPLACE_WCTRANS.
9250         * m4/wctrans.m4 (gl_FUNC_WCTRANS): Define through AC_DEFUN_ONCE. Test
9251         whether wctrans supports the "tolower" character mapping. Set
9252         REPLACE_WCTRANS if not.
9253         * m4/towctrans.m4 (gl_FUNC_TOWCTRANS): Require gl_FUNC_WCTRANS.
9254         * modules/wctrans (Depends-on): Add towctrans.
9255         (configure.ac): Consider REPLACE_WCTRANS.
9256         * modules/towctrans (Files): Add m4/wctrans.m4.
9257         (configure.ac): Override also if REPLACE_WCTRANS is 1.
9258         * modules/wctype-h (Makefile.am): Substitute REPLACE_WCTRANS.
9259         * doc/posix-functions/wctrans.texi: Mention the NetBSD bug.
9261 2023-07-26  Bruno Haible  <bruno@clisp.org>
9263         towctrans: Add tests.
9264         * tests/test-towctrans.c: New file, based on
9265         tests/test-c32_apply_mapping.c.
9266         * modules/towctrans-tests: New file.
9268         wctrans: Add tests.
9269         * tests/test-wctrans.c: New file, based on tests/test-c32_get_mapping.c.
9270         * modules/wctrans-tests: New file.
9272 2023-07-26  Bruno Haible  <bruno@clisp.org>
9274         fnmatch: Update dependencies.
9275         * modules/fnmatch (Depends-on): Add wctype.
9277 2023-07-26  Bruno Haible  <bruno@clisp.org>
9279         wctype: Work around wctype+iswctype bug on MSVC.
9280         * m4/wctype.m4 (gl_FUNC_WCTYPE): In the test program, test also for the
9281         MSVC bug. Update cross-compilation guess.
9282         * doc/posix-functions/wctype.texi: Mention the MSVC bug.
9284 2023-07-26  Bruno Haible  <bruno@clisp.org>
9286         wctype: Work around wctype bug on mingw.
9287         * lib/wctype.in.h (rpl_wctype_t, wctype_t, GNULIB_defined_wctype_t):
9288         Define if REPLACE_WCTYPE is 1.
9289         (wctype): Consider REPLACE_WCTYPE.
9290         (iswctype): Override also if REPLACE_WCTYPE is 1.
9291         * lib/iswctype.c: If GNULIB_defined_wctype_t is defined, use the
9292         function-pointer based implementation.
9293         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize REPLACE_WCTYPE.
9294         * m4/wctype.m4 (gl_FUNC_WCTYPE): Define through AC_DEFUN_ONCE. Test
9295         whether wctype supports the "blank" character class. Set REPLACE_WCTYPE
9296         if not.
9297         * m4/iswctype.m4 (gl_FUNC_ISWCTYPE): Require gl_FUNC_WCTYPE.
9298         * modules/wctype (Status, Notice): Remove.
9299         (Depends-on): Add iswctype. Consider REPLACE_WCTYPE.
9300         (configure.ac): Consider REPLACE_WCTYPE.
9301         * modules/iswctype (Status, Notice): Remove.
9302         (Files): Add m4/wctype.m4.
9303         (configure.ac): Override also if REPLACE_WCTYPE is 1.
9304         * modules/wctype-h (Makefile.am): Substitute REPLACE_WCTYPE.
9305         * doc/posix-functions/wctype.texi: Mention the mingw bug.
9307 2023-07-26  Bruno Haible  <bruno@clisp.org>
9309         wctype-h: Work around iswprint bug on mingw.
9310         * lib/wctype.in.h (rpl_iswprint): On mingw, don't use the system's
9311         iswprint function.
9312         * tests/test-wctype-h.c (main): Verify that this character class
9313         contains the ASCII space but not tab and newline.
9314         * tests/test-c32isprint.c (main): For tab, \v, \f, expect the same value
9315         on native Windows as on other platforms.
9316         * doc/posix-functions/iswprint.texi: Mention the mingw bug.
9318 2023-07-26  Bruno Haible  <bruno@clisp.org>
9320         iswblank tests: Add more tests.
9321         * tests/test-iswblank.c (main): Verify that this character class
9322         contains the ASCII space and tab, but not newline.
9324 2023-07-26  Bruno Haible  <bruno@clisp.org>
9326         wctype, wctrans: Require a non-NULL argument.
9327         * lib/wctype.in.h: Add placeholder for definition of _GL_ARG_NONNULL.
9328         (wctype, wctrans): Mark with _GL_ARG_NONNULL ((1)).
9329         * modules/wctype-h (Depends-on): Add snippet/arg-nonnull.
9330         (Makefile.am): Substitute $(ARG_NONNULL_H) into wctype.h.
9332 2023-07-25  Bruno Haible  <bruno@clisp.org>
9334         iswctype: Add tests.
9335         * tests/test-iswctype.c: New file, based on
9336         tests/test-c32_apply_type_test.c.
9337         * tests/test-c32_apply_type_test.c (main): Update accordingly.
9338         * modules/iswctype-tests: New file.
9340         wctype: Add tests.
9341         * tests/test-wctype.c: New file, based on
9342         tests/test-c32_get_type_test.c.
9343         * modules/wctype-tests: New file.
9345 2023-07-25  Bruno Haible  <bruno@clisp.org>
9347         Compile benchmark programs without assertions.
9348         * modules/mbiter-bench-tests (Makefile.am): Compile bench-mbiter with
9349         -DNDEBUG.
9350         * modules/mbiterf-bench-tests (Makefile.am): Compile bench-mbiterf with
9351         -DNDEBUG.
9352         * modules/mbuiter-bench-tests (Makefile.am): Compile bench-mbuiter with
9353         -DNDEBUG.
9354         * modules/mbuiterf-bench-tests (Makefile.am): Compile bench-mbuiterf
9355         with -DNDEBUG.
9356         * modules/mbswidth-bench-tests (Makefile.am): Compile bench-mbswidth
9357         with -DNDEBUG.
9358         * modules/crypto/md5-buffer-tests (Makefile.am): Compile bench-md5 with
9359         -DNDEBUG.
9360         * modules/crypto/sha1-buffer-tests (Makefile.am): Compile bench-sha1
9361         with -DNDEBUG.
9362         * modules/crypto/sha256-buffer-tests (Makefile.am): Compile bench-sha224
9363         and bench-sha256 with -DNDEBUG.
9364         * modules/crypto/sha512-buffer-tests (Makefile.am): Compile bench-sha384
9365         and bench-sha512 with -DNDEBUG.
9367 2023-07-25  Bruno Haible  <bruno@clisp.org>
9369         unistr/u8-*: Make Unicode decoder more Unicode Standard compliant.
9370         Based on a remark by Paul Eggert in
9371         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00120.html>.
9372         * tests/unistr/test-u8-mbtouc.c (test_safe_function): Change expected
9373         results for "non-shortest form" or out-of-range byte sequences. Add new
9374         test cases of incomplete well-formed byte sequences.
9375         * tests/unistr/test-u8-mbsnlen.c (main): Likewise.
9376         * lib/unistr/u8-mbtouc-aux.c (u8_mbtouc_aux): Reject a first byte in the
9377         range 0xF5..0xF7 as invalid. Distinguish incomplete from invalid byte
9378         sequences correctly. For the former, return only the number of bytes in
9379         the maximal well-formed subpart.
9380         * lib/unistr/u8-mbtouc.c (u8_mbtouc): Likewise.
9381         * lib/unistr/u8-check.c (u8_check): Reject a first byte in the range
9382         0xF5..0xF7 as invalid.
9383         * lib/unistr/u8-mblen.c (u8_mblen): Likewise.
9384         * lib/unistr/u8-mbtoucr.c (u8_mbtoucr): Likewise.
9385         * lib/unistr/u8-strmbtouc.c (u8_strmbtouc): Likewise.
9386         * lib/unistr/u8-strmblen.c (u8_strmblen): Likewise.
9387         * lib/unistr/u8-prev.c (u8_prev): Likewise.
9389 2023-07-24  Bruno Haible  <bruno@clisp.org>
9391         fnmatch: Overcome wchar_t limitations.
9392         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Set REPLACE_FNMATCH to 1 on
9393         AIX in 32-bit mode.
9394         * lib/fnmatch.c: Include <uchar.h>. Conditionally include unistr.h.
9395         (UCHAR_TO_WCHAR): Renamed from BTOWC.
9396         (WCHAR_T, WINT_T, BTOWC, MBSRTOWCS, WCSLEN, WCSCAT, WMEMPCPY, WMEMCHR,
9397         TOWLOWER, WCTYPE_T, WCTYPE, ISWCTYPE): New macros.
9398         (IS_CHAR_CLASS): Use WCTYPE instead of wctype.
9399         (UCHAR_TO_WCHAR): Use BTOWC instead of btowc.
9400         (FOLD): Use TOWLOWER instead of towlower.
9401         (CHAR): Use WCHAR_T instead of wchar_t.
9402         (UCHAR, INT): Use WINT_T instead of wint_t.
9403         (STRLEN): Use WCSLEN instead of wcslen.
9404         (STRCAT): Use WCSCAT instead of wcscat.
9405         (MEMPCPY): Use WMEMPCPY instead of wmempcpy.
9406         (MEMCHR): Use WMEMCHR instead of wmemchr.
9407         (is_char_class): Use WCTYPE_T instead of wctype_t, WCHAR_T instead of
9408         wchar_t, WCTYPE instead of wctype.
9409         (fnmatch): Use WCHAR_T instead of wchar_t, MBSRTOWCS instead of
9410         mbsrtowcs.
9411         * lib/fnmatch_loop.c (FCT): Use WCTYPE_T instead of wctype_t, ISWCTYPE
9412         instead of iswctype. Update for renamed BTOWC.
9413         * modules/fnmatch (Depends-on): Add btoc32, c32tolower,
9414         c32_get_type_test, c32_apply_type_test, mbsrtoc32s, unistr/u32-chr,
9415         unistr/u32-pcpy, unistr/u32-strcat, unistr/u32-strlen.
9416         (Link): Add $(LIBUNISTRING).
9417         * modules/fnmatch-tests (Makefile.am): Link test-fnmatch with
9418         $(LIBUNISTRING).
9419         * doc/posix-functions/fnmatch.texi: Move the Cygwin, mingw, MSVC, AIX
9420         bug descriptions to the "fixed by Gnulib" section.
9422 2023-07-24  Bruno Haible  <bruno@clisp.org>
9424         fnmatch: Update doc regarding Solaris 10.
9425         * doc/posix-functions/fnmatch.texi: Move the Solaris 10 bug description
9426         to the "fixed by Gnulib" section.
9428 2023-07-23  Paul Eggert  <eggert@cs.ucla.edu>
9430         timespec_get: port to Ubuntu 23.04
9431         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET):
9432         Default REPLACE_TIMESPEC_GET to 0, fixing a typo.
9434 2023-07-23  Bruno Haible  <bruno@clisp.org>
9436         unistr/u32-strcat: Relicense under LGPLv2+.
9437         * modules/unistr/u32-strcat (License): Change to LGPLv2+.
9438         * lib/unistr/u32-strcat.c: Update license notice.
9439         * lib/unistr/u-strcat.h: Likewise.
9441 2023-07-23  Bruno Haible  <bruno@clisp.org>
9443         unistr/u32-strlen: Relicense under LGPLv2+.
9444         * modules/unistr/u32-strlen (License): Change to LGPLv2+.
9445         * lib/unistr/u32-strlen.c: Update license notice.
9447 2023-07-23  Bruno Haible  <bruno@clisp.org>
9449         unistr/u32-chr: Relicense under LGPLv2+.
9450         * modules/unistr/u32-chr (License): Change to LGPLv2+.
9451         * lib/unistr/u32-chr.c: Update license notice.
9453 2023-07-23  Paul Eggert  <eggert@cs.ucla.edu>
9455         utimecmp: clean up old spare1 cruft
9456         * lib/utimecmp.c: Remove a ‘defined HAVE_STRUCT_STAT_ST_SPARE1’
9457         that has been false since 2007.
9459 2023-07-23  Bruno Haible  <bruno@clisp.org>
9461         fnmatch tests: Avoid a test failure on FreeBSD.
9462         * tests/test-fnmatch.c (main): In a GB18030 locale, test the towupper()
9463         mapping of 'ö', not of 'ü'.
9465 2023-07-23  Bruno Haible  <bruno@clisp.org>
9467         fnmatch: Work around bugs on FreeBSD, NetBSD, Solaris, Cygwin, Android.
9468         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Add three more test cases to
9469         the test program. Reorganize its return values.
9470         * tests/test-fnmatch.c (main): Reflect the changes done in fnmatch.m4.
9471         * doc/posix-functions/fnmatch.texi: Move the corresponding bug
9472         descriptions to the "fixed by Gnulib" section.
9474 2023-07-23  Bruno Haible  <bruno@clisp.org>
9476         fnmatch, fnmatch-gnu: Document known bugs.
9477         * doc/posix-headers/fnmatch.texi: Mention the macros FNM_LEADING_DIR,
9478         FNM_CASEFOLD, FNM_EXTMATCH, FNM_FILE_NAME.
9479         * doc/posix-functions/fnmatch.texi: Reference the glibc documentation
9480         and the Linux man page. Document the effects of the two modules and all
9481         the known bugs in detail.
9483 2023-07-22  Bruno Haible  <bruno@clisp.org>
9485         fnmatch tests: Add many more test cases.
9486         * lib/fnmatch.in.h (GNULIB_defined_fnmatch_function): New macro.
9487         * tests/test-fnmatch.c: Add many more test cases.
9488         * tests/test-fnmatch-1.sh: New file, based on tests/test-mbrtoc32-5.sh.
9489         * tests/test-fnmatch-2.sh: New file, based on tests/test-mbrtoc32-1.sh.
9490         * tests/test-fnmatch-3.sh: New file, based on tests/test-mbrtoc32-2.sh.
9491         * tests/test-fnmatch-4.sh: New file, based on tests/test-mbrtoc32-3.sh.
9492         * tests/test-fnmatch-5.sh: New file, based on tests/test-mbrtoc32-4.sh.
9493         * tests/test-fnmatch-w32.c: New file, based on tests/test-mbrtoc32-w32.c
9494         and tests/test-fnmatch.c.
9495         * tests/test-fnmatch-w32-1.sh: New file, based on
9496         tests/test-mbrtoc32-w32-1.sh.
9497         * tests/test-fnmatch-w32-2.sh: New file, based on
9498         tests/test-mbrtoc32-w32-2.sh.
9499         * tests/test-fnmatch-w32-3.sh: New file, based on
9500         tests/test-mbrtoc32-w32-3.sh.
9501         * tests/test-fnmatch-w32-4.sh: New file, based on
9502         tests/test-mbrtoc32-w32-4.sh.
9503         * tests/test-fnmatch-w32-5.sh: New file, based on
9504         tests/test-mbrtoc32-w32-5.sh.
9505         * tests/test-fnmatch-w32-6.sh: New file, based on
9506         tests/test-mbrtoc32-w32-6.sh.
9507         * tests/test-fnmatch-w32-7.sh: New file, based on
9508         tests/test-mbrtoc32-w32-7.sh.
9509         * modules/fnmatch-tests: Add the new program and shell scripts.
9511 2023-07-22  Bruno Haible  <bruno@clisp.org>
9513         doc: Mention a wctype bug.
9514         * doc/posix-functions/wctype.texi: Mention a bug on mingw.
9516 2023-07-21  Bruno Haible  <bruno@clisp.org>
9518         unistr/u8-pcpy, unistr/u16-pcpy, unistr/u32-pcpy: Add tests.
9519         * tests/unistr/test-pcpy.h: New file, based on tests/unistr/test-cpy.h.
9520         * tests/unistr/test-u8-pcpy.c: New file, based on
9521         tests/unistr/test-u8-cpy.c.
9522         * tests/unistr/test-u16-pcpy.c: New file, based on
9523         tests/unistr/test-u16-cpy.c.
9524         * tests/unistr/test-u32-pcpy.c: New file, based on
9525         tests/unistr/test-u32-cpy.c.
9526         * modules/unistr/u8-pcpy-tests: New file, based on
9527         modules/unistr/u8-cpy-tests.
9528         * modules/unistr/u16-pcpy-tests: New file, based on
9529         modules/unistr/u16-cpy-tests.
9530         * modules/unistr/u32-pcpy-tests: New file, based on
9531         modules/unistr/u32-cpy-tests.
9533         unistr/u8-pcpy, unistr/u16-pcpy, unistr/u32-pcpy: New modules.
9534         * lib/unistr.in.h (u8_pcpy, u16_pcpy, u32_pcpy): New declarations.
9535         * lib/unistr/u-pcpy.h: New file, based on lib/wmempcpy.c.
9536         * lib/unistr/u8-pcpy.c: New file, based on lib/unistr/u8-cpy.c.
9537         * lib/unistr/u16-pcpy.c: New file, based on lib/unistr/u16-cpy.c.
9538         * lib/unistr/u32-pcpy.c: New file, based on lib/unistr/u32-cpy.c.
9539         * modules/unistr/u8-pcpy: New file, based on modules/unistr/u8-cpy.
9540         * modules/unistr/u16-pcpy: New file, based on modules/unistr/u16-cpy.
9541         * modules/unistr/u32-pcpy: New file, based on modules/unistr/u32-cpy.
9543 2023-07-20  Bruno Haible  <bruno@clisp.org>
9545         error-h: Fix dependencies.
9546         Reported by <cbh34680@gmail.com> in
9547         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00111.html>.
9548         * modules/error-h (Depends-on): Add include_next.
9550 2023-07-20  Pádraig Brady  <P@draigBrady.com>
9552         fts: fix compilation errors with fts_cross_check()
9553         * lib/fts.c: Fix printf format chars.
9554         * lib/fts_.h: Provide a declaration for users.
9556 2023-07-19  Bruno Haible  <bruno@clisp.org>
9558         Document migration path for obsolescent functions.
9559         * doc/glibc-functions/timespec_get.texi: Add reference to ISO C.
9560         * doc/posix-functions/_tolower.texi: Recommend use of tolower.
9561         * doc/posix-functions/_toupper.texi: Recommend use of toupper.
9562         * doc/posix-functions/asctime.texi: Recommend use of strftime.
9563         * doc/posix-functions/asctime_r.texi: Likewise.
9564         * doc/posix-functions/ctime.texi: Recommend use of localtime_r and
9565         strftime.
9566         * doc/posix-functions/ctime_r.texi: Likewise.
9567         * doc/posix-functions/ftw.texi: Recommend use of fts.
9568         * doc/posix-functions/getitimer.texi: Recommend use of timer_gettime.
9569         * doc/posix-functions/gets.texi: Recommend use of fgets.
9570         * doc/posix-functions/gettimeofday.texi: Recommend use of gettime or
9571         timespec_get.
9572         * doc/posix-functions/inet_addr.texi: Recommend use of inet_pton.
9573         * doc/posix-functions/inet_ntoa.texi: Recommend use of inet_ntop.
9574         * doc/posix-functions/pthread_getconcurrency.texi: Recommend no-op.
9575         * doc/posix-functions/pthread_setconcurrency.texi: Recommend no-op.
9576         * doc/posix-functions/rand_r.texi: Recommend use of random_r.
9577         * doc/posix-functions/setitimer.texi: Recommend use of timer_create and
9578         timer_settime.
9579         * doc/posix-functions/setpgrp.texi: Recommend use of setpgid or setsid.
9580         * doc/posix-functions/sighold.texi: Recommend use of sigprocmask.
9581         * doc/posix-functions/sigignore.texi: Recommend use of sigaction.
9582         * doc/posix-functions/siginterrupt.texi: Recommend use of sigaction.
9583         * doc/posix-functions/sigpause.texi: Recommend use of sigsuspend.
9584         * doc/posix-functions/sigrelse.texi: Recommend use of sigprocmask.
9585         * doc/posix-functions/sigset.texi: Recommend use of sigaction.
9586         * doc/posix-functions/tempnam.texi: Recommend use of mkstemp.
9587         * doc/posix-functions/ulimit.texi: Recommend use of getrlimit and
9588         setrlimit.
9589         * doc/posix-functions/utime.texi: Recommend use of utimens.
9591 2023-07-19  Paul Eggert  <eggert@cs.ucla.edu>
9593         Document POSIX obsolescence
9594         * doc/posix-functions/_longjmp.texi, doc/posix-functions/_setjmp.texi:
9595         * doc/posix-functions/_tolower.texi, doc/posix-functions/_toupper.texi:
9596         * doc/posix-functions/asctime.texi, doc/posix-functions/asctime_r.texi:
9597         * doc/posix-functions/ctime.texi, doc/posix-functions/ctime_r.texi:
9598         * doc/posix-functions/encrypt.texi, doc/posix-functions/ftw.texi:
9599         * doc/posix-functions/getitimer.texi, doc/posix-functions/gets.texi:
9600         * doc/posix-functions/gettimeofday.texi:
9601         * doc/posix-functions/inet_addr.texi:
9602         * doc/posix-functions/inet_ntoa.texi, doc/posix-functions/isascii.texi:
9603         * doc/posix-functions/pthread_getconcurrency.texi:
9604         * doc/posix-functions/pthread_setconcurrency.texi:
9605         * doc/posix-functions/rand_r.texi, doc/posix-functions/setitimer.texi:
9606         * doc/posix-functions/setkey.texi, doc/posix-functions/setpgrp.texi:
9607         * doc/posix-functions/sighold.texi, doc/posix-functions/sigignore.texi:
9608         * doc/posix-functions/siginterrupt.texi:
9609         * doc/posix-functions/sigpause.texi, doc/posix-functions/sigrelse.texi:
9610         * doc/posix-functions/sigset.texi, doc/posix-functions/tempnam.texi:
9611         * doc/posix-functions/toascii.texi, doc/posix-functions/ulimit.texi:
9612         * doc/posix-functions/utime.texi:
9613         Update as per draft 3 of POSIX 10003.1-202x.
9615 2023-07-19  Paul Eggert  <eggert@cs.ucla.edu>
9617         Don’t worry about Version 7 tolower
9618         Some code ported back to pre-C89 libraries where tolower (C) had
9619         undefined behavior if C is not an upper case character.
9620         Nowadays that function is _tolower which is itself obsolete,
9621         and much Gnulib code already assumes this part of C89 anyway.
9622         Assume C89 or better tolower, which simplifies the code
9623         and should improve performance slightly.
9624         * lib/mbmemcasecmp.c, lib/mbmemcasecoll.c, lib/mbscasecmp.c:
9625         * lib/mbscasestr.c, lib/mbsncasecmp.c, lib/mbspcasecmp.c:
9626         * lib/strcasecmp.c, lib/strcasestr.c, lib/strncasecmp.c:
9627         (TOLOWER): Remove.  All uses replaced by tolower.
9629 2023-07-19  Bruno Haible  <bruno@clisp.org>
9631         c32swidth, mbszero: Fix file list.
9632         * modules/c32swidth (Files): Add locale-ja.m4, locale-zh.m4, codeset.m4.
9633         * modules/mbszero (Files): Likewise.
9635 2023-07-19  Bruno Haible  <bruno@clisp.org>
9637         wcsnrtombs: Fix file list.
9638         * modules/wcsnrtombs (Files): Add locale-fr.m4.
9640 2023-07-19  Bruno Haible  <bruno@clisp.org>
9642         mbsnrtowcs: Fix file list.
9643         * modules/mbsnrtowcs (Files): Add locale-fr.m4, codeset.m4.
9645 2023-07-19  Bruno Haible  <bruno@clisp.org>
9647         mbrtoc16: Fix file list.
9648         * modules/mbrtoc16 (Files): Add locale-zh.m4.
9650 2023-07-19  Bruno Haible  <bruno@clisp.org>
9652         mbrlen: Fix file list.
9653         * modules/mbrlen (Files): Add locale-fr.m4, locale-ja.m4, locale-zh.m4,
9654         codeset.m4.
9656 2023-07-18  Paul Eggert  <eggert@cs.ucla.edu>
9658         mbiterf, mbuiterf: port to strict C17
9659         I ran into this problem on NetBSD 9.3.
9660         * lib/mbiterf.h (mbiterf_next) [!GNULIB_MBRTOC32_REGULAR]:
9661         * lib/mbuiterf.h (mbuiterf_next) [!GNULIB_MBRTOC32_REGULAR]:
9662         Don’t label a declaration.
9664 2023-07-18  Bruno Haible  <bruno@clisp.org>
9666         mbiter, mbiterf, mbuiter, mbuiterf: Force inlining with clang.
9667         * lib/mbiter.h (MBITER_INLINE): Use _GL_ATTRIBUTE_ALWAYS_INLINE.
9668         * lib/mbiterf.h (MBITERF_INLINE): Likewise.
9669         * lib/mbuiter.h (MBUITER_INLINE): Likewise.
9670         * lib/mbuiterf.h (MBUITERF_INLINE): Likewise.
9672 2023-07-18  Bruno Haible  <bruno@clisp.org>
9674         mbsspn: Optimize.
9675         * lib/mbsspn.c: Include mbuiterf.h instead of mbuiter.h.
9676         (mbsspn): Use mbuif_* macros instead of mbui_* macros.
9677         * modules/mbsspn (Depends-on): Add mbuiterf. Remove mbuiter.
9679         mbscspn: Optimize.
9680         * lib/mbscspn.c: Include mbuiterf.h instead of mbuiter.h.
9681         (mbscspn): Use mbuif_* macros instead of mbui_* macros.
9682         * modules/mbscspn (Depends-on): Add mbuiterf. Remove mbuiter.
9684         mbspbrk: Optimize.
9685         * lib/mbspbrk.c: Include mbuiterf.h instead of mbuiter.h.
9686         (mbspbrk): Use mbuif_* macros instead of mbui_* macros.
9687         * modules/mbspbrk (Depends-on): Add mbuiterf. Remove mbuiter.
9689         mbspcasecmp: Optimize.
9690         * lib/mbspcasecmp.c: Include mbuiterf.h instead of mbuiter.h.
9691         (mbspcasecmp): Use mbuif_* macros instead of mbui_* macros.
9692         * modules/mbspcasecmp (Depends-on): Add mbuiterf. Remove mbuiter.
9694         mbsncasecmp: Optimize.
9695         * lib/mbsncasecmp.c: Include mbuiterf.h instead of mbuiter.h.
9696         (mbsncasecmp): Use mbuif_* macros instead of mbui_* macros.
9697         * modules/mbsncasecmp (Depends-on): Add mbuiterf. Remove mbuiter.
9699         mbscasecmp: Optimize.
9700         * lib/mbscasecmp.c: Include mbuiterf.h instead of mbuiter.h.
9701         (mbscasecmp): Use mbuif_* macros instead of mbui_* macros.
9702         * modules/mbscasecmp (Depends-on): Add mbuiterf. Remove mbuiter.
9704         mbssep: Optimize.
9705         * lib/mbssep.c: Include mbuiterf.h instead of mbuiter.h.
9706         (mbssep): Use mbuif_* macros instead of mbui_* macros.
9707         * modules/mbssep (Depends-on): Add mbuiterf. Remove mbuiter.
9709         mbsrchr: Optimize.
9710         * lib/mbsrchr.c: Include mbuiterf.h instead of mbuiter.h.
9711         (mbsrchr): Use mbuif_* macros instead of mbui_* macros.
9712         * modules/mbsrchr (Depends-on): Add mbuiterf. Remove mbuiter.
9714         mbschr: Optimize.
9715         * lib/mbschr.c: Include mbuiterf.h instead of mbuiter.h.
9716         (mbschr): Use mbuif_* macros instead of mbui_* macros.
9717         * modules/mbschr (Depends-on): Add mbuiterf. Remove mbuiter.
9719         mbslen: Optimize.
9720         * lib/mbslen.c: Include mbuiterf.h instead of mbuiter.h.
9721         (mbslen): Use mbuif_* macros instead of mbui_* macros.
9722         * modules/mbslen (Depends-on): Add mbuiterf. Remove mbuiter.
9724         mbuiterf: Add a benchmark.
9725         * tests/bench-mbuiterf.c: New file, based on tests/bench-mbuiter.c.
9726         * modules/mbuiterf-bench-tests: New file, based on
9727         modules/mbuiter-bench-tests.
9729         mbuiterf: New module.
9730         * lib/mbuiterf.h: New file, based on lib/mbuiter.h.
9731         * lib/mbuiterf.c: New file, based on lib/mbuiter.c.
9732         * modules/mbuiterf: New file, based on modules/mbuiter.
9734 2023-07-18  Bruno Haible  <bruno@clisp.org>
9736         mbiterf: Fix compiler warnings.
9737         * lib/mbiterf.h (mbiterf_next): Use C99 designated initializer syntax.
9738         * tests/bench-mbiterf.c (do_test): Use a 'const char *' pointer.
9740         trim: Optimize.
9741         * lib/trim.c: Include mbiterf.h instead of mbiter.h.
9742         (trim2): Use mbif_* macros instead of mbi_* macros.
9743         * modules/trim (Depends-on): Add mbiterf. Remove mbiter.
9745         mbmemcasecmp: Optimize.
9746         * lib/mbmemcasecmp.c: Include mbiterf.h instead of mbiter.h.
9747         (mbmemcasecmp): Use mbif_* macros instead of mbi_* macros.
9748         * modules/mbmemcasecmp (Depends-on): Add mbiterf. Remove mbiter.
9750         mbsnlen: Optimize.
9751         * lib/mbsnlen.c: Include mbiterf.h instead of mbiter.h.
9752         (mbsnlen): Use mbif_* macros instead of mbi_* macros.
9753         * modules/mbsnlen (Depends-on): Add mbiterf. Remove mbiter.
9755         mbiterf: Add a benchmark.
9756         * tests/bench-mbiterf.c: New file, based on tests/bench-mbiter.c.
9757         * modules/mbiterf-bench-tests: New file, based on
9758         modules/mbiter-bench-tests.
9760         mbiterf: New module.
9761         * lib/mbiterf.h: New file, based on lib/mbiter.h.
9762         * lib/mbiterf.c: New file, based on lib/mbiter.c.
9763         * modules/mbiterf: New file, based on modules/mbiter.
9765 2023-07-18  Bruno Haible  <bruno@clisp.org>
9767         mbstok_r: Simplify dependencies.
9768         * lib/mbstok_r.c: Include <stdlib.h> instead of mbuiter.h.
9769         * modules/mbstok_r (Depends-on): Remove mbuiter.
9771 2023-07-17  Simon Josefsson  <simon@josefsson.org>
9773         announce-gen: Allow using local git user.name.
9774         * build-aux/announce-gen (readable_interval): Remove --global
9775         parameter to 'git config' call.
9777 2023-07-17  Bruno Haible  <bruno@clisp.org>
9779         mbuiter: Optimize.
9780         * lib/mbuiter.h (struct mbuiter_multi): Add cur_max field.
9781         (mbui_init): Initialize it.
9782         (mbuiter_multi_next): Use it instead of MB_CUR_MAX.
9783         (mbuiter_multi_copy): Update.
9785 2023-07-17  Bruno Haible  <bruno@clisp.org>
9787         mbchar: Reduce size of 'struct mbchar'.
9788         * modules/mbfile (configure.ac): Define GNULIB_MBFILE as an indicator.
9789         * lib/mbchar.h (MBCHAR_BUF_SIZE): Set to 4.
9790         (struct mbchar): Disable member 'buf' if the module 'mbfile' is not in
9791         use.
9792         (mb_setascii): Disable if the module 'mbfile' is not in use.
9793         (mb_copy): Update.
9795 2023-07-17  Bruno Haible  <bruno@clisp.org>
9797         mbszero: Fix for Minix.
9798         * lib/wchar.in.h: (_GL_MBSTATE_INIT_SIZE): Don't define on Minix.
9799         (_GL_MBSTATE_ZERO_SIZE): Define to 4 on Minix.
9801 2023-07-17  Bruno Haible  <bruno@clisp.org>
9803         mbszero: Source code tweaks.
9804         Suggested by Paul Eggert in
9805         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00084.html>.
9806         * lib/wchar.in.h: Comment changes.
9807         (_GL_MBSTATE_INIT_SIZE): Don't define on NetBSD, Solaris, native
9808         Windows. Use a safe default at the end.
9809         (_GL_MBSTATE_ZERO_SIZE): Don't define on AIX, IRIX, Solaris, native
9810         Windows. Use a safe default at the end.
9811         * lib/mbrtoc16.c: Update comments accordingly.
9813 2023-07-16  Bruno Haible  <bruno@clisp.org>
9815         dfa: Optimize clearing an mbstate_t.
9816         * lib/dfa.c (mbszero) [GAWK]: Add fallback definition.
9817         (mbs_to_wchar, lex, addtok_wc, dfaexec_main): Use mbszero.
9818         * modules/dfa (Depends-on): Add mbszero.
9820 2023-07-16  Bruno Haible  <bruno@clisp.org>
9822         uchar-c23: Optimize clearing an mbstate_t.
9823         * lib/lc-charset-unicode.c (locale_encoding_to_unicode,
9824         unicode_to_locale_encoding): Use mbszero.
9825         * modules/uchar-c23 (Depends-on): Add mbszero.
9827 2023-07-16  Bruno Haible  <bruno@clisp.org>
9829         quotearg: Optimize clearing an mbstate_t.
9830         * lib/quotearg.c: Include <wchar.h>.
9831         (quotearg_buffer_restyled): Use mbszero.
9832         * modules/quotearg (Depends-on): Add mbszero.
9834 2023-07-16  Bruno Haible  <bruno@clisp.org>
9836         vasnprintf, vasnwprintf: Optimize clearing an mbstate_t.
9837         * lib/vasnprintf.c (VASNPRINTF): Use mbszero.
9838         * modules/vasnprintf (Depends-on): Add mbszero.
9839         * modules/vasnwprintf (Depends-on): Likewise.
9840         * modules/c-vasnprintf (Depends-on): Likewise.
9841         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
9842         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
9843         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
9844         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
9845         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
9846         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
9847         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
9849 2023-07-16  Bruno Haible  <bruno@clisp.org>
9851         mbmemcasecoll: Optimize clearing an mbstate_t.
9852         * lib/mbmemcasecoll.c (apply_c32tolower): Use mbszero.
9853         * modules/mbmemcasecoll (Depends-on): Add mbszero.
9855 2023-07-16  Bruno Haible  <bruno@clisp.org>
9857         mbswidth: Optimize clearing an mbstate_t.
9858         * lib/mbswidth.c (mbsnwidth): Use mbszero.
9859         * modules/mbswidth (Depends-on): Add mbszero.
9861 2023-07-16  Bruno Haible  <bruno@clisp.org>
9863         mbfile: Optimize clearing an mbstate_t.
9864         * lib/mbfile.h (mbfile_multi_getc, mbf_init): Use mbszero.
9865         * modules/mbfile (Depends-on): Add mbszero.
9867 2023-07-16  Bruno Haible  <bruno@clisp.org>
9869         mbuiter: Optimize clearing an mbstate_t.
9870         * lib/mbuiter.h: Include <wchar.h>.
9871         (mbuiter_multi_next, mbuiter_multi_copy, mbui_init): Use mbszero.
9872         * modules/mbuiter (Depends-on): Add mbszero.
9874 2023-07-16  Bruno Haible  <bruno@clisp.org>
9876         mbiter: Optimize clearing an mbstate_t.
9877         * lib/mbiter.h: Include <wchar.h>.
9878         (mbiter_multi_next, mbiter_multi_copy, mbi_init): Use mbszero.
9879         * modules/mbiter (Depends-on): Add mbszero.
9881 2023-07-16  Bruno Haible  <bruno@clisp.org>
9883         c32stombs: Optimize clearing an mbstate_t.
9884         * lib/c32stombs.c (c32stombs): Use mbszero.
9885         * lib/uchar.in.h (c32stombs): Likewise.
9886         * modules/c32stombs (Depends-on): Add mbszero.
9888 2023-07-16  Bruno Haible  <bruno@clisp.org>
9890         mbstoc32s: Optimize clearing an mbstate_t.
9891         * lib/mbstoc32s.c (mbstoc32s): Use mbszero.
9892         * lib/uchar.in.h (mbstoc32s): Likewise.
9893         * modules/mbstoc32s (Depends-on): Add mbszero.
9895 2023-07-16  Bruno Haible  <bruno@clisp.org>
9897         mbstowcs: Optimize clearing an mbstate_t.
9898         * lib/mbstowcs.c (mbstowcs): Use mbszero.
9899         * modules/mbstowcs (Depends-on): Add mbszero.
9901 2023-07-16  Bruno Haible  <bruno@clisp.org>
9903         c32tob: Optimize clearing an mbstate_t.
9904         * lib/c32tob.c (c32tob): Use mbszero.
9905         * modules/c32tob (Depends-on): Add mbszero.
9907 2023-07-16  Bruno Haible  <bruno@clisp.org>
9909         wctomb: Optimize clearing an mbstate_t.
9910         * lib/wctomb-impl.h (wctomb): Use mbszero.
9911         * modules/wctomb (Depends-on): Add mbszero.
9913 2023-07-16  Bruno Haible  <bruno@clisp.org>
9915         btoc32: Optimize clearing an mbstate_t.
9916         * lib/btoc32.c: Include <wchar.h>.
9917         (btoc32): Use mbszero.
9918         * modules/btoc32 (Depends-on): Add mbszero.
9920 2023-07-16  Bruno Haible  <bruno@clisp.org>
9922         btowc: Optimize clearing an mbstate_t.
9923         * lib/btowc.c (btowc): Use mbszero.
9924         * modules/btowc (Depends-on): Add mbszero.
9926 2023-07-16  Bruno Haible  <bruno@clisp.org>
9928         mbrtoc32: Optimize clearing an mbstate_t.
9929         * lib/mbrtoc32.c (mbrtoc32): Use mbszero.
9930         * modules/mbrtoc32 (Depends-on): Add mbsinit, mbszero.
9932 2023-07-16  Bruno Haible  <bruno@clisp.org>
9934         mbtowc: Optimize clearing an mbstate_t.
9935         * lib/mbtowc-impl.h (mbtowc): Use mbszero.
9936         * modules/mbtowc (Depends-on): Add mbszero.
9938 2023-07-16  Bruno Haible  <bruno@clisp.org>
9940         mbszero: New module.
9941         * lib/wchar.in.h: Include <string.h>.
9942         (_GL_MBSTATE_INIT_SIZE, _GL_MBSTATE_ZERO_SIZE): New macros.
9943         (mbszero): New declaration.
9944         * lib/mbrtoc16.c: Update comments.
9945         * lib/mbszero.c: New file.
9946         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Initialize
9947         GNULIB_MBSZERO.
9948         * modules/wchar (Depends-on): Add extern-inline.
9949         (Makefile.am): Substitute GNULIB_MBSZERO.
9950         * modules/mbszero: New file.
9952 2023-07-15  Bruno Haible  <bruno@clisp.org>
9954         mbsinit: Fix module description.
9955         * modules/mbsinit (Files): Add m4/mbrtowc.m4.
9957 2023-07-15  Bruno Haible  <bruno@clisp.org>
9959         c32_apply_type_test: Fix compilation error with GCC < 9.
9960         * lib/uchar.in.h (c32_apply_type_test) [_GL_WCHAR_T_IS_UCS4]: Remove
9961         _GL_ARG_NONNULL attribute.
9963 2023-07-13  Bruno Haible  <bruno@clisp.org>
9965         mbchar: Optimize is_basic.
9966         * lib/mbchar.h (is_basic_table): Remove declaration.
9967         (is_basic) [IS_BASIC_ASCII]: Define through a simple range test.
9968         * lib/mbchar.c (is_basic_table): Remove array.
9970         localcharset: Clean up locale encodings used by glibc.
9971         * lib/localcharset.h: Remove VISCII from the list, since never supported
9972         in glibc/localedata/SUPPORTED. JOHAB is not supported by glibc any more
9973         since 2000-09-25. TCVN5712-1 is not supported by glibc any more since
9974         2012-05-21.
9976 2023-07-13  Bruno Haible  <bruno@clisp.org>
9978         doc: Mention c32_get_mapping, c32_apply_mapping.
9979         * doc/posix-functions/wctrans.texi: Mention c32_get_mapping.
9980         * doc/posix-functions/towctrans.texi: Mention c32_apply_mapping.
9981         * doc/strings.texi (Comparison of character APIs): Mention both.
9983         c32_apply_mapping: Add tests.
9984         * tests/test-c32_apply_mapping.c: New file.
9985         * modules/c32_apply_mapping-tests: New file.
9987         c32_apply_mapping: New module.
9988         * lib/uchar.in.h (c32_apply_mapping): New declaration.
9989         * lib/c32_apply_mapping.c: New file.
9990         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
9991         GNULIB_C32_APPLY_MAPPING.
9992         * modules/uchar (Makefile.am): Substitute GNULIB_C32_APPLY_MAPPING.
9993         * modules/c32_apply_mapping: New file.
9995         c32_get_mapping: Add tests.
9996         * tests/test-c32_get_mapping.c: New file.
9997         * modules/c32_get_mapping-tests: New file.
9999         c32_get_mapping: New module.
10000         * lib/uchar.in.h (c32_mapping_t): New type.
10001         (c32_get_mapping): New declaration.
10002         * lib/c32_get_mapping.c: New file, based on lib/wctrans-impl.h.
10003         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
10004         GNULIB_C32_GET_MAPPING.
10005         * modules/uchar (Makefile.am): Substitute GNULIB_C32_GET_MAPPING.
10006         * modules/c32_get_mapping: New file.
10008         towctrans: Relax license.
10009         * modules/towctrans (License): Change to LGPLv2+.
10010         * lib/towctrans.c: Update license notice.
10011         * lib/towctrans-impl.h: Likewise.
10013         wctrans: Relax license.
10014         * modules/wctrans (License): Change to LGPLv2+.
10015         * lib/wctrans.c: Update license notice.
10016         * lib/wctrans-impl.h: Likewise.
10018 2023-07-12  Bruno Haible  <bruno@clisp.org>
10020         doc: Mention c32_get_type_test, c32_apply_type_test.
10021         * doc/posix-functions/wctype.texi: Mention c32_get_type_test.
10022         * doc/posix-functions/iswctype.texi: Mention c32_apply_type_test.
10023         * doc/strings.texi (Comparison of character APIs): Mention both.
10025         c32_apply_type_test: Add tests.
10026         * tests/test-c32_apply_type_test.c: New file.
10027         * modules/c32_apply_type_test-tests: New file.
10029         c32_apply_type_test: New module.
10030         * lib/uchar.in.h (c32_apply_type_test): New declaration.
10031         * lib/c32_apply_type_test.c: New file.
10032         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
10033         GNULIB_C32_APPLY_TYPE_TEST.
10034         * modules/uchar (Makefile.am): Substitute GNULIB_C32_APPLY_TYPE_TEST.
10035         * modules/c32_apply_type_test: New file.
10037         c32_get_type_test: Add tests.
10038         * tests/test-c32_get_type_test.c: New file.
10039         * modules/c32_get_type_test-tests: New file.
10041         c32_get_type_test: New module.
10042         * lib/uchar.in.h (c32_type_test_t): New type.
10043         (c32_get_type_test): New declaration.
10044         * lib/c32_get_type_test.c: New file, based on lib/wctype-impl.h.
10045         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
10046         GNULIB_C32_GET_TYPE_TEST.
10047         * modules/uchar (Makefile.am): Substitute GNULIB_C32_GET_TYPE_TEST.
10048         * modules/c32_get_type_test: New file.
10050         iswctype: Relax license.
10051         * modules/iswctype (License): Change to LGPLv2+.
10052         * lib/iswctype.c: Update license notice.
10053         * lib/iswctype-impl.h: Likewise.
10055         wctype: Relax license.
10056         * modules/wctype (License): Change to LGPLv2+.
10057         * lib/wctype.c: Update license notice.
10058         * lib/wctype-impl.h: Likewise.
10060 2023-07-12  Bruno Haible  <bruno@clisp.org>
10062         mbiter, mbuiter: Small optimization.
10063         * lib/mbiter.h: Optimize away the in_shift field when the module
10064         'mbrtoc32-regular' is in use.
10065         * lib/mbuiter.h: Likewise.
10067 2023-07-12  Gavin Smith  <gavinsmith0123@gmail.com>
10069         gendocs: support chapter- and section-level split
10070         * doc/gendocs_template: Add lines to mark parts of file to output
10071         only when splitting HTML by node.
10072         Remove obsolete comment about ranges of years in copyright notice
10073         (as per Karl).
10074         * build-aux/gendocs.sh
10075         [!texi2html]: Strip out parts of the template depending on --split.
10076         [texi2html] Include all of the template as before.
10078 2023-07-11  Bruno Haible  <bruno@clisp.org>
10080         mbsrtoc32s, mbsnrtoc32s: Small optimization.
10081         * lib/mbsrtoc32s.c (USES_C32): Set to 0 when the module
10082         'mbrtoc32-regular' is in use.
10083         * lib/mbsnrtoc32s.c (USES_C32): Likewise.
10085 2023-07-11  Bruno Haible  <bruno@clisp.org>
10087         mbswidth: Add a benchmark.
10088         * tests/bench-mbswidth.c: New file, based on tests/bench-mbiter.c.
10089         * modules/mbswidth-bench-tests: New file.
10091         mbuiter: Add a benchmark.
10092         * tests/bench-mbuiter.c: New file, based on tests/bench-mbiter.c.
10093         * modules/mbuiter-bench-tests: New file.
10095         mbiter: Add a benchmark.
10096         * tests/bench-mbiter.c: New file.
10097         * tests/bench-multibyte.h: New file.
10098         * modules/mbiter-bench-tests: New file.
10100         tests: Create new file bench.h.
10101         * tests/bench.h: New file, extracted from tests/bench-digest.h.
10102         * tests/bench-digest.h: Include it.
10103         * modules/crypto/md5-buffer-tests (Files): Add tests/bench.h.
10104         * modules/crypto/sha1-buffer-tests (Files): Likewise.
10105         * modules/crypto/sha256-buffer-tests (Files): Likewise.
10106         * modules/crypto/sha512-buffer-tests (Files): Likewise.
10108 2023-07-11  Bruno Haible  <bruno@clisp.org>
10110         Optimize away some mbsinit calls.
10111         * lib/mbiter.h (mbiter_multi_next): When the module 'mbrtoc32-regular'
10112         is in use, don't invoke mbsinit and don't compare the mbrtoc32 result
10113         against (size_t)(-3).
10114         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
10115         * lib/mbfile.h (mbfile_multi_getc): Likewise.
10116         * lib/mbswidth.c (mbsnwidth): Likewise.
10117         * lib/mbmemcasecoll.c (apply_c32tolower): Likewise.
10118         * lib/quotearg.c (quotearg_buffer_restyled): Likewise.
10120 2023-07-11  Bruno Haible  <bruno@clisp.org>
10122         Fix build errors on Linux/hppa.
10123         * modules/math (Makefile.am): Split long pipe command into several
10124         smaller commands.
10125         * modules/pthread-h (Makefile.am): Likewise.
10126         * modules/stdio (Makefile.am): Likewise.
10127         * modules/stdlib (Makefile.am): Likewise.
10128         * modules/string (Makefile.am): Likewise.
10129         * modules/unictype/base (Makefile.am): Likewise.
10130         * modules/unistd (Makefile.am): Likewise.
10131         * modules/wchar (Makefile.am): Likewise.
10133 2023-07-11  Paul Eggert  <eggert@cs.ucla.edu>
10135         quotearg: update Solaris-related comments
10136         * doc/solaris-versions: Modernize.
10137         * lib/quotearg.c: Update comments.
10139 2023-07-10  Bruno Haible  <bruno@clisp.org>
10141         dfa: Overcome wchar_t limitations.
10142         * lib/localeinfo.h: Include <uchar.h>. Add special definitions for GAWK.
10143         (case_folded_counterparts): Change array element type to char32_t.
10144         * lib/localeinfo.c: Include <uchar.h>. Add special definitions for GAWK.
10145         (is_using_utf8, init_localeinfo): Use mbrtoc32 instead of mbrtowc.
10146         (lonesome_lower): Change element type to 'unsigned short'.
10147         (case_folded_counterparts): Change array element type to char32_t. Use
10148         c32toupper instead of towupper. Use c32tolower instead of towlower.
10149         * lib/dfa.c: Include <uchar.h>. Add special definitions for GAWK.
10150         (struct mb_char_classes): Change element type of 'chars' to char32_t.
10151         (mbs_to_wchar): Use mbrtoc32 instead of mbrtowc.
10152         (setbit_wc): Change type of first argument to char32_t. Use c32tob
10153         instead of wctob.
10154         (parse_bracket_exp): Update.
10155         (lex): Use c32isprint instead of iswprint. Use c32isspace instead of
10156         iswspace. Use c32rtomb instead of a %lc directive.
10157         (addtok_wc): Use c32rtomb instead of wcrtomb.
10158         (atom): Update.
10159         * modules/dfa (Depends-on): Remove wctype-h. Add uchar,
10160         mbrtoc32-regular, c32rtomb, c32tob, c32tolower, c32toupper, c32isprint,
10161         c32isspace.
10162         (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10163         * modules/dfa-tests (Makefile.am): Link test-dfa-match-aux with
10164         $(LIBUNISTRING) $(LIBC32CONV).
10165         * NEWS: Mention the change.
10167 2023-07-10  Bruno Haible  <bruno@clisp.org>
10169         mbrtoc32-regular: Add tests.
10170         * tests/test-mbrtoc32-regular.c: New file.
10171         * modules/mbrtoc32-regular-tests: New file.
10173         mbrtoc32-regular: New module.
10174         * modules/mbrtoc32-regular: New file.
10175         * lib/mbrtoc32.c (mbrtoc32): If the module 'mbrtoc32-regular' is present
10176         and the system's mbrtoc32 returned a char32_t, clear the mbstate_t.
10177         * doc/posix-functions/mbrtoc32.texi: Mention the new module.
10179 2023-07-10  Bruno Haible  <bruno@clisp.org>
10181         Apply the last change to all locale-*.m4 files.
10182         * m4/locale-ar.m4 (gt_LOCALE_AR): Reject locale name that might cause
10183         trouble with sh or make.
10184         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
10186 2023-07-09  Paul Eggert  <eggert@cs.ucla.edu>
10188         c32width: protect against bad configure args
10189         Avoid ‘test’ misuse with ‘./configure gt_cv_locale_fr=""’.
10190         Possible problem of this sort reported by Angelo Graziosi in:
10191         https://lists.gnu.org/r/emacs-devel/2023-07/msg00329.html
10192         * m4/locale-fr.m4 (gt_LOCALE_FR_UTF8, gt_LOCALE_FR_UTF8):
10193         * m4/locale-ja.m4 (gt_LOCALE_JA):
10194         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN):
10195         Reject locale names that might cause trouble with sh or make.
10197 2023-07-06  Bruno Haible  <bruno@clisp.org>
10199         wcscmp: Work around a glibc bug.
10200         Reported by مصعب الزعبي (Mosab Al-Zoubi) <moceap@hotmail.com> in
10201         <https://lists.gnu.org/archive/html/bug-gnulib/2023-07/msg00029.html>.
10202         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Test against a glibc/arm* bug.
10203         * doc/posix-functions/wcscmp.texi: Mention the glibc/arm* bug.
10205 2023-07-04  Bruno Haible  <bruno@clisp.org>
10207         mbiter, mbfile, mbmemcasecoll: Improve handling of mbrtoc32 result.
10208         * lib/mbiter.h (mbi_avail): If cur.ptr has reached the limit but
10209         in_shift is true, call mbiter_multi_next.
10210         (mbiter_multi_next): Set in_shift to false after an incomplete multibyte
10211         character.
10212         * lib/mbfile.h (mbfile_multi_getc): Pass the input bytes incrementally
10213         into mbrtoc32. When mbf->state is not in the initial state, call
10214         mbrtoc32 again.
10215         * lib/mbmemcasecoll.c (apply_c32tolower): When the state is not in the
10216         initial state, call mbrtoc32 again.
10218 2023-07-04  Bruno Haible  <bruno@clisp.org>
10220         mbiter, mbuiter, mbfile: Improve state handling after invalid input.
10221         * lib/mbiter.h (mbiter_multi_next): After an invalid multibyte sequence
10222         was encountered, clear the state.
10223         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
10224         * lib/mbfile.h (mbfile_multi_getc): Likewise.
10226 2023-07-04  Bruno Haible  <bruno@clisp.org>
10228         mbchar: Optimize all chars from the POSIX "portable character set".
10229         * lib/mbchar.h (is_basic): Include all the characters from the POSIX
10230         "portable character set".
10231         * lib/mbchar.c (is_basic_table): Likewise.
10232         * lib/mbiter.h (mbiter_multi_next): Update comment.
10233         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
10234         * lib/mbfile.h (mbfile_multi_getc): Likewise.
10236 2023-07-04  Paul Eggert  <eggert@cs.ucla.edu>
10238         mbchar: treat @, $, ` as basic
10239         The C standard says that @, $, ` must have a single-byte
10240         representation so they count as basic as far as multibyte
10241         character processing goes.
10242         * lib/mbchar.c (is_basic_table):
10243         * lib/mbchar.h (is_basic):
10244         * lib/mbswidth.c (mbsnwidth):
10245         Treat @, $, ` as basic too.
10247 2023-07-03  Bruno Haible  <bruno@clisp.org>
10249         mbrtoc32: Document another glibc bug.
10250         * doc/posix-functions/mbrtoc32.texi: Reference the glibc bug in
10251         BIG5-HKSCS locales.
10253 2023-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10255         mbrtoc32: document (size_t) -3 issue
10256         * doc/posix-functions/mbrtoc32.texi (mbrtoc32):
10257         Say (size_t) -3 might not be worth bothering about.
10259 2023-07-02  Bruno Haible  <bruno@clisp.org>
10261         mbsrtoc32s: Accommodate a difference between mbrtowc and mbrtoc32.
10262         * lib/mbsrtoc32s.c (USES_C32): New macro.
10263         * lib/mbsrtowcs.c (USES_C32): New macro.
10264         * lib/mbsrtowcs-impl.h (FUNC): If USES_C32 and mbrtoc32 returned
10265         (size_t)(-3), don't increment the pointer.
10267 2023-07-02  Bruno Haible  <bruno@clisp.org>
10269         mbsnrtoc32s: Accommodate a difference between mbrtowc and mbrtoc32.
10270         * lib/mbsnrtoc32s.c (USES_C32): New macro.
10271         * lib/mbsnrtowcs.c (USES_C32): New macro.
10272         * lib/mbsnrtowcs-impl.h (FUNC): If USES_C32 and mbrtoc32 returned
10273         (size_t)(-3), don't increment the pointer.
10275 2023-07-02  Bruno Haible  <bruno@clisp.org>
10277         mbmemcasecoll: Overcome wchar_t limitations.
10278         * lib/mbmemcasecoll.c: Include <uchar.h> instead of <wctype.h>.
10279         (apply_c32tolower): Renamed from apply_towlower. Use mbrtoc32 instead of
10280         mbrtowc. Use c32tolower instead of towlower. Use c32rtomb instead of
10281         wcrtomb.
10282         * modules/mbmemcasecoll (Depends-on): Remove mbrtowc, wcrtomb. Add
10283         uchar, mbrtoc32, c32rtomb, c32tolower.
10284         (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10285         * modules/mbmemcasecoll-tests (Makefile.am): Link test-mbmemcasecoll
10286         with $(LIBUNISTRING) $(LIBC32CONV).
10288 2023-07-02  Bruno Haible  <bruno@clisp.org>
10290         mbswidth: Overcome wchar_t limitations.
10291         * lib/mbswidth.c: Include <uchar.h> instead of <wctype.h>.
10292         (mbsnwidth): Use mbrtoc32 instead of mbrtowc. Use c32width instead of
10293         wcwidth. Use c32iscntrl instead of iswcntrl.
10294         * modules/mbswidth (Depends-on): Remove wctype-h, mbrtowc, wcwidth. Add
10295         uchar, mbrtoc32, c32width, c32iscntrl.
10296         (Link): Add $(LIBC32CONV).
10298 2023-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10300         Fix long bootstrap lines
10301         * top/bootstrap:
10302         * top/bootstrap-funclib.sh: Reformat to fit into 80 columns,
10303         for coreutils ‘make syntax-check’.
10305 2023-07-01  Bruno Haible  <bruno@clisp.org>
10307         doc: Update regarding stable branches.
10308         * doc/gnulib-readme.texi (Stable Branches): Mention new branch
10309         stable-202307. Mention that stable-202207 is no longer updated.
10311 2023-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10313         maint.mk: Modernize stddef.h checks for C23
10314         * top/maint.mk (_stddef_syms_re): Modernize for C23.
10316 2023-07-01  Bruno Haible  <bruno@clisp.org>
10318         quotearg: Overcome wchar_t limitations.
10319         * lib/quotearg.c: Include <uchar.h> instead of <wchar.h>, <wctype.h>.
10320         (quotearg_buffer_restyled): Use mbrtoc32, c32isprint instead of mbrtowc,
10321         iswprint.
10322         * modules/quotearg (Files): Remove m4/mbstate_t.m4, m4/mbrtowc.m4
10323         (redundant).
10324         (Depends-on): Add uchar, mbrtoc32, c32isprint. Remove wchar, wctype-h,
10325         mbrtowc.
10326         (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10327         * modules/quotearg-tests (Makefile.am): Link test-quotearg with
10328         $(LIBUNISTRING) $(LIBC32CONV).
10329         * modules/quotearg-simple (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10330         * modules/quotearg-simple-tests (Makefile.am): Link test-quotearg-simple
10331         with $(LIBUNISTRING) $(LIBC32CONV).
10332         --
10333         * modules/quote (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10334         --
10335         * modules/acl (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10336         * modules/acl-tests (Makefile.am): Link test-set-mode-acl and
10337         test-copy-acl with $(LIBUNISTRING) $(LIBC32CONV).
10338         * modules/copy-file (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10339         * modules/copy-file-tests (Makefile.am): Link test-copy-file with
10340         $(LIBUNISTRING) $(LIBC32CONV).
10341         --
10342         * modules/argmatch (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10343         * modules/argmatch-tests (Makefile.am): Link test-argmatch with
10344         $(LIBUNISTRING) $(LIBC32CONV).
10345         * modules/backup-rename (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10346         * modules/backupfile (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10347         * modules/human (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10348         --
10349         * modules/sh-quote (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10350         * modules/sh-quote-tests (Makefile.am): Link test-sh-quote with
10351         $(LIBUNISTRING) $(LIBC32CONV).
10352         * modules/system-quote (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10353         * modules/system-quote-tests (Makefile.am): Link test-system-quote-main
10354         with $(LIBUNISTRING) $(LIBC32CONV).
10355         * modules/csharpcomp (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10356         * modules/csharpexec (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10357         * modules/javacomp (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10358         * modules/javaexec (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10359         --
10360         * modules/string-desc-quotearg (Link): New section.
10361         * modules/string-desc-quotearg-tests (Makefile.am): Link
10362         test-string-desc-quotearg with $(LIBUNISTRING) $(LIBC32CONV).
10363         --
10364         * modules/xmemcoll (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10365         --
10366         * modules/closeout (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10367         * modules/readtokens-tests (Makefile.am): Link test-readtokens with
10368         $(LIBUNISTRING) $(LIBC32CONV).
10369         --
10370         * modules/closein (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10371         * modules/closein-tests (Makefile.am): Link test-closein with
10372         $(LIBUNISTRING) $(LIBC32CONV).
10373         * modules/yesno-tests (Makefile.am): Link test-yesno with
10374         $(LIBUNISTRING) $(LIBC32CONV).
10376 2023-06-30  Bruno Haible  <bruno@clisp.org>
10378         Accommodate a difference between mbrtowc and mbrtoc32.
10379         * lib/mbiter.h (mbiter_multi_next): Handle the mbrtoc32 return value
10380         (size_t)(-3).
10381         * lib/mbuiter.h (mbuiter_multi_next): Likewise.
10382         * lib/mbfile.h (mbfile_multi_getc): Likewise.
10384 2023-06-30  Bruno Haible  <bruno@clisp.org>
10386         doc: Reference some reported bugs (in comments).
10387         * doc/posix-functions/mbrlen.texi: Add references to bug reports.
10388         * doc/posix-functions/mbrtoc16.texi: Likewise.
10389         * doc/posix-functions/mbrtoc32.texi: Likewise.
10390         * doc/posix-functions/mbrtowc.texi: Likewise.
10391         * doc/posix-functions/mbsnrtowcs.texi: Likewise.
10392         * doc/posix-functions/mbsrtowcs.texi: Likewise.
10393         * doc/posix-functions/mbstowcs.texi: Likewise.
10395 2023-06-29  Paul Eggert  <eggert@cs.ucla.edu>
10397         assert-tests: pacify gcc -Wunused-function
10398         * tests/test-assert.c (main): Call f, so that the test
10399         works even if NDEBUG is defined.
10401         stddef-tests: pacify gcc -Wshadow
10402         * tests/test-stddef.c (mat): Rename from ‘x’.
10404         nullptr-tests: pacify gcc -Wmissing-declarations
10405         * tests/test-nullptr.c (varargs_callee): Now static.
10407 2023-06-29  Bruno Haible  <bruno@clisp.org>
10409         libtextstyle-optional: Update to gettext 0.22.
10410         * lib/textstyle.in.h: Declare all functions that were added in
10411         textstyle.h from gettext-0.22.
10413         libtextstyle-optional: Update to gettext 0.21.
10414         * lib/textstyle.in.h: Declare all functions that exist in textstyle.h
10415         from gettext-0.21, independently of iconv.
10417 2023-06-28  Bruno Haible  <bruno@clisp.org>
10419         doc: Mention c8rtomb and mbrtoc8 from ISO C 23.
10420         * doc/posix-functions/c8rtomb.texi: New file.
10421         * doc/posix-functions/mbrtoc8.texi: New file.
10422         * doc/gnulib.texi (Function Substitutes): Include them.
10424 2023-06-28  Bruno Haible  <bruno@clisp.org>
10426         mbrtoc16: Add tests.
10427         * tests/test-mbrtoc16.c: New file, based on tests/test-mbrtoc32.c.
10428         * tests/test-mbrtoc16-1.sh: New file, based on tests/test-mbrtoc32-1.sh.
10429         * tests/test-mbrtoc16-2.sh: New file, based on tests/test-mbrtoc32-2.sh.
10430         * tests/test-mbrtoc16-3.sh: New file, based on tests/test-mbrtoc32-3.sh.
10431         * tests/test-mbrtoc16-4.sh: New file, based on tests/test-mbrtoc32-4.sh.
10432         * tests/test-mbrtoc16-5.sh: New file, based on tests/test-mbrtoc32-5.sh.
10433         * tests/test-mbrtoc16-w32.c: New file, based on
10434         tests/test-mbrtoc32-w32.c.
10435         * tests/test-mbrtoc16-w32-1.sh: New file, based on
10436         tests/test-mbrtoc32-w32-1.sh.
10437         * tests/test-mbrtoc16-w32-2.sh: New file, based on
10438         tests/test-mbrtoc32-w32-2.sh.
10439         * tests/test-mbrtoc16-w32-3.sh: New file, based on
10440         tests/test-mbrtoc32-w32-3.sh.
10441         * tests/test-mbrtoc16-w32-4.sh: New file, based on
10442         tests/test-mbrtoc32-w32-4.sh.
10443         * tests/test-mbrtoc16-w32-5.sh: New file, based on
10444         tests/test-mbrtoc32-w32-5.sh.
10445         * tests/test-mbrtoc16-w32-6.sh: New file, based on
10446         tests/test-mbrtoc32-w32-6.sh.
10447         * tests/test-mbrtoc16-w32-7.sh: New file, based on
10448         tests/test-mbrtoc32-w32-7.sh.
10449         * modules/mbrtoc16-tests: New file, based on modules/mbrtoc32-tests.
10451         mbrtoc16: New module.
10452         * lib/uchar.in.h (mbrtoc16): New declaration.
10453         * lib/mbrtoc16.c: New file.
10454         * m4/mbrtoc16.m4: New file, based on m4/mbrtoc32.m4.
10455         * modules/mbrtoc16: New file.
10456         * m4/uchar_h.m4 (gl_UCHAR_H): Test whether mbrtoc16 is declared.
10457         (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize GNULIB_MBRTOC16.
10458         (gl_UCHAR_H_DEFAULTS): Initialize HAVE_MBRTOC16, REPLACE_MBRTOC16.
10459         * modules/uchar (Makefile.am): Substitute GNULIB_MBRTOC16,
10460         HAVE_MBRTOC16, REPLACE_MBRTOC16.
10461         * doc/posix-functions/mbrtoc16.texi: Mention the mbrtoc16 module and the
10462         mbsinit related limitation.
10463         * doc/posix-functions/mbsinit.texi: Mention the mbrtoc16 related
10464         limitation.
10466 2023-06-28  Bruno Haible  <bruno@clisp.org>
10468         c32*: Update comment.
10469         * lib/c32is-impl.h (FUNC): Add comment regarding Android.
10470         * lib/c32to-impl.h (FUNC): Likewise.
10471         * lib/c32width.c (c32width): Likewise.
10473 2023-06-28  Bruno Haible  <bruno@clisp.org>
10475         mbrtoc32: Doc tweak.
10476         * doc/posix-functions/mbrtoc32.texi: Mention that mingw and Android have
10477         the empty input bug.
10478         * m4/mbrtoc32.m4 (gl_MBRTOC32_EMPTY_INPUT): Update cross-compilation
10479         guess.
10481 2023-06-28  Bruno Haible  <bruno@clisp.org>
10483         mbrtowc: Doc tweak.
10484         * doc/posix-functions/mbrtowc.texi: Mention that MSVC has the empty
10485         input bug and the return value bug. Mention that Android has the empty
10486         input bug.
10487         * m4/mbrtowc.m4 (gl_MBRTOC32_EMPTY_INPUT): Update cross-compilation
10488         guess.
10490 2023-06-28  Bruno Haible  <bruno@clisp.org>
10492         mbrtowc, mbrtoc32: Simplify autoconf macros.
10493         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT, gl_MBRTOWC_C_LOCALE): Put
10494         cross-compilation guess at the usual place.
10495         * m4/mbrtoc32.m4 (gl_MBRTOC32_EMPTY_INPUT, gl_MBRTOC32_C_LOCALE):
10496         Likewise.
10498 2023-06-27  Bruno Haible  <bruno@clisp.org>
10500         c32*: Optionally enforce ISO C 23 semantics of char32_t.
10501         * lib/lc-charset-unicode.h: New file.
10502         * lib/lc-charset-unicode.c: New file.
10503         * modules/uchar-c23: New file.
10504         * lib/uchar.in.h (char32_t): Add comment.
10505         * lib/mbrtoc32.c: Include lc-charset-unicode.h.
10506         (mbrtoc32): If char32_t is Unicode and wchar_t is not, invoke
10507         locale_encoding_to_unicode.
10508         * lib/btoc32.c: Include lc-charset-unicode.h.
10509         (btoc32): If char32_t is Unicode and wchar_t is not, invoke
10510         locale_encoding_to_unicode.
10511         * lib/c32rtomb.c: Include lc-charset-unicode.h.
10512         (c32rtomb): If char32_t is Unicode and wchar_t is not, invoke
10513         unicode_to_locale_encoding.
10514         * lib/c32tob.c: Include lc-charset-unicode.h.
10515         (c32tob): If char32_t is Unicode and wchar_t is not, invoke
10516         unicode_to_locale_encoding.
10517         * lib/mbsnrtoc32s.c: If char32_t is Unicode and wchar_t is not, don't
10518         use mbsnrtowcs.
10519         * lib/mbsrtoc32s.c: If char32_t is Unicode and wchar_t is not, don't use
10520         mbsrtowcs.
10521         * lib/c32snrtombs.c: If char32_t is Unicode and wchar_t is not, don't
10522         use wcsnrtombs.
10523         * lib/c32srtombs.c: If char32_t is Unicode and wchar_t is not, don't use
10524         wcsrtombs.
10525         * lib/c32is-impl.h: Include lc-charset-unicode.h.
10526         (FUNC): If char32_t is Unicode and wchar_t is not, use UCS_FUNC.
10527         * lib/c32to-impl.h: Include lc-charset-unicode.h.
10528         (FUNC): If char32_t is Unicode and wchar_t is not, use UCS_FUNC.
10529         * lib/c32width.c: Include lc-charset-unicode.h.
10530         (c32width): If char32_t is Unicode and wchar_t is not, use uc_width.
10531         * tests/test-mbrtoc32.c: Include <wchar.h>.
10532         (main): Skip GB18030 tests on NetBSD and Solaris. If
10533         GL_CHAR32_T_IS_UNICODE, expect Unicode encoding for the char32_t values.
10534         * tests/test-mbrtoc32-w32.c: Include <wchar.h>.
10535         (test_one_locale): Simplify.
10536         * tests/test-c32rtomb.c (main): Skip GB18030 tests on NetBSD and
10537         Solaris.
10538         * tests/test-c32rtomb.sh: Update.
10539         * tests/test-mbsnrtoc32s.c: Include <wchar.h>.
10540         (main): Skip GB18030 tests on NetBSD and Solaris.
10541         * tests/test-mbsrtoc32s.c: Include <wchar.h>.
10542         (main): Skip GB18030 tests on NetBSD and Solaris.
10543         * tests/test-mbstoc32s.c (main): Skip GB18030 tests on NetBSD and
10544         Solaris.
10545         * tests/test-c32snrtombs.c (main): Skip GB18030 tests on NetBSD and
10546         Solaris.
10547         * tests/test-c32srtombs.c (main): Skip GB18030 tests on NetBSD and
10548         Solaris.
10549         * tests/test-c32stombs.c (main): Skip GB18030 tests on NetBSD and
10550         Solaris.
10551         * tests/test-c32isalnum.c (main): Skip GB18030 tests on NetBSD and
10552         Solaris.
10553         * tests/test-c32isalnum.sh: Update.
10554         * tests/test-c32isalpha.c (main): Skip GB18030 tests on NetBSD and
10555         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
10556         Solaris.
10557         * tests/test-c32isalpha.sh: Update.
10558         * tests/test-c32isblank.c (main): Skip GB18030 tests on NetBSD and
10559         Solaris.
10560         * tests/test-c32isblank.sh: Update.
10561         * tests/test-c32iscntrl.c (main): Skip GB18030 tests on NetBSD and
10562         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
10563         Solaris.
10564         * tests/test-c32iscntrl.sh: Update.
10565         * tests/test-c32isdigit.c (main): Skip GB18030 tests on NetBSD and
10566         Solaris.
10567         * tests/test-c32isdigit.sh: Update.
10568         * tests/test-c32isgraph.c (main): Skip GB18030 tests on NetBSD and
10569         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
10570         Solaris.
10571         * tests/test-c32isgraph.sh: Update.
10572         * tests/test-c32islower.c (main): Skip GB18030 tests on NetBSD and
10573         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
10574         Solaris.
10575         * tests/test-c32islower.sh: Update.
10576         * tests/test-c32isprint.c (main): Skip GB18030 tests on NetBSD and
10577         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
10578         Solaris.
10579         * tests/test-c32isprint.sh: Update.
10580         * tests/test-c32ispunct.c (main): Skip GB18030 tests on NetBSD and
10581         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
10582         Solaris.
10583         * tests/test-c32ispunct.sh: Update.
10584         * tests/test-c32isspace.c (main): Skip GB18030 tests on NetBSD and
10585         Solaris.
10586         * tests/test-c32isspace.sh: Update.
10587         * tests/test-c32isupper.c (main): Skip GB18030 tests on NetBSD and
10588         Solaris.
10589         * tests/test-c32isupper.sh: Update.
10590         * tests/test-c32isxdigit.c (main): Skip GB18030 tests on NetBSD and
10591         Solaris.
10592         * tests/test-c32isxdigit.sh: Update.
10593         * tests/test-c32tolower.c (main): Skip GB18030 tests on NetBSD and
10594         Solaris.
10595         * tests/test-c32tolower.sh: Update.
10596         * tests/test-c32toupper.c (main): Skip GB18030 tests on NetBSD and
10597         Solaris. Disable tests that would fail on macOS, FreeBSD, NetBSD,
10598         Solaris.
10599         * tests/test-c32toupper.sh: Update.
10600         * modules/mbrtoc32 (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10601         * modules/mbrtoc32-tests (Makefile.am): Link test-mbrtoc32 with
10602         $(LIBUNISTRING) $(LIBC32CONV).
10603         * modules/btoc32 (Link): New section.
10604         * modules/btoc32-tests (Makefile.am): Link test-btoc32 with
10605         $(LIBUNISTRING) $(LIBC32CONV).
10606         * modules/c32rtomb (Link): New section.
10607         * modules/c32rtomb-tests (Makefile.am): Link test-c32rtomb with
10608         $(LIBUNISTRING) $(LIBC32CONV).
10609         * modules/c32tob (Link): New section.
10610         * modules/mbsnrtoc32s (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10611         * modules/mbsnrtoc32s-tests (Makefile.am): Link test-mbsnrtoc32s with
10612         $(LIBUNISTRING) $(LIBC32CONV).
10613         * modules/mbsrtoc32s (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10614         * modules/mbsrtoc32s-tests (Makefile.am): Link test-mbsrtoc32s with
10615         $(LIBUNISTRING) $(LIBC32CONV).
10616         * modules/mbstoc32s (Link): Add $(LIBUNISTRING) $(LIBC32CONV).
10617         * modules/mbstoc32s-tests (Makefile.am): Link test-mbstoc32s with
10618         $(LIBUNISTRING) $(LIBC32CONV).
10619         * modules/c32snrtombs (Link): New section.
10620         * modules/c32snrtombs-tests (Makefile.am): Link test-c32snrtombs with
10621         $(LIBUNISTRING) $(LIBC32CONV).
10622         * modules/c32srtombs (Link): New section.
10623         * modules/c32srtombs-tests (Makefile.am): Link test-c32srtombs with
10624         $(LIBUNISTRING) $(LIBC32CONV).
10625         * modules/c32stombs (Link): New section.
10626         * modules/c32stombs-tests (Makefile.am): Link test-c32stombs with
10627         $(LIBUNISTRING) $(LIBC32CONV).
10628         * modules/c32isalnum (Link): Add $(LIBC32CONV).
10629         * modules/c32isalnum-tests (Makefile.am): Link test-c32isalnum with
10630         $(LIBC32CONV).
10631         * modules/c32isalpha (Link): Add $(LIBC32CONV).
10632         * modules/c32isalpha-tests (Makefile.am): Link test-c32isalpha with
10633         $(LIBC32CONV).
10634         * modules/c32isblank (Link): Add $(LIBC32CONV).
10635         * modules/c32isblank-tests (Makefile.am): Link test-c32isblank with
10636         $(LIBC32CONV).
10637         * modules/c32iscntrl (Link): Add $(LIBC32CONV).
10638         * modules/c32iscntrl-tests (Makefile.am): Link test-c32iscntrl with
10639         $(LIBC32CONV).
10640         * modules/c32isdigit (Link): Add $(LIBC32CONV).
10641         * modules/c32isdigit-tests (Makefile.am): Link test-c32isdigit with
10642         $(LIBC32CONV).
10643         * modules/c32isgraph (Link): Add $(LIBC32CONV).
10644         * modules/c32isgraph-tests (Makefile.am): Link test-c32isgraph with
10645         $(LIBC32CONV).
10646         * modules/c32islower (Link): Add $(LIBC32CONV).
10647         * modules/c32islower-tests (Makefile.am): Link test-c32islower with
10648         $(LIBC32CONV).
10649         * modules/c32isprint (Link): Add $(LIBC32CONV).
10650         * modules/c32isprint-tests (Makefile.am): Link test-c32isprint with
10651         $(LIBC32CONV).
10652         * modules/c32ispunct (Link): Add $(LIBC32CONV).
10653         * modules/c32ispunct-tests (Makefile.am): Link test-c32ispunct with
10654         $(LIBC32CONV).
10655         * modules/c32isspace (Link): Add $(LIBC32CONV).
10656         * modules/c32isspace-tests (Makefile.am): Link test-c32isspace with
10657         $(LIBC32CONV).
10658         * modules/c32isupper (Link): Add $(LIBC32CONV).
10659         * modules/c32isupper-tests (Makefile.am): Link test-c32isupper with
10660         $(LIBC32CONV).
10661         * modules/c32isxdigit (Link): Add $(LIBC32CONV).
10662         * modules/c32isxdigit-tests (Makefile.am): Link test-c32isxdigit with
10663         $(LIBC32CONV).
10664         * modules/c32tolower (Link): Add $(LIBC32CONV).
10665         * modules/c32tolower-tests (Makefile.am): Link test-c32tolower with
10666         $(LIBC32CONV).
10667         * modules/c32toupper (Link): Add $(LIBC32CONV).
10668         * modules/c32toupper-tests (Makefile.am): Link test-c32toupper with
10669         $(LIBC32CONV).
10670         * modules/c32width (Link): Add $(LIBC32CONV).
10671         * modules/c32width-tests (Makefile.am): Link test-c32width with
10672         $(LIBC32CONV).
10673         * modules/c32swidth (Link): Add $(LIBC32CONV).
10674         * modules/c32swidth-tests (Makefile.am): Link test-c32swidth with
10675         $(LIBC32CONV).
10676         * modules/mbchar (Link): Add $(LIBC32CONV).
10677         * modules/mbiter (Link): Add $(LIBC32CONV).
10678         * modules/mbuiter (Link): Add $(LIBC32CONV).
10679         * modules/mbfile (Link): Add $(LIBC32CONV).
10680         * modules/mbmemcasecmp (Link): Add $(LIBC32CONV).
10681         * modules/mbmemcasecmp-tests (Makefile.am): Link test-mbmemcasecmp with
10682         $(LIBC32CONV).
10683         * modules/mbscasecmp (Link): Add $(LIBC32CONV).
10684         * modules/mbscasecmp-tests (Makefile.am): Link test-mbscasecmp with
10685         $(LIBC32CONV).
10686         * modules/mbscasestr (Link): Add $(LIBC32CONV).
10687         * modules/mbscasestr-tests (Makefile.am): Link test-mbscasestr1,
10688         test-mbscasestr2, test-mbscasestr3, test-mbscasestr4 with $(LIBC32CONV).
10689         * modules/mbschr (Link): Add $(LIBC32CONV).
10690         * modules/mbschr-tests (Makefile.am): Link test-mbschr with
10691         $(LIBC32CONV).
10692         * modules/mbscspn (Link): Add $(LIBC32CONV).
10693         * modules/mbscspn-tests (Makefile.am): Link test-mbscspn with
10694         $(LIBC32CONV).
10695         * modules/mbslen (Link): Add $(LIBC32CONV).
10696         * modules/mbsncasecmp (Link): Add $(LIBC32CONV).
10697         * modules/mbsncasecmp-tests (Makefile.am): Link test-mbsncasecmp with
10698         $(LIBC32CONV).
10699         * modules/mbsnlen (Link): Add $(LIBC32CONV).
10700         * modules/mbspbrk (Link): Add $(LIBC32CONV).
10701         * modules/mbspbrk-tests (Makefile.am): Link test-mbspbrk with
10702         $(LIBC32CONV).
10703         * modules/mbspcasecmp (Link): Add $(LIBC32CONV).
10704         * modules/mbspcasecmp-tests (Makefile.am): Link test-mbspcasecmp with
10705         $(LIBC32CONV).
10706         * modules/mbsrchr (Link): Add $(LIBC32CONV).
10707         * modules/mbsrchr-tests (Makefile.am): Link test-mbsrchr with
10708         $(LIBC32CONV).
10709         * modules/mbssep (Link): Add $(LIBC32CONV).
10710         * modules/mbsspn (Link): Add $(LIBC32CONV).
10711         * modules/mbsspn-tests (Makefile.am): Link test-mbsspn with
10712         $(LIBC32CONV).
10713         * modules/mbsstr (Link): Add $(LIBC32CONV).
10714         * modules/mbsstr-tests (Makefile.am): Link test-mbsstr1, test-mbsstr2,
10715         test-mbsstr3 with $(LIBC32CONV).
10716         * modules/mbstok_r (Link): Add $(LIBC32CONV).
10717         * modules/propername (Link): Add $(LIBC32CONV).
10718         * modules/regex-quote (Link): Add $(LIBC32CONV).
10719         * modules/regex-quote-tests (Makefile.am): Link test-regex-quote with
10720         $(LIBC32CONV).
10721         * modules/trim (Link): Add $(LIBC32CONV).
10722         * modules/trim-tests (Makefile.am): Link test-trim with $(LIBC32CONV).
10723         * modules/exclude (Link): Add $(LIBC32CONV).
10724         * modules/exclude-tests (Makefile.am): Link test-exclude with
10725         $(LIBC32CONV).
10726         * doc/posix-headers/uchar.texi: Mention the uchar-c23 module.
10727         * doc/posix-functions/mbrtoc32.texi: Likewise.
10728         * doc/strings.texi (The char32_t type): Likewise.
10730 2023-06-27  Bruno Haible  <bruno@clisp.org>
10732         striconveh: Fix module description.
10733         * modules/striconveh (Link): Add $(LIBUNISTRING).
10734         * modules/striconveha (Link): New section.
10735         * modules/xstriconveh (Link): New section.
10737 2023-06-25  Bruno Haible  <bruno@clisp.org>
10739         strncat: Update doc regarding Solaris 11.4.
10740         * doc/posix-functions/strncat.texi: Mention that the bug still exists on
10741         Solaris 11.4.
10742         * m4/strncat.m4 (gl_FUNC_STRNCAT): Update comments.
10744 2023-06-25  Bruno Haible  <bruno@clisp.org>
10746         thread: Avoid compiler warnings on Solaris.
10747         * lib/glthread/thread.h: Include <stdint.h>.
10748         (gl_thread_self_pointer): Do the cast from pthread_t to 'void *' via
10749         intptr_t.
10750         * modules/thread (Depends-on): Add stdint.
10752 2023-06-25  Bruno Haible  <bruno@clisp.org>
10754         strerrorname_np: Add support for Solaris 11.4/sparc.
10755         * lib/strerrorname_np.c (strerrorname_np): Consider ECKSUM, EFRAGS.
10756         Allow ENOANO to be overloaded to another value.
10757         * tests/test-strerrorname_np.c (main): Likewise.
10759 2023-06-25  Jim Meyering  <meyering@meta.com>
10761         doc: correct doubled "on on"
10762         * doc/glibc-functions/initstate_r.texi: As above.
10763         * doc/posix-functions/initstate.texi: As above.
10765 2023-06-25  Bruno Haible  <bruno@clisp.org>
10767         sigdescr_np tests: Avoid test failure on glibc/sparc.
10768         * tests/test-sigdescr_np.c (main): Accept the glibc result for SIGEMT.
10769         * doc/glibc-functions/sigdescr_np.texi: Mention two glibc deficiencies.
10771 2023-06-25  Bruno Haible  <bruno@clisp.org>
10773         strerrorname_np: Work around glibc bug on PowerPC, SPARC systems.
10774         * m4/strerrorname_np.m4 (gl_FUNC_STRERRORNAME_NP): Test also
10775         strerrorname_np (EDEADLOCK).
10776         * doc/glibc-functions/strerrorname_np.texi: Mention that glibc 2.36
10777         still needs a workaround.
10779 2023-06-25  Bruno Haible  <bruno@clisp.org>
10781         doc: Mention glibc initstate, initstate_r bug.
10782         * doc/posix-functions/initstate.texi: Mention glibc bug.
10783         * doc/glibc-functions/initstate_r.texi: Likewise.
10784         * tests/test-random_r.c: Add a comment.
10786 2023-06-25  Bruno Haible  <bruno@clisp.org>
10788         doc: Update doc regarding 'setstate'.
10789         * doc/posix-functions/setstate.texi: Mention also Solaris 11.4.
10791 2023-06-25  Bruno Haible  <bruno@clisp.org>
10793         doc: Update doc regarding <ieee754.h>.
10794         * doc/glibc-headers/ieee754.texi: Mention that it's not present on
10795         glibc/sparc64 in 32-bit mode.
10797 2023-06-25  Bruno Haible  <bruno@clisp.org>
10799         exclude: Complete last change.
10800         * lib/exclude.c: Include <uchar.h> instead of <wctype.h>.
10802 2023-06-24  Bruno Haible  <bruno@clisp.org>
10804         mbchar, mbiter, mbuiter: Overcome wchar_t limitations.
10805         * lib/mbchar.h: Include <uchar.h> instead of <wchar.h>, <wctype.h>.
10806         (struct mbchar): Use char32_t instead of wchar_t.
10807         (mb_casecmp, mb_caseequal): Use c32tolower instead of towlower.
10808         (mb_isalnum): Use c32isalnum instead of iswalnum.
10809         (mb_isalpha): Use c32isalpha instead of iswalpha.
10810         (mb_isblank): Use c32isblank instead of iswblank.
10811         (mb_iscntrl): Use c32iscntrl instead of iswcntrl.
10812         (mb_isdigit): Use c32isdigit instead of iswdigit.
10813         (mb_isgraph): Use c32isgraph instead of iswgraph.
10814         (mb_islower): Use c32islower instead of iswlower.
10815         (mb_isprint): Use c32isprint instead of iswprint.
10816         (mb_ispunct): Use c32ispunct instead of iswpunct.
10817         (mb_isspace): Use c32isspace instead of iswspace.
10818         (mb_isupper): Use c32isupper instead of iswupper.
10819         (mb_isxdigit): Use c32isxdigit instead of iswxdigit.
10820         (mb_width_aux): Use c32width, c32iscntrl instead of wcwidth, iswcntrl.
10821         * lib/mbiter.h: Include <uchar.h> instead of <wchar.h>.
10822         (mbiter_multi_next): Use mbrtoc32 instead of mbrtowc.
10823         * lib/mbuiter.h: Include <uchar.h> instead of <wchar.h>.
10824         (mbuiter_multi_next): Use mbrtoc32 instead of mbrtowc.
10825         * lib/mbfile.h (mbfile_multi_getc): Use mbrtoc32 instead of mbrtowc.
10826         * lib/mbscasestr.c (knuth_morris_pratt_multibyte, mbscasestr): Use
10827         c32tolower instead of towlower.
10828         * lib/exclude.c (string_hasher_ci): Use char32_t, c32tolower instead of
10829         wchar_t, towlower.
10830         * modules/mbchar (Depends-on): Add uchar, c32isalnum, c32isalpha,
10831         c32isblank, c32iscntrl, c32isdigit, c32isgraph, c32islower, c32isprint,
10832         c32ispunct, c32isspace, c32isupper, c32isxdigit, c32tolower, c32width.
10833         Remove wchar, wctype-h, iswblank, iswdigit, iswxdigit, wcwidth.
10834         * modules/mbiter (Depends-on): Add mbrtoc32, uchar. Remove mbrtowc,
10835         wchar.
10836         * modules/mbuiter (Depends-on): Likewise.
10837         * modules/mbscasestr (Depends-on): Add c32tolower.
10838         * modules/exclude (Depends-on): Add c32tolower.
10839         * doc/strings.texi (C strings): Fix typo.
10841 2023-06-22  Bruno Haible  <bruno@clisp.org>
10843         doc: Use makeinfo option to check menu structure.
10844         Trick revealed by Patrice Dumas <pertusus@free.fr> in
10845         <https://lists.gnu.org/archive/html/bug-texinfo/2023-06/msg00015.html>.
10846         * doc/Makefile (MAKEINFO): Enforce checking of menu structure.
10848 2023-06-22  Bruno Haible  <bruno@clisp.org>
10850         doc: Correct info menu structure.
10851         Reported by Elijah Zarezky <elijah@zarezky.spb.ru> in
10852         <https://lists.gnu.org/archive/html/bug-gnulib/2023-06/msg00105.html>.
10853         * doc/strings.texi (Strings): Add missing @menu item.
10855 2023-06-20  Paul Eggert  <eggert@cs.ucla.edu>
10857         doc: INSTALL uses UTF-8 now
10858         * doc/Makefile (INSTALL.ISO, INSTALL.UTF-8):
10859         Adjust to the fact that INSTALL now uses UTF-8.
10860         INSTALL.UTF-8 is now obsolescent since it is identical.
10861         (INSTALL.ISO): Transliterate all non-ASCII characters,
10862         not just single quotes.
10863         * doc/INSTALL.ISO: Regenerate.
10865 2023-06-19  Paul Eggert  <eggert@cs.ucla.edu>
10867         largefile: port to GNU/Linux s390x and alpha
10868         This patch syncs from Autoconf master.
10869         Problem reported by Matoro <https://bugs.gnu.org/64123>.
10870         * lib/autoconf/specific.m4 (_AC_SYS_LARGEFILE_TEST_CODE):
10871         New overridable macro FTYPE, to test types other than off_t.
10872         (_AC_SYS_LARGEFILE_TEST_CODE): Test ino_t for
10873         -D_FILE_OFFSETBITS=64 too, if no flags are needed for off_t.
10874         Needed for GNU/Linux on alpha and s390x.
10876 2023-06-19  Bruno Haible  <bruno@clisp.org>
10878         doc: Corrections to the "Strings and Characters" chapter.
10879         Suggested by Paul Eggert.
10880         * doc/strings.texi: Corrections: GB18030 is rarely used nowadays.
10881         <ctype.h> functions can be useful for specific data.
10883 2023-06-19  Bruno Haible  <bruno@clisp.org>
10885         doc: Use "spaced en dash" style instead of "spaced em dash" style.
10886         Suggested by Paul Eggert.
10887         * doc/gnulib.texi: At sentence level, use "spaced en dash" style instead
10888         of "spaced em dash" style.
10889         * doc/gnulib-intro.texi: Likewise.
10890         * doc/multithread.texi: Likewise.
10891         * doc/strings.texi: Likewise.
10893 2023-06-19  Bruno Haible  <bruno@clisp.org>
10895         setenv: Simplify m4 requires.
10896         * m4/setenv.m4 (gl_PREREQ_SETENV): Don't require AC_FUNC_ALLOCA.
10898 2023-06-18  Bruno Haible  <bruno@clisp.org>
10900         configmake: Bypass the unusable 'echo' command of some shells.
10901         Reported by Brian Inglis <Brian.Inglis@Shaw.ca> in
10902         <https://lists.gnu.org/archive/html/bug-gettext/2023-06/msg00054.html>.
10903         * m4/build-to-host.m4 (gl_BUILD_TO_HOST): Use 'printf' instead of
10904         'echo', because the "dash" shell has a SystemV compatible 'echo'
10905         command. Also, be sure to remove trailing CRs.
10907 2023-06-18  Paul Eggert  <eggert@cs.ucla.edu>
10909         update-copyright tests: fix to match behavior
10910         * tests/test-update-copyright.sh: Change tests to match new behavior.
10912 2023-06-18  Bruno Haible  <bruno@clisp.org>
10914         update-copyright tests: Add tests for man pages.
10915         * tests/test-update-copyright.sh: Add 4 tests that use man page syntax.
10917 2023-06-18  Bruno Haible  <bruno@clisp.org>
10919         gettext: Clarify the purpose of this module.
10920         Suggested by Paul Eggert in
10921         <https://lists.gnu.org/archive/html/bug-gnulib/2023-06/msg00089.html>.
10922         * modules/gettext (Description): Clarify the purpose.
10923         (Makefile.am): Remove outdated comment. "gettextize --intl" is no longer
10924         possible since 2019.
10926 2023-06-18  Paul Eggert  <eggert@cs.ucla.edu>
10928         Update \(en in copyright notices
10929         * build-aux/update-copyright (ndash_re): New var, matching \(en too.
10930         (stmt_remainder_re, stmt): Use it.
10931         (stmt): Match year in constructs like "\(en2023".
10932         (ndash): Now \(en in man pages.
10934 2023-06-17  Bruno Haible  <bruno@clisp.org>
10936         gettext: Update to gettext 0.22.
10937         * modules/gettext (Files): Add m4/build-to-host.m4.
10938         (configure.ac): Request infrastructure compatible with gettext 0.22.
10939         * m4/gettext.m4: Update from gettext 0.22.
10940         * m4/po.m4: Likewise.
10942 2023-06-15  Bruno Haible  <bruno@clisp.org>
10944         aligned-malloc, rmdir-errno: Sanitize configuration test result.
10945         * m4/malloc-align.m4 (gl_MALLOC_ALIGNMENT): Don't put a newline at the
10946         end of the conftest.out file.
10947         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Don't put a newline at the
10948         end of the confdir2/errno file.
10950 2023-06-13  Bruno Haible  <bruno@clisp.org>
10952         Make internationalization tests stricter on musl systems.
10953         --
10954         * m4/locale-fr.m4 (gt_LOCALE_FR): On musl systems, set LOCALE_FR_UTF8 to
10955         "fr_FR.UTF-8" instead of "none". Set and substitute
10956         LC_COLLATE_IMPLEMENTED, LC_NUMERIC_IMPLEMENTED, LC_TIME_IMPLEMENTED,
10957         LC_MONETARY_IMPLEMENTED.
10958         * m4/iswdigit.m4 (gl_FUNC_ISWDIGIT): Skip testing a certain locale if
10959         that locale is "none".
10960         * m4/iswxdigit.m4 (gl_FUNC_ISWXDIGIT): Likewise.
10961         * m4/mbrlen.m4 (gl_MBRLEN_RETVAL): Likewise.
10962         * m4/mbrtowc.m4 (gl_MBRTOWC_RETVAL): Likewise.
10963         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Likewise.
10964         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
10965         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
10966         --
10967         * tests/test-c32isalpha.c (main): On musl libc, disable tests that fail.
10968         * tests/test-c32iscntrl.c (main): Likewise.
10969         * tests/test-c32isgraph.c (main): Likewise.
10970         * tests/test-c32islower.c (main): Likewise.
10971         * tests/test-c32isprint.c (main): Likewise.
10972         * tests/test-c32toupper.c (main): Likewise.
10973         * tests/test-nl_langinfo1.c (main): Likewise.
10974         * tests/test-nl_langinfo2.c (main): Likewise.
10975         * modules/c32isalpha-tests (Files): Add musl.m4.
10976         (configure.ac): Invoke gl_MUSL_LIBC.
10977         * modules/c32iscntrl-tests (Files): Add musl.m4.
10978         (configure.ac): Invoke gl_MUSL_LIBC.
10979         * modules/c32isgraph-tests (Files): Add musl.m4.
10980         (configure.ac): Invoke gl_MUSL_LIBC.
10981         * modules/c32islower-tests (Files): Add musl.m4.
10982         (configure.ac): Invoke gl_MUSL_LIBC.
10983         * modules/c32isprint-tests (Files): Add musl.m4.
10984         (configure.ac): Invoke gl_MUSL_LIBC.
10985         * modules/c32toupper-tests (Files): Add musl.m4.
10986         (configure.ac): Invoke gl_MUSL_LIBC.
10987         * modules/nl_langinfo-tests (Files): Add musl.m4.
10988         (configure.ac): Invoke gl_MUSL_LIBC.
10989         --
10990         * tests/test-strtod1.sh: Skip the test if LC_NUMERIC_IMPLEMENTED is
10991         false.
10992         * tests/test-strtold1.sh: Likewise.
10993         * tests/test-vasnprintf-posix2.sh: Likewise.
10994         * tests/test-vasnwprintf-posix2.sh: Likewise.
10995         * modules/strtod-tests (Makefile.am): Set LC_NUMERIC_IMPLEMENTED in the
10996         tests environment.
10997         * modules/strtold-tests (Makefile.am): Likewise.
10998         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
10999         * modules/vasnwprintf-posix-tests (Makefile.am): Likewise.
11001 2023-06-12  Bruno Haible  <bruno@clisp.org>
11003         vasnwprintf-posix: Work around another musl libc bug.
11004         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LC): New macro.
11005         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke it, and set
11006         NEED_WPRINTF_DIRECTIVE_LC if the %lc test failed.
11007         * lib/vasnprintf.c (VASNPRINTF): If NEED_WPRINTF_DIRECTIVE_LC is set, do
11008         the processing for %lc and %ls ourselves.
11009         (local_wcslen): Update condition.
11010         * doc/posix-functions/swprintf.texi: Mention the %lc problem.
11012 2023-06-12  Bruno Haible  <bruno@clisp.org>
11014         vasnwprintf-posix: Work around a musl libc bug.
11015         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Test also whether swprintf
11016         in the C locale is free of encoding errors, and set
11017         NEED_WPRINTF_DIRECTIVE_C if not.
11018         * doc/posix-functions/swprintf.texi: Clarify the list of platforms for
11019         the %c problem.
11021 2023-06-12  Bruno Haible  <bruno@clisp.org>
11023         vasnwprintf: Fix some cross-compilation results.
11024         * m4/printf.m4 (gl_SWPRINTF_WORKS): Fix cross-compilation result for
11025         musl.
11026         (gl_SWPRINTF_DIRECTIVE_LA): Fix cross-compilation result for Android.
11028 2023-06-12  Bruno Haible  <bruno@clisp.org>
11030         warnings: Save memory and CPU time when inhibiting all warnings.
11031         * m4/warnings.m4 (gl_WARN_ADD): Improve comments.
11032         (gl_CC_INHIBIT_WARNINGS): Add also '-fno-analyzer' to
11033         GL_CFLAG_INHIBIT_WARNINGS.
11034         (gl_CXX_INHIBIT_WARNINGS): Add also '-fno-analyzer' to
11035         GL_CXXFLAG_INHIBIT_WARNINGS.
11037 2023-06-11  Bruno Haible  <bruno@clisp.org>
11039         javacomp-script, javacomp: Document effects of yesterday's change.
11040         * NEWS: Mention yesterday's change.
11042 2023-06-11  Bruno Haible  <bruno@clisp.org>
11044         javacomp-script, javacomp: Silence javac warnings regarding [options].
11045         * m4/javacomp.m4 (gt_JAVACOMP): Use option '-Xlint:-options' by default
11046         and omit it only when it does not work.
11047         * lib/javacomp.c (compile_using_javac): Add nowarn_option parameter.
11048         (is_envjavac_usable): Add nowarn_option_out parameter. Use option
11049         '-Xlint:-options' by default and omit it only when it does not work.
11050         (is_javac_usable): Likewise.
11051         (compile_java_class): Store the nowarn_option returned from
11052         is_envjavac_usable and use it when invoking compile_using_envjavac.
11053         Store the nowarn_option returned from is_javac_usable and use it when
11054         invoking compile_using_javac.
11056 2023-06-10  Bruno Haible  <bruno@clisp.org>
11058         javacomp-script, javacomp: Add support for javac versions > 11.
11059         Reported by Adrian Bunk <bunk-gnu@fs.tum.de> in
11060         <https://savannah.gnu.org/bugs/?63385>.
11061         * m4/javacomp.m4 (gt_JAVACOMP): When the java version is > 11, use that
11062         version as target_version, not 11. When the java version is > 17, don't
11063         warn. Remove goodcode, failcode variables. Don't bail out if the
11064         source-version argument or the target-version argument is in the range
11065         12..99. Use a heuristic that works with javac versions 11..20 at least.
11066         Update comments.
11067         * lib/javacomp.h (compile_java_class): State that source-version and
11068         target-version may be larger than 11.
11069         * lib/javacomp.c (default_target_version): Accommodate versions up to
11070         99.
11071         (SOURCE_VERSION_BOUND): Increase to 94.
11072         (source_version_index): Accept versions up to 99.
11073         (get_goodcode_snippet, get_failcode_snippet): Remove functions.
11074         (TARGET_VERSION_BOUND): Increase to 94.
11075         (target_version_index): Accept versions up to 99.
11076         (corresponding_classfile_version): Remove function.
11077         (execute_and_read_line): New function, based on lib/javaversion.c.
11078         (get_compiler_version): New function.
11079         (is_envjavac_usable): Add parameters source_option_out,
11080         target_option_out. Use a heuristic that works with javac versions 11..20
11081         at least. Call cleanup_temp_dir.
11082         (is_javac_usable): Likewise.
11083         (compile_java_class): Update.
11085 2023-06-10  Bruno Haible  <bruno@clisp.org>
11087         javacomp-script, javacomp: Remove support for javac versions < 1.6.
11088         * m4/javacomp.m4 (gt_JAVACOMP): State that the minimum source_version
11089         and the minimum target_version are 1.6. Map smaller values to 1.6.
11090         Complain if the java version is < 1.6. Use 1.6 as default, instead of
11091         1.1. Don't bother trying the -target option alone.
11092         * lib/javacomp.h (compile_java_class): State that the minimum
11093         source_version and the minimum target_version are 1.6.
11094         * lib/javacomp.c (default_target_version): Complain if the java version
11095         is < 1.6. Use 1.6 as default, instead of 1.1.
11096         (SOURCE_VERSION_BOUND, source_version_index, get_goodcode_snippet,
11097         get_failcode_snippet): Adjust to the new minimum source_version = 1.6.
11098         (TARGET_VERSION_BOUND, target_version_index,
11099         corresponding_classfile_version): Adjust to the new minimum
11100         target_version = 1.6.
11101         (get_source_version_for_javac): Remove function.
11102         (is_envjavac_usable): Remove source_version_for_javac parameter. Don't
11103         bother trying the -target option alone.
11104         (is_javac_usable): Likewise.
11105         (compile_java_class): Map source_version < 1.6 to 1.6. Map
11106         target_version < 1.6 to 1.6. Use source_version instead of calling
11107         get_source_version_for_javac.
11109 2023-06-10  Bruno Haible  <bruno@clisp.org>
11111         javacomp: Simplify after gcj support was removed.
11112         * m4/javacomp.m4 (gt_JAVACOMP): Don't create conftestlib.java.
11113         * lib/javacomp.c (compile_java_class): Remove local variables
11114         no_assert_option, fsource_option, ftarget_option.
11116 2023-06-09  Bruno Haible  <bruno@clisp.org>
11118         doc: Document <stdatomic.h>.
11119         * doc/posix-headers/stdatomic.texi: New file.
11120         * doc/gnulib.texi (Header File Substitutes): Include it.
11122 2023-06-09  Jim Meyering  <meyering@meta.com>
11124         maint.mk: sc_prohibit_xalloc_without_use: also match alloc_die
11125         * top/maint.mk (sc_prohibit_xalloc_without_use):
11126         Adjust in-comment command's regexp so it also finds alloc_die,
11127         whose declaration has a prefix of "_Noreturn ".
11128         Also delete some now-obsolete commentary.
11129         (_xa1): Regenerate the regexp using that command.
11130         Reported by Pádraig Brady in
11131         <https://lists.gnu.org/r/bug-gnulib/2023-06/msg00062.html>.
11133 2023-06-09  Paul Eggert  <eggert@cs.ucla.edu>
11135         xalloc-die: omit /*extern*/
11136         * lib/xalloc.h (xalloc_die): Omit leading "/*extern*/".
11137         It complicates syntax checking; see:
11138         https://lists.gnu.org/r/bug-gnulib/2023-06/msg00062.html
11139         Plus, it’s inconsistent style: the other function declarations in
11140         xalloc.h don’t use ‘extern’. (I’m not a fan of using ‘extern’ when
11141         it’s just noise, as is the case here.)
11143 2023-06-09  Bruno Haible  <bruno@clisp.org>
11145         javaversion: Update comments.
11146         * lib/javaversion.h (javaexec_version): Document the possible results up
11147         to OpenJDK 20.
11149 2023-06-09  Bruno Haible  <bruno@clisp.org>
11151         javacomp: Remove support for 'jikes'.
11152         * lib/javacomp.c (compile_using_jikes, is_jikes_present): Remove
11153         functions.
11154         (compile_java_class): Remove jikes related code.
11156         javacomp-script: Remove support for 'jikes'.
11157         * build-aux/javacomp.sh.in: Don't test HAVE_JIKES.
11158         * m4/javacomp.m4 (gt_JAVACOMP): Don't set HAVE_JIKES. Don't set
11159         CONF_JAVAC to 'jikes'. Update comment.
11160         (gt_JAVACOMP_DISABLED): Don't set HAVE_JIKES.
11162 2023-06-09  Bruno Haible  <bruno@clisp.org>
11164         javacomp: Remove support for 'gcj'.
11165         * lib/javacomp.h: Update comment.
11166         * lib/javacomp.c (compile_using_gcj, is_envjavac_gcj, is_envjavac_gcj43,
11167         is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
11168         is_envjavac_oldgcj_14_13_usable, is_gcj_present, is_gcj_43,
11169         is_gcj43_usable, is_oldgcj_14_14_usable, is_oldgcj_14_13_usable): Remove
11170         functions.
11171         (is_envjavac_usable): Renamed from is_envjavac_nongcj_usable.
11172         (compile_java_class): Remove gcj related code.
11174         javacomp-script: Remove support for 'gcj'.
11175         * build-aux/javacomp.sh.in: Don't test HAVE_GCJ_C.
11176         * m4/javacomp.m4 (gt_JAVACOMP): Don't set HAVE_GCJ_C. Don't test whether
11177         $JAVAC is gcj. Don't set CONF_JAVAC to 'gcj -C'. Update comment.
11178         (gt_JAVACOMP_DISABLED): Don't set HAVE_GCJ_C.
11180         javaexec: Remove support for 'gij'.
11181         * lib/javaexec.c (execute_java_class): Don't test for gij.
11183         javaexec-script: Remove support for 'gij'.
11184         * build-aux/javaexec.sh.in: Don't test HAVE_GIJ.
11185         * m4/javaexec.m4 (gt_JAVAEXEC): Don't set HAVE_GIJ. Don't set CONF_JAVA
11186         to 'gij'.
11187         * m4/javacomp.m4: Update comment.
11189 2023-06-09  Bruno Haible  <bruno@clisp.org>
11191         javaexec: Remove support for 'jview'.
11192         * lib/javaexec.c (execute_java_class): Don't test for jview.
11194         javaexec-script: Remove support for 'jview'.
11195         * build-aux/javaexec.sh.in: Don't test HAVE_JVIEW.
11196         * m4/javaexec.m4 (gt_JAVAEXEC): Don't set HAVE_JVIEW. Don't set
11197         CONF_JAVA to 'jview'.
11198         (gt_JAVAEXEC_DISABLED): Don't set HAVE_JVIEW.
11199         * m4/javacomp.m4: Update comment.
11201 2023-06-06  Jim Meyering  <meyering@meta.com>
11203         maint.mk: regenerate regex to reflect new functions in xalloc.h
11204         * top/maint.mk (sc_prohibit_xalloc_without_use) [_xa1]:
11205         Regenerate using the command listed in the comment.
11207 2023-06-06  Paul Eggert  <eggert@cs.ucla.edu>
11209         propername: pacify po_check
11210         Problem reported by Bruno Haible <https://bugs.gnu.org/63933>.
11211         * lib/propername.h: Change comment.
11213         Put "/" at end of .gitignore directory names
11214         * build-aux/bootstrap: Regenerate.
11215         * top/bootstrap-funclib.sh (symlink_to_dir, autogen):
11216         Put slashes after .gitignore entries that name directories.
11218 2023-06-06  Jose E. Marchesi  <jemarch@gnu.org>
11220         maintainer-makefile: Enforce the GNU Coding Standards in the README.
11221         * top/maint.mk (sc_readme_link_install): New rule.
11222         (sc_readme_link_copying): Likewise.
11224 2023-06-05  Paul Eggert  <eggert@cs.ucla.edu>
11226         copy-file-range: support building for older kernels
11227         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE):
11228         Remove static check, to support the dubious practice of
11229         building for platforms that predate the build platform.
11230         On working kernels this adds an extra syscall the first time
11231         that copy_file_range is used.  Problem reported for Gentoo by
11232         Sam James <https://bugs.gnu.org/63850>.
11234         manywarnings: more nuance about optimization
11235         * doc/manywarnings.texi (manywarnings): Suggest compiling with the
11236         optimization flags commonly used, as opposed to -O2 and -O0
11237         specifically.  -ggdb shouldn’t affect warnings so don’t mention it.
11239 2023-06-05  Bruno Haible  <bruno@clisp.org>
11241         posix_spawn-internal: Fix a warning (regression 2022-11-20).
11242         * lib/spawni.c: Don't use this particular #pragma for gcc < 4.2.
11244 2023-06-05  Bruno Haible  <bruno@clisp.org>
11246         file-has-acl: Fix compilation error on Slackware 13 (regr. 2023-05-12).
11247         * lib/file-has-acl.c (XATTR_NAME_POSIX_ACL_ACCESS,
11248         XATTR_NAME_POSIX_ACL_DEFAULT): Add fallback definitions.
11250 2023-06-05  Bruno Haible  <bruno@clisp.org>
11252         Fix bugs on mingw when module dirfd is in use (regression 2023-04-26).
11253         * lib/getcwd.c: When GNULIB_defined_DIR, revert to the system's
11254         definitions of opendir, closedir, readdir, rewinddir.
11255         * lib/mountlist.c: When GNULIB_defined_DIR, revert to the system's
11256         definitions of opendir, closedir, readdir.
11257         * lib/scandir.c: Likewise.
11258         * lib/glob.c: Fix comment. When GNULIB_defined_DIR, don't undefine
11259         opendir, closedir.
11261 2023-06-04  Bruno Haible  <bruno@clisp.org>
11263         manywarnings: Overhaul documentation.
11264         * doc/manywarnings.texi: In the example, put all unwanted warning
11265         options into 'nw', and use a second gl_MANYWARN_COMPLEMENT invocation to
11266         sort out how these options need to get added to WARN_FLAGS.
11267         Describe the first-time use in more detail: Recommend a new GCC.
11268         Recommend to test builds with -O2 and with -O0. Suggest to sort the
11269         warning by warning option. Add reference to the GCC pragma's
11270         documentation.
11272 2023-06-04  Bruno Haible  <bruno@clisp.org>
11274         error: Fix support for library namespacing (regression 2023-05-27).
11275         * lib/error.in.h (error): If error is defined as a macro, define a
11276         static inline function _gl_inline_error that invokes it, and let the
11277         new error macro invoke that function.
11278         (error_at_line): If error_at_line is defined as a macro, define a static
11279         inline function _gl_inline_error_at_line that invokes it, and let the
11280         new error_at_line macro invoke that function.
11282 2023-06-04  Bruno Haible  <bruno@clisp.org>
11284         terminfo, termcap: Fix "discards 'const' qualifier" warnings.
11285         * lib/tparm.c (tparm): Change type of 'fmt'. New local variable 'fmtp'.
11287 2023-06-04  Bruno Haible  <bruno@clisp.org>
11289         uniname/uniname: Add comments.
11290         * modules/uniname/uniname (Makefile.am): Explain how to work around a
11291         GCC bug.
11293 2023-06-04  Bruno Haible  <bruno@clisp.org>
11295         uniname/uniname: Fix -Wformat-signedness warning.
11296         * lib/uniname/uniname.c (unicode_character_name): Use %u instead of %d
11297         in format string.
11299 2023-06-04  Bruno Haible  <bruno@clisp.org>
11301         uniname/uniname: Improve comments.
11302         * lib/uniname/uniname.c (unicode_character_name): Fix comments.
11304 2023-06-03  Bruno Haible  <bruno@clisp.org>
11306         classpath, csharpexec: Avoid "candidate for attribute 'malloc'" warning.
11307         * lib/classpath.h (set_classpath): Mark with attribute 'malloc'.
11309 2023-06-03  Bruno Haible  <bruno@clisp.org>
11311         propername-lite: Improve documentation.
11312         * lib/propername.h: Describe functional differences between
11313         proper_name_lite and proper_name_utf8.
11315 2023-06-03  Bruno Haible  <bruno@clisp.org>
11317         gnulib-tool: Keep in sync with last change to gnulib-tool.py.
11318         * gnulib-tool (func_emit_po_Makevars): Treat proper_name_lite like
11319         proper_name_utf8.
11321 2023-06-03  Bruno Haible  <bruno@clisp.org>
11323         error: Improve comments.
11324         * lib/error.in.h (__gl_error_call): Add more comments.
11326 2023-06-02  Paul Eggert  <eggert@cs.ucla.edu>
11328         error: do not evaluate status twice
11329         Do this in a different way, so that the status is evaluated
11330         once even when not optimizing and when using GCC.
11331         * lib/error.in.h (__gl_error_call1) [__GNUC__]: New macro.
11332         (__gl_error_call) [__GNUC__]: Use it.
11334 2023-06-02  Bruno Haible  <bruno@clisp.org>
11336         warnings: Add ability to inhibit all warnings.
11337         * m4/warnings.m4 (gl_CC_INHIBIT_WARNINGS, gl_CXX_INHIBIT_WARNINGS): New
11338         macros, based on gl_CC_ALLOW_WARNINGS and gl_CXX_ALLOW_WARNINGS in
11339         m4/gnulib-common.m4.
11341 2023-06-02  Paul Eggert  <eggert@cs.ucla.edu>
11343         propername-lite: new module
11344         propername_lite acts like propername_utf8 but needs less
11345         infrastructure, e.g., it does not worry about memory allocation.
11346         * MODULES.html.sh (func_all_modules): Mention it.
11347         * lib/propername.h (proper_name_lite): New decl.
11348         * lib/propername-lite.c, modules/propername-lite: New files.
11349         * pygnulib/GLEmiter.py (GLEmiter.po_Makevars):
11350         Treat proper_name_lite like proper_name_utf8.
11352 2023-06-02  Bruno Haible  <bruno@clisp.org>
11354         openmp-init: Silence "no previous prototype for 'openmp_init'" warning.
11355         * lib/omp.in.h: Test _OPENMP.
11356         * lib/omp-init.c: Include <omp.h> always.
11357         * modules/openmp-init (Include): Allow <omp.h> to be included always.
11359 2023-06-02  Bruno Haible  <bruno@clisp.org>
11361         term-style-control: Silence -Wshadow warning.
11362         * lib/term-style-control.c (continuing_signal_handler): Rename
11363         parameter.
11365 2023-06-02  Bruno Haible  <bruno@clisp.org>
11367         pipe-filter-gi, pipe-filter-ii: Silence -Wunused-macro warning.
11368         * lib/pipe-filter-aux.c: Remove many unnecessary includes.
11369         (_): Remove macro.
11371 2023-06-02  Bruno Haible  <bruno@clisp.org>
11373         javacomp: Silence -Wanalyzer-possible-null-argument warning.
11374         * lib/javacomp.c: Include verify.h.
11375         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_13_usable,
11376         is_envjavac_nongcj_usable, compile_java_class): Assert that the
11377         xasprintf results are non-NULL. This is possible since all involved
11378         format strings are valid and don't use %ls, and all argument strings
11379         are small compared to INT_MAX.
11380         * modules/javacomp (Depends-on): Add verify.
11382 2023-06-02  Bruno Haible  <bruno@clisp.org>
11384         striconveha: Don't crash if malloc() returns NULL.
11385         * lib/striconveha.c (mem_iconveha, str_iconveha): Check malloca() return
11386         value.
11388 2023-06-02  Bruno Haible  <bruno@clisp.org>
11390         setenv: Don't crash if malloc() returns NULL.
11391         * lib/setenv.c (rpl_setenv): Check malloca() return value.
11393 2023-06-02  Bruno Haible  <bruno@clisp.org>
11395         error: Avoid implicit-fallthrough warnings with -O0 (regr. 2023-05-30).
11396         * lib/error.in.h (__gl_error_call): Parenthesize status. When not
11397         optimizing, expand to code without compound statements.
11399 2023-06-01  Bruno Haible  <bruno@clisp.org>
11401         getprogname: Add support for ASCII-compatible environments in z/OS.
11402         Reported by Mike Fulton <mikefultonpersonal@gmail.com> in
11403         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00198.html>.
11404         * lib/getprogname.c (getprogname): On z/OS, when compiling for an
11405         ASCII-compatible environment, convert the result from EBCDIC to ASCII.
11407 2023-06-01  Mitch Capper  <mitch.capper@gmail.com>
11409         gnulib-tool.py: Fix a format string mistake.
11410         * pygnulib/GLImport.py (GLImport.execute): Fix a typo in a format
11411         string.
11412         Copyright-paperwork-exempt: Yes
11414 2023-06-01  Bruno Haible  <bruno@clisp.org>
11416         Add info for maintainers and contributors.
11417         * HACKING: New file.
11419 2023-05-30  Nick Bowler  <nbowler@draconx.ca>
11421         readline: fix memory leak in replacement readline.
11422         * lib/readline.c (readline): Free memory after getline failure.
11423         Copyright-paperwork-exempt: true
11425 2023-05-30  Paul Eggert  <eggert@cs.ucla.edu>
11427         error: don’t call ‘exit’
11428         Let the underlying functions call ‘exit’, instead of having the
11429         Gnulib replacement macros do it.  Use ‘unreachable’ to tell the
11430         compiler that those functions exit when the status is nonzero.
11431         This saves a function call.
11432         * lib/error.in.h: Include stddef.h, not stdlib.h.
11433         (__gl_error_call): Rely on the function to exit, using
11434         ‘unreachable’ to tell the compiler that the function does not return.
11435         * modules/error (Depends-on): Add stddef.
11437         error: don’t evaluate status arg twice
11438         This avoids potential issues if the first argument has a side effect.
11439         * lib/error.in.h (__gl_error_call): New macro, which evaluates its
11440         status arg only once, by using a statement expression if GNU C -
11441         the only platform we need to worry about pacifying - and by simply
11442         calling ‘error’ otherwise.
11443         (error, error_at_line): Use it.
11445 2023-05-28  Bruno Haible  <bruno@clisp.org>
11447         warnings, manywarnings: Assume autoconf >= 2.64.
11448         * m4/warnings.m4 (gl_AS_VAR_APPEND): Remove macro.
11449         (gl_COMPILER_OPTION_IF, gl_WARN_ADD): Use AS_VAR_APPEND instead of
11450         gl_AS_VAR_APPEND.
11451         * m4/manywarnings.m4: Likewise.
11453 2023-05-28  Jim Meyering  <meyering@fb.com>
11455         file-has-acl: avoid warning from bleeding-edge GCC
11456         * lib/file-has-acl.c: Include attribute.h.
11457         (have_xattr): Declare with ATTRIBUTE_PURE,
11458         to avoid new warning from GCC14-to-be.
11459         * modules/file-has-acl (Depends-on): Add attribute.
11460         Spotted while building coreutils with this:
11461         gcc version 14.0.0 20230526 (experimental)
11463 2023-05-28  Bruno Haible  <bruno@clisp.org>
11465         error: Avoid -Wint-in-bool-context warning.
11466         Reported by Pádraig Brady in
11467         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00178.html>.
11468         * lib/error.in.h (error, error_at_line): Use 'status != 0', since status
11469         is expected to be an int, not a bool value.
11471 2023-05-27  Bruno Haible  <bruno@clisp.org>
11473         error: Support the compiler's control flow analysis better.
11474         * lib/error.in.h: Remove @PRAGMA_SYSTEM_HEADER@. Include <stdlib.h>.
11475         (error): Define as a macro that explicitly invokes exit().
11476         (error_at_line): Likewise.
11477         * lib/error.c (_GL_NO_INLINE_ERROR): Define before including error.h.
11478         * modules/error-h (configure.ac): Don't invoke gl_CONDITIONAL_HEADER.
11479         (Makefile.am): Generate error.h always. Don't substitute
11480         PRAGMA_SYSTEM_HEADER.
11481         * m4/error_h.m4 (gl_ERROR_H): Set COMPILE_ERROR_C instead of
11482         GL_GENERATE_ERROR_H.
11483         * modules/error (configure.ac, Depends-on): Test COMPILE_ERROR_C instead
11484         of GL_GENERATE_ERROR_H.
11485         * lib/copy-file.c: Revert the last change.
11487 2023-05-26  Bruno Haible  <bruno@clisp.org>
11489         flexmember: Make it easier to use.
11490         * lib/flexmember.h (FLEXNSIZEOF): New macro.
11491         * lib/hamt.c (alloc_bucket, alloc_subtrie): Fix FLEXSIZEOF invocation.
11492         Use FLEXNSIZEOF instead of FLEXSIZEOF.
11493         * lib/ssfmalloc.h (init_small_block_page_pool): Use FLEXNSIZEOF instead
11494         of FLEXSIZEOF.
11496 2023-05-26  Bruno Haible  <bruno@clisp.org>
11498         diffseq: Silence another gcc warning.
11499         * lib/diffseq.h (compareseq): Move into the scope of the '#pragma GCC
11500         diagnostic'.
11502 2023-05-26  Bruno Haible  <bruno@clisp.org>
11504         copy-file: Silence gcc warnings.
11505         * lib/copy-file.c: Add #pragma GCC diagnostic.
11507 2023-05-26  Bruno Haible  <bruno@clisp.org>
11509         diffseq: Silence gcc warning.
11510         * lib/diffseq.h: Add #pragma GCC diagnostic.
11512 2023-05-24  Paul Eggert  <eggert@cs.ucla.edu>
11514         manywarnings: speed up nomfi test
11515         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Simplify and speed up
11516         on current platforms, by seeing first whether
11517         -Wno-missing-field-initializers is needed (it isn’t), so that
11518         later we don’t need to determine whether it’s supported.
11520         Simplify -Wno-missing-field-initializers checking
11521         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Don’t worry about
11522         -Wmissing-field-initializers, as this is no longer needed now that
11523         gl_MANYWARN_ALL_GCC is fixed.
11525         manywarnings: port better to GCC 11.2 and earlier
11526         Problem reported by Bruno Haible in:
11527         https://lists.gnu.org/r/bug-diffutils/2023-05/msg00015.html
11528         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
11529         Also test for GCC bug 82283
11530         <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82283>.
11532 2023-05-24  Bruno Haible  <bruno@clisp.org>
11534         asyncsafe-spin, simple-atomic: Don't use -mcpu-v9 on NetBSD/sparc.
11535         Reported by Brandon Applegate in
11536         <https://lists.gnu.org/archive/html/bug-gettext/2023-05/msg00042.html>.
11537         * lib/asyncsafe-spin.c: Limit the SPARC workaround to Solaris.
11538         * lib/simple-atomic.c: Likewise.
11539         * m4/sparcv8+.m4 (gl_SPARC_V8PLUS): Likewise.
11541 2023-05-23  Paul Eggert  <eggert@cs.ucla.edu>
11543         nstrftime: wmemmove → __wmemmove in glibc part
11544         https://sourceware.org/pipermail/libc-alpha/2023-May/148435.html
11545         * lib/nstrftime.c (__strftime_internal) [COMPILE_WIDE]:
11546         Use __wmemmove, not wmemmove, to keep in better sync with draft glibc.
11548 2023-05-22  Bruno Haible  <bruno@clisp.org>
11550         git-merge-changelog: Code style changes.
11551         * lib/git-merge-changelog.c: Don't make side effects to variables
11552         inside parenthesized expressions. Write (size_t)(-1), for consistency
11553         with gl_list.h.
11554         (compute_mapping): Rename variable in2 to jrev.
11556 2023-05-21  Paul Eggert  <eggert@cs.ucla.edu>
11558         strtol: match 'configure' to 'make check'
11559         Inferred from report by Tomasz Kłoczko <https://bugs.gnu.org/63632>.
11560         * m4/strtol.m4 (gl_FUNC_STRTOL):
11561         * m4/strtoll.m4 (gl_FUNC_STRTOLL):
11562         Also test "0b", since the test cases check it.
11564         git-merge-changelog: port to size_t padding
11565         * lib/git-merge-changelog (entry_hashcode):
11566         As a nicety, Prefer SIZE_WIDTH to computing it ourselves.
11568         git-merge-changelog: prefer idx_t
11569         * lib/git-merge-changelog.c: Include idx.h.
11570         (struct entry, entry_create, entry_hashcode)
11571         (struct changelog_file, read_changelog_file)
11572         (entries_mapping_get, entries_mapping_reverse_get)
11573         (compute_mapping, struct edit, struct differences)
11574         (compute_differences, find_paragraph_end)
11575         (try_split_merged_entry, struct conflict, conflict_write, main):
11576         Prefer idx_t to ptrdiff_t and size_t when the value is a
11577         nonnegative index or size.  Change a few for-loops so that
11578         the index never goes negative.
11579         * modules/git-merge-changelog (Depends-on): Add idx.
11581         git-merge-changelog: ssize_t → ptrdiff_t
11582         Prefer ptrdiff_t to ssize_t, as per
11583         <https://lists.gnu.org/archive/html/emacs-devel/2014-10/msg00019.html>.
11584         * lib/git-merge-changelog.c (struct entries_mapping)
11585         (entries_mapping_get, entries_mapping_reverse_get)
11586         (compute_mapping, struct edit, struct differences, OFFSET)
11587         (OFFSET_MAX, EXTRA_CONTEXT_FIELDS, compute_differences, main):
11588         Use ptrdiff_t, not ssize_t.
11589         * modules/git-merge-changelog (Depends-on): Add stdint for PTRDIFF_MAX.
11591         git-merge-changelog: port to ssize_t padding
11592         * lib/git-merge-changelog.c (OFFSET_MAX): New macro, as a nicety.
11594 2023-05-21  Bruno Haible  <bruno@clisp.org>
11596         limits-h tests: Check the value of SSIZE_MAX.
11597         * tests/test-limits-h.c (limits12): New variable.
11598         Include <sys/types.h> and check the value of SSIZE_MAX.
11599         * modules/limits-h-tests (Depends-on): Add sys_types.
11601 2023-05-21  Bruno Haible  <bruno@clisp.org>
11603         ssize_t: Fix replacement on 64-bit Windows.
11604         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Use prefix 'gl_' instead of 'gt_'.
11605         Define ssize_t to 'long long' or 'long', depending on the width of
11606         'size_t'.
11608 2023-05-20  Paul Eggert  <eggert@cs.ucla.edu>
11610         limits-h: other modules can rely on SSIZE_MAX
11611         * lib/areadlink-with-size.c, lib/areadlinkat-with-size.c:
11612         * lib/careadlinkat.c, lib/getdelim.c, lib/getndelim2.c:
11613         * lib/regex_internal.h:
11614         (SSIZE_MAX): Do not define.
11615         * modules/areadlink-with-size, modules/areadlinkat-with-size:
11616         * modules/careadlinkat, modules/getdelim, modules/getndelim2:
11617         * modules/regex:
11618         (Depends-on) Add limits-h.
11620         limits-h: define SSIZE_MAX
11621         * doc/posix-headers/limits.texi (limits.h): Document this.
11622         * lib/limits.in.h (SSIZE_MAX): Define if not already defined.
11623         * m4/limits-h.m4 (gl_LIMITS_H): Also generate limits.h
11624         if <limits.h> does not define SSIZE_MAX.
11626         diffseq: backward compatibility for OFFSET_MAX
11627         * lib/diffseq.h (OFFSET_MAX): Define only if not already defined.
11629 2023-05-19  Bruno Haible  <bruno@clisp.org>
11631         careadlinkat: Silence gcc warning for GCC ≥ 12.
11632         * lib/careadlinkat.c: For GCC 12 or newer, use
11633         "#pragma GCC diagnostic ignored" to silence the warning.
11635 2023-05-19  Pádraig Brady  <P@draigBrady.com>
11637         modechange: pacify gcc -Wsuggest-attribute=pure
11638         * lib/modechange.h (mode_adjust): Add _GL_ATTRIBUTE_PURE
11639         suggested with GCC 12 with -flto.
11641 2023-05-19  Paul Eggert  <eggert@cs.ucla.edu>
11643         diffseq: don’t assume integers lack padding
11644         * NEWS: Mention this.
11645         * lib/diffseq.h (OFFSET_MAX): Don’t define;
11646         this is now the user’s responsibility.
11647         * lib/fstrcmp.c (OFFSET_MAX): Define to PTRDIFF_MAX.
11649 2023-05-18  Bruno Haible  <bruno@clisp.org>
11651         getndelim2: Silence gcc warning.
11652         * lib/getndelim2.c: Add #pragma GCC diagnostic.
11653         (IF_LINT): Remove macro.
11654         (getndelim2): Remove use of IF_LINT.
11656 2023-05-18  Bruno Haible  <bruno@clisp.org>
11658         canonicalize: Silence gcc warning.
11659         * lib/canonicalize.c: Add #pragma GCC diagnostic.
11660         (IF_LINT): Remove macro.
11661         (canonicalize_filename_mode_stk): Remove use of IF_LINT.
11663 2023-05-18  Bruno Haible  <bruno@clisp.org>
11665         vasnprintf, c-vasnprintf: Silence gcc warning.
11666         * lib/vasnprintf.c: Add #pragma GCC diagnostic.
11668 2023-05-18  Bruno Haible  <bruno@clisp.org>
11670         nstrftime: Silence gcc warning.
11671         * lib/nstrftime.c: Add #pragma GCC diagnostic.
11673 2023-05-18  Bruno Haible  <bruno@clisp.org>
11675         astrxfrm: Silence gcc warning.
11676         * lib/astrxfrm.c: Add #pragma GCC diagnostic.
11678 2023-05-18  Bruno Haible  <bruno@clisp.org>
11680         vasnprintf, c-vasnprintf: Silence gcc warnings.
11681         * lib/vasnprintf.c (scale10_round_decimal_decoded): Remove memory==NULL
11682         test.
11683         (scale10_round_decimal_long_double, scale10_round_decimal_double): Test
11684         for memory==NULL here. Remove use of IF_LINT.
11686 2023-05-18  Bruno Haible  <bruno@clisp.org>
11688         bitset: Silence gcc warning.
11689         * lib/bitset/list.c (lbitset_copy_): Remove redundant test from the
11690         loop's first iteration.
11692 2023-05-18  Bruno Haible  <bruno@clisp.org>
11694         stack: Silence gcc warning in tests.
11695         * lib/stack.h (init, destroy, empty, current_base, push, pop, discard,
11696         top, size): Mark as possibly unused.
11698 2023-05-18  Bruno Haible  <bruno@clisp.org>
11700         hamt: Silence gcc warning.
11701         * lib/hamt.c (init_element): Mark as possibly unused.
11703 2023-05-18  Bruno Haible  <bruno@clisp.org>
11705         get-rusage-data: Silence gcc warning.
11706         * lib/get-rusage-data.c (get_rusage_data_via_iterator): Mark as possibly
11707         unused.
11709 2023-05-18  Bruno Haible  <bruno@clisp.org>
11711         astrxfrm: Fix use-after-free bug.
11712         * lib/astrxfrm.c (astrxfrm): Don't use memcpy after realloc succeeded.
11714 2023-05-18  Bruno Haible  <bruno@clisp.org>
11716         gnulib-tool: Ignore .orig and .rej files under modules/.
11717         * gnulib-tool (func_sanitize_modulelist): Exclude also files whose name
11718         ends in .orig or .rej.
11719         * pygnulib/GLModuleSystem.py (GLModuleSystem.file_is_module): Likewise.
11721 2023-05-18  Bruno Haible  <bruno@clisp.org>
11723         uchar: Fix error when <uchar.h> is included twice.
11724         * lib/uchar.in.h: Fix double-inclusion guard.
11726 2023-05-17  Paul Eggert  <eggert@cs.ucla.edu>
11728         stdckdint: use in more modules
11729         * lib/nstrftime.c (__strftime_internal):
11730         * lib/parse-datetime.y (apply_relative_time, zone, date)
11731         (iso_8601_date, relunit, relunit_snumber, time_zone_hhmm)
11732         (to_tm_year, yylex, parse_datetime_body):
11733         * lib/timespec-add.c (timespec_add):
11734         * lib/timespec-sub.c (timespec_sub):
11735         * lib/xstrtol.c (bkm_scale):
11736         Prefer ckd_add to INT_ADD_WRAPV etc., and include stdckdint.h.
11737         * modules/nstrftime, modules/parse-datetime:
11738         * modules/timespec-add, modules/timespec-sub, modules/xstrtol:
11739         (Depends-on): Add stdckdint.
11741         nstrftime: suggest to glibc how to avoid alloca
11742         * lib/nstrftime.c (widen) [COMPILE_WIDE]: Remove.
11743         (__strftime_internal) [COMPILE_WIDE): Instead of converting the
11744         multibyte time zone abbreviation into a potentially unbounded
11745         alloca buffer, convert it directly into the output buffer.
11746         Although this code is not used in Gnulib, this can help the glibc
11747         developers avoid the problem on the glibc side.
11749 2023-05-15  Bruno Haible  <bruno@clisp.org>
11751         doc: New chapter "Strings and Characters".
11752         * doc/strings.texi: New file.
11753         * doc/gnulib.texi (POSIXURL): New variable.
11754         (posixheader, posixfunc, func): New macros, from GNU libunistring's
11755         documentation.
11756         Include strings.texi.
11757         (Particular Modules): Don't include c-locale.texi here.
11758         * doc/c-locale.texi: Sections become subsections, subsections become
11759         subsubsections.
11760         * doc/posix-functions/isalnum.texi: Mention c32isalnum.
11761         * doc/posix-functions/isalpha.texi: Mention c32isalpha.
11762         * doc/posix-functions/isblank.texi: Mention c32isblank.
11763         * doc/posix-functions/iscntrl.texi: Mention c32iscntrl.
11764         * doc/posix-functions/isdigit.texi: Mention c32isdigit.
11765         * doc/posix-functions/isgraph.texi: Mention c32isgraph.
11766         * doc/posix-functions/islower.texi: Mention c32islower.
11767         * doc/posix-functions/isprint.texi: Mention c32isprint.
11768         * doc/posix-functions/ispunct.texi: Mention c32ispunct.
11769         * doc/posix-functions/isspace.texi: Mention c32isspace.
11770         * doc/posix-functions/isupper.texi: Mention c32isupper.
11771         * doc/posix-functions/isxdigit.texi: Mention c32isxdigit.
11772         * doc/posix-functions/tolower.texi: Mention alternative APIs.
11773         * doc/posix-functions/toupper.texi: Likewise.
11774         * doc/posix-functions/towlower.texi: Mention c32tolower.
11775         * doc/posix-functions/towupper.texi: Mention c32toupper.
11776         * doc/posix-functions/wcswidth.texi: Mention c32swidth.
11777         * doc/posix-functions/wcwidth.texi: Mention c32width.
11779 2023-05-15  Bruno Haible  <bruno@clisp.org>
11781         sigsegv: Add tentative support for Hurd/x86_64.
11782         Based on explanations by Sergey Bugaev <bugaevc@gmail.com>.
11783         * lib/sigsegv.c: Update from libsigsegv/src/fault-hurd-i386-old.h.
11785 2023-05-15  Paul Eggert  <eggert@cs.ucla.edu>
11787         file-has-acl: improve port to Fedora 39
11788         Problem reported by Ondrej Valousek in:
11789         https://lists.gnu.org/r/bug-gnulib/2023-05/msg00078.html
11790         * lib/file-has-acl.c: Include minmax.h.
11791         [USE_ACL && HAVE_LINUX_XATTR_H && HAVE_LISTXATTR]: Include stdckdint.h.
11792         (file_has_acl) [USE_ACL && HAVE_LINUX_XATTR_H && HAVE_LISTXATTR]:
11793         If the file has NFSv4 ACLs, ignore any POSIX ACLs, for Fedora 39.
11794         Return a bit faster when listxattr returns 0.
11795         Don’t loop forever if an attacker is fiddling with ACLs.
11796         * modules/file-has-acl (Depends-on): Add minmax, stdckdint.
11798 2023-05-15  Bruno Haible  <bruno@clisp.org>
11800         Work around https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82283 .
11801         Reported by Pádraig Brady <P@draigBrady.com> in
11802         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00077.html>.
11803         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Add
11804         -Wno-missing-field-initializers for GCC < 11.
11806 2023-05-15  Bruno Haible  <bruno@clisp.org>
11808         gettimeofday, pthread-*, thread, thrd: Don't omit intended initializers.
11809         * lib/gettimeofday.c (gettimeofday): List the initializers of both
11810         tv_sec and tv_usec.
11811         * lib/glthread/thread.c (gl_thread_self): List the initializers of both
11812         tv_sec and tv_nsec.
11813         * lib/pthread-cond.c (pthread_cond_wait): Likewise.
11814         * lib/thrd.c (rpl_thrd_current): Likewise.
11815         * lib/pthread-rwlock.c (MIN): New macro.
11816         (pthread_rwlock_timedrdlock, pthread_rwlock_timedwrlock): List the
11817         initializers of both tv_sec and tv_nsec. Don't modify the duration after
11818         having initialized it.
11819         * lib/pthread_mutex_timedlock.c (MIN): New macro.
11820         (pthread_mutex_timedlock): List the initializers of both tv_sec and
11821         tv_nsec. Don't modify the duration after having initialized it.
11823         select: Fix compilation error (regression from yesterday).
11824         * lib/select.c (rpl_select): Revert last change.
11826         poll: Fix syntax error (regression from yesterday).
11827         * lib/poll.c (poll): Remove semicolon inside braces.
11829 2023-05-14  Paul Eggert  <eggert@cs.ucla.edu>
11831         timespec: fill in other members
11832         This problem was found when compiling GNU Emacs with
11833         --enable-gcc-warnings on a platform where tv_sec is 64 bits and
11834         tv_nsec is 32 bits, and struct timespec has padding.  GCC
11835         -Wuse-of-uninitialized-value complained when a struct timespec
11836         initialized only via assigning to tv_sec and tv_nsec was copied
11837         via assignment (this was in lib/timespec.h’s make_timespec).
11838         Although behavior is well-defined on this platform, the warning is
11839         annoying and the behavior might not be well-defined on theoretical
11840         platforms where struct timespec has other members.  To work around
11841         this, initialize all the struct’s members.
11842         * lib/getsockopt.c (rpl_getsockopt):
11843         * lib/gettime.c (gettime):
11844         * lib/gettimeofday.c (gettimeofday):
11845         * lib/glthread/thread.c (gl_thread_self):
11846         * lib/nanosleep.c (nanosleep):
11847         * lib/parse-datetime.y (digits_to_date_time, set_hhmmss)
11848         (signed_seconds, unsigned_seconds, yylex, parse_datetime_body):
11849         * lib/poll.c (poll):
11850         * lib/pselect.c (pselect):
11851         * lib/pthread-cond.c (endlessly, pthread_cond_timedwait):
11852         * lib/pthread-rwlock.c (pthread_rwlock_timedrdlock)
11853         (pthread_rwlock_timedwrlock):
11854         * lib/pthread_mutex_timedlock.c (pthread_mutex_timedlock):
11855         * lib/select.c (rpl_select):
11856         * lib/settime.c (settime):
11857         * lib/stat-time.h (get_stat_atime, get_stat_ctime)
11858         (get_stat_mtime, get_stat_birthtime):
11859         * lib/thrd.c (rpl_thrd_current):
11860         * lib/timespec.h (make_timespec):
11861         * lib/timespec_getres.c (timespec_getres):
11862         * lib/utimecmp.c (utimecmpat):
11863         * lib/utimens.c (fdutimens):
11864         When filling in a struct timespec or similar time-related structure
11865         that might be copied elsewhere, also assign to any storage other
11866         than tv_sec and tv_nsec, to avoid undefined behavior on (likely
11867         theoretical) platforms where struct timespec has other members,
11868         and also to avoid warnings from GCC and/or valgrind.
11870         year2038-recommended: Improve failure diagnostic.
11871         * m4/largefile.m4 (AC_SYS_YEAR2038_RECOMMENDED): Sync from Autoconf.
11873 2023-05-13  Paul Eggert  <eggert@cs.ucla.edu>
11875         stdio: use _GL_ATTRIBUTE_MALLOC
11876         * lib/stdio.in.h (fdopen, fopen, popen, tmpfile): Declare with
11877         _GL_ATTRIBUTE_MALLOC, for consistency with glibc, and so that
11878         building the fopen module with ‘gcc -O2 -Wsuggest-attribute=malloc
11879         -Wsystem-headers -Werror’ does not fail with “stdio.h: In function
11880         ‘rpl_fopen’: stdio.h:970:1: error: function might be candidate for
11881         attribute ‘malloc’ [-Werror=suggest-attribute=malloc]”, a problem
11882         I noticed on both Fedora 38 and Ubuntu 23.04.
11884 2023-05-12  Bruno Haible  <bruno@clisp.org>
11886         sigsegv: Add tentative support for Hurd/x86_64.
11887         Reported by Samuel Thibault <samuel.thibault@ens-lyon.org>.
11888         * lib/sigsegv.c: Update from libsigsegv/src/fault-hurd-i386.h.
11890 2023-05-12  Paul Eggert  <eggert@cs.ucla.edu>
11892         file-has-acl: port to Fedora 39
11893         Fedora 39 getxattr with XATTR_NAME_POSIX_ACL_ACCESS either
11894         succeeds or fails with ENODATA, so it is no longer possible to
11895         detect from its failure that the filesystem might support NFSv4 ACLs.
11896         Problem reported by Ondrej Valousek in:
11897         https://lists.gnu.org/r/bug-gnulib/2023-04/msg00228.html
11898         Instead, use listxattr to determine whether NFSv4 ACLs are in play.
11899         This typically saves syscalls anyway.
11900         * lib/file-has-acl.c: In #if, use (HAVE_LINUX_XATTR_H &&
11901         HAVE_LISTXATTR) instead of GETXATTR_WITH_POSIX_ACLS.
11902         The following changes apply when (USE_ACL && HAVE_LINUX_XATTR_H &&
11903         HAVE_LISTXATTR):
11904         Include minmax.h.
11905         (have_xattr): New function.
11906         (file_has_acl): Try listxattr first; typically this means we need
11907         to do no other syscall.  Call getxattr only if there are NFSv4
11908         ACLs but not POSIX ACLs.
11909         * m4/acl.m4 (gl_FILE_HAS_ACL): Simplify by merely testing for
11910         linux/xattr.h and listxattr.  All uses changed.
11912 2023-05-10  Josh Soref  <jsoref@gmail.com>
11914         bootstrap: spelling/grammar fix in comment
11915         * build-aux/bootstrap: As above.
11917 2023-05-07  Paul Eggert  <eggert@cs.ucla.edu>
11919         Warn against bogus TZ settings
11920         * doc/parse-datetime.texi (Specifying time zone rules):
11921         Warn against TZ="UTC=5".
11923 2023-05-05  Bruno Haible  <bruno@clisp.org>
11925         dirfd: Add tests.
11926         * tests/test-dirfd.c: New file.
11927         * modules/dirfd-tests: New file.
11929 2023-05-05  Bruno Haible  <bruno@clisp.org>
11931         dirfd: Fix bogus override (regression 2023-04-26).
11932         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
11933         <https://lists.gnu.org/archive/html/bug-gnulib/2023-05/msg00040.html>.
11934         * m4/dirfd.m4 (gl_FUNC_DIRFD): Fix mistake in last change.
11936 2023-05-04  Bruno Haible  <bruno@clisp.org>
11938         c32swidth: Add tests.
11939         * tests/test-c32swidth.c: New file, based on tests/test-c32width.c.
11940         * modules/c32swidth-tests: New file.
11942         c32swidth: New module.
11943         * lib/uchar.in.h (c32swidth): New declaration.
11944         * lib/wcswidth-impl.h: Use macros FUNC, UNIT, CHARACTER_WIDTH.
11945         * lib/wcswidth.c: Define FUNC, UNIT, CHARACTER_WIDTH before including
11946         wcswidth-impl.h.
11947         * lib/c32swidth.c: New file.
11948         * modules/c32swidth: New file.
11949         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
11950         GNULIB_C32SWIDTH.
11951         * modules/uchar (Makefile.am): Substitute GNULIB_C32SWIDTH.
11953 2023-05-04  Bruno Haible  <bruno@clisp.org>
11955         wcswidth: Fix result in case of overflow.
11956         * lib/wcswidth-impl.h (wcswidth): Continue searching for a non-printing
11957         wide character after the total width has become > INT_MAX.
11959 2023-05-04  Bruno Haible  <bruno@clisp.org>
11961         wcswidth: Relax license.
11962         * modules/wcswidth (License): Change to LGPLv2+.
11963         * lib/wcswidth.c: Update license notice.
11964         * lib/wcswidth-impl.h: Likewise.
11966 2023-05-04  Bruno Haible  <bruno@clisp.org>
11968         c32width: Relax license.
11969         * modules/c32width (License): Change to LGPLv2+.
11970         * lib/c32width.c: Update license notice.
11972 2023-05-04  Bruno Haible  <bruno@clisp.org>
11974         c32to*: Relax license.
11975         * modules/c32tolower (License): Change to LGPLv2+.
11976         * modules/c32toupper (License): Likewise.
11977         * lib/c32tolower.c: Update license notice.
11978         * lib/c32toupper.c: Likewise.
11979         * lib/c32to-impl.h: Likewise.
11981         unicase/tolower, unicase/toupper: Relax license.
11982         * lib/gen-uni-tables.c (output_simple_mapping): Bump copyright year. For
11983         unicase/tolower.h and unicase/toupper.h, use the LGPLv2+.
11984         * lib/unicase/tolower.h: Regenerated.
11985         * lib/unicase/toupper.h: Likewise.
11986         * lib/unicase/simple-mapping.h: Update license notice.
11987         * lib/unicase/tolower.c: Likewise.
11988         * lib/unicase/toupper.c: Likewise.
11989         * modules/unicase/tolower (License): Change to LGPLv2+.
11990         * modules/unicase/toupper (License): Likewise.
11992         unicase/base: Relax license.
11993         * modules/unicase/base (License): Change to LGPLv2+.
11994         * lib/unicase.in.h: Update license notice.
11996 2023-05-04  Bruno Haible  <bruno@clisp.org>
11998         c32is*: Relax license.
11999         * modules/c32isalnum (License): Change to LGPLv2+.
12000         * modules/c32isalpha (License): Likewise.
12001         * modules/c32isblank (License): Likewise.
12002         * modules/c32iscntrl (License): Likewise.
12003         * modules/c32isdigit (License): Likewise.
12004         * modules/c32isgraph (License): Likewise.
12005         * modules/c32islower (License): Likewise.
12006         * modules/c32isprint (License): Likewise.
12007         * modules/c32ispunct (License): Likewise.
12008         * modules/c32isspace (License): Likewise.
12009         * modules/c32isupper (License): Likewise.
12010         * modules/c32isxdigit (License): Likewise.
12011         * lib/c32isalnum.c: Update license notice.
12012         * lib/c32isalpha.c: Likewise.
12013         * lib/c32isblank.c: Likewise.
12014         * lib/c32iscntrl.c: Likewise.
12015         * lib/c32isdigit.c: Likewise.
12016         * lib/c32isgraph.c: Likewise.
12017         * lib/c32islower.c: Likewise.
12018         * lib/c32isprint.c: Likewise.
12019         * lib/c32ispunct.c: Likewise.
12020         * lib/c32isspace.c: Likewise.
12021         * lib/c32isupper.c: Likewise.
12022         * lib/c32isxdigit.c: Likewise.
12023         * lib/c32is-impl.h: Likewise.
12025         unictype/ctype-*: Relax license.
12026         * lib/gen-uni-tables.c (output_predicate): Bump copyright year. For
12027         unictype/ctype_*, use the LGPLv2+.
12028         * lib/unictype/ctype_*.h: Regenerated.
12029         * lib/unictype/ctype_*.c: Update license notice.
12030         * modules/unictype/ctype-alnum (License): Change to LGPLv2+.
12031         * modules/unictype/ctype-alpha (License): Likewise.
12032         * modules/unictype/ctype-blank (License): Likewise.
12033         * modules/unictype/ctype-cntrl (License): Likewise.
12034         * modules/unictype/ctype-digit (License): Likewise.
12035         * modules/unictype/ctype-graph (License): Likewise.
12036         * modules/unictype/ctype-lower (License): Likewise.
12037         * modules/unictype/ctype-print (License): Likewise.
12038         * modules/unictype/ctype-punct (License): Likewise.
12039         * modules/unictype/ctype-space (License): Likewise.
12040         * modules/unictype/ctype-upper (License): Likewise.
12041         * modules/unictype/ctype-xdigit (License): Likewise.
12043 2023-05-04  Bruno Haible  <bruno@clisp.org>
12045         c32width: Add tests.
12046         * tests/test-c32width.c: New file, based on tests/test-wcwidth.c.
12047         * modules/c32width-tests: New file.
12049         c32width: New module.
12050         * lib/uchar.in.h (c32width): New declaration.
12051         * lib/c32width.c: New file, based on lib/c32is-impl.h.
12052         * modules/c32width: New file.
12053         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
12054         GNULIB_C32WIDTH.
12055         * modules/uchar (Makefile.am): Substitute GNULIB_C32WIDTH.
12057 2023-05-04  Bruno Haible  <bruno@clisp.org>
12059         doc: Mention macOS wcwidth bug.
12060         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Mention macOS bugs.
12061         * doc/posix-functions/wcwidth.texi: Update regarding macOS.
12063 2023-05-03  Bruno Haible  <bruno@clisp.org>
12065         vasnprintf, vasnwprintf: Make '0' flag handling more ISO C compliant.
12066         * lib/vasnprintf.c (VASNPRINTF): When doing the padding ourselves,
12067         ignore the '0' flag if a precision is specified and the conversion is
12068         one of d, i, o, u, x, X, b, B.
12069         * tests/test-vasnprintf-posix.c (test_function): Update expected results
12070         accordingly.
12071         * tests/test-vasprintf-posix.c (test_function): Likewise.
12072         * tests/test-snprintf-posix.h (test_function): Likewise.
12073         * tests/test-sprintf-posix.h (test_function): Likewise.
12074         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
12076 2023-05-02  Paul Eggert  <eggert@cs.ucla.edu>
12078         mktime: include <intprops.h>
12079         * lib/mktime.c: Include <intprops.h> again,
12080         fixing a typo noted by Bruno Haible in:
12081         https://lists.gnu.org/r/bug-gnulib/2023-05/msg00014.html
12083 2023-05-02  Bruno Haible  <bruno@clisp.org>
12085         fopen: Silence a gcc warning.
12086         * lib/fopen.c (rpl_fopen): Mark open_direction as used.
12088 2023-05-01  Paul Eggert  <eggert@cs.ucla.edu>
12090         extern-inline: port to pcc
12091         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Port to pcc
12092         1.2.0.DEVEL 20220331, which doesn’t support extern inline
12093         even though it claims to be GCC 4.3 and to support C11.
12095         regex: prefer C23 style overflow checking
12096         * lib/regex_internal.h: Include stdckdint.h.
12097         * lib/regexec.c (re_search_2_stub):
12098         * modules/regex (Depends-on): Add stdckdint.
12099         Prefer stdckdint.h to intprops.h macros.
12101         dynarray: prefer C23 style overflow checking
12102         * lib/malloc/dynarray_emplace_enlarge.c, lib/malloc/dynarray_resize.c:
12103         Include stdckdint.h, not intprops.h.
12104         * lib/malloc/dynarray_emplace_enlarge.c:
12105         (__libc_dynarray_emplace_enlarge):
12106         * lib/malloc/dynarray_resize.c (__libc_dynarray_resize):
12107         Prefer stdckdint.h to intprops.h macros.
12108         * modules/glibc-internal/dynarray (Depends-on):
12109         Depend on stdckdint, not intprops.
12111         mktime: prefer C23 style overflow checking
12112         Prefer stdckdint.h macros to intprops.h macros where either will do,
12113         as this is the C23 standard.  Also, it ports around a pcc bug.
12114         * config/srclist.txt: Comment out mktime.c.
12115         * lib/mktime.c: Include stdckdint.h, not intprops.h.
12116         (__mktime_internal): Prefer stdckdint.h to intprops.h macros.
12117         * modules/mktime (Depends-on): Add stdckdint.
12119         limits-h: port to pcc
12120         * doc/posix-headers/limits.texi: Document the issue.
12121         * lib/limits.in.h (MB_LEN_MAX): New macro, if not already defined.
12122         * m4/limits-h.m4 (gl_LIMITS_H): Test for MB_LEN_MAX.
12123         * tests/test-limits-h.c: Check that it’s positive.
12125 2023-04-28  Paul Eggert  <eggert@cs.ucla.edu>
12127         year2038-recommended: new module
12128         Remove year2038-required and largefile-required, replacing
12129         the former with year2038-recommended and simply removing
12130         the latter.  This syncs with Autoconf master.
12131         * MODULES.html.sh, NEWS, doc/largefile.texi:
12132         * all-modules (exclude): Exclude year2038-recommended, not -required.
12133         * doc/posix-headers/sys_types.texi, doc/posix-headers/time.texi:
12134         * doc/year2038.texi: Mention this.
12135         * m4/largefile.m4: Sync from Autoconf.  Override existing macros
12136         if AC_SYS_YEAR2038_RECOMMENDED is not defined, rather than if
12137         AC_SYS_LARGEFILE_REQUIRED is not defined.
12138         * modules/largefile-required, modules/year2038-required: Removed.
12139         * modules/year2038: Do not depend on largefile; simply
12140         use m4/largefile.m4, since we shouldn’t need the extra goodies
12141         largefile supplies.
12142         * modules/year2038-recommended: New module.
12144 2023-04-28  Bruno Haible  <bruno@clisp.org>
12146         stdio: Avoid different configure results in different testdirs.
12147         * m4/stdio_h.m4 (gl_STDIO_H_EARLY): New macro, extracted from
12148         gl_STDIO_H.
12149         (gl_STDIO_H): Move the code that sets __USE_MINGW_ANSI_STDIO to
12150         gl_STDIO_H_EARLY.
12151         * modules/stdio (configure.ac-early): New section.
12153 2023-04-28  Bruno Haible  <bruno@clisp.org>
12155         stdbool tests: Avoid compilation error with Sun C on Solaris 10.
12156         * tests/test-stdbool.c (WORKING_BOOL): Set to 0 on Sun C.
12158 2023-04-28  Bruno Haible  <bruno@clisp.org>
12160         hamt tests: Fix test failure with Sun C on Solaris 10/SPARC.
12161         * tests/test-hamt.c (main): Finish with exit code 0.
12163 2023-04-27  Bruno Haible  <bruno@clisp.org>
12165         localeconv: Work around a mingw bug.
12166         * m4/localeconv.m4 (gl_FUNC_LOCALECONV): Test whether fields of type
12167         'char' are filled correctly.
12168         (gl_PREREQ_LOCALECONV): Test whether 'struct lconv' has the int_{p,n}_*
12169         members.
12170         * lib/localeconv.c (FIX_CHAR_VALUE): New macro.
12171         (localeconv): Replace negative field values with CHAR_MAX.
12172         * doc/posix-functions/localeconv.texi: Mention the mingw bug.
12174 2023-04-27  Bruno Haible  <bruno@clisp.org>
12176         stdlib: Fix error when cross-compiling (regression 2023-04-04).
12177         Reported by Pierre Labastie <pierre.labastie@neuf.fr> in
12178         <https://lists.gnu.org/archive/html/bug-gnulib/2023-04/msg00220.html>.
12179         * m4/stdlib_h.m4 (gl_STDLIB_H): Provide a 4th argument to AC_RUN_IFELSE.
12181 2023-04-26  Paul Eggert  <eggert@cs.ucla.edu>
12183         freopen-safer: pacify GCC 13
12184         * lib/freopen-safer.c: Ignore -Wanalyzer-fd-leak.
12186 2023-04-26  Bruno Haible  <bruno@clisp.org>
12188         fdopendir: Fix fd leak and test failure on native Windows.
12189         --
12190         * lib/dirent-private.h: On mingw, define 'struct gl_directory' as a
12191         wrapper around the original DIR. On MSVC, add an 'fd_to_close' field to
12192         'struct gl_directory'.
12193         * lib/dirent.in.h (DIR): Define when DIR_HAS_FD_MEMBER is 0, i.e. on
12194         both mingw and MSVC.
12195         (GNULIB_defined_DIR): New macro.
12196         (opendir): Avoid incompatible redeclaration.
12197         (readdir): Consider REPLACE_READDIR.
12198         (rewinddir): Consider REPLACE_REWINDDIR.
12199         * m4/dirent_h.m4 (gl_DIRENT_DIR): New macro.
12200         (gl_DIRENT_H): Invoke it.
12201         (gl_DIRENT_H_DEFAULTS): Initialize REPLACE_READDIR, REPLACE_REWINDDIR.
12202         * modules/dirent (Makefile.am): Substitute DIR_HAS_FD_MEMBER,
12203         REPLACE_READDIR, REPLACE_REWINDDIR.
12204         --
12205         * lib/dirfd.c (dirfd): If GNULIB_defined_DIR, just use the
12206         'fd_to_close' field.
12207         * m4/dirfd.m4 (gl_FUNC_DIRFD): Set HAVE_DIRFD. Don't set REPLACE_DIRFD
12208         to 1 if HAVE_DIRFD is 0. If DIR_HAS_FD_MEMBER is 0, ensure dirfd.c gets
12209         compiled.
12210         * modules/dirfd (Files): Add lib/dirent-private.h.
12211         (Depends-on, configure.ac): Simplify conditions.
12212         --
12213         * lib/closedir.c: Include <stdlib.h> always, for free().
12214         (closedir): If GNULIB_defined_DIR, arrange to call close(dirfd(dirp)) at
12215         the end. On mingw, call free() of dirp. Prefer testing HAVE_DIRENT_H,
12216         for consistency with dirent.h.
12217         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Don't set REPLACE_CLOSEDIR to 1 if
12218         HAVE_CLOSEDIR is 0. If DIR_HAS_FD_MEMBER is 0, ensure closedir.c gets
12219         compiled.
12220         --
12221         * lib/opendir.c: Include <stdlib.h> always. Include <string.h>.
12222         (opendir): On mingw, allocate the 'struct gl_directory' through malloc.
12223         If GNULIB_defined_DIR, set the 'fd_to_close' field to -1. Prefer
12224         testing HAVE_DIRENT_H, for consistency with dirent.h.
12225         * m4/opendir.m4 (gl_FUNC_OPENDIR): Don't set REPLACE_OPENDIR to 1 if
12226         HAVE_OPENDIR is 0. If DIR_HAS_FD_MEMBER is 0, ensure opendir.c gets
12227         compiled.
12228         --
12229         * lib/fdopendir.c (fdopendir): If GNULIB_defined_DIR, use a simple
12230         implementation based on opendir and the fchdir module. If __KLIBC__,
12231         don't define unused auxiliary functions.
12232         * modules/fdopendir (Files): Add lib/dirent-private.h.
12233         --
12234         * lib/readdir.c (readdir): On mingw, redirect to the original readdir
12235         function. Prefer testing HAVE_DIRENT_H, for consistency with dirent.h.
12236         * m4/readdir.m4 (gl_FUNC_READDIR): If DIR_HAS_FD_MEMBER is 0, ensure
12237         readdir.c gets compiled.
12238         * modules/readdir (configure.ac): Consider REPLACE_READDIR.
12239         --
12240         * lib/rewinddir.c (rewinddir): On mingw, redirect to the original
12241         rewinddir function. Prefer testing HAVE_DIRENT_H, for consistency with
12242         dirent.h.
12243         * m4/rewinddir.m4 (gl_FUNC_REWINDDIR): If DIR_HAS_FD_MEMBER is 0, ensure
12244         rewinddir.c gets compiled.
12245         * modules/rewinddir (configure.ac): Consider REPLACE_REWINDDIR.
12246         --
12247         * lib/fchdir.c (dir_info_t): Remove a FIXME.
12249 2023-04-26  Bruno Haible  <bruno@clisp.org>
12251         fchdir tests: Fix test failure on native Windows.
12252         * modules/fchdir-tests (Depends-on): Add dup.
12254 2023-04-26  Bruno Haible  <bruno@clisp.org>
12256         fclose: Make last change more maintainable.
12257         * m4/fclose.m4 (gl_FUNC_FCLOSE): Define through AC_DEFUN_ONCE. Don't
12258         modify REPLACE_FOPEN.
12259         * modules/fclose (Depends-on): Add comment.
12260         (configure.ac): Don't modify REPLACE_FOPEN. Don't duplicate actions of
12261         module 'fopen'.
12262         * m4/fopen.m4 (gl_FUNC_FOPEN_ITSELF): Renamed from gl_FUNC_FOPEN.
12263         (gl_FUNC_FOPEN): New macro.
12264         * modules/fopen (Files): Add m4/fclose.m4, m4/fflush.m4.
12265         * m4/close.m4 (gl_FUNC_CLOSE): Define through AC_DEFUN_ONCE.
12267 2023-04-26  Po Lu  <luangruo@yahoo.com>  (tiny change)
12268             Bruno Haible  <bruno@clisp.org>
12270         gnulib-tool: For conditional dependencies, generate portable sh code.
12271         * gnulib-tool (func_emit_autoconf_snippets): Avoid sh syntax
12272         'if ! variable', that does not work with Solaris /bin/sh.
12273         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Likewise.
12275 2023-04-25  Bruno Haible  <bruno@clisp.org>
12277         expm1 tests: Avoid test failure on 32-bit mingw.
12278         * tests/test-expm1.h (test_function): Mark y as 'volatile'.
12280 2023-04-25  Bruno Haible  <bruno@clisp.org>
12282         poll tests: Avoid test failure on native Windows.
12283         * tests/test-poll.c (test_pipe): Disable the POLLHUP check also on
12284         native Windows.
12285         * doc/posix-functions/poll.texi: Mention also native Windows w.r.t.
12286         POLLHUP.
12288 2023-04-25  Bruno Haible  <bruno@clisp.org>
12290         dfa tests: Fix compilation error (regression 2023-04-22).
12291         * tests/test-dfa-match-aux.c: Include unistd.h.
12292         * modules/dfa-tests (Depends-on): Add unistd.
12294 2023-04-24  Bruno Haible  <bruno@clisp.org>
12296         tests: Suppress ‘#pragma GCC diagnostic’ warnings with GCC < 13.
12297         * tests/test-localename.c: Disable #pragma for GCC < 12.
12298         * tests/test-dup2.c: Disable #pragma for GCC < 13.
12299         * tests/test-fcntl.c: Likewise.
12300         * tests/test-getdtablesize.c: Likewise.
12301         * tests/test-listen.c: Likewise.
12302         * tests/test-open.h: Likewise.
12303         * tests/test-perror2.c: Likewise.
12304         * tests/test-select.h: Likewise.
12306 2023-04-24  Bruno Haible  <bruno@clisp.org>
12308         select, pselect: Fix test failure on native Windows.
12309         * lib/select.c (rpl_select): Fail if nfds is out-of-range.
12310         * lib/pselect.c (pselect): Likewise.
12312 2023-04-24  Paul Eggert  <eggert@cs.ucla.edu>
12314         fclose: pacify gcc -Wanalyzer-file-leak
12315         Without this patch, building coreutils with
12316         --enable-gcc-checking=expensive would fail with a message like
12317         “lib/exclude.c:682:6: error: leak of FILE 'in' [CWE-775]
12318         [-Werror=analyzer-file-leak]”, because Gnulib replaced fclose but
12319         not fopen, and GCC saw a call to fopen followed by a call to
12320         rpl_fclose.  The patch causes GCC to instead see a call to
12321         rpl_fopen followed by rpl_fclose.
12322         * m4/fclose.m4 (gl_FUNC_FCLOSE): Replace fopen when replacing
12323         fclose.
12324         * modules/fclose (Depends-on): Add fopen.
12325         (configure.ac): Replace fopen when replacing fclose.
12327         unsetenv-tests: pacify -Wanalyzer-putenv-of-auto-var
12328         * tests/test-unsetenv.c (main): Make entry static.  Even with this
12329         change, it’s unclear whether this test is portable POSIX code, but
12330         that’s a different matter.
12332         tests: suppress some unwanted -fanalyzer checking
12333         * tests/test-dup2.c, tests/test-fcntl.c, tests/test-fopen.h:
12334         * tests/test-getdtablesize.c, tests/test-listen.c:
12335         * tests/test-localename.c, tests/test-open.h, tests/test-perror2.c:
12336         * tests/test-select.h:
12337         Add pragmas to disable unwanted -fanalyzer checking.
12339 2023-04-24  Bruno Haible  <bruno@clisp.org>
12341         ftell, ftello: Fix recognition of pipes on native Windows.
12342         * m4/lseek.m4 (gl_FUNC_LSEEK): Update comment.
12343         * m4/ftello.m4 (gl_FUNC_FTELLO): On native Windows, set REPLACE_FTELLO=1
12344         always.
12345         * doc/posix-functions/ftello.texi: Mention the behaviour on pipes.
12346         * doc/posix-functions/ftell.texi: Likewise.
12347         * doc/posix-functions/fgetpos.texi: Likewise.
12349 2023-04-24  Bruno Haible  <bruno@clisp.org>
12351         lseek: Fix module dependencies (regression 2021-11-15).
12352         * modules/lseek (Depends-on): Re-enable the msvc-nothrow dependency
12353         also when WINDOWS_64_BIT_OFF_T is 0.
12355 2023-04-24  Bruno Haible  <bruno@clisp.org>
12357         system-quote: Fix memory overrun bug on native Windows.
12358         * lib/system-quote.c (system_quote): Allocate enough space for the
12359         result.
12361 2023-04-24  Bruno Haible  <bruno@clisp.org>
12363         unicodeio tests: Avoid test failures on native Windows.
12364         * tests/test-unicodeio.c: Include localcharset.h.
12365         (main): Handle C locales whose encoding is CP1252 or similar.
12366         * modules/unicodeio-tests (Depends-on): Add localcharset.
12368 2023-04-24  Bruno Haible  <bruno@clisp.org>
12370         *sprintf tests: Avoid test failures on mingw 10.
12371         * tests/test-vasnprintf-posix.c (test_function): On newer mingw, expect
12372         the de-facto standard result.
12373         * tests/test-vasprintf-posix.c (test_function): Likewise.
12374         * tests/test-snprintf-posix.h (test_function): Likewise.
12375         * tests/test-sprintf-posix.h (test_function): Likewise.
12377 2023-04-23  Bruno Haible  <bruno@clisp.org>
12379         Improve quoting of AS_HELP_STRING's first argument.
12380         * m4/acl.m4 (gl_FUNC_ACL_ARG): Don't underquote AS_HELP_STRING's first
12381         argument.
12382         * m4/assert.m4 (gl_ASSERT): Likewise.
12383         * m4/gc.m4 (gl_GC): Likewise.
12384         * m4/gnulib-common.m4 (gl_COMMON_BODY): Likewise.
12385         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT): Likewise.
12386         * m4/lib-ld.m4 (AC_LIB_PROG_LD): Likewise.
12387         * m4/libgmp.m4 (gl_LIBGMP): Likewise.
12388         * m4/regex.m4 (gl_REGEX): Likewise.
12389         * m4/relocatable-lib.m4 (gl_RELOCATABLE_NOP): Likewise.
12390         * m4/selinux-selinux-h.m4 (gl_LIBSELINUX): Likewise.
12391         * m4/sigsegv.m4 (gl_SIGSEGV): Likewise.
12392         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Likewise.
12393         * m4/valgrind-tests.m4 (gl_VALGRIND_TESTS): Likewise.
12394         * m4/version-etc.m4 (gl_VERSION_ETC_FLAG): Likewise.
12395         * m4/xattr.m4 (gl_FUNC_XATTR): Likewise.
12396         * doc/manywarnings.texi (manywarnings): Likewise. This avoids the use of
12397         quadrigraphs.
12399 2023-04-23  Bruno Haible  <bruno@clisp.org>
12401         category-none: Fix link errors on MSVC, when libunistring is installed.
12402         * modules/unictype/category-none (configure.ac): Remove
12403         gl_LIBUNISTRING_MODULE invocation.
12404         (Makefile.am): Compile unictype/categ_none.c always.
12406 2023-04-23  Paul Eggert  <eggert@cs.ucla.edu>
12408         manywarnings: use AS_IF
12409         * m4/manywarnings.m4 (gl_MANYWARN_COMPLEMENT):
12410         Use AS_IF when the body contains Autoconf macros that could
12411         conceivably require something.
12413         manywarnings: update C warnings for GCC 13
12414         Adjust for C programs compiled by GCC 13.
12415         (A C++ expert still needs to look at manywarnings-c++.m4.)
12416         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 13.
12417         * doc/manywarnings.texi (manywarnings): Document flex arrays.
12418         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add
12419         -fstrict-flex-arrays and -Wstrict-flex-arrays as these should be
12420         suitable for Gnulib-using code.
12422         manywarnings: bring doc up to date
12423         * doc/manywarnings.texi: Bring doc up to date for GCC 12.
12425         manywarnings: omit -fno-common in GCC 10+
12426         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Omit -fno-common
12427         in GCC 10 and later, as it is the default there.
12428         Check exit status of ‘gcc --version’.
12430 2023-04-23  Bruno Haible  <bruno@clisp.org>
12432         libunistring: Fix build on Windows, when a libunistring is installed.
12433         * lib/unicase.in.h: Include <unistring/woe32dll.h>.
12434         (unicase_empty_prefix_context, unicase_empty_suffix_context): Declare
12435         with GNULIB_UNICASE_..._DLL_VARIABLE.
12436         * lib/unictype.in.h: Include <unistring/woe32dll.h>.
12437         (UC_CATEGORY_*, UC_PROPERTY_*): Declare with
12438         GNULIB_UNICTYPE_..._DLL_VARIABLE.
12439         * lib/uninorm.in.h: Include <unistring/woe32dll.h>.
12440         (unicode_normalization_form uninorm_nf*): Declare with
12441         GNULIB_UNINORM_..._DLL_VARIABLE.
12442         * m4/libunistring-base.m4 (gl_LIBUNISTRING_MODULE_WITH_VARIABLE): New
12443         macro.
12444         (gl_LIBUNISTRING_LIB_PREPARE): Set HAVE_UNISTRING_WOE32DLL_H.
12445         * m4/unicase_h.m4: New file.
12446         * m4/unictype_h.m4: New file.
12447         * m4/uninorm_h.m4: New file.
12448         * modules/unicase/base (Files): Add m4/unicase_h.m4.
12449         (configure.ac): Bump version number. Invoke gl_UNICASE_H,
12450         gl_UNICASE_H_REQUIRE_DEFAULTS.
12451         (Makefile.am): Substitute all GNULIB_UNICASE_*_DLL_VARIABLE.
12452         * modules/unicase/empty-*-context (configure.ac): Invoke
12453         gl_UNICASE_H_REQUIRE_DEFAULTS. Use gl_LIBUNISTRING_MODULE_WITH_VARIABLE.
12454         * modules/unictype/base (Files): Add m4/unictype_h.m4.
12455         (configure.ac): Bump version number. Invoke gl_UNICTYPE_H,
12456         gl_UNICTYPE_H_REQUIRE_DEFAULTS.
12457         (Makefile.am): Substitute all GNULIB_UNICTYPE_*_DLL_VARIABLE.
12458         * modules/unictype/category-* (configure.ac): Invoke
12459         gl_UNICTYPE_H_REQUIRE_DEFAULTS. Use
12460         gl_LIBUNISTRING_MODULE_WITH_VARIABLE.
12461         * modules/unictype/property-* (configure.ac): Likewise.
12462         * modules/uninorm/base (Files): Add m4/uninorm_h.m4.
12463         (configure.ac): Bump version number. Invoke gl_UNINORM_H,
12464         gl_UNINORM_H_REQUIRE_DEFAULTS.
12465         (Makefile.am): Substitute all GNULIB_UNINORM_*_DLL_VARIABLE.
12466         * modules/uninorm/nf* (configure.ac): Invoke
12467         gl_UNINORM_H_REQUIRE_DEFAULTS. Use gl_LIBUNISTRING_MODULE_WITH_VARIABLE.
12469 2023-04-22  Bruno Haible  <bruno@clisp.org>
12471         Avoid some Autoconf "was expanded before it was required" warnings.
12472         * m4/locale-ar.m4 (gt_LOCALE_AR): Define through AC_DEFUN_ONCE.
12473         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
12474         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
12475         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
12476         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
12478 2023-04-22  Bruno Haible  <bruno@clisp.org>
12480         string-desc tests: Avoid test failure on native Windows.
12481         * tests/test-string-desc.c: Include <fcntl.h>, <unistd.h>.
12482         (main): Expect a file name argument. Write to this file, instead of to
12483         fd 3.
12484         * tests/test-string-desc.sh: Pass a file name as argument, instead of
12485         using '3>'.
12486         * modules/string-desc-tests (Depends-on): Add close.
12488 2023-04-22  Bruno Haible  <bruno@clisp.org>
12490         threadlib, pthread-h, threads-h: Avoid mingw's libwinpthread by default.
12491         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Set
12492         gl_use_winpthreads_default to 'no' by default.
12493         (gl_AVOID_WINPTHREAD): Update comments.
12495 2023-04-22  Bruno Haible  <bruno@clisp.org>
12497         posixtm tests: Avoid test failure on native Windows.
12498         * tests/test-posixtm.c (T): On native Windows, disable test cases that
12499         would fail.
12501 2023-04-22  Bruno Haible  <bruno@clisp.org>
12503         dfa tests: Fix test failure on mingw differently.
12504         Suggested by Paul Eggert.
12505         * tests/test-dfa-invalid-char-class.sh: Revert last change.
12506         * tests/test-dfa-match-aux.c: Include binary-io.h.
12507         (main): Put stdout into binary mode.
12508         * modules/dfa-tests (Depends-on): Add binary-io.
12510 2023-04-20  Bruno Haible  <bruno@clisp.org>
12512         getumask: Make it work on native Windows.
12513         * lib/getumask.c (getumask): When TMPDIR is unset, try TMP and TEMP.
12514         * tests/test-getumask.c (ASSUME_UMASK_CONSTANT): Define to 1 on native
12515         Windows.
12517 2023-04-20  Bruno Haible  <bruno@clisp.org>
12519         posixtm tests: Fix link error.
12520         * modules/posixtm-tests (Depends-on): Add stpcpy.
12522 2023-04-20  Bruno Haible  <bruno@clisp.org>
12524         readtokens tests: Fix test failure on mingw.
12525         * tests/test-readtokens.sh: Transform CRLF to LF in the output, before
12526         comparing with the expected output.
12528         parse-duration tests: Fix test failure on mingw.
12529         * tests/test-parse-duration.sh: Transform CRLF to LF in the output,
12530         before analyzing the output.
12532         dfa tests: Fix test failure on mingw.
12533         * tests/test-dfa-invalid-char-class.sh: Transform CRLF to LF in the
12534         output, before comparing with the expected output.
12536 2023-04-20  Bruno Haible  <bruno@clisp.org>
12538         Fix uses of libwinpthread on mingw 10.
12539         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): On mingw, set the result to
12540         "guessing no".
12542 2023-04-20  Bruno Haible  <bruno@clisp.org>
12544         Move remaining call_once tests from mtx-tests to call_once-tests.
12545         * tests/test-call_once1.c: Renamed from tests/test-call_once.c.
12546         * tests/test-call_once2.c: New file, based on tests/test-mtx.c.
12547         * tests/test-mtx.c: Remove the code that was testing call_once.
12548         * modules/call_once-tests (Files): Add test-call_once1.c,
12549         test-call_once2.c. Remove test-call_once.c.
12550         (Depends-on): Add thrd, lock, stdint.
12551         (configure.ac): Check for alarm.
12552         (Makefile.am): Test test-call_once1 instead of test-call_once. Also test
12553         test-call_once2.
12555 2023-04-20  Bruno Haible  <bruno@clisp.org>
12557         execute tests: Fix compilation error on mingw (regression 2023-01-17).
12558         * tests/test-execute-main.c (main): Don't use SIGPIPE if it's not
12559         defined.
12561 2023-04-20  Bruno Haible  <bruno@clisp.org>
12563         assert-h, verify: Fix compilation error in C++ mode with MSVC 14.30.
12564         * lib/verify.h (_Static_assert): In C++ mode with MSVC 14.1 or newer,
12565         define merely to static_assert.
12566         (static_assert): In C++ mode with MSVC 14.1 or newer, don't define.
12568 2023-04-19  Bruno Haible  <bruno@clisp.org>
12570         chown, lchown tests: Fix link error on mingw 10.
12571         * modules/chown-tests (configure.ac): Test whether getgid() exists.
12572         * modules/lchown-tests (configure.ac): Likewise.
12573         * modules/fchownat-tests (configure.ac): Likewise.
12574         * tests/test-chown.h (getgid): Define a fallback.
12575         * tests/test-lchown.h (getgid): Likewise.
12577 2023-04-19  Bruno Haible  <bruno@clisp.org>
12579         ctime: Fix compilation errors in C++ mode on mingw 10.
12580         * lib/c++defs.h (_GL_FUNCDECL_RPL): Add a comment.
12581         * lib/time.in.h (ctime): Don't use _GL_ATTRIBUTE_DEPRECATED before
12582         _GL_FUNCDECL_RPL in C++ mode.
12584 2023-04-19  Bruno Haible  <bruno@clisp.org>
12586         random: Fix compilation errors in C++ mode on mingw 10.
12587         * lib/stdlib.in.h (random, srandom): Disable _GL_CXXALIASWARN invocation
12588         on non-glibc systems.
12590 2023-04-19  Bruno Haible  <bruno@clisp.org>
12592         year2038-required: Fix configure failure with MSVC.
12593         * m4/largefile.m4 (_AC_SYS_LARGEFILE_PROBE): Distinguish the results
12594         "support not detected" and "supported through gnulib". If the result is
12595         "supported through gnulib", don't fail.
12597 2023-04-19  Bruno Haible  <bruno@clisp.org>
12599         doc: Add references to changes accepted for future POSIX revisions.
12600         * doc/glibc-functions/bind_textdomain_codeset.texi: Add reference to
12601         www.austingroupbugs.net issue.
12602         * doc/glibc-functions/bindtextdomain.texi: Likewise.
12603         * doc/glibc-functions/dcgettext.texi: Likewise.
12604         * doc/glibc-functions/dcngettext.texi: Likewise.
12605         * doc/glibc-functions/dgettext.texi: Likewise.
12606         * doc/glibc-functions/dngettext.texi: Likewise.
12607         * doc/glibc-functions/getentropy.texi: Likewise.
12608         * doc/glibc-functions/getresgid.texi: Likewise.
12609         * doc/glibc-functions/getresuid.texi: Likewise.
12610         * doc/glibc-functions/gettext.texi: Likewise.
12611         * doc/glibc-functions/ngettext.texi: Likewise.
12612         * doc/glibc-functions/posix_spawn_file_actions_addchdir_np.texi:
12613         Likewise.
12614         * doc/glibc-functions/posix_spawn_file_actions_addfchdir_np.texi:
12615         Likewise.
12616         * doc/glibc-functions/setresgid.texi: Likewise.
12617         * doc/glibc-functions/setresuid.texi: Likewise.
12618         * doc/glibc-functions/textdomain.texi: Likewise.
12619         * doc/posix-functions/asctime_r.texi: Likewise.
12620         * doc/posix-functions/ctime_r.texi: Likewise.
12622 2023-04-19  Bruno Haible  <bruno@clisp.org>
12624         wcsncmp: Add tests.
12625         * tests/test-wcsncmp.c: New file, based on tests/unistr/test-strncmp.h
12626         and tests/test-wcscmp.c.
12627         * modules/wcsncmp-tests: New file.
12629         wcsncmp: Work around two ISO C compliance bugs on several platforms.
12630         * lib/wchar.in.h (wcsncmp): Consider REPLACE_WCSNCMP.
12631         * lib/wcsncmp-impl.h (wcsncmp): Don't assume that the two wide
12632         characters are in the range 0..INT_MAX.
12633         * m4/wcsncmp.m4 (gl_FUNC_WCSNCMP): Test whether wcsncmp works for all
12634         wide characters. Set REPLACE_WCSNCMP.
12635         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSNCMP.
12636         * modules/wchar (Makefile.am): Substitute REPLACE_WCSNCMP.
12637         * modules/wcsncmp (Status, Notice): Un-obsolete this module.
12638         (configure.ac): Consider REPLACE_WCSNCMP.
12639         * doc/posix-functions/wcsncmp.texi: Mention the two bugs.
12641 2023-04-18  Bruno Haible  <bruno@clisp.org>
12643         wcscmp: Add tests.
12644         * tests/test-wcscmp.c: New file, based on tests/unistr/test-strcmp.h.
12645         * modules/wcscmp-tests: New file.
12647         wcscmp: Work around two ISO C compliance bugs on several platforms.
12648         * lib/wchar.in.h (wcscmp): Consider REPLACE_WCSCMP.
12649         * lib/wcscmp-impl.h (wcscmp): Don't assume that the two wide characters
12650         are in the range 0..INT_MAX.
12651         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Test whether wcscmp works for all wide
12652         characters. Set REPLACE_WCSCMP.
12653         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSCMP.
12654         * modules/wchar (Makefile.am): Substitute REPLACE_WCSCMP.
12655         * modules/wcscmp (Status, Notice): Un-obsolete this module.
12656         (configure.ac): Consider REPLACE_WCSCMP.
12657         * doc/posix-functions/wcscmp.texi: Mention the two bugs.
12659 2023-04-18  Bruno Haible  <bruno@clisp.org>
12661         wmemcmp: Add tests.
12662         * tests/test-wmemcmp.c: New file, based on tests/unistr/test-cmp.h.
12663         * modules/wmemcmp-tests: New file.
12665         wmemcmp: Work around ISO C compliance bug on several platforms.
12666         * lib/wchar.in.h (wmemcmp): Consider REPLACE_WMEMCMP.
12667         * lib/wmemcmp-impl.h (wmemcmp): Don't assume that the two wide
12668         characters are in the range 0..INT_MAX.
12669         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Test whether wmemcmp works for all
12670         wide characters. Set REPLACE_WMEMCMP.
12671         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WMEMCMP.
12672         * modules/wchar (Makefile.am): Substitute REPLACE_WMEMCMP.
12673         * modules/wmemcmp (configure.ac): Consider REPLACE_WMEMCMP.
12674         * doc/posix-functions/wmemcmp.texi: Mention the bug.
12676 2023-04-18  Bruno Haible  <bruno@clisp.org>
12678         doc: Update platform list for posix_spawnp.
12679         * doc/posix-functions/posix_spawnp.texi: Update platform list.
12681 2023-04-18  Paul Eggert  <eggert@cs.ucla.edu>
12683         Go back to dynamic largefile, year2038 tests
12684         Problem reported by Bruno Haible in:
12685         https://lists.gnu.org/r/bug-gnulib/2023-04/msg00134.html
12686         * modules/largefile-tests, modules/year2038-tests (Depends-on):
12687         Remove assert-h.
12688         * tests/test-largefile.c, tests/test-year2038.c:
12689         Test dynamically, not via static_assert.
12691         doc: mention when O_* defaults to 0
12692         * doc/posix-headers/fcntl.texi: Document in more detail which O_*
12693         macros default to 0 in Gnulib.
12695 2023-04-18  Bruno Haible  <bruno@clisp.org>
12697         doc: Mention a Cygwin 3.4.6 bug.
12698         * doc/posix-functions/readlinkat.texi: Mention a readlinkat bug on
12699         Cygwin < 3.4.7.
12701 2023-04-18  Bruno Haible  <bruno@clisp.org>
12703         ilogbl: Work around a Cygwin 3.4.6 bug.
12704         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Also test the value of
12705         ilogbl(NaN).
12706         * doc/posix-functions/ilogbl.texi: Mention the new Cygwin bug.
12708 2023-04-18  Bruno Haible  <bruno@clisp.org>
12710         file-has-acl tests: Avoid test failures on Cygwin 3.4.6.
12711         * tests/test-file-has-acl.sh: Fix distinction between Linux setfacl and
12712         Cygwin setfacl.
12714 2023-04-18  Bruno Haible  <bruno@clisp.org>
12716         c32isgraph tests: Avoid test failure on Cygwin 3.4.6.
12717         * tests/test-c32isgraph.c (main): Skip U+00A0 test on Cygwin.
12719 2023-04-17  Paul Eggert  <eggert@cs.ucla.edu>
12721         Slightly nicer largefile, year2038 tests
12722         * modules/largefile-tests, modules/year2038-tests (Depends-on):
12723         Add assert-h, intprops.
12724         * tests/test-largefile.c, tests/test-year2038.c:
12725         Prefer compile-time to run-time tests.
12726         Don’t assume CHAR_BIT == 8.
12728 2023-04-17  Bruno Haible  <bruno@clisp.org>
12730         MODULES.html.sh: Ensure hyperlinked files are displayable.
12731         * MODULES.html.sh (repo_url_prefix): Use cgit instead of gitweb.
12733         MODULES.html.sh: Avoid a HTTP redirect.
12734         * MODULES.html.sh (repo_url_prefix): Use the unabbreviated name of the
12735         git repository server.
12737 2023-04-16  Bruno Haible  <bruno@clisp.org>
12739         year2038: Add tests.
12740         * tests/test-year2038.c: New file.
12741         * modules/year2038-tests: New file.
12743 2023-04-16  Bruno Haible  <bruno@clisp.org>
12745         largefile: Add tests.
12746         * tests/test-largefile.c: New file.
12747         * modules/largefile-tests: New file.
12749 2023-04-16  Bruno Haible  <bruno@clisp.org>
12751         year2038: Revert the added module dependencies.
12752         Suggested by Paul Eggert in
12753         <https://lists.gnu.org/archive/html/bug-gnulib/2023-04/msg00117.html>.
12754         * modules/year2038 (Depends-on): Remove sched, sys_msg, sys_select,
12755         sys_sem, sys_shm, sys_stat, sys_time, sys_types, time-h, utime-h.
12757 2023-04-16  Bruno Haible  <bruno@clisp.org>
12759         posix_spawn_file_actions_addclose tests: Avoid test failure on Cygwin.
12760         * tests/test-posix_spawn_file_actions_addclose.c (main): Skip an
12761         unportable test also on Cygwin.
12763 2023-04-15  Bruno Haible  <bruno@clisp.org>
12765         Fix compilation errors of list, set, oset, map, omap in C++ mode.
12766         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define
12767         _GL_BRACKET_BEFORE_ATTRIBUTE. In _GL_ATTRIBUTE_DEPRECATED,
12768         _GL_ATTRIBUTE_MAYBE_UNUSED, _GL_ATTRIBUTE_NODISCARD, don't use the
12769         bracket syntax if _GL_BRACKET_BEFORE_ATTRIBUTE is defined.
12771 2023-04-15  Bruno Haible  <bruno@clisp.org>
12773         Don't include module 'year2038-required' in all-of-gnulib testdirs.
12774         * all-modules (exclude): Add year2038-required.
12776 2023-04-15  Bruno Haible  <bruno@clisp.org>
12778         selinux-h: Fix compilation error (regression 2023-04-13).
12779         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Instead of
12780         defining the C macro HAVE_SELINUX_SELINUX_H to 0, set the Autoconf
12781         variable HAVE_SELINUX_SELINUX_H to 0.
12783 2023-04-14  Bruno Haible  <bruno@clisp.org>
12785         year2038: Fix configure failure on 32-bit mingw.
12786         * m4/largefile.m4 (_AC_SYS_YEAR2038_PROBE): Use the same option
12787         spelling as in _AC_SYS_YEAR2038_OPTIONS.
12789 2023-04-14  Bruno Haible  <bruno@clisp.org>
12791         isnan: Fix compilation error in C++ mode on FreeBSD 13.2.
12792         * lib/math.in.h (isnan): On FreeBSD 13.2 or newer, don't declare isnan
12793         through _GL_MATH_CXX_REAL_FLOATING_DECL_2.
12795 2023-04-14  Bruno Haible  <bruno@clisp.org>
12797         filemode: Fix double-inclusion guard.
12798         * lib/filemode.h: Make the double-inclusion guard actually work.
12800 2023-04-14  Bruno Haible  <bruno@clisp.org>
12802         year2038: Add reminder to include <config.h> before time_t gets defined.
12803         * lib/sched.in.h: Check that config.h was already included before the
12804         #include_next.
12805         * lib/sys_select.in.h: Likewise.
12806         * lib/sys_stat.in.h: Likewise.
12807         * lib/sys_time.in.h: Likewise.
12808         * lib/sys_types.in.h: Likewise.
12809         * lib/time.in.h: Likewise.
12810         * lib/utime.in.h: Likewise.
12811         * modules/year2038 (Depends-on): Add sched, sys_msg, sys_select,
12812         sys_sem, sys_shm, sys_stat, sys_time, sys_types, time-h, utime-h.
12814         sys_shm: New module.
12815         * lib/sys_shm.in.h: New file.
12816         * m4/sys_shm_h.m4: New file.
12817         * modules/sys_shm: New file.
12818         * doc/posix-headers/sys_shm.texi: Mention the new module.
12820         sys_sem: New module.
12821         * lib/sys_sem.in.h: New file.
12822         * m4/sys_sem_h.m4: New file.
12823         * modules/sys_sem: New file.
12824         * doc/posix-headers/sys_sem.texi: Mention the new module.
12826         sys_msg: New module.
12827         * lib/sys_msg.in.h: New file.
12828         * m4/sys_msg_h.m4: New file.
12829         * modules/sys_msg: New file.
12830         * doc/posix-headers/sys_msg.texi: Mention the new module.
12832 2023-04-13  Bruno Haible  <bruno@clisp.org>
12834         Add more reminders to include <config.h>.
12835         * lib/aligned-malloc.h: Check that config.h was already included.
12836         * lib/careadlinkat.h: Likewise.
12837         * lib/filemode.h: Likewise.
12838         * lib/freadptr.h: Likewise.
12839         * lib/fseterr.h: Likewise.
12840         * lib/glthread/lock.h: Likewise.
12841         * lib/glthread/tls.h: Likewise.
12842         * lib/immutable.h: Likewise.
12843         * lib/isapipe.h: Likewise.
12844         * lib/isnand-nolibm.h: Likewise.
12845         * lib/isnanf-nolibm.h: Likewise.
12846         * lib/isnanl-nolibm.h: Likewise.
12847         * lib/mbswidth.h: Likewise.
12848         * lib/md5.h: Likewise.
12849         * lib/minmax.h: Likewise.
12850         * lib/msvc-inval.h: Likewise.
12851         * lib/msvc-nothrow.h: Likewise.
12852         * lib/pathmax.h: Likewise.
12853         * lib/sha1.h: Likewise.
12854         * lib/sha256.h: Likewise.
12855         * lib/sha512.h: Likewise.
12856         * lib/size_max.h: Likewise.
12857         * lib/sm3.h: Likewise.
12858         * lib/stat-size.h: Likewise.
12859         * lib/termcap.h: Likewise.
12860         * lib/terminfo.h: Likewise.
12861         * lib/thread-optim.h: Likewise.
12862         * lib/unlocked-io.h: Likewise.
12863         * lib/vma-iter.h: Likewise.
12865 2023-04-13  Bruno Haible  <bruno@clisp.org>
12867         Adjust comments in <config.h> reminders.
12868         * lib/*.h: In the comments, mention also HAVE_*.
12870 2023-04-13  Bruno Haible  <bruno@clisp.org>
12872         Adjust comments in <config.h> reminders.
12873         * lib/*.in.h: In the comments, mention also HAVE_RAW_DECL_*.
12874         * Makefile (sc_check_config_h_reminder): Search also for HAVE_RAW_DECL_.
12876 2023-04-13  Bruno Haible  <bruno@clisp.org>
12878         utmp: Avoid using HAVE_* macros in *.in.h files.
12879         * m4/pty_h.m4 (gl_PTY_CHECK_UTIL_H): New macro, extracted from gl_PTY_H.
12880         (gl_PTY_H): Invoke it.
12881         * m4/utmp_h.m4 (gl_UTMP_H): Invoke gl_PTY_CHECK_UTIL_H and set
12882         HAVE_TERMIOS_H.
12883         (gl_UTMP_H_DEFAULTS): Require gl_PTY_H_DEFAULTS, gl_TERMIOS_H_DEFAULTS.
12884         * modules/utmp (Files): Add m4/pty_h.m4, m4/termios_h.m4.
12885         (Makefile.am): Substitute also HAVE_UTIL_H, HAVE_LIBUTIL_H,
12886         HAVE_TERMIOS_H.
12887         * lib/utmp.in.h: Test HAVE_UTIL_H, HAVE_LIBUTIL_H, HAVE_TERMIOS_H as
12888         Autoconf variables.
12890 2023-04-13  Bruno Haible  <bruno@clisp.org>
12892         getprogname: Avoid using HAVE_* macros in *.in.h files.
12893         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
12894         HAVE_DECL_PROGRAM_INVOCATION_NAME.
12895         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Require gl_STDLIB_H_DEFAULTS
12896         and gl_USE_SYSTEM_EXTENSIONS. Set HAVE_DECL_PROGRAM_INVOCATION_NAME.
12897         * modules/stdlib (Makefile.am): Substitute
12898         HAVE_DECL_PROGRAM_INVOCATION_NAME.
12899         * lib/stdlib.in.h (getprogname): Test HAVE_DECL_PROGRAM_INVOCATION_NAME
12900         as an Autoconf variable.
12902 2023-04-13  Bruno Haible  <bruno@clisp.org>
12904         selinux-h: Avoid using HAVE_* macros in *.in.h files.
12905         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Initialize
12906         HAVE_SELINUX_SELINUX_H.
12907         * modules/selinux-h (Makefile.am): Substitute HAVE_SELINUX_SELINUX_H.
12908         * lib/se-selinux.in.h: Test HAVE_SELINUX_SELINUX_H as an Autoconf
12909         variable.
12911 2023-04-13  Bruno Haible  <bruno@clisp.org>
12913         ialloc, gethrxtime: Restore GCC diagnostics options.
12914         * lib/ialloc.h: Invoke _GL_INLINE_HEADER_END.
12915         * lib/xtime.h: Likewise.
12916         * Makefile (sc_check_GL_INLINE_HEADER_use): New rule.
12918 2023-04-13  Bruno Haible  <bruno@clisp.org>
12920         flexmember: Fix module description (regression 2016-09-07).
12921         * modules/flexmember (Include): Add "flexmember.h".
12923 2023-04-12  Paul Eggert  <eggert@cs.ucla.edu>
12925         doc: year2038 MIPS o32 nudge
12926         * doc/year2038.texi: Use more-common "o32" name for
12927         32-bit MIPS ABI.
12929 2023-04-12  Bruno Haible  <bruno@clisp.org>
12931         Add more reminders to include <config.h>.
12932         * m4/gnulib-common.m4 (gl_COMMON): In config.h, define
12933         _GL_CONFIG_H_INCLUDED.
12934         * lib/acl-internal.h: Test _GL_CONFIG_H_INCLUDED instead of
12935         _GL_INLINE_HEADER_BEGIN.
12936         * lib/alignalloc.h: Likewise.
12937         * lib/argp-fmtstream.h: Likewise.
12938         * lib/argp.h: Likewise.
12939         * lib/binary-io.h: Likewise.
12940         * lib/bitrotate.h: Likewise.
12941         * lib/c-ctype.h: Likewise.
12942         * lib/count-leading-zeros.h: Likewise.
12943         * lib/count-one-bits.h: Likewise.
12944         * lib/count-trailing-zeros.h: Likewise.
12945         * lib/eealloc.h: Likewise.
12946         * lib/execinfo.in.h: Likewise.
12947         * lib/gethrxtime.h: Likewise.
12948         * lib/gl_list.h: Likewise.
12949         * lib/gl_map.h: Likewise.
12950         * lib/gl_omap.h: Likewise.
12951         * lib/gl_openssl.h: Likewise.
12952         * lib/gl_oset.h: Likewise.
12953         * lib/gl_set.h: Likewise.
12954         * lib/gl_xlist.h: Likewise.
12955         * lib/gl_xmap.h: Likewise.
12956         * lib/gl_xomap.h: Likewise.
12957         * lib/gl_xoset.h: Likewise.
12958         * lib/gl_xset.h: Likewise.
12959         * lib/gl_xsublist.h: Likewise.
12960         * lib/glthread/cond.h: Likewise.
12961         * lib/hamt.h: Likewise.
12962         * lib/ialloc.h: Likewise.
12963         * lib/math.in.h: Likewise.
12964         * lib/mbchar.h: Likewise.
12965         * lib/mbfile.h: Likewise.
12966         * lib/mbiter.h: Likewise.
12967         * lib/mbuiter.h: Likewise.
12968         * lib/openat.h: Likewise.
12969         * lib/pipe-filter-aux.h: Likewise.
12970         * lib/priv-set.h: Likewise.
12971         * lib/safe-alloc.h: Likewise.
12972         * lib/savewd.h: Likewise.
12973         * lib/se-context.in.h: Likewise.
12974         * lib/se-label.in.h: Likewise.
12975         * lib/se-selinux.in.h: Likewise.
12976         * lib/sig-handler.h: Likewise.
12977         * lib/stat-time.h: Likewise.
12978         * lib/string-desc-quotearg.h: Likewise.
12979         * lib/string-desc.h: Likewise.
12980         * lib/sys_socket.in.h: Likewise.
12981         * lib/timespec.h: Likewise.
12982         * lib/u64.h: Likewise.
12983         * lib/uchar.in.h: Likewise.
12984         * lib/unistd.in.h: Likewise.
12985         * lib/utimens.h: Likewise.
12986         * lib/wctype.in.h: Likewise.
12987         * lib/xalloc.h: Likewise.
12988         * lib/xbinary-io.h: Likewise.
12989         * lib/xsize.h: Likewise.
12990         * lib/xstring-desc.h: Likewise.
12991         * lib/xtime.h: Likewise.
12992         * lib/acl.h: Check that config.h was already included.
12993         * lib/alignof.h: Likewise.
12994         * lib/argmatch.h: Likewise.
12995         * lib/argv-iter.h: Likewise.
12996         * lib/arpa_inet.in.h: Likewise.
12997         * lib/attribute.h: Likewise.
12998         * lib/backupfile.h: Likewise.
12999         * lib/base32.h: Likewise.
13000         * lib/base64.h: Likewise.
13001         * lib/basename-lgpl.h: Likewise.
13002         * lib/bitset.h: Likewise.
13003         * lib/bitsetv.h: Likewise.
13004         * lib/c-snprintf.h: Likewise.
13005         * lib/c-stack.h: Likewise.
13006         * lib/c-strcase.h: Likewise.
13007         * lib/c-vasnprintf.h: Likewise.
13008         * lib/c-vasprintf.h: Likewise.
13009         * lib/c-vsnprintf.h: Likewise.
13010         * lib/c-xvasprintf.h: Likewise.
13011         * lib/canon-host.h: Likewise.
13012         * lib/canonicalize.h: Likewise.
13013         * lib/clean-temp.h: Likewise.
13014         * lib/concat-filename.h: Likewise.
13015         * lib/ctype.in.h: Likewise.
13016         * lib/dfa.h: Likewise.
13017         * lib/di-set.h: Likewise.
13018         * lib/dirent-safer.h: Likewise.
13019         * lib/dirent.in.h: Likewise.
13020         * lib/dirname.h: Likewise.
13021         * lib/eloop-threshold.h: Likewise.
13022         * lib/error.in.h: Likewise.
13023         * lib/exclude.h: Likewise.
13024         * lib/fatal-signal.h: Likewise.
13025         * lib/fcntl.in.h: Likewise.
13026         * lib/file-type.h: Likewise.
13027         * lib/filenamecat.h: Likewise.
13028         * lib/filevercmp.h: Likewise.
13029         * lib/flexmember.h: Likewise.
13030         * lib/fnmatch.in.h: Likewise.
13031         * lib/fpending.h: Likewise.
13032         * lib/freadable.h: Likewise.
13033         * lib/freadahead.h: Likewise.
13034         * lib/freading.h: Likewise.
13035         * lib/fts_.h: Likewise.
13036         * lib/fwritable.h: Likewise.
13037         * lib/fwriting.h: Likewise.
13038         * lib/gc.h: Likewise.
13039         * lib/get_progname_of.h: Likewise.
13040         * lib/glob.in.h: Likewise.
13041         * lib/glthread/thread.h: Likewise.
13042         * lib/hash-pjw-bare.h: Likewise.
13043         * lib/hash-pjw.h: Likewise.
13044         * lib/hash-triple.h: Likewise.
13045         * lib/hash.h: Likewise.
13046         * lib/i-ring.h: Likewise.
13047         * lib/iconv.in.h: Likewise.
13048         * lib/ino-map.h: Likewise.
13049         * lib/inttostr.h: Likewise.
13050         * lib/inttypes.in.h: Likewise.
13051         * lib/javaversion.h: Likewise.
13052         * lib/langinfo.in.h: Likewise.
13053         * lib/locale.in.h: Likewise.
13054         * lib/localename.h: Likewise.
13055         * lib/malloc.in.h: Likewise.
13056         * lib/malloca.h: Likewise.
13057         * lib/memcasecmp.h: Likewise.
13058         * lib/memchr2.h: Likewise.
13059         * lib/memcmp2.h: Likewise.
13060         * lib/modechange.h: Likewise.
13061         * lib/monetary.in.h: Likewise.
13062         * lib/mountlist.h: Likewise.
13063         * lib/netdb.in.h: Likewise.
13064         * lib/obstack.h: Likewise.
13065         * lib/opendirat.h: Likewise.
13066         * lib/pagealign_alloc.h: Likewise.
13067         * lib/pipe-filter.h: Likewise.
13068         * lib/poll.in.h: Likewise.
13069         * lib/pthread.in.h: Likewise.
13070         * lib/pty.in.h: Likewise.
13071         * lib/quotearg.h: Likewise.
13072         * lib/read-file.h: Likewise.
13073         * lib/readline.h: Likewise.
13074         * lib/readutmp.h: Likewise.
13075         * lib/regex-quote.h: Likewise.
13076         * lib/relocatable.h: Likewise.
13077         * lib/savedir.h: Likewise.
13078         * lib/sched.in.h: Likewise.
13079         * lib/search.in.h: Likewise.
13080         * lib/sh-quote.h: Likewise.
13081         * lib/signal.in.h: Likewise.
13082         * lib/sigpipe-die.h: Likewise.
13083         * lib/sockets.h: Likewise.
13084         * lib/spawn.in.h: Likewise.
13085         * lib/ssfmalloc.h: Likewise.
13086         * lib/stack.h: Likewise.
13087         * lib/stdalign.in.h: Likewise.
13088         * lib/stdarg.in.h: Likewise.
13089         * lib/stddef.in.h: Likewise.
13090         * lib/stdio-safer.h: Likewise.
13091         * lib/stdio.in.h: Likewise.
13092         * lib/stdlib.in.h: Likewise.
13093         * lib/stdnoreturn.in.h: Likewise.
13094         * lib/strerror-override.h: Likewise.
13095         * lib/striconv.h: Likewise.
13096         * lib/striconveh.h: Likewise.
13097         * lib/striconveha.h: Likewise.
13098         * lib/string-buffer.h: Likewise.
13099         * lib/string.in.h: Likewise.
13100         * lib/strings.in.h: Likewise.
13101         * lib/strnlen1.h: Likewise.
13102         * lib/sys_file.in.h: Likewise.
13103         * lib/sys_ioctl.in.h: Likewise.
13104         * lib/sys_random.in.h: Likewise.
13105         * lib/sys_resource.in.h: Likewise.
13106         * lib/sys_select.in.h: Likewise.
13107         * lib/sys_stat.in.h: Likewise.
13108         * lib/sys_time.in.h: Likewise.
13109         * lib/sys_times.in.h: Likewise.
13110         * lib/sys_utsname.in.h: Likewise.
13111         * lib/sys_wait.in.h: Likewise.
13112         * lib/system-quote.h: Likewise.
13113         * lib/term-style-control.h: Likewise.
13114         * lib/termios.in.h: Likewise.
13115         * lib/textstyle.in.h: Likewise.
13116         * lib/threads.in.h: Likewise.
13117         * lib/time.in.h: Likewise.
13118         * lib/trim.h: Likewise.
13119         * lib/utime.in.h: Likewise.
13120         * lib/utmp.in.h: Likewise.
13121         * lib/vasnprintf.h: Likewise.
13122         * lib/verror.h: Likewise.
13123         * lib/version-etc.h: Likewise.
13124         * lib/wchar.in.h: Likewise.
13125         * lib/windows-spawn.h: Likewise.
13126         * lib/windows-thread.h: Likewise.
13127         * lib/xgetcwd.h: Likewise.
13128         * lib/xgetdomainname.h: Likewise.
13129         * lib/xgethostname.h: Likewise.
13130         * lib/xmalloca.h: Likewise.
13131         * lib/xmemdup0.h: Likewise.
13132         * lib/xprintf.h: Likewise.
13133         * lib/xreadlink.h: Likewise.
13134         * lib/xstriconv.h: Likewise.
13135         * lib/xstriconveh.h: Likewise.
13136         * lib/xstrndup.h: Likewise.
13137         * lib/xstrtol-error.h: Likewise.
13138         * lib/xvasprintf.h: Likewise.
13139         * Makefile (config_h_MACROS*): New variables.
13140         (sc_check_config_h_reminder): New rule.
13142 2023-04-11  Paul Eggert  <eggert@cs.ucla.edu>
13144         doc: update year2038 list further
13145         Prompted by Adhemerval Zanella Netto’s email in:
13146         https://lists.gnu.org/r/bug-gnulib/2023-04/msg00083.html
13147         Also, mention 32-bit Android.
13148         * doc/year2038.texi: Mention Linux/ork1 and Android.
13149         Append "32" to powerpc and sparc names.
13151 2023-04-11  Bruno Haible  <bruno@clisp.org>
13153         Fix the "make sc_prohibit_AC_LIBOBJ_in_m4" findings.
13154         * Makefile (allow_AC_LIBOBJ): Update after 2023-03-24 change. Add
13155         termcap, terminfo.
13157 2023-04-11  Bruno Haible  <bruno@clisp.org>
13159         Fix some "make sc_prohibit_leading_TABs" findings.
13160         * tests/test-calloc-gnu.c: Expand tabs.
13161         * tests/test-regex.c: Likewise.
13163 2023-04-11  Bruno Haible  <bruno@clisp.org>
13165         Makefile: Fix a syntax alert.
13166         * Makefile: Indent commands with tabs, not spaces.
13168 2023-04-10  Bruno Haible  <bruno@clisp.org>
13170         alignasof: Ensure a correct _Alignas (regression 2023-01-15).
13171         * m4/stdalign.m4 (gl_ALIGNASOF): Define _Alignas also when <stdalign.h>
13172         exists.
13174 2023-04-10  Paul Eggert  <eggert@cs.ucla.edu>
13176         doc: update list of year2038 platforms
13177         * doc/year2038.texi: Update list of platforms
13178         by adding dates and version numbers and fixing some that
13179         appear to have been misfiled.  Also, list working systems
13180         and versions first, as that helps shorten the list of
13181         failing systems by saying "older versions".
13183         doc: moved year2038 para up
13184         * doc/year2038.texi: Move a paragraph up,
13185         as it’s lonely at the end.
13187         doc: document year2038 first
13188         * doc/year2038.texi: Document year2038 first, then
13189         year2038-required.
13191 2023-04-10  Bruno Haible  <bruno@clisp.org>
13193         doc: Clarify list of platforms for year2038 support.
13194         * doc/year2038.texi (Avoiding the year 2038 problem): List the platforms
13195         on which year2038-required is known to fail vs. known to succeed.
13197 2023-04-10  Bruno Haible  <bruno@clisp.org>
13199         doc: Avoid ambiguous wording.
13200         * doc/posix-headers/time.texi: Say "or" not "and".
13202 2023-04-09  Bruno Haible  <bruno@clisp.org>
13204         doc: Fix a typo.
13205         * doc/posix-headers/time.texi: Fix typo in module name.
13207 2023-04-09  Paul Eggert  <eggert@cs.ucla.edu>
13209         largefile: sync from Autoconf master
13210         * modules/largefile-required, modules/year2038-required: New modules.
13211         * MODULES.html.sh, doc/largefile.texi, doc/posix-headers/time.texi:
13212         * doc/year2038.texi: Document this.
13213         * m4/largefile.m4: Sync from Autoconf master.
13214         Conditionalize the workaround on AC_SYS_LARGEFILE_REQUIRED rather
13215         than on AC_SYS_YEAR2038 so that we replace older but still
13216         unreleased Autoconf.
13217         (AC_SYS_LARGEFILE_REQUIRED, AC_SYS_YEAR2038_REQUIRED): New macros.
13219         year2038: configure earlier
13220         * modules/year2038: Put AC_SYS_YEAR2038 in configure.ac-early
13221         since it can affect later compilations with _TIME_BITS=64.
13223 2023-04-09  Bruno Haible  <bruno@clisp.org>
13225         c32toupper: Add tests.
13226         * tests/test-c32toupper.sh: New file.
13227         * tests/test-c32toupper.c: New file, based on tests/test-c32islower.c.
13228         * modules/c32toupper-tests: New file.
13230         c32toupper: New module.
13231         * lib/uchar.in.h (c32toupper): New declaration.
13232         * lib/c32toupper.c: New file.
13233         * modules/c32toupper: New file.
13234         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
13235         GNULIB_C32TOUPPER.
13236         * modules/uchar (Makefile.am): Substitute GNULIB_C32TOUPPER.
13238 2023-04-09  Bruno Haible  <bruno@clisp.org>
13240         c32tolower: Add tests.
13241         * tests/test-c32tolower.sh: New file.
13242         * tests/test-c32tolower.c: New file, based on tests/test-c32isupper.c.
13243         * modules/c32tolower-tests: New file.
13245         c32tolower: New module.
13246         * lib/uchar.in.h (c32tolower): New declaration.
13247         * lib/c32tolower.c: New file.
13248         * lib/c32to-impl.h: New file, based on lib/c32is-impl.h.
13249         * modules/c32tolower: New file.
13250         * m4/uchar_h.m4 (gl_UCHAR_H_REQUIRE_DEFAULTS): Initialize
13251         GNULIB_C32TOLOWER.
13252         * modules/uchar (Makefile.am): Substitute GNULIB_C32TOLOWER.
13254 2023-04-09  Bruno Haible  <bruno@clisp.org>
13256         c32is*: Ensure GNULIB_defined_mbstate_t is defined on AIX.
13257         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN): Define through AC_DEFUN_ONCE.
13258         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32): Require it.
13259         * modules/c32isalnum (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4.
13260         (configure.ac): Require gl_MBSTATE_T_BROKEN.
13261         * modules/c32isalpha: Likewise.
13262         * modules/c32isblank: Likewise.
13263         * modules/c32iscntrl: Likewise.
13264         * modules/c32isdigit: Likewise.
13265         * modules/c32isgraph: Likewise.
13266         * modules/c32islower: Likewise.
13267         * modules/c32isprint: Likewise.
13268         * modules/c32ispunct: Likewise.
13269         * modules/c32isspace: Likewise.
13270         * modules/c32isupper: Likewise.
13271         * modules/c32isxdigit: Likewise.
13273 2023-04-09  Bruno Haible  <bruno@clisp.org>
13275         mbrtoc32: Add comments.
13276         * lib/mbrtoc32.c: Add comment regarding AIX.
13277         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32): Add comment regarding
13278         GNULIB_defined_mbstate_t.
13280 2023-04-09  Bruno Haible  <bruno@clisp.org>
13282         doc: Mention a NetBSD bug.
13283         * doc/posix-functions/towlower.texi: Mention NetBSD bug 57339.
13284         * doc/posix-functions/towupper.texi: Likewise.
13286 2023-04-09  Bruno Haible  <bruno@clisp.org>
13288         vasnwprintf-posix: More details about the glibc bug.
13289         * doc/posix-functions/swprintf.texi: Add comment.
13290         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LA): Update cross-compilation
13291         guess.
13293 2023-04-08  Bruno Haible  <bruno@clisp.org>
13295         doc: Mention another Haiku bug.
13296         * doc/posix-functions/open.texi: Mention a Haiku bug with symlinks.
13298 2023-04-08  Bruno Haible  <bruno@clisp.org>
13300         Avoid Autoconf "was expanded before it was required" warning.
13301         * m4/exponentf.m4 (gl_FLOAT_EXPONENT_LOCATION): Define through
13302         AC_DEFUN_ONCE.
13303         * m4/exponentd.m4 (gl_DOUBLE_EXPONENT_LOCATION): Likewise.
13304         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Likewise.
13306 2023-04-08  Bruno Haible  <bruno@clisp.org>
13308         striconveh tests: Avoid test failure on glibc 2.15.
13309         * tests/test-striconveh.c (main): Skip some of the GB18030 tests on
13310         glibc < 2.16.
13312 2023-04-08  Bruno Haible  <bruno@clisp.org>
13314         vasnwprintf-posix: Really work around %La bug in glibc 2.15 and Haiku.
13315         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Fix a copy&paste bug.
13317 2023-04-08  Bruno Haible  <bruno@clisp.org>
13319         login_tty: Fix compilation error in C++ mode on Solaris 11.4.
13320         * m4/login_tty.m4 (gl_FUNC_LOGIN_TTY): Test whether <termios.h> exists.
13321         Consider it when testing whether login_tty is declared.
13322         * lib/utmp.in.h: If none of <util.h> and <libutil.h> exists, include
13323         <termios.h> instead.
13324         * doc/glibc-functions/login_tty.texi: Document the Solaris 11.4 problem.
13326 2023-04-08  Bruno Haible  <bruno@clisp.org>
13328         time: Fix compilation error in C++ mode on Solaris 11.
13329         * lib/time.in.h (time): Disable _GL_CXXALIASWARN invocation on non-glibc
13330         systems.
13332 2023-04-07  Bruno Haible  <bruno@clisp.org>
13334         unistdio/*: Fix test failures (regression 2023-01-28).
13335         * modules/unistdio/*printf (configure.ac): Bump required libunistring
13336         version number.
13338 2023-04-07  Bruno Haible  <bruno@clisp.org>
13340         trim tests: Fix link error.
13341         * modules/trim-tests (Makefile.am): Link test-trim also against libintl.
13343 2023-04-07  Bruno Haible  <bruno@clisp.org>
13345         stdio: Fix the value of _PRINTF_NAN_LEN_MAX on OpenBSD.
13346         * lib/stdio.in.h (_PRINTF_NAN_LEN_MAX): Define to 4 on OpenBSD.
13348 2023-04-07  Bruno Haible  <bruno@clisp.org>
13350         vasnwprintf-posix: Work around %La bug in glibc 2.15 and Haiku.
13351         * m4/printf.m4 (gl_SWPRINTF_DIRECTIVE_LA): New macro.
13352         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke
13353         gl_SWPRINTF_DIRECTIVE_LA and define NEED_WPRINTF_DIRECTIVE_LA
13354         accordingly.
13355         * lib/vasnprintf.c: When compiling vasnwprintf, if
13356         NEED_WPRINTF_DIRECTIVE_LA, handle the %La and %LA directives ourselves.
13357         * doc/posix-functions/swprintf.texi: Mention the %La bug.
13359 2023-04-07  Bruno Haible  <bruno@clisp.org>
13361         stdio: Fix compilation error in C++ mode on macOS.
13362         * lib/stdio.in.h (getw, putw): Repeat the declaration even if the
13363         function is already supposed to be declared.
13365 2023-04-07  Bruno Haible  <bruno@clisp.org>
13367         vasnwprintf-posix tests: Avoid test failure on mingw.
13368         * tests/test-vasnwprintf-posix.c (test_function): For mingw, change two
13369         expected test results.
13371 2023-04-06  Bruno Haible  <bruno@clisp.org>
13373         uchar: Inline functions with C linkage in C++ mode (regr. 2023-04-04).
13374         * m4/gnulib-common.m4 (gl_COMMON_BODY): Put definitions of
13375         _GL_BEGIN_C_LINKAGE, _GL_END_C_LINKAGE into config.h.
13376         * lib/uchar.in.h: Enclose all inline functions in _GL_BEGIN_C_LINKAGE /
13377         _GL_END_C_LINKAGE.
13379 2023-04-06  Bruno Haible  <bruno@clisp.org>
13381         alignalloc: Fix link error on glibc 2.15 systems.
13382         * lib/alignalloc.h (ALIGNALLOC_VIA_ALIGNED_ALLOC): Set to 0 on
13383         glibc 2.15 systems.
13385 2023-04-05  Bruno Haible  <bruno@clisp.org>
13387         doc: Add references to registered Haiku bugs.
13388         * doc/posix-functions/call_once.texi: Mention Haiku bug.
13389         * doc/posix-functions/duplocale.texi: Likewise.
13390         * doc/posix-functions/freelocale.texi: Likewise.
13391         * doc/posix-functions/getlogin_r.texi: Likewise.
13392         * doc/posix-functions/initstate.texi: Likewise.
13393         * doc/posix-functions/mbrtoc32.texi: Likewise.
13394         * doc/posix-functions/strxfrm.texi: Likewise.
13395         * doc/posix-headers/math.texi: Update.
13397 2023-04-05  Bruno Haible  <bruno@clisp.org>
13399         string-desc-quotearg tests: Avoid a test failure on Haiku.
13400         * tests/test-string-desc-quotearg.c (main): For the
13401         clocale_quoting_style, accept also the U+2018 and U+2019 characters in
13402         UTF-8 encoding.
13404 2023-04-05  Bruno Haible  <bruno@clisp.org>
13406         random_r: Fix compilation error on Haiku.
13407         * lib/stdlib.in.h: For random_r, include <stdint.h> always.
13408         * modules/random_r (Depends-on): Depend on 'stdint' always.
13410 2023-04-05  Bruno Haible  <bruno@clisp.org>
13412         forkpty, openpty, login_tty: Fix link errors of the tests.
13413         * m4/pty.m4 (gl_PTY_LIB): On Haiku, set PTY_LIB to '-lbsd'.
13415 2023-04-05  Bruno Haible  <bruno@clisp.org>
13417         strerrorname_np: Fix compilation error on Haiku.
13418         * lib/strerrorname_np.c (strerrorname_np): Avoid conflict between
13419         EDOOFUS and EINVAL.
13420         * tests/test-strerrorname_np.c (main): Likewise.
13422 2023-04-05  Bruno Haible  <bruno@clisp.org>
13424         uchar: Fix recent change.
13425         * lib/uchar.in.h: Include <string.h>, <wctype.h>.
13427 2023-04-05  Bruno Haible  <bruno@clisp.org>
13429         localename tests: Work around a Haiku bug.
13430         * tests/test-localename.c (freelocale): New macro.
13432 2023-04-05  Bruno Haible  <bruno@clisp.org>
13434         localename: Add support for Haiku's per-thread locales.
13435         * lib/localename.c: Include <dlfcn.h>.
13436         (gl_locale_name_thread_unsafe): Add special code for Haiku.
13438 2023-04-05  Bruno Haible  <bruno@clisp.org>
13440         uchar: Work around Haiku bug.
13441         * m4/uchar_h.m4 (gl_UCHAR_H, gl_TYPE_CHAR8_T, gl_TYPE_CHAR16_T,
13442         gl_TYPE_CHAR32_T): Before including <uchar.h>, on Haiku, first include
13443         <stdint.h>.
13444         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Likewise.
13445         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32, gl_CHECK_FUNC_MBRTOC32,
13446         gl_MBRTOC32_EMPTY_INPUT, gl_MBRTOC32_C_LOCALE, gl_MBRTOC32_SANITYCHECK):
13447         Likewise.
13448         * lib/uchar.in.h: On Haiku, include <stdint.h> before the include_next.
13449         * doc/posix-headers/uchar.texi: Mention the Haiku bug.
13451 2023-04-05  Bruno Haible  <bruno@clisp.org>
13453         stdlib, btowc: Fix file lists.
13454         * modules/stdlib (Files): Add m4/codeset.m4.
13455         * modules/btowc (Files): Likewise.
13456         * modules/c-dtoastr-tests (Files): Likewise.
13457         * modules/c-ldtoastr-tests (Files): Likewise.
13458         * modules/c-snprintf-tests (Files): Likewise.
13459         * modules/c-vasprintf-tests (Files): Likewise.
13460         * modules/c-vsnprintf-tests (Files): Likewise.
13461         * modules/c-xvasprintf-tests (Files): Likewise.
13462         * modules/nl_langinfo-tests (Files): Likewise.
13464 2023-04-04  Bruno Haible  <bruno@clisp.org>
13466         duplocale: Fix compilation error on Haiku (regression 2023-01-22).
13467         * lib/locale.in.h (duplocale): If HAVE_DUPLOCALE = 0, don't declare it,
13468         even if REPLACE_DUPLOCALE = 1.
13469         * modules/duplocale (Depends-on, configure.ac): Don't compile a
13470         replacement if HAVE_DUPLOCALE = 0 and REPLACE_DUPLOCALE = 1.
13472 2023-04-04  Bruno Haible  <bruno@clisp.org>
13474         c32tob, c32is*, c32rtomb, mbrtoc32: Fix file lists.
13475         * modules/c32tob (Files): Add m4/locale-fr.m4, m4/locale-zh.m4,
13476         m4/codeset.m4.
13477         * modules/c32isalnum (Files): Likewise.
13478         * modules/c32isalpha (Files): Likewise.
13479         * modules/c32isblank (Files): Likewise.
13480         * modules/c32iscntrl (Files): Likewise.
13481         * modules/c32isdigit (Files): Likewise.
13482         * modules/c32isgraph (Files): Likewise.
13483         * modules/c32islower (Files): Likewise.
13484         * modules/c32isprint (Files): Likewise.
13485         * modules/c32ispunct (Files): Likewise.
13486         * modules/c32isspace (Files): Likewise.
13487         * modules/c32isupper (Files): Likewise.
13488         * modules/c32isxdigit (Files): Likewise.
13489         * modules/c32rtomb (Files): Likewise.
13490         * modules/mbrtoc32 (Files): Likewise.
13492 2023-04-04  Bruno Haible  <bruno@clisp.org>
13494         stdlib: Work around MB_CUR_MAX bug on Solaris 10.
13495         * lib/stdlib.in.h (gl_MB_CUR_MAX): New function.
13496         (MB_CUR_MAX, GNULIB_defined_MB_CUR_MAX): New macros.
13497         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether MB_CUR_MAX is correct.
13498         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MB_CUR_MAX.
13499         * modules/stdlib (Files): Add m4/locale-fr.m4.
13500         (Makefile.am): Substitute REPLACE_MB_CUR_MAX.
13501         * doc/posix-headers/stdlib.texi: Mention the Solaris 10 bug.
13503 2023-04-04  Bruno Haible  <bruno@clisp.org>
13505         *c32*: Inline most functions on glibc and musl libc.
13506         * lib/uchar.in.h: Invoke _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
13507         (btoc32): Inline if _GL_WCHAR_T_IS_UCS4.
13508         (c32isalnum, c32isalpha, c32isblank, c32iscntrl, c32isdigit, c32isgraph,
13509         c32islower, c32isprint, c32ispunct, c32isspace, c32isupper,
13510         c32isxdigit): Inline if
13511         _GL_WCHAR_T_IS_UCS4 && !GNULIB_defined_mbstate_t.
13512         (c32snrtombs, c32srtombs, c32stombs, c32tob, mbsnrtoc32s, mbsrtoc32s,
13513         mbstoc32s): Inline if _GL_WCHAR_T_IS_UCS4.
13514         * lib/btoc32.c: Define compilation unit marker.
13515         (btoc32): Conditionally mark as _GL_EXTERN_INLINE.
13516         * lib/c32isalnum.c: Define compilation unit marker.
13517         * lib/c32isalpha.c: Likewise.
13518         * lib/c32isblank.c: Likewise.
13519         * lib/c32iscntrl.c: Likewise.
13520         * lib/c32isdigit.c: Likewise.
13521         * lib/c32isgraph.c: Likewise.
13522         * lib/c32islower.c: Likewise.
13523         * lib/c32isprint.c: Likewise.
13524         * lib/c32ispunct.c: Likewise.
13525         * lib/c32isspace.c: Likewise.
13526         * lib/c32isupper.c: Likewise.
13527         * lib/c32isxdigit.c: Likewise.
13528         * lib/c32is-impl.h (FUNC): Conditionally mark as _GL_EXTERN_INLINE.
13529         * lib/c32snrtombs.c: Define compilation unit marker.
13530         (c32snrtombs): Conditionally mark as _GL_EXTERN_INLINE.
13531         * lib/c32srtombs.c: Define compilation unit marker.
13532         (c32srtombs): Conditionally mark as _GL_EXTERN_INLINE.
13533         * lib/c32stombs.c: Define compilation unit marker.
13534         (c32stombs): Conditionally mark as _GL_EXTERN_INLINE.
13535         * lib/c32tob.c: Define compilation unit marker.
13536         (c32tob): Conditionally mark as _GL_EXTERN_INLINE.
13537         * lib/mbsnrtoc32s.c: Define compilation unit marker.
13538         (mbsnrtoc32s): Conditionally mark as _GL_EXTERN_INLINE.
13539         * lib/mbsrtoc32s.c: Define compilation unit marker.
13540         (mbsrtoc32s): Conditionally mark as _GL_EXTERN_INLINE.
13541         * lib/mbstoc32s.c: Define compilation unit marker.
13542         (mbstoc32s): Conditionally mark as _GL_EXTERN_INLINE.
13543         * modules/uchar (Depends-on): Add extern-inline.
13545 2023-04-04  Pádraig Brady  <P@draigBrady.com>
13547         backupfile: fix bug when renaming from subdirectory
13548         * lib/backupfile.c (backup_internal): Ensure we use the
13549         appropriate offset if operating on a subdirectory,
13550         i.e., on an updated sdir.
13551         Fixes https://bugs.gnu.org/62607
13553 2023-04-04  Bruno Haible  <bruno@clisp.org>
13555         *c32*: Optimize on musl libc like on glibc.
13556         * lib/uchar.in.h (_GL_WCHAR_T_IS_UCS4): New macro.
13557         * lib/btoc32.c (btoc32): Test _GL_WCHAR_T_IS_UCS4 instead of __GLIBC__.
13558         * lib/mbsrtoc32s.c: Likewise.
13559         * lib/mbsnrtoc32s.c: Likewise.
13560         * lib/c32tob.c (c32tob): Likewise.
13561         * lib/c32srtombs.c: Likewise.
13562         * lib/c32snrtombs.c: Likewise.
13563         * lib/c32is-impl.h (FUNC): Likewise.
13565 2023-04-04  Bruno Haible  <bruno@clisp.org>
13567         uchar: Rename _GL_LARGE_CHAR32_T to _GL_SMALL_WCHAR_T.
13568         * lib/uchar.in.h (_GL_SMALL_WCHAR_T): Renamed from _GL_LARGE_CHAR32_T.
13569         * lib/mbrtoc32.c: Update.
13570         * lib/mbsrtoc32s.c: Update.
13571         * lib/mbsnrtoc32s.c: Update.
13572         * lib/c32tob.c: Update.
13573         * lib/c32rtomb.c: Update.
13574         * lib/c32srtombs.c: Update.
13575         * lib/c32snrtombs.c: Update.
13576         * lib/c32is-impl.h: Update.
13577         * tests/test-uchar.c: Update.
13579 2023-04-04  Bruno Haible  <bruno@clisp.org>
13581         c32rtomb: Fix an autoconf test.
13582         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): In a test program, include
13583         <stddef.h>, for NULL.
13585 2023-04-03  Bruno Haible  <bruno@clisp.org>
13587         tests: Set executable bit on more tests.
13588         * tests/test-c-dtoastr.sh: Make executable.
13589         * tests/test-c-ldtoastr.sh: Likewise.
13590         * tests/test-immutable.sh: Likewise.
13591         * tests/test-vasnwprintf-posix2.sh: Likewise.
13593 2023-04-03  Jim Meyering  <meyering@fb.com>
13595         tests: set executable bit in test-trim[1-3].sh
13596         This avoids a test failure for each new file.
13597         * tests/test-trim1.sh: Make this file executable.
13598         * tests/test-trim2.sh: Likewise.
13599         * tests/test-trim3.sh: Likewise.
13601 2023-04-03  Bruno Haible  <bruno@clisp.org>
13603         Use the 'extern-inline' module explicitly where needed.
13604         I found the list of affected modules through this command:
13605           for m in $(for f in `grep -Fl _GL_INLINE_HEADER_BEGIN lib/*.h | sort`
13606                      do ./gnulib-tool --find $f; done)
13607           do grep '^extern-inline' modules/$m > /dev/null || echo $m
13608           done
13609         * modules/fdutimensat (Depends-on): Add extern-inline.
13610         * modules/file-has-acl (Depends-on): Likewise.
13611         * modules/hamt (Depends-on): Likewise.
13612         * modules/relocatable-prog-wrapper (Depends-on): Likewise.
13613         * modules/safe-alloc (Depends-on): Likewise.
13614         * modules/string-desc (Depends-on): Likewise.
13615         * modules/string-desc-quotearg (Depends-on): Likewise.
13616         * modules/xstring-desc (Depends-on): Likewise.
13617         * modules/xvasprintf (Depends-on): Likewise.
13619 2023-04-03  Bruno Haible  <bruno@clisp.org>
13621         vasnprintf-posix: Fix harmless mistake (regression 2023-03-24).
13622         Found by Coverity.
13623         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Insert 'break;' statement.
13625 2023-04-03  Bruno Haible  <bruno@clisp.org>
13627         mbstoc32s tests: Check behaviour in the C locale.
13628         * tests/test-mbstoc32s.c (main): Test behaviour in the C locale. Based
13629         on tests/test-mbstowcs.c.
13630         * tests/test-mbstoc32s-5.sh: New file, based on tests/test-mbstowcs5.sh.
13631         * modules/mbstoc32s-tests (Files): Add it.
13632         (Depends-on): Add btoc32.
13633         (Makefile.am): Run test-mbstoc32s-5.sh.
13635 2023-04-03  Bruno Haible  <bruno@clisp.org>
13637         mbsnrtoc32s tests: Check behaviour in the C locale.
13638         * tests/test-mbsnrtoc32s.c (main): Test behaviour in the C locale. Based
13639         on tests/test-mbsnrtowcs.c.
13640         * tests/test-mbsnrtoc32s-5.sh: New file, based on
13641         tests/test-mbsrtowcs5.sh.
13642         * modules/mbsnrtoc32s-tests (Files): Add it.
13643         (Depends-on): Add btoc32.
13644         (Makefile.am): Run test-mbsnrtoc32s-5.sh.
13646 2023-04-03  Bruno Haible  <bruno@clisp.org>
13648         mbsrtoc32s tests: Check behaviour in the C locale.
13649         * tests/test-mbsrtoc32s.c (main): Test behaviour in the C locale. Based
13650         on tests/test-mbsrtowcs.c.
13651         * tests/test-mbsrtoc32s-5.sh: New file, based on
13652         tests/test-mbsrtowcs5.sh.
13653         * modules/mbsrtoc32s-tests (Files): Add it.
13654         (Depends-on): Add btoc32.
13655         (Makefile.am): Run test-mbsrtoc32s-5.sh.
13657 2023-04-03  Bruno Haible  <bruno@clisp.org>
13659         btoc32 tests: Check behaviour in the C locale.
13660         * tests/test-btoc32.c (main): Test behaviour in the C locale. Based on
13661         tests/test-btowc.c.
13662         * tests/test-btoc32-3.sh: New file, based on tests/test-btowc3.sh.
13663         * modules/btoc32-tests (Files): Add it.
13664         (Makefile.am): Test it.
13666 2023-04-03  Bruno Haible  <bruno@clisp.org>
13668         mbrtoc32 tests: Prefer *c32* functions.
13669         * tests/test-mbrtoc32.c (main): Use btoc32 instead of btowc.
13670         * modules/mbrtoc32-tests (Depends-on): Add btoc32.
13672 2023-04-03  Bruno Haible  <bruno@clisp.org>
13674         mbrtoc32 tests: Add comment.
13675         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): Add comment.
13676         * m4/mbrtoc32.m4 (gl_MBRTOC32_C_LOCALE): Add comment.
13677         * tests/test-mbrtoc32.c: Add comment.
13678         * tests/test-mbrtoc32-5.sh: Use symmetric coding style.
13679         * doc/posix-functions/mbrtoc32.texi: Update.
13681 2023-04-02  Bruno Haible  <bruno@clisp.org>
13683         trim: Fix trim_trailing result in multibyte locales.
13684         * lib/trim.c (trim2): Simplify algorithm for trim_trailing in multibyte
13685         locales, to use 2 instead of 3 states.
13686         (IF_LINT): Remove macro.
13688         trim: Add tests.
13689         * tests/test-trim.c: New file.
13690         * tests/test-trim1.sh: New file.
13691         * tests/test-trim2.sh: New file.
13692         * tests/test-trim3.sh: New file.
13693         * modules/trim-tests: New file.
13695 2023-04-02  Bruno Haible  <bruno@clisp.org>
13697         unistr/u8-strstr: Simplify code.
13698         * lib/unistr/u8-strstr.c: Inline the contents of lib/unistr/u-strstr.h.
13699         * lib/unistr/u-strstr.h: Remove file.
13700         * modules/unistr/u8-strstr (Files): Remove it.
13702         unistr/u{16,32}-strstr: Use two-way algorithm (no memory allocation).
13703         * lib/wcs-two-way.h: Use UNIT instead of wchar_t. Don't undefine
13704         RETURN_TYPE.
13705         * lib/wcsstr-impl.h: Move the non-linear implementation away. Use UNIT
13706         instead of wchar_t, RETURN_TYPE instead of 'wchar_t *', FUNC instead of
13707         wcsstr.
13708         (AVAILABLE): Use MEMCHR0 instead of wmemchr.
13709         (FUNC): Use STRCHR instead of wcschr.
13710         * lib/wcsstr.c: Moved the non-linear implementation to here.
13711         (FUNC, UNIT, RETURN_TYPE, MEMCHR0, STRCHR): New macros.
13712         * lib/unistr/u16-strstr.c: Don't include malloca.h, str-kmp.h,
13713         u-strstr.h. Instead, include wcsstr-impl.h.
13714         * lib/unistr/u32-strstr.c: Likewise.
13715         * modules/unistr/u16-strstr (Files): Remove u-strstr.h, str-kmp.h. Add
13716         wcsstr-impl.h, wcs-two-way.h.
13717         (Depends-on): Remove u16-strmbtouc, u16-strlen, u16-strnlen, malloca.
13718         Add u16-chr, u16-cmp.
13719         * modules/unistr/u32-strstr (Files): Remove u-strstr.h, str-kmp.h. Add
13720         wcsstr-impl.h, wcs-two-way.h.
13721         (Depends-on): Remove u32-strlen, u32-strnlen, malloca. Add u32-chr,
13722         u32-cmp.
13724 2023-04-02  Bruno Haible  <bruno@clisp.org>
13726         unistr/u*strstr tests: Add more tests.
13727         * tests/unistr/test-u-strstr.h (test_u_strstr): Add the two latest tests
13728         from tests/test-strstr.c.
13729         * tests/unistr/test-u8-strstr.c (U_SET): New macro.
13730         * tests/unistr/test-u16-strstr.c (U_SET): New macro.
13731         * tests/unistr/test-u32-strstr.c (U_SET): New macro.
13732         * modules/unistr/u8-strstr-tests (Depends-on): Add unistr/u8-set.
13733         * modules/unistr/u16-strstr-tests (Depends-on): Add unistr/u16-set.
13734         * modules/unistr/u32-strstr-tests (Depends-on): Add unistr/u32-set.
13736 2023-04-01  Bruno Haible  <bruno@clisp.org>
13738         vasnwprintf-posix: Fix behaviour in the C locale.
13739         * lib/vasnprintf.c (VASNPRINTF): If NEED_WPRINTF_DIRECTIVE_C is set,
13740         implement the 'c' directive here.
13741         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke gl_MBRTOWC_C_LOCALE.
13742         If mbrtowc is buggy in the C locale, define NEED_WPRINTF_DIRECTIVE_C.
13743         * modules/vasnwprintf (Files): Add m4/mbrtowc.m4.
13744         * tests/test-vasnwprintf-posix.c (test_function): Add tests of %s and %c
13745         in the C locale.
13746         * doc/posix-functions/fwprintf.texi: Mention the C locale behaviour bug.
13747         * doc/posix-functions/swprintf.texi: Likewise.
13748         * doc/posix-functions/vfwprintf.texi: Likewise.
13749         * doc/posix-functions/vswprintf.texi: Likewise.
13750         * doc/posix-functions/vwprintf.texi: Likewise.
13751         * doc/posix-functions/wprintf.texi: Likewise.
13753 2023-04-01  Bruno Haible  <bruno@clisp.org>
13755         vasnprintf-posix: Fix crash in narrow %lc directive (regr. 2023-03-21).
13756         * lib/vasnprintf.c (VASNPRINTF): Negative results of local_wcrtomb can
13757         now occur; handle them.
13758         * tests/test-vasnprintf-posix.c (test_function): Test %lc directive with
13759         a wint_t argument that is not a valid wide character.
13760         * tests/test-snprintf-posix.h (test_function): Likewise.
13761         * tests/test-sprintf-posix.h (test_function): Likewise.
13762         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
13763         * tests/test-vasprintf-posix.c (test_function): Likewise.
13765 2023-04-01  Bruno Haible  <bruno@clisp.org>
13767         stddef: Fix __need_wint_t handling in case of two stddef.h overrides.
13768         * lib/stddef.in.h: Replace _GL_STDDEF_WINT_T with a symbol that depends
13769         on the @GUARD_PREFIX@.
13771 2023-03-31  Bruno Haible  <bruno@clisp.org>
13773         vasnwprintf: Fix crash upon conversion failure when processing %s.
13774         * lib/vasnprintf.c (VASNPRINTF): When processing %s with !has_precision
13775         and !has_width, don't call abort() if there is a conversion failure.
13777 2023-03-30  Bruno Haible  <bruno@clisp.org>
13779         Avoid test failures on Android.
13780         * tests/test-btowc.c (main): Treat C locale like in
13781         tests/test-mbrtowc.c.
13782         * tests/test-mbsrtowcs.c (main): Likewise.
13783         * tests/test-mbsnrtowcs.c (main): Likewise.
13784         * tests/test-mbstowcs.c (main): Likewise.
13786 2023-03-30  Bruno Haible  <bruno@clisp.org>
13788         mbstowcs: Add tests.
13789         * tests/test-mbstowcs1.sh: New file, based on tests/test-mbsrtowcs1.sh.
13790         * tests/test-mbstowcs2.sh: New file, based on tests/test-mbsrtowcs2.sh.
13791         * tests/test-mbstowcs3.sh: New file, based on tests/test-mbsrtowcs3.sh.
13792         * tests/test-mbstowcs4.sh: New file, based on tests/test-mbsrtowcs4.sh.
13793         * tests/test-mbstowcs5.sh: New file, based on tests/test-mbsrtowcs5.sh.
13794         * tests/test-mbstowcs.c: New file, based on tests/test-mbsrtowcs.c.
13795         * modules/mbstowcs-tests: New file, based on modules/mbsrtowcs-tests.
13797         mbstowcs: New module.
13798         * lib/stdlib.in.h (mbstowcs): New declaration.
13799         * lib/mbstowcs.c: New file, based on lib/mbstoc32s.c.
13800         * m4/mbstowcs.m4: New file.
13801         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether mbstowcs is declared.
13802         (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_MBSTOWCS.
13803         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MBSTOWCS.
13804         * modules/stdlib (Makefile.am): Substitute GNULIB_MBSTOWCS,
13805         REPLACE_MBSTOWCS.
13806         * modules/mbstowcs: New file.
13807         * tests/test-stdlib-c++.cc (mbstowcs): Check signature.
13808         * doc/posix-functions/mbstowcs.texi: Mention the C locale behaviour bug
13809         and the new module.
13811 2023-03-30  Bruno Haible  <bruno@clisp.org>
13813         mbsnrtowcs: Fix behaviour in the C locale.
13814         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Invoke gl_MBRTOWC_C_LOCALE. If
13815         mbrtowc is buggy in the C locale, override also mbsnrtowcs.
13816         * modules/mbsnrtowcs (Files): Add m4/mbrtowc.m4.
13817         * tests/test-mbsnrtowcs.c (main): Add a test of the C locale, based on
13818         tests/test-mbsrtowcs.c.
13819         * tests/test-mbsnrtowcs5.sh: New file, based on tests/test-mbrtowc5.sh.
13820         * modules/mbsnrtowcs-tests (Files): Add it.
13821         (Makefile.am): Test it.
13822         * doc/posix-functions/mbsnrtowcs.texi: Mention the C locale behaviour
13823         bug.
13825 2023-03-30  Bruno Haible  <bruno@clisp.org>
13827         mbsrtowcs: Fix behaviour in the C locale.
13828         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Invoke gl_MBRTOWC_C_LOCALE. If
13829         mbrtowc is buggy in the C locale, override also mbsrtowcs.
13830         * modules/mbsrtowcs (Files): Add m4/mbrtowc.m4.
13831         * tests/test-mbsrtowcs.c (main): Add a test of the C locale, based on
13832         tests/test-mbrtowc.c.
13833         * tests/test-mbsrtowcs5.sh: New file, based on tests/test-mbrtowc5.sh.
13834         * modules/mbsrtowcs-tests (Files): Add it.
13835         (Makefile.am): Test it.
13836         * doc/posix-functions/mbsrtowcs.texi: Mention the C locale behaviour
13837         bug.
13839 2023-03-30  Bruno Haible  <bruno@clisp.org>
13841         mbrlen: Add tests.
13842         * tests/test-mbrlen1.sh: New file, based on tests/test-mbrtowc1.sh.
13843         * tests/test-mbrlen2.sh: New file, based on tests/test-mbrtowc2.sh.
13844         * tests/test-mbrlen3.sh: New file, based on tests/test-mbrtowc3.sh.
13845         * tests/test-mbrlen4.sh: New file, based on tests/test-mbrtowc4.sh.
13846         * tests/test-mbrlen5.sh: New file, based on tests/test-mbrtowc5.sh.
13847         * tests/test-mbrlen.c: New file, based on tests/test-mbrtowc.c.
13848         * tests/test-mbrlen-w32-1.sh: New file, based on
13849         tests/test-mbrtowc-w32-1.sh.
13850         * tests/test-mbrlen-w32-2.sh: New file, based on
13851         tests/test-mbrtowc-w32-2.sh.
13852         * tests/test-mbrlen-w32-3.sh: New file, based on
13853         tests/test-mbrtowc-w32-3.sh.
13854         * tests/test-mbrlen-w32-4.sh: New file, based on
13855         tests/test-mbrtowc-w32-4.sh.
13856         * tests/test-mbrlen-w32-5.sh: New file, based on
13857         tests/test-mbrtowc-w32-5.sh.
13858         * tests/test-mbrlen-w32-6.sh: New file, based on
13859         tests/test-mbrtowc-w32-6.sh.
13860         * tests/test-mbrlen-w32-7.sh: New file, based on
13861         tests/test-mbrtowc-w32-7.sh.
13862         * tests/test-mbrlen-w32.c: New file, based on tests/test-mbrtowc-w32.c.
13863         * modules/mbrlen-tests: New file, based on modules/mbrtowc-tests.
13864         * doc/posix-functions/mbrlen.texi: Update.
13866 2023-03-30  Bruno Haible  <bruno@clisp.org>
13868         btowc: Fix behaviour in the C locale.
13869         * lib/btowc.c: Include <string.h>
13870         (btowc): Use mbrtowc instead of mbtowc when possible.
13871         * m4/btowc.m4 (gl_FUNC_BTOWC): Test for the mingw bug in the C locale.
13872         Invoke gl_MBRTOWC_C_LOCALE. If mbrtowc is buggy in the C locale,
13873         override also btowc.
13874         (gl_PREREQ_BTOWC): Test whether mbrtowc exists.
13875         * modules/btowc (Files): Add m4/mbrtowc.m4.
13876         (Depends-on): Add mbrtowc.
13877         * tests/test-btowc.c (main): Add a test of the C locale, based on
13878         tests/test-mbrtowc.c.
13879         * tests/test-btowc3.sh: New file, based on tests/test-mbrtowc5.sh.
13880         * modules/btowc-tests (Files): Add it.
13881         (Makefile.am): Test it.
13882         * doc/posix-functions/btowc.texi: Mention the two C locale behaviour
13883         bugs and that they are worked around.
13885 2023-03-30  Bruno Haible  <bruno@clisp.org>
13887         mbrtowc tests: Add comment.
13888         * tests/test-mbrtowc.c: Add comment.
13889         * tests/test-mbrtowc5.sh: Use symmetric coding style.
13890         * doc/posix-functions/mbrtowc.texi: Update.
13892 2023-03-30  Bruno Haible  <bruno@clisp.org>
13894         stdlib tests: Check behaviour of C locale.
13895         * tests/test-stdlib.c (main): Check MB_CUR_MAX.
13897 2023-03-30  Bruno Haible  <bruno@clisp.org>
13899         string-desc tests: Fix "make distcheck" failure.
13900         * tests/test-string-desc.sh: Run the test in a subdir.
13902 2023-03-30  Bruno Haible  <bruno@clisp.org>
13904         snprintf: Avoid autoconf warning regarding gl_PRINTF_POSITIONS.
13905         * m4/printf.m4 (gl_PRINTF_POSITIONS): Define through AC_DEFUN_ONCE.
13907 2023-03-28  Bruno Haible  <bruno@clisp.org>
13909         doc: Document string-desc and related modules.
13910         * doc/string-desc.texi: New file.
13911         * doc/gnulib.texi (Particular Modules): Include it.
13913         string-desc-quotearg: Add tests.
13914         * tests/test-string-desc-quotearg.c: New file.
13915         * modules/string-desc-quotearg-tests: New file.
13917         string-desc-quotearg: New module.
13918         * lib/string-desc-quotearg.h: New file.
13919         * lib/string-desc-quotearg.c: New file.
13920         * modules/string-desc-quotearg: New file.
13922         xstring-desc: Add tests.
13923         * tests/test-xstring-desc.c: New file.
13924         * modules/xstring-desc-tests: New file.
13926         xstring-desc: New module.
13927         * lib/xstring-desc.h: New file.
13928         * lib/xstring-desc.c: New file.
13929         * modules/xstring-desc: New file.
13931         string-desc: Add tests.
13932         * tests/test-string-desc.sh: New file.
13933         * tests/test-string-desc.c: New file.
13934         * modules/string-desc-tests: New file.
13936         string-desc: New module.
13937         * lib/string-desc.h: New file.
13938         * lib/string-desc.c: New file.
13939         * lib/string-desc-contains.c: New file.
13940         * modules/string-desc: New file.
13942 2023-03-28  Bruno Haible  <bruno@clisp.org>
13944         doc: Fix placement of memset_explicit node.
13945         * doc/posix-functions/memset_explicit.texi: Define a section, not a
13946         subsection.
13948 2023-03-28  Bruno Haible  <bruno@clisp.org>
13950         doc: Update regarding linear string search.
13951         * doc/glibc-functions/memmem.texi: Update platforms list.
13952         * doc/posix-functions/strstr.texi: Likewise.
13953         * doc/glibc-functions/strcasestr.texi: Likewise.
13955 2023-03-27  Bruno Haible  <bruno@clisp.org>
13957         ialloc: Add comments.
13958         * lib/ialloc.h (imalloc, irealloc, icalloc, ireallocarray): Add
13959         comments.
13961 2023-03-27  Paul Eggert  <eggert@cs.ucla.edu>
13963         Support FALLTHROUGH macro better in glibc+clang.
13964         * lib/fnmatch.c (FALLTHROUGH): Use __attribute__ ((__fallthrough__))
13965         also in clang >= 10.
13966         * lib/fts.c (FALLTHROUGH): Likewise.
13967         * lib/regex_internal.h (FALLTHROUGH): Likewise.
13969 2023-03-27  Bruno Haible  <bruno@clisp.org>
13971         wcsstr: Ensure worst-case linear execution time.
13972         * lib/wchar.in.h (wcsstr): Consider REPLACE_WCSSTR.
13973         * lib/wcs-two-way.h: New file, based on lib/str-two-way.h.
13974         * lib/wcsstr-impl.h: If requested, use the two-way algorithm. New code
13975         based on lib/strstr.c.
13976         * m4/wcsstr.m4 (gl_FUNC_WCSSTR_SIMPLE): Renamed from gl_FUNC_WCSSTR.
13977         (gl_FUNC_WCSSTR): New macro, based on gl_FUNC_STRSTR in m4/strstr.m4.
13978         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSSTR.
13979         * modules/wchar (Makefile.am): Substitute REPLACE_WCSSTR.
13980         * modules/wcsstr-simple: New file, based on modules/wcsstr.
13981         * modules/wcsstr (Description): Document that this module now provides
13982         an efficient implementation.
13983         (Files): Add lib/wcs-two-way.h.
13984         (Depends-on): Depend on wcsstr-simple and the dependencies of the
13985         two-way implementation.
13986         (configure.ac): Use AC_LIBOBJ instead of a conditional. Don't invoke
13987         gl_WCHAR_MODULE_INDICATOR.
13988         (Makefile.am): Don't augment lib_SOURCES.
13989         * tests/test-wcsstr.c: New file, based on tests/test-strstr.c.
13990         * modules/wcsstr-tests: New file, based on modules/strstr-tests.
13991         * doc/posix-functions/wcsstr.texi: Mention the worst-case complexity.
13992         Mention the new 'wcsstr-simple' module.
13993         * doc/posix-functions/strstr.texi: Fix typo.
13995 2023-03-27  Bruno Haible  <bruno@clisp.org>
13997         Add test case from a past musl libc bug.
13998         * tests/test-strstr.c (main): Add test of periodic needle.
13999         * tests/test-strcasestr.c (main): Likewise.
14000         * tests/test-c-strstr.c (main): Likewise.
14001         * tests/test-c-strcasestr.c (main): Likewise.
14002         * tests/test-memmem.c (main): Likewise.
14004 2023-03-27  Bruno Haible  <bruno@clisp.org>
14006         uchar: ISO C 23: Define char8_t.
14007         * lib/uchar.in.h (char8_t): New type or macro.
14008         * m4/uchar_h.m4 (gl_TYPE_CHAR8_T): New macro.
14009         (gl_UCHAR_H): Invoke it. Set CXX_HAS_CHAR8_TYPE.
14010         * modules/uchar (Makefile.am): Substitute CXX_HAS_CHAR8_TYPE,
14011         GNULIBHEADERS_OVERRIDE_CHAR8_T.
14012         * tests/test-uchar.c: Add tests for char8_t.
14014 2023-03-25  Bruno Haible  <bruno@clisp.org>
14016         stdlib: ISO C 23: Document issue with once_flag and call_once.
14017         * doc/posix-headers/stdlib.texi: Document issue and workaround.
14019 2023-03-25  Bruno Haible  <bruno@clisp.org>
14021         call_once: New module, separate from mtx.
14022         * lib/threads.in.h (call_once): Declare as part of module 'call_once',
14023         not module 'mtx'.
14024         * lib/call_once.c: New file, extracted from lib/mtx.c.
14025         * lib/mtx.c (call_once): Remove function.
14026         * m4/threads_h.m4 (gl_THREADS_H_REQUIRE_DEFAULTS): Inititalize
14027         GNULIB_CALL_ONCE.
14028         * modules/threads-h (Makefile.am): Substitute GNULIB_CALL_ONCE.
14029         * modules/call_once: New file, based on modules/mtx.
14030         * modules/threads (Depends-on): Add call_once.
14031         * tests/test-threads-c++.cc: Update accordingly.
14032         * modules/call_once-tests: New file, based on modules/mtx-tests.
14033         * modules/mtx-tests (Files): Remove tests/test-call_once.c.
14034         (Makefile.am): Don't compile test-call_once.
14035         * doc/posix-functions/call_once.texi: Document that the relevant module
14036         is now 'call_once'.
14037         * NEWS: Mention the change.
14039 2023-03-25  Bruno Haible  <bruno@clisp.org>
14041         stdio: ISO C 23: Define _PRINTF_NAN_LEN_MAX.
14042         * lib/stdio.in.h (_PRINTF_NAN_LEN_MAX): New macro.
14043         * m4/stdio_h.m4 (gl_STDIO_H): Invoke gl_MUSL_LIBC.
14044         * modules/stdio (Files): Add m4/musl.m4.
14045         * tests/test-stdio.c: Check that _PRINTF_NAN_LEN_MAX is defined.
14046         Include nan.h, macros.h.
14047         (main): Check the value of _PRINTF_NAN_LEN_MAX.
14048         * modules/stdio-tests (Files): Add tests/nan.h, tests/macros.h,
14049         m4/exponentd.m4.
14050         (configure.ac): Invoke gl_DOUBLE_EXPONENT_LOCATION.
14052 2023-03-25  Bruno Haible  <bruno@clisp.org>
14054         Make some header file tests a bit stronger.
14055         * tests/test-float.c: Include fpucw.h and macros.h only after checking
14056         the macros.
14057         * tests/test-glob-h.c: Include macros.h only after checking the types
14058         and macros.
14059         * tests/test-inttypes.c: Don't include <stddef.h>.
14060         * tests/test-math.c: Include <limits.h> and macros.h only after checking
14061         the types and macros.
14062         * tests/test-stddef.c: Include <limits.h> only after checking the types
14063         and macros.
14064         * tests/test-sys_select.c: Include signature.h only after checking the
14065         types.
14066         * tests/test-sys_socket.c: Include <errno.h> only after checking the
14067         types and macros.
14068         * tests/test-wctype-h.c: Include macros.h only after checking the types.
14070 2023-03-25  Bruno Haible  <bruno@clisp.org>
14072         is* tests: Ensure needed .m4 files are packaged.
14073         * modules/isfinite-tests (Files): Add m4/exponent*.m4.
14074         * modules/isnan-tests (Files): Likewise.
14075         * modules/isnanf-tests (Files): Add m4/exponentf.m4.
14076         * modules/isnanf-nolibm-tests (Files): Likewise.
14077         * modules/isnand-tests (Files): Add m4/exponentd.m4.
14078         * modules/isnand-nolibm-tests (Files): Likewise.
14079         * modules/isnanl-tests (Files): Add m4/exponentl.m4.
14080         * modules/isnanl-nolibm-tests (Files): Likewise.
14081         * modules/isinf-tests (Files): Reorder.
14083 2023-03-24  Bruno Haible  <bruno@clisp.org>
14085         *printf-posix: ISO C 23: Support size specifiers 'wN' and 'wfN'.
14086         * lib/printf-args.h: Include <stdint.h>.
14087         (arg_type): Add TYPE_[U]INT8_T, ..., TYPE_[U]INT_FAST64_T and
14088         TYPE_COUNT_INT8_T_POINTER, ..., TYPE_COUNT_INT_FAST64_T_POINTER.
14089         (argument): Add the union members a_[u]int8_t, ..., a_[u]int_fast64_t
14090         and a_count_int8_t_pointer, ..., a_count_int_fast64_t_pointer.
14091         * lib/printf-args.c: Include <limits.h>.
14092         (PRINTF_FETCHARGS): Handle TYPE_[U]INT8_T, ..., TYPE_[U]INT_FAST64_T and
14093         TYPE_COUNT_INT8_T_POINTER, ..., TYPE_COUNT_INT_FAST64_T_POINTER.
14094         * lib/printf-parse.c (PRINTF_PARSE): Accept only one size specifier, not
14095         a sequence of size specifiers. Accept "wN" and "wfN", where N = 8, 16,
14096         32, 64.
14097         * lib/vasnprintf.c (MAX_ROOM_NEEDED, VASNPRINTF): Handle the new TYPE_*
14098         values as well.
14099         * m4/printf.m4 (gl_PRINTF_SIZES_C23): New macro.
14100         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): Require
14101         gl_PRINTF_SIZES_C23. Test gl_cv_func_printf_sizes_c23.
14102         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): Likewise.
14103         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): Likewise.
14104         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX):
14105         Likewise.
14106         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): Likewise.
14107         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): Likewise.
14108         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): Likewise.
14109         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): Likewise.
14110         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): Likewise.
14111         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): Likewise.
14112         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): Likewise.
14113         * tests/test-vasnprintf-posix.c (test_function): Add tests for size
14114         specifiers with %d, %u, %b, %o, %x.
14115         * tests/test-snprintf-posix.h (test_function): Likewise.
14116         * tests/test-sprintf-posix.h (test_function): Likewise.
14117         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
14118         * tests/test-vasprintf-posix.c (test_function): Likewise.
14119         * modules/vasnprintf (Depends-on): Add limits-h.
14120         * modules/vasnwprintf (Depends-on): Add limits-h.
14121         * modules/c-vasnprintf (Depends-on): Add limits-h, stdint.
14122         * modules/unistdio/u-printf-args (Depends-on): Add stdint, limits-h.
14123         * doc/posix-functions/dprintf.texi: Mention the ISO C 23 size
14124         specifiers.
14125         * doc/posix-functions/fprintf.texi: Likewise.
14126         * doc/posix-functions/fwprintf.texi: Likewise.
14127         * doc/posix-functions/printf.texi: Likewise.
14128         * doc/posix-functions/snprintf.texi: Likewise.
14129         * doc/posix-functions/sprintf.texi: Likewise.
14130         * doc/posix-functions/swprintf.texi: Likewise.
14131         * doc/posix-functions/vdprintf.texi: Likewise.
14132         * doc/posix-functions/vfprintf.texi: Likewise.
14133         * doc/posix-functions/vfwprintf.texi: Likewise.
14134         * doc/posix-functions/vprintf.texi: Likewise.
14135         * doc/posix-functions/vsnprintf.texi: Likewise.
14136         * doc/posix-functions/vsprintf.texi: Likewise.
14137         * doc/posix-functions/vswprintf.texi: Likewise.
14138         * doc/posix-functions/vwprintf.texi: Likewise.
14139         * doc/posix-functions/wprintf.texi: Likewise.
14141 2023-03-24  Bruno Haible  <bruno@clisp.org>
14143         xprintf-gnu: New module.
14144         * modules/xprintf-gnu: New file, based on modules/vasnprintf-gnu and
14145         modules/xprintf-posix.
14147 2023-03-24  Bruno Haible  <bruno@clisp.org>
14149         xvasprintf-gnu: New module.
14150         * modules/xvasprintf-gnu: New file, based on modules/xvasprintf-posix.
14152 2023-03-24  Bruno Haible  <bruno@clisp.org>
14154         vasnwprintf-gnu: Add tests.
14155         * tests/test-vasnwprintf-gnu.c: New file, based on
14156         tests/test-vasnwprintf-posix.c and tests/test-vasnprintf-gnu.c.
14157         * modules/vasnwprintf-gnu-tests: New file, based on
14158         modules/vasnwprintf-posix-tests.
14160         vasnwprintf-gnu: New module.
14161         * m4/vasnwprintf-posix.m4 (gl_FUNC_VASNWPRINTF_IS_POSIX): New macro.
14162         (gl_FUNC_VASNWPRINTF_POSIX): Require it. Invoke
14163         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14164         * m4/vasnwprintf-gnu.m4: New file, based on m4/vasnprintf-gnu.m4.
14165         * modules/vasnwprintf-gnu: New file, based on modules/vasnprintf-gnu.
14167 2023-03-24  Bruno Haible  <bruno@clisp.org>
14169         obstack-printf-gnu: Add tests.
14170         * modules/obstack-printf-gnu-tests: New file, based on
14171         modules/obstack-printf-posix-tests.
14173         obstack-printf-gnu: New module.
14174         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_IS_POSIX): New
14175         macro, extracted from gl_FUNC_OBSTACK_PRINTF_POSIX.
14176         (gl_FUNC_OBSTACK_PRINTF_POSIX): Require it. Invoke
14177         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14178         * m4/obstack-printf-gnu.m4: New file, based on
14179         m4/obstack-printf-posix.m4.
14180         * modules/obstack-printf-gnu: New file, based on modules/vasnprintf-gnu.
14181         * doc/glibc-functions/obstack_printf.texi: Mention the new module.
14182         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
14184 2023-03-24  Bruno Haible  <bruno@clisp.org>
14186         dprintf-gnu: Add tests.
14187         * tests/test-dprintf-gnu.sh: New file, based on
14188         tests/test-dprintf-posix.sh.
14189         * tests/test-dprintf-gnu.c: New file, based on
14190         tests/test-vasnprintf-gnu.c.
14191         * modules/dprintf-gnu-tests: New file, based on
14192         modules/dprintf-posix-tests.
14194         dprintf-gnu: New module.
14195         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_IS_POSIX): New macro,
14196         extracted from gl_FUNC_DPRINTF_POSIX.
14197         (gl_FUNC_DPRINTF_POSIX): Require it. Invoke
14198         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14199         * m4/dprintf-gnu.m4: New file, based on m4/dprintf-posix.m4.
14200         * modules/dprintf-gnu: New file, based on modules/vasnprintf-gnu.
14201         * doc/posix-functions/dprintf.texi: Mention the new module.
14203 2023-03-24  Bruno Haible  <bruno@clisp.org>
14205         vdprintf-gnu: Add tests.
14206         * tests/test-vdprintf-gnu.sh: New file, based on
14207         tests/test-vdprintf-posix.sh.
14208         * tests/test-vdprintf-gnu.c: New file, based on
14209         tests/test-vdprintf-posix.c.
14210         * modules/vdprintf-gnu-tests: New file, based on
14211         modules/vdprintf-posix-tests.
14213         vdprintf-gnu: New module.
14214         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_IS_POSIX): New macro,
14215         extracted from gl_FUNC_VDPRINTF_POSIX.
14216         (gl_FUNC_VDPRINTF_POSIX): Require it. Invoke
14217         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14218         * m4/vdprintf-gnu.m4: New file, based on m4/vdprintf-posix.m4.
14219         * modules/vdprintf-gnu: New file, based on modules/vasnprintf-gnu.
14220         * doc/posix-functions/vdprintf.texi: Mention the new module.
14222 2023-03-24  Bruno Haible  <bruno@clisp.org>
14224         printf-gnu: Add tests.
14225         * tests/test-printf-gnu.sh: New file, based on
14226         tests/test-printf-posix.sh.
14227         * tests/test-printf-gnu.c: New file, based on tests/test-printf-posix.c.
14228         * modules/printf-gnu-tests: New file, based on
14229         modules/printf-posix-tests.
14231         printf-gnu: New module.
14232         * m4/printf-posix.m4: Renamed from m4/printf-posix-rpl.m4.
14233         (gl_FUNC_PRINTF_IS_POSIX): New macro.
14234         (gl_FUNC_PRINTF_POSIX): Require it. Don't require
14235         gl_FUNC_VFPRINTF_POSIX. Invoke gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS
14236         and gl_REPLACE_VASNPRINTF.
14237         * m4/printf-gnu.m4: New file, based on m4/fprintf-posix.m4.
14238         * modules/printf-posix (Files): Update.
14239         * modules/printf-gnu: New file, based on modules/vasnprintf-gnu.
14240         * doc/posix-functions/printf.texi: Mention the new module.
14242 2023-03-24  Bruno Haible  <bruno@clisp.org>
14244         vprintf-gnu: Add tests.
14245         * tests/test-vprintf-gnu.sh: New file, based on
14246         tests/test-vprintf-posix.sh.
14247         * tests/test-vprintf-gnu.c: New file, based on
14248         tests/test-vprintf-posix.c.
14249         * tests/test-printf-gnu.h: New file, based on
14250         tests/test-vasnprintf-gnu.c.
14251         * modules/vprintf-gnu-tests: New file, based on
14252         modules/vprintf-posix-tests.
14254         vprintf-gnu: New module.
14255         * m4/vprintf-posix.m4 (gl_FUNC_VPRINTF_IS_POSIX): New macro.
14256         (gl_FUNC_VPRINTF_POSIX): Require it. Don't require
14257         gl_FUNC_VFPRINTF_POSIX. Invoke gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS
14258         and gl_REPLACE_VASNPRINTF.
14259         * m4/vprintf-gnu.m4: New file, based on m4/vfprintf-posix.m4.
14260         * modules/vprintf-gnu: New file, based on modules/vasnprintf-gnu.
14261         * doc/posix-functions/vprintf.texi: Mention the new module.
14263 2023-03-24  Bruno Haible  <bruno@clisp.org>
14265         fprintf-gnu: Add tests.
14266         * tests/test-fprintf-gnu.sh: New file, based on
14267         tests/test-fprintf-posix.sh.
14268         * tests/test-fprintf-gnu.c: New file, based on
14269         tests/test-fprintf-posix.c.
14270         * modules/fprintf-gnu-tests: New file, based on
14271         modules/fprintf-posix-tests.
14273         fprintf-gnu: New module.
14274         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_IS_POSIX): New macro,
14275         extracted from gl_FUNC_FPRINTF_POSIX.
14276         (gl_FUNC_FPRINTF_POSIX): Require it. Invoke
14277         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14278         * m4/fprintf-gnu.m4: New file, based on m4/fprintf-posix.m4.
14279         * modules/fprintf-gnu: New file, based on modules/vasnprintf-gnu.
14280         * doc/posix-functions/fprintf.texi: Mention the new module.
14282 2023-03-24  Bruno Haible  <bruno@clisp.org>
14284         vfprintf-gnu: Add tests.
14285         * tests/test-vfprintf-gnu.sh: New file, based on
14286         tests/test-vfprintf-posix.sh.
14287         * tests/test-vfprintf-gnu.c: New file, based on
14288         tests/test-vfprintf-posix.c.
14289         * tests/test-fprintf-gnu.h: New file, based on
14290         tests/test-vasnprintf-gnu.c.
14291         * tests/test-printf-gnu.output: New file, based on
14292         tests/test-vasnprintf-gnu.c.
14293         * modules/vfprintf-gnu-tests: New file, based on
14294         modules/vfprintf-posix-tests.
14296         vfprintf-gnu: New module.
14297         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_IS_POSIX): New macro,
14298         extracted from gl_FUNC_VFPRINTF_POSIX.
14299         (gl_FUNC_VFPRINTF_POSIX): Require it. Invoke
14300         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14301         * m4/vfprintf-gnu.m4: New file, based on m4/vfprintf-posix.m4.
14302         * modules/vfprintf-gnu: New file, based on modules/vasnprintf-gnu.
14303         * doc/posix-functions/vfprintf.texi: Mention the new module.
14305 2023-03-24  Bruno Haible  <bruno@clisp.org>
14307         vasprintf-gnu: Add tests.
14308         * tests/test-vasprintf-gnu.c: New file, based on
14309         tests/test-vasprintf-posix.c and tests/test-vasnprintf-gnu.c.
14310         * modules/vasprintf-gnu-tests: New file, based on
14311         modules/vasprintf-posix-tests.
14313         vasprintf-gnu: New module.
14314         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_IS_POSIX): New macro,
14315         extracted from gl_FUNC_VASPRINTF_POSIX.
14316         (gl_FUNC_VASPRINTF_POSIX): Require it. Invoke
14317         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14318         * m4/vasprintf-gnu.m4: New file, based on m4/vasprintf-posix.m4.
14319         * modules/vasprintf-gnu: New file, based on modules/vasnprintf-gnu.
14320         * doc/glibc-functions/vasprintf.texi: Mention the new module.
14321         * doc/glibc-functions/asprintf.texi: Likewise.
14323 2023-03-24  Bruno Haible  <bruno@clisp.org>
14325         sprintf-gnu: Add tests.
14326         * tests/test-sprintf-gnu.c: New file, based on
14327         tests/test-sprintf-posix.c.
14328         * modules/sprintf-gnu-tests: New file, based on
14329         modules/sprintf-posix-tests.
14331         sprintf-gnu: New module.
14332         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_IS_POSIX): New macro,
14333         extracted from gl_FUNC_SPRINTF_POSIX.
14334         (gl_FUNC_SPRINTF_POSIX): Require it. Invoke
14335         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14336         * m4/sprintf-gnu.m4: New file, based on m4/sprintf-posix.m4.
14337         * modules/sprintf-gnu: New file, based on modules/vasnprintf-gnu.
14338         * doc/posix-functions/sprintf.texi: Mention the new module.
14340 2023-03-24  Bruno Haible  <bruno@clisp.org>
14342         vsprintf-gnu: Add tests.
14343         * tests/test-vsprintf-gnu.c: New file, based on
14344         tests/test-vsprintf-posix.c.
14345         * tests/test-sprintf-gnu.h: New file, based on
14346         tests/test-vasnprintf-gnu.c.
14347         * modules/vsprintf-gnu-tests: New file, based on
14348         modules/vsprintf-posix-tests.
14350         vsprintf-gnu: New module.
14351         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_IS_POSIX): New macro,
14352         extracted from gl_FUNC_VSPRINTF_POSIX.
14353         (gl_FUNC_VSPRINTF_POSIX): Require it. Invoke
14354         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14355         * m4/vsprintf-gnu.m4: New file, based on m4/vsprintf-posix.m4.
14356         * modules/vsprintf-gnu: New file, based on modules/vasnprintf-gnu.
14357         * doc/posix-functions/vsprintf.texi: Mention the new module.
14359 2023-03-24  Bruno Haible  <bruno@clisp.org>
14361         snprintf-gnu: Add tests.
14362         * tests/test-snprintf-gnu.c: New file, based on
14363         tests/test-snprintf-posix.c.
14364         * modules/snprintf-gnu-tests: New file, based on
14365         modules/snprintf-posix-tests.
14367         snprintf-gnu: New module.
14368         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_IS_POSIX): New macro,
14369         extracted from gl_FUNC_SNPRINTF_POSIX.
14370         (gl_FUNC_SNPRINTF_POSIX): Require it. Invoke
14371         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14372         * m4/snprintf-gnu.m4: New file, based on m4/snprintf-posix.m4.
14373         * modules/snprintf-gnu: New file, based on modules/vasnprintf-gnu.
14374         * doc/posix-functions/snprintf.texi: Mention the new module.
14376 2023-03-24  Bruno Haible  <bruno@clisp.org>
14378         vsnprintf-gnu: Add tests.
14379         * tests/test-vsnprintf-gnu.c: New file, based on
14380         tests/test-vsnprintf-posix.c.
14381         * tests/test-snprintf-gnu.h: New file, based on
14382         tests/test-vasnprintf-gnu.c.
14383         * modules/vsnprintf-gnu-tests: New file, based on
14384         modules/vsnprintf-posix-tests.
14386         vsnprintf-gnu: New module.
14387         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_IS_POSIX): New macro,
14388         extracted from gl_FUNC_VSNPRINTF_POSIX.
14389         (gl_FUNC_VSNPRINTF_POSIX): Require it. Invoke
14390         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14391         * m4/vsnprintf-gnu.m4: New file, based on m4/vsnprintf-posix.m4.
14392         * modules/vsnprintf-gnu: New file, based on modules/vasnprintf-gnu.
14393         * doc/posix-functions/vsnprintf.texi: Mention the new module.
14395 2023-03-23  Bruno Haible  <bruno@clisp.org>
14397         vasnprintf-gnu: Add tests.
14398         * tests/test-vasnprintf-gnu.c: New file, based on
14399         tests/test-vasnprintf-posix.c.
14400         * modules/vasnprintf-gnu-tests: New file.
14402         vasnprintf-gnu: New module.
14403         Suggested by Eric Blake in
14404         <https://lists.gnu.org/archive/html/bug-gnulib/2023-03/msg00060.html>.
14405         * lib/printf-parse.c (PRINTF_PARSE): Recognize the 'B' conversion.
14406         * lib/printf-parse.h: Update comments.
14407         * lib/wprintf-parse.h: Likewise.
14408         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Treat the 'B' conversion like 'b'.
14409         (VASNPRINTF): Implement 'B' conversion if
14410         NEED_PRINTF_DIRECTIVE_UPPERCASE_B is set. Support the 'B' conversion if
14411         requested.
14412         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_B): When cross-compiling, guess yes
14413         on glibc >= 2.35.
14414         (gl_PRINTF_DIRECTIVE_UPPERCASE_B): New macro.
14415         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS): Renamed
14416         from gl_PREREQ_VASNPRINTF_WITH_EXTRAS.
14417         (gl_PREREQ_VASNPRINTF_DIRECTIVE_UPPERCASE_B,
14418         gl_PREREQ_VASNPRINTF_WITH_GNU_EXTRAS): New macros.
14419         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_IS_POSIX): New macro,
14420         extracted from gl_FUNC_VASNPRINTF_POSIX.
14421         (gl_FUNC_VASNPRINTF_POSIX): Require it. Invoke
14422         gl_PREREQ_VASNPRINTF_WITH_POSIX_EXTRAS.
14423         * m4/vasnprintf-gnu.m4: New file.
14424         * modules/vasnprintf-gnu: New file.
14425         * modules/c-vasnprintf (configure.ac): Update.
14426         * modules/unistdio/u8-vasnprintf (configure.ac): Likewise.
14427         * modules/unistdio/u8-u8-vasnprintf (configure.ac): Likewise.
14428         * modules/unistdio/u16-vasnprintf (configure.ac): Likewise.
14429         * modules/unistdio/u16-u16-vasnprintf (configure.ac): Likewise.
14430         * modules/unistdio/u32-vasnprintf (configure.ac): Likewise.
14431         * modules/unistdio/u32-u32-vasnprintf (configure.ac): Likewise.
14432         * modules/unistdio/ulc-vasnprintf (configure.ac): Likewise.
14434 2023-03-23  Bruno Haible  <bruno@clisp.org>
14436         printf-posix tests: Fix compilation error (regression 2021-08-28).
14437         * modules/printf-posix-tests (Files): Add tests/qemu.h.
14439 2023-03-22  Jim Meyering  <meyering@fb.com>
14441         gnu-web-doc-update: don't use host alias, cvs.sv.gnu.org
14442         * build-aux/gnu-web-doc-update: Use hostname cvs.savannah.gnu.org,
14443         not cvs.sv.gnu.org. Using the shorter alias would elicit this:
14444           $ pkg=grep ; cvs -d $USER@cvs.sv.gnu.org:/webcvs/$pkg co $pkg
14445           Bad server host key: Invalid key length
14447 2023-03-22  Bruno Haible  <bruno@clisp.org>
14449         *printf-posix: Fix implementation of %b directive.
14450         * lib/vasnprintf.c (VASNPRINTF): In the %b directive implementation, fix
14451         the precision handling, and ignore the '0' flag when a width and a
14452         precision are both present.
14453         * tests/test-snprintf-posix.h (test_function): Add test cases for the %x
14454         directive and more test cases for the %b directive.
14455         * tests/test-sprintf-posix.h (test_function): Likewise.
14456         * tests/test-vasnprintf-posix.c (test_function): Likewise.
14457         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
14458         * tests/test-vasprintf-posix.c (test_function): Likewise.
14459         * modules/vasnwprintf-posix-tests (Files): Add m4/musl.m4.
14460         (configure.ac): Invoke gl_MUSL_LIBC.
14462 2023-03-22  Bruno Haible  <bruno@clisp.org>
14464         vasnwprintf: Fix a warning: implicit declaration of function ‘wcsnlen’.
14465         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Test also whether wcsnlen is
14466         declared.
14467         * lib/vasnprintf.c (local_wcsnlen): Together with HAVE_WCSNLEN, test
14468         also HAVE_DECL_WCSNLEN.
14470 2023-03-22  Bruno Haible  <bruno@clisp.org>
14472         vasnwprintf: Fix a "warning: unused function local_wcsnlen".
14473         * lib/vasnprintf.c: Adjust #if conditions.
14475 2023-03-22  Bruno Haible  <bruno@clisp.org>
14477         vasnwprintf: Fix test failures on FreeBSD, NetBSD, AIX, mingw.
14478         * m4/printf.m4 (gl_SWPRINTF_WORKS): New macro.
14479         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke it and define
14480         HAVE_WORKING_SWPRINTF accordingly.
14481         * lib/vasnprintf.c: Together with HAVE_SWPRINTF, test also
14482         HAVE_WORKING_SWPRINTF.
14483         (VASNPRINTF): If WIDE_CHAR_VERSION && !DCHAR_IS_TCHAR, don't pass a
14484         wchar_t[] to snprintf. Add a workaround against mingw's snwprintf
14485         function.
14486         * doc/posix-functions/swprintf.texi: Document the null wide character
14487         bug.
14489 2023-03-22  Bruno Haible  <bruno@clisp.org>
14491         vasnwprintf: Fix a "warning: unused function 'wmax_room_needed'".
14492         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Adjust #if condition.
14494 2023-03-22  Bruno Haible  <bruno@clisp.org>
14496         vasnwprintf: Simplify last change.
14497         * lib/vasnprintf.c (VASNPRINTF): Remove unused variable 'len'.
14499 2023-03-22  Bruno Haible  <bruno@clisp.org>
14501         vasnwprintf tests: Fix link errors on AIX.
14502         * modules/vasnwprintf (Link): New section.
14503         * modules/vasnwprintf-posix (Link): New section.
14504         * modules/vasnwprintf-tests (Makefile.am): Link test-vasnwprintf with
14505         $(MBRTOWC_LIB).
14506         * modules/vasnwprintf-posix-tests (Makefile.am): Link
14507         test-vasnwprintf-posix, test-vasnwprintf-posix2, test-vasnwprintf-posix3
14508         with $(MBRTOWC_LIB).
14510 2023-03-22  Bruno Haible  <bruno@clisp.org>
14512         gnu-web-doc-update: Make it work for the first upload of a manual.
14513         Reported by Reuben Thomas <rrt@sc3d.org> in
14514         <https://lists.gnu.org/archive/html/bug-gnulib/2023-03/msg00066.html>.
14515         * build-aux/gnu-web-doc-update: Put the 'manual' directory under version
14516         control if it is not yet.
14518 2023-03-21  Bruno Haible  <bruno@clisp.org>
14520         unistdio/u*-vasnprintf: Fix conversion of %Id directive result.
14521         * lib/vasnprintf.c (VASNPRINTF): Don't assume that snprintf's result is
14522         entirely ASCII if the directive contain the glibc 'I' flag.
14524 2023-03-21  Bruno Haible  <bruno@clisp.org>
14526         vasnwprintf: Fix for older platforms without swprintf.
14527         * lib/vasnprintf.c (VASNPRINTF): In the %lc handling, ignore the
14528         precision. Convert the snprintf result to a wchar_t[] not by mbsrtowcs,
14529         but by a loop that does not stop at NUL characters.
14530         * tests/test-vasnwprintf-posix.c (test_function): Add more tests for the
14531         %c and %lc directives.
14532         * modules/vasnwprintf (Depends-on): Add mbrtowc. Remove mbsrtowcs.
14534 2023-03-21  Bruno Haible  <bruno@clisp.org>
14536         *printf-posix: Work around bug with %lc of 0 on many platforms.
14537         * lib/vasnprintf.c (local_wctomb): Define also for
14538         NEED_PRINTF_DIRECTIVE_LC.
14539         (VASNPRINTF): Implement %lc handling ourselves if
14540         NEED_PRINTF_DIRECTIVE_LC.
14541         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LC): New macro.
14542         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_LC): New macro.
14543         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
14544         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Require
14545         gl_PRINTF_DIRECTIVE_LC and test its result. Invoke
14546         gl_PREREQ_VASNPRINTF_DIRECTIVE_LC.
14547         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
14548         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
14549         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
14550         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
14551         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
14552         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
14553         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
14554         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
14555         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
14556         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
14557         * tests/test-snprintf-posix.h (test_function): Add more tests for the
14558         %c and %lc directives.
14559         * tests/test-sprintf-posix.h (test_function): Likewise.
14560         * tests/test-vasnprintf-posix.c (test_function): Likewise.
14561         * tests/test-vasprintf-posix.c (test_function): Likewise.
14562         * doc/glibc-functions/asprintf.texi: Mention the %lc 0 bug.
14563         * doc/glibc-functions/obstack_printf.texi: Likewise.
14564         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
14565         * doc/glibc-functions/vasprintf.texi: Likewise.
14566         * doc/posix-functions/dprintf.texi: Likewise.
14567         * doc/posix-functions/fprintf.texi: Likewise.
14568         * doc/posix-functions/printf.texi: Likewise.
14569         * doc/posix-functions/snprintf.texi: Likewise.
14570         * doc/posix-functions/sprintf.texi: Likewise.
14571         * doc/posix-functions/vdprintf.texi: Likewise.
14572         * doc/posix-functions/vfprintf.texi: Likewise.
14573         * doc/posix-functions/vprintf.texi: Likewise.
14574         * doc/posix-functions/vsnprintf.texi: Likewise.
14575         * doc/posix-functions/vsprintf.texi: Likewise.
14577 2023-03-21  Ar Rakin  <rakinar2@onesoftnet.eu.org>  (tiny change)
14579         gnupload: correct SFTP connection URL
14580         Approved by Sergey Poznyakoff in
14581         <https://lists.gnu.org/archive/html/bug-gnulib/2023-03/msg00078.html>.
14582         * build-aux/gnupload: fix gnu.org.ua SFTP connection URL:
14583         puszcza.gnu.org.ua -> download.gnu.org.ua
14585 2023-03-20  Bruno Haible  <bruno@clisp.org>
14587         memrchr tests: Avoid GCC warning.
14588         * tests/test-memrchr.c: Don't use '#pragma GCC diagnostic' for GCC
14589         versions older than 4.7.
14591 2023-03-20  Bruno Haible  <bruno@clisp.org>
14593         unistdio: Simplify code.
14594         * lib/unistdio/u8-vasnprintf.c (DCHAR_T_IS_UINT8_T): Remove unused
14595         macro.
14596         * lib/unistdio/u8-u8-vasnprintf.c: Likewise.
14597         * lib/unistdio/u16-vasnprintf.c (DCHAR_T_IS_UINT16_T): Remove unused
14598         macro.
14599         * lib/unistdio/u16-u32-vasnprintf.c: Likewise.
14600         * lib/unistdio/u32-vasnprintf.c (DCHAR_T_IS_UINT32_T): Remove unused
14601         macro.
14602         * lib/unistdio/u32-u32-vasnprintf.c: Likewise.
14604 2023-03-20  Bruno Haible  <bruno@clisp.org>
14606         vasnwprintf: Port to older platforms without swprintf.
14607         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Test for swprintf.
14608         * lib/vasnprintf.c (TCHAR_T, DCHAR_IS_TCHAR, SNPRINTF): When
14609         WIDE_CHAR_VERSION and swprintf does not exist, use TCHAR_T = char,
14610         SNPRINTF = snprintf, and !DCHAR_IS_TCHAR.
14611         (VASNPRINTF): In this case, implement %ls and %lc directly. Adjust a
14612         couple of #if conditions. For the conversion from TCHAR_T[] to
14613         DCHAR_T[], use mbsrtowcs.
14614         * modules/vasnwprintf (Depends-on): Add mbsrtowcs.
14616 2023-03-20  Bruno Haible  <bruno@clisp.org>
14618         wmemset: Relicense under LGPLv2+.
14619         * modules/wmemset (License): Change to LGPLv2+.
14620         * lib/wmemset.c: Update license notice.
14621         * lib/wmemset-impl.h: Likewise.
14623 2023-03-20  Bruno Haible  <bruno@clisp.org>
14625         wmemcpy: Relicense under LGPLv2+.
14626         * modules/wmemcpy (License): Change to LGPLv2+.
14627         * lib/wmemcpy.c: Update license notice.
14628         * lib/wmemcpy-impl.h: Likewise.
14630 2023-03-19  Bruno Haible  <bruno@clisp.org>
14632         vasnwprintf: Fix test failures on musl libc.
14633         * m4/vasnprintf.m4 (gl_PREREQ_VASNWPRINTF): Invoke gl_MUSL_LIBC.
14634         * lib/vasnprintf.c (VASNPRINTF): On musl libc, when WIDE_CHAR_VERSION,
14635         - force pad_ourselves to be 1,
14636         - don't use %n.
14637         Fix zero-padding when the result starts with a prefix "0x" or "0b".
14638         * modules/vasnwprintf (Files): Add musl.m4.
14639         * doc/posix-functions/swprintf.texi: Mention two musl libc bugs.
14641 2023-03-19  Bruno Haible  <bruno@clisp.org>
14643         vasnwprintf: Fix module dependencies.
14644         * modules/vasnwprintf (Depends-on): Add wmemcpy, wmemset.
14645         * modules/vasnwprintf-tests (Depends-on): Add wmemcmp.
14646         * modules/vasnwprintf-posix-tests (Depends-on): Likewise.
14648 2023-03-19  Paul Eggert  <eggert@cs.ucla.edu>
14650         test-pselect, test-select: use different ports
14651         I have observed rare and hard-to-reproduce problems with the GNU
14652         grep release candidate with ‘make -j5 check’ on Fedora 37 x86-64.
14653         One possibility is that test-pselect and test-select interfere
14654         with each other somehow when run simultaneously, as they use the
14655         same port.  Work around this possibility by using different ports
14656         from each other, and from test-poll (which also uses 12345).
14657         Of course it’d be better if all these tests used system-assigned
14658         ports, but I assume that’d take more work.
14659         * tests/test-pselect.c, tests/test-select.c (TEST_PORT): New macro.
14660         * tests/test-select.h (TEST_PORT): Remove.
14662 2023-03-19  Bruno Haible  <bruno@clisp.org>
14664         Update MODULES.html.sh.
14665         * MODULES.html.sh: Move stack, wmempcpy, bison to different sections.
14666         Fix a HTML layout problem.
14668 2023-03-18  Paul Eggert  <eggert@cs.ucla.edu>
14670         dfa: pacify Oracle Solaris Studio 12.6
14671         Without this patch, the compiler complains “statement not reached”.
14672         * lib/dfa.c (lex): Refactor to omit unreachable statement.
14674         Update MODULES.html.sh
14675         * MODULES.html.sh: Add some recently-added modules.
14676         This is by no means a complete update.  I needed to point
14677         to something about ‘time’ so I added ‘time’, and then added
14678         more modules until I ran out of, errr, time.
14679         Assuming MODULES.html.sh is still useful,
14680         at some point a more-complete update should be done.
14682 2023-03-17  Bruno Haible  <bruno@clisp.org>
14684         *printf-posix: ISO C 23: Add %b directive for binary output of integers.
14685         * lib/printf-parse.c (PRINTF_PARSE): Recognize the 'b' directive.
14686         * lib/printf-parse.h: Update comment.
14687         * lib/wprintf-parse.h: Likewise.
14688         * lib/vasnprintf.c (MAX_ROOM_NEEDED, VASNPRINTF): Add support for the
14689         'b' directive.
14690         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_B): New macro.
14691         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_B): New macro.
14692         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
14693         * m4/vasnwprintf-posix.m4 (gl_FUNC_VASNWPRINTF_POSIX): Invoke
14694         gl_PREREQ_VASNPRINTF_DIRECTIVE_B.
14695         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Require
14696         gl_PRINTF_DIRECTIVE_B and test its result. Invoke
14697         gl_PREREQ_VASNPRINTF_DIRECTIVE_B.
14698         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
14699         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
14700         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
14701         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
14702         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
14703         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
14704         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
14705         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
14706         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
14707         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
14708         * tests/test-snprintf-posix.h (test_function): Add some tests of the %b
14709         directive.
14710         * tests/test-sprintf-posix.h (test_function): Likewise.
14711         * tests/test-vasnprintf-posix.c (test_function): Likewise.
14712         * tests/test-vasnwprintf-posix.c (test_function): Likewise.
14713         * tests/test-vasprintf-posix.c (test_function): Likewise.
14714         * doc/glibc-functions/asprintf.texi: Mention the 'b' directive.
14715         * doc/glibc-functions/obstack_printf.texi: Likewise.
14716         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
14717         * doc/glibc-functions/vasprintf.texi: Likewise.
14718         * doc/posix-functions/dprintf.texi: Likewise.
14719         * doc/posix-functions/fprintf.texi: Likewise.
14720         * doc/posix-functions/fwprintf.texi: Likewise.
14721         * doc/posix-functions/printf.texi: Likewise.
14722         * doc/posix-functions/snprintf.texi: Likewise.
14723         * doc/posix-functions/sprintf.texi: Likewise.
14724         * doc/posix-functions/swprintf.texi: Likewise.
14725         * doc/posix-functions/vdprintf.texi: Likewise.
14726         * doc/posix-functions/vfprintf.texi: Likewise.
14727         * doc/posix-functions/vfwprintf.texi: Likewise.
14728         * doc/posix-functions/vprintf.texi: Likewise.
14729         * doc/posix-functions/vsnprintf.texi: Likewise.
14730         * doc/posix-functions/vsprintf.texi: Likewise.
14731         * doc/posix-functions/vswprintf.texi: Likewise.
14732         * doc/posix-functions/vwprintf.texi: Likewise.
14733         * doc/posix-functions/wprintf.texi: Likewise.
14735 2023-03-17  Bruno Haible  <bruno@clisp.org>
14737         vasnprintf, vasnwprintf: Simplify code.
14738         * lib/vasnprintf.c (MAX_ROOM_NEEDED): Remove dead code: The directives
14739         'o', 'x', 'X' always take an unsigned integer argument.
14741 2023-03-17  Bruno Haible  <bruno@clisp.org>
14743         vasnwprintf: Fix test failure on OpenBSD.
14744         * lib/vasnprintf.c (VASNPRINTF): Don't use the %n directive on OpenBSD.
14746 2023-03-17  Bruno Haible  <bruno@clisp.org>
14748         time: Fix test failure on AIX 7.2.
14749         * m4/time.m4 (gl_FUNC_TIME): Guess that it does not work on AIX.
14750         * doc/posix-functions/time.texi: Mention the bug on AIX.
14752         time: Fix test failure on native Windows.
14753         * m4/time.m4 (gl_FUNC_TIME): Guess that it does not work on native
14754         Windows.
14755         * modules/time (Depends-on): Add gettimeofday.
14756         * doc/posix-functions/time.texi: Mention the bug on Windows.
14758 2023-03-17  Bruno Haible  <bruno@clisp.org>
14760         vasnprintf, vasnwprintf: Include all necessary workarounds in libintl.
14761         * lib/vasnprintf.c: Remove IN_LIBINTL special-casing.
14763 2023-03-17  Bruno Haible  <bruno@clisp.org>
14765         vasnwprintf-posix: Add tests.
14766         * tests/test-vasnwprintf-posix.c: New file, based on
14767         tests/test-vasnprintf-posix.c.
14768         * tests/test-vasnwprintf-posix2.sh: New file, based on
14769         tests/test-vasnprintf-posix2.sh.
14770         * tests/test-vasnwprintf-posix2.c: New file, based on
14771         tests/test-vasnprintf-posix2.c.
14772         * tests/test-vasnwprintf-posix3.c: New file, based on
14773         tests/test-vasnprintf-posix3.c.
14774         * modules/vasnwprintf-posix-tests: New file, based on
14775         modules/vasnprintf-posix-tests.
14777         vasnwprintf-posix: New module.
14778         * m4/vasnwprintf-posix.m4: New file.
14779         * modules/vasnwprintf-posix: New file, based on
14780         modules/vasnprintf-posix.
14782 2023-03-17  Bruno Haible  <bruno@clisp.org>
14784         vasnprintf-posix: Relicense under LGPLv2+.
14785         * modules/vasnprintf-posix (License): Change to LGPLv2+.
14787 2023-03-17  Bruno Haible  <bruno@clisp.org>
14789         vasnwprintf: Add tests.
14790         * tests/test-vasnwprintf.c: New file, based on tests/test-vasnprintf.c.
14791         * modules/vasnwprintf-tests: New file, based on
14792         modules/vasnprintf-tests.
14794         vasnwprintf: New module.
14795         * lib/vasnprintf.c: Enable more code for WIDE_CHAR_VERSION, because
14796         snwprintf()/_snwprintf() (Windows) and swprintf() (Unix) don't return
14797         the needed buffer size, like snprintf does.
14798         * lib/wprintf-parse.h: New file, based on lib/printf-parse.h and
14799         gettext/gettext-runtime/intl/wprintf-parse.h.
14800         * lib/wprintf-parse.c: New file, based on
14801         gettext/gettext-runtime/intl/printf.c.
14802         * lib/vasnwprintf.h: New file, based on lib/vasnprintf.h and
14803         gettext/gettext-runtime/intl/vasnwprintf.h.
14804         * lib/vasnwprintf.c: New file.
14805         * lib/asnwprintf.c: New file, based on lib/asnprintf.c.
14806         * m4/vasnprintf.m4 (gl_FUNC_VASNWPRINTF): New macro.
14807         (gl_PREREQ_VASNXPRINTF): New macro, extracted from gl_PREREQ_VASNPRINTF.
14808         (gl_PREREQ_VASNPRINTF): Invoke it. Don't test for wcsnlen and mbrtowc.
14809         (gl_PREREQ_VASNWPRINTF): New macro.
14810         * modules/vasnwprintf: New file, based on modules/vasnprintf.
14812 2023-03-16  Bruno Haible  <bruno@clisp.org>
14814         strtol, strtoll, strtoul, strtoull: Make ISO C 23 compliant.
14815         * lib/strtol.c (INTERNAL (strtol)): Treat 'b' and base 2 like 'x' and
14816         base 16. Based on glibc commit 64924422a99690d147a166b4de3103f3bf3eaf6c
14817         by Joseph Myers.
14818         * m4/strtol.m4 (gl_FUNC_STRTOL): Test also whether parsing binary
14819         integers works. Update cross-compilation guesses.
14820         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
14821         * m4/strtoul.m4 (gl_FUNC_STRTOUL): Likewise.
14822         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise.
14823         * tests/test-strtol.c (main): Add tests of parsing binary integers.
14824         * tests/test-strtoll.c (main): Likewise.
14825         * tests/test-strtoul.c (main): Likewise.
14826         * tests/test-strtoull.c (main): Likewise.
14827         * doc/posix-functions/strtol.texi: Mention the problem with parsing
14828         binary integers.
14829         * doc/posix-functions/strtoll.texi: Likewise.
14830         * doc/posix-functions/strtoul.texi: Likewise.
14831         * doc/posix-functions/strtoull.texi: Likewise.
14833 2023-03-16  Bruno Haible  <bruno@clisp.org>
14835         timegm: Document under ISO C and POSIX substitutes.
14836         * doc/posix-functions/timegm.texi: Renamed from doc/glibc-functions/timegm.texi.
14837         * doc/gnulib.texi (Function Substitutes): Include timegm.texi here...
14838         (Glibc time.h): ... not here.
14840 2023-03-16  Bruno Haible  <bruno@clisp.org>
14842         stddef: Fix a compilation error on AIX 7.2 with xlclang.
14843         * lib/stddef.in.h (__CLANG_MAX_ALIGN_T_DEFINED): Define whenever we
14844         define GNULIB_defined_max_align_t.
14846 2023-03-16  Bruno Haible  <bruno@clisp.org>
14848         stddef: Define 'unreachable', for ISO C 23 compliance.
14849         * lib/verify.h (_GL_HAS_BUILTIN_UNREACHABLE): Don't define if already
14850         defined.
14851         * lib/stddef.in.h (_GL_HAS_BUILTIN_UNREACHABLE, unreachable): New
14852         macros.
14853         (abort): Declare if needed for unreachable.
14854         * m4/stddef_h.m4 (gl_STDDEF_H): Test for unreachable.
14855         * tests/test-stddef.c (test_unreachable_optimization,
14856         test_unreachable_noreturn): New functions, based on tests/test-verify.c.
14857         * doc/posix-headers/stddef.texi: Mention unreachable.
14859 2023-03-10  Paul Eggert  <eggert@cs.ucla.edu>
14861         posixtm: work around Glibc time issue
14862         * modules/posixtm (Depends-on): Add time.
14864 2023-03-09  Jim Meyering  <meyering@fb.com>
14866         bootstrap: correct last change
14867         * top/bootstrap-funclib.sh (autogen) [AUTORECONFFLAGS]: Do always
14868         apply the --no-recursive option.
14869         * build-aux/bootstrap: Regenerate.
14871         bootstrap: remove code that accommodated RHEL5's old autoreconf
14872         * top/bootstrap-funclib.sh (autogen) [AUTORECONFFLAGS]: RHEL5 has not
14873         been supported since 2017. It included (and this code worked around)
14874         a version of autoreconf that was so old it did not accept the
14875         --no-recursive option. Drop that workaround.
14876         * build-aux/bootstrap: Regenerate.
14878 2023-03-08  Bruno Haible  <bruno@clisp.org>
14880         gettimeofday, timespec_get tests: Avoid test failure on glibc/Linux.
14881         * modules/gettimeofday-tests (Depends-on): Add 'time'.
14882         * modules/timespec_get-tests (Depends-on): Likewise.
14883         * tests/test-gettimeofday.c (test_consistency): Update comment.
14884         * tests/test-timespec_get.c (main): Likewise.
14886         time: Add tests.
14887         * tests/test-time.c: New file.
14888         * modules/time-tests: New file.
14890         time: New module.
14891         * lib/time.in.h (time): New declaration.
14892         * lib/time.c: New file.
14893         * m4/time_h.m4 (gl_TIME_H_REQUIRE_DEFAULTS): Initialize GNULIB_TIME.
14894         (gl_TIME_H_DEFAULTS): Initialize REPLACE_TIME.
14895         * m4/time.m4: New file.
14896         * modules/time-h (Makefile.am): Substitute GNULIB_TIME, REPLACE_TIME.
14897         * modules/time: New file.
14898         * tests/test-time-h-c++.cc: Check the signature of
14899         GNULIB_NAMESPACE::time.
14900         * doc/posix-functions/time.texi: Mention the glibc problem and the
14901         'time' module.
14903 2023-03-08  Bruno Haible  <bruno@clisp.org>
14905         time-h: Renamed from time.
14906         * modules/time-h: Renamed from modules/time.
14907         * tests/test-time-h.c: Renamed from tests/test-time.c.
14908         * modules/time-h-tests: Renamed from modules/time-tests. Update.
14909         * tests/test-time-h-c++.cc: Renamed from tests/test-time-c++.cc.
14910         * tests/test-time-h-c++2.cc: Renamed from tests/test-time-c++2.cc.
14911         * modules/time-h-c++-tests: Renamed from modules/time-c++-tests. Update.
14912         * modules/cond (Depends-on): Update.
14913         * modules/ctime (Depends-on): Likewise.
14914         * modules/localtime (Depends-on): Likewise.
14915         * modules/mktime (Depends-on): Likewise.
14916         * modules/nanosleep (Depends-on): Likewise.
14917         * modules/parse-datetime (Depends-on): Likewise.
14918         * modules/posixcheck (Depends-on): Likewise.
14919         * modules/pthread-h (Depends-on): Likewise.
14920         * modules/stat-time (Depends-on): Likewise.
14921         * modules/stat-time-tests (Depends-on): Likewise.
14922         * modules/strftime-fixes (Depends-on): Likewise.
14923         * modules/strptime (Depends-on): Likewise.
14924         * modules/sys_stat (Depends-on): Likewise.
14925         * modules/tempname (Depends-on): Likewise.
14926         * modules/threads-h (Depends-on): Likewise.
14927         * modules/time_r (Depends-on): Likewise.
14928         * modules/time_rz (Depends-on): Likewise.
14929         * modules/timegm (Depends-on): Likewise.
14930         * modules/timespec (Depends-on): Likewise.
14931         * modules/timespec_get (Depends-on): Likewise.
14932         * modules/timespec_getres (Depends-on): Likewise.
14933         * modules/tzset (Depends-on): Likewise.
14934         * modules/usleep-tests (Depends-on): Likewise.
14935         * modules/utime (Depends-on): Likewise.
14936         * modules/utimecmp (Depends-on): Likewise.
14937         * modules/utimens (Depends-on): Likewise.
14938         * modules/windows-cond (Depends-on): Likewise.
14939         * modules/windows-timedmutex (Depends-on): Likewise.
14940         * modules/windows-timedrecmutex (Depends-on): Likewise.
14941         * modules/windows-timedrwlock (Depends-on): Likewise.
14942         * modules/xnanosleep (Depends-on): Likewise.
14943         * doc/posix-headers/time.texi: Update.
14944         * NEWS: Mention the change.
14946 2023-03-08  Bruno Haible  <bruno@clisp.org>
14948         gettimeofday tests: Enhance test.
14949         * tests/test-gettimeofday.c: Include <stdlib.h> and macros.h.
14950         (test_clobber): New function, extracted from main.
14951         (test_consistency): New function, based on tests/test-timespec_get.c.
14952         (main): Invoke both functions.
14953         * modules/gettimeofday-tests (Files): Add macros.h.
14955 2023-03-05  Paul Eggert  <eggert@cs.ucla.edu>
14957         stdio: suppress macOS 13 sprintf warnings
14958         * lib/stdio.in.h (_POSIX_C_SOURCE, _GL_DEFINED__POSIX_C_SOURCE):
14959         Suppress deprecation warnings for sprintf and vsprintf
14960         that were introduced in macOS 13.  These are not useful
14961         for Gnulib itself, and are more likely than not to be
14962         merely an annoyance for Gnulib-using code.
14964 2023-03-05  Bruno Haible  <bruno@clisp.org>
14966         timespec_get tests: Add comment.
14967         * tests/test-timespec_get.c: Add a comment regarding a glibc bug.
14969 2023-03-02  Bruno Haible  <bruno@clisp.org>
14971         nl_langinfo tests: Avoid test failure on Solaris 11.
14972         * tests/test-nl_langinfo2.c (main): Skip French T_FMT_AMPM test on
14973         Solaris.
14975 2023-02-28  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
14977         terminfo, termcap: Fix more spellos in a comment.
14978         * lib/tparm.c: Fix misspellings and wording in the main comment.
14980 2023-02-28  Bruno Haible  <bruno@clisp.org>
14982         perl: Allow this module to be used with 'gnulib-tool --lgpl'.
14983         Reported by Reuben Thomas <rrt@sc3d.org> in
14984         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00191.html>.
14985         * modules/perl (License): Relax to 'GPLed build tool'.
14986         Approved by Jim Meyering in
14987         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00198.html>.
14989 2023-02-28  Bruno Haible  <bruno@clisp.org>
14991         dfa: Tweak the last patch.
14992         Suggested by Alexei Podtelezhnikov <apodtele@gmail.com>.
14993         * lib/dfa.c (FALLTHROUGH): Assume that Apple clang, in C mode, supports
14994         __attribute__ ((__fallthrough__)) starting with version 1200.
14995         References:
14996         https://en.wikipedia.org/wiki/Xcode#Xcode_11.0_-_14.x_(since_SwiftUI_framework)_2
14997         https://github.com/apple/llvm-project/blob/swift-5.3-RELEASE/clang/test/Sema/fallthrough-attr.c
14999 2023-02-27  ChuanGang Jiang  <jiangchuanganghw@outlook.com>
15001         fts: fail gracefully when out of memory
15002         * lib/fts.c (fts_read): Set errno==ENOMEM and return NULL
15003         when setup_dir() fails, rather than hitting an assertion later.
15005 2023-02-26  Jim Meyering  <meyering@fb.com>
15007         announce-gen: spell OpenBSD with a capital "O"
15008         * build-aux/announce-gen (print_checksums): Capitalize
15009         the "O" in OpenBSD, as suggested by Bruno Haible.
15011 2023-02-26  Bruno Haible  <bruno@clisp.org>
15013         dfa: Avoid warnings with some Apple clang versions.
15014         Reported by Werner Lemberg <wl@gnu.org> in
15015         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00159.html>.
15016         * lib/dfa.c (FALLTHROUGH): When __apple_build_version__ is defined,
15017         ignore __clang_major__.
15019 2023-02-25  Jim Meyering  <meyering@fb.com>
15021         announce-gen: add more info the auto-generated announce template
15022         * build-aux/announce-gen (readable_interval, readable_interval0):
15023         New functions.
15024         (digest_file_base64_wrap): New function to add padding to the
15025         base64-encoded SHA256 checksums.
15026         (print_checksums): Use that wrapper. Indent each line by two spaces.
15027         (main): Emit new sections, e.g., these lines from grep-3.8's release:
15028         - There have been 104 commits by 6 people in the 55 weeks since 3.7.
15029         - The following people contributed changes to this release: (and list)
15030         I tested with this, running from a sibling cloned grep directory:
15031           ../gnulib/build-aux/announce-gen --release-type=stable \
15032             --package-name=grep --previous-version=3.7 --current-version=3.8 \
15033             --gpg-key-id=0x7FD9FCCB000BEEEE --url-directory=https://testing
15034         Also, reference the cksum programs from coreutils-9.2 and from OpenBSD.
15036 2023-02-25  ChuanGang Jiang  <jiangchuanganghw@outlook.com>  (tiny change)
15038         terminfo, termcap: Fix typos in comments.
15039         * lib/tparm.c: Fix misspellings in comments.
15041 2023-02-23  Paul Eggert  <eggert@cs.ucla.edu>
15043         lseek: avoid SEEK_HOLE bugs in FreeBSD, macOS
15044         This attempts to fix <https://bugs.gnu.org/61386>, a bug in GNU cp
15045         caused by a serious data corruption bug in FreeBSD and macOS.
15046         * doc/posix-functions/lseek.texi: Mention the bug.
15047         * lib/unistd.in.h (SEEK_DATA, SEEK_HOLE): Undef in macOS < 13 and
15048         FreeBSD < 14.  FreeBSD fixed the bug sometime during FreeBSD 13
15049         <https://bugs.freebsd.org/256205>, so the "FreeBSD < 14" is
15050         conservative.  It’s unknown when Apple will fix macOS so use
15051         macOS "9999" as a placeholder.
15052         * m4/lseek.m4 (gl_FUNC_LSEEK): Replace lseek if on one of the
15053         above platforms.
15055 2023-02-18  Bruno Haible  <bruno@clisp.org>
15057         configmake: Add support for $build_os != $host_os.
15058         * m4/build-to-host.m4: New file.
15059         * m4/configmake.m4 (gl_CONFIGMAKE_PREP): Provide a configure-time
15060         definition for pkgdatadir, pkgincludedir, pkglibdir.
15061         (gl_CONFIGMAKE): New macro.
15062         * modules/configmake (Files): Add m4/build-to-host.m4.
15063         (configure.ac): Invoke gl_CONFIGMAKE instead of gl_CONFIGMAKE_PREP.
15064         (Makefile.am): For creating configmake.h, use the various *prefix_c_make
15065         and *dir_c_make variables.
15067 2023-02-18  Bruno Haible  <bruno@clisp.org>
15069         configmake: Prepare for using directory names with backslashes.
15070         * modules/configmake (Makefile.am): Use printf instead of echo.
15072 2023-02-18  Bruno Haible  <bruno@clisp.org>
15074         unilbrk tests: Fix compilation failures (regression 2023-02-11).
15075         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Outside of
15076         libunistring, don't test the backward compatibility function.
15077         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
15078         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
15079         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
15080         * tests/unilbrk/test-u8-width-linebreaks.c (main): Likewise.
15081         * tests/unilbrk/test-u16-width-linebreaks.c (main): Likewise.
15082         * tests/unilbrk/test-u32-width-linebreaks.c (main): Likewise.
15083         * tests/unilbrk/test-ulc-width-linebreaks.c (main): Likewise.
15085 2023-02-17  Bruno Haible  <bruno@clisp.org>
15087         Improve cross-compilation for midipix.
15088         Reported by Ørjan Malde <red@foxi.me> at
15089         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00131.html>.
15090         This patch handles the cases where midipix acts like Linux.
15091         * m4/chmod.m4 (gl_FUNC_CHMOD): Treat midipix like Linux with glibc or
15092         musl libc.
15093         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
15094         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
15095         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
15096         * m4/link.m4 (gl_FUNC_LINK): Likewise.
15097         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
15098         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
15099         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
15100         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
15101         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Likewise.
15102         * m4/readlink.m4 (gl_FUNC_READLINK): Likewise.
15103         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
15104         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
15105         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
15106         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
15107         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
15108         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
15109         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
15110         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
15111         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
15113         Improve cross-compilation for midipix.
15114         Reported by Ørjan Malde <red@foxi.me> at
15115         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00131.html>.
15116         Since midipix consists of musl libc based on an emulation of Linux system
15117         calls, for pure libc functionality it can be treated like musl libc.
15118         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Treat midipix like systems with
15119         musl libc.
15120         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Likewise.
15121         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
15122         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
15123         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
15124         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
15125         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
15126         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
15127         * m4/expm1f.m4 (gl_FUNC_EXPM1F): Likewise.
15128         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Likewise.
15129         * m4/fclose.m4 (gl_FUNC_FCLOSE_STDIN): Likewise.
15130         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Likewise.
15131         * m4/ffsll.m4 (gl_FUNC_FFSLL): Likewise.
15132         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
15133         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
15134         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
15135         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
15136         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
15137         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
15138         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): Likewise.
15139         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
15140         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
15141         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
15142         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
15143         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
15144         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
15145         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): Likewise.
15146         * m4/log.m4 (gl_FUNC_LOG): Likewise.
15147         * m4/log10.m4 (gl_FUNC_LOG10): Likewise.
15148         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
15149         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Likewise.
15150         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
15151         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Likewise.
15152         * m4/log1pl.m4 (gl_FUNC_LOG1PL, gl_FUNC_LOG1PL_WORKS): Likewise.
15153         * m4/log2.m4 (gl_FUNC_LOG2): Likewise.
15154         * m4/log2f.m4 (gl_FUNC_LOG2F): Likewise.
15155         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Likewise.
15156         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
15157         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
15158         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Likewise.
15159         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
15160         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
15161         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
15162         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
15163         * m4/musl.m4 (gl_MUSL_LIBC): Likewise.
15164         * m4/perror.m4 (gl_FUNC_PERROR): Likewise.
15165         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_SECURE,
15166         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE,
15167         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2,
15168         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): Likewise.
15169         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_INFINITE,
15170         gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_A,
15171         gl_PRINTF_DIRECTIVE_F, gl_PRINTF_FLAG_ZERO, gl_SNPRINTF_TRUNCATION_C99,
15172         gl_SNPRINTF_RETVAL_C99, gl_SNPRINTF_DIRECTIVE_N,
15173         gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
15174         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
15175         Likewise.
15176         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
15177         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
15178         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
15179         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
15180         * m4/remainderl.m4 (gl_FUNC_REMAINDERL, gl_FUNC_REMAINDERL_WORKS):
15181         Likewise.
15182         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
15183         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
15184         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
15185         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
15186         * m4/setenv.m4 (gl_FUNC_SETENV): Likewise.
15187         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Likewise.
15188         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
15189         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
15190         * m4/strerror.m4 (gl_FUNC_STRERROR, gl_FUNC_STRERROR_0): Likewise.
15191         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
15192         * m4/strtold.m4 (gl_FUNC_STRTOLD): Likewise.
15193         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
15194         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
15195         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
15196         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
15197         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
15199 2023-02-13  ChuanGang Jiang  <jiangchuanganghw@outlook.com>  (tiny change)
15201         hamt: Detect GCC version correctly.
15202         * lib/hamt.h:Use __GNUC_MINOR__, not  __GNUC_MINOR.
15204 2023-02-11  Bruno Haible  <bruno@clisp.org>
15206         terminfo, termcap: Avoid wrong configure result with clang ≥ 15.
15207         clang 15 reports an error for -Wint-conversion by default.
15208         Reported by Sam James <sam@gentoo.org> in
15209         <https://savannah.gnu.org/bugs/?63793>.
15210         * m4/terminfo.m4 (gl_TERMINFO_BODY): Avoid a -Wint-conversion warning
15211         when testing for tparam and tparm.
15212         * m4/termcap.m4 (gl_TERMCAP_BODY): Likewise.
15214 2023-02-11  Bruno Haible  <bruno@clisp.org>
15216         error-h: Make less fragile.
15217         * lib/error.in.h: Use #include_next if the system has an <error.h>. Use
15218         a split double-inclusion guard.
15219         * m4/error_h.m4 (gl_ERROR_H): Invoke gl_CHECK_NEXT_HEADERS. Set
15220         HAVE_ERROR_H.
15221         * modules/error-h (Makefile.am): Substitute GUARD_PREFIX, HAVE_ERROR_H,
15222         INCLUDE_NEXT, PRAGMA_SYSTEM_HEADER, NEXT_ERROR_H.
15224 2023-02-11  Bruno Haible  <bruno@clisp.org>
15226         unilbrk: Don't compile unused functions outside of libunistring.
15227         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Don't
15228         compile outside of libunistring.
15229         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
15230         Likewise.
15231         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
15232         Likewise.
15233         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
15234         Likewise.
15235         * lib/unilbrk/u8-width-linebreaks.c (u8_width_linebreaks): Likewise.
15236         * lib/unilbrk/u16-width-linebreaks.c (u16_width_linebreaks): Likewise.
15237         * lib/unilbrk/u32-width-linebreaks.c (u32_width_linebreaks): Likewise.
15238         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Likewise.
15240 2023-02-11  Bruno Haible  <bruno@clisp.org>
15242         sigsegv: Fix a compilation error on OpenBSD with clang ≥ 16.
15243         * lib/sigsegv.c (install_for): Add a cast when assigning to
15244         action.sa_sigaction.
15246 2023-02-10  Bruno Haible  <bruno@clisp.org>
15248         Fix code duplication in last commit.
15249         * m4/gnulib-common.m4 (gl_CHECK_FUNCS_DEFAULT_CASE,
15250         gl_CHECK_FUNCS_CASE_FOR_ANDROID, gl_CHECK_FUNCS_CASE_FOR_MACOS,
15251         gl_CHECK_FUNCS_SET_RESULTS): New macros, extracted from
15252         gl_CHECK_FUNCS_ANDROID, gl_CHECK_FUNCS_MACOS,
15253         gl_CHECK_FUNCS_ANDROID_MACOS.
15254         (gl_CHECK_FUNCS_ANDROID, gl_CHECK_FUNCS_MACOS,
15255         gl_CHECK_FUNCS_ANDROID_MACOS): Use them.
15257         mkfifoat: Fix crash on macOS 12.
15258         * m4/gnulib-common.m4 (gl_PREPARE_CHECK_FUNCS_MACOS,
15259         gl_CHECK_FUNCS_MACOS, gl_CHECK_FUNCS_ANDROID_MACOS): New macros.
15260         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Test for mknodat and mkfifoat using
15261         gl_CHECK_FUNCS_ANDROID_MACOS instead of gl_CHECK_FUNCS_ANDROID.
15263 2023-02-10  ChuanGang Jiang  <jiangchuanganghw@outlook.com>  (tiny change)
15265         Fix typos like "the the" and "a a" in comments.
15266         * lib/c32is-impl.h: s/the the/the/
15267         * lib/getopt-pfx-core.h: s/a a/a/
15268         * lib/term-style-control.h: s/the the/the/
15269         * lib/textstyle.in.h: Likewise.
15271 2023-02-10  Bruno Haible  <bruno@clisp.org>
15273         chown, lchown, fchownat tests: Avoid test failure on macOS 12.
15274         * tests/test-chown.h (test_chown): Skip some assertions if
15275         getgid() == (gid_t)-1.
15276         * tests/test-lchown.h (test_lchown): Likewise.
15278 2023-02-09  Paul Eggert  <eggert@cs.ucla.edu>
15280         nullptr: work around Apple clang 14 issue
15281         Problem reported by Bruno Haible in:
15282         https://lists.gnu.org/r/bug-gnulib/2023-02/msg00098.html
15283         * doc/gnulib.texi (nullptr): Document limitations better.
15284         * m4/nullptr.m4 (gl_NULLPTR): Check for incompatibility of macOS
15285         clang 14.0.0 (clang-1400.0.29.202), where <stddef.h> defines a
15286         non-working nullptr macro.
15288 2023-02-09  Bruno Haible  <bruno@clisp.org>
15290         math: Fix compilation error in C++ mode on macOS 12.5.
15291         * lib/math.in.h (isnan): On macOS, treat clang version 14 again like
15292         clang versions < 12.
15294 2023-02-09  Bruno Haible  <bruno@clisp.org>
15296         Fix compilation errors in C++ mode on macOS 12.5.
15297         * m4/gnulib-common.m4 (gl_COMMON_BODY): Don't define
15298         _GL_ATTRIBUTE_MAYBE_UNUSED to [[__maybe_unused__]] if the compiler is
15299         an Apple variant of clang.
15301 2023-02-09  Bruno Haible  <bruno@clisp.org>
15303         limits-h: Work around a clang 15 bug.
15304         * m4/limits-h.m4 (gl_LIMITS_H): Test also for BOOL_MAX.
15305         * lib/limits.in.h: Handle the case where BOOL_WIDTH is present and
15306         BOOL_MAX is missing.
15307         * doc/posix-headers/limits.texi: Mention the clang bug.
15309 2023-02-09  Bruno Haible  <bruno@clisp.org>
15311         Fix error in C++ mode on glibc systems (regression 2022-04-28).
15312         * lib/malloc.in.h (rpl_free): Add exception specification like
15313         stdlib.in.h does.
15314         * lib/string.in.h (rpl_free): Likewise.
15315         * lib/wchar.in.h (rpl_free): Likewise.
15317 2023-02-09  Bruno Haible  <bruno@clisp.org>
15319         getcwd: Fix compilation error in C23 mode.
15320         * lib/getcwd.c: Include <stdio.h>.
15322 2023-02-08  Bruno Haible  <bruno@clisp.org>
15324         x-to-1: Accept additional help2man arguments.
15325         Suggested by Reuben Thomas <rrt@sc3d.org> in
15326         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00078.html>.
15327         * build-aux/x-to-1.in: Allow additional options after the HELP2MAN
15328         argument, and pass them down to help2man.
15330 2023-02-08  Bruno Haible  <bruno@clisp.org>
15332         x-to-1: Document the configure-time prerequisites.
15333         Suggested by Reuben Thomas <rrt@sc3d.org> in
15334         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00078.html>.
15335         * build-aux/x-to-1.in: Add more comments.
15337 2023-02-08  Bruno Haible  <bruno@clisp.org>
15339         hard-locale: Add comment regarding per-thread locales.
15340         * lib/hard-locale.h (hard_locale): Add comment.
15342 2023-02-08  Bruno Haible  <bruno@clisp.org>
15344         nl_langinfo: Add comment regarding per-thread locales.
15345         * lib/nl_langinfo.c (ctype_codeset): Add comment.
15347         nl_langinfo tests: Add another test.
15348         * tests/test-nl_langinfo2.c: New file.
15349         * tests/test-nl_langinfo2.sh: New file.
15350         * modules/nl_langinfo-tests (Files): Add them. Add
15351         intl-thread-locale.m4.
15352         (Depends-on): Add c-strcasestr, stdbool.
15353         (configure.ac): Invoke gt_FUNC_USELOCALE.
15354         (Makefile.am): Arrange to compile test-nl_langinfo2 and test it through
15355         test-nl_langinfo2.sh.
15357         nl_langinfo tests: Prepare for adding more tests.
15358         * tests/test-nl_langinfo1.c: Renamed from tests/test-nl_langinfo.c.
15359         * tests/test-nl_langinfo1.sh: Renamed from tests/test-nl_langinfo.sh.
15360         Update.
15361         * modules/nl_langinfo-tests (Files, Makefile.am): Update.
15363 2023-02-08  Bruno Haible  <bruno@clisp.org>
15365         assert-h: Fix test failure on IRIX 6.5.
15366         * m4/assert_h.m4 (gl_ASSERT_H): Ensure that on IRIX, including
15367         <assert.h> after <config.h> actually defines the assert macro.
15369 2023-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15371         nullptr: test for compilers at autoconf-time
15372         * m4/nullptr.m4 (gl_NULLPTR): Test for C and C++ compiler usage at
15373         autoconf-time.  This should work better than testing at
15374         configure-time.  Also, push and pop languages so we check the
15375         proper compiler.
15377         nullptr: test for C++ nullptr at configure-time
15378         * m4/nullptr.m4 (gl_NULLPTR): Test for C++ support for nullptr
15379         at configure-time, as we already do for C support.
15380         This should be more reliable than maintaining #ifdefs by hand.
15382         nullptr: rename from c-nullptr
15383         * NEWS, doc/gnulib.texi: Mention this.
15384         * m4/nullptr.m4: Rename from m4/c-nullptr.m4.
15385         (gl_NULLPTR): Rename from gl_C_NULLPTR.
15386         * modules/nullptr: Rename from modules/nullptr.
15387         * modules/nullptr-c++-tests: Rename from modules/c-nullptr-c++-tests.
15388         * modules/nullptr-tests: Rename from modules/c-nullptr-tests.
15389         All uses changed.
15391 2023-02-07  Bruno Haible  <bruno@clisp.org>
15393         Fix a copyright header - module license mismatch.
15394         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
15395         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00057.html>.
15396         * lib/gen-uni-tables.c (output_predicate): For uniwidth/width2.h, use an
15397         LGPLv2+ license.
15398         (output_nonspacing_property): Use an LGPLv2+ license.
15399         * lib/uniwidth/width0.h: Regenerated.
15400         * lib/uniwidth/width2.h: Likewise.
15402 2023-02-07  Bruno Haible  <bruno@clisp.org>
15404         check-copyright: Don't fail because of the 'glob' module.
15405         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
15406         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00057.html>.
15407         * check-copyright: Filter out the files from the 'glob' module.
15409 2023-02-07  Bruno Haible  <bruno@clisp.org>
15411         check-copyright: Make output prettier.
15412         * check-copyright: Resize the second column from width 14 to width 17.
15414 2023-02-06  Bruno Haible  <bruno@clisp.org>
15416         setlocale-null: Don't use a lock in Cygwin >= 3.4.6.
15417         Road paved by Corinna Vinschen <vinschen@redhat.com>.
15418         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Assume that
15419         setlocale (LC_ALL, NULL) is multithread-safe in Cygwin >= 3.4.6.
15420         * lib/setlocale_null.c: Update comments.
15421         * tests/test-setlocale_null-mt-all.c: Likewise.
15423 2023-02-05  Bruno Haible  <bruno@clisp.org>
15425         c-nullptr: Fix conflict with libstdc++ in GCC >= 11.
15426         Reported by Bjarni Ingi Gislason <bjarniig@simnet.is> in
15427         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00030.html>.
15428         * m4/c-nullptr.m4 (gl_C_NULLPTR): Don't define nullptr if it is already
15429         defined. In C++ mode, ignore the result of the configure test and don't
15430         define it when we know that the C++ compiler already supports it.
15432 2023-02-05  Bruno Haible  <bruno@clisp.org>
15434         c-nullptr: Add tests.
15435         * tests/test-nullptr.c: New file.
15436         * modules/c-nullptr-tests: New file.
15437         * tests/test-nullptr-c++.cc: New file.
15438         * modules/c-nullptr-c++-tests: New file.
15440 2023-02-05  Paul Eggert  <eggert@cs.ucla.edu>
15442         sh-quote: backport fix from diffutils
15443         * lib/sh-quote.c (init_sh_quoting_options):
15444         Use C89 through C17 style for parameterless static function.
15445         This avoided a warning when compiling diffutils.
15446         This patch is backported from a circa-2009 diffutils patch
15447         and lets us remove diffutils/gl/lib/sh-quote.c.diff; see:
15448         https://git.savannah.gnu.org/cgit/diffutils.git/commit/?id=8c3d25a63a2c5912170ef6e13f748f3904e6b5cf
15450         c-nullptr: new module
15451         * doc/gnulib.texi (nullptr): New section.
15452         * doc/posix-headers/stddef.texi: Document lack of nullptr_t.
15453         * m4/c-nullptr.m4, modules/c-nullptr: New files.
15455 2023-02-05  Bruno Haible  <bruno@clisp.org>
15457         Update build-aux/po/Makefile.in.in.
15458         Reported by Reuben Thomas <rrt@sc3d.org> in
15459         <https://lists.gnu.org/archive/html/bug-gnulib/2023-02/msg00020.html>.
15460         * build-aux/po/Makefile.in.in: Sync from GNU gettext 0.21.1.
15461         Fixes:
15462         - In the .po -> .gmo rules, consider the newest changes to the POT file.
15463         - Emit a warning when creating a tarball without POT file.
15465 2023-02-05  Bruno Haible  <bruno@clisp.org>
15467         assert-h, verify: Fix compilation error in C++ mode with MSVC 14.
15468         * lib/verify.h (static_assert): Define _ALLOW_KEYWORD_MACROS.
15469         * tests/test-assert-h-c++.cc: Strengthen test.
15470         * tests/test-assert-h-c++2.cc: Likewise.
15472 2023-02-04  Paul Eggert  <eggert@cs.ucla.edu>
15474         fts: pacify GCC 13 -Wuse-after-free
15475         Ordinarily I fix this sort of thing by using well-defined rather
15476         than undefined behavior, but a straightforward patch along those
15477         lines would change the fts_.h API since fts_accpath would change
15478         from a pointer to an integer with a more-complex interpretation.
15479         Instead, attempt to pacify GCC 13 with code that relies on
15480         undefined but portable-in-practice behavior that GCC 13 does not
15481         complain about.  GCC problem reported by Peter Frazier in:
15482         https://lists.gnu.org/r/bug-gnulib/2023-02/msg00000.html
15483         * lib/fts.c: Include stdint.h.
15484         (fts_build): Do not access freed pointer directly; instead,
15485         save its bit-pattern into a uintptr_t, and use that to compare.
15486         (ADJUST): Likewise, but more trickily since this hack
15487         actually accesses freed pointers, but does so in a way that
15488         I hope GCC doesn’t notice.  Although using ‘*(uintptr_t *) &P’
15489         instead of ‘(uintptr_t) P’ would avoid accessing freed pointers,
15490         it would provoke a -Wstrict-aliasing diagnostic.
15491         * modules/fts (Depends-on): Add stdint.
15493 2023-02-04  Bruno Haible  <bruno@clisp.org>
15495         assert-h, verify: Fix conflict with standard C++ header files on macOS.
15496         * lib/verify.h (_Static_assert): Don't redefine with clang ≥ 3.8.0
15497         in C++ mode.
15498         * tests/test-assert-h-c++.cc: Also check against conflict with the
15499         standard C++ header files.
15500         * tests/test-assert-h-c++2.cc: Likewise.
15502 2023-02-04  Bruno Haible  <bruno@clisp.org>
15504         Activate all existing C++ tests.
15505         * modules/assert-h-tests (Depends-on): Add assert-h-c++-tests.
15506         * modules/stdarg-tests (Depends-on): Add stdarg-c++-tests.
15508 2023-02-04  Bruno Haible  <bruno@clisp.org>
15510         spawn: Fix compilation error on macOS (regression 2023-01-22).
15511         * lib/spawn.in.h: Tweak logic for defining the POSIX_SPAWN_* constants.
15513 2023-02-03  Bruno Haible  <bruno@clisp.org>
15515         relocatable-prog: Fix compiler warning.
15516         * lib/progreloc.c (full_read): Use a non-const pointer.
15518 2023-02-03  Bruno Haible  <bruno@clisp.org>
15520         doc: Update regarding AIX.
15521         * doc/glibc-headers/getopt.texi: Update.
15523 2023-02-03  Bruno Haible  <bruno@clisp.org>
15525         doc: Update regarding NetBSD.
15526         * doc/posix-functions/sigprocmask.texi: Mention a NetBSD 9.0 bug.
15527         * doc/posix-functions/pthread_sigmask.texi: Likewise.
15529 2023-02-03  Paul Eggert  <eggert@cs.ucla.edu>
15531         isnan: update comment
15532         * lib/isnan.c: Update comment for C23.
15534 2023-01-30  Bruno Haible  <bruno@clisp.org>
15536         at-internal: Fix support for z/OS.
15537         * lib/openat-proc.c (openat_proc_name) [z/OS]: Proper error handling.
15538         Convert only the relevant part of the dir[] buffer.
15540         at-internal: Add support for z/OS.
15541         Reported and draft patch by Igor Todorovski <itodorov@ca.ibm.com>.
15542         * lib/openat-proc.c [z/OS]: Include <termios.h>.
15543         (openat_proc_name): For z/OS, use an approach similar to kLIBC, with
15544         3 lines of z/OS specific code by Igor Todorovski <itodorov@ca.ibm.com>.
15546 2023-01-30  Bruno Haible  <bruno@clisp.org>
15548         Update NEWS.
15549         * NEWS: Update for qcopy-acl change on 2023-01-13.
15551 2023-01-29  Bruno Haible  <bruno@clisp.org>
15553         maintainer-makefile: Determine gnulib's location on disk correctly.
15554         * top/maint.mk (gnulib_dir): Give priority to $(GNULIB_SRCDIR) over
15555         $(srcdir)/gnulib.
15557 2023-01-29  Bruno Haible  <bruno@clisp.org>
15559         Fix compilation errors with CC="clang -D_FORTIFY_SOURCE=2" on Android.
15560         Reported by Alexey Rochev <equeim@gmail.com> in
15561         <https://lists.gnu.org/archive/html/bug-gnu-libiconv/2023-01/msg00019.html>.
15562         * lib/cdefs.h (__bos, __bos0, __glibc_objsize0, __glibc_objsize,
15563         __glibc_safe_len_cond, __glibc_unsigned_or_positive,
15564         __glibc_safe_or_unknown_len, __glibc_unsafe_len, __glibc_fortify,
15565         __glibc_fortify_n): Don't define these macros in Gnulib.
15566         * lib/libc-config.h: Don't undefine these macros in Gnulib.
15568 2023-01-28  Bruno Haible  <bruno@clisp.org>
15570         Clarify _GL_ATTRIBUTE_NODISCARD code.
15571         Reported by Paul Eggert.
15572         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add comment regarding
15573         _GL_ATTRIBUTE_NODISCARD definition.
15575 2023-01-28  Bruno Haible  <bruno@clisp.org>
15577         unistdio/*printf: Fix negative width handling for %U, %lU, %llU.
15578         * lib/vasnprintf.c (VASNPRINTF): In the code for %U, %lU, %llU, test for
15579         the FLAG_LEFT bit in the flags variable.
15580         * tests/unistdio/test-u8-printf1.h (test_xfunction): Add tests for width
15581         given as argument for the directives %U, %lU, %llU, %s, %a, %f, %e, %g.
15582         * tests/unistdio/test-u16-printf1.h (test_xfunction): Likewise.
15583         * tests/unistdio/test-u32-printf1.h (test_xfunction): Likewise.
15584         * tests/unistdio/test-ulc-printf1.h (test_xfunction): Likewise.
15586 2023-01-28  Bruno Haible  <bruno@clisp.org>
15588         vasnprintf-posix: Fix possible bug with negative width handling for %lc.
15589         * lib/vasnprintf.c (VASNPRINTF): In the code for %lc in vasnprintf, test
15590         for the FLAG_LEFT bit in the flags variable.
15591         * tests/test-vasnprintf-posix.c (test_function): Add tests for width
15592         given as argument for the directives %c, %lc.
15593         * tests/test-vasprintf-posix.c (test_function): Likewise.
15594         * tests/test-snprintf-posix.h (test_function): Likewise.
15595         * tests/test-sprintf-posix.h (test_function): Likewise.
15596         * tests/test-snprintf-posix.c: Include <wchar.h>, for wint_t.
15597         * tests/test-sprintf-posix.c: Likewise.
15598         * tests/test-vsnprintf-posix.c: Likewise.
15599         * tests/test-vsprintf-posix.c: Likewise.
15601 2023-01-28  Bruno Haible  <bruno@clisp.org>
15603         vasnprintf-posix: Fix negative width handling for %ls directive.
15604         Reported by clang via Po Lu <luangruo@yahoo.com>.
15605         * lib/vasnprintf.c (VASNPRINTF): In the code for %ls in vasnprintf and
15606         for %s in vasnwprintf, test for the FLAG_LEFT bit in the flags variable.
15607         * tests/test-vasnprintf-posix.c (test_function): Add tests for width
15608         given as argument for the directives %s, %ls.
15609         * tests/test-vasprintf-posix.c (test_function): Likewise.
15610         * tests/test-snprintf-posix.h (test_function): Likewise.
15611         * tests/test-sprintf-posix.h (test_function): Likewise.
15613 2023-01-28  Bruno Haible  <bruno@clisp.org>
15615         vasnprintf-posix: Add more unit tests.
15616         * tests/test-vasnprintf-posix.c (test_function): Add tests for width
15617         given as argument for the directives %a, %f, %e, %g.
15618         * tests/test-vasprintf-posix.c (test_function): Likewise.
15619         * tests/test-snprintf-posix.h (test_function): Likewise.
15620         * tests/test-sprintf-posix.h (test_function): Likewise.
15622 2023-01-28  Bruno Haible  <bruno@clisp.org>
15624         Avoid clang warnings regarding [[__nodiscard__]].
15625         * m4/gnulib-common.m4 (gl_COMMON_BODY): For clang, in C++ mode, ignore
15626         the __has_c_attribute value and define _GL_ATTRIBUTE_NODISCARD to
15627         __attribute__ ((__warn_unused_result__)), not [[__nodiscard__]].
15629 2023-01-28  Bruno Haible  <bruno@clisp.org>
15631         Avoid clang warnings regarding [[__maybe_unused__]].
15632         * m4/gnulib-common.m4 (gl_COMMON_BODY): For clang versions ≥ 6, < 10,
15633         in C++ mode, ignore the __has_c_attribute value and define
15634         _GL_ATTRIBUTE_MAYBE_UNUSED to __attribute__ ((__unused__)), not
15635         [[__maybe_unused__]].
15637 2023-01-27  Bruno Haible  <bruno@clisp.org>
15639         alignasof: Ensure a correct _Alignof (regression 2023-01-15).
15640         * m4/stdalign.m4 (gl_ALIGNASOF): Apply the workaround for wrong _Alignof
15641         in GCC < 4.9 and clang < 8.0.0 also when the system has <stdalign.h>.
15643 2023-01-27  Bruno Haible  <bruno@clisp.org>
15645         stdalign: Ensure alignof is defined on FreeBSD (regression 2023-01-15).
15646         * lib/stdalign.in.h: Include the system's <stdalign.h> when it exists.
15647         * m4/stdalign.m4 (gl_ALIGNASOF): Invoke gl_CHECK_NEXT_HEADERS. Set
15648         HAVE_STDALIGN_H.
15649         * modules/stdalign (Makefile.am): Substitute GUARD_PREFIX,
15650         HAVE_STDALIGN_H, INCLUDE_NEXT, PRAGMA_SYSTEM_HEADER, PRAGMA_COLUMNS,
15651         NEXT_STDALIGN_H.
15653 2023-01-27  Bruno Haible  <bruno@clisp.org>
15655         stddef: Fix test-stddef compilation error on FreeBSD 12/x86.
15656         * m4/stddef_h.m4 (gl_STDDEF_H): When testing for good max_align_t, use
15657         an ISO C compliant definition of _Alignof.
15659 2023-01-25  Bruno Haible  <bruno@clisp.org>
15661         Keep config.h idempotent.
15662         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add double-inclusion guards to
15663         the definitions of the macros _GL_ATTRIBUTE_ALLOC_SIZE,
15664         _GL_ATTRIBUTE_ALWAYS_INLINE, _GL_ATTRIBUTE_ARTIFICIAL,
15665         _GL_ATTRIBUTE_COLD, _GL_ATTRIBUTE_CONST, _GL_ATTRIBUTE_DEALLOC,
15666         _GL_ATTRIBUTE_DEPRECATED, _GL_ATTRIBUTE_ERROR, _GL_ATTRIBUTE_WARNING,
15667         _GL_ATTRIBUTE_EXTERNALLY_VISIBLE, _GL_ATTRIBUTE_FALLTHROUGH,
15668         _GL_ATTRIBUTE_FORMAT, _GL_ATTRIBUTE_LEAF, _GL_ATTRIBUTE_MALLOC,
15669         _GL_ATTRIBUTE_MAY_ALIAS, _GL_ATTRIBUTE_MAYBE_UNUSED,
15670         _GL_ATTRIBUTE_NODISCARD, _GL_ATTRIBUTE_NOINLINE, _GL_ATTRIBUTE_NONNULL,
15671         _GL_ATTRIBUTE_NONSTRING, _GL_ATTRIBUTE_NOTHROW, _GL_ATTRIBUTE_PACKED,
15672         _GL_ATTRIBUTE_PURE, _GL_ATTRIBUTE_RETURNS_NONNULL,
15673         _GL_ATTRIBUTE_SENTINEL, _GL_ATTRIBUTE_UNUSED, _GL_UNUSED_LABEL.
15675 2023-01-25  Bruno Haible  <bruno@clisp.org>
15677         vasnprintf: Fix compilation error on Android NDK r26b.
15678         Reported by Po Lu <luangruo@yahoo.com>.
15679         * lib/vasnprintf.c: Include <wchar.h>.
15681 2023-01-25  Nick Bowler  <nbowler@draconx.ca>  (tiny change)
15683         threadlib: Fix support for Solaris 9 and older.
15684         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): Allow case patterns to survive
15685         m4 processing by using changequote.
15687 2023-01-24  Bruno Haible  <bruno@clisp.org>
15689         alignasof, stdalign: Fix a compilation error on FreeBSD 12.0.
15690         * m4/stdalign.m4 (gl_ALIGNASOF): In C mode, prefer __builtin_offsetof
15691         over offsetof when possible, since __builtin_offsetof works also when
15692         <stddef.h> has not been fully included yet.
15694 2023-01-22  Bruno Haible  <bruno@clisp.org>
15696         doc: Update list of target platforms.
15697         * doc/gnulib-intro.texi (Supported Platforms): Mark musl libc, Android,
15698         and MSVC as "occasionally tested". Update the version numbers of some
15699         OSes. Combine paragraphs regarding mingw and MSVC.
15700         (Formerly Supported Platforms): Mark AIX 5, 6 as "formerly supported".
15702 2023-01-22  Bruno Haible  <bruno@clisp.org>
15704         Resolve conflicts for functions introduced in Android API level 29.
15706         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY): Conditionally set
15707         REPLACE_REALLOCARRAY.
15708         * lib/stdlib.in.h (reallocarray): Disable _GL_CXXALIASWARN invocation on
15709         non-glibc systems.
15711         * lib/stdlib.in.h (getloadavg): Consider REPLACE_GETLOADAVG. Disable
15712         _GL_CXXALIASWARN invocation on non-glibc systems.
15713         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_GETLOADAVG.
15714         * modules/stdlib (Makefile.am): Substitute REPLACE_GETLOADAVG.
15715         * m4/getloadavg.m4 (gl_GETLOADAVG): Conditionally set
15716         REPLACE_GETLOADAVG.
15717         * modules/getloadavg (Depends-on, configure.ac): Consider
15718         REPLACE_GETLOADAVG.
15720         * lib/time.in.h (timespec_get): Consider REPLACE_TIMESPEC_GET. Disable
15721         _GL_CXXALIASWARN invocation on non-glibc systems.
15722         * m4/time_h.m4 (gl_TIME_H_DEFAULTS): Initialize REPLACE_TIMESPEC_GET.
15723         * modules/time (Makefile.am): Substitute REPLACE_TIMESPEC_GET.
15724         * m4/gettime.m4 (gl_CHECK_FUNC_TIMESPEC_GET): Set also
15725         gl_cv_onwards_func_timespec_get.
15726         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET): Conditionally set
15727         REPLACE_TIMESPEC_GET.
15728         * modules/timespec_get (Depends-on, configure.ac): Consider
15729         REPLACE_TIMESPEC_GET.
15731 2023-01-22  Bruno Haible  <bruno@clisp.org>
15733         Resolve conflicts for functions introduced in Android API level 28.
15735         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Conditionally set
15736         REPLACE_ALIGNED_ALLOC.
15737         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Conditionally set
15738         REPLACE_GETRANDOM.
15740         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Conditionally set
15741         REPLACE_GETLOGIN_R.
15742         * lib/unistd.in.h (getlogin_r): Disable _GL_CXXALIASWARN invocation on
15743         non-glibc systems.
15745         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): Conditionally set
15746         REPLACE_POSIX_SPAWN.
15747         * lib/spawn.in.h: Adapt logic for defining the POSIX_SPAWN_* constants.
15748         (posix_spawn, posix_spawnp, posix_spawnattr_init,
15749         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
15750         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
15751         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
15752         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
15753         posix_spawnattr_setpgroup, posix_spawn_file_actions_init,
15754         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addchdir,
15755         posix_spawn_file_actions_addfchdir): Disable _GL_CXXALIASWARN invocation
15756         on non-glibc systems.
15758         * m4/glob.m4 (gl_GLOB): Conditionally set REPLACE_GLOB.
15759         * lib/glob.in.h (glob): Disable _GL_CXXALIASWARN invocation on non-glibc
15760         systems.
15762         * lib/unistd.in.h (getentropy): Consider REPLACE_GETENTROPY. Disable
15763         _GL_CXXALIASWARN invocation on non-glibc systems.
15764         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_GETENTROPY.
15765         * modules/unistd (Makefile.am): Substitute REPLACE_GETENTROPY.
15766         * m4/getentropy.m4 (gl_FUNC_GETENTROPY): Conditionally set
15767         REPLACE_GETENTROPY.
15768         * modules/getentropy (Depends-on, configure.ac): Consider
15769         REPLACE_GETENTROPY.
15771 2023-01-22  Bruno Haible  <bruno@clisp.org>
15773         Resolve conflicts for functions introduced in Android API level 26.
15775         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Test for getdomainname
15776         using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS. Conditionally
15777         set REPLACE_GETSUBOPT.
15779         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Conditionally set
15780         REPLACE_NL_LANGINFO.
15781         * lib/langinfo.in.h (nl_langinfo): Disable _GL_CXXALIASWARN invocation
15782         on non-glibc systems.
15784         * lib/stdlib.in.h (getsubopt): Consider REPLACE_GETSUBOPT. Disable
15785         _GL_CXXALIASWARN invocation on non-glibc systems.
15786         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_GETSUBOPT.
15787         * modules/stdlib (Makefile.am): Substitute REPLACE_GETSUBOPT.
15788         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Conditionally set
15789         REPLACE_GETSUBOPT.
15790         * modules/getsubopt (Depends-on, configure.ac): Consider
15791         REPLACE_GETSUBOPT.
15793 2023-01-22  Bruno Haible  <bruno@clisp.org>
15795         Resolve conflicts for functions introduced in Android API level 24.
15796         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Conditionally set
15797         REPLACE_STRCHRNUL.
15799 2023-01-22  Bruno Haible  <bruno@clisp.org>
15801         Resolve conflicts for functions introduced in Android API level 23.
15803         * m4/login_tty.m4 (gl_FUNC_LOGIN_TTY): Conditionally set
15804         REPLACE_LOGIN_TTY.
15805         * lib/utmp.in.h (login_tty): Disable _GL_CXXALIASWARN invocation on
15806         non-glibc systems.
15808         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Conditionally set REPLACE_MKFIFOAT.
15809         * lib/sys_stat.in.h (mkfifoat): Disable _GL_CXXALIASWARN invocation on
15810         non-glibc systems.
15812         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Conditionally set
15813         REPLACE_STRERROR_R.
15814         * lib/string.in.h (strerror_r): Disable _GL_CXXALIASWARN invocation on
15815         non-glibc systems.
15817         * m4/error_h.m4 (gl_ERROR_H): Conditionally set REPLACE_ERROR.
15818         * lib/error.in.h (error): Disable _GL_CXXALIASWARN invocation on
15819         non-glibc systems.
15821         * lib/wchar.in.h (wmempcpy): Consider REPLACE_WMEMPCPY.
15822         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WMEMPCPY.
15823         * modules/wchar (Makefile.am): Substitute REPLACE_WMEMPCPY.
15824         * m4/wmempcpy.m4 (gl_FUNC_WMEMPCPY): Conditionally set
15825         REPLACE_WMEMPCPY.
15826         * modules/wmempcpy (configure.ac): Consider REPLACE_WMEMPCPY.
15828         * lib/unistd.in.h (sethostname): Consider REPLACE_SETHOSTNAME. Disable
15829         _GL_CXXALIASWARN invocation on non-glibc systems.
15830         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_SETHOSTNAME.
15831         * modules/unistd (Makefile.am): Substitute REPLACE_SETHOSTNAME.
15832         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): Conditionally set
15833         REPLACE_SETHOSTNAME.
15834         * modules/sethostname (Depends-on, configure.ac): Consider
15835         REPLACE_SETHOSTNAME.
15837         * lib/string.in.h (mempcpy): Consider REPLACE_MEMPCPY. Disable
15838         _GL_CXXALIASWARN invocation on non-glibc systems.
15839         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize REPLACE_MEMPCPY.
15840         * modules/string (Makefile.am): Substitute REPLACE_MEMPCPY.
15841         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Conditionally set REPLACE_MEMPCPY.
15842         * modules/mempcpy (configure.ac): Consider REPLACE_MEMPCPY.
15844         * lib/stdlib.in.h (mkostemp): Consider REPLACE_MKOSTEMP. Disable
15845         _GL_CXXALIASWARN invocation on non-glibc systems.
15846         (mkostemps): Consider REPLACE_MKOSTEMPS. Disable _GL_CXXALIASWARN
15847         invocation on non-glibc systems.
15848         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MKOSTEMP,
15849         REPLACE_MKOSTEMPS.
15850         * modules/stdlib (Makefile.am): Substitute REPLACE_MKOSTEMP,
15851         REPLACE_MKOSTEMPS.
15852         * m4/mkostemp.m4 (gl_FUNC_MKOSTEMP): Conditionally set REPLACE_MKOSTEMP.
15853         * modules/mkostemp (Depends-on, configure.ac): Consider
15854         REPLACE_MKOSTEMP.
15855         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Conditionally set
15856         REPLACE_MKOSTEMPS.
15857         * modules/mkostemps (Depends-on, configure.ac): Consider
15858         REPLACE_MKOSTEMPS.
15860 2023-01-22  Bruno Haible  <bruno@clisp.org>
15862         Resolve conflicts for functions introduced in Android API level 21.
15864         * m4/fts.m4 (gl_FUNC_FTS_CORE): Use rpl_* symbols also when the system
15865         will have fts_open in a future version.
15866         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Conditionally set REPLACE_ISWBLANK.
15867         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Conditionally set REPLACE_MBTOWC.
15868         * m4/vdprintf.m4 (gl_REPLACE_VDPRINTF): Conditionally set
15869         REPLACE_VDPRINTF.
15870         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): Conditionally set
15871         REPLACE_WCSNRTOMBS.
15873         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Conditionally set
15874         REPLACE_MBSNRTOWCS.
15875         * lib/wchar.in.h (mbsnrtowcs): Disable _GL_CXXALIASWARN invocation on
15876         non-glibc systems.
15878         * m4/execvpe.m4 (gl_FUNC_EXECVPE): Conditionally set REPLACE_EXECVPE.
15879         * m4/linkat.m4 (gl_FUNC_LINKAT): Conditionally set REPLACE_LINKAT.
15880         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Conditionally set
15881         REPLACE_READLINKAT.
15882         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Conditionally set
15883         REPLACE_SYMLINKAT.
15884         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Conditionally set REPLACE_TRUNCATE.
15885         * lib/unistd.in.h (execvpe, linkat, readlinkat, symlinkat, truncate):
15886         Disable _GL_CXXALIASWARN invocation on non-glibc systems.
15888         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Conditionally set REPLACE_MKNODAT.
15889         * lib/sys_stat.in.h (mknodat): Disable _GL_CXXALIASWARN invocation on
15890         non-glibc systems.
15892         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Conditionally set REPLACE_STPNCPY.
15893         * lib/string.in.h (stpncpy): Disable _GL_CXXALIASWARN invocation on
15894         non-glibc systems.
15896         * m4/random.m4 (gl_FUNC_RANDOM): Conditionally set REPLACE_INITSTATE,
15897         REPLACE_SETSTATE.
15898         * lib/stdlib.in.h (initstate, setstate): Disable _GL_CXXALIASWARN
15899         invocation on non-glibc systems.
15901         * m4/dprintf.m4 (gl_REPLACE_DPRINTF): Conditionally set REPLACE_DPRINTF.
15902         * lib/stdio.in.h (dprintf): Disable _GL_CXXALIASWARN invocation on
15903         non-glibc systems.
15905         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Conditionally set
15906         REPLACE_DUPLOCALE.
15907         * m4/localename.m4 (gl_LOCALENAME): Conditionally set REPLACE_NEWLOCALE,
15908         REPLACE_DUPLOCALE, REPLACE_FREELOCALE.
15909         * lib/locale.in.h (newlocale, duplocale, freelocale): Disable
15910         _GL_CXXALIASWARN invocation on non-glibc systems.
15912         * lib/unistd.in.h (dup3): Consider REPLACE_DUP3. Disable
15913         _GL_CXXALIASWARN invocation on non-glibc systems.
15914         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_DUP3.
15915         * modules/unistd (Makefile.am): Substitute REPLACE_DUP3.
15916         * m4/dup3.m4 (gl_FUNC_DUP3): Conditionally set REPLACE_DUP3.
15918         * lib/string.in.h (stpcpy): Consider REPLACE_STPCPY. Disable
15919         _GL_CXXALIASWARN invocation on non-glibc systems.
15920         * m4/string_h.m4 (gl_STRING_H_DEFAULTS): Initialize REPLACE_STPCPY.
15921         * modules/string (Makefile.am): Substitute REPLACE_STPCPY.
15922         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Conditionally set REPLACE_STPCPY.
15923         * modules/stpcpy (configure.ac): Consider REPLACE_STPCPY.
15925         * lib/stdlib.in.h (_Exit): Consider REPLACE__EXIT. Disable
15926         _GL_CXXALIASWARN invocation on non-glibc systems.
15927         (getprogname): Consider REPLACE_GETPROGNAME. Disable _GL_CXXALIASWARN
15928         invocation on non-glibc systems.
15929         (posix_openpt): Consider REPLACE_POSIX_OPENPT. Disable _GL_CXXALIASWARN
15930         invocation on non-glibc systems.
15931         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE__EXIT,
15932         REPLACE_GETPROGNAME, REPLACE_POSIX_OPENPT.
15933         * modules/stdlib (Makefile.am): Substitute REPLACE__EXIT,
15934         REPLACE_GETPROGNAME, REPLACE_POSIX_OPENPT.
15935         * m4/_Exit.m4 (gl_FUNC__EXIT): Conditionally set REPLACE__EXIT.
15936         * modules/_Exit (configure.ac): Consider REPLACE__EXIT.
15937         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Conditionally set
15938         REPLACE_GETPROGNAME.
15939         * modules/getprogname (configure.ac): Consider REPLACE_GETPROGNAME.
15940         * m4/posix_openpt.m4 (gl_FUNC_POSIX_OPENPT): Conditionally set
15941         REPLACE_POSIX_OPENPT.
15942         * modules/posix_openpt (configure.ac): Consider REPLACE_POSIX_OPENPT.
15944         * lib/search.in.h (twalk): Consider REPLACE_TWALK.
15945         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize REPLACE_TWALK.
15946         * modules/search (Makefile.am): Substitute REPLACE_TWALK.
15947         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Conditionally set REPLACE_TWALK.
15948         * modules/tsearch (configure.ac): Consider REPLACE_TWALK.
15950 2023-01-22  Bruno Haible  <bruno@clisp.org>
15952         Resolve conflicts for functions introduced in Android API level 19.
15954         * lib/inttypes.in.h (imaxabs): Consider REPLACE_IMAXABS. Disable
15955         _GL_CXXALIASWARN invocation on non-glibc systems.
15956         (imaxdiv): Consider REPLACE_IMAXDIV. Disable _GL_CXXALIASWARN invocation
15957         on non-glibc systems.
15958         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Initialize HAVE_IMAXABS,
15959         HAVE_IMAXDIV, REPLACE_IMAXABS, REPLACE_IMAXDIV.
15960         * modules/inttypes-incomplete (Makefile.am): Substitute REPLACE_IMAXABS,
15961         REPLACE_IMAXDIV.
15962         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Conditionally set HAVE_IMAXABS,
15963         REPLACE_IMAXABS.
15964         * modules/imaxabs (configure.ac): Consider HAVE_IMAXABS, REPLACE_IMAXABS.
15965         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Conditionally set HAVE_IMAXDIV,
15966         REPLACE_IMAXDIV.
15967         * modules/imaxdiv (configure.ac): Consider HAVE_IMAXDIV, REPLACE_IMAXDIV.
15969         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Conditionally set REPLACE_FUTIMENS.
15970         * lib/sys_stat.in.h (futimens): Disable _GL_CXXALIASWARN invocation on
15971         non-glibc systems.
15973 2023-01-22  Bruno Haible  <bruno@clisp.org>
15975         Resolve conflicts for functions introduced in Android API level 18.
15977         * m4/log2.m4 (gl_FUNC_LOG2): Conditionally set REPLACE_LOG2.
15978         * m4/log2f.m4 (gl_FUNC_LOG2F): Conditionally set REPLACE_LOG2F.
15979         * m4/log2l.m4 (gl_FUNC_LOG2L): Conditionally set REPLACE_LOG2L.
15980         * lib/math.in.h (log2f): Disable _GL_CXXALIASWARN invocation on
15981         non-glibc systems.
15983         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Conditionally set REPLACE_GETDELIM.
15984         * m4/getline.m4 (gl_FUNC_GETLINE): Conditionally set REPLACE_GETLINE.
15985         * lib/stdio.in.h (getdelim, getline): Disable _GL_CXXALIASWARN
15986         invocation on non-glibc systems.
15988 2023-01-22  Bruno Haible  <bruno@clisp.org>
15990         Resolve conflicts for functions introduced in Android API level 16-17.
15991         * m4/posix_memalign.m4 (gl_FUNC_POSIX_MEMALIGN): Conditionally set
15992         REPLACE_POSIX_MEMALIGN.
15993         * lib/stdlib.in.h (posix_memalign): Disable _GL_CXXALIASWARN invocation
15994         on non-glibc systems.
15996 2023-01-22  Bruno Haible  <bruno@clisp.org>
15998         Resolve conflicts for functions introduced in Android API level 16.
16000         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Conditionally set REPLACE_TSEARCH.
16001         * lib/search.in.h (tsearch, tfind, tdelete, twalk): Disable
16002         _GL_CXXALIASWARN invocation on non-glibc systems.
16004         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Conditionally set
16005         REPLACE_FACCESSAT.
16006         * lib/unistd.in.h (faccessat): Disable _GL_CXXALIASWARN invocation on
16007         non-glibc systems.
16009 2023-01-22  Bruno Haible  <bruno@clisp.org>
16011         Resolve conflicts for functions introduced in Android API level 12.
16013         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Conditionally set
16014         REPLACE_UTIMENSAT.
16015         * lib/sys_stat.in.h (utimensat): Disable _GL_CXXALIASWARN invocation on
16016         non-glibc systems.
16018         * m4/timegm.m4 (gl_FUNC_TIMEGM): Conditionally set REPLACE_TIMEGM.
16019         * lib/time.in.h (timegm): Disable _GL_CXXALIASWARN invocation on
16020         non-glibc systems.
16022         * m4/pwrite.m4 (gl_FUNC_PWRITE): Conditionally set REPLACE_PWRITE.
16023         * lib/unistd.in.h (pwrite): Disable _GL_CXXALIASWARN invocation on
16024         non-glibc systems.
16026         * m4/pread.m4 (gl_FUNC_PREAD): Conditionally set REPLACE_PREAD.
16027         * lib/unistd.in.h (pread): Disable _GL_CXXALIASWARN invocation on
16028         non-glibc systems.
16030         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Conditionally set
16031         REPLACE_FTRUNCATE.
16032         * lib/unistd.in.h (ftruncate): Disable _GL_CXXALIASWARN invocation on
16033         non-glibc systems.
16035 2023-01-22  Bruno Haible  <bruno@clisp.org>
16037         Resolve conflicts for functions introduced in Android API level 9.
16038         * lib/unistd.in.h (fdatasync): Consider REPLACE_FDATASYNC. Disable
16039         _GL_CXXALIASWARN invocation on non-glibc systems.
16040         (pipe2): Consider REPLACE_PIPE2. Disable _GL_CXXALIASWARN invocation on
16041         non-glibc systems.
16042         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_FDATASYNC,
16043         REPLACE_PIPE2.
16044         * modules/unistd (Makefile.am): Substitute REPLACE_FDATASYNC,
16045         REPLACE_PIPE2.
16046         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Test for fdatasync using
16047         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS. Conditionally set
16048         REPLACE_FDATASYNC.
16049         * modules/fdatasync (Depends-on, configure.ac): Consider
16050         REPLACE_FDATASYNC.
16051         * m4/pipe2.m4 (gl_FUNC_PIPE2): Conditionally set REPLACE_PIPE2.
16053 2023-01-22  Bruno Haible  <bruno@clisp.org>
16055         Resolve conflicts for functions introduced in Android API level 8.
16056         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Conditionally set
16057         REPLACE_TTYNAME_R.
16058         * lib/unistd.in.h (ttyname_r): Disable _GL_CXXALIASWARN invocation on
16059         non-glibc systems.
16061 2023-01-22  Bruno Haible  <bruno@clisp.org>
16063         Prepare for resolving conflicts regarding future Android API levels.
16064         * m4/gnulib-common.m4 (gl_CHECK_FUNCS_ANDROID): Don't check for the
16065         function declaration on platforms other than Android. Set a variable
16066         gl_cv_onwards_func_<func>.
16068 2023-01-22  Paul Eggert  <eggert@cs.ucla.edu>
16070         sigsegv, vma-iter: port to Solaris 10
16071         On this platform, <sys/types.h> does not define off_t if neither
16072         _LP64 nor _FILE_OFFSET_BITS is defined, which can happen if we
16073         #undef _FILE_OFFSET_BITS.  This became a problem with the new way
16074         of doing stdbool, since config.h now includes <stdbool.h>, and
16075         Solaris 10 <stdbool.h> includes <sys/feature_tests.h> which
16076         arranges for _FILE_OFFSET_BITS to always be defined (if only to 32),
16077         which <sys/types.h> assumes.
16078         * lib/stackvma.c, lib/vma-iter.c (_FILE_OFFSET_BITS) [__sun && !_LP64]:
16079         Define to 32 instead of leaving undefined.
16081 2023-01-21  Bruno Haible  <bruno@clisp.org>
16083         login_tty: Ensure declaration in <utmp.h>.
16085         * tests/test-utmp-c++.cc: New file.
16086         * modules/utmp-c++-tests: New file.
16088         * tests/test-utmp.c: New file.
16089         * modules/utmp-tests: New file.
16091         * lib/login_tty.c: Include <utmp.h>.
16092         * m4/login_tty.m4: New file.
16093         (gl_FUNC_LOGIN_TTY): Moved here from m4/pty.m4. Set HAVE_LOGIN_TTY.
16094         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Moved to m4/login_tty.m4.
16095         * modules/login_tty (Files): Add m4/login_tty.m4.
16096         (Depends-on): Add utmp. Remove pty. Update condition.
16097         (configure.ac): Update condition. Invoke gl_UTMP_MODULE_INDICATOR
16098         instead of gl_PTY_MODULE_INDICATOR.
16099         (Include): List <utmp.h>.
16100         * doc/glibc-functions/login_tty.texi: Mark the include file diversity as
16101         fixed.
16102         * tests/test-login_tty.c: Include <utmp.h>. Don't declare login_tty
16103         here.
16105         * lib/utmp.in.h: New file.
16106         * m4/utmp_h.m4: New file.
16107         * modules/utmp: New file.
16108         * doc/glibc-headers/utmp.texi: New file.
16109         * doc/gnulib.texi (Glibc Header File Substitutes): Include it.
16111 2023-01-21  Bruno Haible  <bruno@clisp.org>
16113         login_tty: Fix detection of declaration (regression 2023-01-19).
16114         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Check for the three possible header
16115         files.
16117 2023-01-21  Bruno Haible  <bruno@clisp.org>
16119         alignasof tests: Rename test file.
16120         * tests/test-alignasof.c: Renamed from tests/test-stdalign.c.
16121         * modules/alignasof-tests (Files, Makefile.am): Update accordingly.
16123 2023-01-21  Bruno Haible  <bruno@clisp.org>
16125         alignasof tests: Fix GCC warning (regression 2023-01-15).
16126         * tests/test-stdalign.c (alignas): Undefine before redefine.
16128 2023-01-21  Bruno Haible  <bruno@clisp.org>
16130         getprogname: Move declaration from "getprogname.h" to <stdlib.h>.
16131         * lib/stdlib.in.h (getprogname): New declaration.
16132         * lib/getprogname.h: Add deprecation warning.
16133         (getprogname): Remove declaration.
16134         * lib/getprogname.c: Include <stdlib.h> instead of getprogname.h.
16135         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether getprogname is declared.
16136         (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPROGNAME.
16137         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_GETPROGNAME.
16138         * m4/getprogname.m4 (gl_PREREQ_GETPROGNAME): New macro, extracted from
16139         gl_FUNC_GETPROGNAME. Set HAVE_GETPROGNAME.
16140         (gl_FUNC_GETPROGNAME): Remove code that was moved to
16141         gl_PREREQ_GETPROGNAME.
16142         * modules/stdlib (Makefile.am): Substitute GNULIB_GETPROGNAME and
16143         HAVE_GETPROGNAME.
16144         * modules/getprogname (Depends-on): Add stdlib.
16145         (configure.ac): Define a module indicator. Invoke gl_PREREQ_GETPROGNAME.
16146         (Makefile.am): Don't compile getprogname.c if not needed.
16147         (Include): List <stdlib.h> instead of getprogname.h.
16148         * tests/test-getprogname.c: Include <stdlib.h> instead of getprogname.h.
16149         * NEWS: Mention the change.
16150         * lib/argmatch.c: Don't include getprogname.h.
16151         * lib/c-stack.c: Likewise.
16152         * lib/error.c: Likewise.
16153         * lib/git-merge-changelog.c: Likewise.
16155 2023-01-19  Paul Eggert  <eggert@cs.ucla.edu>
16157         snippet/_Noreturn: work around Clang _Noreturn bug
16158         This is a bigger-hammer workaround for the clang _Noreturn issue
16159         fix for dfa.c on 2023-01-01.  Unfortunately, it causes 270
16160         -Wreturn-type and -Wsometimes-uninitialized warnings when building
16161         bleeding-edge GNU Emacs from Git on Fedora 37 with plain
16162         ‘./configure && make’.  So the workaround is enabled only if you
16163         compile with -D_GL_WORK_AROUND_LLVM_BUG_59792.
16164         * lib/_Noreturn.h (_Noreturn):
16165         * m4/gnulib-common.m4 (gl_COMMON_BODY):
16166         #define _Noreturn to be empty if it is Clang 15 or earlier,
16167         and if _GL_WORK_AROUND_LLVM_BUG_59792 is defined.
16169 2023-01-19  Bruno Haible  <bruno@clisp.org>
16171         Fix warnings for functions introduced in Android API level 34.
16172         * modules/execute-tests (configure.ac): Test for close_range using
16173         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16175 2023-01-19  Bruno Haible  <bruno@clisp.org>
16177         Fix warnings for functions introduced in Android API level 30.
16178         * m4/threadlib.m4 (gl_STDTHREADLIB_BODY): Test for thrd_create using
16179         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16181 2023-01-19  Bruno Haible  <bruno@clisp.org>
16183         Fix warnings for functions introduced in Android API level 29.
16184         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for getloadavg using
16185         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNC.
16187 2023-01-19  Bruno Haible  <bruno@clisp.org>
16189         Fix warnings for functions introduced in Android API level 28.
16190         * m4/glob.m4 (gl_GLOB): Test for glob using gl_CHECK_FUNCS_ANDROID
16191         instead of AC_CHECK_FUNCS_ONCE.
16193 2023-01-19  Bruno Haible  <bruno@clisp.org>
16195         Fix warnings for functions introduced in Android API level 26.
16196         * m4/mountlist.m4 (gl_MOUNTLIST): Test for hasmntopt using
16197         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16198         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Test for nl_langinfo using
16199         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16200         * m4/strtod.m4 (gl_PREREQ_STRTOD): Test for nl_langinfo using
16201         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16202         * m4/strtold.m4 (gl_PREREQ_STRTOLD): Likewise.
16203         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Likewise.
16204         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R): Test for catgets using
16205         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16206         * m4/utimens.m4 (gl_UTIMENS): Test for lutimes using
16207         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16208         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Test for nl_langinfo_l using
16209         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16210         * modules/duplocale-tests (configure.ac): Likewise.
16211         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Update comment.
16213 2023-01-19  Bruno Haible  <bruno@clisp.org>
16215         Fix warnings for functions introduced in Android API level 24.
16216         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Test for strchrnul using
16217         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16219 2023-01-19  Bruno Haible  <bruno@clisp.org>
16221         Fix warnings for functions introduced in Android API level 23.
16222         * m4/fbufmode.m4 (gl_FUNC_FBUFMODE): Test for __flbf, __fbufsize using
16223         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16224         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT_LGPL): Test for mempcpy using
16225         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16226         * m4/fpurge.m4 (gl_FUNC_FPURGE): Test for __fpurge using
16227         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16228         * m4/freadable.m4 (gl_FUNC_FREADABLE): Test for __freadable using
16229         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16230         * m4/fwritable.m4 (gl_FUNC_FWRITABLE): Test for __fwritable using
16231         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16232         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): Test for __fsetlocking using
16233         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16234         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Test for mempcpy using
16235         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16236         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Test for mkfifoat using
16237         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16238         * m4/mkostemp.m4 (gl_FUNC_MKOSTEMP): Test for mkostemp using
16239         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16240         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Test for mkostemps using
16241         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16242         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Test for login_tty using
16243         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16244         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): Test for sethostname using
16245         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16246         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Test for strerror_r using
16247         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16248         * m4/wmempcpy.m4 (gl_FUNC_WMEMPCPY): Test for wmempcpy using
16249         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16251 2023-01-19  Bruno Haible  <bruno@clisp.org>
16253         Fix warnings for functions introduced in Android API level 21.
16254         * m4/_Exit.m4 (gl_FUNC__EXIT): Test for _Exit using
16255         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16256         * m4/c-strtod.m4 (gl_C_STRTOLD): Test for strtold_l using
16257         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16258         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Test for c32rtomb like
16259         gl_CHECK_FUNCS_ANDROID does.
16260         * m4/dprintf.m4 (gl_FUNC_DPRINTF): Test for dprintf using
16261         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16262         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Likewise.
16263         * m4/dup3.m4 (gl_FUNC_DUP3): Test for dup3 using
16264         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16265         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Test for duplocale using
16266         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16267         * m4/execvpe.m4 (gl_FUNC_EXECVPE): Test for execvpe using
16268         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16269         * m4/fts.m4 (gl_FUNC_FTS_CORE): Test for fts_open using
16270         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNC.
16271         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Test for getprogname using
16272         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16273         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): Test for uselocale using
16274         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16275         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Test for iswblank using
16276         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16277         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Test for
16278         tcdrain using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16279         * m4/linkat.m4 (gl_FUNC_LINKAT): Test for linkat using
16280         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16281         * m4/localename.m4 (gl_LOCALENAME): Test for newlocale, duplocale,
16282         freelocale using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16283         * m4/mbrtoc32.m4 (gl_CHECK_FUNC_MBRTOC32): Test for mbrtoc32 like
16284         gl_CHECK_FUNCS_ANDROID does.
16285         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Test for mbsnrtowcs using
16286         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16287         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Test for mbtowc using
16288         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16289         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Test for mknodat using
16290         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16291         * m4/mountlist.m4 (gl_MOUNTLIST): Test for setmntent, endmntent using
16292         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16293         * m4/posix_openpt.m4 (gl_FUNC_POSIX_OPENPT): Test for posix_openpt using
16294         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16295         * m4/pty.m4 (gl_FUNC_OPENPTY): Test for posix_openpt using
16296         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16297         * m4/random.m4 (gl_FUNC_RANDOM): Test for initstate, setstate using
16298         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16299         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Test for stpcpy using
16300         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16301         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Test for stpncpy using
16302         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16303         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Test for symlinkat using
16304         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16305         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Test for truncate using
16306         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16307         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Test for twalk using
16308         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16309         * m4/vdprintf.m4 (gl_FUNC_VDPRINTF): Test for vdprintf using
16310         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16311         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
16312         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): Test for wcsnrtombs using
16313         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16314         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Test for readlinkat using
16315         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16316         * m4/fchmodat.m4 (gl_PREREQ_FCHMODAT): Likewise.
16317         * modules/careadlinkat (configure.ac): Likewise.
16318         * modules/ftoastr (configure.ac): Test for strtof using
16319         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16320         * modules/duplocale-tests (configure.ac): Test for duplocale using
16321         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16322         * modules/hard-locale-tests (configure.ac): Likewise.
16323         * modules/locale-tests (configure.ac): Test for newlocale using
16324         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16325         * modules/localename-tests (configure.ac): Likewise.
16326         * modules/tsearch-tests (configure.ac): Test for initstate using
16327         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16328         * modules/unistr/u8-stpcpy (configure.ac): Test for stpcpy using
16329         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16331         * m4/tcgetattr.m4: New file, extracted from m4/getpass.m4.
16332         * m4/getpass.m4 (gl_PREREQ_GETPASS): Remove code that tests for
16333         tcgetattr. Invoke gl_HAVE_TCGETATTR instead.
16334         * modules/getpass (Files): Add tcgetattr.m4.
16335         * modules/getpass-gnu (Files): Add tcgetattr.m4.
16336         * modules/term-style-control (Files): Add tcgetattr.m4.
16337         (configure.ac): Remove code that tests for tcgetattr. Invoke
16338         gl_HAVE_TCGETATTR instead.
16340 2023-01-19  Bruno Haible  <bruno@clisp.org>
16342         Fix warnings for functions introduced in Android API level 19.
16343         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Test for futimens using
16344         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16345         * m4/utimens.m4 (gl_UTIMENS): Likewise.
16346         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Test for imaxabs using
16347         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16348         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Test for imaxdiv using
16349         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16351 2023-01-19  Bruno Haible  <bruno@clisp.org>
16353         Fix warnings for functions introduced in Android API level 18.
16354         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Test for getdelim using
16355         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16356         * m4/getline.m4 (gl_FUNC_GETLINE): Test for getline using
16357         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNC.
16358         * m4/log2.m4 (gl_FUNC_LOG2): Test for log2 using
16359         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16360         * m4/log2f.m4 (gl_FUNC_LOG2F): Test for log2f using
16361         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16362         * m4/log2l.m4 (gl_FUNC_LOG2L): Test for log2l using
16363         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16365 2023-01-19  Bruno Haible  <bruno@clisp.org>
16367         Fix warnings for functions introduced in Android API level 16 or 17.
16368         * m4/posix_memalign.m4 (gl_FUNC_POSIX_MEMALIGN): Test for posix_memalign
16369         using gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16370         * m4/alignalloc.m4 (gl_ALIGNALLOC): Likewise.
16371         * m4/pagealign_alloc.m4 (gl_PREREQ_PAGEALIGN_ALLOC): Likewise.
16372         * modules/aligned-malloc (configure.ac): Likewise.
16374 2023-01-19  Bruno Haible  <bruno@clisp.org>
16376         Fix warnings for functions introduced in Android API level 16.
16377         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Test for faccessat using
16378         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16379         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE,
16380         gl_CANONICALIZE_LGPL_SEPARATE): Likewise.
16381         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
16382         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Test for tsearch using
16383         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16384         * m4/setenv.m4 (gl_PREREQ_SETENV): Likewise.
16386 2023-01-19  Bruno Haible  <bruno@clisp.org>
16388         Fix warnings for functions introduced in Android API level 12.
16389         Reported by Po Lu <luangruo@yahoo.com>.
16390         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Test for ftruncate using
16391         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16392         * m4/glob.m4 (gl_PREREQ_GLOB): Test for getpwnam_r using
16393         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16394         * m4/nproc.m4 (gl_PREREQ_NPROC): Test for sched_getaffinity using
16395         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16396         * m4/pread.m4 (gl_FUNC_PREAD): Test for pread using
16397         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16398         * m4/pwrite.m4 (gl_FUNC_PWRITE): Test for pwrite using
16399         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16400         * m4/thread.m4 (gl_THREAD): Test for pthread_atfork using
16401         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16402         * m4/timegm.m4 (gl_FUNC_TIMEGM): Test for timegm using
16403         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16404         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Test for utimensat using
16405         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16406         * m4/utimens.m4 (gl_UTIMENS): Likewise.
16408 2023-01-19  Bruno Haible  <bruno@clisp.org>
16410         Fix warnings for functions introduced in Android API level 9.
16411         * m4/pipe2.m4 (gl_FUNC_PIPE2): Test for pipe2 using
16412         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16413         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Update comments.
16415 2023-01-19  Bruno Haible  <bruno@clisp.org>
16417         Fix warnings for functions introduced in Android API level 8.
16418         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test for ttyname_r using
16419         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16421 2023-01-19  Bruno Haible  <bruno@clisp.org>
16423         fts: Document this module.
16424         * doc/glibc-headers/fts.texi: Mention the 'fts' module.
16425         * doc/glibc-functions/fts_children.texi: Likewise.
16426         * doc/glibc-functions/fts_close.texi: Likewise.
16427         * doc/glibc-functions/fts_open.texi: Likewise.
16428         * doc/glibc-functions/fts_read.texi: Likewise.
16429         * doc/glibc-functions/fts_set.texi: Likewise.
16431 2023-01-18  Bruno Haible  <bruno@clisp.org>
16433         getcwd: Speed up on Linux. Add support for Android.
16434         * lib/getcwd.c (__getcwd_generic): On Linux, use a specific readlink
16435         call to speed up the operation.
16437 2023-01-17  Paul Eggert  <eggert@cs.ucla.edu>
16439         qcopy-acl: port to Fedora 9
16440         It has libattr-2.4.41, which is too old for our code.
16441         Problem reported by Po Lu <https://bugs.gnu.org/60843>.
16442         * m4/xattr.m4 (gl_FUNC_XATTR): Check that we can use
16443         ATTR_ACTION_PERMISSIONS, too.  Refactor so that there’s a single
16444         test program that we compile and link, rather than doing the tests
16445         in dribs and drabs.
16447 2023-01-17  Bruno Haible  <bruno@clisp.org>
16449         execute tests: Avoid test failure with GNU make 4.4.
16450         Reported by Eric Blake in
16451         <https://lists.gnu.org/archive/html/bug-gnulib/2023-01/msg00157.html>.
16452         * tests/test-execute-main.c (main): Reset the SIGPIPE handler to
16453         default on all platforms.
16455 2023-01-17  Bruno Haible  <bruno@clisp.org>
16457         fflush: Tweak last commit.
16458         * lib/stdio-impl.h (fp_): Make the last change work also with newer
16459         Android NDKs and _FILE_OFFSET_BITS=64.
16461 2023-01-17  Ondrej Valousek  <ondrej.valousek.xm@renesas.com>
16463         qset-acl, acl: Improve comments.
16464         * lib/qset-acl.c (qset_acl): Improve comments.
16465         * lib/set-acl.c (set_acl): Likewise.
16467 2023-01-17  Bruno Haible  <bruno@clisp.org>
16469         fflush: Fix a buffer overrun on 32-bit Android.
16470         * lib/stdio-impl.h (fp_): On Android, change the type of _offset to
16471         'long'.
16472         * lib/fflush.c (update_fpos_cache): On Android, update a 'long', not an
16473         'fpos_t'.
16475 2023-01-17  Bruno Haible  <bruno@clisp.org>
16477         execute tests: Avoid test failure on Android.
16478         * tests/test-execute-main.c (main): Reset the SIGPIPE handler to
16479         default.
16481 2023-01-17  Bruno Haible  <bruno@clisp.org>
16483         hard-locale: Port to Android ≥ 5.0.
16484         * lib/hard-locale.c: Include <stdlib.h>.
16485         (hard_locale): On Android, consider also MB_CUR_MAX, even if the
16486         locale's name is "C".
16487         * tests/test-hard-locale.c (test_one, main): Assume that on Android,
16488         even the "C" locale is hard.
16490 2023-01-16  Bruno Haible  <bruno@clisp.org>
16492         stddef tests: Fix compilation error (regression 2023-01-15).
16493         * tests/test-stddef.c: Don't include <stdalign.h>.
16495 2023-01-16  Bruno Haible  <bruno@clisp.org>
16497         mbrtowc, mbrtoc32 tests: Avoid test failure on Android ≥ 5.0.
16498         * tests/test-mbrtowc.c (main): On Android 5.0 or newer, when testing
16499         the "C" locale, verify that the encoding is UTF-8.
16500         * tests/test-mbrtoc32.c (main): Likewise.
16501         * doc/posix-functions/setlocale.texi: Mention the Android problems.
16503         mbrtowc, mbrtoc32 tests: Refactor.
16504         * tests/test-mbrtowc.c (main): Straighten convoluted code.
16505         * tests/test-mbrtoc32.c (main): Likewise.
16507 2023-01-16  Paul Eggert  <eggert@cs.ucla.edu>
16509         sigpipe tests: Modernize use of 'head'.
16510         POSIX no longer requires support for ‘head -1’.
16511         * tests/test-sigpipe.sh: Use ‘head -n1’ rather than ‘head -1’.
16512         * tests/test-sigpipe.c (main): Likewise.
16513         * lib/git-merge-changelog.c (main): Update comment accordingly.
16515 2023-01-15  Paul Eggert  <eggert@cs.ucla.edu>
16517         alignasof: new module
16518         This splits off support for the C23 keywords alignas and alignof,
16519         from the now-deprecated stdalign module.  The latter now merely
16520         provides C11 support.
16521         * MODULES.html.sh, NEWS, doc/gnulib.texi:
16522         * doc/posix-headers/stdalign.texi: Document the change.
16523         * lib/stdalign.in.h: Remove most of the definitions (which are now
16524         supplied by the alignasof module), leaving only
16525         __alignas_is_defined and __alignof_is_defined.
16526         * modules/alignasof, modules/alignasof-tests: New files.
16527         * m4/stdalign.m4 (gl_ALIGNASOF): New macro, with
16528         most of the contents of the old gl_STDALIGN_H.
16529         Do not define __alignas_is_defined or __alignof_is_defined.
16530         (gl_STDALIGN_H): Rely on gl_ALIGNASOF for most of the work.
16531         * modules/alignalloc, modules/alignof, modules/argp:
16532         * modules/crypto/md4-buffer, modules/crypto/md5-buffer:
16533         * modules/crypto/sha1-buffer, modules/crypto/sha256-buffer:
16534         * modules/crypto/sha512-buffer, modules/crypto/sm3-buffer:
16535         * modules/fts, modules/rawmemchr, modules/relocatable-prog-wrapper:
16536         * modules/stddef-tests, modules/sys_socket:
16537         Depend on alignasof, not stdalign.
16538         * modules/stdalign: Deprecate.  Depend on alignasof.
16539         * modules/stdalign-tests: Move most contents to the new module
16540         alignasof-tests, and depend on that.
16542 2023-01-15  Bruno Haible  <bruno@clisp.org>
16544         fpending: Fix compilation error with NDK ≥ r14b and Android API < 23.
16545         Report and patch by Po Lu <luangruo@yahoo.com>.
16546         * lib/fpending.c (__fpending) [__ANDROID__]: Use the fp_ macro.
16548 2023-01-14  Paul Eggert  <eggert@cs.ucla.edu>
16550         alignof: port to strict C23
16551         Problem reported by Khem Raj in:
16552         https://lists.gnu.org/r/bug-gnulib/2023-01/msg00111.html
16553         * lib/alignof.h (alignof_slot) [!__cplusplus]: Use C23-style alignof.
16554         * modules/alignof (Depends-on): Add stdalign.
16556         test-framework-sh: work around AIX 7.2 diff bugs
16557         * tests/init.sh (compare_dev_null_): Run diff in the C locale.
16558         AIX 7.2 diff messes up in UTF-8 locales; for example,
16559         ‘printf '\360\220\200\200\n' | diff - /dev/null’ incorrectly
16560         outputs nothing and exits with status 0 when LC_ALL=en_US.UTF-8.
16562 2023-01-14  Bruno Haible  <bruno@clisp.org>
16564         error, verror tests: Fix link error when the package uses libintl.
16565         * modules/error-tests (Makefile.am): Link test-error with $(LIBINTL).
16566         * modules/verror-tests (Makefile.am): Link test-verror with $(LIBINTL).
16568 2023-01-13  Bruno Haible  <bruno@clisp.org>
16570         localename: Fix -Wtautological-pointer-compare warning in a better way.
16571         * lib/localename.c (duplocale, freelocale): Revert last patch.
16572         (_GL_ARG_NONNULL): Define to empty.
16574 2023-01-13  Paul Eggert  <eggert@cs.ucla.edu>
16576         verify: work around xlclang 16.1 compiler bug
16577         Problem reported by Bruno Haible in:
16578         https://lists.gnu.org/r/grep-devel/2023-01/msg00003.html
16579         * lib/verify.h (_GL_HAS_BUILTIN_TRAP, _GL_HAS_BUILTIN_UNREACHABLE):
16580         Define to 0 if compiler advertises itself as clang before version 5.
16581         xlclang 16.1 advertises itself as 4.0.1 and this patch works
16582         around what appears to be a compiler bug when compiling dfa.c in
16583         bleeding-edge grep.
16585         assert-h: suppress xlclang 16.1 false alarms
16586         * m4/assert_h.m4 (gl_ASSERT_H): Pacify older clangs too,
16587         with regard to single-argument static_assert.
16588         Problem found with xlclang 16.1 on AIX 7.2.
16590         assert-h: fix configure comment-out
16591         * m4/assert_h.m4 (gl_ASSERT_H): Also break apart "#undef
16592         static_assert" with /**/.  Problem discovered with xlclang 16.1,
16593         though it does not directly affect xlclang 16.1.
16595         Don’t use alloc_size with xlclang 16.1
16596         * m4/gnulib-common.m4 (_GL_HAS_ATTRIBUTE): Require Clang 5 instead
16597         of 3.5 for this, to pacify xlclang 16.1.0 on AIX 7.2, which
16598         advertises itself as clang 4.0.1, and which otherwise issues
16599         warnings like “./xalloc.h:141:3: warning: 1540-2990 The attribute
16600         "__attribute__((alloc_size(2, 3)))" is not supported.  The
16601         attribute is ignored.” when building bleeding-edge GNU grep.
16603         localename: -Wtautological-pointer-compare
16604         Problem found by xlclang 16.1 on AIX 7.2.
16605         * lib/localename.c (duplocale, freelocale):
16606         Omit unnecessary comparison of non-null args to NULL.
16608 2023-01-13  Bruno Haible  <bruno@clisp.org>
16610         login_tty tests: Be more verbose when the test fails.
16611         * tests/test-login_tty.c (main): When the test fails, write a message
16612         into a file.
16614 2023-01-13  Bruno Haible  <bruno@clisp.org>
16616         qcopy-acl: Make last patch more robust.
16617         * m4/acl.m4 (gl_FUNC_ACL): Define through AC_DEFUN_ONCE.
16618         * modules/qcopy-acl (configure.ac): Require gl_FUNC_ACL.
16620         qcopy-acl: Adjust link dependencies.
16621         * modules/qcopy-acl (Depends-on): Add condition.
16622         (configure.ac): Set QCOPY_ACL_LIB.
16623         (Link): Add $(QCOPY_ACL_LIB). Remove $(LIB_ACL).
16624         * modules/qacl (Link): Add $(LIB_ACL) and $(QCOPY_ACL_LIB).
16625         * modules/acl (Link): Add $(LIB_ACL) and $(QCOPY_ACL_LIB).
16626         * modules/copy-file (Link): Add $(QCOPY_ACL_LIB).
16627         * modules/supersede (Link): Add $(QCOPY_ACL_LIB).
16628         * modules/acl-tests (Makefile.am): Link test-copy-acl with
16629         $(QCOPY_ACL_LIB).
16630         * modules/copy-file-tests (Makefile.am): Link test-copy-file with
16631         $(QCOPY_ACL_LIB).
16632         * modules/supersede-tests (Makefile.am): Link test-supersede with
16633         $(QCOPY_ACL_LIB).
16635 2023-01-13  Bruno Haible  <bruno@clisp.org>
16637         qcopy-acl: Avoid autoconf warning.
16638         * m4/xattr.m4 (gl_FUNC_XATTR): Provide a description in AC_DEFINE.
16639         Also, protect against unsafe use of a configure option value.
16641 2023-01-12  Ondrej Valousek  <ondrej.valousek.xm@renesas.com>
16643         qcopy-acl: Optimize copying of ACLs by directly copying the attributes.
16644         * lib/qcopy-acl.c (is_attr_permissions): New functions.
16645         (qcopy_acl): If USE_XATTR, copy the ACL related attributes directly.
16646         * m4/xattr.m4: New file.
16647         * modules/qcopy-acl (Files): Add it.
16648         (configure.ac): Invoke gl_FUNC_XATTR.
16650 2023-01-12  Bruno Haible  <bruno@clisp.org>
16652         error: Work around an Android problem.
16653         * lib/error.in.h: Renamed from lib/error.h.
16654         (_GL_ATTRIBUTE_SPEC_PRINTF_ERROR): New macro.
16655         (error): Consider HAVE_ERROR and REPLACE_ERROR.
16656         (error_at_line): Consider HAVE_ERROR_AT_LINE and REPLACE_ERROR_AT_LINE.
16657         * m4/error_h.m4: New file, partially based on m4/error.m4.
16658         * m4/error.m4 (gl_ERROR): Remove the test for error_at_line.
16659         * modules/error-h: New file.
16660         * modules/error (Files): Remove lib/error.h.
16661         (Depends-on): Add error-h. Update conditions.
16662         (configure.ac): Require gl_ERROR_H. Update condition.
16663         * doc/glibc-headers/error.texi: Mention the 'error-h' module.
16664         * doc/glibc-functions/error.texi: Mention the Android problem.
16665         * config/srclist.txt: Add comment regarding error.h.
16667 2023-01-12  Bruno Haible  <bruno@clisp.org>
16669         error, verror tests: Add clarification.
16670         * tests/test-error.c (main): Clarify why we don't test error_at_line
16671         with a NULL filename.
16672         * tests/test-verror.c (main): Clarify why we don't test verror_at_line
16673         with a NULL filename.
16675 2023-01-12  Bruno Haible  <bruno@clisp.org>
16677         verror: Add tests.
16678         * tests/test-verror.sh: New file, based on tests/test-error.sh.
16679         * tests/test-verror.c: New file, based on tests/test-error.c.
16680         * modules/verror-tests: New file.
16682 2023-01-12  Bruno Haible  <bruno@clisp.org>
16684         error: Add tests.
16685         * tests/test-error.sh: New file.
16686         * tests/test-error.c: New file.
16687         * modules/error-tests: New file.
16689 2023-01-11  Bruno Haible  <bruno@clisp.org>
16691         xstrtol-error: Improve comments.
16692         * lib/xstrtol-error.h (xstrtol_fatal): Add parameter names to
16693         declaration.
16695 2023-01-11  Bruno Haible  <bruno@clisp.org>
16697         spawn-pipe tests: Fix test failure on Android.
16698         * tests/test-spawn-pipe-child.c (main): Skip the is_open (STDERR_FILENO)
16699         check on Android.
16701 2023-01-11  Bruno Haible  <bruno@clisp.org>
16703         perror: Fix "perror clobbers strerror's buffer" problem on Android.
16704         * m4/perror.m4 (gl_FUNC_PERROR): Set REPLACE_PERROR to 1 on Android.
16705         * doc/posix-functions/perror.texi: Mention the Android problem.
16707 2023-01-11  Bruno Haible  <bruno@clisp.org>
16709         posix_spawn_file_actions_addfchdir tests: Fix test failure on Android.
16710         * tests/test-posix_spawn-fchdir.c: Include xvasprintf.h.
16711         (test): On Android, use "/proc" instead of "/".
16712         (main): Determine the relative location of the 'pwd' program
16713         accordingly.
16714         * modules/posix_spawn_file_actions_addfchdir-tests (Depends-on): Add
16715         xvasprintf.
16717 2023-01-11  Bruno Haible  <bruno@clisp.org>
16719         rename, renameat, renameatu: Fix test failures on Android/Termux.
16720         * tests/test-rename.h (test_rename): On Android, treat an EACCES failure
16721         like EPERM.
16723 2023-01-11  Bruno Haible  <bruno@clisp.org>
16725         link, linkat tests: Fix test failures on Android/Termux.
16726         * tests/test-link.h (test_link): On Android, treat an EACCES failure
16727         like EPERM.
16728         * tests/test-linkat.c (main): When test_link is marked skipped, skip the
16729         rest of the test as well.
16731 2023-01-11  Bruno Haible  <bruno@clisp.org>
16733         link tests: Correct indentation.
16734         * tests/test-link.h (test_link): Correct indentation.
16736 2023-01-11  Bruno Haible  <bruno@clisp.org>
16738         Fix link errors on Android 4.3.
16739         * lib/asyncsafe-spin.c: Don't use the GCC >= 4.1 builtins on Android,
16740         when building with GCC.
16741         * lib/pthread-spin.c: Likewise.
16742         * lib/simple-atomic.c: Likewise.
16744 2023-01-10  Jim Meyering  <meyering@fb.com>
16746         update-copyright: also work with two or more updatable lines in a file
16747         * build-aux/update-copyright: Replace every occurrence of the copyright
16748         line, not just the first one.
16749         * tests/test-update-copyright.sh: Add a test case for this.
16751 2023-01-10  Bruno Haible  <bruno@clisp.org>
16753         immutable: Fix initialization failure on Android.
16754         * lib/immutable.c: Include "pathmax.h".
16755         (do_init_mmap_file): Use $TMPDIR rather than /tmp, if it is safe.
16756         * modules/immutable (Depends-on): Add pathmax.
16758 2023-01-10  Bruno Haible  <bruno@clisp.org>
16760         Fix some test failures on Android ≥ 11.
16761         * tests/test-fclose.c (main): On Android, avoid triggering the
16762         file-descriptor sanitizer (fdsan).
16763         * tests/test-fdopen.c (main): Likewise.
16764         * tests/test-fflush.c (main): Likewise.
16765         * tests/test-fgetc.c (main): Likewise.
16766         * tests/test-fputc.c (main): Likewise.
16767         * tests/test-fread.c (main): Likewise.
16768         * tests/test-fseeko4.c (main): Likewise.
16769         * tests/test-ftello4.c (main): Likewise.
16770         * tests/test-fwrite.c (main): Likewise.
16772 2023-01-10  Bruno Haible  <bruno@clisp.org>
16774         utimens: Fix warning on Android.
16775         * m4/utimens.m4 (gl_UTIMENS): Test for futimesat and futimes using
16776         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16778 2023-01-10  Bruno Haible  <bruno@clisp.org>
16780         secure_getenv: Fix warning on Android.
16781         * m4/secure_getenv.m4 (gl_FUNC_SECURE_GETENV): Test for issetugid using
16782         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS.
16783         * lib/secure_getenv.c: Fix comment regarding issetugid.
16785 2023-01-10  Bruno Haible  <bruno@clisp.org>
16787         renameat, renameatu: Fix warning on Android.
16788         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Test for renameat2 using
16789         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
16791 2023-01-10  Bruno Haible  <bruno@clisp.org>
16793         memset_explicit tests: Fix signature check.
16794         * tests/test-memset_explicit.c: Fix return type in signature check.
16796 2023-01-10  Bruno Haible  <bruno@clisp.org>
16798         math: Fix compilation errors in C++ mode on Android.
16799         * lib/math.in.h: Declare nothing if this file gets included from
16800         /usr/include/c++/v1/math.h too early.
16802 2023-01-10  Bruno Haible  <bruno@clisp.org>
16804         sys_ioctl: Fix compilation error in C++ mode on Android.
16805         * lib/sys_ioctl.in.h (ioctl): Disable _GL_CXXALIASWARN invocation on
16806         non-glibc systems.
16808 2023-01-09  Bruno Haible  <bruno@clisp.org>
16810         threads-h: Improve portability.
16811         * lib/threads.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE when possible.
16812         * modules/threads-h (Makefile.am): Substitute
16813         INCLUDE_NEXT_AS_FIRST_DIRECTIVE and NEXT_AS_FIRST_DIRECTIVE_THREADS_H.
16815 2023-01-09  Bruno Haible  <bruno@clisp.org>
16817         threads-h: Fix compilation errors in C++ mode on Android.
16818         * lib/threads.in.h (_GL_ALREADY_INCLUDING_THREADS_H): New macro.
16820 2023-01-09  Bruno Haible  <bruno@clisp.org>
16822         aligned-malloc: Don't disturb the module aligned_alloc.
16823         * modules/aligned-malloc (configure.ac): Test for aligned_alloc in the
16824         same way as module aligned_alloc does.
16826 2023-01-09  Bruno Haible  <bruno@clisp.org>
16828         malloc-h: Improve portability.
16829         * lib/malloc.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE when possible.
16830         * modules/malloc-h (Makefile.am): Substitute
16831         INCLUDE_NEXT_AS_FIRST_DIRECTIVE and NEXT_AS_FIRST_DIRECTIVE_MALLOC_H.
16833 2023-01-09  Bruno Haible  <bruno@clisp.org>
16835         reallocarray: Fix compilation error in C++ mode on Android.
16836         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY): Use gl_CHECK_FUNCS_ANDROID
16837         instead of AC_CHECK_FUNCS.
16839 2023-01-09  Bruno Haible  <bruno@clisp.org>
16841         getsubopt: Fix compilation error in C++ mode on Android.
16842         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Use gl_CHECK_FUNCS_ANDROID
16843         instead of AC_CHECK_FUNCS_ONCE.
16845 2023-01-09  Bruno Haible  <bruno@clisp.org>
16847         malloc-h: Fix compilation errors in C++ mode on Android.
16848         * lib/malloc.in.h: Don't include <stdlib.h>, except on Solaris and on
16849         HP-UX. Include <stddef.h>. Make _GL_ATTRIBUTE_DEALLOC_FREE work (code
16850         snippet copied from string.in.h and wchar.in.h).
16851         * m4/malloc_h.m4 (gl_MALLOC_H_REQUIRE_DEFAULTS): Invoke
16852         gl_STDLIB_H_REQUIRE_DEFAULTS.
16853         * modules/malloc-h (Depends-on): Add stddef, stdlib.
16854         (Makefile.am): Substitute GNULIB_FREE_POSIX and REPLACE_FREE.
16856 2023-01-09  Bruno Haible  <bruno@clisp.org>
16858         gettime: Fix compilation error in C++ mode on Android.
16859         * m4/gettime.m4 (gl_CHECK_FUNC_TIMESPEC_GET): Also test whether
16860         timespec_get is declared.
16862 2023-01-09  Bruno Haible  <bruno@clisp.org>
16864         malloc-h: Fix compilation error in C++ mode on Android.
16865         * lib/malloc.in.h (_GL_ALREADY_INCLUDING_MALLOC_H): New macro.
16867 2023-01-07  Bruno Haible  <bruno@clisp.org>
16869         timer_time: Rename LIB_TIMER_TIME to TIMER_TIME_LIB.
16870         * m4/timer_time.m4: Rename LIB_TIMER_TIME to TIMER_TIME_LIB.
16871         All uses changed.
16872         * NEWS: Mention the change
16874 2023-01-07  Bruno Haible  <bruno@clisp.org>
16876         setlocale-null: Rename LIB_SETLOCALE_NULL to SETLOCALE_NULL_LIB.
16877         * m4/setlocale_null.m4: Rename LIB_SETLOCALE_NULL to SETLOCALE_NULL_LIB.
16878         All uses changed.
16879         * NEWS: Mention the change
16881 2023-01-07  Bruno Haible  <bruno@clisp.org>
16883         setlocale: Rename LIB_SETLOCALE to SETLOCALE_LIB.
16884         * m4/setlocale.m4: Rename LIB_SETLOCALE to SETLOCALE_LIB.
16885         All uses changed.
16886         * NEWS: Mention the change.
16888 2023-01-07  Bruno Haible  <bruno@clisp.org>
16890         select: Rename LIB_SELECT to SELECT_LIB.
16891         * m4/select.m4: Rename LIB_SELECT to SELECT_LIB.
16892         All uses changed.
16893         * NEWS: Mention the change.
16895 2023-01-07  Bruno Haible  <bruno@clisp.org>
16897         sched_yield: Rename LIB_SCHED_YIELD to SCHED_YIELD_LIB.
16898         * m4/threadlib.m4: Rename LIB_SCHED_YIELD to SCHED_YIELD_LIB.
16899         All uses changed.
16900         * NEWS: Mention the change.
16902 2023-01-07  Bruno Haible  <bruno@clisp.org>
16904         pthread_sigmask: Rename LIB_PTHREAD_SIGMASK to PTHREAD_SIGMASK_LIB.
16905         * m4/pthread_sigmask.m4: Rename LIB_PTHREAD_SIGMASK to
16906         PTHREAD_SIGMASK_LIB.
16907         All uses changed.
16908         * NEWS: Mention the change.
16910 2023-01-07  Bruno Haible  <bruno@clisp.org>
16912         posix_spawn: Rename LIB_POSIX_SPAWN to POSIX_SPAWN_LIB.
16913         * m4/spawn_h.m4: Rename LIB_POSIX_SPAWN to POSIX_SPAWN_LIB.
16914         All uses changed.
16915         * NEWS: Mention the change.
16917 2023-01-07  Bruno Haible  <bruno@clisp.org>
16919         poll: Rename LIB_POLL to POLL_LIB.
16920         * m4/poll.m4: Rename LIB_POLL to POLL_LIB.
16921         All uses changed.
16922         * NEWS: Mention the change.
16924 2023-01-07  Bruno Haible  <bruno@clisp.org>
16926         nanosleep: Rename LIB_NANOSLEEP to NANOSLEEP_LIB.
16927         * m4/nanosleep.m4: Rename LIB_NANOSLEEP to NANOSLEEP_LIB.
16928         All uses changed.
16929         * NEWS: Mention the change.
16931 2023-01-07  Bruno Haible  <bruno@clisp.org>
16933         mbrtowc: Rename LIB_MBRTOWC to MBRTOWC_LIB.
16934         * m4/mbrtowc.m4: Rename LIB_MBRTOWC to MBRTOWC_LIB.
16935         All uses changed.
16936         * NEWS: Mention the change.
16938 2023-01-07  Bruno Haible  <bruno@clisp.org>
16940         hard-locale: Rename LIB_HARD_LOCALE to HARD_LOCALE_LIB.
16941         * modules/hard-locale (configure.ac): Rename LIB_HARD_LOCALE to
16942         HARD_LOCALE_LIB.
16943         All uses changed.
16944         * NEWS: Mention the change.
16946 2023-01-07  Bruno Haible  <bruno@clisp.org>
16948         getrandom: Rename LIB_GETRANDOM to GETRANDOM_LIB.
16949         * m4/getrandom.m4: Rename LIB_GETRANDOM to GETRANDOM_LIB.
16950         All uses changed.
16951         * NEWS: Mention the change.
16953 2023-01-07  Bruno Haible  <bruno@clisp.org>
16955         getlogin, getlogin_r: Rename LIB_GETLOGIN to GETLOGIN_LIB.
16956         * m4/getlogin.m4: Rename LIB_GETLOGIN to GETLOGIN_LIB.
16957         All uses changed.
16958         * NEWS: Mention the change.
16960 2023-01-07  Bruno Haible  <bruno@clisp.org>
16962         gethrxtime: Rename LIB_GETHRXTIME to GETHRXTIME_LIB.
16963         * m4/gethrxtime.m4: Rename LIB_GETHRXTIME to GETHRXTIME_LIB.
16964         All uses changed.
16965         * NEWS: Mention the change.
16967 2023-01-07  Bruno Haible  <bruno@clisp.org>
16969         fdatasync: Rename LIB_FDATASYNC to FDATASYNC_LIB.
16970         * m4/fdatasync.m4: Rename LIB_FDATASYNC to FDATASYNC_LIB.
16971         All uses changed.
16972         * NEWS: Mention the change.
16974 2023-01-07  Bruno Haible  <bruno@clisp.org>
16976         euidaccess: Rename LIB_EACCESS to EUIDACCESS_LIBGEN.
16977         * m4/euidaccess.m4: Rename LIB_EACCESS to EUIDACCESS_LIBGEN.
16978         All uses changed.
16979         * NEWS: Mention the change.
16981 2023-01-07  Bruno Haible  <bruno@clisp.org>
16983         duplocale: Rename LIB_DUPLOCALE to DUPLOCALE_LIB.
16984         * m4/duplocale.m4: Rename LIB_DUPLOCALE to DUPLOCALE_LIB.
16985         All uses changed.
16986         * NEWS: Mention the change.
16988 2023-01-07  Bruno Haible  <bruno@clisp.org>
16990         clock_time: Rename LIB_CLOCK_GETTIME to CLOCK_TIME_LIB.
16991         * m4/clock_time.m4: Rename LIB_CLOCK_GETTIME to CLOCK_TIME_LIB.
16992         All uses changed.
16993         * NEWS: Mention the change.
16995 2023-01-06  Paul Eggert  <eggert@cs.ucla.edu>
16997         file-has-acl: don’t bother setting LIB_HAS_ACL
16998         * m4/acl.m4 (gl_FUNC_ACL, gl_FILE_HAS_ACL): Don’t set LIB_HAS_ACL.
16999         I think only Coreutils and Tar used it, and I’ve updated them.
17001         bootstrap: suppress stray message from --pull
17002         * build-aux/bootstrap: Regenerate.
17003         * top/bootstrap-funclib.sh (autopull): Suggest running autogen.sh
17004         only if it exists (i.e., the package is using autopull.sh/autogen.sh).
17005         Suggest the same name for autogen.sh that is used in the test.
17007 2023-01-05  Bruno Haible  <bruno@clisp.org>
17009         string: Fix compilation errors in C++ mode on Android.
17010         * lib/string.in.h (memrchr, strchrnul, strcasestr): Disable
17011         _GL_CXXALIASWARN invocation on non-glibc systems.
17013 2023-01-05  Bruno Haible  <bruno@clisp.org>
17015         getpass: Fix compilation error on Android.
17016         * m4/getpass.m4 (gl_FUNC_GETPASS): Define NO_INLINE_GETPASS.
17017         * doc/glibc-functions/getpass.texi: Mention the Android problem.
17019 2023-01-05  Bruno Haible  <bruno@clisp.org>
17021         Recognize functions added in future versions of Android.
17022         * m4/gnulib-common.m4 (gl_CHECK_FUNCS_ANDROID): New macro.
17023         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Use
17024         gl_CHECK_FUNCS_ANDROID instead of AC_CHECK_FUNCS_ONCE.
17025         * m4/freading.m4 (gl_FUNC_FREADING): Likewise.
17026         * m4/fseterr.m4 (gl_FUNC_FSETERR): Likewise.
17027         * m4/fwriting.m4 (gl_FUNC_FWRITING): Likewise.
17028         * m4/getentropy.m4 (gl_FUNC_GETENTROPY): Likewise.
17029         * m4/getlogin_r.m4 (gl_CHECK_FUNCS_ANDROID): Likewise.
17030         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
17031         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
17032         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): Likewise.
17033         * doc/glibc-functions/getentropy.texi: Mark function as existing in
17034         Android 9.0.
17035         * doc/glibc-functions/getrandom.texi: Likewise.
17036         * doc/posix-functions/pthread_attr_getinheritsched.texi: Likewise.
17037         * doc/posix-functions/pthread_attr_setinheritsched.texi: Likewise.
17039 2023-01-05  Bruno Haible  <bruno@clisp.org>
17041         copy-file, supersede: Fix link-time requirements.
17042         * modules/copy-file (Link): Add $(LIB_ACL).
17043         * modules/supersede (Link): Likewise.
17045 2023-01-05  Bruno Haible  <bruno@clisp.org>
17047         More systematic naming of LIB variables.
17048         * m4/acl.m4 (gl_FUNC_ACL, gl_FILE_HAS_ACL): Set FILE_HAS_ACL_LIB to the
17049         same value as LIB_HAS_ACL.
17050         * modules/file-has-acl (Link): Use FILE_HAS_ACL_LIB instead of
17051         LIB_HAS_ACL.
17052         * modules/file-has-acl-tests (Makefile.am): Likewise.
17054 2023-01-04  Bruno Haible  <bruno@clisp.org>
17056         doc: Update regarding Android.
17057         * doc/glibc-functions/getdtablesize.texi: Update Android information.
17058         * doc/glibc-functions/wait3.texi: Likewise.
17059         * doc/pastposix-functions/ftime.texi: Likewise.
17060         * doc/pastposix-functions/index.texi: Likewise.
17061         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Likewise.
17062         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Likewise.
17063         * doc/pastposix-functions/wcswcs.texi: Likewise.
17065 2023-01-03  Bruno Haible  <bruno@clisp.org>
17067         ffsl, ffsll: Fix compilation error on Android.
17068         * lib/string.in.h: On Android as well, include <strings.h>.
17069         * m4/ffsl.m4 (gl_FUNC_FFSL): Use a specific link test instead of
17070         AC_CHECK_FUNCS_ONCE.
17071         * m4/ffsll.m4 (gl_FUNC_FFSLL): Likewise.
17072         * doc/glibc-functions/ffsl.texi: Mention Android problems.
17073         * doc/glibc-functions/ffsll.texi: Likewise.
17075         ffs: Document Android problem.
17076         * doc/posix-functions/ffs.texi: Mention Android problem.
17077         * m4/ffs.m4: Update comment.
17079 2023-01-03  Bruno Haible  <bruno@clisp.org>
17081         stdio: Fix error in C++ mode on Android, due to putw.
17082         * lib/stdio.in.h (putw): Don't declare in the C++ namespace if putw is
17083         not declared.
17084         * m4/stdio_h.m4 (gl_STDIO_H): Test whether putw is declared.
17085         (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_PUTW.
17086         * modules/stdio (Makefile.am): Substitute HAVE_DECL_PUTW.
17087         * doc/glibc-functions/putw.texi: Update regarding Android.
17089 2023-01-03  Bruno Haible  <bruno@clisp.org>
17091         stdio: Fix error in C++ mode on Android, due to getw.
17092         * lib/stdio.in.h (getw): Don't declare in the C++ namespace if getw is
17093         not declared.
17094         * m4/stdio_h.m4 (gl_STDIO_H): Test whether getw is declared.
17095         (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_GETW.
17096         * modules/stdio (Makefile.am): Substitute HAVE_DECL_GETW.
17098 2023-01-02  Bruno Haible  <bruno@clisp.org>
17100         sigsegv: Fix compilation error on Android 4.3.
17101         * lib/sigsegv.in.h: For Android, don't include <ucontext.h> and don't
17102         reference ucontext_t.
17103         * lib/sigsegv.c (SIGSEGV_FAULT_): For Android, use a plain POSIX fault
17104         handler (cf. libsigsegv/src/fault-posix.h).
17106 2023-01-01  Paul Eggert  <eggert@cs.ucla.edu>
17108         dfa: work around Clang 15 bug
17109         Problem reported by Kenton Groombridge in:
17110         https://lists.gnu.org/archive/html/bug-gawk/2022-12/msg00010.html
17111         On x86-64, Clang 15 gets confused by a call (X ? dfaerror :
17112         dfawarn) (Y) and generates the wrong code, presumably because
17113         dfaerror is _Noreturn and dfawarn is not.
17114         * lib/dfa.c (parse_bracket_exp): Reword to have one call for
17115         dfaerror, the other for dfawarn.
17117 2023-01-01  Bruno Haible  <bruno@clisp.org>
17119         doc: Update regarding stable branches.
17120         * doc/gnulib-readme.texi (Stable Branches): Mention new branch
17121         stable-202301. Mention that stable-202201 is no longer updated.
17123 2022-12-31  Paul Eggert  <eggert@cs.ucla.edu>
17125         maint: use UTC when updating copyright date
17126         Problem reported by Simon Josefsson in:
17127         https://lists.gnu.org/r/bug-gnulib/2022-12/msg00125.html
17128         * Makefile (COPYRIGHT_TZ): New macro.
17129         (update-copyright): Use it.
17131 2022-12-28  Paul Eggert  <eggert@cs.ucla.edu>
17133         assert-h: port static_assert to strict C99
17134         * lib/verify.h (_GL_VERIFY): Port MSVC hack back to C99.
17135         Problem found when testing bleeding-edge gzip on IBM XL C for AIX,
17136         V12.1 (5765-J02, 5725-C72), which complained ‘"malloca.c", line
17137         42.56: 1506-041 (E) The invocation of macro _Static_assert
17138         contains fewer arguments than are required by the macro
17139         definition.’  This diagnostic is valid because C99 requires
17140         that if you #define _Static_assert(R, ...) you must call
17141         _Static_assert with at least two arguments.  I found a similar
17142         problem with Sun C 5.9 SunOS_sparc Patch 124867-12 2009/11/22.
17144 2022-12-27  Paul Eggert  <eggert@cs.ucla.edu>
17146         file-has-acl: fix recently-introduced NFSv4 bug
17147         * lib/file-has-acl.c (acl_nfs4_nontrivial): Fix off-by-one
17148         error when rounding WHOLEN up to next multiple of 4.
17149         Pacify GCC 12.2.1 -Wcast-align.
17151         Add --pull, --gen options to build-aux/bootstrap
17152         This supports a single bootstrap script with --pull and --gen
17153         options, as an alternative to separate autogen.sh and autopull.sh
17154         and bootstrap-funclib.sh auxiliary files.
17155         * top/bootstrap: With --version, also output library version.
17156         Support update of package that has only the bootstrap script,
17157         and not the other three files.
17159         Support packages with just 'bootstrap'
17160         * top/bootstrap: With --version, also output library version.
17161         Support update of package that has only the bootstrap script,
17162         and not the other three files.
17164         * top/bootstrap-funclib.sh (scriptlibversion): Rename
17165         from scriptversion.  All uses changed.  This way we
17166         can distinguish script from script library versions.
17167         (upgrade_bootstrap): If the package currently has only
17168         the bootstrap script, just update that.
17170         Bootstrap with functions, not scripts
17171         * top/bootstrap: Use autopull and autogen functions, not
17172         shell scripts.  This lets build-aux/bootstrap become a
17173         standalone script.  It does not change the behavior of
17174         top/bootstrap, except for minor rewording of disagnostics.
17176         Make autopull a shell function too
17177         This does not change behavior.  It is helpful for future changes.
17178         * top/autopull.sh: Call autopull to do the actual work.
17179         (usage, download_po_files, update_po_files):
17180         Move to top/bootstrap-funclib.sh.
17181         * top/bootstrap-funclib.sh (autopull_usage): Rename from ‘usage’.
17182         (autopull): New function, containing the top level of the
17183         old top/autopull.sh.
17185         Make autogen a shell function too
17186         This does not change behavior.  It is helpful for future changes.
17187         * top/autogen.sh: Call autogen to do the actual work.
17188         (usage, version_controlled_file, gitignore_entries, insert_if_absent):
17189         (insert_vc_ignore, symlink_to_dir): Move to top/bootstrap-funclib.sh.
17190         * top/bootstrap-funclib.sh (autogen_usage): Rename from ‘usage’.
17191         (autogen): New function, containing the top level of the
17192         old top/autogen.sh.
17194 2022-12-27  Bruno Haible  <bruno@clisp.org>
17196         Fix compilation errors in C++ mode on Solaris 11 OpenIndiana.
17197         * m4/gnulib-common.m4 (gl_COMMON_BODY): In _GL_ATTRIBUTE_DEALLOC_FREE,
17198         with GNU C++, cast the 'free' function.
17199         * lib/string.in.h (_GL_ATTRIBUTE_DEALLOC_FREE): With GNU C++, cast the
17200         'free' function.
17201         * lib/wchar.in.h (_GL_ATTRIBUTE_DEALLOC_FREE): Likewise.
17203 2022-12-27  Bruno Haible  <bruno@clisp.org>
17205         stdnoreturn: Mark as deprecated, not obsolete. (Regression 2022-12-24.)
17206         * modules/stdnoreturn (Status): Remove.
17207         (Notice): Say that it is deprecated, not obsolete.
17208         * doc/noreturn.texi: Fix a typo.
17210 2022-12-26  Paul Eggert  <eggert@cs.ucla.edu>
17212         stdbool-c99: fix typo
17213         Reported against Autoconf by Todd C. Miller in:
17214         https://lists.gnu.org/r/autoconf/2022-12/msg00001.html
17215         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Sync from Autoconf master.
17217 2022-12-26  Bruno Haible  <bruno@clisp.org>
17219         ctime: Mark as deprecated, not obsolete. (Regression 2022-12-21.)
17220         * modules/ctime (Status): Remove.
17221         (Notice): Say that it is deprecated, not obsolete.
17223 2022-12-25  Paul Eggert  <eggert@cs.ucla.edu>
17225         largefile: sync from Autoconf master
17226         * m4/largefile.m4 (gl_SET_LARGEFILE_SOURCE): Test whether
17227         AC_SYS_YEAR2038 is defined when this macro is defined, not when it
17228         is used, as we now define AC_SYS_YEAR2038 later.
17229         (_AC_SYS_LARGEFILE_MACRO_VALUE): Remove.
17230         (_AC_SYS_YEAR2038_TEST_CODE, _AC_SYS_YEAR2038_OPTIONS)
17231         (_AC_SYS_YEAR2038_PROBE, _AC_SYS_YEAR2038_ENABLE)
17232         (_AC_SYS_YEAR2038_OPT_IN, AC_SYS_YEAR2038)
17233         (_AC_SYS_LARGEFILE_TEST_CODE, _AC_SYS_LARGEFILE_OPTIONS)
17234         (_AC_SYS_LARGEFILE_PROBE, _AC_SYS_LARGEFILE_ENABLE): New macros.
17235         (AC_SYS_LARGEFILE): Use them.
17236         * m4/year2038.m4: Remove.  All mentions removed.
17237         * modules/largefile, modules/year2038 (configure.ac-early):
17238         Do not require gl_YEAR2038_EARLY.
17239         * modules/year2038 (Depends-on): Depend on largefile.
17240         (configure.ac): Require AC_SYS_YEAR2038, not gl_YEAR2038.
17242 2022-12-24  Paul Eggert  <eggert@cs.ucla.edu>
17244         extensions: enable some C23 Annex F functions
17245         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
17246         Also define __STDC_WANT_IEC_60559_EXT__, for C23 Annex F
17247         functions like totalorder.  This syncs from Autoconf master.
17249         stdnoreturn: deprecate
17250         C23 says <stdnoreturn.h> is obsolescent, so deprecate the
17251         stdnoreturn module.  I don't think it was being used anyway
17252         as it had too many problems.
17253         * modules/stdnoreturn: Mark as obsolete.
17255 2022-12-23  Paul Eggert  <eggert@cs.ucla.edu>
17257         file-has-acl: improve recent NFSv4 support
17258         This fixes a link failure with emacsclient on GNU/Linux.  This
17259         program wants file_has_acl but none of the other ACL primitives,
17260         so it doesn’t link acl-internal.o; this way it doesn’t need to
17261         link with -lacl.  While I was at it I reviewed the recent changes,
17262         fixed some unlikely overflow bugs, and adjusted to GNU style.
17263         * doc/acl-nfsv4.txt: Remove.  Its contents are now in a
17264         comment in lib/file-has-acl.c.
17265         * lib/acl-internal.c, lib/acl-internal.h: Move recent changes
17266         relating to acl_nfs4_nontrivial to lib/file-has-acl.c, so that
17267         there is no trouble linking programs that need only file_has_acl.
17268         * lib/file-has-acl.c (acl_nfs4_nontrivial): Move here from
17269         lib/acl-internal.c, so that we needn't link -lacl in
17270         programs that want only file_has_acl, such as emacsclient.
17271         Do not assume a char buffer is aligned for uint32_t.
17272         Check more carefully for buffer read overrun.
17273         Allow up to 6 ACEs, since other code does; but check
17274         that they’re distinct.  Avoid integer overflow.
17275         Use memcmp rather than strncmp to compare memory blocks.
17276         (file_has_acl): Preserve initial errno instead of setting to 0.
17277         Allocate a bit more room for trivial ACL buffer.
17278         Use EINVAL for botchedk NFSv4 ACLs (which shouldn’t happen).
17280 2022-12-22  Paul Eggert  <eggert@cs.ucla.edu>
17282         posix_spawnp-tests: fix filename typo
17283         Problem reported for GNU m4 by Mitchell Dorrell in:
17284         https://lists.gnu.org/r/bug-m4/2022-12/msg00000.html
17285         * tests/test-posix_spawnp-script.c (DATA_FILENAME):
17286         Fix typo in file name that caused race with
17287         test-posix_spawn-script.c.
17289 2022-12-22  Ondrej Valousek  <ondrej.valousek.xm@renesas.com>
17291         file-has-acl: Basic support for checking NFSv4 ACLs in Linux.
17292         * lib/acl-internal.h (acl_nfs4_nontrivial): New declaration.
17293         * lib/acl-internal.c (acl_nfs4_nontrivial): New function.
17294         * lib/file-has-acl.c: Include <arpa/inet.h>.
17295         (XATTR_NAME_NFSV4_ACL, TRIVIAL_NFS4_ACL_MAX_LENGTH): New macros.
17296         (file_has_acl): Test for NFSv4 ACLs.
17297         * doc/acl-nfsv4.txt: New file.
17299 2022-12-21  Paul Eggert  <eggert@cs.ucla.edu>
17301         Port __has_c_attribute to strict C23
17302         * m4/gnulib-common.m4 (_GL_HAS_C_ATTRIBUTE): Remove, as C23 says
17303         behavior is undefined if __has_c_attribute appears anywhere other
17304         than at the top level of an #if or #ifdef.  All uses replaced by
17305         wordier invocations of __has_c_attribute.
17307         asctime, ctime: deprecate
17308         C23 deprecates asctime and ctime, so deprecate them in Gnulib too.
17309         * NEWS, doc/posix-functions/asctime.texi:
17310         * doc/posix-functions/ctime.texi: Mention this.
17311         * lib/time.in.h (ctime): Deprecate any ctime replacement.
17312         * modules/ctime: Now obsolete.
17314 2022-12-17  Paul Eggert  <eggert@cs.ucla.edu>
17316         memset_explicit: port to older MS-Windows
17317         * lib/memset_explicit.c (memset_explicit):
17318         Remove special case for C==0 and MS-Windows.  The code isn’t
17319         needed for correctness and it’s more trouble than it’s worth as it
17320         prevents this module from being used with GNU Emacs, which wants
17321         to port to MS-Windows versions so old that they lack
17322         SecureZeroMemory.
17324 2022-12-09  Bruno Haible  <bruno@clisp.org>
17326         Update users.txt.
17327         * users.txt: Add lbzip2.
17329 2022-12-09  Paul Eggert  <eggert@cs.ucla.edu>
17331         fts: make debug version compilable again
17332         This fixes things in what I hope is a better way than the
17333         fd-only approach proposed by Kamil Dudka here:
17334         https://lists.gnu.org/archive/html/bug-gnulib/2018-03/msg00079.html
17335         https://lists.gnu.org/archive/html/bug-gnulib/2018-03/msg00080.html
17336         * lib/fts.c (GNULIB_FTS_DEBUG): Rename from FTS_DEBUG,
17337         to avoid collision with coreutils symbol.
17338         Do not include <stdint.h> (not needed, since we include <stdint.h>)
17339         or "getcwdat.h" (no longer exists).
17340         (fd_ring_check, fd_ring_print): Add forward decls.
17341         (struct devino): New type.
17342         (PRINT_DEVINO): New macro.
17343         (getdevino): New static function.
17344         (fd_ring_print): Do nothing if not debugging.
17345         (fd_ring_print, fd_ring_check): Use getdevino instead of getcwdat.
17346         The output isn’t as good, but at least it compiles and runs.
17348 2022-12-07  Paul Eggert  <eggert@cs.ucla.edu>
17350         verify: update __STDC_VERSION__ as per C23
17351         This shouldn’t affect anything; it’s merely a refactoring.
17352         * lib/verify.h (_GL_HAVE__STATIC_ASSERT1): Require
17353         __STDC_VERSION__ to be at least 202311, instead of at least
17354         202000.  The latter number was put in in 2019 because we didn’t
17355         yet know C23’s __STDC_VERSION__ value.
17357 2022-12-06  Paul Eggert  <eggert@cs.ucla.edu>
17359         fts: fix race + mishandling of fstatat failure
17360         I hope this fixes a Luke Dashjr coreutils bug report about ext4
17361         ramdisks; see “9.1: du Aborted (corrupt filesystem)”
17362         <https://debbugs.gnu.org/59821>.
17363         * lib/fts.c (fts_build): Fix two bugs.  First, fts_stat was being
17364         called without checking its return value, causing a later abort.
17365         Second, there was a race between opening a directory and statting
17366         it, fixed by using fstat on the file descriptor rather than
17367         fstatat on the directory name.
17369         fts: omit goto break_without_closedir
17370         * lib/fts.c (fts_build): Refactor to omit goto.
17372         fts: clarify ISSET
17373         * lib/fts.c (ISSET): Refactor to clarify boolean usage.
17375 2022-12-05  Bruno Haible  <bruno@clisp.org>
17377         argp: Correct documentation.
17378         Reported by José E. Marchesi <jemarch@gnu.org>.
17379         * doc/glibc-functions/argp_*.texi: Mention the 'argp' module.
17381 2022-12-02  Pádraig Brady  <P@draigBrady.com>
17383         doc: poll: document poll of special files not supported on macOS
17384         * doc/posix-functions/poll.texi: Reinstate (updated) macOS info,
17385         removed in recent cleanup re removal of support for Mac OS X <= 10.4.
17386         * m4/poll.m4: Update macOS to latest tested version.
17388 2022-11-29  Pádraig Brady  <P@draigBrady.com>
17390         add new ronna and quetta SI prefixes
17391         As voted for in Nov 2022 by the BIPM:
17392         https://www.bipm.org/en/cgpm-2022/resolution-3
17394         * lib/human.c: Add Ronna (10^27), and Quetta (10^30) to the prefix list.
17395         * lib/xstrtol.c (__xstrtol): Likewise.
17397 2022-11-29  Bruno Haible  <bruno@clisp.org>
17399         Update users.txt.
17400         * users.txt: Add 4ti2, ale, amanda, binfmt-support, cgminer, collectd,
17401         complexity, dc3dd, dico, enchant-2, fuse-overlayfs, gsequencer, idutils,
17402         libu2f-host, licenseutils, mmv, pacemaker, trader, ttfautohint.
17404 2022-11-27  Paul Eggert  <eggert@cs.ucla.edu>
17406         explicit_bzero: implement via memset_explicit
17407         * lib/explicit_bzero.c (explicit_bzero):
17408         Simplify by just calling memset_explicit.
17409         * m4/explicit_bzero.m4 (gl_PREREQ_EXPLICIT_BZERO): Remove.
17410         All uses removed.
17411         * modules/explicit_bzero (Depends-on): Add memset_explicit.
17413         explicit_bzero: memset_explicit is standard
17414         * doc/glibc-functions/explicit_bzero.texi:
17415         Say that memset_explicit is preferred in new code.
17417         read-file: use memset_explicit
17418         * lib/read-file.c (fread_file, read_file):
17419         Use memset_explicit instead of explicit_bzero.
17420         * modules/read-file (Depends-on): Depend on memset_explicit
17421         instead of on explicit_bzero.
17423         memset_explicit: new module
17424         * doc/posix-functions/memset_explicit.texi, lib/memset_explicit.c:
17425         * m4/memset_explicit.m4, modules/memset_explicit:
17426         * modules/memset_explicit-tests, tests/test-memset_explicit.c:
17427         New files.
17428         * lib/string.in.h (memset_explict): New decl.
17429         * m4/string_h.m4 (gl_STRING_H, gl_STRING_H_REQUIRE_DEFAULTS)
17430         (gl_STRING_H_DEFAULTS):
17431         * modules/string (string.h):
17432         Support memset_explicit.
17434         explicit_bzero: add poison
17435         * m4/string_h.m4 (gl_STRING_H): Poison explicit_bzero.
17436         This was inadvertently omitted when explicit_bzero was added.
17438 2022-11-27  Arsen Arsenović  <arsen@aarsen.me>
17440         bootstrap: Fix --help output.
17441         * build-aux/bootstrap (usage): Regenerate.
17443 2022-11-27  Paul Eggert  <eggert@cs.ucla.edu>
17445         explicit_bzero: work with gcc -std=c99
17446         * lib/explicit_bzero.c (explicit_bzero) [__GNUC__ && !__clang__]:
17447         Use __asm__ instead of asm.
17449 2022-11-26  Paul Eggert  <eggert@cs.ucla.edu>
17451         Prefer "kill -INT" to killing with a number
17452         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
17453         * tests/test-login_tty.c (main):
17454         * tests/test-pthread_sigmask1.c (main):
17455         * tests/test-sigprocmask.c (main):
17456         Prefer "kill -INT" to "kill -N" where N is SIGINT’s value.
17457         Don’t assume pid_t fits in int.
17459 2022-11-25  Bruno Haible  <bruno@clisp.org>
17461         In 'trap' commands, prefer symbolic to numeric signal names.
17462         Reported by Mike Fulton <fultonm@ca.ibm.com> in
17463         <https://lists.gnu.org/archive/html/bug-gnulib/2022-11/msg00130.html>.
17464         * gnulib-tool: Use symbolic signal names.
17465         * posix-modules: Likewise.
17466         * MODULES.html.sh: Likewise.
17467         * build-aux/bootstrap (prepare_GNULIB_SRCDIR): Likewise.
17468         * build-aux/csharpcomp.sh.in: Likewise.
17469         * build-aux/gnu-web-doc-update: Likewise.
17470         * top/autogen.sh: Likewise.
17471         * top/bootstrap-funclib.sh: Likewise.
17472         * top/gitsub.sh: Likewise.
17473         * lib/t-idcache: Likewise.
17474         * tests/havelib/rpath-1: Likewise.
17475         * tests/havelib/rpath-2_a: Likewise.
17476         * tests/havelib/rpath-2_b: Likewise.
17477         * tests/havelib/rpath-3_a: Likewise.
17478         * tests/havelib/rpath-3_b: Likewise.
17479         * tests/init.sh: Likewise.
17480         * tests/test-binary-io.sh: Likewise.
17481         * tests/test-c-stack.sh: Likewise.
17482         * tests/test-c-stack2.sh: Likewise.
17483         * tests/test-dprintf-posix.sh: Likewise.
17484         * tests/test-fpending.sh: Likewise.
17485         * tests/test-fprintf-posix.sh: Likewise.
17486         * tests/test-lseek.sh: Likewise.
17487         * tests/test-printf-posix.sh: Likewise.
17488         * tests/test-select-in.sh: Likewise.
17489         * tests/test-select-out.sh: Likewise.
17490         * tests/test-sigpipe.sh: Likewise.
17491         * tests/test-tsearch.sh: Likewise.
17492         * tests/test-update-copyright.sh: Likewise.
17493         * tests/test-vdprintf-posix.sh: Likewise.
17494         * tests/test-vfprintf-posix.sh: Likewise.
17495         * tests/test-vprintf-posix.sh: Likewise.
17496         * tests/test-xprintf-posix.sh: Likewise.
17497         * tests/uniwidth/test-uc_width2.sh: Likewise.
17499 2022-11-20  Bruno Haible  <bruno@clisp.org>
17501         posix_spawn-internal: Avoid warning on macOS.
17502         Suggested by Minsoo Choo in
17503         <https://lists.gnu.org/archive/html/bug-gnulib/2022-11/msg00114.html>.
17504         * lib/spawni.c: Ignore -Wdeprecated-declarations warnings.
17506 2022-11-20  Bruno Haible  <bruno@clisp.org>
17508         posix_spawn tests: Fix compilation error (regression 2022-09-14).
17509         * modules/posix_spawn-tests (Makefile.am): Augment DEFS, to define
17510         EXEEXT.
17512 2022-11-14  Paul Eggert  <eggert@cs.ucla.edu>
17514         parse-datetime: improve doc formatting, timeliness
17515         * doc/parse-datetime.texi: Use @samp and @code in menus
17516         for consistenty with how the Coreutils manual will do
17517         this sort of thing.  Update examples to this year.
17519 2022-11-13  Simon Josefsson  <simon@josefsson.org>
17521         vc-list-files-tests: Avoid OpenPGP private key operations.
17522         * tests/test-vc-list-files-git.sh (GIT_CONFIG_GLOBAL): Set it to
17523         /dev/null.
17525 2022-11-03  Bruno Haible  <bruno@clisp.org>
17527         dynarray: Rename to glibc-internal/dynarray.
17528         * modules/glibc-internal/dynarray: Renamed from modules/dynarray.
17529         * modules/glibc-internal/dynarray-tests: Renamed from
17530         modules/dynarray-tests.
17531         * modules/regex (Depends-on): Update.
17532         * NEWS: Mention this change and the previous one.
17534 2022-11-03  Bruno Haible  <bruno@clisp.org>
17536         scratch_buffer: Rename to glibc-internal/scratch_buffer.
17537         * modules/glibc-internal/scratch_buffer: Renamed from
17538         modules/scratch_buffer.
17539         * modules/glibc-internal/scratch_buffer-tests: Renamed from
17540         modules/scratch_buffer-tests.
17541         * modules/canonicalize (Depends-on): Update.
17542         * modules/canonicalize-lgpl (Depends-on): Likewise.
17543         * modules/glob (Depends-on): Likewise.
17545 2022-11-02  Bruno Haible  <bruno@clisp.org>
17547         scratch_buffer: Document last change.
17548         * NEWS: Mention last change.
17550 2022-11-02  Paul Eggert  <eggert@cs.ucla.edu>
17552         scratch_buffer: adjust to glibc changes
17553         Problem reported by Karl Berry in:
17554         https://lists.gnu.org/r/bug-gnulib/2022-11/msg00004.html
17555         * build-aux/depcomp, doc/make-stds.texi, lib/malloc/scratch_buffer.h:
17556         Autoupdate.
17557         * build-aux/install-reloc (func_create_wrapper):
17558         Omit removed file scratch_buffer_dupfree.c.
17559         * config/srclist.txt: Remove lib/malloc/scratch_buffer_dupfree.c
17560         * lib/canonicalize-lgpl.c: Merge changes from glibc through its
17561         commit ef0700004bf0dccf493a5e8e21f71d9e7972ea9f dated 2022-07-05
17562         11:04:45 +0200.
17563         (__strdup) [!_LIBC]: New macro.
17564         (struct realpath_bufs): New type.
17565         (realpath_stk): Use it as the extra argument.  All uses changed.
17566         No longer any need for noinline or GCC_BOGUS_WRETURN_LOCAL_ADDR.
17567         * lib/canonicalize.c (struct realpath_bufs)
17568         (canonicalize_filename_mode_stk): Likewise.
17569         * lib/malloc/scratch_buffer_dupfree.c:
17570         Remove, since it was removed in glibc.
17571         * lib/scratch_buffer.h (scratch_buffer_dupfree) [0]:
17572         (__libc_scratch_buffer_dupfree): Remove decls.
17573         * modules/relocatable-prog-wrapper (Files):
17574         * modules/scratch_buffer (Files, lib_SOURCES):
17575         Remove lib/malloc/scratch_buffer_dupfree.c.
17577 2022-11-01  Bruno Haible  <bruno@clisp.org>
17579         relocatable-script: Relax license.
17580         * modules/relocatable-script (License): Change to GPLv2+.
17581         * build-aux/relocatable.sh.in: Change copyright header to GPLv2+.
17583 2022-10-31  Simon Josefsson  <simon@josefsson.org>
17585         maintainer-makefile: Fix Apple Xcode 'make syntax-check'.
17586         * top/maint.mk (sc_indent): Don't use non-GNU indent.
17588 2022-10-30  Paul Eggert  <eggert@cs.ucla.edu>
17590         thread: pacify gcc -Wbad-function-cast
17591         * lib/glthread/thread.h (gl_thread_self_pointer): With POSIX
17592         threads, cast the call to gl_thread_t before casting to void *.
17594         test-getlogin: pacify gcc -Wshadow
17595         * tests/test-getlogin.h (test_getlogin_result): Rename local.
17597 2022-10-25  Simon Josefsson  <simon@josefsson.org>
17599         gendocs: Output timestamp in English.
17600         * build-aux/gendocs.sh (SETLANG): Add LC_TIME= for "date".
17602 2022-10-23  Bruno Haible  <bruno@clisp.org>
17604         assert-h: Make static_assert work on Solaris 11.4.
17605         * m4/assert_h.m4 (gl_ASSERT_H): After including <assert.h>, on Solaris,
17606         redefine static_assert.
17608 2022-10-16  Bruno Haible  <bruno@clisp.org>
17610         getdelim: Work around buggy implementation on macOS 10.13.
17611         * doc/posix-functions/getdelim.texi: Mention the macOS bug.
17612         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Let the "checking for working
17613         getdelim function" test answer 'no' on macOS.
17615 2022-10-15  Bruno Haible  <bruno@clisp.org>
17617         Update to Unicode 15.0.0.
17619         * lib/gen-uni-tables.c (is_property_default_ignorable_code_point):
17620         Exclude 0x13439..0x1343F.
17621         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
17623         * All generated files under lib/uni* and tests/uni*: Regenerate.
17624         * tests/uniname/NameAliases.txt: Update.
17625         * tests/uniname/UnicodeData.txt: Update.
17626         * tests/uninorm/NormalizationTest.txt: Update.
17627         * tests/unigbrk/GraphemeBreakTest.txt: Update.
17628         * tests/uniwbrk/WordBreakTest.txt: Update.
17630         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
17631         0x0ECE, 0x10EFD..0x10EFF, 0x11241, 0x11F00..0x11F01, 0x11F36..0x11F3A,
17632         0x11F40, 0x11F42, 0x13439..0x13440, 0x13447..0x13455, 0x1E08F,
17633         0x1E4EC..0x1E4EF.
17635         * All the affected modules: Bump required libunistring version.
17637 2022-10-15  Bruno Haible  <bruno@clisp.org>
17639         gen-uni-tables: Temporarily revert last change.
17640         * lib/gen-uni-tables.c: Include <stdbool.h>, unless the C compiler
17641         advertises compliance to ISO C 23.
17643 2022-10-12  Paul Eggert  <eggert@cs.ucla.edu>
17645         doc: improve intprops doc
17646         * doc/intprops.texi: Tighten up wording, by saying that macros
17647         "yield 1 if X, 0 otherwise" rather than the weaker "yield 1 if X".
17648         Say "yield" rather than "return" since the macros are not
17649         functions.  Say "1" and "0" rather than "true" and "false" since
17650         the macros yield int.  Say that stdckdint.h is the standard
17651         alternative to the _WRAPV macros.  Mention another source of
17652         problems with the _OVERFLOW macros.
17654 2022-10-10  Paul Eggert  <eggert@cs.ucla.edu>
17656         tests: prefer stdckdint to intprops
17657         * modules/chown-tests, modules/fchownat-tests:
17658         * modules/fdutimensat-tests, modules/futimens-tests:
17659         * modules/lchown-tests, modules/stat-time-tests:
17660         * modules/utime-tests, modules/utimens-tests:
17661         * modules/utimensat-tests:
17662         (Depends on): Depend on stdckint, not intprops.
17663         * tests/nap.h: Include stdckdint.h, not intprops.h.
17664         All macro uses changed.
17666         stat-time: prefer stdckdint to intprops
17667         * lib/stat-time.h: Include stdckdint.h instead of intprops.h.
17668         (stat_time_normalize): Use ckd_add instead of INT_ADD_WRAPV.
17669         * modules/stat-time (Depends-on): Depend on stdckdint, not intprops.
17671         xalloc: remove stray includes + dependencies
17672         These used to be needed, but are not needed now.
17673         * lib/xalloc.h: Do not include stdlib.h.
17674         [GNULIB_XALLOC]: Do not include "intprops.h".
17675         * lib/xmalloc.c: Include stdint.h here instead, for SIZE_MAX.
17676         * modules/xalloc-die, modules/xvasprintf (Depends-on): Remove stdint.
17678 2022-09-30  Paul Eggert  <eggert@cs.ucla.edu>
17680         assert-h: suppress Apple clang 13 false alarms
17681         * m4/assert_h.m4 (gl_ASSERT_H): Suppress bogus warnings from Apple
17682         clang 13 (clang-1300.0.29.30).  Problem privately reported by
17683         Mattias Engdegård for GNU Emacs.
17685 2022-09-26  Daiki Ueno  <ueno@gnu.org>
17687         largefile: fix detection of time_t size on mingw32
17688         * modules/largefile (configure.ac-early): Ensure gl_YEAR2038_EARLY
17689         is invoked before gl_YEAR2038_BODY.
17691 2022-09-25  Paul Eggert  <eggert@cs.ucla.edu>
17693         fts: fix errno handling if dirfd fails
17694         * lib/fts.c (fts_build): Use proper errno if dirfd failed.
17695         Although I don’t know of any platform where dirfd can fail here,
17696         we might as well get it right.
17698 2022-09-25  Bruno Haible  <bruno@clisp.org>
17700         stdbool: Mostly revert last patch.
17701         * m4/c-bool.m4 (gl_C_BOOL): If stdbool.h does not exist, just err out.
17702         * modules/stdbool (Files): Remove m4/stdbool.m4.
17704 2022-09-24  Bruno Haible  <bruno@clisp.org>
17706         stdbool: Don't #include a gnulib-generated stdbool.h from config.h.
17707         * m4/c-bool.m4 (gl_C_BOOL): Check for stdbool.h and for _Bool. If
17708         stdbool.h does not exist, don't #include <stdbool.h> but instead put the
17709         substitute code into config.h.
17710         * modules/stdbool (Files): Add m4/stdbool.m4.
17712 2022-09-24  Bruno Haible  <bruno@clisp.org>
17714         stdalign: Don't #include a gnulib-generated stdalign.h from config.h.
17715         * m4/stdalign.m4 (gl_STDALIGN_H): Check for stdalign.h. If it does not
17716         exist, don't #include <stdalign.h> but instead put the substitute code
17717         into config.h.
17719 2022-09-24  Bruno Haible  <bruno@clisp.org>
17721         stdalign: Fix compilation error with MSVC in C++ mode.
17722         * lib/stdalign.in.h: Treat MSVC in C++ mode like C++11 compliant
17723         compilers.
17724         * tests/test-stdalign-c++.cc: Include some other header files.
17726         stdalign: Avoid namespace pollution.
17727         * lib/stdalign.in.h (_GL_STDALIGN_NEEDS_STDDEF): New macro.
17728         Include <stddef.h> only when needed.
17730 2022-09-23  Simon Josefsson  <simon@josefsson.org>
17732         warnings, manywarnings: Doc fixes.
17733         * doc/manywarnings.texi (manywarnings): Improve usage instruction.
17734         Start list of comments on particular warning flags, based on
17735         comment from Paul Eggert <eggert@cs.ucla.edu>.
17736         * doc/warnings.texi (warnings): Mention that it is often used with manywarnings.
17738 2022-09-21  Paul Eggert  <eggert@cs.ucla.edu>
17740         assert-h: suppress clang false alarms
17741         Suppress scads of annoying warnings from clang version 14.0.5
17742         (Fedora 14.0.5-1.fc36) of the form "warning: '_Static_assert' with
17743         no message is a C2x extension [-Wc2x-extensions]",
17744         by refusing to use single-arg static_assert with older clang.
17745         * m4/assert_h.m4 (gl_ASSERT_H): Turn -Wc2x-extensions from a
17746         warning into an error when testing static_assert, so that the
17747         annoying diagnostic causes the test to fail, which causes assert.h
17748         to be replaced in a way that suppresses the diagnostic during
17749         the real build.
17751 2022-09-20  Bruno Haible  <bruno@clisp.org>
17753         Add another helper script for creating testdirs.
17754         * all-modules: New file, based on posix-modules.
17756 2022-09-20  Bruno Haible  <bruno@clisp.org>
17758         snippet/warn-on-use: Don't cause wrong AC_CHECK_DECL results with clang.
17759         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Use the clang command-line
17760         option that disables implicit built-in function declarations in clang.
17762 2022-09-19  Bruno Haible  <bruno@clisp.org>
17764         stdbool, stdbool-c99 tests: Fix compilation error with clang/MSVC.
17765         * tests/test-stdbool.c (WORKING_BOOL): Define to 0 on compilers that
17766         define _MSC_VER.
17768 2022-09-18  Paul Eggert  <eggert@cs.ucla.edu>
17770         stdbool: omit ‘#undef true’
17771         This is mostly just simplification.
17772         * m4/c-bool.m4 (gl_C_BOOL): Test all preprocessors when
17773         !HAVE_C_BOOL, not merely __SUNPRO_CC.  Use the slightly
17774         more-elegant ‘!true’ instead of ‘true == 1’; this shouldn’t matter
17775         in practice and if it does matter we want to know about it anyway.
17776         Remove an unnecessary ‘#undef true’ that is simply commented out
17777         by ‘configure’; again, if true is already #defined to be 0 the
17778         system is so messed up we want to know about it anyway.
17780 2022-09-18  Bruno Haible  <bruno@clisp.org>
17782         stdbool: Ensure that 'true' can be used in the preprocessor.
17783         * m4/c-bool.m4 (gl_C_BOOL): With Sun C++, redefine 'true' if it does not
17784         evaluate to 1 in the preprocessor.
17786         stdbool-c99: Ensure that 'true' can be used in the preprocessor.
17787         * lib/stdbool.in.h (true): Redefine if it does not evaluate to 1 in the
17788         preprocessor.
17790 2022-09-18  Bruno Haible  <bruno@clisp.org>
17792         uni{case,ctype,gbrk,str}/base: Fix installed .h file (regr. 2022-09-10).
17793         * lib/unicase.in.h: Do include <stdbool.h>.
17794         * lib/unictype.in.h: Likewise.
17795         * lib/unigbrk.in.h: Likewise.
17796         * lib/unistr.in.h: Likewise.
17798 2022-09-18  Bruno Haible  <bruno@clisp.org>
17800         signal: Fix a C++ compilation error due to sched_yield on OpenBSD 6.0.
17801         * lib/signal.in.h: On OpenBSD, include <sys/param.h>. Don't include
17802         <pthread.h> on OpenBSD ≥ 5.1.
17804 2022-09-17  Paul Eggert  <eggert@cs.ucla.edu>
17806         explicit_bzero-tests: robustify a bit
17807         This is mostly to suppress GCC warnings, though I suppose it
17808         might also improve the test.
17809         * tests/test-explicit_bzero.c: Do not ignore -Wmaybe-uninitialized,
17810         as this warning should no longer be generated given the other changes.
17811         (test_heap): ASSERT that malloc succeeds, to suppress any GCC
17812         warning about relying on malloc succeeding.  Declare addr to be
17813         volatile, so that GCC does not deduce that it is heapbuf in
17814         disguise and diagnose using it after freeing it.
17815         (do_secret_stuff): Declare more things to be volatile, to avoid
17816         optimizations that might disturb the stack and/or mess up the test
17817         in other ways.  Pass last_stackbuf address as a parameter rather
17818         than having last_stackbuf be static, to avoid GCC warning about
17819         assigning address of a local to a static; all callers changed.
17821 2022-09-17  Bruno Haible  <bruno@clisp.org>
17823         wchar: Fix compilation errors in C++ mode on Solaris 11.3.
17824         * lib/wchar.in.h (wcsnlen, wcpcpy, wcpncpy, wcscasecmp, wcsncasecmp,
17825         wcsdup): Force declaration in C++ mode on Solaris (which does not
17826         declare these functions in the global namespace).
17828 2022-09-17  Bruno Haible  <bruno@clisp.org>
17830         swab: Fix compilation error with Sun C++ on Solaris 11.3.
17831         * lib/unistd.in.h (swab): For the C++ declaration, under Solaris 11 but
17832         not under Solaris 10, test also __XOPEN_OR_POSIX.
17834 2022-09-17  Bruno Haible  <bruno@clisp.org>
17836         time C++ tests: Fix link error on CentOS 5.
17837         * modules/time-c++-tests (Makefile.am): Link test-time-c++ against
17838         $(LIB_CLOCK_GETTIME).
17840 2022-09-14  Bruno Haible  <bruno@clisp.org>
17842         time: Fix compilation errors with clang/MSVC.
17843         * m4/time_h.m4 (gl_TIME_H): Test whether asctime_r and ctime_r are
17844         declared.
17845         * lib/time.in.h (asctime_r, ctime_r): Skip _GL_WARN_ON_USE invocations
17846         when these functions are not declared.
17848 2022-09-14  Bruno Haible  <bruno@clisp.org>
17850         verify: Avoid syntax error due to static_assert with clang in C++ mode.
17851         * lib/verify.h (static_assert): Don't define in clang C++ 6 or newer.
17852         * m4/assert_h.m4 (gl_ASSERT_H): If we don't need to define static_assert
17853         with clang in C++ mode, don't include <assert.h>.
17855 2022-09-14  Paul Eggert  <eggert@cs.ucla.edu>
17857         assert-h: work around include confusion
17858         * m4/assert_h.m4 (gl_ASSERT_H): Arrange for <config.h> to not
17859         include <assert.h> if assert is already defined.  This works
17860         around bugs in packages that mistakenly include <config.h> after
17861         including <assert.h> (typically due to double-inclusion of
17862         <config.h>).  Found in coreutils, which I plan to fix.
17864         stdbool: depend on C99
17865         Record that stdbool depends on C99 these days.
17866         This matters only for ancient compilers that need special
17867         flags to support C99 features.
17868         * modules/stdbool (Depends-on): Add c99.
17870 2022-09-14  Bruno Haible  <bruno@clisp.org>
17872         verify: Avoid syntax error due to static_assert with MSVC 14 in C++.
17873         * lib/verify.h (static_assert): For MSVC in C++ mode, use a definition
17874         that supports both the two-arguments and the one-argument syntax.
17876 2022-09-14  Bruno Haible  <bruno@clisp.org>
17878         posix_spawn-* tests: Fix test failure on mingw when libtool is in use.
17879         * tests/test-posix_spawn-inherit0.c (CHILD_PROGRAM_FILENAME): Add the
17880         EXEEXT suffix.
17881         * tests/test-posix_spawn-inherit1.c (CHILD_PROGRAM_FILENAME): Likewise.
17882         * tests/test-posix_spawn-open1.c (CHILD_PROGRAM_FILENAME): Likewise.
17883         * tests/test-posix_spawn-open2.c (CHILD_PROGRAM_FILENAME): Likewise.
17885 2022-09-14  Bruno Haible  <bruno@clisp.org>
17887         verify: Avoid syntax error due to static_assert with MSVC 14.
17888         * lib/verify.h (_Static_assert): Pass only the first argument to
17889         _GL_VERIFY.
17891 2022-09-13  Paul Eggert  <eggert@cs.ucla.edu>
17893         verify: treat GNU C++ 6 like recent C++
17894         * m4/assert_h.m4 (gl_ASSERT_H):
17895         If we check __cpp_static_assert < 201411, also check __GNUG__ < 6,
17896         for consistency with the previous change.
17898 2022-09-13  Bruno Haible  <bruno@clisp.org>
17900         verify: Avoid syntax error due to static_assert with GNU C++ 6.x.
17901         * lib/verify.h (static_assert): Don't define in GNU C++ 6 or newer.
17903 2022-09-13  Paul Eggert  <eggert@cs.ucla.edu>
17905         stdalign: prefer to not include <stdalign.h>
17906         * lib/alignalloc.c, lib/argp-parse.c, lib/fts.c, lib/md4.c, lib/md5.c:
17907         * lib/rawmemchr.c, lib/sha1.c, lib/sha256.c, lib/sha512.c, lib/sm3.c:
17908         * lib/sys_socket.in.h:
17909         In C23, <stdalign.h> is a no-op, so don’t include it.
17911         stdalign: alignas and alignof are C23 keywords
17912         * m4/stdalign.m4 (gl_STDALIGN_H): Check also whether
17913         alignas and alignof are keywords and so don’t need stdalign.h,
17914         and define HAVE_C_ALIGNASOF if so.
17915         If not, arrange for config.h to #define alignas and alignof
17916         by including <stdalign.h>.
17917         * modules/stdalign: No need to include <stdalign.h>.
17918         * tests/test-stdalign.c: Do not include stdalign.h.
17920         assert-h: prefer to ‘verify’
17921         Where it’s easy, prefer ‘static_assert’ to ‘verify’,
17922         as this simplifies the source by removing the need to
17923         include verify.h.  Keep using ‘verify’ if verify.h
17924         is used for other reasons, or if code is shared with glibc.
17925         * lib/alignalloc.c, lib/argmatch.h, lib/c32is-impl.h:
17926         * lib/c32snrtombs.c, lib/c32srtombs.c, lib/exclude.c:
17927         * lib/filevercmp.c, lib/fma.c, lib/i-ring.h, lib/ino-map.c:
17928         * lib/localeinfo.c, lib/malloca.c, lib/mbrtoc32.c, lib/mbrtowc.c:
17929         * lib/mbsinit.c, lib/mbsnrtoc32s.c, lib/mbsrtoc32s.c:
17930         * lib/nanosleep.c, lib/parse-datetime.y, lib/pipe2.c:
17931         * lib/rawmemchr.c, lib/relocwrapper.c, lib/sleep.c:
17932         * lib/stat-w32.c, lib/strerror.c, lib/strtoimax.c:
17933         * lib/utimecmp.c, lib/vasnprintf.c, tests/test-alignof.c:
17934         * tests/test-intprops.c, tests/test-libgmp.c:
17935         * tests/test-limits-h.c, tests/test-locale.c:
17936         * tests/test-pthread.c, tests/test-round2.c:
17937         * tests/test-stdalign.c, tests/test-stddef.c, tests/test-stdio.c:
17938         * tests/test-stdlib.c, tests/test-string.c, tests/test-sys_stat.c:
17939         * tests/test-time.c, tests/test-uchar.c, tests/test-unistd.c:
17940         * tests/test-wchar.c:
17941         Prefer static_assert to verify, and stop including verify.h.
17942         * lib/stat.c: Don’t include verify.h (this include was unnecessary).
17943         * modules/alignalloc, modules/alignof-tests, modules/argmatch:
17944         * modules/c-vasnprintf, modules/c32isalnum, modules/c32isalpha:
17945         * modules/c32isblank, modules/c32iscntrl, modules/c32isdigit:
17946         * modules/c32isgraph, modules/c32islower, modules/c32isprint:
17947         * modules/c32ispunct, modules/c32isspace, modules/c32isupper:
17948         * modules/c32isxdigit, modules/c32snrtombs, modules/c32srtombs:
17949         * modules/exclude, modules/filevercmp, modules/fma, modules/fmaf:
17950         * modules/fmal, modules/fstat, modules/i-ring, modules/ino-map:
17951         * modules/intprops-tests, modules/libgmp-tests:
17952         * modules/limits-h-tests, modules/locale-tests, modules/malloca:
17953         * modules/mbrtoc32, modules/mbrtowc, modules/mbsinit:
17954         * modules/mbsnrtoc32s, modules/mbsrtoc32s, modules/nanosleep:
17955         * modules/parse-datetime, modules/pipe2, modules/pthread-h-tests:
17956         * modules/rawmemchr, modules/relocatable-prog-wrapper:
17957         * modules/round-tests, modules/roundf-tests, modules/sleep:
17958         * modules/stat, modules/stdalign-tests, modules/stdckdint-tests:
17959         * modules/stddef-tests, modules/stdio-tests, modules/stdlib-tests:
17960         * modules/strerror, modules/string-tests, modules/strtoimax:
17961         * modules/strtoumax, modules/sys_stat-tests, modules/time-tests:
17962         * modules/uchar-tests, modules/unistd-tests:
17963         * modules/unistdio/u16-u16-vasnprintf:
17964         * modules/unistdio/u16-vasnprintf:
17965         * modules/unistdio/u32-u32-vasnprintf:
17966         * modules/unistdio/u32-vasnprintf:
17967         * modules/unistdio/u8-u8-vasnprintf:
17968         * modules/unistdio/u8-vasnprintf, modules/unistdio/ulc-vasnprintf:
17969         * modules/utimecmp, modules/vasnprintf, modules/wchar-tests:
17970         Depend on assert-h, not verify.
17972         assert-h: static_assert is a keyword in C23
17973         * m4/assert_h.m4 (gl_ASSERT_H): Also test for static_assert
17974         keyword a la C23, and define HAVE_C_STATIC_ASSERT if so.
17975         If not, arrange for config.h to #define static_assert
17976         by including <assert.h>, and then do "#undef assert"
17977         so that the assert macro still needs an explicit include.
17978         This should be safe even on very old hosts, as assert.h
17979         has been re-includable for decades.
17980         * tests/tests-assert.c: New test.
17981         * modules/assert-h-tests (Files, Makefile.am): Add it.
17983 2022-09-13  Bruno Haible  <bruno@clisp.org>
17985         Prefer talking about alignas than _Alignas.
17986         * m4/gnulib-common.m4 (gl_COMMON_BODY): Don't mention _Alignas in a
17987         comment.
17988         * m4/stdalign.m4 (gl_STDALIGN_H): Likewise.
17990 2022-09-13  Paul Eggert  <eggert@cs.ucla.edu>
17992         stdalign-tests: port to C23
17993         * tests/test-stdalign.c: Do not test __alignas_is_defined,
17994         _Alignof, or _Alignas as they are obsolescent.
17995         Do not use __alignas_is_defined in C23 or later (or C++11 or later),
17996         as it’s removed in C23.
17998 2022-09-12  Bruno Haible  <bruno@clisp.org>
18000         supersede: Avoid a failure when writing to /dev/null in Solaris zones.
18001         * lib/supersede.c (open_supersede): Treat EACCES (seen on Solaris 11.3)
18002         like EINVAL (seen on Illumos).
18004 2022-09-11  Paul Eggert  <eggert@cs.ucla.edu>
18006         maint: avoid unportable ERE \}
18007         * top/maint.mk (sc_copyright_check):
18008         Avoid unportable use of \} in ERE.
18010         verify: improve maint check
18011         * top/maint.mk (sc_prohibit_verify_without_use):
18012         Adjust re to match verify.h.
18014         verify: port better to C23
18015         * lib/verify.h (_GL_VERIFY, static_assert):
18016         If C23, use static_assert keyword; no macro.
18017         This should simplify diagnostics and debugging.
18019 2022-09-10  Bruno Haible  <bruno@clisp.org>
18021         pipe-filter-gi: Fix test failure on native Windows.
18022         * lib/pipe-filter-aux.h (write): Redefine on native Windows.
18024 2022-09-10  Bruno Haible  <bruno@clisp.org>
18026         stdbool C++ tests: Fix compilation error with MSVC14 (regr. from today).
18027         * tests/test-stdbool-c++.cc (s): Choose field names that are not type
18028         names.
18030         Reorganize C++ tests for stdbool and stdbool-c99.
18031         * tests/test-stdbool-c++.cc: Don't include <stdbool.h> if TEST_STDBOOL_H
18032         is not defined. Add a couple of simple tests, from test-stdbool.c.
18033         * tests/test-stdbool-c99-c++.cc: New file.
18034         * modules/stdbool-c99-c++-tests: New file, based on
18035         modules/stdbool-c++-tests.
18036         * modules/stdbool-c99-tests (Depends-on): Add stdbool-c99-c++-tests.
18037         Remove stdbool-c++-tests.
18038         * modules/stdbool-tests (Depends-on): Add stdbool-c++-tests.
18040 2022-09-10  Bruno Haible  <bruno@clisp.org>
18042         stdbool C++ tests: Fix for C++20.
18043         * tests/test-stdbool-c++2.cc: Don't include <cstdbool> in C++20 or
18044         newer.
18046 2022-09-10  Bruno Haible  <bruno@clisp.org>
18048         uchar: Work around error in C++ mode on AIX 7.2 with xlclang.
18049         * lib/uchar.in.h (char16_t, char32_t): On AIX with xlclang++, define
18050         these as macros.
18051         * doc/posix-headers/uchar.texi: Document the AIX + xlclang++ bug.
18053 2022-09-10  Paul Eggert  <eggert@cs.ucla.edu>
18055         Rely on new stdbool behavior
18056         Prefer the C23 style to the C99 style,
18057         since the stdbool module now supports C23.
18058         * lib/acl-internal.h, lib/acl.h, lib/argmatch.c, lib/argmatch.h:
18059         * lib/argp-help.c, lib/argv-iter.h, lib/asyncsafe-spin.c:
18060         * lib/backup-internal.h, lib/backupfile.c, lib/base32.h:
18061         * lib/base64.h, lib/basename-lgpl.c, lib/bitset/base.h:
18062         * lib/c-ctype.h, lib/c-strcasestr.c, lib/canonicalize-lgpl.c:
18063         * lib/canonicalize.c, lib/chdir-long.c, lib/chown.c:
18064         * lib/classpath.h, lib/clean-temp-private.h:
18065         * lib/clean-temp-simple.c, lib/clean-temp-simple.h:
18066         * lib/clean-temp.c, lib/clean-temp.h, lib/cloexec.h:
18067         * lib/close-stream.c, lib/closein.c, lib/closeout.c, lib/closeout.h:
18068         * lib/csharpcomp.h, lib/csharpexec.h, lib/cycle-check.c:
18069         * lib/cycle-check.h, lib/des.h, lib/dfa.h, lib/diffseq.h:
18070         * lib/dirname.h, lib/exclude.c, lib/exclude.h, lib/execute.c:
18071         * lib/execute.h, lib/execvpe.c, lib/fatal-signal.c, lib/fchdir.c:
18072         * lib/file-set.h, lib/filevercmp.c, lib/findprog-in.c:
18073         * lib/findprog.c, lib/findprog.h, lib/fma.c, lib/fnmatch.c:
18074         * lib/fopen.c, lib/freadable.h, lib/freading.h, lib/freopen-safer.c:
18075         * lib/fstrcmp.c, lib/fsusage.h, lib/fts.c, lib/fwritable.h:
18076         * lib/fwriteerror.c, lib/fwriting.h, lib/gen-uni-tables.c:
18077         * lib/getaddrinfo.c, lib/getcwd.c, lib/getloadavg.c:
18078         * lib/getndelim2.c, lib/getpass.c, lib/getrandom.c:
18079         * lib/git-merge-changelog.c, lib/gl_list.h, lib/gl_map.h:
18080         * lib/gl_omap.h, lib/gl_oset.h, lib/gl_set.h, lib/glob.c:
18081         * lib/glthread/cond.h, lib/hamt.h, lib/hard-locale.h:
18082         * lib/hash-triple.h, lib/hash.h, lib/human.h, lib/i-ring.h:
18083         * lib/isapipe.c, lib/javacomp.h, lib/javaexec.h, lib/javaversion.c:
18084         * lib/lchown.c, lib/localeinfo.h, lib/localename.c:
18085         * lib/long-options.h, lib/malloc/dynarray.h, lib/mbchar.h:
18086         * lib/mbfile.h, lib/mbiter.h, lib/mbmemcasecoll.h, lib/mbscasestr.c:
18087         * lib/mbsstr.c, lib/mbuiter.h, lib/mkdir-p.h, lib/modechange.h:
18088         * lib/mountlist.h, lib/nanosleep.c, lib/nonblocking.h:
18089         * lib/nstrftime.c, lib/openat.c, lib/openat.h, lib/os2-spawn.c:
18090         * lib/parse-datetime.h, lib/pipe-filter-aux.c, lib/pipe-filter-gi.c:
18091         * lib/pipe-filter-ii.c, lib/pipe-filter.h, lib/posixtm.h:
18092         * lib/priv-set.c, lib/progreloc.c, lib/propername.c:
18093         * lib/pthread-spin.c, lib/quotearg.c, lib/readtokens.c:
18094         * lib/readtokens0.h, lib/readutmp.c, lib/regex-quote.h:
18095         * lib/regex_internal.h, lib/relocwrapper.c, lib/rename.c:
18096         * lib/renameatu.c, lib/rpmatch.c, lib/same.c, lib/same.h:
18097         * lib/save-cwd.c, lib/savewd.c, lib/savewd.h, lib/spawn-pipe.h:
18098         * lib/spawni.c, lib/stack.h, lib/stat.c, lib/stdckdint.in.h:
18099         * lib/strcasestr.c, lib/strfmon_l.c, lib/striconveh.c:
18100         * lib/striconveha.h, lib/string-buffer.h, lib/strptime.c:
18101         * lib/strstr.c, lib/strtod.c, lib/supersede.h, lib/system-quote.c:
18102         * lib/tempname.c, lib/term-style-control.c:
18103         * lib/term-style-control.h, lib/textstyle.in.h, lib/time_rz.c:
18104         * lib/tmpdir.c, lib/tmpdir.h, lib/tmpfile.c, lib/unicase.in.h:
18105         * lib/unicase/caseprop.h, lib/unicase/invariant.h:
18106         * lib/unicase/u16-casemap.c, lib/unicase/u16-ct-totitle.c:
18107         * lib/unicase/u16-is-invariant.c, lib/unicase/u32-casemap.c:
18108         * lib/unicase/u32-ct-totitle.c, lib/unicase/u32-is-invariant.c:
18109         * lib/unicase/u8-casemap.c, lib/unicase/u8-ct-totitle.c:
18110         * lib/unicase/u8-is-invariant.c, lib/unictype.in.h:
18111         * lib/unigbrk.in.h, lib/unigbrk/u16-grapheme-breaks.c:
18112         * lib/unigbrk/u32-grapheme-breaks.c:
18113         * lib/unigbrk/u8-grapheme-breaks.c:
18114         * lib/unigbrk/uc-grapheme-breaks.c, lib/uniname/uniname.c:
18115         * lib/unistr.in.h, lib/unlinkdir.h, lib/userspec.h, lib/utime.c:
18116         * lib/utimecmp.c, lib/utimens.c, lib/wait-process.h:
18117         * lib/windows-cond.c, lib/windows-spawn.c, lib/windows-spawn.h:
18118         * lib/windows-timedrwlock.c, lib/write-any-file.h, lib/xbinary-io.c:
18119         * lib/xstrtod.h, lib/yesno.h:
18120         * tests/nap.h, tests/qemu.h, tests/test-areadlink-with-size.c:
18121         * tests/test-areadlink.c, tests/test-areadlinkat-with-size.c:
18122         * tests/test-areadlinkat.c, tests/test-base32.c:
18123         * tests/test-base64.c, tests/test-ceil2.c, tests/test-ceilf2.c:
18124         * tests/test-chown.c, tests/test-dirname.c, tests/test-dup-safer.c:
18125         * tests/test-dup3.c, tests/test-exclude.c:
18126         * tests/test-execute-child.c, tests/test-execute-main.c:
18127         * tests/test-execute-script.c, tests/test-explicit_bzero.c:
18128         * tests/test-fchownat.c, tests/test-fcntl-safer.c:
18129         * tests/test-fcntl.c, tests/test-fdutimensat.c:
18130         * tests/test-filenamecat.c, tests/test-floor2.c:
18131         * tests/test-floorf2.c, tests/test-fstatat.c, tests/test-fstrcmp.c:
18132         * tests/test-futimens.c, tests/test-getlogin.h, tests/test-getopt.h:
18133         * tests/test-hard-locale.c, tests/test-hash.c:
18134         * tests/test-idpriv-drop.c, tests/test-idpriv-droptemp.c:
18135         * tests/test-immutable.c, tests/test-intprops.c:
18136         * tests/test-lchown.c, tests/test-link.c, tests/test-linkat.c:
18137         * tests/test-lstat.c, tests/test-mbmemcasecmp.c:
18138         * tests/test-mbmemcasecoll.c, tests/test-mkdir.c:
18139         * tests/test-mkdirat.c, tests/test-mkfifo.c, tests/test-mkfifoat.c:
18140         * tests/test-mknod.c, tests/test-nonblocking-pipe-child.c:
18141         * tests/test-nonblocking-pipe-main.c:
18142         * tests/test-nonblocking-socket-child.c:
18143         * tests/test-nonblocking-socket-main.c, tests/test-open.c:
18144         * tests/test-openat.c, tests/test-pipe.c, tests/test-pipe2.c:
18145         * tests/test-poll.c, tests/test-posix_spawn-chdir.c:
18146         * tests/test-posix_spawn-dup2-stdin.c:
18147         * tests/test-posix_spawn-dup2-stdout.c:
18148         * tests/test-posix_spawn-fchdir.c, tests/test-posix_spawn-open1.c:
18149         * tests/test-posix_spawn-open2.c, tests/test-quotearg-simple.c:
18150         * tests/test-quotearg.c, tests/test-readlink.c:
18151         * tests/test-readlinkat.c, tests/test-readtokens.c:
18152         * tests/test-rename.c, tests/test-renameat.c:
18153         * tests/test-renameatu.c, tests/test-rmdir.c, tests/test-round2.c:
18154         * tests/test-select.h, tests/test-spawn-pipe-child.c:
18155         * tests/test-spawn-pipe-main.c, tests/test-spawn-pipe-script.c:
18156         * tests/test-stack.c, tests/test-stat.c, tests/test-supersede.c:
18157         * tests/test-symlink.c, tests/test-symlinkat.c:
18158         * tests/test-system-quote-main.c:
18159         * tests/test-term-style-control-hello.c:
18160         * tests/test-term-style-control-yes.c, tests/test-timespec.c:
18161         * tests/test-trunc2.c, tests/test-truncf2.c, tests/test-unlink.c:
18162         * tests/test-unlinkat.c, tests/test-userspec.c, tests/test-utime.c:
18163         * tests/test-utimens.c, tests/test-utimensat.c:
18164         * tests/unictype/test-categ_byname.c:
18165         * tests/unigbrk/test-uc-is-grapheme-break.c:
18166         Don’t include stdbool.h.
18167         * modules/acl, modules/xgetcwd:
18168         Don’t depend on stdbool, as these modules don’t use bool.
18169         * modules/argp, modules/bitset, modules/diffseq, modules/file-has-acl:
18170         * modules/gen-uni-tables, modules/getrandom:
18171         * modules/hash-triple-simple, modules/posix_spawn-internal:
18172         * modules/strcasestr, modules/supersede, modules/system-quote:
18173         * modules/uniconv/base, modules/uniname/uniname, modules/utime:
18174         * modules/windows-timedrwlock:
18175         Depend on stdbool, as these modules use bool.
18177         stdbool: upgrade from C99 to C23
18178         Change the stdbool module so that it now emulates C23.
18179         The module now assumes C99.  The old module (which assumes
18180         C89 and emulates C99) is still available  as stdbool-c99,
18181         but is deprecated.
18182         * tests/test-stdbool.c [TEST_C_BOOL]: Do not include stdbool.h.
18183         * m4/c-bool.m4, modules/c-bool, modules/c-bool-tests:
18184         * tests/test-c-bool.c: New files.
18186 2022-09-10  Bruno Haible  <bruno@clisp.org>
18188         string: Fix compilation error in C++ mode on AIX 7.2 with xlclang.
18189         * lib/string.in.h (mbslen): Enable the C++ alias warning only on glibc
18190         systems.
18192 2022-09-10  Bruno Haible  <bruno@clisp.org>
18194         math: Fix compilation error in C++ mode on AIX 7.2 with xlclang.
18195         * lib/math.in.h (cbrtl, copysignl, exp2l, expm1l, fmal, ilogbl, log1pl,
18196         log2l, logbl, remainderl, rintl, roundl, truncl): Enable the C++ alias
18197         warning only on glibc systems.
18199 2022-09-10  Bruno Haible  <bruno@clisp.org>
18201         doc: Mention the stable branches.
18202         * doc/gnulib-readme.texi (High Quality): Add subsection
18203         'Stable Branches'.
18204         (Writing reliable code): Extracted from 'High Quality'. Mention also
18205         -Wall and valgrind.
18207 2022-09-09  Bruno Haible  <bruno@clisp.org>
18209         posix_spawn-internal: Optimize DuplicateHandle calls on native Windows.
18210         * lib/windows-spawn.h (DELAYED_DUP2_OLDFD, DELAYED_DUP2_NEWFD): New
18211         macros.
18212         (struct IHANDLE): Add a linked_fd field.
18213         * lib/spawni.c (SPAWN_INTERNAL_OPTIMIZE_DUPLICATEHANDLE): New macro.
18214         (do_delayed_dup2, do_remaining_delayed_dup2): New functions.
18215         (close_inheritable_handles): Don't close handles in DELAYED_DUP2_NEWFD
18216         entries.
18217         (do_close): Add a third parameter. Optimize delayed dup2 calls.
18218         (do_open): Use do_close.
18219         (do_dup2): Likewise. Prepare for optimizing the DuplicateHandle call.
18220         (__spawni): Do the remaining delayed dup2 invocations after the loop
18221         over the actions.
18223         posix_spawn-internal: Refactor.
18224         * lib/windows-spawn.h (struct IHANDLE): New type.
18225         (struct inheritable_handles): Combine handles and flags into a single
18226         array.
18227         * lib/windows-spawn.c (init_inheritable_handles, compose_handles_block,
18228         spawnpvech): Update.
18229         * lib/spawni.c (grow_inheritable_handles, shrink_inheritable_handles,
18230         do_open, do_dup2, do_close): Update.
18232         posix_spawn-internal: Optimize DuplicateHandle calls on native Windows.
18233         * lib/spawni.c (open_handle): Return an inheritable HANDLE.
18234         (do_open): Don't call DuplicateHandle. Remove curr_process parameter.
18235         (__spawni): Update.
18237         posix_spawn-internal: Optimize DuplicateHandle calls on native Windows.
18238         * lib/windows-spawn.h (KEEP_OPEN_IN_PARENT): New macro.
18239         * lib/windows-spawn.c (init_inheritable_handles): When a handle is
18240         already inheritable, don't bother duplicating it; instead, just mark it
18241         as KEEP_OPEN_IN_PARENT.
18242         * lib/spawni.c (shrink_inheritable_handles, close_inheritable_handles,
18243         do_open, do_dup2, do_close): Don't close handles that are marked as
18244         KEEP_OPEN_IN_PARENT.
18246 2022-09-09  Bruno Haible  <bruno@clisp.org>
18248         posix_spawn-internal: Don't lose flags while duplicating an fd.
18249         * lib/spawni.c (do_dup2): Fix the flags of the new fd.
18251 2022-09-09  Bruno Haible  <bruno@clisp.org>
18253         spawn-pipe: Fix pipe-filter-* test hangs (regression 2020-12-24).
18254         * lib/windows-spawn.h (struct inheritable_handles): Widen the per-fd
18255         flags from 8 bits to 16 bits.
18256         (KEEP_OPEN_IN_CHILD): New macro.
18257         (init_inheritable_handles): Change description of what it does when
18258         duplicate == true.
18259         * lib/windows-spawn.c (init_inheritable_handles): If duplicate == true,
18260         add all fds to the array, regardless whether they are scheduled to be
18261         preserved in the child process.
18262         (compose_handles_block): Update.
18263         (spawnpvech): Update.
18264         * lib/spawni.c (grow_inheritable_handles): Update.
18265         (shrink_inheritable_handles): Also close the handles not marked with
18266         KEEP_OPEN_IN_CHILD.
18267         (do_open, do_dup2): Mark the new fd with KEEP_OPEN_IN_CHILD.
18269 2022-09-09  Bruno Haible  <bruno@clisp.org>
18271         spawn-pipe: Fix possible hangs in programs that spawn several children.
18272         * lib/spawn-pipe.c (create_pipe) [Unix]: Create the ifd[] and ofd[] file
18273         descriptors with the close-on-exec flag set.
18275 2022-09-09  Bruno Haible  <bruno@clisp.org>
18277         pipe-filter-gi tests: Fix long-standing failure on native Windows.
18278         * tests/test-pipe-filter-gi2-main.c: Include binary-io.h.
18279         (main): Avoid NL to CRLF conversion on standard output.
18280         * tests/test-pipe-filter-gi2-child.c: Include <unistd.h>, binary-io.h.
18281         (main): Avoid NL to CRLF conversion on standard output.
18283 2022-09-09  Bruno Haible  <bruno@clisp.org>
18285         posix_spawn_file_actions_addclose tests: Fix mistake from 2022-09-07.
18286         * modules/posix_spawn_file_actions_addclose-tests (Files): Add
18287         m4/musl.m4.
18289 2022-09-08  Paul Eggert  <eggert@cs.ucla.edu>
18291         stdbool-tests: match stdbool
18292         * tests/test-stdbool.c: Omit test for
18293         __bool_true_false_are_defined since AC_CHECK_HEADER_STDBOOL no
18294         longer checks for this obsolescent macro.
18296         mktime: back in sync with GNUlib
18297         * config/srclist.txt: glibc has synced mktime from Gnulib.
18299 2022-09-07  Bruno Haible  <bruno@clisp.org>
18301         posix_spawn_file_actions_addclose tests: Avoid test failure on musl.
18302         Reported by Valery Ushakov <uwe@stderr.spb.ru> in
18303         <https://lists.gnu.org/archive/html/bug-gnulib/2022-09/msg00041.html>.
18304         * modules/posix_spawn_file_actions_addclose-tests (configure.ac): Invoke
18305         gl_MUSL_LIBC.
18306         * tests/test-posix_spawn_file_actions_addclose.c (main): Skip one of the
18307         tests on musl libc.
18309 2022-09-06  Simon Josefsson  <simon@josefsson.org>
18311         gnumakefile: Improve tarball reproducibility.
18312         * top/GNUmakefile (TAR_OPTIONS): Add --sort=name.  Suggested by
18313         Tzvetelin Katchov <katchov@gnu.org>.
18314         * DEPENDENCIES: Mention tar 1.28 dependency.
18316 2022-09-05  Bruno Haible  <bruno@clisp.org>
18318         pthread-h: Fix compilation error on mingw with --enable-threads=windows.
18319         * lib/pthread.in.h: In C++ mode, if mingw's <pthread.h> has not been
18320         used, import many pthread_* symbols from the GNULIB_NAMESPACE into the
18321         global namespace.
18323 2022-09-04  Bruno Haible  <bruno@clisp.org>
18325         Fix various test link errors on MSVC.
18326         * modules/crypto/gc-arcfour-tests (Makefile.am): Link test-gc-arcfour
18327         with $(LIB_GETRANDOM).
18328         * modules/crypto/gc-arctwo-tests (Makefile.am): Link test-gc-arctwo with
18329         $(LIB_GETRANDOM).
18330         * modules/crypto/gc-des-tests (Makefile.am): Link test-gc-des with
18331         $(LIB_GETRANDOM).
18332         * modules/crypto/gc-hmac-md5-tests (Makefile.am): Link test-gc-hmac-md5
18333         with $(LIB_GETRANDOM).
18334         * modules/crypto/gc-hmac-sha1-tests (Makefile.am): Link
18335         test-gc-hmac-sha1 with $(LIB_GETRANDOM).
18336         * modules/crypto/gc-hmac-sha256-tests (Makefile.am): Link
18337         test-gc-hmac-sha256 with $(LIB_GETRANDOM).
18338         * modules/crypto/gc-hmac-sha512-tests (Makefile.am): Link
18339         test-gc-hmac-sha512 with $(LIB_GETRANDOM).
18340         * modules/crypto/gc-md2-tests (Makefile.am): Link test-gc-md2 with
18341         $(LIB_GETRANDOM).
18342         * modules/crypto/gc-md4-tests (Makefile.am): Link test-gc-md4 with
18343         $(LIB_GETRANDOM).
18344         * modules/crypto/gc-md5-tests (Makefile.am): Link test-gc-md5 with
18345         $(LIB_GETRANDOM).
18346         * modules/crypto/gc-pbkdf2-tests (Makefile.am): Link test-gc-pbkdf2 with
18347         $(LIB_GETRANDOM).
18348         * modules/crypto/gc-pbkdf2-sha1-tests (Makefile.am): Link
18349         test-gc-pbkdf2-sha1 with $(LIB_GETRANDOM).
18350         * modules/crypto/gc-rijndael-tests (Makefile.am): Link test-gc-rijndael
18351         with $(LIB_GETRANDOM).
18352         * modules/crypto/gc-sha1-tests (Makefile.am): Link test-gc-sha1 with
18353         $(LIB_GETRANDOM).
18354         * modules/crypto/gc-sha256-tests (Makefile.am): Link test-gc-sha256 with
18355         $(LIB_GETRANDOM).
18356         * modules/crypto/gc-sha512-tests (Makefile.am): Link test-gc-sha512 with
18357         $(LIB_GETRANDOM).
18358         * modules/crypto/gc-sm3-tests (Makefile.am): Link test-gc-sm3 with
18359         $(LIB_GETRANDOM).
18360         * modules/sys_stat-c++-tests (Makefile.am): Link test-sys_stat-c++ with
18361         $(LIB_GETRANDOM).
18362         * modules/unistd-c++-tests (Makefile.am): Link test-unistd-c++ with
18363         $(LIB_GETRANDOM).
18365 2022-09-04  Bruno Haible  <bruno@clisp.org>
18367         count-leading-zeros: Fix a link error on 32-bit MSVC and a test failure.
18368         * lib/count-leading-zeros.h: Correct syntax for #pragma intrinsic.
18369         (COUNT_LEADING_ZEROS): Fix the return value.
18370         (count_leading_zeros_ll): Use two _BitScanReverse invocations instead
18371         of a _BitScanReverse64 invocation.
18373 2022-09-04  Bruno Haible  <bruno@clisp.org>
18375         count-trailing-zeros: Fix a link error on 32-bit MSVC.
18376         * lib/count-trailing-zeros.h: Correct syntax for #pragma intrinsic.
18377         (count_trailing_zeros_ll): Use two _BitScanForward invocations instead
18378         of a _BitScanForward64 invocation.
18380 2022-09-04  Bruno Haible  <bruno@clisp.org>
18382         unictype/category-none tests: Fix a link error on MSVC.
18383         * tests/unictype/test-categ_none.c (main): Disable the test on MSVC.
18385 2022-09-04  Bruno Haible  <bruno@clisp.org>
18387         oset-c++: Fix compilation error with MSVC 14.
18388         * lib/gl_oset.hh: With MSVC, avoid 'friend'.
18390 2022-09-04  Bruno Haible  <bruno@clisp.org>
18392         glob tests: Fix link error on mingw.
18393         * modules/glob-tests (Makefile.am): Link test-glob with $(LIBINTL).
18395 2022-09-04  Bruno Haible  <bruno@clisp.org>
18397         timespec_get: Fix compilation error with MSVC 14.
18398         * m4/gettime.m4 (gl_CHECK_FUNC_TIMESPEC_GET): New macro.
18399         (gl_GETTIME): Use it instead of AC_CHECK_FUNCS_ONCE.
18400         * m4/timespec_get.m4 (gl_FUNC_TIMESPEC_GET): Likewise.
18402 2022-09-04  Bruno Haible  <bruno@clisp.org>
18404         stdbool: Fix compilation error in C++ mode with MSVC 14.
18405         * lib/stdbool.in.h (_Bool, bool, false, true): In C++ mode with MSVC 14,
18406         don't define these as macros.
18408 2022-09-04  Bruno Haible  <bruno@clisp.org>
18410         fts: Fix compilation error with MSVC 14.
18411         * lib/fts.c (S_IFBLK): Add fallback definition.
18413 2022-09-04  Bruno Haible  <bruno@clisp.org>
18415         lstat: Fix compilation error in C++ mode on mingw.
18416         * lib/sys_stat.h (lstat): Move declaration after the declaration of
18417         'stat'.
18419 2022-09-04  Bruno Haible  <bruno@clisp.org>
18421         pselect: Fix compilation error in C++ mode on mingw.
18422         * lib/sys_select.in.h (pselect): Enable the C++ alias warning only on
18423         glibc systems.
18425 2022-09-04  Bruno Haible  <bruno@clisp.org>
18427         nanosleep: Work around bug on newer 32-bit mingw.
18428         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Test for 32-bit mingw bug.
18429         * tests/test-nanosleep.c (main): Add another test.
18430         * doc/posix-functions/nanosleep.texi: Mention the mingw bug.
18432 2022-09-03  Bruno Haible  <bruno@clisp.org>
18434         fmal: Work around glibc 2.17 bug on x86_64.
18435         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Test against bug seen on glibc 2.17
18436         x86_64.
18437         * doc/posix-functions/fmal.texi: Update info.
18439 2022-09-03  Bruno Haible  <bruno@clisp.org>
18441         Fix a compilation error in C++ mode on Solaris 11.4.
18442         * lib/uchar.in.h (c32rtomb): Enable the C++ alias warning only on
18443         glibc ≥ 2.16 systems. Fix a GNULIB_POSIXCHECK mistake.
18444         (mbrtoc32): Enable the C++ alias warning only on glibc ≥ 2.16 systems.
18446 2022-09-03  Bruno Haible  <bruno@clisp.org>
18448         Fix compilation errors of C++ tests on Solaris 10 with Sun C++.
18449         * modules/string-c++-tests (Makefile.am): Link test-string-c++ with
18450         $(LIBUNISTRING).
18451         * modules/wchar-c++-tests (Makefile.am): Link test-wchar-c++ with
18452         $(LIBUNISTRING).
18454 2022-09-03  Bruno Haible  <bruno@clisp.org>
18456         Fix a compilation error in C++ mode on FreeBSD 13.1.
18457         * lib/signal.in.h: Don't include <pthread.h> on FreeBSD ≥ 8.0.
18458         * lib/sys_select.in.h: Don't include <sys/time.h> on FreeBSD.
18460 2022-09-03  Bruno Haible  <bruno@clisp.org>
18462         stdnoreturn: Document relation to C++.
18463         * doc/posix-headers/stdnoreturn.texi: Document FreeBSD problem.
18465 2022-09-03  Bruno Haible  <bruno@clisp.org>
18467         sysexits: Add C++ tests.
18468         * tests/test-sysexits-c++.cc: New file.
18469         * modules/sysexits-c++-tests: New file.
18470         * modules/sysexits-tests (Depends-on): Add sysexits-c++-tests.
18472 2022-09-03  Bruno Haible  <bruno@clisp.org>
18474         sys_utsname: Add C++ tests.
18475         * tests/test-sys_utsname-c++.cc: New file.
18476         * modules/sys_utsname-c++-tests: New file.
18477         * modules/sys_utsname-tests (Depends-on): Add sys_utsname-c++-tests.
18479 2022-09-03  Bruno Haible  <bruno@clisp.org>
18481         sys_uio: Add C++ tests.
18482         * tests/test-sys_uio-c++.cc: New file.
18483         * modules/sys_uio-c++-tests: New file.
18484         * modules/sys_uio-tests (Depends-on): Add sys_uio-c++-tests.
18486 2022-09-03  Bruno Haible  <bruno@clisp.org>
18488         sys_times: Add C++ tests.
18489         * tests/test-sys_times-c++.cc: New file.
18490         * modules/sys_times-c++-tests: New file.
18491         * modules/sys_times-tests (Depends-on): Add sys_times-c++-tests.
18493 2022-09-03  Bruno Haible  <bruno@clisp.org>
18495         sys_file: Add C++ tests.
18496         * tests/test-sys_file-c++.cc: New file.
18497         * modules/sys_file-c++-tests: New file.
18498         * modules/sys_file-tests (Depends-on): Add sys_file-c++-tests.
18500         sys_file: Document this module.
18501         * doc/glibc-headers/sys_file.texi: New file.
18502         * doc/gnulib.texi (Glibc Header File Substitutes): Include it.
18504 2022-09-03  Bruno Haible  <bruno@clisp.org>
18506         stdckdint: Add C++ tests.
18507         * tests/test-stdckdint-c++.cc: New file.
18508         * modules/stdckdint-c++-tests: New file.
18509         * modules/stdckdint-tests (Depends-on): Add stdckdint-c++-tests.
18511 2022-09-03  Bruno Haible  <bruno@clisp.org>
18513         stdalign: Add C++ tests.
18514         * tests/test-stdalign-c++.cc: New file.
18515         * modules/stdalign-c++-tests: New file.
18516         * modules/stdalign-tests (Depends-on): Add stdalign-c++-tests.
18518 2022-09-03  Bruno Haible  <bruno@clisp.org>
18520         sched: Add C++ tests.
18521         * tests/test-sched-c++.cc: New file.
18522         * modules/sched-c++-tests: New file.
18523         * modules/sched-tests (Depends-on): Add sched-c++-tests.
18525 2022-09-03  Bruno Haible  <bruno@clisp.org>
18527         netinet_in: Add C++ tests.
18528         * tests/test-netinet_in-c++.cc: New file.
18529         * modules/netinet_in-c++-tests: New file.
18530         * modules/netinet_in-tests (Depends-on): Add netinet_in-c++-tests.
18532 2022-09-03  Bruno Haible  <bruno@clisp.org>
18534         net_if: Add C++ tests.
18535         * tests/test-net_if-c++.cc: New file.
18536         * modules/net_if-c++-tests: New file.
18537         * modules/net_if-tests (Depends-on): Add net_if-c++-tests.
18538         * doc/posix-headers/net_if.texi: Fix documentation.
18540 2022-09-03  Bruno Haible  <bruno@clisp.org>
18542         termcap: Fix link error on AIX 7.
18543         * m4/termcap.m4 (gl_TERMCAP_BODY): Search also for libxcurses and for
18544         libcurses, like gl_TERMINFO_BODY does.
18545         * m4/terminfo.m4 (gl_TERMINFO_BODY): Update platform list in comment.
18547 2022-09-02  Bruno Haible  <bruno@clisp.org>
18549         getrandom: Fix compilation error in C++ mode on FreeBSD 12.
18550         * lib/sys_random.in.h (getrandom): Enable the C++ alias warning only on
18551         glibc ≥ 2.25 systems.
18553 2022-09-02  Bruno Haible  <bruno@clisp.org>
18555         math C++ tests: Fix compilation error with clang on FreeBSD 13.
18556         * lib/math.in.h (isnan): For clang >= 11 on FreeBSD, declare 'isnan',
18557         not 'rpl_isnan'.
18559 2022-09-02  Bruno Haible  <bruno@clisp.org>
18561         strerror_r-posix: Fix for Hurd.
18562         * lib/strerror_r.c (strerror_r): Interpret return value of
18563         __xpg_strerror_r correctly. Remove assumption about how strerror_r
18564         behaves.
18566 2022-09-02  Bruno Haible  <bruno@clisp.org>
18568         ptsname tests, ptsname_r tests: Fix test failures on Hurd.
18569         * tests/test-ptsname.c (main): On Hurd, test only the BSD ptys that
18570         actually exist on Hurd.
18571         * tests/test-ptsname_r.c (main): Likewise.
18573 2022-09-02  Bruno Haible  <bruno@clisp.org>
18575         strtol, strtoul: Fix compilation error in C++ mode on Solaris 11.
18576         * lib/stdlib.in.h (strtol, strtoul): Enable the C++ alias warning only
18577         on glibc systems.
18579 2022-09-02  Bruno Haible  <bruno@clisp.org>
18581         aligned_alloc: Fix compilation error in C++ mode on Solaris 11.
18582         * lib/stdlib.in.h (aligned_alloc): Enable the C++ alias warning only on
18583         glibc systems.
18585 2022-09-02  Bruno Haible  <bruno@clisp.org>
18587         getdomainname: Fix compilation error in C++ mode on Solaris 11.
18588         * lib/unistd.in.h (getdomainname): Enable the C++ alias warning only on
18589         glibc systems.
18591 2022-09-02  Bruno Haible  <bruno@clisp.org>
18593         terminfo: Don't disturb the termcap module.
18594         * m4/terminfo.m4 (gl_TERMINFO_BODY): Save and restore the variables
18595         determined by the gl_TERMCAP_BODY macro.
18597 2022-08-30  Paul Eggert  <eggert@cs.ucla.edu>
18599         fnmatch: fix stdckdint typo
18600         * lib/fnmatch_loop.c (NEW_PATTERN): Fix typo in previous patch.
18601         Problem and fix reported by Simon Josefsson in:
18602         https://lists.gnu.org/r/bug-gnulib/2022-08/msg00104.html
18604 2022-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18606         tempname: simplify by omitting _LIBC code
18607         * lib/tempname.c [_LIBC]: Simplify.
18608         Suggested by Bruno Haible in:
18609         https://lists.gnu.org/r/bug-gnulib/2022-08/msg00077.html
18610         I plan to propose a corresponding patch to glibc.
18612 2022-08-22  Paul Eggert  <eggert@cs.ucla.edu>
18614         tempname: don't lose entropy in seed
18615         * lib/tempname.c (random_bits): Don't lose entropy in S
18616         in the rare case where where the template has more than 10 Xs.
18617         From a suggestion by Bruno Haible in:
18618         https://bugs.gnu.org/57129#149
18620         tempname: fix multithreading, ASLR leak etc.
18621         Fix problems with tempname and multithreading, entropy loss,
18622         and missing clock data (this last on non-GNU platforms).
18623         See analysis by Bruno Haible in:
18624         https://bugs.gnu.org/57129#149
18625         While looking into this, I noticed that tempname can leak
18626         info derived from ASLR into publicly-visible file names,
18627         which is a no-no.  Fix that too.
18628         * lib/tempname.c: Don't include stdalign.h.
18629         (HAS_CLOCK_ENTROPY): Remove.
18630         (mix_random_values): New function.
18631         (random_bits): Use it.  Args are now new value address and
18632         old value, and this function now returns a success indicator.
18633         Omit old USE_GETRANDOM argument: always try getrandom now, as
18634         there is no good reason not to now that GRND_NONBLOCK is used.
18635         Caller changed.  Use CLOCK_REALTIME for for ersatz entropy,
18636         as CLOCK_MONOTONIC doesn't work on some platforms.
18637         Also, mix in ersatz entropy from tv_sec and from clock ().
18638         (try_tempname_len): Do not mix in ASLR-based entropy, as
18639         the result is published to the world and ASLR should be private.
18640         Do not try to use a static var as that has issues if multithreaded.
18641         Instead, simply generate new random bits.
18642         Worry about bias only with high-quality random bits.
18644         * modules/tempname (Depends-on): Do not depend on stdalign.
18646         tempname: merge 64-bit time_t fix from glibc
18647         This merges glibc commit 52a5fe70a2c77935afe807fb6e904e512ddd894e
18648         "Use 64 bit time_t stat internally".
18649         * lib/tempname.c (struct_stat64) [_LIBC]: Use struct __stat64_t64.
18650         (__lstat64_time64) [!_LIBC]: Rename from __lstat64.
18651         All uses changed.
18652         (direxists): Use __stat64_time64 instead of __stat64.
18654 2022-08-16  Bruno Haible  <bruno@clisp.org>
18656         tempname: Add more tests.
18657         Based on scenario described by Eli Zaretskii in
18658         <https://lists.gnu.org/archive/html/bug-gnulib/2022-08/msg00043.html>.
18659         * tests/test-tempname.c (main): Add another test.
18660         * modules/tempname-tests (Status): Mark the test as unportable.
18662 2022-08-16  Paul Eggert  <eggert@cs.ucla.edu>
18664         tempname: generate better names for MinGW Emacs
18665         On MinGW, GNU Emacs disables clock_gettime, which reliably breaks
18666         some of gen_tempname’s optimistic callers.  Work around the
18667         problem by making the generated names less predictable.  We don’t
18668         need cryptographic randomness here, just enough unpredictability
18669         to keep Emacs happy most of the time.
18670         * lib/tempname.c (HAS_CLOCK_ENTROPY): New macro.
18671         (random_bits): Use it.
18672         (try_tempname_len): On systems lacking clock entropy, maintain
18673         state so that gen_filename generates less-predictable names on
18674         successive successful calls.
18676 2022-08-16  Simon Josefsson  <simon@josefsson.org>
18678         maintainer-makefile: Check for incorrect DISTCHECK_CONFIGURE_FLAGS
18679         usage.
18680         * top/maint.mk (sc_makefile_DISTCHECK_CONFIGURE_FLAGS): Add.
18682 2022-08-16  Bruno Haible  <bruno@clisp.org>
18684         tempname: Add tests.
18685         * tests/test-tempname.c: New file.
18686         * modules/tempname-tests: New file.
18688 2022-08-16  Simon Josefsson  <simon@josefsson.org>
18690         pmccabe2html: Doc fix.
18691         * build-aux/pmccabe2html: Don't use reserved _SOURCES namespace.
18692         Use AM_V_GEN.  Use LC_ALL=C.
18694 2022-08-15  Bruno Haible  <bruno@clisp.org>
18696         stdbool: Drop old BeOS support that gets in the way of ISO C 23 support.
18697         * lib/stdbool.in.h: Don't include <OS.h>.
18699 2022-08-15  Bruno Haible  <bruno@clisp.org>
18701         tempname: Fix a comment.
18702         * lib/tempname.c (try_tempname_len): Use of entropy makes the function
18703         more, not less, secure.
18705 2022-08-15  Paul Eggert  <eggert@cs.ucla.edu>
18707         tempname: remove incorrect comment
18708         * lib/tempname.c, lib/tempname.h: Remove incorrect comment,
18709         as the names are not necessarily hard to predict (Bug#57129).
18711 2022-08-14  Simon Josefsson  <simon@josefsson.org>
18713         bootstrap.conf: Use proper shell marker for Emacs.
18714         * build-aux/bootstrap.conf: Add it.
18716 2022-08-13  Paul Eggert  <eggert@cs.ucla.edu>
18718         stdbool: port to C23
18719         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Copy from bleeding-edge
18720         Autoconf.  Define only if Autoconf 2.71 and earlier.
18721         * tests/test-stdbool.c (bool, false, true)
18722         (__bool_true_false_are_defined): Do not require these to be
18723         defined.  C23 still requires __bool_true_false_are_defined but
18724         marks it as obsolescent, and it’s no longer worth testing.
18725         (WORKING_BOOL): New macro, which also tests __STDC_VERSION__.
18726         Use it in tests for working bool.
18727         Test for bool instead of for _Bool, which C23 says is obsolescent.
18729 2022-08-13  Bruno Haible  <bruno@clisp.org>
18731         gnulib-tool.py: Fix some code generation details.
18732         * pygnulib/GLEmiter.py: Don't produce Windows CR-LFs on Windows.
18733         (GLEmiter.po_Makevars): Emit a definition of top_builddir, not
18734         top_subdir.
18735         (GLEmiter.po_POTFILES_in): Fix result when sourcebase is 'tests' or
18736         something like that.
18737         (GLEmiter.initmacro_start): Add two more newlines (mistake from
18738         2021-04-11).
18740         gnulib-tool.py: Reduce code duplication.
18741         * pygnulib/constants.py (relinverse): New function.
18742         * pygnulib/GLEmiter.py (GLEmiter.po_Makevars,
18743         GLEmiter.tests_Makefile_am): Use it.
18744         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
18746 2022-08-12  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
18748         hamt: fix technically undefined behavior
18749         Bug reported by Bruno Haible in
18750         <https://lists.gnu.org/r/bug-gnulib/2022-04/msg00023.html>.
18751         * lib/hamt.c (entry_insert): Remove technically undefined
18752         behavior when shifting an integer of N bits by N or more bits.
18754 2022-08-10  Paul Eggert  <eggert@cs.ucla.edu>
18756         stdckdint: fix dependency
18757         * modules/stdckdint (Depends-on): Add stdbool.
18758         Reported by Bruno Haible.
18760         maint: parenthesize macro definiens
18761         * lib/intprops.h (INT_ADD_OK, INT_SUBTRACT_OK, INT_MULTIPLY_OK):
18762         * lib/pipe-filter-ii.c (GetLastError):
18763         * lib/thread-optim.h (gl_multithreaded): Parenthesize
18764         function-like macro definiens beginning with a unary operator;
18765         needed for weird invocations like ‘m (...)[p]’.
18767 2022-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18769         stdckdint: prefer to intprops when easy
18770         stdckdint.h is part of draft C23 and therefore is more likely
18771         to be familiar to programmers in the future, so prefer it to
18772         intprops.h in files that don’t need non-_WRAPV intprops.h macros.
18773         * lib/alignalloc.c, lib/backupfile.c, lib/fnmatch.c, lib/fnmatch_loop.c:
18774         * lib/group-member.c, lib/malloca.c, lib/posixtm.c, lib/reallocarray.c:
18775         * lib/xmalloc.c:
18776         For files that can use stdckdint.h just as easily as intprops.h,
18777         include the former instead of the latter, and use the former’s
18778         ckd_* macros instead of the latter’s *_WRAPV macros.
18779         * modules/alignalloc, modules/backup-rename, modules/backupfile:
18780         * modules/fnmatch, modules/group-member, modules/malloca:
18781         * modules/posixtm, modules/reallocarray:
18782         * modules/relocatable-prog-wrapper, modules/xalloc:
18783         Depend on stdckdint instead of intprops.
18785         stdckdint: new module
18786         This supports draft C23 <stdckdint.h>.
18787         * doc/posix-headers/stdckdint.texi:
18788         * lib/stdckdint.in.h, modules/stdckdint:
18789         * modules/stdckdint-tests, tests/test-stdckdint.c:
18790         New files.
18791         * MODULES.html.sh, doc/gnulib.texi: Update for new module.
18792         * lib/intprops-internal.h: Include <stdckdint.h> if C23 and
18793         its macros would help and our substitute has not already
18794         started to be included.
18795         (_GL_INT_ADD_WRAPV, _GL_INT_SUBTRACT_WRAPV)
18796         (_GL_INT_MULTIPLY_WRAPV): Use ckd_add, ckd_sub, ckd_mul
18797         if they are defined and would help.
18798         * lib/intprops-internal.h, lib/intprops.h: Improve comments.
18799         The C23 restrictions on stdckdint macros already mostly applied to
18800         intprops.h, so these are clarifications, not further restrictions.
18801         * tests/test-intprops.c: If TEST_STDCKDINT is defined,
18802         include <stdckdint.h> instead of "intprops.h", and test
18803         it instead.
18804         (VERIFY) [TEST_STDCKDINT]: Ignore the arg in this case.
18805         (main) [TEST_STDCKDINT]: Skip tests irrelevant to stdckdint.h.
18807         intprops: refactor intprops.h into two
18808         * lib/intprops.h: Include new file intprops-internal.h.
18809         (_GL_INT_CONVERT, _GL_INT_NEGATE_CONVERT, _GL_INT_MINIMUM)
18810         (_GL_INT_MAXIMUM, _GL_SIGNED_INT_MAXIMUM, LLONG_MAX, LLONG_MIN)
18811         (_GL_HAVE___TYPEOF__, _GL_SIGNED_TYPE_OR_EXPR)
18812         (_GL_HAS_BUILTIN_ADD_OVERFLOW, _GL_HAS_BUILTIN_MUL_OVERFLOW)
18813         (_GL_HAS_BUILTIN_OVERFLOW_P, _GL__GENERIC_BOGUS)
18814         (_GL_INT_OP_WRAPV, _GL_INT_OP_WRAPV_LONGISH, _GL_INT_OP_CALC)
18815         (_GL_INT_OP_WRAPV_VIA_UNSIGNED, _GL_INT_ADD_RANGE_OVERFLOW)
18816         (_GL_INT_SUBTRACT_RANGE_OVERFLOW)
18817         (_GL_INT_MULTIPLY_RANGE_OVERFLOW):
18818         Move to intprops-internal.h.
18819         (TYPE_SIGNED, EXPR_SIGNED, TYPE_WIDTH, INT_NEGATE_RANGE_OVERFLOW)
18820         (INT_NEGATE_OVERFLOW, INT_ADD_WRAPV, INT_SUBTRACT_WRAPV)
18821         (INT_MULTIPLY_WRAPV): Rename to _GL_ prefix, move to
18822         intprops-internal.h, and define here in terms of the _GL_ name.
18823         * lib/intprops-internal.h: New file, containing the above.
18824         * modules/intprops (Files): Add lib/intprops-internal.h.
18826         intprops: refactor _GL_HAS_BUILTIN_OVERFLOW_P
18827         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P)
18828         [_GL_HAS_BUILTIN_OVERFLOW_P]: Use __builtin_sub_overflow_p
18829         directly rather than indirectly via INT_SUBTRACT_OVERFLOW.
18830         This simplifies future changes, and doesn’t change the generated code.
18832         verify: port ‘assume’ to C23 non-GCC
18833         * lib/verify.h (assume): Use C23's unreachable if available
18834         and if GCC and/or MSC primitives are not available.
18836 2022-08-09  Bruno Haible  <bruno@clisp.org>
18838         gnulib-tool.py: Finish implementing option --conditional-dependencies.
18839         * gnulib-tool.py (main) Accept options --conditional-dependencies,
18840         --no-conditional-dependencies.
18841         * pygnulib/GLModuleSystem.py (GLModuleTable.addConditional): Use
18842         str(module), not module, as key. Fix logic bug.
18843         (GLModuleTable.getCondition): Simplify.
18844         (GLModuleTable.transitive_closure): Show a warning when there are
18845         duplicate dependencies. Fix logic bug.
18846         (GLModuleTable.transitive_closure_separately): Simplify.
18847         (GLModuleTable.add_dummy): Ignore tests modules. Cope with multiple
18848         lib_SOURCES augmentation lines. Cope with comments at the end of a
18849         lib_SOURCES augmentation line. Add the dummy module at the end of the
18850         modules list.
18851         * pygnulib/GLTestDir.py (GLTestDir.execute): Remove the code that forces
18852         the dummy module to the end of the list.
18853         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Add code to
18854         terminate the shell functions. Add code for the dependencies from the
18855         unconditional to the conditional modules. Don't emit AM_CONDITIONAL for
18856         unconditional modules.
18858         gnulib-tool.py: Don't do license replacements in the autoconf snippets.
18859         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Remove fileassistant
18860         argument. Don't invoke the 'aux' transformer here. Don't produce Windows
18861         CR-LFs on Windows.
18862         (GLEmiter.autoconfSnippets): Remove fileassistant argument.
18863         * pygnulib/GLImport.py (GLImport.gnulib_comp): Update all callers.
18864         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
18866         gnulib-tool.py: Fix some code generation details.
18867         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): When removing a
18868         lib_LDFLAGS line, remove also the newline. Fix regex that matches
18869         lib_SOMETHING. Add a newline after each '## begin gnulib module' line.
18870         Don't emit 'endif' lines without corresponding 'if'. When emitting a
18871         '+=' augmentation, make sure it does not get emitted a second time.
18872         Don't emit a blank line when there is no AM_CPPFLAGS augmentation.
18873         Update after getLink() changed. In the value of DEFAULT_TEXT_DOMAIN,
18874         backslash-escape the double-quotes. Don't produce Windows CR-LFs on
18875         Windows. Simplify.
18876         (GLEmiter.tests_Makefile_am): When removing a lib_LDFLAGS line, remove
18877         also the newline. Fix regex that matches lib_SOMETHING. Don't remove a
18878         blank line before EXTRA_DIST. Add a newline after each
18879         '## begin gnulib module' line. Set uses_subdirs also when there is a .c
18880         file in a subdir of tests/. When emitting a '+=' augmentation, make sure
18881         it does not get emitted a second time. Don't produce Windows CR-LFs on
18882         Windows. Simplify.
18883         * pygnulib/GLImport.py (GLImport.execute): Update after getLink()
18884         changed.
18886         gnulib-tool.py: Fixes for conditional dependencies.
18887         * pygnulib/GLModuleSystem.py (GLModule.shell_id_chars): New constant.
18888         (GLModule.getShellFunc): Don't use md5 just because of an '_' character.
18889         (GLModule.getShellVar): Likewise.
18890         (GLModule.getConditionalName): Include a newline in the md5 input.
18891         * pygnulib/constants.py (ALPHANUMERIC): Remove constant.
18893         gnulib-tool.py: Refactor.
18894         * pygnulib/GLModuleSystem.py (GLModule.getLicense): Separate the warning
18895         logic from the result logic.
18897 2022-08-09  Paul Eggert  <eggert@cs.ucla.edu>
18899         largefile, year2038: simplify if > Autoconf 2.71
18900         * m4/largefile.m4 (gl_SET_LARGEFILE_SOURCE)
18901         (_AC_SYS_LARGEFILE_MACRO_VALUE):
18902         * m4/year2038.m4 (gl_YEAR2038_EARLY, gl_YEAR2038, gl_YEAR2038_BODY):
18903         Adjust to Autoconf versions after 2.71, which should contain the Gnulib
18904         patches in this area and so should not need to be overridden.
18906 2022-08-07  Bruno Haible  <bruno@clisp.org>
18908         gnulib-tool.py: Finish implementing option --extract-test-module.
18909         * gnulib-tool.py (main): Accept option --extract-tests-module.
18911         gnulib-tool.py: Fix handling of nonexistent module names in --extract-*.
18912         * gnulib-tool.py (main): To test whether a module exists, just call
18913         GLModuleSystem.find and test its return value.
18915         gnulib-tool.py: Fix --extract-dependencies result.
18916         * pygnulib/GLModuleSystem.py (GLModule.getDependencies): Return a
18917         snippet, not a list. Implement dependency of ${module}-tests on
18918         ${module}.
18919         (GLModule.getDependenciesWithoutConditions,
18920         GLModule.getDependenciesWithConditions): New methods.
18921         (GLModuleTable.transitive_closure): Call getDependenciesWithConditions.
18922         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippets): Call
18923         getDependenciesWithoutConditions.
18924         * gnulib-tool.py (main) [--extract-dependencies]: Update.
18926         gnulib-tool.py: Rename a method.
18927         * pygnulib/GLModuleSystem.py (GLModule.getAutoconfEarlySnippet): Renamed
18928         from GLModule.getAutoconfSnippet_Early.
18929         * pygnulib/GLImport.py: Update.
18930         * pygnulib/GLTestDir.py: Likewise.
18932         gnulib-tool.py: Fix section extraction from module descriptions.
18933         The code with   self.content.split(section)[-1]
18934         was broken because it recognizes an indented section label.
18935         Similar code with   ('\n' + self.content).split('\n' + section)[-1]
18936         would still be broken because it recognizes an indented section label
18937         in the first line of the file.
18938         The code with   section_label_regex
18939         was broken because sometimes it returns the second-to-last section with
18940         the given label, not the last one.
18941         Also, whitespace after the colon was not ignored.
18942         * pygnulib/GLModuleSystem.py (GLModule.__init__): Dissect the module
18943         description's contents immediately, once only, in a reliable way.
18944         (GLModule.getDescription, GLModule.getComment): Simplify.
18945         (GLModule.getStatus): Simplify. Return a string.
18946         (GLModule.getStatuses): New function. Return a list.
18947         (GLModule.getNotice, GLModule.getApplicability, GLModule.getFiles,
18948         GLModule.getDependencies, GLModules.getAutoconfSnippet_Early,
18949         GLModules.getAutoconfSnippet, GLModule.getAutomakeSnippet_Conditional,
18950         GLModule.getInclude, GLModule.getLink, GLModule.getLicense_Raw):
18951         Simplify.
18952         (GLModule.getLicense): Remove whitespace after calling getLicense_Raw.
18953         (GLModule.getMaintainer): Simplify.
18954         (GLModuleTable.transitive_closure): Call getStatuses() instead of
18955         getStatus().
18956         * pygnulib/GLEmiter.py: Likewise.
18957         * gnulib-tool.py (main): For --extract-description, --extract-comment,
18958         --extract-status, --extract-notice, --extract-autoconf-snippet,
18959         --extract-automake-snippet, --extract-include-directive,
18960         --extract-link-directive, --extract-maintainer, don't add an extra
18961         newline after the snippet.
18963         gnulib-tool.py: Improve field naming.
18964         * pygnulib/GLModuleSystem.py (GLModule): Rename field 'module' to
18965         'path'. Fix a typo in a TypeError message.
18967         gnulib-tool.py: Simplify.
18968         * pygnulib/GLModuleSystem.py (GLModule): Convert Windows newlines right
18969         after reading the module description, not in every accessor.
18971         gnulib-tool.py: Reduce code duplication.
18972         * pygnulib/GLModuleSystem.py (GLModule): Declare two regexes are class
18973         variables.
18975         gnulib-tool.py: Implement option --find.
18976         * pygnulib/GLModuleSystem.py (GLModuleSystem.file_is_module): New
18977         method.
18978         (GLModuleSystem.list): Filter the listing in memory; don't use a 'sed'
18979         subprocess.
18980         * gnulib-tool.py (main): Handle mode 'find'.
18982         gnulib-tool: Fix option --find in combination with option --local-dir.
18983         * gnulib-tool (func_prefixed_modules_in_dir): New function.
18984         (find): Use it, and filter the directory names away after the 'grep'
18985         pass.
18987         gnulib-tool.py: Fix some regexes.
18988         * pygnulib/GLEmiter.py (GLEmiter.lib_Makefile_am): Use an equivalent
18989         regex as gnulib-tool.
18990         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
18992         gnulib-tool.py: Fix some regex uses.
18993         * pygnulib/GLModuleSystem.py (GLModuleTable.transitive_closure): Match
18994         the regex against all lines of the snippet, not only the first line.
18995         * pygnulib/GLEmiter.py (GLEmiter.autoconfSnippet): Likewise.
18997         gnulib-tool.py: Make regex uses more straightforward.
18998         * pygnulib/constants.py: Don't use the "minimal matching" *? construct
18999         when it makes no difference (because we're matching a single line only
19000         and flag re.M is not specified).
19001         * pygnulib/GLModuleSystem.py: Likewise.
19003         gnulib-tool.py: Make regex uses more straightforward.
19004         * pygnulib/GLModuleSystem.py: Don't use flag re.S on regular expressions
19005         that are meant to match a single line only, and remove the use of the
19006         "minimal matching" *? construct whose only purpose was to neutralize the
19007         re.S flag.
19008         * pygnulib/GLEmiter.py: Likewise.
19009         * pygnulib/GLImport.py: Likewise.
19010         * pygnulib/GLTestDir.py: Likewise.
19012         gnulib-tool.py: Make regex uses more straightforward.
19013         * pygnulib/GLEmiter.py: Don't use flag re.S on regular expressions on
19014         regular expressions with no '.'.
19015         * pygnulib/GLImport.py: Likewise.
19017 2022-08-06  Bruno Haible  <bruno@clisp.org>
19019         gnulib-tool: In the VC files messages, omit the destination directory.
19020         This makes these messages consistent with the other "Copying ..." and
19021         "Creating ..." messages.
19022         * gnulib-tool (func_import): Omit $destdir/ from the "Updating"/
19023         "Creating" messages regarding .gitignore files.
19024         * pygnulib/GLImport.py (GLImport._update_ignorelist_): Likewise.
19026         gnulib-tool.py: Fix output in --dry-run mode.
19027         * pygnulib/GLImport.py (GLImport._update_ignorelist_): In dry-run mode,
19028         say "Update", not "Updating".
19030         gnulib-tool.py: Finish implementing options --vc-files, --no-vc-files.
19031         * gnulib-tool.py (main): Accept options --vc-files, --no-vc-files.
19032         * pygnulib/GLImport.py (GLImport.__init__): Correct parsing of
19033         gl_VC_FILES directive.
19034         (GLImport.gnulib_cache): Don't treat the value False like None.
19035         (GLImport.execute): Skip the .gitignore file manipulations if vc_files
19036         is False.
19038         gnulib-tool.py: Finish implementing option --witness-c-macro.
19039         * gnulib-tool.py (main): Accept option --witness-c-macro.
19040         * pygnulib/GLConfig.py (GLConfig.__init__): Remove wrong type check of
19041         witness_c_macro argument.
19043 2022-08-05  Bruno Haible  <bruno@clisp.org>
19045         gnulib-tool.py: Don't initialize local variables too early.
19046         * gnulib-tool.py (main): Initialize each local variable in one place.
19047         I prefer to have pylint tell me about uninitialized variables than to
19048         get the value None at runtime.
19050         gnulib-tool.py: Finish implementing option --po-domain.
19051         * gnulib-tool.py (main): Accept option --po-domain.
19052         * pygnulib/GLEmiter.py (GLEmiter.po_POTFILES_in): Fix variable
19053         reference.
19054         * pygnulib/GLImport.py (GLImport.execute): Don't delete Makefile.in.in
19055         from the gnulib directory. Don't require a shell when invoking wget.
19056         After invoking wget, restore the current directory.
19058         gnulib-tool.py: Finish implementing option --macro-prefix.
19059         * gnulib-tool.py (main): Accept option --macro-prefix.
19061         gnulib-tool.py: Refactor --makefile-name option.
19062         * gnulib-tool.py (main): Handle option --makefile-name like all other
19063         string-valued options.
19065         gnulib-tool.py: Implement option --no-libtool.
19066         * gnulib-tool.py (main): Accept option --no-libtool.
19068         gnulib-tool.py: Remove redundant type checks.
19069         * pygnulib/GLConfig.py (GLConfig.__init__): Remove redundant type
19070         checks, left over from 2022-08-04.
19071         (GLConfig.getIncludeGuardPrefix): Improve comment.
19072         (GLConfig.resetMacroPrefix): Optimize.
19074         gnulib-tool.py: Refactor --makefile-name option.
19075         * gnulib-tool.py (main): Rename variable 'makefile' to 'makefile_name'.
19076         * pygnulib/GLConfig.py: Rename attribute 'makefile' to 'makefile_name'.
19077         * pygnulib/GLMakefileTable.py: Update.
19078         * pygnulib/GLEmiter.py: Likewise.
19079         * pygnulib/GLImport.py: Likewise.
19080         * pygnulib/GLFileSystem.py (GLFileAssistant): Remove unused assignment.
19082         gnulib-tool.py: Fix link_if_changed function.
19083         * pygnulib/constants.py (joinpath): Fix comment.
19084         (as_link_value_at_dest): New function, extracted from link_relative.
19085         (link_relative): Use it.
19086         (link_if_changed): Really don't replace the symbolic link if it does not
19087         need to change.
19089         gnulib-tool.py: Fix 'Unused import' warnings.
19090         * gnulib-tool.py: Remove unused imports.
19091         * pygnulib/*.py: Likewise.
19093         gnulib-tool.py: Fix 'Undefined variable' errors.
19094         * pygnulib/constants.py: Import codecs.
19095         * pygnulib/GLConfig.py (GLConfig.setLibName): Fix local variable
19096         reference.
19097         * pygnulib/GLFileSystem.py (GLFileSystem.lookup,
19098         GLFileAssistant.update): Fix local variable references.
19099         * pygnulib/GLEmiter.py (GLEmiter.po_POTFILES_in): Fix reference.
19100         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Define missing local
19101         variables.
19103         gnulib-tool.py: Make option --version work.
19104         * pygnulib/constants.py (__copyright__): Bump copyright year.
19105         * pygnulib/GLInfo.py (GLInfo.authors): Add a comma after the
19106         second-to-last author.
19107         (GLInfo.copyright): Show only the last modification year.
19108         (GLInfo.date): Check whether git and GNU date are available. Use
19109         'git log ChangeLog', not 'git log'. Run 'git log' in the gnulib
19110         directory, not in the current directory. Search for 'Date:' only at the
19111         beginning of a line. As a fallback, look at the first ChangeLog entry.
19112         (GLInfo.version): Check whether git is available. Run git-version-gen in
19113         the gnulib directory, not in the current directory. Replace '-dirty'
19114         with '-modified'. As a fallback, return the empty string.
19115         * gnulib-tool.py (main) [--version]: Add a space before the version.
19117         gnulib-tool.py: Simplify.
19118         * pygnulib/constants.py (compiler): Remove function.
19119         * gnulib-tool.py: Use re.compile directly instead.
19120         * pygnulib/*.py: Likewise.
19122 2022-08-04  Bruno Haible  <bruno@clisp.org>
19124         gnulib-tool.py: Fix typo.
19125         * pygnulib/GLImport.py (GLImport.execute): Actually handle file
19126         removals.
19128         gnulib-tool.py: Coding style: Revisit line breaks.
19129         * gnulib-tool.py: Avoid line breaks at arbitrary points inside
19130         expressions. Use line breaks to clarify [... for ...] iterations.
19131         * pygnulib/*.py: Likewise.
19133         gnulib-tool.py: Simplify boolean setters.
19134         * pygnulib/GLConfig.py (setLibtool): New method, replaces enableLibtool
19135         and disableLibtool.
19136         (setCondDeps): New method, replaces enableCondDeps and disableCondDeps.
19137         (setVCFiles): New method, replaces enableVCFiles and disableVCFiles.
19138         (setSymbolic): New method, replaces enableSymbolic and disableSymbolic.
19139         (setLSymbolic): New method, replaces enableLSymbolic and
19140         disableLSymbolic.
19141         (setLibtests): New method, replaces enableLibtests and disableLibtests.
19142         (setSingleConfigure): New method, replaces enableSingleConfigure and
19143         disableSingleConfigure.
19144         (setDryRun): New method, replaces enableDryRun and disableDryRun.
19145         (setErrors): New method, replaces enableErrors and disableErrors.
19146         (__init__): Update.
19147         * pygnulib/GLImport.py: Likewise.
19148         * pygnulib/GLTestDir.py: Likewise.
19150         gnulib-tool.py: Implement options --cache-modules, --no-cache-modules.
19151         * gnulib-tool.py (main): Accept options --cache-modules,
19152         --no-cache-modules.
19153         * pygnulib/GLConfig.py: Remove modcache property and constructor
19154         argument.
19155         * pygnulib/GLInfo.py (GLInfo.usage): Don't document these no-op options.
19157         gnulib-tool.py: Use mainstream/GNU coding style.
19158         * gnulib-tool.py: Break lines before the % operator, not after.
19159         * pygnulib/*.py: Likewise. Avoid line breaks when the resulting lines
19160         are not too long.
19162         gnulib-tool.py: Follow gnulib-tool changes, part 24.
19163         Follow gnulib-tool change
19164         2017-02-19  Bruno Haible  <bruno@clisp.org>
19165         gnulib-tool: Avoid conflict of havelib-tests with --single-configure.
19166         * pygnulib/GLTestDir.py (GLTestDir.__init__): Don't allocate the
19167         GLModuleTable here.
19168         (GLTestDir.execute): Do it here. Avoid havelib-tests when
19169         --with-tests --single-configure is specified.
19171         gnulib-tool.py: Respect the specified module list.
19172         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't remove specific
19173         modules (ftruncate, mountlist, etc.) from the specified module list.
19175         gnulib-tool.py: Implement option --avoid.
19176         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Compute the
19177         effective avoids list here.
19178         (GLModuleTable.transitive_closure, GLModuleTable.add_dummy): Consider
19179         the avoids list.
19180         * pygnulib/GLImport.py (GLImport.gnulib_cache): Use the avoids list from
19181         GLConfig directly.
19182         (GLImport.prepare): No need any more to set the avoids list in the
19183         GLModuleTable.
19185         gnulib-tool.py: Make --with/--without-*-tests handling a little safer.
19186         * pygnulib/GLConfig.py (__init__): Fix reset* invocations.
19187         setInclTestCategories, setExclTestCategories): Revert to old value if
19188         the new value is invalid.
19190 2022-08-03  Bruno Haible  <bruno@clisp.org>
19192         gnulib-tool.py: Implement option --single-configure.
19193         * gnulib-tool.py (main): Accept option --single-configure. Pass its
19194         value to the GLConfig constructor.
19195         * pygnulib/GLTestDir.py (GLTestDir.execute): Remove debugging output.
19197         gnulib-tool.py: Implement options --without-c++-tests etc.
19198         * gnulib-tool.py (main): Accept options --without-c++-tests,
19199         --without-longrunning-tests, --without-privileged-tests,
19200         --without-unportable-tests.
19201         Improve error message for --copy-file with invalid number of arguments.
19202         Check for invalid options given in --import, --add-import,
19203         --remove-import, --update modes.
19204         Pass both sets of test categories to the GLConfig constructor.
19205         * pygnulib/GLConfig.py (GLConfig.__init__): Accept incl_test_categories
19206         and excl_test_categories instead of testflags.
19207         (checkInclTestCategory): Renamed from checkTestFlag.
19208         (enableInclTestCategory): Renamed from enableTestFlag.
19209         (disableInclTestCategory): Renamed from disableTestFlag.
19210         (getInclTestCategories): Renamed from getTestFlags.
19211         (setInclTestCategories): Renamed from setTestFlags.
19212         (resetInclTestCategories): Renamed from resetTestFlags.
19213         (setInclTestCategory, checkExclTestCategory, enableExclTestCategory,
19214         disableExclTestCategory, getExclTestCategories, setExclTestCategories,
19215         resetExclTestCategories): New methods.
19216         * pygnulib/GLModuleSystem.py (GLModuleTable.__init__): Accept two
19217         booleans as second and third constructor arguments.
19218         (transitive_closure): Correct the determination of whether to include
19219         each module, depending on the with-* and without-* options.
19220         (transitive_closure_separately): Update.
19221         * pygnulib/GLMakefileTable.py: Update.
19222         * pygnulib/GLImport.py (__init__, actioncmd, gnulib_cache, execute):
19223         Update.
19224         * pygnulib/GLTestDir.py (GLTestDir.__init__, GLTestDir.execute,
19225         GLMegaTestDir.__init__): Update.
19227         gnulib-tool.py: Implement option --without-tests.
19228         * gnulib-tool.py (main): Accept option --without-tests.
19230         gnulib-tool.py: Fix broken 'for' loop.
19231         * gnulib-tool.py (main): Canonicalize inctests before creating the
19232         GLConfig. Rewrite a broken 'for' loop.
19233         * pygnulib/GLConfig.py (GLConfig.setTestFlags): Remove unused statement.
19235         gnulib-tool.py: Follow gnulib-tool changes, part 23.
19236         Follow gnulib-tool changes
19237         2016-11-11  Bruno Haible  <bruno@clisp.org>
19238         gnulib-tool: Support for the dual "LGPLv3+ or GPLv2" license.
19239         2016-12-02  Nikos Mavrogiannopoulos <nmav@gnutls.org>
19240         gnulib-tool (func_import): Adhere to the license guideline ...
19241         2016-12-02  Daiki Ueno  <ueno@gnu.org>
19242         gnulib-tool (func_import): Relax the regex ...
19243         * gnulib-tool.py: For --lgpl, accept value 3orGPLv2.
19244         * pygnulib/GLInfo.py (GLInfo.usage): Update.
19245         * pygnulib/GLConfig.py (GLConfig.setLGPL): Update argument check.
19246         * pygnulib/GLImport.py (GLImport.__init__, GLImport.gnulib_cache):
19247         Update gl_LGPL handling.
19248         (GLImport.prepare): Update license compatibility checks and license
19249         header rewriting.
19250         * pygnulib/GLTestDir.py (GLTestDir.execute): Update license
19251         compatibility checks. Handle also the licenses GPLv3+, GPL, LGPLv3+.
19253         gnulib-tool.py: Fix unjustified "incompatible license" warnings.
19254         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't emit a warning when
19255         the dependency module has a license such as "public domain" or
19256         "unlimited".
19258         gnulib-tool.py: Follow gnulib-tool changes, part 22.
19259         Follow gnulib-tool change
19260         2016-10-15  Bruno Haible  <bruno@clisp.org>
19261         Avoid gnulib-tool warnings about the dependencies of 'parse-datetime'.
19262         * pygnulib/GLModuleSystem.py (GLModule.getLicense): Special-case the
19263         'parse-datetime' module.
19265         gnulib-tool.py: Follow gnulib-tool changes, part 21.
19266         Follow gnulib-tool change
19267         2016-10-16  Bruno Haible  <bruno@clisp.org>
19268         gnulib-tool: Make --create-testdir on all modules work again.
19269         * pygnulib/GLTestDir.py (GLTestDir.execute): Don't include the
19270         non-recursive-gnulib-prefix-hack module.
19272         gnulib-tool.py: Follow gnulib-tool changes, part 20.
19273         Follow gnulib-tool changes
19274         2016-01-15  Paul Eggert  <eggert@cs.ucla.edu>
19275         gnulib-tool: don't assume ln -s works
19276         2016-01-24  Paul Eggert  <eggert@cs.ucla.edu>
19277         gnulib-tool: don't give up on ln -s so easily
19278         2017-06-08  Bruno Haible  <bruno@clisp.org>
19279         gnulib-tool: Fix bug in func_ln_s, from 2016-01-15.
19280         * pygnulib/constants.py (symlink_relative): New function.
19281         (link_relative): Use it instead of os.symlink.
19283         gnulib-tool.py: Avoid errors when writing to a VFAT file system, part 2.
19284         * pygnulib/constants.py (movefile): New function.
19285         * pygnulib/*.py: Use it instead of shutil.
19287         gnulib-tool.py: Avoid errors when writing to a VFAT file system.
19288         * pygnulib/constants.py (copyfile, copyfile2): New functions.
19289         * gnulib-tool.py: Use them instead of shutil.
19290         * pygnulib/*.py: Likewise.
19292         gnulib-tool.py: Fix typo.
19293         * pygnulib/GLImport.py (GLImport.__init__): Use the relative auxdir as
19294         second, not as first argument of joinpath.
19296 2022-07-31  Bruno Haible  <bruno@clisp.org>
19298         gnulib-tool.py: Fix typo.
19299         * pygnulib/GLTestDir.py (GLMegaTestDir.execute): Invoke os.mkdir as
19300         intended.
19302         gnulib-tool.py: Improve some error messages.
19303         * gnulib-tool.py (main): Write "*** Stop." instead of "*** Exit.".
19304         (__main__): Print an error message for GLError 5, 13, 14, 15, 16, 17, 18.
19305         * pygnulib/GLError.py (GLError.__repr__): Compute one error message,
19306         not 19.
19308         gnulib-tool.py: Write errors to stderr, not stdout.
19309         * pygnulib/constants.py: Write error messages to stderr, not stdout.
19311         gnulib-tool.py: Use mainstream coding style.
19312         * pygnulib/GLConfig.py: Use 'raise' to re-throw an exception.
19314         gnulib-tool.py: Implement options --symlink and --local-symlink.
19315         * gnulib-tool.py (main): Handle options --symlink and --local-symlink.
19316         * pygnulib/constants.py (link_if_changed): Ignore FileNotFoundError from
19317         os.remove call.
19319         gnulib-tool.py: Make --copy-file work.
19320         * gnulib-tool.py (main) [copy-file]: Fix reference to uninitialized
19321         variable. Fix error handling of os.makedirs. Pass the destdir to the
19322         GLFileAssistant.
19324         gnulib-tool.py: Allow module arguments to occur at any position.
19325         * gnulib-tool.py (main): Collect the non-option arguments in a single
19326         list, regardless of their position. Use parse_known_args instead of
19327         parse_args, and give an error message about unknown options ourselves.
19328         * gnulib-tool: Fix typo in error message.
19330         gnulib-tool.py: Make --test behaviour more similar to gnulib-tool.
19331         * gnulib-tool.py (main) [test]: Remove space from the testdir name.
19333         gnulib-tool: Clarify that --test allows zero module arguments.
19334         * gnulib-tool (func_usage): Mark the modules for --test as optional.
19335         * pygnulib/GLInfo.py (GLInfo.usage): Likewise.
19337         gnulib-tool.py: Make option processing more similar to gnulib-tool.
19338         * gnulib-tool.py (main): Allow --add-import and --remove-import with 0
19339         modules.
19341         gnulib-tool.py: Improve compliance with GNU standards.
19342         * gnulib-tool.py (main): Handle --help and --version before testing for
19343         conflicting modes.
19345         gnulib-tool.py: Emit error message when conflicting modes are specified.
19346         * gnulib-tool.py (main): Fix test of conflicting modes. (Some options
19347         produce a value of [], and as a condition, [] evaluates to False.)
19349         gnulib-tool.py: Remove most short options.
19350         * gnulib-tool.py (main): Reorder the list of options. Remove most short
19351         options, for consistency with gnulib-tool.
19353         gnulib-tool.py: Follow gnulib-tool changes, part 19.
19354         Follow gnulib-tool changes
19355         2015-12-09  Pavel Raiskup  <praiskup@redhat.com>
19356         gnulib-tool: allow multiple --local-dir usage
19357         2019-02-14  Bruno Haible  <bruno@clisp.org>
19358         gnulib-tool: Improve handling of multiple --local-dir options.
19359         * gnulib-tool (func_reconstruct_cached_dir): When the argument is
19360         absolute, return it unmodified.
19361         (func_compute_relative_local_gnulib_path): Renamed from
19362         func_count_relative_local_gnulib_path. Add comment.
19363         * gnulib-tool.py: Accept multiple --local-dir options and collect the
19364         values into localpath.
19365         * pygnulib/GLConfig.py: Take a localpath argument instead of a localdir
19366         argument.
19367         (getLocalDir, setLocalDir, resetLocalDir): Remove methods.
19368         (getLocalPath, setLocalPath, resetLocalPath): New methods.
19369         * pygnulib/GLFileSystem.py (CopyAction): New class.
19370         (GLFileSystem.lookup): Consider all dirs in localpath.
19371         (GLFileSystem.shouldLink): New method.
19372         (GLFileAssistant): Use shouldLink.
19373         * pygnulib/GLModuleSystem.py (GLModuleSystem.exists): Iterate over all
19374         dirs in localpath.
19375         (GLModuleSystem.list): Likewise.
19376         * pygnulib/GLEmiter.py: Update.
19377         * pygnulib/GLImport.py (GLImport.__init__): Put the argument of
19378         gl_LOCAL_DIR into localpath, not localdir.
19379         (GLImport.actioncmd): Consider all dirs in localpath.
19380         (GLImport.relative_to_destdir, GLImport.relative_to_currdir): New
19381         methods.
19382         (GLImport.gnulib_cache): Combine all dirs in localpath. Use
19383         self.relative_to_destdir.
19384         * pygnulib/GLTestDir.py (GLTestDir.execute): Use shouldLink.
19386         gnulib-tool.py: Improve the primitives for relative file names.
19387         * pygnulib/constants.py (relativize): Don't attempt to handle absolute
19388         file names. Fix bug with relativize('../foo/bar', '../foo/bla/zut').
19389         (relconcat): New function.
19391         gnulib-tool.py: Follow gnulib-tool changes, part 18.
19392         Follow gnulib-tool change
19393         2005-09-20  Bruno Haible  <bruno@clisp.org>
19394         gnulib-tool: Remove trailing slashes
19395         * pygnulib/constants.py (remove_trailing_slashes): New function.
19396         * pygnulib/GLConfig.py (GLConfig): Use it in the setters.
19398 2022-07-31  Bruno Haible  <bruno@clisp.org>
19400         avltree-omap, avltree-oset, avltreehash-list, rbtree-omap: Pacify GCC.
19401         * lib/gl_avltree_omap.c (gl_avltree_omap_check_invariants): Add extern
19402         decl.
19403         * lib/gl_avltree_oset.c (gl_avltree_oset_check_invariants): Likewise.
19404         * lib/gl_avltreehash_list.c (gl_avltreehash_list_check_invariants):
19405         Likewise.
19406         * lib/gl_rbtree_omap.c (gl_rbtree_omap_check_invariants): Likewise.
19408 2022-07-31  Paul Eggert  <eggert@cs.ucla.edu>
19410         rbtree-oset, rbtreehash-list: Pacify GCC
19411         * lib/gl_rbtree_oset.c (gl_rbtree_oset_check_invariants):
19412         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_check_invariants):
19413         Add extern decls, to pacify --enable-gcc-warnings with Bison.
19415 2022-07-31  Akim Demaille  <akim@lrde.epita.fr>
19417         gnulib-tool: add support for --automake-subdir-tests
19418         <https://lists.gnu.org/r/bug-gnulib/2022-01/msg00111.html>
19419         * gnulib-tool (main): Handle --automake-subdir-tests.
19420         (func_emit_shellvars_init, func_emit_lib_Makefile_am): Use
19421         $sourcebase when handling tests and --automake-subdir-tests is
19422         given.
19423         (func_append_actionarg): Support --automake-subdir-tests.
19424         (func_create_testdir): Add missing argument for func_emit_initmacro_end.
19426 2022-07-31  Bruno Haible  <bruno@clisp.org>
19428         gendocs.sh: Fix error when invoking 'perl' (regression 2022-07-23).
19429         * build-aux/gendocs.sh (PERL): Use double-quotes, not single-quotes.
19431 2022-07-30  Bruno Haible  <bruno@clisp.org>
19433         gnulib-tool.py: Clean up imports.
19434         * gnulib-tool.py: Remove unused constants.
19435         * pygnulib/*.py: Likewise.
19437         gnulib-tool.py: Assume Python 3.
19438         * gnulib-tool.py: Don't allow 'bytes' as an alternative to 'str'.
19439         * pygnulib/*.py: Likewise.
19441         gnulib-tool.py: Assume Python 3.
19442         * gnulib-tool.py: Don't set PYTHON3, string. Use str instead of string.
19443         * pygnulib/*.py: Likewise.
19445         gnulib-tool.py: Modernize coding style.
19446         * pygnulib/*.py: Remove parentheses around raise value expressions.
19448 2022-07-30  Bruno Haible  <bruno@clisp.org>
19450         doc: Update regarding bootstrap split.
19451         Reported by Paul Smith <psmith@gnu.org>.
19452         * doc/gnulib-tool.texi (gettextize and autopoint): Mention autogen.sh
19453         instead of bootstrap.
19454         (VCS Issues): Describe three alternative approaches.
19455         * doc/gnulib.texi (Developer tools): Mention also autopull.sh and
19456         autogen.sh.
19457         * top/bootstrap (usage): Fix copy&paste mistake.
19459 2022-07-29  Bruno Haible  <bruno@clisp.org>
19461         gnulib-tool.py: Follow gnulib-tool changes, part 17.
19462         Follow gnulib-tool change
19463         2015-10-06  Pavel Raiskup  <praiskup@redhat.com>
19464         gnulib-tool: fix tests of 'extensions' module
19465         * pygnulib/GLEmiter.py (GLEmiter.preEarlyMacros): New function.
19466         * pygnulib/GLImport.py (GLImport.gnulib_comp): Invoke it.
19467         * pygnulib/GLTestDir.py (GLTestDir.execute): Likewise.
19469         gnulib-tool.py: Follow gnulib-tool changes, part 16.
19470         Follow gnulib-tool change
19471         2015-09-25  Pavel Raiskup  <praiskup@redhat.com>
19472         gnulib-common.m4: fix gl_PROG_AR_RANLIB/AM_PROG_AR clash
19473         * pygnulib/GLImport.py (GLImport.gnulib_comp): Put the
19474         gl_USE_SYSTEM_EXTENSIONS right before gl_PROG_AR_RANLIB into
19475         gnulib-comp.m4 (if the 'extensions' module is used).
19477         gnulib-tool.py: Modernize coding style.
19478         * pygnulib/*.py: Remove parentheses around return value expressions.
19480         gnulib-tool.py: Modernize the file headers.
19481         * pygnulib/*.py: Remove '#!/usr/bin/python' (not needed) and
19482         'encoding: UTF-8' lines (default in Python 3). Add copyright notice.
19484         gnulib-tool.py: Use mainstream coding style.
19485         * gnulib-tool.py: Clarify the coding style. Fix some pycodestyle
19486         warnings.
19487         * pygnulib/constants.py: Likewise.
19488         * pygnulib/GLEmiter.py: Likewise.
19489         * pygnulib/GLImport.py: Likewise.
19490         * pygnulib/GLMakefileTable.py: Likewise.
19492 2022-07-29  Bruno Haible  <bruno@clisp.org>
19494         gnulib-tool.py: Fix error (regression 2021-04-11).
19495         * pygnulib/GLConfig.py (GLConfig.getModuleIndicatorPrefix): Fix code.
19497         gnulib-tool.py: Fix warning from Python 3.10.4.
19498         * pygnulib/GLModuleSystem.py (getConditionalName): Fix a string
19499         substitution expression.
19501         gnulib-tool.py: Fix error in Ubuntu 22.04.
19502         * gnulib-tool.py: Search for python3 in $PATH.
19504 2022-07-25  Bruno Haible  <bruno@clisp.org>
19506         bootstrap: Make the automatic sync more resilient.
19507         Reported by Paul Eggert in
19508         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00060.html>.
19509         * top/bootstrap (bootstrap_sync): Set to true when bootstrap-funclib.sh
19510         is not present.
19511         * top/gen-bootstrap.sed: Insert a couple of comment lines.
19512         * build-aux/bootstrap: Regenerated using "make build-aux/bootstrap".
19514 2022-07-24  Bruno Haible  <bruno@clisp.org>
19516         Fix comment.
19517         Reported by Paul Eggert in
19518         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00058.html>.
19519         * top/bootstrap-funclib.sh: Fix comment about canonical location.
19520         * top/autopull.sh: Likewise.
19521         * top/autogen.sh: Likewise.
19522         * top/bootstrap: Likewise.
19524         Split bootstrap into autopull.sh and autogen.sh.
19525         * top/bootstrap-funclib.sh: New file, based on build-aux/bootstrap.
19526         * top/autopull.sh: New file, based on build-aux/bootstrap.
19527         * top/autogen.sh: New file, based on build-aux/bootstrap.
19528         * top/bootstrap: New file, based on build-aux/bootstrap.
19529         * top/gen-bootstrap.sed: New file.
19530         * Makefile (build-aux/bootstrap): New rule.
19531         (regen): Depend on it.
19532         * build-aux/bootstrap: Regenerated using "make build-aux/bootstrap".
19534 2022-07-24  Bruno Haible  <bruno@clisp.org>
19536         bootstrap: Obey another environment variable GNULIB_REFDIR.
19537         * build-aux/bootstrap (usage): Document option --gnulib-refdir and
19538         environment variable GNULIB_REFDIR.
19539         Accept option --gnulib-refdir.
19540         When GNULIB_SRCDIR is specified, verify that it denotes a directory.
19541         Use $GNULIB_REFDIR, not $GNULIB_SRCDIR, as argument to git's --reference
19542         option.
19543         Improve an error message.
19544         * NEWS: Mention the change.
19546 2022-07-23  Bruno Haible  <bruno@clisp.org>
19548         Fix a couple of ShellCheck warnings.
19549         * MODULES.html.sh (sed_escape_slash): Remove unused variable.
19550         * build-aux/bootstrap: Avoid computed printf format strings.
19551         * build-aux/do-release-commit-and-tag: Likewise.
19552         * build-aux/gendocs.sh: Likewise.
19553         * build-aux/declared.sh: Fix "unrecognized option" message.
19554         * gnulib-tool (supplied_opts): Remove unused variable.
19555         (--single-con): Remove redundant option recognition.
19556         * tests/test-parse-duration.sh (nl): Remove unused variable.
19557         * tests/test-update-copyright.sh: Use double-quotes instead of
19558         single-quotes.
19560 2022-07-23  Bruno Haible  <bruno@clisp.org>
19562         Avoid DoS vulnerability through unsafe default assignment.
19563         See https://www.shellcheck.net/wiki/SC2223 .
19564         * MODULES.html.sh (func_tmpdir): Surround default assignment with
19565         double-quotes.
19566         * build-aux/bootstrap: Likewise.
19567         * build-aux/csharpcomp.sh.in (func_tmpdir): Likewise.
19568         * build-aux/gendocs.sh: Likewise.
19569         * build-aux/libtool-next-version (func_tmpdir): Likewise.
19570         * config/srclist-update: Likewise.
19571         * gnulib-tool (func_tmpdir): Likewise.
19572         * posix-modules (func_tmpdir): Likewise.
19573         * tests/test-atexit.sh: Likewise.
19574         * tests/test-btoc32-1.sh: Likewise.
19575         * tests/test-btoc32-2.sh: Likewise.
19576         * tests/test-btowc1.sh: Likewise.
19577         * tests/test-btowc2.sh: Likewise.
19578         * tests/test-c-dtoastr.sh: Likewise.
19579         * tests/test-c-ldtoastr.sh: Likewise.
19580         * tests/test-c-snprintf.sh: Likewise.
19581         * tests/test-c-strcase.sh: Likewise.
19582         * tests/test-c-vasprintf.sh: Likewise.
19583         * tests/test-c-vsnprintf.sh: Likewise.
19584         * tests/test-c-xvasprintf.sh: Likewise.
19585         * tests/test-c32isalnum.sh: Likewise.
19586         * tests/test-c32isalpha.sh: Likewise.
19587         * tests/test-c32isblank.sh: Likewise.
19588         * tests/test-c32iscntrl.sh: Likewise.
19589         * tests/test-c32isdigit.sh: Likewise.
19590         * tests/test-c32isgraph.sh: Likewise.
19591         * tests/test-c32islower.sh: Likewise.
19592         * tests/test-c32isprint.sh: Likewise.
19593         * tests/test-c32ispunct.sh: Likewise.
19594         * tests/test-c32isspace.sh: Likewise.
19595         * tests/test-c32isupper.sh: Likewise.
19596         * tests/test-c32isxdigit.sh: Likewise.
19597         * tests/test-c32rtomb.sh: Likewise.
19598         * tests/test-c32snrtombs-1.sh: Likewise.
19599         * tests/test-c32snrtombs-2.sh: Likewise.
19600         * tests/test-c32snrtombs-3.sh: Likewise.
19601         * tests/test-c32snrtombs-4.sh: Likewise.
19602         * tests/test-c32srtombs-1.sh: Likewise.
19603         * tests/test-c32srtombs-2.sh: Likewise.
19604         * tests/test-c32srtombs-3.sh: Likewise.
19605         * tests/test-c32srtombs-4.sh: Likewise.
19606         * tests/test-c32stombs-1.sh: Likewise.
19607         * tests/test-c32stombs-2.sh: Likewise.
19608         * tests/test-c32stombs-3.sh: Likewise.
19609         * tests/test-c32stombs-4.sh: Likewise.
19610         * tests/test-closein.sh: Likewise.
19611         * tests/test-copy-acl.sh (func_tmpdir): Likewise.
19612         * tests/test-copy-file.sh (func_tmpdir): Likewise.
19613         * tests/test-dprintf-posix.sh: Likewise.
19614         * tests/test-execl.sh: Likewise.
19615         * tests/test-execle.sh: Likewise.
19616         * tests/test-execlp.sh: Likewise.
19617         * tests/test-execv.sh: Likewise.
19618         * tests/test-execve.sh: Likewise.
19619         * tests/test-execvp.sh: Likewise.
19620         * tests/test-execvpe.sh: Likewise.
19621         * tests/test-file-has-acl.sh (func_tmpdir): Likewise.
19622         * tests/test-fprintf-posix.sh: Likewise.
19623         * tests/test-init.sh: Likewise.
19624         * tests/test-iswdigit.sh: Likewise.
19625         * tests/test-iswxdigit.sh: Likewise.
19626         * tests/test-mbmemcasecmp1.sh: Likewise.
19627         * tests/test-mbmemcasecmp2.sh: Likewise.
19628         * tests/test-mbmemcasecmp3.sh: Likewise.
19629         * tests/test-mbmemcasecoll1.sh: Likewise.
19630         * tests/test-mbmemcasecoll2.sh: Likewise.
19631         * tests/test-mbmemcasecoll3.sh: Likewise.
19632         * tests/test-mbrtoc32-1.sh: Likewise.
19633         * tests/test-mbrtoc32-2.sh: Likewise.
19634         * tests/test-mbrtoc32-3.sh: Likewise.
19635         * tests/test-mbrtoc32-4.sh: Likewise.
19636         * tests/test-mbrtowc1.sh: Likewise.
19637         * tests/test-mbrtowc2.sh: Likewise.
19638         * tests/test-mbrtowc3.sh: Likewise.
19639         * tests/test-mbrtowc4.sh: Likewise.
19640         * tests/test-mbscasecmp.sh: Likewise.
19641         * tests/test-mbscasestr2.sh: Likewise.
19642         * tests/test-mbscasestr3.sh: Likewise.
19643         * tests/test-mbscasestr4.sh: Likewise.
19644         * tests/test-mbschr.sh: Likewise.
19645         * tests/test-mbscspn.sh: Likewise.
19646         * tests/test-mbsinit.sh: Likewise.
19647         * tests/test-mbsncasecmp.sh: Likewise.
19648         * tests/test-mbsnrtoc32s-1.sh: Likewise.
19649         * tests/test-mbsnrtoc32s-2.sh: Likewise.
19650         * tests/test-mbsnrtoc32s-3.sh: Likewise.
19651         * tests/test-mbsnrtoc32s-4.sh: Likewise.
19652         * tests/test-mbsnrtowcs1.sh: Likewise.
19653         * tests/test-mbsnrtowcs2.sh: Likewise.
19654         * tests/test-mbsnrtowcs3.sh: Likewise.
19655         * tests/test-mbsnrtowcs4.sh: Likewise.
19656         * tests/test-mbspbrk.sh: Likewise.
19657         * tests/test-mbspcasecmp.sh: Likewise.
19658         * tests/test-mbsrchr.sh: Likewise.
19659         * tests/test-mbsrtoc32s-1.sh: Likewise.
19660         * tests/test-mbsrtoc32s-2.sh: Likewise.
19661         * tests/test-mbsrtoc32s-3.sh: Likewise.
19662         * tests/test-mbsrtoc32s-4.sh: Likewise.
19663         * tests/test-mbsrtowcs1.sh: Likewise.
19664         * tests/test-mbsrtowcs2.sh: Likewise.
19665         * tests/test-mbsrtowcs3.sh: Likewise.
19666         * tests/test-mbsrtowcs4.sh: Likewise.
19667         * tests/test-mbsspn.sh: Likewise.
19668         * tests/test-mbsstr2.sh: Likewise.
19669         * tests/test-mbsstr3.sh: Likewise.
19670         * tests/test-mbstoc32s-1.sh: Likewise.
19671         * tests/test-mbstoc32s-2.sh: Likewise.
19672         * tests/test-mbstoc32s-3.sh: Likewise.
19673         * tests/test-mbstoc32s-4.sh: Likewise.
19674         * tests/test-nl_langinfo.sh: Likewise.
19675         * tests/test-parse-duration.sh (func_tmpdir): Likewise.
19676         * tests/test-perror.sh: Likewise.
19677         * tests/test-printf-posix.sh: Likewise.
19678         * tests/test-set-mode-acl.sh (func_tmpdir): Likewise.
19679         * tests/test-setlocale1.sh: Likewise.
19680         * tests/test-strtod1.sh: Likewise.
19681         * tests/test-strtold1.sh: Likewise.
19682         * tests/test-unicodeio2.sh: Likewise.
19683         * tests/test-unicodeio3.sh: Likewise.
19684         * tests/test-vasnprintf-posix2.sh: Likewise.
19685         * tests/test-vc-list-files-cvs.sh: Likewise.
19686         * tests/test-vc-list-files-git.sh: Likewise.
19687         * tests/test-vdprintf-posix.sh: Likewise.
19688         * tests/test-vfprintf-posix.sh: Likewise.
19689         * tests/test-vprintf-posix.sh: Likewise.
19690         * tests/test-wcrtomb.sh: Likewise.
19691         * tests/test-wcsnrtombs1.sh: Likewise.
19692         * tests/test-wcsnrtombs2.sh: Likewise.
19693         * tests/test-wcsnrtombs3.sh: Likewise.
19694         * tests/test-wcsnrtombs4.sh: Likewise.
19695         * tests/test-wcsrtombs1.sh: Likewise.
19696         * tests/test-wcsrtombs2.sh: Likewise.
19697         * tests/test-wcsrtombs3.sh: Likewise.
19698         * tests/test-wcsrtombs4.sh: Likewise.
19699         * tests/test-xprintf-posix.sh: Likewise.
19700         * tests/test-xstrtoimax.sh: Likewise.
19701         * tests/test-xstrtol.sh: Likewise.
19702         * tests/test-xstrtoll.sh: Likewise.
19703         * tests/test-xstrtoumax.sh: Likewise.
19704         * tests/test-yesno.sh: Likewise.
19705         * tests/unicase/test-locale-language.sh: Likewise.
19706         * tests/unicase/test-ulc-casecmp1.sh: Likewise.
19707         * tests/unicase/test-ulc-casecmp2.sh: Likewise.
19708         * tests/unicase/test-ulc-casecoll1.sh: Likewise.
19709         * tests/unicase/test-ulc-casecoll2.sh: Likewise.
19710         * tests/unigbrk/test-ulc-grapheme-breaks.sh: Likewise.
19711         * tests/unistdio/test-u16-vasnprintf2.sh: Likewise.
19712         * tests/unistdio/test-u16-vasnprintf3.sh: Likewise.
19713         * tests/unistdio/test-u32-vasnprintf2.sh: Likewise.
19714         * tests/unistdio/test-u32-vasnprintf3.sh: Likewise.
19715         * tests/unistdio/test-u8-vasnprintf2.sh: Likewise.
19716         * tests/unistdio/test-u8-vasnprintf3.sh: Likewise.
19717         * tests/unistdio/test-ulc-vasnprintf2.sh: Likewise.
19718         * tests/unistdio/test-ulc-vasnprintf3.sh: Likewise.
19719         * tests/uniwbrk/test-ulc-wordbreaks.sh: Likewise.
19720         * tests/uniwidth/test-uc_width2.sh: Likewise.
19722 2022-07-18  Bruno Haible  <bruno@clisp.org>
19724         bootstrap: Comments.
19725         * build-aux/bootstrap: Comment about two unused variables.
19727 2022-07-17  Bruno Haible  <bruno@clisp.org>
19729         doc: Update README.
19730         * doc/README: Fix stale links (reported by Tzvetelin Katchov). Clarify
19731         the relation to build-aux/gnu-web-doc-update.
19733 2022-07-14  Bruno Haible  <bruno@clisp.org>
19735         doc: Fix typo.
19736         Reported by Eric Gallager <egall@gwmail.gwu.edu> in
19737         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00045.html>.
19738         * doc/posix-functions/mmap.texi: Add parenthesis.
19740 2022-07-12  Paul Eggert  <eggert@cs.ucla.edu>
19742         parse-datetime: improve doc for TZ="<-07>7" etc.
19743         * doc/parse-datetime.texi (Specifying time zone rules):
19744         Give examples of POSIX TZ strings that specify UTC offsets (Bug#56524).
19746 2022-07-10  Bruno Haible  <bruno@clisp.org>
19748         sigsegv: Optimize stackvma implementation for AIX 7.
19749         Reported by Neha Jain <nehajain29@in.ibm.com> in
19750         <https://lists.gnu.org/archive/html/bug-m4/2022-06/msg00005.html>
19751         via Eric Blake.
19752         * lib/stackvma.c: For AIX, add implementation that uses /proc/$pid/map,
19753         based on lib/vma-iter.c.
19754         (sigsegv_get_vma): Use it on AIX 7 or higher.
19756 2022-07-10  Bruno Haible  <bruno@clisp.org>
19758         vma-iter: Add support for AIX 7.
19759         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on AIX.
19760         * lib/vma-iter.c (vma_iterate): Add code for AIX, known to work on
19761         AIX 7.
19762         * lib/get-rusage-as.c: Update comments.
19763         * lib/get-rusage-data.c: Likewise.
19764         * tests/test-get-rusage-as.c (main): Take into account the special
19765         address space organization on AIX in 32-bit mode.
19767 2022-07-10  Bruno Haible  <bruno@clisp.org>
19769         iconv: Define a summary result.
19770         Reported by Simon Josefsson in
19771         <https://lists.gnu.org/archive/html/bug-gnulib/2022-07/msg00020.html>.
19772         * m4/iconv.m4 (AM_ICONV): Define also am_cv_func_iconv_summary.
19774 2022-07-10  Bruno Haible  <bruno@clisp.org>
19776         iconv: Remove obsolete comment.
19777         * m4/iconv.m4 (AM_ICONV): Remove comment that is obsolete since
19778         2020-08-16.
19780 2022-07-10  Bruno Haible  <bruno@clisp.org>
19782         announce-gen: Fix internationalization in verification instructions.
19783         * build-aux/announce-gen: Set LC_ALL, not LANG, to "C", to force English
19784         output from gpg.
19786 2022-07-10  Bruno Haible  <bruno@clisp.org>
19788         lib-symbol-visibility: Improve documentation.
19789         * doc/lib-symbol-visibility.texi: Tweak BUILDING_SHARED snippet.
19791 2022-07-10  Bruno Haible  <bruno@clisp.org>
19793         doc: Mark Minix as no longer tested.
19794         Rationale: No commits since 2018 at https://git.minix3.org/.
19795         Reported by Paul Eggert and Jim Meyering in
19796         <https://lists.gnu.org/archive/html/grep-devel/2022-07/msg00027.html>.
19797         * doc/gnulib-intro.texi (Supported Platforms): Mark Minix as no longer
19798         tested.
19800 2022-07-09  Jim Meyering  <meyering@fb.com>
19802         announce-gen: better diagnose some usage errors
19803         * build-aux/announce-gen (main): Erroneous usage would elicit a
19804         misleading diagnostic. When --gnulib-version=V was specified:
19805         - without --bootstrap_tools, or
19806         - with --bootstrap_tools, but without listing "gnulib" as a tool
19807         we would give an inappropriate diagnostic. Now, each diagnostic
19808         is tailored to the precise erroneous condition.
19809         Reported by Bruno Haible in
19810         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00025.html
19812 2022-07-09  Simon Josefsson  <simon@josefsson.org>
19814         git-version-gen: Doc fix.
19815         Reported by Reuben Thomas <rrt@sc3d.org> in
19816         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00012.html>.
19817         * build-aux/git-version-gen (usage): Replace incorrect text with
19818         bug report instructions.
19820 2022-07-09  Simon Josefsson  <simon@josefsson.org>
19822         announce-gen: Improve GnuPG verification instructions.
19823         * build-aux/announce-gen: Add GPG fingerprint to output, and a
19824         pointer to GNU keyring.
19826 2022-07-08  Simon Josefsson  <simon@josefsson.org>
19828         lib-symbol-visibility: Improve documentation.
19829         * doc/lib-symbol-visibility.texi: Include BUILDING_SHARED snippet
19830         suggested by Bruno Haible.
19832 2022-07-04  Bruno Haible  <bruno@clisp.org>
19834         havelib: Fix 'configure --help' output.
19835         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Fix m4 quoting bug.
19837 2022-07-03  Bruno Haible  <bruno@clisp.org>
19839         lib-symbol-visibility: Improve documentation.
19840         Reported by Vivien Kraus <vivien@planete-kraus.eu> in
19841         <https://lists.gnu.org/archive/html/bug-gnulib/2022-06/msg00093.html>.
19842         * doc/lib-symbol-visibility.texi: List the platforms. Extend the
19843         LIBFOO_DLL_EXPORTED to work also with mingw and also with
19844         --disable-shared.
19846 2022-07-03  Bruno Haible  <bruno@clisp.org>
19848         supersede: Support the file name "/dev/null" on native Windows.
19849         * lib/supersede.c (open_supersede): On native Windows, map "/dev/null"
19850         to "NUL".
19852 2022-06-23  Jim Meyering  <meyering@fb.com>
19854         maint.mk: fix syntax-check for unnecessary hash.h header use
19855         * top/maint.mk (_hash_re): Correct the regexp. It had two problems:
19856         - lacked the "hash_" prefix, so would match non-uses
19857         - failed to detect uses of the hash_x?initialize functions
19858         The former led to an excess/unneeded use of hash.h in coreutils' cut.c.
19859         The latter would have led to a FP "not needed" report for copy.c.
19861 2022-06-22  Bruno Haible  <bruno@clisp.org>
19863         fchmodat: Fix test failure on native Windows.
19864         * modules/fchmodat (Depends-on): Add 'chmod'.
19866 2022-06-22  Bruno Haible  <bruno@clisp.org>
19868         chmod: Add tests.
19869         * tests/test-chmod.c: New file, based on tests/test-lchmod.c.
19870         * modules/chmod-tests: New file.
19872         chmod: New module.
19873         * lib/sys_stat.in.h (chmod): Declare when GNULIB_CHMOD is 1.
19874         * lib/chmod.c: New file, based on lib/lchmod.c.
19875         * m4/chmod.m4: New file, based on m4/fchmodat.m4.
19876         * m4/sys_stat_h.m4 (gl_SYS_STAT_H): Test whether chmod is declared.
19877         (gl_SYS_STAT_H_REQUIRE_DEFAULTS): Initialize GNULIB_CHMOD.
19878         (gl_SYS_STAT_H_DEFAULTS): Initialize REPLACE_CHMOD.
19879         * modules/sys_stat (Makefile.am): Substitute GNULIB_CHMOD,
19880         REPLACE_CHMOD.
19881         * modules/chmod: New file, based on modules/lchmod.
19882         * doc/posix-functions/chmod.texi: Mention the new module and the
19883         problems on IRIX and Windows.
19885 2022-06-21  Bruno Haible  <bruno@clisp.org>
19887         lchmod: Simplify.
19888         * lib/lchmod.c: Remove unnecessary include, obsolete since 2020-02-23.
19890 2022-06-20  Bruno Haible  <bruno@clisp.org>
19892         javacomp-script, javaexec-script: Add support for disabling Java.
19893         * m4/javacomp.m4 (gt_JAVACOMP_DISABLED): New macro.
19894         * m4/javaexec.m4 (gt_JAVAEXEC_DISABLED): New macro.
19896 2022-06-19  Paul Eggert  <eggert@cs.ucla.edu>
19898         lchmod: port back to AIX 7.2
19899         Problem reported by Bruno Haible in:
19900         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00075.html
19901         * lib/lchmod.c: Include string.h, for strlen.
19902         (lchmod): Do not depend on HAVE_READLINK since we now depend on
19903         the readlink module.  Check for AIX 7.2 bug.
19904         * m4/lchmod.m4 (gl_PREREQ_LCHMOD): Do not check for readlink
19905         since we now depend on the readlink module.
19906         * modules/lchmod (Depends-on): Depend on readlink.
19908         fchmodat: pacify gcc -Wunused-variable
19909         Problem reported by Bruno Haible in:
19910         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00075.html
19911         * lib/fchmodat.c (fchmodat): Remove unused local.
19913 2022-06-19  Bruno Haible  <bruno@clisp.org>
19915         getlogin, getlogin_r tests: Really avoid test failure.
19916         Reported by Letu Ren <fantasquex@gmail.com> in
19917         <https://lists.gnu.org/archive/html/bug-gnulib/2022-06/msg00037.html>.
19918         * tests/test-getlogin.h (test_getlogin_result): Parse the contents of
19919         /proc/self/loginuid as an unsigned integer.
19921 2022-06-12  Paul Eggert  <eggert@cs.ucla.edu>
19923         fchmodat: port better to MS-Windows etc.
19924         MS-Windows problem reported by Bruno Haible in:
19925         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00041.html
19926         Although I don’t use MS-Windows I see some related fstatat etc.
19927         problems and am trying to fix them with this further patch.
19928         * lib/fchmodat.c (fchmodat):
19929         * lib/lchmod.c (lchmod):
19930         * lib/lchown.c (lchown)
19931         [!HAVE_LCHOWN && HAVE_CHOWN && !CHOWN_MODIFIES_SYMLINK]:
19932         * lib/renameatu.c (renameatu)
19933         [HAVE_RENAME && RENAME_TRAILING_SLASH_SOURCE_BUG]:
19934         Use readlinkat/readlink instead of fstatat/lstat to test merely
19935         whether a string names a symlink, as this avoids problems
19936         with EOVERFLOW.  Also, I hope it works around the MS-Windows
19937         issues that Bruno noted.
19938         * m4/fchmodat.m4 (gl_PREREQ_FCHMODAT):
19939         Check for readlinkat, not lchmod.
19940         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Do not require AC_CANONICAL_HOST
19941         or check for lstat.
19942         (gl_PREREQ_LCHMOD): Check for readlink.
19943         * modules/lchown (Depends-on): Add readlink.  Do not depend on
19944         lstat merely because !HAVE_LCHOWN.
19945         * modules/renameatu (Depends-on): Add fstatat, readlinkat.
19947 2022-06-12  Bruno Haible  <bruno@clisp.org>
19949         doc: Update O_PATH platforms list.
19950         * doc/posix-headers/fcntl.texi: Update O_PATH platforms list.
19952 2022-06-11  Paul Eggert  <eggert@cs.ucla.edu>
19954         fcntl: document O_PATH
19955         * doc/posix-headers/fcntl.texi: Mention O_PATH.
19957         fchmodat: port to old Linux kernel + newer headers
19958         Problem reported by Lance Fredrickson in:
19959         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00038.html
19960         * lib/fchmodat.c (fchmodat):
19961         * lib/lchmod.c (lchmod): Do not rely on AT_EMPTY_PATH as to
19962         whether syscalls work on ""; instead, if a call fails with
19963         ENOENT assume that those syscalls do not work.
19964         Do not use fstatat to determine whether a file is a symlink,
19965         as this has problems with EOVERFLOW.  Use readlinkat instead,
19966         and if it fails with EINVAL then the file is not a symlink.
19967         Remove #if tests on __linux__ || __ANDROID__ || __CYGWIN__
19968         as this has been a maintenance hassle and it’s unlikely
19969         these days that a new platform would #define O_PATH without also
19970         either supporting /proc or keeping it absent.
19971         * modules/fchmodat (Depends-on): Remove fstatat.
19972         There should be no need for either fchmodat or lchmod to depend on
19973         readlinkat, since they use readlinkat only in contexts where it
19974         should work without Gnulib intervention.
19976 2022-06-06  Bruno Haible  <bruno@clisp.org>
19978         fopen-gnu: Make this module work again (regression 2022-01-03).
19979         Reported by Nelson H. F. Beebe <beebe@math.utah.edu> in
19980         <https://lists.gnu.org/archive/html/platform-testers/2022-04/msg00005.html>.
19981         * modules/fopen-gnu (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
19983 2022-06-06  Bruno Haible  <bruno@clisp.org>
19985         getlogin, getlogin_r tests: Avoid test failure in specific environments.
19986         Reported by Letu Ren <fantasquex@gmail.com> in
19987         <https://lists.gnu.org/archive/html/bug-gnulib/2022-06/msg00001.html>.
19988         * modules/getlogin-tests (Depends-on): Add stdbool.
19989         * modules/getlogin_r-tests (Depends-on): Likewise.
19990         * tests/test-getlogin.h: Include stdbool.h.
19991         (test_getlogin_result): On Linux, skip the test if /proc/self/loginuid
19992         contains "-1".
19994 2022-06-05  Bruno Haible  <bruno@clisp.org>
19996         doc: Add section to attract more people towards the GNU project.
19997         Inspired by a suggestion from José E. Marchesi <jemarch@gnu.org> on
19998         the gnu-prog-discuss mailing list.
19999         * doc/join-gnu.texi: New file.
20000         * doc/gnulib-readme.texi: Include it.
20002 2022-06-05  Bruno Haible  <bruno@clisp.org>
20004         doc: Fix warnings about regex chapter structure (regression 2022-05-15).
20005         * doc/regex.texi (GNU Operators): Fix menu.
20007 2022-06-04  Paul Eggert  <eggert@cs.ucla.edu>
20009         regex-quote: \} -> } in EREs
20010         * lib/regex-quote.c (ere_special): Don’t use \} in EREs,
20011         as POSIX says the interpretation is undefined.
20012         * tests/test-regex-quote.c (test_bre, test_ere):
20013         Add tests for }.
20015         dfa: do not warn about \] and \}
20016         * lib/dfa.c (lex): Do not warn about \] and \}, since they’re
20017         surely universally supported even though POSIX says their
20018         interpretation is undefined.
20020 2022-06-03  Paul Eggert  <eggert@cs.ucla.edu>
20022         regex-quote: \] -> ] in EREs and BREs
20023         * build-aux/bootstrap:
20024         * build-aux/bootstrap.conf (gettext_external):
20025         * check-AC_LIBOBJ:
20026         * lib/regex-quote.c (bre_special, ere_special):
20027         * gnulib-tool (func_modules_transitive_closure)
20028         (func_emit_autoconf_snippet, func_import, func_create_testdir):
20029         * tests/test-regex-quote.c (test_bre, test_ere):
20030         * top/maint.mk (longopt_re, gpg_key_ID):
20031         Don’t use \] in BREs and EREs, as POSIX says the interpretation is
20032         undefined.
20034         filevercmp: don’t treat entire filename as suffix
20035         Problem reported by Artém S. Tashkinóv in:
20036         https://lists.gnu.org/r/bug-gnulib/2022-06/msg00012.html
20037         * lib/filevercmp.c (file_prefixlen): When stripping
20038         (\.[A-Za-z~][A-Za-z0-9~]*)*$ suffixes, do not strip
20039         the entire file name.
20040         * tests/test-filevercmp.c (examples): Adjust to match new behavior.
20042 2022-06-03  Bruno Haible  <bruno@clisp.org>
20044         setlocale: Update after Turkey changed its name.
20045         * lib/setlocale.c: Update comments.
20047 2022-05-25  Karl Berry  <karl@freefriends.org>
20049         doc: regex.texi deleted the node GNU Emacs Operators
20050         * doc/gnulib.texi (Regular expression): remove "GNU Emacs Operators"
20051         from the @menu, since the node no longer exists in regex.texi.
20053 2022-05-24  Paul Eggert  <eggert@cs.ucla.edu>
20055         dfa: new options DFA_STAR_WARN, DFA_PLUS_WARN
20056         This lets ‘grep -E '(*a|+b)'’ warn about the * and the +.
20057         * lib/dfa.h (DFA_STAR_WARN, DFA_PLUS_WARN): New flags.
20058         * lib/dfa.c (lex): Support them.
20060 2022-05-23  Paul Eggert  <eggert@cs.ucla.edu>
20062         dfa: '\n' is not governed by RE_LIMITED_OPS
20063         * lib/dfa.c (lex): Pay no attention to RE_LIMITED_OPS when
20064         deciding how to parse '\n', since regcomp.c doesn’t.
20066         dfa: new option DFA_STRAY_BACKSLASH_WARN
20067         This is for grep, which wants to warn about stray backslashes that
20068         lead to unspecified behavior.  For example, "grep -oi '\a'"
20069         surprisingly is not equivalent to "grep -oi 'a'", so the stray
20070         backslash should be warned about.
20071         * lib/dfa.c: Include wctype.h, for iswprint and iswspace.
20072         (lex): Add support for DFA_STRAY_BACKSLASH_WARN.
20073         * lib/dfa.h (DFA_STRAY_BACKSLASH_WARN): New constant.
20075         dfa: new option DFA_CONFUSING_BRACKETS_ERROR
20076         This is for grep, which wants [:alpha:] to be an error
20077         at the top level.
20078         * lib/dfa.c (struct regex_syntax): New member dfaopts,
20079         replacing anchor.  All uses changed.
20080         (parse_bracket_exp): Error, not warn, if DFA_CONFUSING_BRACKETS_ERROR.
20081         * lib/dfa.h (DFA_CONFUSING_BRACKETS_ERROR): New constant.
20083 2022-05-21  Paul Eggert  <eggert@cs.ucla.edu>
20085         strstr-simple: pacify GCC 12.1
20086         * lib/str-two-way.h (two_way_long_needle): Pacify GCC 12.1
20087         -Wsuggest-attribute=pure (x86-64, -O2).
20089 2022-05-20  Paul Eggert  <eggert@cs.ucla.edu>
20091         dfa: steer cleer of POSIX-reserved symbols
20092         * lib/dfa.c (str_eq): Rename from streq.  All uses changed.
20093         (c_isdigit): Rename from isasciidigit.  The function worked in
20094         EBCDIC so it wasn’t ASCII-specific anyway.  All uses changed.
20096 2022-05-17  Paul Eggert  <eggert@cs.ucla.edu>
20098         parse-datetime: support 'J' military time zone
20099         Requested by Brian Inglis in:
20100         https://savannah.gnu.org/support/?110644
20101         * lib/parse-datetime.y (parser_control): New member J_zones_seen.
20102         (item): New item 'J'.
20103         (military_table): Add 'J'.
20104         (parse_datetime_body): Set and use J_zones_seen.
20105         * tests/test-parse-datetime.c (main): Test "J".
20107 2022-05-15  Reuben Thomas  <rrt@sc3d.org>
20109         doc: Update regex documentation to match implementation.
20110         * doc/regex.texi: remove Emacs-specific documentation; match code.
20111         Remove mention of both Emacs and non-Emacs syntax tables, as these
20112         are no longer supported by the code.  Document the word character
20113         class (alnum + _).  Add documentation for \s and \S.  Replace
20114         mentions of #defining emacs with RE_NO_GNU_OPS (which takes effect
20115         in the opposite sense); merge the node “GNU Emacs Operators” into
20116         “GNU Operators”.  For \` and \', refer to the “whole string” rather
20117         than the (Emacs) “buffer”.
20119 2022-05-15  Bruno Haible  <bruno@clisp.org>
20121         string, wchar: Fix compilation error on MSVC (regression 2021-09-07).
20122         * lib/string.in.h (free): For MSVC, add the dllimport specification if
20123         the MSVC headers have it.
20124         * lib/wchar.in.h (free): Likewise.
20126 2022-05-14  Bruno Haible  <bruno@clisp.org>
20128         glob tests: Fix a warning (regression from 2022-03-23).
20129         * tests/test-glob.c: Include <fcntl.h>.
20130         * modules/glob-tests (Depends-on): Add fcntl-h.
20132 2022-05-14  Bruno Haible  <bruno@clisp.org>
20134         termcap: Fix link error when no suitable library is found.
20135         * m4/termcap.m4 (gl_TERMCAP_BODY): If no suitable library is found,
20136         set LIBTERMCAP and LTLIBTERMCAP to empty.
20138 2022-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20140         dfa: fix bug with ‘.’ and UTF-8 Hangul Syllables
20141         This fixes a bug introduced in 2019-12-18T05:41:27Z!eggert@cs.ucla.edu,
20142         an earlier patch that fixed dfa.c to not match invalid UTF-8.
20143         Unfortunately that patch had a couple of typos when dfa.c is
20144         matching against the regular expression ‘.’ (dot).  One typo
20145         caused dfa.c to incorrectly reject the valid UTF-8 sequences
20146         (ED)(90-9F)(80-BF) corresponding to U+D400 through U+D7FF, which
20147         are some Hangul Syllables and Hangul Jamo Extended-B.  The other
20148         typo caused dfa.c to incorrectly reject the valid sequences
20149         (F4)(88-8F)(80-BF)(80-BF) which correspond to U+108000 through
20150         U+10FFFF (Supplemental Private Use Area plane B).
20151         * lib/dfa.c (utf8_classes): Fix typos.
20152         * tests/test-dfa-match.sh: Test the fix.
20154 2022-05-12  Paul Eggert  <eggert@cs.ucla.edu>
20156         manywarnings: update C warnings for GCC 12
20157         Adjust for C programs compiled by GCC 12.
20158         (A C++ expert still needs to look at manywarnings-c++.m4.)
20159         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 12.
20160         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wbidi-chars=any,ucn
20161         and -Wuse-after-free=3.  Although not enabled by -Wall or -Wextra
20162         they seem suitable for Gnulib-using C code.
20164 2022-05-11  Paul Eggert  <eggert@cs.ucla.edu>
20166         parse-datetime: remove Emacs cruft
20167         * lib/parse-datetime.y: Remove an ‘ifdef emacs’.  Emacs has never
20168         used this module.  The module is derived from code taken from
20169         Emacs, but that code was removed from Emacs in the 1990s.
20171 2022-05-11  Bruno Haible  <bruno@clisp.org>
20173         alloca: Remove old code for Emacs, unused since 2009.
20174         Reported by Reuben Thomas <rrt@sc3d.org> in
20175         <https://lists.gnu.org/archive/html/bug-gnulib/2022-05/msg00032.html>.
20176         * lib/alloca.c: Remove Emacs specific code.
20178 2022-05-05  Paul Eggert  <eggert@cs.ucla.edu>
20180         libc-config: update to match cdefs
20181         * lib/libc-config.h (__attribute_alloc_align__)
20182         (__attribute_maybe_unused, __fortified_attr_access)
20183         (__glibc_fortify, __glibc_fortify_n, __glibc_likely)
20184         (__glibc_safe_len_cond, __glibc_safe_or_unknown_len)
20185         (__glibc_unsafe_len, __glibc_unsigned_or_positive, __wur):
20186         Undef these too, since lib/cdefs.h now defines them
20187         unconditionally.
20189         cdefs: merge from glibc
20190         * lib/cdefs.h (__glibc_safe_or_unknown_len):
20191         Use glibc’s newer version.
20193 2022-05-02  Paul Eggert  <eggert@cs.ucla.edu>
20195         gettime-res: help the compiler
20196         * lib/gettime-res.c (gettime_res): Pacify GCC versions that
20197         incorrectly complain about earlier.tv_sec not being initialized.
20198         Let GCC know that gcd args are always positive.
20200         af_alg: port to Ubuntu 22.04
20201         Without this patch, maintainer builds of coreutils fail on Ubuntu
20202         22.04 with diagnostics like "./lib/gl_openssl.h:79:1: error:
20203         'MD5_Init' is deprecated: Since OpenSSL 3.0
20204         [-Werror=deprecated-declarations]".  From
20205         <https://wiki.openssl.org/index.php/OpenSSL_1.1.0_Changes>
20206         it appears that Gnulib needs to either define OPENSSL_API_COMPAT
20207         to a version less than 3.0, or use a compatibility layer, or
20208         assume OpenSSL 1.1.0 or later.  The simplest workaround is to
20209         define OPENSSL_API_COMPAT for 1.1.1, the oldest OpenSSL release
20210         still supported.  A better fix would be to rewrite the code to
20211         assume OpenSSL 1.1.1 or later, and stop using the older API.
20212         * lib/md5.h, lib/sha1.h, lib/sha256.h, lib/sha512.h, lib/sm3.h:
20213         Define OPENSSL_API_COMPAT to 0x10101000L to suppress
20214         the deprecation warnings on Ubuntu 22.04.
20216 2022-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20218         vasnprintf: Simplify. Reduce binary code size.
20219         * lib/vasnprintf.c (VASNPRINTF): Coalesce cleanup code.
20221         vasnprintf: Simplify 'result' variable.
20222         * lib/vasnprintf.c (VASNPRINTF): Simplify initialization and test of
20223         'result' variable.
20225         vasnprintf: Simplify a free() call.
20226         * lib/vasnprintf.c (divide): Just call
20227         free (x) instead of doing ‘if (x != NULL) free (x);’.
20229 2022-04-30  Bruno Haible  <bruno@clisp.org>
20231         string: Avoid syntax error on glibc systems with GCC 11.
20232         Reported by Tom Tromey <tromey@adacore.com> in
20233         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00075.html>
20234         and by Satadru Pramanik <satadru@umich.edu> in
20235         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00076.html>.
20236         * lib/string.in.h (strndup): Don't rededeclare strndup if it is defined
20237         as a macro.
20239 2022-04-28  Simon Marchi  <simon.marchi@efficios.com>  (tiny change)
20241         stdlib: Fix error in C++ mode on glibc systems (regr. 2022-04-13).
20242         * lib/stdlib.in.h (free): Add exception specification like glibc does.
20244 2022-04-28  Paul Eggert  <eggert@cs.ucla.edu>
20246         glob: improve config and test cleanup
20247         Config problem reported by Benno Schulenberg in:
20248         https://lists.gnu.org/r/bug-gnulib/2022-04/msg00071.html
20249         * m4/glob.m4 (gl_GLOB): Clean up temporary file.
20250         Also, name it conf$$-file not conf-file, so it’s cleaned
20251         up on interrupt.
20252         * modules/glob-tests (MOSTLYCLEANFILES):
20253         Append test-glob.tglobfile, test-glob.tgloblink[123].
20255 2022-04-26  Paul Eggert  <eggert@cs.ucla.edu>
20257         glob: port to NetBSD 9.2
20258         Problem reported by Benno Schulenberg in:
20259         https://lists.gnu.org/r/bug-gnulib/2022-04/msg00052.html
20260         * doc/posix-functions/dirfd.texi: Document NetBSD 9.2 portability
20261         bugs.  Remove an old comment about errno that is no longer true
20262         of POSIX 2018.
20263         * lib/glob.c (glob_in_dir): Convert dirfd arg from void *
20264         to DIR * before passing it to dirfd.
20266 2022-04-21  Paul Eggert  <eggert@cs.ucla.edu>
20268         regex: match [...---...] like V7 grep
20269         Problem reported by Arnold Robbins in:
20270         https://bugs.gnu.org/20657
20271         https://lists.gnu.org/r/bug-gnulib/2022-04/msg00053.html
20272         * lib/regcomp.c (peek_token_bracket): Let [...---...] match '-'.
20273         This is an extension to POSIX, and matches V7 Unix grep.
20275 2022-04-20  Paul Eggert  <eggert@cs.ucla.edu>
20277         backupfile: fix bug when renaming simple backups
20278         * lib/backupfile.c (backupfile_internal): Fix bug when RENAME
20279         and when doing simple backups.  Problem reported by Steve Ward in:
20280         https://bugs.gnu.org/55029
20282         gettime-res: more-robust sampling
20283         * lib/gettime-res.c (gettime_res): If adjacent timestamps are
20284         identical search for a differing timestamp.  Also, stop collecting
20285         samples thereafter since they surely won’t help.
20287 2022-04-19  Paul Eggert  <eggert@cs.ucla.edu>
20289         Port _GL_HAS_C_ATTRIBUTE to pedantic gcc -std=c99
20290         * m4/gnulib-common.m4 (_GL_HAS_C_ATTRIBUTE):
20291         Disable -Wpedantic if using __has_c_attribute and this is not C2x.
20293         verify: port to pedantic gcc -std=c99
20294         * lib/verify.h (_GL_VERIFY): If we lack both _Static_assert and
20295         static_assert, suppress -Wnexted-externs.
20297         gettime-res: add tests
20298         * modules/gettime-res-tests, tests/test-gettime-res.c: New files.
20300 2022-04-16  Paul Eggert  <eggert@cs.ucla.edu>
20302         verify: port to Mac OS 10.7.5
20303         Mac OS 10.7.5 clang sets __clang_major__ to 4 even though it was
20304         derived from Clang 3.2.  Problem reported by Werner Lemberg in:
20305         https://lists.gnu.org/r/emacs-devel/2022-04/msg00779.html
20306         * lib/verify.h (_GL_HAVE__STATIC_ASSERT): Don’t define to 1
20307         when __clang_major__ == 4 && !__cplusplus
20308         && __STDC_VERSION__ < 201112L && !defined __STRICT_ANSI__.
20310 2022-04-15  Bruno Haible  <bruno@clisp.org>
20312         sigsegv: Fix compilation error on arceb CPUs.
20313         Reported by Fabrice Fontaine <fontaine.fabrice@gmail.com> in
20314         <https://lists.gnu.org/archive/html/bug-gnulib/2022-04/msg00028.html>.
20315         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Treat the 'arc' variants
20316         like 'arc'.
20318 2022-04-13  Bruno Haible  <bruno@clisp.org>
20320         string, wchar: Fix error in C++ mode on glibc systems with clang.
20321         * lib/string.in.h (free): Add exception specification like glibc does.
20322         * lib/wchar.in.h (free): Likewise.
20324 2022-04-13  Bruno Haible  <bruno@clisp.org>
20326         string: Fix errors in C++ mode on glibc systems with clang.
20327         * lib/string.in.h (memchr, memrchr, rawmemchr, strchrnul, strpbrk,
20328         strstr, strcasestr): Use _GL_CXXALIASWARN1 also with clang, and add
20329         exception specification.
20331 2022-04-13  Bruno Haible  <bruno@clisp.org>
20333         math: Fix errors in C++ mode on glibc systems with clang.
20334         * lib/math.in.h (GNULIB_NAMESPACE_LACKS_ISFINITE,
20335         GNULIB_NAMESPACE_LACKS_ISINF, GNULIB_NAMESPACE_LACKS_ISNAN,
20336         GNULIB_NAMESPACE_LACKS_SIGNBIT): New macros.
20337         * tests/test-math-c++.cc (isfinite): Skip test if
20338         GNULIB_NAMESPACE_LACKS_ISFINITE is 1.
20339         (isinf): Skip test if GNULIB_NAMESPACE_LACKS_ISINF is 1.
20340         (isnan): Skip test if GNULIB_NAMESPACE_LACKS_ISNAN is 1.
20341         (signbit): Skip test if GNULIB_NAMESPACE_LACKS_SIGNBIT is 1.
20343 2022-04-08  Paul Eggert  <eggert@cs.ucla.edu>
20345         libgmp: pacify Clang too
20346         * lib/mini-gmp-gnulib.c [NDEBUG]: Also use -Wunused-variable if clang.
20347         Problem reported for Emacs by Mattias Engdegård.
20349 2022-04-04  Paul Eggert  <eggert@cs.ucla.edu>
20351         init.sh: don’t assume gzip
20352         * tests/init.sh (rand_bytes_): Don’t assume gzip is installed.
20353         I found this while testing gzip installation on a platform where I
20354         had removed the installed gzip.  gzip is executed only on
20355         platforms lacking mktemp and /dev/urandom so this code is rarely
20356         used; however, these platforms might also lack gzip since gzip
20357         is neither specified by POSIX or required by the GNU Coding Standards.
20359 2022-03-30  Paul Eggert  <eggert@cs.ucla.edu>
20361         glob: sync better with glibc
20362         * lib/glob.c (dirfd) [_LIBC]: Use #undef instead of #ifdef.
20363         Problem reported by DJ Delorie.
20365 2022-03-23  Paul Eggert  <eggert@cs.ucla.edu>
20367         glob: test for glibc bug 25659
20368         https://sourceware.org/bugzilla/show_bug.cgi?id=25659
20369         * m4/glob.m4 (gl_GLOB): Replace glob if it has bug 25659.
20370         * tests/test-glob.c (main): Test for glibc bug 25659.
20372         glob: fix symlink and // issues; improve speed
20373         * lib/glob.c: Include fcntl.h.
20374         (dirfd) [_LIBC]: New macro.
20375         (GLOB_STAT64, GLOB_LSTAT64): Remove.  Replace all uses with ...
20376         (GLOB_FSTATAT64): ... this new macro.
20377         (glob_in_dir): Treat DT_LNK like DT_UNKNOWN.
20378         Use directory-relative fstatat unless GLOB_ALTDIRFUNC, or dirfd fails.
20379         Avoid duplicate strlen (directory).
20380         Work even if directory is "/", without turning it into "//".
20381         Use a scratch buffer instead of by-hand alloca stuff.
20382         Use mempcpy and memcpy instead of stpcpy and strcpy.
20383         * modules/glob (Depends-on): Add dirfd, fstatat.  Remove stat.
20384         (License): Change from LGPLv2+ to GPL, since it depends on
20385         fstatat.
20387 2022-03-23  DJ Delorie  <dj@redhat.com>
20389         glob: resolve DT_UNKNOWN via is_dir
20391         The DT_* values returned by getdents (readdir) are only hints and
20392         not required.  In fact, some Linux filesystems return DT_UNKNOWN
20393         for most entries, regardless of actual type.  This causes make
20394         to mis-match patterns with a trailing slash (via GLOB_ONLYDIR)
20395         (see make's functions/wildcard test case).  Thus, this patch
20396         detects that case and uses is_dir() to make the type known enough
20397         for proper operation.
20399         Performance in non-DT_UNKNOWN cases is not affected.
20401         The lack of DT_* is a well known issue on older XFS installations
20402         (for example, RHEL 7 and 8, Fedora 28) but can be recreated by
20403         creating an XFS filesystem with flags that mimic older behavior:
20405         $ fallocate -l 10G /xfs.fs
20406         $ mkfs.xfs -n ftype=0 -m crc=0 -f /xfs.fs
20407         $ mkdir /xfs
20408         $ mount -o loop /xfs.fs /xfs
20410 2022-03-20  Jim Meyering  <meyering@fb.com>
20412         maint: bootstrap: split a too-long line
20413         * build-aux/bootstrap (git_modules_config): Split longer-than-80 line.
20415 2022-03-14  Simon Josefsson  <simon@josefsson.org>
20417         announce-gen: Modernize GnuPG key retrieval suggestions.  Based on
20418         patch by Darshit Shah in:
20419         https://lists.gnu.org/archive/html/bug-gnulib/2022-03/msg00022.html
20420         * build-aux/announce-gen (usage): Add --gpg-key-email and
20421         --gpg-keyring-url.
20422         (main): Support the new options.
20423         (main): Don't suggest 'gpg --keyserver' since the situation with
20424         public key servers is complicated and GnuPG version dependent.
20426         maintainer-makefile: Improve GnuPG announce-gen options.
20427         * top/maint.mk (gpg_key_emil): New variable.
20428         (gpg_keyring_url): New variable.
20429         (announcement): Pass them as --gpg-key-email and
20430         --gpg-keyring-url.
20432 2022-03-13  Ben Pfaff  <blp@cs.stanford.edu>
20434         Document Automake 1.14 requirement in NEWS, too, since it had been
20435         documented there before for the Automake 1.11 requirement.
20436         * NEWS: Mention the change.
20438 2022-03-13  Bruno Haible  <bruno@clisp.org>
20440         sigsegv: Add support for Linux/PowerPC (32-bit) with musl libc.
20441         Reported by Khem Raj <raj.khem@gmail.com> in
20442         <https://lists.gnu.org/archive/html/m4-patches/2022-03/msg00000.html>.
20443         * src/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): In the Linux/PowerPC
20444         32-bit case, handle musl libc differently.
20445         * modules/sigsegv (Files): Add m4/musl.m4.
20446         (configure.ac): Invoke gl_MUSL_LIBC.
20448 2022-03-11  Paul Eggert  <eggert@cs.ucla.edu>
20450         regex: fix double-free
20451         * lib/regex_internal.c (re_dfa_add_node): Don’t free storage
20452         twice if an allocation fails.
20454         regex: fix minor over-allocation
20455         * lib/regexec.c (push_fail_stack): Fix off-by-one error that
20456         over-allocated the stack.
20458         regex: fix free_fail_stack undefined behavior
20459         * lib/regexec.c (push_fail_stack): Don’t increment number of
20460         re_fail_stack_t entries until after successful allocation.  This
20461         prevents a crash if re_realloc or re_malloc fails here, and a
20462         later free_fail_stack examines regs or a later pop_fail_stack
20463         examines node.  Problem discovered by Coverity scan sent
20464         2022-03-11 11:03:52Z.
20466 2022-03-10  Paul Eggert  <eggert@cs.ucla.edu>
20468         fts: revert change to use AT_NO_AUTOMOUNT
20469         * NEWS: Don’t mention AT_NO_AUTOMOUNT.
20470         * lib/fts.c (fts_stat): Don’t use AT_NO_AUTOMOUNT, as
20471         it has no effect with fstatat.
20473 2022-03-09  Paul Eggert  <eggert@cs.ucla.edu>
20475         statat: now obsolete
20476         * lib/openat.h (statat, lstatat): Now deprecated.
20477         All uses removed, and replaced with fstatat.
20478         * modules/statat: Mark as obsolete, because it’s confusing:
20479         it’s not clear whether it should use AT_NO_AUTOMOUNT,
20480         which is implied by stat and by lstat, but not by fstatat.
20481         * tests/test-statat.c: Disable deprecated-declarations warnings.
20483         fts: be consistent about AT_NO_AUTOMOUNT
20484         * lib/fts.c (fts_stat): Use fstatat with AT_NO_AUTOMOUNT
20485         consistently, instead of sometimes using stat (which implies
20486         AT_NO_AUTOMOUNT) and sometimes using fstatat without AT_NO_AUTOMOUNT.
20487         Remove a goto while we’re at it.
20489 2022-03-07  Pádraig Brady  <P@draigBrady.com>
20491         fcntl-h: add AT_NO_AUTOMOUNT
20492         * lib/fcntl.in.h: Define AT_NO_AUTOMOUNT to 0 where not defined.
20493         This is available on Linux since 2.6.38.
20495 2022-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20497         Create lib/Makefile.am after gnulib-comp.m4
20498         * gnulib-tool (func_import): Create library makefile after
20499         creating gnulib-comp.m4.  With --gnu-make, the latter depends on
20500         the former.  See <https://bugs.gnu.org/32452#109>.
20502 2022-02-26  Paul Eggert  <eggert@cs.ucla.edu>
20504         gettime-res: fix unlikely overflow bug
20505         * lib/gettime-res.c (gettime_res): Fix bug when hz * tv_sec overflows.
20506         With 64-bit ‘long’ and nanosecond resolution the bug can occur
20507         starting in the year 2262, with probability about 2e-9.
20508         With 32-bit ‘long’ the bug can occur now, with same probability.
20509         The probability goes up on hosts with worse timestamp resolution.
20511         Document clang -fsanitize=undefined glitch
20512         * doc/gnulib-intro.texi (Unsupported Platforms):
20513         Document incompatibility of ‘clang -fsanitize=undefined’
20514         with Gnulib, and how to work around it by also using
20515         ‘-fno-sanitize=pointer-overflow’.
20517 2022-02-25  Darshit Shah  <darnir@gnu.org>
20519         modules/unicase/special-casing: Fix compilation error
20520         * modules/unicase/special-casing: Don't prepend $(AM_V_at) to the
20521         second part of a compound command.  It causes make to try and
20522         execute the command "@sed" which doesn't exist.
20524 2022-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20526         Port __has_attribute to Apple’s Clang renumbering
20527         Problem reported by Kirill A. Korinsky in:
20528         https://lists.gnu.org/r/bug-gnulib/2022-02/msg00034.html
20529         * config/srclist.txt: Comment out sys/cdefs.h for now.
20530         * lib/cdefs.h (__glibc_has_attribute):
20531         * m4/gnulib-common.m4 (gl_COMMON_BODY):
20532         Port to Apple’s renumbering of Clang versions.
20534         nanosleep: simplify by using pselect
20535         GNU Emacs avoids Gnulib’s ‘select’ module and uses only pselect,
20536         which it implements in a special way on MS-DOS.
20537         Unfortunately, though, nanosleep uses ‘select’;
20538         problem reported by Lars Ingebrigtsen (Bug#32452#74).
20539         As far as I can tell, Gnulib nanosleep's use of
20540         ‘select’ with signals is only for ancient platforms
20541         that Gnulib no longer cares about, so remove that use of ‘select’.
20542         I don’t know of any platforms that still need this fallback code,
20543         but just in case, fall back to pselect instead, while removing
20544         signal handling that it shouldn’t be needed nowadays.
20545         * lib/nanosleep.c: Do not include sig-handler.h, sys/time.h.
20546         (SIGCONT, suspended, sighandler, my_usleep): Remove.
20547         (nanosleep) [!HAVE_BUG_BIG_NANOSLEEP && !(_WIN32 && !__CYGWIN__)]:
20548         Just call pselect.
20549         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Do not check for sys/time.h
20550         or call gl_FUNC_SELECT.  Do not include sys/time.h or worry
20551         about LIBSOCKET.
20552         (gl_PREREQ_NANOSLEEP): Remove as it’s no longer needed.
20553         All uses removed.
20554         * modules/nanosleep (Depends-on): Add pselect.
20555         Remove select, sigaction, sys_time.
20557 2022-02-24  Paul Eggert  <eggert@cs.ucla.edu>
20559         userspec: warn about '.' separator
20560         Problem reported by Dan Jacobson (Bug#44770).
20561         * lib/userspec.c: Don’t include stdbool.h since it’s now in our API.
20562         (parse_user_spec_warn): New function, broken out of parse_user_spec
20563         and with a new PWARN arg.
20564         (parse_user_spec): Use it.
20565         * lib/userspec.h: Include stdbool.h and declare new function.
20566         * tests/test-userspec.c (struct test.in): Now a char array
20567         so that it can be modified.
20568         (T): Make the placeholder a valid test, as that simplifies
20569         the code.  Omit NULL placeholder at the end, likewise.
20570         (main): Set up T in the new way, and test that the "."  separator
20571         acts like the ":" separator except with a warning if it works.
20573         userspec: no need for static vars
20574         * lib/userspec.c (parse_with_separator): Simplify.
20576 2022-02-22  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
20578         doc: add two missing closing parentheses
20579         * doc/regex.texi (Syntax Bits): Add missing closing parenthesis.
20580         * doc/regex.texi (BSD Regular Expression Compiling): Likewise.
20582 2022-02-22  Simon Josefsson  <simon@josefsson.org>
20584         gnulib-tool: Bump automake dependency.
20585         * gnulib-tool (func_emit_lib_Makefile_am)
20586         (func_emit_tests_Makefile_am): Demand Automake ≥ 1.14, for
20587         %reldir%.
20589 2022-02-21  Paul Eggert  <eggert@cs.ucla.edu>
20591         close-stream: don't depend on fclose
20592         This reverts 2022-01-26T17:33:03Z!eggert@cs.ucla.edu.
20593         Depending on fclose broke Emacs, and since this dependency didn't
20594         help GNU m4 let's remove it for now.  Problem reported by
20595         Lars Ingebrigtsen <https://bugs.gnu.org/32452#47>.
20596         * modules/close-stream (Depends-on): Remove fclose.
20598 2022-02-20  Bruno Haible  <bruno@clisp.org>
20600         Document that Automake ≥ 1.14 is needed (regression 2021-12-15).
20601         Reported by Simon Josefsson and Mike Frysinger in
20602         <https://lists.gnu.org/archive/html/bug-gnulib/2022-02/msg00010.html>.
20603         * DEPENDENCIES (Automake): Require version 1.14 or newer.
20605 2022-02-19  Paul Eggert  <eggert@cs.ucla.edu>
20607         mktime: improve heuristic for ca-1986 Indiana DST
20608         Problem reported by Mark Krenz <https://bugs.gnu.org/48085>.
20609         * lib/mktime.c (__mktime_internal): Be more generous about
20610         accepting arguments with the wrong value of tm_isdst, by falling
20611         back to a one-hour DST difference if we find no nearby DST that is
20612         unusual.  This fixes a problem where "1986-04-28 00:00 EDT" was
20613         rejected when TZ="America/Indianapolis" because the nearest DST
20614         timestamp occurred in 1970, a temporal distance too great for the
20615         old heuristic.  This also also narrows the search a bit, which
20616         is a minor performance win.
20617         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS):
20618         Check for putenv failures and for Bug#48085.
20619         * tests/test-parse-datetime.c (main):
20620         Test for setenv failures and for Bug#48085.
20622 2022-02-12  Paul Eggert  <eggert@cs.ucla.edu>
20624         filevercmp: fix several unexpected results
20625         Problems reported by Michael Debertol in <https://bugs.gnu.org/49239>.
20626         While looking into this, I spotted some more areas where the
20627         code and documentation did not agree, or where the documentation
20628         was unclear.  The biggest change needed by coreutils is a new
20629         function filenvercmp that can compare byte strings containing NUL.
20630         * lib/filevercmp.c: Do not include sys/types.h, stdlib.h, string.h.
20631         Include idx.h, verify.h.
20632         (match_suffix): Remove, replacing all uses with calls to ...
20633         (file_prefixlen): ... this new function.  Simplify it by
20634         avoiding the need for a confusing READ_ALPHA state variable.
20635         Change its API to something more useful, with a *LEN arg.
20636         it with a new *LEN arg.
20637         (file_prefixlen, verrevcmp):
20638         Prefer idx_t to size_t where either will do.
20639         (order): Change args to S, POS, LEN instead of just S[POS].
20640         This lets us handle NUL bytes correctly.  Callers changed.
20641         Verify that ints are sufficiently wide for its API.
20642         (verrevcmp): Don't assume that S1[S1_LEN] is a non-digit,
20643         and likewise for S2[S2_LEN].  The byte might not be accessible
20644         if filenvercmp is being called.
20645         (filevercmp): Reimplement by calling filenvercmp.
20646         (filenvercmp): New function, rewritten without the assumption
20647         that the inputs are null-terminated.
20648         Remove "easy comparison to see if strings are identical", as the
20649         use of it later (a) was undocumented, and (b) caused sort -V to be
20650         unstable.  When both strings start with ".", do not skip past
20651         the "."s before looking for suffixes, as this disagreed
20652         with the documentation.
20653         * lib/filevercmp.h: Fix comments, which had many mistakes.
20654         (filenvercmp): New decl.
20655         * modules/filevercmp (Depends-on): Add idx, verify.  Remove string.
20656         * tests/test-filevercmp.c: Include string.h.
20657         (examples): Reorder examples ".0" and ".9" that matched the code
20658         but not the documentation.  The code has been fixed to match the
20659         documentation.  Add some examples involving \1 so that they
20660         can be tried with both \1 and \0.  Add some other examples
20661         taken from the bug report.
20662         (equals): New set of test cases.
20663         (sign, test_filevercmp): New functions.
20664         (main): Remove test case where the fixed filevercmp disagrees with
20665         strverscmp.  Use test_filevercmp instead of filevercmp, so that
20666         we also test filenvercmp.  Test the newly-introduced EQUALS cases.
20668 2022-02-09  Bruno Haible  <bruno@clisp.org>
20670         string: Fix "mismatched allocation function" warnings regarding strndup.
20671         * lib/string.in.h (strndup): Mark with _GL_ATTRIBUTE_MALLOC and
20672         _GL_ATTRIBUTE_DEALLOC_FREE. For GCC >= 11: Declare also when the
20673         platform already declares the function or when the module 'strndup' is
20674         not in use.
20676 2022-02-09  Bruno Haible  <bruno@clisp.org>
20678         unictype/category-byname: Fix test failure.
20679         * modules/unictype/category-byname (configure.ac): Bump required
20680         libunistring version.
20682 2022-02-06  Bruno Haible  <bruno@clisp.org>
20684         termcap, termcap-h: Deprecate.
20685         * modules/termcap (Status, Notice): Add deprecation.
20686         * modules/termcap-h (Status, Notice): Likewise.
20688 2022-02-05  Paul Eggert  <eggert@cs.ucla.edu>
20690         parse-datetime: allow calculations to yield -1
20691         Problem reported by Jeremy Cantrell <https://bugs.gnu.org/50115>.
20692         * lib/parse-datetime.y (parse_datetime_body): When calling mktime,
20693         use an unmodifed and negative tm_wday or tm_yday to detect an error,
20694         as a (time_t) -1 return value is valid on most hosts.
20695         * tests/test-parse-datetime.c (main): Add a test for the bug.
20697 2022-02-04  Paul Eggert  <eggert@cs.ucla.edu>
20699         userspec: help fix GNU ‘id’ incompatibility
20700         * lib/userspec.c (parse_with_separator):
20701         Don’t set *username to a numeric string that is not a user name,
20702         and similarly for *groupname.  Needed to fix Bug#53631.
20704 2022-01-30  Pádraig Brady  <P@draigBrady.com>
20706         argmatch: add variants that only match full argument
20707         * lib/argmatch.h (argmatch_exact, [X]ARGMATCH_EXACT): New interfaces
20708         that don't allow abbreviations.
20709         * lib/argmatch.c (argmatch_exact): Likewise.
20710         (__xargmatch_internal): Add a bool parameter to disable abbreviations.
20711         * tests/test-argmatch.c: Add tests.
20713 2022-01-30  Bruno Haible  <bruno@clisp.org>
20715         tests: Fix interpretation of setupterm's return code.
20716         * tests/test-terminfo.c (main): Test the value of err when setupterm
20717         fails, not when it succeeds.
20718         * tests/test-termcap.c (main): Likewise.
20720 2022-01-30  Bruno Haible  <bruno@clisp.org>
20722         terminfo: Add tests.
20723         * tests/test-terminfo.c: New file.
20724         * modules/terminfo-tests: New file.
20726         terminfo, terminfo-h: New modules.
20727         * lib/terminfo.h: New file, from GNU gettext.
20728         * m4/terminfo.m4: New file, from GNU gettext.
20729         * modules/terminfo: New file, from GNU gettext.
20730         * modules/terminfo-h: New file, from GNU gettext.
20732 2022-01-30  Bruno Haible  <bruno@clisp.org>
20734         termcap: Add tests.
20735         * tests/test-termcap.c: New file.
20736         * modules/termcap-tests: New file.
20738         termcap, termcap-h: New modules.
20739         * lib/termcap.h: New file, from GNU gettext.
20740         * lib/tparm.c: New file, from GNU gettext.
20741         * lib/tputs.c: New file, from GNU gettext.
20742         * m4/termcap.m4: New file, from GNU gettext.
20743         * m4/curses.m4: New file, from GNU gettext.
20744         * modules/termcap: New file, from GNU gettext.
20745         * modules/termcap-h: New file, from GNU gettext.
20747 2022-01-29  Bruno Haible  <bruno@clisp.org>
20749         doc: Clarify MSVC support.
20750         * doc/gnulib-intro.texi (Supported Platforms): Document that "debug"
20751         builds are unsupported.
20753 2022-01-28  Pádraig Brady  <P@draigBrady.com>
20755         maintainer-makefile: fix sc_error_message_uppercase false failure
20756         * top/maint.mk (sc_error_message_uppercase): Don't trigger for
20757         any of the PRI... defines.
20759 2022-01-27  Paul Eggert  <eggert@cs.ucla.edu>
20761         alignalloc: work around AddressSanitizer bug
20762         * doc/posix-functions/aligned_alloc.texi (aligned_alloc):
20763         Mention AddressSanitizer bug.
20764         * lib/alignalloc.h (ALIGNALLOC_VIA_ALIGNED_ALLOC):
20765         Define to 0 if AddressSanitizer is in use.
20766         * tests/test-alignalloc.c (test_alignalloc): New function,
20767         which tests for non-aligned sizes too.
20768         (main): Use it.  Don’t bother checking for alignments
20769         greater than 16 MiB, as this flummoxes AddressSanitizer
20770         and there seems little point to testing them.
20772         doc: use UTF-8 encoding
20773         * doc/gnulib.texi: Use ‘@documentencoding UTF-8’.
20774         Partly this is because there are a few UTF-8 characters
20775         in the .texi files and there seems little point nowadays
20776         to @U-ifiying them.  And partly it is so that the .info
20777         output uses nicer UTF-8 characters, e.g., it single-quotes
20778         ‘like this’ instead of 'like this'.
20780         maint: Update copyright notices
20781         * build-aux/announce-gen, build-aux/declared.sh:
20782         * build-aux/git-version-gen, build-aux/gitlog-to-changelog:
20783         * build-aux/gnu-web-doc-update, build-aux/gnupload:
20784         * build-aux/increment-serial, build-aux/libtool-next-version:
20785         * build-aux/useless-if-before-free:
20786         Update some copyright notices by hand, that were not
20787         updated automatically.
20789 2022-01-26  Paul Eggert  <eggert@cs.ucla.edu>
20791         calloc-gnu: fix misspelling in 2022-01-03 patch
20792         Problem reported by Thien-Thi Nguyen in:
20793         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00170.html
20794         * modules/calloc-gnu (Depends-on):
20795         * modules/calloc-posix (Depends-on):
20796         Fix misspelling of REPLACE_CALLOC_FOR_CALLOC_POSIX.
20798         close-stream: avoid crash on MSVC Debug mode
20799         Problem reported by Julien Marrec in:
20800         https://lists.gnu.org/r/bug-m4/2022-01/msg00000.html
20801         * modules/close-stream (Depends-on): Depend on fclose.
20803 2022-01-23  Paul Eggert  <eggert@cs.ucla.edu>
20805         xstrtoimax, xstrtoumax: depend on inttypes-incomplete
20806         This fixes a call to strtoimax without declaring it,
20807         and similarly for strtoumax.
20808         * lib/xstrtoimax.c, lib/xstrtoumax.c (XSTRTOL_INCLUDE_INTTYPES_H):
20809         Define, so that strtoimax and strtoumax are declared.
20810         * lib/xstrtol.c [XSTRTOL_INCLUDE_INTTYPES_H]: Include inttypes.h.
20811         * modules/xstrtoimax, modules/xstrtoumax (Depends-on):
20812         Add inttypes-incomplete.
20814         alignalloc, xalignalloc: new modules
20815         * lib/alignalloc.c, lib/alignalloc.h, lib/xalignalloc.c:
20816         * m4/alignalloc.m4, modules/alignalloc, modules/alignalloc-tests:
20817         * modules/xalignalloc, tests/test-alignalloc.c:
20818         New files.
20820 2022-01-17  Paul Eggert  <eggert@cs.ucla.edu>
20822         extern-inline: improve macOS port
20823         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
20824         Define HAVE___HEADER_INLINE at configure-time, so that config.h
20825         knows the workaround is not needed even though ctype.h has not yet
20826         been included.  This lets the compiler use extern inline functions
20827         on newer macOS platforms, instead of static inline.
20828         Problem reported by Reuben Thomas in:
20829         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00130.html
20831 2022-01-17  Bruno Haible  <bruno@clisp.org>
20833         xstrtol: Trim dependencies.
20834         * lib/xstrtol.h: Include <stdint.h>, not <inttypes.h>.
20835         * modules/xstrtol (Depends-on): Add stdint. Remove inttypes-incomplete.
20837 2022-01-17  Bruno Haible  <bruno@clisp.org>
20839         xstrtol: Fix compilation error (regression 2022-01-16).
20840         * modules/xstrtol (Depends-on): Add intprops.
20842 2022-01-17  Jim Meyering  <meyering@fb.com>
20844         xstrtol: remove unnecessary else after return
20845         * lib/xstrtol.c (bkm_scale): Drop "else" after return.
20847 2022-01-16  Paul Eggert  <eggert@cs.ucla.edu>
20849         xstrtol: simplify integer overflow checking
20850         * lib/xstrtol.c: Include intprops.h.
20851         (TYPE_SIGNED): Remove, as intprops.h defines that for us now.
20852         (bkm_scale): Use INT_MULTIPLY_WRAPV instead of checking for
20853         overflow by hand.
20855         xstrtoll-tests: use %lld for long long
20856         * tests/test-xstrtoll.c, tests/test-xstrtoull.c (__spec):
20857         Do not assume long long is 64 bits, or that exact-width
20858         64-bit types exist.  Although these assumptions are true
20859         on current Gnulib platforms they are not true in general.
20860         Also, GCC warns if PRId64 is "ld" but intmax_t is long long
20861         even when long and long long are both 64 bits.
20863 2022-01-15  Bruno Haible  <bruno@clisp.org>
20865         Don't pass unknown warning option to clang.
20866         Reported by Assaf Gordon via Paul Eggert in
20867         <https://lists.gnu.org/archive/html/coreutils/2022-01/msg00018.html>.
20868         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Don't use
20869         -Wno-unsuffixed-float-constants with clang.
20871 2022-01-15  Bruno Haible  <bruno@clisp.org>
20873         log tests: Avoid test failure with nvc 22.1.
20874         * tests/test-log.h (test_function): With nvc, expect up to 4 ulps error.
20876 2022-01-15  Bruno Haible  <bruno@clisp.org>
20878         havelib: Recognize ELF platform despite nvc 22.1.
20879         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Recognize Linux as an ELF
20880         platform, even with a compiler that does not define __ELF__.
20882 2022-01-15  Bruno Haible  <bruno@clisp.org>
20884         oset-c++: Avoid compilation error with nvc++ 22.1.
20885         * lib/gl_oset.hh: With EDG C++ compilers, avoid 'friend'.
20887 2022-01-14  Paul Eggert  <eggert@cs.ucla.edu>
20889         nstrftime: pacify nvc 22.1 unreachable statement
20890         * lib/nstrftime.c (__strftime_internal):
20891         Omit unreachable ‘break;’.
20893         tests: pacify nvc 22.1 unreachable statement
20894         * tests/test-sys_wait.h (test_sys_wait_macros):
20895         Widen scope of ‘#if 0’ so that there is not an unreachable ‘break;’.
20897         tests: pacify nvc 22.1 set-but-not-used
20898         * tests/test-fnmatch.c (main): Don’t set a var without using it.
20899         * tests/test-sched.c (f1): Now extern.
20901         intprops: work around nvc 22.1 bug
20902         Problem reported by Olivier Cessenat (Bug#53256).
20903         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW) [__EDG__]:
20904         Define to 0, since __builtin_add_overflow doesn’t work
20905         on NVIDIA HPC SDK 22.1.
20907         copy-file-range: work around Linux kernel bug
20908         This workaround is adapted from Coreutils.
20909         * lib/copy-file-range.c [__linux__ && HAVE_COPY_FILE_RANGE]:
20910         Include <sys/utsname.h>.
20911         (copy_file_range): Use a stub to replace the copy_file_range of
20912         Linux kernel versions 4.5 through 5.2.
20913         * lib/unistd.in.h (copy_file_range):
20914         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS):
20915         * modules/copy-file-range (configure.ac):
20916         * modules/unistd (unistd.h):
20917         Support replacement of copy_file_range.
20918         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE):
20919         Define HAVE_COPY_FILE_RANGE if the system has copy_file_range,
20920         and on Linux check whether the system’s is known to work.
20922 2022-01-14  Bruno Haible  <bruno@clisp.org>
20924         Avoid error "conditional LIBUNISTRING_COMPILE_... was never defined"
20925         when option --conditional-dependencies is used (regression 2022-01-09).
20926         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
20927         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00099.html>.
20928         * m4/libunistring-base.m4 (gl_LIBUNISTRING_MODULE): Use gl_CONDITIONAL
20929         instead of AM_CONDITIONAL.
20931 2022-01-13  Bruno Haible  <bruno@clisp.org>
20933         Avoid warning "_GL_ATTRIBUTE_DEALLOC_FREE redefined" (regr. 2022-01-04).
20934         Reported by Werner Lemberg <wl@gnu.org> in
20935         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00094.html>.
20936         * m4/gnulib-common.m4 (gl_COMMON_BODY): Avoid redefining
20937         _GL_ATTRIBUTE_DEALLOC_FREE.
20939 2022-01-10  Paul Eggert  <eggert@cs.ucla.edu>
20941         backupfile: fix bug when renaming not from wd
20942         * lib/backupfile.c (backupfile_internal): Fix bug when DIR_FD
20943         does not specify the working directory, and when RENAME.
20944         Without the bug fix, FILE is treated as relative to the working
20945         directory, not relative to DIR_FD, when renaming FILE.
20946         This bug was introduced when DIR_FD and RENAME were introduced,
20947         in 2018-10-24T02:10:21Z!eggert@cs.ucla.edu.
20948         While we’re at it, when SDIR is nonnegative improve performance a
20949         bit by passing an SDIR-relative old name to renameatu.
20951 2022-01-09  Bruno Haible  <bruno@clisp.org>
20953         host-cpu-c-abi: Add support for LoongArch64 CPU.
20954         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Define __loongarch64__. (GCC
20955         and clang predefine only __loongarch__, __loongarch64.)
20957 2022-01-09  Bruno Haible  <bruno@clisp.org>
20959         stdio: Fix "missing file" errors (regression from today).
20960         * modules/stdio (Files): Add stdio-read.c, stdio-write.c.
20961         * m4/stdio_h.m4 (gl_STDIO_H): Update comments.
20963 2022-01-09  Bruno Haible  <bruno@clisp.org>
20965         Use the GL_CFLAG_GNULIB_WARNINGS for most AC_LIBOBJ compilation units.
20966         * modules/_Exit (configure.ac): Define an Automake conditional. Remove
20967         the AC_LIBOBJ invocation.
20968         (Makefile.am): Augment lib_SOURCES, guarded by that Automake
20969         conditional.
20970         * modules/accept: Likewise.
20971         * modules/access: Likewise.
20972         * modules/acosf: Likewise.
20973         * modules/acosl: Likewise.
20974         * modules/aligned_alloc: Likewise.
20975         * modules/alphasort: Likewise.
20976         * modules/argz: Likewise.
20977         * modules/asinf: Likewise.
20978         * modules/asinl: Likewise.
20979         * modules/atan2f: Likewise.
20980         * modules/atanf: Likewise.
20981         * modules/atanl: Likewise.
20982         * modules/atexit: Likewise.
20983         * modules/atoll: Likewise.
20984         * modules/bind: Likewise.
20985         * modules/btowc: Likewise.
20986         * modules/c32rtomb: Likewise.
20987         * modules/canonicalize-lgpl: Likewise.
20988         * modules/cbrt: Likewise.
20989         * modules/cbrtf: Likewise.
20990         * modules/cbrtl: Likewise.
20991         * modules/ceil: Likewise.
20992         * modules/ceilf: Likewise.
20993         * modules/ceill: Likewise.
20994         * modules/chdir-long: Likewise.
20995         * modules/chown: Likewise.
20996         * modules/close: Likewise.
20997         * modules/closedir: Likewise.
20998         * modules/cnd: Likewise.
20999         * modules/connect: Likewise.
21000         * modules/copy-file-range: Likewise.
21001         * modules/copysign: Likewise.
21002         * modules/copysignf: Likewise.
21003         * modules/copysignl: Likewise.
21004         * modules/cosf: Likewise.
21005         * modules/coshf: Likewise.
21006         * modules/cosl: Likewise.
21007         * modules/creat: Likewise.
21008         * modules/crypto/gc: Likewise.
21009         * modules/ctime: Likewise.
21010         * modules/dirfd: Likewise.
21011         * modules/dup: Likewise.
21012         * modules/dup2: Likewise.
21013         * modules/duplocale: Likewise.
21014         * modules/error: Likewise.
21015         * modules/euidaccess: Likewise.
21016         * modules/execinfo: Likewise.
21017         * modules/execl: Likewise.
21018         * modules/execle: Likewise.
21019         * modules/execlp: Likewise.
21020         * modules/execv: Likewise.
21021         * modules/execve: Likewise.
21022         * modules/execvp: Likewise.
21023         * modules/execvpe: Likewise.
21024         * modules/exp2: Likewise.
21025         * modules/exp2f: Likewise.
21026         * modules/exp2l: Likewise.
21027         * modules/expf: Likewise.
21028         * modules/expl: Likewise.
21029         * modules/explicit_bzero: Likewise.
21030         * modules/expm1: Likewise.
21031         * modules/expm1f: Likewise.
21032         * modules/expm1l: Likewise.
21033         * modules/fabsf: Likewise.
21034         * modules/fabsl: Likewise.
21035         * modules/faccessat: Likewise.
21036         * modules/fchdir: Likewise.
21037         * modules/fchmodat: Likewise.
21038         * modules/fchownat: Likewise.
21039         * modules/fclose: Likewise.
21040         * modules/fcntl: Likewise.
21041         * modules/fdatasync: Likewise.
21042         * modules/fdopen: Likewise.
21043         * modules/fdopendir: Likewise.
21044         * modules/fflush: Likewise.
21045         * modules/ffs: Likewise.
21046         * modules/ffsl: Likewise.
21047         * modules/ffsll: Likewise.
21048         * modules/fileblocks: Likewise.
21049         * modules/float: Likewise.
21050         * modules/flock: Likewise.
21051         * modules/floor: Likewise.
21052         * modules/floorf: Likewise.
21053         * modules/floorl: Likewise.
21054         * modules/fma: Likewise.
21055         * modules/fmaf: Likewise.
21056         * modules/fmal: Likewise.
21057         * modules/fmod: Likewise.
21058         * modules/fmodf: Likewise.
21059         * modules/fmodl: Likewise.
21060         * modules/forkpty: Likewise.
21061         * modules/fpending: Likewise.
21062         * modules/fpurge: Likewise.
21063         * modules/freadable: Likewise.
21064         * modules/freadahead: Likewise.
21065         * modules/freadptr: Likewise.
21066         * modules/free-posix: Likewise.
21067         * modules/freopen: Likewise.
21068         * modules/frexpf: Likewise.
21069         * modules/fseek: Likewise.
21070         * modules/fseeko: Likewise.
21071         * modules/fseterr: Likewise.
21072         * modules/fstat: Likewise.
21073         * modules/fstatat: Likewise.
21074         * modules/fsusage: Likewise.
21075         * modules/fsync: Likewise.
21076         * modules/ftell: Likewise.
21077         * modules/ftello: Likewise.
21078         * modules/ftruncate: Likewise.
21079         * modules/fts: Likewise.
21080         * modules/futimens: Likewise.
21081         * modules/fwritable: Likewise.
21082         * modules/fwriting: Likewise.
21083         * modules/getaddrinfo: Likewise.
21084         * modules/getcwd: Likewise.
21085         * modules/getcwd-lgpl: Likewise.
21086         * modules/getdelim: Likewise.
21087         * modules/getdomainname: Likewise.
21088         * modules/getdtablesize: Likewise.
21089         * modules/getentropy: Likewise.
21090         * modules/getgroups: Likewise.
21091         * modules/gethostname: Likewise.
21092         * modules/getline: Likewise.
21093         * modules/getloadavg: Likewise.
21094         * modules/getlogin: Likewise.
21095         * modules/getlogin_r: Likewise.
21096         * modules/getopt-posix: Likewise.
21097         * modules/getpagesize: Likewise.
21098         * modules/getpeername: Likewise.
21099         * modules/getrandom: Likewise.
21100         * modules/getrusage: Likewise.
21101         * modules/getsockname: Likewise.
21102         * modules/getsockopt: Likewise.
21103         * modules/getsubopt: Likewise.
21104         * modules/gettimeofday: Likewise.
21105         * modules/getumask: Likewise.
21106         * modules/getusershell: Likewise.
21107         * modules/glob: Likewise.
21108         * modules/grantpt: Likewise.
21109         * modules/group-member: Likewise.
21110         * modules/hypot: Likewise.
21111         * modules/hypotf: Likewise.
21112         * modules/hypotl: Likewise.
21113         * modules/iconv_open: Likewise.
21114         * modules/ilogb: Likewise.
21115         * modules/ilogbf: Likewise.
21116         * modules/ilogbl: Likewise.
21117         * modules/imaxabs: Likewise.
21118         * modules/imaxdiv: Likewise.
21119         * modules/inet_ntop: Likewise.
21120         * modules/inet_pton: Likewise.
21121         * modules/ioctl: Likewise.
21122         * modules/isapipe: Likewise.
21123         * modules/isatty: Likewise.
21124         * modules/isblank: Likewise.
21125         * modules/isfinite: Likewise.
21126         * modules/isinf: Likewise.
21127         * modules/iswblank: Likewise.
21128         * modules/iswctype: Likewise.
21129         * modules/iswdigit: Likewise.
21130         * modules/iswxdigit: Likewise.
21131         * modules/lchmod: Likewise.
21132         * modules/lchown: Likewise.
21133         * modules/ldexpf: Likewise.
21134         * modules/ldexpl: Likewise.
21135         * modules/libgmp: Likewise.
21136         * modules/link: Likewise.
21137         * modules/linkat: Likewise.
21138         * modules/listen: Likewise.
21139         * modules/localeconv: Likewise.
21140         * modules/localtime: Likewise.
21141         * modules/log: Likewise.
21142         * modules/log10: Likewise.
21143         * modules/log10f: Likewise.
21144         * modules/log10l: Likewise.
21145         * modules/log1p: Likewise.
21146         * modules/log1pf: Likewise.
21147         * modules/log1pl: Likewise.
21148         * modules/log2: Likewise.
21149         * modules/log2f: Likewise.
21150         * modules/log2l: Likewise.
21151         * modules/logb: Likewise.
21152         * modules/logbf: Likewise.
21153         * modules/logbl: Likewise.
21154         * modules/logf: Likewise.
21155         * modules/login_tty: Likewise.
21156         * modules/logl: Likewise.
21157         * modules/lseek: Likewise.
21158         * modules/lstat: Likewise.
21159         * modules/mbrlen: Likewise.
21160         * modules/mbrtoc32: Likewise.
21161         * modules/mbrtowc: Likewise.
21162         * modules/mbsinit: Likewise.
21163         * modules/mbsnrtowcs: Likewise.
21164         * modules/mbsrtowcs: Likewise.
21165         * modules/mbtowc: Likewise.
21166         * modules/memalign: Likewise.
21167         * modules/memchr: Likewise.
21168         * modules/memcmp: Likewise.
21169         * modules/memcpy: Likewise.
21170         * modules/memmove: Likewise.
21171         * modules/mempcpy: Likewise.
21172         * modules/memrchr: Likewise.
21173         * modules/memset: Likewise.
21174         * modules/mkdir: Likewise.
21175         * modules/mkdirat: Likewise.
21176         * modules/mkdtemp: Likewise.
21177         * modules/mkfifo: Likewise.
21178         * modules/mkfifoat: Likewise.
21179         * modules/mknod: Likewise.
21180         * modules/mkostemp: Likewise.
21181         * modules/mkostemps: Likewise.
21182         * modules/mkstemp: Likewise.
21183         * modules/mkstemps: Likewise.
21184         * modules/modf: Likewise.
21185         * modules/modff: Likewise.
21186         * modules/modfl: Likewise.
21187         * modules/mountlist: Likewise.
21188         * modules/msvc-inval: Likewise.
21189         * modules/msvc-nothrow: Likewise.
21190         * modules/mtx: Likewise.
21191         * modules/nanosleep: Likewise.
21192         * modules/nl_langinfo: Likewise.
21193         * modules/obstack: Likewise.
21194         * modules/open: Likewise.
21195         * modules/openat: Likewise.
21196         * modules/opendir: Likewise.
21197         * modules/openpty: Likewise.
21198         * modules/pclose: Likewise.
21199         * modules/perror: Likewise.
21200         * modules/pipe-posix: Likewise.
21201         * modules/poll: Likewise.
21202         * modules/popen: Likewise.
21203         * modules/posix_memalign: Likewise.
21204         * modules/posix_openpt: Likewise.
21205         * modules/posix_spawn: Likewise.
21206         * modules/posix_spawn-internal: Likewise.
21207         * modules/posix_spawn_file_actions_addchdir: Likewise.
21208         * modules/posix_spawn_file_actions_addclose: Likewise.
21209         * modules/posix_spawn_file_actions_adddup2: Likewise.
21210         * modules/posix_spawn_file_actions_addfchdir: Likewise.
21211         * modules/posix_spawn_file_actions_addopen: Likewise.
21212         * modules/posix_spawn_file_actions_destroy: Likewise.
21213         * modules/posix_spawn_file_actions_init: Likewise.
21214         * modules/posix_spawnattr_destroy: Likewise.
21215         * modules/posix_spawnattr_getflags: Likewise.
21216         * modules/posix_spawnattr_getpgroup: Likewise.
21217         * modules/posix_spawnattr_getschedparam: Likewise.
21218         * modules/posix_spawnattr_getschedpolicy: Likewise.
21219         * modules/posix_spawnattr_getsigdefault: Likewise.
21220         * modules/posix_spawnattr_getsigmask: Likewise.
21221         * modules/posix_spawnattr_init: Likewise.
21222         * modules/posix_spawnattr_setflags: Likewise.
21223         * modules/posix_spawnattr_setpgroup: Likewise.
21224         * modules/posix_spawnattr_setschedparam: Likewise.
21225         * modules/posix_spawnattr_setschedpolicy: Likewise.
21226         * modules/posix_spawnattr_setsigdefault: Likewise.
21227         * modules/posix_spawnattr_setsigmask: Likewise.
21228         * modules/posix_spawnp: Likewise.
21229         * modules/powf: Likewise.
21230         * modules/pread: Likewise.
21231         * modules/pselect: Likewise.
21232         * modules/pthread-cond: Likewise.
21233         * modules/pthread-mutex: Likewise.
21234         * modules/pthread-once: Likewise.
21235         * modules/pthread-rwlock: Likewise.
21236         * modules/pthread-spin: Likewise.
21237         * modules/pthread-thread: Likewise.
21238         * modules/pthread-tss: Likewise.
21239         * modules/pthread_mutex_timedlock: Likewise.
21240         * modules/pthread_sigmask: Likewise.
21241         * modules/ptsname: Likewise.
21242         * modules/ptsname_r: Likewise.
21243         * modules/putenv: Likewise.
21244         * modules/pwrite: Likewise.
21245         * modules/qsort_r: Likewise.
21246         * modules/raise: Likewise.
21247         * modules/random: Likewise.
21248         * modules/random_r: Likewise.
21249         * modules/rawmemchr: Likewise.
21250         * modules/read: Likewise.
21251         * modules/readdir: Likewise.
21252         * modules/readline: Likewise.
21253         * modules/readlink: Likewise.
21254         * modules/readlinkat: Likewise.
21255         * modules/readutmp: Likewise.
21256         * modules/reallocarray: Likewise.
21257         * modules/recv: Likewise.
21258         * modules/recvfrom: Likewise.
21259         * modules/regex: Likewise.
21260         * modules/relocatable-prog: Likewise.
21261         * modules/remainder: Likewise.
21262         * modules/remainderf: Likewise.
21263         * modules/remainderl: Likewise.
21264         * modules/remove: Likewise.
21265         * modules/rename: Likewise.
21266         * modules/renameat: Likewise.
21267         * modules/rewinddir: Likewise.
21268         * modules/rint: Likewise.
21269         * modules/rintf: Likewise.
21270         * modules/rintl: Likewise.
21271         * modules/rmdir: Likewise.
21272         * modules/round: Likewise.
21273         * modules/roundf: Likewise.
21274         * modules/roundl: Likewise.
21275         * modules/rpmatch: Likewise.
21276         * modules/scandir: Likewise.
21277         * modules/sched_yield: Likewise.
21278         * modules/secure_getenv: Likewise.
21279         * modules/select: Likewise.
21280         * modules/selinux-h: Likewise.
21281         * modules/send: Likewise.
21282         * modules/sendto: Likewise.
21283         * modules/setenv: Likewise.
21284         * modules/sethostname: Likewise.
21285         * modules/setlocale: Likewise.
21286         * modules/setlocale-null: Likewise.
21287         * modules/setsockopt: Likewise.
21288         * modules/shutdown: Likewise.
21289         * modules/sig2str: Likewise.
21290         * modules/sigabbrev_np: Likewise.
21291         * modules/sigaction: Likewise.
21292         * modules/sigdescr_np: Likewise.
21293         * modules/signbit: Likewise.
21294         * modules/sigprocmask: Likewise.
21295         * modules/sinf: Likewise.
21296         * modules/sinhf: Likewise.
21297         * modules/sinl: Likewise.
21298         * modules/sleep: Likewise.
21299         * modules/socket: Likewise.
21300         * modules/spawn-pipe: Likewise.
21301         * modules/sqrtf: Likewise.
21302         * modules/sqrtl: Likewise.
21303         * modules/stat: Likewise.
21304         * modules/stdio: Likewise.
21305         * modules/stpcpy: Likewise.
21306         * modules/stpncpy: Likewise.
21307         * modules/strcase: Likewise.
21308         * modules/strchrnul: Likewise.
21309         * modules/strcspn: Likewise.
21310         * modules/strdup-posix: Likewise.
21311         * modules/strerror: Likewise.
21312         * modules/strerror-override: Likewise.
21313         * modules/strerrorname_np: Likewise.
21314         * modules/strfmon_l: Likewise.
21315         * modules/strftime-fixes: Likewise.
21316         * modules/strncat: Likewise.
21317         * modules/strndup: Likewise.
21318         * modules/strnlen: Likewise.
21319         * modules/strpbrk: Likewise.
21320         * modules/strptime: Likewise.
21321         * modules/strsep: Likewise.
21322         * modules/strsignal: Likewise.
21323         * modules/strtod: Likewise.
21324         * modules/strtoimax: Likewise.
21325         * modules/strtok_r: Likewise.
21326         * modules/strtol: Likewise.
21327         * modules/strtold: Likewise.
21328         * modules/strtoll: Likewise.
21329         * modules/strtoul: Likewise.
21330         * modules/strtoull: Likewise.
21331         * modules/strtoumax: Likewise.
21332         * modules/strverscmp: Likewise.
21333         * modules/symlink: Likewise.
21334         * modules/symlinkat: Likewise.
21335         * modules/tanf: Likewise.
21336         * modules/tanhf: Likewise.
21337         * modules/tanl: Likewise.
21338         * modules/tcgetsid: Likewise.
21339         * modules/thrd: Likewise.
21340         * modules/time_r: Likewise.
21341         * modules/time_rz: Likewise.
21342         * modules/timegm: Likewise.
21343         * modules/times: Likewise.
21344         * modules/timespec_get: Likewise.
21345         * modules/timespec_getres: Likewise.
21346         * modules/tmpfile: Likewise.
21347         * modules/towctrans: Likewise.
21348         * modules/trunc: Likewise.
21349         * modules/truncate: Likewise.
21350         * modules/truncf: Likewise.
21351         * modules/truncl: Likewise.
21352         * modules/tsearch: Likewise.
21353         * modules/tss: Likewise.
21354         * modules/ttyname_r: Likewise.
21355         * modules/tzset: Likewise.
21356         * modules/uname: Likewise.
21357         * modules/unlink: Likewise.
21358         * modules/unlinkat: Likewise.
21359         * modules/unlockpt: Likewise.
21360         * modules/unsetenv: Likewise.
21361         * modules/usleep: Likewise.
21362         * modules/utime: Likewise.
21363         * modules/utimensat: Likewise.
21364         * modules/waitpid: Likewise.
21365         * modules/wcpcpy: Likewise.
21366         * modules/wcpncpy: Likewise.
21367         * modules/wcrtomb: Likewise.
21368         * modules/wcscasecmp: Likewise.
21369         * modules/wcscat: Likewise.
21370         * modules/wcschr: Likewise.
21371         * modules/wcscmp: Likewise.
21372         * modules/wcscoll: Likewise.
21373         * modules/wcscpy: Likewise.
21374         * modules/wcscspn: Likewise.
21375         * modules/wcsdup: Likewise.
21376         * modules/wcsftime: Likewise.
21377         * modules/wcslen: Likewise.
21378         * modules/wcsncasecmp: Likewise.
21379         * modules/wcsncat: Likewise.
21380         * modules/wcsncmp: Likewise.
21381         * modules/wcsncpy: Likewise.
21382         * modules/wcsnlen: Likewise.
21383         * modules/wcsnrtombs: Likewise.
21384         * modules/wcspbrk: Likewise.
21385         * modules/wcsrchr: Likewise.
21386         * modules/wcsrtombs: Likewise.
21387         * modules/wcsspn: Likewise.
21388         * modules/wcsstr: Likewise.
21389         * modules/wcstok: Likewise.
21390         * modules/wcswidth: Likewise.
21391         * modules/wcsxfrm: Likewise.
21392         * modules/wctob: Likewise.
21393         * modules/wctomb: Likewise.
21394         * modules/wctrans: Likewise.
21395         * modules/wctype: Likewise.
21396         * modules/wcwidth: Likewise.
21397         * modules/windows-cond: Likewise.
21398         * modules/windows-mutex: Likewise.
21399         * modules/windows-once: Likewise.
21400         * modules/windows-recmutex: Likewise.
21401         * modules/windows-rwlock: Likewise.
21402         * modules/windows-spawn: Likewise.
21403         * modules/windows-spin: Likewise.
21404         * modules/windows-thread: Likewise.
21405         * modules/windows-timedmutex: Likewise.
21406         * modules/windows-timedrecmutex: Likewise.
21407         * modules/windows-timedrwlock: Likewise.
21408         * modules/windows-tls: Likewise.
21409         * modules/wmemchr: Likewise.
21410         * modules/wmemcmp: Likewise.
21411         * modules/wmemcpy: Likewise.
21412         * modules/wmemmove: Likewise.
21413         * modules/wmempcpy: Likewise.
21414         * modules/wmemset: Likewise.
21415         * modules/write: Likewise.
21417 2022-01-09  Bruno Haible  <bruno@clisp.org>
21419         obstack: Move AC_LIBOBJ invocation to the module description.
21420         * m4/obstack.m4 (gl_FUNC_OBSTACK): Renamed from AC_FUNC_OBSTACK. Don't
21421         invoke AC_LIBSOURCES nor AC_LIBOBJ.
21422         * modules/obstack (configure.ac): Update. Invoke AC_LIBOBJ here.
21424 2022-01-09  Bruno Haible  <bruno@clisp.org>
21426         stdio: Move AC_LIBOBJ invocations to the module description.
21427         * m4/stdio_h.m4 (gl_STDIO_H): Don't invoke AC_LIBOBJ.
21428         * modules/stdio (configure.ac): Invoke AC_LIBOBJ here.
21430 2022-01-09  Bruno Haible  <bruno@clisp.org>
21432         fchdir: Move AC_LIBOBJ invocation to the module description.
21433         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke AC_LIBOBJ and
21434         gl_PREREQ_FCHDIR.
21435         * modules/fchdir (configure.ac): Invoke AC_LIBOBJ and gl_PREREQ_FCHDIR.
21437 2022-01-09  Bruno Haible  <bruno@clisp.org>
21439         Remove influence of Automake conditionals on conditional dependencies.
21440         * m4/gnulib-common.m4 (gl_CONDITIONAL): New macro.
21441         (gl_CONDITIONAL_HEADER): Use it instead of AM_CONDITIONAL.
21442         * m4/libgmp.m4 (gl_LIBGMP): Likewise.
21443         * modules/posix_spawn_file_actions_addfchdir-tests (configure.ac):
21444         Likewise.
21445         * modules/uchar-c++-tests (configure.ac): Likewise.
21446         * gnulib-tool (func_modules_transitive_closure): Don't inhibit
21447         conditional dependencies processing on a module that uses an Automake
21448         conditional.
21450 2022-01-08  Bruno Haible  <bruno@clisp.org>
21452         gnulib-tool: Fix "Don't forget" messages (regression 2021-12-12).
21453         * gnulib-tool (func_import): Fix variable references in "Don't forget"
21454         messages.
21456 2022-01-08  Bruno Haible  <bruno@clisp.org>
21458         gnulib-tool: Remove all *.Po files upon distclean (regr. 2022-01-05).
21459         Reported by Mohammad Akhlaghi <mohammad@akhlaghi.org> in
21460         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00061.html>.
21461         * gnulib-tool (func_emit_initmacro_end): Collect the *.Po or *.Plo files
21462         to remove into an AC_SUBSTed variable gl_LIBOBJDEPS.
21463         (func_emit_lib_Makefile_am): Extend the distclean and maintainer-clean
21464         rules.
21466 2022-01-08  Bruno Haible  <bruno@clisp.org>
21468         Add another example.
21469         * examples/hello-c-gnulib-conddeps: New directory.
21471 2022-01-08  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
21473         c-stack: Adapt header file for use in C++ applications.
21474         * lib/c-stack.h: Add extern "C" block.
21476 2022-01-08  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
21478         version-etc: Adapt header file for use in C++ applications.
21479         * lib/version-etc.h: Add extern "C" block.
21481 2022-01-07  Bruno Haible  <bruno@clisp.org>
21483         sigsegv: Improve support for Linux/LoongArch64.
21484         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER): Add special case for
21485         Linux/LoongArch.
21487 2022-01-05  Glenn Washburn  <development@efficientek.com>
21489         bootstrap: When a commit is specified, do a shallow fetch if possible.
21490         Rationale and explanation:
21491         <https://lists.gnu.org/archive/html/bug-gnulib/2021-10/msg00073.html>.
21492         * bootstrap: When a commit hash is specified, ask for this specific
21493         commit on fetch, and fallback to fetching the entire repository if
21494         fetching by commit hash fails.
21496 2022-01-05  Paul Eggert  <eggert@cs.ucla.edu>
21498         stack: pacify gcc -Wsign-compare
21499         * lib/stack.h (_GL_STACK_TYPE): Use idx_t for size too.
21500         Suggested by Bruno Haible in:
21501         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00035.html
21502         (_GL_STACK_PREFIX (size)): Return idx_t, not size_t.
21504 2022-01-05  Bruno Haible  <bruno@clisp.org>
21506         Fix last commit.
21507         Based on a patch by José E. Marchesi <jemarch@gnu.org>, reported in
21508         <https://lists.gnu.org/archive/html/bug-gnulib/2022-01/msg00036.html>.
21509         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): Don't enable
21510         -Wimplicit-fallthrough for GCC < 7.
21512 2022-01-05  Bruno Haible  <bruno@clisp.org>
21514         gnulib-tool: Avoid known warnings that reflect Gnulib's coding style.
21515         * m4/gnulib-common.m4 (gl_CC_GNULIB_WARNINGS): New macro.
21516         * gnulib-tool (func_emit_lib_Makefile_am): Add the
21517         GL_CFLAG_GNULIB_WARNINGS to the CFLAGS of all the compilation units of
21518         the library.
21519         (func_emit_tests_Makefile_am): Add the GL_CFLAG_GNULIB_WARNINGS to the
21520         CFLAGS.
21521         (func_import): Emit an invocation of gl_CC_GNULIB_WARNINGS.
21523 2022-01-04  Bernhard Voelker  <mail@bernhard-voelker.de>
21525         license: fix GPLv3 texts to use a comma instead of semicolon.
21526         See: https://www.gnu.org/licenses/gpl-3.0.html#howto
21527         Run:
21528           $ git grep -l 'Foundation; either version 3' \
21529               | xargs sed -i '/Foundation; either version 3/ s/n; e/n, e/'
21530         * All files using GPLv3: Adjust via the above command.
21532 2022-01-04  Bruno Haible  <bruno@clisp.org>
21534         string, wchar: Fix compilation error on MSVC (regression 2021-09-07).
21535         * lib/string.in.h (free): Don't redeclare as rpl_free. Instead, redefine
21536         _GL_ATTRIBUTE_DEALLOC_FREE to reference rpl_free directly.
21537         * lib/wchar.in.h (free): Likewise.
21539 2022-01-03  Bruno Haible  <bruno@clisp.org>
21541         getpass-gnu: Allow use as dependency from test modules.
21542         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): Set
21543         REPLACE_GETPASS_FOR_GETPASS_GNU instead of REPLACE_GETPASS.
21544         * m4/unistd_h.m4 (gl_UNISTD_H_REQUIRE_DEFAULTS): Initialize the
21545         getpass-gnu module indicator.
21546         (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_GETPASS_FOR_GETPASS_GNU.
21547         * modules/unistd (Makefile.am): Substitute GNULIB_GETPASS_GNU,
21548         REPLACE_GETPASS_FOR_GETPASS_GNU.
21549         * modules/getpass-gnu (configure.ac): Test
21550         REPLACE_GETPASS_FOR_GETPASS_GNU instead of REPLACE_GETPASS. Set a module
21551         indicator.
21552         * lib/unistd.in.h (getpass): Test REPLACE_GETPASS,
21553         REPLACE_GETPASS_FOR_GETPASS_GNU, and the respective module indicators
21554         instead of just REPLACE_GETPASS.
21556 2022-01-03  Bruno Haible  <bruno@clisp.org>
21558         fopen-gnu: Allow use as dependency from test modules.
21559         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): Set REPLACE_FOPEN_FOR_FOPEN_GNU
21560         instead of REPLACE_FOPEN.
21561         * m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize the fopen-gnu
21562         module indicator.
21563         (gl_STDIO_H_DEFAULTS): Initialize REPLACE_FOPEN_FOR_FOPEN_GNU.
21564         * modules/stdio (Makefile.am): Substitute GNULIB_FOPEN_GNU,
21565         REPLACE_FOPEN_FOR_FOPEN_GNU.
21566         * modules/fopen-gnu (Depends-on): Add more dependencies.
21567         (configure.ac): Test REPLACE_FOPEN_FOR_FOPEN_GNU instead of
21568         REPLACE_FOPEN.
21569         * lib/stdio.in.h (fopen): Test REPLACE_FOPEN,
21570         REPLACE_FOPEN_FOR_FOPEN_GNU, and the respective module indicators
21571         instead of just REPLACE_FOPEN.
21573 2022-01-03  Bruno Haible  <bruno@clisp.org>
21575         realloc-gnu: Allow use as dependency from test modules.
21576         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): Set
21577         REPLACE_REALLOC_FOR_REALLOC_GNU instead of REPLACE_REALLOC.
21578         (gl_FUNC_REALLOC_POSIX): Set REPLACE_REALLOC_FOR_REALLOC_POSIX instead
21579         of REPLACE_REALLOC.
21580         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
21581         realloc-gnu module indicator.
21582         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_REALLOC_FOR_REALLOC_GNU,
21583         REPLACE_REALLOC_FOR_REALLOC_POSIX, not REPLACE_REALLOC.
21584         * modules/stdlib (Makefile.am): Substitute GNULIB_REALLOC_GNU,
21585         REPLACE_REALLOC_FOR_REALLOC_GNU, REPLACE_REALLOC_FOR_REALLOC_POSIX, not
21586         REPLACE_REALLOC.
21587         * modules/realloc-posix (Depends-on, configure.ac): Test
21588         REPLACE_REALLOC_FOR_REALLOC_POSIX instead of REPLACE_REALLOC.
21589         * modules/realloc-gnu (Comment): Remove section.
21590         (Depends-on): Add free-posix, malloc-gnu, xalloc-oversized.
21591         (configure.ac): Test REPLACE_REALLOC_FOR_REALLOC_GNU instead of
21592         REPLACE_REALLOC. Set a module indicator.
21593         * lib/stdlib.in.h (realloc): Test REPLACE_REALLOC_FOR_REALLOC_POSIX,
21594         REPLACE_REALLOC_FOR_REALLOC_GNU, and the respective module indicators
21595         instead of just REPLACE_REALLOC.
21597 2022-01-03  Bruno Haible  <bruno@clisp.org>
21599         calloc-gnu: Allow use as dependency from test modules.
21600         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Set REPLACE_CALLOC_FOR_CALLOC_GNU
21601         instead of REPLACE_CALLOC.
21602         (gl_FUNC_CALLOC_POSIX): Set REPLACE_CALLOC_FOR_CALLOC_POSIX instead of
21603         REPLACE_CALLOC.
21604         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
21605         calloc-gnu module indicator.
21606         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_CALLOC_FOR_CALLOC_GNU,
21607         REPLACE_CALLOC_FOR_CALLOC_POSIX, not REPLACE_CALLOC.
21608         * modules/stdlib (Makefile.am): Substitute GNULIB_CALLOC_GNU,
21609         REPLACE_CALLOC_FOR_CALLOC_GNU, REPLACE_CALLOC_FOR_CALLOC_POSIX, not
21610         REPLACE_CALLOC.
21611         * modules/calloc-posix (Depends-on, configure.ac): Test
21612         REPLACE_CALLOC_FOR_CALLOC_POSIX instead of REPLACE_CALLOC.
21613         * modules/calloc-gnu (Depends-on): Add xalloc-oversized.
21614         (configure.ac): Test REPLACE_CALLOC_FOR_CALLOC_GNU instead of
21615         REPLACE_CALLOC. Set a module indicator.
21616         * lib/stdlib.in.h (calloc): Test REPLACE_CALLOC_FOR_CALLOC_POSIX,
21617         REPLACE_CALLOC_FOR_CALLOC_GNU, and the respective module indicators
21618         instead of just REPLACE_CALLOC.
21620 2022-01-03  Bruno Haible  <bruno@clisp.org>
21622         malloc-gnu: Allow use as dependency from test modules.
21623         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): Set REPLACE_MALLOC_FOR_MALLOC_GNU
21624         instead of REPLACE_MALLOC.
21625         (gl_FUNC_MALLOC_PTRDIFF, gl_FUNC_MALLOC_POSIX): Set
21626         REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
21627         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Test
21628         REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
21629         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
21630         * m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
21631         malloc-gnu module indicator.
21632         (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MALLOC_FOR_MALLOC_GNU,
21633         REPLACE_MALLOC_FOR_MALLOC_POSIX, not REPLACE_MALLOC.
21634         * modules/stdlib (Makefile.am): Substitute GNULIB_MALLOC_GNU,
21635         REPLACE_MALLOC_FOR_MALLOC_GNU, REPLACE_MALLOC_FOR_MALLOC_POSIX, not
21636         REPLACE_MALLOC.
21637         * modules/malloc-posix (Depends-on, configure.ac): Test
21638         REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
21639         * modules/malloc-gnu (Comment): Remove section.
21640         (Depends-on): Add xalloc-oversized.
21641         (configure.ac): Test REPLACE_MALLOC_FOR_MALLOC_GNU instead of
21642         REPLACE_MALLOC. Set a module indicator.
21643         * lib/stdlib.in.h (malloc): Test REPLACE_MALLOC_FOR_MALLOC_POSIX,
21644         REPLACE_MALLOC_FOR_MALLOC_GNU, and the respective module indicators
21645         instead of just REPLACE_MALLOC.
21647 2022-01-02  Bruno Haible  <bruno@clisp.org>
21649         striconveh: Make the last change also work on Solaris 11.
21650         * lib/striconveh.c (mem_cd_iconveh_internal): Tweak last commit.
21652         striconveh: Make the last change also work on musl libc.
21653         * lib/striconveh.c (mem_cd_iconveh_internal): Make the U+FFFD conversion
21654         also work with non-GNU iconv() implementations.
21656 2022-01-01  Paul Eggert  <eggert@cs.ucla.edu>
21658         gen-header: port to BusyBox ‘sed’
21659         Problem reported by Tim Rühsen in:
21660         https://lists.gnu.org/r/bug-gnulib/2022-01/msg00004.html
21661         * modules/gen-header (SED_HEADER_NOEDIT): Replace instead of prepend.
21662         (SED_HEADER_STDOUT, SED_HEADER_TO_AT_t): Adjust to that change.
21663         Do not use ‘w foo’ twice in the same script, as BusyBox ‘sed’
21664         mistakenly opens ‘foo’ for output twice, thus losing some output.
21666 2022-01-01  Bruno Haible  <bruno@clisp.org>
21668         striconveh: Support an error handler that produces a Unicode U+FFFD.
21669         Suggested by Marc Nieper-Wißkirchen in
21670         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00175.html>.
21671         * lib/iconveh.h (iconveh_replacement_character): New enum value.
21672         * lib/striconveh.c (mem_cd_iconveh_internal): When the handler is
21673         iconveh_replacement_character, try to produce U+FFFD when possible,
21674         instead of '?'.
21675         * tests/test-striconveh.c (main): Add GB18030 tests. Test also
21676         iconveh_replacement_character.
21678 2022-01-01  Bruno Haible  <bruno@clisp.org>
21680         maint: Update copyright notices.
21681         * build-aux/declared.sh (func_version): Bump year.
21683 2022-01-01  Bruno Haible  <bruno@clisp.org>
21685         maint: Update copyright notices in code generating programs.
21686         * lib/gen-uni-tables.c (output_predicate_test, output_predicate,
21687         output_category, output_combclass, output_bidi_category,
21688         output_decimal_digit_test, output_decimal_digit, output_digit_test,
21689         output_digit, output_numeric_test, output_numeric, output_mirror,
21690         output_joining_type_test, output_joining_type,
21691         output_joining_group_test, output_joining_group, output_scripts,
21692         output_scripts_byname, output_blocks, output_ident_category,
21693         output_nonspacing_property, output_lbrk_tables,
21694         output_lbrk_rules_as_tables, output_wbrk_tables, output_gbp_test,
21695         output_gbp_table, output_decomposition_tables,
21696         output_composition_tables, output_simple_mapping_test,
21697         output_simple_mapping, output_casing_rules): Extend copyright year of
21698         generated file to 2022.
21699         * lib/uniname/gen-uninames.lisp (main): Likewise. Produce license notice
21700         that is consistent with the gnulib/etc/license-notices/ files.
21701         * All files regenerated.
21703 2022-01-01  Paul Eggert  <eggert@cs.ucla.edu>
21705         maint: fix ‘make update-copyright’ on symlinks
21706         After running ‘make update-copyright’ I noticed that it
21707         incorrectly replaced a couple of symlinks with their contents.
21708         * Makefile (update-copyright): Do not update symlinks.
21709         * etc/license-notices/GPL, etc/license-notices/LGPL:
21710         Change these back to symlinks.
21712 2021-12-31  Bruno Haible  <bruno@clisp.org>
21714         unistdio: Prefer newer version to older, buggy one.
21715         * modules/unistdio/ulc-vasnprintf (configure.ac): Bump required
21716         libunistring version. This is needed because of the heap overrun fix
21717         (2018-09-23) and the need to avoid %n on more platforms (2020-10-04).
21718         * modules/unistdio/ulc-asnprintf (configure.ac): Likewise.
21719         * modules/unistdio/ulc-asprintf (configure.ac): Likewise.
21720         * modules/unistdio/ulc-fprintf (configure.ac): Likewise.
21721         * modules/unistdio/ulc-snprintf (configure.ac): Likewise.
21722         * modules/unistdio/ulc-sprintf (configure.ac): Likewise.
21723         * modules/unistdio/ulc-vasprintf (configure.ac): Likewise.
21724         * modules/unistdio/ulc-vfprintf (configure.ac): Likewise.
21725         * modules/unistdio/ulc-vsnprintf (configure.ac): Likewise.
21726         * modules/unistdio/ulc-vsprintf (configure.ac): Likewise.
21728 2021-12-31  Bruno Haible  <bruno@clisp.org>
21730         uniwidth: Optimize.
21731         * lib/gen-uni-tables.c (output_nonspacing_property): Add version
21732         parameter. Emit the usual boilerplate header for generated files.
21733         (is_width2): New function, based on lib/uniwidth/width.c.
21734         (output_width2_property): New function.
21735         (main): Create uniwidth/width0.h instead of uniwidth/width.c.part.
21736         Create uniwidth/width2.h.
21737         * lib/uniwidth/width.c: Include width0.h, width2.h, bitmap.h.
21738         (nonspacing_table_data, nonspacing_table_ind): Remove here.
21739         (uc_width): Replace the double-width character with an u_width2 bitmap
21740         lookup.
21741         * modules/uniwidth/width (Files): Add lib/uniwidth/width0.h,
21742         lib/uniwidth/width2.h, lib/unictype/bitmap.h.
21744 2021-12-31  Bruno Haible  <bruno@clisp.org>
21746         Update to Unicode 14.0.0.
21748         * lib/gen-uni-tables.c (UC_JOINING_GROUP_THIN_YEH,
21749         UC_JOINING_GROUP_VERTICAL_TAIL): New enum values.
21750         (fill_arabicshaping, joining_group_as_c_identifier): Recognize these
21751         joining groups.
21752         * lib/unictype.in.h (UC_JOINING_GROUP_THIN_YEH,
21753         UC_JOINING_GROUP_VERTICAL_TAIL): New enum values.
21754         * lib/unictype/joininggroup_name.h: Add the THIN_YEH, VERTICAL_TAIL
21755         joining groups.
21756         * lib/unictype/joininggroup_byname.gperf: Likewise.
21758         * lib/gen-uni-tables.c (LBP_ID1, LBP_ID2): New enum values.
21759         (LBP_ID): Assign artificial value.
21760         (get_lbp): Use the extended_pictographic property to assign LBP_ID1,
21761         LBP_ID2 instead of LBP_ID. Update such that unilbrk/lbrkprop.txt comes
21762         out as expected.
21763         (debug_output_lbp): Print either LBP_ID1 or LBP_ID2 as LBP_ID.
21764         (lbp_value_to_string): Handle LBP_ID1, LBP_ID2 instead of LBP_ID.
21765         (output_lbrk_rules_as_tables): Treat LBP_ID as macro that maps to two
21766         table rows/columns. In rule LB30b, use LBP_ID2 in addition to LBP_EB.
21767         Remove redundant part of rule LB27.
21768         * lib/unilbrk/lbrktables.h (LBP_ID1, LBP_ID2): New enum values.
21769         (LBP_ID): Remove enum value.
21770         (unilbrk_table): Update declaration.
21771         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks_loop):
21772         Use LBP_ID1 instead of LBP_ID.
21773         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks_loop):
21774         Likewise.
21775         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks_loop):
21776         Likewise.
21777         * tests/unilbrk/test-u8-possible-linebreaks.c (test_function): Add a
21778         test of potential future emoji.
21779         * tests/unilbrk/test-u16-possible-linebreaks.c (test_function):
21780         Likewise.
21781         * tests/unilbrk/test-u32-possible-linebreaks.c (test_function):
21782         Likewise.
21784         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
21785         Update.
21786         (uc_width): Assign width 2 to the characters 0x1AFF0..0x1AFF3,
21787         0x1AFF5..0x1AFFB, 0x1AFFD..0x1AFFE, 0x1B120..0x1B122, 0x1F6DD..0x1F6DF,
21788         0x1F7F0, 0x1FA7B..0x1FA7C, 0x1FAA9..0x1FAAC, 0x1FAB7..0x1FABA,
21789         0x1FAC3..0x1FAC5, 0x1FAD7..0x1FAD9, 0x1FAE0..0x1FAE7, 0x1FAF0..0x1FAF6.
21790         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
21791         0x0890..0x0891, 0x0898..0x089F, 0x08CA..0x0902, 0x0C3C, 0x180F,
21792         0x1AC1..0x1ACE, 0x1DFA, 0x10F82..0x10F85, 0x11070, 0x11073..0x11074,
21793         0x110C2, 0x1CF00..0x1CF2D, 0x1CF30..0x1CF46, 0x1E2AE. Expect ambiguous
21794         width for the character 0x1734. Expect width 2 for the characters
21795         0x1AFF0..0x1AFF3, 0x1AFF5..0x1AFFB, 0x1AFFD..0x1AFFE, 0x1B120..0x1B122,
21796         0x1F6DD..0x1F6DF, 0x1F7F0, 0x1FA7B..0x1FA7C, 0x1FAA9..0x1FAAC,
21797         0x1FAB7..0x1FABA, 0x1FAC3..0x1FAC5, 0x1FAD7..0x1FAD9, 0x1FAE0..0x1FAE7,
21798         0x1FAF0..0x1FAF6.
21800         * All generated files under lib/uni* and tests/uni*: Regenerate.
21801         * tests/uniname/NameAliases.txt: Update.
21802         * tests/uniname/UnicodeData.txt: Update.
21803         * tests/uninorm/NormalizationTest.txt: Update.
21804         * tests/unigbrk/GraphemeBreakTest.txt: Update.
21805         * tests/uniwbrk/WordBreakTest.txt: Update.
21807         * All the affected modules: Bump required libunistring version.
21809 2021-12-31  Bruno Haible  <bruno@clisp.org>
21811         Update to Unicode 13.0.0.
21813         * lib/gen-uni-tables.c (is_WBP_MIDLETTER): Add character 0x055F.
21814         (get_wbp): Assign value WBP_ALETTER to the characters 0x02E5..0x02EB,
21815         0x055A, 0x058A, 0xA708..0xA716.
21817         * lib/gen-uni-tables.c (LBP_CP1, LBP_CP2, LBP_OP1, LBP_OP2): New enum
21818         values.
21819         (LBP_OP, LBP_CP): Assign artificial values.
21820         (get_lbp): Use the unicode_width[] table to assign LBP_CP1, LBP_CP2
21821         instead of LBP_CP, and LBP_OP1, LBP_OP2 instead of LBP_OP. Update such
21822         that unilbrk/lbrkprop.txt comes out as expected.
21823         (debug_output_lbp): Print either LBP_CP1 or LBP_CP2 as LBP_CP. Print
21824         either LBP_OP1 or LBP_OP2 as LBP_OP.
21825         (lbp_value_to_string): Handle LBP_CP1, LBP_CP2, LBP_OP1, LBP_OP2 instead
21826         of LBP_CP, LBP_OP.
21827         (output_lbrk_rules_as_tables): Treat LBP_CP and LBP_OP as macros that
21828         map to two table rows/columns. In rule LB30, use only LBP_OP1 instead of
21829         LBP_OP, and only LBP_CP1 instead of LBP_CP. Simplify rule LB22.
21830         * lib/unilbrk/lbrktables.h (LBP_CP1, LBP_CP2, LBP_OP1, LBP_OP2): New
21831         enum values.
21832         (LBP_OP, LBP_CP): Remove enum values.
21833         (unilbrk_table): Update declaration.
21834         * tests/unilbrk/test-u8-possible-linebreaks.c (test_function): Add a
21835         test for East Asian opening parenthesis.
21836         * tests/unilbrk/test-u16-possible-linebreaks.c (test_function):
21837         Likewise.
21838         * tests/unilbrk/test-u32-possible-linebreaks.c (test_function):
21839         Likewise.
21841         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
21842         Update.
21843         (uc_width): Assign width 2 to the characters 0x16FF0..0x16FF1,
21844         0x18AF3..0x18CD5, 0x18D00..0x18D08, 0x1F6D6..0x1F6D7, 0x1F6FB..0x1F6FC,
21845         0x1F90C, 0x1FA74, 0x1FA83..0x1FA86, 0x1FA96..0x1FAA8, 0x1FAB0..0x1FAB6,
21846         0x1FAC0..0x1FAC2, 0x1FAD0..0x1FAD6.
21847         Assign width 1 to the characters 0x1F93B, 0x1F946.
21848         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
21849         0x0B55, 0x0D81, 0x1ABF..0x1AC0, 0xA82C, 0x10EAB..0x10EAC, 0x111CF,
21850         0x1193B..0x1193C, 0x1193E, 0x11943, 0x16FE4. Expect width 2 for the
21851         characters 0x16FF0..0x16FF1, 0x18AF3..0x18CD5, 0x18D00..0x18D08,
21852         0x1F6D6..0x1F6D7, 0x1F6FB..0x1F6FC, 0x1F90C, 0x1FA74, 0x1FA83..0x1FA86,
21853         0x1FA96..0x1FAA8, 0x1FAB0..0x1FAB6, 0x1FAC0..0x1FAC2, 0x1FAD0..0x1FAD6.
21854         Expect width 1 for the characters 0x1F93B, 0x1F946.
21856         * All generated files under lib/uni* and tests/uni*: Regenerate.
21857         * tests/uniname/NameAliases.txt: Update.
21858         * tests/uniname/UnicodeData.txt: Update.
21859         * tests/uninorm/NormalizationTest.txt: Update.
21860         * tests/unigbrk/GraphemeBreakTest.txt: Update.
21861         * tests/uniwbrk/WordBreakTest.txt: Update.
21863         * All the affected modules: Bump required libunistring version.
21865 2021-12-30  Bruno Haible  <bruno@clisp.org>
21867         uniwbrk: Correction of Unicode 10.0.0 support.
21868         * lib/gen-uni-tables.c (is_WBP_MIDLETTER): Remove character 0x02D7.
21869         The generated files are not affected.
21871 2021-12-30  Bruno Haible  <bruno@clisp.org>
21873         Update to Unicode 12.1.0.
21875         * lib/gen-uni-tables.c: Update comments.
21877         * All generated files under lib/uni* and tests/uni*: Regenerate.
21878         * tests/uniname/NameAliases.txt: Update.
21879         * tests/uniname/UnicodeData.txt: Update.
21880         * tests/uninorm/NormalizationTest.txt: Update.
21881         * tests/unigbrk/GraphemeBreakTest.txt: Update.
21882         * tests/uniwbrk/WordBreakTest.txt: Update.
21884         * All the affected modules: Bump required libunistring version.
21886 2021-12-30  Bruno Haible  <bruno@clisp.org>
21888         Update to Unicode 12.0.0.
21890         * lib/gen-uni-tables.c (is_property_default_ignorable_code_point):
21891         Exclude 0x13430..0x13438.
21892         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
21893         (get_wbp): Map 0xFF10..0xFF19 to WBP_NUMERIC.
21895         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
21896         Update.
21897         (uc_width): Assign width 2 to the characters 0x16FE2..0x16FE3,
21898         0x187F2..0x187F7, 0x1B150..0x1B152, 0x1B164..0x1B167, 0x1F6D5, 0x1F6FA,
21899         0x1F7E0..0x1F7EB, 0x1F90D..0x1F90F, 0x1FA70..0x1FA73, 0x1FA78..0x1FA7A,
21900         0x1FA80..0x1FA82, 0x1FA90..0x1FA95.
21901         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
21902         0x0EBA, 0xA9BD, 0x119D4..0x119D7, 0x119DA..0x119DB, 0x119E0,
21903         0x13430..0x13438, 0x16F4F, 0x1E130..0x1E136, 0x1E2EC..0x1E2EF. Expect
21904         width 2 for the characters 0x16FE2..0x16FE3, 0x187F2..0x187F7,
21905         0x1B150..0x1B152, 0x1B164..0x1B167, 0x1F6D5, 0x1F6FA, 0x1F7E0..0x1F7EB,
21906         0x1F90D..0x1F90F, 0x1FA70..0x1FA73, 0x1FA78..0x1FA7A, 0x1FA80..0x1FA82,
21907         0x1FA90..0x1FA95.
21909         * All generated files under lib/uni* and tests/uni*: Regenerate.
21910         * tests/uniname/NameAliases.txt: Update.
21911         * tests/uniname/UnicodeData.txt: Update.
21912         * tests/uninorm/NormalizationTest.txt: Update.
21913         * tests/unigbrk/GraphemeBreakTest.txt: Update.
21914         * tests/uniwbrk/WordBreakTest.txt: Update.
21916         * All the affected modules: Bump required libunistring version.
21918 2021-12-30  Paul Eggert  <eggert@cs.ucla.edu>
21920         crypto/sm3-buffer: fix C99 conformance bug
21921         * lib/sm3.c (sm3_process_block): Call varargs macro with enough
21922         arguments.  Problem found by IBM XL/C 12.1.0.0 for AIX.
21924 2021-12-30  Bruno Haible  <bruno@clisp.org>
21926         Update to Unicode 11.0.0.
21928         * lib/gen-uni-tables.c (is_property_default_ignorable_code_point):
21929         Simplify by use of PROP_PREPENDED_CONCATENATION_MARK.
21930         (UC_JOINING_GROUP_HANIFI_ROHINGYA_PA,
21931         UC_JOINING_GROUP_HANIFI_ROHINGYA_KINNA_YA): New enum values.
21932         (fill_arabicshaping, joining_group_as_c_identifier): Recognize these
21933         joining groups.
21934         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
21935         (WBP_EB, WBP_EM, WBP_GAZ, WBP_EBG): Remove enum values.
21936         (WBP_WSS): New enum value.
21937         (get_wbp): Update such that uniwbrk/wbrkprop.txt comes out as expected.
21938         (debug_output_wbp, fill_org_wbp, debug_output_org_wbp, output_wbp):
21939         Update for changed enum values.
21941         * lib/unictype.in.h (UC_JOINING_GROUP_HANIFI_ROHINGYA_*): New enum
21942         values.
21943         * lib/unictype/joininggroup_name.h: Add the HANIFI_ROHINGYA_* joining
21944         groups.
21945         * lib/unictype/joininggroup_byname.gperf: Likewise.
21947         * lib/unigbrk.in.h: Mark 4 enum values as obsolete.
21948         * lib/unigbrk/u-grapheme-breaks.h (FUNC): Handle emoji modifier sequence
21949         according to Unicode 11.0.0.
21950         * lib/unigbrk/u8-grapheme-breaks.c: Include <stdbool.h>, unictype.h.
21951         * lib/unigbrk/u16-grapheme-breaks.c: Likewise.
21952         * lib/unigbrk/u32-grapheme-breaks.c: Likewise.
21953         * lib/unigbrk/uc-grapheme-breaks.c: Likewise.
21954         * modules/unigbrk/u8-grapheme-breaks (Depends-on): Add
21955         unictype/property-extended-pictographic, stdbool.
21956         * modules/unigbrk/u16-grapheme-breaks (Depends-on): Likewise.
21957         * modules/unigbrk/u32-grapheme-breaks (Depends-on): Likewise.
21958         * modules/unigbrk/uc-grapheme-breaks (Depends-on): Likewise.
21959         * tests/unigbrk/test-u8-grapheme-breaks.c (main): Add test for emoji
21960         modifier / ZWJ sequence.
21961         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
21962         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
21963         * tests/unigbrk/test-uc-is-grapheme-break.c: Include <stdbool.h>,
21964         unictype.h.
21965         (main): Update workaround logic to match the one in
21966         lib/unigbrk/u-grapheme-breaks.h.
21967         * modules/unigbrk/uc-is-grapheme-break-tests (Depends-on): Add
21968         unictype/property-extended-pictographic, stdbool.
21970         * lib/uniwbrk.in.h: Mark 4 enum values as obsolete.
21971         (WBP_WSS): New enum value.
21972         * lib/uniwbrk/u-wordbreaks.h (FUNC): Handle emoji ZWJ sequences and
21973         horizontal whitespace according to Unicode 11.0.0.
21974         * lib/uniwbrk/u8-wordbreaks.c: Include unictype.h.
21975         * lib/uniwbrk/u16-wordbreaks.c: Likewise.
21976         * lib/uniwbrk/u32-wordbreaks.c: Likewise.
21977         * lib/uniwbrk/wbrktable.c (uniwbrk_prop_index, uniwbrk_table): Add a row
21978         and column for WBP_WSS.
21979         * lib/uniwbrk/wbrktable.h (uniwbrk_prop_index, uniwbrk_table): Update
21980         declarations.
21981         * modules/uniwbrk/u8-wordbreaks (Depends-on): Add
21982         unictype/property-extended-pictographic.
21983         * modules/uniwbrk/u16-wordbreaks (Depends-on): Likewise.
21984         * modules/uniwbrk/u32-wordbreaks (Depends-on): Likewise.
21985         * tests/uniwbrk/test-u8-wordbreaks.c (main): Update expected results.
21986         * tests/uniwbrk/test-u16-wordbreaks.c (main): Likewise.
21987         * tests/uniwbrk/test-u32-wordbreaks.c (main): Likewise.
21988         * tests/uniwbrk/test-uc-wordbreaks.c (wordbreakproperty_to_string):
21989         Update.
21991         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks_loop):
21992         Handle ZWJ according to Unicode 11.0.0.
21993         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks_loop):
21994         Likewise.
21995         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks_loop):
21996         Likewise.
21998         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
21999         Update.
22000         (uc_width): Assign width 2 to the characters 0x187ED..0x187F1, 0x1F6F9,
22001         0x1F9E7..0x1F9FF.
22002         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
22003         0x07FD, 0x08D3, 0x09FE, 0x0C04, 0xA8FF, 0x10D24..0x10D27,
22004         0x10F46..0x10F50, 0x110CD, 0x111C9, 0x1133B, 0x1145E, 0x1182F..0x11837,
22005         0x11839..0x1183A, 0x11D90..0x11D91, 0x11D95, 0x11D97, 0x11EF3..0x11EF4.
22006         Expect width 2 for the characters 0x187ED..0x187F1, 0x1F6F9,
22007         0x1F9E7..0x1F9FF.
22009         * All generated files under lib/uni* and tests/uni*: Regenerate.
22010         * tests/uniname/NameAliases.txt: Update.
22011         * tests/uniname/UnicodeData.txt: Update.
22012         * tests/uninorm/NormalizationTest.txt: Update.
22013         * tests/unigbrk/GraphemeBreakTest.txt: Update.
22014         * tests/uniwbrk/WordBreakTest.txt: Update.
22016         * All the affected modules: Bump required libunistring version.
22018 2021-12-30  Bruno Haible  <bruno@clisp.org>
22020         unictype: Add Emoji properties from Unicode 11.0.0.
22021         * lib/gen-uni-tables.c (PROP_EMOJI*, PROP_EXTENDED_PICTOGRAPHIC): New
22022         enum values.
22023         (fill_properties): Don't require a space between the property name and
22024         the comment. Handle the property names from emoji-data.txt.
22025         (is_property_emoji, is_property_emoji_presentation,
22026         is_property_emoji_modifier, is_property_emoji_modifier_base,
22027         is_property_emoji_component, is_property_extended_pictographic): New
22028         declarations.
22029         (output_properties): Emit the properties emoji, emoji_presentation,
22030         emoji_modifier, emoji_modifier_base, emoji_component,
22031         extended_pictographic.
22032         (get_lbp): Use the emoji_modifier property.
22033         (main): Expect one more argument, for the emoji-data.txt file.
22034         * lib/unictype.in.h (UC_PROPERTY_EMOJI, UC_PROPERTY_EMOJI_PRESENTATION,
22035         UC_PROPERTY_EMOJI_MODIFIER, UC_PROPERTY_EMOJI_MODIFIER_BASE,
22036         UC_PROPERTY_EMOJI_COMPONENT, UC_PROPERTY_EXTENDED_PICTOGRAPHIC,
22037         uc_is_property_emoji, uc_is_property_emoji_presentation,
22038         uc_is_property_emoji_modifier, uc_is_property_emoji_modifier_base,
22039         uc_is_property_emoji_component, uc_is_property_extended_pictographic):
22040         New declarations.
22041         * lib/unictype/pr_emoji.c: New file.
22042         * lib/unictype/pr_emoji_presentation.c: New file.
22043         * lib/unictype/pr_emoji_modifier.c: New file.
22044         * lib/unictype/pr_emoji_modifier_base.c: New file.
22045         * lib/unictype/pr_emoji_component.c: New file.
22046         * lib/unictype/pr_extended_pictographic.c: New file.
22047         * modules/unictype/property-emoji: New file.
22048         * modules/unictype/property-emoji-tests: New file.
22049         * modules/unictype/property-emoji-presentation: New file.
22050         * modules/unictype/property-emoji-presentation-tests: New file.
22051         * modules/unictype/property-emoji-modifier: New file.
22052         * modules/unictype/property-emoji-modifier-tests: New file.
22053         * modules/unictype/property-emoji-modifier-base: New file.
22054         * modules/unictype/property-emoji-modifier-base-tests: New file.
22055         * modules/unictype/property-emoji-component: New file.
22056         * modules/unictype/property-emoji-component-tests: New file.
22057         * modules/unictype/property-extended-pictographic: New file.
22058         * modules/unictype/property-extended-pictographic-tests: New file.
22059         * modules/unictype/property-all (Depends-on): Depend on the new modules.
22061 2021-12-29  Bruno Haible  <bruno@clisp.org>
22063         uniwidth: Give width 0 to conjoining Hangul Jamo jungseong, jongseong.
22064         Reported by Luis Javier Merino <ninjalj@gmail.com> in
22065         <https://lists.gnu.org/archive/html/bug-libunistring/2021-12/msg00006.html>.
22066         * lib/gen-uni-tables.c (is_nonspacing): Return true for the conjoining
22067         Hangul Jamo jungseong and jongseong characters.
22068         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
22069         Regenerated.
22070         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
22071         0x1160..0x11FF, 0xD7B0..0xD7C6, 0xD7CB..0xD7FB.
22073 2021-12-29  Bruno Haible  <bruno@clisp.org>
22075         uniwidth: Update to Unicode 10.0.0.
22076         * lib/uniwidth/width.c (uc_width): Assign width 2 to the characters
22077         0x231A..0x231B, 0x23E9..0x23EC, 0x23F0, 0x23F3, 0x25FD..0x25FE,
22078         0x2614..0x2615, 0x2648..0x2653, 0x267F, 0x2693, 0x26A1, 0x26AA..0x26AB,
22079         0x26BD..0x26BE, 0x26C4..0x26C5, 0x26CE, 0x26D4, 0x26EA, 0x26F2..0x26F3,
22080         0x26F5, 0x26FA, 0x26FD, 0x2705, 0x270A..0x270B, 0x2728, 0x274C, 0x274E,
22081         0x2753..0x2755, 0x2757, 0x2795..0x2797, 0x27B0, 0x27BF, 0x2B1B..0x2B1C,
22082         0x2B50, 0x2B55, 0xA960..0xA97C, 0x16FE0..0x16FE1, 0x17000..0x187EC,
22083         0x18800..0x18AF2, 0x1B000..0x1B11F, 0x1B170..0x1B2FB, 0x1F004, 0x1F0CF,
22084         0x1F18E, 0x1F191..0x1F19A, 0x1F200..0x1F320, 0x1F32D..0x1F335,
22085         0x1F337..0x1F37C, 0x1F37E..0x1F393, 0x1F3A0..0x1F3CA, 0x1F3CF..0x1F3D3,
22086         0x1F3E0..0x1F3F0, 0x1F3F4, 0x1F3F8..0x1F43E, 0x1F440, 0x1F442..0x1F4FC,
22087         0x1F4FF..0x1F53D, 0x1F54B..0x1F54E, 0x1F550..0x1F567, 0x1F57A,
22088         0x1F595..0x1F596, 0x1F5A4, 0x1F5FB..0x1F64F, 0x1F680..0x1F6C5, 0x1F6CC,
22089         0x1F6D0..0x1F6D2, 0x1F6EB..0x1F6EC, 0x1F6F4..0x1F6F8, 0x1F910..0x1F9E6.
22090         Assign ambiguous width to the characters 0x3248..0x324F.
22091         * tests/uniwidth/test-uc_width2.sh: Expect these changes.
22093 2021-12-29  Bruno Haible  <bruno@clisp.org>
22095         unilbrk: Improve support for strings that contain CR-LF sequences.
22096         * lib/gen-uni-tables.c (LBP_CR, LBP_LF): New enum values.
22097         (get_lbp): For '\r' and '\n', return LBP_CR and LBP_LF, respectively,
22098         instead of LBP_BK.
22099         (debug_output_lbp, fill_org_lbp, debug_output_org_lbp,
22100         lbp_value_to_string): Handle LBP_CR, LBP_LF.
22101         * lib/unilbrk/lbrkprop2.h: Regenerated.
22102         * lib/unilbrk/lbrktables.h (LBP_CR, LBP_LF): New enum values.
22103         * lib/unilbrk.in.h (UC_BREAK_CR_BEFORE_LF): New enum value.
22104         (u8_possible_linebreaks, u16_possible_linebreaks,
22105         u32_possible_linebreaks, ulc_possible_linebreaks, u8_width_linebreaks,
22106         u16_width_linebreaks, u32_width_linebreaks, ulc_width_linebreaks):
22107         Declare also a _v2 variant, and use a C macro to activate it by default.
22108         * lib/unilbrk/internal.h: New file.
22109         * lib/unilbrk/u8-possible-linebreaks.c: Include unilbrk/internal.h.
22110         (u8_possible_linebreaks_loop): Renamed from u8_possible_linebreaks. Add
22111         'cr' parameter.
22112         (u8_possible_linebreaks, u8_possible_linebreaks_v2): New functions.
22113         (main): Update.
22114         * lib/unilbrk/u16-possible-linebreaks.c: Include unilbrk/internal.h.
22115         (u16_possible_linebreaks_loop): Renamed from u16_possible_linebreaks.
22116         Add 'cr' parameter.
22117         (u16_possible_linebreaks, u16_possible_linebreaks_v2): New functions.
22118         * lib/unilbrk/u32-possible-linebreaks.c: Include unilbrk/internal.h.
22119         (u32_possible_linebreaks_loop): Renamed from u32_possible_linebreaks.
22120         Add 'cr' parameter.
22121         (u32_possible_linebreaks, u32_possible_linebreaks_v2): New functions.
22122         * lib/unilbrk/ulc-possible-linebreaks.c: Include unilbrk/internal.h,
22123         unilbrk/lbrktables.h.
22124         (ulc_possible_linebreaks_internal): Renamed from
22125         ulc_possible_linebreaks. Add 'cr' parameter.
22126         (ulc_possible_linebreaks, ulc_possible_linebreaks_v2): New functions.
22127         (main): Update.
22128         * lib/unilbrk/u8-width-linebreaks.c: Include unilbrk/internal.h,
22129         unilbrk/lbrktables.h.
22130         (u8_width_linebreaks_internal): Renamed from u8_width_linebreaks. Add
22131         'cr' parameter.
22132         (u8_width_linebreaks, u8_width_linebreaks_v2): New functions.
22133         (main): Update.
22134         * lib/unilbrk/u16-width-linebreaks.c: Include unilbrk/internal.h,
22135         unilbrk/lbrktables.h.
22136         (u16_width_linebreaks_internal): Renamed from u16_width_linebreaks. Add
22137         'cr' parameter.
22138         (u16_width_linebreaks, u16_width_linebreaks_v2): New functions.
22139         * lib/unilbrk/u32-width-linebreaks.c: Include unilbrk/internal.h,
22140         unilbrk/lbrktables.h.
22141         (u32_width_linebreaks_internal): Renamed from u32_width_linebreaks. Add
22142         'cr' parameter.
22143         (u32_width_linebreaks, u32_width_linebreaks_v2): New functions.
22144         * lib/unilbrk/ulc-width-linebreaks.c: Include unilbrk/internal.h,
22145         unilbrk/lbrktables.h.
22146         (ulc_width_linebreaks_internal): Renamed from ulc_width_linebreaks. Add
22147         'cr' parameter.
22148         (ulc_width_linebreaks, ulc_width_linebreaks_v2): New functions.
22149         (main): Update.
22150         * modules/unilbrk/u8-possible-linebreaks (Files): Add
22151         lib/unilbrk/internal.h.
22152         * modules/unilbrk/u16-possible-linebreaks (Files): Likewise.
22153         * modules/unilbrk/u32-possible-linebreaks (Files): Likewise.
22154         * modules/unilbrk/u8-width-linebreaks (Files): Likewise.
22155         * tests/unilbrk/test-u8-possible-linebreaks.c (test_function): New
22156         function, extracted from main. Add a test of CR-LF handling.
22157         (main): Invoke it twice.
22158         * tests/unilbrk/test-u16-possible-linebreaks.c (test_function): New
22159         function, extracted from main. Add a test of CR-LF handling.
22160         (main): Invoke it twice.
22161         * tests/unilbrk/test-u32-possible-linebreaks.c (test_function): New
22162         function, extracted from main. Add a test of CR-LF handling.
22163         (main): Invoke it twice.
22164         * tests/unilbrk/test-ulc-possible-linebreaks.c (test_function): New
22165         function, extracted from main.
22166         (main): Invoke it twice.
22167         * tests/unilbrk/test-u8-width-linebreaks.c (test_function): New
22168         function, extracted from main.
22169         (main): Invoke it twice.
22170         * tests/unilbrk/test-u16-width-linebreaks.c (test_function): New
22171         function, extracted from main.
22172         (main): Invoke it twice.
22173         * tests/unilbrk/test-u32-width-linebreaks.c (test_function): New
22174         function, extracted from main.
22175         (main): Invoke it twice.
22176         * tests/unilbrk/test-ulc-width-linebreaks.c (test_function): New
22177         function, extracted from main.
22178         (main): Invoke it twice.
22180 2021-12-29  Bruno Haible  <bruno@clisp.org>
22182         uniwbrk: Add unit tests of CR-LF sequences.
22183         * tests/uniwbrk/test-u8-wordbreaks.c (main): Add test of a string with
22184         CR-LF.
22185         * tests/uniwbrk/test-u16-wordbreaks.c (main): Likewise.
22186         * tests/uniwbrk/test-u32-wordbreaks.c (main): Likewise.
22188 2021-12-29  Bruno Haible  <bruno@clisp.org>
22190         unigbrk: Add unit tests of CR-LF sequences.
22191         * tests/unigbrk/test-u8-grapheme-breaks.c (main): Add test of a string
22192         with CR-LF.
22193         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
22194         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
22196 2021-12-29  Bruno Haible  <bruno@clisp.org>
22198         unilbrk: Update handling of Hebrew letter + hyphen for Unicode 10.0.0.
22199         * lib/unilbrk/lbrktables.h (LBP_HL_BA): New enum value.
22200         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Add
22201         code for handling break-after character after Hebrew letter.
22202         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
22203         Likewise.
22204         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
22205         Likewise.
22206         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
22207         regarding break-after character after Hebrew letter.
22208         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
22209         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
22211 2021-12-28  Paul Eggert  <eggert@cs.ucla.edu>
22213         nstrftime: improve handling of invalid formats
22214         * lib/nstrftime.c (__strftime_internal): Without this change,
22215         ‘date +'%0_-+^#1%A'’ would output ‘%A’; with it, it outputs
22216         something like ‘%0_-+^#1Tuesday’ which is easier to debug and to
22217         write wrappers for (such as the nstrftime/fprintftime usage in GNU
22218         ‘date’).
22220 2021-12-28  Bruno Haible  <bruno@clisp.org>
22222         unilbrk: Update handling of regional indicators for Unicode 10.0.0.
22223         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Add
22224         code for handling regional indicators.
22225         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
22226         Likewise.
22227         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
22228         Likewise.
22229         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
22230         regarding regional indicators.
22231         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
22232         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
22234 2021-12-28  Bruno Haible  <bruno@clisp.org>
22236         unilbrk: Update handling of zero-width joiner for Unicode 10.0.0.
22237         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Update
22238         code for zero-width joiner handling to match UAX #14 for Unicode 10.0.0.
22239         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
22240         Likewise.
22241         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
22242         Likewise.
22243         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
22244         regarding zero-width joiner.
22245         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
22246         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
22248 2021-12-28  Bruno Haible  <bruno@clisp.org>
22250         unilbrk: Update handling of combining marks for Unicode 10.0.0.
22251         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Update
22252         code for combining characters to match UAX #14 for Unicode 10.0.0.
22253         Remove legacy support for space + combining mark.
22254         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
22255         Likewise.
22256         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
22257         Likewise.
22258         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add a test
22259         regarding combining characters.
22260         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
22261         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
22263 2021-12-28  Bruno Haible  <bruno@clisp.org>
22265         unilbrk: Restore deviation for (IS,AL) pair.
22266         * lib/gen-uni-tables.c (output_lbrk_rules_as_tables): Disable rule LB29.
22267         * lib/unilbrk/lbrktables.c: Regenerated.
22268         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add test case with
22269         HTML markup.
22270         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
22271         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
22272         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
22274 2021-12-28  Bruno Haible  <bruno@clisp.org>
22276         unilbrk: Change algorithm to be closer to Unicode Standard Annex #14.
22277         * lib/gen-uni-tables.c (lbp_value_to_string): New function, extracted
22278         from output_lbp.
22279         (output_lbp): Invoke it.
22280         (output_lbrk_rules_as_tables): New function.
22281         (main): Invoke it.
22282         * lib/unilbrk/lbrktables.c: Now automatically generated.
22283         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update expected
22284         result.
22285         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
22286         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
22287         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
22288         * tests/unilbrk/test-ulc-width-linebreaks.c (main): Likewise.
22290 2021-12-28  Bruno Haible  <bruno@clisp.org>
22292         uniwbrk: Add unit tests of regional indicators.
22293         * tests/uniwbrk/test-u8-wordbreaks.c (main): Add test of regional
22294         indicators.
22295         * tests/uniwbrk/test-u16-wordbreaks.c (main): Likewise.
22296         * tests/uniwbrk/test-u32-wordbreaks.c (main): Likewise.
22298 2021-12-28  Bruno Haible  <bruno@clisp.org>
22300         unigbrk: Simplify code for regional indicators.
22301         * lib/unigbrk/u-grapheme-breaks.h (FUNC): Make code for regional
22302         indicators more future-proof.
22303         * tests/unigbrk/test-u8-grapheme-breaks.c (main): Add test of regional
22304         indicators.
22305         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
22306         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
22308 2021-12-28  Paul Eggert  <eggert@cs.ucla.edu>
22310         clock_getres: document portability issues better
22311         * doc/posix-functions/clock_getres.texi:
22312         * doc/posix-functions/timespec_getres.texi:
22313         Document problems with timestamp resolution.
22315         timespec_getres: new module
22316         * lib/time.in.h (timespec_getres): New decl.
22317         * lib/timespec_getres.c, m4/timespec_getres.m4:
22318         * modules/timespec_getres, modules/timespec_getres-tests:
22319         * tests/test-timespec_getres.c:
22320         New files.
22321         * m4/time_h.m4 (gl_TIME_H_REQUIRE_DEFAULTS, gl_TIME_H_DEFAULTS):
22322         * modules/time (time.h):
22323         Support timespec_getres.
22325         gettime-res: new module
22326         * lib/gettime-res.c, modules/gettime-res: New files.
22327         * lib/timespec.h (gettime_res): New decl.
22328         * m4/clock_time.m4 (gl_CLOCK_TIME): Also check for clock_getres.
22329         * m4/gettime.m4 (gl_GETTIME_RES): New macro.
22331         gettime: port better to non-POSIX C2x
22332         C2x requires a function timespec_get; prefer that to
22333         gettimeofday, since it has better resolution.
22334         * lib/gettime.c (gettime): Prefer timespec_get to gettimeofday.
22335         * m4/gettime.m4 (gl_GETTIME): Check for timespec_get.
22336         Omit a check for gettimeofday; not needed because
22337         the gettime module depends on the gettimeofday module.
22339 2021-12-28  Bruno Haible  <bruno@clisp.org>
22341         gen-uni-tables: Produce license notices suitable for Gnulib.
22342         * lib/gen-uni-tables.c (output_library_license, output_tests_license):
22343         Produce license notices that are consistent with the
22344         gnulib/etc/license-notices/ files.
22345         * All generated files under lib/uni* and tests/uni*: Regenerate.
22347 2021-12-28  Bruno Haible  <bruno@clisp.org>
22349         unigbrk, uniwbrk: No-op tweaks.
22350         * lib/unigbrk/u-grapheme-breaks.h: Comment tweaks.
22351         * lib/uniwbrk/u-wordbreaks.h: Coding style and comment tweaks.
22352         * lib/uniwbrk/wbrktable.c: Comment tweaks.
22354 2021-12-28  Paul Eggert  <eggert@cs.ucla.edu>
22356         perl: let caller see whether perl was found
22357         Problem reported for coreutils by Serge Belyshev (Bug#52844).
22358         * m4/perl.m4 (gl_PERL): Use AC_CACHE_CHECK, so that
22359         an invoker of gl_PERL can later inspect gl_cv_prog_perl
22360         to see whether perl was found.
22362 2021-12-28  Bruno Haible  <bruno@clisp.org>
22364         Fix --automake-subdir breakage (regression 2021-12-24).
22365         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
22366         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00156.html>.
22367         * build-aux/prefix-gnulib-mk (prefix_assignment): Don't change
22368         SED_HEADER_* variables.
22370 2021-12-26  Bruno Haible  <bruno@clisp.org>
22372         Update to Unicode 10.0.0.
22374         * lib/gen-uni-tables.c (PROP_REGIONAL_INDICATOR): New enum value.
22375         (fill_properties): Recognize property "Regional_Indicator".
22376         (is_property_regional_indicator): New function.
22377         (output_properties): Also output the data for regional_indicator.
22378         (get_lbp): Update such that unilbrk/lbrkprop.txt comes out as expected.
22379         Use is_property_regional_indicator.
22380         (get_wbp): Update such that uniwbrk/wbrkprop.txt comes out as expected.
22381         Use is_property_regional_indicator.
22382         (UC_JOINING_GROUP_MALAYALAM_*): New enum values.
22383         (fill_arabicshaping, joining_group_as_c_identifier): Recognize these
22384         joining groups.
22386         * lib/uniname/gen-uninames.lisp (main): Ignore empty lines and comment
22387         lines in the aliases file. Needed because since 2015-06-20, we use the
22388         unmodified Unicode NameAliases.txt file. Remove reference to undefined
22389         variable. Correct indentation.
22391         * lib/unictype.in.h (UC_PROPERTY_REGIONAL_INDICATOR,
22392         uc_is_property_regional_indicator): New declarations.
22393         * lib/unictype/pr_regional_indicator.c: New file.
22394         * modules/unictype/property-regional-indicator: New file.
22395         * modules/unictype/property-regional-indicator-tests: New file.
22396         * modules/unictype/property-all (Depends-on): Add
22397         unictype/property-regional-indicator.
22399         * lib/unictype.in.h (UC_JOINING_GROUP_MALAYALAM_*): New enum values.
22400         * lib/unictype/joininggroup_name.h: Add the MALAYALAM_* joining groups.
22401         * lib/unictype/joininggroup_byname.gperf: Likewise.
22403         * lib/uniwidth/width.c (nonspacing_table_data, nonspacing_table_ind):
22404         Update.
22405         * tests/uniwidth/test-uc_width2.sh: Expect width 0 for the characters
22406         0x0AFA..0x0AFF, 0x0D00, 0x0D3B..0x0D3C, 0x1DF6..0x1DF9,
22407         0x11A01..0x11A06, 0x11A09..0x11A0A, 0x11A33..0x11A38, 0x11A3B..0x11A3E,
22408         0x11A47, 0x11A51..0x11A56, 0x11A59..0x11A5B, 0x11A8A..0x11A96,
22409         0x11A98..0x11A99, 0x11D31..0x11D36, 0x11D3A, 0x11D3C..0x11D3D,
22410         0x11D3F..0x11D45, 0x11D47.
22412         * All generated files under lib/uni* and tests/uni*: Regenerate.
22413         * tests/uniname/NameAliases.txt: Update.
22414         * tests/uniname/UnicodeData.txt: Update.
22415         * tests/uninorm/NormalizationTest.txt: Update.
22416         * tests/unigbrk/GraphemeBreakTest.txt: Update.
22417         * tests/uniwbrk/WordBreakTest.txt: Update.
22419         * All the affected modules: Bump required libunistring version.
22421 2021-12-26  Bruno Haible  <bruno@clisp.org>
22423         pselect: Fix compilation error in C++ mode on AIX 7.
22424         * lib/sys_select.in.h (pselect): Use _GL_CXXALIAS_SYS_CAST instead of
22425         _GL_CXXALIAS_SYS.
22426         * doc/posix-functions/pselect.texi: Mention the AIX problem.
22428 2021-12-25  Bruno Haible  <bruno@clisp.org>
22430         gnulib-tool: Fix handling of module libtextstyle-optional.
22431         Reported by Paul Eggert in
22432         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00152.html>.
22433         * gnulib-tool (func_repeat_module_in_tests): New function.
22434         (func_emit_tests_Makefile_am, func_create_testdir): Use it for the file
22435         list and when creating tests/Makefile.am.
22437 2021-12-25  Bruno Haible  <bruno@clisp.org>
22439         gnulib-tool: Respect applicability 'all' without --single-configure.
22440         * gnulib-tool (func_verify_tests_module): Treat modules with
22441         applicability 'all' like 'tests' modules, not like 'main' modules.
22443 2021-12-24  Paul Eggert  <eggert@cs.ucla.edu>
22445         maint: avoid empty lines in recipes
22446         AIX 7.2 ‘make’ complains about recipe lines that are empty after
22447         macro expansion, and I suppose there’s a good chance some
22448         non-POSIX ‘make’ would prohibit them.  Rework macros so
22449         that we can avoid them.
22450         * gnulib-tool (func_emit_lib_Makefile_am)
22451         (func_emit_tests_Makefile_am): Support @!NMD@ too.
22452         * modules/gen-header (@gl_V_at): New macro.
22453         * modules/alloca-opt, modules/argz, modules/assert-h:
22454         * modules/byteswap, modules/configmake, modules/ctype:
22455         * modules/dirent, modules/errno, modules/execinfo, modules/fcntl-h:
22456         * modules/float, modules/fnmatch-h, modules/getopt-posix:
22457         * modules/glob-h, modules/iconv-h, modules/ieee754-h:
22458         * modules/inttypes-incomplete, modules/langinfo:
22459         * modules/libtextstyle-optional, modules/limits-h, modules/locale:
22460         * modules/malloc-h, modules/math, modules/monetary, modules/netdb:
22461         * modules/openmp-init, modules/poll-h, modules/posix-shell:
22462         * modules/pthread-h, modules/pty, modules/sched, modules/search:
22463         * modules/signal-h, modules/sigsegv, modules/snippet/link-warning:
22464         * modules/spawn, modules/stdalign, modules/stdarg, modules/stdbool:
22465         * modules/stddef, modules/stdint, modules/stdio, modules/stdlib:
22466         * modules/stdnoreturn, modules/string, modules/strings:
22467         * modules/sysexits, modules/termios, modules/threads-h:
22468         * modules/time, modules/uchar, modules/unicase/base:
22469         * modules/uniconv/base, modules/unictype/base, modules/unigbrk/base:
22470         * modules/unilbrk/base, modules/uniname/base, modules/uninorm/base:
22471         * modules/unistd, modules/unistdio/base, modules/unistr/base:
22472         * modules/unitypes, modules/uniwbrk/base, modules/uniwidth/base:
22473         * modules/utime-h, modules/wchar, modules/wctype-h:
22474         Use it.
22476         maint: tight-scope.mk need not be read-only
22477         * top/maint.mk (tight-scope.mk): Don’t bother to make
22478         tight-scope.mk read-only either.
22480         maint: break out '&& mv $@-t $@'
22481         * build-aux/git-version-gen, config/argz.mk, modules/configmake:
22482         * modules/posix_spawnp-tests, modules/snippet/link-warning:
22483         * top/maint.mk:
22484         Break out '&& mv $@-t $@' to a separate line in the Make recipe,
22485         as this makes things a bit easier to debug.
22487         gen-header: new module
22488         Simplify header generation by using Makefile variables
22489         defined by a new gen-header module.
22490         * modules/gen-header: New module.
22491         * modules/alloca-opt, modules/argz, modules/arpa_inet:
22492         * modules/assert-h, modules/byteswap:
22493         * modules/ctype, modules/dirent, modules/dynarray, modules/errno:
22494         * modules/execinfo, modules/fcntl-h, modules/float:
22495         * modules/fnmatch-h, modules/getopt-posix, modules/glob-h:
22496         * modules/iconv-h, modules/ieee754-h, modules/inttypes-incomplete:
22497         * modules/langinfo, modules/libtextstyle-optional, modules/limits-h:
22498         * modules/locale, modules/malloc-h, modules/math, modules/monetary:
22499         * modules/net_if, modules/netdb, modules/netinet_in:
22500         * modules/openmp-init, modules/poll-h:
22501         * modules/pthread-h, modules/pty, modules/sched:
22502         * modules/scratch_buffer, modules/search, modules/selinux-h:
22503         * modules/signal-h, modules/sigsegv:
22504         * modules/spawn, modules/stdalign, modules/stdarg, modules/stdbool:
22505         * modules/stddef, modules/stdint, modules/stdio, modules/stdlib:
22506         * modules/stdnoreturn, modules/string, modules/strings:
22507         * modules/sys_file, modules/sys_ioctl, modules/sys_random:
22508         * modules/sys_resource, modules/sys_select, modules/sys_socket:
22509         * modules/sys_stat, modules/sys_time, modules/sys_times:
22510         * modules/sys_types, modules/sys_uio, modules/sys_utsname:
22511         * modules/sys_wait, modules/sysexits, modules/termios:
22512         * modules/threads-h, modules/time, modules/uchar:
22513         * modules/unicase/base, modules/unicase/special-casing:
22514         * modules/uniconv/base, modules/unictype/base, modules/unigbrk/base:
22515         * modules/unilbrk/base, modules/uniname/base, modules/uninorm/base:
22516         * modules/unistd, modules/unistdio/base, modules/unistr/base:
22517         * modules/unitypes, modules/uniwbrk/base, modules/uniwidth/base:
22518         * modules/utime-h, modules/wchar, modules/wctype-h:
22519         Depend on gen-header, and use its macros to simplify
22520         header generation.
22522 2021-12-24  Bruno Haible  <bruno@clisp.org>
22524         passfd: Fix compilation error on IRIX.
22525         * lib/passfd.c (sendfd): On IRIX, ignore CMSG_FIRSTHDR.
22526         (recvfd): Likewise. Produce a fake error ENOTCONN.
22528 2021-12-24  Bruno Haible  <bruno@clisp.org>
22530         tests: Fix link errors on AIX.
22531         * modules/fnmatch-h-c++-tests (Makefile.am): Link test-fnmatch-h-c++
22532         with $(LIB_MBRTOWC).
22533         * modules/glob-h-c++-tests (Makefile.am): Link test-glob-h-c++ with
22534         $(LIB_MBRTOWC).
22535         * modules/stdlib-c++-tests (Makefile.am): Link test-stdlib-c++ with
22536         $(GETLOADAVG_LIBS).
22537         * modules/sys_stat-c++-tests (Makefile.am): Link test-sys_stat-c++ with
22538         $(LIB_MBRTOWC).
22539         * modules/uchar-c++-tests (Makefile.am): Link test-uchar-c++ with
22540         $(LIBUNISTRING).
22542 2021-12-24  Bruno Haible  <bruno@clisp.org>
22544         hamt tests: Fix compilation error with AIX xlc.
22545         * tests/test-hamt.c (test_iterator): Don't use compound initializer.
22547 2021-12-24  Bruno Haible  <bruno@clisp.org>
22549         strerrorname_np: Fix compilation error on IRIX.
22550         * lib/strerrorname_np.c (strerrorname_np): Handle conflict between
22551         EDIRCORRUPTED and EFSCORRUPTED.
22552         * tests/test-strerrorname_np.c (main): Likewise.
22554 2021-12-24  Bruno Haible  <bruno@clisp.org>
22556         hamt: Fix compilation error on NetBSD 7.
22557         * lib/hamt.h (GL_HAMT_THREAD_SAFE): Define to 0 if the compiler is a
22558         GCC version < 4.9.
22560 2021-12-24  Bruno Haible  <bruno@clisp.org>
22562         search: Fix compilation errors with SunPRO C++ on Solaris 10.
22563         * lib/search.in.h (_gl_lsearch_compar_fn): New type.
22564         (lfind, lsearch): Use it.
22566 2021-12-24  Bruno Haible  <bruno@clisp.org>
22568         qsort_r: Fix compilation error with SunPRO C++ on Solaris 10.
22569         * lib/stdlib.in.h (_gl_qsort_r_compar_fn): New type.
22570         (qsort_r): Use it.
22571         * tests/test-stdlib-c++.cc (qsort_r): Don't test with SunPRO C++.
22573 2021-12-24  Bruno Haible  <bruno@clisp.org>
22575         threads-h tests: Avoid clang warnings.
22576         * tests/test-threads.c (main): Add 'default' to switch statements.
22578 2021-12-24  Bruno Haible  <bruno@clisp.org>
22580         doc: Small updates.
22581         * doc/glibc-functions/ptsname_r.texi: Update info regarding Mac OS X.
22582         * doc/posix-functions/getlogin_r.texi: Update info regarding FreeBSD.
22584 2021-12-22  Paul Eggert  <eggert@cs.ucla.edu>
22586         libgmp: omit redundant 'mkdir -p .'
22587         * modules/libgmp: Mark $(MKDIR) with @NMD@; this was missed
22588         in a previous pass.
22590         maint: omit unnecessary ‘rm -f $@-t $@’
22591         * modules/alloca-opt, modules/argz, modules/arpa_inet:
22592         * modules/assert-h, modules/byteswap, modules/configmake:
22593         * modules/ctype, modules/dirent, modules/dynarray, modules/errno:
22594         * modules/execinfo, modules/fcntl-h, modules/float:
22595         * modules/fnmatch-h, modules/getopt-posix, modules/glob-h:
22596         * modules/iconv-h, modules/ieee754-h, modules/inttypes-incomplete:
22597         * modules/langinfo, modules/libtextstyle-optional:
22598         * modules/limits-h, modules/langinfo, modules/libgmp, modules/limits-h:
22599         * modules/locale, modules/malloc-h, modules/math, modules/monetary:
22600         * modules/net_if, modules/netdb, modules/netinet_in:
22601         * modules/openmp-init, modules/poll-h, modules/posix-shell:
22602         * modules/posix_spawnp-tests, modules/pthread-h, modules/pty:
22603         * modules/sched, modules/scratch_buffer, modules/search:
22604         * modules/selinux-h, modules/signal-h, modules/sigsegv:
22605         * modules/snippet/link-warning, modules/spawn, modules/stdalign:
22606         * modules/stdarg, modules/stdbool, modules/stddef, modules/stdint:
22607         * modules/stdio, modules/stdlib, modules/stdnoreturn:
22608         * modules/string, modules/strings, modules/sys_file:
22609         * modules/sys_ioctl, modules/sys_random, modules/sys_resource:
22610         * modules/sys_select, modules/sys_socket, modules/sys_stat:
22611         * modules/sys_time, modules/sys_times, modules/sys_types:
22612         * modules/sys_uio, modules/sys_utsname, modules/sys_wait:
22613         * modules/sysexits, modules/termios, modules/threads-h:
22614         * modules/time, modules/uchar, modules/unicase/base:
22615         * modules/unicase/special-casing, modules/uniconv/base:
22616         * modules/unictype/base, modules/unigbrk/base, modules/unilbrk/base:
22617         * modules/uniname/base, modules/uninorm/base, modules/unistd:
22618         * modules/unistdio/base, modules/unistr/base, modules/unitypes:
22619         * modules/uniwbrk/base, modules/uniwidth/base, modules/utime-h:
22620         * modules/wchar, modules/wctype-h:
22621         Don’t bother to do a ‘rm -f $@-t $@’ at the start of recipes that
22622         create .h and similar files.  This is a revenant of a style in
22623         which the files were created read-only.  Also, consistently use
22624         use plain ‘mv $@-t $@’ afterwards, instead of usually using
22625         ‘mv -f’ but sometimes plain ‘mv’.
22627 2021-12-21  Paul Eggert  <eggert@cs.ucla.edu>
22629         maint: fix __clang_major__ misspellings
22630         The intprops.h typo fix should fix a bug in Emacs on Debian testing
22631         with clang <https://bugs.gnu.org/52711>.
22632         * lib/asyncsafe-spin.c, lib/intprops.h, lib/pthread-spin.c:
22633         Fix some misspellings of ‘__clang_major__’.
22634         I left one misspelling alone, in lib/cdefs.h,
22635         and instead reported that bug upstream here:
22636         https://sourceware.org/pipermail/libc-alpha/2021-December/134512.html
22638 2021-12-21  Bruno Haible  <bruno@clisp.org>
22640         get_ppid_of, get_progname_of: Fix runtime error on Mac OS X < 10.5.
22641         Reported by Evan Miller <emmiller@gmail.com>
22642         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00081.html>.
22643         * lib/get_ppid_of.c (proc_pidinfo): Declare with WEAK_IMPORT_ATTRIBUTE.
22644         (get_ppid_of): Test whether the symbol declared weak evaluates to
22645         non-NULL before invoking it.
22646         * lib/get_progname_of (proc_pidinfo): Declare with
22647         WEAK_IMPORT_ATTRIBUTE.
22648         (get_progname_of): Test whether the symbol declared weak evaluates to
22649         non-NULL before invoking it.
22651 2021-12-21  Paul Eggert  <eggert@cs.ucla.edu>
22653         Move AM_V_GEN to recipe start
22654         This is especially needed when building Emacs, as it uses
22655         ‘AM_V_GEN=@$(info GEN $@)', which means the GEN line is output by
22656         GNU make just before the recipe runs, regardless of where AM_V_GEN
22657         appears in the recipe.  And it’s also good practice even if the
22658         default Automake ‘AM_V_GEN=@echo GEN $@;’ is used, as it’s better
22659         to output the GEN line consistently at the start of every recipe,
22660         even if this precedes a preparatory command that almost always
22661         works silently.
22662         * modules/arpa_inet, modules/dynarray, modules/net_if:
22663         * modules/netinet_in, modules/scratch_buffer, modules/selinux-h:
22664         * modules/sys_file, modules/sys_ioctl, modules/sys_random:
22665         * modules/sys_resource, modules/sys_select, modules/sys_socket:
22666         * modules/sys_stat, modules/sys_time, modules/sys_times:
22667         * modules/sys_types, modules/sys_uio, modules/sys_utsname:
22668         * modules/sys_wait, modules/unicase/special-casing, top/maint.mk:
22669         Use AM_V_GEN only at the start of each recipe.
22671 2021-12-21  Bruno Haible  <bruno@clisp.org>
22673         c-xvasprintf: Fix declarations (regression 2021-08-07).
22674         * lib/c-xvasprintf.h (c_xasprintf, c_xvasprintf): Remove
22675         _GL_ATTRIBUTE_RETURNS_NONNULL attribute.
22677 2021-12-21  Bruno Haible  <bruno@clisp.org>
22679         snippet/warn-on-use: Fix compilation error in C++ mode on OpenBSD 7.0.
22680         * lib/warn-on-use.h (_GL_WARN_ON_USE): In C++ mode, declare function
22681         with "C" linkage.
22683 2021-12-21  Bruno Haible  <bruno@clisp.org>
22685         Optimize redundant 'mkdir -p .' invocations.
22686         Reported by Paul Eggert.
22687         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
22688         Eliminate @NMD@ tokens.
22689         * modules/alloca-opt (Makefile.am): Prefix the "$(MKDIR_P) '%reldir%'"
22690         line with @NMD@.
22691         * modules/argz (Makefile.am): Likewise.
22692         * modules/assert-h (Makefile.am): Likewise.
22693         * modules/byteswap (Makefile.am): Likewise.
22694         * modules/configmake (Makefile.am): Likewise.
22695         * modules/ctype (Makefile.am): Likewise.
22696         * modules/dirent (Makefile.am): Likewise.
22697         * modules/errno (Makefile.am): Likewise.
22698         * modules/execinfo (Makefile.am): Likewise.
22699         * modules/fcntl-h (Makefile.am): Likewise.
22700         * modules/float (Makefile.am): Likewise.
22701         * modules/fnmatch-h (Makefile.am): Likewise.
22702         * modules/getopt-posix (Makefile.am): Likewise.
22703         * modules/glob-h (Makefile.am): Likewise.
22704         * modules/iconv-h (Makefile.am): Likewise.
22705         * modules/ieee754-h (Makefile.am): Likewise.
22706         * modules/inttypes-incomplete (Makefile.am): Likewise.
22707         * modules/langinfo (Makefile.am): Likewise.
22708         * modules/libtextstyle-optional (Makefile.am): Likewise.
22709         * modules/limits-h (Makefile.am): Likewise.
22710         * modules/locale (Makefile.am): Likewise.
22711         * modules/malloc-h (Makefile.am): Likewise.
22712         * modules/math (Makefile.am): Likewise.
22713         * modules/monetary (Makefile.am): Likewise.
22714         * modules/netdb (Makefile.am): Likewise.
22715         * modules/openmp-init (Makefile.am): Likewise.
22716         * modules/poll-h (Makefile.am): Likewise.
22717         * modules/posix-shell (Makefile.am): Likewise.
22718         * modules/pthread-h (Makefile.am): Likewise.
22719         * modules/pty (Makefile.am): Likewise.
22720         * modules/sched (Makefile.am): Likewise.
22721         * modules/search (Makefile.am): Likewise.
22722         * modules/signal-h (Makefile.am): Likewise.
22723         * modules/sigsegv (Makefile.am): Likewise.
22724         * modules/snippet/link-warning (Makefile.am): Likewise.
22725         * modules/spawn (Makefile.am): Likewise.
22726         * modules/stdalign (Makefile.am): Likewise.
22727         * modules/stdarg (Makefile.am): Likewise.
22728         * modules/stdbool (Makefile.am): Likewise.
22729         * modules/stddef (Makefile.am): Likewise.
22730         * modules/stdint (Makefile.am): Likewise.
22731         * modules/stdio (Makefile.am): Likewise.
22732         * modules/stdlib (Makefile.am): Likewise.
22733         * modules/stdnoreturn (Makefile.am): Likewise.
22734         * modules/string (Makefile.am): Likewise.
22735         * modules/strings (Makefile.am): Likewise.
22736         * modules/sysexits (Makefile.am): Likewise.
22737         * modules/termios (Makefile.am): Likewise.
22738         * modules/threads-h (Makefile.am): Likewise.
22739         * modules/time (Makefile.am): Likewise.
22740         * modules/uchar (Makefile.am): Likewise.
22741         * modules/unicase/base (Makefile.am): Likewise.
22742         * modules/uniconv/base (Makefile.am): Likewise.
22743         * modules/unictype/base (Makefile.am): Likewise.
22744         * modules/unigbrk/base (Makefile.am): Likewise.
22745         * modules/unilbrk/base (Makefile.am): Likewise.
22746         * modules/uniname/base (Makefile.am): Likewise.
22747         * modules/uninorm/base (Makefile.am): Likewise.
22748         * modules/unistd (Makefile.am): Likewise.
22749         * modules/unistdio/base (Makefile.am): Likewise.
22750         * modules/unistr/base (Makefile.am): Likewise.
22751         * modules/unitypes (Makefile.am): Likewise.
22752         * modules/uniwbrk/base (Makefile.am): Likewise.
22753         * modules/uniwidth/base (Makefile.am): Likewise.
22754         * modules/utime-h (Makefile.am): Likewise.
22755         * modules/wchar (Makefile.am): Likewise.
22756         * modules/wctype-h (Makefile.am): Likewise.
22758 2021-12-19  Bruno Haible  <bruno@clisp.org>
22760         non-recursive-gnulib-prefix-hack: Deprecate module.
22761         * modules/non-recursive-gnulib-prefix-hack (Status, Notice): New
22762         sections.
22764 2021-12-19  Bruno Haible  <bruno@clisp.org>
22766         gnulib-tool: Don't insist on ACLOCAL_AMFLAGS.
22767         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
22768         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00112.html>.
22769         * gnulib-tool (func_import): Mention an AC_CONFIG_MACRO_DIRS invocation
22770         as an alternative to augmenting ACLOCAL_AMFLAGS.
22771         (--import, --add-import, --remove-import, --update): To find the m4
22772         directories, look also for AC_CONFIG_MACRO_DIR and AC_CONFIG_MACRO_DIRS
22773         invocations in configure.ac.
22775 2021-12-18  Bruno Haible  <bruno@clisp.org>
22777         nstrftime: Update meta info.
22778         * config/srclist.txt: Fix typo from 2017-07-23.
22780 2021-12-18  Bruno Haible  <bruno@clisp.org>
22782         stdint: Fix handling of limits.h (regression 2021-12-16).
22783         * modules/stdint (configure.ac): Revert last change.
22784         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
22785         If --gnu-make is used, assume that AC_SUBSTed variables for conditionals
22786         are constructed by appending the suffix '_CONDITION'.
22788 2021-12-18  Paul Eggert  <eggert@cs.ucla.edu>
22790         nstrftime: simplify by using libc-config.h.
22791         * lib/nstrftime.c [!_LIBC]: Include libc-config.h
22792         instead of config.h.
22793         (iso_week_days): Simplify via libc-config.h’s __inline.
22794         (my_strftime): Simplify via libc-config.h’s libc_hidden_def.
22795         * modules/nstrftime (Depends-on): Add libc-config.
22797 2021-12-18  Bruno Haible  <bruno@clisp.org>
22799         libtextstyle-optional: Fix generation of textstyle.h (regr. 2021-12-15).
22800         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Invoke
22801         gl_CONDITIONAL_HEADER.
22803 2021-12-18  Bruno Haible  <bruno@clisp.org>
22805         Fix support for --gnu-make in tests (regression 2021-12-15).
22806         * gnulib-tool (func_emit_tests_Makefile_am): When producing output for
22807         GNU make, eliminate %reldir% tokens.
22809 2021-12-17  Bruno Haible  <bruno@clisp.org>
22811         getopt-posix: Fix build on AIX (regression 2021-12-15).
22812         * modules/getopt-posix (configure.ac): Arrange to generate
22813         getopt-cdefs.h.
22814         (Makefile.am): Separate the rules for getopt.h and getopt-cdefs.h.
22816 2021-12-16  Paul Eggert  <eggert@cs.ucla.edu>
22818         getopt-posix: omit unnessary building of getopt.h
22819         * modules/getopt-posix (getopt.h, getopt-cdefs.h):
22820         Build only if GL_GENERATE_GETOPT_H.
22822         stdint: omit duplicate gl_CONFIGURE_HEADER calls
22823         * modules/stdint (configure.ac): Omit
22824         ‘gl_CONDITIONAL_HEADER([limits.h])’, since stdint depends on
22825         limits-h and doing gl_CONDITIONAL_HEADER twice can result in
22826         ‘configure’ failing with “*** GL_GENERATE_LIMITS_H is not set
22827         correctly”.
22829 2021-12-15  Bruno Haible  <bruno@clisp.org>
22831         automake-subdir support: Support the libunistring modules.
22832         * m4/libunistring-base.m4 (gl_LIBUNISTRING_LIBHEADER): Use the value of
22833         the gl_source_base_prefix variable.
22835 2021-12-15  Bruno Haible  <bruno@clisp.org>
22837         automake-subdir support: Support arbitrary --source-base value.
22838         Reported by Marc Nieper-Wißkirchen in
22839         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00066.html>.
22840         * build-aux/prefix-gnulib-mk ($canon_prefix): New variable.
22841         (prefix): Initialize it.
22842         (prefix_assignment): Use it.
22844 2021-12-15  Bruno Haible  <bruno@clisp.org>
22846         automake-subdir support: Look for 'subdir-objects' also in configure.ac.
22847         * gnulib-tool: Look for the automake options also in the first argument
22848         of the AM_INIT_AUTOMAKE invocation in configure.ac.
22850 2021-12-15  Bruno Haible  <bruno@clisp.org>
22852         Add simple examples.
22853         * examples: New directory.
22855 2021-12-15  Bruno Haible  <bruno@clisp.org>
22857         Accommodate non-recursive Automake in a less hacky way.
22858         * gnulib-tool: New option --automake-subdir.
22859         (automake_subdir): New variable.
22860         (func_emit_initmacro_end): Add a second argument. Use it to prefix each
22861         object file name in *_LIBOBJS and *_LTLIBOBJS.
22862         (func_emit_shellvars_init): New function.
22863         (func_import): Add support for --automake-subdir. Invoke
22864         prefix-gnulib-mk. Update calls to func_emit_initmacro_end. Call
22865         func_emit_shellvars_init.
22866         (func_create_testdir): Update calls to func_emit_initmacro_end. Call
22867         func_emit_shellvars_init.
22868         * m4/gnulib-tool.m4 (gl_AUTOMAKE_SUBDIR): New macro.
22869         * m4/gnulib-common.m4 (gl_CONDITIONAL_HEADER): Use the value of the
22870         gl_source_base_prefix variable.
22871         * build-aux/prefix-gnulib-mk: New options --from-gnulib-tool, --prefix.
22872         (contents_of_file): Renamed from contents.
22873         (contents_of_stdin): New function.
22874         (process): Inline and remove function.
22875         * doc/gnulib-tool.texi (Non-recursive make): New section.
22877 2021-12-15  Bruno Haible  <bruno@clisp.org>
22879         Move .h file names out of the *.m4 files.
22880         This is useful because Autoconf macros defined in *.m4 files can be
22881         AC_REQUIREd. In the configure file, they are then expanded before
22882         gl_INIT, i.e. at a place where it is not known whether they are required
22883         for the lib/ or for the tests/ directory (or both).
22884         * m4/gnulib-common.m4 (gl_CONDITIONAL_HEADER): New macro.
22885         * m4/alloca.m4 (gl_FUNC_ALLOCA): Set GL_GENERATE_ALLOCA_H instead of
22886         ALLOCA_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22887         * modules/alloca-opt (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22888         * m4/argz.m4 (gl_FUNC_ARGZ): Set GL_GENERATE_ARGZ_H instead of ARGZ_H.
22889         Drop AC_SUBST and AM_CONDITIONAL invocations.
22890         * modules/argz (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22891         * m4/assert_h.m4 (gl_ASSERT_H): Set GL_GENERATE_ASSERT_H instead of
22892         ASSERT_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22893         * modules/assert-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22894         * m4/byteswap.m4 (gl_BYTESWAP): Set GL_GENERATE_BYTESWAP_H instead of
22895         BYTESWAP_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22896         * modules/byteswap (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22897         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Set GL_GENERATE_ERRNO_H instead of
22898         ERRNO_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22899         (gl_REPLACE_ERRNO_VALUE): Update.
22900         * m4/perror.m4 (gl_FUNC_PERROR): Update.
22901         * m4/strerror.m4 (gl_FUNC_STRERROR): Update.
22902         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R, gl_FUNC_STRERROR_R_WORKS):
22903         Update.
22904         * modules/errno (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22905         * m4/execinfo.m4 (gl_EXECINFO_H): Set GL_GENERATE_EXECINFO_H instead of
22906         EXECINFO_H. Drop AC_SUBST and AM_CONDITIONAL invocations. Drop AC_LIBOBJ
22907         invocation.
22908         * modules/execinfo (configure.ac): Invoke gl_CONDITIONAL_HEADER and
22909         AC_LIBOBJ.
22910         * m4/float_h.m4 (gl_FLOAT_H): Set GL_GENERATE_FLOAT_H instead of
22911         FLOAT_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22912         * modules/float (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22913         * m4/fnmatch_h.m4 (gl_FNMATCH_H, gl_REPLACE_FNMATCH_H): Set
22914         GL_GENERATE_FNMATCH_H instead of FNMATCH_H. Drop AC_SUBST and
22915         AM_CONDITIONAL invocations.
22916         * modules/fnmatch-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22917         * modules/fnmatch (configure.ac): Likewise.
22918         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX, gl_GETOPT_SUBSTITUTE_HEADER): Set
22919         GL_GENERATE_GETOPT_H instead of GETOPT_H. Set GL_GENERATE_GETOPT_CDEFS_H
22920         instead of GETOPT_CDEFS_H. Drop AC_SUBST invocations.
22921         * modules/getopt-posix (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22922         * m4/glob_h.m4 (gl_GLOB_H, gl_REPLACE_GLOB_H): Set GL_GENERATE_GLOB_H
22923         instead of GLOB_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22924         * modules/glob-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22925         * modules/glob (configure.ac): Likewise.
22926         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS, gl_REPLACE_ICONV_H): Set
22927         GL_GENERATE_ICONV_H instead of ICONV_H. Drop AC_SUBST and AM_CONDITIONAL
22928         invocations.
22929         (gl_ICONV_H): Update.
22930         * modules/iconv-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22931         * modules/iconv_open (configure.ac): Likewise.
22932         * m4/ieee754-h.m4 (gl_IEEE754_H): Set GL_GENERATE_IEEE754_H instead of
22933         IEEE754_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22934         * modules/ieee754-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22935         * m4/libgmp.m4 (gl_LIBGMP): Set GL_GENERATE_GMP_H instead of GMP_H. Drop
22936         AC_SUBST invocation.
22937         * modules/libgmp (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22938         (Makefile.am): Use GL_GENERATE_GMP_H.
22939         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Set
22940         GL_GENERATE_TEXTSTYLE_H instead of TEXTSTYLE_H. Drop AC_SUBST and
22941         AM_CONDITIONAL invocations.
22942         * modules/libtextstyle-optional (configure.ac): Invoke
22943         gl_CONDITIONAL_HEADER.
22944         * m4/limits-h.m4 (gl_LIMITS_H, gl_REPLACE_LIMITS_H): Set
22945         GL_GENERATE_LIMITS_H instead of LIMITS_H. Drop AC_SUBST and
22946         AM_CONDITIONAL invocations.
22947         * modules/limits-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22948         * m4/monetary_h.m4 (gl_MONETARY_H): Set GL_GENERATE_MONETARY_H instead
22949         of MONETARY_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22950         * modules/monetary (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22951         * m4/net_if_h.m4 (gl_HEADER_NET_IF): Set GL_GENERATE_NET_IF_H instead of
22952         NET_IF_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22953         * modules/net_if (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22954         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Set
22955         GL_GENERATE_NETINET_IN_H instead of NETINET_IN_H. Drop AC_SUBST and
22956         AM_CONDITIONAL invocations.
22957         * modules/netinet_in (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22958         * m4/selinux-context-h.m4 (gl_HEADERS_SELINUX_CONTEXT_H): Set
22959         GL_GENERATE_SELINUX_CONTEXT_H instead of SELINUX_CONTEXT_H. Drop
22960         AC_SUBST and AM_CONDITIONAL invocations.
22961         * m4/selinux-label-h.m4 (gl_HEADERS_SELINUX_LABEL_H): Set
22962         GL_GENERATE_SELINUX_LABEL_H instead of SELINUX_LABEL_H. Drop AC_SUBST
22963         and AM_CONDITIONAL invocations.
22964         * modules/selinux-h (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22965         * m4/stdalign.m4 (gl_STDALIGN_H): Set GL_GENERATE_STDALIGN_H instead of
22966         STDALIGN_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22967         * modules/stdalign (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22968         * m4/stdarg.m4 (gl_STDARG_H): Set GL_GENERATE_STDARG_H instead of
22969         STDARG_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22970         * modules/stdarg (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22971         * m4/stdbool.m4 (gl_STDBOOL_H): Renamed from AM_STDBOOL_H. Set
22972         GL_GENERATE_STDBOOL_H instead of STDBOOL_H. Drop AC_SUBST and
22973         AM_CONDITIONAL invocations.
22974         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Don't require AM_STDBOOL_H.
22975         * modules/stdbool (configure.ac): Invoke gl_STDBOOL_H instead of
22976         AM_STDBOOL_H. Invoke gl_CONDITIONAL_HEADER.
22977         * m4/stddef_h.m4 (gl_STDDEF_H): Set GL_GENERATE_STDDEF_H instead of
22978         STDDEF_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22979         * modules/stddef (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22980         * m4/stdint.m4 (gl_STDINT_H): Set GL_GENERATE_STDINT_H instead of
22981         STDINT_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22982         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): Update.
22983         * modules/stdint (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22984         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): Set GL_GENERATE_STDNORETURN_H
22985         instead of STDNORETURN_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22986         * modules/stdnoreturn (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22987         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H): Set GL_GENERATE_SYS_SOCKET_H
22988         instead of SYS_SOCKET_H.
22989         * m4/sysexits.m4 (gl_SYSEXITS): Set GL_GENERATE_SYSEXITS_H instead of
22990         SYSEXITS_H. Drop AC_SUBST and AM_CONDITIONAL invocations.
22991         * modules/sysexits (configure.ac): Invoke gl_CONDITIONAL_HEADER.
22992         * modules/sigsegv (configure.ac): Set GL_GENERATE_SIGSEGV_H instead of
22993         SIGSEGV_H. Drop AC_SUBST and AM_CONDITIONAL invocations. Invoke
22994         gl_CONDITIONAL_HEADER.
22996 2021-12-15  Bruno Haible  <bruno@clisp.org>
22998         Fix creation of build directories with non-recursive-gnulib-prefix-hack.
22999         This is necessary for executing "make" in a VPATH build of a package
23000         that uses prefix-gnulib-mk and a module such as alloca-opt.
23001         * modules/alloca-opt (Makefile.am): Before generating the .h-t file,
23002         ensure that the directory in which we want to create it exists.
23003         (configure.ac): Invoke AC_PROG_MKDIR_P.
23004         * modules/argz: Likewise.
23005         * modules/arpa_inet: Likewise.
23006         * modules/assert-h: Likewise.
23007         * modules/byteswap: Likewise.
23008         * modules/configmake: Likewise.
23009         * modules/ctype: Likewise.
23010         * modules/dirent: Likewise.
23011         * modules/dynarray: Likewise.
23012         * modules/errno: Likewise.
23013         * modules/execinfo: Likewise.
23014         * modules/fcntl-h: Likewise.
23015         * modules/float: Likewise.
23016         * modules/fnmatch-h: Likewise.
23017         * modules/getopt-posix: Likewise.
23018         * modules/glob-h: Likewise.
23019         * modules/iconv-h: Likewise.
23020         * modules/ieee754-h: Likewise.
23021         * modules/inttypes-incomplete: Likewise.
23022         * modules/langinfo: Likewise.
23023         * modules/libgmp: Likewise.
23024         * modules/libtextstyle-optional: Likewise.
23025         * modules/limits-h: Likewise.
23026         * modules/locale: Likewise.
23027         * modules/malloc-h: Likewise.
23028         * modules/math: Likewise.
23029         * modules/monetary: Likewise.
23030         * modules/net_if: Likewise.
23031         * modules/netdb: Likewise.
23032         * modules/netinet_in: Likewise.
23033         * modules/openmp-init: Likewise.
23034         * modules/poll-h: Likewise.
23035         * modules/posix-shell: Likewise.
23036         * modules/pthread-h: Likewise.
23037         * modules/pty: Likewise.
23038         * modules/sched: Likewise.
23039         * modules/scratch_buffer: Likewise.
23040         * modules/search: Likewise.
23041         * modules/selinux-h: Likewise.
23042         * modules/signal-h: Likewise.
23043         * modules/sigsegv: Likewise.
23044         * modules/snippet/link-warning: Likewise.
23045         * modules/spawn: Likewise.
23046         * modules/stdalign: Likewise.
23047         * modules/stdarg: Likewise.
23048         * modules/stdbool: Likewise.
23049         * modules/stddef: Likewise.
23050         * modules/stdint: Likewise.
23051         * modules/stdio: Likewise.
23052         * modules/stdlib: Likewise.
23053         * modules/stdnoreturn: Likewise.
23054         * modules/string: Likewise.
23055         * modules/strings: Likewise.
23056         * modules/sys_file: Likewise.
23057         * modules/sys_ioctl: Likewise.
23058         * modules/sys_random: Likewise.
23059         * modules/sys_resource: Likewise.
23060         * modules/sys_select: Likewise.
23061         * modules/sys_socket: Likewise.
23062         * modules/sys_stat: Likewise.
23063         * modules/sys_time: Likewise.
23064         * modules/sys_times: Likewise.
23065         * modules/sys_types: Likewise.
23066         * modules/sys_uio: Likewise.
23067         * modules/sys_utsname: Likewise.
23068         * modules/sys_wait: Likewise.
23069         * modules/sysexits: Likewise.
23070         * modules/termios: Likewise.
23071         * modules/threads-h: Likewise.
23072         * modules/time: Likewise.
23073         * modules/uchar: Likewise.
23074         * modules/unicase/base: Likewise.
23075         * modules/unicase/special-casing: Likewise.
23076         * modules/uniconv/base: Likewise.
23077         * modules/unictype/base: Likewise.
23078         * modules/unigbrk/base: Likewise.
23079         * modules/unilbrk/base: Likewise.
23080         * modules/uniname/base: Likewise.
23081         * modules/uninorm/base: Likewise.
23082         * modules/unistd: Likewise.
23083         * modules/unistdio/base: Likewise.
23084         * modules/unistr/base: Likewise.
23085         * modules/unitypes: Likewise.
23086         * modules/uniwbrk/base: Likewise.
23087         * modules/uniwidth/base: Likewise.
23088         * modules/utime-h: Likewise.
23089         * modules/wchar: Likewise.
23090         * modules/wctype-h: Likewise.
23091         * gnulib-tool (func_emit_lib_Makefile_am): When producing output for
23092         GNU make, eliminate %reldir% tokens.
23094 2021-12-15  Bruno Haible  <bruno@clisp.org>
23096         non-recursive-gnulib-prefix-hack: Remove obsolete code.
23097         * build-aux/prefix-gnulib-mk (prefix): Remove handling of t-$@ pattern.
23099 2021-12-15  Bruno Haible  <bruno@clisp.org>
23101         Indentation fix.
23102         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Correct indentation.
23104 2021-12-14  Paul Eggert  <eggert@cs.ucla.edu>
23106         renameatu: port to macOS tmpfs
23107         Problem reported by Sudhip Nashi (Bug#52193).
23108         * lib/renameatu.c (renameat2ish) [HAVE_RENAMEAT]: New function.
23109         (renameatu): Use the new function, to avoid a bug when
23110         renameatx_np fails with errno == ENOTSUP.  Don’t try to support
23111         RENAME_EXCHANGE; the old code didn’t work and nobody using using
23112         RENAME_EXCHANGE anyway.
23114 2021-12-12  Bruno Haible  <bruno@clisp.org>
23116         gnulib-tool: Try to support non-recursive-gnulib-prefix-hack with tests.
23117         * gnulib-tool (func_import): Synthesize an AC_CONFIG_LIBOBJ_DIR
23118         invocation.
23119         * m4/non-recursive-gnulib-prefix-hack.m4
23120         (gl_NON_RECURSIVE_GNULIB_PREFIX_HACK): Don't invoke
23121         AC_CONFIG_LIBOBJ_DIR.
23123 2021-12-12  Paul Eggert  <eggert@cs.ucla.edu>
23125         bootstrap: refactor for GNU tar
23126         * build-aux/bootstrap (gitignore_entries, insert_if_absent)
23127         (insert_vc_ignore, symlink_to_dir): Define these shell functions
23128         before including bootstrap.conf.  This is for GNU tar, whose
23129         bootstrap.conf uses symlink_to_dir.
23131 2021-12-12  Bruno Haible  <bruno@clisp.org>
23133         gnulib-tool: Support different basenames for the lib/,tests/ Makefiles.
23134         * gnulib-tool: New option --tests-makefile-name.
23135         (tests_makefile_name): New variable.
23136         (func_import): Add support for --tests-makefile-name. Replace local
23137         variable makefile_am with two local variables source_makefile_am,
23138         tests_makefile_am.
23139         * m4/gnulib-tool.m4 (gl_TESTS_MAKEFILE_NAME): New macro.
23141 2021-12-11  Bruno Haible  <bruno@clisp.org>
23143         get_ppid_of, get_progname_of: Fix compilation error on Mac OS X < 10.5.
23144         Reported by Ryan Schmidt <gnulib@ryandesign.com> in
23145         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00011.html>.
23146         * lib/get_ppid_of.c: Include AvailabilityMacros.h
23147         (get_ppid_of): Use MAC_OS_X_VERSION_MAX_ALLOWED and
23148         MAC_OS_X_VERSION_MIN_REQUIRED.
23149         * lib/get_progname_of: Include AvailabilityMacros.h
23150         (get_progname_of): Use MAC_OS_X_VERSION_MAX_ALLOWED and
23151         MAC_OS_X_VERSION_MIN_REQUIRED.
23153 2021-12-10  Paul Eggert  <eggert@cs.ucla.edu>
23155         backupfile: assume C99 decls
23156         * lib/backupfile.c: Use C99-style decls after statements.
23158         backupfile: prefer signed integers
23159         * lib/backupfile.c: Include ialloc.h instead of idx.h.
23160         Prefer idx_t to size_t where either will do.
23161         Use imalloc and irealloc instead of malloc and realloc.
23163         * modules/backupfile, modules/backup-rename (Depends-on):
23164         Depend on ialloc not idx.
23166         backupfile: fix numbered backups for XXX/
23167         * lib/backupfile.c (check_extension): Return a bool indicating
23168         whether the original extension was OK.  Caller changed.
23169         (numbered_backup): Require that FILELEN does not count
23170         trailing slashes after a non-slash, and don’t require
23171         that *BUF be null-terminated.  Caller changed.
23172         This fixes a bug where the numbered backup file name for X/ was
23173         incorrectly computed because the slash messed up the code
23174         looking for X.~1~, X.~2~, etc., and this caused numbered_backup
23175         to loop forever.  Also, check that check_extension doesn’t
23176         truncate a file name leading to an infloop.
23178 2021-12-07  Paul Eggert  <eggert@cs.ucla.edu>
23180         regex: pacify Coverity clean_state_log_if_needed
23181         Problem reported by Robbie Harwood in:
23182         https://lists.gnu.org/r/bug-gnulib/2021-12/msg00005.html
23183         * lib/regexec.c (clean_state_log_if_needed):
23184         Add a DEBUG_ASSERT; this both pacifies Coverity and
23185         will help to debug in case some other change mistakenly
23186         causes the assertion to become false.
23188 2021-12-07  Bruno Haible  <bruno@clisp.org>
23190         gettext-h: Optimize also for clang.
23191         * lib/gettext.h (pgettext_aux, npgettext_aux, dcpgettext_expr,
23192         dcnpgettext_expr): Inline also on clang.
23194 2021-12-06  Bruno Haible  <bruno@clisp.org>
23196         intprops: Break sync with glibc.
23197         * config/srclist.txt: Comment out intprops.h.
23199 2021-12-06  Paul Eggert  <eggert@cs.ucla.edu>
23201         intprops: streamline and get ready for Clang 14
23202         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW):
23203         Rely on __has_builtin first, since GCC didn’t introduce it until
23204         GCC 9 so we don’t need to special-case GCC first.
23205         (_GL_HAS_BUILTIN_ADD_OVERFLOW, _GL_HAS_BUILTIN_OVERFLOW_P):
23206         Look at __EDG__ rather than __ICC, since icc defines __EDG__ too.
23207         (_GL_HAS_BUILTIN_MUL_OVERFLOW): Define to 1 in Clang 14 and later,
23208         as a bug fix is scheduled for Clang 14.
23209         (_GL_HAS_BUILTIN_OVERFLOW_P): Do not bother to special-case
23210         __clang__, since __has_builtin should do the right thing anyway.
23212 2021-12-06  Bruno Haible  <bruno@clisp.org>
23214         intprops: Treat EDG-based compilers like Intel compilers.
23215         Reported by Ilya Kurdyukov <ilyakurdyukov@altlinux.org> in
23216         <https://lists.gnu.org/archive/html/bug-gnulib/2021-12/msg00028.html>.
23217         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P): Define to 0 on EDG-based
23218         compilers.
23220 2021-12-05  Bruno Haible  <bruno@clisp.org>
23222         sigsegv: Fix build on some more embedded CPUs.
23223         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Assume the stack grows
23224         negative, when the GCC 11 sources say so.
23226 2021-11-30  Paul Eggert  <eggert@cs.ucla.edu>
23228         sys_random: port better to uClibc < 1.0.35
23229         Problem reported by Fabrice Fontaine in:
23230         https://lists.gnu.org/r/bug-gnulib/2021-11/msg00043.html
23231         * lib/sys_random.in.h [HAVE_SYS_RANDOM_H && !__GLIBC__ && __UCLIBC__]:
23232         Include <stddef.h>, in case this file is included before
23233         __UCLIBC__ is defined.
23235 2021-11-27  Paul Eggert  <eggert@cs.ucla.edu>
23237         gettext-h: document GNULIB_NO_VLA
23238         * doc/gnulib-readme.texi (C99 features avoided):
23239         Document GNULIB_NO_VLA.
23241         gettext-h: use VLA test similar to regex
23242         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Assuming
23243         GNULIB_NO_VLA, define if (defined __STDC_VERSION__ && 199901L <=
23244         __STDC_VERSION__ \ + && !defined __STDC_NO_VLA___), not if
23245         ((__GNUC__ >= 3 || __GNUG__ >= 2) && !defined __STRICT_ANSI__).
23246         This is more consistent with what the regex module does.
23247         * modules/gettext-h (Depends-on): Depend on vararrays, since
23248         lib/gettext.h uses __STDC_NO_VLA__.
23250         regex: port to tcc
23251         Problem reported by Benno Schulenberg in:
23252         https://lists.gnu.org/r/bug-gnulib/2021-11/msg00038.html
23253         * modules/regex (Depends-on): Depend on vararrays, since
23254         lib/regex.h uses __STDC_NO_VLA__.
23255         * modules/vararrays: Change license from LGPL to LGPLv2+.
23257 2021-11-25  Bernhard Voelker  <mail@bernhard-voelker.de>
23259         test-framework-sh: remove unsafe entries from PATH
23260         Running tests with '.' in the PATH may yield unspecified results,
23261         and is deemed unsafe per se.  This includes empty entries as well
23262         which are treated like a '.' entry as per POSIX.
23263         * tests/init.sh (setup_): Add snippet to remove relative and non-
23264         accessible entries from the PATH environment variable.
23266 2021-11-24  Paul Eggert  <eggert@cs.ucla.edu>
23268         regex: merge from glibc
23269         The main change here, imported from Glibc, is for the regex
23270         code to stop using nested functions when _LIBC is defined.
23271         The intent is for the result to be copied back to Glibc
23272         so that the two implementations can resync.
23273         * lib/regcomp.c (re_set_fastmap, seek_collating_symbol_entry)
23274         (lookup_collation_sequence_value, build_range_exp)
23275         (build_collating_symbol):
23276         * lib/regexec.c (acquire_init_state_context):
23277         Declare with __always_inline instead of with
23278         ‘inline __attribute__ ((always_inline))’.
23279         * lib/regexec.c (init_word_char):
23280         Move uint64_t comment to regex_internal.h.
23281         (parse_byte): Change multibyte-detecting arg from re_charset_t *
23282         to re_dfa_t const *.  All callers changed.
23283         (build_range_exp, build_collating_symbol) [!_LIBC]:
23284         Change signature to match _LIBC well enough so that the caller can
23285         be simplified to assume _LIBC.
23286         (parse_bracket_exp): Pull its nested functions
23287         seek_collating_symbol_entry, lookup_collation_sequence_value,
23288         build_range_exp, build_collating_symbol out to the top level,
23289         adding args to pass the information instead of having them access
23290         nonlocal vars.  Use types in local vars that do not assume glibc.
23291         * lib/regex_internal.h: Explain uint64_t etc. here.
23293 2021-11-23  Paul Eggert  <eggert@cs.ucla.edu>
23295         regex: assume RE_ENABLE_I18N
23296         These days there is no longer any need to port to platforms
23297         lacking iswctype etc., since Gnulib now has substitutes.
23298         * config/srclist.txt: Comment out regex_internal.c and
23299         regex_internal.h for now, since they no longer match glibc.
23300         The intent is to merge them again soon.
23301         * lib/regex_internal.h (RE_ENABLE_I18N): Remove.
23302         All uses changed to assume that RE_ENABLE_I18N is 1.
23303         * modules/regex (Depends-on): Add iswctype.
23305 2021-11-15  Paul Eggert  <eggert@cs.ucla.edu>
23307         lseek: port around macOS SEEK_HOLE glitch
23308         Problem reported by Sudhip Nashi (Bug#51857#47).
23309         * lib/lseek.c (rpl_lseek): Work around macOS lseek+SEEK_HOLE
23310         returning -1 with ENXIO if there are no holes before EOF,
23311         contrary to the macOS documentation.
23313         lseek: port around macOS SEEK_DATA glitch
23314         Problem reported by Sudhip Nashi (Bug#51857).
23315         * doc/posix-functions/lseek.texi (lseek): Mention macOS SEEK_DATA
23316         issue.
23317         * lib/lseek.c (rpl_lseek): Work around macOS portability glitch.
23318         * m4/lseek.m4 (gl_FUNC_LSEEK): Replace lseek on Darwin.
23319         * modules/lseek (Depends-on): Depend on msvc-nothrow
23320         and fstat only if needed.
23322 2021-11-11  Fabrice Fontaine  <fontaine.fabrice@gmail.com>  (tiny change)
23324         sigsegv: fix builds on microblazeel, or1k
23325         * m4/stack-direction.m4 (SV_STACK_DIRECTION):
23326         Assume it grows negative on microblaze* and or1k.
23328 2021-11-09  Paul Eggert  <eggert@cs.ucla.edu>
23330         exclude: yield proper errno on failure
23331         * lib/exclude.c (add_exclude_file): Do not assume that fclose
23332         preserves errno on success.
23334 2021-11-07  Paul Eggert  <eggert@cs.ucla.edu>
23336         regex: break regcomp.c link with glibc
23337         Problem reported by Bruno Haible in:
23338         https://lists.gnu.org/r/bug-gnulib/2021-11/msg00005.html
23339         * config/srclist.txt: Comment out regcomp.c for now.
23340         * lib/regcomp.c: Revert previous change.
23342 2021-10-24  Bruno Haible  <bruno@clisp.org>
23344         string: Avoid syntax error re strdup in string.in.h (regr. 2021-09-07).
23345         Reported by Jan Engelhardt <jengelh@inai.de>
23346         and by Arash Esbati <arash@gnu.org> via Andy Moreton in
23347         <https://lists.gnu.org/archive/html/bug-gnulib/2021-10/msg00058.html>.
23348         * lib/string.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE,
23349         _GL_ATTRIBUTE_MALLOC): Add fallback declarations, like in
23350         lib/stdlib.in.h.
23351         * lib/wchar.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE,
23352         _GL_ATTRIBUTE_MALLOC): Likewise.
23354 2021-10-19  Paul Eggert  <eggert@cs.ucla.edu>
23356         xalloc: new function xinmalloc
23357         * lib/xmalloc.c (xinmalloc): New function, which is like
23358         xnmalloc but for idx_t instead of size_t.
23360 2021-10-18  Paul Eggert  <eggert@cs.ucla.edu>
23362         regex: fix buffer read overrrun
23363         * lib/regexec.c (re_search_internal):
23364         Fix buffer read overrun reported by Benno Schulenberg in:
23365         https://lists.gnu.org/r/bug-gnulib/2021-10/msg00035.html
23367 2021-10-15  Paul Eggert  <eggert@cs.ucla.edu>
23369         nproc: port better to macOS 10.14
23370         * lib/nproc.c (num_processors_ignoring_omp)
23371         [HAVE_SYSCTL && !defined __GLIBC__ && defined HW_NCPU]:
23372         Do not use a const mib, as macOS 10.14 rejects this.
23374 2021-10-13  Paul Eggert  <eggert@cs.ucla.edu>
23376         sigsegv: fix quoting problem
23377         Problem reported for FreeBSD ports by Alexey Dokuchaev in:
23378         https://bugs.gnu.org/51144
23379         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Quote brackets.
23381 2021-10-10  Paul Eggert  <eggert@cs.ucla.edu>
23383         nproc: port better to OpenBSD
23384         Problem reported by Omar Polo in:
23385         https://lists.gnu.org/r/emacs-devel/2021-10/msg00692.html
23386         * lib/nproc.c (num_processors_ignoring_omp): Prefer HW_NCPUONLINE
23387         to HW_NCPU, for OpenBSD.  Also, make mib const.
23389 2021-10-02  Paul Eggert  <eggert@cs.ucla.edu>
23391         timer-time: port better to OpenBSD 6.9
23392         * m4/timer_time.m4 (gl_TIMER_TIME): Also require timer_settime to
23393         be declared, as it exists in OpenBSD but always fails with ENOSYS.
23395         sys_select: port better to OpenBSD 6.9
23396         OpenBSD 6.9’s <sys/time.h> includes <sys/select.h> which then
23397         includes <signal.h>, which caused coreutils/lib/nproc.c compiles
23398         to fail with "/usr/include/signal.h:57: warning: 'struct
23399         sigaction' declared inside parameter list".  Fix this.
23400         * lib/sys_select.in.h [__OpenBSD__]: Simply delegate to the system
23401         header if being included from <sys/time.h>.
23403 2021-09-22  Bruno Haible  <bruno@clisp.org>
23405         doc: Fix outdated statement about Spanish collation.
23406         Reported by Dietmar Schindler in
23407         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00095.html>.
23408         * doc/regex.texi (Collating Elements vs. Characters): Choose another
23409         example of a digraph with special collation.
23411         doc: Don't assume that the output format is TeX-based or info.
23412         Reported by Dietmar Schindler in
23413         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00095.html>.
23414         * doc/regex.texi (Collating Elements vs. Characters): Assume a texinfo
23415         version that groks UTF-8 encoded ISO-8859-1 characters.
23417 2021-09-21  Paul Eggert  <eggert@cs.ucla.edu>
23419         regex: sync with glibc
23420         * config/srclist.txt: Uncomment-out posix/regex.c and related
23421         files, as the Gnulib versions have now been copied to glibc.
23422         * lib/intprops.h: Remove authorship comment, as per glibc guidelines.
23424 2021-09-20  Simon Josefsson  <simon@josefsson.org>
23426         maint: Avoid syntax-check failure for empty gnulib submodule.
23427         * top/maint.mk (gnulib_dir): Fall back to GNULIB_SRCDIR if
23428         submodule is not checked out.
23430 2021-09-19  Bruno Haible  <bruno@clisp.org>
23432         Relicense qemu.h under LGPLv2+.
23433         * tests/qemu.h: Change license header.
23435 2021-09-19  Bruno Haible  <bruno@clisp.org>
23437         ialloc: Update license headers after license change from 2021-08-29.
23438         * lib/ialloc.h: Update license header.
23439         * lib/ialloc.c: Likewise.
23441 2021-09-19  Bruno Haible  <bruno@clisp.org>
23443         Improve 'configure --help' output for crypto modules.
23444         * m4/af_alg.m4 (gl_AF_ALG): List the hash functions for which we use the
23445         Linux crypto. Also mention that we use it on files only.
23446         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Use manual line breaking, not the
23447         line-filling style of AS_HELP_STRING. Show that --with-openssl takes an
23448         optional argument. List the hash functions for which we use the OpenSSL
23449         library. Don't mention --with-linux-crypto if the af_alg module is not
23450         in use. Mention that --with-linux-crypto applies only to the Linux
23451         kernel. Mention that it gets used only when available. Mention that it
23452         takes precedence only for files. In the error or warning, mention the
23453         pre-built package name that people can install.
23455 2021-09-18  Bruno Haible  <bruno@clisp.org>
23457         string, wchar: Don't require undefined m4 macros (regr. today).
23458         Reported by Colin Watson <cjwatson@debian.org> in
23459         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00078.html>.
23460         * m4/string_h.m4 (gl_STRING_H_REQUIRE_DEFAULTS): Don't use m4_require
23461         directly. Instead, invoke gl_STDLIB_H_REQUIRE_DEFAULTS.
23462         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Likewise.
23464 2021-09-18  Bruno Haible  <bruno@clisp.org>
23466         sm3-buffer tests: New module.
23467         * tests/test-sm3-buffer.c: Renamed from tests/test-sm3.c.
23468         * modules/crypto/sm3-buffer-tests: Renamed from
23469         modules/crypto/sm3-tests. Test tests/test-sm3-buffer.c instead of
23470         tests/test-sm3.c.
23472         sm3-buffer: New module.
23473         * lib/sm3-stream.c: New file, extracted from lib/sm3.c.
23474         * lib/sm3.c: Don't include stdlib.h, unlocked-io.h.
23475         (BLOCKSIZE, sm3_stream): Moved to sm3-stream.c.
23476         * lib/sm3.h: Tweak.
23477         * modules/crypto/sm3-buffer: New file, based on modules/crypto/sm3.
23478         * modules/crypto/sm3: Rewritten.
23480 2021-09-18  Bruno Haible  <bruno@clisp.org>
23482         sha512-buffer tests: New module.
23483         * tests/test-sha512-stream.c: Renamed from tests/test-sha512.c.
23484         * modules/crypto/sha512-buffer-tests: New file, based on
23485         modules/crypto/sha512-tests.
23486         * modules/crypto/sha512-tests: Remove tests that are now in
23487         modules/crypto/sha512-buffer-tests. Test tests/test-sha512-stream.c
23488         instead of tests/test-sha512.c.
23490         sha512: Clarify module to source relation.
23491         * lib/sha512-stream.c: New file, extracted from lib/sha512.c.
23492         * lib/sha512.c: Don't include stdlib.h, unlocked-io.h.
23493         (BLOCKSIZE, shaxxx_stream, sha512_stream, sha384_stream): Moved to
23494         sha512-stream.c.
23495         * lib/sha512.h: Tweak.
23496         * modules/crypto/sha512 (Files): Add lib/sha512-stream.c.
23497         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
23498         (Makefile.am): Arrange to compile sha512-stream.c.
23499         (Link): Mention $(LIB_CRYPTO).
23501 2021-09-18  Bruno Haible  <bruno@clisp.org>
23503         sha256-buffer tests: New module.
23504         * tests/test-sha256-stream.c: Renamed from tests/test-sha256.c.
23505         * modules/crypto/sha256-buffer-tests: New file, based on
23506         modules/crypto/sha256-tests.
23507         * modules/crypto/sha256-tests: Remove tests that are now in
23508         modules/crypto/sha256-buffer-tests. Test tests/test-sha256-stream.c
23509         instead of tests/test-sha256.c.
23511         sha256: Clarify module to source relation.
23512         * lib/sha256-stream.c: New file, extracted from lib/sha256.c.
23513         * lib/sha256.c: Don't include stdlib.h, unlocked-io.h.
23514         (BLOCKSIZE, shaxxx_stream, sha256_stream, sha224_stream): Moved to
23515         sha256-stream.c.
23516         * lib/sha256.h: Tweak.
23517         * modules/crypto/sha256 (Files): Add lib/sha256-stream.c.
23518         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
23519         (Makefile.am): Arrange to compile sha256-stream.c.
23520         (Link): Mention $(LIB_CRYPTO).
23522 2021-09-18  Bruno Haible  <bruno@clisp.org>
23524         sha1-buffer tests: New module.
23525         * tests/test-sha1-buffer.c: New file, based on tests/test-sha1.c.
23526         * tests/test-sha1-stream.c: Renamed from tests/test-sha1.c.
23527         (main): Remove sha1-buffer tests.
23528         * modules/crypto/sha1-buffer-tests: New file, based on
23529         modules/crypto/sha1-tests.
23530         * modules/crypto/sha1-tests: Remove tests that are now in
23531         modules/crypto/sha1-buffer-tests. Test tests/test-sha1-stream.c instead
23532         of tests/test-sha1.c.
23534         sha1: Clarify module to source relation.
23535         * lib/sha1-stream.c: New file, extracted from lib/sha1.c.
23536         * lib/sha1.c: Don't include stdlib.h, unlocked-io.h.
23537         (BLOCKSIZE, sha1_stream): Moved to sha1-stream.c.
23538         * lib/sha1.h: Correct indentation.
23539         * modules/crypto/sha1 (Files): Add lib/sha1-stream.c.
23540         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
23541         (Makefile.am): Arrange to compile sha1-stream.c.
23542         (Link): Mention $(LIB_CRYPTO).
23544 2021-09-18  Bruno Haible  <bruno@clisp.org>
23546         md5-buffer tests: New module.
23547         * tests/test-md5-buffer.c: New file, based on tests/test-md5.c.
23548         * tests/test-md5-stream.c: Renamed from tests/test-md5.c.
23549         (main): Remove md5-buffer tests.
23550         * modules/crypto/md5-buffer-tests: New file, based on
23551         modules/crypto/md5-tests.
23552         * modules/crypto/md5-tests: Remove tests that are now in
23553         modules/crypto/md5-buffer-tests. Test tests/test-md5-stream.c instead
23554         of tests/test-md5.c.
23556         md5: Clarify module to source relation.
23557         * lib/md5-stream.c: New file, extracted from lib/md5.c.
23558         * lib/md5.c: Don't include stdlib.h, unlocked-io.h.
23559         (BLOCKSIZE, md5_stream): Moved to md5-stream.c.
23560         * lib/md5.h: Tweak.
23561         * modules/crypto/md5 (Files): Add lib/md5-stream.c.
23562         (configure.ac): Don't define GL_COMPILE_CRYPTO_STREAM.
23563         (Makefile.am): Arrange to compile md5-stream.c.
23564         (Link): Mention $(LIB_CRYPTO).
23566 2021-09-18  Bruno Haible  <bruno@clisp.org>
23568         md4-buffer tests: New module.
23569         * tests/test-md4-buffer.c: Renamed from tests/test-md4.c.
23570         * modules/crypto/md4-buffer-tests: Renamed from
23571         modules/crypto/md4-tests. Test tests/test-md4-buffer.c instead of
23572         tests/test-md4.c.
23574         md4-buffer: New module.
23575         * lib/md4-stream.c: New file, extracted from lib/md4.c.
23576         * lib/md4.c: Don't include stdlib.h, unlocked-io.h.
23577         (BLOCKSIZE, md4_stream): Moved to md4-stream.c.
23578         * lib/md4.h: Reorder declarations.
23579         * modules/crypto/md4-buffer: New file, based on modules/crypto/md4.
23580         * modules/crypto/md4: Rewritten.
23582 2021-09-18  Bruno Haible  <bruno@clisp.org>
23584         md2-buffer tests: New module.
23585         * tests/test-md2-buffer.c: Renamed from tests/test-md2.c.
23586         * modules/crypto/md2-buffer-tests: Renamed from
23587         modules/crypto/md2-tests. Test tests/test-md2-buffer.c instead of
23588         tests/test-md2.c.
23590         md2-buffer: New module.
23591         * lib/md2-stream.c: New file, extracted from lib/md2.c.
23592         * lib/md2.c: Don't include stdlib.h, unlocked-io.h.
23593         (BLOCKSIZE, md2_stream): Moved to md2-stream.c.
23594         * lib/md2.h: Reorder declarations.
23595         * modules/crypto/md2-buffer: New file, based on modules/crypto/md2.
23596         * modules/crypto/md2: Rewritten.
23598 2021-09-18  Bruno Haible  <bruno@clisp.org>
23600         string, wchar: Don't cause link errors for rpl_free (regr. 2021-09-07).
23601         Reported by Simon Josefsson in
23602         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00042.html>.
23603         * lib/string.in.h (free, rpl_free): Consider GNULIB_FREE_POSIX variable.
23604         * lib/wchar.in.h (free, rpl_free): Likewise.
23605         * m4/string_h.m4 (gl_STRING_H_REQUIRE_DEFAULTS): Require module
23606         indicator variable initializations from the stdlib module.
23607         * m4/wchar_h.m4 (gl_WCHAR_H_REQUIRE_DEFAULTS): Likewise.
23608         * modules/string (Makefile.am): Substitute GNULIB_FREE_POSIX in string.h.
23609         * modules/wchar (Makefile.am): Substitute GNULIB_FREE_POSIX in wchar.h.
23611 2021-09-17  Bruno Haible  <bruno@clisp.org>
23613         threadlib: Avoid crashes in thread-related functions on Cygwin 3.2.0.
23614         Reported by Brian Inglis via Akim Demaille in
23615         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00063.html>.
23616         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): Force a "guessing no" result on
23617         Cygwin.
23619 2021-09-13  Bruno Haible  <bruno@clisp.org>
23621         simple-atomic: Port to Oracle Studio 12.6.
23622         * lib/simple-atomic.c (asm) [0x590 <= __SUNPRO_C && __STDC__]:
23623         #define to __asm.
23625 2021-09-13  Paul Eggert  <eggert@cs.ucla.edu>
23627         asyncsafe-spin: port to Oracle Studio 12.6 sparc
23628         Problem reported by Dennis Clarke via Eric Blake in:
23629         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00056.html
23630         * lib/asyncsafe-spin.c (asm) [0x590 <= __SUNPRO_C && __STDC__]:
23631         #define to __asm.
23633 2021-09-12  Paul Eggert  <eggert@cs.ucla.edu>
23635         stdint-tests: long long preproc on recent Sun C
23636         * tests/test-stdint.c: Test long long preprocessor constants on
23637         Oracle Developer Studio 12.6, where they should work.
23639 2021-09-13  Bruno Haible  <bruno@clisp.org>
23641         extern-inline: Fix syntax error on macOS with GCC 11 (regr. 2021-08-22).
23642         Reported by Akim Demaille in
23643         <https://lists.gnu.org/archive/html/bug-gnulib/2021-09/msg00052.html>.
23644         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE): Put _GL_UNUSED
23645         before, not after, 'static'.
23647 2021-09-11  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
23649         sigsegv: port to OpenBSD 6.8+ powerpc64
23650         * lib/sigsegv.c (SIGSEGV_FAULT_STACKPOINTER):
23651         Special case for __OpenBSD__ && __powerpc64__, needed due to:
23652         https://github.com/openbsd/src/commit/5e649a8714ba05cf482011b7b7d1e5437b7c17db
23653         which is part of the oldest currently-supported OpenBSD (6.8),
23654         so we needn’t worry about older versions.
23656 2021-09-09  Pádraig Brady  <P@draigBrady.com>
23658         maintainer-makefile: add 'can' to sc_prohibit_doubled_word
23659         * top/maint.mk (sc_prohibit_doubled_word): Check for "can can".
23661 2021-09-08  Paul Eggert  <eggert@cs.ucla.edu>
23663         strerror_r-posix: port even better to Android
23664         * lib/strerror_r.c: Use STRERROR_R_CHAR_P to decide whether the
23665         system strerror_r returns char *, and HAVE_DECL_STRERROR_R to
23666         decide whether it either does that or returns an integer.  In the
23667         former case, use the system strerror_r even on platforms like
23668         Android API level 23 that don’t have __xpg_strerror_r; also
23669         check for strerror_r failure just in case.
23670         * m4/error.m4 (gl_PREREQ_ERROR):
23671         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R):
23672         Use system extensions on Android, to avoid mishandling strerror_r
23673         on API level 23 and later.
23674         * modules/error, modules/strerror_r-posix (configure.ac):
23675         Surround gl_PREREQ_ERROR with AS_IF instead of plain if, so that
23676         AC_REQUIREs are propagated out.
23678         strerror_r-posix: port better to Android
23679         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Move requirement of
23680         gl_USE_SYSTEM_EXTENSIONS from here ...
23681         (gl_FUNC_STRERROR_R_WORKS): ... to here, which is the macro that
23682         actually needs it.  This avoids a bug where 'configure' tests
23683         whether strerror_r has the POSIX API before enabling GNU
23684         extensions.  On Android, enabling GNU extensions switches from the
23685         POSIX to the GNU API.  Problem reported by Lucy Phipps in:
23686         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00026.html
23688         string, wchar: port rpl_free decl to Android
23689         * lib/string.in.h, lib/wchar.in.h:
23690         (free): When replacing it, declare the unreplaced version too.
23691         Problem reported by Lucy Phipps in:
23692         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00026.html
23694 2021-09-07  Paul Eggert  <eggert@cs.ucla.edu>
23696         string, wchar: avoid some namespace pollution
23697         * lib/string.in.h, lib/wchar.in.h:
23698         (free): Declare by hand instead of including stdlib.h.
23699         This avoids some namespace pollution.  It should also avoid some
23700         nested-include problems described by Lucy Phipps in:
23701         https://lists.gnu.org/r/bug-gnulib/2021-09/msg00018.html
23702         * modules/string, modules/wchar:
23703         (Depends-on): Add stdlib, so that REPLACE_FREE has the right value.
23704         (Makefile.am): Replace @REPLACE_FREE@ when creating the include file.
23706 2021-09-04  Paul Eggert  <eggert@cs.ucla.edu>
23708         idx: break copying from glibc
23709         * config/srclist.txt: Comment out idx.h, and bring back recent change.
23711 2021-09-04  Sun Haiyong  <youbest@sina.com>  (tiny change)
23713         sigsegv: Improve cross-compilation support for LoongArch CPU.
23714         * m4/stack-direction.m4 (SV_STACK_DIRECTION): Assume the stack grows
23715         down on LoongArch.
23717 2021-09-04  Simon Josefsson  <simon@josefsson.org>
23719         doc: Improve help related to bootstrap script.
23720         * doc/gnulib-tool.texi (VCS Issues): Make title more positive,
23721         s/Issues/Integration/.  Some more bootstrap-related hints,
23722         including changing suggested submodule path from .gnulib to gnulib
23723         as this seems to be more wide-spread.
23725 2021-09-04  Paul Eggert  <eggert@cs.ucla.edu>
23727         intprops: fix minor doc glitches
23728         * doc/intprops.texi (Integer Properties): Fix doc glitches.
23730 2021-09-04  Simon Josefsson  <simon@josefsson.org>
23732         doc: Add suggestions on FDL texinfo usage.
23733         * doc/licenses-texi.texi (License Texinfo sources): Add texinfo
23734         examples.
23736 2021-09-03  Simon Josefsson  <simon@josefsson.org>
23738         maintainer-makefile: Add indentation syntax-check rule.
23739         * top/maint.mk (indent): Use AM_V_GEN and indent_args.
23740         (sc_indent): New rule.
23741         (indent_args): New variable.
23742         (C_SOURCES): New variable, initialized to reasonable C files.
23743         (exclude_file_name_regexp--indent): New variable.
23745 2021-08-30  Paul Eggert  <eggert@cs.ucla.edu>
23747         idx: add commentary
23748         * lib/idx.h: Add comments about ssize_t and strlen, in
23749         response to comments from Simon Josefsson in:
23750         https://lists.gnu.org/r/bug-gnulib/2021-08/msg00196.html
23752 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
23754         attribute: keep up with gnulib-common.m4
23755         * lib/attribute.h (ATTRIBUTE_DEALLOC, ATTRIBUTE_DEALLOC_FREE):
23756         New macros, aliases for the _GL_-prefixed macros added
23757         to gnulib-common.m4 last month.
23759 2021-08-29  Bruno Haible  <bruno@clisp.org>
23761         supersede: Fix test failure under QEMU user-mode for Linux/mips.
23762         * tests/test-supersede-open.h (test_open_supersede): Copy statbuf.st_dev
23763         into a local variable of type dev_t.
23764         * tests/test-supersede-fopen.h (test_fopen_supersede): Likewise.
23766 2021-08-29  Bruno Haible  <bruno@clisp.org>
23768         spawn-pipe: Fix test failure when running under QEMU user-mode.
23769         * tests/test-spawn-pipe-child.c: Include <stdbool.h>, <string.h>,
23770         qemu.h.
23771         (main): Under QEMU user-mode, allow fd 2 or fd 3 to be open.
23772         * modules/spawn-pipe-tests (Files): Add qemu.h.
23773         (Depends-on): Add stdbool.
23775 2021-08-29  Bruno Haible  <bruno@clisp.org>
23777         execute: Fix test failure when running under QEMU user-mode.
23778         * tests/test-execute-child.c: Include <stdbool.h>, qemu.h.
23779         (main): Under QEMU user-mode, allow fd 3 to be open.
23780         * modules/execute-tests (Files): Add qemu.h.
23781         (Depends-on): Add stdbool.
23783 2021-08-29  Bruno Haible  <bruno@clisp.org>
23785         posix_spawn_file_actions_addfchdir: Avoid test failure under QEMU.
23786         * tests/test-posix_spawn-fchdir.c: Include qemu.h.
23787         (is_qemu): New variable.
23788         (test): Under QEMU user-mode, don't expect that "pwd" produces the
23789         result "/".
23790         (main): Initialize is_qemu. Under QEMU user-mode, skip the relative file
23791         name test.
23792         * modules/posix_spawn_file_actions_addfchdir-tests (Files): Add qemu.h.
23793         (Depends-on): Add stdbool.
23795 2021-08-29  Bruno Haible  <bruno@clisp.org>
23797         getcwd tests: Avoid test failure when running under QEMU user-mode.
23798         * modules/getcwd-tests (Files): Add qemu.h.
23799         (Depends-on): Add stdbool.
23800         * tests/test-getcwd.c: Include qemu.h.
23801         (test_long_name): Skip this test when running under QEMU user-mode.
23802         (main): Consider return code 77 from test_long_name.
23804 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
23806         base32, base64: treat negative sizes as overflows
23807         * lib/base64.c (base64_encode_alloc):
23808         * lib/base32.c (base32_encode_alloc):
23809         Treat negative sizes as overflows, for better compatibility
23810         with previous API.
23812 2021-08-29  Bruno Haible  <bruno@clisp.org>
23814         explicit_bzero test: Fix test failure due to GCC optimizations.
23815         * tests/test-explicit_bzero.c (do_secret_stuff): Use static variable
23816         'last_stackbuf'.
23817         (main): Use an 'if' to combine the two do_secret_stuff invocations.
23819 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
23821         dfa: port to non-gnulib
23822         Suggested by Arnold Robbins in:
23823         https://lists.gnu.org/r/bug-gnulib/2021-08/msg00181.html
23824         * lib/dfa.h (_GL_ATTRIBUTE_DEALLOC) [!_GL_ATTRIBUTE_MALLOC]:
23825         Add missing definition.
23827 2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
23829         base32, base64: fix broken tests
23830         Problem reported by Bruno Haible in:
23831         https://lists.gnu.org/r/bug-gnulib/2021-08/msg00170.html
23832         * lib/base32.c, lib/base64.c: Do not include verify.h,
23833         and omit all uses of ‘assume’.
23834         * modules/base32, modules/base64 (Depends-on): Remove verify.
23835         * tests/test-base32.c, tests/test-base64.c:
23836         Don’t pass out-of-range values to allocator,
23837         as converting them to idx_t relies on implementation-defined
23838         behavior that could trap.
23840         ialloc: relicense
23841         * modules/ialloc (License): Change from LGPL to LGPLv2+.
23843 2021-08-28  Bruno Haible  <bruno@clisp.org>
23845         fma: Fix compilation error on Linux/sh4.
23846         * lib/fma.c (FUNC): Don't test for FE_DOWNWARD or FE_UPWARD when these
23847         rounding modes are not defined.
23849 2021-08-28  Bruno Haible  <bruno@clisp.org>
23851         Skip some tests when running under QEMU user-mode.
23852         * tests/qemu.h: New file.
23853         * tests/test-get-rusage-as.c: Include qemu.h.
23854         (main): Skip the test when running under QEMU.
23855         * tests/test-get-rusage-data.c: Include qemu.h.
23856         (main): Skip the test when running under QEMU.
23857         * tests/test-printf-posix2.c: Include qemu.h.
23858         (main): Return with code 77 when running under QEMU.
23859         * tests/test-fprintf-posix2.c: Include qemu.h.
23860         (main): Return with code 77 when running under QEMU.
23861         * tests/test-fprintf-posix3.c: Include qemu.h.
23862         (main): Return with code 79 when running under QEMU.
23863         * tests/test-fprintf-posix3.sh: Skip the test when the return code was
23864         79.
23865         * tests/test-dprintf-posix2.c: Include qemu.h.
23866         (main): Return with code 79 when running under QEMU. Use return code 80
23867         instead of 78.
23868         * tests/test-dprintf-posix2.sh: Skip the test when the return code was
23869         79. Update for changed return code.
23870         * modules/get-rusage-as-tests (Files): Add qemu.h.
23871         (Depends-on): Add stdbool.
23872         * modules/get-rusage-data-tests (Files): Add qemu.h.
23873         (Depends-on): Add stdbool.
23874         * modules/fprintf-posix-tests (Files): Add qemu.h.
23875         (Depends-on): Add stdbool.
23876         * modules/dprintf-posix-tests (Files): Add qemu.h.
23877         (Depends-on): Add stdbool.
23879 2021-08-28  Bruno Haible  <bruno@clisp.org>
23881         sigabbrev_np, sigdescr_np: Fix compilation error on Linux/alpha.
23882         * lib/sigabbrev_np.c (sigabbrev_np): When SIGINFO and SIGPWR have the
23883         same value, give precendence to SIGPWR.
23884         * lib/sigdescr_np.c (sigdescr_np): Likewise.
23885         * tests/test-sigabbrev_np.c (main): Likewise.
23886         * tests/test-sigdescr_np.c (main): Likewise.
23888 2021-08-28  Bruno Haible  <bruno@clisp.org>
23890         execle, execve, execvpe tests: Fix test failures under qemu user-mode.
23891         * test-execle-main.c: Include <string.h>.
23892         (get_environ_assignment, create_minimal_env): New functions.
23893         (main): Call create_minimal_env.
23894         * test-execve-main.c: Likewise.
23895         * test-execvpe-main.c: Likewise.
23897 2021-08-27  Paul Eggert  <eggert@cs.ucla.edu>
23899         base32, base64: prefer signed to unsigned integers
23900         * lib/base32.c, lib/base64.c: Include ialloc.h instad of stdlib.h.
23901         Include intprops.h, verify.h.
23902         * lib/base32.c (base32_encode, base32_encode_alloc, get_8, decode_8)
23903         (base32_decode_ctx, base32_decode_alloc_ctx):
23904         * lib/base32.h (struct base32_decode_context):
23905         * lib/base64.c (base64_encode_fast, base64_encode)
23906         (base64_encode_alloc, get_4, decode_4, base64_decode_ctx)
23907         (base64_decode_alloc_ctx):
23908         * lib/base64.h (struct base64_decode_context):
23909         * tests/test-base32.c (main):
23910         * tests/test-base64.c (main):
23911         Prefer signed to unsigned integers.
23912         * lib/base32.c (base32_encode_alloc):
23913         * lib/base64.c (base64_encode_alloc):
23914         Use simpler and more-direct check for overflow, removing a TODO.
23915         * lib/base32.h, lib/base64.h: Include idx.h instead of stddef.h.
23916         * modules/base32, modules/base64 (Depends-on): Add ialloc, verify.
23918 2021-08-26  Paul Eggert  <eggert@cs.ucla.edu>
23920         regex: use __attr_access and C99-style array arg
23921         This should help with some static checking.
23922         Derived from a suggestion by Martin Sebor in:
23923         https://sourceware.org/pipermail/libc-alpha/2021-August/130336.html
23924         * config/srclist.txt: Remove lib/regex.c for now.
23925         * lib/regex.c: Ignore -Wvla for the whole file.
23926         * lib/regex.h (_REGEX_NELTS, _Attr_access_): New macros.
23927         Ignore -Wvla when declaring regexec.
23928         (re_compile_pattern, re_search, re_search2, re_match, re_match_2)
23929         (regerror): Mark with _Attr_access_, as glibc does.
23930         * lib/regex.h (regexec):
23931         * lib/regexec.c (regexec, __compat_regexec):
23932         Use _REGEX_NELTS for each array parameter whose size is another arg
23933         but with an access pattern that cannot be captured with __attr_access.
23935 2021-08-25  Bruno Haible  <bruno@clisp.org>
23937         execute tests: Fix test failure when libtool is in use.
23938         * modules/execute-tests (Makefile.am): Link test-execute-child without
23939         using libtool.
23940         * modules/spawn-pipe-tests (Makefile.am): Link test-spawn-pipe-child
23941         without using libtool.
23942         * modules/system-quote-tests (Makefile.am): Link test-system-quote-child
23943         without using libtool.
23945 2021-08-24  Paul Eggert  <eggert@cs.ucla.edu>
23947         dfa: prefer idx_t to ptrdiff_t for nonnegative
23948         * lib/dfa.c (struct dfa, dfaexec_main, dfaexec_mb, dfaexec_sb)
23949         (dfaexec_noop, dfaexec):
23950         * lib/dfa.h (dfaparse, dfacomp, dfaexec):
23951         Prefer idx_t to ptrdiff_t for counts, which should be nonnegative.
23952         * lib/dfa.h: Include idx.h.
23954 2021-08-22  Bruno Haible  <bruno@clisp.org>
23956         snippet/unused-parameter: Mark unused module obsolete.
23957         * modules/snippet/unused-parameter (Status, Notice): Mark as obsolete.
23959 2021-08-22  Bruno Haible  <bruno@clisp.org>
23961         Make generated .in.h files as standalone as possible.
23962         Reported by Jan Engelhardt <jengelh@inai.de>.
23963         * lib/stdlib.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_DEALLOC_FREE,
23964         _GL_ATTRIBUTE_MALLOC): Add fallback definitions.
23965         * lib/dirent.in.h (_GL_ATTRIBUTE_DEALLOC, _GL_ATTRIBUTE_MALLOC): Add
23966         fallback definitions.
23967         * lib/stdio.in.h (_GL_ATTRIBUTE_DEALLOC): Add fallback definition.
23968         * lib/math.in.h (_GL_ATTRIBUTE_CONST): Add fallback definition.
23969         * lib/pthread.in.h (_GL_ATTRIBUTE_PURE): Add fallback definition.
23970         * lib/threads.in.h (_GL_ATTRIBUTE_PURE): Likewise.
23971         * lib/uchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
23972         * lib/string.in.h (_GL_ATTRIBUTE_PURE): Move definition, for consistency
23973         with the other *.in.h files.
23974         * lib/se-context.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Add fallback
23975         definition.
23976         * lib/se-label.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Likewise.
23977         * lib/se-selinux.in.h (_GL_ATTRIBUTE_MAYBE_UNUSED): Likewise.
23978         * lib/textstyle.in.h: Use _GL_ATTRIBUTE_MAYBE_UNUSED instead of
23979         _GL_UNUSED.
23980         (_GL_ATTRIBUTE_SPEC_PRINTF_STANDARD, _GL_ATTRIBUTE_MAYBE_UNUSED): Add
23981         fallback definitions.
23983 2021-08-22  Bruno Haible  <bruno@clisp.org>
23985         gnulib-common.m4: Clarify logic behind _GL_UNUSED_LABEL.
23986         Reported by Paul Eggert.
23987         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add comment and write the
23988         condition in a way that is close to the comment.
23990 2021-08-22  Paul Eggert  <eggert@cs.ucla.edu>
23992         c-stack: depend on inttypes, mempcpy
23993         * modules/c-stack (Depends-on): Add inttypes, mempcpy.
23994         mempcpy problem reported by Evan Miller in:
23995         https://debbugs.gnu.org/50098#31
23997 2021-08-22  Bruno Haible  <bruno@clisp.org>
23999         mountlist: Use recommended syntax for _GL_UNUSED_LABEL.
24000         * lib/mountlist.c (read_file_system_list): Add semicolon after
24001         _GL_UNUSED_LABEL.
24003 2021-08-22  Bruno Haible  <bruno@clisp.org>
24005         gnulib-common.m4: Make _GL_UNUSED_LABEL effective for clang.
24006         * m4/gnulib-common.m4 (gl_COMMON_BODY): Make _GL_UNUSED_LABEL use
24007         _GL_ATTRIBUTE_UNUSED also for clang.
24009 2021-08-22  Bruno Haible  <bruno@clisp.org>
24011         gnulib-common.m4: Use C2x [[maybe_unused]] when possible.
24012         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _GL_UNUSED as an alias of
24013         _GL_ATTRIBUTE_MAYBE_UNUSED, not of _GL_ATTRIBUTE_UNUSED.
24014         * lib/binary-io.h (__gl_setmode): Put _GL_UNUSED before, not after, the
24015         declaration.
24016         * lib/c-stack.c (null_action, segv_handler, overflow_handler,
24017         c_stack_action): Likewise.
24018         * lib/chown.c (chown): Likewise.
24019         * lib/clean-temp-simple.c (cleanup_action): Likewise.
24020         * lib/fts.c (dirent_inode_sort_may_be_useful, leaf_optimization,
24021         fts_set): Likewise.
24022         * lib/getgroups.c (getgroups): Likewise.
24023         * lib/getopt.c (_getopt_initialize): Likewise.
24024         * lib/getugroups.c (getugroups): Likewise.
24025         * lib/localename.c (gl_locale_name_thread_unsafe, gl_locale_name_thread,
24026         gl_locale_name_posix, gl_locale_name_environ): Likewise.
24027         * lib/mkdir.c (rpl_mkdir): Likewise.
24028         * lib/mkfifo.c (mkfifo): Likewise.
24029         * lib/mkfifoat.c (mkfifoat): Likewise.
24030         * lib/mknod.c (mknod): Likewise.
24031         * lib/mknodat.c (mknodat): Likewise.
24032         * lib/mountlist.c (me_remote): Likewise.
24033         * lib/openpty.c (openpty): Likewise.
24034         * lib/parse-datetime.y (yyerror): Likewise.
24035         * lib/passfd.c (sendfd, recvfd): Likewise.
24036         * lib/pthread-cond.c (pthread_condattr_destroy, pthread_cond_init,
24037         pthread_cond_wait, pthread_cond_timedwait, pthread_cond_signal,
24038         pthread_cond_broadcast, pthread_cond_destroy): Likewise.
24039         * lib/pthread-mutex.c (pthread_mutexattr_destroy, pthread_mutex_init,
24040         pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_timedlock,
24041         pthread_mutex_unlock, pthread_mutex_destroy): Likewise.
24042         * lib/pthread-rwlock.c (pthread_rwlockattr_destroy, pthread_rwlock_init,
24043         pthread_rwlock_timedrdlock, pthread_rwlock_timedwrlock): Likewise.
24044         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
24045         pthread_spin_trylock, pthread_spin_unlock, pthread_spin_destroy):
24046         Likewise.
24047         * lib/pthread-thread.c (pthread_attr_destroy): Likewise.
24048         * lib/readlink.c (readlink): Likewise.
24049         * lib/rename.c (rpl_rename): Likewise.
24050         * lib/set-permissions.c (set_permissions): Likewise.
24051         * lib/sockets.c (gl_sockets_startup): Likewise.
24052         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime,
24053         stat_time_normalize): Likewise.
24054         * lib/strptime.c (__strptime_internal): Likewise.
24055         * lib/strtod.c (LDEXP): Likewise.
24056         * lib/symlink.c (symlink): Likewise.
24057         * lib/symlinkat.c (symlinkat): Likewise.
24058         * lib/tempname.c (try_dir, try_nocreate): Likewise.
24059         * lib/textstyle.in.h (styled_ostream_begin_use_class,
24060         styled_ostream_end_use_class, styled_ostream_get_hyperlink_ref,
24061         styled_ostream_get_hyperlink_id, styled_ostream_set_hyperlink,
24062         styled_ostream_flush_to_current_style, fd_ostream_create,
24063         term_ostream_get_color, term_ostream_set_color,
24064         term_ostream_get_bgcolor, term_ostream_set_bgcolor,
24065         term_ostream_get_weight, term_ostream_set_weight,
24066         term_ostream_get_posture, term_ostream_set_posture,
24067         term_ostream_get_underline, term_ostream_set_underline,
24068         term_ostream_get_hyperlink_ref, term_ostream_get_hyperlink_id,
24069         term_ostream_set_hyperlink, term_ostream_create,
24070         term_styled_ostream_create, html_styled_ostream_create,
24071         handle_color_option, handle_style_option, style_file_prepare,
24072         styled_ostream_create, libtextstyle_set_failure_exit_code): Likewise.
24073         * lib/unicodeio.c (exit_failure_callback, fallback_failure_callback):
24074         Likewise.
24075         * lib/wait-process.c (cleanup_slaves_action): Likewise.
24076         * tests/signature.h (SIGNATURE_CHECK2): Likewise.
24077         * tests/test-areadlink.c (do_areadlink): Likewise.
24078         * tests/test-areadlinkat.c (do_areadlinkat): Likewise.
24079         * tests/test-ceilf-ieee.c (main): Likewise.
24080         * tests/test-ceilf1.c (main): Likewise.
24081         * tests/test-dirent.c (dir): Likewise.
24082         * tests/test-fchownat.c (main): Likewise.
24083         * tests/test-fdopendir.c (main): Likewise.
24084         * tests/test-filenamecat.c (main): Likewise.
24085         * tests/test-floor1.c (main): Likewise.
24086         * tests/test-floorf-ieee.c (main): Likewise.
24087         * tests/test-floorf1.c (main): Likewise.
24088         * tests/test-fseeko.c (main): Likewise.
24089         * tests/test-fstatat.c (main): Likewise.
24090         * tests/test-ftello.c (main): Likewise.
24091         * tests/test-getdomainname.c (main): Likewise.
24092         * tests/test-getgroups.c (main): Likewise.
24093         * tests/test-gethostname.c (main): Likewise.
24094         * tests/test-math-c++.cc (OVERLOADED_CHECK): Likewise.
24095         * tests/test-mkdirat.c (main): Likewise.
24096         * tests/test-openat.c (main): Likewise.
24097         * tests/test-parse-datetime.c (main): Likewise.
24098         * tests/test-quotearg-simple.c (main): Likewise.
24099         * tests/test-quotearg.c (main): Likewise.
24100         * tests/test-sethostname2.c (main): Likewise.
24101         * tests/test-unlinkat.c (main): Likewise.
24102         * tests/test-version-etc.c (main): Likewise.
24103         * tests/test-xalloc-die.c (main): Likewise.
24104         * tests/test-xfprintf-posix.c (main): Likewise.
24105         * tests/test-xprintf-posix.c (main): Likewise.
24106         * tests/test-xvasprintf.c (main): Likewise.
24108 2021-08-22  Bruno Haible  <bruno@clisp.org>
24110         gnulib-common.m4: Document the gnulib-internal _GL_ATTRIBUTE_* macros.
24111         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add comments to the
24112         _GL_ATTRIBUTE_* macros, based on lib/attribute.h.
24114 2021-08-22  Bernhard Voelker  <mail@bernhard-voelker.de>
24116         doc: fix order of stdlib functions
24117         * doc/gnulib.texi (node Glibc stdlib.h): Move mrand48_r after mkstemps.
24118         Reported by Benno Schulenberg.
24120 2021-08-21  Bruno Haible  <bruno@clisp.org>
24122         c-stack: Test for libsigsegv once, not twice.
24123         * m4/sigsegv.m4: New file, based on modules/sigsegv.
24124         * modules/sigsegv (Files): Add it.
24125         (configure.ac): Require gl_SIGSEGV. Test gl_sigsegv_uses_libsigsegv
24126         instead of with_libsigsegv and gl_cv_lib_sigsegv.
24127         * m4/c-stack.m4 (gl_C_STACK): Likewise.
24129 2021-08-21  Bruno Haible  <bruno@clisp.org>
24131         rawmemchr: Fix use in relocatable-prog-wrapper (regression 2021-08-20).
24132         * lib/rawmemchr.c: Restore test of HAVE_RAWMEMCHR.
24133         * modules/relocatable-prog-wrapper (Depends-on): Add stdalign.
24135 2021-08-20  Paul Eggert  <eggert@cs.ucla.edu>
24137         rawmemchr: modernize and simplify
24138         * lib/rawmemchr.c (HAVE_RAWMEMCHR): Assume it’s not defined;
24139         otherwise this file would not be compiled.  Include limits.h,
24140         stdalign.h, stdint.h, verify.h.
24141         (rawmemchr): Prefer uintptr_t to unsigned long and to size_t when
24142         it’s the better type.  Verify that longword lacks padding.  Use
24143         alignof rather than sizeof when checking alignment.  Simplify by
24144         assuming C99 decl-after-statement, and by using multiplication
24145         rather than repeated shifting and OR (modern compilers can
24146         optimize the multiplication if needed).  Avoid unnecessary casts.
24147         Don’t assume CHAR_WIDTH is 8.  Convert back and forth between void *
24148         to suppress bogus GCC warnings about alignment.  Omit a
24149         duplicate assignment to char_ptr.
24150         * modules/rawmemchr (Depends-on): Add stdalign, stdint, verify.
24152 2021-08-17  Paul Eggert  <eggert@cs.ucla.edu>
24154         c-stack: fix libsigsegv dependency (regression 2021-05-18)
24155         Problem reported for GNU grep by Evan Miller (Bug#50098).
24156         * m4/c-stack.m4 (gl_C_STACK): Call gl_LIBSIGSEGV before
24157         testing gl_cv_lib_sigsegv.
24159 2021-08-14  Bruno Haible  <bruno@clisp.org>
24161         doc: Update for glibc 2.34.
24162         * doc/posix-functions/timespec_getres.texi: New file.
24163         * doc/glibc-functions/_Fork.texi: New file.
24164         * doc/glibc-functions/closefrom.texi: New file.
24165         * doc/glibc-functions/dn_comp.texi: New file.
24166         * doc/glibc-functions/dn_skipname.texi: New file.
24167         * doc/glibc-functions/execveat.texi: New file.
24168         * doc/glibc-functions/posix_spawn_file_actions_addclosefrom_np.texi: New
24169         file.
24170         * doc/glibc-functions/res_dnok.texi: New file.
24171         * doc/glibc-functions/res_hnok.texi: New file.
24172         * doc/glibc-functions/res_mailok.texi: New file.
24173         * doc/glibc-functions/res_nmkquery.texi: New file.
24174         * doc/glibc-functions/res_nquery.texi: New file.
24175         * doc/glibc-functions/res_nquerydomain.texi: New file.
24176         * doc/glibc-functions/res_nsearch.texi: New file.
24177         * doc/glibc-functions/res_nsend.texi: New file.
24178         * doc/glibc-functions/res_ownok.texi: New file.
24179         * doc/glibc-functions/res_send.texi: New file.
24180         * doc/gnulib.texi: Include them.
24181         * doc/glibc-functions/inet_neta.texi: Remove file.
24182         * doc/glibc-functions/malloc_get_state.texi: Remove file.
24183         * doc/glibc-functions/malloc_set_state.texi: Remove file.
24184         * doc/glibc-functions/pthread_mutex_consistent_np.texi: Remove file.
24185         * doc/glibc-functions/pthread_mutexattr_getrobust_np.texi: Remove file.
24186         * doc/glibc-functions/pthread_mutexattr_setrobust_np.texi: Remove file.
24187         * doc/glibc-functions/pthread_yield.texi: Remove file.
24188         * doc/gnulib.texi: Don't include them.
24189         * doc/glibc-headers/resolv.texi: Update.
24190         * doc/pastposix-functions/h_errno.texi: Likewise.
24191         * doc/posix-functions/*.texi: Likewise.
24192         * doc/glibc-functions/*.texi: Likewise.
24194 2021-08-12  Paul Eggert  <eggert@cs.ucla.edu>
24196         memrchr-tests: port to GCC 12
24197         * tests/test-memrchr.c: Bug#101494 is fixed in GCC 12.
24199 2021-08-12  Akim Demaille  <akim@lrde.epita.fr>
24201         snippet/_Noreturn: Fix typo
24202         * lib/_Noreturn.h: Fix spelling of 4.
24204 2021-08-11  Paul Eggert  <eggert@cs.ucla.edu>
24206         dynarray: merge from glibc
24207         This also helps document glibc’s direction in using GCC’s
24208         memory-allocation checking.
24209         * lib/cdefs.h: Omit comments that glibc rejected.
24210         (__returns_nonnull, __attr_access_none, __attr_dealloc)
24211         (__attr_dealloc_free): New macros.
24212         * lib/libc-config.h: Undef the new macros that are defined
24213         unconditionally.
24214         * lib/malloc/dynarray_at_failure.c [_LIBC]: Do not include stdlib.h.
24215         (__libc_dynarray_at_failure) [_LIBC]: Call __libc_fatal,
24216         fixing a bad merge previously.
24218 2021-08-08  Bruno Haible  <bruno@clisp.org>
24220         canonicalize-lgpl: Fix conflict with z/OS <sys/stat.h>.
24221         Reported by Mike Fulton <mikefultonpersonal@gmail.com> in
24222         <https://lists.gnu.org/archive/html/m4-discuss/2021-08/msg00000.html>
24223         via Eric Blake.
24224         * lib/canonicalize-lgpl.c (__stat): Remove macro.
24225         (file_accessible): Use 'stat' instead.
24227 2021-08-08  Bruno Haible  <bruno@clisp.org>
24229         ptsname_r: Drop sync with glibc.
24230         * lib/ptsname_r.c: Drop _LIBC code.
24231         (__set_errno, __isatty, __stat, __ttyname_r, __ptsname_r): Remove
24232         macros.
24233         (ptsname_r): Rename local variable 'save_errno'.
24235 2021-08-08  Bruno Haible  <bruno@clisp.org>
24237         config: Update after glibc changed.
24238         * config/srclist.txt: Remove two files that glibc dropped on 2013-12-17.
24240 2021-08-08  Bruno Haible  <bruno@clisp.org>
24242         relocatable-lib-lgpl: Fix a memory leak related to a Windows DLL.
24243         Reported by Jonathan Boeing <jonathan@claws-mail.org> in
24244         <https://lists.gnu.org/archive/html/bug-gnulib/2021-08/msg00048.html>.
24245         * lib/relocatable.c (DllMain): Avoid memory leak in a special case
24246         of repeated attach/detach.
24248 2021-08-08  Bruno Haible  <bruno@clisp.org>
24250         fopen: Fix link error on native Windows.
24251         * modules/fopen (Depends-on): Add close.
24253 2021-08-08  Bruno Haible  <bruno@clisp.org>
24255         fopen: Fix compilation error on AIX (regression from 2020-05-28).
24256         * modules/fopen (Depends-on): Add fcntl-h.
24258 2021-08-08  Bruno Haible  <bruno@clisp.org>
24260         stdio: Improve GCC 11 allocation-deallocation checking.
24261         * lib/stdio.in.h (fdopen, fopen, tmpfile): For GCC >= 11: Declare nearly
24262         always.
24263         (popen): For GCC >= 11: Declare also when the platform already declares
24264         the function or when the module 'popen' is not in use.
24266 2021-08-08  Bruno Haible  <bruno@clisp.org>
24268         dirent: Improve GCC 11 allocation-deallocation checking.
24269         * lib/dirent.in.h (opendir): For GCC >= 11: Declare also when the
24270         platform already declares the function or when the module 'opendir' is
24271         not in use.
24272         (fdopendir): For GCC >= 11: Declare also when the platform already
24273         declares the function or when the module 'fdopendir' is not in use.
24275 2021-08-08  Bruno Haible  <bruno@clisp.org>
24277         stdlib, string, wchar: Improve GCC 11 allocation-deallocation checking.
24278         * lib/stdlib.in.h (aligned_alloc): For GCC >= 11: Declare also when the
24279         platform already declares the function or when the module
24280         'aligned_alloc' is not in use.
24281         (calloc): For GCC >= 11: Declare nearly always.
24282         (canonicalize_file_name): For GCC >= 11: Declare also when the platform
24283         already declares the function or when the module 'canonicalize-lgpl' is
24284         not in use.
24285         (malloc, realloc): For GCC >= 11: Declare nearly always.
24286         * lib/malloc.in.h: Remove redundant include.
24287         (memalign): For GCC >= 11: Declare also when the platform already
24288         declares the function or when the module 'memalign' is not in use.
24289         * lib/string.in.h: Include <stdlib.h> always.
24290         (strdup): For GCC >= 11: Declare also when the platform already declares
24291         the function or when the module 'strdup' or 'strdup-posix' is not in
24292         use.
24293         * lib/wchar.in.h: Include <stdlib.h> always.
24294         (wcsdup): For GCC >= 11: Declare also when the platform already declares
24295         the function or when the module 'wcsdup' is not in use.
24296         * modules/free-posix (Depends-on): Add string, wchar.
24298 2021-08-07  Bruno Haible  <bruno@clisp.org>
24300         gnulib-tool: Add support for Automake 1.16.4.
24301         Reported by <shoober420@gmail.com> in
24302         <https://lists.gnu.org/archive/html/bug-libunistring/2021-08/msg00000.html>.
24303         * build-aux/test-driver-1.16.3.diff: Renamed from
24304         build-aux/test-driver.diff.
24305         * build-aux/test-driver.diff: Update to match Automake 1.16.4.
24306         * gnulib-tool (func_create_testdir, func_create_megatestdir): Try both
24307         .diff files.
24309 2021-08-07  Bruno Haible  <bruno@clisp.org>
24311         gnulib-common.m4: Minor style fix.
24312         * m4/gnulib-common.m4 (gl_COMMON_BODY): Keep list of attributes sorted
24313         alphabetically.
24315 2021-08-07  Bruno Haible  <bruno@clisp.org>
24317         uninorm, unistr: Improve GCC 11 allocation-deallocation checking.
24318         * lib/uninorm.in.h (uninorm_filter_free): Move declaration up.
24319         (uninorm_filter_create): Declare that deallocation must happen through
24320         'uninorm_filter_free'.
24321         * lib/unistr.in.h: Include <stdlib.h>.
24322         (u8_strdup, u16_strdup, u32_strdup): Declare that deallocation must
24323         happen through 'free'.
24325 2021-08-07  Bruno Haible  <bruno@clisp.org>
24327         ialloc: Prepare for allocation-deallocation checking.
24328         * lib/ialloc.h (imalloc, irealloc, icalloc): Add comment that
24329         deallocation must happen through 'free'.
24331 2021-08-07  Bruno Haible  <bruno@clisp.org>
24333         aligned-malloc: Prepare for allocation-deallocation checking.
24334         * lib/aligned-malloc.h (aligned_free): Move declaration up.
24335         (aligned_malloc): Add comment that deallocation must happen through
24336         'aligned_free'.
24338 2021-08-07  Bruno Haible  <bruno@clisp.org>
24340         list, set, oset, map, omap: Prepare allocation-deallocation checking.
24341         * lib/gl_list.h (gl_list_create_empty, gl_list_nx_create_empty,
24342         gl_list_create, gl_list_nx_create): Add comment that deallocation must
24343         happen through 'gl_list_free'.
24344         * lib/gl_xlist.h (gl_list_create_empty, gl_list_create): Likewise.
24345         * lib/gl_sublist.h (gl_sublist_create, gl_sublist_nx_create): Likewise.
24346         * lib/gl_xsublist.h (gl_sublist_create): Likewise.
24347         * lib/gl_set.h (gl_set_create_empty, gl_set_nx_create_empty): Add
24348         comment that deallocation must happen through 'gl_set_free'.
24349         * lib/gl_xset.h (gl_set_create_empty): Likewise.
24350         * lib/gl_oset.h (gl_oset_create_empty, gl_oset_nx_create_empty): Add
24351         comment that deallocation must happen through 'gl_oset_free'.
24352         * lib/gl_xoset.h (gl_oset_create_empty): Likewise.
24353         * lib/gl_map.h (gl_map_create_empty, gl_map_nx_create_empty): Add
24354         comment that deallocation must happen through 'gl_map_free'.
24355         * lib/gl_xmap.h (gl_map_create_empty): Likewise.
24356         * lib/gl_omap.h (gl_omap_create_empty, gl_omap_nx_create_empty): Add
24357         comment that deallocation must happen through 'gl_omap_free'.
24358         * lib/gl_xomap.h (gl_omap_create_empty): Likewise.
24360 2021-08-07  Bruno Haible  <bruno@clisp.org>
24362         xgetdomainname: Improve GCC 11 allocation-deallocation checking.
24363         * lib/xgetdomainname.h: Include <stdlib.h>.
24364         (xgetdomainname): Declare that deallocation must happen through 'free'.
24366 2021-08-07  Bruno Haible  <bruno@clisp.org>
24368         xgetdomainname: Ensure .c file starts with '#include <config.h>'.
24369         * lib/xgetaname-impl.h: New file, based on lib/xgethostname.c.
24370         * lib/xgethostname.c: Move implementation to lib/xgetaname-impl.h.
24371         * lib/xgetdomainname.c: Include <config.h>. Include xgetaname-impl.h
24372         instead of xgethostname.c.
24373         * modules/xgethostname (Files): Add lib/xgetaname-impl.h.
24374         * modules/xgetdomainname (Files): Likewise.
24375         (Depends-on): Remove xgethostname. Add free-posix, xalloc.
24377 2021-08-07  Bruno Haible  <bruno@clisp.org>
24379         xstrndup: Improve GCC 11 allocation-deallocation checking.
24380         * lib/xstrndup.h: Include <stdlib.h> instead of <stddef.h>.
24381         (xstrndup): Declare that deallocation must happen through 'free'.
24383 2021-08-07  Bruno Haible  <bruno@clisp.org>
24385         xstriconveh: Improve GCC 11 allocation-deallocation checking.
24386         * lib/xstriconveh.h: Include <stdlib.h> instead of <stddef.h>.
24387         (xstr_cd_iconveh, xstr_iconveh): Declare that deallocation must happen
24388         through 'free'.
24390 2021-08-07  Bruno Haible  <bruno@clisp.org>
24392         xmemdup0: Improve GCC 11 allocation-deallocation checking.
24393         * lib/xmemdup0.h: Include <stdlib.h> instead of <stddef.h>.
24394         (xmemdup0): Declare that deallocation must happen through 'free'.
24396 2021-08-07  Bruno Haible  <bruno@clisp.org>
24398         windows-spawn: Improve GCC 11 allocation-deallocation checking.
24399         * lib/windows-spawn.h: Include <stdlib.h>.
24400         (compose_command, compose_envblock): Declare that deallocation must
24401         happen through 'free'.
24403 2021-08-07  Bruno Haible  <bruno@clisp.org>
24405         string-buffer: Improve GCC 11 allocation-deallocation checking.
24406         * lib/string-buffer.h: Include <stdlib.h> instead of <stddef.h>.
24407         (sb_dupfree): Declare that deallocation must happen through 'free'.
24409 2021-08-07  Bruno Haible  <bruno@clisp.org>
24411         striconveha: Improve GCC 11 allocation-deallocation checking.
24412         * lib/striconveha.h: Include <stdlib.h> instead of <stddef.h>.
24413         (str_iconveha): Declare that deallocation must happen through 'free'.
24415 2021-08-07  Bruno Haible  <bruno@clisp.org>
24417         striconveh: Improve GCC 11 allocation-deallocation checking.
24418         * lib/striconveh.h: Include <stdlib.h> instead of <stddef.h>.
24419         (str_cd_iconveh, str_iconveh): Declare that deallocation must happen
24420         through 'free'.
24422 2021-08-07  Bruno Haible  <bruno@clisp.org>
24424         striconv: Improve GCC 11 allocation-deallocation checking.
24425         * lib/striconv.h: Include <stdlib.h> instead of <stddef.h>.
24426         (str_cd_iconv, str_iconv): Declare that deallocation must happen through
24427         'free'.
24429 2021-08-07  Bruno Haible  <bruno@clisp.org>
24431         relocatable-lib-lgpl: Improve GCC 11 allocation-deallocation checking.
24432         * lib/relocatable.h: Include <stdlib.h>.
24433         (compute_curr_prefix): Declare that deallocation must happen through
24434         'free'.
24436 2021-08-07  Bruno Haible  <bruno@clisp.org>
24438         regex-quote: Improve GCC 11 allocation-deallocation checking.
24439         * lib/regex-quote.h: Include <stdlib.h> instead of <stddef.h>.
24440         (regex_quote): Declare that deallocation must happen through 'free'.
24442 2021-08-07  Bruno Haible  <bruno@clisp.org>
24444         readline: Improve GCC 11 allocation-deallocation checking.
24445         * lib/readline.h: Include <stdlib.h>.
24446         (readline): Declare that deallocation must happen through 'free'.
24448 2021-08-07  Bruno Haible  <bruno@clisp.org>
24450         read-file: Improve GCC 11 allocation-deallocation checking.
24451         * lib/read-file.h: Include <stdlib.h> instead of <stddef.h>.
24452         (fread_file, read_file): Declare that deallocation must happen through
24453         'free'.
24455 2021-08-07  Bruno Haible  <bruno@clisp.org>
24457         pipe-filter-gi: Improve GCC 11 allocation-deallocation checking.
24458         * lib/pipe-filter.h (pipe_filter_gi_close): Move declaration up.
24459         (pipe_filter_gi_create): Declare that deallocation must happen through
24460         'pipe_filter_gi_close'.
24462 2021-08-07  Bruno Haible  <bruno@clisp.org>
24464         javaversion: Improve GCC 11 allocation-deallocation checking.
24465         * lib/javaversion.h: Include <stdlib.h>.
24466         (javaexec_version): Declare that deallocation must happen through
24467         'free'.
24469 2021-08-07  Bruno Haible  <bruno@clisp.org>
24471         ino-map: Improve GCC 11 allocation-deallocation checking.
24472         * lib/ino-map.h (ino_map_free): Move declaration up.
24473         (ino_map_alloc): Declare that deallocation must happen through
24474         'ino_map_free'.
24476 2021-08-07  Bruno Haible  <bruno@clisp.org>
24478         hash: Improve GCC 11 allocation-deallocation checking.
24479         * lib/hash.h (hash_free): Move declaration up.
24480         (hash_initialize, hash_xinitialize): Declare that deallocation must
24481         happen through 'hash_free'.
24483 2021-08-07  Bruno Haible  <bruno@clisp.org>
24485         hamt: Improve GCC 11 allocation-deallocation checking.
24486         * lib/hamt.h (hamt_free): Move declaration up.
24487         (hamt_create, hamt_copy): Declare that deallocation must happen through
24488         'hamt_free'.
24490 2021-08-07  Bruno Haible  <bruno@clisp.org>
24492         get_progname_of: Improve GCC 11 allocation-deallocation checking.
24493         * lib/get_progname_of.h: Include <stdlib.h>.
24494         (get_progname_of): Declare that deallocation must happen through 'free'.
24496 2021-08-07  Bruno Haible  <bruno@clisp.org>
24498         fts: Improve GCC 11 allocation-deallocation checking.
24499         * lib/fts_.h (fts_open): Declare that deallocation must happen through
24500         'fts_close'.
24502 2021-08-07  Bruno Haible  <bruno@clisp.org>
24504         eealloc: Improve GCC 11 allocation-deallocation checking.
24505         * lib/eealloc.h (eemalloc): Declare that deallocation must happen
24506         through 'free'.
24508 2021-08-07  Bruno Haible  <bruno@clisp.org>
24510         di-set: Improve GCC 11 allocation-deallocation checking.
24511         * lib/di-set.h (di_set_free): Move declaration up.
24512         (di_set_alloc): Declare that deallocation must happen through
24513         'di_set_free'.
24515 2021-08-07  Bruno Haible  <bruno@clisp.org>
24517         [x]concat-filename: Improve GCC 11 allocation-deallocation checking.
24518         * lib/concat-filename.h: Include <stdlib.h>.
24519         (concatenated_filename, xconcatenated_filename): Declare that
24520         deallocation must happen through 'free'.
24522 2021-08-07  Bruno Haible  <bruno@clisp.org>
24524         clean-temp: Improve GCC 11 allocation-deallocation checking.
24525         * lib/clean-temp.h (cleanup_temp_dir): Move declaration up.
24526         (create_temp_dir): Declare that deallocation must happen through
24527         'cleanup_temp_dir'.
24529 2021-08-07  Bruno Haible  <bruno@clisp.org>
24531         canon-host: Improve GCC 11 allocation-deallocation checking.
24532         * lib/canon-host.h: Include <stdlib.h>.
24533         (canon_host, canon_host_r): Declare that deallocation must happen
24534         through 'free'.
24536 2021-08-07  Bruno Haible  <bruno@clisp.org>
24538         c-xvasprintf: Improve GCC 11 allocation-deallocation checking.
24539         * lib/c-xvasprintf.h: Include <stdlib.h>.
24540         (c_xasprintf, c_xvasprintf): Declare that deallocation must happen
24541         through 'free'.
24543 2021-08-07  Bruno Haible  <bruno@clisp.org>
24545         bitsetv: Improve GCC 11 allocation-deallocation checking.
24546         * lib/bitsetv.h (bitsetv_free): Move declaration up.
24547         (bitsetv_alloc, bitsetv_create): Declare that deallocation must happen
24548         through 'bitsetv_free'.
24550         bitset: Improve GCC 11 allocation-deallocation checking.
24551         * lib/bitset.h (bitset_free): Move declaration up.
24552         (bitset_alloc, bitset_create): Declare that deallocation must happen
24553         through 'bitset_free'.
24554         (bitset_obstack_free): Move declaration up.
24555         (bitset_obstack_alloc): Declare that deallocation must happen through
24556         'bitset_obstack_free'.
24558 2021-08-07  Bruno Haible  <bruno@clisp.org>
24560         argv-iter: Improve GCC 11 allocation-deallocation checking.
24561         * lib/argv-iter.h (argv_iter_free): Move declaration up.
24562         (argv_iter_init_argv, argv_iter_init_stream): Declare that deallocation
24563         must happen through 'argv_iter_free'.
24565 2021-08-07  Bruno Haible  <bruno@clisp.org>
24567         argp: Improve GCC 11 allocation-deallocation checking.
24568         * lib/argp-fmtstream.h (__argp_fmtstream_free, argp_fmtstream_free):
24569         Move declarations up.
24570         (__argp_make_fmtstream): Declare that deallocation must happen through
24571         '__argp_fmtstream_free'.
24572         (argp_make_fmtstream): Declare that deallocation must happen through
24573         'argp_fmtstream_free'.
24575 2021-08-07  Bruno Haible  <bruno@clisp.org>
24577         areadlink, areadlinkat: Improve GCC 11 allocation-deallocation checking.
24578         * lib/areadlink.h: Include <stdlib.h> instead of <stddef.h>.
24579         (areadlink, areadlink_with_size, areadlinkat, areadlinkat_with_size):
24580         Declare that deallocation must happen through 'free'.
24582 2021-08-07  Bruno Haible  <bruno@clisp.org>
24584         stdio: Improve GCC 11 allocation-deallocation checking.
24585         * lib/stdio.in.h (fdopen, fopen, tmpfile): Declare that deallocation
24586         must happen through 'fclose'.
24587         (popen): Declare that deallocation must happen through 'pclose'.
24588         * lib/stdio-safer.h (fopen_safer, tmpfile_safer): Declare that
24589         deallocation must happen through 'fclose'.
24590         (popen_safer): Declare that deallocation must happen through 'pclose'.
24591         (freopen_safer): Declare that arguments must be non-NULL.
24593 2021-08-07  Bruno Haible  <bruno@clisp.org>
24595         dirent: Improve GCC 11 allocation-deallocation checking.
24596         * lib/dirent.in.h (closedir): Move declaration up.
24597         (opendir, fdopendir): Declare that deallocation must happen through
24598         'closedir'.
24599         * lib/dirent-safer.h (opendir_safer): Likewise.
24600         * lib/opendirat.h (opendirat): Likewise.
24602 2021-08-07  Bruno Haible  <bruno@clisp.org>
24604         stdlib, string, wchar: Improve GCC 11 allocation-deallocation checking.
24605         * lib/stdlib.in.h (free): Move declaration up.
24606         (aligned_alloc, calloc, canonicalize_file_name, malloc, realloc):
24607         Declare that deallocation must happen through 'free' (which may actually
24608         be 'rpl_free').
24609         * lib/string.in.h: Include <stdlib.h>.
24610         (strdup): Declare deallocation.
24611         * lib/wchar.in.h: Include <stdlib.h>.
24612         (wcsdup): Declare deallocation.
24613         * lib/malloc.in.h: Include <stdlib.h>.
24614         (memalign): Declare deallocation.
24616 2021-08-07  Bruno Haible  <bruno@clisp.org>
24618         year2038: Fix recommendation regarding -m64 flag.
24619         * m4/year2038.m4 (gl_YEAR2038_BODY): Recommend to put option --m64 in
24620         CC, not in CPPFLAGS and LDFLAGS.
24622 2021-08-07  Bruno Haible  <bruno@clisp.org>
24624         quotearg: Tweak last commit.
24625         * lib/quotearg.h: Don't include <stddef.h>. Remove stray semicolon.
24627 2021-08-07  Bruno Haible  <bruno@clisp.org>
24629         malloca: Tweak last commit.
24630         * lib/malloca.h: Keep use and declaration of mmalloca close together.
24632 2021-08-07  Bruno Haible  <bruno@clisp.org>
24634         dirname-lgpl, sh-quote, system-quote, xstriconv: Clean up includes.
24635         * lib/dirname.h: Don't include <stddef.h>.
24636         * lib/sh-quote.h: Likewise.
24637         * lib/system-quote.h: Likewise.
24638         * lib/xstriconv.h: Likewise.
24640 2021-08-07  Bruno Haible  <bruno@clisp.org>
24642         dfa: Improve GCC 11 allocation-deallocation checking.
24643         * lib/dfa.h (dfamust): Declare that deallocation must happen through
24644         dfamustfree.
24646 2021-08-06  Paul Eggert  <eggert@cs.ucla.edu>
24648         glob: merge from glibc
24649         * lib/glob-libc.h, lib/glob.c: Merge changes from glibc 2.34.
24650         The result should be copyable directly into glibc.
24651         * modules/glob-h (glob-libc.gl.h): Also omit __THROWNL.
24653 2021-08-03  Simon Josefsson  <simon@josefsson.org>
24655         announce-gen: Print SHA1/B64(SHA256) instead of MD5/SHA1.
24656         * build-aux/announce-gen (%digest_classes): Removed.
24657         (usage): Doc fix.
24658         (print_checksums): Instead of MD5/SHA1, print SHA1 and
24659         B64(SHA256), inspired by OpenSSH announcements.
24661         maintainer-makefile: Print checksums by default.
24662         * top/maint.mk (announcement): Drop --no-print-checksums.
24664 2021-08-02  Paul Eggert  <eggert@cs.ucla.edu>
24666         manywarnings: enable some malloc warnings
24667         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Stop adding
24668         -Wno-analyzer-double-free, -Wno-analyzer-null-dereference, and
24669         -Wno-analyzer-use-after-free, as these false alarms don’t seem
24670         to be as much of an issue now that we’ve pacified a couple
24671         of individual modules and GCC has some bug fixes.
24673         dfa: omit unneeded malloc+free
24674         Problem indirectly found by Coverity.
24675         * lib/dfa.c (enlistnew): New function, with most of the body of
24676         the old ‘enlist’.  It assumes its arg NEW has been malloced and
24677         can be freed eventually.
24678         (enlist, addlists, dfamust): Use it.
24679         (dfamust): Omit an unnecessary malloc+free.
24681         year2038: port to unusual time_t platforms
24682         * m4/year2038.m4 (gl_YEAR2038_TEST_INCLUDES): Check that time_t
24683         can go to 2**32 - 1, not to 2**63 - 1, as the former is enough to
24684         be year 2038 safe.  Unsigned 32-bit time_t (AmigaOS) and signed
24685         40-bit time_t (Unisys ClearPath) have occurred in the wild, and
24686         even if Gnulib code is rarely or never ported to them there’s no
24687         need to exclude them merely because of year 2038 issues.
24688         (gl_YEAR2038_BODY): Adjust messages to match.  Use 2**32 - 1,
24689         not 2**32, as the test timestamp, to allow unsigned 32-bit time_t.
24691 2021-08-01  Paul Eggert  <eggert@cs.ucla.edu>
24693         xalloc: no attribute (malloc (free)) on inline
24694         The GCC manual says you can’t use __attribute__ ((__malloc__
24695         (free, 1))) on inline functions.  Problem discovered when
24696         compiling diffutils 3.8 on RHEL 8.4 using a GCC 11.2.0 that I
24697         built myself.  Perhaps the problem was not discovered earlier
24698         because the attribute works with ‘free’ (which is what I was
24699         seeing before on Fedora 34) but not with ‘rpl_free’ (seen on RHEL
24700         8.4).  Anyway, the GCC manual says it shouldn’t work at all, so
24701         don’t use it.
24702         * lib/xalloc.h (xnmalloc, xcharalloc): No longer inline.
24703         * lib/xmalloc.c (xcharalloc, xnmalloc): Move function bodies here.
24704         * m4/gnulib-common.m4 (_GL_ATTRIBUTE_DEALLOC)
24705         (_GL_ATTRIBUTE_DEALLOC_FREE): Document that these cannot be
24706         used on inline functions, as per the GCC 11.2.1 manual.
24708         sigsegv-tests: make more things static
24709         * tests/test-sigsegv-catch-segv1.c:
24710         * tests/test-sigsegv-catch-stackoverflow1.c:
24711         * tests/test-sigsegv-catch-stackoverflow2.c:
24712         Declare some functions and variables static, to pacify GCC when
24713         warning about external functions missing declarations.
24715         maint: improve -fanalyzer malloc checking
24716         * lib/backup-internal.h, lib/backupfile.h:
24717         * lib/canonicalize.h, lib/dfa.h, lib/dirname.h, lib/exclude.h:
24718         * lib/filenamecat.h, lib/malloca.h, lib/modechange.h:
24719         * lib/mountlist.h, lib/pagealign_alloc.h, lib/quotearg.h:
24720         * lib/readutmp.h, lib/savedir.h, lib/sh-quote.h, lib/system-quote.h:
24721         * lib/trim.h, lib/xgetcwd.h, lib/xgethostname.h, lib/xmalloca.h:
24722         * lib/xreadlink.h, lib/xstriconv.h, lib/xvasprintf.h:
24723         Add malloc-related attributes and include stdlib.h as needed.
24724         * lib/dfa.c: Include verify.h.
24725         (assume_nonnull): New macro.
24726         (dfamust): Use it to pacify GCC.
24727         * lib/malloca.c (mmalloca): Redo to pacify GCC, to cut down on the
24728         number of casts, and to avoid signed integer overflow on
24729         theoretical platforms.
24730         * lib/vasnprintf.c, tests/test-argmatch.c:
24731         Disable -Wanalyzer-null-argument here.
24732         * m4/manywarnings.m4: Update GCC bug report number in comment.
24734 2021-08-01  Jim Meyering  <meyering@fb.com>
24736         regex: pacify GCC 11.2.1's -fanalyzer
24737         * lib/regex_internal.c (re_node_set_merge):
24738         Add a debug assertion to pacify GCC 11.2.1's -fanalyzer.
24740 2021-08-01  Bruno Haible  <bruno@clisp.org>
24742         limits-h tests: Add tests for BOOL_MAX and BOOL_WIDTH.
24743         * tests/test-limits-h.c (bool_attrs): New variable.
24744         Check value of BOOL_MAX.
24746 2021-07-31  Paul Eggert  <eggert@cs.ucla.edu>
24748         regex: pacify GCC 11.2 -fanalyzer
24749         * lib/regex_internal.c (re_node_set_insert):
24750         Add a debug assertion to pacify GCC 11.2 -fanalyzer.
24752         maint: pacify GCC 11.2 -fanalyzer in crypto tests
24753         * tests/bench-digest.h (main): Report an error after memory
24754         exhaustion, instead of using a null pointer.
24756 2021-07-30  Paul Eggert  <eggert@cs.ucla.edu>
24758         xalloc: add malloc-related function attributes
24759         * lib/quotearg.h, lib/xalloc.h: Include stdlib.h, for
24760         the benefit of _GL_ATTRIBUTE_RETURNS_NONNULL.
24761         * lib/quotearg.h (clone_quoting_options):
24762         * lib/xalloc.h (xmalloc, ximalloc, xzalloc, xizalloc, xcalloc)
24763         (xicalloc, xrealloc, xirealloc, xireallocarray, x2realloc)
24764         (x2nrealloc, xmemdup, ximemdup, xstrdup, xnmalloc, xcharalloc):
24765         Add _GL_ATTRIBUTE_DALLOC_FREE and _GL_ATTRIBUTE_RETURNS_NONNULL
24766         attributes as appropriate.
24768         gnulib-common: update for gcc -Wmismatched-dealloc
24769         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define the macros
24770         _GL_ATTRIBUTE_DEALLOC and _GL_ATTRIBUTE_DEALLOC_FREE.  These can
24771         be useful with gcc -Wmismatched-dealloc.
24773         gnulib-common: update for C2x 2020-12-11 draft
24774         Use blessed-by-draft-standard way to test for [[__deprecated__]]
24775         etc.; this is supported by GCC 11 and the fallback code should
24776         work fine with GCC 10 and earlier.
24777         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define the macro
24778         _GL_HAS_C_ATTRIBUTE, and use it instead of __STDC_VERSION__ in
24779         deciding whether to use C2x attributes like [[__deprecated__]].
24781         manywarnings: document GCC 11 warnings
24782         * build-aux/gcc-warning.spec: Add warnings introduced in GCC 11.
24783         None of them require Gnulib code changes, so this is just
24784         a documentation change.
24786         limits-h: add BOOL_MAX, BOOL_WIDTH
24787         * doc/posix-headers/limits.texi (limits.h): Document them.
24788         * lib/limits.in.h: Also define CHAR_WIDTH etc. if C2x.
24789         (BOOL_MAX, BOOL_WIDTH): New macros, from C2x.
24790         * m4/limits-h.m4 (gl_LIMITS_H): Also check BOOL_WIDTH.
24792 2021-07-28  Simon Josefsson  <simon@josefsson.org>
24794         maintainer-makefile: Respect cfg.mk setting announcement_Cc_,
24795         reverting most of the previous patch.
24796         * top/maint.mk (announcement_mail_Cc_stable): Rename back to
24797         announcement_Cc_stable.
24798         (announcement_Cc_alpha): Rename back to
24799         announcement_mail_Cc_alpha.
24800         (announcement_Cc_): Renamed from announcement_mail_Cc_.
24801         (announcement_mail_headers_stable)
24802         (announcement_mail_headers_alpha): Use announcement_Cc_ again.
24804 2021-07-28  Simon Josefsson  <simon@josefsson.org>
24806         maintainer-makefile: Fix announcement mail CC's.
24807         * top/maint.mk (announcement_Cc_stable): Rename to
24808         announcement_mail_Cc_stable.
24809         (announcement_Cc_alpha): Rename to announcement_mail_Cc_alpha.
24810         (announcement_mail_headers_stable)
24811         (announcement_mail_headers_alpha): Use announcement_mail_Cc_
24812         instead of announcement_Cc_.
24814 2021-07-25  Bruno Haible  <bruno@clisp.org>
24816         Assume GNU gettext >= 0.17.
24817         * modules/vasprintf (Notice): Remove.
24818         * modules/xvasprintf (Notice): Remove.
24819         * modules/xprintf (Notice): Remove.
24820         * modules/error (Notice): Remove.
24821         * modules/verror (Notice): Remove.
24822         * modules/argp (Notice): Remove.
24823         * modules/propername (Notice): Remove.
24824         * lib/propername.h: Remove outdated comment.
24826 2021-07-19  Simon Josefsson  <simon@josefsson.org>
24828         gendocs.sh: Fix local rendering of HTML manuals.
24829         * build-aux/gendocs.sh (htmlarg): Don't use relative URLs.
24831 2021-07-18  Paul Eggert  <eggert@cs.ucla.edu>
24833         explicit_bzero-tests: pacify GCC better
24834         Problem reported by Bruno Haible in:
24835         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00039.html
24836         * tests/test-explicit_bzero.c: Ignore -Wmaybe-uninitialized.
24837         (stackbuf): Remove this static pointer, reverting recent change.
24838         (do_secret_stuff, test_stack): Revert these related changes too.
24840 2021-07-17  Paul Eggert  <eggert@cs.ucla.edu>
24842         memrchr-tests: pacify GCC
24843         Pacify GCC 11.1.1 20210531 (Red Hat 11.1.1-3) x86-64.
24844         * tests/test-memrchr.c: Disable -Wmaybe-uninitialized.
24846         explicit_bzero-tests: pacify GCC
24847         Redo to pacify -Wmaybe-uninitialized with
24848         GCC 11.1.1 20210531 (Red Hat 11.1.1-3) x86-64.
24849         * tests/test-explicit_bzero.c (stackbuf): New static pointer.
24850         (do_secret_stuff): Use it.
24851         (test_stack): Set it to a local buffer.
24853         posixtm: pacify latest GCC
24854         Also, modernize while I’m at it.
24855         * lib/posixtm.c: Include c-ctype.h, idx.h, intprops.h, verify.h
24856         instead of stdlib.h.
24857         (ISDIGIT): Remove.  All uses replaced by c_isdigit.
24858         (year, posix_time_parse): Prefer idx_t to size_t.  Use assume
24859         instead of abort.
24860         (posixtime): Do not parse twice; once is enough.  That way, we
24861         needn’t worry about a bogus warning about strcpy overrunning a
24862         buffer from GCC 11.1.1 20210531 (Red Hat 11.1.1-3) x86-64
24863         when coreutils is configured with --enable-gcc-warnings.
24864         * modules/posixtm (Depends-on): Add c-ctype, intprops, verify.
24865         Remove stpcpy.
24867 2021-07-17  Bruno Haible  <bruno@clisp.org>
24869         Don't use '#pragma weak' for thread functions in Linux/glibc>=2.34.
24870         Suggested by Florian Weimer <fweimer@redhat.com> in
24871         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00211.html>.
24872         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): Set gl_pthread_in_glibc and set
24873         LIBPMULTITHREAD accordingly.
24874         (gl_STDTHREADLIB_BODY): Update comments.
24875         (gl_THREADLIB_BODY): Define USE_POSIX_THREADS_FROM_LIBC.
24876         * lib/glthread/thread.h (c11_threads_in_use): Define to 1 if all POSIX
24877         thread functions are in libc.
24878         * lib/glthread/lock.h (c11_threads_in_use): Likewise.
24879         * lib/glthread/cond.h (c11_threads_in_use): Likewise.
24880         * lib/glthread/tls.h (c11_threads_in_use): Likewise.
24882 2021-07-17  Bruno Haible  <bruno@clisp.org>
24884         Fix cross-compilation test results.
24885         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): When cross-compiling, include
24886         <string.h> before testing __GNU_LIBRARY__.
24887         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Likewise.
24888         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Likewise.
24890 2021-07-14  Paul Eggert  <eggert@cs.ucla.edu>
24892         regex: modernize to newer regex bugset
24893         Problem reported by Hiroo Hayashi in:
24894         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00024.html
24895         * m4/regex.m4 (gl_REGEX): Allow newer glibc behavior for ()0|\1,
24896         behavior where the regex compiles but does not match.
24897         Test for glibc bug 11053.
24898         * tests/test-regex.c (bug_regex11, main): Add casts needed
24899         for printf portability.
24900         (main): Allow newer glibc behavior for ()0|\1.
24902         regex: fix shell quoting problem in configuration
24903         * m4/regex.m4 (gl_REGEX): Fix quoting problems.
24904         These C programs are put into unquoted here-documents,
24905         so $ and \ need to be quoted.
24907 2021-07-08  Paul Eggert  <eggert@cs.ucla.edu>
24909         select: port better to MinGW
24910         Problem reported by Eli Zaretskii in:
24911         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00017.html
24912         * lib/select.c (rpl_select) [_WIN32 && !__CYGWIN__]:
24913         Pass a SOCKET, not a HANDLE, to FD_ISSET.
24915 2021-07-06  Paul Eggert  <eggert@cs.ucla.edu>
24917         year2038: Add --disable-year2038 option
24918         Also, document this stuff better.  Suggested by Bruno Haible in:
24919         https://lists.gnu.org/r/bug-gnulib/2021-07/msg00011.html
24920         * doc/year2038.texi: Document --disable-year2038.
24921         * m4/year2038.m4 (gl_YEAR2038_BODY): Support ‘./configure
24922         --disable-year2038’ to disable 64-bit time_t when that is not the
24923         default.  Arg is now either empty or nonempty (not a shell
24924         command) and is evaluated at m4 expansion time instead of at
24925         runtime; all callers changed.
24927         doc: clarify which module fixes 32-bit time_t
24928         * doc/posix-headers/time.texi: Make it clear that the 32-bit
24929         time_t problem is addressed by the year2038 module, not
24930         by the time module.
24932 2021-07-01  Paul Eggert  <eggert@cs.ucla.edu>
24934         year2038: support glibc 2.34 _TIME_BITS=64
24935         In glibc 2.34 on Linux kernels where time_t is traditionally 32-bit,
24936         defining _FILE_OFFSET_BITS=64 and _TIME_BITS=64 makes time_t 64-bit.
24937         Apps must define both macros.  Gnulib applications that use either
24938         the largefile or the year2038 modules will want this behavior;
24939         largefile because it deals with the off_t and ino_t components of
24940         struct stat already, and so should also deal with time_t.
24941         * NEWS, doc/largefile.texi, doc/posix-headers/time.texi:
24942         Mention this.
24943         * m4/largefile.m4: Override two macros even in Autoconf 2.70 and later.
24944         (_AC_SYS_LARGEFILE_MACRO_VALUE): #undef $1 before #defining it, in
24945         case some other Gnulib macro has #defined it.
24946         (AC_SYS_LARGEFILE): Use AS_IF and AS_CASE to propagate AC_REQUIREs.
24947         Invoke gl_YEAR2038_BODY if we need to set _FILE_OFFSET_BITS=64.
24948         * m4/year2038.m4 (gl_YEAR2038_TEST_INCLUDES): New macro.
24949         (gl_YEAR2038_BODY): New macro, with gl_YEAR2038’s old body; this
24950         macro is designed to be used directly instead of being
24951         AC_REQUIREd.  It takes an argument specifying whether 64-bit is
24952         required.  Set _TIME_BITS=64 if this makes a difference in time_t
24953         width when setting _FILE_OFFSET_BITS=64.  Do not warn about
24954         32-bit time_t more than once.
24955         * modules/largefile (Files): Add year2038.m4.
24956         (Depends-on): Require gl_YEAR2038_EARLY.
24958         relocatable-prog-wrapper: add m4 files
24959         Add .m4 files needed for standalone relocatable-prog-wrapper, so
24960         that ‘./gnulib-tool --test relocatable-prog-wrapper’ does not fail
24961         with diagnostics like ‘configure.ac:63: error: possibly undefined
24962         macro: gl_FUNC_MALLOC_POSIX’.
24963         * modules/relocatable-prog-wrapper (Files): Add m4/free.m4,
24964         m4/malloc.m4, m4/mempcpy.m4, m4/rawmemchr.m4, m4/realloc.m4.
24966 2021-06-28  Bruno Haible  <bruno@clisp.org>
24968         strerror-override: Fix possible compilation error.
24969         Reported by Thomas Klausner <wiz@netbsd.org>.
24970         * lib/strerror-override.h (GNULIB_defined_strerror_override_macro): New
24971         macro.
24972         * lib/strerror-override.c (strerror_override): Don't define if
24973         GNULIB_defined_strerror_override_macro is set.
24975 2021-06-27  Bruno Haible  <bruno@clisp.org>
24977         environ: Fix wrong autoconf test result in C++ mode.
24978         * m4/environ.m4 (gt_CHECK_VAR_DECL): Use a typedef'ed type, not an
24979         anonymous type.
24981 2021-06-22  Egor Ignatov  <egori@altlinux.org>  (tiny change)
24983         regex: fix undefined behavior
24984         Problem reported by Paul Eggert in:
24985         https://lists.gnu.org/r/bug-gnulib/2021-06/msg00115.html
24986         * lib/regexec.c (proceed_next_node):
24987         Don’t insert already-inserted node.
24989 2021-06-21  Eric Blake  <eblake@redhat.com>
24991         sigsegv, sigsegv-tests: Assign my contributions to the FSF.
24992         * m4/sigaltstack.m4: Change copyright notice: Write "Copyright (C) FSF"
24993         instead of "Copyright (C) Eric Blake".
24994         * tests/altstack-util.h: Likewise.
24995         * tests/test-sigsegv-catch-stackoverflow1.c: Likewise.
24996         * tests/test-sigsegv-catch-stackoverflow2.c: Likewise.
24998 2021-06-20  Bruno Haible  <bruno@clisp.org>
25000         unistd: Avoid compilation error in C++ mode on Solaris, HP-UX, mingw.
25001         Reported by Eli Zaretskii <eliz@gnu.org> in
25002         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00135.html>.
25003         * lib/unistd.in.h (swab): Consider different declarations on Solaris,
25004         HP-UX, and old mingw.
25006 2021-06-20  Bruno Haible  <bruno@clisp.org>
25008         Sync with GNU gettext.
25009         * lib/printf-parse.c: Ignore IN_LIBINTL and IN_LIBASPRINTF.
25010         * lib/vasnprintf.c: Ignore IN_LIBINTL.
25012 2021-06-19  Bruno Haible  <bruno@clisp.org>
25014         Sync with GNU gettext.
25015         * lib/tsearch.c: Ignore IN_LIBINTL.
25016         * lib/localename-table.h: Likewise.
25017         * lib/localename.c: Ignore IN_LIBINTL in some places.
25019 2021-06-19  Bruno Haible  <bruno@clisp.org>
25021         unistd: Improve conflict resolution between gnulib and textstyle.h.
25022         * lib/unistd.in.h (GNULIB_overrides_isatty): New macro.
25024 2021-06-19  Bruno Haible  <bruno@clisp.org>
25026         stdio: Improve conflict resolution between gnulib and libintl.h.
25027         * lib/stdio.in.h (GNULIB_overrides_snprintf, GNULIB_overrides_sprintf,
25028         GNULIB_overrides_asprintf, GNULIB_overrides_vasprintf,
25029         GNULIB_overrides_vsnprintf, GNULIB_overrides_vsprintf): New macros.
25031 2021-06-19  Bruno Haible  <bruno@clisp.org>
25033         declared.sh: Allow parsing 'extern "C"' lines.
25034         * build-aux/declared.sh: Don't concatenate lines to an 'extern "C" {'
25035         line.
25037 2021-06-19  Bruno Haible  <bruno@clisp.org>
25039         unitypes: Fix trouble caused by installed older versions of unitypes.h.
25040         * modules/unitypes (configure.ac): Define _UC_RESTRICT through config.h.
25042 2021-06-19  Bruno Haible  <bruno@clisp.org>
25044         sigsegv, sigsegv-tests: Assign my contributions to the FSF.
25045         * lib/sigsegv.in.h: Change copyright notice: Write "Copyright (C) FSF"
25046         instead of "Copyright (C) Bruno Haible".
25047         * lib/sigsegv.c: Likewise.
25048         * lib/stackvma.h: Likewise.
25049         * lib/stackvma.c: Likewise.
25050         * m4/sigaltstack.m4: Likewise.
25051         * m4/stack-direction.m4: Likewise.
25052         * tests/altstack-util.h: Likewise.
25053         * tests/mmap-anon-util.h: Likewise.
25054         * tests/test-sigsegv-catch-segv1.c: Likewise.
25055         * tests/test-sigsegv-catch-segv2.c: Likewise.
25056         * tests/test-sigsegv-catch-stackoverflow1.c: Likewise.
25057         * tests/test-sigsegv-catch-stackoverflow2.c: Likewise.
25059 2021-06-18  Darren Kenny  <darren.kenny@oracle.com>  (tiny change)
25061         argp: Avoid possible NULL access in argp_help.
25062         Reported by Coverity. The invocation chain is:
25063         argp_help -> _help -> fill_in_uparams -> validate_uparams.
25064         * lib/argp-help.c (validate_uparams): Don't crash if state == NULL.
25066 2021-06-16  Bruno Haible  <bruno@clisp.org>
25068         tsearch: Relicense under LGPLv2+.
25069         * modules/tsearch (License): Change to LGPLv2+.
25070         * lib/tsearch.c: Update license notice.
25072 2021-06-15  Bruno Haible  <bruno@clisp.org>
25074         pipe-filter-ii tests: Fix long-standing failure on native Windows.
25075         * tests/test-pipe-filter-ii2-main.c: Include binary-io.h.
25076         (main): Avoid NL to CRLF conversion on standard output.
25077         * tests/test-pipe-filter-ii2-child.c: Include <unistd.h>, binary-io.h.
25078         (main): Avoid NL to CRLF conversion on standard output.
25080 2021-06-15  Bruno Haible  <bruno@clisp.org>
25082         xnanosleep: Improve module description.
25083         * modules/xnanosleep (Description): Improve.
25084         * lib/xnanosleep.h: Add comment. Make includable from C++.
25085         * lib/xnanosleep.c: Update comment.
25087 2021-06-15  Bruno Haible  <bruno@clisp.org>
25089         xfreopen: Improve module description.
25090         * modules/xfreopen (Description): Improve.
25091         * lib/xfreopen.h: Add comments. Make includable from C++.
25092         * lib/xfreopen.c: Update comment.
25094 2021-06-14  Paul Eggert  <eggert@cs.ucla.edu>
25096         idx: new printf/scanf length modifier macro
25097         * lib/idx.h (pIDX): New macro.
25099 2021-06-13  Bruno Haible  <bruno@clisp.org>
25101         Align 2011-11-26 patch to 2021-04-11 patch (regression from 2021-04-11).
25102         Reported by Paul Eggert.
25103         * m4/unistd_h.m4 (gl_UNISTD_H_REQUIRE_DEFAULTS): Also initialize
25104         GNULIB_UNISTD_H_GETOPT variable.
25105         * modules/getopt-posix (configure.ac): Set GNULIB_UNISTD_H_GETOPT
25106         variable.
25107         * modules/unistd (Makefile.am): Rely on ${gl_include_guard_prefix}
25108         processing done by gnulib-tool since 2021-04-11.
25109         * gnulib-tool: Revert last change.
25110         * pygnulib/GLEmiter.py: Likewise.
25112 2021-06-13  Paul Eggert  <eggert@cs.ucla.edu>
25114         * lib/stack.h (_GL_STACK_PREFIX): Omit stray semicolon.
25116         getopt-gnu: port back to Solaris 10
25117         * gnulib-tool (func_emit_lib_Makefile_am)
25118         (func_emit_tests_Makefile_am): Don’t substitute things like
25119         $(GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT),
25120         as this mishandles unistd and getopt-gnu, which breaks
25121         ‘make check’ on Solaris 10 with getopt-gnu.
25122         * pygnulib/GLEmiter.py (lib_Makefile_am, tests_Makefile_am):
25123         Likewise, albeit hackier since I did not test this and
25124         so went with a trivial hack instead.
25126 2021-06-13  Bruno Haible  <bruno@clisp.org>
25128         ialloc: Put appropriate license notice in source files.
25129         * lib/ialloc.h: Use LGPLv3+ notice.
25130         * lib/ialloc.c: Likewise.
25132 2021-06-11  Paul Eggert  <eggert@cs.ucla.edu>
25134         xalloc: new idx_t-based allocators
25135         This is for code that prefers to use idx_t for sizes.
25136         * lib/basename.c (base_name):
25137         * lib/dfa.c (mbs_to_wchar, state_index, dfaoptimize, dfaanalyze)
25138         (icatalloc, enlist, allocmust, dfamust):
25139         * lib/exclude.c (struct exclude_pattern, free_exclude_segment)
25140         (file_pattern_matches, add_exclude, add_exclude_fp):
25141         * lib/getusershell.c (line_size, readname):
25142         * lib/linebuffer.c (readlinebuffer_delim):
25143         * lib/linebuffer.h (struct linebuffer):
25144         * lib/readtokens.c (readtoken, readtokens):
25145         * lib/readutmp.c (read_utmp):
25146         * lib/savedir.c (streamsavedir):
25147         * lib/stack.h (_GL_STACK_TYPE, _GL_STACK_PREFIX):
25148         * lib/userspec.c (parse_with_separator):
25149         * lib/xgethostname.c (XGETANAME):
25150         Prefer idx_t to size_t for indexes, and use idx_t-related allocators.
25151         * lib/basename.c: Do not include xstrndup.h.
25152         (basename): Simplify by always using memcpy.
25153         * lib/xalloc.h (ximalloc, xizalloc, xicalloc, xirealloc)
25154         (xireallocarray, ximemdup, ximemdup0) [GNULIB_XALLOC]:
25155         New decls.
25156         (x2nrealloc): Now just a decl, as the body is moved into xmalloc.c.
25157         * lib/xmalloc.c: Include ialloc.h.
25158         Rename some local parameters to be consistent with the .h files.
25159         (nonnull): New static function.
25160         (xmalloc, xcalloc): Simplify by using nonnull.
25161         (ximalloc, xirealloc, xireallocarray, xizalloc, xicalloc)
25162         (ximemdup, ximemdup0): New functions.
25163         (x2nrealloc): Moved here from xalloc.h.
25164         * modules/xalloc (Depends-on): Add ialloc.
25165         * modules/dirname (Depends-on): Removbe xstrndup.
25166         * modules/linebuffer (Depends-on): Add idx.
25168         ialloc: new module
25169         * lib/ialloc.c, lib/ialloc.h, modules/ialloc: New files.
25171         exclude: improve wide-character hashing
25172         * lib/exclude.c (string_hasher_ci): Take the modulo at the end
25173         rather than each time a wide character is retrieved; this should
25174         be more efficient and should hash better.
25176 2021-06-11  Bruno Haible  <bruno@clisp.org>
25178         Make message in last commit more precise.
25179         Suggested by Eric Blake.
25180         * gnulib-tool (func_emit_tests_Makefile_am): Add more precision to
25181         'check-notice' message.
25183 2021-06-10  Bruno Haible  <bruno@clisp.org>
25185         Clarify where to report test failures from Gnulib tests.
25186         * gnulib-tool (func_emit_tests_Makefile_am): Emit a dependency of
25187         'check-am' on 'check-notice' that prints a notice.
25189 2021-06-10  Bruno Haible  <bruno@clisp.org>
25191         Clarify that compiler warnings in the Gnulib tests can be ignored.
25192         * gnulib-tool (func_emit_tests_Makefile_am): Emit overrides for CFLAGS
25193         and CXXFLAGS. Emit a dependency of 'all' on 'all-notice' that prints a
25194         notice.
25195         (func_emit_initmacro_start): Add a second argument. If it is true, emit
25196         code to require gl_CC_ALLOW_WARNINGS and gl_CXX_ALLOW_WARNINGS.
25197         (func_import, func_create_testdir): All callers updated.
25198         * m4/gnulib-common.m4 (gl_CC_ALLOW_WARNINGS, gl_CXX_ALLOW_WARNINGS): New
25199         macros.
25201 2021-06-09  Bruno Haible  <bruno@clisp.org>
25203         sigsegv tests: Hide a null pointer from the compiler's optimizations.
25204         Patch by Paul Eggert.
25205         * tests/test-sigsegv-catch-stackoverflow2.c
25206         (null_pointer_to_volatile_int): New variable.
25207         (main): Use it.
25209 2021-06-07  Bruno Haible  <bruno@clisp.org>
25211         get_ppid_of: Add support for DragonFly BSD.
25212         * lib/get_ppid_of.c: Treat DragonFly BSD like FreeBSD.
25214 2021-06-07  Bruno Haible  <bruno@clisp.org>
25216         sigsegv: Document context type for DragonFly BSD.
25217         * lib/sigsegv.in.h (stackoverflow_context_t): On DragonFly BSD, it is a
25218         pointer to 'struct sigcontext'.
25220 2021-06-07  Bruno Haible  <bruno@clisp.org>
25222         dynarray, scratch_buffer: Fix VPATH builds (regression from yesterday).
25223         * modules/dynarray (configure.ac): Invoke AC_PROG_MKDIR_P.
25224         (Makefile.am): Create malloc/ directory before creating
25225         malloc/dynarray.gl.h and malloc/dynarray-skeleton.gl.h.
25226         * modules/scratch_buffer (configure.ac): Invoke AC_PROG_MKDIR_P.
25227         (Makefile.am): Create malloc/ directory before creating
25228         malloc/scratch_buffer.gl.h.
25230 2021-06-07  Bruno Haible  <bruno@clisp.org>
25232         ptsname_r: Add support for DragonFly BSD 6.0.
25233         * lib/ptsname_r.c (__ptsname_r): Add implementation for DragonFly BSD.
25234         * tests/test-ptsname_r.c (main): Treat Dragonfly BSD like Solaris.
25236 2021-06-07  Bruno Haible  <bruno@clisp.org>
25238         Avoid some test failures on DragonFly BSD 6.0.
25239         * tests/test-c32isalnum.c (main): On Dragonfly BSD, disable tests that
25240         fail.
25241         * tests/test-c32isalpha.c (main): Likewise.
25242         * tests/test-c32islower.c (main): Likewise.
25243         * tests/test-c32isupper.c (main): Likewise.
25244         * tests/test-ptsname.c (main): Treat Dragonfly BSD like Solaris.
25246 2021-06-07  Kamil Dudka  <kdudka@redhat.com>
25248         mountlist: recognize fuse.portal as dummy file system
25249         * lib/mountlist.c [ME_DUMMY_0]: Add "fuse.portal" as
25250         a dummy file system (used in flatpak implementations).
25252 2021-06-07  Bruno Haible  <bruno@clisp.org>
25254         host-os: Add support for DragonFly BSD.
25255         * m4/host-os.m4 (gl_HOST_OS): On DragonFly BSD, set
25256         HOST_OPERATING_SYSTEM to "DragonFly BSD", not "Dragonfly".
25258 2021-06-07  Bruno Haible  <bruno@clisp.org>
25260         thread: Fix test link error on DragonFly BSD 6.0.
25261         * lib/glthread/thread.c (gl_thread_create): Moved to here...
25262         * lib/glthread/thread.h (gl_thread_create): ...from here.
25263         (_GLTHREAD_THREAD_INLINE): Remove macro.
25264         Remove _GL_INLINE_HEADER_BEGIN/END invocations.
25266 2021-06-06  Bruno Haible  <bruno@clisp.org>
25268         sigsegv: Avoid a gcc warning "declaration of 'sig' shadows a parameter".
25269         Reported by Dmitry V. Levin <ldv@altlinux.org> in
25270         <https://lists.gnu.org/archive/html/bug-gnulib/2021-06/msg00018.html>.
25271         * lib/sigsegv.c (sigsegv_handler): Use a different local variable name
25272         than 'sig'.
25274 2021-06-06  Bruno Haible  <bruno@clisp.org>
25276         scratch_buffer: Avoid conflict with prepr. macros owned by the system.
25277         * lib/scratch_buffer.h: Don't include <libc-config.h>. Define
25278         _GL_LIKELY, _GL_UNLIKELY. Include malloc/scratch_buffer.gl.h instead of
25279         malloc/scratch_buffer.h.
25280         * modules/scratch_buffer (Depends-on): Add builtin-expect.
25281         (Makefile.am): Arrange to create malloc/scratch_buffer.gl.h from
25282         malloc/scratch_buffer.h.
25284 2021-06-06  Bruno Haible  <bruno@clisp.org>
25286         dynarray: Avoid conflict with preprocessor macros owned by the system.
25287         * lib/dynarray.h: Don't include <libc-config.h>. Define _GL_LIKELY,
25288         _GL_UNLIKELY. Include malloc/dynarray.gl.h instead of malloc/dynarray.h.
25289         Include malloc/dynarray-skeleton.gl.h instead of
25290         malloc/dynarray-skeleton.c.
25291         * modules/dynarray (Depends-on): Add builtin-expect.
25292         (Makefile.am): Arrange to create malloc/dynarray.gl.h from
25293         malloc/dynarray.h and malloc/dynarray-skeleton.gl.h from
25294         malloc/dynarray-skeleton.c.
25296 2021-06-06  Bruno Haible  <bruno@clisp.org>
25298         glob-h: Avoid conflict with preprocessor macros owned by the system.
25299         This fixes a compilation error on DragonFly BSD 6.0.
25300         * lib/glob.in.h: Don't include <libc-config.h>. Don't define __USE_GNU.
25301         Include glob-libc.gl.h instead of glob-libc.h.
25302         * modules/glob-h (Makefile.am): Arrange to create glob-libc.gl.h from
25303         glob-libc.h.
25304         * lib/libc-config.h: Add comment.
25306 2021-06-06  Dmitry V. Levin  <ldv@altlinux.org>
25308         * tests/test-regex.c (tests): Add test cases for *+ and ** regressions
25309         fixed by the previous commit.
25311         * tests/test-regex.c (tests): Remove the comment saying that some tests
25312         are not used.  That comment was copied along with tests from glibc
25313         where some of these tests are commented out.
25315 2021-06-06  Egor Ignatov  <egori@altlinux.org>  (tiny change)
25317         * lib/regexec.c (set_regs): Pop if CUR_NODE has already been checked
25318         only when we have a fail stack.
25320 2021-06-05  Bruno Haible  <bruno@clisp.org>
25322         lib-symbol-visibility: Make configure check work for newer GCC.
25323         Reported by Ozkan Sezer <sezeroz@gmail.com> in
25324         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00117.html>.
25325         * m4/visibility.m4 (gl_VISIBILITY): Add a function definition for each
25326         declaration in the test program.
25328 2021-06-05  Bruno Haible  <bruno@clisp.org>
25330         vasnprintf: Don't leak memory when memory allocation fails.
25331         Found by Coverity. Reported by Mike Fabian <mfabian@redhat.com> in
25332         <https://lists.gnu.org/archive/html/bug-libunistring/2021-06/msg00000.html>.
25333         * lib/vasnprintf.c (VASNPRINTF): In places where a local variable points
25334         to heap-allocated storage, free that storage before doing
25335         'goto out_of_memory;'.
25337 2021-06-04  Bruno Haible  <bruno@clisp.org>
25339         gnulib-tool: Stop doing license notice replacements.
25340         * gnulib-tool: Don't document --more-symlinks and --more-hardlinks any
25341         more.
25342         (do_copyrights): Remove variable.
25343         (func_import): Don't perform license updates on imported files any more.
25344         * pygnulib/GLInfo.py: Don't document --more-symlinks any more.
25345         * doc/gnulib-intro.texi (Copyright): Document the new situation.
25346         * doc/gnulib.texi (Module description): Likewise.
25347         * NEWS: Mention the change.
25349 2021-06-04  Bruno Haible  <bruno@clisp.org>
25351         git-merge-changelog: Fix license.
25352         * modules/git-merge-changelog (License): Change back to GPL.
25353         * lib/git-merge-changelog.c: Use a GPLv3+ notice.
25355 2021-06-04  Bruno Haible  <bruno@clisp.org>
25357         Put GPLv3+ notices in source files where appropriate.
25358         * lib/*.{h,c}: Use GPLv3+ notice whenever the module description says
25359         so.
25360         * build-aux/pmccabe.css: Likewise.
25362 2021-06-04  Bruno Haible  <bruno@clisp.org>
25364         Put LGPLv3+ notices in source files where appropriate.
25365         * lib/*.{h,c}: Use LGPLv3+ notice whenever the module description says
25366         so.
25368 2021-06-04  Bruno Haible  <bruno@clisp.org>
25370         Put "LGPLv3+ or GPLv2+" notices in source files where appropriate.
25371         * lib/**.{h,c,gperf}: Use "LGPLv3+ or GPLv2+" notice whenever the module
25372         description says so.
25374 2021-06-04  Bruno Haible  <bruno@clisp.org>
25376         Generate correct license notices in libunistring files.
25377         * lib/gen-uni-tables.c (output_library_license, output_tests_license):
25378         New functions.
25379         (output_predicate, output_category, output_combclass,
25380         output_bidi_category, output_decimal_digit, output_digit,
25381         output_numeric, output_mirror, output_joining_type,
25382         output_joining_group, output_scripts, output_scripts_byname,
25383         output_blocks, output_ident_category, output_lbrk_tables,
25384         output_wbrk_tables, output_gbp_table, output_decomposition_tables,
25385         output_composition_tables, output_simple_mapping, output_casing_rules):
25386         Invoke output_library_license.
25387         (output_predicate_test, output_decimal_digit_test, output_digit_test,
25388         output_numeric_test, output_joining_type_test,
25389         output_joining_group_test, output_gbp_test, output_simple_mapping_test):
25390         Invoke output_tests_license.
25391         * lib/uni*/*.h, lib/uni*/*.gperf: Regenerated.
25392         * tests/uni*/*.h: Likewise.
25394 2021-06-04  Bruno Haible  <bruno@clisp.org>
25396         Generate correct license notices in libunistring files.
25397         * lib/uniname/gen-uninames.lisp (main): Emit a copyright and license
25398         notice.
25399         * lib/uniname/uninames.h: Regenerated.
25401 2021-06-04  Bruno Haible  <bruno@clisp.org>
25403         Put LGPLv2+ notices in source files where appropriate.
25404         * lib/**.{h,c,gperf}: Use LGPLv2+ notice whenever the module description
25405         says so.
25407 2021-06-04  Bruno Haible  <bruno@clisp.org>
25409         Put "unlimited" notices in source files where appropriate.
25410         * build-aux/prefix-gnulib-mk: Use "unlimited" notice, since the module
25411         description says so.
25413 2021-06-04  Bruno Haible  <bruno@clisp.org>
25415         Put public domain notices in source files where appropriate.
25416         * lib/{alloca.c,atexit.c,memmove.c}: Use public domain notice.
25418 2021-06-04  Bruno Haible  <bruno@clisp.org>
25420         Revamp check-copyright script.
25421         * check-copyright: Search only the first 50 lines of each file.
25422         Recognize 'LGPLv3+ or GPLv2+', 'unlimited', and 'public domain' license
25423         notices. For files that are part of several modules, consider the
25424         weakest among the licenses. Allocate more room for the first output
25425         column.
25427 2021-06-04  Bruno Haible  <bruno@clisp.org>
25429         gnupload, git-merge-changelog: Fix module description.
25430         * gnulib-tool (func_import, func_create_testdir): Treat
25431         'GPLv2+ build tool' like 'GPLed build tool'.
25432         * pygnulib/GLImport.py (prepare): Likewise.
25433         * modules/gnupload (License): Change to 'GPLv2+ build tool'.
25434         * modules/git-merge-changelog (License): Change to GPLv2+.
25436 2021-06-04  Bruno Haible  <bruno@clisp.org>
25438         New directory with license notices.
25439         * etc/license-notices/*: New files.
25441 2021-05-30  Paul Eggert  <eggert@cs.ucla.edu>
25443         reallocarray-tests: port to weird platforms
25444         * tests/test-reallocarray.c (main): Don’t assume that
25445         PTRDIFF_MAX / 2 + 1 <= SIZE_MAX.  POSIX allows platforms
25446         where this isn’t true, though I don’t know of any examples.
25448         dfa, etc.: prefer xreallocarray to older name
25449         * lib/dfa.c (addtok_mb, realloc_trans_if_necessary, enlist):
25450         * lib/readtokens.c (readtokens):
25451         * tests/uninorm/test-u32-normalize-big.c:
25452         (read_normalization_test_file):
25453         Prefer xreallocarray to the equivalent xnrealloc.
25454         The newer name follows the glibc lead of ‘reallocarray’.
25456 2021-05-30  Bruno Haible  <bruno@clisp.org>
25458         Write 'LGPLv3+ or GPLv2+' instead of 'LGPLv3+ or GPLv2'.
25459         * modules/* (License): Change.
25460         * gnulib-tool (func_import, func_create_testdir): Likewise.
25462 2021-05-29  Paul Eggert  <eggert@cs.ucla.edu>
25464         sigsegv: Port to Solaris 11
25465         Problem reported by Kiyoshi KANAZAWA in:
25466         https://lists.gnu.org/r/bug-m4/2021-05/msg00020.html
25467         * lib/stackvma.c (_FILE_OFFSET_BITS): #undef on Solaris and Android.
25469 2021-05-24  Bruno Haible  <bruno@clisp.org>
25471         c-stack: Document another restriction.
25472         Triggered by a discussion with Paul Eggert.
25473         * lib/c-stack.h: Mention that ACTION should not use nested functions.
25475 2021-05-22  Bruno Haible  <bruno@clisp.org>
25477         stdio: Fix compilation error on DragonFly BSD.
25478         * lib/stdio.in.h (fcloseall): Treat DragonFly BSD like FreeBSD.
25480 2021-05-22  Larkin Nickle  <me@larbob.org>  (tiny change)
25482         getprogname: port to Tru64
25483         * lib/getprogname.c: Treat __osf__ like __sgi, except
25484         with /proc/123 instead of /proc/pinfo/123.
25486 2021-05-21  Paul Eggert  <eggert@cs.ucla.edu>
25488         sigsegv: don’t assume SIGSTKSZ is a constant
25489         * m4/sigaltstack.m4 (SV_SIGALTSTACK): Don’t attempt to override
25490         SIGSTKSZ.  Instead, use an array that is plenty large, while
25491         checking that it’s large enough.  Also, be consistent about
25492         putting that array in static storage rather than on the stack.
25493         * tests/altstack-util.h (SIGSTKSZ): Don’t define.
25494         (MYSTACK_SIZE): New macro, used instead of SIGSTKSZ.
25495         (mystack_storage, mystack): Now static.
25496         (prepare_alternate_stack) [SIGSTKSZ]:
25497         Check that MYSTACK_SIZE is large enough.
25499 2021-05-20  Paul Eggert  <eggert@cs.ucla.edu>
25501         fstatat: doc improvement
25502         * doc/posix-functions/fstatat.texi (fstatat):
25503         Mention AT_EMPTY_PATH when talking about empty strings.
25505 2021-05-18  Bruno Haible  <bruno@clisp.org>
25507         c-stack: Support catching stack overflow on most platforms without libsigsegv.
25508         * lib/c-stack.c: Remove all Solaris-specific code. Include <sigsegv.h>
25509         always.
25510         * m4/c-stack.m4: Remove all Solaris-specific code.
25511         (gl_C_STACK): Test $with_libsigsegv from module 'sigsegv'.
25512         * modules/c-stack (Files): Remove m4/libsigsegv.m4.
25513         (Depends-on): Add sigsegv. Remove havelib, intprops, inttypes, mempcpy,
25514         sigaction, stdbool.
25516 2021-05-16  Bruno Haible  <bruno@clisp.org>
25518         sigsegv, c-stack: Avoid compilation error with glibc >= 2.34.
25519         * lib/sigsegv.in.h (SIGSTKSZ): On glibc systems, redefine to a suitable
25520         constant.
25521         * m4/sigaltstack.m4 (SV_SIGALTSTACK): Likewise.
25522         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Likewise.
25524 2021-05-16  Bruno Haible  <bruno@clisp.org>
25526         sigsegv: Add tests.
25527         * tests/test-sigsegv-catch-segv1.c: New file, from GNU libsigsegv with
25528         modifications.
25529         * tests/test-sigsegv-catch-segv2.c: Likewise.
25530         * tests/test-sigsegv-catch-stackoverflow1.c: Likewise.
25531         * tests/test-sigsegv-catch-stackoverflow2.c: Likewise.
25532         * tests/altstack-util.h: Likewise.
25533         * tests/mmap-anon-util.h: Likewise.
25534         * modules/sigsegv-tests: New file.
25536         sigsegv: New module.
25537         * lib/sigsegv.in.h: New file, from GNU libsigsegv with modifications.
25538         * lib/sigsegv.c: Likewise.
25539         * lib/stackvma.h: Likewise.
25540         * lib/stackvma.c: Likewise.
25541         * m4/sigaltstack.m4: Likewise.
25542         * m4/stack-direction.m4: Likewise.
25543         * modules/sigsegv: New file.
25545 2021-05-15  Pádraig Brady  <P@draigBrady.com>
25547         realloc-gnu: avoid glibc MALLOC_CHECK_ issue
25548         * tests/test-realloc-gnu.c (main): if MALLOC_CHECK_ env var
25549         is set then don't check ENOMEM is returned from realloc().
25550         See https://sourceware.org/bugzilla/show_bug.cgi?id=27870
25551         Note it doesn't suffice to unsetenv() this var within the program,
25552         as the hooks have already been set up at that stage.
25554 2021-05-14  Paul Eggert  <eggert@cs.ucla.edu>
25556         c-stack: work around Solaris 11 bugs
25557         Problem reported by Bruno Haible in:
25558         https://lists.gnu.org/r/bug-gnulib/2021-05/msg00062.html
25559         * lib/c-stack.c: Always include sigsegv.h if HAVE_LIBSIGSEGV.
25560         (USE_LIBSIGSEGV): Do not use libsigsegv if the kernel
25561         has the si_addr bug and libsigsegv is too old to work
25562         around it.
25563         (segv_handler) [!USE_LIBSIGSEGV]: Do not trust si_addr
25564         if BOGUS_SI_ADDR_UPON_STACK_OVERFLOW.
25565         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
25566         Define BOGUS_SI_ADDR_UPON_STACK_OVERFLOW on Solaris 2.11 SPARC.
25567         And do not define HAVE_XSI_STACK_OVERFLOW_HEURISTIC.
25569 2021-05-14  Bruno Haible  <bruno@clisp.org>
25571         fcntl tests: Avoid failure in MacPorts.
25572         Reported by Nicholas Gaya <nicholasgaya@gmail.com> in
25573         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00014.html>.
25574         * tests/test-fcntl.c (main): Close fd 10 before assuming that it is
25575         closed.
25576         * tests/test-execute-main.c: Update comment.
25578 2021-05-14  Bruno Haible  <bruno@clisp.org>
25580         linked-list-unportable-test: New module.
25581         * modules/linked-list-unportable-tests: New file, based on
25582         modules/linked-list-tests.
25583         * modules/linked-list-tests: Remove the unportable tests from here.
25584         Depend on linked-list-unportable-tests.
25586 2021-05-14  Simon Josefsson  <simon@josefsson.org>
25588         valgrind-tests: Doc fix and introduce AM_VALGRINDFLAGS.
25589         * doc/valgrind-tests.texi (Using valgrind automatically): Clarify
25590         when the parallel vs serial test harness is used, suggested by
25591         Bruno Haible <bruno@clisp.org>.
25592         * m4/valgrind-tests.m4: Add VALGRIND_PROGRAM and AM_VALGRINDFLAGS.
25594 2021-05-14  Bruno Haible  <bruno@clisp.org>
25596         malloc-gnu, realloc-gnu, calloc-gnu: Ensure errno gets set to ENOMEM.
25597         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Set gl_cv_func_malloc_posix to
25598         'no' also on Solaris.
25600 2021-05-14  Bruno Haible  <bruno@clisp.org>
25602         DEPENDENCIES: Mention the requirement for 'join'.
25603         Reported by Simon Josefsson <simon@josefsson.org> in
25604         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00047.html>.
25605         * DEPENDENCIES: Mention 'join' among the core POSIX utilities.
25607 2021-05-14  Bruno Haible  <bruno@clisp.org>
25609         *alloc-gnu tests: Use ASSERT macro.
25610         * tests/test-malloc-gnu.c: Include "macros.h".
25611         (main): Use ASSERT.
25612         * tests/test-calloc-gnu.c: Include "macros.h".
25613         (main): Use ASSERT.
25614         * tests/test-realloc-gnu.c: Include "macros.h".
25615         (main): Use ASSERT.
25616         * tests/test-reallocarray.c: Include "macros.h".
25617         (main): Use ASSERT.
25618         * modules/malloc-gnu-tests (Files): Add tests/macros.h.
25619         * modules/calloc-gnu-tests (Files): Likewise.
25620         * modules/realloc-gnu-tests (Files): Likewise.
25621         * modules/reallocarray-tests (Files): Likewise.
25623 2021-05-14  Simon Josefsson  <simon@josefsson.org>
25625         valgrind-tests: Fix 'sh: yes: unknown operand' error.
25626         * m4/valgrind-tests.m4: Protect variable usage.
25628 2021-05-14  Simon Josefsson  <simon@josefsson.org>
25630         valgrind-tests: Fix LOG_VALGRIND when valgrind is missing.
25631         * m4/valgrind-tests.m4: Clear all variables when missing.
25633 2021-05-14  Simon Josefsson  <simon@josefsson.org>
25635         valgrind-tests: Better option handling.
25636         * m4/valgrind-tests.m4: Support new variables VALGRINDFLAGS and
25637         DEFAULT_VALGRINDFLAGS.
25638         * doc/valgrind-tests.texi (Running self-tests under valgrind):
25639         Improve.
25641 2021-05-14  Markus Mützel  <markus.muetzel@gmx.de>  (tiny change)
25643         windows-spawn: Don't assume that UNICODE is not defined.
25644         * lib/windows-spawn.h (compose_handles_block): Use type STARTUPINFOA.
25646 2021-05-13  Bruno Haible  <bruno@clisp.org>
25648         getrandom: Produce a better error code.
25649         Reported by Paul Eggert in
25650         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00025.html>.
25651         * lib/getrandom.c (getrandom): When open() fails with an error that does
25652         not indicate the absence of the file, fail with that error code, not
25653         with ENOSYS.
25655 2021-05-13  Bruno Haible  <bruno@clisp.org>
25657         fstatat: Document a glibc 2.7 bug.
25658         * doc/posix-functions/fstatat.texi: Document an old glibc 2.7 bug.
25660 2021-05-13  Bruno Haible  <bruno@clisp.org>
25662         posix_spawn, posix_spawnp: Fix build error on Minix 3.3.
25663         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): If posix_spawn does not exist
25664         but is declared, set REPLACE_POSIX_SPAWN.
25665         * doc/posix-functions/posix_spawn.texi: Update platforms list.
25666         * doc/posix-functions/posix_spawnp.texi: Likewise.
25668 2021-05-13  Bruno Haible  <bruno@clisp.org>
25670         reallocarray tests: Avoid test failure on NetBSD.
25671         * tests/test-reallocarray.c (main): Accept EOVERFLOW error code.
25673 2021-05-12  Bruno Haible  <bruno@clisp.org>
25675         gnulib-tool: Fail properly if the 'join' program is not found.
25676         Reported by Simon Josefsson <simon@josefsson.org> in
25677         <https://lists.gnu.org/archive/html/bug-gnulib/2021-05/msg00029.html>.
25678         * gnulib-tool: Bail out early of the 'join' program is not found.
25680 2021-05-09  Bruno Haible  <bruno@clisp.org>
25682         {realloc,calloc}-gnu: Fix autoconf macro (regression 2021-04-18).
25683         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Don't reset REPLACE_REALLOC
25684         to 0 if it is already 1 after gl_FUNC_REALLOC_GNU was executed.
25685         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Don't reset REPLACE_CALLOC
25686         to 0 if it is already 1 after gl_FUNC_CALLOC_GNU was executed.
25688         {malloc,realloc,calloc}-gnu: Fix autoconf macro (regression 2021-04-18).
25689         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): Don't assume that
25690         _AC_FUNC_MALLOC_IF expands to a single shell statement.
25691         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): Don't assume that
25692         _AC_FUNC_REALLOC_IF expands to a single shell statement.
25693         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Don't assume that
25694         _AC_FUNC_CALLOC_IF expands to a single shell statement.
25696 2021-05-09  Bruno Haible  <bruno@clisp.org>
25698         malloc-gnu, realloc-gnu, calloc-gnu: Ensure errno gets set on IRIX.
25699         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Require AC_CANONICAL_HOST. Set
25700         gl_cv_func_malloc_posix to 'no' also on IRIX.
25702         malloc-gnu, realloc-gnu, calloc-gnu tests: Verify errno is set.
25703         * tests/test-malloc-gnu.c: Include <errno.h>.
25704         (main): Verify that, when an allocation larger than PTRDIFF_MAX failed,
25705         errno is ENOMEM.
25706         * tests/test-realloc-gnu.c: Likewise.
25707         * tests/test-calloc-gnu.c: Likewise.
25709 2021-05-09  Bruno Haible  <bruno@clisp.org>
25711         getrandom: Fail with ENOSYS when the system has no randomness source.
25712         * lib/getrandom.c (getrandom): When open() fails, set errno to ENOSYS.
25714 2021-05-09  Bruno Haible  <bruno@clisp.org>
25716         free tests: Avoid test failure on glibc < 2.15.
25717         * tests/test-free.c (main): Skip the hairy test on glibc < 2.15.
25719 2021-05-08  Bruno Haible  <bruno@clisp.org>
25721         Fix build error when libintl is installed.
25722         * modules/posix_spawn_file_actions_addchdir-tests (Makefile.am): Link
25723         test-posix_spawn-chdir with libintl.
25724         * modules/posix_spawn_file_actions_addfchdir-tests (Makefile.am): Link
25725         test-posix_spawn-fchdir with libintl.
25727 2021-05-07  Bruno Haible  <bruno@clisp.org>
25729         Fix build when an older libunistring is installed (regr. 2020-02-23).
25730         * modules/unitypes (configure.ac): Arrange to generate the .h file if
25731         the installed one is from a version < 0.9.11.
25732         * modules/unicase/base (configure.ac): Likewise.
25733         * modules/uniconv/base (configure.ac): Likewise.
25734         * modules/unilbrk/base (configure.ac): Likewise.
25735         * modules/uninorm/base (configure.ac): Likewise.
25736         * modules/unistdio/base (configure.ac): Likewise.
25737         * modules/unistr/base (configure.ac): Likewise.
25738         * modules/uniwbrk/base (configure.ac): Likewise.
25739         * modules/uniwidth/base (configure.ac): Likewise.
25740         * modules/unictype/base (configure.ac): Arrange to generate the .h file
25741         if the installed one is from a version < 0.9.8.
25742         * modules/unigbrk/base (configure.ac): Likewise.
25744 2021-04-30  Bruno Haible  <bruno@clisp.org>
25746         immutable: Fix crash when immmalloc() fails.
25747         Found by GCC 11 '-fanalyzer'.
25748         * lib/immutable.c (immstrdup): Don't crash when immmalloc() fails.
25750 2021-04-30  Bruno Haible  <bruno@clisp.org>
25752         supersede: Fix crash when malloc() fails.
25753         Found by GCC 11 '-fanalyzer'.
25754         * lib/supersede.c (create_temp_file): Don't crash when malloc() fails.
25756 2021-04-27  Paul Eggert  <eggert@cs.ucla.edu>
25758         libc-config: fix include problem on older Debian
25759         https://lists.gnu.org/r/bug-gnulib/2021-04/msg00198.html
25760         * lib/cdefs.h: Use __GNULIB_CDEFS, not __GLIBC__,
25761         to determine whether to include the bits/* files.
25762         * lib/libc-config.h (__WORDSIZE): Remove.
25763         (__GNULIB_CDEFS): New macro.
25765 2021-04-26  Paul Eggert  <eggert@cs.ucla.edu>
25767         gnulib-tool: port better to current Autoconf
25768         * doc/gnulib-tool.texi (Initial import): Don’t mention
25769         AC_PROG_CC_STDC as it’s deprecated in current Autoconf.
25770         * gnulib-tool (func_done_dir): Suggest replacing
25771         AC_PROG_CC_STDC and AC_PROG_CC_C99, as per current Autoconf.
25773 2021-04-25  Paul Eggert  <eggert@cs.ucla.edu>
25775         reallocarray: a bit more tuning
25776         * lib/reallocarray.c: Include intprops.h.
25777         (reallocarray): Use INT_MULTIPLY_WRAPV instead of
25778         xalloc_oversized, as it now suffices and is likely a bit more
25779         efficient (five fewer machine insns on Ubuntu 20.10 x86-64).
25780         * modules/reallocarray (Depends-on): Depend on intprops, not
25781         xalloc-oversized.  Use conditional dependencies to avoid building
25782         realloc-gnu when not needed.
25784         reallocarray: don’t crash if item size is 0
25785         This problem affects only platforms where xalloc_oversized
25786         divides a number by the size arg.  Fix this by defining
25787         xalloc_oversized (n, s) to work even if s == 0.
25788         * lib/malloca.h, lib/xalloc-oversized.h: Document new behavior.
25789         * lib/xalloc-oversized.h (__xalloc_oversized): Do not crash if S==0.
25790         * tests/test-reallocarray.c (main): Test for the bug.
25792 2021-04-24  Paul Eggert  <eggert@cs.ucla.edu>
25794         xmalloca, etc.: avoid unlikely trap
25795         * lib/malloca.h (nmalloca):
25796         * lib/xmalloca.h (xnmalloca):
25797         Use size_t, not ptrdiff_t, to avoid implementation-defined
25798         behavior (which could include a trap) if N is 0 and S exceeds
25799         PTRDIFF_MAX.
25800         * lib/xalloc-oversized.h: Adjust comment to match.
25802         xmalloca, etc.: fix some xalloc-oversized issues
25803         * lib/malloca.h (nmalloca):
25804         * lib/xmalloca.h (xnmalloca): Convert S to ptrdiff_t to avoid
25805         arithmetic overflow if N and S are both narrower than ptrdiff_t.
25806         * lib/xalloc-oversized.h (xalloc_oversized):
25807         Don’t say that args must be ptrdiff_t or size_t or wider.
25808         The macro returns the correct answer even when that is not
25809         the case, and it’s the caller’s responsibility to avoid
25810         howlers like (xalloc_oversized (n, s) ? NULL : malloc (n * s))
25811         when N and S are both narrower than ptrdiff_t and size_t.
25812         Add a comment to that effect.
25813         * lib/xmalloca.h: Include xalloc-oversized.h, since this file uses
25814         xalloc_oversized.  Add comments about side effects and avoid
25815         unnecessary parens.
25816         * modules/xmalloca (Depends-on): Add xalloc-oversized.
25818         reallocarray: check for ptrdiff_t overflow
25819         * doc/glibc-functions/reallocarray.texi (reallocarray):
25820         Mention ptrdiff_t overflow.
25821         * lib/reallocarray.c (reallocarray): Reindent as per usual GNU.
25822         * lib/stdlib.in.h (reallocarray): Allow reallocarray to be replaced.
25823         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY):
25824         Check for ptrdiff_t overflow.
25825         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Set up REPLACE_REALLOCARRAY.
25826         * modules/reallocarray (Files): Add malloc.m4.
25827         (configure.ac): Also test REPLACE_REALLOCARRAY.
25828         * modules/reallocarray-tests (Depends-on): Add stdint.
25829         * modules/stdlib (stdlib.h): Substitute REPLACE_REALLOCARRAY.
25830         * tests/test-reallocarray.c: Include stdint.h.
25831         (main): Check for ptrdiff_t overflow.
25833         calloc-gnu-tests: add overflow tests
25834         * tests/test-calloc-gnu.c (identity): New function, replacing ‘eight’.
25835         (main): Do 2 * log2(SIZE_MAX) tests instead of just two tests.
25836         Don’t bother to free on failure.
25838 2021-04-22  Paul Eggert  <eggert@cs.ucla.edu>
25840         libc-config: port better to Fedora Rawhide
25841         Problem reported by Eric Blake in:
25842         https://lists.gnu.org/r/bug-gnulib/2021-04/msg00181.html
25843         * lib/cdefs.h: Make this closer to glibc, so that we can
25844         merge Gnulib into glibc here.
25845         (__attribute_maybe_unused__): Make identical to glibc’s
25846         definition, though with an additional comment.
25847         (__attribute_nonnull__): Add clarifying comment.
25848         Make inclusion of bits/wordsize.h, bits/long-double.h
25849         dependent on __GLIBC__, not on !__WORDSIZE.
25850         * lib/libc-config.h: Use __attribute_nonnull__,
25851         not __attribute_maybe_unused__, to detect whether
25852         to include sys/cdefs.h.
25854 2021-04-21  Paul Eggert  <eggert@cs.ucla.edu>
25856         realloc: port to AIX 7.1
25857         * lib/realloc.c (_GL_USE_STDLIB_ALLOC): Do not define.  This
25858         module relies on GNU malloc.  This fixes a test failure on AIX 7.1.
25860         malloc: simplify
25861         * lib/malloc.c: Omit unnecessary "#undef malloc".
25862         I recently introduced it by mistake.  This module defines
25863         _GL_USE_STDLIB_ALLOC and so malloc isn’t redefined to rpl_malloc.
25865         malloca: avoid ptrdiff_t overflow
25866         * lib/malloca.c: Include idx.h, intprops.h.
25867         (mmalloca): Check for ptrdiff_t overflow.  Since this module uses
25868         _GL_USE_STDLIB_ALLOC, it cannot assume GNU malloc semantics.
25869         * modules/malloca (Depends-on): Add idx, intprops.
25871         careadlinkat: avoid ptrdiff_t overflow
25872         * lib/careadlinkat.c: Include idx.h, minmax.h.
25873         (readlink_stk): Avoid ptrdiff_t overflow in object allocation.
25874         Since this module uses arbitrary allocators (including
25875         stdlib_allocator), it cannot assume GNU malloc semantics.
25876         * modules/careadlinkat (Depends-on): Add idx, minmax.
25878         execute-tests: pacify compiler
25879         * tests/test-execute-main.c (main): Use 0x7DEADBEE rather than
25880         0xDEADBEEF for nonces, to avoid provoking AIX XLC compiler warning
25881         that the latter is out of int range.
25883 2021-04-20  Paul Eggert  <eggert@cs.ucla.edu>
25885         malloc-gnu-tests, etc.: use volatile for clang
25886         In some more test locations, store the result of malloc etc. into
25887         a volatile pointer so that clang doesn’t optimize away the malloc
25888         and thus bypass the test.  This fixes a malloc-gnu test failure on
25889         macOS 11.2.3 with clang 12.0.0 on ARM.
25890         * tests/test-alloca-opt.c (do_allocation):
25891         * tests/test-malloc-gnu.c (main):
25892         * tests/test-malloca.c (do_allocation):
25893         * tests/test-realloc-gnu.c (main):
25894         * tests/test-reallocarray.c (main):
25895         * tests/test-aligned-malloc.c (main):
25896         * tests/test-aligned_alloc.c (main):
25897         Store malloc etc. results into a volatile pointer.
25899 2021-04-18  Paul Eggert  <eggert@cs.ucla.edu>
25901         malloc-gnu-tests: pacify -Walloc-size-larger-than
25902         * tests/test-malloc-gnu.c (main):
25903         * tests/test-realloc-gnu.c (main): Hide true intentions from GCC,
25904         to prevent diagnostics like “warning: argument 1 value
25905         ‘9223372036854775808’ exceeds maximum object size
25906         9223372036854775807 [-Walloc-size-larger-than=]”.
25908         safe-alloc: fix pointer implementation
25909         The old implementation assumed that all pointers use the same
25910         internal representation, but the C standard doesn’t guarantee
25911         this.  Use void * (pointer) not void ** (pointer-to-pointer) for
25912         the internal functions’ API.  The internal functions now return
25913         NULL if and only if they failed, and the macros translate that
25914         into -1 or 0 to satisfy the existing API.
25915         * doc/safe-alloc.texi (Safe Allocation Macros): Mention overflow.
25916         * lib/safe-alloc.c: Major rewrite.  Now this simply
25917         defines SAFE_ALLOC_INLINE and includes safe-alloc.h.
25918         * lib/safe-alloc.h: Include stddef.h, not stdlib.h.
25919         (SAFE_ALLOC_INLINE): New macro; use Gnulib inline function style.
25920         (safe_alloc_realloc_n): New API, which passes and returns
25921         the pointer, and which returns NULL if and only if failure occurs.
25922         (safe_alloc_check): New function.
25923         (ALLOC, ALLOC_N, ALLOC_N_UNINITIALIZED, REALLOC_N):
25924         Redo using the new API for internal functions, and using calloc
25925         which is good enough since it’s GNU-compatible now.
25926         (FREE): Expand to an expression rather than merely to something
25927         that needs a following ‘;’ to become a statement.
25928         * modules/safe-alloc (Depends-on): Add calloc-gnu.
25930         calloc-gnu: now LGPLv2+
25931         * modules/calloc-gnu (License): Change from GPL to LGPLv2+.
25932         The old value was evidently a longstanding typo, and calloc
25933         will be needed by LGPLv2+ modules that will want to rely
25934         on GNU behavior.
25936         safe-alloc: simplify via reallocarray
25937         * lib/safe-alloc.c: Do not include xalloc-oversized.h.
25938         (safe_alloc_alloc_n, safe_alloc_realloc_n):
25939         Use reallocarray to check for size or ptrdiff_t overflow.
25940         * modules/reallocarray (License): Switch from LGPL to LGPLv2+, as
25941         this is needed for safe-alloc and anyway is more appropriate for
25942         this library function common with BSD.
25943         * modules/safe-alloc (Depends-on): Depend on reallocarray
25944         rather than xalloc-oversized.
25946         xalloc-oversized: fix SIZE_MAX optimization bug
25947         * lib/xalloc-oversized.h (xalloc_count_t): Remove; no longer
25948         needed and was evidently error-prone anyway.
25949         (xalloc_oversized): Omit some over-optimization that caused
25950         SIZE_MAX to not be treated as too large (the Gnulib convention) on
25951         unusual platforms where PTRDIFF_MAX == SIZE_MAX.  This change
25952         should not affect typical platforms where PTRDIFF_MAX < SIZE_MAX.
25953         When optimizing, simply use ptrdiff_t instead of xalloc_count_t.
25955         xalloc: new function xreallocarray
25956         This is the same as xnrealloc, which perhaps should be deprecated.
25957         The name xreallocarray should be easier to remember now that
25958         reallocarray is a standard GNU function.
25959         * lib/xalloc.h [GNULIB_XALLOC]: Do not include xalloc-oversized.h.
25960         (xnmalloc, xnrealloc, x2nrealloc): Simplify by using xreallocarray.
25961         * lib/xmalloc.c (xreallocarray): New function.
25962         * modules/xalloc (Depends-on): Add reallocarray;
25963         remove xalloc-oversized.
25965         group-member: simplify via realloc-gnu
25966         * lib/group-member.c, modules/group-member:
25967         Simplify similarly to backupfile.
25969         backupfile: simplify via realloc-gnu
25970         * lib/backupfile.c: Do not include xalloc-oversized.h.
25971         (numbered_backup): Simplify now that realloc will do the right
25972         thing about ptrdiff_t overflow.
25973         * modules/backupfile (Depends-on): Add realloc-gnu;
25974         remove xalloc-oversized.
25976         safe-alloc: improve doc
25977         * doc/safe-alloc.texi: Clarify that reallocating an array appends
25978         uninitialized storage.  Say ‘sizeof *p’ rather than ‘sizeof(*p)’
25979         which would need a space before the paren to follow GNU style.
25981         malloc-gnu-tests, etc.: test ptrdiff_t overflow
25982         * modules/calloc-gnu-tests (Depends-on):
25983         * modules/malloc-gnu-tests (Depends-on):
25984         * modules/realloc-gnu-tests (Depends-on): Add stdint.
25985         * tests/test-calloc-gnu.c (main):
25986         * tests/test-malloc-gnu.c (main):,
25987         * tests/test-realloc-gnu.c (main): Test for ptrdiff_t overflow.
25989         malloc-gnu, etc.: prefer AS_CASE to woolly AS_IF
25990         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
25991         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
25992         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Use AS_CASE.
25994         malloc-gnu, etc.: sync better with Autoconf
25995         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
25996         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
25997         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF):
25998         Avoid some unnecessary differences from Autoconf’s versions.
25999         Separate our platforms into a different line so that it’s easier
26000         to diff.  Use AS_IF in case the args use AC_REQUIRE.
26001         However, don’t bother with omitting the first newline, as
26002         omitting the newline is not Gnulib style and the difference
26003         doesn’t seem to matter here.
26005 2021-04-18  Bruno Haible  <bruno@clisp.org>
26007         malloc-posix, realloc-posix, calloc-posix: Document affected platforms.
26008         * doc/posix-functions/malloc.texi: Re-add platforms list.
26009         * doc/posix-functions/realloc.texi: Likewise.
26010         * doc/posix-functions/calloc.texi: Likewise.
26012 2021-04-18  Bruno Haible  <bruno@clisp.org>
26014         More systematic file naming.
26015         * m4/ctype_h.m4: Renamed from m4/ctype.m4.
26016         * m4/threads_h.m4: Renamed from m4/threads.m4.
26017         * m4/uchar_h.m4: Renamed from m4/uchar.m4.
26019 2021-04-18  Bruno Haible  <bruno@clisp.org>
26021         Add comments after 2021-04-11 change.
26022         * m4/*_h.m4: Add comments regarding *_REQUIRE_DEFAULTS and
26023         *_MODULE_INDICATOR macros.
26025 2021-04-18  Bruno Haible  <bruno@clisp.org>
26027         doc: Update for FreeBSD 13.0/arm64.
26028         * doc/posix-headers/stdint.texi: Mention FreeBSD 13 bug.
26029         * m4/stdint.m4: Update comment.
26031 2021-04-17  Paul Eggert  <eggert@cs.ucla.edu>
26033         xalloc: adjust to malloc ptrdiff_t change
26034         * lib/xmalloc.c (HAVE_GNU_CALLOC, HAVE_GNU_MALLOC, HAVE_GNU_REALLOC):
26035         Remove.
26036         (xmalloc, xrealloc, xcalloc): Simplify by assuming GNU behavior.
26037         * modules/xalloc (Depends-on): Add calloc-gnu, malloc-gnu,
26038         realloc-gnu.
26040         malloc, etc.: check for ptrdiff_t overflow
26041         In glibc 2.30 and later, malloc, realloc and calloc reject
26042         attempts to create objects larger than PTRDIFF_MAX bytes.
26043         This patch changes malloc-gnu etc. to support this behavior
26044         on non-GNU hosts.  It also makes this change for malloc-posix etc.
26045         since it’s a safety measure that ought to be in POSIX (perhaps
26046         we can talk them into that...).
26048         In writing this patch I found a complicated set of code that had
26049         accumulated over the years, some written by yours truly.  I got
26050         rid of the code I couldn’t see the need for nowadays.  Among other
26051         things, the GNU realloc behavior is no longer incompatible with
26052         the C standard, because in C17 the latter was relaxed to allow the
26053         former.  If I went too far in cleaning up, the old stuff can be
26054         resurrected.
26056         This change is mostly for 32-bit platforms, since practical 64-bit
26057         platforms cannot create objects larger than PTRDIFF_MAX bytes anyway.
26058         * doc/posix-functions/calloc.texi:
26059         * doc/posix-functions/malloc.texi:
26060         * doc/posix-functions/realloc.texi:
26061         Mention ptrdiff_t issues, and go into more detail about what
26062         the gnu extension module does.
26063         * doc/posix-functions/realloc.texi: Fix now-obsolete commentary
26064         about C99 vs glibc, as C17 allows the glibc behavior and POSIX
26065         will follow suit when it gets around to it.
26066         * lib/calloc.c, lib/malloc.c, lib/realloc.c:
26067         Simplify by always supplying a GNU-compatible version,
26068         as that suffices for correctness and is good enough for performance.
26069         Include xalloc-oversized.h, and use xalloc_oversized to
26070         check for ptrdiff_t overflow.
26071         (NEED_CALLOC_GNU, NEED_MALLOC_GNU, NEED_REALLOC_GNU): Remove.
26072         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
26073         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
26074         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF):
26075         Don’t start with a newline.  Fix message to match behavior.
26076         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don’t test for size_t overflow,
26077         as the ptrdiff_t test is good enough.
26078         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU):
26079         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU):
26080         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU):
26081         Do not define HAVE_CALLOC_GNU, HAVE_MALLOC_GNU, HAVE_REALLOC_GNU.
26082         It’s not worth the aggravation of maintaining these, as they
26083         are confusing (they don’t really mean GNU-compatible anyway).
26084         Don’t bother testing for GNU behavior if we have already decided
26085         to replace the function, since the replacement is always GNUish.
26086         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX):
26087         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX):
26088         Defer to gl_FUNC_MALLOC_POSIX.
26089         * m4/malloc.m4 (gl_FUNC_MALLOC_PTRDIFF, gl_CHECK_MALLOC_PTRDIFF):
26090         New macros.
26091         (gl_FUNC_MALLOC_POSIX): Use them to check for ptrdiff_t overflow.
26092         * modules/calloc-gnu, modules/malloc-gnu, modules/realloc-gnu:
26093         Remove no-longer-needed module indicators.
26094         * modules/calloc-posix, modules/malloc-posix, modules/realloc-posix:
26095         Depend on xalloc-oversized.
26096         * modules/malloc-posix: Require gl_FUNC_MALLOC_POSIX instead of
26097         calling it directly, so that other code can require it.
26098         * modules/realloc-posix: Depend on free-posix and malloc-posix.
26100 2021-04-17  Bruno Haible  <bruno@clisp.org>
26102         stdio: Fix build error in some configurations (regression 2021-04-11).
26103         * m4/stdio_h.m4 (gl_STDIO_H): Move gl_STDIO_MODULE_INDICATOR and
26104         gl_MODULE_INDICATOR invocations from here...
26105         * modules/stdio (configure.ac): ... to here.
26107 2021-04-17  Bruno Haible  <bruno@clisp.org>
26109         doc: Update for FreeBSD 11.0, 12.0, 13.0.
26110         * doc/posix-headers/*.texi: Update.
26111         * doc/glibc-headers/*.texi: Update.
26112         * doc/posix-functions/*.texi: Likewise.
26113         * doc/pastposix-functions/*.texi: Likewise.
26114         * doc/glibc-functions/*.texi: Likewise.
26115         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Update cross-compilation guess.
26117 2021-04-16  Paul Eggert  <eggert@cs.ucla.edu>
26119         malloc, realloc: fix recently-introduced #undef typos
26120         * lib/malloc.c (malloc):
26121         * lib/realloc.c (malloc, realloc): #undef before using.
26123 2021-04-14  Bruno Haible  <bruno@clisp.org>
26125         hamt tests: Fix link error.
26126         * modules/hamt-tests (Makefile.am): Link test-hamt against @LIBINTL@.
26128 2021-04-14  Bruno Haible  <bruno@clisp.org>
26130         c-stack: Don't use an undefined C macro (regression from 2020-10-04).
26131         * lib/c-stack.c: Test GNU C version directly, without __GNUC_PREREQ.
26133 2021-04-12  Bruno Haible  <bruno@clisp.org>
26135         doc: Fix confusion between LIBADD and LDADD.
26136         Reported by Reuben Thomas <rrt@sc3d.org> in
26137         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00102.html>.
26138         * doc/gnulib-tool.texi (Multiple instances): For programs, use LDADD,
26139         not LIBADD.
26141 2021-04-11  Bruno Haible  <bruno@clisp.org>
26143         malloc, realloc, calloc: Support restricted library symbols on AIX.
26144         Suggested by Paul Eggert in
26145         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00119.html>.
26146         * lib/malloc.c: Drop the code that intends to collaborate with
26147         AC_FUNC_MALLOC.
26148         * lib/realloc.c: Drop the code that intends to collaborate with
26149         AC_FUNC_REALLOC.
26150         * lib/calloc.c: Drop the code that intends to collaborate with the
26151         nonexistent macro AC_FUNC_CALLOC.
26153 2021-04-11  Bruno Haible  <bruno@clisp.org>
26155         Support several gnulib-tool invocations under the same configure.ac.
26156         Reported by Reuben Thomas <rrt@sc3d.org> in
26157         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00104.html>.
26158         This is done by defining the Gnulib module indicator variables per
26159         gnulib-tool invocation. So that a generated .h file is no longer
26160         influenced by the set of modules used in other gnulib-tool invocations.
26161         * gnulib-tool (func_compute_include_guard_prefix): Set
26162         module_indicator_prefix.
26163         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use it to
26164         modify $(GNULIB_*) variable references in the Automake snippets.
26165         (func_emit_initmacro_start): Push macro definitions for GL_MACRO_PREFIX
26166         and GL_MODULE_INDICATOR_PREFIX.
26167         (func_emit_initmacro_end): Pop these macro definitions.
26168         * pygnulib/GLConfig.py (GLConfig.getIncludeGuardPrefix): New method.
26169         * pygnulib/GLEmiter.py (GLEmiter.initmacro_start): Push macro
26170         definitions for GL_MACRO_PREFIX and GL_MODULE_INDICATOR_PREFIX.
26171         (GLEmiter.initmacro_end): Pop these macro definitions.
26172         (GLEmiter.lib_Makefile_am, GLEmiter.tests_Makefile_am): Use the module
26173         indicator prefix to modify $(GNULIB_*) variable references in the
26174         Automake snippets.
26175         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_INIT_VARIABLE,
26176         gl_MODULE_INDICATOR_SET_VARIABLE): Use the value of
26177         GL_MODULE_INDICATOR_PREFIX.
26178         * m4/arpa_inet_h.m4: Use new idiom for header files that contain
26179         references to Gnulib module indicator variables:
26180         - Define the main macro through AC_DEFUN_ONCE.
26181         - Define a macro gl_*_H_REQUIRE_DEFAULTS that initializes the Gnulib
26182           module indicator variables (each prefixed with
26183           GL_MODULE_INDICATOR_PREFIX).
26184         - Invoke this macro in the gl_*_MODULE_INDICATOR macro.
26185         * m4/ctype.m4: Likewise.
26186         * m4/dirent_h.m4: Likewise.
26187         * m4/fcntl_h.m4: Likewise.
26188         * m4/fnmatch_h.m4: Likewise.
26189         * m4/glob_h.m4: Likewise.
26190         * m4/iconv_h.m4: Likewise.
26191         * m4/inttypes.m4: Likewise.
26192         * m4/langinfo_h.m4: Likewise.
26193         * m4/locale_h.m4: Likewise.
26194         * m4/malloc_h.m4: Likewise.
26195         * m4/math_h.m4: Likewise.
26196         * m4/monetary_h.m4: Likewise.
26197         * m4/netdb_h.m4: Likewise.
26198         * m4/poll_h.m4: Likewise.
26199         * m4/pthread_h.m4: Likewise.
26200         * m4/pty_h.m4: Likewise.
26201         * m4/sched_h.m4: Likewise.
26202         * m4/search_h.m4: Likewise.
26203         * m4/signal_h.m4: Likewise.
26204         * m4/spawn_h.m4: Likewise.
26205         * m4/stddef_h.m4: Likewise.
26206         * m4/stdio_h.m4: Likewise.
26207         * m4/stdlib_h.m4: Likewise.
26208         * m4/string_h.m4: Likewise.
26209         * m4/strings_h.m4: Likewise.
26210         * m4/sys_file_h.m4: Likewise.
26211         * m4/sys_ioctl_h.m4: Likewise.
26212         * m4/sys_random_h.m4: Likewise.
26213         * m4/sys_resource_h.m4: Likewise.
26214         * m4/sys_select_h.m4: Likewise.
26215         * m4/sys_socket_h.m4: Likewise.
26216         * m4/sys_stat_h.m4: Likewise.
26217         * m4/sys_time_h.m4: Likewise.
26218         * m4/sys_times_h.m4: Likewise.
26219         * m4/sys_types_h.m4: Likewise.
26220         * m4/sys_uio_h.m4: Likewise.
26221         * m4/sys_utsname_h.m4: Likewise.
26222         * m4/sys_wait_h.m4: Likewise.
26223         * m4/termios_h.m4: Likewise.
26224         * m4/threads.m4: Likewise.
26225         * m4/time_h.m4: Likewise.
26226         * m4/uchar.m4: Likewise.
26227         * m4/unistd_h.m4: Likewise.
26228         * m4/utime_h.m4: Likewise.
26229         * m4/wchar_h.m4: Likewise.
26230         * m4/wctype_h.m4: Likewise.
26231         * modules/arpa_inet (configure.ac): Invoke the macro
26232         gl_*_H_REQUIRE_DEFAULTS explicitly.
26233         * modules/ctype (configure.ac): Likewise.
26234         * modules/dirent (configure.ac): Likewise.
26235         * modules/fcntl-h (configure.ac): Likewise.
26236         * modules/fnmatch-h (configure.ac): Likewise.
26237         * modules/glob-h (configure.ac): Likewise.
26238         * modules/iconv-h (configure.ac): Likewise.
26239         * modules/inttypes-incomplete (configure.ac): Likewise.
26240         * modules/langinfo (configure.ac): Likewise.
26241         * modules/locale (configure.ac): Likewise.
26242         * modules/malloc-h (configure.ac): Likewise.
26243         * modules/math (configure.ac): Likewise.
26244         * modules/monetary (configure.ac): Likewise.
26245         * modules/netdb (configure.ac): Likewise.
26246         * modules/poll-h (configure.ac): Likewise.
26247         * modules/pthread-h (configure.ac): Likewise.
26248         * modules/pty (configure.ac): Likewise.
26249         * modules/sched (configure.ac): Likewise.
26250         * modules/search (configure.ac): Likewise.
26251         * modules/signal-h (configure.ac): Likewise.
26252         * modules/spawn (configure.ac): Likewise.
26253         * modules/stddef (configure.ac): Likewise.
26254         * modules/stdio (configure.ac): Likewise.
26255         * modules/stdlib (configure.ac): Likewise.
26256         * modules/string (configure.ac): Likewise.
26257         * modules/strings (configure.ac): Likewise.
26258         * modules/sys_file (configure.ac): Likewise.
26259         * modules/sys_ioctl (configure.ac): Likewise.
26260         * modules/sys_random (configure.ac): Likewise.
26261         * modules/sys_resource (configure.ac): Likewise.
26262         * modules/sys_select (configure.ac): Likewise.
26263         * modules/sys_socket (configure.ac): Likewise.
26264         * modules/sys_stat (configure.ac): Likewise.
26265         * modules/sys_time (configure.ac): Likewise.
26266         * modules/sys_times (configure.ac): Likewise.
26267         * modules/sys_types (configure.ac): Likewise.
26268         * modules/sys_uio (configure.ac): Likewise.
26269         * modules/sys_utsname (configure.ac): Likewise.
26270         * modules/sys_wait (configure.ac): Likewise.
26271         * modules/termios (configure.ac): Likewise.
26272         * modules/threads-h (configure.ac): Likewise.
26273         * modules/time (configure.ac): Likewise.
26274         * modules/uchar (configure.ac): Likewise.
26275         * modules/unistd (configure.ac): Likewise.
26276         * modules/utime-h (configure.ac): Likewise.
26277         * modules/wchar (configure.ac): Likewise.
26278         * modules/wctype-h (configure.ac): Likewise.
26279         * m4/af_alg.m4: Update after a macro name changed.
26280         * m4/ctime.m4: Likewise.
26281         * m4/explicit_bzero.m4: Likewise.
26282         * m4/ffs.m4: Likewise.
26283         * m4/ffsl.m4: Likewise.
26284         * m4/ffsll.m4: Likewise.
26285         * m4/flock.m4: Likewise.
26286         * m4/fstat.m4: Likewise.
26287         * m4/getaddrinfo.m4: Likewise.
26288         * m4/getdomainname.m4: Likewise.
26289         * m4/gettimeofday.m4: Likewise.
26290         * m4/hostent.m4: Likewise.
26291         * m4/ioctl.m4: Likewise.
26292         * m4/localtime.m4: Likewise.
26293         * m4/mbslen.m4: Likewise.
26294         * m4/memchr.m4: Likewise.
26295         * m4/memmem.m4: Likewise.
26296         * m4/mempcpy.m4: Likewise.
26297         * m4/memrchr.m4: Likewise.
26298         * m4/mktime.m4: Likewise.
26299         * m4/nanosleep.m4: Likewise.
26300         * m4/passfd.m4: Likewise.
26301         * m4/pselect.m4: Likewise.
26302         * m4/rawmemchr.m4: Likewise.
26303         * m4/select.m4: Likewise.
26304         * m4/servent.m4: Likewise.
26305         * m4/sigabbrev_np.m4: Likewise.
26306         * m4/sigdescr_np.m4: Likewise.
26307         * m4/sockpfaf.m4: Likewise.
26308         * m4/stat.m4: Likewise.
26309         * m4/stpcpy.m4: Likewise.
26310         * m4/stpncpy.m4: Likewise.
26311         * m4/strcase.m4: Likewise.
26312         * m4/strcasestr.m4: Likewise.
26313         * m4/strchrnul.m4: Likewise.
26314         * m4/strdup.m4: Likewise.
26315         * m4/strerror.m4: Likewise.
26316         * m4/strerror_r.m4: Likewise.
26317         * m4/strerrorname_np.m4: Likewise.
26318         * m4/strftime-fixes.m4: Likewise.
26319         * m4/strncat.m4: Likewise.
26320         * m4/strndup.m4: Likewise.
26321         * m4/strnlen.m4: Likewise.
26322         * m4/strpbrk.m4: Likewise.
26323         * m4/strptime.m4: Likewise.
26324         * m4/strsep.m4: Likewise.
26325         * m4/strsignal.m4: Likewise.
26326         * m4/strstr.m4: Likewise.
26327         * m4/strtok_r.m4: Likewise.
26328         * m4/strverscmp.m4: Likewise.
26329         * m4/time_r.m4: Likewise.
26330         * m4/time_rz.m4: Likewise.
26331         * m4/timegm.m4: Likewise.
26332         * m4/timespec_get.m4: Likewise.
26333         * m4/tzset.m4: Likewise.
26334         * modules/accept (configure.ac): Likewise.
26335         * modules/bind (configure.ac): Likewise.
26336         * modules/connect (configure.ac): Likewise.
26337         * modules/flock (configure.ac): Likewise.
26338         * modules/getpeername (configure.ac): Likewise.
26339         * modules/getsockname (configure.ac): Likewise.
26340         * modules/getsockopt (configure.ac): Likewise.
26341         * modules/listen (configure.ac): Likewise.
26342         * modules/recv (configure.ac): Likewise.
26343         * modules/recvfrom (configure.ac): Likewise.
26344         * modules/send (configure.ac): Likewise.
26345         * modules/sendto (configure.ac): Likewise.
26346         * modules/setsockopt (configure.ac): Likewise.
26347         * modules/shutdown (configure.ac): Likewise.
26348         * modules/socket (configure.ac): Likewise. Use the
26349         gl_*_H_REQUIRE_DEFAULTS macros.
26350         * modules/nonblocking (configure.ac): Use the gl_*_H_REQUIRE_DEFAULTS
26351         and gl_MODULE_INDICATOR_INIT_VARIABLE macros.
26352         * modules/sigpipe (configure.ac): Likewise.
26353         * modules/windows-stat-override (configure.ac): Likewise.
26354         * m4/nonblocking.m4: Update a comment.
26355         * m4/sigpipe.m4: Likewise.
26357 2021-04-11  Bruno Haible  <bruno@clisp.org>
26359         Rename GNULIB_OVERRIDES_CHAR16_T, GNULIB_OVERRIDES_CHAR32_T.
26360         * GNULIBHEADERS_OVERRIDE_CHAR16_T: Renamed from
26361         GNULIB_OVERRIDES_CHAR16_T.
26362         * GNULIBHEADERS_OVERRIDE_CHAR32_T: Renamed from
26363         GNULIB_OVERRIDES_CHAR32_T.
26365         Rename GNULIB_OVERRIDES_WINT_T.
26366         * GNULIBHEADERS_OVERRIDE_WINT_T: Renamed from GNULIB_OVERRIDES_WINT_T.
26368 2021-04-11  Bruno Haible  <bruno@clisp.org>
26370         increment-serial: New program.
26371         * build-aux/increment-serial: New file.
26373 2021-04-11  Bruno Haible  <bruno@clisp.org>
26375         useless-if-before-free: Implement --version option according to GCS.
26376         * build-aux/useless-if-before-free (copyright_year): New variable.
26377         (GetOptions): Print also a short copyright and license notice and
26378         author statement.
26380         libtool-next-version: Implement --version option according to GCS.
26381         * build-aux/libtool-next-version (scriptversion): New variable.
26382         (func_version): Deduce the copyright year from it. Terminate sentences
26383         with '.'.
26385         gnupload: Implement --version option according to GCS.
26386         * build-aux/gnupload (copyright_year, copyright): New variables.
26387         (--version): Print also a short copyright and license notice.
26389         git-version-gen: Implement --version option according to GCS.
26390         * build-aux/git-version-gen (version): State the license. Use wording
26391         from GCS.
26393         bootstrap: Implement --version option according to GCS.
26394         * build-aux/bootstrap (copyright_year, copyright): New variables.
26395         (--version): New option processing.
26397         announce-gen: Implement --version option according to GCS.
26398         * build-aux/announce-gen (copyright_year): New variable.
26399         (GetOptions): Print also a short copyright and license notice and
26400         author statement.
26402 2021-04-10  Bruno Haible  <bruno@clisp.org>
26404         Simplify GNULIB_* variable initializations.
26405         * modules/gnulib-common.m4 (gl_MODULE_INDICATOR_INIT_VARIABLE): New
26406         macro.
26407         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Use it.
26408         * m4/ctype.m4 (gl_CTYPE_H_DEFAULTS): Likewise.
26409         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Likewise.
26410         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Likewise.
26411         * m4/fnmatch_h.m4 (gl_FNMATCH_H_DEFAULTS): Likewise.
26412         * m4/glob_h.m4 (gl_GLOB_H_DEFAULTS): Likewise.
26413         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Likewise.
26414         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Likewise.
26415         * m4/langinfo_h.m4 (gl_LANGINFO_H_DEFAULTS): Likewise.
26416         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Likewise.
26417         * m4/malloc_h.m4 (gl_MALLOC_H_DEFAULTS): Likewise.
26418         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Likewise.
26419         * m4/monetary_h.m4 (gl_MONETARY_H_DEFAULTS): Likewise.
26420         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Likewise.
26421         * m4/poll_h.m4 (gl_POLL_H_DEFAULTS): Likewise.
26422         * m4/pthread_h.m4 (gl_PTHREAD_H_DEFAULTS): Likewise.
26423         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Likewise.
26424         * m4/sched_h.m4 (gl_SCHED_H_DEFAULTS): Likewise.
26425         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Likewise.
26426         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Likewise.
26427         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Likewise.
26428         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
26429         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
26430         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
26431         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_DEFAULTS): Likewise.
26432         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H_DEFAULTS): Likewise.
26433         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Likewise.
26434         * m4/sys_random_h.m4 (gl_SYS_RANDOM_H_DEFAULTS): Likewise.
26435         * m4/sys_resource_h.m4 (gl_SYS_RESOURCE_H_DEFAULTS): Likewise.
26436         * m4/sys_select_h.m4 (gl_SYS_SELECT_H_DEFAULTS): Likewise.
26437         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Likewise.
26438         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
26439         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): Likewise.
26440         * m4/sys_times_h.m4 (gl_SYS_TIMES_H_DEFAULTS): Likewise.
26441         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
26442         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H_DEFAULTS): Likewise.
26443         * m4/termios_h.m4 (gl_TERMIOS_H_DEFAULTS): Likewise.
26444         * m4/threads.m4 (gl_THREADS_H_DEFAULTS): Likewise.
26445         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Likewise.
26446         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Likewise.
26447         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
26448         * m4/utime_h.m4 (gl_UTIME_H_DEFAULTS): Likewise.
26449         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Likewise.
26450         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Likewise.
26452 2021-04-10  Paul Eggert  <eggert@cs.ucla.edu>
26454         realloc: fix undef typo
26455         * lib/realloc.c: #undef realloc if config.h defines it.
26456         This fixes a typo that I introduced in
26457         2011-04-08T18:39:01Z!eggert@cs.ucla.edu.
26458         Apparently nobody uses Gnulib realloc in that way?
26460 2021-04-07  Bruno Haible  <bruno@clisp.org>
26462         execute tests: Avoid test failure in certain environments.
26463         Reported by Dmitry V. Levin <ldv@altlinux.org> in
26464         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00082.html>.
26465         * tests/test-execute-main.c (main): Close file descriptors 3..19.
26466         * tests/test-execute-child.c (main): Remove NetBSD workaround.
26467         * modules/execute-tests (configure.ac): Test for close_range function.
26469 2021-04-07  Paul Eggert  <eggert@cs.ucla.edu>
26471         utimens: fix confusing arg type in internal func
26472         Although the old code was technically correct, this was accidental
26473         and it confused a GCC 11 prerelease.  Reported by Ondrej Dubaj in:
26474         https://lists.gnu.org/r/bug-tar/2021-04/msg00000.html
26475         * lib/utimens.c (update_timespec): Change arg type from ‘struct
26476         timespec *[2]’ (pointer to array of 2 pointers to timespecs) to
26477         ‘struct timespec **’ (pointer to pointer to the first timespec in
26478         an array of 2 timespecs).  Although the old code happened to be
26479         technically correct, it was misleading and confused Coverity.
26480         And though the type ‘struct timespec (**)[2]’ (pointer to pointer
26481         to array of 2 timespecs) would perhaps be more technically
26482         correct, it would be almost as confusing and would require changes
26483         elsewhere in this file; let’s quit while we’re ahead.
26485         xalloc: simplify integer overflow test
26486         * lib/xalloc.h (x2nrealloc): Simplify integer overflow detection.
26487         This is easier to maintain, and (unlike the old code) exact.
26489 2021-04-06  Paul Eggert  <eggert@cs.ucla.edu>
26491         group-member: minor tweak to omit a *
26492         * lib/group-member.c: Include intprops.h.
26493         (get_group_info): Use INT_MULTIPLY_WRAPV instead of
26494         xalloc_oversized (which does a multiplication) followed by the
26495         same multiplication.  The code was OK as-is; this is just
26496         conceptual simplification, possible now that we have xalloc_count_t.
26497         * modules/group-member: Depend on intprops.
26499         backupfile: less-aggressive buffer growth
26500         * lib/backupfile.c: Include intprops.h.
26501         (numbered_backup): Grow buffer by the usual 50%, not 100%.
26502         This is easier to do now that we have xalloc_count_t.
26503         * modules/backup-rename, modules/backupfile: Depend on intprops.
26505         xalloc-oversized: export xalloc_count_t
26506         * lib/xalloc-oversized.h (__xalloc_oversized, xalloc_oversized):
26507         * lib/xmalloca.h (nmalloca):
26508         Comment re restrictions on arg types.
26509         * lib/xalloc-oversized.h (xalloc_count_t): Rename from
26510         __xalloc_count_type; all uses changed.  This publicizes the type.
26512 2021-04-05  Paul Eggert  <eggert@cs.ucla.edu>
26514         xalloc: try to pacify gcc -Wsign-compare
26515         Problem reported by Marc Nieper-Wißkirchen in:
26516         https://lists.gnu.org/r/bug-gnulib/2021-04/msg00034.html
26517         * lib/xmalloc.c (xpalloc): For odd platforms where SIZE_MAX < IDX_MAX,
26518         use a tricky destination for INT_MULTIPLY_WRAPV instead of an
26519         explicit comparison to SIZE_MAX.  This should be more likely to
26520         pacify gcc -Wsign-compare.
26522 2021-04-05  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
26524         hamt: Fix coding errors.
26525         Reported by Bruno Haible in
26526         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00047.html>
26527         after a Coverity run.
26528         * lib/hamt.c (bucket_do_while, hamt_iterator): Add missing
26529         derefencing operator and silence a bogus warning on uninitialized
26530         variables.
26531         * tests/test-hamt.c (test_general): Replace two errorneous
26532         assignment operators with comparison operators.
26534 2021-04-05  Fabrice Fontaine  <fontaine.fabrice@gmail.com>
26536         pthread-cond: Fix compilation error.
26537         * lib/pthread-cond.c (pthread_cond_wait): Use tv.nsec instead of
26538         tv.usec.
26540 2021-04-04  Fabrice Fontaine  <fontaine.fabrice@gmail.com>
26542         pthread-cond: Fix wrong configure results when <pthread.h> is absent.
26543         * m4/pthread-cond.m4 (gl_PTHREAD_COND): When <pthread.h> does not exist,
26544         set HAVE_PTHREAD_COND_* to 0, not to 1.
26546 2021-04-04  Bruno Haible  <bruno@clisp.org>
26548         backupfile, backup-rename: Trim dependencies.
26549         * lib/backupfile.h: Add comment.
26550         * lib/backupfile.c: Include <dirent.h>, for readdir() declaration.
26551         * modules/backup-rename (Depends-on): Remove dirent-safer, fcntl. Add
26552         fcntl-h.
26553         * modules/backupfile (Depends-on): Likewise. Remove xalloc. Add
26554         xalloc-die.
26556 2021-04-04  Bruno Haible  <bruno@clisp.org>
26558         doc: Fix syntax error (regression from 2021-04-02).
26559         * doc/posix-functions/strtol.texi: Put @item inside @itemize block.
26561 2021-04-04  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
26563         hamt: Document the module in the Gnulib manual.
26564         Suggested by Bruno Haible in
26565         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00026.html>.
26566         * doc/containers.texi: Add a subsection to section 15.11 Container
26567         data types.
26568         * lib/hamt.h: Improve documentation on how Hamt_entry is supposed
26569         to be used.
26571 2021-04-03  Paul Eggert  <eggert@cs.ucla.edu>
26573         savedir: avoid unlikely undefined behavior
26574         * lib/savedir.c (streamsavedir): Prefer idx_to size_t where
26575         either will do.  Simplify reallocation of entries.
26576         Use xpalloc to reallocate name_space, to avoid some unlikely
26577         integer overflows.
26579         quotearg: avoid undefined and/or O(N**2)
26580         Avoid undefined and O(N**2) behavior in some very unlikely cases.
26581         * lib/quotearg.c (quotearg_n_options): Document that N must
26582         be less than MIN (INT_MAX, IDX_MAX), and add this to the
26583         abort test; this also avoids a conditional branch.
26584         Use xpalloc instead of xrealloc, to avoid O(N**2) behavior in
26585         very-unlikely cases.
26587         xgethostname: reorganize / simplify
26588         xgethostname and xgetdomainname were essentially copies long
26589         ago, but they’ve diverged.  Bring them back together again
26590         by implementing the (rarely used) latter in terms of the former.
26591         And avoid some unnecessary realloc calls while we’re at it.
26592         * lib/xgetdomainname.c: Rewrite from scratch so that it merely
26593         includes xgethostname.c with a few preliminaries.
26594         * lib/xgethostname.c: Generalize so that it can be included
26595         from xgetdomainname.c.
26596         (GETANAME, XGETANAME): New macros.
26597         (INITIAL_HOSTNAME_LENGTH): Remove.  No need for this parameter.
26598         Use 100 instead, as few hostnames are longer than that.
26599         (XGETANAME): Try getting the hostname into the stack first,
26600         as that avoids a malloc call in the usual case.
26601         Check for both POSIX-style truncation and SunOS 5.5 bug
26602         in a cleaner way, by simply checking string length.
26603         Don’t use x2realloc, which wastes time preserving buffer garbage;
26604         use xpalloc with NULL instead.  Don’t bother shrinking buffer
26605         in the very rare case where the hostname is longer than sizeof
26606         buf; it’s not worth the aggravation.
26607         * modules/xgetdomainname (Depends-on): Remove free-posix, xalloc.
26608         Add xgethostname.
26610 2021-04-03  Bruno Haible  <bruno@clisp.org>
26612         *-list tests: Add more tests.
26613         * tests/test-array_list.c (check_equals_by_forward_iteration,
26614         check_equals_by_backward_iteration): New functions.
26615         (main): Invoke them.
26616         * tests/test-carray_list.c: Likewise.
26617         * tests/test-linked_list.c: Likewise.
26618         * tests/test-linkedhash_list.c: Likewise.
26619         * tests/test-avltree_list.c: Likewise.
26620         * tests/test-avltreehash_list.c: Likewise.
26621         * tests/test-rbtree_list.c: Likewise.
26622         * tests/test-rbtreehash_list.c: Likewise.
26624         list: Add operations first_node, last_node.
26625         Reported by Marc Nieper-Wißkirchen in
26626         <https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00005.html>.
26627         * lib/gl_list.h (gl_list_first_node, gl_list_last_node): New functions.
26628         (struct gl_list_implementation): Add members first_node, last_node.
26629         * lib/gl_array_list.c (gl_array_first_node, gl_array_last_node): New
26630         functions.
26631         (gl_array_list_implementation): Add the new operations.
26632         * lib/gl_carray_list.c (gl_carray_first_node, gl_carray_last_node): New
26633         functions.
26634         (gl_carray_list_implementation): Add the new operations.
26635         * lib/gl_anylinked_list2.h (gl_linked_first_node, gl_linked_last_node):
26636         New functions.
26637         * lib/gl_linked_list.c (gl_linked_list_implementation): Add the new
26638         operations.
26639         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation):
26640         Likewise.
26641         * lib/gl_anytree_list2.h (gl_tree_first_node, gl_tree_last_node): New
26642         functions.
26643         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Add the new
26644         operations.
26645         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
26646         Likewise.
26647         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Likewise.
26648         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation):
26649         Likewise.
26650         * lib/gl_sublist.c (gl_sublist_first_node, gl_sublist_last_node): New
26651         functions.
26652         (gl_sublist_list_implementation): Add the new operations.
26653         * lib/gl_list.hh (class gl_List): Add member functions first_node,
26654         last_node.
26655         * doc/containers.texi: Update table.
26657 2021-04-03  Bruno Haible  <bruno@clisp.org>
26659         xalloc-die: Fix compilation error (regression from 2021-03-28).
26660         * lib/xalloc.h: Don't include idx.h and xalloc-oversized.h if the module
26661         'xalloc' is not in use.
26662         * modules/xalloc-die (Depends-on): Remove xalloc-oversized.
26664 2020-04-03  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
26666         hamt: New module.
26667         This module provides (persistent) hash array mapped tries.
26668         * MODULES.html.sh: Add hamt.
26669         * lib/hamt.c: New file.
26670         * lib/hamt.h: New file.
26671         * modules/hamt: New file.
26672         * modules/hamt-tests: New file.
26673         * tests/test-hamt.c: New file.
26675 2021-04-02  Bruno Haible  <bruno@clisp.org>
26677         strtoul, strtoll, strtoull: Fix compilation warning.
26678         * lib/strtol.c (strtol): Undefine before defining as a macro.
26680 2021-04-02  Bruno Haible  <bruno@clisp.org>
26682         strtoll: Work around a bug on native Windows and Minix.
26683         * lib/stdlib.in.h (strtoll): Override if REPLACE_STRTOLL is 1.
26684         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_STRTOLL.
26685         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Test whether strtoll works. Set
26686         REPLACE_STRTOLL.
26687         * modules/stdlib (Makefile.am): Substitute REPLACE_STRTOLL.
26688         * modules/strtoll (configure.ac): Test REPLACE_STRTOLL.
26689         * tests/test-strtoll.c (main): Add tests of hexadecimal integer syntax.
26690         * doc/posix-functions/strtoll.texi: Mention the bug.
26692 2021-04-02  Bruno Haible  <bruno@clisp.org>
26694         strtol: Work around a bug on native Windows and Minix.
26695         * lib/stdlib.in.h (strtol): New declaration.
26696         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtol is declared.
26697         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOL, HAVE_STRTOL,
26698         REPLACE_STRTOL.
26699         * m4/strtol.m4 (gl_FUNC_STRTOL): Require gl_STDLIB_H_DEFAULTS. Test
26700         whether strtol works. Set REPLACE_STRTOL.
26701         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOL, HAVE_STRTOL,
26702         REPLACE_STRTOL.
26703         * modules/strtol (Status, Notice): Remove.
26704         (Depends-on): Add stdlib.
26705         (configure.ac): Test HAVE_STRTOL and REPLACE_STRTOL. Invoke
26706         gl_STDLIB_MODULE_INDICATOR.
26707         * tests/test-strtol.c (main): Add tests of hexadecimal integer syntax.
26708         * doc/posix-functions/strtol.texi: Mention the bug.
26710 2021-04-02  Bruno Haible  <bruno@clisp.org>
26712         strtoull: Work around a bug on native Windows and Minix.
26713         * lib/stdlib.in.h (strtoull): Override if REPLACE_STRTOULL is 1.
26714         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_STRTOULL.
26715         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Test whether strtoull works. Set
26716         REPLACE_STRTOULL.
26717         * modules/stdlib (Makefile.am): Substitute REPLACE_STRTOULL.
26718         * modules/strtoull (configure.ac): Test REPLACE_STRTOULL.
26719         * tests/test-strtoull.c (main): Add tests of hexadecimal integer syntax.
26720         * doc/posix-functions/strtoull.texi: Mention the bug.
26722 2021-04-02  Bruno Haible  <bruno@clisp.org>
26724         strtoul: Work around a bug on native Windows and Minix.
26725         Reported by Eric Blake <eblake@redhat.com> in
26726         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00082.html>.
26727         * lib/stdlib.in.h (strtoul): New declaration.
26728         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtoul is declared.
26729         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOUL, HAVE_STRTOUL,
26730         REPLACE_STRTOUL.
26731         * m4/strtoul.m4 (gl_FUNC_STRTOUL): Require gl_STDLIB_H_DEFAULTS. Test
26732         whether strtoul works. Set REPLACE_STRTOUL.
26733         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOUL, HAVE_STRTOUL,
26734         REPLACE_STRTOUL.
26735         * modules/strtoul (Status, Notice): Remove.
26736         (Depends-on): Add stdlib.
26737         (configure.ac): Test HAVE_STRTOUL and REPLACE_STRTOUL. Invoke
26738         gl_STDLIB_MODULE_INDICATOR.
26739         * tests/test-strtoul.c (main): Add tests of hexadecimal integer syntax.
26740         * doc/posix-functions/strtoul.texi: Mention the bug.
26742 2021-04-02  Bruno Haible  <bruno@clisp.org>
26744         strtol, strtoul, strtoll, strtoull: Optimize.
26745         * lib/strtol.c (GROUP_PARAM_PROTO): New macro.
26746         (INTERNAL): Define differently if !USE_NUMBER_GROUPING.
26747         (INTERNAL (strtol)): Define without 'int group' parameter if
26748         !USE_NUMBER_GROUPING.
26749         (strtol): Don't define if !USE_NUMBER_GROUPING.
26751 2021-04-02  Bruno Haible  <bruno@clisp.org>
26753         strto*l: Don't pass invalid arguments to isspace, isalnum, toupper.
26754         * lib/strtol.c (ISSPACE, ISALPHA, TOUPPER): Cast argument to
26755         'unsigned char' before passing it to the functions isspace(), isalpha(),
26756         toupper().
26758 2021-04-02  Bruno Haible  <bruno@clisp.org>
26760         glob: Reject ~user syntax, when flag GLOB_TILDE_CHECK is given.
26761         Reported and patch suggested by Eli Zaretskii <eliz@gnu.org> in
26762         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00136.html>.
26763         * lib/glob.c (__glob) [WINDOWS32]: If flag GLOB_TILDE_CHECK is given, do
26764         error handling like when ~user is allowed by the user is unknown.
26766 2021-03-31  Paul Eggert  <eggert@cs.ucla.edu>
26768         xalloc: delay setting size until success
26769         * lib/xalloc.h (x2nrealloc): Don’t change *PN until after xrealloc
26770         succeeds, in case xalloc_die or one of its callees or longjmp
26771         targets uses *PN.  Similar code in xpalloc already does this.
26773 2021-03-28  Paul Eggert  <eggert@cs.ucla.edu>
26775         xalloc: new function xpalloc, from dfa
26776         Move xpalloc from dfa.c to xmalloc.c and change it from static to
26777         extern.  The function is useful in other contexts; I’m about to
26778         use it in coreutils.
26779         * lib/dfa.c: Include idx.h, instead of rolling our own idx_t and
26780         IDX_MAX.  Do not include intprops.h; no longer needed.
26781         (xpalloc): Move from here ...
26782         * lib/xmalloc.c (xpalloc): ... to here, and make it extern.
26783         Include intprops.h and minmax.h, needed by xpalloc.
26784         * lib/xalloc.h: Include idx.h, for idx_t.
26785         * modules/dfa (Depends-on): Add idx; remove intprops.
26786         * modules/xalloc (Depends-on): Add idx, intprops, minmax.
26788 2021-03-28  Bruno Haible  <bruno@clisp.org>
26790         linked-list tests: Add another test for SIGNAL_SAFE_LIST.
26791         * tests/test-asyncsafe-linked_list-strong.c: Renamed from
26792         tests/test-asyncsafe-linked_list.c.
26793         * tests/test-asyncsafe-linked_list-strong.sh: Renamed from
26794         tests/test-asyncsafe-linked_list.sh.
26795         * tests/test-asyncsafe-linked_list-weak.c: New file, based on
26796         tests/test-asyncsafe-linked_list.c.
26797         * tests/test-asyncsafe-linked_list-weak.sh: New file, based on
26798         tests/test-asyncsafe-linked_list.sh.
26799         * modules/linked-list-tests (Files): Add
26800         tests/test-asyncsafe-linked_list-weak.*,
26801         tests/test-asyncsafe-linked_list-strong.*.
26802         (Makefile.am): Arrange to test also
26803         tests/test-asyncsafe-linked_list-weak.sh. Mark
26804         test-asyncsafe-linked_list-weak.sh and
26805         test-asyncsafe-linked_list-strong.sh as expected failures.
26807 2021-03-27  Bruno Haible  <bruno@clisp.org>
26809         renameatu tests: Add unit test for bug found on macOS.
26810         * tests/test-renameatu.c (main): Add test for identical rename with
26811         RENAME_NOREPLACE.
26813 2021-03-26  Bruno Haible  <bruno@clisp.org>
26815         unistdio/*-vasnprintf: Fix errno value (regression from yesterday).
26816         * modules/unistdio/u8-vasnprintf (Depends-on): Add free-posix.
26817         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
26818         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
26819         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
26820         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
26821         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
26822         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
26824 2021-03-26  Bruno Haible  <bruno@clisp.org>
26826         vasnprintf: Fix memory leak (regression from yesterday).
26827         * lib/vasnprintf.c (VASNPRINTF): Restore omitted CLEANUP invocation.
26828         Some more simplifications of errno around free().
26830 2021-03-26  Akim Demaille  <akim@lrde.epita.fr>
26832         fprintf-posix: fix typo
26833         * modules/fprintf-posix (Depends-on): Fix typo.
26835 2021-03-25  Paul Eggert  <eggert@cs.ucla.edu>
26837         free-posix: use more often in other modules
26838         This lets us simplify cleanup code that calls ‘free’.
26839         * lib/amemxfrm.c (amemxfrm):
26840         * lib/areadlink-with-size.c (areadlink_with_size):
26841         * lib/areadlinkat-with-size.c (areadlinkat_with_size):
26842         * lib/astrxfrm.c (astrxfrm):
26843         * lib/dprintf.c (dprintf):
26844         * lib/execute.c (execute):
26845         * lib/execvpe.c (execvpe):
26846         * lib/fchdir.c (get_name):
26847         * lib/file-has-acl.c (file_has_acl):
26848         * lib/fprintf.c (fprintf):
26849         * lib/getcwd-lgpl.c (rpl_getcwd):
26850         * lib/getgroups.c (rpl_getgroups):
26851         * lib/link.c (link, rpl_link):
26852         * lib/linkat.c (link_immediate, link_follow, linkat_follow):
26853         * lib/localename.c (newlocale, duplocale):
26854         * lib/mgetgroups.c (mgetgroups):
26855         * lib/mountlist.c (read_file_system_list):
26856         * lib/pipe-filter-gi.c (pipe_filter_gi_close):
26857         * lib/putenv.c (_unsetenv, putenv):
26858         * lib/read-file.c (read_file):
26859         * lib/rename.c (rpl_rename):
26860         * lib/savedir.c (streamsavedir, savedir):
26861         * lib/spawni.c (do_open, __spawni):
26862         * lib/spawn-pipe.c (create_pipe):
26863         * lib/striconv.c (mem_cd_iconv, str_cd_iconv, str_iconv):
26864         * lib/striconveh.c (mem_cd_iconveh_internal, str_cd_iconveh)
26865         (mem_iconveh, str_iconveh):
26866         * lib/supersede.c (open_supersede, close_supersede):
26867         * lib/vasnprintf.c (VASNPRINTF):
26868         * lib/vdprintf.c (vdprintf):
26869         * lib/vfprintf.c (vfprintf):
26870         * lib/wcscoll-impl.h (wcscoll):
26871         * lib/wcsxfrm-impl.h (wcsxfrm):
26872         * lib/xgetdomainname.c (xgetdomainname):
26873         * lib/xgethostname.c (xgethostname):
26874         Simplify by assuming that ‘free’ preserves errno.
26875         * lib/localename.c: Do not include errno.h.
26876         * modules/amemxfrm, modules/areadlink-with-size:
26877         * modules/areadlinkat-with-size, modules/astrxfrm:
26878         * modules/c-vasnprintf, modules/dprintf, modules/execute:
26879         * modules/execvpe, modules/fchdir, modules/file-has-acl:
26880         * modules/fprintf-posix, modules/getcwd-lgpl, modules/getgroups:
26881         * modules/link, modules/linkat, modules/localename:
26882         * modules/mgetgroups, modules/mountlist, modules/pipe-filter-gi:
26883         * modules/posix_spawn-internal, modules/putenv, modules/read-file:
26884         * modules/rename, modules/savedir, modules/spawn-pipe:
26885         * modules/striconv, modules/striconveh, modules/supersede:
26886         * modules/vasnprintf, modules/vdprintf, modules/vfprintf-posix:
26887         * modules/wcscoll, modules/wcsxfrm, modules/xgetdomainname:
26888         * modules/xgethostname:
26889         Depend on free-posix.
26891 2021-03-24  Paul Eggert  <eggert@cs.ucla.edu>
26893         renameatu: work around macOS 11.2 renameatx_np bug
26894         * lib/renameatu.c (renameatu) [RENAME_EXCL]: Use lstatat test here too.
26896 2021-03-22  Bruno Haible  <bruno@clisp.org>
26898         clean-temp-simple: Fix a rare memory leak.
26899         * lib/clean-temp-simple.c (register_temporary_file): Fix cleanup code.
26901 2021-03-22  Bruno Haible  <bruno@clisp.org>
26903         clean-temp-simple: Relicense under LGPLv2+.
26904         * modules/clean-temp-simple (License): Change to LGPLv2+.
26906 2021-03-22  Bruno Haible  <bruno@clisp.org>
26908         clean-temp-simple: Remove dependency upon xalloc, xalloc-die, xlist.
26909         * lib/clean-temp-private.h (clean_temp_init): Change return type to
26910         'int'.
26911         * lib/clean-temp-simple.h (register_temporary_file): Change return type
26912         to 'int'.
26913         * lib/clean-temp-simple.c: Don't include xalloc.h, gl_xlist.h. Include
26914         gl_list.h instead.
26915         (init_failed): New variable.
26916         (do_clean_temp_init): Set it.
26917         (clean_temp_init): Return an error indicator.
26918         (register_temporary_file): Invoke gl_list_nx_create_empty instead of
26919         gl_list_create_empty. Invoke strdup instead of xstrdup. Invoke
26920         gl_list_nx_add_first instead of gl_list_add_first. Return an error
26921         indicator.
26922         * lib/clean-temp.c (create_temp_dir, gen_register_open_temp): Call
26923         xalloc_die() if clean_temp_init or register_temporary_file failed.
26924         * modules/clean-temp-simple (Depends-on): Remove xalloc, xalloc-die,
26925         xlist.
26927 2021-03-22  Bruno Haible  <bruno@clisp.org>
26929         clean-temp-simple: New module.
26930         * lib/clean-temp-simple.h: New file, based on lib/clean-temp.h.
26931         * lib/clean-temp-private.h: New file, based on lib/clean-temp.c.
26932         * lib/clean-temp-simple.c: New file, based on lib/clean-temp.c.
26933         * lib/clean-temp.h: Include clean-temp-simple.h.
26934         (register_temporary_file, unregister_temporary_file,
26935         cleanup_temporary_file): Remove declarations.
26936         * lib/clean-temp.c: Don't include <limits.h>, <stdint.h>. Include
26937         <signal.h>, <stdio.h>, clean-temp-simple.h, clean-temp-private.h.
26938         (file_cleanup_list_lock, file_cleanup_list): Moved to
26939         clean-temp-simple.c.
26940         (struct tempdir, dir_cleanup_list, struct closeable_fd, descriptors):
26941         Moved to clean-temp-private.h.
26942         (string_equals, SIZE_BITS, string_hash, fatal_signal_set,
26943         init_fatal_signal_set, asyncsafe_close): Moved to clean-temp-simple.c.
26944         (asyncsafe_fclose_variant): Use get_fatal_signal_set() here.
26945         (cleanup_action, do_init_clean_temp, clean_temp_once, init_clean_temp,
26946         register_temporary_file, unregister_temporary_file, do_unlink,
26947         cleanup_temporary_file): Moved to clean-temp-simple.c.
26948         (create_temp_dir, cleanup_temp_file, cleanup_temp_dir_contents,
26949         gen_register_open_temp, close_temp): Update for changed function names.
26950         (fclose_variant_temp): Don't call init_fatal_signal_set().
26951         * modules/clean-temp-simple: New file, based on modules/clean-temp.
26952         * modules/clean-temp (Depends-on): Add clean-temp-simple, list. Remove
26953         stdint.
26954         (configure.ac): Don't define SIGNAL_SAFE_LIST here.
26956 2021-03-22  Bruno Haible  <bruno@clisp.org>
26958         error: Relicense under LGPLv2+.
26959         Pino Toscano's approval is in
26960         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00109.html>.
26961         Paul Eggert's approval is in
26962         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00110.html>.
26963         * modules/error (License): Change to LGPLv2+.
26965 2021-03-22  Bruno Haible  <bruno@clisp.org>
26967         getprogname: Relicense under LGPLv2+.
26968         Pino Toscano's approval is in
26969         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00109.html>.
26970         Paul Eggert's approval is in
26971         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00110.html>.
26972         Jim Meyering's approval is in
26973         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00107.html>.
26974         Gisle Vanem's approval is in
26975         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00115.html>.
26976         Daniel Richard G's approval is in
26977         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00112.html>.
26978         John David Anglin's approval is in
26979         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00108.html>.
26980         Benji Wiebe's approval is in
26981         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00114.html>.
26982         * modules/getprogname (License): Change to LGPLv2+.
26984 2021-03-22  Bruno Haible  <bruno@clisp.org>
26986         fatal-signal: Relicense under LGPLv2+.
26987         Eric Blake's approval is in
26988         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00111.html>.
26989         * modules/fatal-signal (License): Change to LGPLv2+.
26991 2021-03-22  Bruno Haible  <bruno@clisp.org>
26993         doc: Mention an open glibc bug.
26994         * doc/posix-functions/mbrtowc.texi: Mention the possible out-of-range
26995         wchar_t values returned by this function on glibc.
26996         * doc/posix-functions/mbtowc.texi: Likewise.
26998 2021-03-22  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
27000         mbrtowc: Remove a redundant condition.
27001         * lib/mbrtowc-impl-utf8.h: There is no need to check for c == 0xf4
27002         when !(c < 0xf4), as ten lines earlier c <= 0xf4 was established.
27004 2021-03-22  Bruno Haible  <bruno@clisp.org>
27006         linkedhash-list: Relicense under LGPLv2+.
27007         Paul Eggert's approval is in
27008         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00102.html>.
27009         * modules/linkedhash-list (License): Change to LGPLv2+.
27011 2021-03-21  Bruno Haible  <bruno@clisp.org>
27013         fatal-signal: Remove dependency upon xalloc.
27014         * lib/fatal-signal.h (at_fatal_signal): Change return type to 'int'.
27015         * lib/fatal-signal.c: Don't include xalloc.h.
27016         (at_fatal_signal): Return an error indicator.
27017         * modules/fatal-signal (Depends-on): Remove xalloc.
27018         * NEWS: Mention the change.
27019         * lib/term-style-control.c: Include xalloc.h.
27020         (ensure_other_signal_handlers): Test return value of at_fatal_signal.
27021         * lib/clean-temp.c (do_init_clean_temp): Likewise.
27022         * lib/wait-process.c (register_slave_subprocess): Likewise.
27023         * modules/term-style-control (Depends-on): Add xalloc-die.
27024         * modules/clean-temp (Depends-on): Likewise.
27025         * modules/wait-process (Depends-on): Likewise.
27027 2021-03-21  Paul Eggert  <eggert@cs.ucla.edu>
27029         diacrit: remove
27030         * MODULES.html.sh (func_all_modules), NEWS: Remove diacrit.
27031         * lib/diacrit.c, lib/diacrit.h, modules/diacrit: Remove.
27033         tests: fix signed overflow issues
27034         * tests/test-dynarray.c (value_at): Avoid undefined behavior
27035         in signed integer multiplication.
27036         * tests/test-scratch-buffer.c (byte_at): Likewise, for the
27037         theoretically-possible case where size_t is narrower than int.
27039 2021-03-21  Bruno Haible  <bruno@clisp.org>
27041         doc: More updates.
27042         * doc/glibc-functions/sethostname.texi: Update regarding macOS.
27043         * doc/glibc-functions/sethostname.texi: List the affected platforms.
27045         doc: Update for macOS 11.1.
27046         * doc/posix-headers/*.texi: Update.
27047         * doc/glibc-headers/*.texi: Update.
27048         * doc/posix-functions/*.texi: Likewise.
27049         * doc/pastposix-functions/*.texi: Likewise.
27050         * doc/glibc-functions/*.texi: Likewise.
27051         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Update cross-compilation
27052         guess.
27054 2021-03-21  Bruno Haible  <bruno@clisp.org>
27056         ftell: Document bug in macOS >= 10.15.
27057         * doc/posix-functions/ftell.texi: Mention the macOS bug.
27059 2021-03-20  Bruno Haible  <bruno@clisp.org>
27061         ftello: Work around bug in macOS >= 10.15.
27062         Reported by Martin Storsjö <martin@martin.st> in
27063         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00002.html>.
27064         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): On macOS, don't define
27065         FUNC_UNGETC_BROKEN. Instead, set gl_ftello_broken_after_ungetc to yes.
27066         * m4/ftello.m4 (gl_FUNC_FTELLO): Invoke gl_FUNC_UNGETC_WORKS, and
27067         arrange to provide the workaround if ftello is broken after ungetc.
27068         * lib/ftello.c: Include <errno.h>, intprops.h.
27069         (ftello) [FTELLO_BROKEN_AFTER_UNGETC]: Implement from scratch.
27070         * modules/ftello (Files): Add m4/ungetc.m4.
27071         (Depends-on): Add intprops.
27072         * doc/posix-functions/ftello.texi: Mention the macOS bug.
27074 2021-03-20  Bruno Haible  <bruno@clisp.org>
27076         math C++ tests: Fix compilation error on macOS 11.2.
27077         * lib/math.in.h (isnan): For clang >= 12 on macOS, declare 'rpl_isnan',
27078         not 'isnan'.
27080 2021-03-18  Bruno Haible  <bruno@clisp.org>
27082         simple-atomic tests: Fix compilation error on Solaris 10.
27083         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
27084         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00085.html>.
27085         * tests/test-simple-atomic.c (yield): Define only after all #includes.
27087 2021-03-18  Bruno Haible  <bruno@clisp.org>
27089         simple-atomic: Fix compilation error on Solaris 10/x86_64 with cc.
27090         * lib/simple-atomic.c (atomic_compare_and_swap_ptr): Correct asm
27091         instruction.
27093 2021-03-18  Paul Eggert  <eggert@cs.ucla.edu>
27095         argmatch: fix testing typo
27096         Problem and fix reported by Gisle Vanem in:
27097         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00083.html
27098         * lib/argmatch.c (main) [TEST]: Fix address-of typo.
27100 2021-03-14  Paul Eggert  <eggert@cs.ucla.edu>
27102         intprops: improve commentary
27103         * lib/intprops.h: Improve comments about promotion etc.
27105 2021-03-14  Bruno Haible  <bruno@clisp.org>
27107         time_rz: Put reference documentation into the .h file.
27108         * lib/time.in.h (timezone_t, tzalloc, tzfree, localtime_rz, mktime_z):
27109         Add comments, based on modules/time_rz.
27110         * modules/time_rz (Comment): Remove section.
27112 2021-03-14  Bruno Haible  <bruno@clisp.org>
27114         parse-datetime tests: Avoid a test failure on NetBSD.
27115         Reported by Thomas Klausner <tk@giga.or.at> in
27116         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00069.html>.
27117         * tests/test-parse-datetime.c (main): Skip two tests on NetBSD.
27119 2021-03-10  Paul Eggert  <eggert@cs.ucla.edu>
27121         libc-config: port to DragonFlyBSD 5.9
27122         DragonFlyBSD defines __nonnull incompatibly with glibc,
27123         so avoid the use of __nonnull in Gnulib code.
27124         Problem reported by Gavin Smith in:
27125         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00066.html
27126         * lib/cdefs.h (__attribute_nonnull__): Rename from __nonnull.
27127         All uses in Gnulib changed.  There should be no need to change
27128         glibc code that is not shared with Gnulib.
27129         (__nonnull): New macro, defined in terms of __attribute_nonnull__,
27130         and which can be used in glibc code that is not shared with Gnulib.
27132 2021-03-07  Paul Eggert  <eggert@cs.ucla.edu>
27134         manywarnings: modernize documentation
27135         Problem reported by Reuben Thomas in:
27136         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00046.html
27137         * doc/manywarnings.texi (manywarnings): Update in
27138         the light of recent changes to the manywarnings module.
27140 2021-03-07  Bruno Haible  <bruno@clisp.org>
27142         sysexits: Fix for Haiku.
27143         * lib/sysexits.in.h: Don't assume that <sysexits.h>, when it exists,
27144         defines anything.
27145         * doc/glibc-headers/sysexits.texi: Mention the Haiku bug.
27147 2021-03-07  Bruno Haible  <bruno@clisp.org>
27149         Rename GNULIB_WCHAR_SINGLE to GNULIB_WCHAR_SINGLE_LOCALE.
27150         * lib/lc-charset-dispatch.c: Test GNULIB_WCHAR_SINGLE_LOCALE instead of
27151         GNULIB_WCHAR_SINGLE.
27152         * lib/wcwidth.c: Likewise.
27153         * tests/test-wcwidth.c: Likewise.
27154         * doc/multithread.texi: Document GNULIB_WCHAR_SINGLE_LOCALE instead of
27155         GNULIB_WCHAR_SINGLE.
27156         * NEWS: Document the change.
27158 2021-03-06  Bruno Haible  <bruno@clisp.org>
27160         mbrtowc: Allow locking optimization independently of 'unlocked-io'.
27161         * lib/mbtowc-lock.h: Test GNULIB_MBRTOWC_SINGLE_THREAD instead of
27162         USE_UNLOCKED_IO.
27163         * doc/multithread.texi: Document GNULIB_MBRTOWC_SINGLE_THREAD.
27165 2021-03-06  Bruno Haible  <bruno@clisp.org>
27167         regex: Allow locking optimization independently of 'unlocked-io'.
27168         * lib/regex_internal.h: Test GNULIB_REGEX_SINGLE_THREAD instead of
27169         USE_UNLOCKED_IO.
27170         * doc/multithread.texi: Document GNULIB_REGEX_SINGLE_THREAD.
27172 2021-03-06  Bruno Haible  <bruno@clisp.org>
27174         exclude: Allow stdio optimization independently of 'unlocked-io'.
27175         * lib/exclude.c: Test GNULIB_EXCLUDE_SINGLE_THREAD instead of
27176         USE_UNLOCKED_IO.
27177         * modules/exclude (Depends-on): Add unlocked-io-internal.
27178         * doc/multithread.texi: Document GNULIB_EXCLUDE_SINGLE_THREAD.
27180 2021-03-06  Bruno Haible  <bruno@clisp.org>
27182         readutmp: Optimize stdio accesses.
27183         * lib/readutmp.c: Include unlocked-io.h unconditionally.
27184         * modules/readutmp (Depends-on): Add unlocked-io-internal.
27186 2021-03-06  Bruno Haible  <bruno@clisp.org>
27188         mountlist: Optimize stdio accesses.
27189         * lib/mountlist.c: Include unlocked-io.h unconditionally.
27190         * modules/mountlist (Depends-on): Add unlocked-io-internal.
27192 2021-03-06  Bruno Haible  <bruno@clisp.org>
27194         getusershell: Optimize stdio accesses when possible.
27195         * lib/getusershell.c: Test GNULIB_GETUSERSHELL_SINGLE_THREAD instead of
27196         USE_UNLOCKED_IO.
27197         * modules/getusershell (Depends-on): Add unlocked-io-internal.
27198         * doc/multithread.texi: Document GNULIB_GETUSERSHELL_SINGLE_THREAD.
27200 2021-03-06  Bruno Haible  <bruno@clisp.org>
27202         unlocked-io-internal: New module.
27203         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Don't define
27204         USE_UNLOCKED_IO here.
27205         * modules/unlocked-io-internal: New file, based on modules/unlocked-io.
27206         * modules/unlocked-io (Description): Clarify.
27207         (Files, Depends-on): Just use the unlocked-io-internal module.
27208         (configure.ac): Define GNULIB_STDIO_SINGLE_THREAD and USE_UNLOCKED_IO
27209         here.
27210         * doc/multithread.texi: Clarify when the 'unlocked-io' module can be
27211         used.
27213 2021-03-06  Bruno Haible  <bruno@clisp.org>
27215         posixtm: Remove unused includes.
27216         * lib/posixtm.c: Don't include <stdio.h>, <sys/types.h>, unlocked-io.h.
27218 2021-03-06  Bruno Haible  <bruno@clisp.org>
27220         dynarray: Add tests.
27221         * tests/test-dynarray.c: New file.
27222         * modules/dynarray-tests: New file.
27224         dynarray: Make the module usable on its own.
27225         * lib/dynarray.h: Document the exported API. Comments taken from
27226         lib/malloc/dynarray-skeleton.c and lib/malloc/dynarray.h.
27227         Distinguish an internal include from an include for instantiation.
27228         In the latter case, include <libc-config.h> and
27229         <malloc/dynarray-skeleton.c>.
27230         * modules/dynarray (Depends-on): Add intprops.
27231         (Include): Reduce to just "dynarray.h".
27233 2021-03-06  Bruno Haible  <bruno@clisp.org>
27235         scratch_buffer: Add comment.
27236         * lib/scratch_buffer.h: Add comment.
27238 2021-03-06  Paul Eggert  <eggert@cs.ucla.edu>
27240         parse-datetime2: fix licensing
27241         Problem reported by Bruno Haible in:
27242         https://lists.gnu.org/r/bug-gnulib/2021-03/msg00017.html
27243         * gnulib-tool (func_get_license): Treat parse-datetime2
27244         (actually, anything starting with "parse-datetime")
27245         like parse-datetime, as far as licenses go.
27247 2021-03-06  Bruno Haible  <bruno@clisp.org>
27249         free-posix: Update documentation.
27250         * doc/posix-functions/free.texi: Add platform details.
27252 2021-03-06  Bruno Haible  <bruno@clisp.org>
27254         doc: Update for glibc 2.33.
27255         * doc/glibc-functions/mallinfo2.texi: New file.
27256         * doc/gnulib.texi: Include it.
27257         (Glibc sys/vtimes.h): Remove section.
27258         * doc/glibc-functions/vtimes.texi: Remove file.
27259         * doc/pastposix-functions/h_errno.texi: Update.
27260         * doc/posix-functions/*.texi: Likewise.
27261         * doc/glibc-functions/*.texi: Likewise.
27263 2021-03-04  Bruno Haible  <bruno@clisp.org>
27265         stddef: Generalize tcc workaround to other compilers.
27266         Suggested by Paul Eggert in
27267         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00027.html>.
27268         * lib/stddef.in.h: Undefine the __need_* macros with all compilers.
27269         * doc/posix-headers/stddef.texi: Mention that the TinyCC bug also exists
27270         on macOS.
27272 2021-03-04  Paul Eggert  <eggert@cs.ucla.edu>
27274         stdalign: port to tcc + glibc
27275         * lib/stdalign.in.h (_Alignas): Do not define using __attribute__
27276         if __attribute__ is defined as a macro, as __attribute__ surely a
27277         no-op in that case and this is an area where __attribute__ cannot
27278         simply be ignored.
27279         * m4/stdalign.m4 (gl_STDALIGN_H): Include <stdint.h> so that
27280         it #defines __attribute__(x) to nothing on glibc-based systems
27281         when non-GNU-C-compatible compilers are used.
27282         This exposes a bug in Tiny C Compiler 0.9.27’s implementation
27283         of _Alignas on glibc platforms.
27285 2021-03-03  Bruno Haible  <bruno@clisp.org>
27287         asyncsafe-spin, simple-atomic: Add support for tcc/x86.
27288         * lib/asyncsafe-spin.c (memory_barrier): With tcc/x86, don't use the
27289         'mfence' instruction.
27290         * lib/simple-atomic.c (memory_barrier): Likewise.
27292         asyncsafe-spin, simple-atomic: Add support for tcc.
27293         * lib/asyncsafe-spin.c (memory_barrier, atomic_compare_and_swap): On
27294         i386 and x86_64, treat tcc like older GCC or clang.
27295         * lib/simple-atomic.c (memory_barrier, atomic_compare_and_swap,
27296         atomic_compare_and_swap_ptr): Likewise.
27298 2021-03-02  Bruno Haible  <bruno@clisp.org>
27300         stddef: Work around an interoperability problem of tcc with glibc.
27301         Reported by Luca Saiu <positron@gnu.org> in
27302         <https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00011.html>.
27303         * lib/stddef.in.h [__TINYC__]: In case of the special invocation
27304         convention, undefine the macros that TinyCC's <stddef.h> should undefine
27305         but doesn't.
27306         * doc/posix-headers/stddef.texi: Mention the TinyCC bug.
27308 2021-03-02  Paul Eggert  <eggert@cs.ucla.edu>
27310         mbrtowc: port to AIX 7.1 with xlc 12.1
27311         Fix a problem with locks when building GNU Tar (Savannah commit
27312         55f2a0772e08b9febac3ac0de5cb048d4c60d2f5) on AIX 7.1 with IBM XL
27313         C/C++ V12.1 using ‘./configure CC=xlc’.  The link fails due to
27314         missing definitions of pthread_mutex_lock and
27315         pthread_mutex_unlock.  GNU Tar uses unlocked-io and so
27316         should not need to worry about multithreading or locks.
27317         * lib/mbtowc-lock.h (mbtowc_with_lock) [USE_UNLOCKED_IO]:
27318         Don’t bother with locks, since this app is single-threaded.
27319         There may be similar linking problems with lib/nl_langinfo.c and
27320         lib/setlocale_null.c but my GNU Tar build didn’t run into them, so
27321         I left them alone for now.
27323 2021-03-01  Paul Eggert  <eggert@cs.ucla.edu>
27325         unlocked-io: do not redefine getc_unlocked etc.
27326         I ran into this problem on AIX 7.1 with GNU Tar, which
27327         enables visibility of getc_unlocked etc. after testing
27328         whether they’re declared, causing argp-namefrob.h and
27329         unlocked-io.h to redefine the macros.
27330         * lib/argp-namefrob.h, lib/unlocked-io.h:
27331         (clearerr_unlocked, feof_unlocked ferror_unlocked)
27332         (fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked)
27333         (fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked)
27334         (putc_unlocked, putchar_unlocked): Do not define if already defined.
27336         parse-datetime2: new module
27337         This splits the old parse-datetime into two parts; the
27338         first is parse-datetime2 which supports all the new bells
27339         and whistles, the second is parse-datetime, which reverts to
27340         its original intent.  This avoids some bogus diagnostics
27341         when build GNU Tar with gcc -flto -fanalyze and
27342         with --enable-gcc-warnings.  And it slims down the
27343         executable a bit.
27344         * NEWS: Mention this.
27345         * lib/parse-datetime.y (parser_control) [!GNULIB_PARSE_DATETIME2]:
27346         Omit parse_datetime_debug member.
27347         (debugging): New function.  Use it everywhere the old code
27348         would load parse_datetime_debug.
27349         (parse_datetime_body): New static function, with the body
27350         of the old parse_datetime2.  Set pc.parse_datetime_debug
27351         only if GNULIB_PARSE_DATETIME2.
27352         (parse_datetime2, parse_datetime): Use this new function.
27353         (parse_datetime2) [!GNULIB_PARSE_DATETIME2]: Remove.
27354         * modules/parse-datetime2: New file.
27356 2021-02-27  Bruno Haible  <bruno@clisp.org>
27358         string-buffer: Fixes.
27359         * modules/string-buffer (License): Change to LGPL.
27360         * tests/test-string-buffer.c (main): Add another sb_appendf call, that
27361         is more likely to fail.
27363 2021-02-25  Bernhard Voelker  <mail@bernhard-voelker.de>
27365         gitlog-to-changelog: output SHA in "empty commit message" warning
27366         * build-aux/gitlog-to-changelog: Add $sha to above warning diagnostic.
27368 2021-02-24  Paul Eggert  <eggert@cs.ucla.edu>
27370         glob: include libc-config.h in a more-standard way
27371         Inspired by Tom Tromey’s report for RHEL 6 in:
27372         https://lists.gnu.org/r/bug-gnulib/2021-02/msg00088.html
27373         * lib/glob.c [!_LIBC]: Include libc-config.h, not just config.h
27374         * lib/glob.in.h: Include libc-config.h only if needed.
27376 2021-02-21  Bruno Haible  <bruno@clisp.org>
27378         string-buffer: Add tests.
27379         * tests/test-string-buffer.c: New file.
27380         * modules/string-buffer-tests: New file.
27382         string-buffer: New module.
27383         * lib/string-buffer.h: New file.
27384         * lib/string-buffer.c: New file.
27385         * modules/string-buffer: New file.
27386         * doc/posix-functions/open_memstream.texi: Mention the new module.
27388 2021-02-21  Bruno Haible  <bruno@clisp.org>
27390         scratch_buffer: Document the exported API.
27391         * lib/scratch_buffer.h: Add comments, taken from
27392         lib/malloc/scratch_buffer.h.
27394 2021-02-21  Bruno Haible  <bruno@clisp.org>
27396         DEPENDENCIES: Update.
27397         * DEPENDENCIES: Require GCC >= 3.1. Tell where to find working GNU m4
27398         tarballs. Mention awk. Point to pre-built packages for gettext, bison,
27399         gperf, texinfo.
27401 2021-02-20  Bruno Haible  <bruno@clisp.org>
27403         parse-datetime: Fix comment.
27404         * modules/parse-datetime (Makefile.am): Fix comment.
27406 2021-02-16  Bruno Haible  <bruno@clisp.org>
27408         passfd: Fix test failure on FreeBSD >= 12 and NetBSD in 64-bit mode.
27409         * lib/passfd.c (recvfd): Use the CMSG_SPACE macro to compute the value
27410         for msg_controllen.
27412 2021-02-16  Paul Eggert  <eggert@cs.ucla.edu>
27414         Port better to macOS Mojave
27415         Problem reported by Tom Shields in:
27416         https://lists.gnu.org/r/bug-gnulib/2021-02/msg00064.html
27417         * config/srclist.txt: Comment out dynarray_finalize.c.
27418         * lib/dynarray.h (__libc_dynarray_at_failure): Don’t include
27419         libc-config.h here, as that’s the includer’s responsibility.
27420         * lib/malloc/dynarray_at_failure.c:
27421         * lib/malloc/dynarray_emplace_enlarge.c:
27422         * lib/malloc/dynarray_finalize.c:
27423         * lib/malloc/dynarray_resize.c:
27424         * lib/malloc/dynarray_resize_clear.c:
27425         If _LIBC is not defined, include libc-config.h.
27427 2021-02-15  Bruno Haible  <bruno@clisp.org>
27429         linked-list test: Add test for SIGNAL_SAFE_LIST. (It currently fails.)
27430         * tests/test-asyncsafe-linked_list.sh: New file.
27431         * tests/test-asyncsafe-linked_list.c: New file.
27432         * modules/linked-list-tests (Files): Add them.
27433         (Depends-on): Add thread, yield, nanosleep, sigaction, sigprocmask.
27434         (Makefile.am): Arrange to compile test-asyncsafe-linked_list.c and run
27435         test-asyncsafe-linked_list.sh.
27437 2021-02-14  Bruno Haible  <bruno@clisp.org>
27439         simple-atomic: Add tests.
27440         * tests/test-simple-atomic.c: New file.
27441         * modules/simple-atomic-tests: New file.
27443         simple-atomic: New module.
27444         * lib/simple-atomic.h: New file.
27445         * lib/simple-atomic.c: New file, based on lib/asyncsafe-spin.c.
27446         * modules/simple-atomic: New file.
27448 2021-02-14  Bruno Haible  <bruno@clisp.org>
27450         Fix distinction of 32-bit/64-bit mode with xlc 13.1.3 on AIX.
27451         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI, gl_HOST_CPU_C_ABI_32BIT):
27452         Test __LP64__ instead of _ARCH_PPC64.
27453         * m4/lib-ld.m4 (AC_LIB_PROG_LD): Likewise.
27454         * lib/stddef.in.h: Likewise.
27456 2021-02-13  Ozkan Sezer  <sezeroz@gmail.com>
27458         lib-symbol-visibility: Make it work with -Wmissing-prototypes.
27459         * m4/visibility.m4 (gl_VISIBILITY): Avoid error from simultaneous use of
27460         -Wmissing-prototypes and -Werror.
27462 2021-02-08  Bruno Haible  <bruno@clisp.org>
27464         stddef: Fix test-stddef compilation error on MidnightBSD/x86.
27465         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS, rpl_max_align_t, max_align_t):
27466         Don't ignore HAVE_MAX_ALIGN_T if the compiler is clang.
27468 2021-02-08  Bruno Haible  <bruno@clisp.org>
27470         Document non-standard prototypes on MidnightBSD.
27471         * doc/posix-functions/initstate.texi: Mention different prototype on
27472         MidnightBSD 2.0.
27473         * doc/posix-functions/srandom.texi: Likewise.
27474         * doc/posix-functions/getlogin_r.texi: Likewise.
27475         * doc/glibc-functions/sethostname.texi: Likewise.
27477 2021-02-08  Bruno Haible  <bruno@clisp.org>
27479         posixtm tests: Fix warnings seen on MidnightBSD/x86.
27480         * tests/test-posixtm.c (main): Convert two 'time_t' values to 'long' for
27481         printing.
27483 2021-02-07  Bruno Haible  <bruno@clisp.org>
27485         Add cross-compilation guesses for MidnightBSD.
27486         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): When cross-compiling, use the
27487         result from native compilation.
27488         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
27489         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Likewise.
27490         * m4/mprotect.m4 (gl_FUNC_MPROTECT_WORKS): Likewise.
27491         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_SECURE): Likewise.
27492         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_INFINITE,
27493         gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_F,
27494         gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
27495         gl_SNPRINTF_DIRECTIVE_N, gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
27496         * m4/strfmon_l.m4 (gl_FUNC_STRFMON_L): Likewise.
27497         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Use predetermined
27498         result on MidnightBSD.
27500 2021-02-07  Bruno Haible  <bruno@clisp.org>
27502         threadlib: Add support for MidnightBSD.
27503         * m4/threadlib.m4 (gl_WEAK_SYMBOLS, gl_THREADLIB_BODY): On MidnightBSD,
27504         use the same test as on FreeBSD.
27506 2021-02-07  Bruno Haible  <bruno@clisp.org>
27508         host-os: Add support for MidnightBSD.
27509         * m4/host-os.m4 (gl_HOST_OS): On MidnightBSD, set HOST_OPERATING_SYSTEM
27510         to "MidnightBSD", not "Midnightbsd".
27512 2021-02-07  Bruno Haible  <bruno@clisp.org>
27514         c-stack: Adjust for MidnightBSD.
27515         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): On MidnightBSD,
27516         set FAULT_YIELDS_SIGBUS.
27518 2021-02-07  Bruno Haible  <bruno@clisp.org>
27520         relocatable-prog: Add support for MidnightBSD.
27521         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Use the ELF $ORIGIN trick
27522         also on MidnightBSD >= 1.1.
27523         * build-aux/config.libpath: Treat MidnightBSD like FreeBSD.
27524         * build-aux/reloc-ldflags: Likewise.
27526 2021-02-07  Bruno Haible  <bruno@clisp.org>
27528         havelib: Add support for MidnightBSD.
27529         * build-aux/config.rpath: Treat MidnightBSD like FreeBSD >= 4.
27531 2021-02-07  Bruno Haible  <bruno@clisp.org>
27533         wcwidth: Document MidnightBSD bug.
27534         * doc/posix-functions/wcwidth.texi: Mention MidnightBSD as an affected
27535         platform.
27536         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Update comments.
27538 2021-02-07  Bruno Haible  <bruno@clisp.org>
27540         pthread_sigmask: Document MidnightBSD bug.
27541         * doc/posix-functions/pthread_sigmask.texi: Mention MidnightBSD as an
27542         affected platform.
27543         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Update
27544         cross-compilation guess accordingly.
27546 2021-02-07  Bruno Haible  <bruno@clisp.org>
27548         immutable: Avoid test failures on MidnightBSD.
27549         * tests/test-immutable.c (install_segv_handler): On FreeBSD, install the
27550         handler also for SIGBUS.
27552 2021-02-07  Bruno Haible  <bruno@clisp.org>
27554         c32is*: Avoid test failures on MidnightBSD.
27555         * tests/test-c32isalnum.c (main): On FreeBSD, disable tests that fail on
27556         MidnightBSD 1.1.
27557         * tests/test-c32isalpha.c (main): Likewise.
27558         * tests/test-c32isblank.c (main): Likewise.
27559         * tests/test-c32islower.c (main): Likewise.
27560         * tests/test-c32isupper.c (main): Likewise.
27562 2021-02-05  Paul Eggert  <eggert@cs.ucla.edu>
27564         regex: fix comment location
27565         * lib/regexec.c (update_regs): Move comment.
27567         regex-tests: add bug 11053 test
27568         * tests/test-regex.c (main): New test case for glibc bug 11053.
27570         regex: debug check for set member duplicates
27571         * lib/regex_internal.c (re_node_set_insert): Add a DEBUG_ASSERT
27572         that would have caught some recently-fixed performance bugs
27573         that caused sets to contain duplicate members.
27575         regex: fix longstanding backref match bug
27576         This fixes a longstanding glibc bug concerning backreferences
27577         <https://sourceware.org/11053> (2009-12-04).
27578         * lib/regexec.c (proceed_next_node, push_fail_stack)
27579         (pop_fail_stack): Push and pop the previous registers
27580         as well as the current ones.  All callers changed.
27581         (set_regs): Also pop if CUR_NODE has already been checked,
27582         so that it does not get added as a duplicate set entry.
27583         (update_regs): Fix comment location.
27584         * tests/test-regex.c (tests): New constant.
27585         (bug_regex11): New test function.
27586         (main): Bump alarm value.  Call new test function.
27588         regex: avoid duplicate in espilon closure
27589         * lib/regcomp.c (calc_eclosure_iter): Insert NODE into epsilon
27590         closure first rather than last.  Otherwise, the epsilon closure
27591         might contain a duplicate of NODE.
27593         regex-tests: fix typo
27594         * tests/test-regex.c (main): Fix typo that would have caused an
27595         old test case to report incorrect values on failure.
27597         regex: make it easier to merge into glibc
27598         * lib/regex_internal.h [_LIBC]: Do not include Gnulib’s dynarray.h.
27600         regex: minor refactoring
27601         * lib/regexec.c (proceed_next_node): Use more-local decls.
27603         regex: avoid undefined behavior
27604         * lib/regexec.c (pop_fail_stack): If the stack is empty, return -1
27605         instead of indulging in undefined behavior.  This simplifies
27606         callers, and avoids undefined behavior in some cases (see glibc
27607         bug 11053, though this change does not fix that overall bug).
27609         regex: improve comments
27610         * lib/regexec.c: Add and correct comments about return values.
27612 2021-01-31  Bruno Haible  <bruno@clisp.org>
27614         relocatable-prog-wrapper: Tweak today's patch.
27615         * build-aux/install-reloc (func_create_wrapper): Clean up free.o.
27617 2021-01-31  Bruno Haible  <bruno@clisp.org>
27619         fmaf: Document QEMU bug.
27620         * doc/posix-functions/fmaf.texi: Add note about QEMU bug.
27622 2021-01-31  Bruno Haible  <bruno@clisp.org>
27624         remainderl: Work around musl libc bug.
27625         * doc/posix-functions/remainderl.texi: Document musl libc bug.
27626         * m4/remainderl.m4 (gl_FUNC_REMAINDERL_WORKS): Add more tests. Update
27627         cross compilation guess.
27629 2021-01-31  Bruno Haible  <bruno@clisp.org>
27631         log2l: Work around musl libc bugs.
27632         * doc/posix-functions/log2l.texi: Document musl libc bugs.
27633         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Add more tests. Update cross
27634         compilation guess.
27636 2021-01-31  Bruno Haible  <bruno@clisp.org>
27638         log1pl: Work around musl libc bug.
27639         * doc/posix-functions/log1pl.texi: Document musl libc bug.
27640         * m4/log1pl.m4 (gl_FUNC_LOG1PL_WORKS): New macro.
27641         (gl_FUNC_LOG1PL): Invoke it.
27643 2021-01-31  Bruno Haible  <bruno@clisp.org>
27645         log10l: Document musl libc bug.
27646         * doc/posix-functions/log10l.texi: Document musl libc bug.
27647         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Update comment and cross
27648         compilation guess.
27650 2021-01-31  Bruno Haible  <bruno@clisp.org>
27652         logl: Document musl libc bug.
27653         * doc/posix-functions/logl.texi: Document musl libc bug.
27654         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Update comment and cross
27655         compilation guess.
27657 2021-01-31  Bruno Haible  <bruno@clisp.org>
27659         expm1l: Document musl libc bug.
27660         * doc/posix-functions/expm1l.texi: Document musl libc bug.
27661         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Update comment and cross
27662         compilation guess.
27664 2021-01-31  Bruno Haible  <bruno@clisp.org>
27666         expl: Document musl libc bug.
27667         * doc/posix-functions/expl.texi: Document musl libc bug.
27668         * m4/expl.m4 (gl_FUNC_EXPL): Update comment and cross
27669         compilation guess.
27671 2021-01-31  Bruno Haible  <bruno@clisp.org>
27673         relocatable-prog-wrapper: Update after recent changes.
27674         * lib/relocwrapper.c: Update comments.
27675         * modules/relocatable-prog-wrapper (Files): Add lib/scratch_buffer.h,
27676         lib/malloc/scratch_buffer*, lib/malloc.c, lib/realloc.c, lib/free.c,
27677         lib/mempcpy.c, lib/rawmemchr.c, m4/lstat.m4. Remove lib/lstat.c.
27678         (Depends-on): Add c99, eloop-threshold, fcntl-h, idx, intprops,
27679         libc-config, stddef, sys_stat. Remove alloca-opt.
27680         (configure.ac): Invoke gl_FUNC_MALLOC_POSIX, gl_FUNC_REALLOC_POSIX,
27681         gl_FUNC_FREE, gl_FUNC_MEMPCPY, gl_FUNC_RAWMEMCHR.
27682         * lib/canonicalize-lgpl.c (memmove): Undefine in the relocwrapper.
27683         * build-aux/install-reloc (func_create_wrapper): Compile also
27684         malloc/scratch_buffer_*.c, malloc.c, realloc.c, free.c, mempcpy.c,
27685         rawmemchr.c. Don't compile lstat.c.
27687         Make it possible to compile rawmemchr.c separately, unconditionally.
27688         * lib/rawmemchr.c: Don't define rawmemchr if not needed.
27690         Make it possible to compile mempcpy.c separately, unconditionally.
27691         * lib/mempcpy.c: Don't define mempcpy if not needed.
27693         Make it possible to compile free.c separately, unconditionally.
27694         * m4/free.m4 (gl_FUNC_FREE): Define HAVE_FREE_POSIX.
27695         * lib/free.c: Don't define rpl_free if not needed.
27697         Make it possible to compile realloc.c separately, unconditionally.
27698         * modules/realloc-posix (configure.ac): Invoke gl_MODULE_INDICATOR.
27699         * lib/realloc.c: Don't define rpl_realloc if not needed.
27701         Make it possible to compile malloc.c separately, unconditionally.
27702         * modules/malloc-posix (configure.ac): Invoke gl_MODULE_INDICATOR.
27703         * lib/malloc.c: Don't define rpl_malloc if not needed.
27705 2021-01-31  Bruno Haible  <bruno@clisp.org>
27707         canonicalize-lgpl: Simplify.
27708         * lib/canonicalize-lgpl.c (_GL_USE_STDLIB_ALLOC): Remove macro.
27710 2021-01-30  Bruno Haible  <bruno@clisp.org>
27712         canonicalize, canonicalize-lgpl: Straighten dependencies.
27713         * modules/canonicalize-lgpl (Depends-on): Remove free-posix,
27714         malloc-posix. Add unistd.
27715         * modules/canonicalize (Depends-on): Remove free-posix, xalloc.
27716         Add unistd.
27718 2021-01-30  Bruno Haible  <bruno@clisp.org>
27720         scratch_buffer: Fix dependencies.
27721         * modules/scratch_buffer (Depends-on): Add malloc-posix, realloc-posix,
27722         free-posix.
27724 2021-01-26  Bruno Haible  <bruno@clisp.org>
27726         doc: More precise wording.
27727         Reported by Reuben Thomas <rrt@sc3d.org> in
27728         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00300.html>.
27729         * doc/relocatable.texi (Enabling Relocatability): Talk about package
27730         management systems in general.
27732         doc: Remove obsolete text.
27733         Suggested by Reuben Thomas <rrt@sc3d.org> in
27734         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00299.html>.
27735         * doc/relocatable.texi (Enabling Relocatability): Stop mentioning an
27736         issue of libtool 1.5.x.
27738 2021-01-26  Simon Josefsson  <simon@josefsson.org>
27740         maintainer-makefile: Mimic bootstrap's gnulib-srcdir guessing.
27741         * top/maint.mk (gnulib_dir): If $(srcdir)/gnulib doesn't exist,
27742         fall back to $GNULIB_SRCDIR.
27744 2021-01-25  Bruno Haible  <bruno@clisp.org>
27746         posix_spawn_file_actions_* tests: Fix module dependencies.
27747         * modules/posix_spawn_file_actions_addclose-tests (Depends-on): Add
27748         posix_spawn_file_actions_destroy.
27749         * modules/posix_spawn_file_actions_addopen-tests (Depends-on): Likewise.
27750         * modules/posix_spawn_file_actions_adddup2-tests (Depends-on): Likewise.
27751         * modules/posix_spawn_file_actions_addchdir-tests (Depends-on):
27752         Likewise.
27753         * modules/posix_spawn_file_actions_addfchdir-tests (Depends-on):
27754         Likewise.
27756 2021-01-25  Bruno Haible  <bruno@clisp.org>
27758         posix_spawn_file_actions_addclose: Relax configure test.
27759         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE): Test a
27760         negative file descriptor, not an out-of-range file descriptor.
27761         * tests/test-posix_spawn_file_actions_addclose.c (main): Add comment.
27762         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Update.
27764 2021-01-25  Simon Josefsson  <simon@josefsson.org>
27766         getaddrinfo: Doc fix.
27767         * doc/posix-functions/getaddrinfo.texi (getaddrinfo): Gnulib does
27768         not support IDN.
27770 2021-01-24  Bruno Haible  <bruno@clisp.org>
27772         getcwd: Fix cross-compilation guess for musl libc.
27773         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Guess no also on
27774         musl libc.
27775         * doc/posix-functions/getcwd.texi: Update platform info.
27777 2021-01-24  Bruno Haible  <bruno@clisp.org>
27779         expm1l: Fix configure test result with GCC 10 on powerpc64le.
27780         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Change test to avoid GCC optimization.
27782 2021-01-23  Bruno Haible  <bruno@clisp.org>
27784         utime: Fix configure test (regression 2020-12-04).
27785         Reported by Ryan Schmidt <wget@ryandesign.com> via Tim Rühsen in
27786         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00282.html>.
27787         * m4/utime.m4 (gl_FUNC_UTIME): In the test program, include <utime.h>,
27788         not <time.h>.
27790 2021-01-23  Paul Eggert  <eggert@cs.ucla.edu>
27792         libc-config: port to Xcode 7
27793         Problem reported by Mattias Engdegård in:
27794         https://lists.gnu.org/r/emacs-devel/2021-01/msg01089.html
27795         * lib/cdefs.h (__nonnull): If already defined but glibc is not in
27796         use, override the definition with Gnulib’s _GL_ATTRIBUTE_NONNULL.
27797         This is needed for Xcode 7, which has a ‘#define __nonnull
27798         _Nonnull’ builtin for backwards-compatibility with an older Xcode
27799         syntax that GNUish code never uses.
27801 2021-01-23  Bastien Roucariès  <rouca@debian.org>
27803         explicit_bzero: Add fallback for other compilers.
27804         * lib/explicit_bzero.c (explicit_bzero): For other compilers, invoke
27805         memset through a volatile function pointer.
27807         explicit_bzero: Add support for clang.
27808         * lib/explicit_bzero.c (explicit_bzero): Add a compiler barrier for
27809         clang.
27811 2021-01-21  Paul Eggert  <eggert@cs.ucla.edu>
27813         Port FALLTHROUGH to clang 3.4 and earlier
27814         Problem reported by Akim Demaille in:
27815         https://lists.gnu.org/r/bug-gnulib/2021-01/msg00241.html
27816         * lib/cdefs.h (__glibc_has_attribute):
27817         * m4/gnulib-common.m4 (gl_COMMON_BODY):
27818         Do not trust __has_attribute in clang 3.4 and earlier, as
27819         <https://releases.llvm.org/3.5.0/tools/clang/docs/ReleaseNotes.html>
27820         says that __has_attribute is unreliable in these old versions.
27822 2021-01-20  Bruno Haible  <bruno@clisp.org>
27824         gc-random: Fix link error in tests.
27825         * modules/crypto/gc-random (Link): New section.
27826         * modules/crypto/gc-tests (Makefile.am): Link test-gc with
27827         $(LIB_GETRANDOM).
27829 2021-01-20  Simon Josefsson  <simon@josefsson.org>
27831         gc-random: Replace implementation with call to getrandom.
27832         * lib/gc-gnulib.c [GNULIB_GC_RANDOM]: Replace #include's with
27833         those needed for getrandom.
27834         (gc_init): Remove old randomness code.
27835         (gc_done): Likewise.
27836         (randomize): Rewrite using getrandom, inspired by getentropy.
27837         * m4/gc-random.m4: Remove file.
27838         * modules/crypto/gc-random: Drop gc-random.m4, gl_GC_RANDOM, and
27839         LIB_GC_RANDOM.  Add conditional dependency on getrandom.
27840         * modules/crypto/gc-tests (test_gc_LDADD): Drop LIB_GC_RANDOM.
27842 2021-01-20  Bruno Haible  <bruno@clisp.org>
27844         exec*e tests: Avoid test failures on Cygwin.
27845         * tests/test-execle-main.c (main): On Cygwin, add /bin to the new PATH.
27846         * tests/test-execve-main.c (main): Likewise.
27847         * tests/test-execvpe-main.c (main): Likewise.
27849 2021-01-20  Bruno Haible  <bruno@clisp.org>
27851         canonicalize-lgpl: Work around a Cygwin bug.
27852         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Test for lstat. Add a
27853         test case that involves a symbolic link to an existing file.
27854         * doc/posix-functions/realpath.texi: Mention the Cygwin bug.
27856 2021-01-20  Bruno Haible  <bruno@clisp.org>
27858         doc: Document ptsname_r bug on Cygwin.
27859         * doc/glibc-functions/ptsname_r.texi: Mention Cygwin bug.
27861 2021-01-20  Bruno Haible  <bruno@clisp.org>
27863         sethostname tests: Avoid test failure on Cygwin.
27864         * tests/test-sethostname2.c (main): Treat errno EACCESS like EPERM.
27866 2021-01-19  Paul Eggert  <eggert@cs.ucla.edu>
27868         fnmatch, regex, fts: FALLTHROUGH consistency
27869         Be more consistent about how FALLTHROUGH is defined.
27870         For Gnulib, use attribute.h.  For glibc, use __GNUC__ >= 7.
27871         Problem for glibc reported by Vaseeharan Vinayagamoorthy in:
27872         https://sourceware.org/pipermail/libc-alpha/2021-January/121778.html
27873         * lib/fnmatch.c (FALLTHROUGH) [_LIBC]:
27874         * lib/regex_internal.h (FALLTHROUGH) [_LIBC]:
27875         Don’t worry about Clang, as it’s not needed and provokes GCC.
27876         * lib/fts.c (FALLTHROUGH) [!_LIBC]:
27877         * lib/regex_internal.h (FALLTHROUGH) [!_LIBC]:
27878         Rely on attribute.h for FALLTHROUGH
27879         * modules/regex: Depend on attribute module.
27881 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
27883         spawn-pipe: Fix SIGSEGV on OS/2 kLIBC.
27884         * lib/spawn-pipe.c [OS/2 kLIBC]: Check directory correctly if it means
27885         a current directory.
27887 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
27889         dirent: Fix compilation error in C++ mode on OS/2 kLIBC.
27890         * lib/dirent.in.h (dirfd): Redefine dirfd macro as a rpl function
27891         always.
27893 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
27895         zerosize-ptr: Fix compilation on OS/2 kLIBC.
27896         * tests/zerosize-ptr.h [OS/2 kLIBC]: Don't use mmap().
27898 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
27900         stddef: Fix compilation for max_align_t on OS/2 kLIBC.
27901         * lib/stddef.in.h [OS/2 kLIBC]: Include <cstddef> in C++ mode.
27903 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
27905         yield: Implement for OS/2 kLIBC.
27906         * modules/yield (Depends-on): Add sched_yield.
27908         sched_yield: Implement for OS/2 kLIBC.
27909         * lib/sched_yield.c (sched_yield) [OS/2 kLIBC]: New implementation.
27911 2021-01-19  KO Myung-Hun  <komh78@gmail.com>
27913         spawn: Use special invocation for <spawn.h> on OS/2 kLIBC.
27914         * lib/spawn.in.h: Use special invocation to include <spawn.h> properly
27915         on OS/2 kLIBC.
27917 2021-01-18  Bruno Haible  <bruno@clisp.org>
27919         noreturn tests: Avoid test failure on Solaris 10/x86 with cc.
27920         * tests/test-noreturn.c (main): Return 0.
27922 2021-01-18  Bruno Haible  <bruno@clisp.org>
27924         uninorm tests: Fix compilation error on Cygwin.
27925         * tests/uninorm/test-nfc.c (n): Don't define when using a preinstalled
27926         libunistring on Windows.
27927         * tests/uninorm/test-nfd.c (n): Likewise.
27928         * tests/uninorm/test-nfkc.c (n): Likewise.
27929         * tests/uninorm/test-nfkd.c (n): Likewise.
27931 2021-01-17  Bruno Haible  <bruno@clisp.org>
27933         immutable: Implement on native Windows.
27934         * lib/immutable.h (IMMUTABLE_EFFECTIVE): Set to 1 on native Windows.
27935         * lib/immutable.c: Include <windows.h>.
27936         (CreateFileMapping): New macro.
27937         (init_pagesize, init_mmap_file, alloc_pages, free_pages): Add
27938         implementation for native Windows.
27940 2021-01-17  Bruno Haible  <bruno@clisp.org>
27942         canonicalize-lgpl tests: Fix link error.
27943         * modules/canonicalize-lgpl-tests (Makefile.am): Link
27944         test-canonicalize-lgpl with $(LIBINTL).
27946 2021-01-17  Bruno Haible  <bruno@clisp.org>
27948         canonicalize-lgpl: Work around // handling in realpath() of musl 1.2.2.
27949         Reported by Natanael Copa <ncopa@alpinelinux.org> in
27950         <https://lists.gnu.org/archive/html/bug-gettext/2021-01/msg00021.html>.
27951         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Add a test whether // is
27952         the same as /, on Linux only.
27953         * lib/canonicalize-lgpl.c: Correct indentation of preprocessor
27954         directives.
27955         * doc/posix-functions/realpath.texi: Mention the musl 1.2.2 bug.
27957 2021-01-17  Bruno Haible  <bruno@clisp.org>
27959         canonicalize[-lgpl] tests: Add more tests.
27960         * tests/test-canonicalize.c (main): Add detailed tests for // handling.
27961         * tests/test-canonicalize-lgpl.c (main): Likewise.
27963 2021-01-17  Bruno Haible  <bruno@clisp.org>
27965         argp tests: Avoid test failures on Alpine Linux.
27966         * tests/test-argp-2.sh: Use the test framework (init.sh). Use the
27967         'compare' function instead of 'diff -c'.
27968         * tests/test-argp-version-etc-1.sh: Likewise.
27970 2021-01-17  Bruno Haible  <bruno@clisp.org>
27972         get-rusage-data tests: Avoid test failure on musl libc.
27973         * modules/get-rusage-data-tests (Files): Add m4/musl.m4.
27974         (configure.ac): Invoke gl_MUSL_LIBC.
27975         * tests/test-get-rusage-data.c (main): Treat musl libc like glibc.
27977 2021-01-17  Bruno Haible  <bruno@clisp.org>
27979         immutable, get-rusage-data: Fix autoconf warning.
27980         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Define through AC_DEFUN_ONCE.
27982 2021-01-16  Bruno Haible  <bruno@clisp.org>
27984         vma-iter: Port to 64-bit Haiku.
27985         * lib/vma-iter.c (vma_iterate): Adapt to changed signature of
27986         get_next_area_info.
27988 2021-01-15  Bruno Haible  <bruno@clisp.org>
27990         doc: Update doc about realpath.
27991         * doc/posix-functions/realpath.texi: Update info about macOS.
27993 2021-01-13  Paul Eggert  <eggert@cs.ucla.edu>
27995         verify: simplify static_assert configuration
27996         * lib/verify.h (_GL_HAVE__STATIC_ASSERT, _GL_HAVE__STATIC_ASSERT1):
27997         Do not define for C++.  This should be good enough nowadays,
27998         since recent-enough C++ compilers have static_assert.
27999         (_GL_HAVE_STATIC_ASSERT_CXX11, _GL_HAVE_STATIC_ASSERT_CXX17):
28000         Remove.  All uses replaced by simply checking __cpp_static_assert.
28002 2021-01-13  Simon Josefsson  <simon@josefsson.org>
28004         lib-msvc-compat: Update libtool usage recommendation.
28005         * doc/ld-output-def.texi (Visual Studio Compatibility): Install
28006         .def files into libdir, not bindir.  Have libfoo-*.def file depend
28007         on libfoo.la to fix parallell builds.
28009 2021-01-12  Bruno Haible  <bruno@clisp.org>
28011         verify: Use C++11 static_assert when available.
28012         Reported by Alexandre Duret-Lutz <adl@lrde.epita.fr> in
28013         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00177.html>.
28014         * lib/verify.h (_GL_HAVE_STATIC_ASSERT_CXX11): New macro.
28015         (_GL_HAVE_STATIC_ASSERT_CXX17): Renamed from _GL_HAVE_STATIC_ASSERT1.
28016         (_GL_VERIFY): Use static_assert when available with C++11 syntax.
28018 2021-01-11  Paul Eggert  <eggert@cs.ucla.edu>
28020         tempname: consume less entropy
28021         Derived from a glibc patch proposed by Adhemerval Zanella in:
28022         https://sourceware.org/pipermail/libc-alpha/2021-January/121302.html
28023         * lib/tempname.c: Include stdbool.h.
28024         (random_bits): New arg use_getrandom.
28025         (try_tempname_len): Skip getrandom on the first try,
28026         unless __GT_NOCREATE.
28027         * modules/tempname (Depends-on): Add stdbool.
28029 2021-01-10  Bruno Haible  <bruno@clisp.org>
28031         lchmod-tests: Fix link error.
28032         * modules/lchmod-tests (Makefile.am): Don't assume that LIBINTL is set.
28034 2021-01-10  Simon Josefsson  <simon@josefsson.org>
28036         Correct preceeding change.
28037         * top/gitsub.sh: Update link.
28039 2021-01-09  Bruno Haible  <bruno@clisp.org>
28041         immutable: Add tests.
28042         * tests/test-immutable.sh: New file.
28043         * tests/test-immutable.c: New file.
28044         * modules/immutable-tests: New file.
28046         immutable: New module.
28047         * lib/immutable.h: New file.
28048         * lib/immutable.c: New file.
28049         * m4/immutable.m4: New file.
28050         * m4/mprotect.m4: New file, based on libffcall/m4/codeexec.m4.
28051         * modules/immutable: New file.
28053 2021-01-10  Simon Josefsson  <simon@josefsson.org>
28055         Use https:// instead of git://.
28056         * build-aux/bootstrap (default_gnulib_url): Ditto.
28057         * config/srclistvars.sh: Ditto.
28058         * doc/gnulib-readme.texi (Git Checkout): Ditto.
28059         * doc/gnulib-tool.texi (VCS Issues): Ditto.
28060         * top/gitsub.sh: Update link.
28062 2021-01-09  Paul Eggert  <eggert@cs.ucla.edu>
28064         snippet/_Noreturn: port to pedantic clang
28065         Problem reported by Joe Nelson in:
28066         https://lists.gnu.org/r/bug-gnulib/2021-01/msg00152.html
28067         * doc/noreturn.texi: Improve.
28068         * lib/_Noreturn.h (_Noreturn):
28069         * m4/gnulib-common.m4 (gl_COMMON_BODY):
28070         Do not assume _Noreturn works as-is when __STRICT_ANSI__ is
28071         defined, unless __STDC_VERSION__ indicates C11 or later.
28072         * lib/_Noreturn.h (_Noreturn): Fall back on __attribute__
28073         ((__noreturn__)) if Clang; this merges the
28074         2020-08-10T23:53:13Zbruno@clisp.org patch to m4/gnulib-common.m4.
28076 2021-01-09  Darshit Shah  <darnir@gnu.org>
28078         Allow setting CVS username for gnu-web-doc-update.
28079         * build-aux/gnu-web-doc-update: Introduce new option --user to set the
28080         name of the user on Savannah, when it doesn't match $USER.
28082 2021-01-09  Bruno Haible  <bruno@clisp.org>
28084         exp* tests: Work around clang 6.0.1 optimization bugs on x86.
28085         * tests/test-exp-ieee.h (test_function): Mark some variable as
28086         'volatile'.
28087         * tests/test-exp2-ieee.h (test_function): Likewise.
28089 2021-01-09  Bruno Haible  <bruno@clisp.org>
28091         fchmodat: Work around trailing slash bug in fchmodat() on AIX 7.2.
28092         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): In the test whether fchmodat works,
28093         also test for the trailing slashes behaviour. Define
28094         HAVE_NEARLY_WORKING_FCHMODAT if this is the only missing feature.
28095         * lib/fchmodat.c (fchmodat): If HAVE_NEARLY_WORKING_FCHMODAT, handle
28096         trailing slashes here.
28097         * modules/fchmodat (Depends-on): Sort by condition, not alphabetically.
28098         * doc/posix-functions/fchmodat.texi: Document the AIX bug.
28100 2021-01-09  Bruno Haible  <bruno@clisp.org>
28102         fchmod-tests, fchmodat tests, lchmod tests: Add more tests.
28103         * tests/test-fchmod.c: Include <fcntl.h>.
28104         (BASE): New macro.
28105         (main): Add more tests.
28106         * tests/test-fchmodat.c (main): Add more tests.
28107         * tests/test-lchmod.c (main): Likewise.
28109 2021-01-09  Bruno Haible  <bruno@clisp.org>
28111         utimensat: Fix typo in last commit.
28112         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Fix typo in macro explanation.
28114 2021-01-09  Bruno Haible  <bruno@clisp.org>
28116         truncate: Document last workaround.
28117         * doc/posix-functions/truncate.texi: Document the AIX bug.
28119 2021-01-08  Paul Eggert  <eggert@cs.ucla.edu>
28121         dynarray: work even if ‘free’ is replaced
28122         Problem reported by Darshit Shah in:
28123         https://lists.gnu.org/r/bug-gnulib/2021-01/msg00140.html
28124         * lib/malloc/dynarray-skeleton.c (DYNARRAY_FREE): New macro.
28125         Use it everywhere instead of DYNARRAY_NAME (free).
28127         tempname: don’t block for minutes
28128         Derived from a patch proposed by Adhemerval Zanella in:
28129         https://sourceware.org/pipermail/libc-alpha/2021-January/121302.html
28130         * lib/tempname.c (random_bits): Use GRND_NONBLOCK.
28132         tempname: sync with proposed glibc patch
28133         This is from Adhemerval Zanella in:
28134         https://sourceware.org/pipermail/libc-alpha/2021-January/121301.html
28135         * lib/tempname.c (__lxstat64): Remove.
28136         (__lstat64, __stat64): New replacement macros.  All uses changed.
28138         regex: stop using alloca
28139         * lib/regex_internal.h: Do not include <alloca.h> or define
28140         __libc_use_alloca or alloca.  Patch written by Adhemerval Zanella:
28141         https://sourceware.org/pipermail/libc-alpha/2021-January/121374.html
28142         * modules/regex (Depends-on): Remove alloca-opt.
28144         regexec: remove alloca usage in build_trtable
28145         Prompted by this different change proposed by Adhemerval Zanella:
28146         https://sourceware.org/pipermail/libc-alpha/2021-January/121373.html
28147         * lib/regexec.c (build_trtable): Prevent inlining,
28148         so that it doesn’t bloat the caller’s stack.
28149         Use auto variables instead of alloca/malloc.
28150         After these changes, build_trtable’s total stack allocation is
28151         only 20 KiB on a 64-bit machine, and this is less than glibc’s 64
28152         KiB cutoff so there’s little point to using alloca to shrink it.
28153         Although Gnulib traditionally has used a 4 KiB cutoff, going to 20
28154         KiB here should not be a significant problem in practice;
28155         Gnulib-using packages concerned about overflow of tiny stacks can
28156         compile with something like gcc -fstack-clash-protection.
28158         scratch_buffer: add scratch_buffer_dupfree macro
28159         * lib/scratch_buffer.h (__libc_scratch_buffer_dupfree):
28160         New macro, needed to support recent changes in this module.
28162         regex: remove alloca usage on regex set_regs
28163         Derived from this patch by Adhemerval Zanella:
28164         https://sourceware.org/pipermail/libc-alpha/2021-January/121372.html
28165         * lib/regex_internal.h: Include dynarray.h, for Gnulib.
28166         * lib/regexec.c (DYNARRAY_STRUCT, DYNARRAY_ELEMENT)
28167         (DYNARRAY_PREFIX): New macros.
28168         Include malloc/dynarray-skeleton.c.
28169         (set_regs): Use dynarray rather than alloca.
28170         * modules/regex (Depends-on): Add dynarray.
28172         dynarray: new module
28173         * config/srclist.txt: Mention the new files.
28174         * lib/cdefs.h (__attribute_maybe_unused__): New macro,
28175         like Gnulib’s _GL_ATTRIBUTE_MAYBE_UNUSED but with glibc
28176         naming conventions.
28177         * lib/libc-config.h: Use it instead of __glibc_likely.
28178         * lib/dynarray.h, modules/dynarray: New files.
28179         * lib/malloc/dynarray-skeleton.c, lib/malloc/dynarray.h:
28180         * lib/malloc/dynarray_at_failure.c:
28181         * lib/malloc/dynarray_emplace_enlarge.c:
28182         * lib/malloc/dynarray_finalize.c, lib/malloc/dynarray_resize.c:
28183         * lib/malloc/dynarray_resize_clear.c, modules/dynarray:
28184         New files, from glibc with the following changes needed for
28185         portability to compilers that are not recent-enough GCC.
28186         * lib/malloc/dynarray_at_failure.c: Include stdlib.h, for abort.
28187         (__libc_dynarray_at_failure) [!_LIBC]: Simply abort.
28188         * lib/malloc/dynarray_emplace_enlarge.c:
28189         * lib/malloc/dynarray_resize.c:
28190         Include intprops.h, and use INT_MULTIPLY_WRAPV instead
28191         of __builtin_mul_overflow.
28192         * lib/malloc/dynarray.h (__libc_dynarray_at_failure):
28193         Use _Noreturn instead of __attribute__ ((noreturn)).
28194         * lib/malloc/dynarray_resize_clear.c: Do not include stdlib.h;
28195         it’s not needed.
28196         (__libc_dynarray_resize_clear): Do not do arithmetic on void *.
28197         * lib/malloc/dynarray-skeleton.c (struct DYNARRAY_STRUCT):
28198         Do not use anonymous unions, as they are not in C99. All uses changed.
28199         Use __nonnull (X) instead of __attribute__ ((nonnull X)),
28200         and __attribute_maybe_unused__ instead of __attribute__ ((unused)).
28202 2021-01-06  Simon Josefsson  <simon@josefsson.org>
28204         bootstrap: Fix parsing of package name.
28205         * build-aux/bootstrap (package): Attempt to use autoconf --trace
28206         to parse AC_INIT before falling back to sed expression.
28208 2021-01-07  Bruno Haible  <bruno@clisp.org>
28210         localename: Fix link error with duplocale on AIX 7.2 (regr. 2019-12-18).
28211         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize
28212         LOCALENAME_ENHANCE_LOCALE_FUNCS.
28213         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE):
28214         Set gt_working_uselocale.
28215         (gt_INTL_THREAD_LOCALE_NAME): Set gt_fake_locales, gt_good_uselocale,
28216         gt_localename_enhances_locale_funcs, LOCALENAME_ENHANCE_LOCALE_FUNCS.
28217         Define HAVE_GOOD_USELOCALE, LOCALENAME_ENHANCE_LOCALE_FUNCS.
28218         * m4/localename.m4 (gl_LOCALENAME): Test
28219         gt_localename_enhances_locale_funcs instead of gt_nameless_locales.
28220         * modules/locale (Makefile.am): Substitute
28221         LOCALENAME_ENHANCE_LOCALE_FUNCS.
28222         * lib/locale.in.h (newlocale, duplocale, freelocale): Don't override if
28223         module 'localename' is in use but LOCALENAME_ENHANCE_LOCALE_FUNCS is 0.
28224         * lib/localename.c (HAVE_GOOD_USELOCALE): Don't define here.
28225         (get_locale_t_name, newlocale, duplocale, freelocale): Define if
28226         LOCALENAME_ENHANCE_LOCALE_FUNCS.
28228 2021-01-06  Bruno Haible  <bruno@clisp.org>
28230         logb: Fix test failure on glibc/powerpc.
28231         * doc/posix-functions/logb.texi: Update platform info.
28232         * m4/logb.m4 (gl_FUNC_LOGB_WORKS): Test against bug with negative
28233         subnormal numbers.
28235 2021-01-06  Paul Eggert  <eggert@cs.ucla.edu>
28237         libc-config: simplify clang __has_* macros
28238         cdefs.h sometimes used names like __glibc_clang_has_attribute and
28239         sometimes __glibc_has_attribute.  There is no need in glibc or
28240         Gnulib to distinguish clang from other compilers here, so be
28241         consistent and use the simpler names.
28242         * lib/cdefs.h (__glibc_has_builtin, __glibc_has_extension):
28243         Rename from __glibc_clang_has_builtin, __glibc_clang_has_extension.
28244         All uses changed.
28245         (__glibc_clang_has_attribute): Remove. All uses replaced
28246         by __glibc_has_attribute.
28247         * lib/libc-config.h [!__glibc_likely]: Undef them here too.
28248         This fixes a problem where __glibc_has_attribute was not undeffed.
28250 2021-01-06  Bruno Haible  <bruno@clisp.org>
28252         flock: Update documentation.
28253         * doc/glibc-functions/flock.texi: Document what to expect on AIX and
28254         Solaris.
28256 2021-01-06  Bruno Haible  <bruno@clisp.org>
28258         ilogbl: Fix compilation error with xlclang on AIX 7.2.
28259         * lib/math.in.h (ilogbl): Undefine macro before declaration.
28261 2021-01-06  Bruno Haible  <bruno@clisp.org>
28263         ilogbl: Fix test failures on AIX 7.1 in 64-bit mode.
28264         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Test also some denormalized
28265         argument.
28266         * doc/posix-functions/ilogbl.texi: Mention the AIX bug.
28268 2021-01-06  Bruno Haible  <bruno@clisp.org>
28270         ilogb: Fix test failures on AIX 7.1 in 64-bit mode.
28271         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Test also some denormalized
28272         argument.
28273         * doc/posix-functions/ilogb.texi: Mention the AIX bug.
28275 2021-01-05  Bruno Haible  <bruno@clisp.org>
28277         fclose: Fix test failure on AIX 7.2.
28278         * m4/fclose.m4 (gl_FUNC_FCLOSE_STDIN): New macro.
28279         (gl_FUNC_FCLOSE): Invoke it. Set REPLACE_FCLOSE accordingly.
28280         * doc/posix-functions/fclose.texi: Update platform information.
28281         * doc/posix-functions/fflush.texi: Likewise.
28283 2021-01-05  Bruno Haible  <bruno@clisp.org>
28285         pipe-filter-gi: Fix test failure on AIX 7.2.
28286         * lib/pipe-filter-aux.h (SSIZE_MAX) [AIX]: Set to 4096.
28288 2021-01-05  Bruno Haible  <bruno@clisp.org>
28290         utimens, utimensat, fdutimensat: Avoid test failures on AIX 7.2.
28291         * lib/utimecmp.c (utimecmpat): On AIX, declare equality when the two
28292         times differ by less than 0.01 seconds.
28293         * tests/test-futimens.h (test_futimens): Pass UTIMECMP_TRUNCATE_SOURCE
28294         flag.
28296 2021-01-05  Bruno Haible  <bruno@clisp.org>
28298         utimensat: Work around trailing slash bug in utimensat() on AIX 7.2.
28299         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Require AC_CANONICAL_HOST. Add a
28300         test for trailing slash handling. Improve cross-compilation guesses.
28301         Conditionally define HAVE_NEARLY_WORKING_UTIMENSAT.
28302         * lib/utimensat.c (rpl_utimensat): Add alternative implementation when
28303         HAVE_NEARLY_WORKING_UTIMENSAT is defined.
28304         * lib/utimens.c: Use the overridden utimensat when
28305         HAVE_NEARLY_WORKING_UTIMENSAT is defined.
28306         * doc/posix-functions/utimensat.texi: Mention the AIX bug.
28308 2021-01-05  Bruno Haible  <bruno@clisp.org>
28310         ptsname_r, ptsname: Avoid test failures on AIX 7.2.
28311         * tests/test-ptsname_r.c (main): On AIX, set a 20-seconds timer.
28312         * tests/test-ptsname.c (main): Likewise. On AIX, open a pty through
28313         /dev/ptc and don't test the BSD ptys.
28315 2021-01-05  Paul Eggert  <eggert@cs.ucla.edu>
28317         libc-config: merge from glibc
28318         Use a better way of keeping glibc <sys/cdefs.h> and gnulib
28319         lib/cdefs.h mostly in sync, by using lib/cdefs.h only on platforms
28320         where <sys/cdefs.h> does not work well enough for Gnulib.
28321         * lib/cdefs.h: Go back to using _SYS_CDEFS_H rather than
28322         _GL_DEFS_H as an include guard.
28323         (__THROW, __THROWNL, __NTH, __NTHNL):
28324         Define to noexcept for C++11 and later.
28325         (__glibc_objsize, __glibc_objsize0): New, for _FORTIFY_SOURCE=3.
28326         (__warndecl): Remove.
28327         (__attribute_copy__): New macro, for GCC 9 support.
28328         (__LDBL_REDIR, __LDBL_REDIR_DECL, __LDBL_REDIR1)
28329         (__LDBL_REDIR1_DECL, __LDBL_REDIR1_NTH, __REDIRECT_NTH_LDBL)
28330         (__REDIRECT_LDBL, __LDBL_REDIR_NTH):
28331         Redirections for IEEE long double on powerpc64le.
28332         (__LDBL_REDIR2_DECL): New macro.
28333         (__attr_access): New macro, for GCC 10 bounds checking.
28334         (__attribute_returns_twice__): New macro, for setjmp etc.
28335         * lib/libc-config.h: Include <cdefs.h> only if __glibc_likely is
28336         undefined.  The following changes apply only if __glibc_likely
28337         is not defined.
28338         (__LDBL_REDIR2_DECL, __attr_access, __attribute_returns_twice__)
28339         (__glibc_clang_has_attribute, __glibc_clang_has_extension)
28340         (__glibc_objsize, __glibc_objsize0):
28341         Undef these new (or newer) <cdefs.h> macros.
28342         (__P, __PMT, __always_inline): Do not undef, since cdefs.h does that.
28343         (__glibc_likely): Do not undef, since this is inside
28344         ifndef __glibc_likely.
28345         (__warndecl): Do not undef; no longer defined.
28347 2021-01-05  Jim Meyering  <meyering@fb.com>
28349         maintainer-makefile: correct preceding change
28350         * top/maint.mk (syntax-check-rules): Use LC_ALL=C, not LANG=C.
28352 2021-01-05  Paul Eggert  <eggert@cs.ucla.edu>
28354         maint: note syncs to glibc
28355         * config/srclist.txt: filename.h, idx.h, scratch_buffer.h and
28356         scratch_buffer_dupfree.c are now identical to glibc.  Add
28357         commentary about some other syncs we’d like.
28358         * modules/filename, modules/idx (Maintainer): Add glibc.
28360 2021-01-05  Bruno Haible  <bruno@clisp.org>
28362         truncate: Work around trailing slash bug in truncate() on AIX 7.2.
28363         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Add a test whether truncate
28364         rejects trailing slashes. Set REPLACE_TRUNCATE and define
28365         TRUNCATE_TRAILING_SLASH_BUG if not.
28366         * lib/truncate.c (orig_truncate): New function.
28367         (truncate): Add alternative implementation when
28368         TRUNCATE_TRAILING_SLASH_BUG is defined.
28369         * modules/truncate (Depends-on): Add sys_stat, stat.
28371 2021-01-05  Bruno Haible  <bruno@clisp.org>
28373         mkfifoat: Fix cross-compilation guess (regression from 2021-01-04).
28374         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Fix copy-and-paste mistake.
28376 2021-01-05  Bruno Haible  <bruno@clisp.org>
28378         ffsll: Override completely broken implementation on AIX in 32-bit mode.
28379         * m4/ffsll.m4 (gl_FUNC_FFSLL): Test whether ffsll minimally works. If
28380         not, set REPLACE_FFSLL.
28381         * lib/string.in.h (ffsll): Consider REPLACE_FFSLL.
28382         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
28383         REPLACE_FFSLL.
28384         * modules/string (Makefile.am): Substitute REPLACE_FFSLL.
28385         * modules/ffsll (Depends-on, configure.ac): Consider REPLACE_FFSLL.
28386         * doc/glibc-functions/ffsll.texi: Mention the AIX 7.2 bug.
28388 2021-01-04  Bruno Haible  <bruno@clisp.org>
28390         symlinkat: Fix trailing slash handling.
28391         * lib/symlinkat.c (rpl_symlinkat): Don't follow symlinks during the
28392         trailing slash handling.
28393         * modules/symlinkat (Depends-on): Update conditions.
28395 2021-01-04  Bruno Haible  <bruno@clisp.org>
28397         mkfifoat: Update module description.
28398         * modules/mkfifoat (Depends-on): Update conditions after last commits.
28400 2021-01-04  Bruno Haible  <bruno@clisp.org>
28402         link: Improve trailing slash handling on native Windows.
28403         * lib/link.c (link): If stat() fails, provide a better errno.
28405 2021-01-04  Bruno Haible  <bruno@clisp.org>
28407         mkfifoat: Work around trailing slash bug in mknodat() on AIX 7.2.
28408         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Set also REPLACE_MKNODAT.
28409         * lib/sys_stat.in.h (mknodat): Consider REPLACE_MKNODAT.
28410         * lib/mknodat.c: Add an overriding implementation of mknodat().
28411         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize REPLACE_MKNODAT.
28412         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKNODAT.
28413         * modules/mkfifoat (Depends-on, configure.ac): Consider REPLACE_MKNODAT.
28414         * doc/posix-functions/mknodat.texi: Mention the AIX bug.
28416         mkfifoat: Work around trailing slash bug in mkfifoat() on AIX 7.2.
28417         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Add a test whether mkfifoat rejects
28418         trailing slashes. Set REPLACE_MKFIFOAT if not.
28419         * lib/sys_stat.in.h (mkfifoat): Consider REPLACE_MKFIFOAT.
28420         * lib/mkfifoat.c: Add an overriding implementation of mkfifoat().
28421         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
28422         REPLACE_MKFIFOAT.
28423         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKFIFOAT.
28424         * modules/mkfifoat (Depends-on): Add fstatat.
28425         (configure.ac): Consider REPLACE_MKFIFOAT.
28426         * doc/posix-functions/mkfifoat.texi: Mention the AIX bug.
28428 2021-01-04  Bruno Haible  <bruno@clisp.org>
28430         libc-config: Avoid overriding the headers from an installed newer glibc.
28431         Reported by Paul E Murphy <murphyp@linux.ibm.com> in
28432         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00106.html>.
28433         * lib/cdefs.h: Use a different include guard than glibc's <sys/cdefs.h>.
28434         * lib/libc-config.h: Update accordingly.
28436 2021-01-04  Simon Josefsson  <simon@josefsson.org>
28438         maintainer-makefile: Invoke syntax-checks regardless of locale.
28439         * top/maint.mk (syntax-check-rules): Invoke sed with LANG=C
28440         environment because [a-z] may not include 'w' in all locales.
28442 2021-01-04  Bruno Haible  <bruno@clisp.org>
28444         nstrftime, time_rz: Avoid using an obsolete Autoconf macro.
28445         Reported by Mike Gran <spk121@yahoo.com> in
28446         <https://lists.gnu.org/archive/html/bug-gnulib/2021-01/msg00067.html>.
28447         * lib/time-internal.h: Test HAVE_STRUCT_TM_TM_ZONE, not HAVE_TM_ZONE.
28448         * lib/time_rz.c: Likewise.
28449         * lib/nstrftime.c: Set and test HAVE_STRUCT_TM_TM_ZONE, not
28450         HAVE_TM_ZONE.
28451         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Update comments.
28453 2021-01-04  Bruno Haible  <bruno@clisp.org>
28455         expm1f-ieee: Work around AIX 7.2 bug.
28456         * m4/expm1f.m4 (gl_FUNC_EXPM1F): Initialize gl_expm1f_required. If
28457         module 'expm1f-ieee' is in use, check whether expm1f works according to
28458         IEEE.
28459         * m4/expm1f-ieee.m4: New file.
28460         * modules/expm1f-ieee (Files): Add it.
28461         (Depends-on): Update conditions.
28462         (configure.ac): Invoke gl_FUNC_EXPM1F_IEEE.
28463         * doc/posix-functions/expm1f.texi: Mention the AIX bug.
28465 2021-01-04  Bruno Haible  <bruno@clisp.org>
28467         ffsl, ffsll: Work around AIX 7.2 problem.
28468         * lib/string.in.h: On AIX, include <strings.h> for the declarations of
28469         ffsl and ffsll.
28470         * doc/glibc-functions/ffsl.texi: Document the AIX 7.2 problem.
28471         * doc/glibc-functions/ffsll.texi: Likewise.
28473 2021-01-04  Bruno Haible  <bruno@clisp.org>
28475         ssfmalloc: Fix includes.
28476         * lib/ssfmalloc.h: Include <strings.h>, for ffs().
28477         * tests/test-ssfmalloc.c: Include <string.h>, for memset().
28479 2021-01-03  Bruno Haible  <bruno@clisp.org>
28481         quotearg tests: Avoid test failures on Solaris 11.3.
28482         * tests/test-quotearg.sh: Copy the fr/ directory using 'cp -R', not
28483         'cp -a'.
28485 2021-01-03  Bruno Haible  <bruno@clisp.org>
28487         tests: Fix link errors on Solaris, when libunistring-optional is in use.
28488         * modules/wcwidth (Link): New section.
28489         * modules/wcswidth (Link): New section.
28490         * modules/mbchar (Link): New section.
28491         * modules/mbfile (Link): Link against libunistring.
28492         * modules/mbiter (Link): Likewise.
28493         * modules/mbuiter (Link): Likewise.
28494         * modules/mbmemcasecmp (Link): Likewise.
28495         * modules/mbscasecmp (Link): Likewise.
28496         * modules/mbscasestr (Link): Likewise.
28497         * modules/mbschr (Link): Likewise.
28498         * modules/mbscspn (Link): Likewise.
28499         * modules/mbslen (Link): Likewise.
28500         * modules/mbsncasecmp (Link): Likewise.
28501         * modules/mbsnlen (Link): Likewise.
28502         * modules/mbspbrk (Link): Likewise.
28503         * modules/mbspcasecmp (Link): Likewise.
28504         * modules/mbsrchr (Link): Likewise.
28505         * modules/mbssep (Link): Likewise.
28506         * modules/mbsspn (Link): Likewise.
28507         * modules/mbsstr (Link): Likewise.
28508         * modules/mbstok_r (Link): Likewise.
28509         * modules/mbswidth (Link): Likewise.
28510         * modules/exclude (Link): Likewise.
28511         * modules/propername (Link): Likewise.
28512         * modules/regex-quote (Link): Likewise.
28513         * modules/trim (Link): Likewise.
28514         * modules/mbmemcasecmp-tests (Makefile.am): Link the test program
28515         against libunistring.
28516         * modules/mbscasecmp-tests (Makefile.am): Likewise.
28517         * modules/mbscasestr-tests (Makefile.am): Likewise.
28518         * modules/mbschr-tests (Makefile.am): Likewise.
28519         * modules/mbscspn-tests (Makefile.am): Likewise.
28520         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
28521         * modules/mbspbrk-tests (Makefile.am): Likewise.
28522         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
28523         * modules/mbsrchr-tests (Makefile.am): Likewise.
28524         * modules/mbsspn-tests (Makefile.am): Likewise.
28525         * modules/mbsstr-tests (Makefile.am): Likewise.
28526         * modules/exclude-tests (Makefile.am): Likewise.
28527         * modules/regex-quote-tests (Makefile.am): Likewise.
28529 2021-01-03  Bruno Haible  <bruno@clisp.org>
28531         c32ispunct tests: Avoid test failures on FreeBSD.
28532         * tests/test-c32ispunct.c (main): On FreeBSD, disable tests that fail on
28533         FreeBSD 12.1.1.
28535 2021-01-04  Simon Josefsson  <simon@josefsson.org>
28537         doc: Repeat warning that --with-tests cannot be used twice.
28538         * doc/gnulib-tool.texi (Multiple instances): Remind reader of
28539         --with-tests limitation.
28541 2021-01-03  Bruno Haible  <bruno@clisp.org>
28543         iconv, iconv_open: Improve documentation.
28544         Reported by Noah Misch <noah@leadboat.com> in
28545         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00172.html>.
28546         * doc/posix-functions/iconv_open.texi: Add new paragraph "Portability
28547         problems handled by Gnulib".
28548         * doc/posix-functions/iconv.texi: Likewise. Update info about AIX.
28549         * m4/iconv.m4 (AM_ICONV_LINK): Improve comments.
28551 2021-01-03  Bruno Haible  <bruno@clisp.org>
28553         iconv-h: Fix module description.
28554         * modules/iconv-h (Include): Check HAVE_ICONV_H.
28556 2021-01-03  Noah Misch  <noah@leadboat.com>
28558         iconv_open: Fix module description.
28559         * modules/iconv_open (Include): Check HAVE_ICONV, like modules/iconv.
28561 2021-01-03  Bruno Haible  <bruno@clisp.org>
28563         stddef: Override wrong max_align_t on AIX 7 with xlc in 64-bit mode.
28564         * m4/stddef_h.m4 (gl_STDDEF_H): Make check for good max_align_t
28565         stricter: Add tests for offsetof-based alignof.
28566         * lib/stddef.in.h (max_align_t): Override on AIX in 64-bit mode.
28567         * doc/posix-headers/stddef.texi: Document the AIX max_align_t bug.
28569 2021-01-03  Bruno Haible  <bruno@clisp.org>
28571         free-posix: Work around GCC mis-optimization bug.
28572         Code by Bernhard Voelker <mail@bernhard-voelker.de>.
28573         * lib/free.c (rpl_free): Add alternative complicated code for GCC.
28575 2021-01-02  Bruno Haible  <bruno@clisp.org>
28577         valgrind-tests: Disable valgrind if it would cause all tests to fail.
28578         Suggested by Simon Josefsson <simon@josefsson.org> in
28579         <https://lists.gnu.org/archive/html/help-gsasl/2021-01/msg00004.html>.
28580         * m4/valgrind-tests.m4 (gl_VALGRIND_TESTS): Test $VALGRIND on an
28581         executable produced by the current compiler. Set VALGRIND to empty if it
28582         does not work. Don't set VALGRIND to empty if it merely does not accept
28583         the --error-exitcode=1 --leak-check=full options.
28585 2021-01-02  Bruno Haible  <bruno@clisp.org>
28587         valgrind-tests: Really enable the valgrind options test.
28588         * m4/valgrind-tests.m4 (gl_VALGRIND_TESTS): Don't assume that the
28589         valgrind options --error-exitcode=1 --leak-check=full always work.
28591 2021-01-02  Bruno Haible  <bruno@clisp.org>
28593         utimensat: Fix test failures on macOS 10.13.
28594         * lib/utimensat.c: Include <string.h>, <sys/stat.h>.
28595         (rpl_utimensat): Check against invalid tv_nsec values. Before calling
28596         utimensat, recognize a filename ending in a slash that does not point
28597         to a directory.
28599 2021-01-02  Bruno Haible  <bruno@clisp.org>
28601         utimens: Fix test failure on macOS 10.13.
28602         * lib/utimens.c: Include <string.h>.
28604         utimens: Fix test failure on macOS 10.13.
28605         * lib/utimens.c (fdutimens): Before calling utimensat, recognize a
28606         filename ending in a slash that does not point to a directory.
28608 2021-01-02  Bruno Haible  <bruno@clisp.org>
28610         utimens: Avoid test failures on macOS 10.13.
28611         Reported by Martin Storsjö <martin@martin.st> in
28612         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
28613         * tests/test-utimens-common.h (check_ctime): Define to -1 on macOS.
28614         * tests/test-utimens.h (test_utimens): Don't expect a ctime change when
28615         only the atime is requested to change.
28616         * tests/test-futimens.h (test_futimens): Likewise.
28617         * tests/test-lutimens.h (test_lutimens): Likewise.
28619 2021-01-02  Bruno Haible  <bruno@clisp.org>
28621         renameatu: Fix test failures on macOS.
28622         Reported by Martin Storsjö <martin@martin.st> in
28623         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
28624         * lib/renameatu.c (renameatu): Don't call renameatx_np right away.
28625         Instead, treat it as a variant of renameat, with all possible bugs that
28626         renameat might have.
28628 2021-01-02  Bruno Haible  <bruno@clisp.org>
28630         getgroups test: Avoid warning with glibc >= 2.32 and gcc >= 10.
28631         Reported by Bernhard Voelker <mail@bernhard-voelker.de> in
28632         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00090.html>.
28633         * tests/test-getgroups.c: Silence gcc warnings of type
28634         -Wstringop-overflow.
28636 2021-01-02  Bruno Haible  <bruno@clisp.org>
28638         timespec_get: Add tests.
28639         * tests/test-timespec_get.c: New file.
28640         * modules/timespec_get-tests: New file.
28642         timespec_get: New module.
28643         * lib/time.in.h (timespec_get): New declaration.
28644         * lib/timespec_get.c: New file.
28645         * m4/timespec_get.m4: New file.
28646         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize
28647         GNULIB_TIMESPEC_GET, HAVE_TIMESPEC_GET.
28648         * modules/time (Makefile.am): Substitute GNULIB_TIMESPEC_GET,
28649         HAVE_TIMESPEC_GET.
28650         * modules/timespec_get: New file.
28651         * tests/test-time-c++.cc (timespec_get): Check signature.
28652         * doc/glibc-functions/timespec_get.texi: Mention the new module.
28654 2021-01-01  Bruno Haible  <bruno@clisp.org>
28656         time: Define TIME_UTC.
28657         * lib/time.in.h (TIME_UTC, GNULIB_defined_TIME_UTC): New macros.
28658         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Set TIME_H_DEFINES_TIME_UTC.
28659         * modules/time (Makefile.am): Substitute TIME_H_DEFINES_TIME_UTC.
28660         * tests/test-time.c: Check that TIME_UTC is defined and a positive
28661         integer.
28662         * doc/posix-headers/time.texi: Mention TIME_UTC.
28664 2021-01-01  Bruno Haible  <bruno@clisp.org>
28666         stddef: Try harder to get max_align_t defined on OpenBSD, part 2.
28667         * modules/stddef (Depends-on): Add extensions.
28669 2021-01-01  Paul Eggert  <eggert@cs.ucla.edu>
28671         canonicalize: remove NARROW_ADDRESSES optimization
28672         * lib/canonicalize-lgpl.c, lib/canonicalize.c (NARROW_ADDRESSES):
28673         Remove, and remove all uses, as the optimization is arguably not
28674         worth the extra complexity.  Suggested by Adhemerval Zanella in:
28675         https://sourceware.org/pipermail/libc-alpha/2020-December/121203.html
28677 2021-01-01  Bruno Haible  <bruno@clisp.org>
28679         stddef: Try harder to get max_align_t defined on OpenBSD.
28680         * m4/stddef_h.m4 (gl_STDDEF_H): Require gl_USE_SYSTEM_EXTENSIONS.
28682 2021-01-01  Bruno Haible  <bruno@clisp.org>
28684         aligned_alloc: Fix test failure on OpenBSD 6.8.
28685         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): On OpenBSD, define
28686         _ISOC11_SOURCE.
28687         * m4/aligned_alloc.m4 (gl_FUNC_ALIGNED_ALLOC): Require it. Update
28688         comment.
28690 2021-01-01  Bruno Haible  <bruno@clisp.org>
28692         posixtm tests: Disable part of the test on plaforms where it fails.
28693         * tests/test-posixtm.c (T): Disable two tests on macOS as well.
28695 2021-01-01  Bruno Haible  <bruno@clisp.org>
28697         c32isgraph/c32isprint/c32ispunct tests: Avoid test failures on OmniOS.
28698         * tests/test-c32isgraph.c (main): On Solaris, disable tests that fail on
28699         Solaris 11 OmniOS.
28700         * tests/test-c32isprint.c (main): Likewise.
28701         * tests/test-c32ispunct.c (main): Likewise.
28703 2021-01-01  Paul Eggert  <eggert@cs.ucla.edu>
28705         libc-config: port to Sun C 5.9
28706         * lib/libc-config.h (libc_hidden_proto): Omit ", ..." in macro
28707         definition.  It’s not needed for Gnulib and elicits a diagnostic
28708         from Sun C 5.9 Patch 124867-12 2009/11/22.
28710 2021-01-01  Bruno Haible  <bruno@clisp.org>
28712         quotearg tests: Avoid test failures on Solaris 11.
28713         * modules/quotearg-tests (Makefile.am): Set host_os in
28714         TESTS_ENVIRONMENT.
28715         * tests/test-quotearg.sh: On Solaris 11 systems, make a copy of the fr/
28716         directory that contains the .mo file.
28718 2021-01-01  Bruno Haible  <bruno@clisp.org>
28720         maint: Update copyright notices in --version output.
28721         List the most recent year in which changes were made, per
28722         <https://www.gnu.org/prep/standards/html_node/_002d_002dversion.html>.
28723         * build-aux/declared.sh (func_version): Say 2019.
28724         * build-aux/libtool-next-version (func_version): Likewise.
28725         * build-aux/run-test (func_version): Likewise.
28726         * check-module (COPYRIGHT_NOTICE): Say 2012.
28727         * lib/git-merge-changelog.c (main): Say 2020.
28729 2020-12-31  Paul Eggert  <eggert@cs.ucla.edu>
28731         filename: change filename.h comment to LGPLv2.1+
28732         * lib/filename.h: Change license notice to match what should be in
28733         glibc, and what modules/filename specifies.  This is to simplify
28734         syncing with glibc.
28736         doc: mention year-0 bugs in Solaris etc.
28737         * doc/posix-functions/gmtime.texi, doc/posix-functions/gmtime_r.texi:
28738         * doc/posix-functions/localtime.texi:
28739         * doc/posix-functions/localtime_r.texi:
28740         * doc/posix-functions/mktime.texi:
28741         Mention year-0 bugs in localtime etc.
28743 2020-12-31  Bruno Haible  <bruno@clisp.org>
28745         ptsname_r: Fix test failure on Solaris.
28746         * lib/ptsname_r.c (__ptsname_r) [__sun]: Don't test the major number of
28747         the device.
28749 2020-12-31  Bruno Haible  <bruno@clisp.org>
28751         posixtm tests: Disable part of the test on plaforms where it fails.
28752         * tests/test-posixtm.c (T): Disable two tests on Solaris.
28754 2020-12-31  Bruno Haible  <bruno@clisp.org>
28756         poll tests: Avoid test failure on AIX.
28757         * tests/test-poll.c (test_pipe): Disable the "expecting POLLHUP after
28758         shutdown" test on AIX.
28759         * doc/posix-functions/poll.texi: Mention the AIX bug.
28761 2020-12-31  Bruno Haible  <bruno@clisp.org>
28763         poll tests: Avoid test failure on BSD and Solaris systems.
28764         * tests/test-poll.c (test_accept_first, test_socket_pair): Disable the
28765         "expecting POLLHUP after shutdown" test on all platforms except Linux.
28767 2020-12-31  Paul Eggert  <eggert@cs.ucla.edu>
28769         fnmatch: merge from glibc + proposal
28770         This merges the change proposed by Adhemerval Zanella in:
28771         https://sourceware.org/pipermail/libc-alpha/2020-December/121212.html
28772         which fixes a Gnulib bug that led to a failed assert.
28773         * lib/fnmatch_loop.c (EXT): Use signed level, not unsigned, and
28774         check that it stays nonnegative.  Use __flexarr instead of
28775         FLEXIBLE_ARRAY_MEMBER, to port better to glibc.
28776         * tests/test-fnmatch.c (main): New test cases, taken from glibc.
28778         glob: merge proposed glibc changes
28779         This merges the change proposed by Adhemerval Zanella in:
28780         https://sourceware.org/pipermail/libc-alpha/2020-December/121211.html
28781         * lib/glob.c (__lstat64, __stat64) [_LIBC]: Remove.
28783 2020-12-31  Bruno Haible  <bruno@clisp.org>
28785         memalign: Work around Solaris bug.
28786         * lib/memalign.c: New file.
28787         * m4/memalign.m4: New file.
28788         * modules/memalign (Files): Add them.
28789         (Depends-on): Add malloc-h.
28790         (configure.ac): Invoke gl_FUNC_MEMALIGN. Conditionally compile
28791         memalign.c. Set module indicator.
28792         (Include): Include <malloc.h> unconditionally.
28793         * doc/glibc-functions/memalign.texi: Mention the Solaris issues.
28795         malloc-h: Add tests.
28796         * tests/test-malloc-h.c: New file.
28797         * modules/malloc-h-tests: New file.
28798         * tests/test-malloc-h-c++.cc: New file.
28799         * modules/malloc-h-c++-tests: New file.
28801         malloc-h: New module.
28802         * lib/malloc.in.h: New file.
28803         * m4/malloc_h.m4: New file.
28804         * modules/malloc-h: New file.
28805         * doc/glibc-headers/malloc.texi: New file.
28806         * doc/gnulib.texi (Glibc Header File Substitutes): Include it.
28808 2020-12-31  Bruno Haible  <bruno@clisp.org>
28810         unistd: Fix portability warnings.
28811         * lib/unistd.in.h (fchownat, unlinkat): Fix module name in warning.
28813 2020-12-31  Bruno Haible  <bruno@clisp.org>
28815         utime: Fix compilation error on macOS and Solaris 9 (regr. 2020-12-24).
28816         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
28817         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00295.html>.
28818         * lib/utime.c: Include <errno.h>.
28820 2020-12-30  Karl Berry  <karl@freefriends.org>
28822         config: srclistvars doc.
28823         * config/srclistvars.sh: doc a couple of unusual source repo urls.
28825 2020-12-30  Bruno Haible  <bruno@clisp.org>
28827         getlogin tests, getlogin_r tests: Avoid failure on Solaris OpenIndiana.
28828         * tests/test-getlogin.c (main): Don't fail if getlogin() returns NULL
28829         with no errno.
28830         * tests/test-getlogin_r.c (main): Don't fail if getlogin_r() returns
28831         EINVAL.
28833 2020-12-29  Jim Meyering  <meyering@fb.com>
28835         regex-tests: tweak to avoid a clang-10 warning
28836         * tests/test-regex.c: Compare with explicit zero, rather than
28837         as boolean to avoid this from clang-10:
28838         test-regex.c:315:9: error: converting the result of '<<' to a \
28839           boolean always evaluates to true \
28840           [-Werror,-Wtautological-constant-compare]
28841         if (! REG_STARTEND)
28843         hash: add casts-to-float to avoid clang-10 warnings
28844         * lib/hash.c (compute_bucket_size): Cast SIZE_MAX to float
28845         to avoid this warning from clang-10 (for use in grep):
28846           hash.c:501:11: error: implicit conversion from 'unsigned long' \
28847             to 'float' changes value from 18446744073709551615 to \
28848             18446744073709551616 [-Werror,-Wimplicit-int-float-conversion]
28849           if (SIZE_MAX <= new_candidate)
28850         (hash_insert_if_absent): Likewise.
28852 2020-12-29  Paul Eggert  <eggert@cs.ucla.edu>
28854         canonicalize: fix size overflow treatment
28855         This also has some minor cleanups.
28856         * lib/canonicalize-lgpl.c, lib/canonicalize.c: No need to include
28857         stddef.h, since the code no longer refers directly to ptrdiff_t.
28858         * lib/canonicalize-lgpl.c (realpath_stk):
28859         * lib/canonicalize.c (canonicalize_filename_mode_stk):
28860         Treat size overflow like other out-of-memory.
28861         * lib/canonicalize.c: No need to include stdlib.h, since
28862         the code no longer refers to stdlib.h functions (other
28863         than those that canonicalize.h must declare).
28864         * lib/canonicalize.c (canonicalize_filename_mode_stk):
28865         Do not bother terminating the string result on error.
28867 2020-12-29  Bruno Haible  <bruno@clisp.org>
28869         list-c++, [o]map-c++, [o]set-c++: Fix conflict with 'free-posix' module.
28870         * lib/gl_list.hh: Include <stdlib.h>.
28871         * lib/gl_map.hh: Likewise.
28872         * lib/gl_omap.hh: Likewise.
28873         * lib/gl_set.hh: Likewise.
28874         * lib/gl_oset.hh: Likewise.
28876 2020-12-29  Paul Eggert  <eggert@cs.ucla.edu>
28878         canonicalize: fix ptrdiff_t overflow bug
28879         Problem reported by Adhemerval Zanella in:
28880         https://sourceware.org/pipermail/libc-alpha/2020-December/121182.html
28881         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
28882         Include intprops.h.
28883         (NARROW_ADDRESSES): New constant.
28884         * lib/canonicalize-lgpl.c (realpath_stk):m
28885         * lib/canonicalize.c (canonicalize_filename_mode_stk):
28886         Work even if strlen (END) does not fit in idx_t, or if adding
28887         N to it overflows.
28888         * modules/canonicalize, modules/canonicalize-lgpl (Depends-on):
28889         Add intprops.
28891 2020-12-28  Bruno Haible  <bruno@clisp.org>
28893         havelib: Fix for Solaris 11 OpenIndiana and Solaris 11 OmniOS.
28894         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): In
28895         acl_is_expected_elfclass, use 'expr', not 'test'.
28897 2020-12-28  Bruno Haible  <bruno@clisp.org>
28899         ptsname_r: Fix a compiler warning on Solaris.
28900         * lib/ptsname_r.c (__ptsname_r): Reduce the scope of variable 'err'.
28902 2020-12-28  Bruno Haible  <bruno@clisp.org>
28904         gnulib-tool: Fix logic whether to add a dummy.c.
28905         * gnulib-tool (func_remove_if_blocks): New function.
28906         (func_modules_add_dummy): Use it to eliminate all conditional statements
28907         from the automake snippet.
28909 2020-12-28  Paul Eggert  <eggert@cs.ucla.edu>
28911         faccessat: revert recent EOVERFLOW change
28912         I misunderstood the glibc source code.  Deduced from
28913         Adhemerval Zanella’s proposed glibc patch in:
28914         https://sourceware.org/pipermail/libc-alpha/2020-December/121131.html
28915         * doc/posix-functions/faccessat.texi: It is not a problem.
28916         * lib/canonicalize-lgpl.c, lib/canonicalize.c, lib/faccessat.c:
28917         (FACCESSAT_NEVER_OVERFLOWS): Remove. All uses removed.
28918         * lib/faccessat.c: Revert to simpler version now that
28919         LSTAT_FOLLOWS_SLASHED_SYMLINK must be false.
28920         * m4/faccessat.m4 (gl_FUNC_FACCESSAT_EOVERFLOW):
28921         Remove.  All uses removed.
28922         * modules/canonicalize, modules/canonicalize-lgpl (Files):
28923         Remove m4/faccessat.m4.
28925         canonicalize-lgpl: accommodate picky cpp
28926         * lib/canonicalize-lgpl.c: Use "defined FUNC_REALPATH_WORKS" in
28927         case preprocessor is picky.  Reported by Adhemerval Zanella in:
28928         https://sourceware.org/pipermail/libc-alpha/2020-December/121130.html
28930         canonicalize: simplify via scratch_buffer_dupfree
28931         * config/srclist.txt: Adjust accordingly.
28932         * lib/canonicalize-lgpl.c (realpath_stk):
28933         * lib/canonicalize.c (canonicalize_filename_mode_stk):
28934         Simplify by using scratch_buffer_dupfree.
28935         * lib/malloc/scratch_buffer.h (scratch_buffer_dupfree): New function.
28936         * lib/malloc/scratch_buffer_dupfree.c: New file.
28937         * modules/scratch_buffer (Files, Depends-on):
28938         Add malloc/scratch_buffer_dupfree.c.
28940 2020-12-27  Paul Eggert  <eggert@cs.ucla.edu>
28942         regex: remove glibc21.m4
28943         It doesn’t seem to be needed any more; at least, I couldn’t
28944         reproduce the circa-2013 problem.  Perhaps the recent
28945         --conditional-dependencies fixes have removed the need for it.
28946         * m4/glibc21.m4: Remove.  All uses removed.
28948 2020-12-26  Bruno Haible  <bruno@clisp.org>
28950         gnulib-tool: Make --conditional-dependencies work with --with-tests.
28951         Reported by Paul Eggert in
28952         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00236.html>.
28953         * gnulib-tool (func_emit_tests_Makefile_am): Handle conditional
28954         dependencies like func_emit_lib_Makefile_am.
28956 2020-12-26  Bruno Haible  <bruno@clisp.org>
28958         execvpe: Make dependency to stdbool explicit.
28959         * lib/execvpe.c: Include <stdbool.h>.
28960         * modules/execvpe (Depends-on): Add stdbool.
28962         execlp: Add tests.
28963         * tests/test-execlp-main.c: New file.
28964         * tests/test-execlp.sh: New file.
28965         * modules/execlp-tests: New file.
28967         execlp: New module.
28968         * lib/execlp.c: New file.
28969         * m4/execlp.m4: New file.
28970         * modules/execlp: New file.
28971         * doc/posix-functions/execlp.texi: Mention more Windows problems and the
28972         new module.
28974         execle: Add tests.
28975         * tests/test-execle-main.c: New file.
28976         * tests/test-execle.sh: New file.
28977         * modules/execle-tests: New file.
28979         execle: New module.
28980         * lib/execle.c: New file.
28981         * m4/execle.m4: New file.
28982         * modules/execle: New file.
28983         * doc/posix-functions/execle.texi: Mention more Windows problems and the
28984         new module.
28986         execl: Add tests.
28987         * tests/test-execl-main.c: New file.
28988         * tests/test-execl.sh: New file.
28989         * modules/execl-tests: New file.
28991         execl: New module.
28992         * lib/execl.c: New file.
28993         * m4/execl.m4: New file.
28994         * modules/execl: New file.
28995         * doc/posix-functions/execl.texi: Mention more Windows problems and the
28996         new module.
28998         execv: Add tests.
28999         * tests/test-execv-main.c: New file.
29000         * tests/test-execv.sh: New file.
29001         * modules/execv-tests: New file.
29003         execv: New module.
29004         * lib/execv.c: New file.
29005         * m4/execv.m4: New file.
29006         * modules/execv: New file.
29007         * doc/posix-functions/execv.texi: Mention more Windows problems and the
29008         new module.
29010         execvp: Add tests.
29011         * tests/test-execvp-main.c: New file.
29012         * tests/test-execvp.sh: New file.
29013         * modules/execvp-tests: New file.
29015         execvp: New module.
29016         * lib/execvp.c: New file.
29017         * m4/execvp.m4: New file.
29018         * modules/execvp: New file.
29019         * doc/posix-functions/execvp.texi: Mention more Windows problems and the
29020         new module.
29022         execvpe: Add tests.
29023         * tests/test-execvpe-main.c: New file.
29024         * tests/test-execvpe.sh: New file.
29025         * modules/execvpe-tests: New file.
29027         execvpe: New module.
29028         * lib/execvpe.c: New file.
29029         * m4/execvpe.m4: New file.
29030         * modules/execvpe: New file.
29031         * doc/glibc-functions/execvpe.texi: Mention the Windows problems and the
29032         new module.
29034         execve: Add tests.
29035         * tests/test-exec-child.c: New file.
29036         * tests/test-execve-main.c: New file.
29037         * tests/test-execve.sh: New file.
29038         * modules/execve-tests: New file.
29040         execve: New module.
29041         * lib/execve.c: New file.
29042         * m4/execve.m4: New file.
29043         * modules/execve: New file.
29044         * doc/posix-functions/execve.texi: Mention more Windows problems and the
29045         new module.
29047         execve, execvpe, execvp, execv, execl, execle, execlp: Prepare modules.
29048         * lib/unistd.in.h (execl, execle, execlp, execv, execve, execvp,
29049         execvpe): Add declarations for the new modules.
29050         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether execl, execle, execlp,
29051         execv, execve, execvp, execvpe are declared.
29052         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_EXEC*, HAVE_EXECVPE,
29053         REPLACE_EXEC*.
29054         * modules/unistd (Makefile.am): Substitute GNULIB_EXEC*, HAVE_EXECVPE,
29055         REPLACE_EXEC*.
29056         * tests/test-unistd-c++.cc: Check the signature of execl, execle,
29057         execlp, execv, execve, execvp, execvpe.
29059 2020-12-26  Bruno Haible  <bruno@clisp.org>
29061         stack: Fix typo in comments.
29062         * lib/stack.h: Fix typo in comments.
29064 2020-12-26  Bruno Haible  <bruno@clisp.org>
29066         bitset: Fix conflict with 'free-posix' module.
29067         * lib/bitset/base.h: Include <stdlib.h>.
29069 2020-12-25  Paul Eggert  <eggert@cs.ucla.edu>
29071         idx: change idx.h comment to LGPLv2.1+
29072         * lib/idx.h: Change license notice to match what should be in glibc.
29073         gnulib-tool will change it as appropriate anyway, so this is just
29074         to simplify syncing with glibc.
29076 2020-12-25  Thien-Thi Nguyen  <ttn@gnu.org>
29078         MODULES.html.sh: Update after 2020-12-19 change.
29079         * MODULES.html.sh (func_all_modules): Do s/free/free-posix/.
29081 2020-12-25  Bruno Haible  <bruno@clisp.org>
29083         Make it possible to turn off the mkdir override on Windows.
29084         * lib/sys_stat.in.h (mkdir): Conditionalize through GNULIB_MKDIR and
29085         GNULIB_MDA_MKDIR. Also support GNULIB_POSIXCHECK.
29086         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_MKDIR,
29087         GNULIB_MDA_MKDIR.
29088         * modules/sys_stat (Makefile.am): Substitute GNULIB_MKDIR,
29089         GNULIB_MDA_MKDIR.
29090         * modules/mkdir (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
29091         * doc/posix-functions/mkdir.texi: Mention also the 'sys_stat' module.
29093         Make it possible to turn off each of the Windows oldnames workarounds.
29094         * lib/fcntl.in.h (creat, open):  Conditionalize each of the Windows
29095         oldnames workarounds through a GNULIB_MDA_<func> symbol.
29096         * lib/math.in.h (j0, j1, jn, y0, y1, yn): Likewise.
29097         * lib/search.in.h (lfind, lsearch): Likewise.
29098         * lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
29099         Likewise.
29100         * lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
29101         * lib/string.in.h (memccpy, strdup): Likewise.
29102         * lib/sys_stat.in.h (chmod, umask): Likewise.
29103         * lib/time.in.h (tzset): Likewise.
29104         * lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
29105         execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
29106         read, rmdir, swab, unlink, write): Likewise.
29107         * lib/utime.in.h (utime): Likewise.
29108         * lib/wchar.in.h (wcsdup): Likewise.
29109         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize these
29110         GNULIB_MDA_<func> symbols.
29111         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Likewise.
29112         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Likewise.
29113         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
29114         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
29115         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
29116         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
29117         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Likewise.
29118         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
29119         * m4/utime_h.m4 (gl_UTIME_H_DEFAULTS): Likewise.
29120         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Likewise.
29121         * modules/fcntl-h (Makefile.am): Substitute these GNULIB_MDA_<func>
29122         symbols.
29123         * modules/math (Makefile.am): Likewise.
29124         * modules/search (Makefile.am): Likewise.
29125         * modules/stdio (Makefile.am): Likewise.
29126         * modules/stdlib (Makefile.am): Likewise.
29127         * modules/string (Makefile.am): Likewise.
29128         * modules/sys_stat (Makefile.am): Likewise.
29129         * modules/time (Makefile.am): Likewise.
29130         * modules/unistd (Makefile.am): Likewise.
29131         * modules/utime-h (Makefile.am): Likewise.
29132         * modules/wchar (Makefile.am): Likewise.
29134 2020-12-24  Paul Eggert  <eggert@cs.ucla.edu>
29136         canonicalize, canonicalize-lgpl: remove lint
29137         Pacify GCC.  Some of these problems were reported by Bruno Haible in:
29138         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00217.html
29139         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
29140         Sort shared include directives, for consistency.
29141         (IF_LINT): New macro.
29142         (suffix_requires_dir_check): Mark with _GL_ATTRIBUTE_PURE.
29143         * lib/canonicalize-lgpl.c (GCC_LINT, _GL_ATTRIBUTE_PURE) [_LIBC]:
29144         New macros.
29145         (realpath_stk): Suppress bogus -Wmaybe-uninitialized warning.
29146         * lib/canonicalize.c (canonicalize_filename_mode_stk):
29147         Omit unused local.  Suppress bogus -Wmaybe-uninitialized warning.
29149 2020-12-24  Bruno Haible  <bruno@clisp.org>
29151         spawn-pipe: Use posix_spawn by default on native Windows.
29152         * lib/spawn-pipe.c (SPAWN_PIPE_IMPL_AVOID_POSIX_SPAWN): New macro.
29153         (create_pipe): Use it to decide among the two possible implementations.
29154         * modules/spawn-pipe (Depends-on): Add posix_spawnattr_setpgroup.
29156 2020-12-24  Bruno Haible  <bruno@clisp.org>
29158         unistd-safer: Implement pipe_safer on native Windows.
29159         * lib/pipe-safer.c (pipe_safer): Don't test HAVE_PIPE.
29160         * modules/unistd-safer (Depends-on): Add pipe-posix.
29162 2020-12-24  Bruno Haible  <bruno@clisp.org>
29164         execute: Use posix_spawn by default on native Windows.
29165         * lib/execute.c (EXECUTE_IMPL_AVOID_POSIX_SPAWN): New macro.
29166         (execute): Use it to decide among the two possible implementations.
29168 2020-12-24  Paul Eggert  <eggert@cs.ucla.edu>
29170         canonicalize-lgpl: merge proposed libc changes
29171         This merges the changes proposed for glibc in:
29172         https://sourceware.org/pipermail/libc-alpha/2020-December/121085.html
29173         https://sourceware.org/pipermail/libc-alpha/2020-December/121086.html
29174         * lib/canonicalize-lgpl.c: Include idx.h and filename.h
29175         unconditionally.
29176         (idx_t, IDX_MAX, FILE_SYSTEM_PREFIX_LEN, IS_ABSOLUTE_FILE_NAME)
29177         (ISSLASH) [_LIBC]: Remove.
29179 2020-12-24  Bruno Haible  <bruno@clisp.org>
29181         posix_spawn-internal: Implement for native Windows.
29182         * lib/spawni.c (grow_inheritable_handles, shrink_inheritable_handles,
29183         close_inheritable_handles, memiszero, sigisempty, open_handle, do_open,
29184         do_dup2, do_close): New functions.
29185         (__spawni): Implement on native Windows.
29186         * modules/posix_spawn-internal (Depends-on): Add filename,
29187         concat-filename, findprog-in, malloca, windows-spawn.
29188         * doc/posix-functions/posix_spawn.texi: Update.
29189         * doc/posix-functions/posix_spawnp.texi: Likewise.
29191 2020-12-24  Bruno Haible  <bruno@clisp.org>
29193         windows-spawn: Export another auxiliary function.
29194         * lib/windows-spawn.h (convert_CreateProcess_error): New declaration.
29195         * lib/windows-spawn.c (convert_CreateProcess_error): New function,
29196         extracted from spawnpvech.
29197         (spawnpvech): Use it.
29199 2020-12-24  Bruno Haible  <bruno@clisp.org>
29201         windows-spawn: Export some more auxiliary functions.
29202         * lib/windows-spawn.h: Include <stdbool.h>.
29203         (struct inheritable_handles): New type.
29204         (init_inheritable_handles, compose_handles_block,
29205         free_inheritable_handles): New declarations.
29206         * lib/windows-spawn.c (init_inheritable_handles, compose_handles_block):
29207         New functions, based on spawnvech.
29208         (free_inheritable_handles): New function.
29209         (spawnpvech): Use them.
29211 2020-12-24  Bruno Haible  <bruno@clisp.org>
29213         windows-spawn: Export another auxiliary function.
29214         * lib/windows-spawn.h (compose_envblock): New declaration.
29215         * lib/windows-spawn.c (compose_envblock): New function, extracted from
29216         spawnpvech.
29217         (spawnpvech): Use it.
29219 2020-12-24  Bruno Haible  <bruno@clisp.org>
29221         windows-spawn: Export an auxiliary function.
29222         * lib/windows-spawn.h (compose_command): New declaration.
29223         * lib/windows-spawn.c (compose_command): New function, extracted from
29224         spawnpvech.
29225         (spawnpvech): Use it.
29227 2020-12-24  Bruno Haible  <bruno@clisp.org>
29229         posix_spawn* tests: Add support for native Windows.
29230         * tests/test-posix_spawn-open1.c (DATA_FILENAME): Treat native Windows
29231         like Cygwin.
29232         * tests/test-posix_spawn-dup2-stdin.c (main): Don't assume the signals
29233         SIGHUP and SIGPIPE. On native Windows, don't call
29234         posix_spawnattr_setsigmask.
29235         * tests/test-posix_spawn-dup2-stdout.c (main): Likewise.
29236         * tests/test-posix_spawn-fchdir.c (main): Likewise.
29237         * tests/test-posix_spawn-chdir.c (test): Likewise. Accept the child
29238         output from Cygwin's 'pwd' program.
29239         * tests/test-posix_spawn-script.c (main): On native Windows, skip the
29240         executable-shell-script part of the test.
29241         * tests/test-posix_spawnp-script.c (main): Likewise.
29242         * modules/posix_spawn-tests (Depends-on): Add freopen, waitpid.
29243         (configure.ac): Don't define the POSIX_SPAWN_PORTED conditional.
29244         (Makefile.am): Don't test the POSIX_SPAWN_PORTED conditional.
29245         * modules/posix_spawnp-tests (Depends-on): Add  waitpid.
29246         (configure.ac): Don't define the POSIX_SPAWN_PORTED conditional.
29247         (Makefile.am): Don't test the POSIX_SPAWN_PORTED conditional.
29248         * modules/posix_spawn_file_actions_addchdir-tests (Makefile.am): Don't
29249         test the POSIX_SPAWN_PORTED conditional.
29250         * modules/posix_spawn_file_actions_addfchdir-tests (configure.ac):
29251         Define the POSIX_SPAWN_PORTED conditional here.
29253 2020-12-24  Bruno Haible  <bruno@clisp.org>
29255         sh-filename: Add support for native Windows.
29256         * m4/sh-filename.m4 (gl_SH_FILENAME): Treat native Windows like Cygwin.
29258 2020-12-24  Paul Eggert  <eggert@cs.ucla.edu>
29260         careadlinkat: improve warning line number
29261         This propagates an idea first used in canonicalize-lgpl.
29262         * lib/careadlinkat.c (GCC_BOGUS_WRETURN_LOCAL_ADDR):
29263         New macro.
29264         (careadlinkat): Use it.
29266         linkat: use eloop-threshold
29267         * lib/linkat.c: Include eloop-threshold.h.
29268         Do not include sys/param.h.
29269         (MAXSYMLINKS): Remove.
29270         (link_follow, linkat_follow): Use __eloop_threshold instead
29271         of MAXSYMLINKS.
29272         * m4/linkat.m4 (gl_FUNC_LINKAT): Omit sys/param.h check.
29273         * modules/linkat (Depends-on): Add eloop-threshold.  Sort.
29275         canonicalize-lgpl: use eloop-threshold
29276         * lib/canonicalize-lgpl.c [!_LIBC]: Include eloop-threshold.h.
29277         (MAXSYMLINKS, __eloop_threshold): Remove.
29278         * modules/canonicalize-lgpl (Depends-on): Add eloop-threshold.
29280         eloop-threshold: new module
29281         * config/srclist.txt: Add a comment about it.
29282         * lib/eloop-threshold.h, modules/eloop-threshold: New files.
29284         canonicalize: prefer faccessat to stat
29285         A proper faccessat doesn't have the EOVERFLOW problem, and can be
29286         more efficient as it needn't gather data from the filesystem to
29287         fill in struct stat.  So use stat only if faccessat is absent,
29288         or when checking for symlink loops in canonicalize.c.
29289         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
29290         Include fcntl.h, for AT_EACCESS.
29291         (FACCESSAT_NEVER_EOVERFLOWS): Default to false.
29292         (file_accessible): New function, based on faccessat but with
29293         a fallback to stat and with an EOVERFLOW workaround.
29294         (dir_check): Use it.
29295         (dir_suffix): New static constant.
29296         * lib/canonicalize-lgpl.c (FACCESSAT_NEVER_EOVERFLOWS) [_LIBC]:
29297         Use __ASSUME_FACCESSAT2 to set FACCESSAT_NEVER_EOVERFLOWS
29298         (__faccessat) [!_LIBC]: Define.
29299         (realpath_stk): Use dir_suffix now.
29300         * lib/canonicalize.c (canonicalize_filename_mode_stk):
29301         If logical, don't check each component's existence; just check
29302         at the end, as that's enough.
29303         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
29304         (gl_CANONICALIZE_LGPL_SEPARATE):
29305         Require gl_FUNC_FACCESSAT_EOVERFLOW,
29306         gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, and check for faccessat.
29307         (gl_CANONICALIZE_LGPL_SEPARATE): Do not check for readlink,
29308         as the code does not use HAVE_READLINK.
29309         * modules/canonicalize, modules/canonicalize-lgpl (Files):
29310         Add m4/faccessat.m4, m4/lstat.m4.
29311         (Depends-on): Add fcntl-lh.
29313         faccessat: work around F_OK EOVERFLOW bug
29314         * doc/posix-functions/faccessat.texi: Mention the problem.
29315         * lib/faccessat.c (FACCESSAT_NEVER_EOVERFLOWS): Default to 0.
29316         (rpl_faccessat): If !FACCESSAT_NEVER_EOVERFLOWS, check
29317         for F_OK and EOVERFLOW, which means we can return 0.
29318         * m4/faccessat.m4 (gl_FUNC_FACCESSAT_EOVERFLOW): New macro.
29319         (gl_FUNC_FACCESSAT): Use it.
29321         stat failing with EOVERFLOW implies existence
29322         * lib/euidaccess.c (euidaccess):
29323         * lib/file-has-acl.c (file_has_acl):
29324         * lib/link.c (link, rpl_link):
29325         * lib/mkdir.c (rpl_mkdir):
29326         * lib/mkfifo.c (rpl_mkfifo):
29327         * lib/mknod.c (rpl_mknod):
29328         * lib/ptsname_r.c (__ptsname_r):
29329         * lib/symlink.c (rpl_symlink):
29330         * lib/symlinkat.c (rpl_symlinkat):
29331         * lib/unlink.c (rpl_unlink):
29332         * lib/unlinkat.c (rpl_unlinkat):
29333         * lib/utime.c (utime):
29334         If stat fails with EOVERFLOW the file exists, so treat it that way
29335         in file-existence tests that do not need struct stat values.
29337         canonicalize-lgpl: remove freea macro
29338         * lib/canonicalize-lgpl.c (freea) [_LIBC]: Remove; not needed.
29340         canonicalize, canonicalize-lgpl: fix symlink bug
29341         Problem reported by Adhemerval Zanella in:
29342         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00155.html
29343         * lib/canonicalize-lgpl.c, lib/canonicalize.c:
29344         (suffix_requires_dir_check, dir_check): New functions.
29345         (GCC_BOGUS_WRETURN_LOCAL_ADDR): New macro, to put the diagnostic
29346         closer to the related GCC diagnostics.
29347         * lib/canonicalize-lgpl.c (realpath_stk):
29348         * lib/canonicalize.c (canonicalize_file_mode_stk):
29349         Use them to fix a bug with .../symlink-to-regular-file/ etc.
29350         * lib/canonicalize-lgpl.c (__stat) [!_LIBC]: New macro.
29351         (realpath_stk): New function,
29352         with the contents of the old __realpath and a new scratch buffer arg.
29353         This is needed to pacify GCC 10.1, as canonicalize.c is already doing.
29354         (__realpath): Use it.
29355         * tests/test-canonicalize-lgpl.c, tests/test-canonicalize.c:
29356         Add test cases for the bugs.
29358 2020-12-24  Bruno Haible  <bruno@clisp.org>
29360         execute: Treat signalled processes like wait-process does.
29361         * lib/execute.c: Include <sys/types.h>, <sys/wait.h>.
29362         (execute): Recognize the case where the exit code indicates a signalled
29363         child process.
29364         * tests/test-execute-main.c (main): Update expected test result.
29365         * modules/execute (Depends-on): Add sys_wait.
29367 2020-12-24  Bruno Haible  <bruno@clisp.org>
29369         windows-spawn: Improve errno upon failure on native Windows.
29370         * lib/windows-spawn.c (spawnpvech): Map the CreateProcess errors
29371         ERROR_BAD_FORMAT and ERROR_BAD_EXE_FORMAT to ENOEXEC.
29372         * tests/executable-script.sh: New file.
29373         * tests/test-posix_spawn-script.c (main): Also try executing
29374         executable-script.sh.
29375         * tests/test-posix_spawnp-script.c (main): Likewise.
29376         * tests/test-execute-script.c (main): Likewise.
29377         * tests/test-spawn-pipe-script.c (main): Likewise.
29378         * modules/posix_spawn-tests (Files): Add tests/executable-script.sh.
29379         * modules/posix_spawnp-tests (Files): Likewise.
29380         * modules/execute-tests (Files): Likewise.
29381         * modules/spawn-pipe-tests (Files): Likewise.
29383 2020-12-24  Bruno Haible  <bruno@clisp.org>
29385         findprog-in: Improve errno upon failure on native Windows.
29386         * lib/findprog-in.c (find_in_given_path): If the file basename has no
29387         dot and the search with a suffix returned no result, do also a search
29388         without a suffix, and set errno = ENOEXEC if we find a file in this way.
29389         * tests/test-spawn-pipe-script.c (main): Update expected errno.
29391 2020-12-23  Bruno Haible  <bruno@clisp.org>
29393         posix_spawn, posix_spawnp: Fix execution of scripts.
29394         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_SECURE): New macro.
29395         (gl_POSIX_SPAWN_BODY): Invoke it. Set REPLACE_POSIX_SPAWN if posix_spawn
29396         or posix_spawnp allows unsecure execution of scripts.
29397         * doc/posix-functions/posix_spawn.texi: Document the script execution
29398         problem.
29399         * doc/posix-functions/posix_spawnp.texi: Likewise.
29401 2020-12-23  Bruno Haible  <bruno@clisp.org>
29403         Add unit tests regarding execution of scripts.
29404         * tests/executable-script: New file.
29405         * tests/executable-shell-script: New file.
29406         * tests/test-posix_spawn-script.c: New file.
29407         * tests/test-posix_spawnp-script.c: New file.
29408         * tests/test-execute-script.c: New file.
29409         * tests/test-spawn-pipe-script.c: New file.
29410         * modules/posix_spawn-tests (Files): Add
29411         tests/test-posix_spawn-script.c, tests/executable-script,
29412         tests/executable-shell-script.
29413         (Makefile.am): Compile and run test-posix_spawn-script.
29414         * modules/posix_spawnp-tests (Files): Add
29415         tests/test-posix_spawnp-script.c, tests/executable-script,
29416         tests/executable-shell-script.
29417         (Makefile.am): Compile and run test-posix_spawnp-script.
29418         * modules/execute-tests (Files): Add tests/test-execute-script.c,
29419         tests/executable-script, tests/executable-shell-script.
29420         (Makefile.am): Compile and run test-execute-script.
29421         * modules/spawn-pipe-tests (Files): Add tests/test-spawn-pipe-script.c,
29422         tests/executable-script, tests/executable-shell-script.
29423         (Makefile.am): Compile and run test-spawn-pipe-script.
29425 2020-12-23  Bruno Haible  <bruno@clisp.org>
29427         Don't execute scripts without '#!' marker through /bin/sh.
29428         This reflects the change done in glibc through
29429         <https://sourceware.org/bugzilla/show_bug.cgi?id=13134> and
29430         <https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=d96de9634a334af16c0ac711074c15ac1762b23c>.
29431         * lib/spawni.c (internal_function): Remove macro.
29432         (script_execute): Remove function.
29433         (__spawni): Don't invoke script_execute.
29434         * lib/execute.c (execute): Disable the ENOEXEC handling.
29435         * lib/spawn-pipe.c (create_pipe): Likewise.
29436         * NEWS: Mention the change.
29438 2020-12-23  Bruno Haible  <bruno@clisp.org>
29440         posix_spawn[p]: Fix compilation error on Windows (regr. 2020-12-14).
29441         Reported by Adrian Ebeling <devl@adrian-ebeling.de> in
29442         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00189.html>.
29443         * lib/spawni.c (__spawni): Update function parameters.
29445 2020-12-23  Bruno Haible  <bruno@clisp.org>
29447         posix_spawn tests: Add two more tests.
29448         * tests/test-posix_spawn-inherit0.c: New file, based on
29449         tests/test-posix_spawn-open2.c.
29450         * tests/test-posix_spawn-inherit1.c: New file, based on
29451         tests/test-posix_spawn-open2.c.
29452         * modules/posix_spawn-tests (Files): Add them.
29453         (Depends-on): Add fflush.
29454         (Makefile.am): Compile and run test-posix_spawn-inherit0 and
29455         test-posix_spawn-inherit1.
29457 2020-12-23  Bruno Haible  <bruno@clisp.org>
29459         posix_spawn tests: Add another test.
29460         * tests/test-posix_spawn-open2.c: New file, based on
29461         tests/test-posix_spawn-open1.c.
29462         * modules/posix_spawn-tests (Files): Add it.
29463         (Makefile.am): Compile and run test-posix_spawn-open1.
29465 2020-12-20  Bruno Haible  <bruno@clisp.org>
29467         Remove support for broken <wchar.h> in AIX 3.
29468         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify test programs.
29470 2020-12-20  Bruno Haible  <bruno@clisp.org>
29472         Remove support for broken <wchar.h> in BSD/OS and OSF/1.
29473         * lib/wchar.in.h: Don't include <stdio.h>, <time.h>.
29474         * lib/mbchar.h: Likewise.
29475         * lib/mbiter.h: Likewise.
29476         * lib/mbuiter.h: Likewise.
29477         * m4/stdint.m4 (gl_STDINT_INCLUDES): Likewise.
29478         * lib/mbfile.h: Don't include <time.h>.
29479         * lib/mbswidth.h: Update comment.
29480         * lib/stdint.in.h: Don't include <stddef.h>, <stdio.h>, <time.h> before
29481         <wchar.h>.
29482         * lib/wctype.in.h: Likewise.
29483         * m4/btowc.m4 (gl_FUNC_BTOWC): Simplify test programs.
29484         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Likewise.
29485         * m4/iswdigit.m4 (gl_FUNC_ISWDIGIT): Likewise.
29486         * m4/iswxdigit.m4 (gl_FUNC_ISWXDIGIT): Likewise.
29487         * m4/mbrlen.m4 (gl_FUNC_MBRLEN, gl_MBRLEN_INCOMPLETE_STATE,
29488         gl_MBRLEN_RETVAL, gl_MBRLEN_NUL_RETVAL): Likewise.
29489         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Likewise.
29490         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC, gl_MBRTOWC_INCOMPLETE_STATE,
29491         gl_MBRTOWC_SANITYCHECK, gl_MBRTOWC_NULL_ARG1, gl_MBRTOWC_NULL_ARG2,
29492         gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL, gl_MBRTOWC_STORES_INCOMPLETE,
29493         AC_FUNC_MBRTOWC): Likewise.
29494         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Likewise.
29495         * m4/mbsnrtowcs.m4 (gl_MBSNRTOWCS_WORKS_IN_TRADITIONAL_LOCALE):
29496         Likewise.
29497         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS, gl_MBSRTOWCS_WORKS): Likewise.
29498         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
29499         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
29500         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Likewise.
29501         * m4/wchar_h.m4 (gl_WCHAR_H, gl_WCHAR_H_INLINE_OK): Likewise.
29502         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
29503         * m4/wcsdup.m4 (gl_FUNC_WCSDUP): Likewise.
29504         * m4/wcsnrtombs.m4 (gl_WCSNRTOMBS_WORKS_IN_TRADITIONAL_LOCALE):
29505         Likewise.
29506         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS, gl_WCSRTOMBS_TERMINATION,
29507         gl_WCSRTOMBS_NULL): Likewise.
29508         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Likewise.
29509         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
29510         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
29511         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
29512         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
29513         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Likewise.
29514         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Likewise.
29515         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Likewise.
29516         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Likewise.
29517         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Likewise.
29519 2020-12-20  Bruno Haible  <bruno@clisp.org>
29521         isnanf: Fix autoconf test.
29522         * m4/isnanf.m4 (gl_ISNANF_WORKS): Fix one of the NaN tests.
29524 2020-12-20  Bruno Haible  <bruno@clisp.org>
29526         Remove some of the support for obsolete IRIX 4 and 5.
29527         * m4/mountlist.m4 (AC_FUNC_GETMNTENT): Don't test for getmntent in
29528         libsun.
29529         * tests/init.sh (setup_): Don't talk about IRIX 5.
29531 2020-12-20  Bruno Haible  <bruno@clisp.org>
29533         filemode: Remove Cray support.
29534         * lib/filemode.c (IS_MIGRATED_FILE): Remove macro.
29535         (filemodestring): Don't produce an 'M' type.
29536         * m4/filemode.m4 (gl_FILEMODE): Don't invoke AC_STRUCT_ST_DM_MODE.
29537         * m4/st_dm_mode.m4: Remove file.
29538         * modules/filemode (Files): Remove it.
29540 2020-12-20  Paul Eggert  <eggert@cs.ucla.edu>
29542         free-posix: assume glibc 2.33 fixes this.
29543         * m4/free.m4 (gl_FUNC_FREE): Assume glibc 2.33+ is fixed.
29544         Use compile-time test rather than guessing for cross-builds.
29546 2020-12-20  Bruno Haible  <bruno@clisp.org>
29548         backupfile: Fix compilation error on native Windows (regr. 2018-10-23).
29549         Reported by Adrian Ebeling <adrianebeling@gmx.de> in
29550         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00156.html>.
29551         * lib/backupfile.c (fpathconf): Define fallback, like for pathconf.
29553 2020-12-20  Bruno Haible  <bruno@clisp.org>
29555         float: Fix compilation error when gnulib's float.h exists twice.
29556         Reported by Santiago Vila <sanvila@unex.es>.
29557         * lib/float.in.h (GNULIB_defined_long_double_union): New macro.
29559 2020-12-19  Bruno Haible  <bruno@clisp.org>
29561         free-posix: Assume future POSIX compliance only on OpenBSD and Solaris.
29562         * m4/free.m4 (gl_FUNC_FREE): Guess yes only on OpenBSD and Solaris.
29563         Don't trust _POSIX_VERSION for this test.
29565 2020-12-19  Paul Eggert  <eggert@cs.ucla.edu>
29567         free-posix: port to GNU/Linux
29568         * m4/free.m4 (gl_FUNC_FREE): Don’t assume GNU hosts are free of
29569         the bug, as it occurs on Ubuntu 20.10 x86-64 and, I assume, on
29570         other GNU/Linux hosts.
29572 2020-12-19  Bruno Haible  <bruno@clisp.org>
29574         free-posix: Add tests.
29575         * tests/test-free.c: New file.
29576         * tests/macros.h (ASSERT_NO_STDIO,
29577         WRITE_MACROEXPANDED_INTEGER_TO_STDERR, WRITE_INTEGER_TO_STDERR,
29578         WRITE_TO_STDERR): New macros.
29579         * modules/free-posix-tests: New file.
29581 2020-12-18  Bruno Haible  <bruno@clisp.org>
29583         free-posix: Add C++ declaration test.
29584         * tests/test-stdlib-c++.cc (free): New declaration.
29586 2020-12-18  Bruno Haible  <bruno@clisp.org>
29588         free-posix: New module, renamed from 'free'.
29589         * modules/free-posix: Renamed from modules/free.
29590         (configure.ac): Update gl_STDLIB_MODULE_INDICATOR invocation.
29591         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_FREE_POSIX,
29592         not GNULIB_FREE.
29593         * modules/stdlib (Makefile.am): Substitute GNULIB_FREE_POSIX, not
29594         GNULIB_FREE.
29595         * lib/stdlib.in.h (free): Test GNULIB_FREE_POSIX, not GNULIB_FREE.
29596         * doc/posix-functions/free.texi: Mention the module 'free-posix' and
29597         what it does.
29598         * NEWS: Mention that module 'free' no longer exists.
29599         * modules/canonicalize (Depends-on): Add free-posix. Remove free.
29600         * modules/canonicalize-lgpl (Depends-on): Likewise.
29602 2020-12-18  Bruno Haible  <bruno@clisp.org>
29604         free: Remove support for obsolete platforms.
29605         * m4/free.m4 (gl_FUNC_FREE): Assume free(NULL) works. Don't define
29606         CANNOT_FREE_NULL.
29607         * lib/free.c (rpl_free): Don't test CANNOT_FREE_NULL.
29608         * modules/free (Description): Update.
29609         * doc/posix-functions/free.texi: Don't mention SunOS 4 any more.
29611 2020-12-18  Paul Eggert  <eggert@cs.ucla.edu>
29613         intprops: port to ICC 2021.1 Beta 20201112
29614         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P):
29615         Port to ICC 2021.1, which has a non-working __builtin_mul_overflow_p.
29616         Add a clause for other compilers that claim to support
29617         __builtin_mul_overflow_p, since we might as well find out about
29618         slackers other than Clang and ICC.
29619         (INT_MULTIPLY_WRAPV): ICC 2021 has GCC bug 91450, so treat it
29620         like older GCCs even when it claims to be a newer one.
29622 2020-12-18  Bruno Haible  <bruno@clisp.org>
29624         intprops: Avoid potentially buggy __builtin_add_overflow in GCC 5, 6.
29625         Reported by Stefan Liebler <stli@linux.ibm.com> in
29626         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00152.html>.
29627         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW): Don't define for
29628         GCC 5.x and 6.x.
29629         * lib/glob.c (size_add_wrapv): Don't use __builtin_add_overflow for
29630         GCC 5.x and 6.x.
29632 2020-12-17  Bruno Haible  <bruno@clisp.org>
29634         free: Fix warning.
29635         Reported by Pádraig Brady <P@draigBrady.com> in
29636         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00148.html>.
29637         * lib/stdlib.in.h (free): New declaration.
29638         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether 'free' is declared.
29639         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_FREE, REPLACE_FREE.
29640         * modules/stdlib (Makefile.am): Substitute GNULIB_FREE, REPLACE_FREE.
29641         * m4/free.m4 (gl_FUNC_FREE): Set REPLACE_FREE, instead of defining
29642         'free' as a macro here.
29643         * modules/free (Depends-on): Add stdlib.
29644         (configure.ac): Test REPLACE_FREE. Invoke gl_STDLIB_MODULE_INDICATOR.
29646 2020-12-17  Paul Eggert  <eggert@cs.ucla.edu>
29648         canonicalize-lgpl: fix AIX test failures
29649         This merges the recent canonicalize.c fix into canonicalize-lgpl.c.
29650         Problem reported by Bruno Haible in:
29651         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00138.html
29652         * lib/canonicalize-lgpl.c: Include sys/stat.h.
29653         (__realpath): When testing a file name ending in '/', use stat
29654         rather than readlink, so that it does the right thing on AIX.
29655         * modules/canonicalize-lgpl (Depends-on): Add stat, sys_stat.
29657         canonicalize: omit second readlink when not needed
29658         * lib/canonicalize.c (canonicalize_filename_mode_stk):
29659         Omit second readlink when (can_exist != CAN_MISSING
29660         && startlen != 0 && !logical).  Simplify.
29662         canonicalize: remove arbitrary 8192-byte limit
29663         Remove canonicalize.c’s arbitrary 8192-byte limit on platforms
29664         like GNU Hurd that do not define the PATH_MAX macro, and similarly
29665         for canonicalize-lgpl.c’s arbitrary 1024-byte limit.  Do this by
29666         using scratch buffers.  Lessen the number of differences between
29667         the two source files, to simplify this and future maintenance.
29668         * lib/canonicalize-lgpl.c (__realpath):
29669         * lib/canonicalize.c (canonicalize_filename_mode_stk):
29670         Use scratch buffers instead of malloc and malloca.  This avoids
29671         the need for alloca, and avoids the need for malloc in most cases.
29672         * lib/canonicalize-lgpl.c, lib/canonicalize.c: Make these files
29673         easier to compare, e.g., by sorting include files and by switching
29674         to the GNU convention of calling file names "file names", not
29675         "path names".  Include stdbool.h, scratch_buffer.h.
29676         * lib/canonicalize-lgpl.c (IDX_MAX) [_LIBC]: New macro.
29677         (malloca) [_LIBC]: Remove.
29678         [!_LIBC]: Do not include malloca.h.
29679         (get_path_max): New function, so that pathconf is called only in
29680         the rare and dubious case when when RESOLVED is not null and
29681         PATH_MAX is not defined.  Invoke pathconf on "/" not the input
29682         file name, as we care about the longest file name starting from
29683         "/" (not from the input file name), and POSIX does not specify
29684         what pathconf does on a non-directory file anyway.  If PATH_MAX is
29685         not defined, do not worry about overriding a path_max of 0, and do
29686         not let path_max exceed IDX_MAX.
29687         (__realpath): Remove an assumption that file name components
29688         cannot exceed 1024 bytes when PATH_MAX is not defined (wrong for
29689         the Hurd, presumably).
29690         When allocating the result, allocate it to just the right size;
29691         this costs nothing when the result is smaller than 1023 bytes,
29692         and for larger results it's probably worth the CPU to call realloc,
29693         as canonicalize.c already does.
29694         * lib/canonicalize.c: Include attribute.h.
29695         Do not include pathmax.h or xgetcwd.h.
29696         (PATH_MAX): Do not define, so file names longer than 8192 bytes
29697         work on platforms with no fixed limit.
29698         (canonicalize_filename_mode_stk): New function, with
29699         the content of the old canonicalize_filename_mode.
29700         Use getcwd instead of xgetcwd, and readlink instead of areadlink,
29701         since the scratch buffers now do memory management for us.
29702         Use rawmemchr instead of adding strlen.
29703         Use mempcpy instead of mempcpy + size.
29704         Assume free preserves errno.
29705         (canonicalize_filename_mode): Use it.
29706         * modules/canonicalize (Depends-on): Remove areadlink, pathmax,
29707         xgetcwd.  Add attribute, free, getcwd, mempcpy, rawmemchr,
29708         scratch_buffer, stdbool, xalloc-die.
29709         * modules/canonicalize-lgpl (Depends-on): Remove alloca-opt,
29710         malloca, realloc-posix.  Add scratch_buffer, stdbool.
29712         canonicalize-lgpl: simplify merge to glibc
29713         This patch lessens the differences between git glibc
29714         stdlib/canonicalize.c and lib/canonicalize-lgpl.c.
29715         The (perhaps wishful) goal is to make them identical.
29716         * lib/canonicalize-lgpl.c [!_LIBC]:
29717         Include <libc-config.h>, not config.h.
29718         Omit an unnecessary (!HAVE_CANONICALIZE_FILE_NAME ||
29719         !FUNC_REALPATH_WORKS || defined _LIBC) #if.
29720         Do not include alloca.h, since we use malloca now.
29721         [_LIBC]: Include <eloop-threshold.h>, and define dummy macros
29722         FILE_SYSTEM_PREFIX_LEN, IS_ABSOLUTE_FILE_NAME, ISSLASH, malloca,
29723         freea so that the mainline code can be kept #ifdef free.
29724         [!_LIBC]: Remove dummy macros for SHLIB_COMPAT, versioned_symbol,
29725         compat_symbol, weak_alias, __set_errno since libc-config.h does that.
29726         Add redirecting macros __mempcpy, __pathconf, __rawmemchr,
29727         __eloop_threshold.  All uses of their definiens changed.
29728         (SIZE_MAX): Remove; no longer needed.
29729         (alloc_failed): Remove, and remove all instances.
29730         No need for alloc_failed now that free preserves errno.
29731         (__realpath): Default path_max to 1024 instead of 8192, as that’s
29732         the glibc tradition and is safer when the 2nd argument is null.
29733         Use __rawmemchr instead of strchr.
29734         Use __mempcpy where appropriate.
29735         Simplify test for overflow so that it does not need SIZE_MAX.
29736         Do not preserve errno around free or freea calls; no longer needed.
29737         Mark __realpath with libc_hidden_def.
29738         * modules/canonicalize-lgpl (Depends-on): Add free, libc-config,
29739         malloc-posix, mempcpy, realloc-posix, rawmemchr.
29740         * modules/free: Now LGPLv2+, for canonicalize-lgpl.
29742         free: preserve errno
29743         * lib/free.c (rpl_free): Preserve errno.  Check for null only if
29744         CANNOT_FREE_NULL is defined, as an optimization for POSIX 2008
29745         platforms that do not preserve errno.
29746         * m4/free.m4 (gl_FUNC_FREE): Check whether free preserves errno.
29747         Also, define CANNOT_FREE_NULL if free cannot free NULL.
29748         * modules/free (configure.ac): Also replace 'free' if
29749         it does not preserve errno.
29751         idx: simplify IDX_MAX, remove IDX_WIDTH
29752         * lib/idx.h (IDX_MAX): Simplify by removing obsolete reference
29753         to UNSIGNED_IDX_T.
29754         (IDX_WIDTH): Remove, since it’s not used and its value
29755         arguably should be PTRDIFF_WIDTH anyway.
29757 2020-12-16  Bruno Haible  <bruno@clisp.org>
29759         posix_spawn_file_actions_addfchdir-tests: Rename test.
29760         * tests/test-posix_spawn-fchdir.c: Renamed from
29761         tests/test-posix_spawn5.c.
29762         * modules/posix_spawn_file_actions_addfchdir-tests (Files, Makefile.am):
29763         Update.
29765         posix_spawn_file_actions_addchdir-tests: Rename test.
29766         * tests/test-posix_spawn-chdir.c: Renamed from
29767         tests/test-posix_spawn4.c.
29768         * modules/posix_spawn_file_actions_addchdir-tests (Files, Makefile.am):
29769         Update.
29771         posix_spawn-tests: Rename test.
29772         * tests/test-posix_spawn-open1.c: Renamed from
29773         tests/test-posix_spawn3.c.
29774         * modules/posix_spawn-tests (Files, Makefile.am): Update.
29776         posix_spawnp-tests: Rename test.
29777         * tests/test-posix_spawn-dup2-stdin.c: Renamed from
29778         tests/test-posix_spawn2.c.
29779         * tests/test-posix_spawn-dup2-stdin.in.sh: Renamed from
29780         tests/test-posix_spawn2.in.sh.
29781         * modules/posix_spawnp-tests (Files, Makefile.am): Update.
29783         posix_spawnp-tests: Rename test.
29784         * tests/test-posix_spawn-dup2-stdout.c: Renamed from
29785         tests/test-posix_spawn1.c.
29786         * tests/test-posix_spawn-dup2-stdout.in.sh: Renamed from
29787         tests/test-posix_spawn1.in.sh.
29788         * modules/posix_spawnp-tests (Files, Makefile.am): Update.
29790 2020-12-14  Bruno Haible  <bruno@clisp.org>
29792         findprog-in: Allow overriding the current directory.
29793         * lib/findprog.h (find_in_given_path): Add directory argument.
29794         * lib/findprog-in.c (find_in_given_path): Likewise.
29795         * lib/execute.c (execute): Update caller.
29796         * lib/spawn-pipe.c (create_pipe): Likewise.
29797         * lib/windows-spawn.c (spawnpvech): Likewise.
29798         * NEWS: Mention the change.
29800 2020-12-14  Bruno Haible  <bruno@clisp.org>
29802         posix_spawn-internal: Make better use of 'const'.
29803         * lib/spawn_int.h (__spawni): Does not need write access to the elements
29804         of argv and envp.
29805         * lib/spawni.c (__spawni, script_execute): Likewise.
29806         * lib/spawn.c (posix_spawn): Update caller.
29807         * lib/spawnp.c (posix_spawnp): Likewise.
29809 2020-12-14  Bruno Haible  <bruno@clisp.org>
29811         spawn: Make it compile on native Windows.
29812         * modules/spawn (Depends-on): Add signal-h.
29814 2020-12-14  Bruno Haible  <bruno@clisp.org>
29816         windows-spawn: Avoid shadowing a variable.
29817         * lib/windows-spawn.c (spawnpvech): Rename local variable 'flags'.
29819 2020-12-13  Paul Eggert  <eggert@cs.ucla.edu>
29821         string: port memchr macro to AIX 7.2 XLC
29822         Its <string.h> defines a memchr macro to help inlining.
29823         * lib/string.in.h (memchr): #undef before #defining.
29825         canonicalize: fix AIX test failures
29826         Problem reported by Bruno Haible in:
29827         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00109.html
29828         * lib/canonicalize.c (canonicalize_filename_mode):
29829         When testing a file name ending in '/', use stat rather than
29830         readlink, so that it does the right thing on AIX.
29831         * modules/canonicalize (Depends-on): Add readlink, to pull in the
29832         recent changes in the Gnulib readlink module.
29834         Assume readlink/readlinkat ERANGE fix
29835         * lib/areadlink-with-size.c (areadlink_with_size):
29836         * lib/areadlinkat-with-size.c (areadlinkat_with_size):
29837         * lib/careadlinkat.c (readlink_stk):
29838         Do not worry about readlink or readlinkat failing with errno == ERANGE,
29839         since the Gnulib readlink and readlinkat modules now fix that.
29841         getcwd: port to AIX
29842         * lib/getcwd.c [!_LIBC]: Undef stat64 before #defining it,
29843         in case our sys/stat.h #defined a function macro with the same name.
29845         readlink, readlinkat: add ERANGE portability
29846         Fix some portability issues with Gnulib's readlink and readlinkat,
29847         notably mostly working around the ERANGE problem in AIX and HP-UX.
29848         * doc/posix-functions/readlink.texi:
29849         * doc/posix-functions/readlinkat.texi:
29850         ERANGE problem is mostly fixed now.  Mention AIX problem with
29851         trailing / and EINVAL.  Lessen differences between these two files.
29852         * lib/readlink.c (rpl_readlink):
29853         * lib/readlinkat.c (rpl_readlinkat):
29854         If stat ("FILE/", ...) reports EOVERFLOW, treat FILE/ as an
29855         existing directory.  Mostly work around READLINK_TRUNCATE BUG.
29856         Lessen spurious differences between the readlink and readlinkat code.
29857         * lib/readlinkat.c (rpl_readlinkat):
29858         Fix bug where stat was used where fstatat was intended.
29859         * m4/readlink.m4 (gl_FUNC_READLINK):
29860         Rename gl_cv_func_readlink_works to gl_cv_func_readlink_trailing_slash
29861         to identify readlink problems more precisely.  All uses changed.
29862         Guess no on AIX or HP-UX for this variable.
29863         Add check for whether readlink truncates results,
29864         and define new macro READLINK_TRUCATE_BUG accordingly.
29865         * m4/readlinkat.m4 (gl_FUNC_READLINKAT):
29866         Also check gl_cv_func_readlink_trailing_slash when deciding
29867         whether to replace readlinkat.
29868         * modules/readlinkat (Depends-on): Most dependencies are also
29869         needed if replacing readlinkat.  fstatat is different, as it
29870         is needed only if replacing an existing readlinkat.
29872 2020-12-13  Bruno Haible  <bruno@clisp.org>
29874         spawn-pipe: Fix hanging processes on Windows (regression 2020-11-30).
29875         * lib/spawn-pipe.c (create_pipe): After spawning the subprocess, close
29876         the stdin_handle and/or stdout_handle.
29878 2020-12-12  Bruno Haible  <bruno@clisp.org>
29880         Fix gnulib-tool error when some modules occur in tests/.
29881         * doc/gnulib.texi (Specification): Update statistics.
29882         (Autoconf macros): Don't suggest to use AC_LIBOBJ in a .m4 file.
29883         (Using AC_LIBOBJ): New section.
29884         * check-AC_LIBOBJ: New file.
29885         * modules/fnmatch-gnu (Files): Add lib/fnmatch.c.
29886         * modules/fopen-gnu (Files): Add lib/fopen.c.
29887         * modules/memmem (Files): Add lib/memmem.c.
29888         * modules/renameat (Files): Add lib/at-func2.c.
29889         * modules/strcasestr (Files): Add lib/strcasestr.c.
29890         * modules/strstr (Files): Add lib/strstr.c.
29892 2020-12-11  Bruno Haible  <bruno@clisp.org>
29894         sh-quote, execute, spawn-pipe, etc.: Make better use of 'const'.
29895         * lib/sh-quote.h (shell_quote_argv): Does not need write access to the
29896         elements of argv.
29897         * lib/sh-quote.c (shell_quote_argv): Likewise.
29898         * lib/windows-spawn.h (prepare_spawn): Add 'const' the argument type and
29899         the return type.
29900         * lib/windows-spawn.c (prepare_spawn): Likewise.
29901         * lib/os2-spawn.h (prepare_spawn): Likewise.
29902         * lib/os2-spawn.c (prepare_spawn): Likewise.
29903         * lib/execute.h (execute): Does not need write access to the elements of
29904         prog_argv.
29905         * lib/execute.c (execute): Likewise.
29906         * lib/spawn-pipe.h (create_pipe_out, create_pipe_in, create_pipe_bidi):
29907         Likewise.
29908         * lib/spawn-pipe.c (create_pipe, create_pipe_bidi, create_pipe_in,
29909         create_pipe_out): Likewise.
29910         * lib/pipe-filter.h (pipe_filter_ii_execute, pipe_filter_gi_create):
29911         Likewise.
29912         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Likewise.
29913         * lib/pipe-filter-gi.c (pipe_filter_gi_create): Likewise.
29914         * lib/javaexec.h (execute_fn): Does not need write access to the
29915         elements of prog_argv.
29916         * lib/javaexec.c (execute_java_class): Update variable types and remove
29917         casts to 'char *'.
29918         * lib/csharpexec.h (execute_fn): Does not need write access to the
29919         elements of prog_argv.
29920         * lib/csharpexec.c (execute_csharp_using_mono,
29921         execute_csharp_using_sscli): Update variable types and remove casts to
29922         'char *'.
29923         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
29924         compile_using_javac, compile_using_jikes, is_envjavac_gcj,
29925         is_envjavac_gcj43, is_gcj_present, is_gcj_43, is_javac_present,
29926         is_jikes_present): Update variable types and remove casts to 'char *'.
29927         * lib/javaversion.c (execute_and_read_line): Does not need write access
29928         to the elements of prog_argv.
29929         * lib/csharpcomp.c (compile_csharp_using_mono,
29930         compile_csharp_using_sscli): Update variable types and remove casts to
29931         'char *'.
29932         * tests/test-sh-quote.c (main): Update variable types and remove casts
29933         to 'char *'.
29934         * tests/test-execute-main.c (main): Update variable types and remove
29935         casts to 'char *'.
29936         * tests/test-spawn-pipe-main.c (test_pipe): Update variable types and
29937         remove casts to 'char *'.
29938         * NEWS: Mention the changes.
29940 2020-12-11  Bruno Haible  <bruno@clisp.org>
29942         execute-tests: Fix compilation error with MSVC.
29943         * tests/test-execute-child.c (is_device): With _fstat, use
29944         'struct _stat', not 'struct stat'.
29946 2020-12-11  Paul Eggert  <eggert@cs.ucla.edu>
29948         vararrays: just use 2.70
29949         * m4/vararrays.m4 (AC_C_VARARRAYS): Do not override Autoconf 2.70
29950         and later, since Autoconf 2.70 matches Gnulib now.
29952         sys_types: just use 2.70
29953         * m4/sys_types_h.m4 (AC_HEADER_MAJOR):
29954         Reindent to match Autoconf sources.
29955         Use Autoconf 2.70 as a prerequisite, not 2.69c.
29957         stdint: port to Autoconf 2.70
29958         * m4/stdint.m4 (gl_STDINT_H): Check for inttypes.h and sys/types.h
29959         instead of assuming that AC_INCLUDES_DEFAULT does it.
29960         The old code relied on AC_INCLUDES_DEFAULT being called
29961         and setting ac_cv_header_inttypes_h and ac_cv_header_sys_types_h,
29962         but this does not occur in Autoconf 2.70.
29964         pid_t.m4: just use 2.70
29965         * m4/pid_t.m4 (AC_TYPE_PID_T):
29966         Use Autoconf 2.70 as a prerequisite, not 2.69c.
29968         largefile: just use 2.70
29969         * m4/largefile.m4 (_AC_SYS_LARGEFILE_TEST_INCLUDES):
29970         Use Autoconf 2.70 as a prerequisite, not 2.69c.
29972         AC_C_RESTRICT: update from Autoconf
29973         * m4/gnulib-common.m4 (gl_PROG_CC_C99): Use Autoconf 2.70
29974         as a prerequisite, not 2.69c, since 2.70 is now out.
29975         (AC_C_RESTRICT): Define only for 2.70 or earlier.
29976         Try __restrict__ before __restrict.
29978         extensions: update from Autoconf
29979         * m4/extensions.m4 (AC_CHECK_INCLUDES_DEFAULT):
29980         Provide a default implementation for Autoconf 2.69 or earlier.
29981         (AC_USE_SYSTEM_EXTENSIONS): Copy from Autoconf git.  Define only
29982         if Autoconf 2.70 or earlier, since 2.70.1 or later should be OK.
29984         alloca: update from Autoconf
29985         * m4/alloca.m4 (gl_PREREQ_ALLOCA):
29986         Trivial update to match Autoconf 2.70.
29988 2020-12-11  Bruno Haible  <bruno@clisp.org>
29990         memchr: Work around memory overrun bug on AIX 7.2.
29991         * m4/memchr.m4 (gl_FUNC_MEMCHR): Test against AIX 7.2 bug.
29992         * doc/posix-functions/memchr.texi: Mention the AIX bug.
29994 2020-12-11  Bruno Haible  <bruno@clisp.org>
29996         execute-tests: Fix compilation error on AIX in 32-bit mode.
29997         * tests/test-execute-child.c: In order to get the original definition of
29998         fstat, don't use '#undef fstat' and '#undef stat'. Instead, arrange to
29999         include the system's <sys/stat.h> and use it before including other
30000         header files.
30002 2020-12-10  Bruno Haible  <bruno@clisp.org>
30004         windows-spawn: Relicense under LGPLv2+.
30005         * modules/windows-spawn (License): Change to LGPLv2+.
30007 2020-12-10  Bruno Haible  <bruno@clisp.org>
30009         execute, spawn-pipe: Fix memory leak on native Windows.
30010         * lib/windows-spawn.h (prepare_spawn): Add a second parameter.
30011         * lib/windows-spawn.c: Don't include xalloc.h.
30012         (quoted_arg_length, quoted_arg_string): New functions, extracted from
30013         prepare_spawn.
30014         (prepare_spawn): Use malloc instead of XNMALLOC. Allocate memory for all
30015         elements of *new_argv together.
30016         * modules/windows-spawn (Depends-on): Remove xalloc. Add malloc-posix.
30017         * lib/os2-spawn.h (prepare_spawn): Add a second parameter.
30018         * lib/os2-spawn.c: Don't include xalloc.h.
30019         (prepare_spawn): Use malloc instead of XNMALLOC. Allocate memory for all
30020         elements of *new_argv together.
30021         * lib/execute.c: Include xalloc.h.
30022         (execute): Check return value of prepare_spawn. Free the memory
30023         allocated by prepare_spawn.
30024         * modules/execute (Depends-on): Add xalloc-die.
30025         * lib/spawn-pipe.c: Include xalloc.h.
30026         (create_pipe): Check return value of prepare_spawn. Free the memory
30027         allocated by prepare_spawn.
30028         * modules/spawn-pipe (Depends-on): Add xalloc-die.
30030 2020-12-10  Bruno Haible  <bruno@clisp.org>
30032         findprog-in: Relicense under LGPLv2+.
30033         Paul Smith's approval is in
30034         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00072.html>.
30035         * modules/findprog-in (License): Change to LGPLv2+.
30037 2020-12-10  Bruno Haible  <bruno@clisp.org>
30039         findprog-in: Don't exit upon out-of-memory.
30040         * lib/findprog.h (find_in_given_path): Document ENOMEM as possible error
30041         code.
30042         * lib/findprog-in.c: Don't include xalloc.h.
30043         (find_in_given_path): Call concatenated_filename, not
30044         xconcatenated_filename. Call strdup, not xstrdup. Upon out-of-memory,
30045         return NULL with errno set.
30046         * modules/findprog-in (Depends-on): Remove xconcat-filename, xalloc. Add
30047         concat-filename, strdup-posix, malloc-posix.
30049 2020-12-09  Bruno Haible  <bruno@clisp.org>
30051         fmaf: Work around a bug on FreeBSD 12.2/arm.
30052         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Add one more test.
30053         * doc/posix-functions/fmaf.texi: Mention the FreeBSD bug.
30055 2020-12-09  Bruno Haible  <bruno@clisp.org>
30057         threadlib: Fix test-fstrcmp failure on FreeBSD 11.
30058         * m4/threadlib.m4 (gl_THREADLIB_BODY): When weak symbols are not present
30059         on FreeBSD, define PTHREAD_IN_USE_DETECTION_HARD.
30060         * lib/glthread/threadlib.c: Include <errno.h>.
30061         (glthread_in_use): For FreeBSD, provide an alternative implementation
30062         that uses pthread_key_create.
30064 2020-12-09  Bruno Haible  <bruno@clisp.org>
30066         math C++ tests: Fix compilation error in with clang >= 7 on FreeBSD.
30067         * lib/math.in.h (isnan): For clang >= 7 on FreeBSD, declare 'rpl_isnan',
30068         not 'isnan'.
30070 2020-12-08  Bruno Haible  <bruno@clisp.org>
30072         std-gnu11: Make compatible with Autoconf 2.70.
30073         * m4/std-gnu11.m4: Disable the entire file if Autoconf >= 2.70 is in
30074         use.
30076 2020-12-08  Bruno Haible  <bruno@clisp.org>
30078         argp: Avoid undefined behaviour when invoking qsort().
30079         This fixes a test-argp-2.sh test failure on macOS and FreeBSD.
30080         Reported by Jeffrey Walton <noloader@gmail.com> in
30081         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00085.html>.
30082         * lib/argp-help.c (group_cmp): Remove third argument.
30083         (hol_sibling_cluster_cmp, hol_cousin_cluster_cmp): New functions, based
30084         upon hol_cluster_cmp.
30085         (hol_cluster_cmp): Use hol_cousin_cluster_cmp.
30086         (hol_entry_cmp): Rewritten to implement a total order.
30088 2020-12-08  Bruno Haible  <bruno@clisp.org>
30090         argp: Improve comments.
30091         * lib/argp-help.c: Add sectioning comments. Write NULL to designate a
30092         null pointer.
30093         (struct hol_entry): Fix comment regarding sort order of group.
30094         (hol_entry_short_iterate, hol_entry_long_iterate): Add comment.
30095         (until_short, canon_doc_option, hol_entry_qcmp): Improve comment.
30096         (hol_cluster_is_child, argp_hol): Move functions.
30097         (HOL_ENTRY_PTRCMP): Remove unused macro.
30099 2020-12-08  Bruno Haible  <bruno@clisp.org>
30101         argp: Don't pass invalid arguments to isspace() and isalnum().
30102         * lib/argp-help.c (canon_doc_option): Cast character to 'unsigned int'
30103         before passing it to isspace() or isalnum().
30105 2020-12-08  Bruno Haible  <bruno@clisp.org>
30107         argp: Don't rely on undefined behaviour of _tolower().
30108         Patch by Eric Blake
30109         <https://lists.gnu.org/archive/html/bug-gnulib/2009-09/msg00287.html>.
30110         * lib/argp-help.c (hol_entry_cmp): Don't use _tolower on values that are
30111         not upper-case.  Pass correct range to tolower.
30113 2020-12-07  Bruno Haible  <bruno@clisp.org>
30115         unicodeio: Fix wrong result on FreeBSD.
30116         * lib/unicodeio.c (unicode_to_mb): Handle question mark fallback
30117         characters on all platforms.
30119 2020-12-07  Bruno Haible  <bruno@clisp.org>
30121         get-rusage-data tests: Avoid test failure on FreeBSD/x86_64.
30122         * tests/test-get-rusage-data.c (main): Don't expect a strict increase on
30123         FreeBSD systems.
30125 2020-12-07  Bruno Haible  <bruno@clisp.org>
30127         get-rusage-data: Fix link error on FreeBSD 12.2/arm64.
30128         * modules/get-rusage-data (configure.ac): Test whether sbrk exists.
30129         * lib/get-rusage-data.c (get_rusage_data_via_setrlimit): Define
30130         trivially of sbrk is not available.
30131         * doc/glibc-functions/sbrk.texi: Mention that the function does not
30132         exist in FreeBSD 12.2/arm64.
30133         * doc/glibc-functions/brk.texi: Likewise.
30135 2020-12-07  Bruno Haible  <bruno@clisp.org>
30137         Correct interaction between gl_ANSI_CXX and AC_PROG_CXX.
30138         Suggested by Zack Weinberg in
30139         <https://savannah.gnu.org/support/?110294>.
30140         * m4/ansi-c++.m4 (gl_ANSI_CXX): Mark AC_PROG_CXX as provided.
30141         * modules/uchar-c++-tests: Revert the workaround from 2020-08-18.
30143 2020-12-07  Bruno Haible  <bruno@clisp.org>
30145         Tweak the Windows oldnames workaround.
30146         Reported by Daniel R. Hurtmans <Daniel.Hurtmans@ulb.ac.be> in
30147         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00073.html>.
30148         * lib/unistd.in.h: On native Windows, include <io.h> and <direct.h>
30149         always.
30150         (getcwd): Use _GL_CXXALIAS_MDA_CAST.
30151         * lib/stdlib.in.h (putenv): Likewise.
30153 2020-12-06  Paul Eggert  <eggert@cs.ucla.edu>
30155         doc: fix flat address space discussion
30156         * doc/gnulib-readme.texi (Other portability assumptions):
30157         Move the all-bits-zero assumption outside the flat address space
30158         section, since the two issues are independent.
30160         doc: document -static-libubsan more
30161         * doc/gnulib-readme.texi (High Quality): Document pros and cons of
30162         -static-libubsan a bit more.  Mostly cons.
30164 2020-12-06  Bruno Haible  <bruno@clisp.org>
30166         doc: Add more details regarding the undefined behaviour sanitizer.
30167         * doc/gnulib-readme.texi (High Quality): Describe
30168         -fsanitize-undefined-trap-on-error better.
30170 2020-12-06  Bruno Haible  <bruno@clisp.org>
30172         Do the Windows oldnames workaround through the C++ GNULIB_NAMESPACE.
30173         Reported by Daniel R. Hurtmans <Daniel.Hurtmans@ulb.ac.be> in
30174         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00029.html>.
30175         * lib/c++defs.h (_GL_CXXALIAS_MDA_CAST): New macro.
30176         * lib/fcntl.in.h (creat, open):  In C++ mode, when GNULIB_NAMESPACE is
30177         defined: 1. Define a symbol in this namespace. 2. Don't redirect using
30178         a preprocessor #define.
30179         * lib/math.in.h (j0, j1, jn, y0, y1, yn): Likewise.
30180         * lib/search.in.h (lfind, lsearch): Likewise.
30181         * lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
30182         Likewise.
30183         * lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
30184         * lib/string.in.h (memccpy, strdup): Likewise.
30185         * lib/sys_stat.in.h (chmod, umask): Likewise.
30186         * lib/time.in.h (tzset): Likewise.
30187         * lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
30188         execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
30189         read, rmdir, swab, unlink, write): Likewise.
30190         * lib/utime.in.h (utime): Likewise.
30191         * lib/wchar.in.h (wcsdup): Likewise.
30192         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_FCLOSEALL.
30193         (gl_STDIO_H): Set HAVE_DECL_FCLOSEALL.
30194         * modules/stdio (Makefile.am): Substitute HAVE_DECL_FCLOSEALL.
30195         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_ECVT,
30196         HAVE_DECL_FCVT, HAVE_DECL_GCVT.
30197         (gl_STDLIB_H): Set HAVE_DECL_ECVT, HAVE_DECL_FCVT, HAVE_DECL_GCVT.
30198         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_ECVT,
30199         HAVE_DECL_FCVT, HAVE_DECL_GCVT.
30200         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_EXECVPE.
30201         (gl_UNISTD_H): Set HAVE_DECL_EXECVPE.
30202         * modules/unistd (Makefile.am): Substitute HAVE_DECL_EXECVPE.
30203         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize HAVE_DECL_WCSDUP.
30204         (gl_WCHAR_H): Set HAVE_DECL_WCSDUP.
30205         * modules/wchar (Makefile.am): Substitute HAVE_DECL_WCSDUP.
30207 2020-12-06  Bruno Haible  <bruno@clisp.org>
30209         doc: Mention some missing function declarations.
30210         * doc/glibc-functions/execvpe.texi: Mention the missing declaration on
30211         AIX.
30212         * doc/glibc-functions/fcloseall.texi: Mention the missing declaration on
30213         FreeBSD.
30214         * doc/pastposix-functions/ecvt.texi: Mention the missing declaration on
30215         Cygwin.
30216         * doc/pastposix-functions/fcvt.texi: Likewise.
30217         * doc/pastposix-functions/gcvt.texi: Likewise.
30219 2020-12-06  Bruno Haible  <bruno@clisp.org>
30221         doc: Tweak example.
30222         * doc/intprops.texi (Checking Integer Overflow): Use 'printf', not
30223         'print'.
30225 2020-12-06  Bruno Haible  <bruno@clisp.org>
30227         filenamecat-tests: Use idx_t for nonnegative ptrdiff_t variables.
30228         * tests/test-filenamecat.c: Include idx.h.
30229         (main): Mark prefixlen as nonnegative.
30230         * modules/filenamecat-tests (Depends-on): Add idx.
30232 2020-12-06  Bruno Haible  <bruno@clisp.org>
30234         time_rz: Use idx_t for nonnegative ptrdiff_t variables.
30235         * lib/time_rz.c: Include idx.h.
30236         (save_abbr): Mark zone_size as nonnegative.
30237         * modules/time_rz (Depends-on): Add idx.
30239 2020-12-06  Bruno Haible  <bruno@clisp.org>
30241         parse-datetime: Use idx_t for nonnegative ptrdiff_t variables.
30242         * lib/parse-datetime.y: Include idx.h.
30243         (textint): Mark digits as nonnegative.
30244         (parser_control): Mark dates_seen, days_seen, local_zones_seen,
30245         dsts_seen, times_seen, zones_seen as nonnegative.
30246         (lookup_word): Mark wordlen as nonnegative.
30247         (yylex): Mark count as nonnegative.
30248         (parse_datetime2): Mark tzsize as nonnegative.
30249         * modules/parse-datetime (Depends-on): Add idx.
30251 2020-12-06  Bruno Haible  <bruno@clisp.org>
30253         fnmatch: Use idx_t for nonnegative ptrdiff_t variables.
30254         * lib/fnmatch.c: Include idx.h. In glibc, define idx_t directly.
30255         * lib/fnmatch_loop.c (EXT): Mark slen, new_used, plensize as
30256         nonnegative.
30257         * modules/fnmatch (Depends-on): Add idx.
30259 2020-12-06  Bruno Haible  <bruno@clisp.org>
30261         c-stack: Use idx_t for nonnegative ptrdiff_t variables.
30262         * lib/c-stack.c: Include idx.h.
30263         (die): Mark buflen as nonnegative.
30264         * modules/c-stack (Depends-on): Add idx.
30266 2020-12-06  Bruno Haible  <bruno@clisp.org>
30268         backupfile: Use idx_t for nonnegative ptrdiff_t variables.
30269         * lib/backupfile.c: Include idx.h.
30270         (numbered_backup): Mark base_offset as nonnegative.
30271         (backupfile_internal): Likewise.
30272         * modules/backup-rename (Depends-on): Add idx.
30273         * modules/backupfile (Depends-on): Likewise.
30275 2020-12-05  Paul Eggert  <eggert@cs.ucla.edu>
30277         doc: fix curved quotes issue
30278         * doc/gnulib.texi: Set txicodequoteundirected and
30279         txicodequotebacktick so that ` and ' in examples do not generate
30280         curved single quotes that do the wrong thing when cut and pasted.
30282         doc: mention static and dynamic checking
30283         * doc/gnulib-readme.texi (High Quality): Add a bit of advice
30284         for static and dynamic checking.
30286         intprops: Add INT_ADD_OK etc.
30287         * doc/intprops.texi (Checking Integer Overflow): New section.
30288         * lib/intprops.h: From a suggestion by Bruno Haible in:
30289         https://lists.gnu.org/r/bug-gnulib/2020-12/msg00051.html
30290         (SAFE_INT_ADD, SAFE_INT_SUBTRACT, SAFE_INT_MULTIPLY): New macros.
30292         doc: move exotic platfroms to Target Platforms
30293         * doc/gnulib-intro.texi (Supported Platforms)
30294         (Formerly Supported Platforms, Unsupported Platforms):
30295         New subsections, split off from Target Platforms.
30296         (Unsupported Platforms): Move the exotic-platform stuff here ...
30297         * doc/gnulib-readme.texi (Exotic platforms): ... from this removed
30298         section.
30300         doc: mention intptr_t etc. and IBM i
30301         * doc/gnulib-readme.texi (Other portability assumptions):
30302         Mention intptr_t and uintptr_t, and that arithmetic on them
30303         works in the usual way.
30304         (Exotic platforms): New section, containing material from
30305         the old 'Integer Portability' section.  Also mention IBM i.
30306         * doc/intprops.texi (Wraparound Arithmetic):
30307         Say that the macros work on unsigned integers too.
30308         (Integer Portability): Remove.
30310 2020-12-04  Bruno Haible  <bruno@clisp.org>
30312         utime: Fix a test failure on macOS 10.13.
30313         Reported by Martin Storsjö <martin@martin.st> in
30314         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
30315         * m4/utime.m4 (gl_FUNC_UTIME): Test whether utime handles trailing
30316         slashes on files.
30317         * lib/utime.c (utime): Add alternative implementation for Unix
30318         platforms.
30319         * modules/utime (Depends-on): Add stat.
30320         * doc/posix-functions/utime.texi: Mention the macOS 10.13 bug.
30321         * doc/posix-functions/lstat.texi: Mention that macOS 10.13 also has the
30322         trailing-slash bug.
30323         * doc/posix-functions/open.texi: Likewise.
30324         * doc/posix-functions/stat.texi: Likewise.
30325         * doc/posix-functions/symlink.texi: Likewise.
30327 2020-12-04  Paul Eggert  <eggert@cs.ucla.edu>
30329         intprops: update doc and mention Unisys
30330         * doc/gnulib-readme.texi (Other portability assumptions):
30331         Also mention ptrdiff_t when talking about widths and overflow.
30332         * doc/intprops.texi (Integer Properties): Summarize new section.
30333         (Arithmetic Type Properties): Document that EXPR_SIGNED no longer
30334         evaluates its argument.
30335         (Integer Bounds): Fix typo.
30336         (Wraparound Arithmetic): Remove obsolete comment about efficiency.
30337         Document that the _WRAPV macros now support pointers to unsigned
30338         integers.
30339         (Integer Range Overflow): Update SEI CERT citation.
30340         (Integer Portability): New subsection, which mentions
30341         the oddball Unisys platforms as non-Gnulib targets.
30343 2020-12-03  Bruno Haible  <bruno@clisp.org>
30345         idx: Clarify that idx_t always behaves like a signed type.
30346         Suggested by Paul Eggert in
30347         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00034.html>.
30348         * lib/idx.h: Clarify that idx_t always behaves like a signed type.
30349         Don't test UNSIGNED_IDX_T.
30351 2020-12-03  Bruno Haible  <bruno@clisp.org>
30353         idx: New module.
30354         * lib/idx.h: New file.
30355         * modules/idx: New file.
30356         * lib/canonicalize-lgpl.c: Include idx.h. Use idx_t instead of
30357         ptrdiff_t.
30358         * lib/canonicalize.c: Likewise.
30359         * modules/canonicalize-lgpl (Depends-on): Add idx.
30360         * modules/canonicalize (Depends-on): Likewise.
30362 2020-12-03  Bruno Haible  <bruno@clisp.org>
30364         fprintf-posix-tests: Avoid a test failure on macOS 10.13.
30365         Reported by Martin Storsjö <martin@martin.st> in
30366         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
30367         * tests/test-fprintf-posix3.c: Skip the test on macOS.
30368         (main): Return a different exit code at each point. Allow 100 KB extra
30369         memory consumption.
30370         * tests/test-fprintf-posix3.sh: Update. Remove the "get_rusage_as()
30371         doesn't work" diagnostic.
30373 2020-12-02  Paul Eggert  <eggert@cs.ucla.edu>
30375         canonicalize: refactor can_mode flag
30376         * lib/canonicalize.c (MULTIPLE_BITS_SET): Remove, replacing with ...
30377         (multiple_bits_set): ... this new static function.  Uses changed.
30378         (canonicalize_filename_mode): Refactor for clarity to avoid
30379         modifying the CAN_MODE argument.
30381         canonicalize: prefer signed integer types
30382         * lib/canonicalize.c: Include stddef.h, for ptrdiff_t.
30383         (seen_triple, canonicalize_filename_mode): Prefer signed to
30384         unsigned types where either will do, as they avoid some glitches
30385         in comparisons and can trap on overflow when debugging.
30387         canonicalize: fix most of another EOVERFLOW issue
30388         * lib/canonicalize.c (canonicalize_filename_mode):
30389         Do not call stat if fewer than 20 symlinks have been traversed.
30390         This avoids EOVERFLOW failure in the common case where there
30391         are not that many symlinks, while continuing to catch loops
30392         (or fail due to EOVERFLOW) in the unusual case when there
30393         are many symlinks to traverse.
30395         canonicalize: do not assume symlinks have st_ino
30396         * lib/canonicalize.c (canonicalize_filename_mode):
30397         When checking for loops, use st_dev and st_ino from the parent
30398         directory not from the symlink, as pre-2017 POSIX says these
30399         members are not reliable for symlinks.  Couple this with START
30400         (the remaining file name to be resolved), not NAME (the whole file
30401         name with START as its suffix).
30402         * modules/canonicalize (Depends-on): Depend on stat, not lstat.
30404         canonicalize: fix EOVERFLOW bug
30405         * lib/canonicalize.c (canonicalize_filename_mode):
30406         When testing whether a directory entry is a symbolic link, or a
30407         directory or other, do not use lstat or stat or
30408         areadlink_with_size.  Just use areadlink, as this suffices and it
30409         avoids the EOVERFLOW problem that lstat and stat have.
30410         * modules/canonicalize (Depends-on): Depend on areadlink instead
30411         of areadlink-with-size and stat.
30413         canonicalize-lgpl: fix EOVERFLOW bug
30414         * lib/canonicalize-lgpl.c: Do not include <sys/stat.h>.
30415         (__realpath): Do not use lstat.  Just use readlink, as this
30416         suffices and it avoids the EOVERFLOW problem that lstat has.
30417         * modules/canonicalize-lgpl (Depends-on): Remove lstat, sys_stat.
30419 2020-12-02  Bruno Haible  <bruno@clisp.org>
30421         strsignal-tests: Fix test failure on macOS 10.13.
30422         Reported by Martin Storsjö <martin@martin.st> in
30423         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
30424         * tests/test-strsignal.c (ASSERT_DESCRIPTION): Allow the actual result
30425         to be longer than the expected result.
30427 2020-12-02  Bruno Haible  <bruno@clisp.org>
30429         Fix compilation errors in test-math-c++.cc on FreeBSD 12.2/arm64.
30430         * lib/math.in.h (_GL_INCLUDING_MATH_H): New macro, to work around
30431         recursive self-include problem on FreeBSD 12.2 in C++ mode.
30433 2020-12-02  Bruno Haible  <bruno@clisp.org>
30435         spawn-pipe: Allow caller to specify directory for the subprocess.
30436         * lib/spawn-pipe.h (create_pipe_out, create_pipe_in, create_pipe_bidi):
30437         Add directory argument.
30438         * lib/spawn-pipe.c: Include canonicalize.h, filename.h, findprog.h.
30439         (create_pipe): Add directory argument. If specified, resolve the program
30440         file name and make it absolute, first. Pass the directory to spawnpvech
30441         and posix_spawn_file_actions_addchdir.
30442         (create_pipe_bidi, create_pipe_in, create_pipe_out): Add directory
30443         argument.
30444         * modules/spawn-pipe (Depends-on): Add canonicalize, filename,
30445         findprog-in, posix_spawn, posix_spawn_file_actions_addchdir.
30446         * tests/test-spawn-pipe-main.c (test_pipe): Update.
30447         * NEWS: Mention the change.
30448         * lib/csharpcomp.c (compile_csharp_using_mono,
30449         compile_csharp_using_sscli): Update.
30450         * lib/javacomp.c (is_envjavac_gcj, is_envjavac_gcj43, is_gcj_present,
30451         is_gcj_43): Update.
30452         * lib/javaversion.c (execute_and_read_line): Update.
30453         * lib/pipe-filter-gi.c (pipe_filter_gi_create): Update.
30454         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Update.
30456 2020-12-02  Bruno Haible  <bruno@clisp.org>
30458         execute: Allow caller to specify directory for the subprocess.
30459         * lib/execute.h (execute): Add directory argument.
30460         * lib/execute.c: Include canonicalize.h, filename.h, findprog.h.
30461         (execute): Add directory argument. If specified, resolve the program
30462         file name and make it absolute, first. Pass the directory to spawnpvech
30463         and posix_spawn_file_actions_addchdir.
30464         * modules/execute (Depends-on): Add canonicalize, filename, findprog-in,
30465         posix_spawn, posix_spawn_file_actions_addchdir.
30466         * tests/test-execute-main.c: Add test for passing a directory.
30467         * tests/test-execute-child.c: Likewise.
30468         * tests/test-execute.sh: Update.
30469         * modules/execute-tests (Depends-on): Add mkdir.
30470         * NEWS: Mention the change.
30471         * lib/csharpcomp.c (compile_csharp_using_sscli): Update.
30472         * lib/csharpexec.c (execute_csharp_using_mono,
30473         execute_csharp_using_sscli): Update.
30474         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
30475         compile_using_javac, compile_using_jikes, is_javac_present,
30476         is_jikes_present): Update.
30477         * lib/javaexec.c (execute_java_class): Update.
30479 2020-12-01  Bruno Haible  <bruno@clisp.org>
30481         vma-iter: Add support for macOS11/arm64.
30482         Patch suggested by Hill Ma <maahiuzeon@gmail.com> in
30483         <https://gitlab.com/gnu-clisp/clisp/-/issues/27>
30484         and by Martin Storsjö <martin@martin.st> in
30485         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>.
30486         * lib/vma-iter.c (vma_iterate): On arm64, use 64-bit type definitions.
30488 2020-12-01  Bruno Haible  <bruno@clisp.org>
30490         spawn-pipe: Fix handling of OS/2 kLIBC.
30491         Reported by KO Myung-Hun <komh78@gmail.com> in
30492         <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00005.html>.
30493         * modules/spawn-pipe (configure.ac): Use the common idiom for
30494         recognizing the OS/2 operating system.
30496 2020-11-30  Bruno Haible  <bruno@clisp.org>
30498         execute: Fix uninitialized use of errno.
30499         * lib/execute.c (execute): Preserve errno across several system calls.
30501 2020-11-30  Bruno Haible  <bruno@clisp.org>
30503         access tests: Fix test failure on native Windows.
30504         * tests/test-access.c (main): Change permissions of f2 file before
30505         attempting to remove it.
30507 2020-11-30  Paul Eggert  <eggert@cs.ucla.edu>
30509         faccessat: link with $(LIB_EACCESS)
30510         * modules/faccessat (Link:): Add $(LIB_EACCESS), since this
30511         module depends on euidaccess.
30513 2020-11-30  Bruno Haible  <bruno@clisp.org>
30515         execute, spawn-pipe: Make multithread-safe on native Windows.
30516         * lib/windows-spawn.h: Include <stdint.h>, <windows.h>.
30517         (dup_safer_noinherit, undup_safer_noinherit): Remove declarations.
30518         (spawnpvech): New declaration.
30519         * lib/windows-spawn.c: Include <stdio.h>, <process.h>, findprog.h.
30520         Don't include <unistd.h>, cloexec.h, error.h, gettext.h.
30521         (_): Remove macro.
30522         (dup_noinherit, fd_safer_noinherit, dup_safer_noinherit,
30523         undup_safer_noinherit): Remove functions.
30524         (spawnpvech): New function.
30525         * modules/windows-spawn (Depends-on): Add findprog-in, stdint. Remove
30526         cloexec, dup2, error, gettext-h.
30527         * lib/execute.c: Include msvc-nothrow.h.
30528         (execute) [WIN32]: Use _get_osfhandle, spawnpvech instead of _spawnvpe.
30529         * lib/spawn-pipe.c: Include msvc-nothrow.h.
30530         (create_pipe) [WIN32]: Use _get_osfhandle, DuplicateHandle, spawnpvech
30531         instead of _spawnvpe.
30532         * modules/execute (Depends-on): Add msvc-nothrow.
30533         * modules/spawn-pipe (Depends-on): Likewise.
30535 2020-11-30  Bruno Haible  <bruno@clisp.org>
30537         execute, spawn-pipe: Improve documentation.
30538         * lib/execute.h: Describe progname, prog_path, prog_argv.
30539         * lib/spawn-pipe.h: Likewise.
30541 2020-11-30  Bruno Haible  <bruno@clisp.org>
30543         execute tests: Add more tests.
30544         * tests/test-execute-main.c: Add tests for reading, writing, isatty on
30545         inherited file descriptors >= 3.
30546         * tests/test-execute-child.c: Likewise.
30547         * tests/test-execute.sh: Update.
30549 2020-11-30  Bruno Haible  <bruno@clisp.org>
30551         havelib: Fix for non-ELF platforms (regression 2019-11-17).
30552         Reported by comex <comexk@gmail.com> in
30553         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00188.html>.
30554         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On non-ELF platforms,
30555         don't expect an ELF header.
30557 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
30559         bitset: use integer_length in table implementation
30560         * lib/bitset/table.c (tbitset_list_reverse): Use
30561         BITSET_FOR_EACH_BIT_REVERSE.
30563 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
30565         bitset: use integer_length in list implementation
30566         * lib/bitset/list.c (lbitset_list_reverse): Use
30567         BITSET_FOR_EACH_BIT_REVERSE.
30569 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
30571         bitset: use integer_length in vector implementation
30572         * lib/bitset/array.c (vbitset_list_reverse): Use
30573         BITSET_FOR_EACH_BIT_REVERSE.
30575 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
30577         bitset: use integer_length in array implementation
30578         * modules/bitset (Depends-on): Add integer_length_l.
30579         * lib/bitset/base.h (bitset_fls_, BITSET_FOR_EACH_BIT_REVERSE): New.
30580         * lib/bitset/array.c (abitset_list_reverse): Use it.
30582 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
30584         bitset: style: use consistent names
30585         * bitset/list.c (lbitset_list_reverse): Rename 'bcount' as 'bitcnt',
30586         and 'boffset' as 'bitoff', for consistency with the other
30587         implementations.
30588         * bitset/table.c (tbitset_list_reverse): Likewise.
30590 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
30592         bitset: style: sort header
30593         * lib/bitset/base.h (bitset_ffs): Rename as...
30594         (bitset_ffs_): this.
30595         (bitset_ffs_, BITSET_FOR_EACH_BIT): Move to better places.
30597 2020-11-29  Akim Demaille  <akim@lrde.epita.fr>
30599         bitset: tests: check BITSET_FOR_EACH_REVERSE
30600         * tests/test-bitset.c (compare, check_zero, check_one_bit, check_ones):
30601         Check BITSET_FOR_EACH_REVERSE.
30603 2020-11-29  Bruno Haible  <bruno@clisp.org>
30605         spawn-pipe tests: Fix test failure with MSVC.
30606         * tests/test-spawn-pipe-child.c: Include <stdint.h>.
30607         (gl_msvc_invalid_parameter_handler): New function.
30608         (main): Set a global invalid-parameter handler.
30609         * modules/spawn-pipe-tests (Depends-on): Add msvc-inval, stdint.
30611 2020-11-29  Bruno Haible  <bruno@clisp.org>
30613         execute: Add tests.
30614         * tests/test-execute.sh: New file.
30615         * tests/test-execute-main.c: New file.
30616         * tests/test-execute-child.c: New file.
30617         * modules/execute-tests: New file.
30619 2020-11-29  Bruno Haible  <bruno@clisp.org>
30621         fcntl: Work around NetBSD bug with F_DUPFD_CLOEXEC.
30622         * m4/fcntl.m4 (gl_FUNC_FCNTL): Test whether F_DUPFD_CLOEXEC actually
30623         works.
30624         * lib/fcntl.c (rpl_fcntl_DUPFD_CLOEXEC): On NetBSD, use the same
30625         fallback implementation as on Haiku.
30626         * tests/test-fcntl.c (main): Add a test whether F_DUPFD_CLOEXEC is
30627         effective.
30628         * doc/posix-functions/fcntl.texi: Mention the NetBSD bug.
30630 2020-11-29  Bruno Haible  <bruno@clisp.org>
30632         spawn-pipe: Fix build on OS/2 kLIBC (regression 2020-11-28).
30633         * lib/os2-spawn.h: New file, based on lib/windows-spawn.h.
30634         * lib/os2-spawn.c: New file, based on lib/windows-spawn.c.
30635         * lib/spawn-pipe.c: On OS/2 kLIBC, include "os2-spawn.h".
30636         * lib/windows-spawn.c: Remove modifications for kLIBC.
30637         * modules/spawn-pipe (Files): Add the new files.
30638         (configure.ac): Arrange to compile os2-spawn.c on OS/2.
30640 2020-11-28  Bruno Haible  <bruno@clisp.org>
30642         asyncsafe-spin: Fix compilation error with GCC on 32-bit SPARC.
30643         Reported by Paul Eggert in
30644         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00066.html>.
30645         * m4/sparcv8+.m4: New file.
30646         * modules/sparcv8+: New file.
30647         * modules/asyncsafe-spin (Depends-on): Add sparcv8+.
30649 2020-11-28  Bruno Haible  <bruno@clisp.org>
30651         asyncsafe-spin: Fix build error with GCC on 32-bit SPARC.
30652         * lib/asyncsafe-spin.c: Don't use GCC >= 4.1 primitives on SPARC.
30654 2020-11-28  Bruno Haible  <bruno@clisp.org>
30656         windows-spawn: New module.
30657         * lib/windows-spawn.h: Renamed from lib/w32spawn.h. Remove
30658         implementations.
30659         * lib/windows-spawn.c: Renamed from lib/w32spawn.h.
30660         * modules/windows-spawn: New file.
30661         * lib/execute.c: Include "windows-spawn.h" instead of "w32spawn.h".
30662         * lib/spawn-pipe.c: Likewise.
30663         * modules/execute (Files): Remove lib/w32spawn.h.
30664         (Depends-on): Add windows-spawn. Remove cloexec, msvc-nothrow, strpbrk,
30665         xalloc.
30666         (Makefile.am): Remove w32spawn.h from lib_SOURCES.
30667         * modules/spawn-pipe (Files): Remove lib/w32spawn.h.
30668         (Depends-on): Add windows-spawn. Remove cloexec, msvc-nothrow, strpbrk,
30669         xalloc.
30670         (Makefile.am): Remove w32spawn.h from lib_SOURCES.
30672 2020-11-27  Bruno Haible  <bruno@clisp.org>
30674         ssfmalloc tests: Port to macOS 11.
30675         * tests/test-ssfmalloc.c (PAGESIZE_MAX): Set to 16384, not 8192.
30677 2020-11-26  Bruno Haible  <bruno@clisp.org>
30679         Fix dependencies of modules that use '_exit' on native Windows.
30680         Reported by Jim Meyering in
30681         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00159.html>.
30682         * modules/_Exit (Depends-on): Add unistd.
30683         * modules/closein (Depends-on): Likewise.
30684         * modules/closeout (Depends-on): Likewise.
30685         * modules/forkpty (Depends-on): Likewise.
30686         * modules/posix_spawn-internal (Depends-on): Likewise.
30687         * modules/savewd (Depends-on): Likewise.
30688         * modules/stat-time-tests (Depends-on): Likewise.
30690 2020-11-26  Bruno Haible  <bruno@clisp.org>
30692         raise-tests: Fix compilation error on MSVC (regression 2020-11-25).
30693         * modules/raise-tests (Depends-on): Add unistd.
30694         * doc/posix-functions/_exit.texi: Mention the 'unistd' module.
30696 2020-11-25  Jim Meyering  <meyering@fb.com>
30698         setlocale-tests: do not trigger gcc's -Wanalyzer-possible-null-argument
30699         * tests/test-setlocale1.c (main): Assert that each strcmp argument is
30700         non-NULL, since we don't bother handing strdup failure.
30702         raise-tests: avoid GCC 11's new exit-from-signal-handler warning
30703         gcc's -Wanalyzer-unsafe-call-within-signal-handler exposed this.
30704         * tests/test-raise.c: Include unistd.h.
30705         (handler): Use _exit, not exit.
30707 2020-11-23  Bruno Haible  <bruno@clisp.org>
30709         Use the correct printf format attribute for mingw.
30710         Reported by Reuben Thomas <rrt@sc3d.org> in
30711         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00133.html>.
30713         * modules/vfprintf-posix (configure.ac): Define GNULIB_VFPRINTF_POSIX.
30714         * modules/vprintf-posix (configure.ac): Define GNULIB_VPRINTF_POSIX.
30716         * lib/stdio.in.h (_GL_ATTRIBUTE_SPEC_PRINTF_STANDARD,
30717         _GL_ATTRIBUTE_SPEC_PRINTF_SYSTEM): New macros.
30718         (_GL_ATTRIBUTE_FORMAT_PRINTF_STANDARD): Renamed from
30719         _GL_ATTRIBUTE_FORMAT_PRINTF. Use _GL_ATTRIBUTE_SPEC_PRINTF_STANDARD.
30720         (_GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM): Use
30721         _GL_ATTRIBUTE_SPEC_PRINTF_SYSTEM.
30723         * modules/vasnprintf (Depends-on): Add stdio.
30724         * lib/vasnprintf.h: Include <stdio.h>.
30725         (asnprintf, vasnprintf): Use the standard printf format attribute.
30727         * modules/xvasprintf (Depends-on): Add stdio.
30728         * lib/xvasprintf.h: Include <stdio.h>.
30729         (xasprintf, xvasprintf): Use the standard printf format attribute.
30731         * modules/xprintf (Depends-on): List stdio first.
30732         * lib/xprintf.h (xprintf, xvprintf): Use a printf format attribute that
30733         depends on GNULIB_VPRINTF_POSIX.
30734         (xfprintf, xvfprintf): Use a printf format attribute that depends on
30735         GNULIB_VFPRINTF_POSIX.
30737         * modules/c-vasnprintf (Depends-on): Add stdio.
30738         * lib/c-vasnprintf.h: Include <stdio.h>.
30739         (c_vasnprintf): Use the standard printf format attribute.
30741         * modules/c-vasprintf (Depends-on): Add stdio.
30742         * lib/c-vasprintf.h: Include <stdio.h>.
30743         (c_asprintf, c_vasprintf): Use the standard printf format attribute.
30745         * modules/c-vsnprintf (Depends-on): Add stdio.
30746         * lib/c-vsnprintf.h: Include <stdio.h>.
30747         (c_vsnprintf): Use the standard printf format attribute.
30749         * modules/c-snprintf (Depends-on): Add stdio.
30750         * lib/c-snprintf.h: Include <stdio.h>.
30751         (c_snprintf): Use the standard printf format attribute.
30753         * modules/c-xvasprintf (Depends-on): Add stdio.
30754         * lib/c-xvasprintf.h: Include <stdio.h>.
30755         (c_xasprintf, c_xvasprintf): Use the standard printf format attribute.
30757         * modules/error (Depends-on): Depend on stdio always.
30758         * lib/error.h: Include <stdio.h>.
30759         (_GL_ATTRIBUTE_SPEC_PRINTF): Remove macro.
30760         (error, error_at_line): Use a printf format attribute that depends on
30761         GNULIB_VFPRINTF_POSIX.
30762         * lib/error.c (_GL_ATTRIBUTE_FORMAT_PRINTF_STANDARD): Renamed from
30763         _GL_ATTRIBUTE_FORMAT_PRINTF.
30765         * modules/verror (Depends-on): Add stdio.
30766         * lib/verror.h: Include <stdio.h>. Don't include "error.h".
30767         (verror, verror_at_line): Use the standard printf format attribute.
30768         * lib/verror.c: Include "error.h".
30770         * modules/argp (Depends-on): Add stdio.
30771         * lib/argp.h (argp_error, __argp_error, argp_failure, __argp_failure):
30772         Use a printf format attribute that depends on GNULIB_VFPRINTF_POSIX.
30774         * modules/libtextstyle-optional (Depends-on): Add stdio.
30775         * lib/textstyle.in.h (ostream_printf, ostream_vprintf): Use the standard
30776         printf format attribute.
30778         * tests/test-nonblocking-misc.h (dbgfprintf): Use the standard printf
30779         format attribute.
30781 2020-11-23  Pádraig Brady  <P@draigBrady.com>
30783         selinux-at, selinux-h: use const correct declarations
30784         * lib/se-selinux.in.h: Use const for "set" functions,
30785         to match current selinux, and support cleaner user code.
30786         * lib/selinux-at.c: Likewise.
30787         * lib/selinux-at.h: Likewise.
30789 2020-11-22  Paul Eggert  <eggert@cs.ucla.edu>
30791         canonicalize-lgpl: fix memory leak
30792         * lib/canonicalize-lgpl.c (__realpath): Fix unlikely memory leak,
30793         which could have occurred if BUF was so large that malloc was
30794         called.  Do this by allocating EXTRA_BUF and BUF at the same time;
30795         this eliminates the need to free BUF separately.
30797 2020-11-22  Bruno Haible  <bruno@clisp.org>
30799         Fix missing module dependencies to 'xalloc' (regression 2020-10-19).
30800         * modules/xvasprintf (Depends-on): Add xalloc.
30801         * modules/pipe-filter-gi (Depends-on): Likewise.
30802         * modules/execute (Depends-on): Likewise, for w32spawn.h.
30803         * modules/spawn-pipe (Depends-on): Likewise.
30805 2020-11-22  Jose E. Marchesi  <jemarch@gnu.org>
30807         bootstrap: add option hooks
30808         * build-aux/bootstrap (bootstrap_print_option_usage_hook): Define.
30809         (bootstrap_option_hook): Likewise.
30810         (usage): Call bootstrap_print_option_usage_hook.
30812 2020-11-22  Bruno Haible  <bruno@clisp.org>
30814         argp: Don't break getprogname on non-glibc systems.
30815         * m4/argp.m4 (gl_ARGP): Don't expect <argp.h> to exist when testing for
30816         program_invocation_name and program_invocation_short_name.
30818 2020-11-22  Bruno Haible  <bruno@clisp.org>
30820         doc: Document <link.h>.
30821         * doc/glibc-headers/link.texi: New file.
30822         * doc/gnulib.texi: Include it.
30824 2020-11-22  Bruno Haible  <bruno@clisp.org>
30826         doc: Add references to the LSB.
30827         * doc/glibc-functions/*.texi: Add references to LSB 5.0.
30828         * doc/posix-functions/*.texi: Likewise.
30830 2020-11-22  Bruno Haible  <bruno@clisp.org>
30832         doc: Fix a makeinfo warning (regression 2020-11-03).
30833         * doc/posix-functions/aligned_alloc.texi: Add missing @item.
30835 2020-11-21  Paul Eggert  <eggert@cs.ucla.edu>
30837         parse-datetime: fix printf format typo
30838         * lib/parse-datetime.y (parse_datetime2): Fix format typo in
30839         previous patch to this file.  Problem reported by Chris Elvidge in
30840         <https://bugs.gnu.org/44763#32>.
30842         setlocale-null-tests: work around GCC bug 44511
30843         * tests/test-setlocale_null-mt-all.c:
30844         * tests/test-setlocale_null-mt-one.c:
30845         Ignore -Wreturn-type, to work around GCC bug 44511.
30847         nl_langinfo-tests: work around GCC bug 44511
30848         * tests/test-nl_langinfo-mt.c: Ignore -Wreturn-type, to work
30849         around a GCC bug <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=44511>.
30850         Problem reported for GNU grep by Andreas Schwab
30851         <https://bugs.gnu.org/44535>.
30853         selinux-h: add stubs for selabel_open etc.
30854         Coreutils with --enable-gcc-warnings does not build on Ubuntu 20.10
30855         because matchpathcon is deprecated in favor of selabel_open etc.,
30856         so this patch adds stubs for these functions.
30857         * lib/se-label.c, lib/se-label.in.h, m4/selinux-label-h.m4: New files.
30858         * lib/se-selinux.in.h (struct selinux_opt): Add incomplete decl,
30859         as it is needed for selabel_open and selinux/selinux.h declares
30860         this type here.
30861         * modules/selinux-h (Files): Add the new files.
30862         (configure.ac): Add gl_HEADERS_SELINUX_LABEL_H.
30863         (lib_SOURCES): Add se-label.in.h, se-label.c.
30864         (BUILT_SOURCES): Add $(SELINUX_LABEL_H).
30865         (selinux/label.h): New rule, mimicking selinux/context.h.
30866         (MOSTLYCLEANFILES): Add selinux/label.h, selinux/label.h-t.
30867         (Include): Add selinux/label.h.
30869 2020-11-21  Bruno Haible  <bruno@clisp.org>
30871         Update after 'test-driver' in Automake changed.
30872         * build-aux/test-driver.diff: Rebase.
30874 2020-11-21  Daiki Ueno  <ueno@gnu.org>
30876         read-file: remove dead assignment
30877         * lib/read-file.c (fread_file): Remove dead assignment when
30878         RF_SENSITIVE is set, flagged by clang-analyzer.
30880 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
30882         bitset: tests: exercise the stats too
30884         * tests/test-bitset.c: Display the stats at the end of the test.
30885         * lib/bitset/stats.c (bitset_log_histogram_print): When diplaying the
30886         last bin, display "256-..." rather that "256-511", since the last bin
30887         does count item greater than or equal to 256.
30889 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
30891         bitset: tests: try harder to break it
30892         * tests/test-bitset.c (compare): Be ready to use bitsets larger than
30893         BITSET_LIST_SIZE.
30894         (main): Likewise.
30895         While at it, also exercise super small bitsets.
30897 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
30899         bitset: use ffs where possible in the vector implementation
30900         * lib/bitset/vector.c (vbitset_list): Use BITSET_FOR_EACH_BIT.
30902 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
30904         bitset: use ffs where possible in the table implementation
30905         * lib/bitset/table.c (tbitset_list): Use BITSET_FOR_EACH_BIT.
30907 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
30909         bitset: check empty and full bitsets
30910         * tests/test-bitset.c (check_zero, check_ones): New.
30911         (check_attributes): Use them.
30913 2020-11-19  Akim Demaille  <akim@lrde.epita.fr>
30915         bitset: be sure to always return a value
30916         * lib/bitset/array.c (abitset_small_list): Always update *next and
30917         return a value.
30919 2020-11-19  Siddhesh Poyarekar  <siddhesh@gotplt.org>
30921         vcs-to-changelog: Expect spaces in file names
30922         Reported by Thierry Bothorel <thierry.bothorel@zaclys.net> in
30923         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00040.html>,
30924         * build-aux/vcstocl/vcs_git.py (exec_git_cmd): Do not transform
30925         tabs to spaces.
30926         (list_changes): Use tabs to identify file names.
30928 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
30930         bitset: strengthen tests
30931         * tests/test-bitset.c (compare): Also check count.
30932         Deal only with random values, move the one-bit tests to...
30933         (check_one_bit): this new function.
30934         (check_attributes): Call it.
30936 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
30938         bitset: fix iteration over table bitsets
30939         * lib/bitset/table.c (tbitset_list): Update bitno when windex is.
30941 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
30943         bitset: rename internal details for consistency
30944         * lib/bitset/table.c: Rename all the EBITSET_ symbols as TBITSET_.
30946 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
30948         bitset: test: run deterministic tests on several bitset sizes
30949         * tests/test-bitset.c (check_attributes): Run it with small and large
30950         sizes.
30952 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
30954         bitset: use ffs where possible in the list implementation
30955         * lib/bitset/list.c (lbitset_list): Use BITSET_FOR_EACH_BIT.
30957 2020-11-17  Akim Demaille  <akim@lrde.epita.fr>
30959         bitset: use ffs where possible in array implementation
30960         * lib/bitset/array.c (abitset_small_list): Use BITSET_FOR_EACH_BIT.
30962 2020-11-17  Bruno Haible  <bruno@clisp.org>
30964         posixcheck: Don't enable GNULIB_POSIXCHECK in C++ mode.
30965         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
30966         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00062.html>.
30967         * m4/posixcheck.m4 (gl_POSIXCHECK): Don't define GNULIB_POSIXCHECK in
30968         C++ mode.
30970 2020-11-17  Bruno Haible  <bruno@clisp.org>
30972         Fix error when GNULIB_POSIXCHECK is enabled (regression 2019-06-04).
30973         * lib/unistd.in.h (copy_file_range): Don't assume that copy_file_range
30974         is always declared.
30975         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether copy_file_range is
30976         declared.
30978 2020-11-17  Bruno Haible  <bruno@clisp.org>
30980         Fix link errors on AIX.
30981         * modules/clean-temp (Link): Link with $(LIBTHREAD).
30982         * modules/getumask (Link): Link with $(LIBTHREAD).
30983         * modules/getumask-tests (Makefile.am): Link test-getumask with
30984         $(LIBTHREAD).
30985         * modules/supersede (Link): Link with $(LIBTHREAD).
30986         * modules/supersede-tests (Makefile.am): Link test-supersede with
30987         $(LIBTHREAD).
30988         * modules/fatal-signal (Link): New section.
30989         * modules/execute (Link): New section.
30990         * modules/csharpexec (Link): Link with $(LIBTHREAD).
30991         * modules/javaexec (Link): Link with $(LIBTHREAD).
30992         * modules/spawn-pipe (Link): New section.
30993         * modules/spawn-pipe-tests (Makefile.am): Link test-spawn-pipe-main with
30994         $(LIBTHREAD).
30995         * modules/csharpcomp (Link): Link with $(LIBTHREAD).
30996         * modules/javacomp (Link): Link with $(LIBTHREAD).
30997         * modules/javaversion (Link): Link with $(LIBTHREAD).
30998         * modules/pipe-filter-gi (Link): New section.
30999         * modules/pipe-filter-gi-tests (Makefile.am): Link test-pipe-filter-gi1,
31000         test-pipe-filter-gi2-main with $(LIBTHREAD).
31001         * modules/pipe-filter-ii (Link): New section.
31002         * modules/pipe-filter-ii-tests (Makefile.am): Link test-pipe-filter-ii1,
31003         test-pipe-filter-ii2-main with $(LIBTHREAD).
31004         * modules/term-style-control (Link): New section.
31005         * modules/term-style-control-tests (Makefile.am): Link
31006         test-term-style-control-hello, test-term-style-control-yes with
31007         $(LIBTHREAD).
31008         * modules/wait-process (Link): New section.
31009         * modules/nonblocking-pipe-tests (Makefile.am): Link
31010         test-nonblocking-pipe-main with $(LIBTHREAD).
31011         * modules/nonblocking-socket-tests (Makefile.am): Link
31012         test-nonblocking-socket-main with $(LIBTHREAD).
31014 2020-11-16  Bruno Haible  <bruno@clisp.org>
31016         Fix link errors on platforms with libunistring.
31017         * modules/c32isalnum (Link): New section.
31018         * modules/c32isalnum-tests (Makefile.am): Link test-c32isalnum with
31019         $(LIBUNISTRING).
31020         * modules/c32isalpha (Link): New section.
31021         * modules/c32isalpha-tests (Makefile.am): Link test-c32isalpha with
31022         $(LIBUNISTRING).
31023         * modules/c32isblank (Link): New section.
31024         * modules/c32isblank-tests (Makefile.am): Link test-c32isblank with
31025         $(LIBUNISTRING).
31026         * modules/c32iscntrl (Link): New section.
31027         * modules/c32iscntrl-tests (Makefile.am): Link test-c32iscntrl with
31028         $(LIBUNISTRING).
31029         * modules/c32isdigit (Link): New section.
31030         * modules/c32isdigit-tests (Makefile.am): Link test-c32isdigit with
31031         $(LIBUNISTRING).
31032         * modules/c32isgraph (Link): New section.
31033         * modules/c32isgraph-tests (Makefile.am): Link test-c32isgraph with
31034         $(LIBUNISTRING).
31035         * modules/c32islower (Link): New section.
31036         * modules/c32islower-tests (Makefile.am): Link test-c32islower with
31037         $(LIBUNISTRING).
31038         * modules/c32isprint (Link): New section.
31039         * modules/c32isprint-tests (Makefile.am): Link test-c32isprint with
31040         $(LIBUNISTRING).
31041         * modules/c32ispunct (Link): New section.
31042         * modules/c32ispunct-tests (Makefile.am): Link test-c32ispunct with
31043         $(LIBUNISTRING).
31044         * modules/c32isspace (Link): New section.
31045         * modules/c32isspace-tests (Makefile.am): Link test-c32isspace with
31046         $(LIBUNISTRING).
31047         * modules/c32isupper (Link): New section.
31048         * modules/c32isupper-tests (Makefile.am): Link test-c32isupper with
31049         $(LIBUNISTRING).
31050         * modules/c32isxdigit (Link): New section.
31051         * modules/c32isxdigit-tests (Makefile.am): Link test-c32isxdigit with
31052         $(LIBUNISTRING).
31053         * modules/unicodeio (Link): Mention $(LIBUNISTRING).
31054         * modules/unicodeio-tests (Makefile.am): Link test-unicodeio with
31055         $(LIBUNISTRING).
31057 2020-11-16  Bruno Haible  <bruno@clisp.org>
31059         Fix link errors on platforms with libintl (e.g. Solaris and AIX).
31060         Reported by Tom G. Christensen <tgc@jupiterrise.com> in
31061         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00062.html>.
31062         * modules/getumask-tests (Makefile.am): Link test-getumask with
31063         $(LIBINTL).
31064         * modules/stack-tests (Makefile.am): Link test-stack with $(LIBINTL).
31065         * modules/supersede-tests (Makefile.am): Link test-supersede with
31066         $(LIBINTL).
31067         * modules/unicodeio-tests (Makefile.am): Link test-unicodeio with
31068         $(LIBINTL).
31070 2020-11-16  Bruno Haible  <bruno@clisp.org>
31072         getumask: Document link dependencies.
31073         * modules/getumask (Link): New section.
31075 2020-11-16  Bruno Haible  <bruno@clisp.org>
31077         Update link dependencies in modules after 2020-09-09 change.
31078         * modules/tempname (Link): Add $(LIB_CLOCK_GETTIME).
31079         * modules/mkdtemp (Link): Likewise.
31080         * modules/mkostemp (Link): Likewise.
31081         * modules/mkostemps (Link): Likewise.
31082         * modules/mkstemp (Link): Likewise.
31083         * modules/mkstemps (Link): Likewise.
31084         * modules/supersede (Link): Likewise.
31085         * modules/tmpfile (Link): Likewise.
31086         * modules/tmpfile-safer (Link): Likewise.
31088 2020-11-15  Paul Eggert  <eggert@cs.ucla.edu>
31090         getumask-tests: port to Solaris 10 etc.
31091         Problem reported by Tom Christensen in:
31092         https://lists.gnu.org/r/bug-gnulib/2020-11/msg00062.html
31093         * modules/getumask-tests (test_getumask_LDADD):
31094         Add $(LIB_CLOCK_GETTIME).
31096 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
31098         bitset: use ffsl to accelerate iterations over set bits
31099         Suggested by Bruno Haible.
31100         * modules/bitset: Depend upon ffsl.
31101         * lib/bitset/base.h (bitset_ffs, BITSET_FOR_EACH_BIT): New.
31102         * lib/bitset/array.c (abitset_list): Use BITSET_FOR_EACH_BIT.
31104 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
31106         bitset: more tests
31107         * tests/test-bitset.c (compare): Make it clear that the random values
31108         should not be modified.
31109         Check bitset_first, bitset_last and BITSET_FOR_EACH.
31111 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
31113         bitset: fix the copy from lbitset to other types
31114         * lib/bitset/list.c (lbitset_copy): Rename as...
31115         (lbitset_copy_): this.
31116         (lbitset_copy): New.
31117         Dispatch to heterogeneous/homogeneous copy.
31119 2020-11-15  Akim Demaille  <akim@lrde.epita.fr>
31121         bitset: making debug traces more useful
31122         * lib/bitset.c (bitset_print): Print the bitset type in verbose mode.
31124         bitset: comment changes
31125         * lib/bitset.c: Move some documenting comments to...
31126         * lib/bitset.h: here.
31127         * lib/bitset/array.c: Fix some comments.
31129 2020-11-14  Paul Eggert  <eggert@cs.ucla.edu>
31131         careadlinkat: warn better about GCC bug 93644
31132         * lib/careadlinkat.c (readlink_stk): When --enable-gcc-warnings is
31133         not in effect, use "#warning" to let builders know more clearly
31134         about GCC bug 93644, because the bug triggers even if no -W option
31135         is given to GCC.
31137 2020-11-13  Jim Meyering  <meyering@fb.com>
31139         hard-locale-tests: avoid a -Wstrict-prototypes warning
31140         * tests/locale.c (main): Placate gcc's -Wstrict-prototypes by
31141         changing "main ()" to "main (void)". This was the only case that
31142         triggered a warning when building grep with --enable-gcc-warnings.
31144 2020-11-11  Paul Eggert  <eggert@cs.ucla.edu>
31146         time_rz: simplify CVE-2017-7476 fix
31147         * lib/time_rz.c: Do not include limits.h; I think it was included
31148         under the mistaken impression that limits.h defines SIZE_MAX.
31149         (SIZE_MAX): Remove.
31150         (save_abbr): Put string length into a ptrdiff_t variable,
31151         so that the size comparison works naturally.  This
31152         fixes CVE-2017-7476 in a cleaner way.
31154         parse-datetime: streamline overflow checking
31155         When parse-datetime.y’s overflow code was written, INT_ADD_WRAPV
31156         did not work for unsigned destinations, and since time_t might
31157         be unsigned that meant it did not work for time_t destinations.
31158         This limitation of INT_ADD_WRAPV has been fixed, so we can
31159         now streamline parse-datetime.y a bit.
31160         * lib/parse-datetime.y: Do not include limits.h, as LONG_MAX
31161         has not been used for a while.
31162         (yylex, parse_datetime2): Assume C99 declarations after statements.
31163         (yyles): Use INT_SUBTRACT_WRAPV instead of an explicit comparison
31164         to TYPE_MINIMUM.
31165         (parse_datetime2): No need for time_overflow now that
31166         INT_ADD_WRAPV works for unsigned results.
31168         parse-datetime-tests: port to Alpine Linux 3.12.1
31169         * tests/test-parse-datetime.c: Include errno.h for errno,
31170         and unistd.h for _SC_TZNAME_MAX and sysconf.
31171         (main): In the outlandishly-long time zone abbreviation test,
31172         do not exceed TZNAME_MAX as this has undefined behavior,
31173         and on Alpine Linux 3.12.1 it makes the test fail.
31175 2020-11-09  Pádraig Brady  <P@draigBrady.com>
31177         mgetgroups: avoid warning with clang
31178         * lib/mgetgroups.c: Xcode-12.1 identifies as GCC 4.2.1,
31179         so disable -Wpointer-sign for all clang versions.
31181 2020-11-07  Bruno Haible  <bruno@clisp.org>
31183         gnulib-tool: Fix link error with 'version-etc' (regression 2020-05-29).
31184         Reported by Simon Josefsson in
31185         <https://lists.gnu.org/archive/html/bug-gnulib/2020-11/msg00032.html>.
31186         * gnulib-tool (func_emit_tests_Makefile_am): Add libtests.a to
31187         LDADD a third time, after the second occurrence of ../lib/libgnu.a.
31188         * pygnulib/GLEmiter.py (tests_Makefile_am): Likewise.
31190 2020-11-04  Paul Eggert  <eggert@cs.ucla.edu>
31192         tests: pacify Sun C 5.9
31193         Without these changes, Sun C 5.9 (2009/11/22) issues complaints like
31194         “"test-nl_langinfo-mt.c", line 75: warning: statement not reached”.
31195         * tests/test-nl_langinfo-mt.c (thread1_func, thread2_func)
31196         (thread3_func, thread4_func, thread5_func, thread6_func, threadN_func):
31197         * tests/test-setlocale_null-mt-all.c (thread1_func, thread2_func):
31198         * tests/test-setlocale_null-mt-one.c (thread1_func, thread2_func):
31199         Remove unreachable ‘return NULL;’s.
31201         tests: port better to XLC 12.01
31202         * tests/test-argmatch.c (CHECK): Do not use -1 as a subscript,
31203         even in code that is not executed, as IBM XLC 12.01 complains "The
31204         subscript -1 is less than zero."
31205         * tests/test-stdint.c (verify_width): Pass an (unused) 3rd
31206         argument to _GL_VERIFY, as ISO C requires.  Otherwise, IBM XLC
31207         12.01 complains "The invocation of macro _GL_VERIFY contains fewer
31208         arguments than are required by the macro definition."
31210 2020-11-03  Bruno Haible  <bruno@clisp.org>
31212         aligned-malloc: Use fixes from the new modules.
31213         * modules/aligned-malloc (Depends-on): Add posix_memalign,
31214         aligned_alloc, memalign.
31215         (configure.ac): Use AC_CHECK_FUNCS_ONCE.
31217 2020-11-03  Bruno Haible  <bruno@clisp.org>
31219         aligned_alloc: Add tests.
31220         * tests/test-aligned_alloc.c: New file.
31221         * modules/aligned_alloc-tests: New file.
31223         aligned_alloc: New module.
31224         * lib/stdlib.in.h (aligned_alloc): New declaration.
31225         * lib/aligned_alloc.c: New file.
31226         * m4/aligned_alloc.m4: New file.
31227         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether aligned_alloc is declared.
31228         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_ALIGNED_ALLOC,
31229         HAVE_ALIGNED_ALLOC, REPLACE_ALIGNED_ALLOC.
31230         * modules/stdlib (Makefile.am): Substitute GNULIB_ALIGNED_ALLOC,
31231         HAVE_ALIGNED_ALLOC, REPLACE_ALIGNED_ALLOC.
31232         * modules/aligned_alloc: New file.
31233         * tests/test-stdlib-c++.cc (aligned_alloc): Check signature.
31234         * doc/posix-functions/aligned_alloc.texi: Mention the new module and the
31235         AIX bug.
31237 2020-11-03  Bruno Haible  <bruno@clisp.org>
31239         posix_memalign: Add tests.
31240         * tests/test-posix_memalign.c: New file.
31241         * modules/posix_memalign-tests: New file.
31243         posix_memalign: New module.
31244         * lib/stdlib.in.h (posix_memalign): New declaration.
31245         * lib/posix_memalign.c: New file.
31246         * m4/posix_memalign.m4: New file.
31247         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether posix_memalign is declared.
31248         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_POSIX_MEMALIGN,
31249         HAVE_POSIX_MEMALIGN, REPLACE_POSIX_MEMALIGN.
31250         * modules/stdlib (Makefile.am): Substitute GNULIB_POSIX_MEMALIGN,
31251         HAVE_POSIX_MEMALIGN, REPLACE_POSIX_MEMALIGN.
31252         * modules/posix_memalign: New file.
31253         * tests/test-stdlib-c++.cc (posix_memalign): Check signature.
31254         * doc/posix-functions/posix_memalign.texi: Mention the new module and
31255         the OpenBSD bug.
31257 2020-11-03  Bruno Haible  <bruno@clisp.org>
31259         memalign: Add tests.
31260         * tests/test-memalign.c: New file.
31261         * modules/memalign-tests: New file.
31263         memalign: New module.
31264         * modules/memalign: New file.
31265         * doc/glibc-functions/memalign.texi: Mention the new module.
31267 2020-11-03  Bruno Haible  <bruno@clisp.org>
31269         verify tests: Fix crash with GCC (regression 2020-11-02).
31270         * tests/test-verify.c (main): Fix initializer of s.
31272 2020-11-03  Pádraig Brady  <P@draigBrady.com>
31274         mountlist: recognize more file system types as remote
31276         * lib/mountlist.c (ME_REMOTE): Sync previously unconsidered
31277         "remote" file systems from stat.c in coreutils.
31279 2020-11-02  Bernhard Voelker  <mail@bernhard-voelker.de>
31281         verify tests: Fix -Wuninitialized warning (regression 2020-10-30).
31282         * tests/test-verify.c (main): Initialize state variable.
31283         Reported by Bruno Haible for GCC 5.4.0.
31285 2020-11-02  Paul Eggert  <eggert@cs.ucla.edu>
31287         dfa.h: support inclusion from C++
31288         * lib/dfa.h: Allow multiple inclusion, and inclusion from
31289         C++ code.  The latter was suggested by Arnold Robbins.
31291 2020-11-01  Bruno Haible  <bruno@clisp.org>
31293         ssfmalloc tests: Portability to Linux/PowerPC and Linux/SPARC.
31294         * tests/test-ssfmalloc.c: Include <limits.h>.
31295         (PAGESIZE_MAX): Set to 65536 on Linux/PowerPC.
31297 2020-11-01  Bruno Haible  <bruno@clisp.org>
31299         verify tests: Fix compilation error with MSVC (regression 2020-10-30).
31300         * tests/test-verify.c (test_assume_noreturn): Fix declaration.
31302 2020-11-01  Jim Meyering  <meyering@fb.com>
31304         dfa-tests: test for today's invalid-merge fix
31305         * tests/test-dfa-invalid-merge.sh: New file.
31306         * modules/dfa-tests (Files): Add it.
31307         (TESTS): Add it.
31309 2020-11-01  Norihiro Tanaka  <noritnk@kcn.ne.jp>
31311         dfa: retain sequences of similar nodes in optimization
31312         DFA was merging similar nodes when it should not.  For example,
31313         it would convert a+a+a to a+a.  Now, a sequence of similar nodes
31314         is not merged.  Problem reported by Gonzalo Padrino in
31315         https://bugs.gnu.org/44351
31316         * lib/dfa.c (merge_nfa_state): Skip the follow for repetition in
31317         optimization.
31319 2020-11-01  Jim Meyering  <meyering@fb.com>
31321         test-dfa-match-aux.c: accept EREs, not BREs
31322         * tests/test-dfa-match-aux.c (main): Specify RE_SYNTAX_EGREP, not
31323         RE_SYNTAX_GREP, so tests can use ERE syntax rather than BRE.
31325 2020-10-30  Bernhard Voelker  <mail@bernhard-voelker.de>
31327         verify tests: avoid -Wmissing-declarations warnings
31328         * tests/test-verify.c (test_assume_expressions): Add declaration.
31329         (test_assume_optimization): Likewise.
31330         (test_assume_noreturn): Likewise.
31331         (main): Move down after all other definitions.  While at it, also
31332         call test_assume_expressions and test_assume_optimization as a
31333         runtime check.
31335 2020-10-26  Paul Eggert  <eggert@cs.ucla.edu>
31337         sys_stat: update comments for S_IRWXUGO, S_IXUGO
31338         * lib/sys_stat.in.h (S_IXUGO, S_IRWXUGO): Update comments.
31339         Perhaps these macros should be removed, as they’re not in either
31340         POSIX or GNU.  They could be moved to stat-macros.h, which would
31341         be cleaner in some sense.
31343 2020-10-25  Bruno Haible  <bruno@clisp.org>
31345         ssfmalloc tests: Small tweaks.
31346         * tests/test-ssfmalloc.c: Add comments.
31347         (alloc_pages): Don't require PROT_EXEC bits.
31348         (block_sizes): Add more small sizes, for better coverage of
31349         ssfmalloc-bitmap.h.
31351         ssfmalloc tests: Portability to Minix.
31352         * modules/ssfmalloc-tests (Files): Add m4/mmap-anon.m4.
31353         (configure.ac): Invoke gl_FUNC_MMAP_ANON.
31354         * m4/mmap-anon.m4: Update comment.
31356         ssfmalloc: Portability to AIX.
31357         * modules/ssfmalloc (Include): Add ssfmalloc.h.
31358         (Link): New section.
31359         * modules/ssfmalloc-tests (Makefile.am): Link test-ssfmalloc with
31360         $(LIBTHREAD).
31362         ssfmalloc: Portability to Cygwin.
31363         * lib/ssfmalloc.h: Add parameter PAGESIZE_MAX.
31364         (pg_offset_t): Define depending on PAGESIZE_MAX.
31365         * tests/test-ssfmalloc.c: Undefine PAGESIZE.
31366         (PAGESIZE_MAX): New macro.
31368         ssfmalloc: Fix buffer overrun in bitmap search.
31369         * lib/ssfmalloc-bitmap.h (find_first_packet_set): Don't access the
31370         word *words_end.
31372 2020-10-24  Paul Eggert  <eggert@cs.ucla.edu>
31374         doc: mention ‘restrict’ and C++
31375         * doc/gnulib-readme.texi (C99 features assumed): Document
31376         that ‘restrict’ should be avoided in C++ code.
31378 2020-10-20  Bernhard Voelker  <mail@bernhard-voelker.de>
31380         selinux-at, selinux-h: port to SELinux 3.1
31381         The new release finally deprecated the typedef 'security_context_t',
31382         see <https://github.com/SELinuxProject/selinux/commit/7a124ca275>.
31383         Use the simpler 'char *' instead.
31384         * lib/getfilecon.c (getfilecon): Adjust type of context parameter.
31385         (lgetfilecon): Likewise.
31386         (fgetfilecon): Likewise.
31387         (map_to_failure): Likewise.
31388         (rpl_getfilecon): Likewise.
31389         (rpl_lgetfilecon): Likewise.
31390         (rpl_fgetfilecon): Likewise.
31391         * lib/se-selinux.in.h (security_context_t): Remove typedef.
31392         (getcon): Adjust type of context parameter.
31393         (freecon): Likewise.
31394         (getfscreatecon): Likewise.
31395         (setfscreatecon): Likewise.
31396         (matchpathcon): Likewise.
31397         (getfilecon): Likewise.
31398         (lgetfilecon): Likewise.
31399         (fgetfilecon): Likewise.
31400         (setfilecon): Likewise.
31401         (lsetfilecon): Likewise.
31402         (fsetfilecon): Likewise.
31403         (security_check_context): Likewise.
31404         (security_check_context_raw): Likewise.
31405         (setexeccon): Likewise.
31406         (security_compute_create): Likewise.
31407         * lib/selinux-at.c (getfileconat): Likewise.
31408         (lgetfileconat): Likewise.
31409         (setfileconat): Likewise.
31410         (lsetfileconat): Likewise.
31411         * lib/selinux-at.h: Likewise.
31413 2020-10-19  Bruno Haible  <bruno@clisp.org>
31415         xalloc-die: Fix link error with Solaris cc (regression 2020-07-27).
31416         * lib/xalloc.h (xalloc_die): Don't declare if GNULIB_XALLOC_DIE is 0.
31417         (xmalloc, xzalloc, xcalloc, xrealloc, x2realloc, xmemdup, xstrdup,
31418         XMALLOC, XNMALLOC, XZALLOC, XCALLOC, xnmalloc, xnrealloc, x2nrealloc,
31419         xcharalloc): Don't declare/define if GNULIB_XALLOC is 0.
31420         * modules/xalloc (configure.ac): Define GNULIB_XALLOC.
31421         * modules/xalloc-die (configure.ac): Define GNULIB_XALLOC_DIE.
31423 2020-10-18  Bruno Haible  <bruno@clisp.org>
31425         ssfmalloc: Add tests.
31426         * tests/test-ssfmalloc.c: New file.
31427         * modules/ssfmalloc-tests: New file.
31429         ssfmalloc: New module.
31430         * lib/ssfmalloc.h: New file.
31431         * lib/ssfmalloc-bitmap.h: New file.
31432         * modules/ssfmalloc: New file.
31434 2020-10-18  Bruno Haible  <bruno@clisp.org>
31436         wchar: Fix configure test result on some versions of AIX.
31437         Reported by Clément Chigot <clement.chigot@atos.net> in
31438         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00115.html>.
31439         * m4/wchar_h.m4 (gl_WCHAR_H_INLINE_OK): Execute the test only on glibc
31440         systems.
31442 2020-10-18  Bruno Haible  <bruno@clisp.org>
31444         time: Fix warning about asctime when asctime is not used.
31445         * lib/time.in.h (asctime_r, ctime, ctime_r): Fix _GL_WARN_ON_USE
31446         invocation.
31448 2020-10-18  Bruno Haible  <bruno@clisp.org>
31450         *-list, *-oset, *-omap: Avoid a GCC warning (regression 2020-10-10).
31451         * lib/gl_anylinked_list2.h (gl_linked_iterator_free): Remove
31452         '_GL_ATTRIBUTE_CONST'.
31453         * lib/gl_anytree_list2.h (gl_tree_iterator_free): Likewise.
31454         * lib/gl_anytree_omap.h (gl_tree_iterator_free): Likewise.
31455         * lib/gl_anytree_oset.h (gl_tree_iterator_free): Likewise.
31456         * lib/gl_array_list.c (gl_array_iterator_free): Likewise.
31457         * lib/gl_array_omap.c (gl_array_iterator_free): Likewise.
31458         * lib/gl_array_oset.c (gl_array_iterator_free): Likewise.
31459         * lib/gl_carray_list.c (gl_carray_iterator_free): Likewise.
31461 2020-10-18  Bruno Haible  <bruno@clisp.org>
31463         obstack: Fix a clang warning.
31464         * lib/obstack.c (print_and_abort): Mark as __attribute_noreturn__.
31466 2020-10-16  Bruno Haible  <bruno@clisp.org>
31468         hash: Rename hash_delete to hash_remove.
31469         * lib/hash.h (hash_remove): Renamed from hash_delete.
31470         (hash_delete): New declaration.
31471         * lib/hash.c (hash_remove): Renamed from hash_delete.
31472         (hash_delete): New function.
31473         * tests/test-hash.c (main): Update.
31474         * lib/fts-cycle.c (leave_dir): Likewise.
31475         * NEWS: Mention the change.
31477 2020-10-16  Bruno Haible  <bruno@clisp.org>
31479         hash, xhash: Make usable from C++.
31480         * lib/hash.h: Add extern "C".
31482 2020-10-16  Bruno Haible  <bruno@clisp.org>
31484         hash, xhash: Move comments to the .h file.
31485         * lib/hash.c: Move comments meant for the user from here...
31486         * lib/xhash.c: ... and here...
31487         * lib/hash.h: ... to here.
31489 2020-10-13  Philipp Klaus Krause  <pkk@spth.de>  (tiny change)
31491         Don't declare an intention to modify the return value of strerror.
31492         * tests/test-perror2.c (main): Assign the return value of strerror to a
31493         'const char *' variable.
31495 2020-10-11  Bruno Haible  <bruno@clisp.org>
31497         *printf: Avoid "expanded before it was required" warning.
31498         * m4/printf.m4 (gl_SNPRINTF_TRUNCATION_C99): Define through
31499         AC_DEFUN_ONCE.
31501 2020-10-11  Benji Wiebe  <benjiwiebe14@gmail.com>
31503         getprogname: Add support for OpenServer 6 and UnixWare 7.
31504         * lib/getprogname.c: Include <fcntl.h>, <stdlib.h>, <string.h>.
31505         (getprogname): On OpenServer6 and UnixWare, read /proc/<pid>/cmdline.
31507 2020-10-11  Bruno Haible  <bruno@clisp.org>
31509         tests: Avoid a name clash on UnixWare.
31510         Reported by Tim Rice <tim@multitalents.net> in
31511         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00025.html>.
31512         * tests/nap.h (nap): Define as gl_nap on OpenServer and UnixWare.
31514 2020-10-11  Bruno Haible  <bruno@clisp.org>
31516         stdioext: Update comments regarding UnixWare.
31517         Reported by Tim Rice <tim@multitalents.net> in
31518         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00005.html>.
31519         * lib/fbufmode.c: Update comments.
31520         * lib/fflush.c: Likewise.
31521         * lib/fpending.c: Likewise.
31522         * lib/fpurge.c: Likewise.
31523         * lib/freadable.h: Likewise.
31524         * lib/freadable.c: Likewise.
31525         * lib/freadahead.c: Likewise.
31526         * lib/freading.h: Likewise.
31527         * lib/freading.c: Likewise.
31528         * lib/freadptr.c: Likewise.
31529         * lib/freadseek.c: Likewise.
31530         * lib/fseeko.c: Likewise.
31531         * lib/fseterr.c: Likewise.
31532         * lib/fwritable.h: Likewise.
31533         * lib/fwritable.c: Likewise.
31534         * lib/fwriting.h: Likewise.
31535         * lib/fwriting.c: Likewise.
31537 2020-10-11  Bruno Haible  <bruno@clisp.org>
31539         stdioext: Treat OpenServer 6 and UnixWare 7 like OpenServer 5.
31540         Reported by Tim Rice <tim@multitalents.net> in
31541         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00005.html>.
31542         Uses the info from
31543         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00028.html>.
31544         * lib/stdio-impl.h: Test also __SCO_VERSION__ and __sysv5__.
31546 2020-10-11  Bruno Haible  <bruno@clisp.org>
31548         stdioext: Avoid compilation errors on UnixWare 7.
31549         Reported by Tim Rice <tim@multitalents.net> in
31550         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00127.html>.
31551         * lib/fbufmode.c: Don't include <stdio_ext.h> if it does not exist.
31552         * lib/fpurge.c: Likewise.
31553         * lib/freadable.h: Likewise.
31554         * lib/freading.h: Likewise.
31555         * lib/fwritable.h: Likewise.
31556         * lib/fwriting.h: Likewise.
31557         * m4/fbufmode.m4 (gl_FUNC_FBUFMODE): Test whether <stdio_ext.h> exists.
31558         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
31559         * m4/freadable.m4 (gl_FUNC_FREADABLE): Likewise.
31560         * m4/freading.m4 (gl_FUNC_FREADING): Likewise.
31561         * m4/fwritable.m4 (gl_FUNC_FWRITABLE): Likewise.
31562         * m4/fwriting.m4 (gl_FUNC_FWRITING): Likewise.
31564 2020-10-11  Bruno Haible  <bruno@clisp.org>
31566         stdioext: Update comments regarding Cygwin.
31567         * lib/fpending.c: Update comments.
31568         * lib/fpurge.c: Likewise.
31569         * lib/freadable.h: Likewise.
31570         * lib/freadable.c: Likewise.
31571         * lib/freading.h: Likewise.
31572         * lib/freading.c: Likewise.
31573         * lib/fwritable.h: Likewise.
31574         * lib/fwritable.c: Likewise.
31575         * lib/fwriting.h: Likewise.
31576         * lib/fwriting.c: Likewise.
31578 2020-10-11  KO Myung-Hun  <komh78@gmail.com>
31580         Fix "warning: implicit declaration of function 'pthread_sigmask'".
31581         * lib/signal.in.h [__KLIBC__]: Include <pthread.h>.
31582         * lib/sys_select.in.h [__KLIBC__]: Do not include <signal.h>.
31584 2020-10-10  Bruno Haible  <bruno@clisp.org>
31586         *-list, *-oset, *-omap: Avoid possible compiler warnings.
31587         Reported by Marc Nieper-Wißkirchen in
31588         <https://lists.gnu.org/r/bug-gnulib/2020-10/msg00025.html>.
31589         * lib/gl_anylinked_list2.h (gl_linked_iterator,
31590         gl_linked_iterator_from_to): Mark as 'pure'.
31591         (gl_linked_iterator_free): Mark as 'const'.
31592         * lib/gl_anytree_list2.h (gl_tree_size, gl_tree_node_value,
31593         gl_tree_search_from_to, gl_tree_indexof_from_to, gl_tree_iterator,
31594         gl_tree_iterator_from_to, gl_tree_sortedlist_search,
31595         gl_tree_sortedlist_search_from_to, gl_tree_sortedlist_indexof,
31596         gl_tree_sortedlist_indexof_from_to): Mark as 'pure'.
31597         (gl_tree_iterator_free): Mark as 'const'.
31598         * lib/gl_anytree_omap.h (gl_tree_size, gl_tree_iterator): Mark as
31599         'pure'.
31600         (gl_tree_iterator_free): Mark as 'const'.
31601         * lib/gl_anytree_oset.h (gl_tree_size, gl_tree_next_node,
31602         gl_tree_prev_node, gl_tree_iterator): Mark as 'pure'.
31603         (gl_tree_iterator_free): Mark as 'const'.
31604         * lib/gl_anytreehash_list1.h (node_position, compare_by_position,
31605         compare_position_threshold): Mark as 'pure'.
31606         * lib/gl_array_list.c (gl_array_size, gl_array_indexof_from_to,
31607         gl_array_search_from_to, gl_array_iterator, gl_array_iterator_from_to,
31608         gl_array_sortedlist_indexof_from_to, gl_array_sortedlist_indexof,
31609         gl_array_sortedlist_search_from_to, gl_array_sortedlist_search): Mark as
31610         'pure'.
31611         (gl_array_iterator_free): Mark as 'const'.
31612         * lib/gl_array_omap.c (gl_array_size, gl_array_indexof, gl_array_search,
31613         gl_array_search_atleast, gl_array_iterator): Mark as 'pure'.
31614         (gl_array_iterator_free): Mark as 'const'.
31615         * lib/gl_array_oset.c (gl_array_size, gl_array_indexof, gl_array_search,
31616         gl_array_indexof_atleast, gl_array_search_atleast, gl_array_iterator,
31617         gl_array_iterator_atleast): Mark as 'pure'.
31618         (gl_array_iterator_free): Mark as 'const'.
31619         * lib/gl_carray_list.c (gl_carray_size, gl_carray_node_value,
31620         gl_carray_next_node, gl_carray_previous_node, gl_carray_get_at,
31621         gl_carray_indexof_from_to, gl_carray_search_from_to, gl_carray_iterator,
31622         gl_carray_iterator_from_to, gl_carray_sortedlist_indexof_from_to,
31623         gl_carray_sortedlist_indexof, gl_carray_sortedlist_search_from_to,
31624         gl_carray_sortedlist_search): Mark as 'pure'.
31625         (gl_carray_iterator_free): Mark as 'const'.
31627 2020-10-10  Bruno Haible  <bruno@clisp.org>
31629         rbtree-list: Avoid possible compiler warnings.
31630         This mirrors the change of avltree-list on 2014-09-16.
31631         * lib/gl_rbtree_list.c (gl_rbtree_list_check_invariants): Add extern
31632         declaration. Add cast to void for ignored value of check_invariants.
31634 2020-10-10  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
31636         stack: New module.
31637         * MODULES.html.sh: Add entry for the stack module.
31638         * modules/stack: New file.
31639         * modules/stack-tests: New file.
31640         * lib/stack.h: New file.
31641         * tests/test-stack.c: New file.
31643 2020-10-10  Paul Eggert  <eggert@cs.ucla.edu>
31645         attribute: improve const, pure doc
31646         Problem reported by Marc Nieper-Wißkirchen in:
31647         https://lists.gnu.org/r/bug-gnulib/2020-10/msg00035.html
31648         * lib/attribute.h (ATTRIBUTE_CONST, ATTRIBUTE_PURE): Improv doc.  See:
31649         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=51971#c1
31651 2020-10-05  Paul Eggert  <eggert@cs.ucla.edu>
31653         thread: pacify GCC on Solaris 10
31654         Problem reported by Kiyoshi KANAZAWA for grep (Bug#43666#29).
31655         * lib/glthread/thread.h (gl_thread_self): Use ‘(pthread_t) 0’
31656         instead of ‘(pthread_t) NULL’, to pacify GCC on Solaris 10
31657         where pthread_t is unsigned int.
31659 2020-10-04  Paul Eggert  <eggert@cs.ucla.edu>
31661         c-stack: avoid AS_IF
31662         Problem reported by Bruno Haible in:
31663         https://lists.gnu.org/r/bug-gnulib/2020-10/msg00018.html
31664         * m4/c-stack.m4 (gl_PREREQ_C_STACK): No need for AS_IF.
31666         c-stack: pacify GCC 9.3.1 when using libsigsegv
31667         * lib/c-stack.c [USE_LIBSIGSEGV]: Disable --suggest-attribute=pure.
31669 2020-10-04  Bruno Haible  <bruno@clisp.org>
31671         localename: Fix a couple of "unused parameter" warnings.
31672         Reported by Marc Nieper-Wißkirchen <marc@nieper-wisskirchen.de> in
31673         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00014.html>.
31674         * lib/localename.c (gl_locale_name_thread_unsafe, gl_locale_name_thread,
31675         gl_locale_name_posix, gl_locale_name_environ): Add _GL_UNUSED in
31676         parameter list.
31678 2020-10-04  Bruno Haible  <bruno@clisp.org>
31680         vasnprintf: Don't use %n on modern, ISO C 99 compliant platforms.
31681         Suggested by Jeremie Courreges-Anglas <jca@wxcvbn.org> in
31682         <https://lists.gnu.org/archive/html/bug-gnulib/2020-10/msg00010.html>.
31683         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Define
31684         HAVE_SNPRINTF_TRUNCATION_C99.
31685         * lib/vasnprintf.c (VASNPRINTF): Don't use %n if
31686         HAVE_SNPRINTF_RETVAL_C99 && HAVE_SNPRINTF_TRUNCATION_C99.
31688 2020-10-03  Paul Eggert  <eggert@cs.ucla.edu>
31690         c-stack: streamline Solaris configuration
31691         * lib/c-stack.c: Omit mention of HAVE_SIGALTSTACK, since
31692         the code is used only if a test for sigaltstack worked
31693         in some other way.
31694         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Do not require gl_LIBSIGSEGV;
31695         instead, execute gl_LIBSIGSEGV only if needed (because the XSI
31696         heuristic does not work).
31697         * modules/c-stack (Files): Add m4/libsigsegv.m4, since
31698         we no longer require the libsigsegv module.
31699         (Depends-on): Depend on havelib, not libsigsegv.
31701         c-stack: stop using SIGSTKSZ
31702         It’s been proposed to stop making SIGSTKSZ an integer constant:
31703         https://sourceware.org/pipermail/libc-alpha/2020-September/118028.html
31704         Also, using SIGSTKSZ in #if did not conform to current POSIX.
31705         Also, avoiding SIGSTKSZ makes the code simpler and easier to grok.
31706         * lib/c-stack.c (SIGSTKSZ): Remove.
31707         (alternate_signal_stack): Now a 64 KiB array, for simplicity.
31708         All uses changed.
31710         c-stack: fix libsigsegv typo
31711         Problem reported by Bruno Haible in:
31712         https://lists.gnu.org/r/bug-gnulib/2020-09/msg00175.html
31713         * lib/c-stack.c (USE_LIBSIGSEGV): Fix typo that caused libsigsegv
31714         to be used only on Solaris (exactly where it is not needed!).
31716 2020-10-03  Thien-Thi Nguyen  <ttn@gnuvola.org>
31718         MODULES.html.sh: Fix typo.
31719         * MODULES.html.sh (Numeric conversion functions <stdlib.h>): Fix typo.
31721 2020-09-28  Paul Eggert  <eggert@cs.ucla.edu>
31723         version-etc: pacify Oracle Studio 12.6
31724         Without this patch, it complains: "version-etc.h", line 64:
31725         warning: token-less macro argument (E_TOKENLESS_MACRO)" when in
31726         pedantic mode.
31727         * lib/version-etc.h (version_etc): Port to C89 macro rules.
31729 2020-09-27  Bruno Haible  <bruno@clisp.org>
31731         Avoid "warning: The macro `AC_DECL_SYS_SIGLIST' is obsolete".
31732         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
31733         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00154.html>.
31734         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Check for sys_siglist
31735         ourselves; don't use AC_DECL_SYS_SIGLIST.
31737 2020-09-27  Bruno Haible  <bruno@clisp.org>
31739         Avoid "warning: The macro `_AC_COMPUTE_INT' is obsolete".
31740         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
31741         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00154.html>.
31742         * m4/gethostname.m4 (gl_PREREQ_HOST_NAME_MAX): Use AC_COMPUTE_INT
31743         instead of _AC_COMPUTE_INT.
31745 2020-09-27  Bruno Haible  <bruno@clisp.org>
31747         Avoid "warning: The macro `AC_HEADER_STDC' is obsolete".
31748         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
31749         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00154.html>.
31750         Based on a patch by Paul Eggert.
31751         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Don't require AC_HEADER_STDC. Don't
31752         test STDC_HEADERS. Assume <stdlib.h> exists.
31753         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
31755 2020-09-27  Bruno Haible  <bruno@clisp.org>
31757         Enable testing of prereleases of Autoconf 2.70.
31758         Suggested by Paul Eggert in
31759         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00160.html>.
31760         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA): Test for Autoconf >= 2.69c, not
31761         >= 2.70.
31762         * m4/largefile.m4 (AC_SYS_LARGEFILE): Likewise.
31763         * m4/pid_t.m4 (AC_TYPE_PID_T): Likewise.
31764         * m4/sys_types_h.m4 (AC_HEADER_MAJOR): Likewise.
31766 2020-09-27  Bruno Haible  <bruno@clisp.org>
31768         Avoid "warning: The macro `AC_PROG_CC_STDC' is obsolete".
31769         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
31770         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00151.html>.
31771         * m4/gnulib-common.m4 (gl_PROG_CC_C99): Use AC_PROG_CC_C99 or
31772         AC_PROG_CC, depending on the Autoconf version.
31774 2020-09-27  Gavin Smith  <gavinsmith0123@gmail.com>
31776         Avoid "warning: The macro `AC_HELP_STRING' is obsolete".
31777         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Use AS_HELP_STRING instead
31778         of AC_HELP_STRING.
31779         * m4/libgcrypt.m4 (AM_PATH_LIBGCRYPT): Likewise.
31781 2020-09-27  Bruno Haible  <bruno@clisp.org>
31783         Avoid "warning: $as_echo_n is obsolete" from autoconf 2.69c.
31784         Reported by Gavin Smith <gavinsmith0123@gmail.com> in
31785         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00151.html>.
31786         * m4/gnulib-common.m4 (gl_CACHE_VAL_SILENT): Use gl_SILENT.
31788 2020-09-27  Bruno Haible  <bruno@clisp.org>
31790         extensions: Simplify last commit.
31791         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't require
31792         AC_GNU_SOURCE ever.
31794 2020-09-26  Paul Eggert  <eggert@cs.ucla.edu>
31796         extensions: require AC_GNU_SOURCE only for <=2.63
31797         Problem reported by Gavin Smith in:
31798         https://lists.gnu.org/r/autoconf/2020-09/msg00012.html
31799         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS):
31800         Require AC_GNU_SOURCE only for Autoconf 2.63 and earlier, since it
31801         shouldn’t be needed after that, and Autoconf 2.70 complains about
31802         it being obsolete.
31804 2020-09-26  Bruno Haible  <bruno@clisp.org>
31806         regex-tests: Make test more robust.
31807         * tests/test-regex.c (main): Make sure to revert the locale to "C" after
31808         the test in "tr_TR.UTF-8" locale. Exit if we can't revert it.
31810 2020-09-25  Paul Eggert  <eggert@cs.ucla.edu>
31812         regex-tests: fix possible Turkish false-alarm
31813         * modules/regex-tests (Depends-on): Add wctype-h.
31814         * tests/test-regex.c: Include wctype.h.
31815         (main): Check that ‘i’ uppercases to ‘İ’ in Turkish,
31816         as the Turkish regex test assumes this.
31818         regex-tests: fix test and add debug output
31819         Perhaps this will fix the recent grep test failure reported at:
31820         https://buildfarm.opencsw.org/buildbot/builders/ggrep-solaris10-sparc/builds/199
31821         At least, the debug output should help narrow down the failure.
31822         * tests/test-regex.c: Include stdarg.h, stdio.h.
31823         (exit_status): New var.
31824         (report_error): New function.
31825         (main): Use it to report failures to stdout instead of merely
31826         exiting with some nonzero status.  The status info alone isn’t
31827         enough to do remote debugging.  In the new tr_TR.UTF-8 test, clear
31828         regex before calling re_compile_pattern, fixing a portability bug.
31830         regex: no longer match glibc
31831         * config/srclist.txt: Comment out regex_internal.c for now.
31833 2020-09-23  Paul Eggert  <eggert@cs.ucla.edu>
31835         regex: fix ignore-case Turkish bug
31836         * lib/regex_internal.c (build_wcs_upper_buffer):
31837         Do not assume that converting single-byte character to upper
31838         yields a single-byte character.  This is not true for Turkish,
31839         where towupper (L'i') yields L'İ', which is not single-byte.
31840         * tests/test-regex.c (main): Test for this bug.
31842         regex: port to weird isascii platforms
31843         * lib/regex_internal.h (isascii) [!_LIBC]: Supply glibc version.
31845 2020-09-20  Norihiro Tanaka  <noritnk@kcn.ne.jp>
31847         dfa: make dfasupported a global function
31848         * lib/dfa.c (dfasupported): Rename, and make it global.
31849         Update caller.
31850         * lib/dfa.h (dfasupported): Add prototype.
31852 2020-09-20  Bruno Haible  <bruno@clisp.org>
31854         canonicalize: Add support for UNC file names on native Windows.
31855         Reported and initial patch by Vaclav Slavik <vaclav@slavik.io> in
31856         <https://savannah.gnu.org/bugs/?59079>.
31857         * lib/canonicalize.c (canonicalize_filename_mode): For UNC file names,
31858         extend the prefix to include the server.
31860 2020-09-20  Bruno Haible  <bruno@clisp.org>
31862         supersede: Fix test failures on native Windows.
31863         * lib/supersede.c (open_supersede): Handle non-regular files on native
31864         Windows like on Solaris.
31865         * tests/test-supersede-open.h (test_open_supersede): Use O_BINARY flag.
31867 2020-09-20  Paul Eggert  <eggert@cs.ucla.edu>
31869         test-stdalign: test Oracle Studio better
31870         * doc/posix-headers/stdalign.texi (stdalign.h):
31871         * tests/test-stdalign.c (main):
31872         Sun Studio Bug #2125432 seems to be fixed.
31874         c-stack: output diagnostic in single 'write'
31875         * lib/c-stack.c (die): In the typical case, use just one 'write'
31876         syscall to output the diagnostic, as this lessens interleaving.
31877         (die, c_stack_action): Assume C99.
31878         * modules/c-stack (Depends-on): Add c99, mempcpy.
31880         c-stack: improve checking if !libsigsegv
31881         If SIGINFO_WORKS, do not treat a null pointer dereference as if it
31882         were a stack overflow.  Use uintptr_t and INT_ADD_WRAPV to avoid
31883         unlikely pointer overflow.  Also, fix some obsolete code and typos.
31884         I found these problems while looking into this bug report:
31885         https://lists.gnu.org/r/grep-devel/2020-09/msg00053.html
31886         * lib/c-stack.c: Include c-stack.h first, to test interface.
31887         Include inttypes.h for UINTPTR_MAX, stdbool.h, stddef.h for
31888         max_align_t, intprops.h for INT_ADD_WRAPV.
31889         (USE_LIBSIGSEGV): New macro; use it to simplify later code.
31890         (SIGSTKSZ): Simplify setup.  Work around libsigsegv bug only
31891         for libsigsegv 2.8 and earlier since the bug should be fixed
31892         after that.
31893         (alternate_signal_stack): Use max_align_t instead of doing it by hand.
31894         (segv_handler, overflow_handler, segv_handler) [DEBUG]:
31895         Assume sprintf returns byte count; this assumption is safe now.
31896         (page_size): New static volatile variable, since sysconf isn’t
31897         documented to be async-signal-safe on Solaris.  This variable is
31898         present and used if (!USE_LIBSIGSEGV && HAVE_SIGALTSTACK &&
31899         HAVE_DECL_SIGALTSTACK && HAVE_STACK_OVERFLOW_HANDLING &&
31900         SIGINFO_WORKS).
31901         (segv_handler): Use it if present.  Never report null pointer
31902         dereference as a stack overflow.  Check for (unlikely) unsigned
31903         and/or pointer overflow.
31904         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
31905         Rename cache variables to gl_cv_sys_stack_overflow_works
31906         and gl_cv_sys_xsi_stack_overflow_heuristic.
31907         All uses changed.
31908         (gl_PREREQ_C_STACK): Do not require AC_FUNC_ALLOCA, since
31909         c-stack no longer uses STACK_DIRECTION.
31910         Do not check for unistd.h, since we depend on unistd.
31911         Fix shell typo ‘$"ac_cv_sys_xsi_stack_overflow_heuristic"’.
31912         * modules/c-stack (Depends-on): Sort.  Add intprops, inttypes,
31913         stdbool, stddef.
31915 2020-09-20  Bruno Haible  <bruno@clisp.org>
31917         Revert now-unnecessary override of config.guess on Alpine Linux 3.10.
31918         * m4/musl.m4: Revert 2020-09-19 patch.
31919         * m4/setlocale_null.m4: Likewise.
31920         * modules/setlocale-null: Likewise.
31922 2020-09-19  Ben Pfaff  <blp@cs.stanford.edu>
31923             Bruno Haible  <bruno@clisp.org>
31925         relocatable-prog: Fix for multiple relocatable library directories.
31926         * build-aux/reloc-ldflags: Fix handling of multiple relocatable library
31927         directories.  Each one needs its own -Wl,-rpath,$dir option, instead of
31928         being attached to a single one.
31930 2020-09-19  Jim Meyering  <meyering@fb.com>
31932         test-verify.c: avoid -Wshadow warnings
31933         * tests/test-verify.c (gx): Rename global from "x". Adjust use.
31934         (enum): Capitalize member names. Adjust uses.
31936 2020-09-19  Bruno Haible  <bruno@clisp.org>
31938         havelib: Avoid linking with libc.a on GNU systems.
31939         Reported by Bruce Dubbs <bruce.dubbs@gmail.com> in
31940         <https://lists.gnu.org/archive/html/grep-devel/2020-09/msg00052.html>.
31941         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): When processing the
31942         dependency_libs value of a .la file, ignore '-lc' options on GNU
31943         systems.
31945 2020-09-19  Bruno Haible  <bruno@clisp.org>
31947         Fix recognition of musl libc on Alpine Linux 3.10.
31948         Reported by Jeffrey Walton <noloader@gmail.com> in
31949         <https://lists.gnu.org/archive/html/grep-devel/2020-09/msg00020.html>.
31950         * m4/musl.m4 (gl_MUSL_CANONICAL_HOST): New macro.
31951         (gl_MUSL_LIBC): Require it.
31952         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Likewise.
31953         * modules/setlocale-null (Files): Add m4/musl.m4.
31955 2020-09-19  Bruno Haible  <bruno@clisp.org>
31957         nl_langinfo: Make multithread-safe on Solaris 10 and Solaris 11.3.
31958         Reported for Solaris 10 by Dagobert Michelsen via Paul Eggert in
31959         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00023.html>
31960         and for Solaris 11.3 by Jeffrey Walton <noloader@gmail.com> in
31961         <https://lists.gnu.org/archive/html/bug-grep/2020-06/msg00013.html>.
31962         * lib/nl_langinfo-lock.c: New file, based on lib/setlocale_null-lock.c.
31963         * lib/nl_langinfo.c: Include <stdlib.h> and <windows.h> or <pthread.h>
31964         or <threads.h>.
31965         (ITEMS, MAX_RESULT_LEN): New macros.
31966         (nl_langinfo_unlocked): New function.
31967         (gl_get_nl_langinfo_lock): New declaration.
31968         (nl_langinfo_with_lock): New function, based on lib/setlocale_null.c.
31969         (rpl_nl_langinfo): Use nl_langinfo_with_lock instead of nl_langinfo.
31970         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Require gl_PTHREADLIB. Define
31971         HAVE_THREADS_H. Set NL_LANGINFO_MTSAFE. If setting it to 0, also set
31972         REPLACE_NL_LANGINFO.
31973         (gl_PREREQ_NL_LANGINFO_LOCK): New macro.
31974         * modules/nl_langinfo (Files): Add lib/nl_langinfo-lock.c,
31975         lib/windows-initguard.h, m4/threadlib.m4, m4/visibility.m4.
31976         (configure.ac): Compile nl_langinfo-lock.c when NL_LANGINFO_MTSAFE is 0.
31977         * doc/posix-functions/nl_langinfo.texi: Mention the Solaris bug.
31979 2020-09-18  Bruno Haible  <bruno@clisp.org>
31981         fsusage, getaddrinfo: Produce more regular configure output.
31982         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Remove AC_MSG_CHECKING without
31983         corresponding AC_MSG_RESULT.
31984         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
31986 2020-09-18  Bruno Haible  <bruno@clisp.org>
31988         Add back gl_SILENT.
31989         * m4/gnulib-common.m4 (GL_TMP_FD, gl_SILENT): New macros.
31991 2020-09-18  Paul Eggert  <eggert@cs.ucla.edu>
31993         c-stack-tests: fix -fsanitize=undefined false alarm
31994         * tests/test-c-stack2.sh: Skip the test-harness self-test
31995         if ‘gcc -fsanitize=undefined’ is in use.
31997 2020-09-17  Paul Eggert  <eggert@cs.ucla.edu>
31999         signalblocking: simplify and remove gl_SILENT
32000         gl_SILENT was problematic because if a trap was sprung, stderr
32001         generated during the trap was lost.  Avoid the problem by
32002         removing the need for gl_SILENT.
32003         * m4/gnulib-common.m4 (GL_TMP_FD, gl_SILENT): Remove.
32004         * m4/signalblocking.m4 (gl_SIGNALBLOCKING):
32005         Simplify, avoiding the need for gl_SILENT while preserving the
32006         ability of the user to override the value of the cache variable,
32007         now ac_cv_func_sigprocmask.
32009 2020-09-17  Bruno Haible  <bruno@clisp.org>
32011         sigprocmask: Fix configuration failure on Solaris 10 (regr. 2020-07-25).
32012         * m4/gnulib-common.m4 (GL_TMP_FD): New macro.
32013         (gl_SILENT): Use 'exec', not a compound statement, to redirect
32014         AS_MESSAGE_FD.
32016 2020-09-17  Paul Eggert  <eggert@cs.ucla.edu>
32018         intprops, xalloc: avoid __builtin_mul_overflow_p with Clang
32019         Problem reported by Nelson H. F. Beebe for clang 9.0.1 in:
32020         https://lists.gnu.org/r/grep-devel/2020-09/msg00028.html
32021         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P) [__clang__]:
32022         Define to 0.
32023         * lib/xalloc-oversized.h (xalloc_oversized) [__clang__]:
32024         Do not use __builtin_mul_overflow_p.
32026         libc-config: port __THROW to Ubuntu 4
32027         * lib/cdefs.h (__THROW): Do not use __attribute__ ((__nothrow__))
32028         for GCC 3.3.  Problem reported by Jeffrey Walton in:
32029         https://lists.gnu.org/r/bug-gnulib/2019-07/msg00058.html
32030         The GCC 3.3.4 documentation says the attribute should work, but
32031         apparently it does not work on Ubuntu 4’s GCC 3.3.  There seems
32032         little point or desire to research this circa-2004 platform further,
32033         so just avoid the attribute there.
32035 2020-09-17  Jim Meyering  <meyering@fb.com>
32037         test-dfa-match.sh: port timeout work-around to newer Busybox
32038         * tests/test-dfa-match.sh: Update timeout -t portability test to
32039         accommodate Busybox 1.30.0 and newer.
32041 2020-09-16  Paul Eggert  <eggert@cs.ucla.edu>
32043         fnmatch: adjust to match glibc fix
32044         This fixes handling of collating symbols in fnmatch (glibc bug 26620).
32045         This does not affect Gnulib; it merely keeps Gnulib and glibc
32046         closer together, to help with any eventual merge, by incorporating
32047         a recent glibc patch.  The patch and the following commentary is
32048         by Andreas Schwab.
32049         * lib/fnmatch_loop.c (FCT) [WIDE_CHAR_VERSION]: The variable idx
32050         contains the index into the extra array, whereas wextra points
32051         into the extra array at this index, containing the length of the
32052         following collating sequence in the wide character representation.
32054 2020-09-16  Bruno Haible  <bruno@clisp.org>
32056         stat, fstat: Fix compilation error with old mingw headers.
32057         Reported by Eli Zaretskii <eliz@gnu.org> in
32058         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00027.html>.
32059         * lib/stat-w32.c (VOLUME_NAME_NONE): Define if the Windows headers don't
32060         define it.
32062 2020-09-16  Bruno Haible  <bruno@clisp.org>
32064         stat, fstat: Fix when compiling for versions older than Windows Vista.
32065         Reported by Eli Zaretskii <eliz@gnu.org> in
32066         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00027.html>.
32067         * lib/stat-w32.c: Include <sdkddkver.h>. Test the value of _WIN32_WINNT
32068         that was originally set before we redefined it.
32069         * m4/stat.m4 (gl_PREREQ_STAT_W32): New macro.
32070         (gl_PREREQ_STAT): Require it.
32071         * m4/fstat.m4 (gl_PREREQ_FSTAT): Likewise.
32073 2020-09-15  Paul Eggert  <eggert@cs.ucla.edu>
32075         dfa: remove dfa-heap-overrun workaround
32076         * lib/dfa.c (reorder_tokens): Go back to a single pass that
32077         both sets map[*] and does other things.  This reverts
32078         2020-09-14T01:20:01Z!eggert@cs.ucla.edu, which is no longer
32079         neeeded now that 2020-09-14T13:21:05Z!noritnk@kcn.ne.jp
32080         fixed the underlying problem.
32082 2020-09-13  Paul Eggert  <eggert@cs.ucla.edu>
32084         dfa: avoid use of uninitialized constraint
32085         * lib/dfa.c (merge_nfa_state): Do not initialize the constraint
32086         to zero here.
32087         (dfaoptimize): Do it here instead, via xcalloc.  This prevents the
32088         use of an uninitialized constraint by later code when ! (flags[i]
32089         & OPT_QUEUED) means merge_nfa_state was not called to initialize
32090         the constraint.  Problem found by running 'valgrind src/grep -E
32091         '(^| )*(a|b)*(c|d)*( |$)' < /dev/null' on Ubuntu 18.04.5 x86-64.
32093         dfa: assume C99 in reorder_tokens
32094         * lib/dfa.c (reorder_tokens): Assume C99 and simplify.
32096         dfa: fix dfa-heap-overrun failure
32097         * lib/dfa.c (reorder_tokens): When setting
32098         map[d->follows[i].elems[j].index], instead of incorrectly assuming
32099         that (i < d->follows[i].elems[j].index), use two loops, one to set
32100         the map array and the other to use it.  The incorrect assumption
32101         caused some elements to be missed, and this in turn caused grep's
32102         dfa-heap-overrun test to fail on Solaris 10 sparc when compiled
32103         with GCC.  I found this bug while investigating
32104         https://buildfarm.opencsw.org/buildbot/builders/ggrep-solaris10-sparc/builds/183
32105         and I think the bug also occurs on GNU/Linux but with more-subtle
32106         symptoms.  The bug predates the recent dfa.c changes; perhaps the
32107         recent changes make the bug more likely.
32109 2020-09-13  Bruno Haible  <bruno@clisp.org>
32111         parse-datetime: Make the build rule work with parallel 'make'.
32112         Reported by Daiki Ueno <ueno@gnu.org> in
32113         <https://lists.gnu.org/archive/html/bug-gnulib/2020-09/msg00036.html>.
32114         * modules/parse-datetime (Makefile.am): Use a phony target and the
32115         general idiom for rules that produce multiple files.
32117 2020-09-13  Ben Pfaff  <blp@cs.stanford.edu>
32119         getpass: Check for nonnull prompt argument while avoiding warnings.
32120         * lib/getpass.c (_GL_ARG_NONNULL): Define to empty.
32121         (getpass) [!_WIN32]: Print prompt only if nonnull.
32123 2020-09-12  Paul Eggert  <eggert@cs.ucla.edu>
32125         dfa: epsilon-closure tweaks (Bug#40634)
32126         Rename BACKWORD to BACKWARD consistently.
32127         * lib/dfa.c (struct dfa): Reorder members to reduce fragmentation.
32128         (addtok_mb): Redo slightly to make it act more like a state machine.
32129         Check depth only when it increases.
32130         (epsclosure): Let the switch test the tokens.
32131         (dfaanalyze): Cache tindex.  Simplify position loops.
32132         Prefer xcalloc to xnmalloc + explicit zeroing.  Free BACKWARD
32133         only if it is not null, since we're testing that anyway.
32134         (dfaanalyze, build_state): Use merge2 instead of doing it by hand.
32136 2020-09-12  Norihiro Tanaka  <noritnk@kcn.ne.jp>
32138         dfa: use backward set in removal of epsilon closure
32139         When removing in epsilon closure, the code searched all nodes
32140         sequentially, and this was slow for some cases.  Build a backward
32141         set before search, and only check previous position with the set.
32142         Problem reported in <https://bugs.gnu.org/40634>.
32143         * lib/dfa.c (struct dfa): New member 'epsilon'.
32144         (addtok_mb): Check whether a pattern has epsilon node or not.
32145         (epsclosure): New arg BACKWORD; caller changed.  When removing
32146         epsilon node and reconnecting, check only previous positions.
32147         Treat BEG as if it were character.
32148         (dfaanalyze): Build backward set.
32150 2020-09-10  Paul Eggert  <eggert@cs.ucla.edu>
32152         canonicalize: fix pointer indexing bugs
32153         Problem reported by Florian Weimer in:
32154         https://lists.gnu.org/r/bug-gnulib/2020-09/msg00025.html
32155         * lib/canonicalize-lgpl.c (__realpath):
32156         * lib/canonicalize.c (canonicalize_filename_mode):
32157         Do not generate a pointer past the end of the array.
32158         * lib/canonicalize.c (canonicalize_filename_mode):
32159         Do not use a pointer after passing it to realloc.
32161 2020-09-09  Paul Eggert  <eggert@cs.ucla.edu>
32163         tempname: help merge with glibc
32164         Inspired by draft patches by Adhemerval Zanella in:
32165         https://sourceware.org/pipermail/libc-alpha/2020-September/117501.html
32166         https://sourceware.org/pipermail/libc-alpha/2020-September/117502.html
32167         * lib/tempname.c: Include stdalign.h, time.h.
32168         If _LIBC, do not include random-bits.h.
32169         (__getrandom, __clock_gettime64, __timespec64) [!_LIBC]: New macros.
32170         (RANDOM_BITS): Remove, replacing with ...
32171         (random_bits): ... this new static function.  All uses changed.
32172         Add entropy each time if getrandom is not supported.
32173         (RANDOM_VALUE, BASE_62_DIGITS, BASE_62_POWER):
32174         Assume 64-bit support a la C99.
32175         (try_tempname_len): Take advantage of ASLR when initializing
32176         random value.
32177         * modules/tempname (Depends-on): Add clock-time, stdalign, time.
32179         getcwd: merge recent glibc changes
32180         * lib/getcwd.c (GETCWD_RETURN_TYPE) [!_LIBC]: New macro.
32181         (__getcwd, getcwd) [_LIBC && !GETCWD_RETURN_TYPE]: Add aliases.
32183 2020-09-06  Bruno Haible  <bruno@clisp.org>
32185         attribute: Clarify which file to include.
32186         * modules/attribute (Include): Add "attribute.h".
32188 2020-09-06  Bruno Haible  <bruno@clisp.org>
32190         pipe-filter-ii, pipe-filter-gi: Fix warnings on native Windows.
32191         * lib/pipe-filter-ii.c: Include <process.h>.
32192         * lib/pipe-filter-gi.c: Likewise.
32194 2020-09-05  Paul Eggert  <eggert@cs.ucla.edu>
32196         verify: avoid __builtin_assume
32197         Our latest attempt to use Clang’s __builtin_assume caused a crash
32198         in GNU Emacs that we spent quite some time tracking down as being
32199         caused by the switch to __builtin_assume.  It’s not known whether
32200         the crash is due is a Clang bug or a portability bug in GNU Emacs.
32201         For now, play it safe and avoid __builtin_assume.
32202         * lib/verify.h (_GL_HAS_BUILTIN_ASSUME): Remove.
32203         (assume): Simplify by not trying to use Clang’s __builtin_assume.
32205 2020-09-05  Bruno Haible  <bruno@clisp.org>
32207         Fix several "warning: no previous prototype for function".
32208         * modules/unicase/locale-language (Makefile.am): Add a 'static' keyword
32209         in front of the declaration of the lookup function in
32210         unicase/locale-languages.h.
32211         * modules/unictype/bidiclass-byname (Makefile.am): Likewise in
32212         unictype/bidi_byname.h.
32213         * modules/unictype/category-byname (Makefile.am): Likewise in
32214         unictype/categ_byname.h.
32215         * modules/unictype/combining-class-byname (Makefile.am): Likewise in
32216         unictype/combiningclass_byname.h.
32217         * modules/unictype/joininggroup-byname (Makefile.am): Likewise in
32218         unictype/joininggroup_byname.h.
32219         * modules/unictype/joiningtype-byname (Makefile.am): Likewise in
32220         unictype/joiningtype_byname.h.
32221         * modules/unictype/property-byname (Makefile.am): Likewise in
32222         unictype/pr_byname.h.
32223         * modules/unictype/scripts (Makefile.am): Likewise in
32224         unictype/scripts_byname.h.
32225         * modules/uninorm/composition (Makefile.am): Likewise in
32226         uninorm/composition-table.h.
32228 2020-09-05  Bruno Haible  <bruno@clisp.org>
32230         select: Fix "warning: no previous prototype for function".
32231         * lib/select.c: Include <sys/select.h>.
32233 2020-09-05  Bruno Haible  <bruno@clisp.org>
32235         Use module 'c99' when needed for variadic macros with '...' syntax.
32236         * modules/crypto/sm3 (Depends-on): Add c99.
32238 2020-09-05  Bruno Haible  <bruno@clisp.org>
32240         Use module 'c99' when needed for subobject initializer syntax.
32241         * modules/tempname (Depends-on): Add c99.
32242         * modules/nstrftime-tests (Depends-on): Likewise.
32244 2020-09-05  Bruno Haible  <bruno@clisp.org>
32246         Use module 'c99' when needed for declaration-after-statement syntax.
32247         * modules/backup-rename (Depends-on): Add c99.
32248         * modules/backupfile (Depends-on): Likewise.
32249         * modules/bitset-tests (Depends-on): Likewise.
32250         * modules/bitsetv (Depends-on): Likewise.
32251         * modules/c-strtod (Depends-on): Likewise.
32252         * modules/c-strtold (Depends-on): Likewise.
32253         * modules/clean-temp (Depends-on): Likewise.
32254         * modules/copy-file (Depends-on): Likewise.
32255         * modules/crypto/hmac-md5-tests (Depends-on): Likewise.
32256         * modules/crypto/hmac-sha1-tests (Depends-on): Likewise.
32257         * modules/crypto/hmac-sha256-tests (Depends-on): Likewise.
32258         * modules/crypto/hmac-sha512-tests (Depends-on): Likewise.
32259         * modules/crypto/md5-buffer (Depends-on): Likewise.
32260         * modules/crypto/md5-tests (Depends-on): Likewise.
32261         * modules/crypto/sha1-buffer (Depends-on): Likewise.
32262         * modules/crypto/sha1-tests (Depends-on): Likewise.
32263         * modules/crypto/sha256-buffer (Depends-on): Likewise.
32264         * modules/crypto/sha256-tests (Depends-on): Likewise.
32265         * modules/crypto/sha512-buffer (Depends-on): Likewise.
32266         * modules/crypto/sha512-tests (Depends-on): Likewise.
32267         * modules/diffseq (Depends-on): Likewise.
32268         * modules/fatal-signal (Depends-on): Likewise.
32269         * modules/fchmodat (Depends-on): Likewise.
32270         * modules/fstrcmp (Depends-on): Likewise.
32271         * modules/fsusage (Depends-on): Likewise.
32272         * modules/fts (Depends-on): Likewise.
32273         * modules/fts-tests (Depends-on): Likewise.
32274         * modules/getumask (Depends-on): Likewise.
32275         * modules/git-merge-changelog (Depends-on): Likewise.
32276         * modules/hash-map (Depends-on): Likewise.
32277         * modules/hash-set (Depends-on): Likewise.
32278         * modules/lchmod (Depends-on): Likewise.
32279         * modules/libgmp-tests (Depends-on): Likewise.
32280         * modules/libtextstyle-optional-tests (Depends-on): Likewise.
32281         * modules/linkedhash-map (Depends-on): Likewise.
32282         * modules/linkedhash-set (Depends-on): Likewise.
32283         * modules/long-options (Depends-on): Likewise.
32284         * modules/mbrtoc32 (Depends-on): Likewise.
32285         * modules/memchr2-tests (Depends-on): Likewise.
32286         * modules/memmem-tests (Depends-on): Likewise.
32287         * modules/memrchr-tests (Depends-on): Likewise.
32288         * modules/mktime-internal (Depends-on): Likewise.
32289         * modules/nstrftime (Depends-on): Likewise.
32290         * modules/opendirat (Depends-on): Likewise.
32291         * modules/parse-datetime (Depends-on): Likewise.
32292         * modules/quotearg-simple-tests (Depends-on): Likewise.
32293         * modules/same (Depends-on): Likewise.
32294         * modules/supersede (Depends-on): Likewise.
32295         * modules/supersede-tests (Depends-on): Likewise.
32296         * modules/time_rz (Depends-on): Likewise.
32297         * modules/unistr/u16-chr-tests (Depends-on): Likewise.
32298         * modules/unistr/u32-chr-tests (Depends-on): Likewise.
32299         * modules/unistr/u8-chr-tests (Depends-on): Likewise.
32300         * modules/xalloc (Depends-on): Likewise.
32301         * modules/xnanosleep (Depends-on): Likewise.
32303 2020-09-05  Bruno Haible  <bruno@clisp.org>
32305         Fix "warning: array initialized from parenthesized string constant".
32306         * tests/test-memmem.c (main): Remove parentheses around string constant.
32307         * tests/test-c-strcasestr.c (main): Likewise.
32308         * tests/test-strcasestr.c (main): Likewise.
32310 2020-09-05  Bruno Haible  <bruno@clisp.org>
32312         argmatch tests: Fix ISO C compliance warning.
32313         * tests/test-argmatch.c: Omit semicolon after ARGMATCH_DEFINE_GROUP
32314         invocation.
32316 2020-09-05  Bruno Haible  <bruno@clisp.org>
32318         uniname/uniname: Fix -Wshadow warning.
32319         * lib/uniname/uniname.c (unicode_name_word): Don't declare i upfront.
32320         * modules/uniname/uniname (Depends-on): Add c99.
32322 2020-09-05  Bruno Haible  <bruno@clisp.org>
32324         uniname/uniname: Fix -Wshorten-64-to-32 warnings.
32325         * lib/uniname/uniname.c (unicode_name_word_lookup): Change type of last
32326         argument to size_t.
32327         (unicode_name_character): Change type of len, n1, n2, n3, words_length,
32328         n to size_t.
32330 2020-09-05  Bruno Haible  <bruno@clisp.org>
32332         unistr/u{8,16,32}-uctomb: Avoid possible trouble with huge strings.
32333         * lib/unistr.in.h (u8_uctomb_aux, u8_uctomb, u16_uctomb_aux, u16_uctomb,
32334         u32_uctomb): Change type of last argument to ptrdiff_t.
32335         * lib/unistr/u8-uctomb.c (u8_uctomb): Likewise.
32336         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Likewise.
32337         * lib/unistr/u16-uctomb.c (u16_uctomb): Likewise.
32338         * lib/unistr/u16-uctomb-aux.c (u16_uctomb_aux): Likewise.
32339         * lib/unistr/u32-uctomb.c (u32_uctomb): Likewise.
32341 2020-09-01  Paul Eggert  <eggert@cs.ucla.edu>
32343         manywarnings: remove -Wchkp and -Wabi from C++ too
32344         Suggested by Reuben Thomas in:
32345         https://lists.gnu.org/r/bug-gnulib/2020-09/msg00001.html
32346         At some point somebody should merge the many other manywarnings-c.m4
32347         changes into manywarnings-c++.m4 too, e.g.,
32348         2020-07-02T00:00:51Z!eggert@cs.ucla.edu.
32349         * m4/manywarnings-c++.m4 (gl_MANYWARN_ALL_GCC_CXX_IMPL):
32350         Remove -Wchkp, -Wabi.
32352 2020-08-30  Bruno Haible  <bruno@clisp.org>
32354         strerrorname_np: Add tests.
32355         * tests/test-strerrorname_np.c: New file.
32356         * modules/strerrorname_np-tests: New file.
32358         strerrorname_np: New module.
32359         * lib/string.in.h (strerrorname_np): New declaration.
32360         * lib/strerrorname_np.c: New file.
32361         * m4/strerrorname_np.m4: New file.
32362         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Test whether strerrorname_np
32363         is declared.
32364         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_STRERRORNAME_NP,
32365         HAVE_STRERRORNAME_NP, REPLACE_STRERRORNAME_NP.
32366         * modules/string (Makefile.am): Substitute GNULIB_STRERRORNAME_NP,
32367         HAVE_STRERRORNAME_NP, REPLACE_STRERRORNAME_NP.
32368         * modules/strerrorname_np: New file.
32369         * tests/test-string-c++.cc: Verify the signature of strerrorname_np.
32370         * doc/glibc-functions/strerrorname_np.texi: Mention the new module and
32371         the glibc 2.32 bug.
32373 2020-08-27  Paul Eggert  <eggert@cs.ucla.edu>
32375         perror, strerror_r: remove unportable tests
32376         Problem reported by Florian Weimer in:
32377         https://lists.gnu.org/r/bug-gnulib/2020-08/msg00220.html
32378         * tests/test-perror2.c (main):
32379         * tests/test-strerror_r.c (main): Omit unportable tests.
32381 2020-08-26  Bruno Haible  <bruno@clisp.org>
32383         stdint, wchar, wctype-h: Change configure message.
32384         * m4/wint_t.m4 (gt_TYPE_WINT_T): Say "checking whether wint_t is large
32385         enough..." instead of "checking whether wint_t is too small...".
32387 2020-08-26  Bruno Haible  <bruno@clisp.org>
32389         time_rz: Change configure message.
32390         * m4/time_rz.m4 (gl_TIME_RZ): Say "checking whether localtime works even
32391         near extrema..." instead of "checking whether localtime loops forever
32392         near extrema...".
32394 2020-08-26  Bruno Haible  <bruno@clisp.org>
32396         stdint: Change configure message.
32397         * m4/stdint.m4 (gl_STDINT_H): Say "checking whether stdint.h works
32398         without ISO C predefines..." instead of "checking whether stdint.h
32399         predates C++11...".
32401 2020-08-26  Bruno Haible  <bruno@clisp.org>
32403         socketlib: Change configure message.
32404         * m4/socketlib.m4 (gl_SOCKETLIB): Say "checking for WSAStartup..."
32405         instead of "checking if we need to call WSAStartup in winsock2.h and
32406         -lws2_32...".
32408 2020-08-26  Bruno Haible  <bruno@clisp.org>
32410         include_next: Change configure message.
32411         * m4/include_next.m4 (gl_INCLUDE_NEXT): Say "checking whether source
32412         code line length is unlimited..." instead of "checking whether system
32413         header files limit the line length...".
32415 2020-08-26  Bruno Haible  <bruno@clisp.org>
32417         getcwd: Change configure message.
32418         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Say "checking
32419         whether getcwd succeeds when 4k < cwd_length < 16k..." instead of
32420         "checking whether getcwd aborts when 4k < cwd_length < 16k...".
32422 2020-08-26  Bruno Haible  <bruno@clisp.org>
32424         chdir-long: Change configure message.
32425         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Say "checking whether this
32426         system supports file names of any length..." instead of "checking
32427         whether this system has an arbitrary file name length limit...".
32428         Set gl_cv_have_unlimited_file_name_length instead of
32429         gl_cv_have_arbitrary_file_name_length_limit.
32430         * modules/chdir-long (Depends-on, configure.ac): Update accordingly.
32432 2020-08-26  Bruno Haible  <bruno@clisp.org>
32434         ceill: Change configure message.
32435         * m4/ceill.m4 (gl_FUNC_CEILL): Say "checking whether ceill() works..."
32436         instead of "checking whether ceill() breaks with small values...".
32438 2020-08-26  Bruno Haible  <bruno@clisp.org>
32440         iconv: Change configure message.
32441         * m4/iconv.m4 (AM_ICONV): Say "checking whether iconv is compatible
32442         with its POSIX signature..." instead of "checking for iconv
32443         declaration...". Remove K&R C support.
32445 2020-08-26  Paul Eggert  <eggert@cs.ucla.edu>
32447         getcwd: help the merge back into glibc
32448         This patch was inspired by Adhemerval Zanella’s proposed glibc patches:
32449         https://sourceware.org/pipermail/libc-alpha/2020-August/117294.html
32450         The idea is to make it easier for Gnulib lib/getcwd.c to match
32451         glibc io/getcwd-generic.c.
32452         * lib/getcwd.c [_LIBC]: Do not include pathmax.h.
32453         Include not-cancel.h.
32454         (HAVE_OPENAT, D_INO_IN_DIRENT, HAVE_MSVC_INVALID_PARAMETER_HANDLER)
32455         (HAVE_MINIMALLY_WORKING_GETCWD): Define for the _LIBC case.
32456         (__getcwd, __lstat, __readdir) [!_LIBC]: Remove these macros.
32457         (__close_nocancel_nostatus, __getcwd_generic, stat64, __fstat64)
32458         (__fstatat64, __lstat64, __readdir64, __fdopendir, __openat)
32459         (__rewinddir, __openat64, dirent64) [_LIBC]: New macros.
32460         (__getcwd_generic): Rename from __getcwd.
32461         Use the abovementioned macros for consistency with glibc.
32462         (weak_alias): Remove.
32464 2020-08-25  Bruno Haible  <bruno@clisp.org>
32466         verify: Avoid warnings when assume(0) is used.
32467         Reported by Mattias Engdegård <mattiase@acm.org> via Paul Eggert in
32468         <https://lists.gnu.org/archive/html/emacs-devel/2020-08/msg00838.html>.
32469         * lib/verify.h (assume): Use __builtin_unreachable if the argument is
32470         the constant 0.
32471         * tests/test-verify.c (f): New function.
32472         (state): New type.
32473         (test_assume_expressions, test_assume_optimization,
32474         test_assume_noreturn): New functions.
32476 2020-08-25  Bruno Haible  <bruno@clisp.org>
32478         fstrcmp: Clarification regarding NOTE_ORDERED.
32479         * lib/fstrcmp.c (NOTE_ORDERED): Define to false.
32481 2020-08-24  Paul Eggert  <eggert@cs.ucla.edu>
32483         diffseq: new option NOTE_ORDERED
32484         Problem reported by Phil Sainty <https://bugs.gnu.org/42931>.
32485         * NEWS: Mention this.
32486         * lib/diffseq.h (NOTE_ORDERED): New macro.
32487         (IF_LINT2): Remove; no longer needed.
32488         (compareseq): If (!NOTE_ORDERED), recurse on the smaller
32489         subproblem and iterate to do the larger.
32491 2020-08-23  Paul Eggert  <eggert@cs.ucla.edu>
32493         sys_types: let Autoconf 2.70 do pid_t
32494         * m4/pid_t.m4 (AC_TYPE_PID_T): Redefine this Autoconf macro
32495         only for Autoconf versions 2.69 and earlier, since 2.70
32496         will be fixed.
32498 2020-08-23  Bruno Haible  <bruno@clisp.org>
32500         tests: Don't assume that pid_t fits in an 'int'.
32501         * tests/test-nonblocking-pipe-main.c (main): Use type 'pid_t' instead
32502         of 'int'.
32503         * tests/test-nonblocking-socket-main.c (main): Likewise.
32505         sys_types: Fix definition of pid_t on 64-bit MSVC.
32506         * m4/pid_t.m4: New file.
32507         * modules/sys_types (Files): Add it.
32508         * modules/dirent (Files): Likewise.
32509         * modules/fcntl-h (Files): Likewise.
32510         * modules/sched (Files): Likewise.
32511         * modules/signal-h (Files): Likewise.
32512         * modules/spawn (Files): Likewise.
32513         * modules/sys_stat (Files): Likewise.
32514         * modules/sys_wait (Files): Likewise.
32515         * modules/termios (Files): Likewise.
32516         * modules/unistd (Files): Likewise.
32518 2020-08-23  Bruno Haible  <bruno@clisp.org>
32520         inttypes: Fix {PRI,SCN}*PTR on 32-bit native Windows (regr. 2020-07-21).
32521         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): Fix syntax error in test
32522         program.
32524 2020-08-23  Paul Eggert  <eggert@cs.ucla.edu>
32526         intprops: be consistent about +X vs X+0
32527         * lib/intprops.h (_GL_SIGNED_INT_MAXIMUM): Simplify.
32529         intprops: fix INT_MULTIPLY_WRAPV bit-field bug
32530         The bug occurs when using INT_MULTIPLY_WRAPV (a, b, c) where B
32531         is a bit-field, on older GCC or non-GCC compilers where we do
32532         things ourselves instead of using __builtin_mul_overflow.
32533         Without this fix, INT_MULTIPLY_WRAPV would not compile, due
32534         to applying sizeof to a bit-field.
32535         * lib/intprops.h (_GL_INT_MULTIPLY_RANGE_OVERFLOW):
32536         Promote B before giving it to TYPE_WIDTH, in case B is a bit-field.
32538 2020-08-23  Bruno Haible  <bruno@clisp.org>
32540         supersede: Avoid a failure when writing to /dev/null in Solaris zones.
32541         Reported by Jörg Sonnenberger <joerg@netbsd.org>
32542         via Thomas Klausner <tk@giga.or.at> in
32543         <https://pkgsrc.se/files.php?messageId=20200812233110.30230FB28@cvs.NetBSD.org>.
32544         * lib/supersede.c (open_supersede): When opening an existing non-regular
32545         file on Solaris, use O_CREAT although it should not be necessary.
32547 2020-08-23  Bruno Haible  <bruno@clisp.org>
32549         verify: Make assume work on bit field expressions (regr. 2020-08-22).
32550         Reported by Benno Schulenberg <bensberg@telfort.nl> in
32551         <https://lists.gnu.org/archive/html/bug-gnulib/2020-08/msg00202.html>.
32552         * lib/verify.h (assume): Use '_Bool' or 'bool' as type of the temporary
32553         variable.
32555 2020-08-23  Bruno Haible  <bruno@clisp.org>
32557         libc-config: Improve comments.
32558         * lib/cdefs.h (__warndecl, __warnattr, __errordecl): Explain why we
32559         cannot use clang's __diagnose_if__ here.
32561 2020-08-22  Bruno Haible  <bruno@clisp.org>
32563         verify: Do use __builtin_assume on clang.
32564         * lib/verify.h (assume): Use clang’s __builtin_assume, with a temporary
32565         variable in a statement expression.
32567 2020-08-22  Bruno Haible  <bruno@clisp.org>
32569         sig2str: Add more signals.
32570         * lib/sig2str.c (numname_table): Add SIGCPUFAIL, SIGTHR, SIGBREAK.
32572 2020-08-22  Bruno Haible  <bruno@clisp.org>
32574         doc: Update for OpenBSD 6.0, 6.7.
32575         * doc/*/*.texi: Update.
32576         * m4/printf.m4: Update comments and cross-compilation guesses.
32577         * m4/ceill.m4: Update comments.
32578         * m4/getcwd-abort-bug.m4: Likewise.
32579         * m4/ilogb.m4: Likewise.
32580         * m4/ilogbf.m4: Likewise.
32581         * m4/langinfo_h.m4: Likewise.
32582         * m4/modf.m4: Likewise.
32583         * m4/modff.m4: Likewise.
32585 2020-08-22  Bruno Haible  <bruno@clisp.org>
32587         doc: Mention sig2str module.
32588         * doc/glibc-functions/sigabbrev_np.texi: Mention the sig2str module.
32590 2020-08-21  Bruno Haible  <bruno@clisp.org>
32592         sigdescr_np: Add tests.
32593         * tests/test-sigdescr_np.c: New file.
32594         * modules/sigdescr_np-tests: New file.
32596         sigdescr_np: New module.
32597         * lib/string.in.h (sigdescr_np): New declaration.
32598         * lib/sigdescr_np.c: New file.
32599         * m4/sigdescr_np.m4: New file.
32600         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Test whether sigdescr_np is
32601         declared.
32602         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_SIGDESCR_NP,
32603         HAVE_SIGDESCR_NP.
32604         * modules/string (Makefile.am): Substitute GNULIB_SIGDESCR_NP,
32605         HAVE_SIGDESCR_NP.
32606         * modules/sigdescr_np: New file.
32607         * tests/test-string-c++.cc: Verify the signature of sigdescr_np.
32608         * doc/glibc-functions/sigdescr_np.texi: Mention the new module.
32610 2020-08-20  Bruno Haible  <bruno@clisp.org>
32612         sigabbrev_np: Add tests.
32613         * tests/test-sigabbrev_np.c: New file.
32614         * modules/sigabbrev_np-tests: New file.
32616         sigabbrev_np: New module.
32617         * lib/string.in.h (sigabbrev_np): New declaration.
32618         * lib/sigabbrev_np.c: New file.
32619         * m4/sigabbrev_np.m4: New file.
32620         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Test whether sigabbrev_np is
32621         declared.
32622         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_SIGABBREV_NP,
32623         HAVE_SIGABBREV_NP.
32624         * modules/string (Makefile.am): Substitute GNULIB_SIGABBREV_NP,
32625         HAVE_SIGABBREV_NP.
32626         * modules/sigabbrev_np: New file.
32627         * tests/test-string-c++.cc: Verify the signature of sigabbrev_np.
32628         * doc/glibc-functions/sigabbrev_np.texi: Mention the new module.
32630 2020-08-20  Bruno Haible  <bruno@clisp.org>
32632         stdalign tests: Skip test with AIX xlclang.
32633         * tests/test-stdalign.c (main): Skip alignas tests with AIX xlclang.
32635 2020-08-20  Bruno Haible  <bruno@clisp.org>
32637         stdalign: Fix test failures on 32-bit platforms with clang versions < 8.
32638         * lib/stdalign.in.h (_Alignof): For clang versions < 8, use the same
32639         workaround as for GCC versions < 4.9.
32641 2020-08-20  Siddhesh Poyarekar  <siddhesh@gotplt.org>
32643         Sync up ProjectQuirks comments and documentation
32644         Transform the ProjectQuirks comments into a docstring so that it can
32645         be accessed from python as ProjectQuirks.__doc__ and harmonize
32646         descriptions with the documentation.
32647         * build-aux/vcstocl/projectquirks.py (ProjectQuirks):
32648         Transform comments into a docstring.
32649         * doc/vcs-to-changelog.texi: Sync up description with comments.
32651         Split ProjectQuirks out into its own file
32652         ProjectQuirks is used by external quirks files and importing it from
32653         vcs-to-changelog.py is broken since it was renamed to use hyphens.  It
32654         is cleaner to put it in its own file anyway.
32655         * build-aux/vcstocl/projectquirks.py: A new file...
32656         * build-aux/vcs-to-changelog.py (ProjectQuirks): ...to which
32657         we move ProjectQuirks and import the file.
32659 2020-08-19  Bruno Haible  <bruno@clisp.org>
32661         uchar: Fix compilation errors in C++ mode on macOS.
32662         * m4/uchar.m4 (gl_UCHAR_H): Require gl_ANSI_CXX if present. Include some
32663         system header file before attempting to use 'char16_t' and 'char32_t'.
32665 2020-08-19  Bruno Haible  <bruno@clisp.org>
32667         ansi-c++-opt: Work around an autoconf macro reordering problem.
32668         * modules/ansi-c++-opt: Require gl_ANSI_CXX already in the early
32669         section.
32671 2020-08-19  Bruno Haible  <bruno@clisp.org>
32673         math C++ tests: Fix compilation error in with GCC 10.
32674         * lib/math.in.h (cbrt, ceil, copysign, exp2, expm1, floor, fma, fmod,
32675         hypot, ilogb, log, log10, log1p, log2, logb, modf, remainder, rint,
32676         round, trunc): Use _GL_CXXALIASWARN1 instead of _GL_CXXALIASWARN.
32678 2020-08-19  Bruno Haible  <bruno@clisp.org>
32680         uchar: Fix compilation errors in C++ mode on OpenBSD.
32681         * lib/uchar.in.h (char16_t, char32_t): Don't define in C++ mode if
32682         CXX_HAS_UCHAR_TYPES is 1.
32683         * m4/uchar.m4 (gl_UCHAR_H): Determine whether the C++ compiler
32684         predefines char16_t and char32_t. Substitute CXX_HAS_UCHAR_TYPES.
32685         * modules/uchar (Makefile.am): Substitute CXX_HAS_UCHAR_TYPES.
32687 2020-08-19  Bruno Haible  <bruno@clisp.org>
32689         Fix compilation errors in C++ mode on OpenBSD.
32690         * lib/math.in.h (isfinite, isinf, isnan, signbit): In C++ mode on
32691         OpenBSD with clang, use the approach without C preprocessor macro.
32693 2020-08-18  Bruno Haible  <bruno@clisp.org>
32695         uchar C++ tests: Fix side effect on math modules (regr. 2020-08-17).
32696         * modules/uchar-c++-tests (configure.ac): Don't use AC_LANG_PUSH and
32697         AC_LANG_POP.
32699 2020-08-17  Paul Eggert  <eggert@cs.ucla.edu>
32701         verify: avoid __built_assume on Clang
32702         * lib/verify.h (assume): Do not use Clang’s __builtin_assume, as
32703         Clang 9 incorrectly diagnoses arguments as having side effects
32704         even when they do not.  I guess Clang 9 considers any function
32705         call as if it had a side effect here.
32707         libc-config: avoid Clang’s __diagnose_if__
32708         * lib/cdefs.h (__warndecl, __warnattr, __errordecl):
32709         For now, do not use __diagnose_if__ here, as this fails
32710         on Fedora 31 with Clang 9.0.1, with diagnostic
32711         "/usr/include/bits/stdio2.h:263:9: error: fgets called with bigger
32712         size than length of destination buffer
32713         [-Werror,-Wuser-defined-warnings]".  I guess Clang 9 warns even
32714         for functions that are not called?
32716         careadlinkat: speedup for GCC 10 with GCC_LINT
32717         Inspired by a suggestion by Bruno Haible in:
32718         https://lists.gnu.org/r/bug-gnulib/2020-08/msg00155.html
32719         * lib/careadlinkat.c (STACK_BUF_SIZE): New constant.
32720         (readlink_stk): New function, with most of the old careadlinkat
32721         contents and with a new STACK_BUF arg.  Inline it in GCC 10
32722         if GCC_LINT.
32723         (careadlinkat): Use the new function for everything but the
32724         stack buffer.
32726         * build-aux/gcc-warning.spec: Update comments.
32728 2020-08-17  Bruno Haible  <bruno@clisp.org>
32730         Assume autoconf >= 2.64.
32731         * m4/std-gnu11.m4 (AC_PROG_CC, AC_PROG_CXX): Use _AC_DO_LIMIT always.
32733 2020-08-17  Bruno Haible  <bruno@clisp.org>
32735         Revert autoupdate's revert.
32736         * config/srclist.txt: Mark regcomp.c as needing sync with glibc.
32738 2020-08-17  Bruno Haible  <bruno@clisp.org>
32740         uchar C++ tests: Fix build error on FreeBSD 12.
32741         * modules/uchar-c++-tests (configure.ac): Test whether <cuchar> exists.
32742         (Makefile.am): Don't include test-uchar-c++2.cc in the compilation if
32743         <cuchar> does not exist.
32745 2020-08-16  Paul Eggert  <eggert@cs.ucla.edu>
32747         time_rz: remove unused functions
32748         * lib/time_rz.c (isdst_differ, equal_tm): Remove; no longer used.
32750         time_rz: fix issues with mktime_z failures
32751         * lib/time_rz.c (mktime_z): Do not update *TM if revert_tz fails.
32752         Use a cheaper tm_yday test for failed mktime.
32754 2020-08-16  Bruno Haible  <bruno@clisp.org>
32756         intprops test: Strengthen on clang.
32757         * tests/test-intprops.c (VERIFY): Use verify_stmt.
32759 2020-08-16  Bruno Haible  <bruno@clisp.org>
32761         nstrftime: Guide inlining also on clang.
32762         * lib/nstrftime.c (iso_week_days): Inline also on clang.
32764 2020-08-16  Bruno Haible  <bruno@clisp.org>
32766         intprops: Avoid bogus "warning: division by zero is undefined" on clang.
32767         * lib/intprops.h (_GL__GENERIC_BOGUS): Define to 1 on clang.
32769 2020-08-16  Bruno Haible  <bruno@clisp.org>
32771         log2l: Disable MSVC workaround on clang.
32772         * lib/log2l.c (log2l): On clang, use the expression 0.0L/0.0L.
32774 2020-08-16  Bruno Haible  <bruno@clisp.org>
32776         argp: Emit a warning also with clang.
32777         * lib/argp-help.c (__argp_short_program_name): Use #warning also on
32778         clang.
32780 2020-08-16  Bruno Haible  <bruno@clisp.org>
32782         libc-config: Enable __REDIRECT macro also on clang.
32783         * lib/cdefs.h (__REDIRECT, __REDIRECT_NTH, __REDIRECT_NTHNL, __ASMNAME,
32784         __ASMNAME2): Define on clang like on GCC.
32786 2020-08-16  Bruno Haible  <bruno@clisp.org>
32788         regex: Use initializer shorthand syntax also with clang.
32789         * lib/regcomp.c (utf8_sb_map): Use the initializer shorthand syntax also
32790         with clang.
32792 2020-08-16  Bruno Haible  <bruno@clisp.org>
32794         regex: Use space optimization also with clang.
32795         * lib/regex_internal.h (re_token_t): Use a single byte for the type also
32796         with clang.
32798 2020-08-16  Bruno Haible  <bruno@clisp.org>
32800         Use _Static_assert and static_assert primitives when present on clang.
32801         * lib/cdefs.h (_Static_assert): Don't define as a macro on clang.
32802         * lib/verify.h (_GL_HAVE__STATIC_ASSERT, _GL_HAVE__STATIC_ASSERT1,
32803         _GL_HAVE_STATIC_ASSERT1): Define as appropriate on clang.
32805 2020-08-16  Bruno Haible  <bruno@clisp.org>
32807         Use 'throw ()' for optimization in C++ mode also on clang.
32808         * lib/cdefs.h (__THROW): Define to 'throw ()' also on clang.
32809         * lib/getopt-cdefs.in.h (__THROW): Likewise.
32810         * lib/md5.h (__THROW): Likewise.
32812 2020-08-16  Bruno Haible  <bruno@clisp.org>
32814         absolute-header: Add support for clang.
32815         * modules/absolute-header (Makefile.am): Include '__clang__' in the
32816         HAVE_INCLUDE_NEXT expression.
32818 2020-08-16  Bruno Haible  <bruno@clisp.org>
32820         Fix "warning: implicitly declaring library function 'strcasecmp'".
32821         * lib/argp-help.c: Include <strings.h>.
32823 2020-08-16  Bruno Haible  <bruno@clisp.org>
32825         stdio: Don't break attribute 'scanf' on clang.
32826         * lib/stdio.in.h (scanf): Treat clang like GCC.
32828 2020-08-16  Bruno Haible  <bruno@clisp.org>
32830         Use __restrict also on clang.
32831         * lib/argp.h (__restrict): Don't define as a macro on clang >= 3.
32832         * lib/glob.in.h (_Restrict_): Use __restrict on clang >= 3.
32833         * lib/unitypes.in.h (_UC_RESTRICT): Likewise.
32835 2020-08-16  Bruno Haible  <bruno@clisp.org>
32837         pthread-spin: Use GCC built-ins also on clang.
32838         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
32839         pthread_spin_trylock, pthread_spin_unlock): Use the newer GCC built-ins
32840         also on clang.
32842 2020-08-16  Bruno Haible  <bruno@clisp.org>
32844         asyncsafe-spin tests: Update.
32845         * tests/test-asyncsafe-spin2.c: Update to match the change in
32846         lib/asyncsafe-spin.c from 2020-08-11.
32848 2020-08-16  Bruno Haible  <bruno@clisp.org>
32850         setenv: Use tree code also with clang.
32851         * lib/setenv.c (USE_TSEARCH): Treat clang like GCC.
32853 2020-08-16  Bruno Haible  <bruno@clisp.org>
32855         math: Optimize signbit also on clang.
32856         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Optimize also
32857         on clang.
32859 2020-08-16  Bruno Haible  <bruno@clisp.org>
32861         avltreehash-list, rbtreehash-list: Optimize also on clang.
32862         * lib/gl_anytreehash_list1.h (add_nodes_to_buckets): Use
32863         __builtin_expect also on clang.
32865 2020-08-16  Bruno Haible  <bruno@clisp.org>
32867         Fix "warning: 'WSASocketA' is deprecated: Use WSASocketW() instead".
32868         * lib/socket.c: Use WSASocketW, not WSASocketA.
32870         Fix "warning: format specifies type 'unsigned long'".
32871         * tests/test-nonblocking-writer.h (main_writer_loop): Cast dbgfprintf
32872         argument to match the format directive.
32874         Fix "warning: no case matching constant switch condition '0'".
32875         * tests/test-fcntl.c (check_flags): Add a 'default' case.
32877         Fix "warning: integer overflow in expression".
32878         * tests/test-strtol.c (main): Use an 'unsigned long' expression to
32879         remove a 'long' overflow.
32881         Fix "warning: "getpagesize" redefined".
32882         * tests/test-getcwd.c (getpagesize): Don't redefine if defined as a
32883         macro.
32885         Fix "warning: implicitly declaring library function 'strncasecmp'".
32886         * lib/strptime.c: Include <strings.h>.
32888         Fix "warning: 'snprintf' macro redefined".
32889         * lib/strerror_r.c (snprintf): Undefine before redefining.
32891         Fix "warning: address of array 'locale' will always evaluate to 'true'".
32892         * lib/nl_langinfo.c (ctype_codeset): Remove redundant NULL test.
32894         Fix "warning: '__stat64' macro redefined".
32895         * lib/glob.c (__stat64): Undefine also on MSVC/clang.
32897         Fix "warning: 'format' attribute argument not supported: rpl_printf".
32898         * lib/stdio.in.h (printf): Treat clang like GCC.
32900         Fix "warning: attribute declaration must precede definition" with clang.
32901         * lib/math.in.h (acosl, asinl, atanl, ceill, cosl, expl, fabsf, fabsl,
32902         floorl, fmodl, frexpf, frexpl, hypotf, hypotl, ldexpf, ldexpl, logl,
32903         log10l, modfl, sinl, sqrtl, tanl): Disable _GL_CXXALIASWARN invocation
32904         on non-glibc systems.
32905         * lib/netdb.in.h (gai_strerror): Likewise.
32906         * lib/stdio.in.h (snprintf, vfscanf, vscanf, vsnprintf): Likewise.
32907         * lib/sys_stat.in.h (fstat): Likewise.
32908         * lib/utime.in.h (utime): Likewise.
32910         Fix undesired warnings.
32911         * lib/sys_select.in.h: Disable all _GL_WARN_ON_USE invocations with
32912         clang.
32914 2020-08-16  Bruno Haible  <bruno@clisp.org>
32916         C++ tests: Fix link errors on MSVC (regression from 2020-05-31).
32917         * modules/stdio-c++-tests (Makefile.am): Link test-stdio-c++ with
32918         $(LIB_GETRANDOM), needed for the rpl_tmpfile symbol.
32919         * modules/stdlib-c++-tests (Makefile.am): Link test-stdlib-c++ with
32920         $(LIB_GETRANDOM), needed for the mkdtemp and mkstemp symbols.
32922 2020-08-16  Bruno Haible  <bruno@clisp.org>
32924         Don't use Autoconf quadrigraphs.
32925         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA): Use '#' instead of the corresponding
32926         Autoconf quadrigraph.
32927         * m4/free.m4 (gl_FUNC_FREE): Likewise.
32928         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Likewise.
32929         * m4/largefile.m4 (_AC_SYS_LARGEFILE_TEST_INCLUDES,
32930         _AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
32931         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
32932         * m4/math_h.m4 (gl_MATH_H): Likewise.
32933         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Likewise.
32935 2020-08-16  Bruno Haible  <bruno@clisp.org>
32937         Fix quoting of AC_LANG_PROGRAM arguments.
32938         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Quote the AC_LANG_PROGRAM
32939         arguments through [[...]].
32940         * m4/fpending.m4 (gl_FUNC_FPENDING): Likewise.
32941         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
32942         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Likewise.
32943         * m4/ld-output-def.m4 (gl_LD_OUTPUT_DEF): Likewise.
32944         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT): Likewise.
32945         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
32946         * m4/mountlist.m4 (gl_MOUNTLIST): Likewise.
32947         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
32948         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
32949         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Likewise.
32950         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Likewise.
32951         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Likewise.
32952         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
32954 2020-08-16  Bruno Haible  <bruno@clisp.org>
32956         Assume autoconf >= 2.64.
32957         * gnulib-tool (DEFAULT_AUTOCONF_MINVERSION): Set to 2.64.
32958         * DEPENDENCIES: Require Autoconf 2.64 or newer.
32959         * NEWS: Mention the changed requirement.
32960         * m4/00gnulib.m4 (_m4_divert_diversion, AC_DEFUN_ONCE): Remove macros.
32961         * m4/gnulib-common.m4 (AS_VAR_IF, AS_VAR_COPY): Remove macros.
32962         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Quote pushdef'ed
32963         variables.
32964         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Likewise.
32965         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Likewise.
32966         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Likewise.
32967         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C), gl_UNKNOWN_WARNINGS_ARE_ERRORS(C++),
32968         gl_UNKNOWN_WARNINGS_ARE_ERRORS(Objective C)): Define through AC_DEFUN.
32969         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C), gl_MANYWARN_ALL_GCC(C++)):
32970         Likewise.
32971         * m4/iconv.m4 (AM_ICONV): Define through AC_DEFUN_ONCE directly.
32972         * m4/libunistring.m4 (gl_LIBUNISTRING): Likewise.
32973         * m4/configmake.m4: Update comment.
32975 2020-08-16  Bruno Haible  <bruno@clisp.org>
32977         sys_ioctl: Simplify.
32978         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Remove confusing use of
32979         AC_INCLUDES_DEFAULT.
32981 2020-08-16  Bruno Haible  <bruno@clisp.org>
32983         Fix quoting of AC_LANG_SOURCE arguments.
32984         * m4/printf.m4 (gl_PRINTF_ENOMEM): Fix an m4 quoting bug in the
32985         GL_NOCRASH expansion.
32986         * m4/locale-ar.m4 (gt_LOCALE_AR): Simplify m4 quoting.
32987         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
32988         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
32989         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
32990         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
32992 2020-08-15  Paul Eggert  <eggert@cs.ucla.edu>
32994         nstrftime: be more predictable about errno
32995         This aligns nstrftime better with draft POSIX 202x strftime.
32996         * lib/nstrftime.c: Include errno.h.
32997         (width_add, __strftime_internal): Set errno on failure,
32998         and preserve it on success.  Check for mktime_z failure.
32999         * modules/nstrftime (Depends-on): Add errno.
33000         * modules/nstrftime-tests (Depends-on): Add atoll, intprops.
33001         * tests/test-nstrftime.c: Include intprops.h, limits.h.
33002         (errno_test): New test function.
33003         (main): Call it.
33005 2020-08-15  Bruno Haible  <bruno@clisp.org>
33007         canonicalize: Fix a problem of the autoconf test on MSVC/clang.
33008         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Remove undesired file
33009         from dependency analysis first.
33011 2020-08-15  Bruno Haible  <bruno@clisp.org>
33013         Determine asm output option and filename suffix for MSVC/clang.
33014         * m4/asm-underscore.m4 (gl_C_ASM): Distinguish clang from cl and
33015         clang-cl.
33017 2020-08-15  Bruno Haible  <bruno@clisp.org>
33019         doc: Update for MSVC/clang.
33020         * doc/*-functions/*printf.texi: Mention that MSVC/clang has two bugs
33021         that MSVC 14 does not have.
33023 2020-08-15  Bruno Haible  <bruno@clisp.org>
33025         Revert autoupdate's revert.
33026         * config/srclist.txt: Mark mktime.c as needing sync with glibc.
33028 2020-08-15  Bruno Haible  <bruno@clisp.org>
33030         frexpl: Fix configuration test result on MSVC.
33031         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Avoid a division by a constant
33032         zero.
33034 2020-08-15  Bruno Haible  <bruno@clisp.org>
33036         Support compiling without -loldnames on native Windows.
33037         * m4/gnulib-common.m4 (GL_MDA_DEFINES, _GL_MDA_DEFINES): New macros.
33038         * m4/chown.m4 (AC_FUNC_CHOWN): In the test programs, use GL_MDA_DEFINES.
33039         (gl_FUNC_CHOWN, gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Likewise.
33040         * m4/dup.m4 (gl_FUNC_DUP): Likewise.
33041         * m4/dup2.m4 (gl_FUNC_DUP2): Likewise.
33042         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
33043         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): Likewise.
33044         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Likewise.
33045         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Likewise.
33046         * m4/fcntl.m4 (gl_FUNC_FCNTL): Likewise.
33047         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Likewise.
33048         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Likewise.
33049         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Likewise.
33050         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): Likewise.
33051         * m4/freopen.m4 (gl_FUNC_FREOPEN): Likewise.
33052         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Likewise.
33053         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
33054         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
33055         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL, gl_FUNC_GETCWD_SIGNATURE):
33056         Likewise.
33057         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Likewise.
33058         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
33059         * m4/lseek.m4 (gl_FUNC_LSEEK): Likewise.
33060         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
33061         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
33062         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Likewise.
33063         * m4/open-slash.m4 (gl_OPEN_TRAILING_SLASH_BUG): Likewise.
33064         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
33065         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Likewise.
33066         * m4/pread.m4 (gl_FUNC_PREAD): Likewise.
33067         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
33068         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Likewise.
33069         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Likewise.
33070         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
33071         * m4/pwrite.m4 (gl_FUNC_PWRITE): Likewise.
33072         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
33073         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
33074         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
33075         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
33076         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
33077         * m4/strncat.m4 (gl_FUNC_STRNCAT): Likewise.
33078         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Likewise.
33079         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
33080         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
33081         * m4/utimens.m4 (gl_UTIMENS): Likewise.
33082         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
33083         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
33084         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL): On native Windows, don't
33085         test for getcwd.
33086         * m4/utime.m4 (gl_FUNC_UTIME): On native Windows, don't test for utime.
33087         * m4/wcsdup.m4 (gl_FUNC_WCSDUP): To test for wcsdup, use a test program
33088         with GL_MDA_DEFINES.
33089         * lib/c++defs.h (_GL_CXXALIAS_MDA): New macro.
33090         * lib/fcntl.in.h (creat, open):  On native Windows, use the underscore-
33091         prefixed symbol.
33092         * lib/search.in.h (lfind, lsearch): Likewise.
33093         * lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
33094         Likewise.
33095         * lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
33096         * lib/string.in.h (memccpy, strdup): Likewise.
33097         * lib/sys_stat.in.h (chmod, umask): Likewise.
33098         * lib/time.in.h (tzset): Likewise.
33099         * lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
33100         execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
33101         read, rmdir, swab, unlink, write): Likewise.
33102         * lib/utime.in.h (utime): Likewise.
33103         * lib/wchar.in.h (wcsdup): Likewise.
33104         * lib/math.in.h (j0, j1, jn, y0, y1, yn):  Likewise.
33105         (isfinite, isinf, isnan, signbit): On native Windows, don't define as an
33106         rpl_-prefixed macro.
33107         * lib/canonicalize-lgpl.c (__getcwd): On native Windows, use _getcwd.
33108         * lib/close.c (close_nothrow): On native Windows, use _close.
33109         * lib/creat.c (orig_creat): On native Windows, use _creat.
33110         * lib/dup.c (dup_nothrow): On native Windows, use _dup.
33111         * lib/dup2.c (dup2_nothrow): Use _dup2.
33112         * lib/fdopen.c (fdopen_nothrow): On native Windows, use _fdopen.
33113         * lib/getcwd-lgpl.c: On native Windows, use _getcwd.
33114         * lib/getcwd.c (getcwd_nothrow): Use _getcwd also on mingw.
33115         * lib/open.c (orig_open): On native Windows, use _open.
33116         * lib/read.c (read_nothrow): Use _read.
33117         * lib/rmdir.c: On native Windows, use _rmdir.
33118         * lib/unlink.c: On native Windows, use _unlink.
33119         * lib/write.c (write_nothrow): Use _write.
33120         * lib/sys_select.in.h (close): With clang, don't attach a warning on an
33121         undefined symbol.
33122         * lib/sys_socket.in.h (close): Likewise.
33123         * lib/sys_time.in.h (close): Likewise.
33124         * tests/test-spawn-pipe-child.c: On native Windows, use _fdopen.
33126 2020-08-15  Bruno Haible  <bruno@clisp.org>
33128         Fix "unknown pragma ignored" warnings with clang on native Windows.
33129         * lib/cbrt.c: Don't use '#pragma fenv_access (off)' with clang.
33130         * lib/cbrtf.c: Likewise.
33131         * lib/ceil.c: Likewise.
33132         * lib/floor.c: Likewise.
33133         * lib/fma.c: Likewise.
33134         * lib/fmod.c: Likewise.
33135         * lib/rint.c: Likewise.
33136         * lib/round.c: Likewise.
33137         * lib/trunc.c: Likewise.
33138         * tests/test-ceil2.c: Likewise.
33139         * tests/test-ceilf2.c: Likewise.
33140         * tests/test-floor2.c: Likewise.
33141         * tests/test-floorf2.c: Likewise.
33142         * tests/test-trunc2.c: Likewise.
33143         * tests/test-truncf2.c: Likewise.
33144         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
33145         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
33147 2020-08-15  Bruno Haible  <bruno@clisp.org>
33149         Fix compilation errors in C++ mode with clang on native Windows.
33150         * lib/pthread.in.h (pthread_*): Disable _GL_CXXALIASWARN invocation on
33151         non-glibc systems.
33152         * lib/sched.in.h (sched_yield): Likewise.
33154 2020-08-14  Bruno Haible  <bruno@clisp.org>
33156         stdnoreturn: Work around problem with MSVC/clang.
33157         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): On native Windows, include some
33158         system header after <stdnoreturn.h>.
33159         * doc/posix-headers/stdnoreturn.texi: Mention the issue.
33161 2020-08-14  Bruno Haible  <bruno@clisp.org>
33163         utime-h: Generate an utime.h file always.
33164         * modules/utime-h (Makefile.am): Generate utime.h always.
33165         * m4/utime_h.m4 (gl_UTIME_H): Don't set UTIME_H. Don't define
33166         GL_GENERATE_UTIME_H.
33168 2020-08-14  Bruno Haible  <bruno@clisp.org>
33170         mktime, mktime-internal: Remove obsolete code.
33171         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Don't #undef putenv.
33173 2020-08-14  Bruno Haible  <bruno@clisp.org>
33175         getcwd: Remove obsolete code.
33176         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Don't #undef mkdir.
33177         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
33179 2020-08-14  Bruno Haible  <bruno@clisp.org>
33181         tzset: Assume the function exists.
33182         * lib/time.in.h (tzset): Assume HAVE_TZSET is 1.
33183         * lib/tzset.c: Define rpl_tzset, not tzset. Assume HAVE_TZSET is 1.
33184         * modules/tzset (configure.ac): Don't test HAVE_TZSET.
33185         * m4/tzset.m4 (gl_FUNC_TZSET): Don't test for tzset. Don't set
33186         HAVE_TZSET.
33187         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Don't initialize HAVE_TZSET.
33188         * modules/time (Makefile.am): Don't substitute HAVE_TZSET.
33190         nstrftime: Assume tzset exists.
33191         * lib/nstrftime.c (HAVE_TZSET): Remove macro.
33192         (__strftime_internal): Test my_strftime, not HAVE_TZSET.
33193         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Don't test for tzset.
33195         mktime, mktime-internal: Assume tzset exists.
33196         * lib/mktime.c (my_tzset): Assume HAVE_TZSET is 1.
33197         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Don't test for tzset.
33199 2020-08-14  Bruno Haible  <bruno@clisp.org>
33201         strdup: Assume the function exists.
33202         * m4/strdup.m4 (gl_FUNC_STRDUP, gl_FUNC_STRDUP_POSIX): Don't test
33203         whether strdup exists.
33204         * modules/strdup (Files): Remove lib/strdup.c.
33205         (configure.ac): Don't compile strdup.c.
33206         * modules/strdup-posix (Depends-on, configure.ac): Don't test
33207         ac_cv_func_strdup.
33208         * doc/posix-functions/strdup.texi: Update.
33209         * lib/unistr/u8-strdup.c: Assume HAVE_STRDUP is 1.
33210         * modules/unistr/u8-strdup (Files): Remove lib/unistr/u-strdup.h.
33211         (Depends-on): Remove unistr/u8-strlen.
33213 2020-08-13  Bruno Haible  <bruno@clisp.org>
33215         sys_random: Work around an uClibc bug.
33216         Reported by akater <nuclearspace@gmail.com>
33217         via Stefan Kangas <stefan@marxist.se>
33218         in <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=42236>.
33219         * lib/sys_random.in.h: On uClibc, include <stddef.h> first.
33220         * m4/sys_random_h.m4 (gl_HEADER_SYS_RANDOM): Update comment.
33221         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
33222         * doc/glibc-headers/sys_random.texi: Mention the uClibc bug.
33224 2020-08-12  Bruno Haible  <bruno@clisp.org>
33226         Avoid implicit conversion from 'unsigned int' to 'int' in initializers.
33227         Reported by Florian Weimer in
33228         <https://lists.gnu.org/archive/html/bug-gnulib/2020-08/msg00086.html>.
33229         * lib/gen-uni-tables.c (output_predicate): Change the element type of
33230         the level3 array to 'unsigned int'.
33231         * lib/unictype/bitmap.h (bitmap_lookup): Access an 'unsigned int'.
33232         * lib/unictype/categ_*.h: Regenerated.
33233         * lib/unictype/ctype_*.h: Regenerated.
33234         * lib/unictype/pr_*.h: Regenerated.
33235         * lib/unictype/sy_*.h: Regenerated.
33236         * lib/unicase/cased.h: Regenerated.
33237         * lib/unicase/ignorable.h: Regenerated.
33239 2020-08-12  Paul Eggert  <eggert@cs.ucla.edu>
33241         stdint: port intptr_t to more-recent MinGW
33242         Problem reported by Eli Zaretskii in <https://bugs.gnu.org/36597#106>.
33243         * lib/stdint.in.h (intptr_t, uintptr_t): Do not define on MinGW,
33244         even if _INTPTR_T_DEFINED and _UINTPTR_T_DEFINED are not defined.
33245         Apparently those two macros were removed in mingwrt-3.22
33246         dated 2016-07-14.
33248 2020-08-12  Bruno Haible  <bruno@clisp.org>
33250         thread-optim: Export function-like macros only.
33251         Suggested by Paul Eggert.
33252         * lib/thread-optim.h (gl_multithreaded): New macro.
33253         (IF_MT_DECL, IF_MT): Remove macros.
33254         * doc/multithread.texi (Multithreading Optimizations): Add a small
33255         example.
33256         * lib/fatal-signal.c: Update all uses.
33257         * lib/clean-temp.c: Likewise.
33258         * lib/localename.c: Likewise.
33259         * modules/localename (Depends-on): Add stdbool.
33261 2020-08-12  Bruno Haible  <bruno@clisp.org>
33263         Revert autoupdate's revert.
33264         * config/srclist.txt: Mark regex.h as needing sync with glibc.
33266 2020-08-11  Bruno Haible  <bruno@clisp.org>
33268         thread-optim: Fix a compiler warning.
33269         * lib/thread-optim.h (IF_MT_DECL): Define differently.
33271 2020-08-11  Bruno Haible  <bruno@clisp.org>
33273         Use __restrict also on clang.
33274         * lib/cdefs.h (__restrict): Don't define as a macro on clang.
33275         (__restrict_arr): On clang, define like on GCC.
33276         * lib/regex.h (_Restrict_): Use '__restrict' also on clang.
33277         (_Restrict_arr_): Use _Restrict_ also on clang.
33278         * lib/spawn.in.h (_Restrict_): Use '__restrict' also on clang.
33279         (_Restrict_arr_): Use _Restrict_ also on clang.
33281 2020-08-11  Bruno Haible  <bruno@clisp.org>
33283         Use flexible array syntax also on clang.
33284         * lib/cdefs.h (__flexarr, __glibc_c99_flexarr_available): For clang,
33285         define like for GCC 3.
33287 2020-08-11  Bruno Haible  <bruno@clisp.org>
33289         fcntl: On native Windows, use _setmode, not setmode.
33290         * lib/fcntl.c (dupfd): Use _setmode, not setmode.
33291         * lib/binary-io.h: Update comment.
33292         * tests/test-cloexec.c: Call set_binary_mode, not setmode.
33293         * tests/test-dup2.c: Likewise.
33294         * tests/test-dup-safer.c: Likewise.
33295         * tests/test-fcntl.c: Likewise.
33297 2020-08-11  Bruno Haible  <bruno@clisp.org>
33299         execute, spawn-pipe: Use _spawnvpe, not spawnvpe.
33300         * lib/execute.c (execute): Use _spawnvpe, not spawnvpe.
33301         * lib/spawn-pipe.c (create_pipe): Likewise.
33302         * tests/test-nonblocking-pipe-main.c (main): Likewise.
33303         * tests/test-nonblocking-socket-main.c (main): Likewise.
33304         * lib/wait-process.c: Update comment.
33305         * doc/posix-functions/fork.texi: Update.
33307 2020-08-11  Bruno Haible  <bruno@clisp.org>
33309         asyncsafe-spin: Use GCC built-ins also on clang.
33310         * lib/asyncsafe-spin.c (asyncsafe_spin_init, do_lock, do_unlock): Use
33311         the newer GCC built-ins also on clang.
33313 2020-08-11  Bruno Haible  <bruno@clisp.org>
33315         Use expression statements also on clang.
33316         * lib/cdefs.h (__extension__): Don't define to empty on clang.
33317         * lib/obstack.h (__extension__): Likewise.
33318         (obstack_object_size, obstack_room, obstack_make_room, obstack_empty_p,
33319         obstack_grow, obstack_grow0, obstack_1grow, obstack_ptr_grow,
33320         obstack_int_grow, obstack_ptr_grow_fast, obstack_int_grow_fast,
33321         obstack_blank, obstack_alloc, obstack_copy, obstack_copy0,
33322         obstack_finish, obstack_free): Enable as optimized macros also on clang.
33323         * lib/fpucw.h (fpucw_t etc.): Enable the definitions also on clang.
33325 2020-08-10  Bruno Haible  <bruno@clisp.org>
33327         Use many __attribute__s with clang.
33328         * m4/gnulib-common.m4 (_Noreturn): Use __attribute__ __noreturn__ also
33329         on clang.
33330         * lib/cdefs.h (__glibc_clang_has_attribute, __glibc_clang_has_builtin):
33331         New macros.
33332         (__THROW, __THROWNL, __NTH, __NTHNL): Use __attribute__ __nothrow__ also
33333         on clang.
33334         (__warndecl, __warnattr, __errordecl): Use __attribute__ __diagnose_if__
33335         also on older clang versions.
33336         (__attribute__): Don't define to empty on clang.
33337         (__attribute_malloc__): Use __attribute__ __malloc__ also on clang.
33338         (__attribute_pure__): Use __attribute__ __pure__ also on clang.
33339         (__attribute_const__): Use __attribute__ __const__ also on clang.
33340         (__attribute_used__): Use __attribute__ __used__ also on clang.
33341         (__attribute_noinline__): Use __attribute__ __noinline__ also on clang.
33342         (__attribute_deprecated__): Use __attribute__ __deprecated__ also on
33343         clang.
33344         (__attribute_format_arg__): Use __attribute__ __format_arg__ also on
33345         clang.
33346         (__attribute_format_strfmon__): Use __attribute__ __format__ __strfmon__
33347         also on clang.
33348         (__nonnull): Use __attribute__ __nonnull__ also on clang.
33349         (__attribute_warn_unused_result__): Use __attribute__
33350         __warn_unused_result__ also on clang.
33351         (__always_inline): Use __attribute__ __always_inline__ also on clang.
33352         (__attribute_artificial__): Use __attribute__ __artificial__ also on
33353         clang >= 7.
33354         (__glibc_unlikely, __glibc_likely): Use __builtin_expect also on older
33355         clang versions.
33356         (_Noreturn): Don't redefine on clang >= 3.5.
33357         * lib/arg-nonnull.h (_GL_ARG_NONNULL): Use __attribute__ __nonnull__
33358         also on clang.
33359         * lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Use __attribute__ __pure__ also
33360         on clang.
33361         * lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Likewise.
33362         * lib/string.in.h (_GL_ATTRIBUTE_PURE): Likewise.
33363         * lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
33364         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT): Use __attribute__ __format__
33365         also on clang.
33366         * lib/monetary.in.h (_GL_ATTRIBUTE_FORMAT): Likewise.
33367         * lib/textstyle.in.h (ostream_printf, ostream_vprintf): Likewise.
33368         * lib/unitypes.in.h (_UC_ATTRIBUTE_CONST): Use __attribute__ __const__
33369         also on clang.
33370         (_UC_ATTRIBUTE_PURE): Use __attribute__ __pure__ also on clang.
33371         * lib/noreturn.h (_GL_NORETURN_FUNC, _GL_NORETURN_FUNCPTR): Use
33372         __attribute__ __noreturn__ also on clang.
33373         * lib/obstack.h (__attribute_noreturn__): Likewise.
33374         * lib/file-set.h (record_file): Use __attribute__ __nonnull__ also on
33375         clang.
33376         * lib/argp-help.c (hol_entry_long_iterate): Use __attribute__
33377         always_inline also on clang.
33378         * tests/test-printf-posix.c (func1, func2, func3, func4): Test also on
33379         clang.
33381 2020-08-10  Bruno Haible  <bruno@clisp.org>
33383         c-ldtoastr tests: Fix test failure.
33384         * tests/test-c-ldtoastr.c (main): Support platforms where 'long double'
33385         is longer than 'double'.
33387 2020-08-10  Bruno Haible  <bruno@clisp.org>
33389         Revert autoupdate's revert.
33390         * config/srclist.txt: Mark intprops.h as needing sync with glibc.
33392 2020-08-09  Bruno Haible  <bruno@clisp.org>
33394         string: Fix build error in C++ mode with clang (regression from today).
33395         * lib/warn-on-use.h (_GL_WARN_ON_USE_CXX): Expect two rettype
33396         parameters, one for GCC, one for clang.
33397         * lib/c++defs.h (_GL_CXXALIASWARN1_2): Update.
33398         * lib/string.in.h (strchr, strpbrk, strrchr): For clang, pass 'char *'
33399         as return type.
33401 2020-08-09  Bruno Haible  <bruno@clisp.org>
33403         ftruncate: Use _chsize, not chsize.
33404         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): Test for _chsize, not chsize.
33405         * lib/ftruncate.c: Test HAVE__CHSIZE.
33406         (chsize_nothrow): Use _chsize, not chsize.
33408 2020-08-09  Bruno Haible  <bruno@clisp.org>
33410         Silence warnings from clang 10 with -Wimplicit-fallthrough.
33411         * lib/dfa.c (FALLTHROUGH): Use __attribute__ __fallthrough__ also on
33412         clang >= 10.
33413         * lib/fnmatch.c (FALLTHROUGH): Likewise.
33414         * lib/fts.c (FALLTHROUGH): Likewise.
33415         * tests/macros.h (FALLTHROUGH): Likewise.
33416         * lib/regex_internal.h (FALLTHROUGH): Likewise.
33417         * config/srclist.txt: Mark it as needing sync with glibc.
33419 2020-08-09  Bruno Haible  <bruno@clisp.org>
33421         stdbool tests: Enable the stricter tests also on clang.
33422         * tests/test-stdbool.c (ADDRESS_CHECK_OKAY): Define also on clang.
33423         (e): Enable the address-to-bool conversion test also on clang.
33425 2020-08-09  Bruno Haible  <bruno@clisp.org>
33427         count-one-bits: Use __builtin_popcount{,l,ll} on clang.
33428         * lib/count-one-bits.h (COUNT_ONE_BITS): Use the GCC built-in.
33430 2020-08-09  Bruno Haible  <bruno@clisp.org>
33432         Use attribute __aligned__ with clang.
33433         * lib/stdalign.in.h (_Alignas): Treat clang like GCC.
33434         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS): Likewise.
33436 2020-08-09  Bruno Haible  <bruno@clisp.org>
33438         Use __alignof__ with clang.
33439         * m4/stddef_h.m4 (gl_STDDEF_H): Test the alignment of max_align_t also
33440         on clang.
33441         * lib/alignof.h (alignof_type): Use __alignof__ also on clang.
33442         * lib/stdalign.in.h (_Alignof): Don't activate the GCC workaround on
33443         clang.
33444         * lib/malloca.h (sa_alignof): Use __alignof__ also on clang.
33445         * lib/bitset/list.c (lbitset_elt_alloc): Use __alignof__ also on clang.
33446         * lib/bitset/table.c (tbitset_elt_alloc): Likewise.
33447         * tests/test-stddef.c: Very the behaviour of __alignof__ also on clang.
33449 2020-08-09  Bruno Haible  <bruno@clisp.org>
33451         ignore-value: Simplify on clang.
33452         * lib/ignore-value.h (ignore_value): With clang, no need to use the GCC
33453         workaround.
33455 2020-08-09  Bruno Haible  <bruno@clisp.org>
33457         Use __typeof__ with clang.
33458         * m4/stdint.m4 (gl_STDINT_H): Check for SIZE_MAX also on
33459         "clang -std=gnu99".
33460         * lib/intprops.h (_GL_HAVE___TYPEOF__): Define to 1 also on clang.
33461         * tests/test-stdint.c (verify_same_types): Enable the check also on
33462         clang.
33464 2020-08-09  Bruno Haible  <bruno@clisp.org>
33466         Add ability to emit user-defined warnings and errors with clang.
33467         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _GL_ATTRIBUTE_ERROR,
33468         _GL_ATTRIBUTE_WARNING using an attribute for clang.
33469         * lib/warn-on-use.h (_GL_WARN_ON_USE, _GL_WARN_ON_USE_ATTRIBUTE,
33470         _GL_WARN_ON_USE_CXX): Define using an attribute for clang.
33471         * lib/cdefs.h (__warndecl, __warnattr, __errordecl): Define using an
33472         attribute for clang.
33474 2020-08-09  Bruno Haible  <bruno@clisp.org>
33476         intprops: Fix typo in comment.
33477         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_P): Fix typo in comment.
33479 2020-08-09  Bruno Haible  <bruno@clisp.org>
33481         Use __builtin_signbit* with clang.
33482         * lib/math.in.h (signbit): Use __builtin_signbit{,f,l} also on clang.
33483         * m4/signbit.m4 (gl_SIGNBIT): Use __builtin_signbit{,f,l} also on clang.
33484         Set REPLACE_SIGNBIT_USING_BUILTINS, not REPLACE_SIGNBIT_USING_GCC.
33485         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize
33486         REPLACE_SIGNBIT_USING_BUILTINS, not REPLACE_SIGNBIT_USING_GCC.
33487         * modules/math (Makefile.am): Substitute REPLACE_SIGNBIT_USING_BUILTINS,
33488         not REPLACE_SIGNBIT_USING_GCC.
33490 2020-08-09  Bruno Haible  <bruno@clisp.org>
33492         Use __builtin_isnan with clang.
33493         * lib/isnanf-nolibm.h (isnanf): Use the GCC built-in __builtin_isnan,
33494         not __builtin_isnanf. Also on clang.
33495         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_ISNANF_WORKS): Use the GCC
33496         built-in __builtin_isnan, not __builtin_isnanf. Also on clang.
33497         * lib/isnand-nolibm.h (isnand): With clang, use the GCC built-in.
33498         * m4/isnand.m4 (gl_HAVE_ISNAND_IN_LIBM): With clang, use the GCC
33499         built-in.
33500         * lib/isnanl-nolibm.h (isnanf): Use the GCC built-in __builtin_isnan,
33501         not __builtin_isnanl. Also on clang.
33502         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_FUNC_ISNANL_WORKS): Use the
33503         GCC built-in __builtin_isnan, not __builtin_isnanl. Also on clang.
33504         * lib/math.in.h (__has_builtin): Remove macro.
33505         (isnanf, gl_isnan_f): Use the GCC built-in __builtin_isnan, not
33506         __builtin_isnanf. Also on clang.
33507         (isnand, gl_isnan_d): With clang, use the GCC built-in.
33508         (isnanl, gl_isnan_l): Use the GCC built-in __builtin_isnan, not
33509         __builtin_isnanl. Also on clang.
33510         (isnan): Use the GCC built-in __builtin_isnan in all three cases. Also
33511         on clang.
33513 2020-08-09  Bruno Haible  <bruno@clisp.org>
33515         thread-optim: Fix logic error.
33516         Reported by Paul Eggert.
33517         * lib/thread-optim.h (IF_MT): Fix logic error.
33519 2020-08-08  Bruno Haible  <bruno@clisp.org>
33521         localename: Use module 'thread-optim'.
33522         * lib/localename.c: Include thread-optim.h.
33523         (struniq): Use IF_MT macro.
33524         * modules/localename (Depends-on): Add thread-optim.
33526         clean-temp: Use module 'thread-optim'.
33527         * lib/clean-temp.c: Include thread-optim.h.
33528         (register_temporary_file, unregister_temporary_file, create_temp_dir,
33529         register_temp_file, unregister_temp_file, register_temp_subdir,
33530         unregister_temp_subdir, cleanup_temp_dir_contents, register_fd,
33531         close_temp, fclose_variant_temp): Use IF_MT macro.
33532         * modules/clean-temp (Depends-on): Add thread-optim.
33534         fatal-signal: Use module 'thread-optim'.
33535         * lib/fatal-signal.c: Include thread-optim.h.
33536         (at_fatal_signal, block_fatal_signals, unblock_fatal_signals): Use IF_MT
33537         macro.
33538         * modules/fatal-signal (Depends-on): Add thread-optim.
33540 2020-08-08  Bruno Haible  <bruno@clisp.org>
33542         New module 'thread-optim'.
33543         * lib/thread-optim.h: New file.
33544         * modules/thread-optim: New file.
33545         * doc/multithread.texi (Multithreading Optimizations): New section.
33547 2020-08-07  Paul Eggert  <eggert@cs.ucla.edu>
33549         doc: more updates for glibc 2.32
33550         * doc/glibc-functions/lchmod.texi, doc/posix-functions/faccessat.texi:
33551         * doc/posix-functions/fchmodat.texi: Update.
33553 2020-08-07  Bruno Haible  <bruno@clisp.org>
33555         doc: Update for glibc 2.32.
33556         * doc/glibc-functions/__libc_single_threaded.texi: New file.
33557         * doc/glibc-functions/pthread_attr_getsigmask_np.texi: New file.
33558         * doc/glibc-functions/pthread_attr_setsigmask_np.texi: New file.
33559         * doc/glibc-functions/sigabbrev_np.texi: New file.
33560         * doc/glibc-functions/sigdescr_np.texi: New file.
33561         * doc/glibc-functions/strerrordesc_np.texi: New file.
33562         * doc/glibc-functions/strerrorname_np.texi: New file.
33563         * doc/gnulib.texi: Include them.
33564         (Glibc sys/single_threaded.h): New section.
33565         * doc/pastposix-functions/h_errno.texi: Update.
33566         * doc/posix-functions/*.texi: Likewise.
33567         * doc/glibc-functions/*.texi: Likewise.
33569 2020-08-07  Bruno Haible  <bruno@clisp.org>
33571         alloca: No need to compile alloca.c with clang.
33572         * lib/alloca.c: Skip all code with clang.
33574         Use __builtin_alloca with clang.
33575         * lib/alloca.in.h (alloca): Define as __builtin_alloca on clang.
33577 2020-08-06  Bruno Haible  <bruno@clisp.org>
33579         Use __builtin_assume with clang.
33580         * lib/verify.h (_GL_HAS_BUILTIN_ASSUME): New macro.
33581         (assume): Use __builtin_assume when available.
33583 2020-08-06  Paul Eggert  <eggert@cs.ucla.edu>
33585         libgmp: add <gmp/gmp.h> support
33586         * m4/libgmp.m4 (gl_LIBGMP):
33587         * modules/libgmp (configure.ac, Makefile.am):
33588         Support platforms requiring ‘#include <gmp/gmp.h>’ instead of
33589         ‘#include <gmp.h>’.
33591 2020-08-06  Bruno Haible  <bruno@clisp.org>
33593         Consider that clang defines __OPTIMIZE__ like GCC does.
33594         * lib/streq.h: Define the inline functions also on clang.
33595         * lib/c-strcaseeq.h: Likewise.
33596         * lib/c++defs.h (_GL_CXXALIASWARN_2, _GL_CXXALIASWARN1_2): Don't enable
33597         the GCC workaround to clang.
33599 2020-08-06  Bruno Haible  <bruno@clisp.org>
33601         safe-alloc: Remove unused code.
33602         * lib/safe-alloc.h (__GNUC_PREREQ): Remove macro.
33604 2020-08-06  Bruno Haible  <bruno@clisp.org>
33606         Use __builtin_expect with clang everywhere.
33607         * lib/cdefs.h (__glibc_unlikely, __glibc_likely): Use the GCC built-in
33608         also on clang.
33610 2020-08-05  Bruno Haible  <bruno@clisp.org>
33612         Use __builtin_ctz{,l,ll} and __builtin_ffs{,l,ll} with clang everywhere.
33613         * lib/count-trailing-zeros.h (COUNT_TRAILING_ZEROS): Use the GCC
33614         built-in also on clang.
33615         * lib/ffs.c: With clang, use the GCC built-in, not <intrin.h>.
33616         * lib/ffsl.h: Likewise. Assume GCC_BUILTIN is defined.
33618 2020-08-05  Bruno Haible  <bruno@clisp.org>
33620         Use __builtin_clz{,l,ll} with clang, also on Windows.
33621         * lib/integer_length.c: With clang, use the GCC built-in, not
33622         <intrin.h>.
33623         * lib/integer_length_l.c: Likewise.
33624         * lib/count-leading-zeros.h (COUNT_LEADING_ZEROS): Use the GCC built-in
33625         also on clang.
33626         * lib/vasnprintf.c (divide): Likewise.
33628 2020-08-04  Paul Eggert  <eggert@cs.ucla.edu>
33630         Update srclist.txt as per recent glibc changes
33631         * config/srclist.txt: Uncomment lines to reflect recent merges
33632         from Gnulib to glibc.
33634 2020-08-03  Bruno Haible  <bruno@clisp.org>
33636         Prefer documented autoconf macro 'm4_if' over 'ifelse'.
33637         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Use m4_if instead of ifelse.
33639 2020-08-03  Bruno Haible  <bruno@clisp.org>
33641         integer_length_ll: Optimize for MSVC in 64-bit mode.
33642         * lib/integer_length_l.c (MSVC_BUILTIN): Define for MSVC in 64-bit mode.
33643         (FUNC): On MSVC, use MSVC_BUILTIN if defined.
33645 2020-08-03  Bruno Haible  <bruno@clisp.org>
33647         integer_length_ll: Optimize for MSVC in 32-bit mode.
33648         * lib/integer_length_l.c: Include <intrin.h>.
33649         (integer_length): Define as inline function, like in
33650         lib/integer_length.c.
33652 2020-08-03  Bruno Haible  <bruno@clisp.org>
33654         integer_length: Optimize for MSVC.
33655         * lib/integer_length.c: Include <intrin.h>.
33656         (integer_length): With MSVC, use the _BitScanReverse built-in.
33658 2020-08-03  Bruno Haible  <bruno@clisp.org>
33660         ffsll: Optimize for MSVC in 64-bit mode.
33661         * lib/ffsl.h (FUNC): On MSVC, use MSVC_BUILTIN if defined.
33662         * lib/ffsll.c (MSVC_BUILTIN): Define for MSVC in 64-bit mode.
33663         * lib/ffsl.c (MSVC_BUILTIN): Define for MSVC.
33665 2020-08-03  Bruno Haible  <bruno@clisp.org>
33667         ffsll: Optimize for MSVC in 32-bit mode.
33668         * lib/ffsl.h: Include <intrin.h>.
33669         (ffs): Define as inline function, like in lib/ffs.c.
33671 2020-08-03  Bruno Haible  <bruno@clisp.org>
33673         ffs: Optimize for MSVC.
33674         * lib/ffs.c: Include <intrin.h>.
33675         (ffs): With MSVC, use the _BitScanForward built-in.
33677 2020-08-03  Bruno Haible  <bruno@clisp.org>
33679         sigprocmask: Try to avoid breakage for people who use an Autoconf cache.
33680         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Change the name of the cache
33681         variable.
33683 2020-08-03  Harald van Dijk  <harald@gigawatt.nl>  (tiny change)
33685         fopen: Avoid undesired interactions with glibc headers.
33686         * lib/fopen.c (_GL_ALREADY_INCLUDING_STDIO_H): Define this instead of
33687         __need_FILE, as the latter does not work with glibc.
33689 2020-08-02  Paul Eggert  <eggert@cs.ucla.edu>
33691         fcntl: document some F_SETLK errno variations
33692         * doc/posix-functions/fcntl.texi (fcntl): Document
33693         OpenIndiana, GNU/Linux, FreeBSD on NFS files.
33695 2020-08-02  Bruno Haible  <bruno@clisp.org>
33697         oset: Add an 'iterator_atleast' operation.
33698         * lib/gl_array_oset.c (gl_array_indexof_atleast): New function,
33699         extracted from gl_array_search_atleast.
33700         (gl_array_search_atleast): Use it.
33701         (gl_array_iterator_atleast): New function.
33702         (gl_array_oset_implementation): Use it.
33703         * lib/gl_anytree_oset.h (gl_tree_iterator_atleast): New function.
33704         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Use it.
33705         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Likewise.
33706         * lib/gl_oset.h (struct gl_oset_implementation): Add 'iterator_atleast'
33707         member.
33708         (gl_oset_iterator_atleast): New function.
33709         * lib/gl_oset.hh (gl_OSet): Add 'begin_atleast' member.
33710         (gl_OSet::iterator): Add another auxiliary constructor.
33711         * tests/test-array_oset.c (is_at_least, gl_sortedlist_indexof_atleast):
33712         New functions.
33713         (main): Test also gl_oset_iterator_atleast.
33714         * tests/test-avltree_oset.c (is_at_least): New function.
33715         (main): Test also gl_oset_iterator_atleast.
33716         * tests/test-rbtree_oset.c (is_at_least): New function.
33717         (main): Test also gl_oset_iterator_atleast.
33718         * tests/test-oset-c++.cc (is_at_most): New function.
33719         (main): Test also gl_OSet::begin_atleast.
33721 2020-08-02  Bruno Haible  <bruno@clisp.org>
33723         oset-c++, omap-c++: Remove restriction for search_atleast method.
33724         * lib/gl_oset.hh (gl_OSet::search_atleast): Allow the threshold to be of
33725         a different type than the element.
33726         * lib/gl_omap.hh (gl_OMap::search_atleast): Allow the threshold to be of
33727         a different type than the key.
33729 2020-08-01  Paul Eggert  <eggert@cs.ucla.edu>
33731         gnumakefile: say ‘$(MAKE)’ not ‘make’
33732         * top/GNUmakefile (abort-due-to-no-makefile):
33733         Prefer ‘$(MAKE)’ to ‘make’ in a diagnostic.
33734         This change is backported from Autoconf.
33736 2020-08-01  Bruno Haible  <bruno@clisp.org>
33738         Prefer documented autoconf macro 'm4_if' over 'ifelse'.
33739         * m4/autobuild.m4 (AB_INIT): Use m4_if instead of ifelse.
33740         * m4/csharpexec.m4 (gt_CSHARPEXEC): Likewise.
33741         * m4/javacomp.m4 (gt_JAVACOMP): Likewise.
33742         * m4/javaexec.m4 (gt_JAVAEXEC): Likewise.
33743         * m4/libtextstyle.m4 (gl_LIBTEXTSTYLE): Likewise.
33745 2020-08-01  Bruno Haible  <bruno@clisp.org>
33747         libtextstyle-optional: Update tests.
33748         * modules/libtextstyle-optional-tests (configure.ac): Invoke
33749         gl_LIBTEXTSTYLE_OPTIONAL.
33751 2020-08-01  Bruno Haible  <bruno@clisp.org>
33753         parse-datetime: Fix wrong #line statements.
33754         * modules/parse-datetime (Makefile.am): Correct #line statements also in
33755         parse-datetime-gen.h.
33757 2020-08-01  Bruno Haible  <bruno@clisp.org>
33759         libtextstyle[-optional]: Allow requesting a minimum version.
33760         * m4/libtextstyle.m4 (gl_LIBTEXTSTYLE): Allow an optional argument.
33761         (gl_LIBTEXTSTYLE_NEWEST_VERSION, gl_LIBTEXTSTYLE_INITIALIZE,
33762         gl_LIBTEXTSTYLE_SEARCH): New macros.
33763         * modules/libtextstyle (configure.ac): Don't invoke gl_LIBTEXTSTYLE.
33764         * m4/libtextstyle-optional.m4 (gl_LIBTEXTSTYLE_OPTIONAL): Allow an
33765         optional argument. Invoke, not require, gl_LIBTEXTSTYLE.
33766         * modules/libtextstyle-optional (configure.ac): Don't invoke
33767         gl_LIBTEXTSTYLE_OPTIONAL.
33768         * NEWS: Mention the changes.
33770 2020-07-31  Bruno Haible  <bruno@clisp.org>
33772         _GL_CMP: Improve documentation.
33773         Reported by Paul Eggert in
33774         <https://lists.gnu.org/archive/html/bug-gnulib/2020-07/msg00188.html>.
33775         * m4/gnulib-common.m4 (gl_COMMON_BODY): Clarify what arguments can be
33776         passed.
33778 2020-07-30  Paul Eggert  <eggert@cs.ucla.edu>
33780         largefile: sync with Autoconf master
33781         * m4/largefile.m4 (_AC_SYS_LARGEFILE_TEST_INCLUDES):
33782         Avoid undefined behavior on platforms where off_t is 32 bits.
33783         See: https://bugs.debian.org/742780
33785         alloca: sync with Autoconf master
33786         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA):
33787         Do not define if Autoconf 2.70 or later, since Autoconf master
33788         now matches us.
33790 2020-07-30  Bruno Haible  <bruno@clisp.org>
33792         unicodeio: Add comment.
33793         * lib/unicodeio.c (unicode_to_mb): Clarify why the code distinguishes
33794         different iconv behaviours.
33796 2020-07-30  Paul Eggert  <eggert@cs.ucla.edu>
33798         Work around some Oracle Studio attribute bugs
33799         These were discovered when building bleeding-edge Emacs with
33800         Oracle Studio.
33801         * m4/gnulib-common.m4 (_GL_ATTRIBUTE_COLD, _GL_ATTRIBUTE_MAY_ALIAS):
33802         Port to Oracle Studio 12.6, which mishandles __attribute__
33803         ((__cold__)) and __attribute__ ((__may_alias__)) even though
33804         __has_attribute says they work.
33806 2020-07-29  Bruno Haible  <bruno@clisp.org>
33808         unicodeio: Fix wrong result on musl libc.
33809         Reported by A. Wilcox <awilfox@adelielinux.org> in
33810         <https://www.openwall.com/lists/musl/2020/07/29/2>.
33811         * lib/unicodeio.c (unicode_to_mb): Handle asterisk fallback characters
33812         on musl libc.
33813         * m4/unicodeio.m4 (gl_UNICODEIO): Invoke gl_MUSL_LIBC.
33814         * modules/unicodeio (Files): Add m4/musl.m4.
33816 2020-07-29  Paul Eggert  <eggert@cs.ucla.edu>
33818         fsusage, regex, stat-size: remove Cray support
33819         As near as I can make out this is actually support for UNICOS/mp,
33820         last released 2005, and Cray hasn’t supported that for years.
33821         * config/srclist.txt: Comment out regex.h for now.
33822         * lib/fsusage.c (get_fs_usage):
33823         * lib/regex.h (re_comp, re_exec):
33824         * lib/stat-size.h (ST_NBLOCKSIZE):
33825         Don’t worry about _CRAY.
33827 2020-07-29  Bruno Haible  <bruno@clisp.org>
33829         parse-datetime: Fix compilation error with bison 3.7.
33830         * modules/parse-datetime (Makefile.am): Create a generated header file
33831         parse-datetime-gen.h in the source directory. Correct #include and
33832         #line statements during preprocessing.
33834 2020-07-28  Bruno Haible  <bruno@clisp.org>
33836         fopen-gnu: Create files correctly (regression from 2020-05-24).
33837         * lib/fopen.c (rpl_open): Pass a third argument to open().
33839 2020-07-27  Paul Eggert  <eggert@cs.ucla.edu>
33841         xalloc-die: don’t depend on xalloc
33842         This removes a circular dependency, as xalloc depends on xalloc-die.
33843         * modules/xalloc-die (Files): Add lib/xalloc.h.
33844         (Depends-on): Remove xalloc.
33845         Add extern-inline, stdint, xalloc-oversized (this is for xalloc.h).
33847         dfa-tests: port to MSVC
33848         Problem reported by Gisle Vanem in:
33849         https://lists.gnu.org/r/bug-gnulib/2020-07/msg00159.html
33850         Also, remove an unnecessary dependency on getprogname.
33851         * modules/dfa-tests (Depends-on): Remove getprogname.
33852         * tests/test-dfa-match-aux.c: Do not include getprogname.h.
33853         (exit_status): New static var.
33854         (dfawarn): Set it instead of exiting.
33855         Do not declare as _Noreturn, to pacify MSVC.
33856         (main): Return exit_status.
33858 2020-07-26  Paul Eggert  <eggert@cs.ucla.edu>
33860         argz: pacify MSVC
33861         * lib/argz.in.h: Avoid "*/*" to pacify MSVC.
33862         Problem reported by Gisle Vanem.
33864         libgmp: remove dependency on havelib
33865         * m4/libgmp.m4 (gl_LIBGMP): If gl_HAVE_MODULE_HAVELIB is not defined,
33866         use the more-traditional AC_SEARCH_LIBS approach.
33867         This should work better with GNU Emacs configuration,
33868         which uses pkg-config instead of a havelib-style approach.
33869         * modules/havelib (gl_HAVE_MODULE_HAVELIB): New witness macro.
33870         * modules/libgmp (Depends-on): Remove havelib.
33872         libgmp: remove HAVE_GMP, LIB_GMP
33873         * m4/libgmp.m4 (gl_LIBGMP): Do not define HAVE_GMP and LIB_GMP, as
33874         they’re redundant.  I’ll adjust GNU Coreutils accordingly.
33876 2020-07-26  Bruno Haible  <bruno@clisp.org>
33878         inttypes: Remove support for AIX 4.
33879         * lib/inttypes.in.h: Assume that PRI_MACROS_BROKEN is 0.
33880         * m4/inttypes-pri.m4: Remove file.
33881         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): Don't require gt_INTTYPES_PRI.
33882         (gl_INTTYPES_H_DEFAULTS): Don't initialize PRI_MACROS_BROKEN.
33883         * modules/inttypes-incomplete (Makefile.am): Don't substitute
33884         PRI_MACROS_BROKEN.
33885         * modules/inttypes (Files): Remove m4/inttypes-pri.m4.
33887 2020-07-26  Bruno Haible  <bruno@clisp.org>
33889         gettimeofday: Remove workaround for Mac OS X 10.0.
33890         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Remove macro.
33891         (gl_FUNC_GETTIMEOFDAY): Don't invoke it.
33892         * lib/gettimeofday.c: Don't include localtime-buffer.h.
33893         (gettimeofday): Don't test GETTIMEOFDAY_CLOBBERS_LOCALTIME.
33894         * lib/localtime.c: Don't test GETTIMEOFDAY_CLOBBERS_LOCALTIME.
33895         * modules/gettimeofday (Depends-on): Remove localtime-buffer.
33896         * modules/localtime-buffer: Remove file.
33897         * lib/localtime-buffer.h: Remove file.
33898         * lib/localtime-buffer.c: Remove file.
33899         * m4/localtime-buffer.m4: Remove file.
33900         * MODULES.html.sh (Date and time <time.h>): Remove localtime-buffer.
33902 2020-07-26  Bruno Haible  <bruno@clisp.org>
33904         tzset: Remove workaround for Solaris 2.6.
33905         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Remove macro.
33906         (gl_FUNC_TZSET): Don't invoke it. Don't define TZSET_CLOBBERS_LOCALTIME.
33907         Don't require gl_LOCALTIME_BUFFER_DEFAULTS.
33908         * lib/localtime-buffer.h: Don't test TZSET_CLOBBERS_LOCALTIME.
33909         * lib/localtime-buffer.c: Likewise.
33910         * lib/localtime.c: Likewise.
33911         * lib/tzset.c: Don't include localtime-buffer.h.
33912         (tzset): Don't test TZSET_CLOBBERS_LOCALTIME.
33913         * lib/nstrftime.c (__strftime_internal): Assume HAVE_RUN_TZSET_TEST
33914         is 1.
33915         * modules/tzset (Depends-on): Remove localtime-buffer.
33917 2020-07-26  Bruno Haible  <bruno@clisp.org>
33919         expl: Simplify autoconf test.
33920         * m4/expl.m4 (gl_FUNC_EXPL): Merge the "checking whether expl() breaks
33921         with small values..." test into the "checking whether expl works..."
33922         test.
33924 2020-07-26  Bruno Haible  <bruno@clisp.org>
33926         alloca: Remove Cray-2 and Cray Y-MP support.
33927         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA): Don't define CRAY_STACKSEG_END.
33928         Enable also on Autoconf >= 2.69.
33929         * lib/alloca.c (ADDRESS_FUNCTION, struct stack_control_header,
33930         struct stack_segment_linkage, struct stk_stat, struct stk_trailer,
33931         i00afunc): Remove.
33933 2020-07-25  Bruno Haible  <bruno@clisp.org>
33935         multiarch: Prepare for x86_64+arm64 universal binaries in macOS 11.
33936         * m4/multiarch.m4 (gl_MULTIARCH): Recognize also the ARM architectures.
33938 2020-07-25  Bruno Haible  <bruno@clisp.org>
33940         sigprocmask: Small autoconf macro improvement.
33941         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Make it possible for the
33942         user to override the value of gl_cv_func_sigprocmask.
33943         * m4/gnulib-common.m4 (gl_SILENT): New macro.
33945 2020-07-25  Bruno Haible  <bruno@clisp.org>
33947         Small autoconf macro improvements.
33948         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Make it possible for the user to
33949         override the value of gl_cv_func_working_mktime.
33950         * m4/multiarch.m4 (gl_MULTIARCH): Show a line "checking whether the
33951         compiler produces multi-arch binaries..." in the configure output.
33952         * m4/size_max.m4 (gl_SIZE_MAX): When not found, say "no".
33953         * m4/parse-datetime.m4 (gl_C_COMPOUND_LITERALS): Improve indentation.
33955 2020-07-25  Bruno Haible  <bruno@clisp.org>
33957         doc: Update for NetBSD 7.1, 8.0, 9.0.
33958         * doc/*/*.texi: Update.
33959         * m4/exp2l.m4: Update comments.
33960         * m4/expl.m4: Likewise.
33961         * m4/ilogb.m4: Likewise.
33962         * m4/ilogbf.m4: Likewise.
33963         * m4/log10l.m4: Likewise.
33964         * m4/logl.m4: Likewise.
33965         * m4/printf.m4: Likewise.
33966         * m4/rintl.m4: Likewise.
33967         * m4/wcwidth.m4: Likewise.
33969 2020-07-24  Bruno Haible  <bruno@clisp.org>
33971         doc: Update for Mac OS X 10.13.
33972         * doc/*/*.texi: Update.
33973         * m4/expm1l.m4: Update comments.
33974         * m4/getgroups.m4: Likewise.
33975         * m4/getlogin_r.m4: Likewise.
33976         * m4/linkat.m4: Likewise.
33977         * m4/printf.m4: Likewise.
33979 2020-07-24  Bruno Haible  <bruno@clisp.org>
33981         doc: Update for Cygwin 2.9.0.
33982         * doc/*/*.texi: Update.
33984 2020-07-24  Paul Eggert  <eggert@cs.ucla.edu>
33986         parse-datetime: modernize doc
33987         * doc/parse-datetime.texi: Use more-current examples.
33988         Don’t lead with 32-bit time_t, as it’s on its way out.
33989         Capitalize “Epoch” to be consistent with POSIX.
33991         timespec: remove dependence on ‘verify’
33992         * lib/timespec.h: Do not include verify.h; no longer needed.
33993         * modules/timespec (Depends-on): Remove ‘verify’.
33995         Optimize a few more three-valued comparisons
33996         * lib/timespec.h (timespec_cmp, timespec_sign):
33997         * lib/utimecmp.c (utimecmpat):
33998         Avoid conditional branches by using _GL_CMP.
34000         Fix _GL_CMP parenthesization typo
34001         * m4/gnulib-common.m4 (_GL_CMP): Properly parenthesize.
34003 2020-07-24  Bruno Haible  <bruno@clisp.org>
34005         dfa: Revert breaking gawk.
34006         Reported by Arnold Robbins <arnold@skeeve.com>.
34007         * lib/dfa.c (compare): Don't reference the _GL_CMP macro.
34009 2020-07-23  Bruno Haible  <bruno@clisp.org>
34011         Optimize three-valued comparison between integers.
34012         (a > b ? 1 : a < b ? -1 : 0) is the same as (a > b) - (a < b).
34013         * m4/gnulib-common.m4 (gl_COMMON): Define _GL_CMP.
34014         * lib/c-strcasecmp.c (c_strcasecmp): Use _GL_CMP.
34015         * lib/c-strncasecmp.c (c_strncasecmp): Likewise.
34016         * lib/dfa.c (compare): Likewise.
34017         * lib/fts.c (fts_compare_ino): Likewise.
34018         * lib/mbmemcasecmp.c (mbmemcasecmp): Likewise.
34019         * lib/mbscasecmp.c (mbscasecmp): Likewise.
34020         * lib/mbsncasecmp.c (mbsncasecmp): Likewise.
34021         * lib/memcasecmp.c (memcasecmp): Likewise.
34022         * lib/memcmp2.c (memcmp2): Likewise.
34023         * lib/savedir.c (direntry_cmp_inode): Likewise.
34024         * lib/strcasecmp.c (strcasecmp): Likewise.
34025         * lib/strncasecmp.c (strncasecmp): Likewise.
34026         * lib/unistr/u-cmp2.h (FUNC): Likewise.
34028 2020-07-23  Bruno Haible  <bruno@clisp.org>
34030         lchmod: Use /proc on Cygwin.
34031         * lib/lchmod.c (lchmod): Use /proc on Cygwin.
34033 2020-07-23  Ken Brown  <kbrown@cornell.edu>
34035         fchmodat: Use /proc on Cygwin
34036         * lib/fchmodat.c (fchmodat): Use /proc on Cygwin.
34038 2020-07-21  Bruno Haible  <bruno@clisp.org>
34040         aligned-malloc: Optionally use aligned_alloc.
34041         * lib/aligned-malloc.h: Verify the alignment.
34042         (aligned_malloc): Use aligned_alloc as an alternative.
34043         * modules/aligned-malloc (configure.ac): Test for aligned_alloc.
34044         * doc/posix-functions/aligned_alloc.texi: Mention the modules
34045         'aligned-malloc' and 'pagealign_alloc'.
34047 2020-07-21  Bruno Haible  <bruno@clisp.org>
34049         aligned-malloc: Add tests.
34050         * tests/test-aligned-malloc.c: New file.
34051         * modules/aligned-malloc-tests: New file.
34053         aligned-malloc: New module.
34054         * lib/aligned-malloc.h: New file.
34055         * m4/malloc-align.m4: New file.
34056         * modules/aligned-malloc: New file.
34057         * doc/posix-functions/posix_memalign.texi: Mention the new module.
34058         * doc/glibc-functions/memalign.texi: Likewise.
34060 2020-07-21  Bruno Haible  <bruno@clisp.org>
34062         inttypes: Fix PRI*PTR and SCN*PTR on 64-bit native Windows.
34063         * m4/inttypes.m4 (gl_INTTYPES_PRI_SCN): On 64-bit native Windows, make
34064         sure PRIPTR_PREFIX is defined to "ll", not "l".
34066 2020-07-21  Bruno Haible  <bruno@clisp.org>
34068         printf-posix: Make an autoconf test more future-proof.
34069         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): Include <inttypes.h> before
34070         using uintptr_t.
34072 2020-07-20  Bruno Haible  <bruno@clisp.org>
34074         list, oset, omap: Relicense some of the container modules under LGPLv2+.
34075         * modules/list (License): Change to LGPLv2+.
34076         * modules/array-list (License): Likewise.
34077         * modules/carray-list (License): Likewise.
34078         * modules/linked-list (License): Likewise.
34079         * modules/avltree-list (License): Likewise.
34080         * modules/rbtree-list (License): Likewise.
34081         * modules/oset (License): Likewise.
34082         * modules/array-oset (License): Likewise.
34083         * modules/avltree-oset (License): Likewise.
34084         * modules/rbtree-oset (License): Likewise.
34085         * modules/omap (License): Likewise.
34086         * modules/array-omap (License): Likewise.
34087         * modules/avltree-omap (License): Likewise.
34088         * modules/rbtree-omap (License): Likewise.
34090 2020-07-20  Bruno Haible  <bruno@clisp.org>
34092         oset: Add an 'update' operation.
34093         * lib/gl_array_oset.c (gl_array_update): New function.
34094         (gl_array_oset_implementation): Use it.
34095         * lib/gl_avltree_omap.c (NODE_PAYLOAD_DISPOSE): Add parameters.
34096         * lib/gl_rbtree_omap.c (NODE_PAYLOAD_DISPOSE): Add parameters.
34097         * lib/gl_avltree_ordered.h (gl_tree_add_node_before): New function,
34098         extracted from gl_tree_nx_add_before.
34099         (gl_tree_nx_add_before): Invoke it.
34100         (gl_tree_add_node_after): New function, extracted from
34101         gl_tree_nx_add_after.
34102         (gl_tree_nx_add_after): Invoke it.
34103         (gl_tree_remove_node_no_free): New function, extracted from
34104         gl_tree_remove_node.
34105         (gl_tree_remove_node): Invoke it.
34106         * lib/gl_rbtree_ordered.h (gl_tree_add_node_before): New function,
34107         extracted from gl_tree_nx_add_before.
34108         (gl_tree_nx_add_before): Invoke it.
34109         (gl_tree_add_node_after): New function, extracted from
34110         gl_tree_nx_add_after.
34111         (gl_tree_nx_add_after): Invoke it.
34112         (gl_tree_remove_node_no_free): New function, extracted from
34113         gl_tree_remove_node.
34114         (gl_tree_remove_node): Invoke it.
34115         * lib/gl_anytree_oset.h (gl_tree_next_node): New function, extracted
34116         from gl_tree_iterator_next.
34117         (gl_tree_iterator_next): Invoke it.
34118         (gl_tree_prev_node, gl_tree_update): New functions.
34119         * lib/gl_avltree_oset.c (NODE_PAYLOAD_DISPOSE): Add parameters.
34120         (gl_avltree_oset_implementation): Use gl_tree_update.
34121         * lib/gl_rbtree_oset.c (NODE_PAYLOAD_DISPOSE): Add parameters.
34122         (gl_rbtree_oset_implementation): Use gl_tree_update.
34123         * lib/gl_oset.h (struct gl_oset_implementation): Add 'update' member.
34124         (gl_oset_update): New function.
34125         * lib/gl_oset.hh (gl_OSet): Add 'update' member.
34126         * modules/avltree-oset (configure.ac): Require AC_C_INLINE.
34127         * modules/rbtree-oset (configure.ac): Likewise.
34128         * tests/test-oset-update.h: New file.
34129         * tests/test-array_oset.c: Include test-oset-update.h.
34130         (main): Invoke test_update.
34131         * tests/test-avltree_oset.c: Likewise.
34132         * tests/test-rbtree_oset.c: Likewise.
34133         * modules/array-oset-tests (Files): Add tests/test-oset-update.h.
34134         * modules/avltree-oset-tests (Files): Likewise.
34135         * modules/rbtree-oset-tests (Files): Likewise.
34136         * tests/test-oset-c++.cc (action): New function.
34137         (main): Test the 'update' member function.
34139 2020-07-15  Paul Eggert  <eggert@cs.ucla.edu>
34141         md5, sha1, sha256, sha512: pacify Autoconf 2.70
34142         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Use m4_if rather than a
34143         shell if, so that the argument to AC_CHECK_HEADERS is
34144         a simple string that does not require shell evaluation.
34145         This fixes a warning generated by Autoconf 2.69b.
34147 2020-07-12  Bruno Haible  <bruno@clisp.org>
34149         libgmp: Avoid warning when --without-libgmp is used.
34150         * lib/mini-gmp-gnulib.c: Ignore -Wsuggest-attribute=malloc only for
34151         GCC >= 8, not for GCC >= 4.6.
34153 2020-07-12  Bruno Haible  <bruno@clisp.org>
34155         libgmp: Link to the correct shared library.
34156         * m4/libgmp.m4 (gl_LIBGMP): Invoke AC_LIB_HAVE_LINKFLAGS.
34157         * modules/libgmp (Depends-on): Add havelib.
34158         (Link): Mention $(LIBGMP) and $(LTLIBGMP).
34159         * modules/libgmp-tests (Makefile.am): Link test-libgmp with $(LIBGMP).
34161 2020-07-12  Bruno Haible  <bruno@clisp.org>
34163         libgmp tests: Add some safety checks.
34164         * modules/libgmp-tests (Depends-on): Add verify.
34165         * tests/test-libgmp.c: Verify GMP_NUMB_BITS value.
34166         (main): Verify that gmp.h and libgmp versions match.
34168 2020-07-10  Bruno Haible  <bruno@clisp.org>
34170         unicodeio: Fix wrong result on NetBSD.
34171         * lib/unicodeio.c (unicode_to_mb): Handle question mark fallback
34172         characters also on NetBSD.
34174 2020-07-09  Bruno Haible  <bruno@clisp.org>
34176         unicodeio: Fix wrong result on Solaris 11.
34177         Reported by Kiyoshi Kanazawa <yoi_no_myoujou@yahoo.co.jp>
34178         via Akim Demaille <akim.demaille@gmail.com> in
34179         <https://lists.gnu.org/archive/html/bug-gnulib/2020-07/msg00036.html>.
34180         * lib/unicodeio.c (unicode_to_mb): Handle question mark fallback
34181         characters on Solaris.
34182         * tests/test-unicodeio.c (main): In the "C" locale, expect either the
34183         UTF-8 output or the specified fallback.
34185 2020-07-08  Bruno Haible  <bruno@clisp.org>
34187         unicodeio: Add tests.
34188         * tests/test-unicodeio.c: New file.
34189         * tests/test-unicodeio1.sh: New file.
34190         * tests/test-unicodeio2.sh: New file.
34191         * tests/test-unicodeio3.sh: New file.
34192         * modules/unicodeio-tests: New file.
34194 2020-07-08  Bruno Haible  <bruno@clisp.org>
34196         unicodeio: Document link requirements.
34197         * modules/unicodeio (Link): New section.
34199 2020-07-07  Bruno Haible  <bruno@clisp.org>
34201         doc: Remove support for some very old platforms.
34202         * doc/posix-functions/memcmp.texi: Don't mention "older platforms".
34203         * doc/posix-functions/memcpy.texi: Likewise.
34204         * doc/posix-functions/memmove.texi: Likewise.
34205         * doc/posix-functions/memset.texi: Likewise.
34206         * doc/posix-functions/getcwd.texi: Likewise.
34208         memchr: Remove support for some very old platforms.
34209         * m4/memchr-obsolete.m4: Remove file.
34210         * modules/memchr-obsolete: Remove file.
34211         * m4/memchr.m4 (gl_FUNC_MEMCHR): Assume module 'memchr-obsolete' is
34212         absent. Don't define HAVE_MEMCHR.
34213         * lib/string.in.h (memchr): Assume HAVE_MEMCHR is 1.
34214         * modules/memchr (Depends-on): Remove memchr-obsolete.
34215         (configure.ac): Assume HAVE_MEMCHR is 1.
34216         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
34217         HAVE_MEMCHR.
34218         * modules/string (Makefile.am): Don't substitute HAVE_MEMCHR.
34219         * doc/posix-functions/memchr.texi: Don't mention module
34220         'memchr-obsolete'.
34221         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Assume HAVE_MEMCHR is 1.
34222         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Assume HAVE_MEMCHR is 1.
34223         * modules/strnlen (Depends-on): Remove memchr-obsolete.
34225         dup2: Remove support for some very old platforms.
34226         * m4/dup2-obsolete.m4: Remove file.
34227         * modules/dup2-obsolete: Remove file.
34228         * m4/dup2.m4 (gl_FUNC_DUP2): Assume module 'dup2-obsolete' is absent.
34229         Don't define HAVE_DUP2.
34230         * lib/unistd.in.h (dup2): Assume HAVE_DUP2 is 1.
34231         * lib/dup2.c: Likewise.
34232         * modules/dup2 (Depends-on, configure.ac): Likewise.
34233         (Depends-on): Remove dup2-obsolete.
34234         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Don't initialize HAVE_DUP2.
34235         * modules/unistd (Makefile.am): Don't substitute HAVE_DUP2.
34236         * doc/posix-functions/dup2.texi: Don't mention module 'dup2-obsolete'.
34238 2020-07-07  Bruno Haible  <bruno@clisp.org>
34240         canonicalize: Trim module dependencies.
34241         * lib/hash-triple.h: Group declarations.
34242         * lib/hash-triple-simple.c: New file, extracted from lib/hash-triple.c.
34243         * lib/hash-triple.c: Don't include <stdlib.h>, <string.h>, hash-pjw.h.
34244         (STREQ): Remove macro.
34245         (triple_hash, triple_compare_ino_str, triple_free): Remove functions.
34246         * modules/hash-triple-simple: New file, based on modules/hash-triple.
34247         * modules/hash-triple (Files): Remove lib/hash-triple.h.
34248         (Depends-on): Add hash-triple-simple. Remove hash-pjw.
34249         * modules/canonicalize (Depends-on): Remove hash-triple. Add
34250         hash-triple-simple.
34251         * modules/file-set (Depends-on): Likewise.
34253 2020-07-07  Bruno Haible  <bruno@clisp.org>
34255         Clarify dependencies to double-slash-root.
34256         * modules/canonicalize (Files): Remove m4/double-slash-root.m4.
34257         (Depends-on): Add double-slash-root.
34258         * modules/canonicalize-lgpl (Depends-on): Add double-slash-root.
34259         * modules/dirname-lgpl (Depends-on): Add double-slash-root.
34261 2020-07-06  Paul Eggert  <eggert@cs.ucla.edu>
34263         libgmp: new module
34264         The idea is to let programs simply include <gmp.h>, and
34265         so long as they live within the mini-gmp subset they need
34266         not worry about whether the GMP libraries are installed.
34267         * MODULES.html.sh: Mention it.
34268         * config/srclist.txt: Mention files copied from GMP source.
34269         * config/srclistvars.sh (GMP): New var.
34270         * lib/mini-gmp-gnulib.c, m4/libgmp.m4, modules/libgmp:
34271         * modules/libgmp-tests, tests/test-libgmp.c: New files.
34272         * lib/mini-gmp.c, lib/mini-gmp.h: New files, copied from GMP.
34274 2020-07-05  Bruno Haible  <bruno@clisp.org>
34276         mkancesdirs: Trim module dependencies.
34277         * lib/mkancesdirs.c: Include filename.h instead of dirname.h.
34278         * modules/mkancesdirs (Depends-on): Remove dirname-lgpl. Add filename.
34280 2020-07-05  Bruno Haible  <bruno@clisp.org>
34282         getprogname: Trim module dependencies.
34283         * lib/getprogname.c: Include basename-lgpl.h instead of dirname.h.
34284         * modules/getprogname (Depends-on): Remove dirname-lgpl. Add
34285         basename-lgpl.
34287 2020-07-05  Bruno Haible  <bruno@clisp.org>
34289         filenamecat-lgpl: Trim module dependencies.
34290         * lib/filenamecat-lgpl.c: Include basename-lgpl.h, filename.h instead of
34291         dirname.h.
34292         * modules/filenamecat-lgpl (Depends-on): Remove dirname-lgpl. Add
34293         basename-lgpl, filename.
34295 2020-07-05  Bruno Haible  <bruno@clisp.org>
34297         backupfile, backup-rename: Trim module dependencies.
34298         * lib/backupfile.c: Include basename-lgpl.h instead of dirname.h.
34299         * modules/backupfile (Depends-on): Remove dirname-lgpl. Add
34300         basename-lgpl.
34301         * modules/backup-rename (Depends-on): Likewise.
34303 2020-07-05  Bruno Haible  <bruno@clisp.org>
34305         argp: Trim module dependencies.
34306         * lib/argp-namefrob.h: Include basename-lgpl.h instead of dirname.h.
34307         * modules/argp (Depends-on): Remove dirname-lgpl. Add basename-lgpl.
34309 2020-07-05  Bruno Haible  <bruno@clisp.org>
34311         basename-lgpl: New module.
34312         * lib/basename-lgpl.h: New file, based on lib/dirname.h and
34313         lib/basename-lgpl.c.
34314         * lib/basename-lgpl.c: Include basename-lgpl.h, not dirname.h. Include
34315         <stdbool.h>, filename.h.
34316         (last_component): Rename a local variable.
34317         * lib/dirname.h: Include basename-lgpl.h.
34318         (DOUBLE_SLASH_IS_DISTINCT_ROOT): Remove macro.
34319         (last_component, base_len): Remove declarations.
34320         * modules/basename-lgpl: New file.
34321         * modules/dirname-lgpl (Files): Remove lib/basename-lgpl.c.
34322         (Depends-on): Add basename-lgpl. Remove double-slash-root.
34323         (Makefile.am): Don't compile basename-lgpl.c.
34324         * doc/posix-functions/basename.texi: Mention the module 'basename-lgpl',
34325         not 'dirname'.
34327 2020-07-05  Bruno Haible  <bruno@clisp.org>
34329         dirname, dirname-lgpl: Simplify.
34330         * m4/dirname.m4: Remove file.
34331         * modules/dirname (configure.ac): Don't invoke gl_DIRNAME.
34332         * modules/dirname-lgpl (Files): Remove m4/dirname.m4.
34333         (configure.ac): Don't invoke gl_DIRNAME_LGPL.
34335 2020-07-05  Bernhard Voelker  <mail@bernhard-voelker.de>
34337         tests: avoid shadowing warning
34338         * tests/test-memchr.c (main): Give page_boundary variable a tight scope.
34340 2020-07-05  Bruno Haible  <bruno@clisp.org>
34342         supersede: Add tests.
34343         * tests/test-supersede.c: New file.
34344         * tests/test-supersede-open.h: New file.
34345         * tests/test-supersede-fopen.h: New file.
34346         * modules/supersede-tests: New file.
34348         supersede: New module.
34349         * lib/supersede.h: New file.
34350         * lib/supersede.c: New file.
34351         * m4/supersede.m4: New file.
34352         * modules/supersede: New file.
34354 2020-07-05  Bruno Haible  <bruno@clisp.org>
34356         Add some copyright headers.
34357         * lib/dev-ino.h: Add copyright header.
34358         * lib/di-set.h: Likewise.
34359         * lib/fchown-stub.c: Likewise.
34360         * lib/file-set.h: Likewise.
34361         * lib/hash-triple.h: Likewise.
34362         * lib/idcache.h: Likewise.
34363         * lib/ino-map.h: Likewise.
34364         * lib/mkancesdirs.h: Likewise.
34365         * lib/scratch_buffer.h: Likewise.
34366         * lib/se-context.in.h: Likewise.
34367         * lib/stdopen.h: Likewise.
34368         * lib/userspec.h: Likewise.
34370 2020-07-04  Bruno Haible  <bruno@clisp.org>
34372         getrandom: Relicense under LGPLv2+.
34373         Paul Eggert's approval is in
34374         <https://lists.gnu.org/archive/html/bug-gnulib/2020-07/msg00023.html>.
34375         * modules/getrandom (License): Change to LGPLv2+.
34377 2020-07-04  Bruno Haible  <bruno@clisp.org>
34379         getumask: Add tests.
34380         * tests/test-getumask.c: New file.
34381         * modules/getumask-tests: New file.
34383         getumask: New module.
34384         * lib/sys_stat.in.h (getumask): New declaration.
34385         * lib/getumask.c: New file.
34386         * m4/getumask.m4: New file.
34387         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Test whether getumask is
34388         declared.
34389         (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_GETUMASK, HAVE_GETUMASK.
34390         * modules/sys_stat (Makefile.am): Substitute GNULIB_GETUMASK,
34391         HAVE_GETUMASK.
34392         * modules/getumask: New file.
34393         * tests/test-sys_stat-c++.cc (getumask): Check signature.
34394         * doc/glibc-functions/getumask.texi: New file.
34395         * doc/gnulib.texi (Glibc sys/stat.h): Include it.
34397 2020-07-04  Bruno Haible  <bruno@clisp.org>
34399         clean-temp: Add support for temporary files with given mode.
34400         * lib/clean-temp.h (gen_register_open_temp): Add mode argument.
34401         * lib/clean-temp.c (struct try_create_file_params): New type.
34402         (try_create_file): New function.
34403         (gen_register_open_temp): Add mode argument. Use try_tempname instead of
34404         gen_tempname.
34406 2020-07-04  Bruno Haible  <bruno@clisp.org>
34408         clean-temp: Document limitations.
34409         * lib/clean-temp.h: Document limitations.
34411 2020-07-04  Bruno Haible  <bruno@clisp.org>
34413         clean-temp: Add support for temporary files with unpredictable names.
34414         * lib/clean-temp.h (gen_register_open_temp): New declaration.
34415         * lib/clean-temp.c: Include tempname.h.
34416         (gen_register_open_temp): New function.
34417         * modules/tempname (configure.ac): Define a module indicator.
34419 2020-07-04  Bruno Haible  <bruno@clisp.org>
34421         clean-temp: Add support for temporary files anywhere in the file system.
34422         * lib/clean-temp.h (register_temporary_file, unregister_temporary_file,
34423         cleanup_temporary_file): New declarations.
34424         * lib/clean-temp.c (file_cleanup_list_lock, file_cleanup_list): New
34425         variables.
34426         (dir_cleanup_list_lock): Renamed from cleanup_list_lock.
34427         (dir_cleanup_list): Renamed from cleanup_list.
34428         (cleanup_action): Process the file_cleanup_list as well.
34429         (do_init_clean_temp): New function.
34430         (clean_temp_once): New variable.
34431         (init_clean_temp): New function.
34432         (create_temp_dir): Invoke it.
34433         (register_temporary_file, unregister_temporary_file,
34434         cleanup_temporary_file): New functions.
34435         (do_unlink, do_rmdir): Remove 'dir' argument. Add 'cleanup_verbose'
34436         argument.
34438 2020-07-04  Bruno Haible  <bruno@clisp.org>
34440         clean-temp: Improve comments.
34441         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
34442         fwriteerror_temp, close_stream_temp): Clarify intended use.
34443         * lib/clean-temp.c: Likewise.
34445 2020-07-04  Bruno Haible  <bruno@clisp.org>
34447         clean-temp: Make multithread-safe, part 2.
34448         * lib/fatal-signal.h: Include <signal.h>.
34449         (get_fatal_signal_set): New declaration.
34450         * lib/fatal-signal.c (get_fatal_signal_set): New function.
34451         * lib/clean-temp.c: Include asyncsafe-spin.h, gl_linked_list.h.
34452         (struct closeable_fd): New type.
34453         (fatal_signal_set): New variable.
34454         (init_fatal_signal_set): New function.
34455         (asyncsafe_close, asyncsafe_fclose_variant): New functions.
34456         (cleanup_action): Invoke asyncsafe_close instead of close.
34457         (create_temp_dir): Invoke init_fatal_signal_set.
34458         (register_fd): Use a plain linked list. Add a 'struct closeable_fd *'
34459         element.
34460         (unregister_fd): Remove function.
34461         (close_temp): Cleanup descriptors list on the fly. Invoke
34462         init_fatal_signal_set. Invoke asyncsafe_close instead of close.
34463         (fclose_variant_temp): New function.
34464         (fclose_temp, fwriteerror_temp, close_stream_temp): Use it.
34465         * modules/clean-temp (Depends-on): Add asyncsafe-spin, linked-list.
34467 2020-07-04  Bruno Haible  <bruno@clisp.org>
34469         clean-temp: Make multithread-safe, part 1.
34470         * lib/clean-temp.c: Include glthread/lock.h.
34471         (cleanup_list_lock): New variable.
34472         (register_temp_file, unregister_temp_file, register_temp_subdir,
34473         unregister_temp_subdir, cleanup_temp_dir_contents): Use it.
34474         (create_temp_dir): Likewise. Don't free the old array.
34475         (descriptors_lock): New variable.
34476         (register_fd, unregister_fd): Use it.
34477         * modules/clean-temp (Depends-on): Add lock.
34479 2020-07-04  Bruno Haible  <bruno@clisp.org>
34481         fatal-signal: Make multithread-safe.
34482         * lib/fatal-signal.c (init_fatal_signals): Add comment.
34483         (do_init_fatal_signal_set): New function, extracted from
34484         init_fatal_signal_set.
34485         (fatal_signal_set_once): New variable.
34486         (init_fatal_signal_set): Use gl_once.
34488 2020-07-03  Bruno Haible  <bruno@clisp.org>
34490         getrandom: Fix compilation error on native Windows (regr. 2020-06-28).
34491         * lib/getrandom.c: Don't include <ntdef.h>. Instead, define NTSTATUS.
34492         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Include <windows.h> before
34493         <bcrypt.h>.
34495 2020-07-03  Bruno Haible  <bruno@clisp.org>
34497         dfa tests: Follow common file naming conventions.
34498         * tests/test-dfa-match-aux.c: Renamed from tests/dfa-match-aux.c.
34499         * tests/test-dfa-match.sh: Renamed from tests/dfa-match.sh. Update.
34500         * tests/test-dfa-invalid-char-class.sh: Renamed from
34501         tests/dfa-invalid-char-class.sh. Update.
34502         * modules/dfa-tests (Files, Makefile.am): Update.
34504 2020-07-03  Bruno Haible  <bruno@clisp.org>
34506         asyncsafe-spin: Use GCC extended asm syntax for SunStudio 12 compiler.
34507         * lib/asyncsafe-spin.c (memory_barrier, atomic_compare_and_swap): Use
34508         the GCC extended asm syntax also for the Sun Studio 12 compilers.
34510 2020-07-03  Bruno Haible  <bruno@clisp.org>
34512         asyncsafe-spin: Reduce code duplication.
34513         * lib/asyncsafe-spin.c (do_lock, do_unlock): New functions.
34514         (asyncsafe_spin_lock, asyncsafe_spin_unlock): Use them.
34515         * modules/asyncsafe-spin (configure.ac): Require AC_C_INLINE.
34517 2020-07-03  Bruno Haible  <bruno@clisp.org>
34519         lchmod: Simplify after 2020-02-22 change.
34520         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Don't require AC_C_INLINE.
34522 2020-07-03  Bruno Haible  <bruno@clisp.org>
34524         gen-uni-tables: Make sure the compiler does not barf on 'inline'.
34525         * modules/gen-uni-tables (configure.ac): Require AC_C_INLINE.
34527 2020-07-03  Bruno Haible  <bruno@clisp.org>
34529         dfa: Make sure the compiler does not barf on 'inline'.
34530         * modules/dfa (configure.ac): Require AC_C_INLINE.
34532 2020-07-03  Bruno Haible  <bruno@clisp.org>
34534         bitset: Make sure the compiler does not barf on 'inline'.
34535         * modules/bitset (configure.ac): New section.
34537 2020-07-01  Paul Eggert  <eggert@cs.ucla.edu>
34539         manywarnings: improve port to GCC 10.1
34540         * build-aux/gcc-warning.spec: Also list warnings that are default
34541         or are enabled by already-given flags.  This lets us speed up
34542         checking for attributes, and makes the generated compilation
34543         commands shorter.  Add -Wanalyzer-too-complex (too much noise).
34544         * m4/manywarnings.m4 (gl_MANYWARN_COMPLEMENT)
34545         (gl_MANYWARN_ALL_GCC): Use gl_AS_VAR_APPEND to append
34546         to shell variables that may have long values.
34547         (gl_MANYWARN_ALL_GCC): Omit flags that are default or are
34548         consequences of other flags, to speed up checking and
34549         shorten commands.
34551         tests: pacify gcc -fanalyzer on zerosize_ptr
34552         * tests/test-memcasecmp.c (main):
34553         * tests/test-memchr.c (main):
34554         * tests/test-memchr2.c (main):
34555         * tests/test-memcmp.c (main):
34556         * tests/test-memmem.c (main):
34557         * tests/test-memrchr.c (main):
34558         * tests/unistr/test-chr.h (main):
34559         * tests/unistr/test-cmp.h (test_cmp):
34560         Check whether zerosize_ptr returns NULL before using it.
34561         This pacifies GCC 10.1’s new fanalyzer option, and matches
34562         other uses of zerosize_ptr.
34564 2020-07-01  Bruno Haible  <bruno@clisp.org>
34566         asyncsafe-spin: Add tests.
34567         * tests/test-asyncsafe-spin1.c: New file.
34568         * tests/test-asyncsafe-spin2.c: New file, based on tests/test-lock.c and
34569         tests/test-pthread-spin.c.
34570         * modules/asyncsafe-spin-tests: New file.
34572 2020-07-01  Bruno Haible  <bruno@clisp.org>
34574         asyncsafe-spin: New module.
34575         * lib/asyncsafe-spin.h: New file.
34576         * lib/asyncsafe-spin.c: New file, based on lib/pthread-spin.c.
34577         * modules/asyncsafe-spin: New file.
34579 2020-07-01  Bruno Haible  <bruno@clisp.org>
34581         windows-spin: Fix race condition on multiprocessor systems.
34582         * lib/windows-spin.c (glwthread_spin_init): Add a memory barrier.
34584 2020-07-01  Bruno Haible  <bruno@clisp.org>
34586         pthread-spin: Add optimized fallback for GCC versions >= 4.1, < 4.7.
34587         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
34588         pthread_spin_trylock, pthread_spin_unlock): For GCC >= 4.1, < 4.7, use
34589         an implementation based on other GCC built-ins.
34591 2020-07-01  Bruno Haible  <bruno@clisp.org>
34593         pthread-spin: Optimize fallback for GCC versions >= 4.7.
34594         * lib/pthread-spin.c (pthread_spin_init, pthread_spin_lock,
34595         pthread_spin_trylock, pthread_spin_unlock): Use a lock word instead of a
34596         lock byte.
34598 2020-07-01  Bruno Haible  <bruno@clisp.org>
34600         pthread-spin: Add error checking.
34601         * lib/pthread-spin.c: Include <stdbool.h>.
34602         (pthread_spin_init, pthread_spin_lock, pthread_spin_trylock,
34603         pthread_spin_unlock) [GCC>=4.7]: Prefer an implementation that verifies
34604         the unlocks.
34605         * modules/pthread-spin (Depends-on): Add stdbool.
34607 2020-07-01  Bruno Haible  <bruno@clisp.org>
34609         pthread-spin: Add tests.
34610         * tests/test-pthread-spin.c: New file, based on tests/test-lock.c.
34611         * modules/pthread-spin-tests: New file.
34613 2020-07-01  Bruno Haible  <bruno@clisp.org>
34615         tests: Reduce code duplication.
34616         * tests/atomic-int-posix.h: New file, extracted from
34617         tests/test-pthread-mutex.c.
34618         * tests/test-pthread-mutex.c: Include it. Remove the corresponding code.
34619         * tests/test-pthread-rwlock.c: Likewise.
34620         * modules/pthread-mutex-tests (Files): Add tests/atomic-int-posix.h.
34621         * modules/pthread-rwlock-tests (Files): Likewise.
34623 2020-07-01  Bruno Haible  <bruno@clisp.org>
34625         tests: Refactor.
34626         * tests/atomic-int-isoc.h: New file, extracted from tests/test-mtx.c.
34627         * tests/test-mtx.c: Include it. Remove the corresponding code.
34628         * modules/mtx-tests (Files): Add tests/atomic-int-isoc.h.
34630 2020-07-01  Bruno Haible  <bruno@clisp.org>
34632         tests: Refactor.
34633         * tests/atomic-int-gnulib.h: New file, extracted from tests/test-lock.c.
34634         * tests/test-lock.c: Include it. Remove the corresponding code.
34635         * modules/lock-tests (Files): Add tests/atomic-int-gnulib.h.
34637 2020-06-29  Bruno Haible  <bruno@clisp.org>
34639         sys_socket: Don't define socklen_t if it is already defined on mingw.
34640         Reported by Keith Marshall <keith.d.marshall@ntlworld.com> in
34641         <https://savannah.gnu.org/bugs/?57725>,
34642         by Rahul Das <bokul_4u@yahoo.com> in
34643         <https://lists.gnu.org/archive/html/bug-gnulib/2020-04/msg00081.html>,
34644         and by Eli Zaretskii <eliz@gnu.org> in
34645         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00068.html>.
34646         * lib/sys_socket.in.h (socklen_t): Remove definition.
34648 2020-06-29  Bruno Haible  <bruno@clisp.org>
34650         alloca-opt: Fix warning on mingw.
34651         Reported and solution by Eli Zaretskii <eliz@gnu.org> in
34652         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00069.html>.
34653         * lib/alloca.in.h: On mingw, include <alloca.h> and then test again
34654         whether alloca is defined.
34656 2020-06-28  Paul Eggert  <eggert@cs.ucla.edu>
34658         getrandom: do not depend on ‘open’ on mingw
34659         Similarly for at-internal, getloadavg.  These modules do not call
34660         the ‘open’ function when they are compiled on mingw.  On mingw,
34661         this avoids having to compile open.c when building Emacs, which
34662         does its own thing with ‘open’.
34663         * modules/at-internal, modules/getloadavg, modules/getrandom:
34664         (Depends-on): Don’t depend on ‘open’ on mingw.
34665         (Depends-on): Require AC_CANONICAL_HOST, for host_os.
34666         * modules/getloadavg (Depends-on):
34667         Depend on intprops, open, stdbool, stdlib only if compiling
34668         getloadavg.c.
34670 2020-06-28  Bruno Haible  <bruno@clisp.org>
34672         doc: Add a note about sigprocmask vs. pthread_sigmask.
34673         * doc/posix-functions/sigprocmask.texi: Add note.
34675 2020-06-28  Bruno Haible  <bruno@clisp.org>
34677         getrandom: Fix compilation errors on older versions of mingw.
34678         Reported by Eli Zaretskii <eliz@gnu.org> in
34679         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00059.html>.
34680         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Test whether <bcrypt.h> exists.
34681         * lib/getrandom.c: If <bcrypt.h> is not available, include <ntdef.h> and
34682         define/declare BCRYPT_ALG_HANDLE, BCRYPT_USE_SYSTEM_PREFERRED_RNG,
34683         BCryptGenRandom ourselves.
34685 2020-06-28  Bruno Haible  <bruno@clisp.org>
34687         clean-temp: Fix wrong errno in error message.
34688         * lib/clean-temp.c (create_temp_dir): Save errno around
34689         unblock_fatal_signals call.
34691 2020-06-27  Bruno Haible  <bruno@clisp.org>
34693         fatal-signal: Make multithread-safe.
34694         * lib/fatal-signal.c (at_fatal_signal): Don't free the old actions array.
34696 2020-06-27  Bruno Haible  <bruno@clisp.org>
34698         clean-temp: Don't force deletion of temporary files on native Windows.
34699         * lib/clean-temp.h (open_temp, fopen_temp): Add delete_on_close
34700         argument.
34701         * lib/clean-temp.c (open_temp, fopen_temp): Likewise.
34702         * NEWS: Mention the change.
34703         * lib/javacomp.c (write_temp_file): Update.
34705 2020-06-27  Bruno Haible  <bruno@clisp.org>
34707         fatal-signal: Make multithread-safe.
34708         * lib/fatal-signal.c: Include glthread/lock.h.
34709         (at_fatal_signal_lock): New variable.
34710         (at_fatal_signal): Use it.
34711         (fatal_signals_block_lock, fatal_signals_block_counter): New variables.
34712         (block_fatal_signals, unblock_fatal_signals): Use them.
34713         * modules/fatal-signal (Depends-on): Add lock.
34715 2020-06-27  Paul Eggert  <eggert@cs.ucla.edu>
34717         getloadavg: don’t depend on fopen-gnu
34718         This is for Emacs, which does not need fopen-gnu for anything else,
34719         and which would need it only on a NetBSD platform where getloadavg
34720         does not work (does that even happen?).
34721         * lib/getloadavg.c (getloadavg) [__NetBSD__]: Use open, not fopen.
34722         * modules/getloadavg (Depends-on): Remove fopen-gnu.
34724         * tests/test-getloadavg.c (main): Fix typo.
34726 2020-06-27  Bruno Haible  <bruno@clisp.org>
34728         tempname et al.: Fix link errors on MSVC (regression from 2020-05-31).
34729         * modules/tempname (Link): New section.
34730         * modules/mkdtemp (Link): Likewise.
34731         * modules/clean-temp (Link): Likewise.
34732         * modules/mkstemp (Link): Likewise.
34733         * modules/stdlib-safer (Link): Likewise.
34734         * modules/mkstemps (Link): Likewise.
34735         * modules/mkostemp (Link): Likewise.
34736         * modules/mkostemps (Link): Likewise.
34737         * modules/tmpfile (Link): Likewise.
34738         * modules/tmpfile-safer (Link): Likewise.
34739         * modules/javacomp (Link): Add $(LIB_GETRANDOM).
34740         * modules/argv-iter-tests (Makefile.am): Link test-argv-iter with
34741         $(LIB_GETRANDOM).
34742         * NEWS: Mention the changes.
34744 2020-06-27  Bruno Haible  <bruno@clisp.org>
34746         fopen-gnu: Simplify code.
34747         * lib/fopen.c: Include <stdbool.h>.
34748         (rpl_fopen): Use a single variable open_flags instead of
34749         open_flags_standard and open_flags_gnu. Make open_flags_gnu a bool.
34750         * modules/fopen (Depends-on): Add stdbool.
34752 2020-06-26  Bruno Haible  <bruno@clisp.org>
34754         canonicalize: Improve documentation.
34755         * lib/canonicalize.h (canonicalize_filename_mode): Document the failure
34756         return convention.
34758 2020-06-26  Bruno Haible  <bruno@clisp.org>
34760         xgetcwd: Improve documentation.
34761         * lib/xgetcwd.c (xgetcwd): Document the failure return convention.
34763 2020-06-26  Bruno Haible  <bruno@clisp.org>
34765         getcwd: Improve documentation.
34766         * lib/getcwd.c (__getcwd): Document the failure return convention.
34768 2020-06-26  Bruno Haible  <bruno@clisp.org>
34770         fchdir: Improve documentation.
34771         * lib/fchdir.c (get_name, _gl_register_fd): Document the failure return
34772         convention.
34774 2020-06-26  Bruno Haible  <bruno@clisp.org>
34776         filenamecat-lgpl: Set errno upon failure.
34777         * lib/filenamecat-lgpl.c (mfile_name_concat): Document the failure
34778         return convention.
34779         * modules/filenamecat-lgpl (Depends-on): Add malloc-posix.
34781 2020-06-26  Bruno Haible  <bruno@clisp.org>
34783         areadlink-with-size: Set errno upon failure.
34784         * lib/areadlink-with-size.c (areadlink_with_size): Set errno when malloc
34785         fails.
34786         * lib/areadlinkat-with-size.c (areadlinkat_with_size): Add comment.
34788 2020-06-26  Bruno Haible  <bruno@clisp.org>
34790         copy-file: Shrink dependencies.
34791         * modules/copy-file (Depends-on): Remove acl. Add acl-permissions,
34792         qcopy-acl.
34794 2020-06-26  Bruno Haible  <bruno@clisp.org>
34796         doc: Mention declaration fixes implemented by some modules.
34797         * doc/posix-functions/chdir.texi: Mention the module 'chdir'.
34798         * doc/posix-functions/close.texi: Mention that Gnulib makes the function
34799         declaration appear in <unistd.h>.
34800         * doc/posix-functions/dup.texi: Likewise.
34801         * doc/posix-functions/dup2.texi: Likewise.
34802         * doc/posix-functions/gethostname.texi: Likewise.
34803         * doc/posix-functions/isatty.texi: Likewise.
34804         * doc/posix-functions/lseek.texi: Likewise.
34805         * doc/posix-functions/unlink.texi: Likewise.
34806         * doc/posix-functions/read.texi: Mention the module 'read'.
34807         * doc/posix-functions/write.texi: Mention the effects of the module
34808         'write'.
34810 2020-06-25  Marc Nieper-Wißkirchen  <marc@nieper-wisskirchen.de>
34812         c-dtoastr, c-ldtoastr: new modules
34813         These modules provide the same functionality as the modules
34814         dtoastr and ldtoastr except for the formatting taking place in the
34815         C locale.
34816         * MODULES.html.sh: Add c-dtoastr and c-ldtoastr.
34817         * lib/c-dtoastr.c, lib/c-ldtoastr.c: New files.
34818         * lib/ftoastr.c: Prefix exported functions when the macro C_LOCALE is
34819         defined.  Use c_snprintf and c_strtod/c_strtold instead of
34820         snprintf and strtod/strtold whhen the macro C_LOCALE is defined.
34821         * lib/ftoastr.h: Add prototypes for c_dtoastr and c_ldtoastr.
34822         * modules/c-dtoastr, modules/c-dtoastr-tests, modules/c-ldtoastr,
34823         modules/c-ldtoastr-tests: New files.
34824         * tests/test-c-dtoastr.c, tests/test-c-dtoastr.sh,
34825         tests-c-ldtoastr.c tests-c-ldtoastr.sh: New files.
34827 2020-06-21  Bruno Haible  <bruno@clisp.org>
34829         tzset: Fix compilation warnings on mingw (regression from 2017-05-01).
34830         * lib/tzset.c: Include <stdlib.h>, <string.h>.
34832 2020-06-16  Bruno Haible  <bruno@clisp.org>
34834         thread: Avoid possible compiler warnings in uses of gl_thread_exit.
34835         * lib/glthread/thread.h (gl_thread_exit): Add a cast to void.
34837 2020-06-16  Bruno Haible  <bruno@clisp.org>
34839         thread, thrd: Avoid a compiler warning.
34840         * lib/windows-thread.h (glwthread_thread_exit): Mark as non-returning.
34842 2020-06-16  Biswapriyo Nath  <nathbappai@gmail.com>  (tiny change)
34844         windows-thread: Avoid a compiler warning.
34845         * lib/windows-thread.h (glwthread_thread_exit): Change return type to
34846         void.
34847         * lib/windows-thread.c (glwthread_thread_exit): Likewise.
34849 2020-06-15  Bruno Haible  <bruno@clisp.org>
34851         unictype/joininggroup-name: Fix warning on 64-bit mingw.
34852         Reported by Biswapriyo Nath <nathbappai@gmail.com> in
34853         <https://lists.gnu.org/archive/html/bug-gnulib/2020-06/msg00036.html>.
34854         * lib/unictype/joininggroup_name.c (ELEM): Cast struct offset to size_t
34855         first.
34857 2020-06-06  Bruno Haible  <bruno@clisp.org>
34859         calloc-gnu tests: Avoid a test failure with clang.
34860         * tests/test-calloc-gnu.c (main): Mark the pointer variable as
34861         'volatile', to defeat compiler optimizations.
34863 2020-06-01  Paul Eggert  <eggert@cs.ucla.edu>
34865         getloadavg: fix double-increment bug
34866         * lib/getloadavg.c (getloadavg): Fix double-increment typo on
34867         Linux without glibc, Android, Cygwin.  This fixes a bug I
34868         introduced in 2011-02-08T20:23:29Z!eggert@cs.ucla.edu.
34869         Problem and fix reported by Semen Verchenko in:
34870         https://lists.gnu.org/r/bug-gnulib/2020-06/msg00007.html
34872         tempname: use getrandom, not getentropy
34873         This removes a dependency, as getentropy depends on getrandom.
34874         * lib/tempname.c: Include sys/random.h instead of unistd.h.
34875         (RANDOM_BITS) [!_LIBC]: Use getrandom, not getentropy.
34876         * modules/tempname (Depends-on): Depend on getrandom, not getentropy.
34878 2020-06-01  Bruno Haible  <bruno@clisp.org>
34880         doc: New chapter 'Multithreading'.
34881         * doc/multithread.texi: New file.
34882         * doc/gnulib.texi: Include it.
34884 2020-06-01  Bruno Haible  <bruno@clisp.org>
34886         doc: Move 'Running self-tests under valgrind' section.
34887         * doc/gnulib.texi (Build Infrastructure Modules): Include
34888         valgrind-tests.texi here...
34889         (Miscellaneous Notes): ... not here.
34891 2020-06-01  Bruno Haible  <bruno@clisp.org>
34893         doc: Move 'Visual Studio Compatibility' section.
34894         * doc/gnulib.texi (Native Windows Support): Include ld-output-def.texi
34895         here...
34896         (Build Infrastructure Modules): ... not here.
34898 2020-06-01  Paul Eggert  <eggert@cs.ucla.edu>
34900         doc: improve randomness discussion
34901         Inspired by comments from Jeffrey Walton in:
34902         https://lists.gnu.org/r/bug-gnulib/2020-06/msg00002.html
34903         * doc/glibc-functions/getentropy.texi (getentropy):
34904         * doc/glibc-functions/getrandom.texi (getrandom):
34905         Improve discussion of problems with "random" data,
34906         and cite Ristenpart & Yilek.  Also, mention GRND_INSECURE.
34908 2020-06-01  Bruno Haible  <bruno@clisp.org>
34910         doc: Fix Texinfo syntax error.
34911         * doc/glibc-functions/getrandom.texi: Add missing '@item'.
34913 2020-06-01  Asher Gordon  <AsDaGo@posteo.net>
34915         doc: Change '.' to '@.' where appropriate.
34916         * doc/c-ctype.texi: Change '.' to '@.' where appropriate.
34917         * doc/glibc-functions/fstatfs.texi: Likewise.
34918         * doc/glibc-functions/fts_children.texi: Likewise.
34919         * doc/glibc-functions/fts_read.texi: Likewise.
34920         * doc/glibc-functions/getdirentries.texi: Likewise.
34921         * doc/glibc-functions/mkostemp.texi: Likewise.
34922         * doc/glibc-functions/mkostemps.texi: Likewise.
34923         * doc/glibc-functions/mkstemps.texi: Likewise.
34924         * doc/glibc-functions/preadv.texi: Likewise.
34925         * doc/glibc-functions/pwritev.texi: Likewise.
34926         * doc/glibc-functions/sendfile.texi: Likewise.
34927         * doc/glibc-functions/statfs.texi: Likewise.
34928         * doc/gnulib-intro.texi: Likewise.
34929         * doc/gnulib-tool.texi: Likewise.
34930         * doc/intprops.texi: Likewise.
34931         * doc/lib-symbol-visibility.texi: Likewise.
34932         * doc/licenses-texi.texi: Likewise.
34933         * doc/pastposix-functions/bcmp.texi: Likewise.
34934         * doc/pastposix-functions/bcopy.texi: Likewise.
34935         * doc/pastposix-functions/bzero.texi: Likewise.
34936         * doc/pastposix-functions/ecvt.texi: Likewise.
34937         * doc/pastposix-functions/fcvt.texi: Likewise.
34938         * doc/pastposix-functions/ftime.texi: Likewise.
34939         * doc/pastposix-functions/gcvt.texi: Likewise.
34940         * doc/pastposix-functions/getwd.texi: Likewise.
34941         * doc/pastposix-functions/index.texi: Likewise.
34942         * doc/pastposix-functions/mktemp.texi: Likewise.
34943         * doc/pastposix-functions/rindex.texi: Likewise.
34944         * doc/pastposix-functions/wcswcs.texi: Likewise.
34945         * doc/posix-functions/aio_cancel.texi: Likewise.
34946         * doc/posix-functions/aio_error.texi: Likewise.
34947         * doc/posix-functions/aio_fsync.texi: Likewise.
34948         * doc/posix-functions/aio_read.texi: Likewise.
34949         * doc/posix-functions/aio_return.texi: Likewise.
34950         * doc/posix-functions/aio_suspend.texi: Likewise.
34951         * doc/posix-functions/aio_write.texi: Likewise.
34952         * doc/posix-functions/creat.texi: Likewise.
34953         * doc/posix-functions/ctime.texi: Likewise.
34954         * doc/posix-functions/daylight.texi: Likewise.
34955         * doc/posix-functions/fgetpos.texi: Likewise.
34956         * doc/posix-functions/fopen.texi: Likewise.
34957         * doc/posix-functions/freopen.texi: Likewise.
34958         * doc/posix-functions/fseeko.texi: Likewise.
34959         * doc/posix-functions/fsetpos.texi: Likewise.
34960         * doc/posix-functions/fstatat.texi: Likewise.
34961         * doc/posix-functions/fstatvfs.texi: Likewise.
34962         * doc/posix-functions/ftello.texi: Likewise.
34963         * doc/posix-functions/ftruncate.texi: Likewise.
34964         * doc/posix-functions/getrlimit.texi: Likewise.
34965         * doc/posix-functions/lio_listio.texi: Likewise.
34966         * doc/posix-functions/localtime.texi: Likewise.
34967         * doc/posix-functions/lseek.texi: Likewise.
34968         * doc/posix-functions/mkstemp.texi: Likewise.
34969         * doc/posix-functions/mktime.texi: Likewise.
34970         * doc/posix-functions/open.texi: Likewise.
34971         * doc/posix-functions/openat.texi: Likewise.
34972         * doc/posix-functions/opendir.texi: Likewise.
34973         * doc/posix-functions/pread.texi: Likewise.
34974         * doc/posix-functions/pwrite.texi: Likewise.
34975         * doc/posix-functions/readdir.texi: Likewise.
34976         * doc/posix-functions/readdir_r.texi: Likewise.
34977         * doc/posix-functions/scandir.texi: Likewise.
34978         * doc/posix-functions/seekdir.texi: Likewise.
34979         * doc/posix-functions/setrlimit.texi: Likewise.
34980         * doc/posix-functions/statvfs.texi: Likewise.
34981         * doc/posix-functions/strftime.texi: Likewise.
34982         * doc/posix-functions/telldir.texi: Likewise.
34983         * doc/posix-functions/timezone.texi: Likewise.
34984         * doc/posix-functions/tmpfile.texi: Likewise.
34985         * doc/posix-functions/truncate.texi: Likewise.
34986         * doc/posix-functions/tzname.texi: Likewise.
34987         * doc/posix-functions/wcsftime.texi: Likewise.
34988         * doc/windows-sockets.texi: Likewise.
34990 2020-05-31  Paul Eggert  <eggert@cs.ucla.edu>
34992         getrandom-tests: do not assume GRND_RANDOM yields short read
34993         * tests/test-getrandom.c (main): Omit assertion that
34994         getrandom (b, sizeof b, GRND_RANDOM | GRND_NONBLOCK) < sizeof b
34995         when b’s size is 100000.  This assertion fails with Linux kernel
34996         5.6.13, as that kernel ignores the GRND_RANDOM flag.
34997         The separate blocking pool is going away in the Linux kernel, and
34998         they’ve added a flag GRND_INSECURE instead; see:
34999         https://lore.kernel.org/linux-api/705c5a091b63cc5da70c99304bb97e0109be0a26.1577088521.git.luto@kernel.org/
35000         The assertion was iffy anyway; what’s to prevent a kernel from
35001         lazily filling a large buffer with random bytes?
35003         read-file-test: pacify --enable-gcc-warnings
35004         * tests/test-read-file.c (test_read_file): Now static.
35006         tempname: merge from glibc and coreutils
35007         Also, merge in Gnulib’s more-recent methods of making it easier
35008         to share between Gnulib and glibc, and fix a few randomness
35009         glitches.
35010         * lib/tempname.c: Include libc-config.h, not config.h, if !_LIBC.
35011         (__set_errno): Remove; libc-config.h does that for us.
35012         Do not include <sys/time.h>.
35013         (__secure_getenv) [_LIBC]: New macro.
35014         (__try_tempname, __getpid, __gettimeofday) [!_LIBC]: Remove macros.
35015         (RANDOM_BITS): Rewrite.
35016         (RANDOM_VALUE_MAX, BASE_62_DIGITS, BASE_62_POWER): New macros.
35017         (random_value): New typedef.
35018         (try_file, try_dir, try_nocreate): Move up.
35019         (gen_tempname_len, try_tempname_len): New functions.
35020         (gen_tempname_len): Use a constant array rather than a switch.
35021         (try_tempname_len): Don’t assume string length fits in int.
35022         Generalize use of RANDOM_BITS.  If _LIBC, don’t assume RANDOM_BITS
35023         has enough entropy (it’s a bit short).
35024         (__gen_tempname): Rewrite in terms of gen_tempname_len.
35025         (__try_tempname): Rewrite in terms of try_tempname_len.
35026         * lib/tempname.h (gen_tempname_len, try_tempname_len): New decls.
35027         * modules/tempname (Depends-on): Remove gettimeofday, sys_time.
35028         Add getentropy, libc-config.
35030 2020-05-31  Bruno Haible  <bruno@clisp.org>
35032         getrandom, getentropy: Mention the crypto/gc-random module.
35033         Suggested by Simon Josefsson in
35034         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00400.html>.
35035         * doc/glibc-functions/getrandom.texi: Mention the quality issues and the
35036         crypto/gc-random module.
35037         * doc/glibc-functions/getentropy.texi: Likewise.
35039 2020-05-31  Bruno Haible  <bruno@clisp.org>
35041         getentropy: Enhance tests.
35042         * tests/test-getentropy.c (main): Add one more test.
35043         * tests/test-unistd-c++.cc: Check the signature of getentropy.
35045 2020-05-31  Bruno Haible  <bruno@clisp.org>
35047         getentropy: Work around a macOS and Solaris problem.
35048         * lib/unistd.in.h: Include <sys/random.h>, when needed for the
35049         'getentropy' module.
35050         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
35051         UNISTD_H_HAVE_SYS_RANDOM_H.
35052         * m4/sys_random_h.m4 (gl_HEADER_SYS_RANDOM): Set
35053         UNISTD_H_HAVE_SYS_RANDOM_H.
35054         * modules/unistd (Makefile.am): Substitute UNISTD_H_HAVE_SYS_RANDOM_H.
35055         * doc/glibc-functions/getentropy.texi: Document the macOS and Solaris
35056         problem. List more platforms.
35058 2020-05-31  Paul Eggert  <eggert@cs.ucla.edu>
35060         fnmatch: merge from glibc
35061         Also, merge in Gnulib’s more-recent methods of making it easier
35062         to share between Gnulib and glibc.
35063         * lib/fnmatch.c: Reorder includes to match glibc better.
35064         Include libc-config.h instead of config.h.
35065         Include alloca.h only if _LIBC || HAVE_ALLOCA.
35066         Do not include "../locale/elem-hash.h" if _LIBC.
35067         Define macros for btowc, etc. if _LIBC.  All uses simplified.
35068         Define FALLTHROUGH if _LIBC, instead of including attribute.h.
35069         Include intprops.h, since glibc has it now.
35070         (SIZE_MAX): Remove; use (size_t) -1 instead.
35071         Omit the "Comment out all this code" ifdef, since Gnulib
35072         has never really needed it.
35073         (STREQ): Remove; no longer used.
35074         (__libc_use_alloca, alloca, alloca_account): Define as
35075         needed if !_LIBC.
35076         (ISWCTYPE): Remove; all uses replaced by iswctype.
35077         (HANDLE_MULTIBYTE): Remove.  All uses removed by assuming true.
35078         (internal_function): Remove.  All uses removed.
35079         (STRUCT): New macro.
35080         (WIDE_CHAR_VERSION): Define to 0 instead of leaving undefined.
35081         (WMEMCMP): New macro.
35082         (FINDIDX): Define if _LIBC, and include <locale/weight.h>
35083         and <locale/weightwc.h>.
35084         (fnmatch): Prefer __glibc_likely and __glibc_unlikely to
35085         __builtin_expect.  Check for integer overflow more
35086         systematically.  Account for alloca storage better when
35087         recursive.  Use strnlen instead of strlen for efficiency.
35088         * lib/fnmatch_loop.c: Include stdint.h if _LIBC, for int32_t etc.
35089         (struct STRUCT): New type.
35090         (FCT, EXT): New ENDS and ALLOCA_USED args.
35091         All callers changed.
35092         (FCT): Prefer __glibc_unlikely to __builtin_expect.
35093         Simplify by assuming WIDE_CHAR_SUPPORT.
35094         Copy _LIBC code from glibc without worrying Gnulib compatibility.
35095         Cast cold to UCHAR to avoid signedness warning.
35096         (END): Check for invalid pattern.
35097         (EXT): Improve alloca/malloc checking (taken from glibc),
35098         and improve it some more by using intprops.h and checking
35099         for integer overflow and using bool for booleans.
35100         * lib/libc-config.h (compat_symbol): New macro.
35101         (versioned_symbol): Make it ‘extern int dummy’ so that it’s
35102         acceptable to non-GCC when a trailing semicolon is added.
35103         * modules/fnmatch (Depends-on): Add alloca-opt, intprops,
35104         libc-config, strnlen.  Remove alloca.
35106 2020-05-31  Bruno Haible  <bruno@clisp.org>
35108         getrandom: Doc and test tweaks.
35109         * lib/getrandom.c (getrandom): Mention that it never returns 0, and that
35110         it sets errno when failing.
35111         * tests/test-getrandom.c (main): Disable the high-quality check on those
35112         platforms on which it fails.
35113         * doc/glibc-functions/getrandom.texi: Add Minix, AIX, HP-UX, IRIX,
35114         Cygwin to the list of platforms that don't have the function. Add a note
35115         about the quality of the result.
35116         * doc/glibc-headers/sys_random.texi: Don't mention the 'getrandom'
35117         declaration; this is fixed by module 'getrandom'.
35119 2020-05-31  Bruno Haible  <bruno@clisp.org>
35121         getrandom: Add support for native Windows.
35122         * lib/getrandom.c: Include <errno.h>, <windows.h>, <bcrypt.h>,
35123         <wincrypt.h>.
35124         (CRYPT_VERIFY_CONTEXT): New macro.
35125         (LoadLibrary, CryptAcquireContext): Redirect to the variant with suffix
35126         'A'.
35127         (GetProcAddress): New macro.
35128         (BCryptGenRandomFuncType): New type.
35129         (BCryptGenRandomFunc, initialized): New variables.
35130         (initialize): New function.
35131         (getrandom): On native Windows, use <bcrypt.h> API when available, and
35132         <wincrypt.h> API as fallback.
35133         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Set LIB_GETRANDOM.
35134         * modules/getrandom (Link): New section.
35135         * modules/getentropy (Link): Likewise.
35136         * modules/getrandom-tests (Makefile.am): Link test-getrandom against
35137         $(LIB_GETRANDOM).
35138         * modules/getentropy-tests (Makefile.am): Link test-getentropy against
35139         $(LIB_GETRANDOM).
35140         * modules/sys_random-c++-tests (Makefile.am): Link test-sys_random-c++
35141         against $(LIB_GETRANDOM).
35142         * doc/glibc-functions/getrandom.texi: Mention the native Windows
35143         support.
35145 2020-05-31  Bruno Haible  <bruno@clisp.org>
35147         getrandom: Simplify the determination of the random number devices.
35148         Suggested by Paul Eggert in
35149         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00383.html>.
35150         * lib/getrandom.c (NAME_OF_RANDOM_DEVICE, NAME_OF_NONCE_DEVICE): New
35151         macros.
35152         * modules/getrandom (Depends-on): Remove crypto/gc-random.
35154 2020-05-31  Bruno Haible  <bruno@clisp.org>
35156         crypto/gc-random: Fix list of crypto devices for Solaris.
35157         * m4/gc-random.m4 (gl_GC_RANDOM): Don't special-case Solaris.
35159 2020-05-31  Akim Demaille  <akim@lrde.epita.fr>
35161         list: fix GCC warnings
35162         * lib/gl_anytree_list2.h (gl_tree_iterator_free)
35163         (gl_tree_next_node, gl_tree_node_nx_set_value)
35164         (gl_tree_previous_node, gl_tree_next_node):
35165         Mark unused arguments.
35166         * lib/gl_anytree_oset.h (gl_tree_iterator_free): Likewise.
35167         * lib/gl_anylinked_list2.h (gl_linked_node_value)
35168         (gl_linked_node_nx_set_value, gl_linked_iterator_free): Likewise.
35170         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Avoid using
35171         the same variable name in nested scopes.
35173 2020-05-31  Bruno Haible  <bruno@clisp.org>
35175         list-c++, set-c++, oset-c++, map-c++, omap-c++: Don't fool the compiler.
35176         Reported by Akim Demaille in
35177         <https://lists.gnu.org/archive/html/bug-bison/2020-05/msg00102.html>.
35178         * lib/gl_list.hh (gl_List::iterator::next): Avoid a reinterpret_cast.
35179         * lib/gl_set.hh (gl_Set::iterator::next): Likewise.
35180         * lib/gl_oset.hh (gl_OSet::iterator::next): Likewise.
35181         * lib/gl_map.hh (gl_Map::iterator::next): Likewise.
35182         * lib/gl_omap.hh (gl_OMap::iterator::next): Likewise.
35184 2020-05-30  Bruno Haible  <bruno@clisp.org>
35186         wmemchr: Relicense under LGPLv2+.
35187         * modules/wmemchr (License): Set to LGPLv2+.
35189 2020-05-30  Bruno Haible  <bruno@clisp.org>
35191         wmempcpy: New module.
35192         Reported by Paul Eggert in
35193         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00387.html>.
35194         * lib/wchar.in.h (wmempcpy): New declaration.
35195         * lib/wmempcpy.c: New file.
35196         * m4/wmempcpy.m4: New file.
35197         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmempcpy is declared.
35198         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMPCPY, HAVE_WMEMPCPY.
35199         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMPCPY,
35200         HAVE_WMEMPCPY.
35201         * modules/wmempcpy: New file.
35202         * tests/test-wchar-c++.cc: Check the signature of wmempcpy.
35203         * doc/glibc-functions/wmempcpy.texi: Mention the new module.
35204         * modules/mempcpy (Description): Fix typo.
35206 2020-05-30  Bruno Haible  <bruno@clisp.org>
35208         crypto/gc-random: Fix list of crypto devices for NetBSD, OpenBSD.
35209         * m4/gc-random.m4 (gl_GC_RANDOM): Don't special-case NetBSD and OpenBSD.
35211 2020-05-30  Bruno Haible  <bruno@clisp.org>
35213         sys_random: Work around macOS bug.
35214         * m4/sys_random_h.m4 (gl_HEADER_SYS_RANDOM): Include <sys/types.h> and
35215         <stdlib.h> before <sys/random.h>.
35216         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Likewise.
35217         * lib/sys_random.in.h: On macOS, include <sys/types.h> and <stdlib.h>
35218         first.
35219         * doc/glibc-headers/sys_random.texi: Mention the macOS problem.
35221 2020-05-30  Bruno Haible  <bruno@clisp.org>
35223         getrandom: Override incompatible system function on Solaris 11.
35224         * lib/sys_random.in.h (getrandom): Override if REPLACE_GETRANDOM is 1.
35225         * lib/getrandom.c (getrandom): When the system has getrandom, just
35226         invoke it.
35227         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Set REPLACE_GETRANDOM if the
35228         system's getrandom function's prototype is not the expected one.
35229         * m4/sys_random_h.m4 (gl_SYS_RANDOM_H_DEFAULTS): Initialize
35230         REPLACE_GETRANDOM.
35231         * modules/sys_random (Makefile.am): Substitute REPLACE_GETRANDOM.
35232         * modules/getrandom (modules/getrandom): Consider REPLACE_GETRANDOM.
35233         * tests/test-getrandom.c (main): Allow error EINVAL as an alternative to
35234         EAGAIN.
35235         * doc/glibc-functions/getrandom.texi: Mention the new module and the
35236         Solaris problem.
35238 2020-05-30  Bruno Haible  <bruno@clisp.org>
35240         sys_random: Add C++ tests.
35241         * tests/test-sys_random-c++.cc: New file.
35242         * modules/sys_random-c++-tests: New file.
35243         * modules/sys_random-tests (Depends-on): Depend on it.
35245         sys_random: Add tests.
35246         * tests/test-sys_random.c: New file.
35247         * modules/sys_random-tests: New file.
35249         sys_random: New module.
35250         * lib/sys_random.in.h: Use the common idioms for overridable header
35251         files.
35252         * m4/sys_random_h.m4: New file.
35253         * m4/getrandom.m4 (gl_FUNC_GETRANDOM): Require gl_SYS_RANDOM_H_DEFAULTS.
35254         * modules/sys_random: New file.
35255         * modules/getrandom (Files): Remove lib/sys_random.in.h.
35256         (Depends-on): Add sys_random.
35257         (configure.ac): Use gl_SYS_RANDOM_MODULE_INDICATOR, not
35258         gl_UNISTD_MODULE_INDICATOR.
35259         (Makefile.am): Don't generate sys/random.h here.
35260         * doc/glibc-headers/sys_random.texi: New file.
35261         * doc/gnulib.texi: Include it.
35263 2020-05-30  Bruno Haible  <bruno@clisp.org>
35265         unistd: Remove conflicting declaration of getrandom().
35266         * lib/unistd.in.h (getrandom): Remove declaration.
35267         * m4/unistd_h.m4 (gl_UNISTD_H): Don't test whether getrandom is
35268         declared.
35269         (gl_UNISTD_H_DEFAULTS): Don't initialize GNULIB_GETRANDOM,
35270         HAVE_GETRANDOM.
35271         * modules/unistd (Makefile.am): Don't substitute GNULIB_GETRANDOM,
35272         HAVE_GETRANDOM.
35274 2020-05-30  Bruno Haible  <bruno@clisp.org>
35276         getrandom: Add tests.
35277         * tests/test-getrandom.c: New file.
35278         * modules/getrandom-tests: New file.
35280 2020-05-30  Bruno Haible  <bruno@clisp.org>
35282         crypto/gc-random: Fix link error on MSVC.
35283         * m4/gc-random.m4 (gl_GC_RANDOM): Set LIB_GC_RANDOM.
35284         * modules/crypto/gc-random (Link): New section.
35285         * modules/crypto/gc-tests (Makefile.am): Link test-gc against
35286         $(LIB_GC_RANDOM).
35288 2020-05-30  Bruno Haible  <bruno@clisp.org>
35290         Don't assume that UNICODE is not defined.
35291         Many Windows API functions are defined differently (redirecting to a
35292         function with suffix 'W') if the application defines the macro UNICODE
35293         than by default (redirecting to a function with suffix 'A').
35294         * lib/clean-temp.c (OSVERSIONINFO, GetVersionEx): Redirect to the
35295         variant with suffix 'A'.
35296         * lib/dirent-private.h (WIN32_FIND_DATA): Likewise.
35297         * lib/gc-gnulib.c (CryptAcquireContext): Likewise.
35298         * lib/getaddrinfo.c (GetModuleHandle): Likewise.
35299         * lib/getlogin.c (GetUserName): Likewise.
35300         * lib/getlogin_r.c (GetUserName): Likewise.
35301         * lib/gettimeofday.c (LoadLibrary): Likewise.
35302         * lib/isatty.c (LoadLibrary, QueryFullProcessImageName): Likewise.
35303         * lib/link.c (GetModuleHandle, CreateHardLink): Likewise.
35304         * lib/localename.c (GetLocaleInfo, EnumSystemLocales): Likewise.
35305         * lib/mountlist.c (GetDriveType): Likewise.
35306         * lib/nonblocking.c (GetNamedPipeHandleState): Likewise.
35307         * lib/opendir.c (WIN32_FIND_DATA, GetFullPathName, FindFirstFile):
35308         Likewise.
35309         * lib/physmem.c (GetModuleHandle): Likewise.
35310         * lib/poll.c (GetModuleHandle, PeekConsoleInput, CreateEvent,
35311         PeekMessage, DispatchMessage): Likewise.
35312         * lib/progreloc.c (GetModuleFileName): Likewise.
35313         * lib/putenv.c (SetEnvironmentVariable): Likewise.
35314         * lib/read.c (GetNamedPipeHandleState): Likewise.
35315         * lib/readdir.c (FindNextFile): Likewise.
35316         * lib/relocatable.c (GetModuleFileName): Likewise.
35317         * lib/rename.c (MoveFileEx): Likewise.
35318         * lib/rewinddir.c (FindFirstFile): Likewise.
35319         * lib/select.c (GetModuleHandle, PeekConsoleInput, CreateEvent,
35320         PeekMessage, DispatchMessage): Likewise.
35321         * lib/sethostname.c (GetComputerNameEx, SetComputerNameEx): Likewise.
35322         * lib/socket.c (WSASocket): Likewise.
35323         * lib/stat-w32.c (LoadLibrary, GetFinalPathNameByHandle): Likewise.
35324         * lib/stat.c (WIN32_FIND_DATA, CreateFile, FindFirstFile): Likewise.
35325         * lib/stdio-read.c (GetNamedPipeHandleState): Likewise.
35326         * lib/stdio-write.c (GetNamedPipeHandleState): Likewise.
35327         * lib/tmpdir.c (GetTempPath): Likewise.
35328         * lib/tmpfile.c (OSVERSIONINFO, GetVersionEx, GetTempPath): Likewise.
35329         * lib/uname.c (OSVERSIONINFO, GetVersionEx): Likewise.
35330         * lib/utime.c (CreateFile, GetFileAttributes): Likewise.
35331         * lib/windows-cond.c (CreateEvent): Likewise.
35332         * lib/windows-rwlock.c (CreateEvent): Likewise.
35333         * lib/windows-timedmutex.c (CreateEvent): Likewise.
35334         * lib/windows-timedrecmutex.c (CreateEvent): Likewise.
35335         * lib/windows-timedrwlock.c (CreateEvent): Likewise.
35336         * lib/write.c (GetNamedPipeHandleState): Likewise.
35338 2020-05-30  Bruno Haible  <bruno@clisp.org>
35340         physmem: Fix compilation errors on MSVC.
35341         * lib/physmem.c (PFN_MS_EX): Use BOOL, not WINBOOL.
35342         * modules/physmem (Depends-on): Add unistd.
35344 2020-05-29  Bruno Haible  <bruno@clisp.org>
35346         gnulib-tool: Fix link errors with a particular set of modules on mingw.
35347         * gnulib-tool (func_emit_tests_Makefile_am): Add ../lib/libgnu.a to
35348         LDADD a second time, after the second occurrence of libtests.a.
35349         * pygnulib/GLEmiter.py (tests_Makefile_am): Likewise.
35351 2020-05-29  Bruno Haible  <bruno@clisp.org>
35353         fnmatch: Rely on more gnulib modules.
35354         * modules/fnmatch (Depends-on): Add btowc, isblank, iswctype, wmemchr,
35355         wmempcpy, mempcpy.
35356         * lib/fnmatch.c: Assume that HAVE_WCTYPE_H, HAVE_BTOWC, HAVE_ISWCTYPE,
35357         HAVE_WMEMCHR, HAVE_WMEMPCPY, HAVE_ISBLANK, HAVE_DECL_ISBLANK,
35358         HAVE_MEMPCPY are all 1.
35359         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): Don't test for btowc, isblank,
35360         iswctype, mempcpy, wmemchr, wmemcpy, wmempcpy, <wctype.h>.
35362 2020-05-29  Bruno Haible  <bruno@clisp.org>
35364         Avoid dynamic lookup of Windows API functions when possible.
35365         * lib/getaddrinfo.c (GetProcAddress, getaddrinfo_func,
35366         freeaddrinfo_func, getnameinfo_func, getaddrinfo_ptr, freeaddrinfo_ptr,
35367         getnameinfo_ptr): Don't define in a build for Windows XP or higher.
35368         (use_win32_p): Define differently.
35369         * lib/link.c (GetProcAddress, CreateHardLinkFuncType,
35370         CreateHardLinkFunc, initialized, initialize): Don't define in a build
35371         for Windows XP or higher.
35373 2020-05-29  Daiki Ueno  <ueno@gnu.org>
35375         read-file: disable buffering if RF_SENSITIVE is set
35376         * lib/read-file.c (read_file): Call setvbuf if RF_SENSITIVE.
35377         Suggested by Glenn Strauss.
35378         (fread_file): Suggest calling setvbuf before calling this
35379         function.  Suggested by Bruno Haible.
35381 2020-05-29  Bruno Haible  <bruno@clisp.org>
35383         wmemchr, wmemcmp, wmemcpy, wmemmove, wmemset: Fix autoconf test.
35384         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Link, not only compile, the test
35385         program.
35386         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Likewise.
35387         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Likewise.
35388         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Likewise.
35389         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Likewise.
35391 2020-05-29  Bruno Haible  <bruno@clisp.org>
35393         Fix compilation error on native Windows (regression from 2020-05-28).
35394         Reported by Daiki Ueno.
35395         * lib/gettimeofday.c (GetSystemTimePreciseAsFileTimeFunc): Define as
35396         macro when not using dynamic loading.
35397         * lib/isatty.c (GetNamedPipeClientProcessIdFunc,
35398         QueryFullProcessImageNameFunc): Likewise.
35399         * lib/stat-w32.c (GetFileInformationByHandleExFunc,
35400         GetFinalPathNameByHandleFunc): Likewise.
35402 2020-05-29  Daiki Ueno  <ueno@gnu.org>
35404         fopen-gnu-tests: fix "\x" escape usage
35405         * tests/test-fopen-gnu.c (DATA): Use safer escape sequence.
35407 2020-05-28  Bruno Haible  <bruno@clisp.org>
35409         Avoid dynamic loading of Windows API functions when possible.
35410         Reported by Steve Lhomme <robux4@ycbcr.xyz> in
35411         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00182.html>.
35412         * lib/gettimeofday.c (GetProcAddress,
35413         GetSystemTimePreciseAsFileTimeFuncType,
35414         GetSystemTimePreciseAsFileTimeFunc, initialized, initialize): Don't
35415         define in a build for Windows 8 or higher.
35416         * lib/isatty.c (GetProcAddress, GetNamedPipeClientProcessIdFuncType,
35417         GetNamedPipeClientProcessIdFunc, QueryFullProcessImageNameFuncType,
35418         QueryFullProcessImageNameFunc, initialized, initialize): Don't define
35419         in a build for Windows Vista or higher.
35420         * lib/stat-w32.c (GetProcAddress, GetFileInformationByHandleExFuncType,
35421         GetFileInformationByHandleExFunc, GetFinalPathNameByHandleFuncType,
35422         GetFinalPathNameByHandleFunc, initialized, initialize): Likewise.
35424 2020-05-28  Paul Eggert  <eggert@cs.ucla.edu>
35426         explicit_bzero-tests: improve -Wmissing-declarations pacification
35427         * tests/test-explicit_bzero.c: Now noinline.
35428         Suggested by Bruno Haible in:
35429         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00300.html
35431 2020-05-28  Bruno Haible  <bruno@clisp.org>
35433         Fix build errors due to read-file changes (regression from 2020-05-27).
35434         * lib/git-merge-changelog.c (read_changelog_file): Update read_file
35435         invocation.
35436         * tests/test-sameacls.c (main): Likewise.
35437         * tests/test-pipe-filter-gi1.c (main): Call read_file instead of
35438         read_binary_file.
35439         * tests/test-pipe-filter-ii1.c (main): Likewise.
35441 2020-05-28  Bruno Haible  <bruno@clisp.org>
35443         fts: Make more robust in multithreaded applications.
35444         * lib/fts.c (fts_open): Pass an O_CLOEXEC flag to open().
35445         * modules/fts (Depends-on): Add 'open'.
35447 2020-05-28  Bruno Haible  <bruno@clisp.org>
35449         relocatable-prog: Make more robust in multithreaded applications.
35450         * lib/progreloc.c (O_CLOEXEC): Define fallback to 0 when use from module
35451         relocatable-prog-wrapper.
35452         (find_executable): Pass an O_CLOEXEC flag to open().
35453         * modules/relocatable-prog (Depends-on): Add 'open'.
35455 2020-05-28  Bruno Haible  <bruno@clisp.org>
35457         getloadavg: Make more robust in multithreaded applications.
35458         * lib/getloadavg.c (getloadavg): Pass an O_CLOEXEC flag to open().
35459         Simplify use of O_CLOEXEC.
35460         * modules/getloadavg (Depends-on): Add 'open'.
35462 2020-05-28  Bruno Haible  <bruno@clisp.org>
35464         vma-iter: Make more robust in multithreaded applications.
35465         * lib/vma-iter.c (rof_open, vma_iterate): Pass an O_CLOEXEC flag to
35466         open().
35467         * modules/vma-iter (Depends-on): Add 'open'.
35469 2020-05-28  Bruno Haible  <bruno@clisp.org>
35471         truncate: Make more robust in multithreaded applications.
35472         * lib/truncate.c (truncate): Pass an O_CLOEXEC flag to open().
35474 2020-05-28  Bruno Haible  <bruno@clisp.org>
35476         pagealign_alloc: Make more robust in multithreaded applications.
35477         * lib/pagealign_alloc.c (pagealign_alloc): Pass an O_CLOEXEC flag to
35478         open().
35479         * modules/pagealign_alloc (Depends-on): Add 'open'.
35481 2020-05-28  Bruno Haible  <bruno@clisp.org>
35483         openat: Make more robust in multithreaded applications.
35484         * lib/openat.c (openat_needs_fchdir): Pass an O_CLOEXEC flag to open().
35486 2020-05-28  Bruno Haible  <bruno@clisp.org>
35488         at-internal: Make more robust in multithreaded applications.
35489         * lib/openat-proc.c (openat_proc_name): Pass an O_CLOEXEC flag to
35490         open().
35492 2020-05-28  Bruno Haible  <bruno@clisp.org>
35494         mountlist: Make more robust in multithreaded applications.
35495         * lib/mountlist.c (read_file_system_list): Pass an O_CLOEXEC flag to
35496         open().
35497         * modules/mountlist (Depends-on): Add 'open'.
35499 2020-05-28  Bruno Haible  <bruno@clisp.org>
35501         login_tty: Make more robust in multithreaded applications.
35502         * lib/login_tty.c (login_tty): Pass an O_CLOEXEC flag to open().
35503         * modules/login_tty (Depends-on): Add 'open'.
35505 2020-05-28  Bruno Haible  <bruno@clisp.org>
35507         javacomp: Make more robust in multithreaded applications.
35508         * lib/javacomp.c (get_classfile_version): Pass an O_CLOEXEC flag to
35509         open().
35510         * modules/javacomp (Depends-on): Add 'open'.
35512 2020-05-28  Bruno Haible  <bruno@clisp.org>
35514         getprogname: Make more robust in multithreaded applications.
35515         * lib/getprogname.c (getprogname): Pass an O_CLOEXEC flag to open().
35516         * modules/getprogname (Depends-on): Add 'open'.
35518 2020-05-28  Bruno Haible  <bruno@clisp.org>
35520         get_progname_of: Make more robust in multithreaded applications.
35521         * lib/get_progname_of.c (get_progname_of): Pass an O_CLOEXEC flag to
35522         open().
35523         * modules/get_progname_of (Depends-on): Add 'open'.
35525 2020-05-28  Bruno Haible  <bruno@clisp.org>
35527         get_ppid_of: Make more robust in multithreaded applications.
35528         * lib/get_ppid_of.c (get_ppid_of): Pass an O_CLOEXEC flag to open().
35529         * modules/get_ppid_of (Depends-on): Add 'open'.
35531 2020-05-28  Bruno Haible  <bruno@clisp.org>
35533         get-rusage-as: Make more robust in multithreaded applications.
35534         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit): Pass an O_CLOEXEC
35535         flag to open().
35536         * modules/get-rusage-as (Depends-on): Add 'open'.
35538 2020-05-28  Bruno Haible  <bruno@clisp.org>
35540         crypto/gc: Make more robust in multithreaded applications.
35541         * lib/gc-gnulib.c (randomize): Pass an O_CLOEXEC flag to open().
35542         * modules/crypto/gc (Depends-on): Add 'open'.
35544 2020-05-28  Bruno Haible  <bruno@clisp.org>
35546         copy-file: Make more robust in multithreaded applications.
35547         * lib/copy-file.c (qcopy_file_preserving): Pass an O_CLOEXEC flag to
35548         open().
35550 2020-05-28  Bruno Haible  <bruno@clisp.org>
35552         chown: Make more robust in multithreaded applications.
35553         * lib/chown.c (rpl_chown): Pass an O_CLOEXEC flag to open().
35555 2020-05-28  Bruno Haible  <bruno@clisp.org>
35557         doc: Fix statement about O_CLOEXEC (wrong since 2017-08-14).
35558         * doc/posix-headers/fcntl.texi: Gnulib no longer defines O_CLOEXEC to 0.
35560 2020-05-28  Daiki Ueno  <ueno@gnu.org>
35562         fopen-gnu: make 'b' flag can be used with 'e' on Windows
35563         * lib/fopen.c (rpl_fopen): Pass O_BINARY to open, if a 'b' flag is
35564         specified on Windows.
35565         * tests/test-fopen-gnu.c (DATA): New define.
35566         (main): Add test for reading binary files with an 'e' flag.
35568 2020-05-27  Bruno Haible  <bruno@clisp.org>
35570         Don't assume that UNICODE is not defined.
35571         Some Windows types, such as TCHAR, LPTSTR, LPCTSTR, are defined
35572         differently if the application defines the macro UNICODE.
35573         Reported by Steve Lhomme <robux4@ycbcr.xyz> in
35574         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00184.html>.
35575         * lib/link.c (CreateHardLinkFuncType): Use LPCSTR, not LPCTSTR.
35576         * lib/localename.c (enum_locales_fn): Use LPSTR, not LPTSTR.
35577         * lib/stat-w32.c (GetFinalPathNameByHandleFuncType): Likewise.
35579 2020-05-27  Bruno Haible  <bruno@clisp.org>
35581         Improve pattern for defining _WIN32_WINNT.
35582         Newer versions of the Windows API may not only add, but also remove API
35583         functions. Therefore, when the user is e.g. building for Windows 10, we
35584         should not set _WIN32_WINNT to e.g. Windows 8, as this may enable the
35585         use of APIs that were present in Windows 8 but removed in Windows 10.
35586         Suggested by Steve Lhomme <robux4@ycbcr.xyz> in
35587         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00318.html>.
35588         * lib/ftruncate.c (_WIN32_WINNT): Don't set to a smaller value.
35589         * lib/sethostname.c (_WIN32_WINNT): Likewise.
35590         * lib/stat-w32.c (_WIN32_WINNT): Likewise.
35592 2020-05-27  Bruno Haible  <bruno@clisp.org>
35594         javacomp: Make more robust in multithreaded applications.
35595         * lib/javacomp.c (write_temp_file): Pass an 'e' flag to fopen_temp.
35596         * modules/javacomp (Depends-on): Add fopen-gnu.
35598 2020-05-27  Bruno Haible  <bruno@clisp.org>
35600         mountlist: Make more robust in multithreaded applications.
35601         * lib/mountlist.c (setmntent, read_file_system_list): Pass an 'e' flag
35602         to fopen.
35603         * modules/mountlist (Depends-on): Add fopen-gnu.
35605 2020-05-27  Bruno Haible  <bruno@clisp.org>
35607         sethostname: Make more robust in multithreaded applications.
35608         * lib/sethostname.c (sethostname): Pass an 'e' flag to fopen.
35609         * modules/sethostname (Depends-on): Add fopen-gnu.
35611 2020-05-27  Bruno Haible  <bruno@clisp.org>
35613         readutmp: Make more robust in multithreaded applications.
35614         * lib/readutmp.c (read_utmp): Pass an 'e' flag to fopen.
35615         * modules/readutmp (Depends-on): Add fopen-gnu.
35617 2020-05-27  Bruno Haible  <bruno@clisp.org>
35619         getpass: Make more robust in multithreaded applications.
35620         * lib/getpass.c (getpass): Pass an 'e' flag to fopen.
35621         * modules/getpass (Depends-on): Add fopen-gnu.
35623 2020-05-27  Bruno Haible  <bruno@clisp.org>
35625         getloadavg: Make more robust in multithreaded applications.
35626         * lib/getloadavg.c (getloadavg): Pass an 'e' flag to fopen.
35627         * modules/getloadavg (Depends-on): Add fopen-gnu.
35629 2020-05-27  Bruno Haible  <bruno@clisp.org>
35631         exclude: Make more robust in multithreaded applications.
35632         * lib/exclude.c (add_exclude_file): Pass an 'e' flag to fopen.
35633         * modules/exclude (Depends-on): Add fopen-gnu.
35635 2020-05-27  Bruno Haible  <bruno@clisp.org>
35637         bitset: Make more robust in multithreaded applications.
35638         * lib/bitset/stats.c (bitset_stats_read, bitset_stats_write): Pass an
35639         'e' flag to fopen.
35640         * modules/bitset (Depends-on): Add fopen-gnu.
35642 2020-05-27  Daiki Ueno  <ueno@gnu.org>
35644         read-file: add RF_SENSITIVE flag
35645         * lib/read-file.h (RF_SENSITIVE): New define.
35646         * lib/read-file.c (fread_file, read_file): Take into account of
35647         RF_SENSITIVE flag.
35648         * modules/read-file (Depends-on): Add explicit_bzero.
35649         This adds an alternative behavior of those functions to explicitly
35650         clear the internal memory block when it becomes unused.  This is
35651         useful for reading sensitive information from a file.
35653 2020-05-27  Daiki Ueno  <ueno@gnu.org>
35655         read-file: add flags to modify reading behavior
35656         * lib/read-file.h (RF_BINARY): New define.
35657         (fread_file, read_file): Take FLAGS argument.
35658         (read_binary_file): Remove.
35659         * lib/read-file.c (internal_read_file): Merge into ...
35660         (read_file): ... here.
35661         * modules/read-file-tests (Files): Add "tests/macros.h".
35662         * tests/test-read-file.c (main): Refactor using ASSERT macro.
35663         * NEWS: Mention this change.
35665 2020-05-26  Bernhard Voelker  <mail@bernhard-voelker.de>
35667         doc/gnulib-intro.texi: add missing "to" in sentence
35668         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
35669         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00316.html>.
35670         * doc/gnulib-intro.texi (Collaborative Development): Add "to".
35672 2020-05-26  Bruno Haible  <bruno@clisp.org>
35674         count-one-bits: Fix MSVC specific code.
35675         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
35676         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00309.html>.
35677         * lib/count-one-bits.h (COUNT_ONE_BITS_GENERIC): Don't define if we're
35678         using GCC.
35679         [_MSC_VER]: Use correct syntax for #pragma intrinsic.
35680         (__popcnt64): In 32-bit mode, define as an inline function.
35681         (COUNT_ONE_BITS): Rename first argument to GCC_BUILTIN.
35683 2020-05-26  Bruno Haible  <bruno@clisp.org>
35685         argz: Avoid name clashes through argz.h.
35686         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
35687         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00308.html>.
35688         * lib/argz.h: Don't use __ prefixed identifiers.
35689         (const): Remove definition.
35690         (argz_next): Remove inline definitions.
35692 2020-05-26  Daiki Ueno  <ueno@gnu.org>
35694         read-file: make use of fopen-gnu
35695         * lib/read-file.c (read_file): Pass an 'e' flag to fopen.
35696         (read_binary_file): Likewise.
35697         * modules/read-file (Depends-on): Add fopen-gnu.
35699 2020-05-25  Paul Eggert  <eggert@cs.ucla.edu>
35701         getentropy, getrandom: new modules
35702         * MODULES.html.sh (func_all_modules):
35703         * lib/unistd.in.h (getentropy, getrandom):
35704         * m4/unistd_h.m4 (gl_UNISTD_H, gl_UNISTD_H_DEFAULTS):
35705         * modules/unistd (unistd.h):
35706         Add support for getentropy, getrandom.
35707         * doc/glibc-functions/getentropy.texi (getentropy):
35708         * doc/glibc-functions/getrandom.texi (getrandom):
35709         These are now fixed on some platforms.
35710         * lib/getentropy.c, lib/getrandom.c, lib/sys_random.in.h:
35711         * m4/getentropy.m4, m4/getrandom.m4:
35712         * modules/getentropy, modules/getentropy-tests:
35713         * modules/getrandom, modules/getrandom-tests:
35714         * tests/test-getentropy.c, tests/test-getrandom.c:
35715         New files.
35717 2020-05-25  Bruno Haible  <bruno@clisp.org>
35719         Add missing C99 dependencies.
35720         Reported by Paul Smith <psmith@gnu.org> in
35721         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00290.html>.
35722         * modules/assert (Depends-on): Add c99.
35723         * modules/filenamecat-lgpl (Depends-on): Likewise.
35724         * modules/libc-config (Depends-on): Likewise.
35725         * modules/mktime (Depends-on): Likewise.
35726         * modules/random_r (Depends-on): Likewise.
35727         * modules/regex (Depends-on): Likewise.
35728         * modules/scratch_buffer (Depends-on): Likewise.
35729         * modules/timespec-add (Depends-on): Likewise.
35730         * modules/timespec-sub (Depends-on): Likewise.
35731         * modules/verify (Depends-on): Likewise.
35733 2020-05-24  Paul Eggert  <eggert@cs.ucla.edu>
35735         explicit_bzero-tests: pacify -Wmissing-declarations
35736         * tests/test-explicit_bzero.c (do_secret_stuff, test_stack):
35737         Now static.
35739 2020-05-24  Bruno Haible  <bruno@clisp.org>
35741         fopen-gnu: Add tests.
35742         * tests/test-fopen-gnu.c: New file.
35743         * modules/fopen-gnu-tests: New file.
35745         fopen-gnu: New module.
35746         Suggested by Tim Rühsen <tim.ruehsen@gmx.de> in
35747         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00119.html>.
35748         * lib/fopen.c (rpl_fopen): When the fopen-gnu module is enabled and the
35749         mode contains an 'x' or 'e' flag, use open() followed by fdopen().
35750         * m4/fopen.m4 (gl_FUNC_FOPEN_GNU): New macro.
35751         * modules/fopen-gnu: New file.
35752         * doc/posix-functions/fopen.texi: Document the 'fopen-gnu' module.
35754 2020-05-24  Bruno Haible  <bruno@clisp.org>
35756         open, openat: Really support O_CLOEXEC.
35757         * lib/open.c (open): When have_cloexec is still undecided, do pass a
35758         O_CLOEXEC flag to orig_open.
35759         * lib/openat.c (rpl_openat): When have_cloexec is still undecided, do
35760         pass a O_CLOEXEC flag to orig_openat.
35761         * tests/test-open.h (test_open): Verify that O_CLOEXEC is honoured.
35762         * modules/open-tests (Depends-on): Add fcntl.
35763         * modules/openat-tests (Depends-on): Likewise.
35764         * modules/fcntl-safer-tests (Depends-on): Likewise.
35766 2020-05-24  Bruno Haible  <bruno@clisp.org>
35768         fopen: Fix the trailing slash workaround.
35769         * lib/fopen.c (rpl_fopen): Parse the mode string. Recognize "r+" as a
35770         write access. Pass the right flags to open().
35771         * tests/test-fopen.h (test_fopen): Add a few more tests on directories.
35773 2020-05-23  Paul Eggert  <eggert@cs.ucla.edu>
35775         assure: new macro ‘affirm’
35776         * lib/assure.h: Include verify.h.
35777         (affirm): New macro, after a suggestion by Marc Nieper-Wißkirchen in:
35778         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00263.html
35779         and commentary by Bruno Haible in:
35780         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00278.html
35781         * modules/assure (Depends-on:): Add verify.
35783 2020-05-23  Bruno Haible  <bruno@clisp.org>
35785         calloc-gnu: Make test work in non-flat address spaces.
35786         Uses code by Paul Eggert.
35787         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Allow a calloc() implementation
35788         to return more than SIZE_MAX bytes, but only without wrap-around bugs.
35790 2020-05-23  Bruno Haible  <bruno@clisp.org>
35792         calloc-gnu: Avoid wrong configure results with GCC's AddressSanitizer.
35793         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Split the AC_RUN_IFELSE into two
35794         AC_RUN_IFELSE invocations.
35796 2020-05-23  Bruno Haible  <bruno@clisp.org>
35798         isnanf, isnanl, isnan: Don't use nonexistent builtins with clang.
35799         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_HAVE_ISNANF_IN_LIBM,
35800         gl_ISNANF_WORKS): Don't use __builtin_isnanf on clang versions that
35801         don't have it.
35802         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM,
35803         gl_FUNC_ISNANL_WORKS): Don't use __builtin_isnanl on clang versions that
35804         don't have it.
35805         * lib/isnanf-nolibm.h (__has_builtin): New macro.
35806         (isnanf): Don't use __builtin_isnanf on clang versions that don't have
35807         it.
35808         * lib/isnanl-nolibm.h (__has_builtin): New macro.
35809         (isnanl): Don't use __builtin_isnanl on clang versions that don't have
35810         it.
35811         * lib/math.in.h (__has_builtin): New macro.
35812         (isnanf): Don't use __builtin_isnanf on clang versions that don't have
35813         it.
35814         (isnanl): Don't use __builtin_isnanl on clang versions that don't have
35815         it.
35816         (isnan): Don't use the builtins on clang versions that don't have
35817         __builtin_isnanf and __builtin_isnanl.
35819 2020-05-23  Bruno Haible  <bruno@clisp.org>
35821         calloc-gnu: Avoid wrong configure results with clang.
35822         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Mark the pointer variable as
35823         'volatile', to defeat compiler optimizations.
35825 2020-05-23  Bruno Haible  <bruno@clisp.org>
35827         isnanl, isnanl-nolibm: Make a test work better with "gcc -O2" on x86_64.
35828         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Pass the
35829         'long double' values by reference, with values taken from a statically
35830         allocated array.
35832 2020-05-23  Bruno Haible  <bruno@clisp.org>
35834         findprog-in: Ignore directories.
35835         Reported by Frederick Eaton via Dmitry Goncharov in
35836         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00003.html>.
35837         * lib/findprog-in.c (find_in_given_path): When the file found is a
35838         directory, set errno to EACCES and, during a PATH search, continue
35839         searching.
35840         * modules/findprog-in (Depends-on): Add sys_stat, stat.
35842 2020-05-23  Paul Eggert  <eggert@cs.ucla.edu>
35844         verify: document ‘assume’ better
35845         * lib/verify.h (assume): Say it’s for static analysis, not dynamic.
35847 2020-05-22  Asher Gordon  <AsDaGo@posteo.net>
35849         gendocs: Clarify licenses for templates.
35850         * doc/gendocs_template: Add a GNU All-Permissive license notice
35851         and bump Parent-Version.
35852         * doc/gendocs_template_min: Add a GNU All-Permissive license
35853         notice and copy the explanatory comment about the license notice
35854         at the bottom from gendocs_template.
35856 2020-05-21  Bruno Haible  <bruno@clisp.org>
35858         group-member: Relicense under LGPLv2+.
35859         Jim Meyering's approval is in
35860         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00218.html>.
35861         Paul Eggert's approval is in
35862         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00225.html>.
35863         Eric Blake's approval is in
35864         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00217.html>.
35865         * modules/group-member (License): Change to LGPLv2+.
35867 2020-05-21  Bruno Haible  <bruno@clisp.org>
35869         memmem: Avoid wrong configure results with "clang -fsanitize=undefined".
35870         Reported by Tim Rühsen in
35871         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
35872         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Use NULL + 1, not NULL.
35874 2020-05-21  Bruno Haible  <bruno@clisp.org>
35876         regex: Avoid wrong configure results with "clang -fsanitize=leak".
35877         Reported by Tim Rühsen in
35878         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
35879         * m4/regex.m4 (gl_REGEX): Free compiled regexes and allocated registers
35880         before returning with status 0.
35882 2020-05-21  Bruno Haible  <bruno@clisp.org>
35884         glob: Avoid wrong configure results with "clang -fsanitize=leak".
35885         Reported by Tim Rühsen in
35886         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
35887         * m4/glob.m4 (gl_GLOB): Free allocated memory before returning.
35889 2020-05-21  Bruno Haible  <bruno@clisp.org>
35891         fchownat: Support clang -fsanitize=implicit-integer-sign-change better.
35892         Reported by Tim Rühsen in
35893         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00207.html>.
35894         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG,
35895         gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Cast -1 to uid_t or git_t,
35896         respectively.
35898 2020-05-18  Tim Rühsen  <tim.ruehsenqgmx.de>
35900         getdelim: Avoid wrong configure results with gcc -fsanitize=address.
35901         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Fix memleak.
35903 2020-05-19  Paul Eggert  <eggert@cs.ucla.edu>
35905         ftoastr: fix ifndef typo
35906         * lib/ftoastr.h (_GL_FTOASTR_H): Define.
35908 2020-05-19  Bruno Haible  <bruno@clisp.org>
35910         havelib: Tweak documentation.
35911         * doc/havelib.texi (Searching for Libraries): Fix typo.
35913 2020-05-18  Siddhesh Poyarekar  <siddhesh@gotplt.org>
35915         vcs-to-changelog: Rename vcs_to_changelog.py to use hyphens.
35916         This was needed earlier because modules had to import the main script,
35917         but that is no longer true.  Rename the script so that it is
35918         consistent with all other scripts in gnulib and uses hyphens.
35919         * build-aux/vcs_to_changelog.py: Rename to...
35920         * build-aux/vcs-to-changelog.py: ... this.
35921         * doc/vcs-to-changelog.texi (VCS To ChangeLog): Update reference.
35922         * modules/vcs-to-changelog: Likewise.
35924 2020-05-17  Bruno Haible  <bruno@clisp.org>
35926         Clarify intended usage of the license file modules.
35927         Reported by Asher Gordon <AsDaGo@posteo.net> in
35928         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00126.html>.
35929         * doc/licenses-texi.texi (License Texinfo sources): Mention the
35930         GNU AGPL. Explain the intended usage of the modules.
35931         * modules/fdl (Notice): Discourage use as a module.
35932         * modules/fdl-1.3 (Notice): Likewise.
35934 2020-05-17  Akim Demaille  <akim@lrde.epita.fr>
35936         hash: add hash_xinsert
35937         * lib/hash.h, lib/xhash.c (hash_xinsert): New.
35939 2020-05-16  Bruno Haible  <bruno@clisp.org>
35941         findprog-lgpl: Fix link error (existing since 2008-09-02).
35942         * modules/findprog-lgpl (Makefile.am): Arrange to compile
35943         findprog-lgpl.c, not findprog.c.
35944         * lib/findprog.c (find_in_path): Add LGPLed replacement code for
35945         XNMALLOC.
35947 2020-05-15  Paul Eggert  <eggert@cs.ucla.edu>
35949         c-stack: pacify -Wunused-result when DEBUG
35950         Problem reported by Marc Nieper-Wißkirchen in:
35951         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00132.html
35952         * lib/c-stack.c (segv_handler, overflow_handler, segv_handler) [DEBUG]:
35953         Explicitly ignore write failures.
35955 2020-05-13  Jim Meyering  <meyering@fb.com>
35957         announce-gen: improve a comment
35958         * build-aux/announce-gen: Improve comment.
35960 2020-05-12  Paul Eggert  <eggert@cs.ucla.edu>
35962         xalloc: pacify -Wanalyzer-possible-null-argument
35963         Problem reported for GCC 10.1.0 by Bruno Haible in:
35964         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00118.html
35965         * lib/xmalloc.c (HAVE_GNU_MALLOC, HAVE_GNU_REALLOC): New constants.
35966         (xmalloc): Suppress unnecessary check if HAVE_GNU_MALLOC.
35967         (xrealloc): Suppress unnecssary check if HAVE_GNU_REALLOC.
35969 2020-05-11  Paul Eggert  <eggert@cs.ucla.edu>
35971         careadlinkat: fix GCC 10 workaround
35972         * lib/careadlinkat.c (careadlinkat) [GCC_LINT]:
35973         Massage the code so that it’s closer to what it was before
35974         the GCC 10.1.0 workaround was introduced.  This fixes
35975         a loop when !buffer and the bug workaround is in effect.
35976         Remove unnecessary casts.  Defend in a different way
35977         against (buffer && !buffer_size), by adding at least 1
35978         to buf_size each time through the loop.
35980 2020-05-10  Bruno Haible  <bruno@clisp.org>
35982         doc: Mark HP-UX as unsupported.
35983         * doc/gnulib-intro.texi (Target Platforms): List HP-UX as unsupported.
35985 2020-05-10  Paul Eggert  <eggert@cs.ucla.edu>
35987         careadlinkat: limit GCC workaround
35988         * lib/careadlinkat.c (careadlinkat): Limit workaround to GCC
35989         10.1.0 and later, since the workaround is pretty bad and the GCC
35990         bug should get fixed.
35992 2020-05-10  Bruno Haible  <bruno@clisp.org>
35994         havelib: Enhance documentation.
35995         * doc/havelib.texi (Searching for Libraries): Mention the bad
35996         consequences of using LIBxxx instead of LTLIBxxx and vice versa.
35998 2020-05-10  Bruno Haible  <bruno@clisp.org>
36000         attribute: Clarify list of attributes.
36001         * lib/attribute.h: Reorder the list of attributes, and group them by
36002         purpose.
36004 2020-05-10  Bruno Haible  <bruno@clisp.org>
36006         string: Fix compilation error in C++ mode.
36007         * lib/warn-on-use.h (_GL_WARN_ON_USE_CXX): In C mode, use plain
36008         _GL_WARN_ON_USE.
36009         * lib/string.in.h (strchr, strpbrk, strrchr): Use _GL_WARN_ON_USE_CXX
36010         instead of _GL_WARN_ON_USE.
36012 2020-05-10  Akim Demaille  <akim@lrde.epita.fr>
36014         announce-gen: add support for dist-lzip
36015         * build-aux/announce-gen (@archive_suffixes): Add tar.lz.
36017 2020-05-09  Paul Eggert  <eggert@cs.ucla.edu>
36019         manywarnings: port to GCC 10.1
36020         * build-aux/gcc-warning.spec:
36021         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C)):
36022         Add GCC 10.1.0 warnings.
36024         careadlinkat: pacify -Wreturn-local-addr
36025         * lib/careadlinkat.c (careadlinkat) [GCC_LINT]:
36026         Pacify gcc 10’s -Wreturn-local-addr option.
36027         Simplify some of the later code.
36029 2020-05-09  Paul Eggert  <eggert@cs.ucla.edu>
36031         attribute: remove ATTRIBUTE_DEPRECATED
36032         * lib/attribute.h: Improve recently-added comments, mostly
36033         by shortening them (use active voice, etc.).
36034         (ATTRIBUTE_DEPRECATED): Remove, as it duplicates DEPRECATED.
36035         Problem reported by Bruno Haible in:
36036         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00089.html
36038 2020-05-09  Bruno Haible  <bruno@clisp.org>
36040         attribute: Add comments.
36041         * lib/attribute.h: Document each macro.
36043 2020-05-09  Akim Demaille  <akim@lrde.epita.fr>
36045         bitset: use the attribute module
36046         * modules/bitset: Depend on 'attribute'.
36047         * lib/bitset/base.h (ATTRIBUTE_UNUSED): Remove.
36048         * lib/bitset.c, lib/bitset/array.c, lib/bitset/list.c,
36049         * lib/bitset/stats.c, lib/bitset/table.c, lib/bitset/vector.c:
36050         Use MAYBE_UNUSED instead of ATTRIBUTE_UNUSED.
36052 2020-05-09  Bruno Haible  <bruno@clisp.org>
36054         c-stack: Fix warning when DEBUG is enabled.
36055         Patch suggested by Marc Nieper-Wißkirchen <marc.nieper+gnu@gmail.com> in
36056         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00081.html>.
36057         * lib/c-stack.c: Include <stdio.h>.
36059 2020-05-09  Bruno Haible  <bruno@clisp.org>
36061         Remove redundant definitions of _GL_ATTRIBUTE_FORMAT.
36062         * lib/argp.h (_GL_ATTRIBUTE_FORMAT): Remove macro.
36063         * lib/argp-fmtstream.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36064         * lib/c-snprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36065         * lib/c-vasnprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36066         * lib/c-vasprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36067         * lib/c-vsnprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36068         * lib/c-xvasprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36069         * lib/error.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36070         * lib/parse-datetime.y (_GL_ATTRIBUTE_FORMAT): Likewise.
36071         * lib/vasnprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36072         * lib/xprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36073         * lib/xvasprintf.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36075 2020-05-09  Bruno Haible  <bruno@clisp.org>
36077         Remove redundant definitions of _GL_ATTRIBUTE_ALLOC_SIZE.
36078         Reported by Akim Demaille in
36079         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00077.html>.
36080         * lib/eealloc.h (_GL_ATTRIBUTE_ALLOC_SIZE): Remove macro.
36081         * lib/pagealign_alloc.h (_GL_ATTRIBUTE_ALLOC_SIZE): Likewise.
36082         * lib/xalloc.h (_GL_ATTRIBUTE_ALLOC_SIZE): Likewise.
36084 2020-05-09  Bruno Haible  <bruno@clisp.org>
36086         stdio, monetary: Don't redefine _GL_ATTRIBUTE_FORMAT.
36087         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT): Don't override the definition
36088         that usually comes from m4/gnulib-common.m4.
36089         * lib/monetary.in.h (_GL_ATTRIBUTE_FORMAT): Likewise.
36091 2020-05-09  Bruno Haible  <bruno@clisp.org>
36093         dirent, stdlib, wchar, string: Don't redefine _GL_ATTRIBUTE_PURE.
36094         * lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Don't override the definition
36095         that usually comes from m4/gnulib-common.m4.
36096         * lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Likewise.
36097         * lib/string.in.h (_GL_ATTRIBUTE_PURE): Likewise.
36098         * lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Likewise.
36100 2020-05-09  Bruno Haible  <bruno@clisp.org>
36102         uchar: Work around incorrect char16_t, char32_t types on Haiku 2020.
36103         * lib/uchar.in.h (char16_t): Define as macro if
36104         GNULIB_OVERRIDES_CHAR16_T.
36105         (char32_t): Define as macro if GNULIB_OVERRIDES_CHAR32_T.
36106         * m4/uchar.m4 (gl_TYPE_CHAR16_T, gl_TYPE_CHAR32_T): New macros.
36107         (gl_UCHAR_H): Invoke them.
36108         (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_OVERRIDES_CHAR16_T,
36109         GNULIB_OVERRIDES_CHAR32_T.
36110         * m4/mbrtoc32.m4 (gl_FUNC_MBRTOC32, gl_MBRTOC32_SANITYCHECK): Require
36111         gl_TYPE_CHAR32_T and test GNULIB_OVERRIDES_CHAR32_T.
36112         * modules/uchar (Makefile.am): Substitute GNULIB_OVERRIDES_CHAR16_T,
36113         GNULIB_OVERRIDES_CHAR32_T.
36115 2020-05-09  Bruno Haible  <bruno@clisp.org>
36117         Macro tweaks.
36118         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Correct config.h comment.
36119         * m4/wint_t.m4 (gt_TYPE_WINT_T): Correct indentation.
36121 2020-05-08  Bruno Haible  <bruno@clisp.org>
36123         c32rtomb: Avoid compilation failure on Haiku.
36124         * m4/c32rtomb.m4 (gl_FUNC_C32RTOMB): Test for c32rtomb without excluding
36125         inline definitions.
36126         * doc/posix-functions/c32rtomb.texi: Mention the Haiku problem.
36128 2020-05-08  Bruno Haible  <bruno@clisp.org>
36130         mbrtoc32: Avoid compilation failure on Haiku.
36131         * m4/mbrtoc32.m4 (gl_CHECK_FUNC_MBRTOC32): New macro.
36132         (gl_FUNC_MBRTOC32, gl_MBRTOC32_SANITYCHECK): Use it instead of
36133         AC_CHECK_FUNCS_ONCE.
36134         * doc/posix-functions/mbrtoc32.texi: Mention the Haiku problem.
36136 2020-05-08  Bruno Haible  <bruno@clisp.org>
36138         limits-h: Define LONG_BIT correctly on Haiku/x86_64.
36139         * lib/limits.in.h: Define and test _GL_ALREADY_INCLUDING_LIMITS_H.
36141 2020-05-08  Bruno Haible  <bruno@clisp.org>
36143         list: Update documentation.
36144         Reported by Marc Nieper-Wißkirchen <marc.nieper+gnu@gmail.com> in
36145         <https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00062.html>.
36146         * doc/containers.texi (Container data types): Document the new list
36147         operations and their complexity.
36149 2020-05-08  Bruno Haible  <bruno@clisp.org>
36151         ignore-value tests: Use module 'attribute'.
36152         * m4/gnulib-common.m4 (gl_COMMON_BODY): Fix a typo.
36153         * tests/test-ignore-value.c: Include attribute.h.
36154         (_GL_ATTRIBUTE_RETURN_CHECK): Remove macro. Use NODISCARD instead.
36155         * modules/ignore-value-tests (Depends-on): Add attribute.
36157 2020-05-08  Bruno Haible  <bruno@clisp.org>
36159         uniname/uniname: Use module 'attribute'.
36160         * lib/uniname/gen-uninames.lisp: Emit a reference to ATTRIBUTE_PACKED.
36161         * lib/uniname/uninames.h: Regenerated.
36162         * lib/uniname/uniname.c: Include attribute.h.
36163         * modules/uniname/uniname (Depends-on): Add attribute.
36165 2020-05-08  Bruno Haible  <bruno@clisp.org>
36167         c32rtomb: Use module 'attribute'.
36168         * lib/c32rtomb.c: Include attribute.h.
36169         (FALLTHROUGH): Remove macro.
36170         * modules/c32rtomb (Depends-on): Add attribute.
36172 2020-05-08  Bruno Haible  <bruno@clisp.org>
36174         xsize: Use module 'attribute'.
36175         * lib/xsize.h: Include attribute.h. Use ATTRIBUTE_PURE.
36176         * modules/xsize (Depends-on): Add attribute.
36178 2020-05-06  Paul Eggert  <eggert@cs.ucla.edu>
36180         * m4/gnulib-common.m4 (gl_COMMON_BODY): Minor style fixes.
36182         * lib/attribute.h: Minor style fixes.
36184         Fix version-etc glitch on OpenIndiana
36185         Problem reported by Mats Erik Andersson in:
36186         https://lists.gnu.org/r/bug-gnulib/2020-05/msg00067.html
36187         * lib/version-etc.h (_GL_ATTRIBUTE_SENTINEL): Remove defn
36188         that now clashes with gnulib-common.h.  All uses changed.
36190 2020-05-03  Paul Eggert  <eggert@cs.ucla.edu>
36192         attribute: new module
36193         This simplifies use of GCC and C2x attributes like ‘deprecated’.
36194         * MODULES.html.sh: Add attribute.
36195         * doc/attribute.texi, lib/attribute.h, modules/attribute: New files.
36196         * doc/gnulib.texi (Particular Modules): Add Attributes.
36197         * lib/backupfile.c, lib/fnmatch.c, lib/freopen-safer.c:
36198         * lib/mbrtoc32.c, lib/mbrtowc.c, lib/nstrftime.c, lib/quotearg.c:
36199         * lib/savewd.c, lib/unistr/u8-uctomb-aux.c, lib/unistr/u8-uctomb.c:
36200         * lib/vasnprintf.c:
36201         Include attribute.h, and let it define FALLTHROUGH.
36202         * lib/bitset/base.h, lib/c-stack.c (__attribute__): Remove macro.
36203         * lib/bitset/base.h (ATTRIBUTE_UNUSED): Define in terms of
36204         _GL_ATTRIBUTE_MAYBE_UNUSED, for forwards compatibility to C2x.
36205         * lib/dfa.c (FALLTHROUGH): Define consistently with gl_COMMON_BODY.
36206         This is a copy since Gawk doesn’t use Gnulib.
36207         * lib/di-set.h (_GL_ATTRIBUTE_NONNULL): Remove definition that
36208         is incompatible with gl_COMMON_BODY’s.  All uses changed.
36209         * lib/fts.c: Include attribte.h, for FALLTHROUGH.
36210         Keep the existing FALLTHROUGH definition since Glibc might use it,
36211         and it does no harm to Gnulib’s FALLTHROUGH.
36212         * lib/fts_.h, lib/inttostr.h:
36213         (__GNUC_PREREQ): Remove; no longer needed.
36214         (__attribute_warn_unused_result__): Remove.  All uses
36215         replaced by _GL_ATTRIBUTE_NODISCARD.
36216         * lib/gl_list.h, lib/gl_map.h, lib/gl_omap.h, lib/gl_oset.h:
36217         * lib/gl_set.h: Prefer _GL_ATTRIBUTE_NODISCARD to an ifdeffed
36218         __attribute__ ((__warn_unused_result__)), for forward
36219         compatibility to C2x.
36220         * lib/hash.h (_GL_ATTRIBUTE_WUR): Remove.  All uses replaced by
36221         _GL_ATTRIBUTE_NODISCARD.
36222         (_GL_ATTRIBUTE_DEPRECATED): Remove, since gl_COMMON_BODY defines it.
36223         * lib/ino-map.h (_GL_ATTRIBUTE_NONNULL): Remove.  All uses
36224         replaced by gl_COMMON_BODY’s implementation, which has a
36225         slightly different signature.
36226         * lib/safe-alloc.h (_GL_ATTRIBUTE_RETURN_CHECK):
36227         Remove.  All uses replaced by _GL_ATTRIBUTE_NODISCARD.
36228         * lib/unused-parameter.h (_GL_UNUSED_PARAMETER):
36229         Define in terms of _GL_ATTRIBUTE_MAYBE_UNUSED.
36230         No doubt all uses should be replaced, at some point.
36231         * m4/gnulib-common.m4 (_GL_GNUC_PREREQ): New macro.
36232         (_Noreturn): Use it.
36233         (_GL_HAS_ATTRIBUTE, _GL_ATTRIBUTE_ALLOC_SIZE)
36234         (_GL_ATTRIBUTE_ALWAYS_INLINE, _GL_ATTRIBUTE_ARTIFICIAL)
36235         (_GL_ATTRIBUTE_COLD)
36236         (_GL_ATTRIBUTE_DEPRECATED, _GL_ATTRIBUTE_ERROR)
36237         (_GL_ATTRIBUTE_WARNING, _GL_ATTRIBUTE_EXTERNALLY_VISIBLE)
36238         (_GL_ATTRIBUTE_FALLTHROUGH, _GL_ATTRIBUTE_FORMAT)
36239         (_GL_ATTRIBUTE_LEAF, _GL_ATTRIBUTE_MAY_ALIAS)
36240         (_GL_ATTRIBUTE_MAYBE_UNUSED)
36241         (_GL_ATTRIBUTE_NODISCARD, _GL_ATTRIBUTE_NOINLINE)
36242         (_GL_ATTRIBUTE_NONNULL, _GL_ATTRIBUTE_NONSTRING)
36243         (_GL_ATTRIBUTE_NOTHROW, _GL_ATTRIBUTE_PACKED, _GL_ATTRIBUTE_PURE)
36244         (_GL_ATTRIBUTE_RETURNS_NONNULL)
36245         (_GL_ATTRIBUTE_SENTINEL): New macros.
36246         * modules/backup-rename, modules/backupfile, modules/c-vasnprintf:
36247         * modules/fnmatch, modules/freopen-safer, modules/fts:
36248         * modules/mbrtoc32, modules/mbrtowc, modules/nstrftime:
36249         * modules/quotearg, modules/savewd:
36250         * modules/unistdio/u16-u16-vasnprintf:
36251         * modules/unistdio/u16-vasnprintf:
36252         * modules/unistdio/u32-u32-vasnprintf:
36253         * modules/unistdio/u32-vasnprintf:
36254         * modules/unistdio/u8-u8-vasnprintf:
36255         * modules/unistdio/u8-vasnprintf:
36256         * modules/unistdio/ulc-vasnprintf:
36257         * modules/unistr/u8-uctomb, modules/vasnprintf:
36258         (Depends-on:): Add attribute module.
36260 2020-05-03  Bruno Haible  <bruno@clisp.org>
36262         bison: Fix today's commit.
36263         * m4/bison.m4 (gl_PROG_BISON): Set ac_verc_fail to 'yes', not 'true'.
36265 2020-05-03  Bruno Haible  <bruno@clisp.org>
36267         list-c++: Add get_first, get_last, set_first, set_last operations.
36268         * lib/gl_list.hh (class gl_List): Add methods get_first, get_last,
36269         set_first, set_last.
36270         * lib/gl_list.h: Tweak comments.
36272 2020-05-03  Akim Demaille  <akim@lrde.epita.fr>
36274         bison: rely on bison's %require to check a version requirement
36275         See https://lists.gnu.org/archive/html/bug-gnulib/2020-05/msg00021.html.
36276         * m4/bison.m4 (gl_PROG_BISON): Let bison itself decide if it it recent
36277         enough of not.
36278         So far it is the only know Yacc tool that supports '%require'.
36279         Other yaccs will actually even choke on seeing the -o option after the
36280         input file name.
36281         * m4/parse-datetime.m4: Simplify gl_PROG_BISON invocation.
36283 2020-05-02  Bruno Haible  <bruno@clisp.org>
36285         list: Add get_first, get_last, set_first, set_last operations.
36286         * lib/gl_list.h (gl_list_get_first, gl_list_get_last,
36287         gl_list_nx_set_first, gl_list_nx_set_last): New functions.
36288         * lib/gl_xlist.h (gl_list_set_first, gl_list_set_last): New functions.
36290 2020-05-02  Bruno Haible  <bruno@clisp.org>
36292         list: Remove redundant code for remove_first and remove_last operations.
36293         * lib/gl_list.h (struct gl_list_implementation): Remove fields
36294         remove_first, remove_last.
36295         (gl_list_remove_first, gl_list_remove_last): Implement in a generic way.
36296         * lib/gl_array_list.c: Revert last change.
36297         * lib/gl_carray_list.c: Likewise.
36298         * lib/gl_anylinked_list2.h: Likewise.
36299         * lib/gl_linked_list.c: Likewise.
36300         * lib/gl_linkedhash_list.c: Likewise.
36301         * lib/gl_anytree_list2.h: Likewise.
36302         * lib/gl_avltree_list.c: Likewise.
36303         * lib/gl_avltreehash_list.c: Likewise.
36304         * lib/gl_rbtree_list.c: Likewise.
36305         * lib/gl_rbtreehash_list.c: Likewise.
36306         * lib/gl_sublist.c: Likewise.
36308 2020-05-02  Bruno Haible  <bruno@clisp.org>
36310         bison-i18n: Add support for cross-compilation.
36311         Reported by Hongxu Jia <hongxu.jia@windriver.com> in
36312         <https://lists.gnu.org/archive/html/bison-patches/2016-02/msg00000.html>
36313         via Akim Demaille <akim@lrde.epita.fr>.
36314         * m4/bison-i18n.m4 (BISON_I18N): Accept a configure option
36315         --with-bison-prefix=PREFIX and use it to determine BISON_LOCALEDIR.
36316         Don't use bison's --print-localedir option when cross-compiling.
36317         Also, fix an error message and a comment.
36319 2020-05-01  Bruno Haible  <bruno@clisp.org>
36321         list: Add remove_first and remove_last operations.
36322         Suggested by Marc Nieper-Wißkirchen <marc.nieper+gnu@gmail.com> in
36323         <https://lists.gnu.org/archive/html/bug-gnulib/2020-04/msg00092.html>.
36324         * lib/gl_list.h (struct gl_list_implementation): Add fields
36325         remove_first, remove_last.
36326         (gl_list_remove_first, gl_list_remove_last): New functions.
36327         * lib/gl_array_list.c (gl_array_remove_first, gl_array_remove_last): New
36328         functions, based on gl_array_remove_at.
36329         (gl_array_list_implementation): Implement the new operations.
36330         * lib/gl_carray_list.c (gl_carray_remove_first, gl_carray_remove_last):
36331         New functions, based on gl_carray_remove_at.
36332         (gl_carray_list_implementation): Implement the new operations.
36333         * lib/gl_anylinked_list2.h (gl_linked_remove_first,
36334         gl_linked_remove_last): New functions, based on gl_linked_remove_at.
36335         * lib/gl_linked_list.c (gl_linked_list_implementation): Implement the
36336         new operations.
36337         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation):
36338         Likewise.
36339         * lib/gl_anytree_list2.h (gl_tree_remove_first, gl_tree_remove_last):
36340         New functions, based on gl_tree_remove_at.
36341         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Implement the
36342         new operations.
36343         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
36344         Likewise.
36345         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Likewise.
36346         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation):
36347         Likewise.
36348         * lib/gl_sublist.c (gl_sublist_remove_first, gl_sublist_remove_last):
36349         New functions, based on gl_sublist_remove_at.
36350         (gl_sublist_list_implementation): Implement the new operations.
36351         * lib/gl_list.hh (class gl_List): Add methods remove_first,
36352         remove_last.
36353         * tests/test-array_list.c (main): Test also gl_list_remove_first and
36354         gl_list_remove_last.
36355         * tests/test-avltree_list.c (main): Likewise.
36356         * tests/test-avltreehash_list.c (main): Likewise.
36357         * tests/test-carray_list.c (main): Likewise.
36358         * tests/test-linked_list.c (main): Likewise.
36359         * tests/test-linkedhash_list.c (main): Likewise.
36360         * tests/test-rbtree_list.c (main): Likewise.
36361         * tests/test-rbtreehash_list.c (main): Likewise.
36363 2020-05-01  Bruno Haible  <bruno@clisp.org>
36365         parse-datetime: Fix a build failure with an older bison version.
36366         * modules/parse-datetime (Makefile.am): Don't do the post-processing of
36367         parse-datetime.tab.c if a suitable version of bison was not found.
36369 2020-05-01  Bruno Haible  <bruno@clisp.org>
36371         bison: New module.
36372         * m4/bison.m4 (gl_PROG_BISON): New macro, extracted from
36373         m4/parse-datetime.m4.
36374         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Invoke gl_PROG_BISON.
36375         * modules/bison: New file.
36376         * modules/parse-datetime (Files): Remove m4/bison.m4.
36377         (Depends-on): Add bison.
36379 2020-05-01  Jose E. Marchesi  <jemarch@gnu.org>
36381         Update users.txt.
36382         * users.txt: Add poke.
36384 2020-04-28  Bruno Haible  <bruno@clisp.org>
36386         posix_spawn_file_actions_addfchdir tests: Enhance test.
36387         * tests/test-posix_spawn5.c: Include findprog.h.
36388         (test): New function, extracted from main.
36389         (main): Invoke it. Also, invoke it with a program name such as
36390         "bin/pwd".
36391         * modules/posix_spawn_file_actions_addfchdir-tests (Depends-on): Add
36392         findprog.
36394 2020-04-28  Bruno Haible  <bruno@clisp.org>
36396         posix_spawn_file_actions_addchdir tests: Enhance test.
36397         * tests/test-posix_spawn4.c: Include findprog.h.
36398         (test): New function, extracted from main.
36399         (main): Invoke it. Also, invoke it with a program name such as
36400         "bin/pwd".
36401         * modules/posix_spawn_file_actions_addchdir-tests (Depends-on): Add
36402         findprog.
36404 2020-04-28  Bruno Haible  <bruno@clisp.org>
36406         posix_spawn_file_actions_destroy: Fix a crash (bug from 2019-06-10).
36407         * lib/spawn_faction_destroy.c (posix_spawn_file_actions_destroy): Don't
36408         access elements of the wrong union member.
36410 2020-04-27  Bruno Haible  <bruno@clisp.org>
36412         getdate: Remove deprecated module.
36413         * modules/getdate: Remove file.
36414         * doc/getdate.texi: Remove file.
36415         * lib/getdate.h: Remove file.
36416         * NEWS: Mention the removal.
36418 2020-04-27  Bruno Haible  <bruno@clisp.org>
36420         realloc: Remove deprecated module.
36421         * modules/realloc: Remove file.
36422         * NEWS: Mention the removal.
36424 2020-04-27  Bruno Haible  <bruno@clisp.org>
36426         calloc: Remove deprecated module.
36427         * modules/calloc: Remove file.
36428         * NEWS: Mention the removal.
36430 2020-04-27  Bruno Haible  <bruno@clisp.org>
36432         malloc: Remove deprecated module.
36433         * modules/malloc: Remove file.
36434         * NEWS: Mention the removal.
36436 2020-04-27  Bruno Haible  <bruno@clisp.org>
36438         fnmatch-posix: Remove deprecated module.
36439         * modules/fnmatch-posix: Remove file.
36440         * MODULES.html.sh (Enhancements for POSIX:2008 functions): Update.
36441         * NEWS: Mention the removal.
36443 2020-04-27  Bruno Haible  <bruno@clisp.org>
36445         pipe: Remove deprecated module.
36446         * modules/pipe: Remove file.
36447         * lib/pipe.h: Remove file.
36448         * NEWS: Mention the removal.
36450 2020-04-27  Bruno Haible  <bruno@clisp.org>
36452         getopt: Remove deprecated module.
36453         * modules/getopt: Remove file.
36454         * NEWS: Mention the removal.
36456 2020-04-27  Bruno Haible  <bruno@clisp.org>
36458         remove-dest-slash: Remove deprecated module.
36459         * modules/rename-dest-slash: Remove file.
36460         * MODULES.html.sh (Compatibility checks for POSIX:2008 functions):
36461         Update.
36462         * NEWS: Mention the removal.
36464 2020-04-27  Bruno Haible  <bruno@clisp.org>
36466         unictype/bidicategory-*: Remove deprecated modules.
36467         * modules/unictype/bidicategory-all: Remove file.
36468         * modules/unictype/bidicategory-byname: Remove file.
36469         * modules/unictype/bidicategory-name: Remove file.
36470         * modules/unictype/bidicategory-of: Remove file.
36471         * modules/unictype/bidicategory-test: Remove file.
36472         * MODULES.html.sh (Unicode string functions): Update.
36473         * NEWS: Mention the removals.
36475 2020-04-25  Paul Eggert  <eggert@cs.ucla.edu>
36477         Tune fts for FTS_LOGICAL+FTS_NOSTAT
36478         From a suggestion by Askar Safin in:
36479         https://lists.gnu.org/r/bug-gnulib/2020-04/msg00074.html
36480         * lib/fts.c (fts_build): If file types are known, optimize
36481         FTS_LOGICAL+FTS_NOSTAT for non-symlinks and non-directories the
36482         same way that we already optimize FTS_PHYSICAL+FTS_NOSTAT for
36483         non-directories.
36485 2020-04-19  Bruno Haible  <bruno@clisp.org>
36487         vasnprintf: Add support for printing wide characters using escapes.
36488         * lib/vasnprintf.c (ENABLE_WCHAR_FALLBACK): Document optional macro.
36489         (wctomb_fallback): New function.
36490         (local_wctomb): New function.
36491         (local_wcrtomb): New function or macro.
36492         (MAX_ROOM_NEEDED): Adjust estimate for %lc.
36493         (VASNPRINTF): Simplify %ls code by use of local_wcrtomb. Add code for
36494         %lc.
36496 2020-04-15  Paul Eggert  <eggert@cs.ucla.edu>
36498         fts: remove NOSTAT_LEAF_OPTIMIZATION
36499         It caused ‘find’ and ‘du’ to dump core, and it was useful
36500         only for obsolescent Linux filesystems anyway.  Problem reported in:
36501         https://lists.gnu.org/r/bug-gnulib/2020-04/msg00068.html
36502         Quite possibly there is still a serious underlying fts bug with
36503         tight-loop-check and mutating file systems, but if so this patch
36504         should cause the bug to be triggered less often.
36505         * lib/fts.c (enum leaf_optimization): Remove
36506         NOSTAT_LEAF_OPTIMIZATION, as it’s problematic.
36507         (S_MAGIC_REISERFS, S_MAGIC_XFS): Remove; no longer needed.
36508         (leaf_optimization): Remove special cases for ReiserFS and XFS.
36509         (fts_read): Remove NOSTAT_LEAF_OPTIMIZATION code.
36510         * lib/fts_.h (struct _ftsent.fts_n_dirs_remaining):
36511         Remove.  All uses removed.
36513 2020-04-13  Bastien Roucariès  <rouca@debian.org>
36515         explicit_bzero: Improve code style.
36516         * lib/explicit_bzero.c (explicit_bzero): Use '\0' instead of 0.
36518 2020-04-13  Bastien Roucariès  <rouca@debian.org>
36520         explicit_bzero: On native Windows, use SecureZeroMemory().
36521         * lib/explicit_bzero.c: Include <windows.h>.
36522         (explicit_bzero): On native Windows, use SecureZeroMemory.
36524 2020-04-13  Bastien Roucariès  <rouca@debian.org>
36526         explicit_bzero: Use memset_s() when available.
36527         * lib/explicit_bzero.c (__STDC_WANT_LIB_EXT1__): Define.
36528         (explicit_bzero): Use memset_s when available.
36529         * m4/explicit_bzero.m4 (gl_PREREQ_EXPLICIT_BZERO): Test for memset_s.
36531 2020-04-13  Bastien Roucariès  <rouca@debian.org>
36533         explicit_bzero tests: Fix test failure on OpenBSD 6.5.
36534         * tests/test-explicit_bzero.c (test_heap): Handle implementations of
36535         free() that overwrite the memory with canaries.
36537 2020-04-13  Akim Demaille  <akim@lrde.epita.fr>
36539         bootstrap: recommend git submodule update --init
36540         Reported by Bruno Haible.
36541         <https://lists.gnu.org/r/bug-gnulib/2020-03/msg00101.html>
36542         * build-aux/bootstrap: recommand "git submodule update --init"
36543         rather than "git submodule init".
36545 2020-04-12  Bruno Haible  <bruno@clisp.org>
36547         explicit_bzero: Add tests.
36548         * tests/test-explicit_bzero.c: New file.
36549         * modules/explicit_bzero-tests: New file.
36551 2020-04-11  Bruno Haible  <bruno@clisp.org>
36553         explicit_bzero: Relicense under LGPLv2+.
36554         Approved by Paul Eggert.
36555         * modules/explicit_bzero (License): Change to LGPLv2+.
36557 2020-04-10  Bruno Haible  <bruno@clisp.org>
36559         findprog, relocatable-prog: Ignore directories during PATH search.
36560         Reported by Frederick Eaton via Dmitry Goncharov in
36561         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00003.html>.
36563         * lib/findprog.c (find_in_path): When the file found in a PATH element
36564         is a directory, continue searching.
36565         * modules/findprog (Depends-on): Add sys_stat, stat.
36566         * modules/findprog-lgpl (Depends-on): Likewise.
36568         * lib/progreloc.c (maybe_executable): When the file found in a PATH
36569         element is a directory, continue searching.
36570         * lib/relocwrapper.c: Update comments.
36571         * modules/relocatable-prog-wrapper (Files): Add m4/largefile.m4.
36572         (configure.ac-early): New section.
36574 2020-04-10  Bruno Haible  <bruno@clisp.org>
36576         MODULES.html.sh: Support for reproducible builds from git-less tarballs.
36577         Reported by Bernhard M. Wiedemann <bwiedemann@suse.de> in
36578         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00061.html>.
36579         * MODULES.html.sh: In a git-less tarball, use the date of the first
36580         ChangeLog entry.
36582 2020-04-04  Bruno Haible  <bruno@clisp.org>
36584         Fix comments: The gettext library is under LGPL 2.1, not LGPL 2.0.
36585         * m4/gettext.m4: Fix comments regarding the gettext library.
36586         * m4/intl-thread-locale.m4: Likewise.
36587         * m4/intlmacosx.m4: Likewise.
36588         * m4/lcmessage.m4: Likewise.
36589         * m4/nls.m4: Likewise.
36590         * m4/po.m4: Likewise.
36591         * m4/progtest.m4: Likewise.
36593 2020-04-04  Jim Meyering  <meyering@fb.com>
36595         maint: remove a stray inter-word space in a 6x-repeated comment
36596         Induce the changes by running this:
36597           re='by  perl'; git grep -l "$re"|xargs perl -pi -e "s/$re/by perl/"
36598         * build-aux/announce-gen: Change "by  perl" to "by perl".
36599         * build-aux/gitlog-to-changelog: Likewise.
36600         * build-aux/prefix-gnulib-mk: Likewise.
36601         * build-aux/update-copyright: Likewise.
36602         * build-aux/useless-if-before-free: Likewise.
36603         * tests/test-update-copyright.sh: Likewise.
36605 2020-03-28  Bruno Haible  <bruno@clisp.org>
36607         Use module 'filename' instead of module 'dosname'.
36609         * lib/at-func.c: Include filename.h instead of dosname.h.
36610         * lib/unlinkat.c: Likewise.
36611         * modules/areadlinkat (Depends-on): Add filename. Remove dosname.
36612         * modules/areadlinkat-with-size (Depends-on): Likewise.
36613         * modules/faccessat (Depends-on): Likewise.
36614         * modules/fchmodat (Depends-on): Likewise.
36615         * modules/fchownat (Depends-on): Likewise.
36616         * modules/fstatat (Depends-on): Likewise.
36617         * modules/mkdirat (Depends-on): Likewise.
36618         * modules/mkfifoat (Depends-on): Likewise.
36619         * modules/readlinkat (Depends-on): Likewise.
36620         * modules/selinux-at (Depends-on): Likewise.
36621         * modules/symlinkat (Depends-on): Likewise.
36622         * modules/unlinkat (Depends-on): Likewise.
36623         * modules/utimensat (Depends-on): Likewise.
36625         * lib/at-func2.c: Include filename.h instead of dosname.h.
36626         * modules/linkat (Depends-on): Add filename. Remove dosname.
36627         * modules/renameatu (Depends-on): Likewise.
36629         * lib/canonicalize.c: Include filename.h instead of dosname.h.
36630         * lib/canonicalize-lgpl.c: Likewise.
36631         * modules/canonicalize (Depends-on): Add filename.
36632         * modules/canonicalize-lgpl (Depends-on): Likewise.
36634         * lib/dirname.h: Include filename.h instead of dosname.h.
36635         * modules/dirname-lgpl (Depends-on): Add filename. Remove dosname.
36637         * lib/fchdir.c: Include filename.h instead of dosname.h.
36638         * modules/fchdir (Depends-on): Add filename. Remove dosname.
36640         * lib/openat.c: Include filename.h instead of dosname.h.
36641         * modules/openat (Depends-on): Add filename. Remove dosname.
36643         * lib/rmdir.c: Include filename.h instead of dosname.h.
36644         * modules/rmdir (Depends-on): Add filename. Remove dosname.
36646         * lib/savewd.c: Include filename.h instead of dosname.h.
36647         * modules/savewd (Depends-on): Add filename. Remove dosname.
36649         * lib/unlink.c: Include filename.h instead of dosname.h.
36650         * modules/unlink (Depends-on): Add filename. Remove dosname.
36652         * modules/relocatable-prog-wrapper (Depends-on): Add filename.
36653         * lib/relocwrapper.c: Update comments.
36655         * modules/lstat (Depends-on): Remove dosname.
36657 2020-03-28  Bruno Haible  <bruno@clisp.org>
36659         dosname: Redirect to 'filename'.
36660         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
36661         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00042.html>.
36662         * lib/dosname.h: Remove all definitions. Just include filename.h.
36663         * modules/dosname (Status, Notice): Mark as deprecated.
36664         (Depends-on): Add 'filename'.
36666 2020-03-28  Bruno Haible  <bruno@clisp.org>
36668         dosname: Change IS_RELATIVE_FILE_NAME.
36669         * lib/dosname.h (IS_RELATIVE_FILE_NAME): On native Windows, OS/2, DOS,
36670         change the definition so that IS_RELATIVE_FILE_NAME("c:") is false.
36671         * NEWS: Mention the change.
36673 2020-03-28  Bruno Haible  <bruno@clisp.org>
36675         filename: Copy some definitions from module 'dosname'.
36676         * lib/filename.h: Include <string.h>, for IS_FILE_NAME_WITH_DIR.
36677         (HAS_DEVICE): Document macro.
36678         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New macro.
36679         (IS_ABSOLUTE_FILE_NAME): Consider
36680         FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE.
36681         (IS_RELATIVE_FILE_NAME, IS_FILE_NAME_WITH_DIR): New macros.
36682         (IS_ABSOLUTE_PATH, IS_PATH_WITH_DIR): Define as deprecated aliases.
36683         * lib/relocatable.c (IS_FILE_NAME_WITH_DIR): Renamed from
36684         IS_PATH_WITH_DIR.
36685         (DllMain): Update.
36686         * lib/progreloc.c (IS_FILE_NAME_WITH_DIR): Renamed from
36687         IS_PATH_WITH_DIR.
36688         (find_executable): Update.
36689         * NEWS: Document the deprecations.
36691 2020-03-25  Paul Eggert  <eggert@cs.ucla.edu>
36693         getopt-posix: port __GETOPT_PREFIX to macOS
36694         * lib/getopt-pfx-core.h (_GETOPT) [__APPLE__ && __GETOPT_PREFIX]:
36695         Define to work around a problem with asm on macOS (Bug#40205).
36697 2020-03-22  Bruno Haible  <bruno@clisp.org>
36699         MODULES.html.sh: Add support for reproducible builds.
36700         Reported by Bernhard M. Wiedemann <bwiedemann@suse.de> in
36701         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00024.html>.
36702         * MODULES.html.sh: Print the date of the last gnulib commit, not the
36703         current date.
36705 2020-03-22  Bruno Haible  <bruno@clisp.org>
36707         Several modules: Depend on stat.
36708         * modules/acl-permissions (Depends-on): Add stat.
36709         * modules/canonicalize (Depends-on): Likewise.
36710         * modules/file-has-acl (Depends-on): Likewise.
36711         * modules/fstat (Depends-on): Likewise.
36712         * modules/fstatat (Depends-on): Likewise.
36713         * modules/glob (Depends-on): Likewise.
36714         * modules/javacomp (Depends-on): Likewise.
36715         * modules/linkat (Depends-on): Likewise.
36716         * modules/mkdir (Depends-on): Likewise.
36717         * modules/pt_chown (Depends-on): Likewise.
36718         * modules/ptsname_r (Depends-on): Likewise.
36719         * modules/readlinkat (Depends-on): Likewise.
36720         * modules/rename (Depends-on): Likewise.
36721         * modules/renameatu (Depends-on): Likewise.
36722         * modules/tmpdir (Depends-on): Likewise.
36723         * modules/utimens (Depends-on): Likewise.
36724         * modules/relocatable-prog-wrapper (Depends-on): Add largefile.
36725         * modules/same (Depends-on): Remove stat.
36727 2020-03-22  Bruno Haible  <bruno@clisp.org>
36729         acl-permissions: Improve autoconf macro.
36730         * m4/acl.m4 (gl_FUNC_ACL): Test the value of gl_need_lib_has_acl
36731         more reliably.
36733 2020-03-22  Bruno Haible  <bruno@clisp.org>
36735         file-has-acl: Fix module description.
36736         * modules/file-has-acl (Files): Add lib/acl-internal.h, m4/acl.m4.
36737         (Depends-on): Depend on acl-permissions unconditionally.
36739 2020-03-21  Bruno Haible  <bruno@clisp.org>
36741         unlink: Ensure errno also on native Windows.
36742         * modules/unlink (Depends-on): Add malloc-posix.
36744 2020-03-21  Paul Eggert  <eggert@cs.ucla.edu>
36746         unlink: fix malloc errno typo
36747         Problem reported by Tim Rühsen in:
36748         https://lists.gnu.org/r/bug-gnulib/2020-03/msg00044.html
36749         * lib/unlink.c (rpl_unlink): Don’t mask malloc errno.
36751 2020-03-16  Bruno Haible  <bruno@clisp.org>
36753         *printf-posix: Fix m4 error (regression from 2020-03-08).
36754         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): Enable interpretation of
36755         brackets in AC_COMPILE_IFELSE invocation.
36757 2020-03-08  Bruno Haible  <bruno@clisp.org>
36759         crypto/af_alg, renameatu, same, term-style-control: Depend on fstat.
36760         * modules/crypto/af_alg (Depends-on): Add fstat.
36761         * modules/renameatu (Depends-on): Likewise.
36762         * modules/same (Depends-on): Likewise.
36763         * modules/term-style-control (Depends-on): Likewise.
36765 2020-03-08  Bruno Haible  <bruno@clisp.org>
36767         *printf-posix: Document why it's overridden on some glibc systems.
36768         Reported by Adrian Bunk <bunk@stusta.de> in
36769         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00011.html>.
36770         * doc/posix-functions/*printf.texi: Document the problem with the %n
36771         directive on some glibc systems.
36772         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N, gl_SNPRINTF_DIRECTIVE_N): Adjust
36773         the cross-compilation guesses accordingly.
36775 2020-03-07  Paul Eggert  <eggert@cs.ucla.edu>
36777         open, openat: port to (O_RDWR | O_RDONLY) != 0
36778         Potential portability problem reported by Dan Gohman in:
36779         https://lists.gnu.org/r/bug-gnulib/2020-03/msg00000.html
36780         * lib/open.c (open):
36781         * lib/openat.c (rpl_openat):
36782         Don’t assume O_RDONLY is disjoint from O_RDWR.
36784 2020-03-07  Bruno Haible  <bruno@clisp.org>
36786         openat: Fix theoretically possible issue on GNU/Hurd.
36787         Reported by Dan Gohman <sunfish@mozilla.com> in
36788         <https://lists.gnu.org/archive/html/bug-gnulib/2020-03/msg00000.html>.
36789         * lib/openat.c (rpl_openat): When testing whether flags contains O_RDWR,
36790         ignore the bits that are also set in O_RDONLY.
36792 2020-02-24  Bruno Haible  <bruno@clisp.org>
36794         getloadavg: Don't use /usr/local when cross-compiling on AIX.
36795         Reported by Jens Rehsack <sno@netbsd.org> in
36796         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00136.html>.
36797         * m4/getloadavg.m4 (gl_GETLOADAVG): Don't look in /usr/local/lib when
36798         cross-compiling.
36800 2020-02-24  Bruno Haible  <bruno@clisp.org>
36802         fcntl: Add witness of gnulib override.
36803         Reported by Jens Rehsack <sno@netbsd.org> in
36804         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00137.html>.
36805         * lib/fcntl.in.h (GNULIB_defined_rpl_fcntl, GNULIB_defined_fcntl): New
36806         macros.
36808 2020-02-23  Assaf Gordon  <assafgordon@gmail.com>
36810         Update users.txt.
36811         * users.txt: Add datamash, time.
36813 2020-02-23  Bruno Haible  <bruno@clisp.org>
36815         uni*/base: Use 'restrict'.
36816         * lib/unitypes.in.h (_UC_RESTRICT): New macro, based on '_Restrict_'
36817         from lib/regex.h.
36818         * lib/unistr.in.h (u8_cpy, u16_cpy, u32_cpy, u8_strcpy, u16_strcpy,
36819         u32_strcpy, u8_stpcpy, u16_stpcpy, u32_stpcpy, u8_strncpy, u16_strncpy,
36820         u32_strncpy, u8_stpncpy, u16_stpncpy, u32_stpncpy, u8_strcat,
36821         u16_strcat, u32_strcat, u8_strncat, u16_strncat, u32_strncat, u8_strtok,
36822         u16_strtok, u32_strtok): Use '_UC_RESTRICT'.
36823         * lib/uninorm.in.h (u8_normalize, u16_normalize, u32_normalize): Use
36824         '_UC_RESTRICT'.
36825         * lib/uniconv.in.h (u8_conv_to_encoding, u16_conv_to_encoding,
36826         u32_conv_to_encoding): Use '_UC_RESTRICT'.
36827         * lib/unicase.in.h (u8_toupper, u16_toupper, u32_toupper, u8_tolower,
36828         u16_tolower, u32_tolower, u8_totitle, u16_totitle, u32_totitle,
36829         u8_ct_toupper, u16_ct_toupper, u32_ct_toupper, u8_ct_tolower,
36830         u16_ct_tolower, u32_ct_tolower, u8_ct_totitle, u16_ct_totitle,
36831         u32_ct_totitle, u8_casefold, u16_casefold, u32_casefold, u8_ct_casefold,
36832         u16_ct_casefold, u32_ct_casefold, u8_casexfrm, u16_casexfrm,
36833         u32_casexfrm, ulc_casexfrm): Use '_UC_RESTRICT'.
36834         * lib/unilbrk.in.h (u8_possible_linebreaks, u16_possible_linebreaks,
36835         u32_possible_linebreaks, ulc_possible_linebreaks, u8_width_linebreaks,
36836         u16_width_linebreaks, u32_width_linebreaks, ulc_width_linebreaks): Use
36837         '_UC_RESTRICT'.
36838         * lib/uniwbrk.in.h (ulc_wordbreaks): Use '_UC_RESTRICT'.
36839         * lib/unistdio.in.h (ulc_sprintf, ulc_snprintf, ulc_asnprintf,
36840         ulc_vsprintf, ulc_vsnprintf, ulc_vasnprintf, u8_u8_sprintf,
36841         u8_u8_snprintf, u8_u8_asnprintf, u8_u8_vsprintf, u8_u8_vsnprintf,
36842         u8_u8_vasnprintf, u16_u16_sprintf, u16_u16_snprintf, u16_u16_asnprintf,
36843         u16_u16_vsprintf, u16_u16_vsnprintf, u16_u16_vasnprintf,
36844         u32_u32_sprintf, u32_u32_snprintf, u32_u32_asnprintf, u32_u32_vsprintf,
36845         u32_u32_vsnprintf, u32_u32_vasnprintf): Use '_UC_RESTRICT'.
36847 2020-02-23  Bruno Haible  <bruno@clisp.org>
36849         glob, spawn: Use improved '_Restrict_' definition.
36850         * lib/glob.in.h (_Restrict_): Use same definition as in lib/regex.h.
36851         * lib/spawn.in.h (_Restrict_, _Restrict_arr_): Likewise.
36853 2020-02-23  Bruno Haible  <bruno@clisp.org>
36855         crypto/gc: Use 'restrict'.
36856         * lib/gc.h (gc_pbkdf2_hmac, gc_pbkdf2_sha1): Use 'restrict'.
36857         * m4/gc.m4 (gl_GC): Require AC_C_RESTRICT.
36859         crypto/hmac-*: Use 'restrict'.
36860         * lib/hmac.h (hmac_md5, hmac_sha1, hmac_sha256, hmac_sha512): Use
36861         'restrict'.
36862         * modules/crypto/hmac-md5 (configure.ac): Require AC_C_RESTRICT.
36863         * modules/crypto/hmac-sha1 (configure.ac): Likewise.
36864         * modules/crypto/hmac-sha256 (configure.ac): Likewise.
36865         * modules/crypto/hmac-sha512 (configure.ac): Likewise.
36867         crypto/sm3: Use 'restrict'.
36868         * lib/sm3.h (sm3_finish_ctx, sm3_read_ctx, sm3_buffer): Use 'restrict'.
36869         * m4/sm3.m4 (gl_SM3): Require AC_C_RESTRICT.
36871         crypto/*-buffer: Use 'restrict'.
36872         * lib/gl_openssl.h (GL_CRYPTO_FN (_finish_ctx), GL_CRYPTO_FN (_buffer),
36873         GL_CRYPTO_FN (_read_ctx)): Use 'restrict'.
36875         crypto/sha512-buffer: Use 'restrict'.
36876         * lib/sha512.h (sha512_finish_ctx, sha384_finish_ctx, sha512_read_ctx,
36877         sha384_read_ctx, sha512_buffer, sha384_buffer): Use 'restrict'.
36878         * modules/crypto/sha512-buffer (configure.ac): Require AC_C_RESTRICT.
36880         crypto/sha256-buffer: Use 'restrict'.
36881         * lib/sha256.h (sha256_finish_ctx, sha224_finish_ctx, sha256_read_ctx,
36882         sha224_read_ctx, sha256_buffer, sha224_buffer): Use 'restrict'.
36883         * modules/crypto/sha256-buffer (configure.ac): Require AC_C_RESTRICT.
36885         crypto/sha1-buffer: Use 'restrict'.
36886         * lib/sha1.h (sha1_finish_ctx, sha1_read_ctx, sha1_buffer): Use
36887         'restrict'.
36888         * modules/crypto/sha1-buffer (configure.ac): Require AC_C_RESTRICT.
36890         crypto/md5-buffer: Use 'restrict'.
36891         * lib/md5.h (__md5_finish_ctx, __md5_read_ctx, __md5_buffer): Use
36892         'restrict'.
36893         * modules/crypto/md5-buffer (configure.ac): Require AC_C_RESTRICT.
36895         crypto/md4: Use 'restrict'.
36896         * lib/md4.h (md4_finish_ctx, md4_read_ctx, md4_buffer): Use 'restrict'.
36897         * modules/crypto/md4 (configure.ac): Require AC_C_RESTRICT.
36899         crypto/md2: Use 'restrict'.
36900         * lib/md2.h (md2_finish_ctx, md2_read_ctx, md2_buffer): Use 'restrict'.
36901         * modules/crypto/md2 (configure.ac): Require AC_C_RESTRICT.
36903         crypto/rijndael: Use 'restrict'.
36904         * lib/rijndael-api-fst.h (rijndaelBlockEncrypt, rijndaelPadEncrypt,
36905         rijndaelBlockDecrypt, rijndaelPadDecrypt): Use 'restrict'.
36906         * modules/crypto/rijndael (configure.ac): Require AC_C_RESTRICT.
36908         crypto/arctwo: Use 'restrict'.
36909         * lib/arctwo.h (arctwo_encrypt, arctwo_decrypt): Use 'restrict'.
36910         * modules/crypto/arctwo (configure.ac): Require AC_C_RESTRICT.
36912         crypto/arcfour: Use 'restrict'.
36913         * lib/arcfour.h (arcfour_stream): Use 'restrict'.
36914         * modules/crypto/arcfour (configure.ac): Require AC_C_RESTRICT.
36916         careadlinkat: Use 'restrict'.
36917         * lib/careadlinkat.h (careadlinkat): Use 'restrict'.
36918         * modules/careadlinkat (configure.ac): Require AC_C_RESTRICT.
36919         * modules/relocatable-prog-wrapper (configure.ac): Likewise.
36921         regex-quote: Use 'restrict'.
36922         * lib/regex-quote.h (regex_quote_copy): Use 'restrict'.
36923         * modules/regex-quote (configure.ac): Require AC_C_RESTRICT.
36925         system-quote: Use 'restrict'.
36926         * lib/system-quote.h (system_quote_copy): Use 'restrict'.
36927         * modules/system-quote (configure.ac): Require AC_C_RESTRICT.
36929         sh-quote: Use 'restrict'.
36930         * lib/sh-quote.h (shell_quote_copy): Use 'restrict'.
36931         * modules/sh-quote (configure.ac): Require AC_C_RESTRICT.
36933         quotearg: Use 'restrict'.
36934         * lib/quotearg.h (quotearg_buffer): Use 'restrict'.
36935         * m4/quotearg.m4 (gl_QUOTEARG): Require AC_C_RESTRICT.
36937         parse-datetime: Use 'restrict'.
36938         * lib/parse-datetime.h (parse_datetime, parse_datetime2): Use
36939         'restrict'.
36940         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Require AC_C_RESTRICT.
36942         nstrftime: Use 'restrict'.
36943         * lib/strftime.h (nstrftime): Use 'restrict'.
36944         * m4/nstrftime.m4 (gl_FUNC_GNU_STRFTIME): Require AC_C_RESTRICT.
36946         mbstok_r: Use 'restrict'.
36947         * lib/string.in.h (mbstok_r): Use 'restrict'.
36949         xmemcoll: Use 'restrict'.
36950         * lib/xmemcoll.h (xmemcoll): Use 'restrict'.
36951         * modules/xmemcoll (configure.ac): Require AC_C_RESTRICT.
36953         memcoll: Use 'restrict'.
36954         * lib/memcoll.h (memcoll): Use 'restrict'.
36955         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_C_RESTRICT.
36957         vasnprintf: Use 'restrict'.
36958         * lib/vasnprintf.h (asnprintf, vasnprintf): Use 'restrict'.
36959         * modules/vasnprintf (configure.ac): Require AC_C_RESTRICT.
36961         c-vasnprintf: Use 'restrict'.
36962         * lib/c-vasnprintf.h (c_vasnprintf): Use 'restrict'.
36963         * modules/c-vasnprintf (configure.ac): Require AC_C_RESTRICT.
36965         c-vsnprintf: Use 'restrict'.
36966         * lib/c-vsnprintf.h (c_vsnprintf): Use 'restrict'.
36967         * modules/c-vsnprintf (configure.ac): Require AC_C_RESTRICT.
36969         c-snprintf: Use 'restrict'.
36970         * lib/c-snprintf.h (c_snprintf): Use 'restrict'.
36971         * modules/c-snprintf (configure.ac): Require AC_C_RESTRICT.
36973         astrxfrm: Use 'restrict'.
36974         * lib/astrxfrm.h (astrxfrm): Use 'restrict'.
36975         * modules/astrxfrm (configure.ac): Require AC_C_RESTRICT.
36977         amemxfrm: Use 'restrict'.
36978         * lib/amemxfrm.h (amemxfrm): Use 'restrict'.
36979         * modules/amemxfrm (configure.ac): Require AC_C_RESTRICT.
36981 2020-02-22  Paul Eggert  <eggert@cs.ucla.edu>
36983         fchmodat, lchmod: simplify
36984         It appears that we may have overengineered lchmod and fchmodat,
36985         in that the code was prepared for some hypothetical platforms but
36986         was so complicated that it was hard to understand.  I attempted to
36987         improve the situation by simplifying the code when this
36988         simplification should not hurt on real platforms; we can re-add
36989         complexity later to port to platforms I didn’t know about.
36990         * lib/fchmodat.c (fchmodat):
36991         * lib/lchmod.c (lchmod):
36992         Put the ‘defined __linux__ || defined __ANDROID__’ #ifdef only
36993         around the /proc code that needs it.
36994         * lib/fchmodat.c (fchmodat): Coalese calls to orig_fchmodat.
36995         * lib/lchmod.c (__need_system_sys_stat_h): Omit; no longer needed.
36996         Do not include <config.h> twice.
36997         (orig_lchmod) [HAVE_LCHMOD]: Remove, since we need not wrap
36998         lchmod on any known hosts.
36999         (lchmod): Do not defer to fchmodat, so that the lchmod module
37000         need not depend on the fchmodat module (which is a circular
37001         dependency).  Do not use openat, since ‘open’ suffices.
37002         Coalesce calls to lchmod/chmod.
37003         * lib/lchmod.c, lib/sys_stat.in.h (lchmod):
37004         * m4/sys_stat_h.m4 (REPLACE_FSTAT):
37005         * modules/lchmod (Depends-on, configure.ac):
37006         * modules/sys_stat (Depends-on):
37007         Do not worry about replacing lchmod, since that shouldn’t happen.
37008         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Do not check for fchmodat.
37009         Do not worry about whether lchmod works on non-symlinks,
37010         since every known lchmod works on non-symlinks.
37011         * modules/lchmod (Depends-on):
37012         Remove circular dependency on fchmodat.
37014 2020-02-22  Bruno Haible  <bruno@clisp.org>
37016         lchmod: Fix link error on Solaris 10 (regression from 2020-02-16).
37017         * lib/lchmod.c (lchmod): Use the code with lstat and chmod also when
37018         NEED_LCHMOD_NONSYMLINK_FIX is not defined.
37020 2020-02-22  Bruno Haible  <bruno@clisp.org>
37022         Use 'restrict' in all POSIX function declarations.
37023         * lib/iconv.in.h (iconv): Use 'restrict'.
37024         * lib/inttypes.in.h (strtoimax, strtoumax): Likewise.
37025         * lib/monetary.in.h (strfmon_l): Likewise.
37026         * lib/pthread.in.h (pthread_create, pthread_mutex_init,
37027         pthread_mutexattr_gettype, pthread_mutexattr_getrobust,
37028         pthread_mutex_timedlock, pthread_rwlock_init,
37029         pthread_rwlock_timedrdlock, pthread_rwlock_timedwrlock,
37030         pthread_cond_init, pthread_cond_wait, pthread_cond_timedwait): Likewise.
37031         * lib/search.in.h (tdelete): Likewise.
37032         * lib/signal.in.h (pthread_sigmask, sigprocmask): Likewise.
37033         * lib/stdio.in.h (dprintf, fgets, fopen, fprintf, fputs, fread, freopen,
37034         fscanf, fwrite, getdelim, getline, printf, scanf, snprintf, sprintf,
37035         vdprintf, vfprintf, vfscanf, vprintf, vscanf, vsnprintf, vsprintf):
37036         Likewise.
37037         * lib/stdlib.in.h (mbtowc, realpath, strtod, strtold, strtoll,
37038         strtoull): Likewise.
37039         * lib/string.in.h (strncat): Likewise.
37040         * lib/sys_socket.in.h (accept, getpeername, getsockname, getsockopt,
37041         recvfrom): Likewise.
37042         * lib/sys_stat.in.h (fstatat, lstat, stat): Likewise.
37043         * lib/time.in.h (strftime): Likewise.
37044         * lib/unistd.in.h (readlink, readlinkat): Likewise.
37045         * lib/wchar.in.h (mbrtowc, mbrlen, mbsrtowcs, mbsnrtowcs, wcrtomb,
37046         wcsrtombs, wcsnrtombs, wmemcpy, wcscpy, wcpcpy, wcsncpy, wcpncpy,
37047         wcscat, wcsncat, wcsxfrm, wcsstr, wcstok, wcsftime): Likewise.
37048         * m4/iconv_h.m4 (gl_ICONV_H): Require AC_C_RESTRICT.
37049         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): Likewise.
37050         * m4/monetary_h.m4 (gl_MONETARY_H): Likewise.
37051         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
37052         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
37053         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
37054         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
37055         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
37056         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
37057         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
37058         * m4/wchar_h.m4 (gl_WCHAR_H): Likewise.
37059         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Make consistent with the
37060         other *_h.m4 files.
37061         * m4/time_h.m4 (gl_HEADER_TIME_H): Likewise.
37063 2020-02-22  Bruno Haible  <bruno@clisp.org>
37065         Update NEWS.
37066         * NEWS: Mention the last change.
37068 2020-02-22  Paul Eggert  <eggert@cs.ucla.edu>
37070         chmodat, chownat: new modules
37071         These are split from fchmodat, fchownat.  GNU Emacs needs the
37072         POSIX-specified fchmodat, but not the gnulib-specified chmodat and
37073         lchmodat.  Split the latter two into a new module chmodat.
37074         Similarly for fchownat.  This the same basic idea for why statat
37075         was split from fstatat on 2013-01-23.
37076         * lib/chmodat.c, lib/openat.h (CHMODAT_INLINE):
37077         Rename from FCHMODAT_INLINE.  All uses changed.
37078         * lib/chownat.c, lib/openat.h (CHOWNAT_INLINE):
37079         Rename from FCHOWNAT_INLINE.  All uses changed.
37080         * lib/openat.h:
37081         (chownat, lchownat): Define if GNULIB_CHOWNAT, not GNULIB_FCHOWNAT.
37082         (chmodat, lchmodat): Define if GNULIB_CHMODAT, not GNULIB_FCHMODAT.
37083         * modules/chmodat, modules/chownat, tests/test-chownat.c: New files.
37084         * modules/fchmodat (Files:): Remove lib/fchmodat.c.
37085         (configure.ac): Remove fchmodat module indicator.
37086         (Makefile.am): Omit chmodat.c.
37087         (Maintainer): Add self.
37088         * modules/fchownat: Similarly, but for chown.
37089         * tests/test-fchownat.c (BASE): Don't define if already defined.
37090         (do_chown, do_lchown) [!TEST_CHOWNAT]: Test fchownat instead.
37092 2020-02-22  Bruno Haible  <bruno@clisp.org>
37094         users.txt: Add groff.
37095         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is>.
37096         * users.txt: Add groff.
37098 2020-02-22  Bruno Haible  <bruno@clisp.org>
37100         gnulib-tool: Ensure copied files are writable.
37101         Reported by Benno Fünfstück <benno.fuenfstueck@gmail.com> in
37102         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00101.html>.
37103         * gnulib-tool (func_ensure_writable): New function.
37104         (func_ln_s, func_hardlink, func_lookup_file, func_import,
37105         func_create_testdir, copy-file): Invoke it after copying a file.
37107 2020-02-22  Bruno Haible  <bruno@clisp.org>
37109         users.txt: Update.
37110         * users.txt: Update URLs to projects that have moved or switched to git.
37111         Use canonical host names. Prefer gitweb over cgit. Prefer the tree view
37112         over the summary view. Add gawk.
37114 2020-02-21  Paul Eggert  <eggert@cs.ucla.edu>
37116         largefile: remove _DARWIN_USE_64_BIT_INODE
37117         It’s not needed in currently-supported macOS versions, and was
37118         problematic anyway in MacOS X 10.5 which was the only version that
37119         could use it.  Problem reported by Peter Eisentraut in:
37120         https://lists.gnu.org/r/bug-autoconf/2020-02/msg00004.html
37121         * m4/largefile.m4 (AC_SYS_LARGEFILE):
37122         Don’t define _DARWIN_USE_64_BIT_INODE.
37123         This syncs with Autoconf master.
37125         Add ‘extern "C"’ to count-one-bits.h etc.
37126         This ports these .h files to C++.
37127         Problem reported by Simon Marchi in:
37128         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00110.html
37129         * lib/count-leading-zeros.h, lib/count-one-bits.h:
37130         * lib/count-trailing-zeros.h: Add ‘extern "C"’.
37132 2020-02-19  Bruno Haible  <bruno@clisp.org>
37134         uninorm/decompose-internal: Avoid "no previous prototype" warning.
37135         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
37136         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00105.html>.
37137         * lib/array-mergesort.h: Accept an optional macro definition
37138         STATIC_FROMTO.
37139         * lib/uninorm/decompose-internal.c (STATIC_FROMTO): New macro.
37141 2020-02-16  Bruno Haible  <bruno@clisp.org>
37143         fchmodat: Make more future-proof.
37144         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): Define
37145         NEED_FCHMODAT_NONSYMLINK_FIX.
37146         (gl_PREREQ_FCHMODAT): New macro.
37147         * lib/fchmodat.c (fchmodat): Test NEED_FCHMODAT_NONSYMLINK_FIX. Access
37148         /proc only on Linux. Return EOPNOTSUPP only on Linux and on platforms
37149         without lchmod function.
37150         * modules/fchmodat (configure.ac): Invoke gl_PREREQ_FCHMODAT.
37152 2020-02-16  Bruno Haible  <bruno@clisp.org>
37154         lchmod: Make more future-proof.
37155         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Define NEED_LCHMOD_NONSYMLINK_FIX.
37156         (gl_PREREQ_LCHMOD): New macro.
37157         * lib/lchmod.c (orig_lchmod): New function.
37158         (lchmod): Test NEED_LCHMOD_NONSYMLINK_FIX. Access /proc only on Linux.
37159         Return EOPNOTSUPP only on Linux and on platforms without lchmod
37160         function.
37161         * modules/lchmod (configure.ac): Invoke gl_PREREQ_LCHMOD.
37163         lchmod: Fix buggy override on macOS, HP-UX (regression from 2020-02-08).
37164         * modules/lchmod (Makefile.am): Don't add lchmod.c to lib_SOURCES.
37166 2020-02-16  Paul Eggert  <eggert@cs.ucla.edu>
37168         xnanosleep: prefer pause, and get remaining time
37169         Problem reported by Vladimir Panteleev in:
37170         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00052.html
37171         * lib/xnanosleep.c: Include intprops.h, unistd.h.
37172         (xnanosleep) [HAVE_PAUSE]: Prefer pause when sleeping infinitely.
37173         (xnanosleep): Obtain remaining time when nanosleep is interrupted.
37174         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Check for 'pause'.
37175         * modules/xnanosleep (Depends-on): Add intprops, unistd.
37177 2020-02-16  Bruno Haible  <bruno@clisp.org>
37179         lchmod: Improve cross-compilation guess.
37180         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Require AC_CANONICAL_HOST. When
37181         cross-compiling, guess depending on the platform.
37183 2020-02-16  Bruno Haible  <bruno@clisp.org>
37185         fstrcmp: Add API to clean up resources.
37186         Reported by Akim Demaille <akim@lrde.epita.fr> in
37187         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00080.html>.
37188         * lib/fstrcmp.h (fstrcmp_free_resources): New declaration.
37189         * lib/fstrcmp.c (fstrcmp_free_resources): New function.
37191 2020-02-14  Bruno Haible  <bruno@clisp.org>
37193         wctype-h: Fix compilation errors in C++ (regression from 2020-01-25).
37194         Reported by Christian Biesinger in
37195         <https://lists.gnu.org/archive/html/bug-gnulib/2020-02/msg00064.html>.
37196         * lib/wctype.in.h (iswdigit, iswxdigit): Don't declare if the
37197         corresponding module is not enabled.
37198         * tests/test-wctype-h-c++.cc (iswdigit, iswxdigit): Don't check the
37199         prototype if the corresponding module is not enabled.
37201 2020-02-13  Paul Eggert  <eggert@cs.ucla.edu>
37203         fchmodat, lchmod: port to buggy Linux filesystems
37204         Problem reported by Florian Weimer in:
37205         https://www.sourceware.org/ml/libc-alpha/2020-02/msg00534.html
37206         * lib/fchmodat.c (fchmodat):
37207         * lib/lchmod.c (lchmod):
37208         Don’t assume that chmod on the O_PATH-opened fd will do
37209         the right thing on a symbolic link.
37210         * lib/fchmodat.c (fchmodat):
37211         Don’t attempt to special-case
37212         any flag value other than AT_SYMLINK_NOFOLLOW.
37214 2020-02-11  Paul Eggert  <eggert@cs.ucla.edu>
37216         lchmod: pacify Coverity CID 1491216
37217         * lib/lchmod.c (lchmod): Redo #if nesting so that Coverity does
37218         not complain about unreachable code at the ‘struct stat st;’
37219         declaration.
37221 2020-02-10  Bruno Haible  <bruno@clisp.org>
37223         copysignf: Fix link error on HP-UX with cc.
37224         * m4/copysignf.m4 (gl_FUNC_COPYSIGNF): Require AC_CANONICAL_HOST. On
37225         HP-UX, set COPYSIGNF_LIBM to -lm.
37227 2020-02-10  Bruno Haible  <bruno@clisp.org>
37229         pthread-mutex-tests, pthread-rwlock-tests: Fix link errors on HP-UX.
37230         * modules/pthread-mutex-tests (Makefile.am): Link test-pthread-mutex
37231         with $(LIB_SEMAPHORE).
37232         * modules/pthread-rwlock-tests (Makefile.am): Link test-pthread-rwlock
37233         with $(LIB_SEMAPHORE).
37235 2020-02-10  Bruno Haible  <bruno@clisp.org>
37237         ptsname_r-tests: Avoid unused function warning.
37238         * tests/test-ptsname_r.c: Don't include null-ptr.h if we don't need it.
37240 2020-02-08  Bruno Haible  <bruno@clisp.org>
37242         lchmod: Add tests.
37243         * tests/test-lchmod.c: New file.
37244         * modules/lchmod-tests: New file.
37246 2020-02-08  Bruno Haible  <bruno@clisp.org>
37248         lchmod: Ensure declaration on HP-UX.
37249         * lib/sys_stat.in.h (lchown): Declare also on HP-UX.
37250         * doc/glibc-functions/lchmod.texi: Mention the HP-UX problem.
37252 2020-02-08  Bruno Haible  <bruno@clisp.org>
37254         fchmodat: Strengthen tests.
37255         * tests/test-fchmodat.c (BASE): New macro.
37256         (main): Use it, to avoid conflicts with other unit tests. Verify that
37257         fchmodat changed the file permission bits.
37259 2020-02-08  Bruno Haible  <bruno@clisp.org>
37261         fchmodat: Fix endless recursion on Cygwin (regression from 2020-02-07).
37262         * lib/fchmodat.c (orig_fchmodat): Move definition to immediately after
37263         '#undef __need_system_sys_stat_h'.
37265 2020-02-08  Bruno Haible  <bruno@clisp.org>
37267         fchmodat: Improve cross-compilation guesses.
37268         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): Require AC_CANONICAL_HOST. When
37269         cross-compiling, guess depending on the platform.
37270         * doc/posix-functions/fchmodat.texi: Clarify.
37272 2020-02-08  Bruno Haible  <bruno@clisp.org>
37274         Fix compilation errors in a testdir created with --with-c++-tests.
37275         * lib/c++defs.h (_GL_CXXALIASWARN1_2): Do not use __typeof__ (func),
37276         since it does not work any more with g++ >= 4.4.
37278 2020-02-08  Bruno Haible  <bruno@clisp.org>
37280         doc: Update for glibc 2.31.
37281         * doc/glibc-functions/pthread_clockjoin_np.texi: New file.
37282         * doc/gnulib.texi: Include it.
37283         * doc/pastposix-functions/h_errno.texi: Update.
37284         * doc/posix-functions/*.texi: Likewise.
37286 2020-02-08  Kenneth D'souza  <kdsouza@redhat.com>
37288         mountlist: consider smb3 file systems as remote
37289         * lib/mountlist.c (ME_REMOTE): Recognize file systems of type
37290         "smb3" as remote.
37292 2020-02-07  Paul Eggert  <eggert@cs.ucla.edu>
37294         fchmodat: AT_SYMLINK_NOFOLLOW fix for non-symlinks
37295         Fix lchmod, and fchmodat with AT_SYMLINK_NOFOLLOW, so that
37296         they act like chmod on non-symlinks.
37297         * NEWS:
37298         * doc/glibc-functions/lchmod.texi (lchmod):
37299         * doc/posix-functions/fchmodat.texi (fchmodat):
37300         Mention this.
37301         * lib/fchmodat.c: Define __need_system_sys_stat_h before including
37302         config.h, and undef it after including sys/stat.h the first time.
37303         Include fcntl.h, stdio.h, unistd.h, intprops.h, and include
37304         sys/stat.h a second time after defining orig_fchmodat.
37305         (orig_fchmodat) [HAVE_FCHMODAT]: New function.
37306         (fchmodat) [HAVE_FCHMODAT]: Work around the AT_SYMLINK_NOFOLLOW bug.
37307         * lib/lchmod.c: New file.
37308         * lib/sys_stat.in.h (fchmodat, lchmod):
37309         Support replacing these functions.
37310         * m4/fchmodat.m4 (gl_FUNC_FCHMODAT): If fchmodat exists,
37311         test that AT_SYMLINK_NOFOLLOW works on non-symlinks.
37312         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Check for lstat.
37313         Test that lchmod works on non-symlinks.
37314         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS):
37315         Default REPLACE_FCHMODAT and REPLACE_LCHMOD to 0.
37316         * modules/fchmodat (Depends-on): Add fstatat, intprops, lchmod, unistd.
37317         (Depends-on, configure.ac): Check REPLACE_FCHMODAT too.
37318         * modules/lchmod (Files): Add lib/lchmod.c.
37319         (Depends-on): Add errno, fcntl-h, fchmodat, intprops, lstat, unistd.
37320         (configure.ac): Compile lchmod.c if needed.
37321         (lib_SOURCES): Add lchmod.c.
37322         * modules/sys_stat (sys/stat.h): Substitute REPLACE_FCHMODAT
37323         and REPLACE_LCHMOD.
37324         * tests/test-fchmodat.c: Include fcntl.h, sys/stat.h.
37325         (main): Test fchmodat with AT_SYMLINK_NOFOLLOW on non-symlinks.
37327 2020-02-05  Marc Dionne  <marc.dionne@auristor.com>  (tiny change)
37329         mountlist: Consider AFS filesystems as remote
37330         df --local relies on the ME_REMOTE macro to determine if a given
37331         mount entry should be considered "local".  There is special logic
37332         for nfs and smb/cifs mounts, but /afs as mounted by OpenAFS, the
37333         kernel's kafs module or AuriStorFS is treated as a local mount.
37334         * lib/mountlist.c (ME_REMOTE): Treat mounts of type 'afs'
37335         (OpenAFS, kernel kafs) and 'auristorfs' (AuriStorFS) as remote.
37337 2020-02-04  Paul Eggert  <eggert@cs.ucla.edu>
37339         Port _Noreturn to older Clang
37340         Problem reported by Jeffery Walton in:
37341         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00013.html
37342         * lib/_Noreturn.h (_Noreturn):
37343         * m4/gnulib-common.m4 (gl_COMMON_BODY):
37344         Assume _Noreturn works in Clang 3.5 and later.
37345         It is documented to work in Clang 3.5:
37346         http://releases.llvm.org/3.5.0/tools/clang/docs/AttributeReference.html
37347         and is not documented in Clang 3.4:
37348         https://releases.llvm.org/3.4/tools/clang/docs/LanguageExtensions.html
37349         Apple sets __clang_version__ to a different value, so use
37350         __apple_build_version__ there.  See:
37351         https://lists.gnu.org/r/bug-gnulib/2020-02/msg00017.html
37353 2020-02-04  Pádraig Brady  <P@draigBrady.com>
37355         test-canonicalize: avoid unused function warning
37356         * tests/test-canonicalize.c: Protect the inclusion of null-ptr.h
37357         with the same guard as that used to protect usage of the null_ptr
37358         function, so that one doesn't get a -Wunused warning.
37359         * tests/test-canonicalize-lgpl.c: Likewise.
37361 2020-02-03  Paul Eggert  <eggert@cs.ucla.edu>
37363         libc-config: port to Apple’s Clang variant
37364         * lib/libc-config.h (__glibc_clang_prereq):
37365         Port to Apple’s Clang variant, which uses a different
37366         numbering scheme for __clang_major__.
37368 2020-02-02  Bruno Haible  <bruno@clisp.org>
37370         Document the new modules list-c++, set-c++, oset-c++, map-c++, omap-c++.
37371         * doc/containers.texi: Document these new modules.
37373 2020-02-02  Bruno Haible  <bruno@clisp.org>
37375         omap-c++: Add tests.
37376         * tests/test-omap-c++.cc: New file.
37377         * modules/omap-c++-tests: New file.
37379         omap-c++: New module.
37380         * lib/gl_omap.hh: New file, based on lib/gl_omap.h.
37381         * modules/omap-c++: New file.
37383 2020-02-02  Bruno Haible  <bruno@clisp.org>
37385         map-c++: Add tests.
37386         * tests/test-map-c++.cc: New file.
37387         * modules/map-c++-tests: New file.
37389         map-c++: New module.
37390         * lib/gl_map.hh: New file, based on lib/gl_map.h.
37391         * modules/map-c++: New file.
37393 2020-02-02  Bruno Haible  <bruno@clisp.org>
37395         oset-c++: Add tests.
37396         * tests/test-oset-c++.cc: New file.
37397         * modules/oset-c++-tests: New file.
37399         oset-c++: New module.
37400         * lib/gl_oset.hh: New file, based on lib/gl_oset.h.
37401         * modules/oset-c++: New file.
37403 2020-02-02  Bruno Haible  <bruno@clisp.org>
37405         set-c++: Add tests.
37406         * tests/test-set-c++.cc: New file.
37407         * modules/set-c++-tests: New file.
37409         set-c++: New module.
37410         * lib/gl_set.hh: New file, based on lib/gl_set.h.
37411         * modules/set-c++: New file.
37413 2020-02-02  Bruno Haible  <bruno@clisp.org>
37415         list-c++: Add tests.
37416         * tests/test-list-c++.cc: New file.
37417         * modules/list-c++-tests: New file.
37419         list-c++: New module.
37420         * lib/gl_list.hh: New file, based on lib/gl_list.h.
37421         * modules/list-c++: New file.
37423 2020-02-02  Bruno Haible  <bruno@clisp.org>
37425         xalloc: Fix compilation error in C++ mode on FreeBSD 12.
37426         * lib/xalloc.h (xalloc_die): Comment out 'extern' keyword before
37427         '_Noreturn'.
37428         * lib/sigpipe-die.h (sigpipe_die): Likewise.
37430 2020-02-02  Pádraig Brady  <P@draigBrady.com>
37432         read-file: reduce max size from SIZE_MAX to PTRDIFF_MAX
37433         On x86_64 with glibc-2.30, gcc 9.2 is giving:
37434           error: argument 2 value '18446744073709551615'
37435           exceeds maximum object size 9223372036854775807
37436           [-Werror=alloc-size-larger-than=]
37437         The details of this restriction are discussed at:
37438         https://stackoverflow.com/q/42574890/4421
37439         * lib/read-file.c: s/SIZE_MAX/PTRDIFF_MAX/
37441 2020-02-02  Pádraig Brady  <P@draigBrady.com>
37443         sysctl.h: avoid including on glibc
37444         * lib/nproc.c: Avoid including deprecated and unneeded header on GLIBC.
37445         * lib/physmem.c: Likewise.
37447 2020-02-02  Bruno Haible  <bruno@clisp.org>
37449         list, set, oset, map, omap: Avoid imperative voice in documentation.
37450         * lib/gl_list.h: Use descriptive sentences instead of imperative voice
37451         in the specification of functions.
37452         * lib/gl_set.h: Likewise.
37453         * lib/gl_oset.h: Likewise.
37454         * lib/gl_map.h: Likewise.
37455         * lib/gl_omap.h: Likewise.
37456         * lib/gl_*.h: Likewise.
37458 2020-02-01  Bruno Haible  <bruno@clisp.org>
37460         ansi-c++-opt: Set CXXFLAGS to "-g -O2" by default.
37461         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): Determine CXXFLAGS like AC_PROG_CXX
37462         does.
37464 2020-01-29  Bruno Haible  <bruno@clisp.org>
37466         array-map, hash-map, linkedhash-map: Fix module description.
37467         * modules/array-map (Description): Fix description.
37468         * modules/hash-map (Description): Likewise.
37469         * modules/linkedhash-map (Description): Likewise.
37471 2020-01-29  Paul Eggert  <eggert@cs.ucla.edu>
37473         dfa: do not depend on isblank
37474         This removes a difference between Gawk dfa.c and Gnulib dfa.c.
37475         * lib/dfa.c (isblank): Define if neither system nor Gnulib does.
37476         * modules/dfa (Depends-on): Remove isblank.
37477         * modules/isblank: Add a module indicator, for lib/dfa.c.
37479         dfa: do not assume 64-bit int
37480         Problem reported for VAX/VMS C (!) by Arnold Robbins in:
37481         https://lists.gnu.org/r/bug-gnulib/2020-01/msg00173.html
37482         * lib/dfa.c (CHARCLASS_PAIR): Bring back this macro.
37483         (CHARCLASS_WORD_BITS, charclass_word) [!UINT_LEAST64_MAX]:
37484         Fall back to 32-bit words.
37485         (CHARCLASS_INIT): Go back to having 8 32-bit args instead
37486         of 4 64-bit args.  All uses changed.
37488 2020-01-27  Paul Eggert  <eggert@cs.ucla.edu>
37490         regex: remove limits-h dependency
37491         * modules/regex (Depends-on): Remove limits-h, since the
37492         code no longer depends on ULONG_WIDTH already being defined.
37494         regex: port to non-GCC pre-IEC-60559
37495         Problem reported by Arnold Robbins in:
37496         https://lists.gnu.org/r/bug-gnulib/2020-01/msg00154.html
37497         * lib/regex_internal.h (ULONG_WIDTH): Make this usable in #if.
37499 2020-01-25  Bruno Haible  <bruno@clisp.org>
37501         c32isxdigit: Add tests.
37502         * tests/test-c32isxdigit.c: New file, based on tests/test-iswxdigit.c.
37503         * tests/test-c32isxdigit.sh: New file.
37504         * modules/c32isxdigit-tests: New file.
37506         c32isxdigit: New module.
37507         * lib/c32isxdigit.c: New file.
37508         * modules/c32isxdigit: New file.
37509         * doc/posix-functions/iswxdigit.texi: Mention the new module.
37511 2020-01-25  Bruno Haible  <bruno@clisp.org>
37513         c32isupper: Add tests.
37514         * tests/test-c32isupper.c: New file.
37515         * tests/test-c32isupper.sh: New file.
37516         * modules/c32isupper-tests: New file.
37518         c32isupper: New module.
37519         * lib/c32isupper.c: New file.
37520         * modules/c32isupper: New file.
37521         * doc/posix-functions/iswupper.texi: Mention the new module.
37523 2020-01-25  Bruno Haible  <bruno@clisp.org>
37525         c32isspace: Add tests.
37526         * tests/test-c32isspace.c: New file.
37527         * tests/test-c32isspace.sh: New file.
37528         * modules/c32isspace-tests: New file.
37530         c32isspace: New module.
37531         * lib/c32isspace.c: New file.
37532         * modules/c32isspace: New file.
37533         * doc/posix-functions/iswspace.texi: Mention the new module.
37535 2020-01-25  Bruno Haible  <bruno@clisp.org>
37537         c32ispunct: Add tests.
37538         * tests/test-c32ispunct.c: New file.
37539         * tests/test-c32ispunct.sh: New file.
37540         * modules/c32ispunct-tests: New file.
37542         c32ispunct: New module.
37543         * lib/c32ispunct.c: New file.
37544         * modules/c32ispunct: New file.
37545         * doc/posix-functions/iswpunct.texi: Mention the new module.
37547 2020-01-25  Bruno Haible  <bruno@clisp.org>
37549         c32isprint: Add tests.
37550         * tests/test-c32isprint.c: New file.
37551         * tests/test-c32isprint.sh: New file.
37552         * modules/c32isprint-tests: New file.
37554         c32isprint: New module.
37555         * lib/c32isprint.c: New file.
37556         * modules/c32isprint: New file.
37557         * doc/posix-functions/iswprint.texi: Mention the new module.
37559 2020-01-25  Bruno Haible  <bruno@clisp.org>
37561         c32islower: Add tests.
37562         * tests/test-c32islower.c: New file.
37563         * tests/test-c32islower.sh: New file.
37564         * modules/c32islower-tests: New file.
37566         c32islower: New module.
37567         * lib/c32islower.c: New file.
37568         * modules/c32islower: New file.
37569         * doc/posix-functions/iswlower.texi: Mention the new module.
37571 2020-01-25  Bruno Haible  <bruno@clisp.org>
37573         c32isgraph: Add tests.
37574         * tests/test-c32isgraph.c: New file.
37575         * tests/test-c32isgraph.sh: New file.
37576         * modules/c32isgraph-tests: New file.
37578         c32isgraph: New module.
37579         * lib/c32isgraph.c: New file.
37580         * modules/c32isgraph: New file.
37581         * doc/posix-functions/iswgraph.texi: Mention the new module.
37583 2020-01-25  Bruno Haible  <bruno@clisp.org>
37585         c32isdigit: Add tests.
37586         * tests/test-c32isdigit.c: New file, based on tests/test-iswdigit.c.
37587         * tests/test-c32isdigit.sh: New file.
37588         * modules/c32isdigit-tests: New file.
37590         c32isdigit: New module.
37591         * lib/c32isdigit.c: New file.
37592         * modules/c32isdigit: New file.
37593         * doc/posix-functions/iswdigit.texi: Mention the new module.
37595 2020-01-25  Bruno Haible  <bruno@clisp.org>
37597         c32iscntrl: Add tests.
37598         * tests/test-c32iscntrl.c: New file.
37599         * tests/test-c32iscntrl.sh: New file.
37600         * modules/c32iscntrl-tests: New file.
37602         c32iscntrl: New module.
37603         * lib/c32iscntrl.c: New file.
37604         * modules/c32iscntrl: New file.
37605         * doc/posix-functions/iswcntrl.texi: Mention the new module.
37607 2020-01-25  Bruno Haible  <bruno@clisp.org>
37609         c32isblank: Add tests.
37610         * tests/test-c32isblank.c: New file.
37611         * tests/test-c32isblank.sh: New file.
37612         * modules/c32isblank-tests: New file.
37614         c32isblank: New module.
37615         * lib/c32isblank.c: New file.
37616         * modules/c32isblank: New file.
37617         * doc/posix-functions/iswblank.texi: Mention the new module.
37619 2020-01-25  Bruno Haible  <bruno@clisp.org>
37621         c32isalpha: Add tests.
37622         * tests/test-c32isalpha.c: New file.
37623         * tests/test-c32isalpha.sh: New file.
37624         * modules/c32isalpha-tests: New file.
37626         c32isalpha: New module.
37627         * lib/c32isalpha.c: New file.
37628         * modules/c32isalpha: New file.
37629         * doc/posix-functions/iswalpha.texi: Mention the new module.
37631 2020-01-25  Bruno Haible  <bruno@clisp.org>
37633         c32isalnum: Add tests.
37634         * tests/test-c32isalnum.c: New file.
37635         * tests/test-c32isalnum.sh: New file.
37636         * modules/c32isalnum-tests: New file.
37638         c32isalnum: New module.
37639         * lib/c32isalnum.c: New file.
37640         * lib/c32is-impl.h: New file.
37641         * modules/c32isalnum: New file.
37642         * doc/posix-functions/iswalnum.texi: Mention the new module.
37644 2020-01-25  Bruno Haible  <bruno@clisp.org>
37646         uchar: Preparations for modules c32isalnum, ..., c32isxdigit.
37647         * lib/uchar.in.h (c32isalnum, c32isalpha, c32isblank, c32iscntrl,
37648         c32isdigit, c32isgraph, c32islower, c32isprint, c32ispunct, c32isspace,
37649         c32isupper, c32isxdigit): New declarations.
37650         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32ISALNUM,
37651         GNULIB_C32ISALPHA, GNULIB_C32ISBLANK, GNULIB_C32ISCNTRL,
37652         GNULIB_C32ISDIGIT, GNULIB_C32ISGRAPH, GNULIB_C32ISLOWER,
37653         GNULIB_C32ISPRINT, GNULIB_C32ISPUNCT, GNULIB_C32ISSPACE,
37654         GNULIB_C32ISUPPER, GNULIB_C32ISXDIGIT.
37655         * modules/uchar (Makefile.am): Substitute GNULIB_C32ISALNUM,
37656         GNULIB_C32ISALPHA, GNULIB_C32ISBLANK, GNULIB_C32ISCNTRL,
37657         GNULIB_C32ISDIGIT, GNULIB_C32ISGRAPH, GNULIB_C32ISLOWER,
37658         GNULIB_C32ISPRINT, GNULIB_C32ISPUNCT, GNULIB_C32ISSPACE,
37659         GNULIB_C32ISUPPER, GNULIB_C32ISXDIGIT.
37660         * tests/test-uchar-c++.cc: Test the signature of c32isalnum, c32isalpha,
37661         c32isblank, c32iscntrl, c32isdigit, c32isgraph, c32islower, c32isprint,
37662         c32ispunct, c32isspace, c32isupper, c32isxdigit.
37664 2020-01-25  Bruno Haible  <bruno@clisp.org>
37666         mbchar, wctype: Use the corrected iswxdigit function.
37667         * modules/mbchar (Depends-on): Add iswxdigit.
37668         * modules/wctype (Depends-on): Likewise.
37670         iswxdigit: Add tests.
37671         * tests/test-iswxdigit.c: New file.
37672         * tests/test-iswxdigit.sh: New file.
37673         * modules/iswxdigit-tests: New file.
37675         iswxdigit: New module.
37676         * m4/iswxdigit.m4: New file.
37677         * lib/wctype.in.h (iswxdigit): Potentially override.
37678         (iswxdigit, rpl_iswxdigit): Test REPLACE_ISWXDIGIT, not
37679         REPLACE_ISWCNTRL. Rely on ISO C compliant definition.
37680         * lib/iswxdigit.c: New file.
37681         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_ISWXDIGIT,
37682         REPLACE_ISWXDIGIT.
37683         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWXDIGIT,
37684         REPLACE_ISWXDIGIT.
37685         * modules/iswxdigit: New file.
37686         * doc/posix-functions/iswxdigit.texi: Mention the portability problem.
37688 2020-01-25  Bruno Haible  <bruno@clisp.org>
37690         lseek: Fix the override to not undo the effects of AC_SYS_LARGEFILE.
37691         Reported by John Donoghue <john.david.donoghue@gmail.com> in
37692         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00146.html>.
37693         * lib/lseek.c (rpl_lseek): When AC_SYS_LARGEFILE has enabled a 64-bit
37694         off_t on mingw, invoke _lseeki64 instead of lseek.
37696 2020-01-25  Bruno Haible  <bruno@clisp.org>
37698         iswdigit tests: Avoid test failure on Cygwin.
37699         * tests/test-iswdigit.c (for_character): If mbrtowc cannot convert the
37700         byte sequence, return 0.
37702         iswdigit: Fix test failure on native Windows.
37703         * lib/wctype.in.h (rpl_iswdigit): Rely on ISO C compliant definition.
37705         mbchar, wctype: Use the corrected iswdigit function.
37706         * modules/mbchar (Depends-on): Add iswdigit.
37707         * modules/wctype (Depends-on): Likewise.
37709         iswdigit: Add tests.
37710         * tests/test-iswdigit.c: New file.
37711         * tests/test-iswdigit.sh: New file.
37712         * modules/iswdigit-tests: New file.
37714         iswdigit: New module.
37715         * m4/iswdigit.m4: New file.
37716         * lib/wctype.in.h (iswdigit): Potentially override.
37717         (iswdigit, rpl_iswdigit): Test REPLACE_ISWDIGIT, not REPLACE_ISWCNTRL.
37718         * lib/iswdigit.c: New file.
37719         * m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_ISWDIGIT,
37720         REPLACE_ISWDIGIT.
37721         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWDIGIT,
37722         REPLACE_ISWDIGIT.
37723         * modules/iswdigit: New file.
37724         * doc/posix-functions/iswdigit.texi: Mention the portability problem.
37726 2020-01-25  Bruno Haible  <bruno@clisp.org>
37728         hard-locale tests: Make it easy to reuse the musl test.
37729         * m4/musl.m4: New file, extracted from modules/hard-locale-tests.
37730         * modules/hard-locale-tests (Files): Add it.
37731         (configure.ac): Invoke gl_MUSL_LIBC.
37733 2020-01-24  Paul Eggert  <eggert@cs.ucla.edu>
37735         regex: port to Gawk on nonstandard platforms
37736         * lib/regex_internal.h (ULONG_WIDTH): Define if not already defined.
37737         This is useful for Gawk, which does not use the Gnulib stdlib-h
37738         module.  Problem reported by Arnold Robbins in:
37739         https://lists.gnu.org/r/bug-gnulib/2020-01/msg00138.html
37741 2020-01-21  Paul Eggert  <eggert@cs.ucla.edu>
37743         regex: fix bug with >=16 subexpressions
37744         * lib/regex_internal.h (struct re_backref_cache_entry):
37745         Use bitset_word_t as the type of eps_reachable_subexps_map,
37746         instead of unsigned short int.  This fixes a bug I introduced
37747         to glibc in 2005-09-28T17:33:18Z!drepper@redhat.com (glibc commit
37748         2c05d33f90861d074dc12808dafbde30f487b1a0, BZ #1302).
37749         Remove unused member 'unused'.
37751         regex: simplify definition of BITSET_WORD_BITS
37752         * config/srclist.txt: Remove regex.c, regex_internal.h temporarily.
37753         * lib/regex.c (__STDC_WANT_IEC_60559_BFP_EXT__): Define.
37754         * lib/regex_internal.h (BITSET_WORD_BITS):
37755         * modules/regex (Depends-on): Add limits-h.
37756         Simplify now that we can use ULONG_WIDTH.
37758 2020-01-20  Bruno Haible  <bruno@clisp.org>
37760         mbrtoc32: Add note about FreeBSD 12.
37761         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): Guess no also on FreeBSD.
37762         * doc/posix-functions/mbrtoc32.texi: Mention that FreeBSD 12 is also
37763         affected.
37765 2020-01-20  Bruno Haible  <bruno@clisp.org>
37767         unistr/u8-uctomb: Fix warning.
37768         Reported by Andreas Schwab <schwab@suse.de> in
37769         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00127.html>.
37770         * lib/unistr/u8-uctomb.c (FALLTHROUGH): New macro.
37771         (u8_uctomb): Add FALLTHROUGH markers.
37773 2020-01-20  Bruno Haible  <bruno@clisp.org>
37775         lock: Fix test-once1 failure on FreeBSD 11 (regression from 2020-01-19).
37776         * lib/glthread/lock.c (glthread_once_multithreaded): New function.
37777         * lib/glthread/lock.h (glthread_once_multithreaded): New declaration.
37778         (glthread_once): Use it.
37780 2020-01-19  Bruno Haible  <bruno@clisp.org>
37782         threadlib: Disable use of weak symbols on FreeBSD 11.
37783         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
37784         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00061.html>.
37785         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): Require AC_CANONICAL_HOST. Test
37786         against a bug in FreeBSD 11.
37788 2020-01-19  Bruno Haible  <bruno@clisp.org>
37790         iconv_open: Improve z/OS support.
37791         * lib/iconv_open-zos.gperf: Choose better aliases. Add mapping for
37792         ISO-8859-3, KOI8-R, KOI8-U, CP775, CP857, CP865, CP1129, CP1131, CP1257.
37793         Remove mapping for EUC-TW.
37795 2020-01-18  Bruno Haible  <bruno@clisp.org>
37797         Rename ~~gnulib.m4 to zzgnulib.m4.
37798         Suggested by Paul Eggert.
37799         * m4/zzgnulib.m4: Renamed from m4/~~gnulib.m4.
37800         * gnulib-tool (func_get_filelist): Update.
37801         * pygnulib/GLModuleSystem.py (getFiles): Likewise.
37803 2020-01-18  Bruno Haible  <bruno@clisp.org>
37805         doc: Update license notices.
37806         * doc/*.texi: Reference the GFDL 1.3 through a URL, rather than by
37807         reference to a section or to a "file as part of this distribution".
37809 2020-01-18  Bruno Haible  <bruno@clisp.org>
37811         Avoid error "m4_require: circular dependency of AC_LANG_COMPILER(C)".
37812         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se> in
37813         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00109.html>.
37814         * m4/00gnulib.m4 (gl_COMPILER_CLANG): Use _AC_COMPILE_IFELSE, not
37815         AC_EGREP_CPP.
37817 2020-01-18  Bruno Haible  <bruno@clisp.org>
37819         Ensure Automake does not drop ~~gnulib.m4.
37820         * m4/~~gnulib.m4 (gl_ZZGNULIB): New macro.
37821         * m4/gnulib-common.m4 (gl_COMMON): Require it.
37823 2020-01-18  Bruno Haible  <bruno@clisp.org>
37825         Fix major regression from 2020-01-10.
37826         Reported by Paul Eggert in
37827         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00079.html>.
37828         * m4/00gnulib.m4 (gl_COMPILER_CLANG, gl_COMPILER_PREPARE_CHECK_DECL):
37829         Don't AC_REQUIRE anything.
37830         (gl_COMPILER_PREPARE_CHECK_DECL): Define through AC_DEFUN, not
37831         AC_DEFUN_ONCE. Use _AC_COMPILE_IFELSE, not AC_COMPILE_IFELSE.
37832         (_AC_CHECK_DECL_BODY): If ac_compile_for_check_decl has not been set,
37833         use ac_compile instead.
37834         (AC_CHECK_DECL): Remove override.
37835         * m4/~~gnulib.m4: New file.
37836         * gnulib-tool (func_get_filelist): Add also ~~gnulib.m4.
37837         * pygnulib/GLModuleSystem.py (getFiles): Likewise.
37839 2020-01-17  Bruno Haible  <bruno@clisp.org>
37840             Paul Eggert  <eggert@cs.ucla.edu>
37842         glob: Fix use-after-free bug.
37843         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
37844         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00102.html>.
37845         * lib/glob.c (__glob): Delay freeing dirname until after the use of
37846         end_name.
37848 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
37850         vcs-to-changelog: Fix parsing of fndecl without args.
37851         * build-aux/vcstocl/frontend_c.py (FNDECL_RE): Fix regular expression
37852         for empty arguments.
37854 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
37856         vcs-to-changelog: Add documentation.
37857         * doc/vcs-to-changelog.texi: New file.
37858         * doc/gnulib.texi (Build Infrastructure Modules): Add vcs-to-changelog
37859         section.
37861 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
37863         vcs-to-changelog: Allow loading of custom quirks file.
37864         * build-aux/vcs_to_changelog.py: New commandline option -q.
37866 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
37868         vcs-to-changelog: Fix formatting of ChangeLog output.
37869         * build-aux/vcstocl/vcs_git.py (list_changes): Add newline in print
37870         output.
37872 2020-01-16  Siddhesh Poyarekar  <siddhesh@gotplt.org>
37874         vcs-to-changelog: Drop python3 shebang from frontend_c.py.
37875         Reported in
37876         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00050.html>.
37877         * build-aux/vcstocl/frontend_c.py: Remove shebang.
37879 2020-01-15  Simon Josefsson  <simon@josefsson.org>
37881         crypto/gc-pbkdf2: New module.
37882         * MODULES.html.sh (func_all_modules): Add gc-pbkdf2.
37883         * NEWS: Deprecated gc-pbkdf2-sha1 in favor of gc-pbkdf2.
37884         * lib/gc-pbkdf2.c: New file.
37885         * lib/gc-pbkdf2-sha1.c: Use new interface.
37886         * lib/gc.h (GC_MAX_DIGEST_SIZE, gc_pbkdf2_hmac): Add.
37887         * modules/crypto/gc-pbkdf2: New file.
37888         * modules/crypto/gc-pbkdf2-tests: New file.
37889         * tests/test-gc-pbkdf2.c: New file.
37891 2020-01-12  Bruno Haible  <bruno@clisp.org>
37893         c32stombs: Add tests.
37894         * tests/test-c32stombs.c: New file, based on tests/test-c32srtombs.c.
37895         * tests/test-c32stombs-1.sh: New file, based on
37896         tests/test-c32srtombs-1.sh.
37897         * tests/test-c32stombs-2.sh: New file, based on
37898         tests/test-c32srtombs-2.sh.
37899         * tests/test-c32stombs-3.sh: New file, based on
37900         tests/test-c32srtombs-3.sh.
37901         * tests/test-c32stombs-4.sh: New file, based on
37902         tests/test-c32srtombs-4.sh.
37903         * modules/c32stombs-tests: New file, based on modules/c32srtombs-tests.
37905         c32stombs: New module.
37906         * lib/uchar.in.h (c32stombs): New declaration.
37907         * lib/c32stombs.c: New file.
37908         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32STOMBS.
37909         * modules/uchar (Makefile.am): Substitute GNULIB_C32STOMBS.
37910         * modules/c32stombs: New file.
37911         * tests/test-uchar-c++.cc: Test the signature of c32stombs.
37912         * doc/posix-functions/wcstombs.texi: Mention the new module.
37914 2020-01-11  Jim Meyering  <meyering@fb.com>
37916         perl: require the "warnings" module
37917         * m4/perl.m4: Also "use warnings", so we reject the perl found
37918         on at least one IRIX 6.5 system. Reported by Bruno Haible in
37919         https://lists.gnu.org/r/sed-devel/2020-01/msg00004.html
37921 2020-01-10  Bruno Haible  <bruno@clisp.org>
37923         Fix major regression from 2020-01-04.
37924         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se> in
37925         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00072.html>.
37926         * m4/00gnulib.m4 (gl_COMPILER_PREPARE_CHECK_DECL): Define through
37927         AC_DEFUN_ONCE.
37928         (AC_CHECK_DECL): Invoke, not require, it.
37930 2020-01-10  Bruno Haible  <bruno@clisp.org>
37932         c32snrtombs: Add tests.
37933         * tests/test-c32snrtombs.c: New file, based on tests/test-wcsnrtombs.c.
37934         * tests/test-c32snrtombs-1.sh: New file, based on
37935         tests/test-wcsnrtombs1.sh.
37936         * tests/test-c32snrtombs-2.sh: New file, based on
37937         tests/test-wcsnrtombs2.sh.
37938         * tests/test-c32snrtombs-3.sh: New file, based on
37939         tests/test-wcsnrtombs3.sh.
37940         * tests/test-c32snrtombs-4.sh: New file, based on
37941         tests/test-wcsnrtombs4.sh.
37942         * modules/c32snrtombs-tests: New file, based on
37943         modules/wcsnrtombs-tests.
37945         c32snrtombs: New module.
37946         * lib/uchar.in.h (c32snrtombs): New declaration.
37947         * lib/wcsnrtombs-impl.h: Parameterize: Use macros FUNC, SCHAR_T,
37948         INTERNAL_STATE, WCRTOMB.
37949         * lib/wcsnrtombs.c (FUNC, SCHAR_T, INTERNAL_STATE, WCRTOMB): New macros.
37950         * lib/c32snrtombs.c: New file.
37951         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32SNRTOMBS.
37952         * modules/uchar (Makefile.am): Substitute GNULIB_C32SNRTOMBS.
37953         * modules/c32snrtombs: New file.
37954         * tests/test-uchar-c++.cc: Test the signature of c32snrtombs.
37955         * doc/posix-functions/wcsnrtombs.texi: Mention the new module.
37957 2020-01-09  Bruno Haible  <bruno@clisp.org>
37959         c32srtombs: Add tests.
37960         * tests/test-c32srtombs.c: New file, based on tests/test-wcsrtombs.c.
37961         * tests/test-c32srtombs-1.sh: New file, based on
37962         tests/test-wcsrtombs1.sh.
37963         * tests/test-c32srtombs-2.sh: New file, based on
37964         tests/test-wcsrtombs2.sh.
37965         * tests/test-c32srtombs-3.sh: New file, based on
37966         tests/test-wcsrtombs3.sh.
37967         * tests/test-c32srtombs-4.sh: New file, based on
37968         tests/test-wcsrtombs4.sh.
37969         * modules/c32srtombs-tests: New file, based on modules/wcsrtombs-tests.
37971         c32srtombs: New module.
37972         * lib/uchar.in.h (c32srtombs): New declaration.
37973         * lib/wcsrtombs-impl.h: Parameterize: Use macros FUNC, SCHAR_T,
37974         INTERNAL_STATE, WCRTOMB.
37975         * lib/wcsrtombs.c (FUNC, SCHAR_T, INTERNAL_STATE, WCRTOMB): New macros.
37976         * lib/c32srtombs.c: New file.
37977         * lib/c32srtombs-state.c: New file, based on lib/wcsrtombs-state.c.
37978         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32SRTOMBS.
37979         * modules/uchar (Makefile.am): Substitute GNULIB_C32SRTOMBS.
37980         * modules/c32srtombs: New file.
37981         * tests/test-uchar-c++.cc: Test the signature of c32srtombs.
37982         * doc/posix-functions/wcsrtombs.texi: Mention the new module.
37984 2020-01-08  Bruno Haible  <bruno@clisp.org>
37986         c32tob: Make consistent with mbrtoc32.
37987         * lib/c32tob.c: Include <stdio.h>, <string.h>, <wchar.h>.
37988         (c32tob): If the char32_t encoding and the wchar_t encoding may differ,
37989         use c32rtomb, not wctob.
37990         * modules/c32tob (Files): Add m4/mbrtoc32.m4.
37991         (Depends-on): Add c32rtomb.
37992         (configure.ac): Require gl_MBRTOC32_SANITYCHECK.
37994 2020-01-08  Bruno Haible  <bruno@clisp.org>
37996         c32rtomb: Add tests.
37997         * tests/test-c32rtomb.c: New file, based on tests/test-wcrtomb.c.
37998         * tests/test-c32rtomb.sh: New file, based on tests/test-wcrtomb.sh.
37999         * tests/test-c32rtomb-w32.c: New file, based on
38000         tests/test-wcrtomb-w32.c.
38001         * tests/test-c32rtomb-w32-1.sh: New file, based on
38002         tests/test-wcrtomb-w32-1.sh.
38003         * tests/test-c32rtomb-w32-2.sh: New file, based on
38004         tests/test-wcrtomb-w32-2.sh.
38005         * tests/test-c32rtomb-w32-3.sh: New file, based on
38006         tests/test-wcrtomb-w32-3.sh.
38007         * tests/test-c32rtomb-w32-4.sh: New file, based on
38008         tests/test-wcrtomb-w32-4.sh.
38009         * tests/test-c32rtomb-w32-5.sh: New file, based on
38010         tests/test-wcrtomb-w32-5.sh.
38011         * tests/test-c32rtomb-w32-6.sh: New file, based on
38012         tests/test-wcrtomb-w32-6.sh.
38013         * tests/test-c32rtomb-w32-7.sh: New file, based on
38014         tests/test-wcrtomb-w32-7.sh.
38015         * modules/c32rtomb-tests: New file.
38017         c32rtomb: New module.
38018         * lib/uchar.in.h (c32rtomb): New declaration.
38019         * lib/c32rtomb.c: New file, based on lib/unistr/u8-uctomb-aux.c.
38020         * m4/c32rtomb.m4: New file.
38021         * m4/uchar.m4 (gl_UCHAR_H): Test whether c32rtomb is declared.
38022         (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_C32RTOMB, HAVE_C32RTOMB,
38023         REPLACE_C32RTOMB.
38024         * modules/uchar (Makefile.am): Substitute GNULIB_C32RTOMB,
38025         HAVE_C32RTOMB, REPLACE_C32RTOMB.
38026         * modules/c32rtomb: New file.
38027         * tests/test-uchar-c++.cc: Test the signature of c32rtomb.
38028         * doc/posix-functions/c32rtomb.texi: Document the new module.
38029         * doc/posix-functions/wcrtomb.texi: Mention the new module.
38031 2020-01-08  Bruno Haible  <bruno@clisp.org>
38033         mbrtoc32: Use the system's mbrtoc32 if it exists and basically works.
38034         * m4/mbrtoc32.m4 (gl_MBRTOC32_SANITYCHECK): New macro.
38035         (gl_FUNC_MBRTOC32): Require it. Set REPLACE_MBRTOC32 if mbrtoc32 exists
38036         but is not working.
38037         * lib/mbrtoc32.c: Include hard-locale.h, <locale.h>.
38038         (mbrtoc32): If the char32_t encoding and the wchar_t encoding may
38039         differ, use the system's mbrtoc32, adding workarounds.
38040         * modules/mbrtoc32 (Depends-on): Add hard-locale.
38041         * doc/posix-functions/mbrtoc32.texi: Mention the Solaris and native
38042         Windows problem.
38043         * lib/btoc32.c: Include <stdio.h>, <string.h>.
38044         (btoc32): If the char32_t encoding and the wchar_t encoding may differ,
38045         use mbrtoc32, not btowc.
38046         * modules/btoc32 (Depends-on): Add mbrtoc32.
38047         * lib/mbsrtoc32s.c (mbsrtoc32s): If the char32_t encoding and the
38048         wchar_t encoding may differ, use mbrtoc32, not mbsrtowcs.
38049         * modules/mbsrtoc32s (Depends-on): Update conditions.
38050         (configure.ac): Compile mbsrtoc32s-state.c unconditionally.
38051         * lib/mbsnrtoc32s.c (mbsnrtoc32s): If the char32_t encoding and the
38052         wchar_t encoding may differ, use mbrtoc32, not mbsnrtowcs.
38053         * modules/mbsnrtoc32s (Depends-on): Update conditions.
38054         (configure.ac): Compile mbsrtoc32s-state.c unconditionally.
38056 2020-01-07  Bruno Haible  <bruno@clisp.org>
38058         wcrtomb: Make multithread-safe, except possibly on IRIX.
38059         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Don't set REPLACE_WCRTOMB to 1 when
38060         REPLACE_MBSTATE_T is set. Define WCRTOMB_C_LOCALE_BUG and
38061         WCRTOMB_RETVAL_BUG.
38062         * lib/wcrtomb.c (wcrtomb): Use original wcrtomb whenever available. Use
38063         wctomb only on IRIX.
38065 2020-01-05  Jim Meyering  <meyering@fb.com>
38067         tests: skip thread-using tests when threading is disabled
38068         sed's configure.ac specifies gl_DISABLE_THREADS, and that caused three
38069         thread-using gnulib tests to fail. Add an #if-guarded exit (77) to each
38070         of those, so they are skipped in this case.
38071         * tests/test-nl_langinfo-mt.c (main): Exit 77 when threading is disabled.
38072         * tests/test-setlocale_null-mt-all.c (main): Likewise.
38073         * tests/test-setlocale_null-mt-one.c (main): Likewise.
38075 2020-01-05  Bruno Haible  <bruno@clisp.org>
38077         tests: Avoid GCC over-optimization caused by _GL_ARG_NONNULL attributes.
38078         Reported by Jim Meyering in
38079         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00040.html>.
38080         * lib/stdlib.in.h (GNULIB_defined_canonicalize_file_name): New macro.
38081         (GNULIB_defined_ptsname_r): New macro.
38082         * tests/test-canonicalize.c (_GL_ARG_NONNULL): Define to empty.
38083         (main): Disable the NULL argument test if canonicalize_file_name does
38084         not come from gnulib.
38085         * tests/test-canonicalize-lgpl.c (_GL_ARG_NONNULL): Define to empty.
38086         (main): Disable the NULL argument test if canonicalize_file_name does
38087         not come from gnulib.
38088         * tests/test-ptsname_r.c (_GL_ARG_NONNULL): Define to empty.
38089         (test_errors): Disable the NULL argument test if ptsname_r does not come
38090         from gnulib.
38092 2020-01-04  Jim Meyering  <meyering@fb.com>
38094         update-copyright: reenable its always-skipped test
38095         * tests/test-update-copyright.sh: Restore the "-pi" options removed
38096         on 2019-06-15. Without those, an internal preliminary test would
38097         fail, causing this test always to be skipped.
38098         Verify that the test is now run and passes via this:
38099           ./gnulib-tool --test --dir /tmp/x --with-tests update-copyright
38101 2020-01-05  Bruno Haible  <bruno@clisp.org>
38103         mbstoc32s: Add tests.
38104         * tests/test-mbstoc32s.c: New file, based on tests/test-mbsrtoc32s.c.
38105         * tests/test-mbstoc32s-1.sh: New file, based on
38106         tests/test-mbsrtoc32s-1.sh.
38107         * tests/test-mbstoc32s-2.sh: New file, based on
38108         tests/test-mbsrtoc32s-2.sh.
38109         * tests/test-mbstoc32s-3.sh: New file, based on
38110         tests/test-mbsrtoc32s-3.sh.
38111         * tests/test-mbstoc32s-4.sh: New file, based on
38112         tests/test-mbsrtoc32s-4.sh.
38113         * modules/mbstoc32s-tests: New file, based on modules/mbsrtoc32s-tests.
38115         mbstoc32s: New module.
38116         * lib/uchar.in.h (mbstoc32s): New declaration.
38117         * lib/mbstoc32s.c: New file.
38118         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBSTOC32S.
38119         * modules/uchar (Makefile.am): Substitute GNULIB_MBSTOC32S.
38120         * modules/mbstoc32s: New file.
38121         * tests/test-uchar-c++.cc: Test the signature of mbstoc32s.
38122         * doc/posix-functions/mbstowcs.texi: Mention the new module.
38124 2020-01-05  Bruno Haible  <bruno@clisp.org>
38126         Tweak recently added tests.
38127         * tests/test-mbrtoc32.c: Make signature consistent with uchar.in.h.
38128         * tests/test-mbsrtoc32s.c: Likewise.
38129         * tests/test-mbsnrtoc32s.c: Likewise.
38131 2020-01-04  Bruno Haible  <bruno@clisp.org>
38133         mbsnrtoc32s: Add tests.
38134         * tests/test-mbsnrtoc32s.c: New file, based on tests/test-mbsnrtowcs.c.
38135         * tests/test-mbsnrtoc32s-1.sh: New file, based on
38136         tests/test-mbsnrtowcs1.sh.
38137         * tests/test-mbsnrtoc32s-2.sh: New file, based on
38138         tests/test-mbsnrtowcs2.sh.
38139         * tests/test-mbsnrtoc32s-3.sh: New file, based on
38140         tests/test-mbsnrtowcs3.sh.
38141         * tests/test-mbsnrtoc32s-4.sh: New file, based on
38142         tests/test-mbsnrtowcs4.sh.
38143         * modules/mbsnrtoc32s-tests: New file, based on
38144         modules/mbsnrtowcs-tests.
38146         mbsnrtoc32s: New module.
38147         * lib/uchar.in.h (mbsnrtoc32s): New declaration.
38148         * lib/mbsnrtowcs-impl.h: Parameterize: Use macros FUNC, DCHAR_T,
38149         INTERNAL_STATE, MBRTOWC.
38150         * lib/mbsnrtowcs.c (FUNC, DCHAR_T, INTERNAL_STATE, MBRTOWC): New macros.
38151         * lib/mbsnrtoc32s.c: New file.
38152         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBSNRTOC32S.
38153         * modules/uchar (Makefile.am): Substitute GNULIB_MBSNRTOC32S.
38154         * modules/mbsnrtoc32s: New file.
38155         * tests/test-uchar-c++.cc: Test the signature of mbsnrtoc32s.
38156         * doc/posix-functions/mbsnrtowcs.texi: Mention the new module.
38158 2020-01-04  Bruno Haible  <bruno@clisp.org>
38160         mbsrtoc32s tests: Enhance test.
38161         * tests/test-mbsrtoc32s.c (main): Include a non-BMP character in the
38162         test strings for UTF-8 and GB18030.
38164 2020-01-04  Bruno Haible  <bruno@clisp.org>
38166         mbsrtoc32s: Fix bug.
38167         * modules/mbsrtoc32s (configure.ac): Require gl_UCHAR_H, to make sure
38168         that SMALL_WCHAR_T is defined.
38170 2020-01-04  Bruno Haible  <bruno@clisp.org>
38172         mbsrtoc32s: Add tests.
38173         * tests/test-mbsrtoc32s.c: New file, based on tests/test-mbsrtowcs.c.
38174         * tests/test-mbsrtoc32s-1.sh: New file, based on
38175         tests/test-mbsrtowcs1.sh.
38176         * tests/test-mbsrtoc32s-2.sh: New file, based on
38177         tests/test-mbsrtowcs2.sh.
38178         * tests/test-mbsrtoc32s-3.sh: New file, based on
38179         tests/test-mbsrtowcs3.sh.
38180         * tests/test-mbsrtoc32s-4.sh: New file, based on
38181         tests/test-mbsrtowcs4.sh.
38182         * modules/mbsrtoc32s-tests: New file, based on modules/mbsrtowcs-tests.
38184         mbsrtoc32s: New module.
38185         * lib/uchar.in.h (mbsrtoc32s): New declaration.
38186         * lib/mbsrtowcs-impl.h: Parameterize: Use macros FUNC, DCHAR_T,
38187         INTERNAL_STATE, MBRTOWC.
38188         * lib/mbsrtowcs.c (FUNC, DCHAR_T, INTERNAL_STATE, MBRTOWC): New macros.
38189         * lib/mbsrtoc32s.c: New file.
38190         * lib/mbsrtoc32s-state.c: New file, based on lib/mbsrtowcs-state.c.
38191         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBSRTOC32S.
38192         * modules/uchar (Makefile.am): Substitute GNULIB_MBSRTOC32S.
38193         * modules/mbsrtoc32s: New file.
38194         * tests/test-uchar-c++.cc: Test the signature of mbsrtoc32s.
38195         * doc/posix-functions/mbsrtowcs.texi: Mention the new module.
38197 2020-01-04  Bruno Haible  <bruno@clisp.org>
38199         mbrtowc, mbrtoc32: Tighten dependendies.
38200         * modules/mbrtowc (Depends-on): Disable hard-locale, mbsinit if
38201         REPLACE_MBSTATE_T is 1.
38202         (configure.ac): Don't compile lc-charset-dispatch.c and mbtowc-lock.c if
38203         REPLACE_MBSTATE_T is 0.
38204         * modules/mbrtoc32 (Depends-on): Remove hard-locale, mbsinit. Disable
38205         mbrtowc dependency if REPLACE_MBSTATE_T is 1.
38206         (configure.ac): Don't compile lc-charset-dispatch.c and mbtowc-lock.c if
38207         REPLACE_MBSTATE_T is 0.
38209 2020-01-04  Bruno Haible  <bruno@clisp.org>
38211         uchar: Decide about _GL_LARGE_CHAR32_T at configure time.
38212         * m4/uchar.m4 (gl_UCHAR_H): Set SMALL_WCHAR_T.
38213         * modules/uchar (Files): Add stdint.m4.
38214         (Makefile.am): Substitute SMALL_WCHAR_T.
38215         * lib/uchar.in.h (_GL_LARGE_CHAR32_T): Rely on SMALL_WCHAR_T.
38217 2020-01-04  Bruno Haible  <bruno@clisp.org>
38219         Fix AC_CHECK_DECL so that it deactivates clang's built-in declarations.
38220         Reported by Martin Storsjö <martin@martin.st> in
38221         <https://lists.gnu.org/archive/html/bug-gnulib/2020-01/msg00016.html>.
38222         * m4/00gnulib.m4 (gl_COMPILER_CLANG, gl_COMPILER_PREPARE_CHECK_DECL):
38223         New macros.
38224         (_AC_CHECK_DECL_BODY, AC_CHECK_DECL): Augment.
38226 2020-01-04  Bruno Haible  <bruno@clisp.org>
38228         btoc32: Add tests.
38229         * tests/test-btoc32.c: New file, based on tests/test-btowc.c.
38230         * tests/test-btoc32-1.sh: New file, based on tests/test-btowc1.sh.
38231         * tests/test-btoc32-2.sh: New file, based on tests/test-btowc2.sh.
38232         * modules/btoc32-tests: New file, based on modules/btowc-tests.
38234         btoc32: New module.
38235         * lib/uchar.in.h (btoc32): New declaration.
38236         * lib/btoc32.c: New file.
38237         * m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_BTOC32.
38238         * modules/uchar (Makefile.am): Substitute GNULIB_BTOC32.
38239         * modules/btoc32: New file.
38240         * tests/test-uchar-c++.cc: Test the signature of btoc32.
38241         * doc/posix-functions/btowc.texi: Mention the new module.
38243 2020-01-03  Bruno Haible  <bruno@clisp.org>
38245         uchar tests: Avoid compilation error with HP cc.
38246         * tests/test-uchar.c: Disable a test when HP cc is in use.
38248 2020-01-03  Bruno Haible  <bruno@clisp.org>
38250         mbrtoc32: Add tests.
38251         * tests/test-mbrtoc32.c: New file, based on tests/test-mbrtowc.c.
38252         * tests/test-mbrtoc32-1.sh: New file, based on tests/test-mbrtowc1.sh.
38253         * tests/test-mbrtoc32-2.sh: New file, based on tests/test-mbrtowc2.sh.
38254         * tests/test-mbrtoc32-3.sh: New file, based on tests/test-mbrtowc3.sh.
38255         * tests/test-mbrtoc32-4.sh: New file, based on tests/test-mbrtowc4.sh.
38256         * tests/test-mbrtoc32-5.sh: New file, based on tests/test-mbrtowc5.sh.
38257         * tests/test-mbrtoc32-w32.c: New file, based on tests/test-mbrtowc-w32.c.
38258         * tests/test-mbrtoc32-w32-1.sh: New file, based on
38259         tests/test-mbrtowc-w32-1.sh.
38260         * tests/test-mbrtoc32-w32-2.sh: New file, based on
38261         tests/test-mbrtowc-w32-2.sh.
38262         * tests/test-mbrtoc32-w32-3.sh: New file, based on
38263         tests/test-mbrtowc-w32-3.sh.
38264         * tests/test-mbrtoc32-w32-4.sh: New file, based on
38265         tests/test-mbrtowc-w32-4.sh.
38266         * tests/test-mbrtoc32-w32-5.sh: New file, based on
38267         tests/test-mbrtowc-w32-5.sh.
38268         * tests/test-mbrtoc32-w32-6.sh: New file, based on
38269         tests/test-mbrtowc-w32-6.sh.
38270         * tests/test-mbrtoc32-w32-7.sh: New file, based on
38271         tests/test-mbrtowc-w32-7.sh.
38272         * modules/mbrtoc32-tests: New file, based on modules/mbrtowc-tests.
38274         mbrtoc32: New module.
38275         * lib/uchar.in.h (mbrtoc32): New declaration.
38276         * lib/mbrtoc32.c: New file, based on lib/mbrtowc.c.
38277         * m4/mbrtoc32.m4: New file, based on m4/mbrtowc.m4.
38278         * m4/uchar.m4 (gl_UCHAR_H): Test whether mbrtoc32 is declared.
38279         (gl_UCHAR_H_DEFAULTS): Initialize GNULIB_MBRTOC32, HAVE_MBRTOC32,
38280         REPLACE_MBRTOC32.
38281         * modules/uchar (Makefile.am): Substitute GNULIB_MBRTOC32,
38282         HAVE_MBRTOC32, REPLACE_MBRTOC32.
38283         * modules/mbrtoc32: New file, based on modules/mbrtowc.
38284         * tests/test-uchar-c++.cc (mbrtoc32): Verify the signature.
38285         * modules/uchar-c++-tests (Makefile.am): Link test-uchar-c++ with
38286         $(LIB_MBRTOWC).
38287         * doc/posix-functions/mbrtoc32.texi: Document the new module.
38288         * doc/posix-functions/mbrtowc.texi: Mention the new module.
38290 2020-01-03  Bruno Haible  <bruno@clisp.org>
38292         mbrtowc: Refactor to share code with mbrtoc32.
38293         * lib/mbrtowc-impl.h: New file, extracted from lib/mbrtowc.c.
38294         * lib/mbrtowc-impl-utf8.h: Likewise.
38295         * lib/mbrtowc.c (mbrtowc): Define macro FITS_IN_CHAR_TYPE. Include
38296         mbrtowc-impl.h.
38297         * modules/mbrtowc (Files): Add the new files.
38299 2020-01-03  Jim Meyering  <meyering@fb.com>
38301         doc: fix time.texi wording
38302         * doc/posix-headers/time.texi (time.h): Typo.
38304 2020-01-03  Bruno Haible  <bruno@clisp.org>
38306         mbrtowc: Refactor locale charset dispatching.
38307         * lib/lc-charset-dispatch.h: New file, extracted from lib/mbrtowc.c.
38308         * lib/lc-charset-dispatch.c: New file, extracted from lib/mbrtowc.c.
38309         * lib/mbrtowc.c: Include lc-charset-dispatch.h. Don't include
38310         localcharset.h, streq.h.
38311         (enc_t): Remove type.
38312         (locale_enc): Remove function.
38313         (cached_locale_enc): Remove variable.
38314         (locale_enc_cached): Remove function.
38315         (mbrtowc): Invoke locale_encoding_classification.
38316         * m4/mbrtowc.m4 (gl_PREREQ_MBRTOWC): Update comment.
38317         * modules/mbrtowc (Files): Add lc-charset-dispatch.h,
38318         lc-charset-dispatch.c.
38319         (configure.ac): Arrange to compile lc-charset-dispatch.c.
38321 2020-01-03  Paul Eggert  <eggert@cs.ucla.edu>
38323         doc: mention 32-bit time_t issue
38324         * doc/posix-headers/sys_stat.texi (sys/stat.h):
38325         * doc/posix-headers/time.texi (time.h): Mention 2038.
38327 2020-01-03  Bruno Haible  <bruno@clisp.org>
38329         mbrtowc: Ensure the mbtowc_lock is unique.
38330         * lib/mbtowc-lock.c: New file, based on lib/setlocale-lock.c.
38331         * lib/mbtowc-lock.h: New file, extracted from lib/mbrtowc.c and
38332         lib/setlocale_null.c.
38333         * lib/mbrtowc.c: Include headers needed for mbtowc-lock.h. Don't include
38334         glthread/lock.h. Include mbtowc-lock.h.
38335         (mbtowc_lock): Remove declaration.
38336         (mbrtowc): Use mbtowc_with_lock.
38337         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Require gl_PTHREADLIB. Check for
38338         threads.h. Set LIB_MBRTOWC.
38339         (gl_PREREQ_MBTOWC_LOCK): New macro.
38340         * modules/mbrtowc (Files): Add lib/mbtowc-lock.h, lib/mbtowc-lock.c,
38341         lib/windows-initguard.h, m4/threadlib.m4, m4/visibility.m4.
38342         (Depends-on): Remove lock.
38343         (configure.ac): Arrange to compile mbtowc-lock.c.
38344         (Link): Mention $(LIB_MBRTOWC) instead of $(LIBTHREAD).
38345         * modules/acl (Link): Likewise.
38346         * modules/argmatch (Link): Likewise.
38347         * modules/backup-rename (Link): Likewise.
38348         * modules/backupfile (Link): Likewise.
38349         * modules/closein (Link): Likewise.
38350         * modules/closeout (Link): Likewise.
38351         * modules/copy-file (Link): Likewise.
38352         * modules/csharpcomp (Link): Likewise.
38353         * modules/csharpexec (Link): Likewise.
38354         * modules/dfa (Link): Likewise.
38355         * modules/exclude (Link): Likewise.
38356         * modules/fnmatch (Link): Likewise.
38357         * modules/fnmatch-gnu (Link): Likewise.
38358         * modules/fnmatch-posix (Link): Likewise.
38359         * modules/glob (Link): Likewise.
38360         * modules/human (Link): Likewise.
38361         * modules/javacomp (Link): Likewise.
38362         * modules/javaexec (Link): Likewise.
38363         * modules/javaversion (Link): Likewise.
38364         * modules/mbfile (Link): Likewise.
38365         * modules/mbiter (Link): Likewise.
38366         * modules/mbmemcasecmp (Link): Likewise.
38367         * modules/mbmemcasecoll (Link): Likewise.
38368         * modules/mbrlen (Link): Likewise.
38369         * modules/mbscasecmp (Link): Likewise.
38370         * modules/mbscasestr (Link): Likewise.
38371         * modules/mbschr (Link): Likewise.
38372         * modules/mbscspn (Link): Likewise.
38373         * modules/mbsinit (Link): Likewise.
38374         * modules/mbslen (Link): Likewise.
38375         * modules/mbsncasecmp (Link): Likewise.
38376         * modules/mbsnlen (Link): Likewise.
38377         * modules/mbsnrtowcs (Link): Likewise.
38378         * modules/mbspbrk (Link): Likewise.
38379         * modules/mbspcasecmp (Link): Likewise.
38380         * modules/mbsrchr (Link): Likewise.
38381         * modules/mbsrtowcs (Link): Likewise.
38382         * modules/mbssep (Link): Likewise.
38383         * modules/mbsspn (Link): Likewise.
38384         * modules/mbsstr (Link): Likewise.
38385         * modules/mbstok_r (Link): Likewise.
38386         * modules/mbswidth (Link): Likewise.
38387         * modules/mbuiter (Link): Likewise.
38388         * modules/mkdir-p (Link): Likewise.
38389         * modules/propername (Link): Likewise.
38390         * modules/quote (Link): Likewise.
38391         * modules/quotearg (Link): Likewise.
38392         * modules/quotearg-simple (Link): Likewise.
38393         * modules/regex-quote (Link): Likewise.
38394         * modules/rpmatch (Link): Likewise.
38395         * modules/sh-quote (Link): Likewise.
38396         * modules/system-quote (Link): Likewise.
38397         * modules/trim (Link): Likewise.
38398         * modules/unistdio/ulc-asnprintf (Link): Likewise.
38399         * modules/unistdio/ulc-fprintf (Link): Likewise.
38400         * modules/unistdio/ulc-vasnprintf (Link): Likewise.
38401         * modules/unistdio/ulc-vasprintf (Link): Likewise.
38402         * modules/unistdio/ulc-vfprintf (Link): Likewise.
38403         * modules/unistdio/ulc-vsnprintf (Link): Likewise.
38404         * modules/unistdio/ulc-vsprintf (Link): Likewise.
38405         * modules/xfreopen (Link): Likewise.
38406         * modules/xmemcoll (Link): Likewise.
38407         * modules/yesno (Link): Likewise.
38408         * modules/regex (Link): Add $(LIB_MBRTOWC).
38409         * modules/acl-tests (Makefile.am): Link the programs with $(LIB_MBRTOWC)
38410         instead of $(LIBTHREAD).
38411         * modules/argmatch-tests (Makefile.am): Likewise.
38412         * modules/closein-tests (Makefile.am): Likewise.
38413         * modules/copy-file-tests (Makefile.am): Likewise.
38414         * modules/dfa-tests (Makefile.am): Likewise.
38415         * modules/fnmatch-tests (Makefile.am): Likewise.
38416         * modules/glob-tests (Makefile.am): Likewise.
38417         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
38418         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
38419         * modules/mbrtowc-tests (Makefile.am): Likewise.
38420         * modules/mbscasecmp-tests (Makefile.am): Likewise.
38421         * modules/mbscasestr-tests (Makefile.am): Likewise.
38422         * modules/mbschr-tests (Makefile.am): Likewise.
38423         * modules/mbscspn-tests (Makefile.am): Likewise.
38424         * modules/mbsinit-tests (Makefile.am): Likewise.
38425         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
38426         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
38427         * modules/mbspbrk-tests (Makefile.am): Likewise.
38428         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
38429         * modules/mbsrchr-tests (Makefile.am): Likewise.
38430         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
38431         * modules/mbsspn-tests (Makefile.am): Likewise.
38432         * modules/mbsstr-tests (Makefile.am): Likewise.
38433         * modules/quotearg-simple-tests (Makefile.am): Likewise.
38434         * modules/quotearg-tests (Makefile.am): Likewise.
38435         * modules/readtokens-tests (Makefile.am): Likewise.
38436         * modules/sh-quote-tests (Makefile.am): Likewise.
38437         * modules/system-quote-tests (Makefile.am): Likewise.
38438         * modules/unistdio/ulc-asnprintf-tests (Makefile.am): Likewise.
38439         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
38440         * modules/unistdio/ulc-vasprintf-tests (Makefile.am): Likewise.
38441         * modules/unistdio/ulc-vsnprintf-tests (Makefile.am): Likewise.
38442         * modules/unistdio/ulc-vsprintf-tests (Makefile.am): Likewise.
38443         * modules/yesno-tests (Makefile.am): Likewise.
38444         * modules/exclude-tests (Makefile.am): Link the programs with
38445         $(LIB_MBRTOWC).
38446         * modules/regex-tests (Makefile.am): Likewise.
38447         * modules/regex-quote-tests (Makefile.am): Likewise.
38449 2020-01-03  Bruno Haible  <bruno@clisp.org>
38451         getopt-posix: Fix compilation failure in testdirs.
38452         * lib/unistd.in.h: Include <getopt-cdefs.h> and <getopt-pfx-core.h> only
38453         when the gnulib module 'getopt-posix' is enabled.
38454         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETOPT_POSIX.
38455         * modules/getopt-posix (configure.ac): Set GNULIB_GETOPT_POSIX as a
38456         module indicator.
38457         * modules/unistd (Makefile.am): Substitute GNULIB_GETOPT_POSIX.
38459 2020-01-03  Bruno Haible  <bruno@clisp.org>
38461         doc: Mention the 64-bit inode number problem.
38462         * m4/largefile.m4 (AC_SYS_LARGEFILE): Mention that this macro fixes the
38463         64-bit inode number problem.
38464         * doc/posix-functions/stat.texi: Mention that this module fixes the
38465         64-bit inode number problem.
38466         * doc/posix-functions/lstat.texi: Likewise.
38467         * doc/posix-functions/fstat.texi: Likewise.
38468         * doc/posix-functions/readdir.texi: Add more details.
38469         * doc/posix-functions/readdir_r.texi: Likewise.
38471 2020-01-02  Bruno Haible  <bruno@clisp.org>
38473         wcrtomb: Add more tests.
38474         * tests/test-wcrtomb-w32.c: Include localcharset.h.
38475         (test_one_locale): For the GB18030 and UTF-8 tests, verify that
38476         locale_charset() returns the expected value; otherwise, skip the test.
38477         * tests/test-wcrtomb-w32-6.sh: Remove old comment.
38478         * tests/test-wcrtomb-w32-7.sh: Likewise.
38479         * modules/wcrtomb-tests (Files): Add these files.
38480         (Depends-on): Add localcharset.
38481         (TESTS): Add test-wcrtomb-w32-6.sh, test-wcrtomb-w32-7.sh.
38483 2020-01-02  Bruno Haible  <bruno@clisp.org>
38485         mbrtowc: Add more tests.
38486         * tests/test-mbrtowc-w32.c: Include localcharset.h.
38487         (test_one_locale): For the GB18030 and UTF-8 tests, verify that
38488         locale_charset() returns the expected value; otherwise, skip the test.
38489         * tests/test-mbrtowc-w32-6.sh: Remove old comment.
38490         * tests/test-mbrtowc-w32-7.sh: Likewise.
38491         * modules/mbrtowc-tests (Files): Add these files.
38492         (Depends-on): Add localcharset.
38493         (TESTS): Add test-mbrtowc-w32-6.sh, test-mbrtowc-w32-7.sh.
38495 2020-01-02  Bruno Haible  <bruno@clisp.org>
38497         mbrtowc: Fix test failures on MSVC (regression by previous commit).
38498         * m4/mbrtowc.m4 (gl_MBRTOWC_STORES_INCOMPLETE): New macro.
38499         (gl_FUNC_MBRTOWC): Invoke it. Define MBRTOWC_STORES_INCOMPLETE_BUG.
38500         * lib/mbrtowc.c (rpl_mbrtowc): Add workaround for
38501         MBRTOWC_STORES_INCOMPLETE_BUG.
38502         * doc/posix-functions/mbrtowc.texi: Mention the MSVC bug.
38504 2020-01-02  Paul Eggert  <eggert@cs.ucla.edu>
38506         doc: mention glibc bug 24269
38507         * doc/regex.texi (Back-reference Operator): Add glibc bug 24269.
38508         Reformat slightly so that it looks nicer in the Grep manual.
38510 2020-01-02  Bruno Haible  <bruno@clisp.org>
38512         mbrtowc: Don't replace mbstate_t on MSVC.
38513         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN): Require AC_CANONICAL_HOST. Ignore
38514         a missing mbsinit function on native Windows.
38515         * lib/wchar.in.h (GNULIB_defined_mbstate_t): Likewise.
38516         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Strengthen the test, to detect an
38517         MSVC bug.
38518         * doc/posix-functions/wcrtomb.texi: Mention the MSVC bug.
38520 2020-01-02  Bruno Haible  <bruno@clisp.org>
38522         setlocale-null: Avoid crashing the MSVC linker.
38523         * lib/setlocale-lock.c: Don't define IMP(gl_get_setlocale_null_lock) on
38524         MSVC.
38526 2020-01-02  Bruno Haible  <bruno@clisp.org>
38528         wchar: Make the HP-UX workaround work on HP-UX 11.31.
38529         * modules/wchar (Depends-on): Add inttypes-incomplete.
38530         * lib/inttypes.in.h: Define _GL_FINISHED_INCLUDING_SYSTEM_INTTYPES_H.
38531         * lib/wchar.in.h: Test _GL_FINISHED_INCLUDING_SYSTEM_INTTYPES_H instead
38532         of strtoimax.
38534 2020-01-02  Bruno Haible  <bruno@clisp.org>
38536         mbrtowc: Fix compilation error on IRIX (regression from 2019-12-26).
38537         * lib/mbrtowc.c: Include <stdint.h>.
38538         * modules/mbrtowc (Depends-on): Add stdint.
38540 2020-01-01  Pádraig Brady  <P@draigBrady.com>
38542         md5, sha1, sha256, sha512: support --with-openssl=auto-gpl-compat
38543         * m4/gl-openssl.m4: Add a new "auto-gpl-compat" mode,
38544         which will auto enable use of openssl, only for >= version 3,
38545         which is newly licensed under the Apache Software License.
38547 2020-01-01  Bruno Haible  <bruno@clisp.org>
38549         mbrtowc: Include function name in macro names.
38550         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Define
38551         MBRTOWC_IN_C_LOCALE_MAYBE_EILSEQ, not C_LOCALE_MAYBE_EILSEQ.
38552         (gl_MBRTOWC_C_LOCALE): Change cache variable name to
38553         gl_cv_func_mbrtowc_C_locale_sans_EILSEQ.
38554         * lib/mbrtowc.c: Test MBRTOWC_IN_C_LOCALE_MAYBE_EILSEQ, not
38555         C_LOCALE_MAYBE_EILSEQ.
38557 2020-01-01  Bruno Haible  <bruno@clisp.org>
38559         c32tob: New module.
38560         * lib/uchar.in.h (_GL_LARGE_CHAR32_T): New macro.
38561         (c32tob): New declaration.
38562         * lib/c32tob.c: New file.
38563         * m4/uchar.m4 (gl_UCHAR_MODULE_INDICATOR, gl_UCHAR_H_DEFAULTS): New
38564         macros.
38565         (gl_UCHAR_H): Require gl_UCHAR_H_DEFAULTS.
38566         * modules/uchar (Depends-on): Add snippet/c++defs.
38567         (Makefile.am): Include c++defs.h and substitute GNULIB_C32TOB in
38568         uchar.h.
38569         * modules/c32tob: New file.
38570         * tests/test-uchar.c: Verify that _GL_LARGE_CHAR32_T is correctly
38571         defined.
38572         * tests/test-uchar-c++.cc: Include signature.h. Test the signature of
38573         c32tob.
38574         * modules/uchar-c++-tests (Files): Add tests/signature.h.
38575         * doc/posix-functions/wctob.texi: Mention the new module.
38577 2020-01-01  Bruno Haible  <bruno@clisp.org>
38579         locale C++ tests: Fix link error on AIX (regression from 2019-12-18).
38580         * modules/locale-c++-tests (Makefile.am): Link test-locale-c++ with
38581         $(LIB_SETLOCALE).
38583 2020-01-01  Bruno Haible  <bruno@clisp.org>
38585         hard-locale tests: Fix a conflict with the C++ tests.
38586         * modules/hard-locale-tests (Makefile.am): Build a program named
38587         'current-locale', not 'locale'.
38589 2020-01-01  Bruno Haible  <bruno@clisp.org>
38591         doc: Update documentation about wchar_t.
38592         * doc/*/*wc*.texi: Clarify that 64-bit AIX does not have a too small
38593         wchar_t type.
38595 2020-01-01  Bruno Haible  <bruno@clisp.org>
38597         mbrtowc tests: Fix typos.
38598         * tests/test-mbrtowc.c (main): Fix typo.
38599         * tests/test-mbrtowc-w32.c (test_one_locale): Likewise.
38601 2019-12-31  Paul Eggert  <eggert@cs.ucla.edu>
38603         maint: update copyright notices
38604         Before doing the following changes done by hand, I also ran ‘make
38605         update-copyright’ and ‘config/srclist-update <config/srclist.txt’
38606         to do most of the copyright years automatically.  A few upstream
38607         sources are still in 2019 but these should eventually be changed
38608         automatically too.
38609         * build-aux/declared.sh (func_version):
38610         * build-aux/libtool-next-version (func_version):
38611         * build-aux/run-test (func_version):
38612         Update these notices by hand.  Put just the last year
38613         in output of programs, as per GNU coding standards.
38615 2019-12-31  Bruno Haible  <bruno@clisp.org>
38617         uchar: Add C++ tests.
38618         * tests/test-uchar-c++.cc: New file.
38619         * tests/test-uchar-c++2.cc: New file.
38620         * modules/uchar-c++-tests: New file.
38622         uchar: Add tests.
38623         * tests/test-uchar.c: New file.
38624         * modules/uchar-tests: New file.
38626         uchar: New module.
38627         * lib/uchar.in.h: New file.
38628         * m4/uchar.m4: New file.
38629         * modules/uchar: New file.
38630         * doc/posix-headers/uchar.texi: Mention the new module.
38632 2019-12-30  Jim Meyering  <meyering@fb.com>
38634         localeinfo: ->simple would be wrong for LC_ALL=C
38635         That would lead to using unnecessary and expensive code paths in dfa.c.
38636         * lib/localeinfo.c (using_simple_locale): Fix recently-introduced logic
38637         error that would have made grep many times slower in the C locale.
38638         With this change, and a file created like this:
38639           yes 00 | head -10000000 > in
38640         Running grep as follows becomes more than 40 times faster:
38641           LC_ALL=C grep -Fw 0 in
38643 2019-12-30  Paul Eggert  <eggert@cs.ucla.edu>
38645         doc: document trouble with back-references
38646         * doc/regex.texi (Back-reference Operator): Mention bugs etc.
38648 2019-12-29  Paul Eggert  <eggert@cs.ucla.edu>
38650         doc: use “back-reference” for \1 etc.
38651         * doc/regex.texi: Consistently spell “back-reference” with
38652         a hyphen, since that’s how POSIX does it.
38654 2019-12-26  Jim Meyering  <meyering@fb.com>
38656         test-framework-sh: tighten an internal grep regexp
38657         * tests/init.sh (gl_shell_test_script_): Tighten the grep regexp
38658         that helps test for a working printf.
38660 2019-12-26  Bruno Haible  <bruno@clisp.org>
38662         test-framework-sh: Avoid /bin/sh on AIX 7.2 due to its printf built-in.
38663         Reported by Paul Eggert in
38664         <https://lists.gnu.org/archive/html/grep-devel/2019-12/msg00020.html>.
38665         Simplification by Jim Meyering.
38666         * tests/init.sh (gl_shell_test_script_): Add a test of printf of an
38667         octal escape sequence in a UTF-8 locale.
38669 2019-12-26  Paul Eggert  <eggert@cs.ucla.edu>
38671         mbrtowc: port better to narrow-wchar_t platforms
38672         * lib/mbrtowc.c (mbrtowc): On platforms like AIX 7.2, where
38673         wchar_t is too narrow to represent all the Unicode characters,
38674         consider a byte sequence for an out-of-wchar_t-range character to
38675         be an encoding error.  This fixes grep’s surrogate-pair test
38676         failure on AIX 7.2.
38678 2019-12-24  Bruno Haible  <bruno@clisp.org>
38680         localcharset: Avoid referencing rpl_setlocale on native Windows.
38681         * lib/localcharset.c (setlocale): Undefine.
38683 2019-12-24  Bruno Haible  <bruno@clisp.org>
38685         lock tests: Fix link error on HP-UX/hppa (regression from 2019-12-21).
38686         * m4/semaphore.m4: New file.
38687         * modules/lock-tests (Files): Add it.
38688         (configure.ac): Require gl_SEMAPHORE.
38689         (Makefile.am): Link test-lock with $(LIB_SEMAPHORE).
38691 2019-12-24  Paul Eggert  <eggert@cs.ucla.edu>
38693         strptime: fix typo in previous patch
38694         Problem and fix reported by Bruno Haible in:
38695         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00202.html
38696         * lib/strptime.c (day_of_the_week): Fix paren bug.
38698 2019-12-24  Bruno Haible  <bruno@clisp.org>
38700         setlocale-null: Make it easy to rely on the lock in another library.
38701         * lib/setlocale-lock.c: Do not define anything if OMIT_SETLOCALE_LOCK is
38702         defined.
38704 2019-12-23  Paul Eggert  <eggert@cs.ucla.edu>
38706         gethrxtime, mktime, nstrftime, strptime: tweak division performance
38707         Performanced analyzed by Bruno Haible in:
38708         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00200.html
38709         * config/srclist.txt: Do not sync mktime.c for now.
38710         * lib/mktime.c (shr, ydhms_diff):
38711         * lib/nstrftime.c (SHR, tm_diff, __strftime_internal):
38712         * lib/strptime.c (day_of_the_week):
38713         * lib/xtime.h (xtime_sec):
38714         Redo with neither ‘%’ nor conditional branches.
38716 2019-12-23  Bruno Haible  <bruno@clisp.org>
38718         setlocale-null: Export the lock function also on non-Windows platforms.
38719         * lib/setlocale-lock.c (DLL_EXPORTED): New macro.
38720         (gl_get_setlocale_null_lock): Declare as DLL_EXPORTED.
38721         * m4/setlocale_null.m4 (gl_PREREQ_SETLOCALE_LOCK): New macro.
38722         * modules/setlocale-null (configure.ac): Invoke it.
38723         (Files): Add m4/visibility.m4.
38725 2019-12-22  Paul Eggert  <eggert@cs.ucla.edu>
38727         gethrxtime: fix rounding bug with negative args
38728         Problem reported by Bruno Haible in:
38729         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00192.html
38730         * lib/xtime.h (xtime_sec): Simplify calculation and correct bug
38731         with negative rounding.  Common platforms can compute / and % with
38732         a single instruction, so the simplified code should be shorter and
38733         faster on these platforms anyway.
38735 2019-12-22  Bruno Haible  <bruno@clisp.org>
38737         gethrxtime: remove incorrect overflow detection
38738         * lib/xtime.h (xtime_make): Remove attempt to prevent internal
38739         integer overflow, as it didn’t suffice.  This reverts the xtime.h
38740         part of 2018-10-12T04:46:09Z!akim.demaille@gmail.com, which I
38741         cannot now see the need for anyway (even in cases where it works),
38742         as the patch is helpful only when the signs of S and NS disagree,
38743         and all callers pass nonnegative values for S and NS.
38745 2019-12-22  Bruno Haible  <bruno@clisp.org>
38747         setlocale-null: Add standalone include file.
38748         * lib/setlocale_null.h: New file, extracted from lib/locale.in.h.
38749         * lib/locale.in.h: Include setlocale_null.h.
38750         (SETLOCALE_NULL_MAX, SETLOCALE_NULL_ALL_MAX, setlocale_null_r,
38751         setlocale_null): Remove declarations.
38752         * lib/setlocale_null.c: Include setlocale_null.h.
38753         * lib/localename.c: Likewise.
38754         * modules/setlocale-null (Files): Add lib/setlocale_null.h.
38755         (Depends-on): Add snippet/arg-nonnull.
38756         (Include): Allow either "setlocale_null.h" or <locale.h>.
38758 2019-12-22  Bruno Haible  <bruno@clisp.org>
38760         strfmon_l: Fix test failures on FreeBSD and Cygwin.
38761         * m4/strfmon_l.m4 (gl_FUNC_STRFMON_L): Require gt_LOCALE_FR_UTF8. Add an
38762         AC_RUN_IFELSE test.
38763         * modules/strfmon_l (Files): Add locale-fr.m4, codeset.m4.
38764         * doc/posix-functions/strfmon_l.texi: Mention the FreeBSD and Cygwin
38765         problem.
38767 2019-12-22  Bruno Haible  <bruno@clisp.org>
38769         Prefer lib_SOURCES to unconditional AC_LIBOBJ.
38770         * modules/at-internal: Prefer a lib_SOURCES augmentation to an
38771         unconditional AC_LIBOBJ.
38772         * modules/selinux-at: Likewise.
38773         * modules/xmemdup0: Likewise.
38774         * modules/xstrtoll: Likewise.
38776 2019-12-22  Bruno Haible  <bruno@clisp.org>
38778         longlong: Mark module obsolete.
38779         * modules/longlong (Status, Notice): New sections.
38781         stdint: Assume that the compiler supports 'long long'.
38782         * lib/stdint.in.h (int64_t, uint64_t, intmax_t, uintmax_t, INT64_C,
38783         UINT64_C, INTMAX_C, UINTMAX_C): Assume HAVE_LONG_LONG_INT and
38784         HAVE_UNSIGNED_LONG_LONG_INT to be 1.
38785         * m4/stdint.m4 (gl_STDINT_H): Don't require AC_TYPE_LONG_LONG_INT,
38786         AC_TYPE_UNSIGNED_LONG_LONG_INT.
38787         * modules/stdint (Files): Remove longlong.m4.
38788         (Makefile.am): Don't substitute HAVE_LONG_LONG_INT,
38789         HAVE_UNSIGNED_LONG_LONG_INT.
38791         inttypes-incomplete: Assume that the compiler supports 'long long'.
38792         * lib/inttypes.in.h (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX,
38793         _SCNu64_PREFIX): Assume HAVE_LONG_LONG_INT and
38794         HAVE_UNSIGNED_LONG_LONG_INT to be 1.
38795         * m4/inttypes.m4 (gl_INTTYPES_CHECK_LONG_LONG_INT_CONDITION): Assume
38796         HAVE_LONG_LONG_INT to be 1.
38797         * modules/inttypes-incomplete (Makefile.am): Don't substitute
38798         HAVE_LONG_LONG_INT, HAVE_UNSIGNED_LONG_LONG_INT.
38800         malloca: Assume that the compiler supports 'long long'.
38801         * lib/malloca.h: Assume HAVE_LONG_LONG_INT to be 1.
38802         * m4/malloca.m4 (gl_MALLOCA): Don't require AC_TYPE_LONG_LONG_INT.
38803         * modules/malloca (Files): Remove longlong.m4.
38804         * modules/relocatable-prog-wrapper (Files): Likewise.
38806         atoll: Assume that the compiler supports 'long long'.
38807         * m4/atoll.m4 (gl_FUNC_ATOLL): Don't require AC_TYPE_LONG_LONG_INT.
38808         * modules/atoll (Files): Remove longlong.m4.
38810         strtoll: Assume that the compiler supports 'long long'.
38811         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Don't require AC_TYPE_LONG_LONG_INT.
38812         * modules/strtoll (Files): Remove longlong.m4.
38814         strtoull: Assume that the compiler supports 'long long'.
38815         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Don't require
38816         AC_TYPE_UNSIGNED_LONG_LONG_INT.
38817         * modules/strtoull (Files): Remove longlong.m4.
38819         strtoimax, strtoumax: Assume that the compiler supports 'long long'.
38820         * lib/strtoimax.c: Assume HAVE_LONG_LONG_INT and
38821         HAVE_UNSIGNED_LONG_LONG_INT to be 1.
38822         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Don't require
38823         AC_TYPE_LONG_LONG_INT.
38824         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't require
38825         AC_TYPE_UNSIGNED_LONG_LONG_INT.
38826         * modules/strtoimax (Files): Remove longlong.m4.
38827         * modules/strtoumax (Files): Likewise.
38829         xstrtoll: Assume that the compiler supports 'long long'.
38830         * lib/xstrtol.h (xstrtoll, xstrtoull): Declare unconditionally.
38831         * modules/xstrtoll (configure.ac): Don't invoke AC_TYPE_LONG_LONG_INT.
38833         vasnprintf: Assume that the compiler supports 'long long'.
38834         * lib/printf-args.h: Assume HAVE_LONG_LONG_INT to be 1.
38835         * lib/printf-args.c (PRINTF_FETCHARGS): Likewise.
38836         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
38837         * lib/vasnprintf.c (MAX_ROOM_NEEDED, VASNPRINTF): Likewise.
38838         * m4/intmax_t.m4 (gl_AC_TYPE_INTMAX_T, gt_AC_TYPE_INTMAX_T): Don't
38839         require AC_TYPE_LONG_LONG_INT.
38840         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
38841         gl_PREREQ_VASNPRINTF): Likewise.
38842         * modules/vasnprintf (Files): Remove longlong.m4.
38843         * modules/c-vasnprintf (Files): Likewise.
38844         * modules/unistdio/u8-vasnprintf (Files): Likewise.
38845         * modules/unistdio/u8-u8-vasnprintf (Files): Likewise.
38846         * modules/unistdio/u16-vasnprintf (Files): Likewise.
38847         * modules/unistdio/u16-u16-vasnprintf (Files): Likewise.
38848         * modules/unistdio/u32-vasnprintf (Files): Likewise.
38849         * modules/unistdio/u32-u32-vasnprintf (Files): Likewise.
38850         * modules/unistdio/ulc-vasnprintf (Files): Likewise.
38852         gethrxtime: Assume that the compiler supports 'long long'.
38853         * lib/xtime.h (xtime_t): Define to 'long long int' always.
38854         (XTIME_PRECISION): Define to 1000000000 always.
38855         (xtime_make, xtime_sec): Optimize accordingly.
38856         * m4/gethrxtime.m4 (gl_XTIME): Don't require AC_TYPE_LONG_LONG_INT.
38857         * modules/gethrxtime (Files): Remove longlong.m4.
38859         integer_length*: Assume that the compiler supports 'long long'.
38860         * lib/integer_length.h (integer_length_ll): Declare unconditionally.
38861         * modules/integer_length (Files): Remove longlong.m4.
38862         (configure.ac): Don't require AC_TYPE_UNSIGNED_LONG_LONG_INT.
38863         * modules/integer_length_l (Files): Remove longlong.m4.
38864         (configure.ac): Don't require AC_TYPE_UNSIGNED_LONG_LONG_INT.
38865         * modules/integer_length_ll (Files): Remove longlong.m4.
38866         (configure.ac): Don't require AC_TYPE_UNSIGNED_LONG_LONG_INT.
38868         count-one-bits: Assume that the compiler supports 'long long'.
38869         * lib/count-one-bits.h (count_one_bits_ll): Define unconditionally.
38870         * m4/count-one-bits.m4: Remove file.
38871         * modules/count-one-bits (Files): Remove it.
38872         (configure.ac): Don't invoke gl_COUNT_ONE_BITS.
38873         * tests/test-count-one-bits.c (main): Test count_one_bits_ll
38874         unconditionally.
38876         count-trailing-zeros: Assume that the compiler supports 'long long'.
38877         * lib/count-trailing-zeros.h (count_trailing_zeros_ll): Define
38878         unconditionally.
38879         * m4/count-trailing-zeros.m4: Remove file.
38880         * modules/count-trailing-zeros (Files): Remove it.
38881         (configure.ac): Don't invoke gl_COUNT_TRAILING_ZEROS.
38882         * tests/test-count-trailing-zeros.c (main): Test count_trailing_zeros_ll
38883         unconditionally.
38885         count-leading-zeros: Assume that the compiler supports 'long long'.
38886         * lib/count-leading-zeros.h (count_leading_zeros_ll): Define
38887         unconditionally.
38888         * m4/count-leading-zeros.m4: Remove file.
38889         * modules/count-leading-zeros (Files): Remove it.
38890         (configure.ac): Don't invoke gl_COUNT_LEADING_ZEROS.
38891         * tests/test-count-leading-zeros.c (main): Test count_leading_zeros_ll
38892         unconditionally.
38894 2019-12-22  Bruno Haible  <bruno@clisp.org>
38896         localcharset: Update support for OpenBSD.
38897         * lib/localcharset.c (alias_table): Map "US-ASCII" to "ASCII".
38899 2019-12-21  Bruno Haible  <bruno@clisp.org>
38901         pthread_sigmask: Avoid test failure on NetBSD 8.0.
38902         * tests/test-pthread_sigmask2.c (main): Skip the error handling test on
38903         NetBSD.
38904         * doc/posix-functions/pthread_sigmask.texi: Mention the NetBSD problem.
38906 2019-12-21  Bruno Haible  <bruno@clisp.org>
38908         threadlib: Improve code structure.
38909         * m4/threadlib.m4: Reorder macros. Add comments.
38911 2019-12-21  Bruno Haible  <bruno@clisp.org>
38913         threadlib: Fix LIBMULTITHREAD on FreeBSD with --enable-threads=isoc.
38914         * m4/threadlib.m4 (gl_STDTHREADLIB_BODY): New macro (some code moved
38915         here from m4/threads.m4).
38916         (gl_THREADLIB_BODY): Don't test whether mtx_lock and cnd_timedwait exist
38917         in libc. Instead, rely on gl_STDTHREADLIB_BODY.
38918         (gl_STDTHREADLIB): New macro.
38919         * m4/threads.m4 (gl_THREADS_H): Require gl_STDTHREADLIB instead of
38920         gl_THREADLIB_BODY and gl_YIELD. Don't set LIBSTDTHREAD here.
38922 2019-12-21  Bruno Haible  <bruno@clisp.org>
38924         sched_yield: Don't depend on threadlib and yield.
38925         * m4/threadlib.m4 (gl_PTHREADLIB): Document that it sets
38926         LIB_SCHED_YIELD.
38927         (gl_PTHREADLIB_BODY): Set LIB_SCHED_YIELD (code moved here from
38928         m4/yield.m4).
38929         * m4/sched_yield.m4 (gl_FUNC_SCHED_YIELD): Require gl_PTHREADLIB, not
38930         gl_THREADLIB and gl_YIELD.
38931         * m4/yield.m4 (gl_YIELD): Require gl_PTHREADLIB. Determine YIELD_LIB
38932         based on $(LIB_SCHED_YIELD).
38933         * m4/threads.m4 (gl_THREADS_H): Don't require gl_YIELD. Use
38934         $(LIB_SCHED_YIELD), not $(YIELD_LIB).
38935         * modules/sched_yield (Files): Remove yield.m4. Add threadlib.m4.
38936         (Depends-on): Remove threadlib.
38937         (Link): Mention $(LIB_SCHED_YIELD), not $(YIELD_LIB).
38938         * modules/threads-h (Files): Remove m4/yield.m4.
38939         * modules/pthread-cond-tests (Makefile.am): Link the programs against
38940         $(LIB_SCHED_YIELD), not $(YIELD_LIB).
38941         * modules/pthread-mutex-tests (Makefile.am): Likewise.
38942         * modules/pthread-once-tests (Makefile.am): Likewise.
38943         * modules/pthread-rwlock-tests (Makefile.am): Likewise.
38944         * modules/pthread-tss-tests (Makefile.am): Likewise.
38946 2019-12-21  Bruno Haible  <bruno@clisp.org>
38948         threads-h: Don't depend on threadlib.
38949         * modules/threads-h (configure.ac-early): Invoke gl_ANYTHREADLIB_EARLY,
38950         not gl_THREADLIB_EARLY.
38952 2019-12-21  Bruno Haible  <bruno@clisp.org>
38954         nl_langinfo tests: Fix link error (regression from 2019-12-18).
38955         * modules/nl_langinfo-tests (Makefile.am): Link also test-nl_langinfo
38956         with $(LIB_SETLOCALE).
38958 2019-12-21  Bruno Haible  <bruno@clisp.org>
38960         threadlib: Remove unused dependency (left over from 2019-07-06).
38961         * modules/threadlib (Depends-on): Remove havelib.
38963 2019-12-21  Bruno Haible  <bruno@clisp.org>
38965         New convention for multithread-safety tests.
38966         * tests/test-setlocale_null-mt-one.c: Renamed from
38967         tests/test-setlocale_null-one.c.
38968         * tests/test-setlocale_null-mt-all.c: Renamed from
38969         tests/test-setlocale_null-all.c.
38970         * modules/setlocale-null-tests (Files, Makefile.am): Update.
38972 2019-12-21  Bruno Haible  <bruno@clisp.org>
38974         quotearg tests: Fix conflict with hard-locale tests.
38975         * tests/testlocale: Renamed from tests/locale.
38976         * modules/quotearg-tests (Files): Update.
38977         * tests/test-quotearg.sh (LOCALEDIR): Likewise.
38979 2019-12-21  Bruno Haible  <bruno@clisp.org>
38981         pthread-thread, lock: On z/OS, use PTHREAD_RWLOCK_INITIALIZER_NP.
38982         Reported by Daniel Richard G. in
38983         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00001.html>
38984         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00167.html>
38985         * lib/pthread.in.h (PTHREAD_RWLOCK_INITIALIZER): Define to
38986         PTHREAD_RWLOCK_INITIALIZER_NP when possible.
38987         * lib/glthread/lock.h: Allow PTHREAD_RWLOCK_INITIALIZER_NP as an
38988         alternative to PTHREAD_RWLOCK_INITIALIZER.
38989         * lib/glthread/lock.c: Likewise.
38991 2019-12-21  Bruno Haible  <bruno@clisp.org>
38993         memcmp tests: Work around the clang bug.
38994         * tests/test-memcmp.c (main): Use a volatile function pointer to disable
38995         the clang optimization.
38997 2019-12-20  Bruno Haible  <bruno@clisp.org>
38999         localcharset: Add support for z/OS encoding names.
39000         * lib/localcharset.h: Mention which encodings are used as locale
39001         encodings on z/OS.
39003 2019-12-20  Bruno Haible  <bruno@clisp.org>
39005         iconv_open: Add support for z/OS encoding names.
39006         Reported by Daniel Richard G. in
39007         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00172.html>.
39008         * lib/iconv_open-zos.gperf: New file.
39009         * modules/iconv_open (Files): Add iconv_open-zos.gperf.
39010         (Makefile.am): Add rules for generating iconv_open-zos.h from it.
39011         * lib/iconv_open.c (ICONV_FLAVOR_ZOS): New macro.
39012         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): On z/OS, use ICONV_FLAVOR_ZOS.
39013         * doc/posix-functions/iconv_open.texi: Mention z/OS.
39015 2019-12-20  Bruno Haible  <bruno@clisp.org>
39017         doc: Document the problem of the per-thread locale functions on z/OS.
39018         * doc/posix-functions/uselocale.texi: Document the z/OS problem.
39019         * doc/posix-functions/newlocale.texi: Likewise.
39020         * doc/posix-functions/duplocale.texi: Likewise.
39021         * doc/posix-functions/freelocale.texi: Likewise.
39023 2019-12-20  Bruno Haible  <bruno@clisp.org>
39025         localename, gettext: Fix host_os value for z/OS.
39026         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): Fix host_os value in
39027         cross-configuration code.
39029 2019-12-19  Jim Meyering  <meyering@fb.com>
39031         nstrftime: avoid a shadowing warning
39032         * lib/nstrftime.c (libc_hidden_def): Rename inner "i" to "j",
39033         to avoid shadowing an "i" declared hundreds of lines above.
39035 2019-12-19  Paul Eggert  <eggert@cs.ucla.edu>
39037         dfa: struct dfamust now uses flexible array
39038         * lib/dfa.c: Include flexmember.h.
39039         (dfamust, dfamustfree): Adjust to struct dfamust change.
39040         This saves a call to malloc+free.
39041         * lib/dfa.h (struct dfamust): Make the final member a
39042         flexible array member.
39043         * modules/dfa (Depends-on): Add flexmember.
39045         dfa: fast->small for array elements
39046         * lib/dfa.c (charclass_word): Use uint_least64_t not uint_fast64_t,
39047         since this type is used in arrays.  This change is more for
39048         documentation than for any practical effect, since the two types
39049         are the same on all known platforms.
39051 2019-12-19  Bruno Haible  <bruno@clisp.org>
39053         iconv tests: Test canonicalized, not system-dependent, encoding names.
39054         * tests/test-iconv.c (main): Revert part of the 2016-08-17 patch.
39055         * modules/iconv-tests (Depends-on): Add iconv_open.
39057 2019-12-18  Bruno Haible  <bruno@clisp.org>
39059         localename: Fix test failure on AIX 7.2.
39060         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): Enable nameless
39061         locales on AIX.
39062         * lib/localename.c (gl_locale_name_thread_unsafe): Handle nameless
39063         locales on AIX.
39065 2019-12-18  Paul Eggert  <eggert@cs.ucla.edu>
39067         Improve port of AC_C_RESTRICT to Oracle C++
39068         Problem reported by Christian Biesinger in:
39069         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00159.html
39070         * m4/gnulib-common.m4 (AC_C_RESTRICT): Port better to
39071         Oracle Developer Studio C++ 12.5 or later.
39073 2019-12-18  Bruno Haible  <bruno@clisp.org>
39075         wchar: Fix test failures on AIX and MSVC (regression from 2019-12-07).
39076         * lib/wchar.in.h (GNULIB_defined_mbstate_t): Do define on AIX and MSVC.
39078 2019-12-18  Bruno Haible  <bruno@clisp.org>
39080         localename: Ensure multithread-safety in future changes.
39081         * lib/localename.c (setlocale): Reference the system's setlocale().
39082         (get_locale_t_name): Invoke setlocale_null instead of setlocale.
39083         (gl_locale_name_posix): Likewise.
39084         * modules/localename (Depends-on): Add setlocale-null.
39086 2019-12-18  Bruno Haible  <bruno@clisp.org>
39088         setlocale-null: Make API more useful.
39089         * lib/locale.in.h (setlocale_null_r): Renamed from setlocale_null. All
39090         callers changed.
39091         (setlocale_null): New declaration.
39092         * lib/setlocale_null.c (setlocale_null_androidfix): New function,
39093         extracted from setlocale_null_unlocked.
39094         (setlocale_null_unlocked): Invoke it.
39095         (setlocale_null_r): Renamed from setlocale_null.
39096         (setlocale_null): New function, extracted from setlocale_mtsafe in
39097         setlocale.c.
39098         * lib/setlocale.c: Don't include <errno.h>.
39099         (setlocale_mtsafe): Invoke setlocale_null.
39100         * lib/setlocale-lock.c: Update comments.
39101         * doc/posix-functions/setlocale.texi: Mention both functions.
39103 2019-12-18  Bruno Haible  <bruno@clisp.org>
39105         localename: Optimize code for native Windows.
39106         * lib/localename.c (gl_locale_name_posix): Remove handling of LC_ALL
39107         category (not allowed here).
39109 2019-12-18  Bruno Haible  <bruno@clisp.org>
39111         setlocale: Make calls with NULL argument multithread-safe.
39112         * lib/setlocale.c: Include <errno.h>.
39113         (setlocale_mtsafe): New function.
39114         (setlocale_unixlike): Invoke setlocale_mtsafe instead of setlocale.
39115         (setlocale_improved): Renamed from rpl_setlocale.
39116         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Require gl_FUNC_SETLOCALE_NULL.
39117         Set and define NEED_SETLOCALE_IMPROVED and NEED_SETLOCALE_MTSAFE. Set
39118         LIB_SETLOCALE.
39119         * modules/setlocale (Depends-on): Add setlocale-null. Update conditions.
39120         (Link): New section.
39121         * tests/locale.c: Undefine setlocale.
39122         * tests/test-setlocale_null-one.c: Likewise.
39123         * tests/test-setlocale_null-all.c: Likewise.
39124         * modules/setlocale-tests (Makefile.am): Link the test programs with
39125         $(LIB_SETLOCALE).
39126         * modules/astrxfrm-tests (Makefile.am): Likewise.
39127         * modules/btowc-tests (Makefile.am): Likewise.
39128         * modules/c-ctype-tests (Makefile.am): Likewise.
39129         * modules/c-snprintf-tests (Makefile.am): Likewise.
39130         * modules/c-strcase-tests (Makefile.am): Likewise.
39131         * modules/c-vasprintf-tests (Makefile.am): Likewise.
39132         * modules/c-vsnprintf-tests (Makefile.am): Likewise.
39133         * modules/c-xvasprintf-tests (Makefile.am): Likewise.
39134         * modules/dfa-tests (Makefile.am): Likewise.
39135         * modules/duplocale-tests (Makefile.am): Likewise.
39136         * modules/hard-locale-tests (Makefile.am): Likewise.
39137         * modules/localcharset-tests (Makefile.am): Likewise.
39138         * modules/localename-tests (Makefile.am): Likewise.
39139         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
39140         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
39141         * modules/mbrtowc-tests (Makefile.am): Likewise.
39142         * modules/mbscasecmp-tests (Makefile.am): Likewise.
39143         * modules/mbscasestr-tests (Makefile.am): Likewise.
39144         * modules/mbschr-tests (Makefile.am): Likewise.
39145         * modules/mbscspn-tests (Makefile.am): Likewise.
39146         * modules/mbsinit-tests (Makefile.am): Likewise.
39147         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
39148         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
39149         * modules/mbspbrk-tests (Makefile.am): Likewise.
39150         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
39151         * modules/mbsrchr-tests (Makefile.am): Likewise.
39152         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
39153         * modules/mbsspn-tests (Makefile.am): Likewise.
39154         * modules/mbsstr-tests (Makefile.am): Likewise.
39155         * modules/nl_langinfo-tests (Makefile.am): Likewise.
39156         * modules/quotearg-tests (Makefile.am): Likewise.
39157         * modules/regex-tests (Makefile.am): Likewise.
39158         * modules/strfmon_l-tests (Makefile.am): Likewise.
39159         * modules/strtod-tests (Makefile.am): Likewise.
39160         * modules/strtold-tests (Makefile.am): Likewise.
39161         * modules/unicase/locale-language-tests (Makefile.am): Likewise.
39162         * modules/unicase/ulc-casecmp-tests (Makefile.am): Likewise.
39163         * modules/unicase/ulc-casecoll-tests (Makefile.am): Likewise.
39164         * modules/unigbrk/ulc-grapheme-breaks-tests (Makefile.am): Likewise.
39165         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
39166         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
39167         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
39168         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
39169         * modules/uniwbrk/ulc-wordbreaks-tests (Makefile.am): Likewise.
39170         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
39171         * modules/wcrtomb-tests (Makefile.am): Likewise.
39172         * modules/wcsnrtombs-tests (Makefile.am): Likewise.
39173         * modules/wcsrtombs-tests (Makefile.am): Likewise.
39174         * modules/wcwidth-tests (Makefile.am): Likewise.
39175         * doc/posix-functions/setlocale.texi: Mention that the multithread-
39176         safety fix is also available in module 'setlocale'.
39178 2019-12-18  Bruno Haible  <bruno@clisp.org>
39180         hard-locale: Make multithread-safe.
39181         * lib/hard-locale.h (hard_locale): Move documentation to here.
39182         * lib/hard-locale.c: Don't include <stdlib.h>.
39183         (GLIBC_VERSION): Remove macro.
39184         (hard_locale): Assume that all systems name the "C" and "POSIX" locales
39185         "C" or "POSIX". Invoke setlocale_null instead of setlocale.
39186         * modules/hard-locale (Depends-on): Remove strdup. Add setlocale-null.
39187         (configure.ac): Require gl_FUNC_SETLOCALE_NULL. Set LIB_HARD_LOCALE.
39188         (Link): New section.
39189         * modules/hard-locale-tests (Makefile.am): Link test-hard-locale against
39190         $(LIB_HARD_LOCALE).
39192 2019-12-18  Bruno Haible  <bruno@clisp.org>
39194         hard-locale: Avoid test failure on Haiku.
39195         * tests/test-hard-locale.c (test_one): Treat Haiku like recent OpenBSD.
39197 2019-12-18  Bruno Haible  <bruno@clisp.org>
39199         setlocale-null: Handle NULL result from setlocale.
39200         * lib/locale.in.h (setlocale_null): Document EINVAL return value.
39201         * lib/setlocale_null.c (setlocale_null_unlocked): Handle NULL result
39202         from setlocale or _wsetlocale.
39204 2019-12-18  Bruno Haible  <bruno@clisp.org>
39206         hard-locale: Add test.
39207         * tests/test-hard-locale.c: New file.
39208         * tests/locale.c: New file.
39209         * modules/hard-locale-tests: New file.
39211 2019-12-17  Paul Eggert  <eggert@cs.ucla.edu>
39213         dfa: do not match invalid UTF-8
39214         * lib/dfa.c (struct dfa): Grow utf8_anychar_classes member array
39215         from 5 to 9 tokens; this is needed due to the changes to
39216         add_utf8_anychar.
39217         (charclass_index): 2nd arg is now pointer-to-const.
39218         (add_utf8_anychar): Match only valid UTF-8 byte sequences
39219         instead of allowing overlong encodings or surrogate halves.
39221         dfa: simplify charclass by assuming C99
39222         * lib/dfa.c (CHARCLASS_WORD_BITS): Now always 64.
39223         (charclass_word): Now always uint_fast64_t.
39224         (CHARCLASS_PAIR): Remove.
39225         (CHARCLASS_INIT): Take 4 arguments instead of 8.  All uses changed.
39227         fts: tune via calloc
39228         * lib/fts.c (fts_open): Prefer calloc to malloc + memset.
39230         dfa: tune via xzalloc
39231         * lib/dfa.c (dfaoptimize): Prefer xzalloc to xmalloc + memset.
39233 2019-12-17  Bruno Haible  <bruno@clisp.org>
39235         localcharset: Fix multithread-safety bug on Windows and OS/2.
39236         * lib/localcharset.h (locale_charset): Clarify when the result becomes
39237         invalid.
39238         * lib/localcharset.c (locale_charset): Use a stack-allocated buffer to
39239         assemble the result.
39241 2019-12-17  Bruno Haible  <bruno@clisp.org>
39243         localcharset: Optimize code for native Windows.
39244         * lib/localcharset.c (locale_charset): Don't bother calling
39245         setlocale (LC_ALL, NULL) since we're not interested in its result.
39247 2019-12-17  Bruno Haible  <bruno@clisp.org>
39249         nl_langinfo: Fix multithread-safety bug on OpenBSD 3.8.
39250         * lib/nl_langinfo.c (ctype_codeset): Invoke setlocale_null instead of
39251         setlocale.
39252         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Require
39253         gl_FUNC_SETLOCALE_NULL. Set LIB_NL_LANGINFO.
39254         * modules/nl_langinfo (Depends-on): Add setlocale-null.
39256 2019-12-17  Bruno Haible  <bruno@clisp.org>
39258         nl_langinfo: Fix multithread-safety bug on mingw and MSVC.
39259         * lib/nl_langinfo.c (ctype_codeset, rpl_nl_langinfo): Use a
39260         stack-allocated buffer to assemble each result and different static
39261         buffers to return it.
39262         * tests/test-nl_langinfo-mt.c: New file.
39263         * modules/nl_langinfo-tests (Files): Add it.
39264         (Depends-on): Add thread, nanosleep.
39265         (Makefile.am): Build test-nl_langinfo-mt test.
39267 2019-12-17  Bruno Haible  <bruno@clisp.org>
39269         langinfo: Document more details.
39270         * doc/posix-headers/langinfo.texi: List platform details.
39271         * doc/posix-functions/nl_langinfo.texi: Likewise.
39273 2019-12-17  Bruno Haible  <bruno@clisp.org>
39275         mbsinit: Fix compilation error in mingw-w64 7.0 with _UCRT defined.
39276         Reported by Tom Kacvinsky <tom.kacvinsky@vector.com>
39277         and Martin Storsjö <martin@martin.st>
39278         in <https://savannah.gnu.org/bugs/?57406>.
39279         * lib/mbsinit.c: Accommodate an MSVC-like mbstate_t definition with
39280         mingw.
39282 2019-12-17  Bruno Haible  <bruno@clisp.org>
39284         glob: Avoid warning on mingw.
39285         Reported by Christian Biesinger <cbiesinger@google.com> in
39286         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00122.html>.
39287         * lib/glob.c (__stat64): Undefine first.
39289 2019-12-17  Paul Eggert  <eggert@cs.ucla.edu>
39291         xalloc: tune xzalloc for fresh allocations
39292         * lib/xmalloc.c (xzalloc): Use xcalloc rather than xmalloc+memset,
39293         because when the memory is freshly allocated from the OS via sbrk
39294         or mmap, calloc can avoid doing the memset.
39296         dfa: new function dfacopysyntax
39297         * lib/dfa.c (struct dfa): Move syntax member later so
39298         that dfacopysyntax can easily clear earlier members.
39299         (dfacopysyntax): New function, used by Gawk.
39301 2019-12-16  Paul Eggert  <eggert@cs.ucla.edu>
39303         dfa: port _GL_ATTRIBUTE_MALLOC to Gawk
39304         Gawk does not use Gnulib, and does not define _GL_ATTRIBUTE_MALLOC.
39305         * lib/dfa.h (_GL_ATTRIBUTE_MALLOC): Define to empty
39306         if not already defined.
39308         dfa: remove one dependency on MB_CUR_MAX
39309         * lib/dfa.c (dfamust): No need to refer to MB_CUR_MAX here.
39311         dfa: remove struct lexer_state.cur_mb_len
39312         * lib/dfa.c (struct lexer_state): Remove cur_mb_len member,
39313         as it’s not needed and the code is simpler without it.
39314         All uses removed.
39316 2019-12-16  Bruno Haible  <bruno@clisp.org>
39318         setlocale-null: Remove need for -lpthread on musl libc, *BSD, Haiku.
39319         Reported by Arnold Robbins <arnold@skeeve.com>.
39320         * lib/setlocale_null.c (c11_threads_in_use, pthread_in_use): New macros,
39321         copied from lib/glthread/lock.h.
39322         (pthread_mutex_lock, pthread_mutex_unlock): Mark as weak.
39323         (setlocale_null_with_lock): If pthread_in_use() is false, use
39324         setlocale_null_unlocked directly.
39325         * m4/threadlib.m4 (gl_WEAK_SYMBOLS): New macro, extracted from
39326         gl_THREADLIB_BODY. Define HAVE_WEAK_SYMBOLS.
39327         (gl_THREADLIB_BODY): Invoke gl_WEAK_SYMBOLS.
39328         * m4/setlocale_null.m4 (gl_FUNC_SETLOCALE_NULL): Invoke gl_WEAK_SYMBOLS.
39329         Set LIB_SETLOCALE_NULL to empty if weak symbols are supported.
39330         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Add comment.
39332 2019-12-16  Paul Eggert  <eggert@cs.ucla.edu>
39334         dfa: make dfasyntax thread-safe
39335         Problem reported by Bruno Haible in:
39336         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00099.html
39337         * lib/dfa.c: Do not include locale.h.
39338         (struct dfa): Remove simple_locale member.
39339         All uses replaced by localeinfo.simple.
39340         (using_simple_locale): Remove; now present (with some
39341         changes) in localeinfo.c.
39342         (dfasyntax): No need to initialize removed member.
39344         localeinfo: record whether locale is simple
39345         * lib/localeinfo.c (using_simple_locale): New function,
39346         copied here from lib/dfa.c but with a change: it uses
39347         strcoll for its heuristic, instead of using setlocale.
39348         This lets it be thread-safe.
39349         * lib/localeinfo.h (struct localeinfo): New member ‘simple’.
39351 2019-12-15  Bruno Haible  <bruno@clisp.org>
39353         duplocale: Fix multithread-safety bug on AIX.
39354         * lib/duplocale.c: Don't include <stdlib.h>.
39355         (rpl_duplocale): Invoke setlocale_null instead of setlocale.
39356         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Require gl_FUNC_SETLOCALE_NULL.
39357         Set LIB_DUPLOCALE.
39358         * modules/duplocale (Depends-on): Add setlocale-null.
39359         (Link): New section.
39360         * modules/duplocale-tests (Makefile.am): Link test-duplocale with
39361         $(LIB_DUPLOCALE).
39363 2019-12-15  Bruno Haible  <bruno@clisp.org>
39365         setlocale-null: Add tests.
39366         * tests/test-setlocale_null.c: New file.
39367         * tests/test-setlocale_null-one.c: New file.
39368         * tests/test-setlocale_null-all.c: New file.
39369         * modules/setlocale-null-tests: New file.
39371         setlocale-null: New module.
39372         * lib/locale.in.h (SETLOCALE_NULL_MAX, SETLOCALE_NULL_ALL_MAX,
39373         setlocale_null): New declarations.
39374         * lib/setlocale_null.c: New file.
39375         * lib/setlocale-lock.c: New file.
39376         * m4/threadlib.m4 (gl_PTHREADLIB_BODY): Define C macro HAVE_PTHREAD_API.
39377         * m4/setlocale_null.m4: New file.
39378         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize
39379         GNULIB_SETLOCALE_NULL.
39380         * modules/locale (Makefile.am): Substitute GNULIB_SETLOCALE_NULL.
39381         * modules/setlocale-null: New file.
39382         * doc/posix-functions/setlocale.texi: Mention the new module.
39384 2019-12-15  Bruno Haible  <bruno@clisp.org>
39386         lock tests: Skip test when no multithreading is enabled.
39387         * tests/test-rwlock1.c: Skip the test when no multithreading is enabled.
39389 2019-12-14  Bruno Haible  <bruno@clisp.org>
39391         locale, duplocale, localename: Fix last patch.
39392         Reported by Daniel Richard G. in
39393         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00093.html>.
39394         * lib/locale.in.h (HAVE_WORKING_NEWLOCALE, HAVE_WORKING_DUPLOCALE):
39395         Don't define if locale_t does not exist.
39397 2019-12-13  Bruno Haible  <bruno@clisp.org>
39399         locale, duplocale, localename: Fix errors if locale_t does not exist.
39400         Reported by Daniel Richard G. in
39401         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00078.html>.
39402         * lib/locale.in.h (HAVE_WORKING_NEWLOCALE, HAVE_WORKING_DUPLOCALE): New
39403         macros.
39404         * tests/test-locale.c: Test HAVE_WORKING_NEWLOCALE instead of
39405         HAVE_NEWLOCALE.
39406         * tests/test-localename.c: Likewise.
39407         * tests/test-duplocale.c: Test HAVE_WORKING_DUPLOCALE instead of
39408         HAVE_DUPLOCALE.
39409         * tests/test-locale-c++.cc: Likewise.
39411 2019-12-13  Bruno Haible  <bruno@clisp.org>
39413         wcstok: Fix test failure on HP-UX.
39414         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Set REPLACE_WCSTOK to 1 on HP-UX.
39415         * doc/posix-functions/wcstok.texi: Mention the HP-UX bug.
39417 2019-12-12  Bruno Haible  <bruno@clisp.org>
39419         strtod, strtold tests: Avoid test failure on AIX 7.2.
39420         * tests/test-strtod1.c (main): Allow implementations in which ',' and
39421         '.' both are radix characters.
39422         * tests/test-strtold1.c (main): Likewise.
39424 2019-12-12  Paul Eggert  <eggert@cs.ucla.edu>
39426         dfa: prefer ptrdiff_t for API, too
39427         Also, use ‘idx_t’ for ptrdiff_t values that must be nonnegative,
39428         but do this only for internal use for now.
39429         * NEWS: Mention the API change.
39430         * lib/dfa.c (idx_t, IDX_MAX): New type and max value, for internal
39431         use for now.  Use them instead of ptrdiff_t and PTRDIFF_MAX for
39432         values known to be nonnegative.
39433         (dfaparse, dfaexec_mb, dfaexec_sb, dfaexec_noop, dfaexec):
39434         Prefer idx_t or ptrdiff_t to size_t for API.
39435         * lib/dfa.h (dfaparse, dfacomp, dfaexec):
39436         Prefer ptrdiff_t to size_t for API.
39438         stdalign: port to xlclang 16.01
39439         Problem reportd by Bruno Haible in:
39440         https://lists.gnu.org/r/bug-gnulib/2019-12/msg00064.html
39441         * lib/stdalign.in.h (_Alignas): Do not use __attribute__
39442         ((__aligned__ (...))) with xlclang, as a top-level
39443         ‘char __attribute__ ((__aligned__ (8))) c;’ does not work with
39444         xlclang version 16.01.0000.0001; the alignment directive is ignored.
39446 2019-12-12  Bruno Haible  <bruno@clisp.org>
39448         duplocale: Fix test failure on AIX 7.2 with xlclang.
39449         * lib/duplocale.c: Include <stdlib.h>.
39450         (rpl_duplocale): Use a heap-allocated copy of the first setlocale return
39451         value.
39453 2019-12-12  Bruno Haible  <bruno@clisp.org>
39455         stddef: Document the AIX xlc issue.
39456         * doc/posix-headers/stddef.texi: Document the NULL issue with AIX xlc.
39458 2019-12-12  Bruno Haible  <bruno@clisp.org>
39460         duplocale: Don't attempt to override if locale_t does not exist.
39461         Reported by Daniel Richard G. in
39462         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00039.html>.
39463         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): If locale_t does not exist, set
39464         HAVE_DUPLOCALE to 0.
39466 2019-12-12  Bruno Haible  <bruno@clisp.org>
39468         wcwidth: Avoid test failure on AIX 7.2.
39469         * tests/test-wcwidth.c (main): Don't fail if wcwidth(0x200B) is
39470         negative.
39471         * doc/posix-functions/wcwidth.texi: Mention the AIX issue.
39473 2019-12-12  Bruno Haible  <bruno@clisp.org>
39475         ilogbl: Work around Cygwin bug.
39476         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Test whether ilogbl(0.0L) is
39477         correct.
39478         * doc/posix-functions/ilogbl.texi: Mention the Cygwin bug.
39480 2019-12-12  Bruno Haible  <bruno@clisp.org>
39482         strtold: Work around Cygwin bug.
39483         * m4/strtold.m4 (gl_FUNC_STRTOLD): Add test for the underflow problem.
39484         If it is present, define STRTOLD_HAS_UNDERFLOW_BUG.
39485         * lib/strtod.c (HAVE_UNDERLYING_STRTOD): Set to 0 if
39486         STRTOLD_HAS_UNDERFLOW_BUG is defined.
39487         * doc/posix-functions/strtold.texi: Mention the Cygwin bug.
39489 2019-12-12  Bruno Haible  <bruno@clisp.org>
39491         strtold: Fix autoconf test.
39492         * m4/strtold.m4 (gl_FUNC_STRTOLD): Test strtold, not strtod.
39494 2019-12-11  Bruno Haible  <bruno@clisp.org>
39496         fsync tests: Skip test that is known to fail.
39497         * doc/posix-functions/fsync.texi: Update list of platforms.
39498         * tests/test-fsync.c (main): Skip test with read-only file descriptors
39499         that is known to fail on AIX and Cygwin.
39501 2019-12-11  Bruno Haible  <bruno@clisp.org>
39503         getaddrinfo: Fix calling convention in 32-bit mode on native Windows.
39504         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Test whether getaddrinfo has a
39505         non-POSIX signature. If so, set REPLACE_GETADDRINFO. Define
39506         HAVE_GETADDRINFO as a C macro.
39507         * lib/netdb.in.h (getaddrinfo, freeaddrinfo): If REPLACE_GETADDRINFO,
39508         declare as replacement functions.
39509         * lib/getaddrinfo.c (getaddrinfo, freeaddrinfo): If HAVE_GETADDRINFO,
39510         define as no-op overrides.
39511         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Initialize REPLACE_GETADDRINFO.
39512         * modules/netdb (Makefile.am): Substitute REPLACE_GETADDRINFO.
39513         * modules/getaddrinfo (Depends-on, configure.ac): Test
39514         REPLACE_GETADDRINFO.
39515         * doc/posix-functions/getaddrinfo.texi: Mention calling convention
39516         problem.
39517         * doc/posix-functions/freeaddrinfo.texi: Mention header file and calling
39518         convention problems.
39520 2019-12-11  Paul Eggert  <eggert@cs.ucla.edu>
39522         dfa: prefer signed integers for internals
39523         Signed integers can be checked more easily for integer overflow.
39524         * lib/dfa.c (position, struct lexer_state, struct parser_state)
39525         (struct dfa, mbs_to_wchar, fetch_wc, parse_bracket_exp)
39526         (struct lexptr, lex, addtok_mb, add_utf8_anychar, atom)
39527         (nsubtoks, copytoks, closure, alloc_position_set, delete)
39528         (replace, state_index, epsclosure, charclass_context)
39529         (state_separate_contexts, merge_nfa_state, dfaoptimize)
39530         (dfaanalyze, build_state, dfaexec_main, dfa_supported)
39531         (maybe_disable_superset_dfa, dfassbuild, dfafree, enlist)
39532         (comsubs, inboth, allocmust):
39533         Prefer a signed to an unsigned integer when calculating indexes,
39534         unless the integer is part of the external API (a bigger deal,
39535         and to be done later).
39537         dfa: fix index overflow
39538         * lib/dfa.c (compare): Avoid integer overflow when analyzing
39539         very large regular expressions.
39541         dfa: update commentary for previous change
39542         * NEWS: Mention the change.
39543         * lib/dfa.c, lib/dfa.h (dfaparse, dfamust, dfacomp): Update comments.
39545 2019-12-11  Norihiro Tanaka  <noritnk@kcn.ne.jp>
39547         dfa: separate parse and compile phase
39548         ‘dfamust’ must be called after parsing and before tokens are
39549         reordered, but both are executed in the compilation phase.
39550         Token reordering was introduced in Gnulib commit
39551         2018-10-22T15:01:08Z!noritnk@kcn.ne.jp
39552         (5c7a0371823876cca7a1347fa09ca26bbbff0c98).
39553         * lib/dfa.c (dfaparse): Change it to global function.
39554         (dfacomp): If first argument is NULL, skip parse.
39555         * lib/dfa.h: (dfaparse): Add a prototype.
39557 2019-12-11  Bruno Haible  <bruno@clisp.org>
39559         unistd tests: Fix link error on MSVC.
39560         * modules/unistd-c++-tests (Makefile.am): Link test-unistd-c++ against
39561         $(LIB_GETLOGIN).
39563 2019-12-11  Bruno Haible  <bruno@clisp.org>
39565         doc: Document that ISO C or POSIX substitutes are supported in C++ mode.
39566         * doc/gnulib-intro.texi (Various Kinds of Modules): Document that ISO C
39567         and POSIX substitutes are supported in C++ mode.
39568         * NEWS: Likewise.
39570 2019-12-11  Bruno Haible  <bruno@clisp.org>
39572         stddef: Fix compilation error in C++ mode on MSVC.
39573         * lib/stddef.in.h (max_align_t): With MSVC in C++ mode, don't define it;
39574         instead, include <cstddef>.
39576 2019-12-11  Bruno Haible  <bruno@clisp.org>
39578         unistd: Fix compilation error in C++ mode on MSVC.
39579         * lib/unistd.in.h: Don't do include[_next] <unistd.h> if the platform
39580         does not have <unistd.h>.
39582 2019-12-11  Bruno Haible  <bruno@clisp.org>
39584         locale: Fix compilation error in C++ mode on MSVC.
39585         * m4/locale_h.m4 (gl_LOCALE_H): Don't set REPLACE_STRUCT_LCONV on MSVC.
39586         * lib/locale.in.h (int_p_cs_precedes, int_p_sign_posn,
39587         int_p_sep_by_space, int_n_cs_precedes, int_n_sign_posn,
39588         int_n_sep_by_space): Define as macros on MSVC.
39590 2019-12-11  Bruno Haible  <bruno@clisp.org>
39592         wchar: Fix compilation error in C++ mode on MSVC.
39593         * lib/wchar.in.h (mbstate_t): Don't override on MSVC.
39595 2019-12-11  Bruno Haible  <bruno@clisp.org>
39597         pthread-thread: Fix compilation error in C++ mode on MSVC.
39598         * lib/pthread.in.h (pthread_exit): Don't use _Noreturn in the
39599         _GL_CXXALIAS_RPL invocation.
39601 2019-12-08  Bruno Haible  <bruno@clisp.org>
39603         Fix compilation errors in C++ mode on Haiku.
39604         * lib/stdio.in.h (vdprintf): Disable _GL_CXXALIASWARN invocation on
39605         non-glibc systems.
39606         * lib/spawn.in.h (posix_spawnattr_getschedpolicy,
39607         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
39608         posix_spawnattr_setschedparam): Likewise.
39609         * lib/stdlib.in.h (random, initstate_r, setstate_r): Use
39610         _GL_CXXALIAS_SYS_CAST instead of _GL_CXXALIAS_SYS.
39611         * lib/unistd.in.h (usleep): Likewise.
39613 2019-12-08  Bruno Haible  <bruno@clisp.org>
39615         Fix compilation errors in 32-bit C++ mode on HP-UX 11/ia64.
39616         * m4/largefile.m4 (gl_SET_LARGEFILE_SOURCE): New macro.
39617         * modules/fseeko (configure.ac-early): Require it instead of
39618         AC_FUNC_FSEEKO.
39619         * modules/ftello (configure.ac-early): Likewise.
39620         * modules/fflush (configure.ac-early): Likewise.
39622 2019-12-08  Bruno Haible  <bruno@clisp.org>
39624         Fix compilation error in C++ mode on HP-UX 11.
39625         * lib/unistd.in.h (getpagesize): Declare on HP-UX.
39626         * doc/glibc-functions/getpagesize.texi: Mention the HP-UX problem.
39628 2019-12-08  Bruno Haible  <bruno@clisp.org>
39630         Fix compilation errors on HP-UX 11/ia64.
39631         * lib/math.in.h (copysignf, fmaf, fma): Undefine before
39632         _GL_FUNCDECL_SYS.
39634 2019-12-08  Bruno Haible  <bruno@clisp.org>
39636         Fix compilation error in C++ mode on OpenBSD.
39637         * lib/signal.in.h (signal): Declare on OpenBSD.
39639 2019-12-08  Bruno Haible  <bruno@clisp.org>
39641         math tests: Don't fail if isfinite, isinf, isnan, signbit is a macro.
39642         * tests/test-math-c++.cc (isfinite, isinf, isnan, signbit): Use #warning
39643         instead of #error.
39645 2019-12-08  Bruno Haible  <bruno@clisp.org>
39647         Fix compilation errors in C++ mode on FreeBSD.
39648         * lib/pthread.in.h (pthread_exit): Remove _Noreturn from prototype.
39649         * tests/test-pthread-c++.cc (GNULIB_NAMESPACE::pthread_exit): Likewise.
39650         * lib/threads.in.h (thrd_exit): Likewise.
39651         * tests/test-threads-c++.cc (GNULIB_NAMESPACE::thrd_exit): Likewise.
39653 2019-12-08  Bruno Haible  <bruno@clisp.org>
39655         Fix compilation errors in C++ mode on macOS and FreeBSD.
39656         * lib/math.in.h (isfinite, isinf, isnan, signbit): In C++ mode on macOS
39657         or FreeBSD with clang, use the approach without C preprocessor macro.
39659 2019-12-07  Bruno Haible  <bruno@clisp.org>
39661         Fix compilation errors in C++ mode on AIX with xlclang++.
39662         Reported by Christian Biesinger <cbiesinger@google.com> in
39663         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00009.html>.
39664         * lib/wchar.in.h (mbstate_t): Don't override on AIX.
39666 2019-12-07  Bruno Haible  <bruno@clisp.org>
39668         Document compilation error in C++ mode on NetBSD 8.0.
39669         * doc/posix-headers/monetary.texi: Mention the NetBSD bug.
39671 2019-12-07  Bruno Haible  <bruno@clisp.org>
39673         Fix compilation errors in C++ mode on Solaris 10.
39674         * m4/stdbool.m4 (AM_STDBOOL_H): Require AC_CANONICAL_HOST. Set STDBOOL_H
39675         to non-empty on Solaris with a non-GCC compiler.
39676         * doc/posix-headers/stdbool.texi: Mention the Solaris issue.
39678 2019-12-07  Bruno Haible  <bruno@clisp.org>
39680         Reword NEWS entry.
39681         * NEWS: Reword the latest NEWS entry.
39683 2019-12-05  Pino Toscano  <ptoscano@redhat.com>
39685         Move xstrtol_fatal to a new xstrtol-error module.
39686         * lib/xstrtol.h: Stop including <getopt.h>.
39687         (xstrtol_fatal): Move ...
39688         * lib/xstrtol-error.h: ... here.  New file.
39689         * lib/xstrtol-error.c: Include xstrtol-error.h instead of xstrtol.h.
39690         * tests/test-xstrtol.c: Likewise.
39691         * modules/xstrtol (Files): Remove lib/xstrtol-error.c.
39692         (Depends-on): Remove exitfail, error, getopt-gnu, and gettext-h.
39693         (Makefile.am): Remove xstrtol-error.c from lib_SOURCES.
39694         * modules/xstrtol-error: New file.
39695         * modules/xstrtol-tests (Depends-on): Add xstrtol-error.
39696         * MODULES.html.sh: Add xstrtol-error.
39697         * NEWS: Document the change.
39699 2019-12-06  Paul Eggert  <eggert@cs.ucla.edu>
39701         nstrftime: better width support for %N, %z
39702         * lib/nstrftime.c (width_add, width_add1, width_cpy):
39703         New macros, which generalize ‘add’, ‘add1’, ‘cpy’ by adding
39704         a new WIDTH parameter.
39705         (add, add1, cpy): Use these macros.
39706         (width_add): Do not treat digits == 0 as a special case,
39707         do not pad if padding is ‘-’, and do not use a negative width.
39708         (__strftime_internal): Redo formatting of nanoseconds and numeric
39709         timezones to avoid buffer misuse in unusual cases, and so that
39710         widths make more sense.  Add support for widths greater than 9 to
39711         the %N format; they are zero filled on the right.
39712         * tests/test-nstrftime.c (posixtm_test): Add a %12N test.
39714 2019-12-05  Bruno Haible  <bruno@clisp.org>
39716         Fix compilation errors in C++ mode on Solaris 10 and Solaris 11.
39717         * m4/isfinite.m4 (gl_ISFINITE): Require AC_CANONICAL_HOST. On Solaris,
39718         set REPLACE_ISFINITE to 1.
39719         * m4/isinf.m4 (gl_ISINF): Require AC_CANONICAL_HOST. On Solaris, set
39720         REPLACE_ISINF to 1.
39721         * m4/signbit.m4 (gl_SIGNBIT): On Solaris, set REPLACE_SIGNBIT to 1.
39722         * lib/pthread.in.h (pthread_create, pthread_once, pthread_key_create):
39723         Use _GL_CXXALIAS_SYS_CAST instead of _GL_CXXALIAS_SYS.
39724         * lib/threads.in.h (call_once): Likewise.
39725         * lib/iconv.in.h (iconv): Likewise.
39727 2019-12-05  Bruno Haible  <bruno@clisp.org>
39729         wchar: Add more C++ tests.
39730         Reported by Christian Biesinger <cbiesinger@google.com> in
39731         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00009.html>.
39732         * tests/test-wchar-c++3.cc: New file.
39733         * modules/wchar-c++-tests (Files): Add it.
39734         (Makefile.am): Compile it.
39736 2019-12-05  Bruno Haible  <bruno@clisp.org>
39738         Add more C++ tests.
39740         assert-h: Add C++ tests.
39741         * tests/test-assert-h-c++.cc: New file.
39742         * tests/test-assert-h-c++2.cc: New file.
39743         * modules/assert-h-c++-tests: New file.
39744         * modules/assert-h-tests: New file.
39746         ctype: Add C++ tests.
39747         * tests/test-ctype-c++.cc: New file.
39748         * tests/test-ctype-c++2.cc: New file.
39749         * modules/ctype-c++-tests: New file.
39750         * modules/ctype-tests (Depends-on): Add ctype-c++-tests.
39752         errno: Add C++ tests.
39753         * tests/test-errno-c++.cc: New file.
39754         * tests/test-errno-c++2.cc: New file.
39755         * modules/errno-c++-tests: New file.
39756         * modules/errno-tests (Depends-on): Add errno-c++-tests.
39758         float: Add C++ tests.
39759         * tests/test-float-c++.cc: New file.
39760         * tests/test-float-c++2.cc: New file.
39761         * modules/float-c++-tests: New file.
39762         * modules/float-tests (Depends-on): Add float-c++-tests.
39764         inttypes: Add more C++ tests.
39765         * tests/test-inttypes-c++2.cc: New file.
39766         * modules/inttypes-c++-tests (Files): Add it.
39767         (Makefile.am): Compile it.
39769         limits-h: Add C++ tests.
39770         * tests/test-limits-h-c++.cc: New file.
39771         * tests/test-limits-h-c++2.cc: New file.
39772         * modules/limits-h-c++-tests: New file.
39773         * modules/limits-h-tests (Depends-on): Add limits-h-c++-tests.
39775         stdarg: Add C++ tests.
39776         * tests/test-stdarg-c++.cc: New file.
39777         * tests/test-stdarg-c++2.cc: New file.
39778         * modules/stdarg-c++-tests: New file.
39779         * modules/stdarg-tests: New file.
39781         stdbool: Add C++ tests.
39782         * tests/test-stdbool-c++.cc: New file.
39783         * tests/test-stdbool-c++2.cc: New file.
39784         * modules/stdbool-c++-tests: New file.
39785         * modules/stdbool-tests (Depends-on): Add stdbool-c++-tests.
39787         stddef: Add C++ tests.
39788         * tests/test-stddef-c++.cc: New file.
39789         * tests/test-stddef-c++2.cc: New file.
39790         * modules/stddef-c++-tests: New file.
39791         * modules/stddef-tests (Depends-on): Add stddef-c++-tests.
39793         stdint: Add C++ tests.
39794         * tests/test-stdint-c++.cc: New file.
39795         * tests/test-stdint-c++2.cc: New file.
39796         * modules/stdint-c++-tests: New file.
39797         * modules/stdint-tests (Depends-on): Add stdint-c++-tests.
39799         wchar: Add more C++ tests.
39800         * tests/test-wchar-c++2.cc: New file.
39801         * modules/wchar-c++-tests (Files): Add it.
39802         (Makefile.am): Compile it.
39804         wctype-h: Add more C++ tests.
39805         * tests/test-wctype-h-c++2.cc: New file.
39806         * modules/wctype-h-c++-tests (Files): Add it.
39807         (Makefile.am): Compile it.
39809 2019-12-04  Bruno Haible  <bruno@clisp.org>
39811         Fix compilation errors in C++ mode with xlclang++ on AIX.
39812         * lib/math.in.h (expm1l, fmal, remainderl, roundl): Don't redeclare in
39813         C++ mode on AIX.
39814         (isfinite, signbit): In C++ mode on AIX with clang, use the approach
39815         without C preprocessor macro.
39816         * lib/pthread.in.h (pthread_exit): Use _GL_CXXALIAS_SYS_CAST instead of
39817         _GL_CXXALIAS_SYS.
39818         * lib/threads.in.h (thrd_exit): Likewise.
39820 2019-12-04  Bruno Haible  <bruno@clisp.org>
39822         Fix compilation error in C++ mode on Solaris 11 OpenIndiana.
39823         * lib/wchar.in.h (wcsnrtombs): Force declaration in C++ mode on Solaris.
39824         * doc/posix-functions/wcsnrtombs.texi: Mention the issue.
39826 2019-12-04  Bruno Haible  <bruno@clisp.org>
39828         Disable more _GL_CXXALIASWARN on all platforms other than glibc systems.
39829         * lib/wchar.in.h (wcsnrtombs, wcwidth, wcswidth): Disable
39830         _GL_CXXALIASWARN invocation on non-glibc systems.
39831         * lib/wctype.in.h (iswalnum, iswalpha, iswcntrl, iswdigit, iswgraph,
39832         iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit, wctype,
39833         iswctype, towlower, towupper): Likewise.
39835 2019-12-03  Bruno Haible  <bruno@clisp.org>
39837         Avoid hassles caused by [[noreturn]] in C++.
39838         Reported by Christian Biesinger <cbiesinger@google.com> in
39839         <https://lists.gnu.org/archive/html/bug-gnulib/2019-12/msg00010.html>.
39840         * m4/gnulib-common.m4 (gl_COMMON_BODY): Disable the use of [[noreturn]].
39841         * lib/_Noreturn.h: Likewise.
39843 2019-12-02  Bruno Haible  <bruno@clisp.org>
39845         Fix mistakes in --enable-threads=isoc fixes from 2019-12-01.
39846         * m4/pthread-mutex.m4 (gl_PTHREAD_MUTEX): Use LIBPMULTITHREAD, not
39847         LIBMULTITHREAD.
39848         * m4/pthread-rwlock.m4 (gl_PTHREAD_RWLOCK): Likewise.
39849         * m4/pthread-thread.m4 (gl_PTHREAD_THREAD): Likewise.
39850         * m4/timer_time.m4 (gl_TIMER_TIME): Likewise. Require gl_PTHREADLIB, not
39851         gl_THREADLIB.
39852         * modules/timer-time (Depends-on): Add pthread-h. Remove threadlib.
39854 2019-12-02  Bruno Haible  <bruno@clisp.org>
39856         Fix some more link errors with --enable-threads=isoc.
39857         * modules/pthread-mutex (Depends-on): Test $gl_threads_api differently.
39858         * modules/pthread-rwlock (Depends-on): Likewise.
39860 2019-12-02  Bruno Haible  <bruno@clisp.org>
39862         Fix link errors with --enable-threads=posix on AIX.
39863         * modules/string-c++-tests (Makefile.am): Link the test-string-c++
39864         program with $(LIBTHREAD).
39865         * modules/wchar-c++-tests (Makefile.am): Link the test-wchar-c++
39866         program with $(LIBTHREAD).
39868 2019-12-02  Bruno Haible  <bruno@clisp.org>
39870         Fix link errors with --enable-threads=posix on AIX.
39871         * modules/mbrtowc (Link): New section.
39872         * modules/acl (Link): Likewise.
39873         * modules/argmatch (Link): Likewise.
39874         * modules/backup-rename (Link): Likewise.
39875         * modules/backupfile (Link): Likewise.
39876         * modules/closein (Link): Likewise.
39877         * modules/closeout (Link): Likewise.
39878         * modules/copy-file (Link): Likewise.
39879         * modules/csharpcomp (Link): Likewise.
39880         * modules/csharpexec (Link): Likewise.
39881         * modules/dfa (Link): Likewise.
39882         * modules/exclude (Link): Likewise.
39883         * modules/fnmatch (Link): Likewise.
39884         * modules/fnmatch-gnu (Link): Likewise.
39885         * modules/fnmatch-posix (Link): Likewise.
39886         * modules/glob (Link): Likewise.
39887         * modules/human (Link): Likewise.
39888         * modules/javacomp (Link): Likewise.
39889         * modules/javaexec (Link): Likewise.
39890         * modules/javaversion (Link): Likewise.
39891         * modules/mbfile (Link): Likewise.
39892         * modules/mbiter (Link): Likewise.
39893         * modules/mbmemcasecmp (Link): Likewise.
39894         * modules/mbmemcasecoll (Link): Likewise.
39895         * modules/mbrlen (Link): Likewise.
39896         * modules/mbscasecmp (Link): Likewise.
39897         * modules/mbscasestr (Link): Likewise.
39898         * modules/mbschr (Link): Likewise.
39899         * modules/mbscspn (Link): Likewise.
39900         * modules/mbsinit (Link): Likewise.
39901         * modules/mbslen (Link): Likewise.
39902         * modules/mbsncasecmp (Link): Likewise.
39903         * modules/mbsnlen (Link): Likewise.
39904         * modules/mbsnrtowcs (Link): Likewise.
39905         * modules/mbspbrk (Link): Likewise.
39906         * modules/mbspcasecmp (Link): Likewise.
39907         * modules/mbsrchr (Link): Likewise.
39908         * modules/mbsrtowcs (Link): Likewise.
39909         * modules/mbssep (Link): Likewise.
39910         * modules/mbsspn (Link): Likewise.
39911         * modules/mbsstr (Link): Likewise.
39912         * modules/mbstok_r (Link): Likewise.
39913         * modules/mbswidth (Link): Likewise.
39914         * modules/mbuiter (Link): Likewise.
39915         * modules/mkdir-p (Link): Likewise.
39916         * modules/propername (Link): Likewise.
39917         * modules/quote (Link): Likewise.
39918         * modules/quotearg (Link): Likewise.
39919         * modules/quotearg-simple (Link): Likewise.
39920         * modules/regex-quote (Link): Likewise.
39921         * modules/rpmatch (Link): Likewise.
39922         * modules/sh-quote (Link): Likewise.
39923         * modules/system-quote (Link): Likewise.
39924         * modules/trim (Link): Likewise.
39925         * modules/unistdio/ulc-asnprintf (Link): Likewise.
39926         * modules/unistdio/ulc-fprintf (Link): Likewise.
39927         * modules/unistdio/ulc-vasnprintf (Link): Likewise.
39928         * modules/unistdio/ulc-vasprintf (Link): Likewise.
39929         * modules/unistdio/ulc-vfprintf (Link): Likewise.
39930         * modules/unistdio/ulc-vsnprintf (Link): Likewise.
39931         * modules/unistdio/ulc-vsprintf (Link): Likewise.
39932         * modules/xfreopen (Link): Likewise.
39933         * modules/xmemcoll (Link): Likewise.
39934         * modules/yesno (Link): Likewise.
39935         * modules/acl-tests (Makefile.am): Link the programs with $(LIBTHREAD).
39936         * modules/argmatch-tests (Makefile.am): Likewise.
39937         * modules/closein-tests (Makefile.am): Likewise.
39938         * modules/copy-file-tests (Makefile.am): Likewise.
39939         * modules/dfa-tests (Makefile.am): Likewise.
39940         * modules/fnmatch-tests (Makefile.am): Likewise.
39941         * modules/glob-tests (Makefile.am): Likewise.
39942         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
39943         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
39944         * modules/mbrtowc-tests (Makefile.am): Likewise.
39945         * modules/mbscasecmp-tests (Makefile.am): Likewise.
39946         * modules/mbscasestr-tests (Makefile.am): Likewise.
39947         * modules/mbschr-tests (Makefile.am): Likewise.
39948         * modules/mbscspn-tests (Makefile.am): Likewise.
39949         * modules/mbsinit-tests (Makefile.am): Likewise.
39950         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
39951         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
39952         * modules/mbspbrk-tests (Makefile.am): Likewise.
39953         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
39954         * modules/mbsrchr-tests (Makefile.am): Likewise.
39955         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
39956         * modules/mbsspn-tests (Makefile.am): Likewise.
39957         * modules/mbsstr-tests (Makefile.am): Likewise.
39958         * modules/quotearg-tests (Makefile.am): Likewise.
39959         * modules/quotearg-simple-tests (Makefile.am): Likewise.
39960         * modules/readtokens-tests (Makefile.am): Likewise.
39961         * modules/regex-quote-tests (Makefile.am): Likewise.
39962         * modules/sh-quote-tests (Makefile.am): Likewise.
39963         * modules/system-quote-tests (Makefile.am): Likewise.
39964         * modules/unistdio/ulc-asnprintf-tests (Makefile.am): Likewise.
39965         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
39966         * modules/unistdio/ulc-vasprintf-tests (Makefile.am): Likewise.
39967         * modules/unistdio/ulc-vsnprintf-tests (Makefile.am): Likewise.
39968         * modules/unistdio/ulc-vsprintf-tests (Makefile.am): Likewise.
39969         * modules/yesno-tests (Makefile.am): Likewise.
39971 2019-12-02  Bruno Haible  <bruno@clisp.org>
39973         Simplify link sections.
39974         * modules/threadlib (Link): Stop mentioning LTLIBTHREAD.
39975         * modules/lock (Link): Likewise.
39976         * modules/cond (Link): Likewise.
39977         * modules/tls (Link): Likewise.
39978         * modules/yield (Link): Likewise.
39979         * modules/regex (Link): Likewise.
39980         * modules/localename (Link): Likewise.
39981         * modules/unicase/locale-language (Link): Likewise.
39982         * modules/thread (Link): Stop mentioning LTLIBMULTITHREAD.
39984 2019-12-02  Bruno Haible  <bruno@clisp.org>
39986         thread tests: Avoid link error with --enable-threads=isoc+posix on AIX.
39987         * tests/test-thread_self.c (main): Disable test on AIX.
39989 2019-12-01  Bruno Haible  <bruno@clisp.org>
39991         pthread-h: Fix link errors with --enable-threads=isoc on AIX.
39992         * m4/threadlib.m4 (gl_ANYTHREADLIB_EARLY): New macro, extracted from
39993         gl_THREADLIB_EARLY_BODY.
39994         (gl_THREADLIB_EARLY_BODY): Invoke it.
39995         (gl_PTHREADLIB_BODY): New macro, extracted from gl_THREADLIB_BODY.
39996         (gl_THREADLIB_BODY): Invoke it.
39997         (gl_PTHREADLIB): New macro.
39998         * m4/pthread_h.m4 (gl_PTHREAD_H): Require gl_PTHREADLIB. Require
39999         gl_THREADLIB and test $gl_threads_api only if module 'threadlib' is
40000         present. Define LIB_PTHREAD using LIBPMULTITHREAD, not LIBMULTITHREAD.
40001         * modules/pthread-h (Files): Add threadlib.m4.
40002         (Depends-on): Remove threadlib.
40003         (configure.ac-early): Invoke gl_ANYTHREADLIB_EARLY. Don't set _REENTRANT
40004         and _THREAD_SAFE here.
40005         (Link): Use LIBPTHREAD, not LIBTHREAD.
40006         * modules/pthread-thread (Link): Use LIBPMULTITHREAD, not
40007         LIBMULTITHREAD.
40008         * modules/pthread-once (Link): Likewise.
40009         * modules/pthread-mutex (Link): Likewise.
40010         * modules/pthread-rwlock (Link): Likewise.
40011         * modules/pthread-cond (Link): Likewise.
40012         * modules/pthread-tss (Link): Likewise.
40013         * modules/pthread-spin (Link): Likewise.
40014         * modules/pthread (Link): Likewise.
40015         * modules/pthread-h-c++-tests (test_pthread_c___LDADD): Likewise.
40016         * modules/pthread-thread-tests (test_pthread_thread_LDADD): Likewise.
40017         * modules/pthread-once-tests (test_pthread_once1_LDADD,
40018         test_pthread_once2_LDADD): Likewise.
40019         * modules/pthread-mutex-tests (test_pthread_mutex_LDADD): Likewise.
40020         * modules/pthread-rwlock-tests (test_pthread_rwlock_LDADD): Likewise.
40021         * modules/pthread-cond-tests (test_pthread_cond_LDADD): Likewise.
40022         * modules/pthread-tss-tests (test_pthread_tss_LDADD): Likewise.
40024 2019-12-01  Bruno Haible  <bruno@clisp.org>
40026         cond: State linking requirements.
40027         * modules/cond (Link): New section.
40029 2019-12-01  Bruno Haible  <bruno@clisp.org>
40031         threadlib: Remove unnecessary file (left over from 2019-07-06).
40032         * modules/threadlib (Files): Remove config.rpath.
40034 2019-11-29  Tim Rühsen  <tim.ruehsen@gmx.de>
40036         gnulib-tool.py: Fix libgnu_la_LDFLAGS section in generated Makefile.am.
40037         Reported by Dagobert Michelsen <dam@opencsw.org> in
40038         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00086.html>.
40039         * pygnulib/GLModuleSystem.py (getLink): Don't join the parts. Return a
40040         list of strings instead of one string.
40041         * pygnulib/GLEmiter.py (lib_Makefile_am): Adapt accordingly.
40042         * pygnulib/GLImport.py (execute): Likewise.
40044 2019-11-27  Bruno Haible  <bruno@clisp.org>
40046         openpty, forkpty: Fix build error on Solaris 11.4.
40047         * m4/pty_h.m4 (gl_PTY_H): Test for termios.h. Look for the declarations
40048         also in <termios.h>.
40049         * m4/pty.m4 (gl_FUNC_FORKPTY, gl_FUNC_OPENPTY): Look for the declaration
40050         of the function also in <termios.h>.
40051         * doc/glibc-functions/openpty.texi: Mention the Solaris 11.4 problems.
40052         * doc/glibc-functions/forkpty.texi: Likewise.
40054 2019-11-27  Bruno Haible  <bruno@clisp.org>
40056         New options --enable-threads=isoc and --enable-threads=isoc+posix.
40057         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Accept the options
40058         --enable-threads=isoc and --enable-threads=isoc+posix.
40059         (gl_THREADLIB_BODY): Test whether the ISO C threads API is available.
40060         When both the ISO C and the POSIX threads API are available, choose
40061         USE_ISOC_AND_POSIX_THREADS instead of USE_POSIX_THREADS if
40062         --enable-threads=isoc+posix was specified. When only the ISO C threads
40063         API is available and --enable-threads=iso was specified, choose
40064         USE_ISOC_THREADS.
40065         * lib/glthread/lock.h: Add new code for USE_ISOC_THREADS ||
40066         USE_ISOC_AND_POSIX_THREADS.
40067         * lib/glthread/lock.c: Likewise.
40068         * lib/glthread/cond.h: Likewise.
40069         * lib/glthread/cond.c: Likewise.
40070         * lib/glthread/tls.h: Likewise.
40071         * lib/glthread/tls.c: Likewise.
40072         * lib/glthread/yield.h: Likewise.
40073         * lib/glthread/thread.h: Add new code for USE_ISOC_THREADS. Treat
40074         USE_ISOC_AND_POSIX_THREADS like USE_POSIX_THREADS.
40075         * lib/glthread/thread.c: Likewise.
40076         * lib/glthread/threadlib.c: Likewise.
40077         * tests/test-lock.c: Save and restore the values of USE_ISOC_THREADS and
40078         USE_ISOC_AND_POSIX_THREADS.
40079         * tests/test-cond.c: Consider USE_ISOC_THREADS and
40080         USE_ISOC_AND_POSIX_THREADS.
40081         * tests/test-tls.c: Likewise.
40082         * tests/test-thread_create.c (main): Likewise.
40083         * tests/test-pthread-cond.c: Likewise.
40084         * tests/test-pthread-mutex.c: Likewise.
40085         * tests/test-pthread-once2.c: Likewise.
40086         * tests/test-pthread-rwlock.c: Likewise.
40087         * tests/test-pthread-tss.c: Likewise.
40088         * tests/test-pthread_sigmask2.c: Treat USE_ISOC_AND_POSIX_THREADS like
40089         USE_POSIX_THREADS.
40091 2019-11-24  Bruno Haible  <bruno@clisp.org>
40093         mbrtowc: Modernize autoconf test.
40094         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Require
40095         gt_LOCALE_FR_UTF8. If a traditional Japanese locale is not available,
40096         try a UTF-8 locale.
40097         * doc/posix-functions/mbrtowc.texi: Update info about AIX.
40099 2019-11-24  Bruno Haible  <bruno@clisp.org>
40101         Fix errors in C++ mode on mingw.
40102         * lib/arpa_inet.in.h (inet_ntop, inet_pton): Use _GL_CXXALIAS_SYS_CAST
40103         instead of _GL_CXXALIAS_SYS.
40104         * lib/signal.in.h (pthread_sigmask): Likewise.
40105         * lib/spawn.in.h (posix_spawn_file_actions_addopen,
40106         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
40107         Likewise.
40108         * lib/wchar.in.h (btowc): Likewise.
40110 2019-11-24  Bruno Haible  <bruno@clisp.org>
40112         sys_time: Fix errors in C++ mode on mingw.
40113         * lib/sys_time.in.h (timeval): Restore the redirection
40114         '#define timeval rpl_timeval', for when the symbol timeval is being used
40115         outside the 'gnulib' namespace.
40116         * lib/sys_select.in.h (select): In C++, write 'timeval', not
40117         'struct timeval'.
40119 2019-11-24  Bruno Haible  <bruno@clisp.org>
40121         iswctype: Fix errors in C++ mode on mingw.
40122         * lib/wctype.in.h (rpl_iswctype): Override if GNULIB_OVERRIDES_WINT_T
40123         is 1.
40124         * lib/iswctype.c (iswctype): Add another implementation, for the
40125         GNULIB_defined_wint_t case.
40126         * modules/iswctype (configure.ac): Compile iswctype.c also if
40127         GNULIB_OVERRIDES_WINT_T is 1.
40129 2019-11-24  Bruno Haible  <bruno@clisp.org>
40131         windows-timedmutex: Fix errors in C++ mode on mingw.
40132         * lib/windows-timedmutex.h: Add closing brace.
40134 2019-11-24  Bruno Haible  <bruno@clisp.org>
40136         Fix errors in C++ mode on Cygwin.
40137         * lib/sys_wait.in.h (waitpid): Use _GL_CXXALIAS_SYS_CAST instead of
40138         _GL_CXXALIAS_SYS.
40140 2019-11-24  Bruno Haible  <bruno@clisp.org>
40142         time_r: Fix for mingw (regression from 2019-11-16).
40143         * m4/time_r.m4 (gl_TIME_R): Revert to using AC_CHECK_FUNCS_ONCE. Use the
40144         AC_LINK_IFELSE test only if the function does not appear to exist.
40146 2019-11-24  Bruno Haible  <bruno@clisp.org>
40148         wcstok: Add tests.
40149         * tests/test-wcstok.c: New file.
40150         * modules/wcstok-tests: New file.
40152 2019-11-24  Bruno Haible  <bruno@clisp.org>
40154         wcstok: Work around wrong signature on native Windows.
40155         * lib/wchar.in.h (wcstok): Override when REPLACE_WCSTOK is 1.
40156         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Check for signature of wcstok. Set
40157         REPLACE_WCSTOK.
40158         * m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSTOK.
40159         * modules/wchar (Makefile.am): Substitute REPLACE_WCSTOK.
40160         * modules/wcstok (Depends-on, configure.ac): Consider REPLACE_WCSTOK.
40161         * doc/posix-functions/wcstok.texi: Mention the problem.
40163 2019-11-22  Paul Eggert  <eggert@cs.ucla.edu>
40165         intprops: INT_MULTIPLY_WRAPV speedup for GCC 8.4+
40166         * lib/intprops.h (INT_MULTIPLY_WRAPV): If GCC 8.x where 4 <= x,
40167         remove workaround for GCC bug 91450 as the bug should be fixed
40168         there too.
40170 2019-11-21  Bruno Haible  <bruno@clisp.org>
40172         Disable many _GL_CXXALIASWARN on all platforms other than glibc systems.
40173         Reported by Christian Biesinger <cbiesinger@google.com> in
40174         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00066.html>.
40175         * lib/fnmatch.in.h (fnmatch): Disable _GL_CXXALIASWARN invocation on
40176         non-glibc systems.
40177         * lib/locale.in.h (localeconv, setlocale): Likewise.
40178         * lib/math.in.h (cbrt, ceil, copysign, exp2, expm1, floor, fma, fmod,
40179         frexp, hypot, ilogb, log, log10, log1p, log2, logb, modf, remainder,
40180         rint, round, trunc): Likewise.
40181         * lib/monetary.in.h (strfmon_l): Likewise.
40182         * lib/pthread.in.h (pthread_mutexattr_getrobust,
40183         pthread_mutexattr_setrobust, pthread_mutex_lock, pthread_spin_init,
40184         pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock,
40185         pthread_spin_destroy): Likewise.
40186         * lib/signal.in.h (raise, signal): Likewise.
40187         * lib/stdio.in.h (fclose, fflush, fgetc, fgets, fopen, fprintf, fputc,
40188         fputs, fread, freopen, fscanf, fseek, ftell, fwrite, getc, getchar,
40189         perror, printf, putc, putchar, puts, remove, rename, scanf, sprintf,
40190         tmpfile, vfprintf, vprintf, vsprintf): Likewise.
40191         * lib/stdlib.in.h (calloc, malloc, mbtowc, realloc, strtod, wctomb):
40192         Likewise.
40193         * lib/string.in.h (memchr, strncat, strpbrk, strstr, strerror):
40194         Likewise.
40195         * lib/time.in.h (mktime, localtime, ctime, strftime): Likewise.
40196         * lib/wchar.in.h (btowc, wctob, mbsinit, mbrtowc, mbrlen, mbsrtowcs,
40197         wcrtomb, wcsrtombs, wmemchr, wmemcmp, wmemcpy, wmemmove, wmemset,
40198         wcslen, wcscpy, wcsncpy, wcscat, wcsncat, wcscmp, wcsncmp, wcscoll,
40199         wcsxfrm, wcschr, wcsrchr, wcscspn, wcsspn, wcspbrk, wcsstr, wcstok,
40200         wcsftime): Likewise.
40201         * lib/wctype.in.h (iswblank, wctrans, towctrans): Likewise.
40203 2019-11-21  Bruno Haible  <bruno@clisp.org>
40205         Fix various errors in _GL_CXXALIAS_SYS invocations.
40206         * lib/locale.in.h (freelocale): Use _GL_CXXALIAS_SYS_CAST instead of
40207         _GL_CXXALIAS_SYS.
40208         * lib/pthread.in.h (pthread_mutexattr_gettype,
40209         pthread_mutexattr_getrobust): Likewise.
40210         * lib/stdlib.in.h (srandom, initstate, setstate): Likewise.
40211         * lib/sys_socket.in.h (recv, send): Likewise.
40212         * lib/unistd.in.h (getdtablesize): Likewise.
40213         * lib/sys_select.in.h (select): In C++, write 'timeval' instead of
40214         'struct timeval'.
40216 2019-11-21  Bruno Haible  <bruno@clisp.org>
40218         math tests: Update after 2019-08-28 change.
40219         * tests/test-math-c++.cc (isfinite, isinf, isnan, signbit): Expect a
40220         return type of 'bool', not 'int'.
40222 2019-11-21  Bruno Haible  <bruno@clisp.org>
40224         pthread-spin: Fix errors in C++ mode.
40225         * m4/pthread-spin.m4 (gl_PTHREAD_SPIN): Mark the pthread_spin_*
40226         functions as nonexistent when <pthread.h> exists but does not define
40227         the pthread_spinlock_t type.
40229 2019-11-21  Bruno Haible  <bruno@clisp.org>
40231         pthread-mutex: Fix errors in C++ mode.
40232         * m4/pthread-mutex.m4 (gl_PTHREAD_MUTEX): Test whether
40233         pthread_mutexattr_getrobust exists. If not, define
40234         PTHREAD_MUTEXATTR_ROBUST_UNIMPLEMENTED.
40235         * lib/pthread-mutex.c (pthread_mutexattr_getrobust,
40236         pthread_mutexattr_setrobust): Define also if <pthread.h> exists but
40237         PTHREAD_MUTEXATTR_ROBUST_UNIMPLEMENTED.
40238         * modules/pthread-mutex (configure.ac): Compile pthread-mutex.c also
40239         when <pthread.h> exists but pthread_mutexattr_getrobust needs a gnulib
40240         definition.
40242 2019-11-19  Bruno Haible  <bruno@clisp.org>
40244         threads-h tests: Fix typo.
40245         * tests/test-threads-c++.cc: Fix references to undefined type 'mtx'.
40247 2019-11-19  Bruno Haible  <bruno@clisp.org>
40249         pthread-thread: Fix prototype of pthread_attr_getdetachstate.
40250         * lib/pthread.in.h (pthread_attr_getdetachstate): Change first parameter
40251         to 'const pthread_attr_t *'.
40252         * lib/pthread-thread.c (pthread_attr_getdetachstate): Likewise.
40253         * tests/test-pthread-c++.cc (pthread_attr_getdetachstate): Likewise.
40255 2019-11-19  Paul Eggert  <eggert@cs.ucla.edu>
40257         intprops: speed up INT_MULTIPLY_WRAPV in GCC 9.3
40258         * lib/intprops.h (INT_MULTIPLY_WRAPV): If GCC 9.3 or later, do not
40259         work around GCC bug 91450 as the bug should be fixed there.
40261 2019-11-18  Paul Eggert  <eggert@cs.ucla.edu>
40263         glob: get closer to glibc glob.c
40264         Omit differences from glibc when the differences don’t matter.
40265         * lib/glob.c [_LIBC]: Include shlib-compat.h.
40266         (__glob) [!_LIBC]: New macro.  All uses of glob changed to __glob.
40267         (glob_lstat): New function.
40268         (glob_in_dir): Use it.
40269         (GLOB_ATTRIBUTE): Define to empty if not already defined.
40270         Use changed.
40272 2019-11-18  Bruno Haible  <bruno@clisp.org>
40274         stdint: Define [u]intptr_t correctly on 64-bit native Windows.
40275         * lib/stdint.in.h (gl_intptr_t, gl_uintptr_t, INTPTR_MIN, INTPTR_MAX,
40276         UINTPTR_MAX): Consider _WIN64.
40277         * tests/test-stdint.c: Verify that [u]intptr_t is large enough to hold
40278         a pointer.
40280 2019-11-18  Bruno Haible  <bruno@clisp.org>
40282         stdint: Fix value of WINT_MAX when we override wint_t.
40283         * lib/stdint.in.h (WINT_MIN, WINT_MAX): Don't override a second time
40284         when GNULIB_OVERRIDES_WINT_T is 1.
40286 2019-11-18  Bruno Haible  <bruno@clisp.org>
40288         vcs-to-changelog: New module.
40289         * modules/vcs-to-changelog: New file.
40290         * MODULES.html.sh (func_all_modules): Add it.
40292 2019-11-01  Siddhesh Poyarekar  <siddhesh@gotplt.org>
40294         vcs-to-changelog: New script to generate ChangeLog-like output.
40295         Discussion:
40296         <https://lists.gnu.org/archive/html/bug-gnulib/2019-10/msg00062.html>
40297         * build-aux/vcs_to_changelog.py: New file.
40298         * build-aux/vcstocl/frontend_c.py: New file.
40299         * build-aux/vcstocl/misc_util.py: New file.
40300         * build-aux/vcstocl/vcs_git.py: New file.
40302 2019-11-18  Bruno Haible  <bruno@clisp.org>
40304         stdint: Avoid triggering a "conflicting types" error on mingw 5.22.
40305         Reported by Keith Marshall <keith@users.osdn.me> in
40306         <https://lists.gnu.org/archive/html/bug-gnulib/2019-10/msg00044.html>
40307         and <https://osdn.net/projects/mingw/ticket/39677>.
40308         * lib/stdint.in.h (intptr_t, uintptr_t): Don't define if the types have
40309         already been defined by mingw's <crtdefs.h>.
40311 2019-11-18  Bruno Haible  <bruno@clisp.org>
40313         gnulib-tool: Fix build error on macOS with --conditional-dependencies.
40314         * gnulib-tool (func_modules_add_dummy): Ignore modules that are
40315         conditionally enabled.
40317 2019-11-18  Bruno Haible  <bruno@clisp.org>
40319         gc: Mirror libgcrypt.m4 from libgcrypt.
40320         * config/srclistvars.sh (LIBGCRYPT): New variable.
40321         * config/srclist.txt: Use it to fetch m4/libgcrypt.m4.
40323 2019-11-17  Bruno Haible  <bruno@clisp.org>
40325         locale, localename: Improve z/OS support.
40326         Reported by Daniel Richard G. in
40327         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00001.html>.
40328         * m4/locale_h.m4 (gl_LOCALE_T): New macro, partially extracted from
40329         gl_LOCALE_H.
40330         (gl_LOCALE_H): Require it.
40331         * m4/localename.m4 (gl_LOCALENAME): Likewise. If locale_t is not
40332         defined, don't even check for newlocale, duplocale, freelocale.
40333         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): Make the test fail when
40334         locale_t is not defined.
40336 2019-11-17  Bruno Haible  <bruno@clisp.org>
40338         havelib: Make libdirstems processing more flexible.
40339         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Set 3 libdirstem
40340         variables: Consider 'lib' always, also on Solaris. Look for lib32 in
40341         addition to lib64. Don't invoke /usr/bin/gcc (reverting the second
40342         patch from 2017-02-19).
40343         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Consider up to 3 additional
40344         libdirs, even when the first one exists as a directory.
40346 2019-11-17  Bruno Haible  <bruno@clisp.org>
40348         havelib: Match the bitness when searching for libraries.
40349         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Define a function
40350         acl_is_expected_elfclass.
40351         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): When testing whether a library
40352         file exists, in ELF, also test whether it has the ELF class that
40353         corresponds to the host's bitness.
40355 2019-11-17  Bruno Haible  <bruno@clisp.org>
40357         host-cpu-c-abi: Add support for unknown CPUs.
40358         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): Set
40359         gl_cv_host_cpu_c_abi_32bit to 'unknown' if we don't know whether it's
40360         32-bit or 64-bit.
40362 2019-11-17  Bruno Haible  <bruno@clisp.org>
40364         havelib: Remove redundant code.
40365         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Remove Solaris specific
40366         test for 64-bit host. Use gl_HOST_CPU_C_ABI_32BIT result instead.
40368 2019-11-17  Bruno Haible  <bruno@clisp.org>
40370         havelib: Fix a bug in dependency processing.
40371         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): During dependency processing
40372         of .la files, don't overwrite the value of additional_libdir for the
40373         next rounds.
40375 2019-11-16  Bruno Haible  <bruno@clisp.org>
40377         wctype-h: When overriding wint_t, override also the related functions.
40378         Reported by Christian Biesinger <cbiesinger@google.com> in
40379         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00027.html>.
40380         * m4/wctype_h.m4 (gl_WCTYPE_H): When GNULIB_OVERRIDES_WINT_T is 1, set
40381         REPLACE_ISWCNTRL to 1.
40382         * lib/wctype.in.h (rpl_iswalnum, rpl_iswalpha, rpl_iswblank,
40383         rpl_iswcntrl, rpl_iswdigit, rpl_iswgraph, rpl_iswlower, rpl_iswprint,
40384         rpl_iswpunct, rpl_iswspace, rpl_iswupper, rpl_iswxdigit, rpl_towlower,
40385         rpl_towupper): New definitions when GNULIB_OVERRIDES_WINT_T is 1.
40386         * doc/posix-headers/wchar.texi: Mention that wint_t is also overridden
40387         on mingw.
40388         * doc/posix-headers/wctype.texi: Likewise.
40390 2019-11-16  Bruno Haible  <bruno@clisp.org>
40392         time_r: Fix for mingw.
40393         Reported by Christian Biesinger <cbiesinger@google.com> in
40394         <https://lists.gnu.org/archive/html/bug-gnulib/2019-11/msg00014.html>.
40395         * lib/time.in.h: On mingw, include <unistd.h>.
40396         * m4/time_r.m4 (gl_TIME_R): On mingw, include <unistd.h> before
40397         <time.h>. Test for localtime_r in a way that works when it is defined
40398         as an inline function.
40400 2019-11-13  Bruno Haible  <bruno@clisp.org>
40402         havelib: Revert last change.
40403         * build-aux/config.rpath: Revert last change. We can add msys2 support
40404         when it has been added to libtool.m4 upstream.
40406 2019-11-09  Paul Eggert  <eggert@cs.ucla.edu>
40408         config: add msys support
40409         Requested by Arnold Robbins in:
40410         https://lists.gnu.org/r/bug-gnulib/2019-11/msg00008.html
40411         He also requested a change to config.guess, which I’ll forward
40412         upstream.
40413         * build-aux/ar-lib (func_file_conv):
40414         * build-aux/compile (func_file_conv):
40415         * build-aux/config.rpath (wl, with_gnu_ld)
40416         (hardcode_libdir_flag_spec, libext, shrext, library_names_spec):
40417         Treat msys like cygwin.
40419 2019-11-06  Paul Eggert  <eggert@cs.ucla.edu>
40421         regex: now back in sync with glibc
40422         * config/srclist.txt: regcomp.c, regex_internal.c, regex_internal.h,
40423         regexec.c got merged into glibc and are now copies again.
40425 2019-10-27  Bruno Haible  <bruno@clisp.org>
40427         host-cpu-c-abi: Recognize i386 and a couple of other CPUs as 32-bit.
40428         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Include i386 in the case
40429         statement.
40430         (gl_HOST_CPU_C_ABI_32BIT): Likewise. Also recognize a couple of other
40431         32-bit CPUs.
40433 2019-10-24  Paul Eggert  <eggert@cs.ucla.edu>
40435         timespec-add, timespec-sub: simplify
40436         * lib/timespec-add.c (timespec_add):
40437         * lib/timespec-sub.c (timespec_sub):
40438         Simplify, now that INT_ADD_WRAPV and INT_SUBTRACT_WRAPV
40439         work on unsigned integers.
40441 2019-10-23  Paul Eggert  <eggert@cs.ucla.edu>
40443         nstrftime: speed up integer overflow checking
40444         * lib/nstrftime.c: Include intprops.h.
40445         (INT_STRLEN_BOUND): Remove, as we can use intprops.h’s defn.
40446         (__strftime_internal): Use INT_MULTIPLY_WRAPV and INT_ADD_WRAPV
40447         instead of doing it by hand.
40448         * modules/nstrftime (Depends-on): Add intprops.
40450         Port better to GCC under macOS
40451         Work around macOS header that has ‘#define __has_builtin(x) 0’
40452         when compiled by GCC.  Apple really, really doesn’t want you to
40453         use GCC, apparently.  Rroblem reported by Akim Demaille in:
40454         https://lists.gnu.org/r/bug-bison/2019-10/msg00071.html
40455         The fix is to not trust __has_builtin when being compiled by
40456         recent-enough GCC.
40457         * lib/intprops.h (__has_builtin)
40458         (_GL_HAS___builtin_add_overflow, _GL_TEMPDEF___has_builtin):
40459         * lib/verify.h (__has_builtin, _GL_HAS___builtin_unreachable)
40460         (_GL_HAS___builtin_trap, _GL_TEMPDEF___has_builtin):
40461         Remove.  All uses removed.
40462         * lib/intprops.h (_GL_HAS_BUILTIN_ADD_OVERFLOW): Use __has_builtin
40463         directly, if defined and if not newer GCC.
40464         * lib/verify.h (_GL_HAS_BUILTIN_TRAP, _GL_HAS_BUILTIN_UNREACHABLE):
40465         New macro, that use __has_builtin directly, if defined and if
40466         not newer GCC.
40467         (assume): Use them.
40469 2019-10-22  Akim Demaille  <akim@lrde.epita.fr>
40471         maintainer-makefile: update rule for argmatch.
40472         * top/maint.mk (sc_prohibit_argmatch_without_use): Add ARGMATCH_DEFINE_GROUP.
40474 2019-10-21  Akim Demaille  <akim@lrde.epita.fr>
40476         bitset: let freeing functions accept NULL.
40477         * lib/bitset.c (bitset_free, bitset_obstack_free): Do nothing if
40478         given NULL.
40479         * lib/bitset.h: Document that.
40480         * doc/bitset.texi: Fix the example, and demonstrate bitset_free.
40482 2019-10-15  Paul Eggert  <eggert@cs.ucla.edu>
40484         inttypes: use more-robust test for int range
40485         This fixes Bison 3.4.2 when built with Oracle Solaris Studio 12.3.
40486         Problem reported by Dagobert Michelsen in:
40487         https://lists.gnu.org/r/bug-gnulib/2019-10/msg00042.html
40488         * lib/inttypes.in.h: Rely only on limits.h when checking
40489         int range.
40491 2019-10-15  Bruno Haible  <bruno@clisp.org>
40493         libtextstyle-optional: Sync with current not-yet-released libtextstyle.
40494         * libtextstyle-optional (styled_ostream_get_hyperlink_ref,
40495         styled_ostream_get_hyperlink_id, styled_ostream_set_hyperlink,
40496         term_ostream_get_hyperlink_ref, term_ostream_get_hyperlink_id,
40497         term_ostream_set_hyperlink): New functions.
40498         (term_styled_ostream_get_hyperlink_ref,
40499         term_styled_ostream_get_hyperlink_id,
40500         term_styled_ostream_set_hyperlink): New function aliases.
40502 2019-10-14  Paul Eggert  <eggert@cs.ucla.edu>
40504         update-copyright: use en dashes in .texi ranges
40505         * build-aux/update-copyright: Match year ranges like "1998--2019",
40506         which are used in the Autoconf manual.  Also, update ranges in
40507         .tex, .texi, and .texinfo files to use en dashes instead of
40508         hyphens.
40510 2019-10-13  Paul Eggert  <eggert@cs.ucla.edu>
40512         * config/srclist.txt: Remove posix/regex_internal.c for now.
40514 2019-10-13  Bruno Haible  <bruno@clisp.org>
40516         git-version-gen: Allow 'snapshot' as .tarball-version contents.
40517         * build-aux/git-version-gen: Don't map non-numeric .tarball-version
40518         contents to the empty string.
40520 2019-10-12  Bruno Haible  <bruno@clisp.org>
40522         intprops tests: Fix compilation errors on HP-UX/ia64 with cc.
40523         * tests/test-intprops.c (main): Disable two more tests when using
40524         HP-UX cc.
40526 2019-10-11  Paul Eggert  <eggert@cs.ucla.edu>
40528         Simplify and regularize regex use of ‘assert’
40529         Also, tell GCC about the asserts even when compiling without
40530         debugging, to give it further optimization opportunities.
40531         * lib/regex_internal.h (DEBUG_ASSERT): New macro.
40532         * lib/regcomp.c (link_nfa_nodes, calc_eclosure)
40533         (parse_expression, parse_bracket_exp):
40534         * lib/regex_internal.c (build_wcs_buffer)
40535         (build_wcs_upper_buffer, re_string_reconstruct)
40536         (re_string_context_at):
40537         * lib/regexec.c (re_search_stub, re_copy_regs)
40538         (re_search_internal, prune_impossible_nodes, check_matching)
40539         (check_halt_state_context, set_regs, sift_states_backward)
40540         (build_sifted_states, transit_state_mb, transit_state_bkref)
40541         (check_arrival_add_next_nodes, check_arrival_expand_ecl)
40542         (match_ctx_add_subtop):
40543         Use it instead of plain ‘assert’.
40545 2019-10-09  Paul Eggert  <eggert@cs.ucla.edu>
40547         regex: omit debug assignment when not debugging
40548         * lib/regexec.c (re_search_internal) [!DEBUG]:
40549         Remove unnecessary assignment.
40551         regex: tell compiler there’s at most 256 arcs out
40552         Partly this is to help the reader (and maybe help GCC);
40553         partly this is to pacify Coverity.
40554         * lib/regex_internal.h: Include verify.h.
40555         * lib/regexec.c (group_nodes_into_DFAstates):
40556         Tell the compiler that ndests cannot exceed SBC_MAX.
40557         * modules/regex (Depends-on): Add ‘verify’.
40559         regex: simplify by assuming C99
40560         * config/srclist.txt: Comment out regex_internal.h and regexec.c
40561         temporarily.
40562         * lib/regex_internal.h (lock_define, re_match_context_t):
40563         Simplify by assuming C99 macros and const.
40564         * lib/regexec.c (re_search_internal): Simplify by assuming C99
40565         initializers.  Remove unnecessary assignment, as mctx is now
40566         safely initialized earlier.
40568         regex: avoid copying of uninitialized storage
40569         * config/srclist.txt: Comment out regcomp.c temporarily.
40570         * lib/regcomp.c (build_charclass_op, create_tree) [! (GCC_LINT||lint)]:
40571         Initialize even when not checking for lint, as the behavior is
40572         arguably undefined otherwise and Coverity warns about it.
40574 2019-10-06  Bruno Haible  <bruno@clisp.org>
40576         access tests: Fix test failure when run as root.
40577         * tests/test-access.c: Include root-uid.h.
40578         (geteuid): Define fallback.
40579         (main): Don't expect that writing to a read-only file would fail when
40580         running as root. Also, remove the created files at the end.
40581         * modules/access-tests (Depends-on): Add root-uid.
40582         (configure.ac): Test whether geteuid exists.
40584 2019-10-06  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
40586         users.txt: add GNU nano
40587         Nano has been making use of gnulib since March 2017, version 2.8.0.
40589 2019-10-05  Paul Eggert  <eggert@cs.ucla.edu>
40591         bootstrap: simplify debugging of wget failures
40592         Problem reported by Tim Rühsen in:
40593         https://lists.gnu.org/r/bug-gnulib/2019-10/msg00000.html
40594         * build-aux/bootstrap (po_download_command_format):
40595         Invoke wget with -nv instead of -q, to make debugging easier.
40597 2019-09-29  Bruno Haible  <bruno@clisp.org>
40599         avltree-list: Fix compilation warning (introduced on 2014-09-16).
40600         * lib/gl_avltree_list.c (gl_avltree_list_check_invariants): Remove
40601         'const' attribute.
40603 2019-09-29  Bruno Haible  <bruno@clisp.org>
40605         fbufmode: Fix compilation error on glibc >= 2.28 systems.
40606         * lib/stdio-impl.h (_IO_UNBUFFERED): Define fallback on glibc >= 2.28.
40608 2019-09-28  Bruno Haible  <bruno@clisp.org>
40610         Update comments that refer to POSIX.
40611         * lib/creat.c, lib/fopen.c, lib/open.c, lib/openat.c: Cite the relevant
40612         sentence about trailing slashes.
40613         * lib/fflush.c: Clarify the reasoning.
40614         * tests/test-fflush2.c: Cite the relevant sentence.
40616 2019-09-28  Bruno Haible  <bruno@clisp.org>
40618         access: Document limitations on Windows.
40619         Suggested by Zaretskii <eliz@gnu.org>.
40620         * doc/posix-functions/access.texi: Mention two limitations on Windows.
40622 2019-09-28  Bruno Haible  <bruno@clisp.org>
40624         findprog-in: Fix comment.
40625         Reported by Eli Zaretskii <eliz@gnu.org>.
40626         * lib/findprog.h (find_in_given_path): Extend description of EACCES
40627         condition.
40628         * lib/stat.c (rpl_stat): Fix typo in comment.
40629         * lib/utime.c (_gl_utimens_windows): Likewise.
40631 2019-09-23  Paul Eggert  <eggert@cs.ucla.edu>
40633         Update URLs and associated text
40634         (Thanks to Bruno Haible for proofreading this patch.)
40635         Prefer https: to http: in URLs where either will do, for the usual
40636         security reasons.  I also updated broken and/or moved URLs
40637         discovered during the process. In a few places I had to resort to
40638         archive.org, since I didn't find the originals elsewhere.
40640 2019-09-15  Paul Smith  <psmith@gnu.org>
40641             Bruno Haible  <bruno@clisp.org>
40643         findprog-in: Set errno when the search fails.
40644         * lib/findprog-in.c: Include <errno.h>.
40645         (find_in_given_path): Set errno before returning NULL.
40646         * lib/findprog.h (find_in_given_path): Update comment accordingly.
40647         Define the term "slash".
40649 2019-09-15  Bruno Haible  <bruno@clisp.org>
40651         findprog, findprog-lgpl, findprog-in: Fix crash on MSVC.
40652         * modules/findprog (Depends-on): Add access.
40653         * modules/findprog-lgpl (Depends-on): Likewise.
40654         * modules/findprog-in (Depends-on): Likewise.
40656 2019-09-15  Bruno Haible  <bruno@clisp.org>
40658         access: Add tests.
40659         * tests/test-access.c: New file.
40660         * modules/access-tests: New file.
40662         access: New module.
40663         * lib/unistd.in.h (access): New declaration.
40664         * lib/access.c: New file.
40665         * m4/access.m4: New file.
40666         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether access is declared.
40667         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ACCESS, REPLACE_ACCESS.
40668         * modules/unistd (Makefile.am): Substitute GNULIB_ACCESS,
40669         REPLACE_ACCESS.
40670         * modules/access: New file.
40671         * tests/test-unistd-c++.cc (access): Check signature.
40672         * doc/posix-functions/access.texi: Mention the new module.
40674 2019-09-15  Bruno Haible  <bruno@clisp.org>
40676         fcntl-h: Fix compilation error of creat.c on MSVC.
40677         * lib/fcntl.in.h: Include <io.h> also when __need_system_fcntl_h is
40678         defined.
40680 2019-09-15  Bruno Haible  <bruno@clisp.org>
40682         creat: Add tests.
40683         * tests/test-creat.c: New file, based on tests/test-open.h.
40684         * modules/creat-tests: New file.
40686         creat: New module.
40687         * lib/fcntl.in.h (creat): New declaration.
40688         * lib/creat.c: New file, based on lib/open.c.
40689         * m4/creat.m4: New file.
40690         * m4/open-slash.m4: New file, extracted from m4/open.m4.
40691         * m4/open.m4 (gl_FUNC_OPEN): Move trailing-slash test to open-slash.m4.
40692         Invoke gl_OPEN_TRAILING_SLASH_BUG.
40693         * modules/open (Files): Add m4/open-slash.m4.
40694         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize GNULIB_CREAT,
40695         REPLACE_CREAT.
40696         * modules/fcntl-h (Makefile.am): Substitute GNULIB_CREAT, REPLACE_CREAT.
40697         * modules/creat: New file.
40698         * tests/test-fcntl-h-c++.cc (creat): Check signature.
40699         * doc/posix-functions/creat.texi: Mention the new module.
40701 2019-09-15  Bruno Haible  <bruno@clisp.org>
40703         open tests: Enhance test.
40704         * tests/test-open.h (test_open): Test the creation of an executable
40705         regular file. Also improve initial cleanup.
40707 2019-09-15  Bruno Haible  <bruno@clisp.org>
40709         intprops tests: Avoid build failure with HP-UX cc.
40710         * tests/test-intprops.c: Disable a check that makes HP cc choke with
40711         "error 4018: Macro param too large after substitution - use -H option.".
40713 2019-09-14  Bruno Haible  <bruno@clisp.org>
40715         Make autoconf tests work with -Werror=implicit-function-declaration.
40716         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Include <wctype.h>, for
40717         towupper() declaration.
40718         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Include <stdlib.h>, for ptsname()
40719         declaration.
40721 2019-09-14  Bruno Haible  <bruno@clisp.org>
40723         findprog-in: Better mimic the system on native Windows.
40724         Reported by Paul Smith <psmith@gnu.org>.
40725         * lib/findprog-in.c (find_in_given_path): On native Windows, don't try
40726         non-empty suffixes when the file name already contains a '.'.
40728 2019-09-10  Bruno Haible  <bruno@clisp.org>
40730         wctob: Fix autoconf test.
40731         Based on patch by Florian Weimer <fweimer@redhat.com>.
40732         * m4/wctob.m4 (gl_FUNC_WCTOB): Include <stdlib.h> before using mbtowc.
40734 2019-09-09  Akim Demaille  <akim@lrde.epita.fr>
40736         xhash: provide hash_xinitialize.
40737         Suggested by Egor Pugin <egor.pugin@gmail.com>
40738         https://lists.gnu.org/archive/html/bison-patches/2019-09/msg00026.html
40739         * modules/xhash, lib/xhash.c: New.
40740         * lib/hash.h (hash_xinitialize): New.
40742 2019-09-09  Bruno Haible  <bruno@clisp.org>
40744         findprog-in: Make exec optimization optional.
40745         * lib/findprog.h: Add double-inclusion guard. Include <stdbool.h>.
40746         (find_in_given_path): Add optimize_for_exec parameter.
40747         * lib/findprog-in.c (find_in_given_path): Likewise.
40749 2019-09-08  Bruno Haible  <bruno@clisp.org>
40751         Add option to assume the best, not the worst, when cross-compiling.
40752         Suggested by Jonas Termansen <sortie@maxsi.org>.
40753         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add --enable-cross-guesses=...
40754         option. Set gl_cross_guess_normal and gl_cross_guess_inverted.
40755         * m4/argz.m4 (gl_FUNC_ARGZ): Obey --enable-cross-guesses for
40756         lt_cv_sys_argz_works.
40757         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Obey --enable-cross-guesses for
40758         ac_cv_func_calloc_0_nonnull.
40759         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Obey
40760         --enable-cross-guesses for gl_cv_func_realpath_works.
40761         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Obey --enable-cross-guesses for
40762         gl_cv_func_cbrtl_ieee.
40763         * m4/ceil.m4 (gl_FUNC_CEIL): Obey --enable-cross-guesses for
40764         gl_cv_func_ceil_ieee.
40765         * m4/ceilf.m4 (gl_FUNC_CEILF): Obey --enable-cross-guesses for
40766         gl_cv_func_ceilf_ieee.
40767         * m4/ceill.m4 (gl_FUNC_CEILL): Obey --enable-cross-guesses for
40768         gl_cv_func_ceill_ieee.
40769         * m4/chown.m4 (AC_FUNC_CHOWN): Obey --enable-cross-guesses for
40770         ac_cv_func_chown_works.
40771         (gl_FUNC_CHOWN): Obey --enable-cross-guesses for
40772         gl_cv_func_chown_slash_works, gl_cv_func_chown_ctime_works.
40773         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Obey
40774         --enable-cross-guesses for gl_cv_struct_dirent_d_ino.
40775         * m4/exp2l.m4 (gl_FUNC_EXP2L): Obey --enable-cross-guesses for
40776         gl_cv_func_exp2l_works, gl_cv_func_exp2l_ieee.
40777         * m4/expl.m4 (gl_FUNC_EXPL): Obey --enable-cross-guesses for
40778         gl_cv_func_expl_works.
40779         * m4/expm1.m4 (gl_FUNC_EXPM1): Obey --enable-cross-guesses for
40780         gl_cv_func_expm1_ieee.
40781         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Obey --enable-cross-guesses for
40782         gl_cv_func_expm1l_works.
40783         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Obey --enable-cross-guesses for
40784         gl_cv_func_open_directory_works.
40785         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Obey
40786         --enable-cross-guesses for gl_cv_func_fchownat_nofollow_works.
40787         (gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Obey --enable-cross-guesses for
40788         gl_cv_func_fchownat_empty_filename_works.
40789         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Obey --enable-cross-guesses for
40790         gl_cv_func_fdopendir_works.
40791         * m4/floor.m4 (gl_FUNC_FLOOR): Obey --enable-cross-guesses for
40792         gl_cv_func_floor_ieee.
40793         * m4/floorf.m4 (gl_FUNC_FLOORF): Obey --enable-cross-guesses for
40794         gl_cv_func_floorf_ieee.
40795         * m4/fma.m4 (gl_FUNC_FMA_WORKS): Obey --enable-cross-guesses for
40796         gl_cv_func_fma_works.
40797         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Obey --enable-cross-guesses for
40798         gl_cv_func_fmaf_works.
40799         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Obey --enable-cross-guesses for
40800         gl_cv_func_fmal_works.
40801         * m4/fmod.m4 (gl_FUNC_FMOD): Obey --enable-cross-guesses for
40802         gl_cv_func_fmod_ieee.
40803         * m4/fmodf.m4 (gl_FUNC_FMODF): Obey --enable-cross-guesses for
40804         gl_cv_func_fmodf_ieee.
40805         * m4/fmodl.m4 (gl_FUNC_FMODL): Obey --enable-cross-guesses for
40806         gl_cv_func_fmodl_ieee.
40807         * m4/fpurge.m4 (gl_FUNC_FPURGE): Obey --enable-cross-guesses for
40808         gl_cv_func_fpurge_works.
40809         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Obey
40810         --enable-cross-guesses for gl_cv_func_getcwd_path_max.
40811         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Obey --enable-cross-guesses for
40812         gl_cv_func_getcwd_null.
40813         (gl_FUNC_GETCWD): Update for getcwd-path-max.m4 change.
40814         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Obey --enable-cross-guesses for
40815         gl_cv_func_working_getdelim.
40816         * m4/getgroups.m4 (AC_FUNC_GETGROUPS): Obey --enable-cross-guesses for
40817         ac_cv_func_getgroups_works. Keep this macro also in Autoconf >= 2.70.
40818         (gl_FUNC_GETGROUPS): Obey --enable-cross-guesses for
40819         gl_cv_func_getgroups_works.
40820         * m4/getline.m4 (gl_FUNC_GETLINE): Obey --enable-cross-guesses for
40821         am_cv_func_working_getline.
40822         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Obey --enable-cross-guesses
40823         for gl_cv_func_getopt_gnu.
40824         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Obey
40825         --enable-cross-guesses for gl_cv_func_gettimeofday_clobber.
40826         * m4/hypot.m4 (gl_FUNC_HYPOT): Obey --enable-cross-guesses for
40827         gl_cv_func_hypot_ieee.
40828         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Obey --enable-cross-guesses for
40829         gl_cv_func_hypotf_ieee.
40830         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Obey --enable-cross-guesses for
40831         gl_cv_func_hypotl_ieee.
40832         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): Obey
40833         --enable-cross-guesses for gl_cv_func_iconv_supports_utf.
40834         * m4/link.m4 (gl_FUNC_LINK): Obey --enable-cross-guesses for
40835         gl_cv_func_link_works.
40836         * m4/linkat.m4 (gl_FUNC_LINKAT): Obey --enable-cross-guesses for
40837         gl_cv_func_linkat_slash.
40838         * m4/log.m4 (gl_FUNC_LOG): Obey --enable-cross-guesses for
40839         gl_cv_func_log_ieee.
40840         * m4/logf.m4 (gl_FUNC_LOGF): Obey --enable-cross-guesses for
40841         gl_cv_func_logf_ieee.
40842         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Obey --enable-cross-guesses for
40843         gl_cv_func_logl_works.
40844         * m4/log10.m4 (gl_FUNC_LOG10): Obey --enable-cross-guesses for
40845         gl_cv_func_log10_ieee.
40846         * m4/log10f.m4 (gl_FUNC_LOG10F): Obey --enable-cross-guesses for
40847         gl_cv_func_log10f_ieee.
40848         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Obey --enable-cross-guesses for
40849         gl_cv_func_log10l_works.
40850         * m4/log1p.m4 (gl_FUNC_LOG1P): Obey --enable-cross-guesses for
40851         gl_cv_func_log1p_ieee.
40852         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Obey --enable-cross-guesses for
40853         gl_cv_func_log1pf_ieee.
40854         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Obey --enable-cross-guesses for
40855         gl_cv_func_log1pl_ieee.
40856         * m4/log2.m4 (gl_FUNC_LOG2): Obey --enable-cross-guesses for
40857         gl_cv_func_log2_ieee.
40858         * m4/log2f.m4 (gl_FUNC_LOG2F): Obey --enable-cross-guesses for
40859         gl_cv_func_log2f_ieee.
40860         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Obey
40861         --enable-cross-guesses for
40862         gl_cv_func_lstat_dereferences_slashed_symlink.
40863         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Obey --enable-cross-guesses for
40864         ac_cv_func_malloc_0_nonnull. Keep this macro also in Autoconf >= 2.70.
40865         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): Obey --enable-cross-guesses for
40866         gl_cv_C_locale_sans_EILSEQ.
40867         * m4/memchr.m4 (gl_FUNC_MEMCHR): Obey --enable-cross-guesses for
40868         gl_cv_func_memchr_works.
40869         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Obey --enable-cross-guesses for
40870         gl_cv_func_memmem_works_always.
40871         (gl_FUNC_MEMMEM): Obey --enable-cross-guesses for
40872         gl_cv_func_memmem_works_fast.
40873         * m4/mkdir.m4 (gl_FUNC_MKDIR): Obey --enable-cross-guesses for
40874         gl_cv_func_mkdir_trailing_slash_works,
40875         gl_cv_func_mkdir_trailing_dot_works.
40876         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Obey --enable-cross-guesses for
40877         gl_cv_func_mkfifo_works.
40878         * m4/mknod.m4 (gl_FUNC_MKNOD): Obey --enable-cross-guesses for
40879         gl_cv_func_mknod_works.
40880         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Obey --enable-cross-guesses for
40881         gl_cv_func_working_mkstemp.
40882         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Obey --enable-cross-guesses for
40883         gl_cv_func_working_mktime.
40884         * m4/modf.m4 (gl_FUNC_MODF): Obey --enable-cross-guesses for
40885         gl_cv_func_modf_ieee.
40886         * m4/modff.m4 (gl_FUNC_MODFF): Obey --enable-cross-guesses for
40887         gl_cv_func_modff_ieee.
40888         * m4/modfl.m4 (gl_FUNC_MODFL): Obey --enable-cross-guesses for
40889         gl_cv_func_modfl_ieee.
40890         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Obey --enable-cross-guesses for
40891         gl_cv_func_nanosleep.
40892         * m4/perror.m4 (gl_FUNC_PERROR): Obey --enable-cross-guesses for
40893         gl_cv_func_perror_works.
40894         * m4/printf.m4 (gl_PRINTF_SIZES_C99): Obey --enable-cross-guesses for
40895         gl_cv_func_printf_sizes_c99.
40896         (gl_PRINTF_INFINITE): Obey --enable-cross-guesses for
40897         gl_cv_func_printf_infinite.
40898         (gl_PRINTF_INFINITE_LONG_DOUBLE): Obey --enable-cross-guesses for
40899         gl_cv_func_printf_infinite_long_double.
40900         (gl_PRINTF_DIRECTIVE_A): Obey --enable-cross-guesses for
40901         gl_cv_func_printf_directive_a.
40902         (gl_PRINTF_DIRECTIVE_F): Obey --enable-cross-guesses for
40903         gl_cv_func_printf_directive_f.
40904         (gl_PRINTF_FLAG_ZERO): Obey --enable-cross-guesses for
40905         gl_cv_func_printf_flag_zero.
40906         (gl_PRINTF_ENOMEM): Obey --enable-cross-guesses for
40907         gl_cv_func_printf_enomem.
40908         (gl_SNPRINTF_TRUNCATION_C99): Obey --enable-cross-guesses for
40909         gl_cv_func_snprintf_truncation_c99.
40910         (gl_SNPRINTF_RETVAL_C99): Obey --enable-cross-guesses for
40911         gl_cv_func_snprintf_retval_c99.
40912         (gl_SNPRINTF_DIRECTIVE_N): Obey --enable-cross-guesses for
40913         gl_cv_func_snprintf_directive_n.
40914         (gl_VSNPRINTF_ZEROSIZE_C99): Obey --enable-cross-guesses for
40915         gl_cv_func_vsnprintf_zerosize_c99.
40916         * m4/pselect.m4 (gl_FUNC_PSELECT): Obey --enable-cross-guesses for
40917         gl_cv_func_pselect_detects_ebadf.
40918         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
40919         Obey --enable-cross-guesses for
40920         gl_cv_pthread_rwlock_rdlock_prefer_writer.
40921         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Obey --enable-cross-guesses for
40922         gl_cv_func_ptsname_sets_errno.
40923         * m4/putenv.m4 (gl_FUNC_PUTENV): Obey --enable-cross-guesses for
40924         gl_cv_func_svid_putenv.
40925         * m4/readlink.m4 (gl_FUNC_READLINK): Obey --enable-cross-guesses for
40926         gl_cv_func_readlink_works.
40927         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Obey --enable-cross-guesses for
40928         ac_cv_func_realloc_0_nonnull. Keep this macro also in Autoconf >= 2.70.
40929         * m4/regex.m4 (gl_REGEX): Obey --enable-cross-guesses for
40930         gl_cv_func_re_compile_pattern_working.
40931         * m4/remainder.m4 (gl_FUNC_REMAINDER): Obey --enable-cross-guesses for
40932         gl_cv_func_remainder_ieee.
40933         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Obey --enable-cross-guesses for
40934         gl_cv_func_remainderf_ieee.
40935         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Obey --enable-cross-guesses for
40936         gl_cv_func_remainderl_ieee.
40937         * m4/rintl.m4 (gl_FUNC_RINTL): Obey --enable-cross-guesses for
40938         gl_cv_func_rintl_works.
40939         * m4/rmdir.m4 (gl_FUNC_RMDIR): Obey --enable-cross-guesses for
40940         gl_cv_func_rmdir_works.
40941         * m4/round.m4 (gl_FUNC_ROUND): Obey --enable-cross-guesses for
40942         gl_cv_func_round_ieee.
40943         * m4/roundf.m4 (gl_FUNC_ROUNDF): Obey --enable-cross-guesses for
40944         gl_cv_func_roundf_ieee.
40945         * m4/roundl.m4 (gl_FUNC_ROUNDL): Obey --enable-cross-guesses for
40946         gl_cv_func_roundl_ieee.
40947         * m4/select.m4 (gl_FUNC_SELECT): Obey --enable-cross-guesses for
40948         gl_cv_func_select_detects_ebadf.
40949         * m4/setenv.m4 (gl_FUNC_SETENV): Obey --enable-cross-guesses for
40950         gl_cv_func_setenv_works.
40951         (gl_FUNC_UNSETENV): Obey --enable-cross-guesses for
40952         gl_cv_func_unsetenv_works.
40953         * m4/signbit.m4 (gl_SIGNBIT): Obey --enable-cross-guesses for
40954         gl_cv_func_signbit, gl_cv_func_signbit_gcc.
40955         * m4/sleep.m4 (gl_FUNC_SLEEP): Obey --enable-cross-guesses for
40956         gl_cv_func_sleep_works.
40957         * m4/stat.m4 (gl_FUNC_STAT): Obey --enable-cross-guesses for
40958         gl_cv_func_stat_file_slash.
40959         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Obey --enable-cross-guesses for
40960         gl_cv_func_stpncpy.
40961         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Obey
40962         --enable-cross-guesses for gl_cv_func_strcasestr_works_always.
40963         (gl_FUNC_STRCASESTR): Obey --enable-cross-guesses for
40964         gl_cv_func_strcasestr_linear.
40965         * m4/strerror.m4 (gl_FUNC_STRERROR): Obey --enable-cross-guesses for
40966         gl_cv_func_working_strerror.
40967         (gl_FUNC_STRERROR_0): Obey --enable-cross-guesses for
40968         gl_cv_func_strerror_0_works.
40969         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Obey
40970         --enable-cross-guesses for gl_cv_func_strerror_r_works.
40971         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Obey --enable-cross-guesses for
40972         gl_cv_func_strstr_works_always.
40973         (gl_FUNC_STRSTR): Obey --enable-cross-guesses for
40974         gl_cv_func_strstr_linear.
40975         * m4/strtod.m4 (gl_FUNC_STRTOD): Obey --enable-cross-guesses for
40976         gl_cv_func_strtod_works.
40977         * m4/strtold.m4 (gl_FUNC_STRTOLD): Obey --enable-cross-guesses for
40978         gl_cv_func_strtold_works.
40979         * m4/symlink.m4 (gl_FUNC_SYMLINK): Obey --enable-cross-guesses for
40980         gl_cv_func_symlink_works.
40981         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Obey --enable-cross-guesses for
40982         gl_cv_func_symlinkat_works.
40983         * m4/trunc.m4 (gl_FUNC_TRUNC): Obey --enable-cross-guesses for
40984         gl_cv_func_trunc_ieee.
40985         * m4/truncf.m4 (gl_FUNC_TRUNCF): Obey --enable-cross-guesses for
40986         gl_cv_func_truncf_ieee.
40987         * m4/truncl.m4 (gl_FUNC_TRUNCL): Obey --enable-cross-guesses for
40988         gl_cv_func_truncl_ieee.
40989         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Obey --enable-cross-guesses for
40990         gl_cv_func_tzset_clobber.
40991         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Obey --enable-cross-guesses for
40992         gl_cv_func_ungetc_works.
40993         * m4/unlink.m4 (gl_FUNC_UNLINK): Obey --enable-cross-guesses for
40994         gl_cv_func_unlink_honors_slashes, gl_cv_func_unlink_parent_fails.
40995         * m4/usleep.m4 (gl_FUNC_USLEEP): Obey --enable-cross-guesses for
40996         gl_cv_func_usleep_works.
40997         * m4/utimens.m4 (gl_UTIMENS): Obey --enable-cross-guesses for
40998         gl_cv_func_futimesat_works.
40999         * m4/utimes.m4 (gl_FUNC_UTIMES): Obey --enable-cross-guesses for
41000         gl_cv_func_working_utimes.
41001         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Obey --enable-cross-guesses for
41002         gl_cv_func_wcwidth_works.
41003         * m4/glob.m4 (gl_GLOB): When cross-compiling, don't create symlinks for
41004         testing. Obey --enable-cross-guesses for gl_cv_glob_lists_symlinks.
41005         * m4/rename.m4 (gl_FUNC_RENAME): When cross-compiling, don't create
41006         links for testing. Obey --enable-cross-guesses for
41007         gl_cv_func_rename_slash_dst_works, gl_cv_func_rename_slash_src_works,
41008         gl_cv_func_rename_link_works, gl_cv_func_rename_dest_works.
41010 2019-09-08  Bruno Haible  <bruno@clisp.org>
41012         Clarify that cross-compilation guesses are guesses.
41013         * m4/threads.m4 (gl_THREADS_H): Say "guessing yes" or "guessing no" when
41014         cross-compiling.
41016 2019-09-08  Bruno Haible  <bruno@clisp.org>
41018         chown: Fix configure output (regression from 2019-03-23).
41019         * m4/chown.m4 (gl_FUNC_CHOWN): Fix reference to
41020         gl_cv_func_chown_follows_symlink variable.
41022 2019-09-08  Bruno Haible  <bruno@clisp.org>
41024         findprog-in: New module.
41025         Suggested by Paul Smith <psmith@gnu.org>.
41026         * lib/findprog.h (find_in_given_path): New declaration.
41027         * lib/findprog-in.c: New file, based on lib/findprog.c.
41028         * m4/findprog-in.m4: New file, based on m4/findprog.m4.
41029         * modules/findprog-in: New file.
41031 2019-09-08  Bruno Haible  <bruno@clisp.org>
41033         findprog: Remove unused dependency.
41034         * modules/findprog (Depends-on): Remove strdup.
41036 2019-09-08  Bruno Haible  <bruno@clisp.org>
41038         findprog: Remove test that is obsolete since 2006-04-24.
41039         * m4/findprog.m4 (gl_FINDPROG): Don't test for unistd.h.
41041 2019-09-06  Akim Demaille  <akim@lrde.epita.fr>
41043         bitset: style changes
41044         * lib/bitset/vector.c (vbitset_resize): Factor computation.
41045         * lib/bitset.c, lib/bitset/stats.c, lib/bitsetv.c: Prefer
41046         xzalloc to xcalloc.
41047         Suggested by Paul Eggert.
41049 2019-09-06  Akim Demaille  <akim@lrde.epita.fr>
41051         bitset: check memory allocation
41052         Reported by 江 祖铭 (Zu-Ming Jiang).
41053         With help from Paul Eggert.
41054         https://lists.gnu.org/archive/html/bug-bison/2019-08/msg00016.html
41055         * lib/bitset/table.c (tbitset_resize): When growing, use xrealloc
41056         instead of realloc.
41057         When shrinking, accept failures.
41058         * lib/bitset/vector.c (vbitset_resize): Likewise.
41060 2019-09-07  Paul Eggert  <eggert@cs.ucla.edu>
41062         scratch_buffer: sync from glibc
41063         * config/srclist.txt: Add the scratch_buffer source
41064         code from glibc, since these should be in sync.
41065         Autoupdate.
41067 2019-09-07  Bruno Haible  <bruno@clisp.org>
41069         doc: Update for glibc 2.30.
41070         * doc/glibc-functions/gettid.texi: New file.
41071         * doc/glibc-functions/pthread_cond_clockwait.texi: New file.
41072         * doc/glibc-functions/pthread_mutex_clocklock.texi: New file.
41073         * doc/glibc-functions/pthread_rwlock_clockrdlock.texi: New file.
41074         * doc/glibc-functions/pthread_rwlock_clockwrlock.texi: New file.
41075         * doc/glibc-functions/sem_clockwait.texi: New file.
41076         * doc/glibc-functions/tgkill.texi: New file.
41077         * doc/glibc-functions/twalk_r.texi: New file.
41078         * doc/gnulib.texi: Include them.
41079         (Glibc semaphore.h): New section.
41080         * doc/pastposix-functions/h_errno.texi: Update.
41081         * doc/posix-functions/*.texi: Likewise.
41083 2019-09-06  Bruno Haible  <bruno@clisp.org>
41085         symlink tests: Avoid test failure on Linux with Lustre file system.
41086         Reported by Thomas C Oppe <Thomas.C.Oppe@erdc.dren.mil>
41087         at <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=37312>.
41088         * tests/test-symlink.h (test_symlink): Accept errno value ENOENT.
41090 2019-09-01  Bruno Haible  <bruno@clisp.org>
41092         gitsub.sh: Add support for shallow-cloning of subdirectories.
41093         * top/gitsub.sh (func_usage): Document allowed git options with
41094         'git pull'.
41095         (func_pull): Accept GIT_OPTIONS argument.
41096         (pull): Parse git options before complaining about too many arguments.
41097         Pass the git options to func_pull.
41099 2019-08-29  Bruno Haible  <bruno@clisp.org>
41101         lock: Fix cross-compilation guesses.
41102         * m4/pthread_rwlock_rdlock.m4 (gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER):
41103         Require AC_CANONICAL_HOST. When cross-compiling, guess no on most
41104         platforms.
41106 2019-08-28  Bruno Haible  <bruno@clisp.org>
41108         isfinite, isinf, isnan, signbit: Fix error in C++ mode on mingw.
41109         Reported by Martin Storsjö <martin@martin.st> in
41110         <https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00075.html>.
41111         * lib/math.in.h (_GL_MATH_CXX_REAL_FLOATING_DECL_2): Add more arguments.
41112         (isfinite, isinf, isnan, signbit): On platforms that use C++ include
41113         files from GCC 6 or newer, use an override through '#define', because
41114         the inline definitions in the platform's <cmath> cannot be overridden
41115         in another way.
41117 2019-08-27  Paul Eggert  <eggert@cs.ucla.edu>
41119         Revert macOS INT_MULTIPLY_WRAPV patch
41120         Problem reported by Bruno Haible in:
41121         https://lists.gnu.org/r/bug-gnulib/2019-08/msg00076.html
41122         * lib/intprops.h (_GL_HAS___builtin_mul_overflow): Remove.
41123         (_GL_HAS_BUILTIN_MUL_OVERFLOW):
41124         Go back to working around the Clang bug on macOS.
41126 2019-08-27  Bruno Haible  <bruno@clisp.org>
41128         libtool-next-version: Fix error output.
41129         * build-aux/libtool-next-version (func_fatal_error): Fix the program
41130         name.
41132 2019-08-27  Paul Eggert  <eggert@cs.ucla.edu>
41134         Speed up INT_MULTIPLY_WRAPV on macOS
41135         Assume that __builtin_mul_overflow works OK with Clang on macOS.
41136         Mattias Engdegård says it’s safe to assume the relevant library
41137         is always available there.
41138         * lib/intprops.h (_GL_HAS___builtin_mul_overflow):
41139         New temporary internal macro.
41140         (_GL_HAS_BUILTIN_MUL_OVERFLOW):
41141         No need to work around the Clang bug on macOS.
41143 2019-08-25  Paul Eggert  <eggert@cs.ucla.edu>
41145         intprops.h, verify.h: port better to clang
41146         Improve code generated by INT_ADD_WRAPV and INT_SUBTRACT_WRAPV
41147         with Clang.  Problem reported privately by Mattias Engdegård.
41148         Also, insulate intprops.h and verify.h better against each other’s
41149         definitions of __has_builtin on non-Clang hosts.
41150         * lib/intprops.h (__has_builtin): Define a temporary substitute
41151         if __has_builtin is not already defined.
41152         (_GL_HAS___builtin_add_overflow, _GL_TEMPDEF___has_builtin):
41153         New temporary internal macros.
41154         (_GL_HAS_BUILTIN_ADD_OVERFLOW, _GL_HAS_BUILTIN_MUL_OVERFLOW):
41155         Now two separate macros, replacing the old
41156         _GL_HAS_BUILTIN_OVERFLOW, since we no longer assume that
41157         __builtin_mul_overflow is like the rest.  All uses changed.
41158         (INT_ADD_WRAPV, INT_SUBTRACT_WRAPV, INT_MULTIPLY_WRAPV):
41159         Adjust to above changes.
41160         (_GL_INT_OP_WRAPV): Remove ‘builtin’ arg, since it’s no
41161         longer relevant.  All uses changed.
41162         * lib/verify.h (__has_builtin): Treat like intprops.h,
41163         so that the two .h files do not collide with each other.
41164         (_GL_HAS___builtin_unreachable, _GL_HAS___builtin_trap)
41165         (_GL_TEMPDEF___has_builtin): New temporary internal macros.
41167 2019-08-24  Paul Eggert  <eggert@cs.ucla.edu>
41169         intprops: say why not Clang __builtin_add_overflow
41170         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW):
41171         Mention Clang in comment, responding to a query from
41172         Mattias Engdegård.
41174 2019-08-24  Bruno Haible  <bruno@clisp.org>
41176         doc: Document most of the files outside of modules.
41177         * doc/gnulib.texi (Build Infrastructure Files,
41178         Release Management Files): New chapters.
41180 2019-08-24  Bruno Haible  <bruno@clisp.org>
41182         bootstrap: Keep in sync with the 'gettext' module.
41183         Reported by Assaf Gordon in
41184         <https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00045.html>.
41185         * build-aux/po/Makefile.in.in: Update to gettext 0.20.
41186         * build-aux/po/remove-potcdate.sin: Likewise.
41188 2019-08-24  Bruno Haible  <bruno@clisp.org>
41190         crypto/gc-sha512: Add tests.
41191         * tests/test-gc-sha512.c: New file, based on tests/test-gc-sha1.c.
41192         * modules/crypto/gc-sha512-tests: New file.
41194         crypto/gc-sha256: Add tests.
41195         * tests/test-gc-sha256.c: New file, based on tests/test-gc-sha1.c.
41196         * modules/crypto/gc-sha256-tests: New file.
41198         crypto/gc-sha256, crypto/gc-sha512: New modules.
41199         * lib/gc.h (gc_sha256, gc_sha512): New declarations.
41200         * lib/gc-gnulib.c: Include sha256.h, sha512.h.
41201         (MAX_DIGEST_SIZE): Set to 64.
41202         (_gc_hash_ctx, gc_hash_open, gc_hash_digest_length, gc_hash_write,
41203         gc_hash_read, gc_hash_buffer): Add support for sha256 and sha512.
41204         (gc_sha256, gc_sha512): New functions.
41205         * lib/gc-libgcrypt.c (gc_sha256, gc_sha512): New functions.
41206         * modules/crypto/gc-sha256: New file, based on modules/crypto/gc-sha1.
41207         * modules/crypto/gc-sha512: New file, based on modules/crypto/gc-sha1.
41209 2019-08-24  Bruno Haible  <bruno@clisp.org>
41211         crypto/gc-sha1 tests: Improve output when the test fails.
41212         * tests/test-gc-sha1.c (main): In case of mismatch, print the entire
41213         output.
41215 2019-08-24  Bruno Haible  <bruno@clisp.org>
41217         crypto/gc-sm3: Fix compilation error with --with-libgcrypt.
41218         * m4/gc-sm3.m4 (gl_GC_SM3): Test whether libgcrypt supports SM3. Define
41219         LIBGCRYPT_HAS_MD_SM3.
41220         * lib/gc-libgcrypt.c: Include sm3.h.
41221         (_gc_hash_ctx, gc_hash_open, gc_hash_hmac_setkey, gc_hash_write,
41222         gc_hash_read, gc_hash_close, gc_hash_buffer, gc_sm3): Use the gnulib
41223         implementation if libgcrypt does not support SM3.
41225 2019-08-24  Bruno Haible  <bruno@clisp.org>
41227         crypto/gc-md2: Optimize and clarify code.
41228         * lib/gc-gnulib.c (gc_hash_open): Comment out md2_init_ctx invocation.
41229         * lib/gc-libgcrypt.c (gc_hash_open): Clarify why md2_init_ctx invocation
41230         is not needed.
41232 2019-08-24  Bruno Haible  <bruno@clisp.org>
41234         crypto/gc-md2: Add comment.
41235         * lib/gc-libgcrypt.c: Add comment.
41237 2019-08-24  Bruno Haible  <bruno@clisp.org>
41239         crypto/gc-{md[24],rijndael} tests: Fix link error with --with-libgcrypt.
41240         * modules/crypto/gc-md2-tests (test_gc_md2_LDADD): New variable.
41241         * modules/crypto/gc-md4-tests (test_gc_md4_LDADD): New variable.
41242         * modules/crypto/gc-rijndael-tests (test_gc_rijndael_LDADD): New
41243         variable.
41245 2019-08-24  Bruno Haible  <bruno@clisp.org>
41247         crypto/gc: Fix link error with --with-libgcrypt.
41248         * m4/gc.m4 (gl_GC): Set LIB_CRYPTO to the value found by the
41249         AC_LIB_HAVE_LINKFLAGS invocation.
41251 2019-08-24  Bruno Haible  <bruno@clisp.org>
41253         crypto/gc: Access the module indicators correctly.
41254         * lib/gc-gnulib.c: Use '#if GNULIB_GC_*', not '#ifdef GNULIB_GC_*'.
41255         * lib/gc-libgcrypt.c: Likewise.
41257 2019-08-24  Bruno Haible  <bruno@clisp.org>
41259         crypto/gc: Fix configuration with --with-libgcrypt.
41260         * m4/libgcrypt.m4: New file, copied from libgcrypt/src/libgcrypt.m4.
41261         * modules/crypto/gc (Files): Add it.
41262         * m4/gc.m4 (gl_GC): Assume AM_PATH_LIBGCRYPT is defined.
41264 2019-08-24  Bruno Haible  <bruno@clisp.org>
41266         Remove unused file.
41267         * m4/stat-macros.m4: Remove file.
41269 2019-08-21  Paul Eggert  <eggert@cs.ucla.edu>
41271         New strip-trailing-space option for srclist-update
41272         * config/srclist-update (fixfile): Support new option.
41273         * config/srclist.txt (texinfo.tex, maintain.texi, standards.texi):
41274         Use it.
41276 2019-08-20  Eric Blake  <eblake@redhat.com>
41278         accept4: Support SOCK_NONBLOCK, if defined
41279         * lib/accept4.c (accept4): If SOCK_NONBLOCK is defined, honor it.
41281         accept4: Fix compilation when native accept4() exists.
41282         Reported by Richard W.M. Jones <rjones@redhat.com> in
41283         https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00029.html
41284         * lib/accept4.c (accept4): Match witness symbol to m4 file update.
41286 2019-08-18  Bruno Haible  <bruno@clisp.org>
41288         Defeat -flto GCC optimization in math autoconf tests.
41289         Reported by Tomasz Kłoczko <kloczko.tomasz@gmail.com>
41290         at <https://savannah.gnu.org/bugs/?56109>.
41291         * m4/mathfunc.m4 (gl_MATHFUNC): Mark function pointer as 'volatile'.
41292         * m4/acosl.m4 (gl_FUNC_ACOSL): Likewise.
41293         * m4/asinl.m4 (gl_FUNC_ASINL): Likewise.
41294         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
41295         * m4/cosl.m4 (gl_FUNC_COSL): Likewise.
41296         * m4/exp2.m4 (gl_FUNC_EXP2): Likewise.
41297         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
41298         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
41299         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Likewise.
41300         * m4/sinl.m4 (gl_FUNC_SINL): Likewise.
41301         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Likewise.
41302         * m4/tanl.m4 (gl_FUNC_TANL): Likewise.
41304 2019-08-17  Bruno Haible  <bruno@clisp.org>
41306         windows-spin: Implement declared functions.
41307         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
41308         <https://lists.gnu.org/archive/html/bug-gnulib/2019-08/msg00024.html>.
41309         * lib/windows-spin.c (glwthread_spin_trylock): Fix typo in function
41310         name.
41312 2019-08-17  Paul Eggert  <eggert@cs.ucla.edu>
41314         intprops: port to Oracle Developer Studio 12.6
41315         * lib/intprops.h (_GL_INT_OP_WRAPV): Fix recently-introduced
41316         typos that were in a section not compiled by GCC.
41318 2019-08-14  Paul Eggert  <eggert@cs.ucla.edu>
41320         intprops: support uchar, ushort _WRAPV dests
41321         * lib/intprops.h (_GL_INT_OP_WRAPV_SMALLISH): New macro, defined
41322         when __builtin_add_overflow etc. and _Generic are not used.
41323         (_GL_INT_OP_WRAPV): Use it to support destinations that
41324         are unsigned char or unsigned short, even in compilers
41325         that lack __typeof__ and are not C11-compatible.
41327         intprops: pacify picky GCC
41328         * lib/intprops.h (_GL_BUILTIN_MUL_OVERFLOW):
41329         Pacify GCC’s complaints about ignoring __builtin_mul_overflow’s
41330         possibly-incorrect result.
41331         (_GL_INT_MULTIPLY_RANGE_OVERFLOW): Pacify GCC’s complaints
41332         about (A) used as a boolean, when A is an expression like 3 * 4.
41334         intprops: support unsigned *_WRAPV results
41335         Add support for unsigned, unsigned long, and unsigned long long
41336         results to INT_ADD_WRAPV, INT_SUBTRACT_WRAPV, and
41337         INT_MULTIPLY_WRAPV.  Also, work around GCC bug 91450, and fix a
41338         bug with unsigned inputs reported by Eli Zaretskii in:
41339         https://lists.gnu.org/r/bug-gnulib/2019-08/msg00012.html
41340         * config/srclist.txt: Break the glibc connection for intprops.h
41341         temporarily, while more testing is done in Gnulib-using apps.
41342         * lib/intprops.h (INT_ADD_WRAPV, INT_SUBTRACT_WRAPV)
41343         (INT_MULTIPLY_WRAPV, _GL_INT_OP_WRAPV, _GL_INT_OP_WRAPV_LONGISH):
41344         Support unsigned results no narrower than unsigned int.  Report
41345         overflow correctly if some arguments are unsigned.
41346         (_GL_BUILTIN_MUL_OVERFLOW): New macro, to work around GCC bug 91450.
41347         (_GL_INT_OP_CALC): Simplify now that the OVERFLOW argument does
41348         the right thing with narrow args.
41349         (_GL_INT_OP_CALC1): Remove.  All callers removed.
41350         (_GL_INT_ADD_RANGE_OVERFLOW, _GL_INT_SUBTRACT_RANGE_OVERFLOW)
41351         (_GL_INT_MULTIPLY_RANGE_OVERFLOW): New macros.
41352         * tests/test-intprops.c: Check for bugs and test new behavior.
41354 2019-08-14  Bruno Haible  <bruno@clisp.org>
41356         get_progname_of: New module.
41357         * lib/get_progname_of.h: New file.
41358         * lib/get_progname_of.c: New file, based on lib/getprogname.c.
41359         * lib/getprogname.c (getprogname): Tweak coding style.
41360         * lib/vma-iter.c (vma_iterate_bsd): Update comment.
41361         * modules/get_progname_of: New file.
41363 2019-08-14  Bruno Haible  <bruno@clisp.org>
41365         get_ppid_of: New module.
41366         * lib/get_ppid_of.h: New file.
41367         * lib/get_ppid_of.c: New file.
41368         * modules/get_ppid_of: New file.
41370 2019-08-13  Bruno Haible  <bruno@clisp.org>
41372         libtextstyle-optional tests: Support the NO_COLOR environment variable.
41373         * tests/test-libtextstyle.c (main): Do not emit styling when the
41374         environment variable NO_COLOR is set.
41376 2019-08-12  Paul Eggert  <eggert@cs.ucla.edu>
41378         verify: improve diagnostic quality in recent GCC
41379         If ‘verify’ fails in a deeply-nested macro, GCC does not output a
41380         useful line number containing the top-level caller of the macro.
41381         So, bring back the older way of issuing a diagnostic containing
41382         the top-level call’s arg, so that it is easier to diagnose
41383         ‘verify’ failures with recent GCC.
41384         * lib/verify.h (_GL_VERIFY_TRUE, _GL_VERIFY_TYPE):
41385         Bring back DIAGNOSTIC arg.  All callers changed.
41386         (verify): Just use _GL_VERIFY.
41388 2019-08-11  Bruno Haible  <bruno@clisp.org>
41390         localcharset: Add more aliases for OS/2.
41391         Based on patch by KO Myung-Hun <komh78@gmail.com> in
41392         <https://lists.gnu.org/archive/html/bug-gnu-libiconv/2019-08/msg00004.html>.
41393         * lib/localcharset.c (alias_table) [OS2]: Add more aliases.
41395 2019-08-10  Eric Blake  <eblake@redhat.com>
41397         configmake: Update advice on usage.
41398         * modules/configmake (Include): No longer necessary to include
41399         last, since configmake.h itself worries about collision avoidance.
41401 2019-08-10  Assaf Gordon <assafgordon@gmail.com>
41403         parse-datetime: fix 'T' military timezone handling
41404         * lib/parse-datetime.y (zone):
41405         follow-up to the previous commit: the 'T' case is handled outside the
41406         conversion table (used as either military timezone UTC-7 or ISO8601
41407         separator). Change it from "HOUR(7)" to "-HOUR(7)" to match other
41408         timezone letters.
41410 2019-08-09  Paul Eggert  <eggert@cs.ucla.edu>
41412         parse-datetime: fix military timezone letters
41413         Problem and trivial fix reported by Neil Hoggarth in:
41414         https://lists.gnu.org/r/bug-gnulib/2019-08/msg00005.html
41415         * lib/parse-datetime.y (military_table):
41416         Do it the right way, not the RFC 822 way.
41418 2019-08-08  Eric Blake  <eblake@redhat.com>
41420         configmake: Avoid namespace pollution issue on mingw.
41421         * modules/configmake (Makefile.am): If the project uses
41422         <winsock2.h>, include that header before defining DATADIR.
41424 2019-07-28  Bruno Haible  <bruno@clisp.org>
41426         mbrtowc tests: Fix regression on mingw (regression from 2018-02-24).
41427         * tests/test-mbrtowc.c (main): Fix expected value of wc.
41429 2019-07-24  Bruno Haible  <bruno@clisp.org>
41431         pthread-h: Fix definitions of types and macros on mingw.
41432         * lib/pthread.in.h (pthread_t, pthread_attr_t, PTHREAD_CREATE_JOINABLE,
41433         PTHREAD_CREATE_DETACHED): Define also when module 'pthread-thread' is
41434         not in use.
41435         (pthread_once_t, PTHREAD_ONCE_INIT): Define also when module
41436         'pthread-once' is not in use.
41437         (pthread_mutex_t, pthread_mutexattr_t, PTHREAD_MUTEX_INITIALIZER,
41438         PTHREAD_MUTEX_DEFAULT, PTHREAD_MUTEX_NORMAL, PTHREAD_MUTEX_ERRORCHECK,
41439         PTHREAD_MUTEX_RECURSIVE): Define also when module 'pthread-mutex' is not
41440         in use.
41441         (pthread_rwlock_t, pthread_rwlockattr_t, PTHREAD_RWLOCK_INITIALIZER):
41442         Define also when module 'pthread-rwlock' is not in use.
41443         (pthread_cond_t, pthread_condattr_t, PTHREAD_COND_INITIALIZER): Define
41444         also when module 'pthread-cond' is not in use.
41445         (pthread_key_t, PTHREAD_DESTRUCTOR_ITERATIONS): Define also when module
41446         'pthread-tss' is not in use.
41447         (pthread_spinlock_t): Define also when module 'pthread-spin' is not in
41448         use.
41450 2019-07-24  Simon Josefsson  <simon@josefsson.org>
41452         crypto/gc: Cope with libgcrypt without SM3.
41453         * lib/gc-libgcrypt.c (gc_hash_open): Guard SM3 usage.
41455 2019-07-23  Paul Eggert  <eggert@cs.ucla.edu>
41457         backupfile: fix resource leak on memory failure
41458         Problem found by Coverity (CID 1484214).
41459         * lib/backupfile.c (backupfile_internal): Don’t leak dirp.
41461 2019-07-22  Bruno Haible  <bruno@clisp.org>
41463         Avoid missing-declarations warning in various tests.
41464         * tests/test-argp.c (fail, test1, test2, test_file, test3, test4, test5,
41465         test6, test_optional, test7, test8, test9, test10, test11, test12,
41466         test13, test14, test15, test_fun): Declare static.
41467         * tests/test-cnd.c (test_cnd_wait): Likewise.
41468         * tests/test-cond.c (test_cond): Likewise.
41470 2019-07-22  Bernhard Voelker  <mail@bernhard-voelker.de>
41472         pthread tests: Avoid missing-declarations warning.
41473         * tests/test-pthread-cond.c (test_pthread_cond_wait): Declare static.
41475 2019-07-19  Bruno Haible  <bruno@clisp.org>
41477         parse-datetime: Avoid warnings from bison versions >= 3.3.
41478         Reported by Bernhard Voelker <mail@bernhard-voelker.de>.
41479         * modules/parse-datetime (Makefile.am): Don't pass option '-y' to bison.
41481 2019-07-19  Bruno Haible  <bruno@clisp.org>
41483         parse-datetime: Require Bison 2.4 or newer.
41484         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Set PARSE_DATETIME_BISON.
41485         Code taken from gettext's intl.m4.
41486         * modules/parse-datetime (Makefile.am): Use PARSE_DATETIME_BISON instead
41487         of YACC.
41489 2019-07-19  Bruno Haible  <bruno@clisp.org>
41491         areadlink-with-size, xgethostname, xgetdomainname: Fix GCC warning.
41492         * lib/areadlink-with-size.c: Include <string.h>.
41493         * lib/areadlinkat-with-size.c: Likewise.
41494         * lib/xgethostname.c: Likewise.
41495         * lib/xgetdomainname.c: Likewise.
41497 2019-07-19  Bernhard Voelker  <mail@bernhard-voelker.de>
41499         parse-datetime: avoid "%pure-parser" deprecation warning from Bison 3.4
41500         * lib/parse-datetime.y: Use "%define api.pure" rather than obsolescent
41501         "%pure-parser".  The former is available since Bison 2.3b (2008),
41502         while the latter is marked as obsolete since version 3.4 (May 2019).
41504 2019-07-16  Bruno Haible  <bruno@clisp.org>
41506         update-copyright: Make it work again (regression from 2019-06-15).
41507         Reported by Brian C. Lane <bcl@redhat.com>.
41508         * build-aux/update-copyright: Add back the -0777, -p, -i options.
41510 2019-07-14  Bruno Haible  <bruno@clisp.org>
41512         doc: Update info about <pthread.h>.
41513         * doc/posix-headers/pthread.texi: Mention the module 'pthread-h' instead
41514         of 'pthread'.
41516 2019-07-14  Bruno Haible  <bruno@clisp.org>
41518         pthread_sigmask tests: Use new multithread modules.
41519         * tests/test-pthread_sigmask2.c: Include <pthread.h> instead of
41520         glthread/thread.h.
41521         (main_thread, killer_thread): Change type to pthread_t.
41522         (main): Update accordingly.
41523         * modules/pthread_sigmask-tests (Depends-on): Add pthread-thread. Remove
41524         thread.
41526 2019-07-14  Bruno Haible  <bruno@clisp.org>
41528         pthread-tss: Add tests.
41529         * tests/test-pthread-tss.c: New file, based on tests/test-tls.c and
41530         tests/test-tss.c.
41531         * modules/pthread-tss-tests: New file.
41533 2019-07-14  Bruno Haible  <bruno@clisp.org>
41535         pthread-cond: Add tests.
41536         * tests/test-pthread-cond.c: New file, based on tests/test-cond.c and
41537         tests/test-cnd.c.
41538         * modules/pthread-cond-tests: New file.
41540 2019-07-14  Bruno Haible  <bruno@clisp.org>
41542         pthread-rwlock: Add tests.
41543         * tests/test-pthread-rwlock.c: New file, based on tests/test-lock.c.
41544         * modules/pthread-rwlock-tests: New file.
41546 2019-07-14  Bruno Haible  <bruno@clisp.org>
41548         pthread-mutex: Add tests.
41549         * tests/test-pthread-mutex.c: New file, based on tests/test-lock.c and
41550         tests/test-mtx.c.
41551         * modules/pthread-mutex-tests: New file.
41553 2019-07-14  Bruno Haible  <bruno@clisp.org>
41555         pthread-once: Add tests.
41556         * tests/test-pthread-once1.c: New file, based on tests/test-once.c and
41557         tests/test-call_once.c.
41558         * tests/test-pthread-once2.c: New file, based on tests/test-lock.c and
41559         tests/test-mtx.c.
41560         * modules/pthread-once-tests: New file.
41562 2019-07-14  Bruno Haible  <bruno@clisp.org>
41564         pthread-thread: Add tests.
41565         * tests/test-pthread-thread.c: New file, based on
41566         tests/test-thread_create.c and tests/test-thrd_create.c.
41567         * modules/pthread-thread-tests: New file.
41569 2019-07-14  Bruno Haible  <bruno@clisp.org>
41571         pthread: Turn into a convenience module.
41572         * lib/pthread.in.h: Remove declarations for extern inline functions.
41573         * lib/pthread.c: Remove file.
41574         * modules/pthread (Files): Remove it.
41575         (Depends-on): Add pthread-thread, pthread-once, pthread-mutex,
41576         pthread-rwlock, pthread-cond, pthread-tss, pthread-spin.
41577         (configure.ac): Don't compile lib/pthread.c. Don't set GNULIB_PTHREAD.
41578         * m4/pthread_h.m4 (gl_PTHREAD_H_DEFAULTS): Don't initialize
41579         GNULIB_PTHREAD.
41580         * modules/pthread-h (Makefile.am): Don't substitute GNULIB_PTHREAD.
41582 2019-07-14  Bruno Haible  <bruno@clisp.org>
41584         pthread-spin: New module.
41585         * lib/pthread.in.h (pthread_spin_init, pthread_spin_destroy,
41586         pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock): Remove
41587         inline definitions.
41588         * lib/pthread-spin.c: New file.
41589         * m4/pthread-spin.m4: New file.
41590         * modules/pthread-spin: New file.
41591         * doc/posix-functions/pthread_spin_init.texi: Mention the new module.
41592         * doc/posix-functions/pthread_spin_lock.texi: Likewise.
41593         * doc/posix-functions/pthread_spin_trylock.texi: Likewise.
41594         * doc/posix-functions/pthread_spin_unlock.texi: Likewise.
41595         * doc/posix-functions/pthread_spin_destroy.texi: Likewise.
41597 2019-07-14  Bruno Haible  <bruno@clisp.org>
41599         pthread-tss: New module.
41600         * lib/pthread-tss.c: New file.
41601         * m4/pthread-tss.m4: New file.
41602         * modules/pthread-tss: New file.
41603         * doc/posix-functions/pthread_key_create.texi: Mention the new module.
41604         * doc/posix-functions/pthread_setspecific.texi: Likewise.
41605         * doc/posix-functions/pthread_getspecific.texi: Likewise.
41606         * doc/posix-functions/pthread_key_delete.texi: Likewise.
41608 2019-07-14  Bruno Haible  <bruno@clisp.org>
41610         pthread-cond: New module.
41611         * lib/pthread.in.h (pthread_cond_destroy, pthread_cond_init,
41612         pthread_cond_signal, pthread_cond_wait): Remove inline definitions.
41613         * lib/pthread-cond.c: New file.
41614         * m4/pthread-cond.m4: New file.
41615         * modules/pthread-cond: New file.
41616         * doc/posix-functions/pthread_cond_init.texi: Mention the new module.
41617         * doc/posix-functions/pthread_condattr_init.texi: Likewise.
41618         * doc/posix-functions/pthread_condattr_destroy.texi: Likewise.
41619         * doc/posix-functions/pthread_cond_wait.texi: Likewise.
41620         * doc/posix-functions/pthread_cond_timedwait.texi: Likewise.
41621         * doc/posix-functions/pthread_cond_signal.texi: Likewise.
41622         * doc/posix-functions/pthread_cond_broadcast.texi: Likewise.
41623         * doc/posix-functions/pthread_cond_destroy.texi: Likewise.
41625 2019-07-14  Bruno Haible  <bruno@clisp.org>
41627         pthread-rwlock: New module.
41628         * lib/pthread-rwlock.c: New file, based on lib/glthread/lock.c.
41629         * m4/pthread-rwlock.m4: New file.
41630         * modules/pthread-rwlock: New file.
41631         * doc/posix-functions/pthread_rwlock_init.texi: Mention the new module
41632         and the Android problem.
41633         * doc/posix-functions/pthread_rwlockattr_init.texi: Likewise.
41634         * doc/posix-functions/pthread_rwlockattr_destroy.texi: Likewise.
41635         * doc/posix-functions/pthread_rwlock_rdlock.texi: Likewise.
41636         * doc/posix-functions/pthread_rwlock_wrlock.texi: Likewise.
41637         * doc/posix-functions/pthread_rwlock_tryrdlock.texi: Likewise.
41638         * doc/posix-functions/pthread_rwlock_trywrlock.texi: Likewise.
41639         * doc/posix-functions/pthread_rwlock_timedrdlock.texi: Likewise.
41640         * doc/posix-functions/pthread_rwlock_timedwrlock.texi: Likewise.
41641         * doc/posix-functions/pthread_rwlock_unlock.texi: Likewise.
41642         * doc/posix-functions/pthread_rwlock_destroy.texi: Likewise.
41644 2019-07-14  Bruno Haible  <bruno@clisp.org>
41646         pthread-mutex: New module.
41647         * lib/pthread.in.h (pthread_mutexattr_destroy, pthread_mutexattr_init,
41648         pthread_mutexattr_settype, pthread_mutex_destroy, pthread_mutex_init,
41649         pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_timedlock,
41650         pthread_mutex_unlock): Remove inline definitions.
41651         * lib/pthread-mutex.c: New file.
41652         * m4/pthread-mutex.m4: New file.
41653         * modules/pthread-mutex: New file.
41654         * doc/posix-functions/pthread_mutex_init.texi: Mention the new module.
41655         * doc/posix-functions/pthread_mutexattr_init.texi: Likewise.
41656         * doc/posix-functions/pthread_mutexattr_gettype.texi: Likewise.
41657         * doc/posix-functions/pthread_mutexattr_settype.texi: Likewise.
41658         * doc/posix-functions/pthread_mutexattr_getrobust.texi: Likewise.
41659         * doc/posix-functions/pthread_mutexattr_setrobust.texi: Likewise.
41660         * doc/posix-functions/pthread_mutexattr_destroy.texi: Likewise.
41661         * doc/posix-functions/pthread_mutex_lock.texi: Likewise.
41662         * doc/posix-functions/pthread_mutex_trylock.texi: Likewise.
41663         * doc/posix-functions/pthread_mutex_timedlock.texi: Likewise.
41664         * doc/posix-functions/pthread_mutex_unlock.texi: Likewise.
41665         * doc/posix-functions/pthread_mutex_destroy.texi: Likewise.
41667 2019-07-14  Bruno Haible  <bruno@clisp.org>
41669         pthread-once: New module.
41670         * lib/pthread-once.c: New file.
41671         * m4/pthread-once.m4: New file.
41672         * modules/pthread-once: New file.
41673         * doc/posix-functions/pthread_once.texi: Mention the new module.
41675 2019-07-14  Bruno Haible  <bruno@clisp.org>
41677         pthread-thread: New module.
41678         * lib/pthread.in.h (pthread_create, pthread_exit, pthread_join): Remove
41679         inline definitions.
41680         * lib/pthread-thread.c: New file.
41681         * m4/pthread-thread.m4: New file.
41682         * modules/pthread-thread: New file.
41683         * doc/posix-functions/pthread_create.texi: Mention the new module.
41684         * doc/posix-functions/pthread_attr_init.texi: Likewise.
41685         * doc/posix-functions/pthread_attr_getdetachstate.texi: Likewise.
41686         * doc/posix-functions/pthread_attr_setdetachstate.texi: Likewise.
41687         * doc/posix-functions/pthread_attr_destroy.texi: Likewise.
41688         * doc/posix-functions/pthread_self.texi: Likewise.
41689         * doc/posix-functions/pthread_equal.texi: Likewise.
41690         * doc/posix-functions/pthread_detach.texi: Likewise.
41691         * doc/posix-functions/pthread_join.texi: Likewise.
41692         * doc/posix-functions/pthread_exit.texi: Likewise.
41694 2019-07-14  Bruno Haible  <bruno@clisp.org>
41696         pthread-h: Prepare for adding new modules.
41697         * lib/pthread.in.h: Define the types and macros for each of the
41698         facilities separately.
41699         * m4/pthread_h.m4 (gl_PTHREAD_H): Set HAVE_PTHREAD_CREATE_DETACHED,
41700         HAVE_PTHREAD_MUTEX_RECURSIVE, HAVE_PTHREAD_MUTEX_ROBUST,
41701         HAVE_PTHREAD_PROCESS_SHARED.
41702         (gl_PTHREAD_H_DEFAULTS): Initialize HAVE_PTHREAD_CREATE_DETACHED,
41703         HAVE_PTHREAD_MUTEX_RECURSIVE, HAVE_PTHREAD_MUTEX_ROBUST,
41704         HAVE_PTHREAD_PROCESS_SHARED.
41705         * modules/pthread-h (Makefile.am): Substitute
41706         HAVE_PTHREAD_CREATE_DETACHED, HAVE_PTHREAD_MUTEX_RECURSIVE,
41707         HAVE_PTHREAD_MUTEX_ROBUST, HAVE_PTHREAD_PROCESS_SHARED.
41709 2019-07-14  Bruno Haible  <bruno@clisp.org>
41711         pthread-h: Add declarations of essential pthread functions.
41712         * lib/pthread.in.h: Include snippets.
41713         (pthread_create, pthread_attr_init, pthread_attr_getdetachstate,
41714         pthread_attr_setdetachstate, pthread_attr_destroy, pthread_self,
41715         pthread_equal, pthread_detach, pthread_join, pthread_exit, pthread_once,
41716         pthread_mutex_init, pthread_mutexattr_init, pthread_mutexattr_gettype,
41717         pthread_mutexattr_settype, pthread_mutexattr_getrobust,
41718         pthread_mutexattr_setrobust, pthread_mutexattr_destroy,
41719         pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_unlock,
41720         pthread_mutex_destroy, pthread_rwlock_init, pthread_rwlockattr_init,
41721         pthread_rwlockattr_destroy, pthread_rwlock_rdlock,
41722         pthread_rwlock_wrlock, pthread_rwlock_tryrdlock,
41723         pthread_rwlock_trywrlock, pthread_rwlock_timedrdlock,
41724         pthread_rwlock_timedwrlock, pthread_rwlock_unlock,
41725         pthread_rwlock_destroy, pthread_cond_init, pthread_condattr_init,
41726         pthread_condattr_destroy, pthread_cond_wait, pthread_cond_timedwait,
41727         pthread_cond_signal, pthread_cond_broadcast, pthread_cond_destroy,
41728         pthread_key_create, pthread_setspecific, pthread_getspecific,
41729         pthread_key_delete, pthread_spin_init, pthread_spin_lock,
41730         pthread_spin_trylock, pthread_spin_unlock, pthread_spin_destroy): New
41731         declarations.
41732         (pthread_mutex_timedlock): Move declaration.
41733         * m4/pthread_h.m4 (gl_PTHREAD_H): Check whether the new functions are
41734         declared.
41735         (gl_PTHREAD_H_DEFAULTS): Initialize GNULIB_PTHREAD_THREAD,
41736         GNULIB_PTHREAD_ONCE, GNULIB_PTHREAD_MUTEX, GNULIB_PTHREAD_RWLOCK,
41737         GNULIB_PTHREAD_COND, GNULIB_PTHREAD_TSS, GNULIB_PTHREAD_SPIN and the
41738         HAVE_* and REPLACE_* variables for the new functions.
41739         * modules/pthread-h (Depends-on): Add snippet/c++defs,
41740         snippet/_Noreturn, snippet/arg-nonnull, snippet/warn-on-use.
41741         (Makefile.am): Substitute GNULIB_PTHREAD_THREAD, GNULIB_PTHREAD_ONCE,
41742         GNULIB_PTHREAD_MUTEX, GNULIB_PTHREAD_RWLOCK, GNULIB_PTHREAD_COND,
41743         GNULIB_PTHREAD_TSS, GNULIB_PTHREAD_SPIN and the HAVE_* and REPLACE_*
41744         variables for the new functions. Split the sed script, to avoid the
41745         limit of 99 commands of HP-UX sed.
41746         * tests/test-pthread-c++.cc: Check the signature of the new functions.
41748 2019-07-14  Bruno Haible  <bruno@clisp.org>
41750         pthread-h: Respect --enable-threads={posix|windows} option on mingw.
41751         * m4/pthread_h.m4 (gl_PTHREAD_H): Require gl_THREADLIB. Set
41752         HAVE_PTHREAD_H if gl_threads_api is 'windows'.
41753         (LIB_PTHREAD): Rely on $LIBMULTITHREAD from threadlib.m4.
41754         * modules/pthread (Link): Change to $(LIBMULTITHREAD).
41755         * modules/pthread-h (Depends-on): Add threadlib.
41756         (Link): Change to $(LIBTHREAD).
41757         * modules/pthread-h-c++-tests (test_pthread_c___LDADD): Use
41758         $(LIBMULTITHREAD) instead of $(LIB_PTHREAD).
41760 2019-07-14  Bruno Haible  <bruno@clisp.org>
41762         pthread-h: Add C++ tests.
41763         * tests/test-pthread-c++.cc: New file.
41764         * modules/pthread-h-c++-tests: New file.
41766 2019-07-14  Bruno Haible  <bruno@clisp.org>
41768         pthread-h: Add tests.
41769         * tests/test-pthread.c: New file.
41770         * modules/pthread-h-tests: New file.
41772 2019-07-14  Bruno Haible  <bruno@clisp.org>
41774         pthread-h: New module.
41775         * lib/pthread.in.h: Define replacement functions only if GNULIB_PTHREAD
41776         is 1.
41777         * m4/pthread_h.m4: Renamed from m4/pthread.m4.
41778         (gl_PTHREAD_H): Renamed from gl_PTHREAD_CHECK. Don't test whether
41779         <pthread.h> pollutes the namespace; instead, prepare for generating a
41780         pthread.h always. Substitute HAVE_PTHREAD_H here.
41781         (gl_PTHREAD_H_DEFAULTS): Renamed from gl_PTHREAD_DEFAULTS. Initialize
41782         GNULIB_PTHREAD. Don't initialize HAVE_PTHREAD_H here.
41783         * modules/pthread-h: New file, based on modules/pthread.
41784         * modules/pthread: Rely on 'pthread-h'.
41785         * m4/pthread_mutex_timedlock.m4 (gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK):
41786         Update.
41787         * modules/pthread_mutex_timedlock (Depends-on): Add pthread-h. Remove
41788         pthread.
41790 2019-07-14  Bruno Haible  <bruno@clisp.org>
41792         sched_yield: New module.
41793         * lib/sched.in.h: Add _GL_FUNCDECL_RPL, _GL_WARN_ON_USE placeholders.
41794         (sched_yield): New declaration.
41795         * lib/sched_yield.c: New file.
41796         * m4/sched_yield.m4: New file.
41797         * m4/sched_h.m4 (gl_SCHED_H): Require gl_SCHED_H_DEFAULTS. Arrange to
41798         provide a replacement sched.h always. Test whether sched_yield is
41799         declared.
41800         (gl_SCHED_MODULE_INDICATOR, gl_SCHED_H_DEFAULTS): New macros.
41801         * modules/sched (Depends-on): Add snippet/c++defs, snippet/warn-on-use.
41802         (Makefile.am): Provide a replacement sched.h always. Substitute
41803         GNULIB_SCHED_YIELD, HAVE_SCHED_YIELD, REPLACE_SCHED_YIELD,
41804         _GL_FUNCDECL_RPL, _GL_WARN_ON_USE.
41805         * modules/sched_yield: New file.
41806         * doc/posix-functions/sched_yield.texi: Mention the new module.
41808 2019-07-14  Bruno Haible  <bruno@clisp.org>
41810         windows-spin: New module.
41811         * lib/windows-spin.h: New file.
41812         * lib/windows-spin.c: New file.
41813         * modules/windows-spin: New file.
41815 2019-07-14  Bruno Haible  <bruno@clisp.org>
41817         windows-timedrwlock: New module.
41818         * lib/windows-timedrwlock.h: New file, based on windows-rwlock.h.
41819         * lib/windows-timedrwlock.c: New file, based on windows-rwlock.c and
41820         windows-cond.c.
41821         * lib/windows-cond.h (struct glwthread_waitqueue_link): Protect against
41822         redefinition conflict with windows-timedrwlock.h.
41823         * modules/windows-timedrwlock: New file.
41825 2019-07-14  Bruno Haible  <bruno@clisp.org>
41827         windows-rwlock: New module.
41828         * lib/windows-rwlock.h: New file, extracted from lib/glthread/lock.h.
41829         * lib/windows-rwlock.c: New file, extracted from lib/glthread/lock.c.
41830         * lib/glthread/lock.h: Include windows-rwlock.h. Don't include
41831         windows-initguard.h.
41832         (gl_rwlock_t): Define using glwthread_rwlock_t.
41833         (gl_rwlock_initializer): Define using GLWTHREAD_RWLOCK_INIT.
41834         (glthread_rwlock_init): Define using glwthread_rwlock_init.
41835         (glthread_rwlock_rdlock): Define using glwthread_rwlock_rdlock.
41836         (glthread_rwlock_wrlock): Define using glwthread_rwlock_wrlock.
41837         (glthread_rwlock_unlock): Define using glwthread_rwlock_unlock.
41838         (glthread_rwlock_destroy): Define using glwthread_rwlock_destroy.
41839         (glthread_rwlock_init_func, glthread_rwlock_rdlock_func,
41840         glthread_rwlock_wrlock_func, glthread_rwlock_unlock_func,
41841         glthread_rwlock_destroy_func): Remove declarations.
41842         * lib/glthread/lock.c (gl_waitqueue_t): Remove type.
41843         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_notify_first,
41844         gl_waitqueue_notify_all, glthread_rwlock_init_func,
41845         glthread_rwlock_rdlock_func, glthread_rwlock_wrlock_func,
41846         glthread_rwlock_unlock_func, glthread_rwlock_destroy_func): Remove
41847         functions.
41848         * modules/windows-rwlock: New file.
41849         * modules/lock (Depends-on): Add windows-rwlock.
41851 2019-07-14  Bruno Haible  <bruno@clisp.org>
41853         windows-thread: Add support for creating a thread in detached state.
41854         * lib/windows-thread.h (GLWTHREAD_ATTR_DETACHED): New macro.
41855         (glwthread_thread_create): Add attr argument.
41856         * lib/windows-thread.c (glwthread_thread_create): Likewise.
41857         * lib/glthread/thread.h (glthread_create): Update.
41858         * lib/thrd.c (thrd_create): Update.
41860 2019-07-14  Bruno Haible  <bruno@clisp.org>
41862         windows-*: Rename glwthread_spinlock_t to glwthread_initguard_t.
41863         * lib/windows-initguard.h: Renamed from lib/windows-spinlock.h.
41864         (glwthread_initguard_t): Renamed from glwthread_spinlock_t.
41865         (GLWTHREAD_INITGUARD_INIT): Renamed from GLWTHREAD_SPINLOCK_INIT.
41866         * lib/windows-mutex.h: Update.
41867         * lib/windows-recmutex.h: Likewise.
41868         * lib/windows-timedmutex.h: Likewise.
41869         * lib/windows-timedrecmutex.h: Likewise.
41870         * lib/windows-cond.h: Likewise.
41871         * lib/glthread/lock.h: Likewise.
41872         * modules/windows-mutex (Files): Add lib/windows-initguard.h. Remove
41873         lib/windows-spinlock.h.
41874         * modules/windows-recmutex (Files): Likewise.
41875         * modules/windows-timedmutex (Files): Likewise.
41876         * modules/windows-timedrecmutex (Files): Likewise.
41877         * modules/windows-cond (Files): Likewise.
41878         * modules/threads-h (Files): Likewise.
41880 2019-07-14  Bruno Haible  <bruno@clisp.org>
41882         doc: Fix info about pthread API in HP-UX.
41883         * doc/posix-functions/pthread_*.texi: Fix info about HP-UX 11.
41885 2019-07-14  Bruno Haible  <bruno@clisp.org>
41887         threads-h: Fix generation of threads.h.
41888         * modules/threads-h (Makefile.am): Insert the required header file
41889         snippets.
41891 2019-07-09  Bruno Haible  <bruno@clisp.org>
41893         striconveh test: Fix a compilation failure when iconv is not available.
41894         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
41895         * tests/test-striconveh.c (main): Move iconv_close invocations inside
41896         HAVE_ICONV.
41898 2019-07-07  Akim Demaille  <akim@lrde.epita.fr>
41900         argmatch: adjust columns for help2man.
41901         * lib/argmatch.h (argmatch_##Name##_doc_col): If some argument
41902         requires column 20 or more, return 20.
41904 2019-07-06  Paul Eggert  <eggert@cs.ucla.edu>
41906         areadlink-with-size: avoid realloc when size==0
41907         * lib/areadlink-with-size.c (areadlink_with_size):
41908         * lib/areadlinkat-with-size.c (areadlinkat_with_size):
41909         Reallocate at the end to the actual size, to avoid memory waste,
41910         as suggested by Bruno Haible.  But when the guessed size is zero -
41911         useful when the size is unknown - do the initial small readlink
41912         into the stack, to avoid that realloc in the usual case.
41914 2019-07-06  Pádraig Brady  <P@draigBrady.com>
41916         areadlink-with-size: guess a buffer size with 0 size
41917         The size is usually taken from st_size, which can be zero,
41918         resulting in inefficient operation.
41919         Instead let zero select an initial memory allocation
41920         of 128 bytes, which most symlinks fit within.
41921         * lib/areadlink-with-size.c (areadlink_with_size):
41922         Start with a 128 byte buffer, for SIZE == 0.
41923         * lib/areadlinkat-with-size.c (areadlinkat_with_size): Likewise.
41925 2019-07-06  Konstantin Kharlamov  <Hi-Angel@yandex.ru>
41927         Replace manually crafted hex regexes with [:xdigit:]
41928         * build-aux/gitlog-to-changelog (parse_amend_file)
41929         (git_dir_option):
41930         Replace various combinations of [0-9a-fA-F] with [[:xdigit:]].
41931         This patch is backported from Emacs (Bug#36167).
41933 2019-07-06  Bruno Haible  <bruno@clisp.org>
41935         error: Fix documentation.
41936         * doc/glibc-functions/error_at_line.texi: Document what the 'error'
41937         module provides.
41938         * doc/glibc-functions/error_message_count.texi: Likewise.
41939         * doc/glibc-functions/error_one_per_line.texi: Likewise.
41940         * doc/glibc-functions/error_print_progname.texi: Likewise.
41942 2019-07-06  Bruno Haible  <bruno@clisp.org>
41944         doc: Remove documentation of glibc <= 2.1.x as a supported platform.
41945         * doc/gnulib-intro.texi (Target Platforms): Mention that glibc 2.1.x
41946         and older is unsupported.
41947         * doc/**/*.texi: Update.
41949 2019-07-06  Bruno Haible  <bruno@clisp.org>
41951         doc: Remove documentation of Linux libc5 as a supported platform.
41952         * doc/posix-functions/iswalnum.texi: Don't mention workarounds specific
41953         to Linux libc5.
41954         * doc/posix-functions/iswalpha.texi: Likewise.
41955         * doc/posix-functions/iswblank.texi: Likewise.
41956         * doc/posix-functions/iswcntrl.texi: Likewise.
41957         * doc/posix-functions/iswdigit.texi: Likewise.
41958         * doc/posix-functions/iswgraph.texi: Likewise.
41959         * doc/posix-functions/iswlower.texi: Likewise.
41960         * doc/posix-functions/iswprint.texi: Likewise.
41961         * doc/posix-functions/iswpunct.texi: Likewise.
41962         * doc/posix-functions/iswspace.texi: Likewise.
41963         * doc/posix-functions/iswupper.texi: Likewise.
41964         * doc/posix-functions/iswxdigit.texi: Likewise.
41965         * doc/posix-functions/snprintf.texi: Likewise.
41966         * doc/posix-functions/vsnprintf.texi: Likewise.
41968 2019-07-06  Bruno Haible  <bruno@clisp.org>
41970         doc: Remove documentation of Tandem/NSK as a supported platform.
41971         * doc/posix-headers/stdlib.texi: Don't mention workarounds specific to
41972         Tandem/NSK.
41973         * doc/**/*.texi: Update.
41975 2019-07-06  Bruno Haible  <bruno@clisp.org>
41977         doc: Remove documentation of Mac OS X <= 10.4 as a supported platform.
41978         * doc/gnulib-intro.texi (Target Platforms): Mention that Mac OS X 10.4
41979         and older is unsupported.
41980         * doc/posix-functions/acosl.texi: Don't mention workarounds specific to
41981         Mac OS X 10.4 and older.
41982         * doc/posix-functions/asinl.texi: Likewise.
41983         * doc/posix-functions/atanl.texi: Likewise.
41984         * doc/posix-functions/cosl.texi: Likewise.
41985         * doc/posix-functions/expl.texi: Likewise.
41986         * doc/posix-functions/frexpl.texi: Likewise.
41987         * doc/posix-functions/gettimeofday.texi: Likewise.
41988         * doc/posix-functions/logl.texi: Likewise.
41989         * doc/posix-functions/mkstemp.texi: Likewise.
41990         * doc/posix-functions/sinl.texi: Likewise.
41991         * doc/posix-functions/sqrtl.texi: Likewise.
41992         * doc/posix-functions/tanl.texi: Likewise.
41993         * doc/posix-functions/wcswidth.texi: Likewise.
41994         * doc/**/*.texi: Update.
41996 2019-07-06  Bruno Haible  <bruno@clisp.org>
41998         doc: Remove documentation of AIX 4 as a supported platform.
41999         * doc/gnulib-intro.texi (Target Platforms): Mention that AIX 4 is
42000         unsupported.
42001         * doc/posix-functions/nanosleep.texi: Don't mention AIX 4 specific
42002         workarounds.
42003         * doc/posix-functions/strnlen.texi: Likewise.
42004         * doc/posix-headers/inttypes.texi: Likewise.
42005         * doc/**/*.texi: Update.
42007 2019-07-06  Bruno Haible  <bruno@clisp.org>
42009         doc: Remove documentation of HP-UX 10 as a supported platform.
42010         * doc/gnulib-intro.texi (Target Platforms): Mention that HP-UX 10 is
42011         unsupported.
42012         * doc/*-functions/*printf.texi: Don't mention HP-UX 10 specific
42013         workarounds.
42014         * doc/posix-functions/gmtime_r.texi: Likewise.
42015         * doc/posix-functions/localtime_r.texi: Likewise.
42016         * doc/posix-functions/mkstemp.texi: Likewise.
42017         * doc/**/*.texi: Update.
42019 2019-07-06  Bruno Haible  <bruno@clisp.org>
42021         doc: Remove documentation of Interix 3.5 as a supported platform.
42022         * doc/gnulib-intro.texi (Target Platforms): Mention that Interix is
42023         unsupported.
42024         * doc/posix-functions/select.texi: Don't mention Interix specific
42025         workarounds.
42026         * doc/posix-headers/signal.texi: Likewise.
42027         * doc/**/*.texi: Update.
42029 2019-07-06  Bruno Haible  <bruno@clisp.org>
42031         doc: Remove documentation of IRIX 6.4 and older as supported platforms.
42032         * doc/gnulib-intro.texi (Target Platforms): Mention that IRIX <= 6.4 is
42033         unsupported.
42034         * doc/pastposix-functions/usleep.texi: Don't mention IRIX specific
42035         workarounds.
42036         * doc/posix-functions/nl_langinfo.texi: Likewise.
42037         * doc/posix-functions/remainder.texi: Likewise.
42038         * doc/posix-functions/towlower.texi: Likewise.
42039         * doc/posix-functions/towupper.texi: Likewise.
42040         * doc/posix-functions/vsnprintf.texi: Likewise.
42041         * doc/posix-functions/wcscat.texi: Likewise.
42042         * doc/posix-functions/wcschr.texi: Likewise.
42043         * doc/posix-functions/wcscmp.texi: Likewise.
42044         * doc/posix-functions/wcscpy.texi: Likewise.
42045         * doc/posix-functions/wcscspn.texi: Likewise.
42046         * doc/posix-functions/wcslen.texi: Likewise.
42047         * doc/posix-functions/wcsncat.texi: Likewise.
42048         * doc/posix-functions/wcsncmp.texi: Likewise.
42049         * doc/posix-functions/wcsncpy.texi: Likewise.
42050         * doc/posix-functions/wcspbrk.texi: Likewise.
42051         * doc/posix-functions/wcsrchr.texi: Likewise.
42052         * doc/posix-functions/wcsspn.texi: Likewise.
42053         * doc/posix-headers/langinfo.texi: Likewise.
42054         * doc/posix-headers/signal.texi: Likewise.
42055         * doc/posix-headers/wchar.texi: Likewise.
42056         * doc/posix-headers/wctype.texi: Likewise.
42057         * doc/**/*.texi: Update.
42059 2019-07-05  Bruno Haible  <bruno@clisp.org>
42061         doc: Remove documentation of OSF/1 as supported platform.
42062         * doc/gnulib-intro.texi (Target Platforms): Mention that OSF/1 is
42063         unsupported.
42064         * doc/glibc-functions/getdomainname.texi: Don't mention OSF/1 specific
42065         workarounds.
42066         * doc/glibc-functions/pthread_setname_np.texi: Likewise.
42067         * doc/glibc-functions/ptsname_r.texi: Likewise.
42068         * doc/posix-functions/ceil.texi: Likewise.
42069         * doc/posix-functions/ceilf.texi: Likewise.
42070         * doc/posix-functions/ceill.texi: Likewise.
42071         * doc/posix-functions/fchdir.texi: Likewise.
42072         * doc/posix-functions/floor.texi: Likewise.
42073         * doc/posix-functions/floorf.texi: Likewise.
42074         * doc/posix-functions/fmod.texi: Likewise.
42075         * doc/posix-functions/fmodf.texi: Likewise.
42076         * doc/posix-functions/fmodl.texi: Likewise.
42077         * doc/posix-functions/log.texi: Likewise.
42078         * doc/posix-functions/logf.texi: Likewise.
42079         * doc/posix-functions/logl.texi: Likewise.
42080         * doc/posix-functions/log10.texi: Likewise.
42081         * doc/posix-functions/log10f.texi: Likewise.
42082         * doc/posix-functions/log10l.texi: Likewise.
42083         * doc/posix-functions/log2.texi: Likewise.
42084         * doc/posix-functions/log2f.texi: Likewise.
42085         * doc/posix-functions/log2l.texi: Likewise.
42086         * doc/posix-functions/mbrtowc.texi: Likewise.
42087         * doc/posix-functions/recv.texi: Likewise.
42088         * doc/posix-functions/recvfrom.texi: Likewise.
42089         * doc/posix-functions/remainder.texi: Likewise.
42090         * doc/posix-functions/remainderf.texi: Likewise.
42091         * doc/posix-functions/remainderl.texi: Likewise.
42092         * doc/posix-functions/round.texi: Likewise.
42093         * doc/posix-functions/roundf.texi: Likewise.
42094         * doc/posix-functions/roundl.texi: Likewise.
42095         * doc/posix-functions/send.texi: Likewise.
42096         * doc/posix-functions/sendto.texi: Likewise.
42097         * doc/posix-functions/setenv.texi: Likewise.
42098         * doc/posix-functions/snprintf.texi: Likewise.
42099         * doc/posix-functions/tcgetsid.texi: Likewise.
42100         * doc/posix-functions/trunc.texi: Likewise.
42101         * doc/posix-functions/truncf.texi: Likewise.
42102         * doc/posix-functions/truncl.texi: Likewise.
42103         * doc/posix-functions/ttyname_r.texi: Likewise.
42104         * doc/posix-functions/unsetenv.texi: Likewise.
42105         * doc/posix-functions/wcsrtombs.texi: Likewise.
42106         * doc/posix-headers/sys_select.texi: Likewise.
42107         * doc/posix-headers/wchar.texi: Likewise.
42108         * doc/posix-headers/wctype.texi: Likewise.
42109         * doc/**/*.texi: Update.
42111 2019-07-05  Bruno Haible  <bruno@clisp.org>
42113         doc: Remove documentation of BSDI and BSD/OS as supported platforms.
42114         * doc/**/*.texi: Update.
42116 2019-07-05  Bruno Haible  <bruno@clisp.org>
42118         doc: Remove documentation of Solaris 8 and older as supported platforms.
42119         * doc/gnulib-intro.texi (Target Platforms): Mention that Solaris <= 8 is
42120         unsupported.
42121         * doc/posix-functions/mbrtowc.texi: Don't mention Solaris specific
42122         workarounds.
42123         * doc/posix-functions/memcmp.texi: Likewise.
42124         * doc/posix-functions/rename.texi: Likewise.
42125         * doc/posix-functions/tzset.texi: Likewise.
42126         * doc/posix-headers/wctype.texi: Likewise.
42127         * doc/**/*.texi: Update.
42129 2019-07-05  Bruno Haible  <bruno@clisp.org>
42131         doc: Remove documentation of Interix 3.5 as a supported platform.
42132         * doc/**/*.texi: Update.
42134 2019-07-05  Bruno Haible  <bruno@clisp.org>
42136         doc: Remove documentation of BeOS as a supported platform.
42137         * doc/gnulib-intro.texi (Target Platforms): Mention that BeOS is
42138         unsupported.
42139         * doc/*-functions/*printf.texi: Don't mention BeOS specific workarounds.
42140         * doc/posix-functions/getdelim.texi: Likewise.
42141         * doc/**/*.texi: Update.
42143 2019-07-05  Bruno Haible  <bruno@clisp.org>
42145         thread, lock, cond, tls: Remove support for Pth threads.
42146         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Don't document
42147         --enable-threads=pth any more.
42148         (gl_THREADLIB_BODY): Don't set USE_PTH_THREADS any more.
42149         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Update comment.
42150         * m4/threads.m4 (gl_THREADS_H): Remove test for conflict between Pth
42151         threads and ISO C11 threads.
42152         * lib/glthread/thread.h: Remove code for USE_PTH_THREADS.
42153         * lib/glthread/lock.h: Likewise.
42154         * lib/glthread/lock.c: Likewise.
42155         * lib/glthread/cond.h: Likewise.
42156         * lib/glthread/cond.c: Likewise.
42157         * lib/glthread/tls.h: Likewise.
42158         * lib/glthread/tls.c: Likewise.
42159         * lib/glthread/yield.h: Likewise.
42160         * lib/regex_internal.h: Likewise.
42161         * tests/test-thread_create.c: Likewise.
42162         * tests/test-lock.c: Likewise.
42163         * tests/test-cond.c: Likewise.
42164         * tests/test-tls.c: Likewise.
42165         * tests/test-rwlock1.c: Don't include glthread/yield.h.
42166         (main): Sleep without calling gl_thread_yield.
42168 2019-07-05  Bruno Haible  <bruno@clisp.org>
42170         thread, lock, cond, tls: Remove support for old Solaris threads.
42171         Solaris >= 2.5.1 has POSIX threads.
42172         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Don't document
42173         --enable-threads=solaris any more.
42174         (gl_THREADLIB_BODY): Don't set USE_SOLARIS_THREADS any more.
42175         * lib/glthread/thread.c: Update comment.
42176         * lib/glthread/thread.h: Remove code for USE_SOLARIS_THREADS.
42177         * lib/glthread/lock.h: Likewise.
42178         * lib/glthread/lock.c: Likewise.
42179         * lib/glthread/cond.h: Likewise.
42180         * lib/glthread/cond.c: Likewise.
42181         * lib/glthread/tls.h: Likewise.
42182         * lib/glthread/tls.c: Likewise.
42183         * lib/glthread/yield.h: Likewise.
42184         * lib/regex_internal.h: Likewise.
42185         * tests/test-thread_create.c: Likewise.
42186         * tests/test-lock.c: Likewise.
42187         * tests/test-cond.c: Likewise.
42188         * tests/test-tls.c: Likewise.
42190 2019-07-05  Bruno Haible  <bruno@clisp.org>
42192         getcwd-lgpl, getcwd: Don't call realloc when it is pointless.
42193         * lib/getcwd-lgpl.c (rpl_getcwd): Don't call realloc if the result's
42194         needed size is equal to the allocated size.
42195         * lib/getcwd.c (__getcwd): Likewise.
42197 2019-07-05  Bruno Haible  <bruno@clisp.org>
42199         xgetdomainname: Don't return an excessive memory allocation.
42200         * lib/xgetdomainname.c (xgetdomainname): Shrink the domainname buffer
42201         before returning it.
42203 2019-07-05  Bruno Haible  <bruno@clisp.org>
42205         xgethostname: Don't return an excessive memory allocation.
42206         * lib/xgethostname.c (xgethostname): Shrink the hostname buffer before
42207         returning it.
42209 2019-07-05  Bruno Haible  <bruno@clisp.org>
42211         areadlinkat-with-size: Don't return an excessive memory allocation.
42212         * lib/areadlinkat-with-size.c (areadlinkat_with_size): Shrink the buffer
42213         before returning it.
42215 2019-07-05  Bruno Haible  <bruno@clisp.org>
42217         areadlink-with-size: Don't return an excessive memory allocation.
42218         Reported by Andreas Dilger <adilger@whamcloud.com>.
42219         * lib/areadlink-with-size.c (areadlink_with_size): Shrink the buffer
42220         before returning it.
42222 2019-07-03  Bruno Haible  <bruno@clisp.org>
42224         renameatu: Fix test failure on MSVC.
42225         * lib/at-func2.c (at_func2): Fail with ENOENT if file1 or file2 is the
42226         empty string.
42228 2019-07-03  Bruno Haible  <bruno@clisp.org>
42230         mbrtowc: Fix invalid use of mbtowc() on MSVC.
42231         * lib/mbrtowc.c: Include glthread/lock.h.
42232         (mbtowc_lock): New variable.
42233         (mbrtowc): Treat UTF-8 encoding without locking. For the other
42234         encodings, explicitly reset the internal state of mbtowc, and protect
42235         this through a lock.
42236         * modules/mbrtowc (Depends-on): Add lock.
42238 2019-07-03  Akim Demaille  <akim@lrde.epita.fr>
42240         argmatch: don't define _ in the header.
42241         Reported by Jim Meyering.
42242         * lib/argmatch.h (N_, _): Don't define.
42243         Use gettext instead.
42244         * lib/argmatch.h (_): Define.
42245         * tests/test-argmatch.c (N_): Define.
42247 2019-07-02  Paul Eggert  <eggert@cs.ucla.edu>
42249         verify: document ‘assume’ better
42250         * lib/verify.h: Reword doc (Bug#36370).
42252 2019-07-02  Bruno Haible  <bruno@clisp.org>
42254         localcharset, nl_langinfo: Fix return value for UTF-8 locales on MSVC.
42255         * lib/localcharset.c (locale_charset): Return "UTF-8" instead of
42256         "CPutf8".
42257         * lib/nl_langinfo.c (ctype_codeset): Likewise.
42259 2019-07-02  Bruno Haible  <bruno@clisp.org>
42261         getcwd: Fix crash when invoked with size = 0 on MSVC.
42262         * lib/getcwd.c: Include msvc-inval.h.
42263         (getcwd_nothrow): New function/macro.
42264         (getcwd_system): New macro.
42265         (__getcwd): Use it instead of getcwd.
42266         * modules/getcwd (Depends-on): Add msvc-inval.
42267         * doc/posix-functions/getcwd.texi: Mention the MSVC issue.
42269 2019-07-02  Bruno Haible  <bruno@clisp.org>
42271         nonblocking-pipe tests: Fix test failure on MSVC.
42272         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE): Set to 10000 on
42273         native Windows.
42275 2019-07-02  Bruno Haible  <bruno@clisp.org>
42277         usleep: Implement with millisecond resolution on native Windows.
42278         * lib/usleep.c (usleep): On native Windows, implement using Sleep().
42279         * doc/pastposix-functions/usleep.texi: Update accordingly.
42281 2019-07-02  Bruno Haible  <bruno@clisp.org>
42283         lstat tests: Fix test failure on MSVC.
42284         * tests/test-lstat.h (test_lstat_func): Don't test SAME_INODE values on
42285         native Windows, unless _GL_WINDOWS_STAT_INODES is defined.
42287 2019-07-02  Bruno Haible  <bruno@clisp.org>
42289         stat tests: Fix test failure on MSVC.
42290         * tests/test-stat.h (test_stat_func): Don't test SAME_INODE values on
42291         native Windows, unless _GL_WINDOWS_STAT_INODES is defined.
42293 2019-07-02  Bruno Haible  <bruno@clisp.org>
42295         getaddrinfo tests: Fix test failure on MSVC.
42296         * tests/test-getaddrinfo.c: Include sockets.h.
42297         (main): Invoke gl_sockets_startup.
42298         * modules/getaddrinfo-tests (Depends-on): Add sockets.
42300 2019-07-01  Hannes Müller  <h.c.f.mueller@gmx.de>
42302         poll: Fix type of timeout pointer passed to select() on mingw x86_64.
42303         * lib/poll.c: Call Windows native select() with Windows native timeval.
42305 2019-06-30  Bruno Haible  <bruno@clisp.org>
42307         argmatch: Fix compilation errors.
42308         * lib/argmatch.h: Include <limits.h>, for INT_MAX.
42309         * tests/test-argmatch.c (main): Update after last-minute function names
42310         change.
42312 2019-06-30  Bruno Haible  <bruno@clisp.org>
42314         Include <stdlib.h> when needed.
42315         * lib/cnd.c: Include <stdlib.h>, needed for abort().
42316         * lib/fcntl.c: Likewise.
42317         * lib/mbscasestr.c: Likewise.
42318         * lib/mbssep.c: Likewise.
42319         * lib/mbsstr.c: Likewise.
42320         * lib/openat.c: Include <stdlib.h>, needed for free().
42321         * lib/windows-tls.c: Include <stdlib.h>, needed for malloc(), free(),
42322         abort().
42324 2019-06-30  Bruno Haible  <bruno@clisp.org>
42326         Include <stdlib.h> when needed.
42327         * lib/areadlinkat.c: Include <stdlib.h>, needed for free() in at-func.c.
42328         * lib/faccessat.c: Likewise.
42329         * lib/fchmodat.c: Likewise.
42330         * lib/fchownat.c: Likewise.
42331         * lib/fstatat.c: Likewise.
42332         * lib/mkfifoat.c: Likewise.
42333         * lib/mknodat.c: Likewise.
42334         * lib/readlinkat.c: Likewise.
42335         * lib/symlinkat.c: Likewise.
42336         * lib/utimensat.c: Likewise.
42337         * lib/mkdirat.c: Likewise. Include also the specification header.
42339 2019-06-30  Bruno Haible  <bruno@clisp.org>
42341         inet_ntop, inet_pton: Avoid conflict with native Windows functions.
42342         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WS2TCPIP): New macro, extracted
42343         from gl_PREREQ_SYS_H_SOCKET.
42344         (gl_PREREQ_SYS_H_SOCKET): Invoke it.
42345         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Invoke
42346         gl_PREREQ_SYS_H_WS2TCPIP.
42347         * modules/arpa_inet (Files): Add m4/sys_socket_h.m4, m4/socklen.m4.
42348         (Makefile.am): Substitute HAVE_WS2TCPIP_H.
42349         * lib/arpa_inet.in.h: Include <ws2tcpip.h>.
42351 2019-06-30  Bruno Haible  <bruno@clisp.org>
42353         inet_ntop, inet_pton: Forward-compatibility with newer Windows versions.
42354         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): On native Windows, set
42355         REPLACE_INET_NTOP to 1 always.
42356         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): On native Windows, set
42357         REPLACE_INET_PTON to 1 always.
42359 2019-06-30  Bruno Haible  <bruno@clisp.org>
42361         inet_pton: Fix link error on mingw with _WIN32_WINNT >= 0x0600.
42362         * modules/inet_pton (Depends-on, configure.ac): Test REPLACE_INET_PTON,
42363         not REPLACE_INET_NTOP.
42365 2019-06-30  Bruno Haible  <bruno@clisp.org>
42367         poll: Add comment.
42368         * lib/poll.c: Add comment about WSAPoll.
42370 2019-06-30  Bruno Haible  <bruno@clisp.org>
42372         poll-h: Fix compilation error on mingw with _WIN32_WINNT >= 0x0600.
42373         Reported by Hannes Müller <h.c.f.mueller@gmx.de>.
42374         * lib/poll.in.h: Include <winsock2.h>.
42375         (POLL*, pollfd): Override on native Windows.
42376         * m4/poll_h.m4 (gl_POLL_H): Invoke gl_PREREQ_SYS_H_WINSOCK2.
42377         * modules/poll-h (Files): Add m4/sys_socket_h.m4.
42378         (Makefile.am): Substitute HAVE_WINSOCK2_H.
42380 2019-06-28  Bruno Haible  <bruno@clisp.org>
42382         accept4: Fix compilation error on OpenIndiana.
42383         Reported by Michal Nowak <mnowak@startmail.com>
42384         via Mark H Weaver <mhw@netris.org>.
42385         * m4/accept.m4 (gl_FUNC_ACCEPT4): Test whether accept4 is declared, not
42386         whether it exists as a function.
42388 2019-06-26  Paul Eggert  <eggert@cs.ucla.edu>
42390         strverscmp: sync from glibc
42391         * lib/strverscmp.c: Sync from glibc, except use UTF-8 encoding in
42392         comments, include libc-config.h, define __strverscmp to be
42393         strverscmp, and don’t assume types line uint8_t and int8_t that
42394         that C99 doesn’t guarantee.
42395         [!_LIBC]: Include libc-config.h; define __strverscmp.
42396         Include stdint.h.
42397         (__strverscmp): Assume C99.  Use uint_least8_t
42398         and int_least8_t instead of unsigned char and signed char.
42399         * modules/strverscmp (Depends-on): Add libc-config, stdint.
42401 2019-06-25  Bruno Haible  <bruno@clisp.org>
42403         tss tests: Add tests for destructors and races.
42404         * tests/test-tss.c (worker_thread): Fix typo in debug message.
42405         (test_tss_dtorcheck1, test_tss_dtorcheck2, test_tss_racecheck): New
42406         functions.
42407         (main): Invoke them.
42408         * modules/tls-tests (Depends-on): Add mtx.
42410 2019-06-25  Bruno Haible  <bruno@clisp.org>
42412         tls tests: Add tests for destructors and races.
42413         * tests/test-tls.c: Include glthread/lock.h.
42414         (test_tls_dtorcheck1, test_tls_dtorcheck2, test_tls_racecheck): New
42415         functions.
42416         (main): Invoke them.
42417         * modules/tls-tests (Depends-on): Add lock.
42419 2019-06-25  Bruno Haible  <bruno@clisp.org>
42421         windows-tls: Implement TLS key destructors for native Windows.
42422         * lib/windows-tls.h (glwthread_tls_process_destructors): New
42423         declaration.
42424         (GLWTHREAD_DESTRUCTOR_ITERATIONS): New macro.
42425         * lib/windows-tls.c: Include <limits.h>, windows-once.h.
42426         (dtor_table_init_once, dtor_table_lock: New variables.
42427         (struct dtor): New type.
42428         (dtor_table, dtors_count, dtors_used, dtors_allocated,
42429         dtor_processing_threads): New variables.
42430         (dtor_table_initialize, dtor_table_ensure_initialized,
42431         dtor_table_shrink_used, glwthread_tls_process_destructors): New
42432         functions.
42433         (glwthread_tls_key_create, glwthread_tls_key_delete): Rewritten to
42434         handle non-NULL destructors.
42435         * modules/windows-tls (Depends-on): Add windows-once.
42436         * lib/glthread/tls.h (glthread_tls_key_init, glthread_tls_key_destroy):
42437         Use the functions declared in windows-tls.h.
42438         * lib/threads.in.h (TSS_DTOR_ITERATIONS): Define using
42439         GLWTHREAD_DESTRUCTOR_ITERATIONS.
42440         * lib/windows-thread.c: Include windows-tls.h.
42441         (wrapper_func, glwthread_thread_exit): Invoke
42442         glwthread_tls_process_destructors.
42443         * modules/windows-thread (Depends-on): Add windows-tls.
42445 2019-06-25  Bruno Haible  <bruno@clisp.org>
42447         threadlib: Avoid autoconf warning "was expanded before it was required".
42448         * modules/threadlib (configure.ac): Require gl_THREADLIB.
42450 2019-06-25  Akim Demaille  <akim@lrde.epita.fr>
42452         argmatch: remove duplicate const qualifier
42453         * lib/argmatch.h (ARGMATCH_DEFINE_GROUP): Here.
42455 2019-06-24  Paul Eggert  <eggert@cs.ucla.edu>
42457         unistd: stddef.h and sys/types.h namespace cleanup
42458         * lib/unistd.in.h [__GLIBC__]:
42459         Do not include stddef.h or sys/types.h.
42460         [!__GLIBC__]: Always include sys/types.h, since unistd.h is
42461         supposed to declare off_t and ssize_t.  Problem found when looking
42462         at why @GNULIB_PWRITE@ was different from the newly-added
42463         @GNULIB_COPY_FILE_RANGE@ with respect to ssize_t.
42465 2019-06-22  Akim Demaille  <akim@lrde.epita.fr>
42467         maintainer-makefile: restore portability to non-GNU awks
42468         Reported by Tim Rühsen.
42469         * top/maint.mk (AWK): New variable.  Use it.
42470         (sc_prohibit_gnu_make_extensions): Skip if $(AWK) is not gawk.
42472 2019-06-23  Paul Eggert  <eggert@cs.ucla.edu>
42474         Document setvbuf _IOLBF problem
42475         * doc/posix-functions/setvbuf.texi (setvbuf):
42476         Document MS-Windows portability problem with _IOLBF.
42478         Document lseek SEEK_DATA/SEEK_HOLE
42479         * doc/posix-functions/lseek.texi (lseek):
42480         Document some systems that do not support SEEK_DATA and SEEK_HOLE.
42482 2019-06-22  Akim Demaille  <akim@lrde.epita.fr>
42484         argmatch: put all the docs member last.
42485         Reported by Bruno Haible.
42486         * lib/argmatch.h (argmatch_##Name##_group_type): Put the args
42487         member before the docs done.
42488         * doc/argmatch.texi, tests/test-argmatch.c: Adjust.
42490 2019-06-21  Akim Demaille  <akim@lrde.epita.fr>
42492         argmatch: add support to generate the usage message.
42493         * lib/argmatch.c: Move some #includes and gettext support to...
42494         * lib/argmatch.h: here.
42495         (ARGMATCH_DEFINE_GROUP): New macro.
42496         * tests/test-argmatch.c (argmatch_backup_docs, argmatch_backup_args)
42497         (argmatch_backup_group): New.
42498         (CHECK): New.
42499         (main): Check argmatch_backup_value, argmatch_backup_xvalue,
42500         argmatch_backup_argument and argmatch_backup_usage.
42501         * modules/argmatch: We depend on c99.
42502         * doc/argmatch.texi (Recognizing Option Arguments): New.
42503         * doc/gnulib.texi: Use it.
42505 2019-06-21  Bruno Haible  <bruno@clisp.org>
42507         thrd: Add comment.
42508         * lib/thrd.c (pthread_main_func): Add comment.
42510 2019-06-21  Bruno Haible  <bruno@clisp.org>
42512         threads-h: Define 'thread_local' if and only if it actually works.
42513         * m4/threads.m4 (gl_THREAD_LOCAL_DEFINITION): New macro.
42514         (gl_THREADS_H): Define _Thread_local to __thread also for ARM C, IBM C,
42515         Oracle Solaris Studio C. Compile a simple program, to see whether
42516         _Thread_local basically works. Set HAVE_THREAD_LOCAL and LIBTHREADLOCAL.
42517         (gl_THREADS_H_DEFAULTS): Initialize HAVE_THREAD_LOCAL.
42518         * lib/threads.in.h (thread_local): Undefine if it does not work.
42519         * modules/threads-h (Makefile.am): Substitute HAVE_THREAD_LOCAL.
42520         (Link): Mention LIBTHREADLOCAL.
42521         * tests/test-threads.c: Don't check that thread_local is defined.
42522         * tests/test-thread_local.c: New file.
42523         * modules/threads-h-tests (Files): Add it and macros.h.
42524         (Depends-on): Add thrd and stdint.
42525         (configure.ac): Test whether 'alarm' is declared.
42526         (Makefile.am): Arrange to build and link test-thread_local.
42527         * doc/posix-headers/threads.texi: Mention the platforms that don't
42528         support 'thread_local'.
42530 2019-06-20  Bruno Haible  <bruno@clisp.org>
42532         threads-h: Simplify link dependencies.
42533         * m4/threads.m4 (gl_THREADS_H): Bail out if Pth threading is requested.
42534         Don't set LTLIBSTDTHREAD.
42535         * modules/thrd (Link): Simplify accordingly.
42536         * modules/mtx (Link): Likewise.
42537         * modules/cnd (Link): Likewise.
42538         * modules/tss (Link): Likewise.
42539         * modules/threads (Link): Likewise.
42541 2019-06-20  Bruno Haible  <bruno@clisp.org>
42543         threads-h: Fix link error on FreeBSD 11.
42544         * m4/threads.m4 (gl_THREADS_H): When linking with -lstdthreads, link
42545         also with -lpthread.
42547 2019-06-20  Bruno Haible  <bruno@clisp.org>
42549         threadlib: Fix typo (regression from today).
42550         * m4/threadlib.m4 (gl_THREADLIB_BODY): Fix typo in comment marker.
42552 2019-06-20  Bruno Haible  <bruno@clisp.org>
42554         windows-thread, windows-tls: Fix compilation error on 32-bit mingw.
42555         * lib/windows-thread.c: Include <errno.h>.
42556         * lib/windows-tls.c: Likewise.
42558 2019-06-20  Bruno Haible  <bruno@clisp.org>
42560         tss tests: Small improvement.
42561         * tests/test-tss.c (test_tss): Pass a different id to each thread.
42563 2019-06-20  Bruno Haible  <bruno@clisp.org>
42565         threads: New module.
42566         * modules/threads: New file.
42568 2019-06-20  Bruno Haible  <bruno@clisp.org>
42570         tss: Add tests.
42571         * tests/test-tss.c: New file, based on tests/test-tls.c.
42572         * modules/tss-tests: New file.
42574 2019-06-20  Bruno Haible  <bruno@clisp.org>
42576         cnd: Add tests.
42577         * tests/test-cnd.c: New file, based on tests/test-cond.c.
42578         * modules/cnd-tests: New file.
42580 2019-06-20  Bruno Haible  <bruno@clisp.org>
42582         mtx: Add tests.
42583         * tests/test-mtx.c: New file, based on tests/test-lock.c.
42584         * tests/test-call_once.c: New file, based on tests/test-once.c.
42585         * modules/mtx-tests: New file.
42587 2019-06-20  Bruno Haible  <bruno@clisp.org>
42589         thrd: Add tests.
42590         * tests/test-thrd_create.c: New file, based on
42591         tests/test-thread_create.c.
42592         * tests/test-thrd_current.c: New file, based on
42593         tests/test-thread_self.c.
42594         * modules/thrd-tests: New file.
42596 2019-06-20  Bruno Haible  <bruno@clisp.org>
42598         tss: New module.
42599         * lib/tss.c: New file.
42600         * modules/tss: New file.
42601         * doc/posix-functions/tss_create.texi: Mention the new module.
42602         * doc/posix-functions/tss_set.texi: Likewise.
42603         * doc/posix-functions/tss_get.texi: Likewise.
42604         * doc/posix-functions/tss_delete.texi: Likewise.
42606 2019-06-20  Bruno Haible  <bruno@clisp.org>
42608         cnd: New module.
42609         * lib/cnd.c: New file.
42610         * modules/cnd: New file.
42611         * doc/posix-functions/cnd_init.texi: Mention the new module.
42612         * doc/posix-functions/cnd_wait.texi: Likewise.
42613         * doc/posix-functions/cnd_timedwait.texi: Likewise.
42614         * doc/posix-functions/cnd_signal.texi: Likewise.
42615         * doc/posix-functions/cnd_broadcast.texi: Likewise.
42616         * doc/posix-functions/cnd_destroy.texi: Likewise.
42618 2019-06-20  Bruno Haible  <bruno@clisp.org>
42620         mtx: New module.
42621         * lib/mtx.c: New file.
42622         * modules/mtx: New file.
42623         * doc/posix-functions/call_once.texi: Mention the new module.
42624         * doc/posix-functions/mtx_init.texi: Likewise.
42625         * doc/posix-functions/mtx_lock.texi: Likewise.
42626         * doc/posix-functions/mtx_trylock.texi: Likewise.
42627         * doc/posix-functions/mtx_timedlock.texi: Likewise.
42628         * doc/posix-functions/mtx_unlock.texi: Likewise.
42629         * doc/posix-functions/mtx_destroy.texi: Likewise.
42631 2019-06-20  Bruno Haible  <bruno@clisp.org>
42633         thrd: New module.
42634         * lib/thrd.c: New file.
42635         * m4/thrd.m4: New file.
42636         * modules/thrd: New file.
42637         * doc/posix-functions/thrd_current.texi: Mention the new module.
42638         * doc/posix-functions/thrd_detach.texi: Likewise.
42639         * doc/posix-functions/thrd_equal.texi: Likewise.
42640         * doc/posix-functions/thrd_exit.texi: Likewise.
42641         * doc/posix-functions/thrd_sleep.texi: Likewise.
42642         * doc/posix-functions/thrd_yield.texi: Likewise.
42643         * doc/posix-functions/thrd_create.texi: Mention the new module and the
42644         AIX bug.
42645         * doc/posix-functions/thrd_join.texi: Mention the new module and the
42646         AIX and Solaris bugs.
42648 2019-06-20  Bruno Haible  <bruno@clisp.org>
42650         threads-h: Add tests.
42651         * tests/test-threads.c: New file.
42652         * modules/threads-h-tests: New file.
42653         * tests/test-threads-c++.cc: New file.
42654         * modules/threads-h-c++-tests: New file.
42656 2019-06-20  Bruno Haible  <bruno@clisp.org>
42658         threads-h: New module.
42659         * lib/threads.in.h: New file.
42660         * m4/threads.m4: New file.
42661         * m4/yield.m4 (gl_YIELD): Update comment.
42662         * modules/threads-h: New file.
42663         * modules/yields (configure.ac): Use AC_REQUIRE.
42664         * doc/posix-headers/threads.texi: Mention the new module and the AIX
42665         bugs.
42667 2019-06-20  Bruno Haible  <bruno@clisp.org>
42669         windows-thread: New module.
42670         * lib/windows-thread.h: New file, based on lib/glthread/thread.h.
42671         * lib/windows-thread.c: New file, based on lib/glthread/thread.c.
42672         * lib/glthread/thread.h: Include windows-thread.h.
42673         (gl_thread_t): Define using glwthread_thread_t.
42674         (glthread_create): Define using glwthread_thread_create.
42675         (glthread_join): Define using glwthread_thread_join.
42676         (gl_thread_self): Define using glwthread_thread_self.
42677         (gl_thread_exit): Define using glwthread_thread_exit.
42678         (glthread_create_func, glthread_join_func, gl_thread_self_func,
42679         gl_thread_exit_func): Remove declarations.
42680         * lib/glthread/thread.c (self_key): Remove variable.
42681         (do_init_self_key, init_self_key): Remove functions.
42682         (struct gl_thread_struct): Remove type.
42683         (get_current_thread_handle, gl_thread_self_func, wrapper_func,
42684         glthread_create_func, glthread_join_func, gl_thread_exit_func): Remove
42685         functions.
42686         * modules/windows-thread: New file.
42687         * modules/thread (Depends-on): Add windows-thread.
42689 2019-06-20  Bruno Haible  <bruno@clisp.org>
42691         windows-tls: New module.
42692         * lib/windows-tls.h: New file, based on lib/glthread/tls.h.
42693         * lib/windows-tls.c: New file, based on lib/glthread/tls.h.
42694         * lib/glthread/tls.h: Include windows-tls.h.
42695         (gl_tls_key_t): Define using glwthread_tls_key_t.
42696         * modules/windows-tls: New file.
42697         * modules/tls (Depends-on): Add windows-tls.
42699 2019-06-20  Bruno Haible  <bruno@clisp.org>
42701         windows-cond: New module.
42702         * lib/windows-cond.h: New file, based on lib/glthread/cond.h.
42703         * lib/windows-cond.c: New file, based on lib/glthread/cond.c.
42704         * lib/glthread/cond.h: Include windows-cond.h.
42705         (struct gl_waitqueue_link, gl_linked_waitqueue_t): Remove types.
42706         (gl_cond_t): Define using glwthread_cond_t.
42707         (gl_cond_initializer): Define using GLWTHREAD_COND_INIT.
42708         (glthread_cond_init): Define using glwthread_cond_init.
42709         (glthread_cond_wait): Define using glwthread_cond_wait.
42710         (glthread_cond_timedwait): Define using glwthread_cond_timedwait.
42711         (glthread_cond_signal): Define using glwthread_cond_signal.
42712         (glthread_cond_broadcast): Define using glwthread_cond_broadcast.
42713         (glthread_cond_destroy): Define using glwthread_cond_destroy.
42714         (glthread_cond_init_func, glthread_cond_wait_func,
42715         glthread_cond_timedwait_func, glthread_cond_signal_func,
42716         glthread_cond_broadcast_func, glthread_cond_destroy_func): Remove
42717         declarations.
42718         * lib/glthread/cond.c (gl_waitqueue_t, gl_waitqueue_element): Remove
42719         types.
42720         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_remove,
42721         gl_waitqueue_notify_first, gl_waitqueue_notify_all,
42722         glthread_cond_init_func, glthread_cond_wait_func,
42723         glthread_cond_timedwait_func, glthread_cond_signal_func,
42724         glthread_cond_broadcast_func, glthread_cond_destroy_func): Remove
42725         functions.
42726         * modules/windows-cond: New file.
42727         * modules/cond (Depends-on): Add windows-cond. Remove gettimeofday.
42729 2019-06-20  Bruno Haible  <bruno@clisp.org>
42731         windows-timedrecmutex: New module.
42732         * lib/windows-timedrecmutex.h: New file, based on windows-recmutex.h.
42733         * lib/windows-timedrecmutex.c: New file, based on windows-recmutex.c.
42734         * modules/windows-timedrecmutex: New file.
42736 2019-06-20  Bruno Haible  <bruno@clisp.org>
42738         windows-timedmutex: New module.
42739         * lib/windows-timedmutex.h: New file, based on windows-mutex.h.
42740         * lib/windows-timedmutex.c: New file, based on windows-mutex.c.
42741         * modules/windows-timedmutex: New file.
42743 2019-06-20  Bruno Haible  <bruno@clisp.org>
42745         windows-recmutex: New module.
42746         * lib/windows-recmutex.h: New file, extracted from lib/glthread/lock.h.
42747         * lib/windows-recmutex.c: New file, extracted from lib/glthread/lock.c.
42748         * lib/glthread/lock.h: Include windows-recmutex.h.
42749         (gl_recursive_lock_t): Define using glwthread_recmutex_t.
42750         (gl_recursive_lock_initializer): Define using GLWTHREAD_RECMUTEX_INIT.
42751         (glthread_recursive_lock_init): Define using glwthread_recmutex_init.
42752         (glthread_recursive_lock_lock): Define using glwthread_recmutex_lock.
42753         (glthread_recursive_lock_unlock): Define using
42754         glwthread_recmutex_unlock.
42755         (glthread_recursive_lock_destroy): Define using
42756         glwthread_recmutex_destroy.
42757         (glthread_recursive_lock_init_func, glthread_recursive_lock_lock_func,
42758         glthread_recursive_lock_unlock_func,
42759         glthread_recursive_lock_destroy_func): Remove declarations.
42760         * lib/glthread/lock.c (glthread_recursive_lock_init_func,
42761         glthread_recursive_lock_lock_func, glthread_recursive_lock_unlock_func,
42762         glthread_recursive_lock_destroy_func): Remove functions.
42763         * modules/windows-recmutex: New file.
42764         * modules/lock (Depends-on): Add windows-recmutex.
42766 2019-06-20  Bruno Haible  <bruno@clisp.org>
42768         windows-mutex: New module.
42769         * lib/windows-mutex.h: New file, extracted from lib/glthread/lock.h.
42770         * lib/windows-mutex.c: New file, extracted from lib/glthread/lock.c.
42771         * lib/windows-spinlock.h: New file, extracted from lib/glthread/lock.h.
42772         * lib/glthread/lock.h: Include windows-spinlock.h, windows-mutex.h.
42773         (gl_spinlock_t): Remove type.
42774         (gl_lock_t): Define using glwthread_mutex_t.
42775         (gl_lock_initializer): Define using GLWTHREAD_MUTEX_INIT.
42776         (glthread_lock_init): Define using glwthread_mutex_init.
42777         (glthread_lock_lock): Define using glwthread_mutex_lock.
42778         (glthread_lock_unlock): Define using glwthread_mutex_unlock.
42779         (glthread_lock_destroy): Define using glwthread_mutex_destroy.
42780         (glthread_lock_init_func, glthread_lock_lock_func,
42781         glthread_lock_unlock_func, glthread_lock_destroy_func): Remove
42782         declarations.
42783         Use glwthread_spinlock_t instead of gl_spinlock_t.
42784         (gl_rwlock_initializer, gl_recursive_lock_initializer): Define using
42785         GLWTHREAD_SPINLOCK_INIT.
42786         * lib/glthread/lock.c (glthread_lock_init_func, glthread_lock_lock_func,
42787         glthread_lock_unlock_func, glthread_lock_destroy_func): Remove
42788         functions.
42789         * lib/glthread/cond.h: Use glwthread_spinlock_t instead of
42790         gl_spinlock_t.
42791         * modules/windows-mutex: New file.
42792         * modules/lock (Depends-on): Add windows-mutex.
42794 2019-06-20  Bruno Haible  <bruno@clisp.org>
42796         windows-once: New module.
42797         * lib/windows-once.h: New file, extracted from lib/glthread/lock.h.
42798         * lib/windows-once.c: New file, extracted from lib/glthread/lock.c.
42799         * lib/glthread/lock.h: Include windows-once.h.
42800         (gl_once_t): Define using glwthread_once_t.
42801         (gl_once_define): Define using GLWTHREAD_ONCE_INIT.
42802         (glthread_once): Define using glwthread_once.
42803         (glthread_once_func): Remove declaration.
42804         * lib/glthread/lock.c (glthread_once_func): Remove function.
42805         * modules/windows-once: New file.
42806         * modules/lock (Depends-on): Add windows-once.
42808 2019-06-20  Bruno Haible  <bruno@clisp.org>
42810         lock, cond: Avoid possible counter wraparound on Windows.
42811         * lib/glthread/lock.c (glthread_lock_lock_func): Leave the 'started'
42812         field of the guard unchanged if it was already positive.
42813         (glthread_rwlock_rdlock_func): Likewise.
42814         (glthread_rwlock_wrlock_func): Likewise.
42815         (glthread_recursive_lock_lock_func): Likewise.
42816         * lib/glthread/cond.c (glthread_cond_wait_func): Likewise.
42817         (glthread_cond_timedwait_func): Likewise.
42819 2019-06-20  Bruno Haible  <bruno@clisp.org>
42821         cond: Make glthread_cond_timedwait more reliable on Windows.
42822         * lib/glthread/cond.c (glthread_cond_timedwait_func): Initialize the
42823         condition variable before looking at the current time.
42825 2019-06-20  Bruno Haible  <bruno@clisp.org>
42827         pthread_mutex_timedlock: New module.
42828         * lib/pthread.in.h (pthread_mutex_timedlock): New dummy function and
42829         new declaration.
42830         * lib/pthread_mutex_timedlock.c: New file.
42831         * m4/pthread_mutex_timedlock.m4: New file.
42832         * m4/pthread.m4 (gl_PTHREAD_CHECK): Don't call AC_LIBOBJ here. Test
42833         whether pthread_mutex_timedlock is declared.
42834         (gl_PTHREAD_MODULE_INDICATOR): New macro.
42835         (gl_PTHREAD_DEFAULTS): Initialize GNULIB_PTHREAD_MUTEX_TIMEDLOCK,
42836         HAVE_PTHREAD_MUTEX_TIMEDLOCK.
42837         * modules/pthread (configure.ac): Call AC_LIBOBJ here.
42838         (Makefile.am): Substitute GNULIB_PTHREAD_MUTEX_TIMEDLOCK,
42839         HAVE_PTHREAD_MUTEX_TIMEDLOCK.
42840         * modules/pthread_mutex_timedlock: New file.
42841         * doc/posix-functions/pthread_mutex_timedlock.texi: Mention the new
42842         module.
42844 2019-06-20  Bruno Haible  <bruno@clisp.org>
42846         thread, lock, cond, tls: Recognize C11 multithreaded applications.
42847         * m4/threadlib.m4 (gl_THREADLIB_BODY): Test for <threads.h>.
42848         * lib/glthread/thread.h (c11_threads_in_use): New macro.
42849         (pthread_in_use, pth_in_use, thread_in_use): Use it.
42850         * lib/glthread/lock.h (c11_threads_in_use): New macro.
42851         (pthread_in_use, pth_in_use, thread_in_use): Use it.
42852         * lib/glthread/cond.h (c11_threads_in_use): New macro.
42853         (pthread_in_use, pth_in_use, thread_in_use): Use it.
42854         * lib/glthread/tls.h (c11_threads_in_use): New macro.
42855         (pthread_in_use, pth_in_use, thread_in_use): Use it.
42857 2019-06-20  Bruno Haible  <bruno@clisp.org>
42859         tls tests: Small improvements.
42860         * tests/test-tls.c: Include <stdint.h>.
42861         (worker_thread): Avoid gcc warning on 64-bit mingw.
42862         (test_tls): Pass a different id to each thread.
42863         * modules/tls-tests (Depends-on): Add stdint.
42865 2019-06-20  Bruno Haible  <bruno@clisp.org>
42867         cond tests: Simplify.
42868         * tests/test-cond.c (test_timedcond): Remove redundant assignment.
42870 2019-06-20  Bruno Haible  <bruno@clisp.org>
42872         lock tests: Avoid reference to undefined variable if !ENABLE_LOCKING.
42873         * tests/test-lock.c (test_once): Don't reference fire_signal if
42874         !ENABLE_LOCKING.
42876 2019-06-19  Bruno Haible  <bruno@clisp.org>
42878         nanosleep: Relicense under LGPLv2+.
42879         Approved by Jim Meyering, Paul Eggert, Eric Blake, Pádraig Brady.
42880         * modules/nanosleep (License): Change to LGPLv2+.
42882 2019-06-19  Bruno Haible  <bruno@clisp.org>
42884         Reorder pieces of header in perl scripts.
42885         The desired order is
42886         - Prologue part 1 (2 lines with #!)
42887         - Program short description
42888         - Copyright and license notice
42889         - Written-by notice
42890         - Program short description (optional)
42891         - Program long description (optional)
42892         - Prologue part 2
42893         - Time stamp
42894         - Code
42895         Reported by Paul Eggert.
42896         * build-aux/announce-gen: Reorder header.
42897         * build-aux/gitlog-to-changelog: Likewise.
42898         * build-aux/useless-if-before-free: Likewise.
42899         * build-aux/prefix-gnulib-mk: Add copyright notice and short
42900         description.
42901         * build-aux/update-copyright: Likewise. Add short description. Bump
42902         time-stamp-line-limit to 200.
42904 2019-06-18  Paul Eggert  <eggert@cs.ucla.edu>
42906         verify-tests: work around xlc bug
42907         Problem reported by Bruno Haible in:
42908         https://lists.gnu.org/r/bug-gnulib/2019-06/msg00049.html
42909         * tests/test-verify.c (item): Move the arithmetic inside the
42910         verify_expr, to avoid tickling a bug in IBM AIX xlc V12.1.
42912 2019-06-16  Bruno Haible  <bruno@clisp.org>
42914         Restore Emacs time-stamp hook applicability.
42915         Reported by Darshit Shah <darnir@gnu.org>.
42916         * build-aux/useless-if-before-free: Bump time-stamp-line-limit to 50.
42917         * build-aux/announce-gen: Likewise.
42918         * build-aux/gitlog-to-changelog: Likewise.
42919         * build-aux/prefix-gnulib-mk: Likewise.
42920         * build-aux/update-copyright: Likewise.
42922 2019-06-15  Bruno Haible  <bruno@clisp.org>
42924         Fix scripts to have valid executable format on Alpine Linux.
42925         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
42926         Idea by Paul Eggert.
42927         * build-aux/useless-if-before-free: Use a prologue that starts with
42928         '#!/bin/sh'.
42929         * build-aux/announce-gen: Likewise.
42930         * build-aux/gitlog-to-changelog: Likewise.
42931         * build-aux/prefix-gnulib-mk: Likewise.
42932         * build-aux/update-copyright: Likewise.
42933         * tests/test-update-copyright.sh: Update test program accordingly.
42935 2019-06-10  Bruno Haible  <bruno@clisp.org>
42937         nproc: Ensure nproc(NPROC_ALL) ≥ nproc(NPROC_CURRENT) with glibc ≥ 2.26.
42938         Reported by Nikita Ermakov <arei@altlinux.org> in
42939         <https://lists.gnu.org/archive/html/bug-gnulib/2019-06/msg00003.html>.
42940         * lib/nproc.c (num_processors_ignoring_omp): Treat a return value of
42941         sysconf (_SC_NPROCESSORS_CONF) == 2 like a return value == 1.
42943 2019-06-10  Bruno Haible  <bruno@clisp.org>
42945         posix_spawn_file_actions_addchdir: Fix possible use-after-free bug.
42946         * lib/spawn_int.h (struct __spawn_action): Remove 'const' from path.
42947         * lib/spawn_faction_addchdir.c (posix_spawn_file_actions_addchdir): Make
42948         a copy of the path argument.
42949         * lib/spawn_faction_destroy.c (posix_spawn_file_actions_destroy): Free
42950         it.
42952 2019-06-10  Bruno Haible  <bruno@clisp.org>
42954         posix_spawn_file_actions_addopen: Fix possible use-after-free bug.
42955         Reported at <https://sourceware.org/bugzilla/show_bug.cgi?id=17048>.
42956         * lib/spawn_int.h (struct __spawn_action): Remove 'const' from path.
42957         * lib/spawn_faction_addopen.c (posix_spawn_file_actions_addopen): Make
42958         a copy of the path argument.
42959         * lib/spawn_faction_destroy.c (posix_spawn_file_actions_destroy): Free
42960         it.
42962 2019-06-10  Bruno Haible  <bruno@clisp.org>
42964         posix_spawn_file_actions_addfchdir: Add tests.
42965         * tests/test-posix_spawn_file_actions_addfchdir.c: New file.
42966         * tests/test-posix_spawn5.c: New file.
42967         * modules/posix_spawn_file_actions_addfchdir-tests: New file.
42969 2019-06-10  Bruno Haible  <bruno@clisp.org>
42971         posix_spawn_file_actions_addfchdir: New module.
42972         * lib/spawn.in.h (posix_spawn_file_actions_addfchdir): New declaration.
42973         * lib/spawn_int.h (struct __spawn_action): Add tag 'spawn_do_fchdir' and
42974         union member 'fchdir_action'.
42975         * lib/spawn_faction_addfchdir.c: New file.
42976         * lib/spawni.c (__spawni): Implement the spawn_do_fchdir action.
42977         * m4/posix_spawn_faction_addfchdir.m4: New file.
42978         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test whether module
42979         'posix_spawn_file_actions_addfchdir' is present and whether
42980         posix_spawn_file_actions_addfchdir_np exists. Set REPLACE_POSIX_SPAWN.
42981         * m4/spawn_h.m4 (gl_SPAWN_H): Test whether
42982         posix_spawn_file_actions_addfchdir is declared.
42983         (gl_SPAWN_H_DEFAULTS): Initialize
42984         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
42985         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
42986         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR.
42987         * modules/spawn (Makefile.am): Substitute
42988         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
42989         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR,
42990         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR.
42991         * modules/posix_spawn_file_actions_addfchdir: New file.
42992         * tests/test-spawn-c++.cc (posix_spawn_file_actions_addfchdir): Check
42993         signature.
42994         * doc/posix-functions/posix_spawn.texi: Mention the new module.
42995         * doc/posix-functions/posix_spawnp.texi: Likewise.
42996         * doc/glibc-functions/posix_spawn_file_actions_addfchdir_np.texi:
42997         Likewise.
42999 2019-06-10  Bruno Haible  <bruno@clisp.org>
43001         doc: Document existence of posix_spawn_file_actions_addchdir module.
43002         * doc/glibc-functions/posix_spawn_file_actions_addchdir_np.texi: Mention
43003         the posix_spawn_file_actions_addchdir module.
43005 2019-06-10  Bruno Haible  <bruno@clisp.org>
43007         posix_spawn-internal: Fix module description.
43008         * modules/posix_spawn (configure.ac): Move request to compile spawni.c
43009         from here...
43010         * modules/posix_spawnp (configure.ac): ... and here...
43011         * modules/posix_spawn-internal (configure.ac): ... to here.
43013 2019-06-10  Bruno Haible  <bruno@clisp.org>
43015         doc: Update and improve documentation of glibc functions.
43016         This is a series of commits that
43017         - updates the documentation to the state of glibc 2.29,
43018         - adds references to Linux man pages and glibc documentation,
43019         - marks Linux specific functions as such.
43020         These are the commits:
43021         doc: Update after removal of crypt functions from glibc 2.28.
43022         doc: Remove mention of function vm86 (does not exist on x86_64).
43023         doc: Remove mention of functions that are gone from glibc.
43024         doc: Mention that glibc no longer provides h_errno.
43025         doc: Mention the availability of specific functions in glibc versions.
43026         doc: Mention eaccess.
43027         doc: Add references to Linux man pages.
43028         doc: Add references to glibc documentation.
43029         doc: Mention inotify_* functions.
43030         doc: Mention ppoll.
43031         doc: Mention sched_getcpu.
43032         doc: Mention sync_file_range.
43033         doc: Mention epoll_pwait.
43034         doc: Mention eventfd, eventfd_read, eventfd_write.
43035         doc: Mention signalfd.
43036         doc: Mention timerfd_create, timerfd_gettime, timerfd_settime.
43037         doc: Mention epoll_create1.
43038         doc: Mention getauxval.
43039         doc: Mention pthread_getattr_default_np, pthread_setattr_default_np.
43040         doc: Mention nextdown, nextup.
43041         doc: Mention more ISO TS 18661-1 <math.h> functions.
43042         doc: Mention ISO TS 18661-1 <fenv.h> functions.
43043         doc: Mention getrandom, getentropy.
43044         doc: Mention strfromf, strfromd, strfroml.
43045         doc: Mention preadv2, pwritev2.
43046         doc: Mention copy_file_range.
43047         doc: Mention memfd_create.
43048         doc: Mention mlock2.
43049         doc: Mention pkey_alloc, pkey_set, pkey_get, pkey_free, pkey_mprotect.
43050         doc: Mention more ISO TS 18661-1 <math.h> functions.
43051         doc: Mention renameat2.
43052         doc: Mention statx.
43053         doc: Mention the ISO C11 multithreading header and functions.
43054         doc: Mention getcpu.
43055         doc: Mention posix_spawn_file_actions_add[f]chdir_np.
43056         doc: Some glibc functions also exist on IRIX 6.5 in 32-bit mode.
43057         doc: Some glibc functions also exist on FreeBSD, AIX, HP-UX, Solaris 11.
43058         doc: Some glibc functions also exist on FreeBSD, Solaris 11.
43059         doc: Some glibc functions also exist on Solaris 11.
43060         doc: Some glibc functions also exist on Solaris 11.4.
43061         doc: Some glibc functions also exist on FreeBSD.
43062         doc: Some glibc functions also exist on BeOS.
43063         doc: Some glibc functions also exist on Haiku.
43064         doc: Mark functions which exist only on Linux.
43065         doc: Mark functions which exist only on Linux and illumos.
43067 2019-06-06  Paul Eggert  <eggert@cs.ucla.edu>
43069         copy-file: fix typo
43070         * lib/copy-file.c (qcopy_file_preserving): Remove unused label.
43072         copy-file-range: simplify into a stub
43073         Based on a comment by Florian Weimer in:
43074         https://lists.gnu.org/r/bug-gnulib/2019-06/msg00007.html
43075         It turns out that Emacs (which will use this module) won’t need an
43076         emulation and I suspect other programs won’t either, because these
43077         programs will need to fall back on read+write anyway.  Perhaps I
43078         am wrong and other programs will be able to use an emulation; if
43079         so, this patch can be reverted.
43080         * lib/copy-file-range.c (COPY_FILE_RANGE): Replace with a stub.
43081         Just call it copy_file_range.
43082         * m4/copy-file-range.m4 (gl_FUNC_COPY_FILE_RANGE):
43083         Check via AC_LINK_IFELSE.
43084         * modules/copy-file-range (Depends-on): Remove modules no longer used.
43086 2019-06-04  Paul Eggert  <eggert@cs.ucla.edu>
43088         copy-file: prefer copy_file_range
43089         * lib/copy-file.c: Do not include xalloc.h.
43090         (qcopy_file_preserving): Allocate a buffer only if
43091         copy_file_range does not suffice.  If the allocation fails
43092         don't give up; just use a small stack-based buffer.
43093         Prefer copy_file_range if it works.
43094         * modules/copy-file (Depends-on): Add copy-file-range.
43095         Remove xalloc.
43097         copy-file-range: new module
43098         * MODULES.html.sh: Add copy-file-range.
43099         * lib/copy-file-range.c, m4/copy-file-range.m4:
43100         * modules/copy-file-range: New files.
43101         * lib/unistd.in.h (copy_file_range): Declare.
43102         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS):
43103         Set up GNULIB_COPY_FILE_RANGE and HAVE_COPY_FILE_RANGE.
43104         * modules/unistd (unistd.h): Substitute them.
43106 2019-05-28  Bruno Haible  <bruno@clisp.org>
43108         binary-io: Attempted use of O_BINARY on consoles no longer fails.
43109         Reported by KO Myung-Hun <komh78@gmail.com> in
43110         <https://lists.gnu.org/archive/html/bug-gnulib/2019-05/msg00124.html>.
43111         * lib/binary-io.h (__gl_setmode_check): Remove function.
43112         (set_binary_mode): Declare as notinline on DJGPP and EMX.
43113         * lib/binary-io.c (__gl_setmode_check): Remove function.
43114         (set_binary_mode): Define here on DJGPP and EMX. Inline
43115         __gl_setmode_check. In case of a tty, don't return an error code.
43117 2019-05-28  James Youngman  <jay@gnu.org>
43119         dirent-safer: Make opendir_safer usable from C++.
43120         * lib/dirent-safer.h: use extern "C".
43122 2019-05-28  James Youngman  <jay@gnu.org>
43124         canonicalize: Make canonicalize_filename_mode usable from C++.
43125         * lib/canonicalize.h: use extern "C".
43127 2019-05-26  Akim Demaille  <akim@lrde.epita.fr>
43129         prefix-gnulib-mk: Fix CPPFLAGS migration.
43130         * build-aux/prefix-gnulib-mk (prefix_assignment): Don't forget the
43131         _a part of the library name.
43133 2019-05-24  Paul Eggert  <eggert@cs.ucla.edu>
43135         flexmember: update comments again
43136         * lib/flexmember.h, m4/flexmember.m4: Improve comments further.
43138         flexmember: update comment
43139         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER): Improve comment.
43141 2019-05-20  Bruno Haible  <bruno@clisp.org>
43143         setlocale: Improve fallback on macOS.
43144         * lib/setlocale.c (search): Optimize away a redundant strcmp()
43145         invocation.
43146         (locales_with_principal_territory): New array.
43147         (langcmp, get_main_locale_with_same_language): New functions.
43148         (locales_with_principal_language): New array.
43149         (terrcmp, get_main_locale_with_same_territory): New functions.
43150         (rpl_setlocale): When setlocale_single failed, try again with a locale
43151         that is more likely to exist. Don't warn if the environment variable
43152         SETLOCALE_VERBOSE is not set.
43154 2019-05-19  Bruno Haible  <bruno@clisp.org>
43156         localename: Fix default on macOS.
43157         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Don't test for CFLocaleCopyCurrent.
43158         * lib/localename.c: Remove includes for HAVE_CFLOCALECOPYCURRENT.
43159         (gl_locale_name_environ, gl_locale_name_default): Remove code for
43160         HAVE_CFLOCALECOPYCURRENT.
43161         * lib/localename.h (gl_locale_name_default): Update.
43163 2019-05-19  Karl Berry  <karl@freefriends.org>
43165         * config/srclistvars.sh (TEXINFOTEX): make ftp.gnu.org be the
43166         source for texinfo.tex, replacing TEXINFOSRC, per Texinfo maintainer.
43167         * config/srclist.txt (texinfo.tex): use it. (Also doc changes.)
43169 2019-05-18  Akim Demaille  <akim@lrde.epita.fr>
43171         maintainer-makefile: catch uses of $< in non-implicit rules
43172         * top/maint.mk (sc_prohibit_magic_number_exit): New.
43174 2019-05-18  Bruno Haible  <bruno@clisp.org>
43176         threadlib: Provide an easy way to avoid mingw's winpthreads library.
43177         * m4/threadlib.m4 (gl_AVOID_WINPTHREAD): New macro.
43178         (gl_THREADLIB_EARLY_BODY): Recognize when it was invoked, and set
43179         gl_use_threads accordingly.
43181 2019-05-18  Bruno Haible  <bruno@clisp.org>
43183         pthread_sigmask: Fix compilation error with --enable-threads=windows.
43184         Reported by Tim Rühsen in
43185         <https://lists.gnu.org/archive/html/bug-gnulib/2018-01/msg00018.html>
43186         and Michele Locati in
43187         <https://lists.gnu.org/archive/html/bug-gettext/2019-04/msg00057.html>.
43188         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Revert change from
43189         2015-06-01. Test whether pthread_sigmask is a macro, regardless of
43190         $LIBMULTITHREAD. Consider it regardless whether module 'threadlib' is
43191         in use and regardless which threads API is chosen.
43193 2019-05-14  Paul Eggert  <eggert@cs.ucla.edu>
43195         close-stream, closein, closeout: simplify
43196         I noticed this opportunity for simplification while drafting a
43197         new, related module that I haven’t had time to finish yet.
43198         * m4/close-stream.m4, m4/closein.m4, m4/closeout.m4: Remove.
43199         * modules/close-stream (Files): Remove m4/close-stream.m4.
43200         (configure.ac): Omit gl_CLOSE_STREAM.
43201         * modules/closein (Files): Remove m4/closein.m4
43202         (configure.ac): Omit gl_CLOSEIN.
43203         * modules/closeout (Files): Remove m4/closeout.m4.
43204         (configure.ac): Omit gl_CLOSEOUT.
43206 2019-05-12  Bruno Haible  <bruno@clisp.org>
43208         libtool-next-version: New program.
43209         * build-aux/libtool-next-version: New file.
43211 2019-05-11  John Darrington  <john@darrington.wattle.id.au>
43212             Bruno Haible  <bruno@clisp.org>
43214         version-etc: Ease translation.
43215         * lib/version-etc.c (version_etc_arn, emit_bug_reporting_address): Move
43216         URLs and formatting newlines out of translatable string.
43218 2019-05-11  Bruno Haible  <bruno@clisp.org>
43220         gnupload: Explain how to create symlinks.
43221         * build-aux/gnupload (usage): Add an example that creates symlinks.
43223 2019-05-11  Paul Eggert  <eggert@cs.ucla.edu>
43225         fpucw: port to gcc -pedantic
43226         * lib/fpucw.h (GET_FPUCW, SET_FPUCW):
43227         Use __extension__ if using ({ ... }).
43229         crypto/af_alg: port to strict C compilers
43230         * lib/af_alg.c: Include af_alg.h regardless, so that the
43231         compilation unit is nonempty.
43233 2019-05-10  Bruno Haible  <bruno@clisp.org>
43235         base64: Avoid false positive warning from Coverity.
43236         Reported by Kamil Dudka <kdudka@redhat.com>.
43237         Idea by Paul Eggert.
43238         * lib/base64.c (base64_encode_fast, base64_encode): Add a no-op
43239         '& 0x3f' to the array index expressions. This convinces Coverity that
43240         there is no out-of-bounds array reference, regardless of the input.
43242 2019-05-09  Bruno Haible  <bruno@clisp.org>
43244         gettext: Update to gettext 0.20.
43245         * modules/gettext (Files): Remove m4/codeset.m4, m4/fcntl-o.m4,
43246         m4/glibc2.m4, m4/glibc21.m4, m4/intdiv0.m4, m4/intl.m4, m4/intldir.m4,
43247         m4/intmax.m4, m4/inttypes_h.m4, m4/inttypes-pri.m4, m4/lcmessage.m4,
43248         m4/lock.m4, m4/longlong.m4, m4/printf-posix.m4, m4/size_max.m4,
43249         m4/stdint_h.m4, m4/threadlib.m4, m4/uintmax_t.m4, m4/visibility.m4,
43250         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4. Add m4/host-cpu-c-abi.m4.
43251         (configure.ac): Request infrastructure compatible with gettext 0.20.
43252         * m4/glibc2.m4: Remove file.
43253         * m4/intdiv0.m4: Remove file.
43254         * m4/intl.m4: Remove file.
43255         * m4/intldir.m4: Remove file.
43256         * m4/intmax.m4: Remove file.
43257         * m4/printf-posix.m4: Remove file.
43258         * m4/uintmax_t.m4: Remove file.
43259         * m4/gettext.m4: Update from gettext 0.20.
43260         * m4/po.m4: Likewise.
43262 2019-05-09  Paul Eggert  <eggert@cs.ucla.edu>
43264         verify: remove verify_true
43265         * NEWS: Mention this.
43266         * lib/verify.h (verify_true): Remove.
43267         * tests/test-verify.c (item): Test verify_expr, not verify_true.
43269         Support C2x and C++17 static_assert
43270         C2x and C++17 finally added support for a simple, single-argument
43271         ‘static_assert’ that implements what the Gnulib ‘verify’ macro was
43272         doing back in 2005.  Implement static_assert on older platforms.
43273         The only remaining advantage of ‘verify’ is a shorter name.
43274         * doc/posix-headers/assert.texi (assert.h):
43275         * doc/verify.texi (Compile-time Assertions):
43276         Modernize for C2x and C++17.
43277         * lib/verify.h (_GL_HAVE__STATIC_ASSERT1, _GL_HAVE_STATIC_ASSERT1):
43278         New macros.
43279         (_GL_HAVE__STATIC_ASSERT): Remove.
43280         (_GL_HAVE__STATIC_ASSERT): Rely more heavily on __STDC_VERSION__.
43281         (_GL_VERIFY_TRUE, _GL_VERIFY_TYPE): Remove 2nd arg, the diagnostic
43282         string.  All callers changed.
43283         (_GL_VERIFY): Require 3 or more args, of which only the first 2
43284         are used.  All callers changed.
43285         (_Static_assert): Allow either 1 or 2 args, and define if
43286         !_GL_HAVE__STATIC_ASSERT1 instead of defining if
43287         !_GL_HAVE__STATIC_ASSERT.
43288         (static_assert): Define if !_GL_HAVE_STATIC_ASSERT1 instead
43289         of defining if !_GL_HAVE_STATIC_ASSERT.
43290         (verify_expr, verify): Don’t bother trying to copy the expression
43291         into the diagnostic, since 1-argument static_assert doesn’t.
43292         (verify): Prefer 1-argument _Static_assert if it works.
43293         * m4/assert_h.m4 (gl_ASSERT_H): Check for 1-argument static_assert.
43295 2019-05-08  Paul Eggert  <eggert@cs.ucla.edu>
43297         Fix _GL_HAVE__STATIC_ASSERT typo
43298         * lib/verify.h (_Static_assert): For the FreeBSD workaround,
43299         use _GL_HAVE__STATIC_ASSERT, not _GL_HAVE_STATIC_ASSERT.
43301 2019-05-05  Bruno Haible  <bruno@clisp.org>
43303         wcwidth: Ensure width 1, not 2, for ambiguous characters.
43304         Reported by Kiyoshi KANAZAWA <yoi_no_myoujou@yahoo.co.jp>
43305         via Akim Demaille <akim.demaille@gmail.com>.
43306         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check the width of U+2202. Use an
43307         en_US.UTF-8 locale, since that is more likely to be present than an
43308         fr_FR.UTF-8 locale.
43309         * tests/test-wcwidth.c (main): Check the width of U+2202.
43310         * doc/posix-functions/wcwidth.texi: Mention the issue.
43312 2019-05-03  Paul Eggert  <eggert@cs.ucla.edu>
43314         Port manywarnings to GCC 9
43315         * build-aux/gcc-warning.spec: Sort.  Add -Wattribute-alias,
43316         -Wc11-c2x-compat, -Wcast-result (for the D programming language),
43317         -Wclass-conversion, -Wdeprecated-copy, -Wdeprecated-copy-dtor,
43318         -Winit-list-lifetime, -Wpessimizing-move, -Wprio-ctor-dtor,
43319         -Wredundant-move.  Adjust to minor wording changes in GCC 9’s
43320         --help=warnings output.
43321         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wabsolute-value,
43322         -Waddress-of-packed-member, -Wattribute-warning, -Wcannot-profile,
43323         -Wmissing-profile.  Change -Wattribute-alias to -Wattribute-alias=2.
43325 2019-04-30  Paul Eggert  <eggert@cs.ucla.edu>
43327         Sync lib/mktime-internal.h from glibc
43328         * config/srclist.txt: Add entry for lib/mktime-internal.h.
43329         * lib/mktime-internal.h: Autoupdate.
43331 2019-04-28  Bruno Haible  <bruno@clisp.org>
43333         tls tests: Prevent that the test takes too long.
43334         * tests/test-tls.c: Include <signal.h>, <unistd.h>.
43335         (main): Let the test fail if it takes more than 10 minutes.
43336         * modules/tls-tests (configure.ac): Test whether 'alarm' is declared.
43338 2019-04-27  Bruno Haible  <bruno@clisp.org>
43340         lock tests: Prevent that the test takes too long.
43341         * tests/test-lock.c: Include <signal.h>, <unistd.h>.
43342         (main): Let the test fail if it takes more than 10 minutes.
43343         * modules/lock-tests (configure.ac): Test whether 'alarm' is declared.
43345 2019-04-27  Bruno Haible  <bruno@clisp.org>
43347         localename: Fix crash on mingw (regression from 2018-11-23).
43348         * lib/localename.c (gl_locale_name_posix): Don't attempt to convert a
43349         locale name that is null.
43351 2019-04-27  Bruno Haible  <bruno@clisp.org>
43353         Fix gcc warnings on 64-bit mode mingw.
43354         * lib/clean-temp.c: Include <stdint.h> instead of defining uintptr_t.
43355         * lib/gl_array_list.c: Likewise.
43356         * lib/gl_array_map.c: Likewise.
43357         * lib/gl_array_set.c: Likewise.
43358         * lib/gl_carray_list.c: Likewise.
43359         * lib/gl_sublist.c: Likewise.
43360         * lib/gl_avltreehash_list.c (uintptr_t): Remove definition.
43361         * lib/gl_rbtreehash_list.c (uintptr_t): Likewise.
43362         * lib/gl_hash_map.c (uintptr_t): Likewise.
43363         * lib/gl_hash_set.c (uintptr_t): Likewise.
43364         * lib/gl_linkedhash_list.c (uintptr_t): Likewise.
43365         * lib/gl_linkedhash_map.c (uintptr_t): Likewise.
43366         * lib/gl_linkedhash_set.c (uintptr_t): Likewise.
43367         * lib/iconv.c (uintptr_t): Likewise.
43368         * lib/iconv_close.c (uintptr_t): Likewise.
43369         * tests/test-lock.c: Include <stdint.h>.
43370         (once_contender_thread, test_once): Cast through 'intptr_t' instead of
43371         'long'.
43372         * modules/clean-temp (Depends-on): Add stdint.
43373         * modules/array-list (Depends-on): Likewise.
43374         * modules/array-map (Depends-on): Likewise.
43375         * modules/array-set (Depends-on): Likewise.
43376         * modules/carray-list (Depends-on): Likewise.
43377         * modules/sublist (Depends-on): Likewise.
43378         * modules/lock-tests (Depends-on): Likewise.
43380 2019-04-27  Bruno Haible  <bruno@clisp.org>
43382         error: Tweak indentation.
43383         * lib/error.c: Correct indentation.
43385 2019-04-27  Bruno Haible  <bruno@clisp.org>
43387         term-style-control: Fix gcc warning on mingw.
43388         * lib/term-style-control.c (ensure_other_signal_handlers): Reduce scope
43389         of i.
43391 2019-04-26  Bruno Haible  <bruno@clisp.org>
43393         pipe-filter-gi, pipe-filter-ii: Fix gcc warning.
43394         * lib/pipe-filter-aux.h (read): Undefine before redefinition.
43396 2019-04-26  Bruno Haible  <bruno@clisp.org>
43398         relocatable-prog: Fix gcc warning on mingw.
43399         * lib/progreloc.c (maybe_executable): Don't define on native Windows and
43400         on EMX.
43402 2019-04-02  Bruno Haible  <bruno@clisp.org>
43404         gitsub.sh: New file.
43405         * top/gitsub.sh: New file.
43407 2019-04-18  Akim Demaille  <akim@lrde.epita.fr>
43409         argmatch: use void* for raw memory pointers
43410         * lib/argmatch.h, lib/argmatch.c (argmatch, argmatch_valid)
43411         (__xargmatch_internal, argmatch_to_argument): Use void* for pointers
43412         to "values", keep char* for strings.
43414 2019-04-21  Akim Demaille  <akim@lrde.epita.fr>
43416         prefix-gnulib-mk: fix the support for gnulib-po
43417         * build-aux/prefix-gnulib-mk (prefix_assignment): Remove useless $res.
43418         Don't touch HAVE_* variables.
43419         Map AM_CPPFLAGS and AM_CPPFLAGS to the library's corresponding variables.
43421 2019-04-18  Bernhard Voelker  <mail@bernhard-voelker.de>
43423         di-set: allow free with 'ino_map' being NULL.
43424         * lib/di-set.c (di_set_free): Avoid ino_map_free() when dis->ino_map
43425         is NULL.  Bug introduced in commit 3703dbbe88dd.
43426         * tests/test-di-set.c: Add di_set_free() right after di_set_alloc()
43427         as a test.
43429 2019-04-14  Paul Eggert  <eggert@cs.ucla.edu>
43431         * lib/str-two-way.h: Fix comment typo.
43433 2019-04-13  Bruno Haible  <bruno@clisp.org>
43435         x-to-1: Restore ability to use original calling convention.
43436         * build-aux/x-to-1.in: Add comments. Accept the original form of
43437         HELP2MAN argument as well as the form expected since 2012-12-12.
43439 2019-04-13  Bruno Haible  <bruno@clisp.org>
43441         x-to-1: Avoid failure due to missing perl modules.
43442         * build-aux/x-to-1.in: Test whether all the perl modules that help2man
43443         needs are installed.
43445 2019-04-13  Bruno Haible  <bruno@clisp.org>
43447         openmp-init: New module.
43448         * modules/openmp-init: New file.
43449         * modules/openmp: (Files, Depends-on, configure.ac, Makefile.am): Revert
43450         the changes from 2019-04-09.
43452 2019-04-12  Bruno Haible  <bruno@clisp.org>
43454         signbit: Fix compilation error when gnulib's math.h exists twice.
43455         * lib/math.in.h (GNULIB_defined_signbit): New macro.
43457 2019-04-12  Bruno Haible  <bruno@clisp.org>
43459         openmp: Fix compilation error on platforms without OpenMP.
43460         * lib/omp-init.c: Include <omp.h> only if _OPENMP.
43462 2019-04-09  Bernhard Voelker  <mail@bernhard-voelker.de>
43464         mountlist: make parsing /proc/self/mountinfo more robust
43465         Cater for the following issues with mountinfo parsing (the first
43466         one was reported by Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
43467         in <https://bugs.gnu.org/35137>).
43468         1. The fields source, target, mntroot and fstype may contain characters
43469         like '\r'; sscanf(3) fails to read such values with the %s format
43470         specifier because it would stop at such characters.
43471         Example: "mount -t tmpfs tmpfs /foo^Mbar".
43472         The only true separator in that file is the ' ' character.
43473         2. The source field may be an empty string, which happens e.g. with
43474         "mount -t tmpfs '' /target".
43475         3. The fstype field may contain mangled characters as well which need
43476         unescaping.
43477         * lib/mountlist.c (terminate_at_blank): Add utility function.
43478         (read_file_system_list): In the block trying to read the mountinfo file,
43479         avoid using sscanf(3) with %s format; instead, parse the above fields
43480         separated by spaces one by one.
43481         This also handles the case when the source field is an empty string.
43482         Unescape the fstype field.
43484 2019-04-09  Bruno Haible  <bruno@clisp.org>
43486         openmp: Add workaround for 32-bit programs on AIX.
43487         * lib/omp.in.h: New file.
43488         * lib/omp-init.c: New file, based on lib/nproc.c.
43489         * m4/omp_h.m4: New file.
43490         * modules/openmp (Files): Add them.
43491         (Depends-on): Add include_next, c-ctype, setenv.
43492         (configure.ac): Invoke gl_OMP_H.
43493         (Makefile.am): Add rules to create omp.h and compile omp-init.c.
43494         (Include): Mention <omp.h>.
43496 2019-04-09  Bruno Haible  <bruno@clisp.org>
43498         nproc: Fix return value for privileged processes.
43499         * lib/nproc.c (num_processors_ignoring_omp): Test getuid(), not
43500         getpid().
43502 2019-04-07  Bruno Haible  <bruno@clisp.org>
43504         Add copyright notices in several files.
43505         Reported by <ineiev@gnu.org> in <https://savannah.gnu.org/bugs/?54809>.
43506         * lib/_Noreturn.h: Add LGPLv2+ copyright notice.
43507         * lib/libunistring.valgrind: Likewise.
43508         * lib/iconv_open-*.gperf: Add GPLv2+ copyright notice.
43509         * lib/uniname/gen-uninames.lisp: Add GPLv3+ copyright notice.
43510         * lib/memchr.valgrind: Likewise.
43511         * lib/memchr2.valgrind: Likewise.
43512         * lib/rawmemchr.valgrind: Likewise.
43513         * lib/relocatable.valgrind: Likewise.
43514         * lib/strchrnul.valgrind: Likewise.
43516 2019-03-25  Bruno Haible  <bruno@clisp.org>
43518         term-style-control tests: Fix link error.
43519         Reported by Tom G. Christensen in
43520         <https://lists.gnu.org/archive/html/bug-gnulib/2019-03/msg00108.html>.
43521         * modules/term-style-control-tests (Makefile.am): Link
43522         test-term-style-control-hello and test-term-style-control-yes against
43523         LIBINTL.
43525 2019-03-24  Bruno Haible  <bruno@clisp.org>
43527         term-style-control: Add tests.
43528         * tests/test-term-style-control-hello.c: New file.
43529         * tests/test-term-style-control-yes.c: New file.
43530         * modules/term-style-control-tests: New file.
43532         term-style-control: New module.
43533         * lib/term-style-control.h: New file, based on libtextstyle's
43534         term-ostream.oo.h and term-ostream.oo.c.
43535         * lib/term-style-control.c: New file, based on libtextstyle's
43536         term-ostream.oo.c.
43537         * modules/term-style-control: New file.
43539 2019-03-22  Akim Demaille  <akim@lrde.epita.fr>
43541         _Noreturn: beware of C's _Noreturn in C++ pre C++11.
43542         * lib/_Noreturn.h, m4/gnulib-common.m4: Using C's _Noreturn in
43543         C++98 appears to be supported by Clang, but not by GCC nor ICC.
43545 2019-03-23  Bruno Haible  <bruno@clisp.org>
43547         Support cross-compilation to musl libc.
43548         Reported by Necktwi Ozfguah <necktwi@ferryfair.com>.
43549         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Add cross-compilation guesses for
43550         musl libc.
43551         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Likewise.
43552         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Likewise.
43553         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
43554         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
43555         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
43556         * m4/chown.m4 (gl_FUNC_CHOWN): Likewise.
43557         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
43558         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
43559         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
43560         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
43561         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Likewise.
43562         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Likewise.
43563         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
43564         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
43565         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
43566         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
43567         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
43568         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
43569         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
43570         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
43571         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
43572         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
43573         * m4/getgroups.m4 (AC_FUNC_GETGROUPS, gl_FUNC_GETGROUPS): Likewise.
43574         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
43575         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Likewise.
43576         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
43577         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
43578         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
43579         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): Likewise.
43580         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Likewise.
43581         * m4/log.m4 (gl_FUNC_LOG): Likewise.
43582         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
43583         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
43584         * m4/log10.m4 (gl_FUNC_LOG10): Likewise.
43585         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
43586         * m4/log10l.m4 (gl_FUNC_LOG10L): Likewise.
43587         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
43588         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Likewise.
43589         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Likewise.
43590         * m4/log2.m4 (gl_FUNC_LOG2): Likewise.
43591         * m4/log2f.m4 (gl_FUNC_LOG2F): Likewise.
43592         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Likewise.
43593         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
43594         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
43595         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
43596         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
43597         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
43598         * m4/perror.m4 (gl_FUNC_PERROR): Likewise.
43599         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_INFINITE,
43600         gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_A,
43601         gl_PRINTF_DIRECTIVE_F, gl_PRINTF_FLAG_ZERO, gl_SNPRINTF_TRUNCATION_C99,
43602         gl_SNPRINTF_RETVAL_C99, gl_SNPRINTF_DIRECTIVE_N,
43603         gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
43604         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Likewise.
43605         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
43606         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Likewise.
43607         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
43608         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
43609         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
43610         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
43611         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
43612         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
43613         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
43614         * m4/setenv.m4 (gl_FUNC_SETENV): Likewise.
43615         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
43616         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
43617         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
43618         * m4/strerror.m4 (gl_FUNC_STRERROR, gl_FUNC_STRERROR_0): Likewise.
43619         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
43620         * m4/strtold.m4 (gl_FUNC_STRTOLD): Likewise.
43621         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
43622         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
43623         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
43624         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
43625         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
43626         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
43627         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
43628         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
43630 2019-03-23  Bruno Haible  <bruno@clisp.org>
43632         posix_spawn_file_actions_*: Document musl libc bugs.
43633         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
43634         the bug.
43635         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Likewise.
43636         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Likewise.
43637         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE): When
43638         cross-compiling to a musl system, guess no.
43639         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2): Likewise.
43640         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): Likewise.
43642 2019-03-23  Bruno Haible  <bruno@clisp.org>
43644         futimens: Document musl libc bug.
43645         * doc/posix-functions/futimens.texi: Mention the bug.
43646         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Require AC_CANONICAL_HOST. When
43647         cross-compiling, guess no on glibc and musl systems.
43649 2019-03-23  Bruno Haible  <bruno@clisp.org>
43651         Clarify that cross-compilation guesses are guesses.
43652         * m4/chown.m4 (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): When cross-compiling, add
43653         prefix 'guessing ' to gl_cv_func_chown_follows_symlink.
43654         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): When cross-compiling, add
43655         prefix 'guessing ' to gl_cv_func_fchownat_nofollow_works.
43656         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): When
43657         cross-compiling, add prefix 'guessing ' to gl_cv_func_getcwd_abort_bug.
43658         * m4/glob.m4 (gl_GLOB): When cross-compiling, add prefix 'guessing ' to
43659         gl_cv_glob_lists_symlinks.
43660         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): When cross-compiling, add prefix
43661         'guessing ' to ac_cv_func_malloc_0_nonnull.
43662         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): When cross-compiling, add prefix
43663         'guessing ' to ac_cv_func_realloc_0_nonnull.
43664         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, add prefix
43665         'guessing ' to gl_cv_func_poll.
43666         * m4/iconv_open-utf.m4 (gl_FUNC_ICONV_OPEN_UTF_SUPPORT): When cross-
43667         compiling, add prefix 'guessing ' to gl_cv_func_iconv_supports_utf.
43668         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Update accordingly.
43670 2019-03-23  Bruno Haible  <bruno@clisp.org>
43672         strtold: Fix typo.
43673         * m4/strtold.m4 (gl_FUNC_STRTOLD): Fix typo in variable name.
43675 2019-03-23  Bruno Haible  <bruno@clisp.org>
43677         noreturn: In C++ mode with clang, use _Noreturn as fallback.
43678         Reported by Akim Demaille.
43679         * lib/noreturn.h (_GL_NORETURN_FUNC): In C++ mode with clang, when
43680         [[noreturn]] would not work, use _Noreturn instead.
43682 2019-03-22  Akim Demaille  <akim@lrde.epita.fr>
43684         libtextstyle-optional: Fix compiler warnings.
43685         * lib/textstyle.in.h (html_styled_ostream_create): Flag arguments
43686         as unused.
43688 2019-03-19  Akim Demaille  <akim@lrde.epita.fr>
43690         bitset: fix memory leaks
43691         Reported by Bruno Haible.
43692         https://lists.gnu.org/archive/html/bug-gnulib/2019-03/msg00027.html
43693         * lib/bitset/vector.c (vbitset_free): New.
43694         (vbitset_vtable): Use it.
43696 2019-03-19  Akim Demaille  <akim@lrde.epita.fr>
43698         bitset: minor changes
43699         * lib/bitset/base.h (bitset_alloc_type): Remove, unused.
43700         * lib/bitset/table.c: Formatting changes.
43701         Remove useless braces.
43702         Prefer using else in cascades of if/else-if with returns.
43703         * lib/bitset/vector.c: Reduce scopes.
43705 2019-03-19  Akim Demaille  <akim@lrde.epita.fr>
43707         bitset: expose bitset_resize
43708         * lib/bitset.h (bitset_resize): Bounce on the polymorphic implementation.
43709         * tests/test-bitset.c (check_attributes): Check bitset_resize.
43710         (main): Use a variable bitset as reference, since fixed does not support resize.
43712 2019-03-19  Bruno Haible  <bruno@clisp.org>
43714         doc: Document the 'stdnoreturn' and 'noreturn' modules.
43715         Reported by Akim Demaille.
43716         * doc/noreturn.texi: New file.
43717         * doc/gnulib.texi: Include it.
43719 2019-03-19  Bruno Haible  <bruno@clisp.org>
43721         doc: Document how to use 'static inline'.
43722         * doc/static-inline.texi: New file.
43723         * doc/gnulib.texi: Include it.
43725 2019-03-19  Bruno Haible  <bruno@clisp.org>
43727         libtextstyle-optional: Add tests.
43728         * tests/test-libtextstyle.c: New file, based on libtextstyle's
43729         adhoc-tests/hello.c.
43730         * tests/test-libtextstyle-default.css: New file, copied from
43731         libtextstyle's adhoc-tests/hello-default.css.
43732         * modules/libtextstyle-optional-tests: New file.
43734         libtextstyle-optional: New module.
43735         * lib/textstyle.in.h: New file, based on libtextstyle's textstyle.h.
43736         * m4/libtextstyle-optional.m4: New file, based on m4/libtextstyle.m4.
43737         * modules/libtextstyle-optional: New file.
43739 2019-03-19  Bruno Haible  <bruno@clisp.org>
43741         c-stack: Make signal handlers more reliable.
43742         * lib/c-stack.c (progname): New variable.
43743         (die): Use it.
43744         (c_stack_action): Initialize it.
43745         (segv_handler): Save and restore errno.
43747 2019-03-19  Bruno Haible  <bruno@clisp.org>
43749         Help making signal handlers more reliable.
43750         * m4/gnulib-common.m4 (gl_COMMON_BODY): Emit definition of
43751         _GL_ASYNC_SAFE into config.h.
43752         * lib/nanosleep.c (sighandler): Mark as _GL_ASYNC_SAFE.
43753         * lib/fatal-signal.h (at_fatal_signal): Add _GL_ASYNC_SAFE marker to
43754         argument.
43755         * lib/fatal-signal.c (action_t, uninstall_handlers,
43756         fatal_signal_handler): Mark as _GL_ASYNC_SAFE.
43757         * lib/clean-temp.c (cleanup_action): Mark as _GL_ASYNC_SAFE.
43758         * lib/wait-process.c (cleanup_slaves, cleanup_slaves_action): Mark as
43759         _GL_ASYNC_SAFE.
43760         * lib/c-stack.h (c_stack_action): Add _GL_ASYNC_SAFE marker to argument.
43761         * lib/c-stack.c: Add _GL_ASYNC_SAFE markers.
43763 2019-03-18  Bruno Haible  <bruno@clisp.org>
43765         _Noreturn: clang and MSVC do support [[noreturn]] in C++11 mode.
43766         * lib/_Noreturn.h: Use [[noreturn]] if __GNUC__ and __GNUC_MINOR__
43767         indicate clang, or if _MSC_VER indicates MSVC++ 14.0 or newer.
43769 2019-03-17  Akim Demaille  <akim@lrde.epita.fr>
43771         _Noreturn: GCC 4.7 does not support [[noreturn]] in C++11 mode
43772         * lib/_Noreturn.h, m4/gnulib-common.m4: Don't use [[noreturn]] before
43773         GCC 4.8.
43775 2019-03-17  Paul Eggert  <eggert@cs.ucla.edu>
43777         fts: minor simplification
43778         * lib/fts.c (fts_safe_changedir): Remove redundant assignment.
43780 2019-03-17  Akim Demaille  <akim@lrde.epita.fr>
43782         bitset, timevar: Depend on c99.
43783         Reported by Bruno Haible.
43784         * modules/bitset, modules/timevar (Depends-on): Add c99.
43786 2019-03-16  Akim Demaille  <akim@lrde.epita.fr>
43788         bitset: a bit (...) more tests
43789         * tests/test-bitset.c (check_attributes): Check zero and ones.
43791 2019-03-16  Akim Demaille  <akim@lrde.epita.fr>
43793         bitset: fix overflows.
43794         Reported by Bruno Haible.
43795         https://lists.gnu.org/archive/html/bug-gnulib/2019-03/msg00017.html
43796         * lib/bitset/table.c (tbitset_test): last_bit is the position of
43797         the bit in the array of bitset_word, so be sure to take its modulo
43798         number-of-bits-in-bitset-word (i.e., EBITSET_ELT_WORDS).
43799         * lib/bitset/list.c (lbitset_unused_clear): Likewise.
43801 2019-03-14  Akim Demaille  <akim@lrde.epita.fr>
43803         bitset: style changes.
43804         * lib/bitset/table.c: Use NULL, not 0, for pointers.
43805         Formatting changes.
43806         (tbitset_list): Reduce scopes.
43808 2019-03-16  Bruno Haible  <bruno@clisp.org>
43810         fatal-signal: Pass the signal number to the action.
43811         * lib/fatal-signal.h (at_fatal_signal): Change the signature.
43812         * lib/fatal-signal.c (action_t): Take the signal number as parameter.
43813         (fatal_signal_handler): Pass the signal number to the action.
43814         * lib/clean-temp.c (cleanup_action): Renamed from cleanup. Take the
43815         signal number as parameter.
43816         (create_temp_dir): Update.
43817         * lib/wait-process.c (cleanup_slaves_action): New function.
43818         (register_slave_subprocess): Update at_fatal_signal invocation.
43819         * NEWS: Mention the change.
43821 2019-03-16  Bruno Haible  <bruno@clisp.org>
43823         fatal-signal: Add function that lists the fatal signals.
43824         * lib/fatal-signal.h (get_fatal_signals): New declaration.
43825         * lib/fatal-signal.c (get_fatal_signals): New function.
43827 2019-03-14  Bruno Haible  <bruno@clisp.org>
43829         isatty: Make it return true in Cygwin consoles on native Windows.
43830         * lib/isatty.c: Include <string.h>.
43831         (GetProcAddress): New macro.
43832         (GetNamedPipeClientProcessIdFuncType): New type.
43833         (GetNamedPipeClientProcessIdFunc): New variable.
43834         (QueryFullProcessImageNameFuncType): New type.
43835         (QueryFullProcessImageNameFunc): New variable.
43836         (initialized): New variable.
43837         (initialize): New function.
43838         (IsCygwinConsoleHandle): New function.
43839         (isatty): Invoke it.
43840         * doc/posix-functions/isatty.texi: Mention the issue.
43842 2019-03-14  Bruno Haible  <bruno@clisp.org>
43844         all: Update URLs to msdn.microsoft.com.
43845         * lib/stat-w32.c et al.: Update URLs after most of msdn.microsoft.com
43846         was moved to docs.microsoft.com.
43848 2019-03-13  Bruno Haible  <bruno@clisp.org>
43850         gnulib-tool: Clarify the coding style.
43851         Suggested by Pavel Raiskup <praiskup@redhat.com>.
43852         * gnulib-tool: Add comment about coding style.
43854 2019-03-11  Paul Eggert  <eggert@cs.ucla.edu>
43856         strtod: fix clash with strtold
43857         Problem reported for RHEL 5 by Jesse Caldwell (Bug#34817).
43858         * lib/strtod.c (compute_minus_zero, minus_zero):
43859         Simplify by remving the macro / external variable,
43860         and having just a function.  User changed.  This avoids
43861         the need for an external variable that might clash.
43863 2019-03-10  Bruno Haible  <bruno@clisp.org>
43865         alloca-opt: Fix conflict mingw's new <alloca.h> file.
43866         Reported by Eli Zaretskii <eliz@gnu.org>.
43867         * lib/alloca.in.h: On mingw systems that have <alloca.h>, include that.
43868         * m4/alloca.m4 (gl_FUNC_ALLOCA): Set HAVE_ALLOCA_H.
43869         * modules/alloca-opt (Makefile.am): Substitute HAVE_ALLOCA_H.
43871 2019-03-10  Bruno Haible  <bruno@clisp.org>
43873         tests: Avoid havoc with "gcc -fcheck-pointer-bounds".
43874         * tests/test-fprintf-posix2.c: Skip the test when -fcheck-pointer-bounds
43875         is in use.
43876         * tests/test-printf-posix2.c: Likewise.
43878 2019-03-10  Bruno Haible  <bruno@clisp.org>
43880         uninorm tests: Free allocated memory.
43881         * tests/uninorm/test-u32-normalize-big.h
43882         (struct normalization_test_file): Remove 'const' from allocated member.
43883         (free_normalization_test_file): New declaration.
43884         * tests/uninorm/test-u32-normalize-big.c (test_other): Free allocated
43885         memory.
43886         (free_normalization_test_file): New function.
43887         * tests/uninorm/test-u32-nfc-big.c (main): Free allocated
43888         'struct normalization_test_file' contents.
43889         * tests/uninorm/test-u32-nfd-big.c (main): Likewise.
43890         * tests/uninorm/test-u32-nfkc-big.c (main): Likewise.
43891         * tests/uninorm/test-u32-nfkd-big.c (main): Likewise.
43893 2019-03-10  Bruno Haible  <bruno@clisp.org>
43895         di-set: Fix memory leak.
43896         * lib/di-set.c (di_set_free): Free the ino_map through ino_map_free(),
43897         not free().
43899 2019-03-10  Bruno Haible  <bruno@clisp.org>
43901         tests: Free allocated memory.
43902         Reported by <deltatau@protonmail.com> via Assaf Gordon.
43903         * tests/test-astrxfrm.c (main): Free allocated memory.
43904         * tests/test-bitset.c (compare, check_attributes): Free allocated
43905         bitsets.
43906         * tests/test-filenamecat.c (main): Free allocated memory.
43907         * tests/test-freadahead.c (main): Free allocated memory and close stdin.
43908         * tests/test-freadptr.c (main): Likewise.
43909         * tests/test-freadptr2.c (main): Free allocated memory.
43910         * tests/test-freadseek.c (main): Likewise.
43911         * tests/test-gc-arcfour.c (main): Close allocated context.
43912         * tests/test-gc-arctwo.c (main): Likewise.
43913         * tests/test-gc-des.c (main): Close all allocated contexts.
43914         * tests/test-pipe-filter-gi1.c (main): Free allocated memory.
43915         * tests/test-pipe-filter-ii1.c (main): Likewise.
43916         * tests/test-posix_spawn_file_actions_addchdir.c (main): Destroy the
43917         allocated file actions.
43918         * tests/test-posix_spawn_file_actions_addclose.c (main): Likewise.
43919         * tests/test-posix_spawn_file_actions_adddup2.c (main): Likewise.
43920         * tests/test-posix_spawn_file_actions_addopen.c (main): Likewise.
43921         * tests/test-sameacls.c (main): Free allocated memory and ACLs.
43922         * tests/test-strfmon_l.c (main): Free allocated locales.
43923         * tests/test-striconveh.c (main): Free allocated iconv_t objects.
43924         * tests/uniconv/test-u8-conv-to-enc.c (main): Free allocated memory.
43925         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
43926         * tests/uniconv/test-u32-conv-to-enc.c (main): Likewise.
43927         * tests/unistr/test-chr.h (main): Free input32.
43928         * tests/unistr/test-strchr.h (test_strchr): Likewise.
43930 2019-03-10  Bruno Haible  <bruno@clisp.org>
43932         tests: Prepare for using valgrind.
43933         * tests/*.sh: Invoke all test programs through ${CHECKER}.
43934         * tests/*/*.sh: Likewise.
43935         * tests/test-freadptr.c (main): Update accordingly.
43936         * tests/test-freadseek.c (main): Likewise.
43938 2019-03-09  Bruno Haible  <bruno@clisp.org>
43940         get-rusage-as, pthread_sigmask tests: Fix -fsanitize=thread findings.
43941         * lib/get-rusage-as.c (get_rusage_as): When compiled by
43942         "gcc -fsanitize=thread", don't try get_rusage_as_via_setrlimit.
43943         * tests/test-pthread_sigmask2.c (main): Clean up the killer_thread
43944         before exiting.
43946 2019-03-09  Jim Meyering  <meyering@fb.com>
43948         test-userspec.c: don't print NULL
43949         * tests/test-userspec.c (main): A test release of gcc,
43950         9.0.1 20190310, warned that this test would attempt to
43951         print a NULL pointer via a %s printf format.  Fix that
43952         and remove the unnecessary preceding "!diag" conjunct.
43953         Also add a comment.
43955 2019-03-03  Bruno Haible  <bruno@clisp.org>
43957         getloadavg: Write NULL for the null pointer.
43958         Reported by Michal Privoznik <mprivozn@redhat.com>.
43959         * lib/getloadavg.c (getloadavg): Write NULL instead of 0.
43961 2019-02-28  Michal Privoznik  <mprivozn@redhat.com>
43963         alloca, tsearch-tests: Write NULL for the null pointer.
43964         * lib/alloca.c (i00afunc): Write NULL instead of 0.
43965         * tests/test-tsearch.c (mangle_tree): Likewise.
43967 2019-03-09  Bruno Haible  <bruno@clisp.org>
43969         strfmon_l: Fix -fsanitize=address finding.
43970         * lib/strfmon_l.c: Include <errno.h>, <stdbool.h>, <stdlib.h>,
43971         <string.h>.
43972         (MAX_ARGS): Renamed from MAX_ARG_WORDS.
43973         (directive_t, directives_t): New types.
43974         (fmon_parse): New function.
43975         (rpl_strfmon_l): Don't call va_arg more often than needed for the
43976         format string. Consume 'long double' arguments in places where the
43977         format string indicates so.
43978         * modules/strfmon_l (Depends-on): Add 'stdbool'.
43980 2019-03-09  Bruno Haible  <bruno@clisp.org>
43982         crypto/des: Fix undefined behaviour.
43983         * lib/des.c (READ_64BIT_DATA): Cast bytes to 'unsigned int', to avoid
43984         shift operations on 'int'.
43986 2019-03-09  Bruno Haible  <bruno@clisp.org>
43988         Fix undefined behaviour.
43989         * lib/bitrotate.h (rotl16, rotr16, rotl8, rotr8): Cast x to
43990         'unsigned int', to avoid shift operations on 'int'.
43991         * lib/xmemdup0.c (xmemdup0): Don't invoke memcpy with a zero size.
43992         * tests/test-count-leading-zeros.c (main): Use a random number that has
43993         as many bits as TYPE, not only 2*15 or 2*31 bits.
43994         * tests/test-count-trailing-zeros.c (main): Likewise.
43995         * tests/test-count-one-bits.c (main): Likewise.
43996         * tests/test-memmem.c: Don't include "null-ptr.h".
43997         (main): Use zerosize_ptr() instead of null_ptr().
43998         * modules/memmem-tests (Files): Remove tests/null-ptr.h.
44000 2019-03-08  Bruno Haible  <bruno@clisp.org>
44002         unilbrk/u*-possible-linebreaks: Fix undefined behaviour.
44003         Reported by Jeffrey Walton <noloader@gmail.com>.
44004         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks): Don't
44005         invoke memset with a zero size.
44006         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
44007         Likewise.
44008         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
44009         Adjust accordingly.
44011 2019-03-08  Bruno Haible  <bruno@clisp.org>
44013         unistr/*, uniconv/*: Fix undefined behaviour.
44014         Reported by Jeffrey Walton <noloader@gmail.com>.
44015         * lib/unistr/u-cpy.h (FUNC): Don't invoke memcpy with a zero size.
44016         * lib/unistr/u-cpy-alloc.h (FUNC): Likewise.
44017         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Likewise.
44018         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
44020 2019-03-08  Bruno Haible  <bruno@clisp.org>
44022         unistr/u8-cmp: Fix undefined behaviour.
44023         Reported by Jeffrey Walton <noloader@gmail.com>.
44024         * lib/unistr/u8-cmp.c (u8_cmp): Don't invoke memcmp if n is zero.
44026 2019-03-08  Bruno Haible  <bruno@clisp.org>
44028         unictype/numeric: Fix undefined behaviour.
44029         Reported by Jeffrey Walton <noloader@gmail.com>.
44030         * lib/unictype/numeric.c (uc_numeric_value): Avoid undefined behaviour
44031         on shift overflow, caught by "gcc -fsanitize=undefined".
44032         * lib/unictype/bidi_of.c (uc_bidi_class): Add cast, for clarity.
44033         * lib/unictype/categ_of.c (lookup_withtable): Likewise.
44034         * lib/unictype/joininggroup_of.c (uc_joining_group): Likewise.
44036 2019-03-05  Paul Eggert  <eggert@cs.ucla.edu>
44038         git-version-gen: fix --version copyright year
44039         * build-aux/git-version-gen, build-aux/move-if-change (version):
44040         --version output copyright year is now taken from script year,
44041         so that it no longer needs to be updated by hand.
44043 2019-03-04  Bruno Haible  <bruno@clisp.org>
44045         relocatable-prog: Use wrapper-free installation on Mac OS X, take 2.
44046         This approach supports relocatable installation of shared libraries
44047         which depend on other shared libraries from the same package.
44048         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Determine use_macos_tools.
44049         If use_macos_tools is true, use reloc-ldflags and set LIBTOOL to be a
44050         wrapper around the original LIBTOOL.
44051         * build-aux/reloc-ldflags: Add support for Mac OS X, which uses the
44052         token '@loader_path' instead of '$ORIGIN'.
44053         * build-aux/libtool-reloc: New file.
44054         * modules/relocatable-prog (Files): Add it.
44055         * doc/relocatable-maint.texi (Supporting Relocation): Update to match
44056         the recent changes. Document the need to set the *_LDFLAGS of libraries.
44057         RELOCATABLE_LIBRARY_PATH and RELOCATABLE_CONFIG_H_DIR should be set in
44058         Makefile.am, not in configure.ac.
44060 2019-03-04  Bruno Haible  <bruno@clisp.org>
44062         relocatable-prog: Revert "Use wrapper-free installation on Mac OS X."
44063         * build-aux/install-reloc: Revert change.
44064         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Likewise.
44066 2019-02-24  Paul Eggert  <eggert@cs.ucla.edu>
44068         nstrftime: support the ‘+’ flag
44069         * lib/nstrftime.c (add, __strftime_internal):
44070         Add support for the ‘+’ flag introduced in POSIX.1-2017.
44071         (__strftime_internal): New arg ‘width’.  All uses changed.
44072         (DO_YEARISH, DO_MAYBE_SIGNED_NUMBER): New macros.
44074 2019-02-24  Bruno Haible  <bruno@clisp.org>
44076         relocatable-prog: Improve verbose output.
44077         * build-aux/install-reloc (func_verbose): Escape characters that would
44078         be interpreted by the shell.
44080 2019-02-24  Bruno Haible  <bruno@clisp.org>
44082         stat, lstat: Fix conflict with relocatable-prog-wrapper module.
44083         * lib/stat.c: On platforms other than OSF/1, include <sys/stat.h>, not
44084         "sys/stat.h".
44085         * lib/lstat.c: Likewise.
44086         * lib/fstat.c: Likewise.
44087         * lib/fstatat.c: Likewise.
44089 2019-02-23  Bernhard Voelker  <mail@bernhard-voelker.de>
44091         long-options: add parse_gnu_standard_options_only
44092         Discussed in https://bugs.gnu.org/33468 .
44094         * lib/long-options.c (parse_long_options): Use EXIT_SUCCESS instead of 0
44095         (parse_gnu_standard_options_only): Add function to process
44096         the GNU default options --help and --version and fail for
44097         any other unknown long or short option. See
44098         https://gnu.org/prep/standards/html_node/Command_002dLine-Interfaces.html
44099         * lib/long-options.h (parse_gnu_standard_options_only): Declare it.
44100         * modules/long-options (depends-on): Add stdbool, exitfail.
44101         * top/maint.mk (sc_prohibit_long_options_without_use): Update
44102         syntax-check rule, add new function name.
44104 2019-02-23  Bruno Haible  <bruno@clisp.org>
44106         relocatable-prog: Update documentation.
44107         * doc/relocatable-maint.texi (Supporting Relocation): Update to match
44108         the recent changes.
44110 2019-02-23  Paul Eggert  <eggert@cs.ucla.edu>
44112         nstrftime: tweak arg order
44113         * lib/nstrftime.c (__strftime_internal): Interchange arg order.
44114         All callers changed.  Suggested by TAMUKI Shoichi in:
44115         https://lists.gnu.org/r/bug-gnulib/2019-02/msg00052.html
44117 2019-02-23  Bruno Haible  <bruno@clisp.org>
44119         relocatable-prog: Use wrapper-free installation also on Mac OS X.
44120         Reported by Paul Smith <psmith@gnu.org>.
44121         * build-aux/install-reloc: Accept a 'mode' argument as first argument.
44122         (func_relativize): New function, from gnulib-tool.
44123         Handle mode 'macosx' through invocations of 'otool' and
44124         'install_name_tool'.
44125         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Determine use_macos_tools.
44126         If use_macos_tools is true, set INSTALL_PROGRAM_ENV to an
44127         'install-reloc' invocation with mode 'macosx'.
44129 2019-02-23  Bruno Haible  <bruno@clisp.org>
44131         relocatable-prog: Use $ORIGIN trick also on GNU/Hurd.
44132         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Use $ORIGIN trick also on
44133         Hurd with glibc >= 2.27.
44135 2019-02-21  Paul Eggert  <eggert@cs.ucla.edu>
44137         nstrftime: merge glibc strftime changes
44138         This incorporates:
44139         2019-02-11 Fix a few whitespace arrangement inconsistencies
44140         2019-01-24 strftime: Pass flags from "%EY" to "%Ey" [BZ #24096]
44141         2019-01-24 Set the default width of "%Ey" to 2 [BZ #23758]
44142         2019-01-11 strftime: use the "L_" macro with character literals
44143         * lib/nstrftime.c (__strftime_internal): New arg yr_spec.  All
44144         callers changed.  Default width of %Ey is now 2.  This is needed
44145         for proper handling of Japanese dates starting on 2019-05-01.
44147 2019-02-19  Bruno Haible  <bruno@clisp.org>
44149         relocatable-prog: Use $ORIGIN trick on more platforms.
44150         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Use $ORIGIN trick also on
44151         FreeBSD >= 7.3, DragonFly >= 3.0, NetBSD >= 8.0, OpenBSD >= 5.4,
44152         Solaris >= 10, Haiku. But don't use it on Android.
44153         * build-aux/reloc-ldflags: Allow the use of the $ORIGIN trick also on
44154         Hurd, FreeBSD, DragonFly, NetBSD, OpenBSD, Solaris, Haiku.
44156 2019-02-19  Bruno Haible  <bruno@clisp.org>
44158         progreloc: Speed up executable lookup on various platforms.
44159         * lib/progreloc.c: Include <errno.h>.
44160         (safe_read, full_read): New functions.
44161         (find_executable): On GNU/kFreeBSD, FreeBSD, DragonFly, NetBSD, Solaris,
44162         prefer the information from the /proc file system to a PATH search.
44164 2019-02-19  Bruno Haible  <bruno@clisp.org>
44166         progreloc: Simplify code for Android.
44167         * lib/progreloc.c (executable_fd): Don't define on Android.
44168         (maybe_executable, find_executable): Don't use executable_fd on Android.
44170 2019-02-15  Bruno Haible  <bruno@clisp.org>
44172         gnulib-tool: Support --import with just a few tests, not --with-tests.
44173         * gnulib-tool (func_import): New variable 'gentests'. Use it instead of
44174         'inctests' when generating files; use 'inctests' only for computing the
44175         transitive closure.
44177 2019-02-14  Bruno Haible  <bruno@clisp.org>
44179         gnulib-tool: Improve handling of multiple --local-dir options.
44180         * doc/gnulib.texi (Extending Gnulib): Explain how multiple --local-dir
44181         options work.
44182         * gnulib-tool (func_path_prepend): Remove function.
44183         (func_path_foreach): Make IFS handling more robust.
44184         (local_gnulib_path): Collect --local-dir values using func_path_append,
44185         not func_path_prepend.
44186         (func_determine_path_separator): Make IFS handling more robust.
44187         (func_lookup_file_cb): New function.
44188         (func_lookup_file): Rewritten to use func_lookup_file_cb instead of
44189         func_lookup_local_file. Apply the patches in the reverse order of their
44190         origin in $local_gnulib_path.
44191         (func_count_relative_local_gnulib_path): Make IFS handling more robust.
44192         * NEWS: Mention that the first --local-dir option is the one with
44193         highest priority.
44195 2019-02-10  Bruno Haible  <bruno@clisp.org>
44197         libtextstyle: New module.
44198         * m4/libtextstyle.m4: New file.
44199         * modules/libtextstyle: New file.
44201 2019-02-05  Bruno Haible  <bruno@clisp.org>
44203         declared.sh: Fix bug with variables of pointer type.
44204         * build-aux/declared.sh (sed_extract_extern_declared): Allow the space
44205         before the symbol to be omitted if the preceding character is a '*'.
44207 2019-02-04  Bruno Haible  <bruno@clisp.org>
44209         Add script for running tests under valgrind.
44210         * build-aux/run-test: New file, from GNU libunistring.
44211         * doc/valgrind-tests.texi: Rewritten to mention alternative approaches
44212         as well.
44214 2019-02-04  Bruno Haible  <bruno@clisp.org>
44216         declared.sh: Fix --version output.
44217         * build-aux/declared.sh (func_version): Update package name.
44219 2019-02-03  Bruno Haible  <bruno@clisp.org>
44221         Add script for determining the set of symbols to export from a library.
44222         * build-aux/declared.sh: New file, from GNU libunistring.
44223         * doc/lib-symbol-visibility.texi (Exported Symbols of Shared Libraries):
44224         Mention it.
44226 2019-02-02  Paul Eggert  <eggert@cs.ucla.edu>
44228         vla: add commentary about VLA_ELEMS
44229         * lib/vla.h (VLA_ELEMS): Add commentary,
44230         some inspired by Bruno Haible’s proposal in:
44231         https://lists.gnu.org/r/bug-gnulib/2019-01/msg00109.html
44233         dtoastr,ftoastr,ldtoastr: port to c-strtod changes
44234         Decouple these modules from c-strtod.  Nowadays it’s reasonable to
44235         assume the C99 signatures for strtod and strtold.  Programs that
44236         require stricter adherence to C99 should also use the strtod and
44237         strtold modules as needed, and we no longer need the
44238         HAVE_C99_STRTOLD macro.
44239         * NEWS: Mention this.
44240         * lib/ftoastr.c (STRTOF) [LENGTH == 3]: Assume strtold.
44241         * m4/c-strtod.m4 (gl_C_STRTOLD): Do not define HAVE_C99_STRTOLD.
44242         * modules/dtoastr, modules/ftoastr, modules/ldtoastr:
44243         (Files): Remove m4/c-strtod.m4.
44244         (configure.ac): Do not require gl_C99_STRTOLD, which no longer
44245         exists.
44247 2019-02-02  Bruno Haible  <bruno@clisp.org>
44249         fma: Improve code style.
44250         * lib/fma.c: Include <limits.h>, for CHAR_BIT.
44252 2019-02-02  Colin Watson  <cjwatson@debian.org>
44254         *-map tests: Fix compilation error.
44255         * tests/test-array_map.c: Include <limits.h>, for CHAR_BIT.
44256         * tests/test-hash_map.c: Likewise.
44257         * tests/test-linkedhash_map.c: Likewise.
44259 2019-01-31  Bruno Haible  <bruno@clisp.org>
44261         c-strtod, c-strtold: Use the bug fixes for strtod, strtold.
44262         * lib/stdlib.in.h (GNULIB_defined_strtod_function,
44263         GNULIB_defined_strtold_function): New macros.
44264         * lib/c-strtod.c (HAVE_GOOD_STRTOD_L): New macro.
44265         (STRTOD): Ignore HAVE_C99_STRTOLD.
44266         (c_locale): Don't define it on platforms where strtod_l/strtold_l is
44267         deemed buggy. But do use it on platforms where uselocale exists and is
44268         usable.
44269         (C_STRTOD): Don't use STRTOD_L on platforms where strtod_l/strtold_l is
44270         deemed buggy. On platforms where uselocale exists and is usable, use
44271         uselocale and strtod/strtold.
44272         * m4/c-strtod.m4 (gl_C99_STRTOLD): Remove macro.
44273         (gl_C_STRTOD): Require gt_FUNC_USELOCALE.
44274         (gl_C_STRTOLD): Likewise. Define HAVE_C99_STRTOLD unconditionally.
44275         * modules/c-strtod (Files): Add m4/intl-thread-locale.m4.
44276         (Depends-on): Add strtod.
44277         * modules/c-strtold (Files): Add m4/intl-thread-locale.m4.
44278         (Depends-on): Add strtold.
44280 2019-01-31  Bruno Haible  <bruno@clisp.org>
44282         strtod, strtold: Use the locale's decimal point.
44283         * lib/strtod.c: Include <locale.h>, <stdio.h>, <langinfo.h>.
44284         (decimal_point_char): New function, copied from lib/vasnprintf.c.
44285         (parse_number): Add a radixchar argument. Use it instead of '.'.
44286         (STRTOD): Invoke decimal_point_char and pass the result to parse_number.
44287         * m4/strtod.m4 (gl_PREREQ_STRTOD): Test whether nl_langinfo exists.
44288         * m4/strtold.m4 (gl_PREREQ_STRTOLD): Likewise.
44289         * tests/test-strtod1.c: New file.
44290         * tests/test-strtod1.sh: New file.
44291         * modules/strtod-tests (Files): Add test-strtod1.{sh,c}. Add
44292         locale-fr.m4 and its dependencies.
44293         (configure.ac): Invoke gt_LOCALE_FR, gt_LOCALE_FR_UTF8.
44294         (Makefile.am): Arrange to compile test-strtod1.c and run
44295         test-strtod1.sh.
44296         * tests/test-strtold1.c: New file.
44297         * tests/test-strtold1.sh: New file.
44298         * modules/strtold-tests (Files): Add test-strtold1.{sh,c}. Add
44299         locale-fr.m4 and its dependencies.
44300         (configure.ac): Invoke gt_LOCALE_FR, gt_LOCALE_FR_UTF8.
44301         (Makefile.am): Arrange to compile test-strtold1.c and run
44302         test-strtold1.sh.
44304 2019-01-31  Bruno Haible  <bruno@clisp.org>
44306         strtod, strtold tests: Simplify tests.
44307         * tests/test-strtod.c (main): Assume no rounding errors for 0.5.
44308         * tests/test-strtold.c (main): Likewise.
44310 2019-01-31  Bruno Haible  <bruno@clisp.org>
44312         strtod, strtold: Avoid unnecessary rounding errors.
44313         * lib/strtod.c (parse_number): Drop trailing zeroes before doing the
44314         decimal to DOUBLE conversion.
44316 2019-01-31  Bruno Haible  <bruno@clisp.org>
44318         strtod, strtold: Work around HP-UX 11.31/ia64 bug.
44319         * lib/strtod.c (STRTOD): When there is an extra character after the
44320         exponent marker 'p', reparse the number.
44321         * doc/posix-functions/strtod.texi: Document the HP-UX 11.31 bug.
44322         * doc/posix-functions/strtold.texi: Likewise.
44324 2019-01-29  Bruno Haible  <bruno@clisp.org>
44326         strtold: Add tests.
44327         * tests/test-strtold.c: New file, based on tests/test-strtod.c.
44328         * modules/strtold-tests: New file.
44330 2019-01-29  Bruno Haible  <bruno@clisp.org>
44332         strtold: New module.
44333         * lib/stdlib.in.h (strtold): New declaration.
44334         * lib/strtold.c: New file.
44335         * lib/strtod.c: Consider USE_LONG_DOUBLE.
44336         (STRTOD, LDEXP, HAVE_UNDERLYING_STRTOD, DOUBLE, MIN, MAX, L_,
44337         USE_LDEXP): New macros.
44338         (LDEXP, scale_radix_exp, parse_number, STRTOD): Adapt for
44339         USE_LONG_DOUBLE.
44340         (underlying_strtod): Remove function. Replace with some macros.
44341         Re-add the code for a missing underlying function that was removed on
44342         2013-02-19.
44343         * m4/strtold.m4: New file.
44344         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtold is declared.
44345         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOLD, HAVE_STRTOLD,
44346         REPLACE_STRTOLD.
44347         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOLD, HAVE_STRTOLD,
44348         REPLACE_STRTOLD.
44349         * modules/strtold: New file.
44350         * doc/posix-functions/strtold.texi: Document the new module.
44352 2019-01-29  Bruno Haible  <bruno@clisp.org>
44354         strtod: Fix compilation error on IRIX 6.5.
44355         * modules/strtod (Depends-on): Add 'math'.
44357 2019-01-28  Bruno Haible  <bruno@clisp.org>
44359         Fix build error when building a shared libunistring on Android.
44360         * tests/uninorm/test-nfc.c (n): Don't define on Android.
44361         (main): Add 'volatile', to defeat a GCC optimization that would
44362         eliminate the reference.
44363         * tests/uninorm/test-nfd.c (n): Don't define on Android.
44364         (main): Add 'volatile', to defeat a GCC optimization that would
44365         eliminate the reference.
44366         * tests/uninorm/test-nfkc.c (n): Don't define on Android.
44367         (main): Add 'volatile', to defeat a GCC optimization that would
44368         eliminate the reference.
44369         * tests/uninorm/test-nfkd.c (n): Don't define on Android.
44370         (main): Add 'volatile', to defeat a GCC optimization that would
44371         eliminate the reference.
44373 2019-01-27  Bruno Haible  <bruno@clisp.org>
44375         Avoid build errors due to wrong references between modules.
44376         * lib/uninorm/canonical-decomposition.c: Include
44377         "uninorm/decomposition-table.h", not "decomposition-table.h".
44378         * lib/uninorm/decomposition.c: Likewise.
44379         * lib/uninorm/u8-normalize.c: Include "uninorm/decompose-internal.h",
44380         not "decompose-internal.h".
44381         * lib/uninorm/u16-normalize.c: Likewise.
44382         * lib/uninorm/u32-normalize.c: Likewise.
44383         * lib/uninorm/uninorm-filter.c: Likewise.
44384         * lib/uninorm/nfkc.c: Likewise.
44385         * lib/uninorm/nfkd.c: Likewise.
44386         * lib/unicase/u8-casemap.c: Include "unicase/caseprop.h", not
44387         "caseprop.h".
44388         * lib/unicase/u8-ct-totitle.c: Likewise.
44389         * lib/unicase/u8-prefix-context.c: Likewise.
44390         * lib/unicase/u8-suffix-context.c: Likewise.
44391         * lib/unicase/u16-casemap.c: Likewise.
44392         * lib/unicase/u16-ct-totitle.c: Likewise.
44393         * lib/unicase/u16-prefix-context.c: Likewise.
44394         * lib/unicase/u16-suffix-context.c: Likewise.
44395         * lib/unicase/u32-casemap.c: Likewise.
44396         * lib/unicase/u32-ct-totitle.c: Likewise.
44397         * lib/unicase/u32-prefix-context.c: Likewise.
44398         * lib/unicase/u32-suffix-context.c: Likewise.
44399         * lib/unicase/u8-tolower.c: Include "unicase/unicasemap.h", not
44400         "unicasemap.h".
44401         * lib/unicase/u8-toupper.c: Likewise.
44402         * lib/unicase/u8-ct-tolower.c: Likewise.
44403         * lib/unicase/u8-ct-toupper.c: Likewise.
44404         * lib/unicase/u16-tolower.c: Likewise.
44405         * lib/unicase/u16-toupper.c: Likewise.
44406         * lib/unicase/u16-ct-tolower.c: Likewise.
44407         * lib/unicase/u16-ct-toupper.c: Likewise.
44408         * lib/unicase/u32-tolower.c: Likewise.
44409         * lib/unicase/u32-toupper.c: Likewise.
44410         * lib/unicase/u32-ct-tolower.c: Likewise.
44411         * lib/unicase/u32-ct-toupper.c: Likewise.
44412         * lib/unicase/u8-ct-casefold.c: Include "unicase/unicasemap.h", not
44413         "unicasemap.h", and "unicase/casefold.h", not "casefold.h".
44414         * lib/unicase/u16-ct-casefold.c: Likewise.
44415         * lib/unicase/u32-ct-casefold.c: Likewise.
44417 2019-01-27  Bruno Haible  <bruno@clisp.org>
44419         gperf: Fix error when this module is required by some test module.
44420         * modules/gperf (Applicability): Set to 'all'.
44422 2019-01-27  Bruno Haible  <bruno@clisp.org>
44424         tmpfile: Add support for Android.
44425         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Add a runtime test whether tmpfile()
44426         works.
44427         * lib/tmpfile.c (tmpfile): Add an alternative implementation for
44428         Android.
44429         * modules/tmpfile (Depends-on): Add 'stdbool'.
44430         * doc/posix-functions/tmpfile.texi: Mention the Android bug.
44431         * modules/argv-iter-tests (Depends-on): Add 'tmpfile'.
44433 2019-01-27  Akim Demaille  <akim@lrde.epita.fr>
44435         bitsetv: allow free on NULL.
44436         * lib/bitsetv.c (bitsetv_free): Do nothing when the bitsetv is NULL.
44438 2019-01-27  Bruno Haible  <bruno@clisp.org>
44440         test-framework-sh: Improve maintainability.
44441         * tests/init.sh: Clarify what belongs together. Reorder definitions.
44443 2019-01-27  Bruno Haible  <bruno@clisp.org>
44445         tests: Don't assume that /tmp exists.
44446         * tests/test-set-mode-acl-1.sh: Skip the test if /tmp does not exist.
44447         * tests/test-copy-acl-1.sh: Likewise.
44448         * tests/test-file-has-acl-1.sh: Likewise.
44449         * tests/test-copy-file-1.sh: Likewise.
44451 2019-01-27  Bruno Haible  <bruno@clisp.org>
44453         tests: Accommodate a shell that is not in /bin/sh.
44454         * tests/init.sh (setup_): Set srcdir and builddir.
44455         (BOURNE_SHELL): New variable.
44456         * modules/acl-tests (Depends-on): Add 'test-framework-sh'.
44457         * modules/file-has-acl-tests (Depends-on): Likewise.
44458         * modules/copy-file-tests (Depends-on): Likewise.
44459         * tests/test-set-mode-acl-1.sh: Use the test framework. Invoke shell
44460         scripts through $BOURNE_SHELL.
44461         * tests/test-set-mode-acl-2.sh: Likewise.
44462         * tests/test-copy-acl-1.sh: Likewise.
44463         * tests/test-copy-acl-2.sh: Likewise.
44464         * tests/test-file-has-acl-1.sh: Likewise.
44465         * tests/test-file-has-acl-2.sh: Likewise.
44466         * tests/test-copy-file-1.sh: Likewise.
44467         * tests/test-copy-file-2.sh: Likewise.
44468         * tests/test-set-mode-acl.sh (builddir): Consider value set by the
44469         invoker.
44470         * tests/test-copy-acl.sh (builddir): Likewise.
44471         * tests/test-file-has-acl.sh (builddir): Likewise.
44472         * tests/test-copy-file.sh (builddir): Likewise.
44473         * tests/test-vc-list-files-cvs.sh: Don't create shims for executables in
44474         build-aux/. Instead, invoke shell scripts through $BOURNE_SHELL.
44475         * tests/test-vc-list-files-git.sh: Likewise.
44477 2019-01-27  Bruno Haible  <bruno@clisp.org>
44479         tests: Fix some "unused variable" warnings.
44480         * tests/test-fts.c (fts_dealloc): Remove unused variable.
44481         * tests/unigbrk/test-uc-grapheme-breaks.c (main): Likewise.
44482         * tests/test-striconveh.c (main): Move some variable into the
44483         '#if HAVE_ICONV'.
44484         * tests/test-striconveha.c (main): Likewise.
44485         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
44486         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
44487         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
44488         * tests/uniconv/test-u8-conv-to-enc.c (main): Likewise.
44489         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
44490         * tests/uniconv/test-u32-conv-to-enc.c (main): Likewise.
44491         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
44492         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
44493         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
44494         * tests/uniconv/test-u8-strconv-to-enc.c (main): Likewise.
44495         * tests/uniconv/test-u16-strconv-to-enc.c (main): Likewise.
44496         * tests/uniconv/test-u32-strconv-to-enc.c (main): Likewise.
44497         * tests/test-tsearch.c (main): Move some variable into the
44498         '#if HAVE_INITSTATE'.
44500 2019-01-27  Bruno Haible  <bruno@clisp.org>
44502         unigbrk/uc-grapheme-breaks: Fix build failure.
44503         * lib/unigbrk/uc-grapheme-breaks.c: Don't include unistr.h.
44504         * modules/unigbrk/uc-grapheme-breaks (Makefile.am): Fix typo.
44506 2019-01-27  Bruno Haible  <bruno@clisp.org>
44508         mountlist: Merge two .m4 files.
44509         * m4/mountlist.m4 (gl_MOUNTLIST): Inline gl_LIST_MOUNTED_FILE_SYSTEMS.
44510         (AC_FUNC_GETMNTENT): Move to here, from m4/ls-mntd-fs.m4.
44511         * m4/ls-mntd-fs.m4: Remove file.
44512         * modules/mountlist (Files): Remove m4/ls-mntd-fs.m4.
44514 2019-01-27  Bruno Haible  <bruno@clisp.org>
44516         tests: Enable Linux specific tests on Android.
44517         * tests/test-flock.c (main): Treat Android like Linux.
44518         * tests/test-openat-safer.c (main): Likewise.
44520 2019-01-27  Bruno Haible  <bruno@clisp.org>
44522         relocatable-prog: Use Linux code on Android.
44523         * lib/progreloc.c: Treat Android like Linux.
44525 2019-01-26  Bruno Haible  <bruno@clisp.org>
44527         getloadavg: Add support for Android.
44528         * lib/getloadavg.c: Treat Android like Linux.
44530 2019-01-26  Bruno Haible  <bruno@clisp.org>
44532         vma-iter: Add support for Android.
44533         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define on Android as well.
44534         * lib/vma-iter.c: Treat Android like Linux.
44535         * lib/get-rusage-data.c (get_rusage_data): Likewise.
44537 2019-01-26  Bruno Haible  <bruno@clisp.org>
44539         fts: Optimize on Android.
44540         * lib/fts.c: Treat Android like Linux.
44542 2019-01-26  Bruno Haible  <bruno@clisp.org>
44544         fts: Add support for Android.
44545         * m4/fts.m4 (gl_FUNC_FTS_CORE): Avoid conflicts between the symbols
44546         defined by this module and the ones in libc.
44547         * tests/test-fts.c (main): Treat mkdir error EMLINK like EMFILE.
44549 2019-01-26  Bruno Haible  <bruno@clisp.org>
44551         mountlist: Use Linux code on Android.
44552         * lib/mountlist.c (setmntent, endmntent): Define fallbacks.
44553         (unescape_tab, read_file_system_list): Enable Linux code on Android
44554         as well.
44555         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Test for setmntent
44556         and endmntent.
44557         * modules/mountlist (Depends-on): Add 'getline'.
44559 2019-01-26  Bruno Haible  <bruno@clisp.org>
44561         localename tests: Fix test failure on Android.
44562         * modules/localename-tests (Depends-on): Add 'setlocale'.
44564 2019-01-26  Bruno Haible  <bruno@clisp.org>
44566         mountlist: Port better to Android.
44567         * lib/mountlist.c (MOUNTED): Redefine on Android.
44568         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Redefine MOUNTED on
44569         Android.
44571 2019-01-26  Bruno Haible  <bruno@clisp.org>
44573         striconveh: Fix use of uninitialized iconv_t.
44574         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
44575         <https://lists.gnu.org/archive/html/bug-libunistring/2019-01/msg00000.html>.
44576         * lib/striconveh.c (iconveh_open): Correct the iconv_close argument.
44578 2019-01-26  Bruno Haible  <bruno@clisp.org>
44580         nonblocking-socket-tests: Fix test failure on Android 4.3.
44581         * tests/test-nonblocking-socket.h (SOCKET_HAS_LARGE_BUFFER): Define to 1
44582         also on Android.
44584 2019-01-26  Bruno Haible  <bruno@clisp.org>
44586         sh-filename: Add support for Android 4.3.
44587         * m4/sh-filename.m4 (gl_SH_FILENAME): Set to "sh" on Android.
44589 2019-01-26  Bruno Haible  <bruno@clisp.org>
44591         ptsname_r: Work around bug on Android 4.3.
44592         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Define
44593         HAVE_ESSENTIALLY_WORKING_PTSNAME_R. Test whether the return value is
44594         correct.
44595         * lib/ptsname_r.c (__ptsname_r): If HAVE_ESSENTIALLY_WORKING_PTSNAME_R
44596         is defined, just fix the return value.
44597         * doc/glibc-functions/ptsname_r.texi: Mention the Android bug. Reword:
44598         The behaviour of musl libc is nothing to be "fixed", since it is
44599         compliant with the next POSIX standard.
44601 2019-01-26  Bruno Haible  <bruno@clisp.org>
44603         ttyname_r: Work around bug on Android 4.3.
44604         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test whether ttyname_r is a stub.
44605         * lib/ttyname_r.c (ttyname_r): Implement for Android.
44606         * doc/posix-functions/ttyname_r.texi: Mention the Android bug.
44607         * doc/posix-functions/ttyname.texi: Likewise.
44609 2019-01-25  Bruno Haible  <bruno@clisp.org>
44611         getprogname: Port to Android 4.3.
44612         * lib/getprogname.c (getprogname): On Android, take only the last
44613         component of __progname.
44615 2019-01-25  Bruno Haible  <bruno@clisp.org>
44617         wcrtomb: Work around bug on Android 4.3.
44618         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Test also whether wcrtomb works in
44619         the C locale.
44620         * lib/wcrtomb.c (wcrtomb): Provide alternate implementation for Android,
44621         which does not have the 'wctomb' function.
44622         * doc/posix-functions/wcrtomb.texi: Mention the Android bug.
44623         * tests/test-wcrtomb.c (main): Accept argument '5'.
44624         * tests/test-wcrtomb.sh: Add tests in the POSIX locale.
44626 2019-01-25  Bruno Haible  <bruno@clisp.org>
44628         setlocale: Work around bug on Android 4.3.
44629         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Test whether setlocale supports
44630         the "C" locale.
44631         * lib/setlocale.c (setlocale_unixlike): New wrapper for Android.
44632         * doc/posix-functions/setlocale.texi: Mention the Android bug.
44634 2019-01-24  Bruno Haible  <bruno@clisp.org>
44636         memchr: Work around bug on Android <= 5.0.
44637         * m4/memchr.m4 (gl_FUNC_MEMCHR): Add test against the Android bug.
44638         * doc/posix-functions/memchr.texi: Mention the Android bug.
44640 2019-01-24  Bruno Haible  <bruno@clisp.org>
44642         random: Fix compilation error on Android 4.3.
44643         * lib/stdlib.in.h (random, srandom): Test also REPLACE_RANDOM.
44644         (initstate): Test REPLACE_INITSTATE and HAVE_INITSTATE, not HAVE_RANDOM.
44645         (setstate): Test REPLACE_SETSTATE and HAVE_SETSTATE, not HAVE_RANDOM.
44646         * m4/random.m4 (gl_FUNC_RANDOM): Set HAVE_INITSTATE, HAVE_SETSTATE,
44647         REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
44648         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_INITSTATE,
44649         HAVE_SETSTATE, REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
44650         * modules/stdlib (Makefile.am): Substitute HAVE_INITSTATE, HAVE_SETSTATE,
44651         REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
44652         * modules/random (Depends-on, configure.ac): Test also REPLACE_RANDOM,
44653         REPLACE_INITSTATE, REPLACE_SETSTATE.
44654         * doc/posix-functions/random.texi: Correct the description of the
44655         situation on Android.
44656         * doc/posix-functions/srandom.texi: Likewise.
44657         * doc/posix-functions/rand.texi: Likewise.
44658         * doc/posix-functions/srand.texi: Likewise.
44660 2019-01-24  Bruno Haible  <bruno@clisp.org>
44662         mbtowc: Fix compilation error on Android 4.3.
44663         * lib/stdlib.in.h (mbtowc): Test also HAVE_MBTOWC.
44664         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Test whether mbtowc exists. Set
44665         HAVE_MBTOWC.
44666         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether mbtowc is declared.
44667         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_MBTOWC.
44668         * modules/stdlib (Makefile.am): Substitute HAVE_MBTOWC.
44669         * modules/mbtowc (Depends-on, configure.ac): Test also HAVE_MBTOWC.
44670         * doc/posix-functions/mbtowc.texi: Mention the change.
44672 2019-01-24  Bruno Haible  <bruno@clisp.org>
44674         fdatasync: Fix compilation error on Android 4.3.
44675         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): On platforms other than Solaris,
44676         test whether fdatasync() exists.
44678 2019-01-24  Bruno Haible  <bruno@clisp.org>
44680         unlinkat: Fix compilation error on Android 4.3.
44681         * lib/unistd.in.h: Include <fcntl.h> when module 'unlinkat' is in use
44682         also on Android.
44683         * doc/posix-functions/unlinkat.texi: Mention the issue.
44685 2019-01-24  Bruno Haible  <bruno@clisp.org>
44687         renameat: Fix compilation error on Android 4.3.
44688         * lib/stdio.in.h: Include <sys/stat.h> when module 'renameat' is in use.
44689         * doc/posix-functions/renameat.texi: Mention the issue.
44691 2019-01-24  Bruno Haible  <bruno@clisp.org>
44693         fchownat: Fix compilation error on Android 4.3.
44694         * lib/unistd.in.h: Include <sys/stat.h> when module 'fchownat' is in
44695         use.
44696         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG,
44697         gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): Include also <sys/stat.h>.
44698         * doc/posix-functions/fchownat.texi: Mention the issue.
44700 2019-01-23  Bruno Haible  <bruno@clisp.org>
44702         gnulib-tool: Support running testdirs on Android.
44703         * build-aux/test-driver.diff: New file.
44704         * gnulib-tool (func_create_testdir, func_create_megatestdir): Patch
44705         build-aux/test-driver after running automake.
44707 2019-01-23  Akim Demaille  <akim@lrde.epita.fr>
44709         relocatable-prog: avoid warnings from Automake
44710         * modules/relocatable-prog: Don't declare PHONY dependencies in
44711         Automake conditionals.
44713 2019-01-23  Akim Demaille  <akim@lrde.epita.fr>
44715         array-list: Pacify warnings about unused arguments (-Wunused-parameter).
44716         * lib/gl_array_list.c (gl_array_iterator_free): "Use" the argument.
44718 2019-01-23  Bruno Haible  <bruno@clisp.org>
44720         threadlib: Revert commit from 2018-06-25. We now have a better fix.
44721         * m4/threadlib.m4 (gl_THREADLIB_BODY): Don't attempt to defeat a
44722         preceding -Wl,--as-needed option. Don't check whether the linker
44723         supports --as-needed/--no-as-needed and --push-state/--pop-state.
44725 2019-01-23  Bruno Haible  <bruno@clisp.org>
44727         thread: Force linking with -lpthread, even when --as-needed is in use.
44728         Reported by Richard W.M. Jones <rjones@redhat.com> in
44729         <https://lists.gnu.org/archive/html/bug-gnulib/2019-01/msg00123.html>.
44730         * lib/glthread/thread.h (pthread_create): Don't declare weak.
44732 2019-01-23  Akim Demaille  <akim.demaille@gmail.com>
44733             Bruno Haible  <bruno@clisp.org>
44735         relocatable: avoid compiler warnings (-Wshadow)
44736         * lib/relocatable.c (compute_curr_prefix): Rename local variables
44737         to avoid name collisions with global variables.
44739 2019-01-22  Bruno Haible  <bruno@clisp.org>
44741         vasnprintf: Don't use %n on Android.
44742         Reported and fix suggested by Hugo Beauzée-Luyssen <hugo@beauzee.fr> in
44743         <https://lists.gnu.org/archive/html/bug-gnulib/2018-12/msg00123.html>.
44744         * lib/vasnprintf.c (VASNPRINTF): Don’t use %n on Android.
44746 2019-01-22  Bruno Haible  <bruno@clisp.org>
44748         *printf: Support cross-compilation to Android.
44749         * m4/printf.m4: Add cross-compilation guesses for Android.
44751 2019-01-21  Bruno Haible  <bruno@clisp.org>
44753         diacrit: Mark deprecated.
44754         * modules/diacrit (Status, Notice): Mark as deprecated.
44755         * NEWS: Mention it.
44757 2019-01-20  Bruno Haible  <bruno@clisp.org>
44759         rintl: Override broken implementation on NetBSD.
44760         * lib/math.in.h (rintl): Test also REPLACE_RINTL.
44761         * m4/rintl.m4 (gl_FUNC_RINTL): Add test for negative arguments. Set
44762         REPLACE_RINTL.
44763         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_RINTL.
44764         * modules/math (Makefile.in): Substitute REPLACE_RINTL.
44765         * modules/rintl (Depends-on, configure.ac): Test REPLACE_RINTL.
44766         * doc/posix-functions/rintl.texi: Mention the NetBSD bug.
44768 2019-01-20  Bruno Haible  <bruno@clisp.org>
44770         log10l: Work around inaccurate implementation on NetBSD.
44771         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Add test for a certain accuracy.
44772         * lib/log10l.c: Comment out too simplistic override.
44773         * doc/posix-functions/log10l.texi: Mention the NetBSD bug.
44775 2019-01-20  Bruno Haible  <bruno@clisp.org>
44777         logl: Work around inaccurate implementation on NetBSD.
44778         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Add test for a certain accuracy.
44779         * lib/logl.c: Comment out unused code.
44780         * doc/posix-functions/logl.texi: Mention the NetBSD bug.
44782 2019-01-20  Bruno Haible  <bruno@clisp.org>
44784         expm1l: Work around inaccurate implementation on NetBSD.
44785         * lib/math.in.h (expm1l): Test also REPLACE_EXPM1L.
44786         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Add test for a certain accuracy. Set
44787         REPLACE_EXPM1L.
44788         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPM1L.
44789         * modules/math (Makefile.in): Substitute REPLACE_EXPM1L.
44790         * modules/expm1l (Depends-on, configure.ac): Test REPLACE_EXPM1L.
44791         * doc/posix-functions/expm1l.texi: Mention the NetBSD bug.
44793 2019-01-20  Bruno Haible  <bruno@clisp.org>
44795         expl: Work around inaccurate implementation on NetBSD.
44796         * lib/math.in.h (expl): Test also REPLACE_EXPL.
44797         * m4/expl.m4 (gl_FUNC_EXPL): Add test for a certain accuracy. Set
44798         REPLACE_EXPL.
44799         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPL.
44800         * modules/math (Makefile.in): Substitute REPLACE_EXPL.
44801         * modules/expl (Depends-on, configure.ac): Test REPLACE_EXPL.
44802         * doc/posix-functions/expl.texi: Mention the NetBSD bug.
44804 2019-01-20  Bruno Haible  <bruno@clisp.org>
44806         exp2l: Work around inaccurate implementation on NetBSD.
44807         * m4/exp2l.m4 (gl_FUNC_EXP2L): Add test for a certain accuracy.
44808         * doc/posix-functions/exp2l.texi: Mention the NetBSD bug.
44810 2019-01-20  Bruno Haible  <bruno@clisp.org>
44812         floor, floorl: Avoid autoconf warnings.
44813         * modules/floor (configure.ac): Use AC_REQUIRE.
44814         * modules/floorl (configure.ac): Likewise.
44816 2019-01-20  Bruno Haible  <bruno@clisp.org>
44818         Defeat current GCC optimizations in math autoconf tests.
44819         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Mark function pointer as 'volatile'.
44820         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
44821         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
44822         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
44823         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
44824         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
44825         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
44826         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
44827         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
44828         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
44829         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
44830         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
44831         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
44832         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
44833         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Likewise.
44834         * m4/ilogbf.m4 (gl_FUNC_ILOGBF_WORKS): Likewise.
44835         * m4/ilogbl.m4 (gl_FUNC_ILOGBL_WORKS): Likewise.
44836         * m4/log.m4 (gl_FUNC_LOG): Likewise.
44837         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
44838         * m4/log10.m4 (gl_FUNC_LOG10): Likewise.
44839         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
44840         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
44841         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Likewise.
44842         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Likewise.
44843         * m4/log2.m4 (gl_FUNC_LOG2): Likewise.
44844         * m4/log2f.m4 (gl_FUNC_LOG2F): Likewise.
44845         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
44846         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
44847         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
44848         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
44849         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
44850         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
44851         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
44852         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
44853         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
44854         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
44855         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
44856         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
44858 2019-01-19  Pádraig Brady  <P@draigBrady.com>
44860         gettext: support disabling use of VLAs
44861         * lib/gettext.h: Disable use of VLAs if GNULIB_NO_VLA is defined
44863 2019-01-17  KO Myung-Hun  <komh78@gmail.com>
44865         sys_stat: Fix 'implicit declaration of function' warning on OS/2 kLIBC.
44866         * lib/sys_stat.in.h [kLIBC]: Include <unistd.h>.
44868 2019-01-17  KO Myung-Hun  <komh78@gmail.com>
44870         fcntl: Fix syntax error (regression from 2018-10-05).
44871         * lib/fcntl.c (klibc_fcntl): Remove mis-placed ';'.
44873 2019-01-13  Akim Demaille  <akim@lrde.epita.fr>
44875         relocatable: improve documentation.
44876         * doc/relocatable-maint.texi (Supporting Relocation): For
44877         substitutions performed by config.status, we need more variables
44878         (for instance datarootdir defaults to '${prefix}/share' so we need
44879         prefix).
44881 2019-01-13  Akim Demaille  <akim@lrde.epita.fr>
44883         backup: update dependencies
44884         * modules/backup-rename (Depends-on): It now depends on opendirat
44885         instead of opendir.  It also uses stdint, and xalloc-oversized.
44886         But no longer dirfd.
44887         * modules/backupfile (Depends-on): Add xalloc-oversized.
44889 2019-01-13  Bruno Haible  <bruno@clisp.org>
44891         getcwd: Fix test failure when building on a Linux 9p file system.
44892         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): On Linux, treat error
44893         EINVAL from mkdir like ENAMETOOLONG.
44894         * tests/test-getcwd.c (test_long_name): Likewise.
44896 2019-01-12  Tim Rühsen  <tim.ruehsen@gmx.de>
44898         Fix typos found by codespell.
44899         * lib/*.[hc]: Fix typos in comments.
44900         * pygnulib/*.py: Fix typos in error messages and comments.
44902 2019-01-12  Bruno Haible  <bruno@clisp.org>
44904         doc: Fix documentation about container data types.
44905         Reported by Werner Lemberg <wl@gnu.org>.
44906         * doc/containers.texi (Container data types): Fix typo.
44908 2019-01-10  Bruno Haible  <bruno@clisp.org>
44910         verify: Enable _GL_HAVE_STATIC_ASSERT for recent G++ versions.
44911         Reported by Reuben Thomas <rrt@sc3d.org>.
44912         * lib/verify.h (_GL_HAVE_STATIC_ASSERT): Define for g++ versions >= 6.
44914 2019-01-06  Bruno Haible  <bruno@clisp.org>
44916         maintainer-makefile: Make the configure.ac section optional.
44917         * top/maint.mk (GREP, SED): Define if not defined.
44919 2019-01-06  Bruno Haible  <bruno@clisp.org>
44921         localename: Assume setlocale function.
44922         * lib/localename.c (gl_locale_name_posix): Assume setlocale exists.
44923         * m4/localename.m4 (gl_LOCALENAME): Don't test whether setlocale exists.
44925 2019-01-06  Bruno Haible  <bruno@clisp.org>
44927         doc: Add documentation about container data types.
44928         * doc/containers.texi: New file.
44929         * doc/gnulib.texi (Particular Modules): Include it.
44931 2019-01-06  Bruno Haible  <bruno@clisp.org>
44933         doc: Update documentation about 'progname' module.
44934         * doc/progname.texi: Rename from doc/error.texi. Change node name and
44935         title. Rewrite.
44936         * doc/gnulib.texi (Particular Modules): Update.
44938 2019-01-06  Bruno Haible  <bruno@clisp.org>
44940         doc: Document the xstdopen and *-safer modules.
44941         * doc/xstdopen.texi: New file.
44942         * doc/gnulib.texi (Particular Modules): Include it.
44944 2019-01-06  Bruno Haible  <bruno@clisp.org>
44946         xstdopen: Add tests.
44947         * tests/test-xstdopen.c: New file.
44948         * tests/test-xstdopen.sh: New file.
44949         * modules/xstdopen-tests: New file.
44951         xstdopen: New module.
44952         * lib/xstdopen.h: New file.
44953         * lib/xstdopen.c: New file.
44954         * modules/xstdopen: New file.
44956 2019-01-06  Bruno Haible  <bruno@clisp.org>
44958         stdopen: Fix compilation error with IRIX cc.
44959         * lib/stdopen.c (stdopen): Do not use C99-style decl in loop.
44961 2019-01-05  Paul Eggert  <eggert@cs.ucla.edu>
44963         xfreopen need not include stdio--.h
44964         * lib/xfreopen.c: Do not include stdio--.h.
44966         xfreopen need not depend on freopen-safer
44967         * modules/xfreopen (Depends-on):
44968         Depend on freopen, not freopen-safer.
44970         stdopen: modernize and simplify
44971         * lib/stdopen.c: Update copyright date
44972         Do not include sys/types.h; no longer needed these days.
44973         (stdopen): Use C99-style decl in loop.  Return int errno
44974         value, rather than just a bool.  Do not worry about fd mismatches,
44975         since the caller cares only if 0, 1, 2 are occupied.
44976         * lib/stdopen.h: No need to include <stdbool.h>.
44977         * m4/stdopen.m4: Remove.
44978         * modules/stdopen: New file.
44980         stdopen: copy from last use in coreutils
44981         * lib/stdopen.c, lib/stdopen.h, m4/stdopen.m4:
44982         New files, taken from their last commit in coreutils
44983         2007-07-23T12:35:58Z!jim@meyering.net
44984         71aa3ea88084d17bcb4fc1031ad7b66f8647115e.
44986 2019-01-05  Bruno Haible  <bruno@clisp.org>
44988         argp: Don't pass an invalid argument to dgettext().
44989         Reported by He X <xw897002528@gmail.com>.
44990         * lib/argp-help.c (print_header, argp_doc): Don't pass a NULL doc to
44991         dgettext().
44993 2019-01-05  Bruno Haible  <bruno@clisp.org>
44995         argp: Don't pass an invalid argument to dgettext().
44996         Reported by He X <xw897002528@gmail.com>.
44997         * lib/argp.h (struct argp): Clarify that the args_doc field may be NULL.
44998         * lib/argp-help.c (argp_args_usage): Don't pass a NULL args_doc to
44999         dgettext().
45001 2018-12-22  Paul Eggert  <eggert@cs.ucla.edu>
45003         stdioext: port to newer 32-bit Android
45004         Problem reported by Tom Yan in:
45005         https://lists.gnu.org/archive/html/bug-gnulib/2018-07/msg00014.html
45006         * lib/stdio-impl.h (_gl_FILE_flags_t) [__ANDROID__]: New macro.
45007         (fp_) [__ANDROID__]: Use it.
45009 2019-01-04  Bruno Haible  <bruno@clisp.org>
45011         lock: Fix link error with --enable-threads=pth.
45012         * lib/glthread/lock.h (pth_cond_init, pth_cond_await, pth_cond_notify):
45013         Mark as weak.
45015 2019-01-04  Bruno Haible  <bruno@clisp.org>
45017         Fix link errors in unit tests.
45018         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
45019         * modules/bitset-tests (Makefile.am): Link test-bitset against libintl.
45020         * modules/array-map-tests (Makefile.am): Link test-array_map against
45021         libintl.
45022         * modules/array-set-tests (Makefile.am): Link test-array_set against
45023         libintl.
45024         * modules/hash-map-tests (Makefile.am): Link test-hash_map against
45025         libintl.
45026         * modules/hash-set-tests (Makefile.am): Link test-hash_set against
45027         libintl.
45028         * modules/linkedhash-map-tests (Makefile.am): Link test-linkedhash_map
45029         against libintl.
45030         * modules/linkedhash-set-tests (Makefile.am): Link test-linkedhash_set
45031         against libintl.
45033 2019-01-04  Bruno Haible  <bruno@clisp.org>
45035         Fix incorrect 'Link' sections.
45036         * modules/regex (Link): Mention the link requirement of module 'lock'.
45037         * modules/regex-tests (Makefile.am): Don't use LIB_PTHREAD.
45039 2019-01-04  Bruno Haible  <bruno@clisp.org>
45041         Fix some 'Link' sections.
45042         * modules/c-stack (Link): Add link directive from the 'gettext-h'
45043         dependency.
45044         * modules/getaddrinfo (Link): Likewise.
45046 2019-01-04  Bruno Haible  <bruno@clisp.org>
45048         Remove redundant 'Link' sections.
45049         * modules/canon-host (Link): Remove section.
45050         * modules/timevar (Link): Likewise.
45052 2019-01-04  Bruno Haible  <bruno@clisp.org>
45054         Remove incorrect 'Link' sections.
45055         * modules/acl (Link): Remove section. Use combined 'Link' sections from
45056         the dependencies instead.
45057         * modules/crypto/md5 (Link): Likewise.
45058         * modules/crypto/sha1 (Link): Likewise.
45059         * modules/crypto/sha256 (Link): Likewise.
45060         * modules/crypto/sha512 (Link): Likewise.
45061         * modules/faccessat (Link): Likewise.
45062         * modules/fdutimensat (Link): Likewise.
45063         * modules/iconv_open-utf (Link): Likewise.
45064         * modules/propername (Link): Likewise.
45065         * modules/qacl (Link): Likewise.
45066         * modules/unicodeio (Link): Likewise.
45067         * modules/utimecmp (Link): Likewise.
45068         * modules/utimensat (Link): Likewise.
45069         * modules/xstriconv (Link): Likewise.
45070         * modules/xstriconveh (Link): Likewise.
45072 2019-01-04  Bruno Haible  <bruno@clisp.org>
45074         gnulib-tool: New option --extract-recursive-link-directive.
45075         * gnulib-tool (func_usage): Document the new options
45076         --extract-recursive-dependencies, --extract-recursive-link-directive.
45077         (func_verify_module): Document output variables.
45078         (func_get_dependencies_recursively): New function.
45079         (func_get_link_directive_recursively): New function.
45080         Use them to implement the new options
45081         --extract-recursive-dependencies, --extract-recursive-link-directive.
45082         * doc/gnulib-tool.texi (Link-time requirements): New section.
45084 2019-01-04  Bruno Haible  <bruno@clisp.org>
45086         Clarify meaning of 'Link' section in module description.
45087         * doc/gnulib.texi (Module description): Clarify the meaning of the
45088         'Link' section versus the one of the dependencies.
45089         * NEWS: Mention the change.
45091 2019-01-04  Bruno Haible  <bruno@clisp.org>
45093         pselect: Fix module description.
45094         * modules/pselect (Link): Put one link option per line.
45096 2019-01-04  Bruno Haible  <bruno@clisp.org>
45098         cosl: Fix module description.
45099         * modules/cosl (Link): Fix typo.
45100         * modules/mathl (configure.ac): Likewise.
45102 2019-01-04  Bruno Haible  <bruno@clisp.org>
45104         c-xvasprintf: Fix module dependencies.
45105         * modules/c-xvasprintf (Depends-on): Add 'xalloc-die'.
45107 2019-01-04  Akim Demaille  <akim@lrde.epita.fr>
45109         bootstrap: die when some submodules are not initialized
45110         * build-aux/bootstrap: Make sure all submodules are initialized.
45112 2019-01-04  Bruno Haible  <bruno@clisp.org>
45114         bitsetv: Fix module dependencies.
45115         * lib/bitsetv.c: Include xalloc.h.
45116         * modules/bitsetv (Depends-on): Add 'xalloc'.
45118 2019-01-04  Bruno Haible  <bruno@clisp.org>
45120         xmemdup0: Remove redundant code.
45121         * lib/xmemdup0.h (xalloc_die): Remove declaration.
45123 2019-01-04  Bruno Haible  <bruno@clisp.org>
45125         backupfile: Fix module dependencies.
45126         * modules/backupfile (Depends-on): Add 'xalloc'.
45128 2019-01-03  Paul Eggert  <eggert@cs.ucla.edu>
45130         bitset, crypto/gc: fix conflicts with Solaris 11
45131         * lib/bitset.h (_GL_BITSET_H): Rename from _BITSET_H, to
45132         avoid clash with Solaris 11 <sys/bitset.h>.
45133         * lib/gc.h (_GL_GC_H): Rename from GC_H, to avoid clash
45134         with Solaris 11 <xorg/gc.h>.
45136 2019-01-04  Bruno Haible  <bruno@clisp.org>
45138         safe-read, safe-write: Fix conflict with Illumos-Joyent <sys/limits.h>.
45139         Reported by Andy Fiddaman <andy@omniosce.org>.
45140         * lib/sys-limits.h: Add a '_GL' prefix to the guard symbol.
45142 2019-01-03  Eric Blake  <eblake@redhat.com>
45144         maintainer-makefile: fix typo in previous patch
45145         * top/maint.mk (_sc_search_regexp): Fix my accidental corruption
45146         of Roman's work.
45148 2019-01-02  Roman Bolshakov <r.bolshakov@yadro.com>  (tiny change)
45150         maintainer-makefile: prefer $(GREP) over grep
45151         * modules/maintainer-makefile (configure.ac): Ensure $(GREP) is
45152         defined.
45153         * top/maint.mk: Use it everywhere.
45155         maintainer-makefile: split long argument lines
45156         * top/maint.mk: Use xargs to split $(VC_LIST_EXCEPT) usage where
45157         it would be too long for exec limits on BSD.
45159 2018-12-27  Paul Eggert  <eggert@cs.ucla.edu>
45161         mkfifo: bring back HAVE_MKFIFO macro
45162         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): #define HAVE_MKFIFO as needed.
45163         Problem reported by Andrew Janke in:
45164         https://lists.gnu.org/r/bug-gnulib/2018-12/msg00147.html
45166 2018-12-21  Bruno Haible  <bruno@clisp.org>
45168         Assume Autoconf >= 2.63.
45169         * modules/stdarg (configure.ac-early): Remove comment about Autoconf
45170         versions < 2.60.
45172 2018-12-21  Bruno Haible  <bruno@clisp.org>
45174         memcmp: Mention the clang bug.
45175         * tests/test-memcmp.c: Add comment about a known test failure.
45176         * doc/posix-functions/memcmp.texi: Mention the clang bug.
45178 2018-12-20  Jim Meyering  <meyering@fb.com>
45180         revert v0.1-2213-gae4b73e28 and part of v0.1-2281-g95cd86dd7
45181         v0.1-2213-gae4b73e28 caused a regression in grep-3.2 (no match):
45182           echo '123-x'|LC_ALL=C grep -E '.\bx'
45183         The goal is to revert the first, but reverting it requires to restore
45184         the function deleted in the second. I ran this to restore the deleted
45185         function:
45186           git show v0.1-2281-g95cd86dd7 lib/dfa.c \
45187             | perl -0777 -pe 's/^@@[^\n]*dfaan.*//ms' \
45188             | patch -R -p1
45189         * lib/dfa.c (charclass_context): Restore deleted function.
45190         Reverting the primary commit removes this change:
45191         dfa: Simplify a building state
45192         * lib/dfa.c (build_state): Simplify a building state.
45194 2018-12-20  Paul Eggert  <eggert@cs.ucla.edu>
45196         version-etc: allow zero authors
45197         * lib/version-etc.c (version_etc_arn): If no authors are given,
45198         omit authorship info instead of dumping core.
45200 2018-12-19  Bruno Haible  <bruno@clisp.org>
45202         lchown tests: Be more permissive regarding errno values.
45203         Reported by Ivan Zakharyaschev <imz@altlinux.org>.
45204         * tests/test-lchown.h (test_lchown): Recognize EOPNOTSUPP as an
45205         alternative to ENOSYS.
45206         * modules/lchown-tests (Depends-on): Add 'errno'.
45207         * modules/fchownat-tests (Depends-on): Likewise.
45209 2018-12-18  Bruno Haible  <bruno@clisp.org>
45211         duplocale: Avoid test failure on AIX 7.
45212         * modules/duplocale-tests (Files): Add m4/intl-thread-locale.m4.
45213         (configure.ac): Invoke gt_FUNC_USELOCALE.
45214         * tests/test-duplocale.c: Test HAVE_WORKING_USELOCALE instead of
45215         HAVE_USELOCALE. Assume that nl_langinfo_l only works when uselocale
45216         works.
45218 2018-12-18  Bruno Haible  <bruno@clisp.org>
45220         localename: Fix test failure on AIX 7.
45221         Reported by Assaf Gordon in
45222         <https://lists.gnu.org/archive/html/sed-devel/2018-12/msg00019.html>.
45223         * m4/intl-thread-locale.m4 (gt_FUNC_USELOCALE): New macro.
45224         (gt_INTL_THREAD_LOCALE_NAME): Invoke it. Test gt_cv_func_uselocale_works
45225         instead of ac_cv_func_uselocale.
45226         * lib/localename.c: Test HAVE_WORKING_USELOCALE instead of
45227         HAVE_USELOCALE.
45228         * lib/localename-table.h: Likewise.
45229         * lib/localename-table.c: Likewise.
45230         * tests/test-localename.c: Likewise.
45231         * doc/posix-functions/uselocale.texi: Mention the AIX problem.
45233 2018-12-18  Bruno Haible  <bruno@clisp.org>
45235         localename: Update comments regarding Cygwin.
45236         * lib/localename.c: Update comment.
45237         * doc/posix-functions/uselocale.texi: Update platforms list.
45238         * doc/posix-functions/newlocale.texi: Likewise.
45239         * doc/posix-functions/duplocale.texi: Likewise.
45240         * doc/posix-functions/freelocale.texi: Likewise.
45242 2018-12-16  Bruno Haible  <bruno@clisp.org>
45244         c-stack: Fix for Linux/sparc.
45245         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Set
45246         ac_cv_sys_xsi_stack_overflow_heuristic to 'no' on Linux/sparc.
45248 2018-12-16  Bruno Haible  <bruno@clisp.org>
45250         localename: Avoid test failure on some glibc systems.
45251         * tests/test-localename.c (test_locale_name, test_locale_name_posix):
45252         Unset environment variables that might disturb the first setlocale call,
45253         and verify that this setlocale call succeeds.
45255 2018-12-16  Assaf Gordon  <assafgordon@gmail.com>
45257         random: Fix build error on native Windows (regression from 2018-06-21).
45258         * lib/random.c (__srandom, __initstate, __setstate, __random,
45259         __srandom_r, __initstate_r, __setstate_r, __random_r) [!_LIBC]: Redirect
45260         to the symbols without '__' prefix.
45262 2018-12-16  Bruno Haible  <bruno@clisp.org>
45264         obstack, libc-config: Support HP-UX cc in C99 mode.
45265         * lib/obstack.h (__FLEXIBLE_ARRAY_MEMBER): Treat HP-UX cc as a pre-C99
45266         compiler, even when in C99 mode.
45267         * lib/cdefs.h (__flexarr): Likewise.
45268         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Update comment.
45270 2018-12-16  Bruno Haible  <bruno@clisp.org>
45272         localename: Fix test failure on OpenBSD >= 6.2.
45273         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): Test for fake
45274         locale system. Define HAVE_FAKE_LOCALES in this case.
45275         * lib/localename.c (HAVE_GOOD_USELOCALE): New macro. Use it instead of
45276         HAVE_USELOCALE.
45277         * tests/test-localename.c (HAVE_GOOD_USELOCALE): New macro. Use it
45278         instead of HAVE_NEWLOCALE && HAVE_USELOCALE.
45279         * doc/posix-functions/uselocale.texi: Mention OpenBSD problem. Update
45280         platforms list.
45281         * doc/posix-functions/newlocale.texi: Likewise.
45282         * doc/posix-functions/duplocale.texi: Update platforms list.
45283         * doc/posix-functions/freelocale.texi: Likewise.
45285 2018-12-16  Bruno Haible  <bruno@clisp.org>
45287         duplocale tests: Re-enable the test on platforms without <monetary.h>.
45288         * tests/test-duplocale.c: Use more fine-grained #ifs to re-enable most
45289         of the test, on platforms without <monetary.h>.
45291 2018-12-16  Bruno Haible  <bruno@clisp.org>
45293         localename: Update comments.
45294         * lib/localename.c (HAVE_USELOCALE): Update list of platforms.
45296 2018-12-15  Jim Meyering  <meyering@fb.com>
45298         regex: fix indentation
45299         * m4/regex.m4 (gl_REGEX): Indent with spaces, not TABs.
45301 2018-12-15  Bruno Haible  <bruno@clisp.org>
45303         openat-safer tests: Avoid test failure on NetBSD 8.
45304         * tests/test-openat-safer.c (main): Execute a Linux specific test only
45305         on Linux.
45307 2018-12-15  Jim Meyering  <meyering@fb.com>
45309         regex: work around a bug in glibc-2.27 and prior
45310         * m4/regex.m4 (gl_REGEX): Reject any system regexp that gets a failed
45311         assertion for /0|()0|\1|0/.
45312         * tests/test-regex.c (main): Add the same test here.
45314 2018-12-15  Bruno Haible  <bruno@clisp.org>
45316         localename: Fix use of uninitialized shell variable.
45317         * m4/intl-thread-locale.m4 (gt_INTL_THREAD_LOCALE_NAME): Initialize
45318         gt_cv_locale_solaris114 always before use. Remove assignment without
45319         effect.
45321 2018-12-15  Bruno Haible  <bruno@clisp.org>
45323         dfa tests: Avoid test failure on Alpine Linux.
45324         * tests/dfa-match.sh (timeout_10): Accommodate the BusyBox 'timeout'
45325         command found on Alpine Linux.
45327 2018-12-15  Jim Meyering  <meyering@fb.com>
45329         dfa: avoid new warnings from gcc
45330         These would prevent building with -Werror and a Dec snapshot of gcc.
45331         * lib/dfa.c (dfaanalyze): Avoid shadowing warnings for "pos".
45332         Rename each inner instance to "p".
45333         (charclass_context): Remove unused static function.
45335 2018-12-14  Paul Eggert  <eggert@cs.ucla.edu>
45337         mkdir-p: improve diagnostic for FUSE mounts
45338         Problem reported by Niklas Hambüchen in:
45339         https://lists.gnu.org/r/bug-gnulib/2018-12/msg00074.html
45340         * lib/mkdir-p.c (make_dir_parents): In diagnostic, prefer stat
45341         errno to mkdir errno if the stat errno is likely more interesting.
45343 2018-12-14  Bruno Haible  <bruno@clisp.org>
45345         hash-map: Add tests.
45346         * tests/test-hash_map.c: New file.
45347         * modules/hash-map-tests: New file.
45349         linkedhash-map: Add tests.
45350         * tests/test-linkedhash_map.c: New file.
45351         * modules/linkedhash-map-tests: New file.
45353         array-map: Add tests.
45354         * tests/test-array_map.c: New file.
45355         * modules/array-map-tests: New file.
45357         xmap: New module.
45358         * lib/gl_xmap.h: New file.
45359         * lib/gl_xmap.c: New file.
45360         * modules/xmap: New file.
45362         hash-map: New module.
45363         * lib/gl_hash_map.h: New file.
45364         * lib/gl_hash_map.c: New file.
45365         * modules/hash-map: New file.
45367         linkedhash-map: New module.
45368         * lib/gl_linkedhash_map.h: New file.
45369         * lib/gl_linkedhash_map.c: New file.
45370         * lib/gl_anyhash1.h: Update comments.
45371         * lib/gl_anyhash2.h: Likewise.
45372         * modules/linkedhash-map: New file.
45374         array-map: New module.
45375         * lib/gl_array_map.h: New file.
45376         * lib/gl_array_map.c: New file.
45377         * modules/array-map: New file.
45379         map: New module.
45380         * lib/gl_map.h: New file.
45381         * lib/gl_map.c: New file.
45382         * lib/gl_omap.h (gl_mapkey_dispose_fn, gl_mapvalue_dispose_fn): Avoid
45383         conflict with gl_map.h.
45384         * modules/map: New file.
45386 2018-12-13  Bruno Haible  <bruno@clisp.org>
45388         select tests: Avoid test failure on Cygwin.
45389         * tests/test-select.h (test_bad_fd): Use an fd < FD_SETSIZE.
45391 2018-12-13  Bruno Haible  <bruno@clisp.org>
45393         localtime-buffer: Avoid endless recursion in localtime and gmtime.
45394         * lib/localtime-buffer.c: Undefine localtime and gmtime before use.
45396 2018-12-13  Bruno Haible  <bruno@clisp.org>
45398         localeconv tests: Avoid test failure on Cygwin.
45399         * tests/test-localeconv.c (main): On Cygwin, skip the 'grouping' and
45400         'mon_grouping' tests.
45402 2018-12-11  Bruno Haible  <bruno@clisp.org>
45404         omap: Don't dispose the old value when the function returns it.
45405         * lib/gl_array_omap.c (gl_array_remove_at): Don't invoke the vdispose_fn
45406         here.
45407         * lib/gl_avltree_omap.c (NODE_PAYLOAD_DISPOSE): Likewise.
45408         * lib/gl_rbtree_omap.c (NODE_PAYLOAD_DISPOSE): Likewise.
45409         * lib/gl_omap.h (gl_omap_nx_put, gl_omap_remove): Invoke the vdispose_fn
45410         here.
45412         array-omap, avltree-omap, rbtree-omap: Tweak style.
45413         * lib/gl_anytree_omap.h (gl_tree_nx_getput): Return 1 or 0, not true or
45414         false.
45415         * lib/gl_array_omap.c (gl_array_nx_getput): Likewise.
45417         rbtree-omap: Add tests.
45418         * tests/test-rbtree_omap.c: New file.
45419         * modules/rbtree-omap-tests: New file.
45421         avltree-omap: Add tests.
45422         * tests/test-avltree_omap.c: New file.
45423         * modules/avltree-omap-tests: New file.
45425         array-omap: Add tests.
45426         * tests/test-array_omap.c: New file.
45427         * modules/array-omap-tests: New file.
45429         xomap: New module.
45430         * lib/gl_xomap.h: New file.
45431         * lib/gl_xomap.c: New file.
45432         * modules/xomap: New file.
45434         rbtree-omap: New module.
45435         * lib/gl_rbtree_omap.h: New file.
45436         * lib/gl_rbtree_omap.c: New file.
45437         * lib/gl_rbtree_ordered.h: Code moved to here from lib/gl_rbtree_oset.c.
45438         Parameterize.
45439         * lib/gl_rbtree_oset.c: Include gl_rbtree_ordered.h.
45440         * modules/rbtree-omap: New file.
45441         * modules/rbtree-oset (Files): Add lib/gl_rbtree_ordered.h.
45442         (Makefile.am): Add gl_rbtree_ordered.h to lib_SOURCES.
45444         avltree-omap: New module.
45445         * lib/gl_avltree_omap.h: New file.
45446         * lib/gl_avltree_omap.c: New file.
45447         * lib/gl_avltree_ordered.h: Code moved to here from
45448         lib/gl_avltree_oset.c. Parameterize.
45449         * lib/gl_avltree_oset.c: Include gl_avltree_ordered.h.
45450         * lib/gl_anytree_omap.h: New file.
45451         * modules/avltree-omap: New file.
45452         * modules/avltree-oset (Files): Add lib/gl_avltree_ordered.h.
45453         (Makefile.am): Add gl_avltree_ordered.h to lib_SOURCES.
45455         array-omap: New module.
45456         * lib/gl_array_omap.h: New file.
45457         * lib/gl_array_omap.c: New file.
45458         * modules/array-omap: New file.
45460         omap: New module.
45461         * lib/gl_omap.h: New file.
45462         * lib/gl_omap.c: New file.
45463         * modules/omap: New file.
45465 2018-12-11  Bruno Haible  <bruno@clisp.org>
45467         hash-set, linkedhash-set: Reduce code duplication.
45468         * lib/gl_anyhash1.h: Rename from lib/gl_anyhash_list1.h and
45469         lib/gl_anyhash_set1.h.
45470         * lib/gl_anyhash2.h: Rename from lib/gl_anyhash_list2.h and
45471         lib/gl_anyhash_set2.h. Parameterize.
45472         (hash_resize_after_add): New function, from lib/gl_anyhash_set2.h.
45473         * lib/gl_anytreehash_list1.h (hash_resize_after_add): Remove function.
45474         * lib/gl_avltreehash_list.c: Include gl_anyhash1.h instead of
45475         gl_anyhash_list1.h. Include gl_anyhash2.h instead of gl_anyhash_list2.h.
45476         * lib/gl_rbtreehash_list.c: Likewise.
45477         * lib/gl_linkedhash_list.c: Likewise.
45478         (hash_resize_after_add): Remove function.
45479         * lib/gl_linkedhash_set.c: Include gl_anyhash1.h instead of
45480         gl_anyhash_set1.h. Include gl_anyhash2.h instead of gl_anyhash_set2.h.
45481         * gl_hash_set.c: Likewise.
45482         * modules/avltreehash-list (Files, Makefile.am): Update file list.
45483         * modules/rbtreehash-list (Files, Makefile.am): Likewise.
45484         * modules/linkedhash-list (Files, Makefile.am): Likewise.
45485         * modules/linkedhash-set (Files, Makefile.am): Likewise.
45486         * modules/hash-set (Files, Makefile.am): Likewise.
45488 2018-12-11  Bruno Haible  <bruno@clisp.org>
45490         array-set: Optimize.
45491         * lib/gl_array_set.c (gl_array_search, gl_array_remove): Test equals_fn
45492         outside the loop, not inside the loop.
45494 2018-12-11  Bruno Haible  <bruno@clisp.org>
45496         times: Fix tests.
45497         * tests/test-times.c (doublecmp): Implement a total order.
45499 2018-12-11  Bruno Haible  <bruno@clisp.org>
45501         array-set, linkedhash-set, hash-set: Fix tests.
45502         * tests/test-array_set.c (cmp_objects_in_array): New function.
45503         (check_equals): Use it.
45504         * tests/test-hash_set.c: Likewise.
45505         * tests/test-linkedhash_set.c: Likewise.
45507 2018-12-08  Bruno Haible  <bruno@clisp.org>
45509         Fix comments.
45510         * lib/gl_list.h (gl_list_free): Clarify what it does.
45511         * lib/gl_oset.h (gl_oset_free): Likewise.
45512         * lib/gl_set.h (gl_set_free): Likewise.
45513         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Fix typo in comment.
45514         * lib/gl_array_oset.c (gl_array_search_atleast): Likewise.
45515         * lib/gl_anyavltree_list1.h (MAXHEIGHT): Likewise.
45516         * lib/gl_avltree_oset.c (MAXHEIGHT): Likewise.
45518 2018-12-03  Bruno Haible  <bruno@clisp.org>
45520         hash-set: Add tests.
45521         * tests/test-hash_set.c: New file.
45522         * modules/hash-set-tests: New file.
45524         linkedhash-set: Add tests.
45525         * tests/test-linkedhash_set.c: New file.
45526         * modules/linkedhash-set-tests: New file.
45528         array-set: Add tests.
45529         * tests/test-array_set.c: New file.
45530         * modules/array-set-tests: New file.
45532         xset: New module.
45533         * lib/gl_xset.h: New file.
45534         * lib/gl_xset.c: New file.
45535         * modules/xset: New file.
45537         hash-set: New module.
45538         * lib/gl_hash_set.h: New file.
45539         * lib/gl_hash_set.c: New file.
45540         * modules/hash-set: New file.
45542         linkedhash-set: New module.
45543         * lib/gl_linkedhash_set.h: New file.
45544         * lib/gl_linkedhash_set.c: New file.
45545         * lib/gl_anyhash_set1.h: New file, based on lib/gl_anyhash_list1.h.
45546         * lib/gl_anyhash_set2.h: New file, based on lib/gl_anyhash_list2.h.
45547         * lib/gl_anyhash_primes.h: New file, extracted from
45548         lib/gl_anyhash_list2.h.
45549         * lib/gl_anyhash_list2.h: Include it.
45550         (primes, next_prime): Remove definitions.
45551         * modules/linkedhash-set: New file.
45552         * modules/avltreehash-list (Files): Add lib/gl_anyhash_primes.h.
45553         (Makefile.am): Add gl_anyhash_primes.h to lib_SOURCES.
45554         * modules/linkedhash-list (Files): Add lib/gl_anyhash_primes.h.
45555         (Makefile.am): Add gl_anyhash_primes.h to lib_SOURCES.
45556         * modules/rbtreehash-list (Files): Add lib/gl_anyhash_primes.h.
45557         (Makefile.am): Add gl_anyhash_primes.h to lib_SOURCES.
45559         array-set: New module.
45560         * lib/gl_array_set.h: New file.
45561         * lib/gl_array_set.c: New file.
45562         * modules/array-set: New file.
45564         set: New module.
45565         * lib/gl_set.h: New file.
45566         * lib/gl_set.c: New file.
45567         * lib/gl_oset.h (gl_setelement_dispose_fn): Avoid conflict with
45568         gl_set.h.
45569         * modules/set: New file.
45571 2018-12-07  Akim Demaille  <akim@lrde.epita.fr>
45573         bison: don't force the Yacc mode
45574         Passing -y forces Bison into POSIX YACC mode.  This includes reporting
45575         errors when Bison features are used in the grammar file.  Some of
45576         these features (such as %expect) were flagged non-yacc recently.  Most
45577         of the time, -y is actually used to please Automake's ylwrap which
45578         expects the output to be y.tab.c.
45579         * m4/bison.m4 (gl_BISON): Use `-o y.tab.c` rather than `-y`.
45581 2018-12-01  Bruno Haible  <bruno@clisp.org>
45583         gnupload: Document short options.
45584         * build-aux/gnupload (usage): Document the short options.
45586 2018-11-28  Ben Elliston  <bje@gnu.org>
45588         gnupload: Support option -h as alias of --help.
45589         * build-aux/gnupload: Support -h.
45591 2018-11-30  Paul Eggert  <eggert@cs.ucla.edu>
45593         memrchr: port better to clang
45594         * lib/memrchr.c (__memrchr): Cast to void * instead of to
45595         longword *, to pacify clang -Wcast-align (Bug#33544).
45597 2018-11-29  Eric Blake  <eblake@redhat.com>
45599         docs: mention printf %m considerations
45600         * doc/glibc-functions/asprintf.texi (asprintf): Document that %m
45601         is not portable, and is easy enough to work around.
45602         * doc/glibc-functions/obstack_printf.texi (obstack_printf): Likewise.
45603         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf): Likewise.
45604         * doc/glibc-functions/vasprintf.texi (vasprintf): Likewise.
45605         * doc/posix-functions/dprintf.texi (dprintf): Likewise.
45606         * doc/posix-functions/fprintf.texi (fprintf): Likewise.
45607         * doc/posix-functions/fwprintf.texi (fwprintf): Likewise.
45608         * doc/posix-functions/printf.texi (printf): Likewise.
45609         * doc/posix-functions/snprintf.texi (snprintf): Likewise.
45610         * doc/posix-functions/sprintf.texi (sprintf): Likewise.
45611         * doc/posix-functions/swprintf.texi (swprintf): Likewise.
45612         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
45613         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
45614         * doc/posix-functions/vfwprintf.texi (vfwprintf): Likewise.
45615         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
45616         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
45617         * doc/posix-functions/vsprintf.texi (vsprintf): Likewise.
45618         * doc/posix-functions/vswprintf.texi (vswprintf): Likewise.
45619         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
45620         * doc/posix-functions/wprintf.texi (wprintf): Likewise.
45622 2018-11-29  Akim Demaille  <akim@lrde.epita.fr>
45624         bitset: rename ebitset/expandable.* as tbitset/table.*
45625         See
45626         https://lists.gnu.org/archive/html/bug-gnulib/2018-11/msg00096.html.
45627         * lib/bitset/expandable.h, lib/bitset/expandable.c: Rename as...
45628         * lib/bitset/table.h, lib/bitset/table.c: these.
45629         Rename all the ebitset* symbols as tbitset*.
45630         Adjust dependencies.
45632 2018-11-28  Akim Demaille  <akim@lrde.epita.fr>
45634         bitset: check the operations
45635         * tests/test-bitset.c (bitset_random): New.
45636         Use it.
45637         * lib/bitset/expandable.c (ebitset_not): Fix typo.
45639 2018-11-28  Akim Demaille  <akim@lrde.epita.fr>
45641         bitset: properly use false/true instead of 0/1 for Booleans
45642         * lib/bitset/expandable.c, lib/bitset/vector.c: Use false/true, not
45643         0/1, as Booleans.
45645 2018-11-28  Akim Demaille  <akim@lrde.epita.fr>
45647         bitset: rename BITSET_VARRAY as BITSET_VECTOR
45648         For consistency with the name of the file.
45649         * doc/bitset.texi, lib/bitset.c, lib/bitset/base.h,
45650         * lib/bitset/stats.c, lib/bitset/vector.c
45651         (BITSET_VARRAY): Rename as...
45652         (BITSET_VECTOR): this.
45654 2018-11-28  Paul Eggert  <eggert@cs.ucla.edu>
45656         strerror_r-posix: memmove, not memcpy
45657         * lib/strerror_r.c (safe_copy): Use memmove, not memcpy,
45658         since the source and destination might overlap in the call
45659         ‘safe_copy (buf, buflen, strerror_r (errnum, buf, buflen))’.
45660         Simplify.
45662 2018-11-25  Akim Demaille  <akim@lrde.epita.fr>
45664         bitsetv: new module
45665         * lib/bitsetv.c, lib/bitsetv.h, modules/bitsetv: New.
45667 2018-11-25  Akim Demaille  <akim@lrde.epita.fr>
45669         bitset: add tests and doc
45670         First stabs at providing a documentation and test for the bitset
45671         module.
45672         * doc/bitset.texi, modules/test-bitset, tests/bitset-tests.c: New.
45674 2018-11-25  Akim Demaille  <akim@lrde.epita.fr>
45676         bitset: new module
45677         * lib/bitset.c, lib/bitset.h, lib/bitset/array.c,
45678         * lib/bitset/array.h, lib/bitset/base.h, lib/bitset/expandable.c,
45679         * lib/bitset/expandable.h, lib/bitset/list.c, lib/bitset/list.h,
45680         * lib/bitset/stats.c, lib/bitset/stats.h, lib/bitset/vector.c,
45681         * lib/bitset/vector.h, modules/bitset:
45682         New.
45684 2018-11-23  Bruno Haible  <bruno@clisp.org>
45686         localename: Fix gettext test failures on mingw.
45687         * lib/localename.c (gl_locale_name_posix): Convert the result of
45688         gl_locale_name_environ to XPG syntax.
45690 2018-11-23  Karl Berry  <karl@freefriends.org>
45692         * config/srclistvars.txt,
45693         * config/srclist.txt: remove all gettext references;
45694         the gettext maintainers will sync as needed.
45696 2018-11-21  Paul Eggert  <eggert@cs.ucla.edu>
45698         mktime: add libc-config dependency
45699         I missed this when we synced from glibc.
45700         * modules/mktime (Depends-on): Add libc-config.
45702 2018-11-13  Paul Eggert  <eggert@cs.ucla.edu>
45704         longlong: fix comment typo
45705         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Fix typo.
45707 2018-11-11  Bruno Haible  <bruno@clisp.org>
45709         havelib: Remove the need to include asm-underscore.m4.
45710         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI_32BIT): New macro.
45711         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Use it instead of
45712         gl_HOST_CPU_C_ABI.
45713         * modules/havelib (Files): Add host-cpu-c-abi.m4.
45714         (Depends-on): Remove host-cpu-c-abi.
45716 2018-11-03  Paul Eggert  <eggert@cs.ucla.edu>
45718         parse-datetime: simplify test for mktime failure
45719         * lib/parse-datetime.y (mktime_ok): Simplify.
45720         Remove args TZ and T; no longer needed.  Callers changed.
45722         posixtm: simplify test for mktime failure
45723         * lib/posixtm.c (posixtime): Simplify.
45725         nstrftime: simplify test for mktime failure
45726         * lib/nstrftime.c (__strftime_internal): Simplify.
45728 2018-11-02  Paul Eggert  <eggert@cs.ucla.edu>
45730         gnulib-common.m4: port _Noreturn to C++
45731         Problem reported by Akim Demaille in:
45732         https://lists.gnu.org/r/bug-bison/2018-10/msg00067.html
45733         * m4/gnulib-common.m4 (gl_COMMON_BODY): If C++, use [[noreturn]].
45734         Merge adjustments from _Noreturn.h and from glibc into the non-C++
45735         version.
45736         * lib/_Noreturn.h: Match gnulib-common.
45738 2018-10-30  Bruno Haible  <bruno@clisp.org>
45740         gnu-make: Fix for NetBSD 8 'make'.
45741         Reported by Reuben Thomas in
45742         <https://lists.gnu.org/archive/html/bug-gnulib/2018-10/msg00135.html>.
45743         * m4/gnu-make.m4 (gl_GNU_MAKE): Use a heuristic based on the --version
45744         output, ignoring exit codes.
45746 2018-10-28  Bernhard Voelker  <mail@bernhard-voelker.de>
45748         maintainer-makefile: fix syntax-check rule for "same.h"
45749         * top/maint.mk (sc_prohibit_same_without_use): Adjust regex to check
45750         for 'same_nameat', too.
45752 2018-10-25  Paul Eggert  <eggert@cs.ucla.edu>
45754         havelib: fix nested ‘configure’ chatter
45755         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Don’t nest
45756         AC_CACHE_CHECK calls, which resulted in confusing output like
45757         “checking for the common suffixes of directories in the library
45758         search path... checking for 64-bit host... no lib,lib”.
45760         backupfile: tweak for better code
45761         * lib/backupfile.c: Sort include directives, and remove
45762         unnecessary <limits.h> include.
45763         (FALLTHROUGH): New macro, copied from other modules.
45764         (backupfile_internal): Use it to avoid code duplication.
45765         This lets GCC 8.2.1 generate better code by inlining the
45766         call to check_extension.
45768 2018-10-23  Paul Eggert  <eggert@cs.ucla.edu>
45770         backupfile: new dir_fd args
45771         New module opendirat with code taken from fts.
45772         Use this module to let backupfile use a directory file descriptor.
45773         * NEWS: Document the incompatible change.
45774         * lib/backup-find.c (find_backup_file_name):
45775         * lib/backup-rename.c (backup_file_rename):
45776         New arg DIR_FD.
45777         * lib/backupfile.c: Include stdint.h, for SIZE_MAX.
45778         (SIZE_MAX): Remove.
45779         Include opendirat.h rather than dirent--.h.
45780         (check_extension): New args DIR_FD and BASE_MAX.  All callers changed.
45781         (numbered_backup): New args DIR_FD and PNEW_FD.  All callers changed.
45782         (backupfile_internal): New arg DIR_FD.  All callers changed.
45783         * lib/fts.c: Include opendirat.h.
45784         (opendirat): Move to opendirat.c.
45785         * lib/opendirat.c, lib/opendirat.h, modules/opendirat: New files.
45786         * modules/backupfile (Depends-on): Remove dirfd, opendir.
45787         Add opendirat.
45788         * modules/fts (Depends-on): Remove fdopendir, openat-safer.
45789         Add opendirat.
45791 2018-10-23  Bruno Haible  <bruno@clisp.org>
45793         localename: Simplify support for per-thread locales on Solaris 11.4.
45794         * m4/intl-thread-locale.m4: Renamed from m4/intlsolaris.m4.
45795         (gt_INTL_THREAD_LOCALE_NAME): Renamed from gt_INTL_SOLARIS. Define
45796         HAVE_SOLARIS114_LOCALES instead of HAVE_NAMELESS_LOCALES.
45797         * lib/localename.c: Handle HAVE_SOLARIS114_LOCALES through Solaris
45798         specific code.
45799         * lib/localename-table.h: Update comments.
45800         * lib/localename-table.c: Update comments.
45801         * m4/localename.m4 (gl_LOCALENAME): Require gt_INTL_THREAD_LOCALE_NAME.
45802         Test for 'uselocale'. Don't invoke gt_INTL_SOLARIS.
45803         * m4/intl.m4 (AM_INTL_SUBDIR): Require gt_INTL_THREAD_LOCALE_NAME. Test
45804         for 'uselocale'. Set HAVE_NAMELESS_LOCALES.
45805         (gt_INTL_SUBDIR_CORE): Don't invoke gt_INTL_SOLARIS. Don't set
45806         HAVE_NAMELESS_LOCALES here.
45807         * modules/localename (Files): Add m4/intl-thread-locale.m4. Remove
45808         m4/intlsolaris.m4.
45809         * modules/gettext (Files): Likewise.
45811 2018-10-22  Bruno Haible  <bruno@clisp.org>
45813         std-gnu11: Support Autoconf versions < 2.64.
45814         * m4/std-gnu11.m4 (AC_PROG_CC, AC_PROG_CXX): Use _AC_DO as fallback
45815         when _AC_DO_LIMIT does not exist.
45817 2018-10-22  Bruno Haible  <bruno@clisp.org>
45819         Assume Autoconf >= 2.63.
45820         * DEPENDENCIES: Mention the requirement.
45822         * gnulib-tool (DEFAULT_AUTOCONF_MINVERSION): Bump to 2.63.
45823         (func_get_filelist): Don't list m4/onceonly.m4 any more.
45824         * pygnulib/GLModuleSystem.py (getFiles): Likewise.
45825         * m4/onceonly.m4: Remove file.
45827         * m4/openmp.m4: Remove file.
45828         * modules/openmp (Files): Remove m4/openmp.m4.
45830         * m4/configmake.m4 (gl_CONFIGMAKE_PREP): Don't set datarootdir, docdir,
45831         htmldir, dvidir, pdfdir, psdir, localedir.
45832         * m4/po.m4 (AM_PO_SUBDIRS): Don't set localedir.
45834         * m4/gnulib-common.m4 (m4_foreach_w): Remove fallback for
45835         Autoconf < 2.60.
45836         (AC_PROG_MKDIR_P): Remove definition for Autoconf < 2.62.
45837         (AC_PROG_SED): Remove fallback for Autoconf < 2.60.
45839         * m4/errno_h.m4 (AC_COMPUTE_INT): Remove fallback for Autoconf < 2.61.
45840         * m4/size_max.m4 (AC_COMPUTE_INT): Likewise.
45841         * m4/stdint.m4 (AC_COMPUTE_INT): Likewise.
45843         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Assume AC_USE_SYSTEM_EXTENSIONS
45844         exists.
45845         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Likewise,
45847         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Remove workaround for
45848         Autoconf < 2.61.
45850         * m4/lib-prefix.m4 (AC_LIB_ARG_WITH): Remove macro.
45851         (AC_LIB_PREFIX): Use AC_ARG_WITH, assuming semantics of
45852         Autoconf >= 2.52.
45854         * m4/longlong.m4: Require Autoconf >= 2.62. Update comments.
45855         * m4/ls-mntd-fs.m4: Require Autoconf >= 2.60. Update comments.
45856         * m4/gettext.m4 (AM_GNU_GETTEXT): Update comment.
45858 2018-10-22  Bruno Haible  <bruno@clisp.org>
45860         Assume Automake >= 1.11.
45861         * m4/configmake.m4: Update comments.
45862         * m4/lib-link.m4 (AC_LIB_RPATH): Assume AC_REQUIRE_AUX_FILE exists.
45863         * m4/po.m4 (AM_PO_SUBDIRS, AM_POSTPROCESS_PO_MAKEFILE): Eliminate uses
45864         of 'eval'.
45865         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am,
45866         func_create_testdir, func_create_megatestdir): Emit a Makefile.am that
45867         requires Automake >= 1.11.
45869 2018-10-22  Bruno Haible  <bruno@clisp.org>
45871         localename: Fix typo in comment.
45872         * tests/test-locale-c++.cc (newlocale): Fix typo in comment.
45874 2018-10-22  Bruno Haible  <bruno@clisp.org>
45876         Fix failure of 'gnulib-tool --create-testdir' with all modules.
45877         * gnulib-tool (func_create_testdir): Exclude 'timevar' module.
45879 2018-10-21  Bruno Haible  <bruno@clisp.org>
45881         locale: Ease integration with GNU libintl.
45882         * lib/locale.in.h (GNULIB_defined_newlocale, GNULIB_defined_duplocale,
45883         GNULIB_defined_freelocale): New macros.
45885 2018-10-21  Bruno Haible  <bruno@clisp.org>
45887         localename: Fine-tune support for per-thread locales on Solaris 11.4.
45888         * lib/localename-table.h: New file, extracted from lib/localename.c.
45889         * lib/localename-table.c: Likewise.
45890         * lib/localename.c: Include localename-table.h.
45891         (get_locale_t_name, newlocale, duplocale, freelocale): Invoke
45892         locale_hash_function instead of pointer_hash.
45893         * modules/localename (Files): Add lib/localename-table.h,
45894         lib/localename-table.c.
45895         (lib_SOURCES): Add localename-table.c.
45896         * m4/intlsolaris.m4 (gt_INTL_SOLARIS): Require AC_CANONICAL_HOST. Test
45897         for Solaris 11.4 locale system only on Solaris. Test for it
45898         independently whether getlocalename_l exists.
45899         * m4/intl.m4 (gt_INTL_SUBDIR_CORE): Don't test for 'uselocale' and
45900         'getlocalename_l'. Instead, invoke gt_INTL_SOLARIS. Set
45901         HAVE_NAMELESS_LOCALES.
45902         * modules/gettext (Files): Add m4/intlsolaris.m4.
45904 2018-10-21  Bruno Haible  <bruno@clisp.org>
45906         Small update from gettext.
45907         * m4/intl.m4: Update from gettext:
45908         - 2018-01-02: Fix 'ar' invocation when cross-compiling and in 64-bit
45909         mode on AIX.
45910         - 2018-01-02: Don't use -lc explicitly when linking with libtool.
45911         - 2017-05-19: (AM_INTL_SUBDIR): Require AC_C_FLEXIBLE_ARRAY_MEMBER.
45913 2018-10-16  Bruno Haible  <bruno@clisp.org>
45915         mountlist: Remove support for Cray with UNICOS 9.
45916         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't define
45917         MOUNTED_LISTMNTENT.
45918         * lib/mountlist.c: Remove MOUNTED_LISTMNTENT case.
45920 2018-10-16  Bruno Haible  <bruno@clisp.org>
45922         fsusage, mountlist, getloadavg, getgroups: Remove support for Ultrix.
45923         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't define
45924         STAT_STATFS2_FS_DATA.
45925         * lib/fsusage.c: Remove STAT_STATFS2_FS_DATA case.
45926         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't define
45927         MOUNTED_GETMNT.
45928         * lib/mountlist.c: Remove MOUNTED_GETMNT case.
45929         * lib/getloadavg.c (decstation): Remove definition and case.
45930         * m4/getgroups.m4 (AC_FUNC_GETGROUPS): Mention NeXTstep, not Ultrix.
45931         * lib/getgroups.c: Likewise.
45932         * doc/posix-functions/getgroups.texi: Likewise.
45933         * lib/time.in.h: Update comments.
45935 2018-10-16  Bruno Haible  <bruno@clisp.org>
45937         getloadavg: Remove support for ConvexOS.
45938         * lib/getloadavg.c: Remove convex case.
45940 2018-10-16  Bruno Haible  <bruno@clisp.org>
45942         getloadavg: Remove support for Sony NEWS.
45943         * lib/getloadavg.c: Remove sony_news case.
45945 2018-10-16  Bruno Haible  <bruno@clisp.org>
45947         fsusage, mountlist, getloadavg: Remove support for Dynix/ptx.
45948         * lib/fsusage.c: Remove _SEQUENT_ case.
45949         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Update comments.
45950         * lib/mountlist.c: Don't test for MNTTABNAME.
45951         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Don't test for libseq.
45952         (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't test for MNTTABNAME.
45953         * lib/getloadavg.c: Remove _SEQUENT_ and sequent cases.
45954         * lib/stat-size.h: Don't mention the Sequent bug.
45955         * doc/posix-functions/utime.texi: Don't mention the Dynix bug.
45957 2018-10-16  Bruno Haible  <bruno@clisp.org>
45959         fsusage: Remove support for AIX 3.
45960         * lib/fsusage.c: Remove code for AIX 3.
45961         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Update comments.
45963 2018-10-16  Bruno Haible  <bruno@clisp.org>
45965         fsusage, stat-size, getloadavg: Remove support for AIX PS/2.
45966         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for dustat.h.
45967         * lib/fsusage.c: Remove code for AIX PS/2.
45968         * lib/stat-size.h (ST_NBLOCKSIZE): Likewise.
45969         * lib/getloadavg.c: Likewise.
45971 2018-10-16  Bruno Haible  <bruno@clisp.org>
45973         getloadavg: Remove support for HP-UX on m68k.
45974         * lib/getloadavg.c: Remove hp9000s300 case.
45976 2018-10-16  Bruno Haible  <bruno@clisp.org>
45978         fsusage, mountlist: Remove support for DolphinOS (an SVR3 variant).
45979         * lib/fsusage.c: Remove DOLPHIN case.
45980         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Update comments.
45981         * lib/mountlist.c: Remove MOUNTED_GETMNTTBL case.
45983 2018-10-16  Bruno Haible  <bruno@clisp.org>
45985         getloadavg: Remove support for Alliant FX/2800.
45986         * lib/getloadavg.c: Remove alliant case.
45988 2018-10-16  Bruno Haible  <bruno@clisp.org>
45990         getloadavg: Remove support for tek4300.
45991         * lib/getloadavg.c: Remove tek4300 case.
45993 2018-10-16  Bruno Haible  <bruno@clisp.org>
45995         getloadavg: Remove support for Ardent.
45996         * lib/getloadavg.c: Remove ardent case.
45998 2018-10-16  Bruno Haible  <bruno@clisp.org>
46000         mountlist: Remove support for SVR2.
46001         Reported by Andrew Borodin <aborodin@vmail.ru> in
46002         <https://lists.gnu.org/archive/html/bug-gnulib/2018-10/msg00101.html>.
46003         * lib/mountlist.c: Remove MOUNTED_FREAD case.
46004         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't define
46005         MOUNTED_FREAD.
46007 2018-10-15  Paul Eggert  <eggert@cs.ucla.edu>
46009         libc-config: merge from glibc
46010         * lib/cdefs.h (__glibc_has_attribute): New macro.
46012         regex: depend on libc-config
46013         * modules/regex (Depends-on): Add libc-config.
46014         This is needed after the recent autoupdate from glibc.
46016 2018-10-14  Bruno Haible  <bruno@clisp.org>
46018         localename: Add support for per-thread locales on Solaris 11.4.
46019         * lib/locale.in.h (newlocale, freelocale): New declarations.
46020         (duplocale): Declare also when the 'localename' module requests it.
46021         * lib/localename.c (struniq_hash_node): Renamed from hash_node.
46022         (STRUNIQ_HASH_TABLE_SIZE): Renamed from HASH_TABLE_SIZE.
46023         (struniq): Update.
46024         (struct locale_categories_names, struct locale_hash_node): New types.
46025         (LOCALE_HASH_TABLE_SIZE): New constant.
46026         (locale_hash_table, locale_lock): New variables.
46027         (pointer_hash, get_locale_t_name): New functions.
46028         (newlocale, duplocale, freelocale): New overridden functions.
46029         (gl_locale_name_thread_unsafe): Use get_locale_t_name.
46030         * m4/intlsolaris.m4: New file.
46031         * m4/localename.m4 (gl_LOCALENAME): Require gl_LOCALE_H_DEFAULTS. Invoke
46032         gt_INTL_SOLARIS. Set HAVE_NEWLOCALE, HAVE_DUPLOCALE, HAVE_FREELOCALE,
46033         REPLACE_NEWLOCALE, REPLACE_DUPLOCALE, REPLACE_FREELOCALE.
46034         * m4/locale_h.m4 (gl_LOCALE_H): Test whether newlocale, freelocale are
46035         declared.
46036         (gl_LOCALE_H_DEFAULTS): Initialize GNULIB_LOCALENAME, HAVE_NEWLOCALE,
46037         HAVE_FREELOCALE, REPLACE_NEWLOCALE, REPLACE_FREELOCALE.
46038         * modules/locale (Makefile.am): Substitute GNULIB_LOCALENAME,
46039         HAVE_NEWLOCALE, HAVE_FREELOCALE, REPLACE_NEWLOCALE, REPLACE_FREELOCALE.
46040         * modules/localename (Files): Add intlsolaris.m4.
46041         (Depends-on): Add 'locale'.
46042         (configure.ac): Invoke gl_LOCALE_MODULE_INDICATOR.
46043         * tests/test-locale-c++.cc (newlocale, freelocale): Prepare for checking
46044         the signatures.
46046 2018-10-14  Akim Demaille  <akim@lrde.epita.fr>
46048         timevar: use gethrxtime to get wall clock time
46049         clock_gettime is not portable.  gethrxtime takes the best available
46050         option to get the wall clock time, including clock_gettime (monotonic
46051         clock), and gettime (non monotonic).
46052         Also, using xtime_t instead of float preserves the precision.
46053         Suggested by Bruno Haible.
46054         * lib/xtime.h (xtime_make): Handle overflows of nanoseconds.
46055         * modules/timevar (Depends-on): We need gethrxtime.
46056         We no longer use times().
46057         (Link): Update.
46058         * lib/timevar.h (timevar_time_def): Use xtime_t.
46059         * lib/timevar.c (set_to_current_time): Use gethrxtime.
46060         (timevar_print): Instead of checking whether the timings themselves
46061         are large enough for the timevar to be printed, check the percentages.
46063 2018-10-14  Bruno Haible  <bruno@clisp.org>
46065         wcsnrtombs: Work around Solaris 11.4 bug.
46066         * m4/wcsnrtombs.m4 (gl_WCSNRTOMBS_WORKS_IN_TRADITIONAL_LOCALE): New
46067         macro.
46068         (gl_FUNC_WCSNRTOMBS): Invoke it.
46069         * doc/posix-functions/wcsnrtombs.texi: Mention the Solaris bug.
46071 2018-10-14  Bruno Haible  <bruno@clisp.org>
46073         mbsnrtowcs: Work around Solaris 11.4 bug.
46074         * m4/mbsnrtowcs.m4 (gl_MBSNRTOWCS_WORKS_IN_TRADITIONAL_LOCALE): New
46075         macro.
46076         (gl_FUNC_MBSNRTOWCS): Invoke it.
46077         * doc/posix-functions/mbsnrtowcs.texi: Mention the Solaris bug.
46079 2018-10-14  Bruno Haible  <bruno@clisp.org>
46081         doc: Update for Solaris 11.4.
46082         * doc/**/*.texi: For bugs that exist in both Solaris 11.3 and 11.4,
46083         mention Solaris 11.4.
46084         * m4/printf.m4: Update comments about Solaris.
46085         * m4/log.m4: Likewise.
46086         * m4/log10.m4: Likewise.
46087         * m4/logb.m4: Likewise.
46088         * m4/logbf.m4: Likewise.
46089         * m4/logbl.m4: Likewise.
46090         * m4/rename.m4: Likewise.
46091         * m4/wcrtomb.m4: Likewise.
46092         * m4/hostent.m4: Likewise.
46093         * m4/servent.m4: Likewise.
46095 2018-10-14  Bruno Haible  <bruno@clisp.org>
46097         floor, ceil, trunc, truncf, truncl: Defeat GCC optimizations.
46098         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Use 'floor' also through a function
46099         pointer.
46100         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Use 'ceil' also through a function
46101         pointer.
46102         * m4/trunc.m4 (gl_FUNC_TRUNC): Use 'trunc' also through a function
46103         pointer.
46104         * m4/truncf.m4 (gl_FUNC_TRUNCF): Use 'truncf' also through a function
46105         pointer.
46106         * m4/truncl.m4 (gl_FUNC_TRUNCL): Use 'truncl' also through a function
46107         pointer.
46109 2018-10-13  Akim Demaille  <akim@lrde.epita.fr>
46111         bootstrap: fix wget command for po files.
46112         * build-aux/bootstrap (po_download_command_format): Fix comment,
46113         and adjust callers.
46115 2018-10-13  Akim Demaille  <akim@lrde.epita.fr>
46117         timevar: improve the output format
46118         Suggested by Bruno Haible.
46119         See https://lists.gnu.org/archive/html/bug-gnulib/2018-10/msg00040.html.
46120         * lib/timevar.c (timevar_print): Use %7.3f for usr/sys and %11.6f for
46121         wall, since its resolution is much higher.
46123 2018-10-13  Akim Demaille  <akim@lrde.epita.fr>
46125         timevar: expect that getrusage is available.
46126         Don't keep both times and getrusage as backend: both are guaranteed by
46127         gnulib, a single one suffices.  Using getrusage is open to possibly
46128         tracking other types of resources in the future.
46129         * modules/timevar (Depends-on): Add getrusage.
46130         (configure.ac): Remove gl_TIMEVAR.
46131         (Files): Remove m4/timevar.m4.
46132         * m4/timevar.m4: Remove, rely on gnulib for getrusage.
46133         * lib/timevar.h (timevar_enabled): Clarify documentation.
46134         * lib/timevar.c: Remove all the code about times.
46135         Remove all the CPP guards about getrusage: expect it to be present
46136         (courtesy of gnulib).
46138 2018-10-12  Bruno Haible  <bruno@clisp.org>
46140         mountlist: Improve support for Solaris in 64-bit mode.
46141         Reported by David Wood <David.Wood@deshaw.com> in
46142         <https://debbugs.gnu.org/cgi/bugreport.cgi?bug=6816>.
46143         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): On Solaris 8 or
46144         newer, define MOUNTED_GETEXTMNTENT instead of MOUNTED_GETMNTENT2.
46145         * lib/mountlist.c: Add code for MOUNTED_GETEXTMNTENT case.
46147 2018-10-12  Bruno Haible  <bruno@clisp.org>
46149         mountlist: Add support for Minix.
46150         Reported by Assaf Gordon in
46151         <https://lists.gnu.org/archive/html/bug-gnulib/2014-09/msg00074.html>.
46152         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use
46153         AC_CHECK_FUNCS to check for 'getmntinfo'.
46154         * lib/mountlist.c: Update comments.
46156 2018-10-12  Bruno Haible  <bruno@clisp.org>
46158         Make better use of Autoconf.
46159         * m4/environ.m4: Use AC_CACHE_CHECK where possible.
46160         * m4/manywarnings.m4: Likewise.
46161         * m4/manywarnings-c++.m4: Likewise.
46162         * m4/socklen.m4: Likewise.
46163         * m4/sockpfaf.m4: Likewise.
46164         * m4/stdarg.m4: Likewise.
46165         * m4/visibility.m4: Likewise.
46166         * m4/fsusage.m4: Use AC_CACHE_CHECK where possible. Modernize
46167         indentation.
46168         * m4/ls-mntd-fs.m4: Likewise.
46170 2018-10-11  Bruno Haible  <bruno@clisp.org>
46172         mountlist: Modernize platform lists.
46173         * m4/ls-mntd-fs.m4: Clarify which MOUNTED_* symbol applies to which
46174         platforms, deemphasizing the obsolete ones.
46175         * lib/mountlist.c: Likewise.
46177 2018-10-11  Bruno Haible  <bruno@clisp.org>
46179         getprogname: Add support for 32-bit programs on HP-UX.
46180         * lib/getprogname.c (getprogname) [HP-UX]: If pstat_getproc fails,
46181         try the similar functions 32-bit programs on 64-bit HP-UX.
46183 2018-10-11  Bruno Haible  <bruno@clisp.org>
46185         getprogname: Work around program name truncation when possible.
46186         * lib/getprogname.c (getprogname) [HP-UX]: When pst_ucomm is truncated,
46187         possibly use pst_cmd instead.
46189 2018-10-08  Paul Eggert  <eggert@cs.ucla.edu>
46191         fts: cleanup after FTS_NOATIME removal
46192         * lib/fts_.h (FTS_VERBATIM, FTS_OPTIONMASK, FTS_NAMEONLY)
46193         (FTS_STOP): Shrink to minimal values.  We don’t need to
46194         worry about binary compatibility in Gnulib, and the old way
46195         of doing things had a hole in the user options that caused
46196         FTS_OPTIONMASK to not work as desired.
46198 2018-10-08  Bernhard Voelker  <mail@bernhard-voelker.de>
46200         fts: remove FTS_NOATIME
46201         This reverts commit da4d6974013c822af1498941e32db774b2031765.
46202         We cannot guarantee that O_NOATIME works: e.g. openat fails
46203         with EPERM if the effective user ID of the caller does not match
46204         the owner of the file and the caller is not privileged.
46205         Downstream findutils has never picked up FTS_NOATIME.  Discussed at
46206         <https://lists.gnu.org/r/bug-gnulib/2018-09/msg00122.html>.
46207         * lib/fts_.h (FTS_NOATIME): Remove bit flag.
46208         (FTS_OPTIONMASK): Adjust.
46209         * lib/fts.c (diropen, fts_open, fts_build): Likewise.
46210         (fd_ring_check): Likewise.
46212 2018-10-08  Bruno Haible  <bruno@clisp.org>
46214         csharpcomp*, csharpexec*: Remove support for pnet.
46215         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Don't test for cscc. Don't set
46216         HAVE_CSCC.
46217         * build-aux/csharpcomp.sh.in (options_cscc): Remove variable.
46218         Don't test HAVE_CSCC.
46219         * lib/csharpcomp.c (compile_csharp_using_pnet): Remove function.
46220         (compile_csharp_class): Don't invoke it.
46221         * m4/csharpexec.m4 (gt_CSHARPEXEC): Don't test for ilrun. Don't set
46222         HAVE_ILRUN.
46223         * build-aux/csharpexec.sh.in (options_ilrun): Remove variable.
46224         Don't test HAVE_ILRUN.
46225         * lib/csharpexec.c (execute_csharp_using_pnet): Remove function.
46226         (execute_csharp_program): Don't invoke it.
46227         * m4/csharp.m4 (gt_CSHARP_CHOICE): Don't recognize --enable-csharp=pnet
46228         any more.
46230 2018-10-07  Andreas Henriksson  <andreas@fatal.se>  (tiny change)
46232         renameatu: prefer renameat2 to syscall
46233         * lib/renameatu.c (renameatu) [HAVE_RENAMEAT2]:
46234         Use renameat2 instead of syscall (Bug#32796).
46235         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Check for renameat2.
46237 2018-10-07  Benno Schulenberg  <bensberg@telfort.nl>
46239         bootstrap, gnulib-tool: use https instead of insecure rsync
46240         * build-aux/bootstrap (download_po_files, po_download_command_format):
46241         Don't try using rsync; always use wget over https to fetch PO files.
46242         * gnulib-tool (func_import): Likewise.
46243         * pygnulib/GLImport.py (GLImport.execute): Likewise.
46245 2018-10-07  Benno Schulenberg  <bensberg@telfort.nl>
46247         bootstrap, gnulib-tool: correct the translations wget command
46248         * build-aux/bootstrap (po_download_command_format2): Restrict
46249         recursion to a single level.
46250         * gnulib-tool (func_import): Likewise.
46251         * pygnulib/GLImport.py (GLImport.execute): Likewise.
46253 2018-10-07  Akim Demaille  <akim@lrde.epita.fr>
46255         doc: the gnulib snapshots are not maintained
46256         * doc/gnulib-intro.texi (Steady Development): Don't mention them.
46258 2018-10-07  Akim Demaille  <akim@lrde.epita.fr>
46260         timevar: add to lib_SOURCES
46261         * modules/timevar (lib_SOURCES): Add timevar.c and timevar.def.
46263 2018-10-07  Bruno Haible  <bruno@clisp.org>
46265         dirent: Update documentation.
46266         * doc/posix-headers/dirent.texi: The MSVC issue is fixed by Gnulib.
46268 2018-10-05  Bruno Haible  <bruno@clisp.org>
46270         strpbrk: Make it possible to namespace the defined symbol.
46271         * lib/strpbrk.c (strpbrk): Don't undefine outside of glibc.
46273 2018-10-05  Bruno Haible  <bruno@clisp.org>
46275         strcspn: Make it possible to namespace the defined symbol.
46276         * lib/strcspn.c (strcspn): Don't undefine outside of glibc.
46278 2018-10-05  Bruno Haible  <bruno@clisp.org>
46280         raise: Make it possible to namespace the defined symbol.
46281         * lib/raise.c (raise): Undefine only after the replacement function has
46282         been defined.
46283         (raise): Renamed from rpl_raise.
46284         (raise_nothrow): Move to the end of the compilation unit.
46286 2018-10-05  Bruno Haible  <bruno@clisp.org>
46288         memcmp: Make it possible to namespace the defined symbol.
46289         * lib/memcmp.c (memcmp): Don't undefine outside of glibc.
46291 2018-10-05  Bruno Haible  <bruno@clisp.org>
46293         explicit_bzero: Make it possible to namespace the defined symbol.
46294         * lib/explicit_bzero.c (explicit_bzero): Don't undefine outside of
46295         glibc.
46297 2018-10-05  Bruno Haible  <bruno@clisp.org>
46299         mkdir-p: Depend on 'mkdir'.
46300         * modules/mkdir-p (Depends-on): Add 'mkdir'.
46302 2018-10-05  Bruno Haible  <bruno@clisp.org>
46304         tempname: Depend on 'mkdir'.
46305         Reported by Maarten Bosmans <mkbosmans@gmail.com>
46306         at <https://savannah.gnu.org/bugs/?33379>.
46307         * modules/tempname (Depends-on): Add 'mkdir'.
46309 2018-10-05  Akim Demaille  <akim@lrde.epita.fr>
46311         timevar: rely on gnulib modules for time portability.
46312         * modules/timevar (Depends-on): Add sys_time, sys_times, and times.
46313         * m4/timevar.m4: Don't check for clock_t and struct tms,
46314         guaranteed by gnulib.
46315         * lib/timevar.h: Use extern "C" protection.
46316         Include <stdio.h> for FILE.
46317         * lib/timevar.c: Include sys/time.h, sys/times.h unconditionally,
46318         they are guaranteed by gnulib.
46319         Remove uses of clock as (now useless) fallback.
46321 2018-10-04  Bruno Haible  <bruno@clisp.org>
46323         sh-filename: New module.
46324         * m4/sh-filename.m4: New file.
46325         * modules/sh-filename: New file.
46326         * lib/spawni.c (_PATH_BSHELL): Use BOURNE_SHELL instead of hardcoding
46327         "/bin/sh".
46328         * tests/test-posix_spawn1.c (main): Likewise.
46329         * tests/test-posix_spawn2.c (main): Likewise.
46330         * lib/javacomp.c (compile_using_envjavac, is_envjavac_gcj,
46331         is_envjavac_gcj43): Likewise.
46332         * lib/javaexec.c (execute_java_class): Likewise.
46333         * modules/posix_spawn-internal (Depends-on): Add sh-filename.
46334         * modules/posix_spawnp-tests (Depends-on): Likewise.
46335         * modules/javacomp (Depends-on): Likewise.
46336         * modules/javaexec (Depends-on): Likewise.
46338 2018-10-04  Bruno Haible  <bruno@clisp.org>
46340         spawn-pipe tests: Avoid test failure on native Windows.
46341         * tests/test-spawn-pipe-child.c (main): On native Windows, don't expect
46342         that fd 2 is closed.
46344 2018-10-04  Bruno Haible  <bruno@clisp.org>
46346         fcntl: Make it possible to namespace the defined symbol.
46347         * lib/fcntl.c (fcntl): Undefine only after the replacement function has
46348         been defined.
46349         (fcntl): Renamed from rpl_fcntl.
46350         (rpl_fcntl_DUPFD, rpl_fcntl_DUPFD_CLOEXEC): New functions, extracted
46351         from fcntl.
46352         (klibc_fcntl): Move to the end of the compilation unit.
46354 2018-10-02  Bruno Haible  <bruno@clisp.org>
46356         vasnprintf tests: Avoid test failure on HP-UX/hppa and IRIX.
46357         * tests/test-vasnprintf.c (test_function): Change the test added on
46358         2018-09-23 to check only the 18 most significant digits.
46360         vasnprintf tests: Avoid test failure on Cygwin.
46361         * tests/test-vasnprintf.c (test_function): Change the test added on
46362         2018-09-23 to check only the 42 most significant digits.
46364 2018-10-01  Bruno Haible  <bruno@clisp.org>
46366         mkostemp, mkostemps: Update documentation.
46367         * doc/glibc-functions/mkostemp.texi: Mention the Mac OS X issue.
46368         * doc/glibc-functions/mkostemps.texi: Likewise.
46370 2018-10-01  Tom Tromey  <tom@tromey.com>
46372         mkostemp, mkostemps: Fix compilation error in C++ mode on Mac OS X.
46373         * lib/stdlib.in.h: Include <unistd.h> for mkostemp and mkostemps
46374         on OS X.
46376 2018-09-30  Pádraig Brady  <P@draigBrady.com>
46378         hmac-*: refactor to remove repetitive code
46379         * lib/hmac.c: A new parameterized single implementation.
46380         * lib/hmac-md5.c: Define parameters and include implementation.
46381         * lib/hmac-sha1.c: Likewise.
46382         * lib/hmac-sha256.c: Likewise.
46383         * lib/hmac-sha512.c: Likewise.
46384         * modules/crypto/hmac-md5: Reference the new implementation file.
46385         * modules/crypto/hmac-sha1: Likewise.
46386         * modules/crypto/hmac-sha256: Likewise.
46387         * modules/crypto/hmac-sha512: Likewise.
46388         * tests/test-hmac-md5.c: Refactor common code to a single function.
46389         * tests/test-hmac-sha1.c: Likewise.
46390         * tests/test-hmac-sha256.c: Likewise.
46391         * tests/test-hmac-sha512.c: Likewise.
46393 2018-09-30  Zhang Qing  <zhangqingl@126.com>
46395         hmac-sha512: fix hash for keys > blocksize (128 bytes)
46396         * lib/hmac-sha512.c (hmac_sha512): Set the computed/shortened
46397         key length to that output by sha512, not the blocksize.
46398         Otherwise uninitialized data from the stack
46399         is used when computing the hash.
46400         * tests/test-hmac-sha512.c: Add a shortened key test case.
46401         Reported at https://github.com/coreutils/gnulib/pull/5
46403 2018-09-30  Bruno Haible  <bruno@clisp.org>
46405         vasnprintf: Avoid warnings from GCC's -Wsign-compare.
46406         Reported by Bjarni Ingi Gislason <bjarniig@rhi.hi.is> in
46407         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00105.html>.
46408         * lib/vasnprintf.c (VASNPRINTF): Cast 'count' from 'int' to
46409         'unsigned int' before comparison with an unsigned value.
46411 2018-09-30  Bruno Haible  <bruno@clisp.org>
46413         grantpt: Remove unnecessary dependency.
46414         * modules/grantpt (Depends-on): Remove 'builtin-expect'.
46416 2018-09-30  Bruno Haible  <bruno@clisp.org>
46418         timevar: Small tweaks.
46419         * lib/timevar.h: Fix comments. Add parameter names to function
46420         declarations.
46421         * lib/timevar.c: Include timevar.h immediately after config.h.
46422         * lib/timevar.def: Fix comments.
46423         * modules/timevar (Maintainer): List Akim Demaille.
46425 2018-09-30  Bruno Haible  <bruno@clisp.org>
46427         timevar: Include documentation in gnulib manual.
46428         * doc/timevar.texi: Change node and section name to 'Profiling of
46429         program phases'.
46430         In the code snippets, tweak the #includes and use GNU coding style.
46431         * doc/gnulib.texi: Include timevar.texi.
46433 2018-09-27  Akim Demaille  <akim@lrde.epita.fr>
46435         timevar: import from Bison.
46436         * m4/timevar.m4, modules/timevar, lib/timevar.h, lib/timevar.c:
46437         New files.
46438         * lib/timevar.def: New file.
46439         * doc/timevar.texi: New file.
46441 2018-09-26  Bruno Haible  <bruno@clisp.org>
46443         javacomp-script, javacomp: Add preliminary support for Java 12..17.
46444         * m4/javacomp.m4 (gt_JAVACOMP): Treat Java versions 12..17 like 11.
46445         * lib/javacomp.c (default_target_version): Likewise.
46447 2018-09-26  Bruno Haible  <bruno@clisp.org>
46449         javacomp-script, javacomp: Add support for Java 11.
46450         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 11 and
46451         target-version 11.
46452         * lib/javaversion.h: Update comments.
46453         * lib/javacomp.c (default_target_version, SOURCE_VERSION_BOUND,
46454         source_version_index, get_goodcode_snippet, get_failcode_snippet,
46455         TARGET_VERSION_BOUND, target_version_index,
46456         corresponding_classfile_version): Accept source_version 11 and
46457         target_version 11.
46458         * lib/javacomp.h: Update comments accordingly.
46460 2018-09-23  Bruno Haible  <bruno@clisp.org>
46462         vasnprintf: Fix heap memory overrun bug.
46463         Reported by Ben Pfaff <blp@cs.stanford.edu> in
46464         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00107.html>.
46465         * lib/vasnprintf.c (convert_to_decimal): Allocate one more byte of
46466         memory.
46467         * tests/test-vasnprintf.c (test_function): Add another test.
46469 2018-09-19  Paul Eggert  <eggert@cs.ucla.edu>
46471         maint: mktime.c now shared with glibc
46472         * config/srclist.txt: intprops.h, timegm.c and mktime.c
46473         are now the same in Gnulib and glibc.
46475         mktime: fix _LIBC typo
46476         * lib/mktime.c (mktime): Fix typo (misspelled "_LIBC").
46478 2018-09-19  Norihiro Tanaka  <noritnk@kcn.ne.jp>
46480         dfa: optimization for state merge
46481         * lib/dfa.c (merge2): New function.
46482         (merge_nfa_state): Use it.
46484 2018-09-18  Jim Meyering  <meyering@fb.com>
46486         dfa: trivial comment fix: s/is/if/
46487         * lib/dfa.c (maybe_disable_superset_dfa): Fix comment typo.
46489 2018-09-18  Paul Eggert  <eggert@cs.ucla.edu>
46491         dfa: use more-informative function name
46492         * lib/dfa.c (maybe_disable_superset_dfa):
46493         Rename from dfautf8noss.  Use change.
46495         dfa: tweak allocation performance
46496         * lib/dfa.c (merge_nfa_state, dfaoptimize):
46497         Prefer ptrdiff_t for indexes some more.
46498         Use char for flags, as it’s wide enough.
46499         Allocate queue and flags together, with one malloc call.
46500         No need to use xnmalloc since the multiplication and
46501         addition cannot overflow (it’s already been checked by
46502         earlier allocation).  Prefer memset to open-coding.
46504         dfa: prune states as we go
46505         * lib/dfa.c (prune): Remove.
46506         dfa: reorder enum for efficiency
46507         (merge_nfa_state): Prune as we go instead of at the end.
46508         Prefer ptrdiff_t for indexes, as this helps the compiler a bit.
46510         * lib/dfa.c (END): Now -1 again.  Reorder other elements
46511         of the enumeration to make it easier for GCC to generate
46512         efficient code by using fewer comparisons to check for
46513         ranges of values.
46514         (atom): Take advantage of the reordering.
46516 2018-09-18  Norihiro Tanaka  <noritnk@kcn.ne.jp>
46518         dfa: optimize alternation in NFA
46519         Even when similar states exist in alternation, the DFA treats them
46520         as separate items, which may complicate the transition in NFA and
46521         cause slowdown.  This change assembles the states into one.  For
46522         example, ab|ac is changed into a(b|c).  This change speeds-up
46523         matching for many branched patterns.  For example, grep speeds up
46524         more than 30× in:
46526           seq 10000 | sed 's/$/ abcdefghijklmnopqrstuvwxyz/; s/$/./' >in
46527           time -p env LC_ALL=C grep -vf in in
46529         * lib/dfa.c (prune): New function.
46530         (merge_nfa_state): New function.  It merges similar NFA states.
46531         (dfaoptimize): New function.  It seeks merged and removed nodes.
46532         (dfaanalyze): Call new function.
46533         (dfautf8noss): Change name from dfaoptimize because of addition of new
46534         function.
46535         (dfacomp): Update caller.
46537         dfa: simplify initial state
46538         Simplifying the initial state enables easier optimization of the NFA.
46539         * lib/dfa.c (enum token): Add new element BEG.
46540         (prtok): Adjust due to adding element BEG.
46541         (dfaparse): Put BEG at a head of tokens.
46542         (state_index): Adjust due to adding element BEG.
46543         (dfaanalyze): Concatenate BEG to other tokens, and simplify to
46544         build initial state.
46545         (dfamust): Adjust due to adding element BEG.  DFAMUST ignores it.
46547 2018-09-18  Bruno Haible  <bruno@clisp.org>
46549         file-has-acl: Fix test failure on Cygwin 2.9.
46550         * m4/acl.m4 (gl_FUNC_ACL): Update comments regarding Cygwin.
46551         * lib/acl-internal.h: Likewise.
46552         (HAVE_ACL_EXTENDED_FILE): Undefine on Cygwin.
46553         * lib/acl-internal.c: Update comments regarding Cygwin.
46554         * lib/acl_entries.c: Likewise.
46555         * lib/file-has-acl.c: Likewise.
46556         (file_has_acl): For Cygwin, use a different way to determine whether
46557         the "default" ACL of a directory is nontrivial.
46558         * lib/get-permissions.c: Update comments regarding Cygwin.
46559         * lib/set-permissions.c: Likewise.
46561 2018-09-18  Bruno Haible  <bruno@clisp.org>
46563         stat-time tests: Fix test failure on Cygwin.
46564         * tests/nap.h (nap_get_stat): Treat Cygwin like native Windows.
46566 2018-09-18  Paul Eggert  <eggert@cs.ucla.edu>
46568         doc: OS X 10.11 lacked ns time functions
46569         According to <https://github.com/zeromq/libzmq/issues/2175>,
46570         nanosecond-resolution timestamp functions were introduced
46571         in macOS 10.12, so document the last version (OS X 10.11)
46572         where they were absent.
46574         gettime: nanotime never existed
46575         Problem reported by Bruno Haible in:
46576         https://lists.gnu.org/r/bug-gnulib/2018-09/msg00082.html
46577         * lib/gettime.c (gettime) [HAVE_NANOTIME]: Remove unused code.
46578         * m4/gettime.m4 (gl_GETTIME): Don’t check for nanotime.
46580 2018-09-18  Bruno Haible  <bruno@clisp.org>
46582         doc: Update statement about target platforms.
46583         Reported by Simon Sobisch.
46584         * doc/gnulib-intro.texi (Target Platforms): Update. Mention
46585         restrictions on MSVC versions.
46587 2018-09-18  Bruno Haible  <bruno@clisp.org>
46589         posix_spawn tests: Fix link error on 64-bit Cygwin.
46590         * tests/test-posix_spawn1.c (environ): Remove declaration.
46591         * tests/test-posix_spawn2.c (environ): Likewise.
46592         * tests/test-posix_spawn3.c (environ): Likewise.
46593         * tests/test-posix_spawn4.c (environ): Likewise.
46594         * modules/posix_spawn-tests (Depends-on): Add 'environ'.
46595         * modules/posix_spawnp-tests (Depends-on): Likewise.
46597 2018-09-16  Paul Eggert  <eggert@cs.ucla.edu>
46599         timespec: new function current_timespec
46600         * lib/gettime.c (gettime): Prefer clock_gettime to nanotime,
46601         and don’t worry about it failing on a CLOCK_REALTIME arg.
46602         POSIX requires it to succeed and I don’t know of any
46603         counterexamples where the fallbacks would work.
46604         (current_timespec): New function, taken from Emacs.  It is more
46605         convenient than gettime, and can help register allocation.
46606         * lib/timespec.h: Include arg-nonnull.h.
46607         (current_timespec): New declaration.
46608         (gettime, settime): Declare args to be nonnull.
46609         * modules/timespec (Depends-on): Add snippet/arg-nonnull.
46611 2018-09-16  Bruno Haible  <bruno@clisp.org>
46613         setlocale: Improve locale handling on macOS 10.12 or newer.
46614         * lib/setlocale.c: Include header files for CoreFoundation. Declare
46615         gl_locale_name_canonicalize.
46616         (libintl_setlocale): Try harder to set a locale for categories LC_CTYPE
46617         and LC_MESSAGES.
46618         * m4/setlocale.m4 (gl_PREREQ_SETLOCALE): Add comment.
46620 2018-09-16  Bruno Haible  <bruno@clisp.org>
46622         Update list of locale names with scripts on macOS.
46623         * lib/localename.c (gl_locale_name_canonicalize): Update tables to
46624         match Mac OS X 10.13 and recent glibc.
46626 2018-09-16  Bruno Haible  <bruno@clisp.org>
46628         gettext: Use newer macOS APIs when possible.
46629         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Check for
46630         CFLocaleCopyPreferredLanguages.
46632 2018-09-16  Bruno Haible  <bruno@clisp.org>
46634         localename: Revisit macOS specific code.
46635         * lib/localename.c (gl_locale_name_default): Reduce code duplication.
46636         Fix comments about Mac OS X versions.
46638 2018-09-15  Bruno Haible  <bruno@clisp.org>
46640         setlocale: Improve support for locales not supported by libc.
46641         Reported by Dapeng Gao <peter@dpgao.cc> at
46642         <https://savannah.gnu.org/bugs/?54479>.
46643         * gettext-runtime/intl/setlocale.c: Include <stdio.h>.
46644         (libintl_setlocale): Use a more error-tolerant strategy when the locale
46645         to be set is not supported by libc: Emit warnings instead of failing.
46647 2018-09-15  Bruno Haible  <bruno@clisp.org>
46649         strstr, strcasestr: Add workaround against glibc-2.28 bug.
46650         Reported by Michael Brunnbauer via Siddhesh Poyarekar and Eric Blake.
46651         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Set
46652         gl_cv_func_strstr_works_always to 'no' on glibc 2.28.
46653         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Set
46654         gl_cv_func_strcasestr_works_always to 'no' on glibc 2.28.
46655         * doc/posix-functions/strstr.texi: Document the glibc 2.28 bug.
46656         * doc/glibc-functions/strcasestr.texi: Likewise.
46658 2018-09-14  Bruno Haible  <bruno@clisp.org>
46660         doc: Fix bottom of top-level page.
46661         Reported by Akim Demaille <akim.demaille@gmail.com> in
46662         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00072.html>.
46663         * doc/pastposix-functions/index.texi: Rename node to '_index' in HTML
46664         mode.
46665         * doc/gnulib.texi (Legacy Function Substitutes): Update menu
46666         accordingly.
46668 2018-09-12  Bruno Haible  <bruno@clisp.org>
46670         Add test case from a recent glibc bug.
46671         * tests/test-strstr.c (main): Add test of long needle.
46672         * tests/test-strcasestr.c (main): Likewise.
46673         * tests/test-c-strstr.c (main): Likewise.
46674         * tests/test-c-strcasestr.c (main): Likewise.
46675         * tests/test-memmem.c (main): Likewise.
46677 2018-09-12  Bruno Haible  <bruno@clisp.org>
46679         Apply Eric Blake's improvements from 2011-02-25 to more tests.
46680         * tests/test-c-strstr.c (main): Add the same tests here as well.
46682 2018-09-12  Bruno Haible  <bruno@clisp.org>
46684         Apply Jim Meyering's fix from 2015-01-11 to more tests.
46685         * tests/test-memmem.c (main): Free haystack.
46686         * tests/test-strcasestr.c (main): Likewise.
46687         * tests/test-c-strcasestr.c (main): Likewise.
46689 2018-09-11  Paul Eggert  <eggert@cs.ucla.edu>
46691         xstrtol: fix missing-TYPE_SIGNED typo
46692         * lib/xstrtol.c (TYPE_SIGNED): New macro, duplicating intprops.h.
46694 2018-09-10  Paul Eggert  <eggert@cs.ucla.edu>
46696         timespec: fix resolution confusion
46697         In normal usage, clock resolution is given in seconds, but the
46698         code was mistakenly using inverse seconds and calling it
46699         “resolution”.  Fix this, partly by renaming two identifiers.
46700         The old names will be kept for a bit, to ease transition.
46701         * lib/timespec.h (TIMESPEC_HZ, LOG10_TIMESPEC_HZ):
46702         New constants, replacing TIMESPEC_RESOLUTION and
46703         LOG10_TIMESPEC_RESOLUTION, which are now obsolescent.
46704         All uses changed.
46706 2018-09-09  Paul Eggert  <eggert@cs.ucla.edu>
46708         mktime: simplify in prep for glibc merge
46709         * lib/mktime.c, lib/timegm.c [_LIBC]:
46710         Include mktime-internal.h (a small file just for glibc)
46711         instead of using a typedef.
46713 2018-09-07  Paul Eggert  <eggert@cs.ucla.edu>
46715         intprops: minor clarification of code
46716         * lib/intprops.h (_GL_BINARY_OP_OVERFLOW):
46717         Use _GL_INT_CONVERT rather than reinventing it.
46719 2018-09-07  Bruno Haible  <bruno@clisp.org>
46721         Fix a comment.
46722         * tests/test-posix_spawn3.c (parent_main): Fix typo in comment.
46724 2018-09-07  Bruno Haible  <bruno@clisp.org>
46726         posix_spawn_file_actions_addchdir: Add tests.
46727         * tests/test-posix_spawn_file_actions_addchdir.c: New file.
46728         * tests/test-posix_spawn4.c: New file.
46729         * modules/posix_spawn_file_actions_addchdir-tests: New file.
46731 2018-09-07  Bruno Haible  <bruno@clisp.org>
46733         posix_spawn_file_actions_addchdir: New module.
46734         Suggested by Eric Blake in
46735         <https://lists.gnu.org/archive/html/bug-findutils/2018-09/msg00007.html>.
46736         * lib/spawn.in.h (posix_spawn_file_actions_addchdir): New declaration.
46737         * lib/spawn_int.h (struct __spawn_action): Add tag 'spawn_do_chdir' and
46738         union member 'chdir_action'.
46739         * lib/spawn_faction_addchdir.c: New file.
46740         * lib/spawni.c (__spawni): Implement the spawn_do_chdir action.
46741         * lib/spawn_faction_addclose.c: Test REPLACE_POSIX_SPAWN instead of
46742         HAVE_WORKING_POSIX_SPAWN.
46743         * lib/spawn_faction_adddup2.c: Likewise.
46744         * lib/spawn_faction_addopen.c: Likewise.
46745         * m4/posix_spawn_faction_addchdir.m4: New file.
46746         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test whether module
46747         'posix_spawn_file_actions_addchdir' is present and whether
46748         posix_spawn_file_actions_addchdir_np exists. Define REPLACE_POSIX_SPAWN
46749         instead of HAVE_WORKING_POSIX_SPAWN.
46750         * m4/spawn_h.m4 (gl_SPAWN_H): Test whether
46751         posix_spawn_file_actions_addchdir is declared.
46752         (gl_SPAWN_H_DEFAULTS): Initialize
46753         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
46754         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
46755         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR.
46756         * modules/spawn (Makefile.am): Substitute
46757         GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
46758         HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR,
46759         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR.
46760         * modules/posix_spawn_file_actions_addchdir: New file.
46761         * modules/posix_spawn_file_actions_addclose (Depends-on,
46762         configure.ac): Test also REPLACE_POSIX_SPAWN.
46763         * modules/posix_spawn_file_actions_adddup2 (Depends-on,
46764         configure.ac): Likewise.
46765         * modules/posix_spawn_file_actions_addopen (Depends-on,
46766         configure.ac): Likewise.
46767         * tests/test-spawn-c++.cc (posix_spawn_file_actions_addchdir): Check
46768         signature.
46769         * doc/posix-functions/posix_spawn.texi: Mention the new module.
46770         * doc/posix-functions/posix_spawnp.texi: Likewise.
46772 2018-09-06  Bruno Haible  <bruno@clisp.org>
46774         stddef: Override max_align_t on NetBSD 8.0/x86.
46775         * m4/stddef_h.m4 (gl_STDDEF_H): When testing for max_align_t, test also
46776         the value of __alignof__ (max_align_t).
46777         * doc/posix-headers/stddef.texi: Mention the issue.
46779 2018-09-06  Bruno Haible  <bruno@clisp.org>
46781         fcntl: Fix F_DUPFD_CLOEXEC behaviour on Haiku.
46782         * lib/fcntl.c (rpl_fcntl): For F_DUPFD_CLOEXEC, don't even try the
46783         system fcntl.
46784         * doc/posix-functions/fcntl.texi: Document the issue.
46786 2018-09-06  Bruno Haible  <bruno@clisp.org>
46788         count-trailing-zeros tests: Rely on limits-h module.
46789         * tests/test-count-trailing-zeros.c (ULLONG_MAX): Remove fallback
46790         definition.
46791         * modules/count-trailing-zeros-tests (Depends-on): Add 'limits-h'.
46793 2018-09-06  Bruno Haible  <bruno@clisp.org>
46795         count-leading-zeros tests: Rely on limits-h module.
46796         * tests/test-count-leading-zeros.c (ULLONG_MAX): Remove fallback
46797         definition.
46798         * modules/count-leading-zeros-tests (Depends-on): Add 'limits-h'.
46800 2018-09-06  Bruno Haible  <bruno@clisp.org>
46802         count-one-bits tests: Rely on limits-h module.
46803         * tests/test-count-one-bits.c (ULLONG_MAX): Remove fallback definition.
46804         * modules/count-one-bits-tests (Depends-on): Add 'limits-h'.
46806 2018-09-06  Bruno Haible  <bruno@clisp.org>
46808         xstrtoll: Rely on limits-h module.
46809         * lib/xstrtol.c: Don't include intprops.h.
46810         (ULLONG_MAX, LLONG_MAX, LLONG_MIN): Remove fallback definitions.
46811         * modules/xstrtol (Depends-on): Remove 'intprops'.
46812         * modules/xstrtoll (Depends-on): Add 'limits-h'.
46814 2018-09-06  Bruno Haible  <bruno@clisp.org>
46816         strtoll, strtoull: Rely on limits-h module.
46817         * lib/strtol.c (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove macros.
46818         (ULLONG_MAX, LLONG_MAX, LLONG_MIN): Remove fallback definitions.
46819         * modules/strtoll (Depends-on): Add limits-h.
46820         * modules/strtoull (Depends-on): Likewise.
46822 2018-09-06  Bruno Haible  <bruno@clisp.org>
46824         intprops tests: Fix compilation error with pre-C99 compiler.
46825         * tests/test-intprops.c (verify_stmt): New macro.
46826         (VERIFY, main): Use it.
46828 2018-09-06  Bruno Haible  <bruno@clisp.org>
46830         limits-h: Provide numerical limits macros.
46831         * lib/limits.in.h (LLONG_MIN, LLONG_MAX, ULLONG_MAX): Define also for
46832         IRIX and for GCC.
46833         (WORD_BIT, LONG_BIT): Define.
46834         * m4/limits-h.m4 (gl_LIMITS_H): Set LIMITS_H to non-empty also when
46835         <limits.h> does not define LLONG_MAX or WORD_BIT.
46836         * tests/test-limits-h.c (TYPE_SIGNED, TYPE_WIDTH, TYPE_MINIMUM,
46837         TYPE_MAXIMUM): New macros, from intprops.h.
46838         Add tests for CHAR_BIT, WORD_BIT, LONG_BIT, <type>_MIN, and <type>_MAX.
46839         * doc/posix-headers/limits.texi: Document what the 'limits-h' module
46840         provides.
46842 2018-09-05  Bruno Haible  <bruno@clisp.org>
46844         fcntl: Don't access nonexistent optional argument.
46845         Reported by Frank Busse <f.busse@imperial.ac.uk> in
46846         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00018.html>.
46847         * lib/fcntl.c (rpl_fcntl): For actions that don't take an argument,
46848         don't consume an argument. For actions that take an 'int' argument,
46849         consume an 'int' argument.
46851 2018-09-05  Eric Blake  <eblake@redhat.com>
46853         doc: mention environ pitfall
46854         * doc/posix-functions/environ.texi (environ): Assigning NULL to
46855         environ is a glibc extension.
46857 2018-09-03  Bruno Haible  <bruno@clisp.org>
46859         gnulib-tool: Fix build order when $testsbase is a subdir of $sourcebase.
46860         Reported by Antoine Luong <antoine.luong@c-s.fr> in
46861         <https://lists.gnu.org/archive/html/bug-gnulib/2018-09/msg00008.html>.
46862         * gnulib-tool (func_import): For the tests, set a dotfirst flag.
46863         (func_emit_lib_Makefile_am): Consider the dotfirst flag.
46864         (func_emit_tests_Makefile_am): Don't consider the dotfirst flag.
46866 2018-09-02  Paul Eggert  <eggert@cs.ucla.edu>
46868         mktime: fix unlikely race+overflow bug
46869         Problem reported by Alexandre Oliva in:
46870         https://sourceware.org/bugzilla/show_bug.cgi?id=16346
46871         * lib/mktime.c (__mktime_internal): Access *OFFSET only once,
46872         to avoid an unlikely race if the compiler delays a load and
46873         if this cascades into a signed integer overflow.
46875 2018-08-31  Paul Eggert  <eggert@cs.ucla.edu>
46877         mktime, timegm: simplify glibc time64_t
46878         * lib/mktime.c, lib/timegm.c (mktime_offset_t) [_LIBC]:
46879         Now long int, not time_t, since long int is the longstanding type
46880         for this in glibc and there is no need to change it even if time_t
46881         becomes 64 bits - even int would do, though this would be a change
46882         to the glibc generated code.  When this change is merged into
46883         glibc, it should simplify the time_t vs time64_t situation.
46885         mktime, timegm: simplify merge to glibc
46886         Move code around to make a merge to glibc easier to audit.
46887         This should not change behavior.
46888         * lib/mktime.c (NEED_MKTIME_INTERNAL, NEED_MKTIME_WINDOWS)
46889         (NEED_MKTIME_WORKING): Give default values to pacify -Wundef,
46890         which glibc uses.  Default NEED_MKTIME_WORKING to DEBUG_MKTIME, to
46891         simplify later conditionals; default the others to zero.  In uses
46892         of these conditionals, explicitly spell out how _LIBC affects
46893         things, so it’s easier to review from a glibc viewpoint.
46894         (my_tzset, __tzset) [!_LIBC]: New function and macro, to better
46895         compartmentalize tzset issues.  Move system-dependent tzsettish
46896         code here from mktime.
46897         (mktime): Move tzsettish code to my_tzset, and move
46898         localtime_offset to within mktime so that it doesn’t
46899         need a separate ifdef.
46901 2018-08-27  Paul Eggert  <eggert@cs.ucla.edu>
46903         intprops: avoid evaluation of some expressions
46904         This makes EXPR_SIGNED (e) easier to use, as it no longer
46905         evaluates the expression E.  Formerly, E was required to be free
46906         of side effects.
46907         * lib/intprops.h (_GL_INT_CONVERT, _GL_INT_NEGATE_CONVERT)
46908         (EXPR_SIGNED, TYPE_WIDTH, _GL_INT_MINIMUM, _GL_INT_MAXIMUM)
46909         (_GL_SIGNED_INT_MAXIMUM): Do not evaluate the expression arg.
46911 2018-08-23  Bruno Haible  <bruno@clisp.org>
46913         getcwd: Add cross-compilation guesses.
46914         Reported by Sergio Durigan Junior <sergiodj@redhat.com> in
46915         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00130.html>.
46916         Based on a patch by Paul Eggert.
46917         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Add cross-compilation
46918         guesses for all GNU systems.
46920 2018-08-19  Bruno Haible  <bruno@clisp.org>
46922         glob-h: Formalize side effects from other modules.
46923         * m4/glob_h.m4 (gl_REPLACE_GLOB_H): New macro.
46924         * m4/glob.m4 (gl_GLOB): Invoke it.
46926         fnmatch-h: Formalize side effects from other modules.
46927         * m4/fnmatch_h.m4 (gl_REPLACE_FNMATCH_H): New macro.
46928         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Invoke it.
46930         limits-h: Formalize side effects from other modules.
46931         * m4/limits-h.m4 (gl_REPLACE_LIMITS_H): New macro.
46932         * m4/stdint.m4 (gl_STDINT_H): Invoke it.
46934 2018-08-19  Bruno Haible  <bruno@clisp.org>
46936         getpass: Move declaration to <unistd.h>.
46937         * lib/unistd.in.h (getpass): New declaration.
46938         * lib/getpass.h: Replace with a stub that just includes <unistd.h>.
46939         * m4/getpass.m4 (gl_FUNC_GETPASS): Declare through AC_DEFUN_ONCE.
46940         Require gl_UNISTD_H_DEFAULTS. Don't test whether getpass is declared.
46941         (gl_FUNC_GETPASS_GNU): Require gl_UNISTD_H_DEFAULTS and gl_FUNC_GETPASS.
46942         On glibc systems, don't set REPLACE_GETPASS to 1.
46943         * modules/getpass (Depends-on): Add 'unistd'.
46944         (configure.ac): Test also REPLACE_GETPASS. Define a module indicator.
46945         (Include): Specify <unistd.h> instead of "getpass.h".
46946         * modules/getpass-gnu (Depends-on): Merely depend on 'getpass'.
46947         (configure.ac): Sync with the configure.ac section of modules/getpass.
46948         (Include): Specify <unistd.h> instead of "getpass.h".
46949         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether getpass is declared.
46950         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETPASS, HAVE_GETPASS,
46951         REPLACE_GETPASS.
46952         * modules/unistd (Makefile.am): Substitute GNULIB_GETPASS, HAVE_GETPASS,
46953         REPLACE_GETPASS.
46954         * tests/test-unistd-c++.cc: Test also the declaration of 'getpass'.
46955         * doc/glibc-functions/getpass.texi: A length limit exists also on uClibc
46956         and musl.
46957         * NEWS: Mention the change.
46959 2018-08-19  Bruno Haible  <bruno@clisp.org>
46961         glob: Fix over-optimization due to attribute __nonnull__.
46962         * lib/glob.c (_GL_ARG_NONNULL): Define to empty.
46964 2018-08-19  Bruno Haible  <bruno@clisp.org>
46966         glob: Fix another compilation error when glob.h is not replaced.
46967         Reported by Reuben Thomas <rrt@sc3d.org> in
46968         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00112.html>.
46969         * m4/glob.m4 (gl_GLOB): Set GLOB_H to non-empty when needed.
46970         * m4/glob_h.m4 (gl_GLOB_H): Define through AC_DEFUN_ONCE.
46972 2018-08-18  Bruno Haible  <bruno@clisp.org>
46974         fnmatch: Avoid conflicting macro definitions of 'fnmatch'.
46975         Reported by Reuben Thomas <rrt@sc3d.org> in
46976         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00108.html>.
46977         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): Don't define 'fnmatch' as a macro
46978         in config.h.
46980 2018-08-18  Bruno Haible  <bruno@clisp.org>
46982         Avoid -Wcast-function-type warnings from casts after GetProcAddress.
46983         Reported by Andy Moreton <andrewjmoreton@gmail.com> in
46984         <https://lists.gnu.org/archive/html/emacs-devel/2018-08/msg00468.html>.
46985         Solution proposed by Eli Zaretskii.
46986         * lib/getaddrinfo.c (GetProcAddress): Cast result to 'void *' first.
46987         * lib/gettimeofday.c (GetProcAddress): Likewise.
46988         * lib/link.c (GetProcAddress): Likewise.
46989         * lib/physmem.c (GetProcAddress): Likewise.
46990         * lib/poll.c (GetProcAddress): Likewise.
46991         * lib/select.c (GetProcAddress): Likewise.
46992         * lib/stat-w32.c (GetProcAddress): Likewise.
46994 2018-08-18  Bruno Haible  <bruno@clisp.org>
46996         glob: Fix another compilation error when glob.h is not replaced.
46997         Reported and fix proposed by Reuben Thomas <rrt@sc3d.org> again.
46998         * lib/globfree.c: Include <libc-config.h>.
47000 2018-08-18  Bruno Haible  <bruno@clisp.org>
47002         glob: Fix compilation error when glob.h is not replaced.
47003         Reported and fix proposed by Reuben Thomas <rrt@sc3d.org> in
47004         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00096.html>.
47005         * lib/glob_pattern_p.c: Include <libc-config.h>.
47006         * modules/glob (Depends-on): Add libc-config.
47008 2018-08-18  Bruno Haible  <bruno@clisp.org>
47010         scratch_buffer: Add tests.
47011         * tests/test-scratch-buffer.c: New file.
47012         * modules/scratch_buffer-tests: New file.
47014 2018-08-18  Bruno Haible  <bruno@clisp.org>
47016         scratch_buffer: Fix include file.
47017         Reported by Reuben Thomas <rrt@sc3d.org> in
47018         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00082.html>.
47019         * lib/scratch_buffer.h: Include <libc-config.h> first. Add
47020         double-inclusion guard.
47022 2018-08-18  Bruno Haible  <bruno@clisp.org>
47024         glob-h: Revert Paul Eggert's revert.
47025         * m4/glob_h.m4: Revert to previous state.
47026         * modules/glob-h: Likewise.
47028 2018-08-18  Paul Eggert  <eggert@cs.ucla.edu>
47030         glob-h: always build glob.h
47031         This works around a problem reported by Reuben Thomas in:
47032         http://lists.gnu.org/r/bug-gnulib/2018-08/msg00079.html
47033         This workaround always builds glob.h, even on platforms that
47034         do not need it; perhaps this could be improved someday.
47035         * m4/glob_h.m4 (gl_GLOB_H): Do not set or use GLOB_H, since glob.h
47036         is always created now.
47037         * modules/glob-h (BUILT_SOURCES, glob.h): Always build glob.h.
47039 2018-08-13  Bruno Haible  <bruno@clisp.org>
47041         monetary: Simplify m4 code.
47042         * m4/monetary_h.m4 (gl_MONETARY_H): Define through AC_DEFUN_ONCE.
47043         (gl_MONETARY_H_BODY): Inline into gl_MONETARY_H. Remove macro.
47045 2018-08-13  Bruno Haible  <bruno@clisp.org>
47047         fnmatch, fnmatch-gnu: Fix compilation error on Mac OS X.
47048         Reported by Jeroen Meijer <jjgmeijer@gmail.com> in
47049         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00046.html>
47050         and by Paul J. Lucas <paul@lucasmail.org> in
47051         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00069.html>.
47052         * m4/fnmatch_h.m4 (gl_FNMATCH_H): Define through AC_DEFUN_ONCE.
47054 2018-08-11  Bruno Haible  <bruno@clisp.org>
47056         setlocale: Trivial simplification.
47057         * lib/setlocale.c (setlocale_unixlike): Remove redundant #if.
47059 2018-08-11  Paul Eggert  <eggert@cs.ucla.edu>
47061         verify: port 'assume' to traditional tools
47062         * lib/verify.h (assume): Port better to Oracle Studio 12.6
47063         and other tools that use /*NOTREACHED*/ comments.
47065 2018-08-10  Bruno Haible  <bruno@clisp.org>
47067         fnmatch-gnu: Fix compilation error in C++ namespace mode on Mac OS X.
47068         * modules/fnmatch-gnu (configure.ac): Invoke gl_MODULE_INDICATOR.
47069         * lib/fnmatch.in.h (fnmatch): Skip _GL_CXXALIASWARN if module
47070         'fnmatch-gnu' is in use.
47072 2018-08-07  Bruno Haible  <bruno@clisp.org>
47074         glob-h: Add tests.
47075         * tests/test-glob-h.c: New file, partially based on tests/test-glob.c.
47076         * tests/test-glob.c: Reorder #includes. Remove tests that are moved to
47077         tests/test-glob-h.c.
47078         * modules/glob-h-tests: New file.
47079         * tests/test-glob-h-c++.cc: Renamed from tests/test-glob-c++.cc. Add
47080         conditions.
47081         * modules/glob-h-c++-tests: Renamed from modules/glob-c++-tests.
47082         * modules/glob-tests (Depends-on): Remove glob-c++-tests.
47084 2018-08-07  Bruno Haible  <bruno@clisp.org>
47086         glob-h: New module.
47087         * lib/glob.in.h: Use nearly the usual gnulib idioms for header file
47088         replacements.
47089         * lib/glob.c: Include <config.h>.
47090         * m4/glob_h.m4: New file.
47091         * m4/glob.m4 (gl_GLOB): Require gl_GLOB_H. Remove code that is moved to
47092         glob_h.m4. Set HAVE_GLOB, REPLACE_GLOB, HAVE_GLOB_PATTERN_P,
47093         REPLACE_GLOB_PATTERN_P as appropriate.
47094         (gl_PREREQ_GLOB): Don't require AC_C_RESTRICT and
47095         AC_USE_SYSTEM_EXTENSIONS, now done through module 'glob-h'.
47096         * modules/glob-h: New file.
47097         * modules/glob (Files): Remove lib/glob.in.h, lib/glob-libc.h.
47098         (Dependencies): Add glob-h. Remove extensions, snippet/*, libc-config,
47099         lstat, sys_stat. Change conditions.
47100         (configure.ac): Test HAVE_GLOB, REPLACE_GLOB, HAVE_GLOB_PATTERN_P,
47101         REPLACE_GLOB_PATTERN_P. Set module indicator.
47102         (Makefile.am): Remove code that is moved to glob-h.
47103         * doc/posix-headers/glob.texi: Mention the 'glob-h' module.
47104         * modules/posixcheck (Depends-on): Add glob-h.
47106 2018-08-06  Bruno Haible  <bruno@clisp.org>
47108         Force generation of substitute .h file when C++ support is enabled.
47109         * m4/ansi-c++.m4 (gl_ANSI_CXX): New macro.
47110         * modules/ansi-c++-opt (configure.ac): Just require gl_ANSI_CXX.
47111         * m4/fnmatch_h.m4 (gl_FNMATCH_H): If C++ support is enabled, set
47112         FNMATCH_H to non-empty.
47113         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): If C++ support is enabled, set
47114         ICONV_H to non-empty.
47115         * m4/monetary_h.m4 (gl_MONETARY_H_BODY): If C++ support is enabled, set
47116         MONETARY_H to non-empty.
47117         * m4/utime_h.m4 (gl_UTIME_H): If C++ support is enabled, set UTIME_H to
47118         non-empty.
47120 2018-08-06  Bruno Haible  <bruno@clisp.org>
47122         fnmatch-h: Fix test compilation error on mingw (regression from today).
47123         * lib/fnmatch.in.h: Fix conditions.
47125 2018-08-06  Bruno Haible  <bruno@clisp.org>
47127         sys_resource: Relicense under LGPLv2+.
47128         John Malmberg's approval is in
47129         <https://lists.gnu.org/archive/html/bug-gnulib/2018-08/msg00031.html>.
47130         * modules/sys_resource (License): Change to LGPLv2+.
47132 2018-08-06  Bruno Haible  <bruno@clisp.org>
47134         fnmatch-h: Add tests.
47135         * tests/test-fnmatch-h.c: New file.
47136         * modules/fnmatch-h-tests: New file.
47137         * tests/test-fnmatch-h-c++.cc: New file.
47138         * modules/fnmatch-h-c++-tests: New file.
47140 2018-08-06  Bruno Haible  <bruno@clisp.org>
47142         fnmatch-h: New module.
47143         * lib/fnmatch.in.h: Use the usual gnulib idioms for header file
47144         replacements.
47145         (FNM_*): Don't redefine if fnmatch exists and we are not overriding it.
47146         (fnmatch): Use the usual gnulib idiom for function declarations. Enable
47147         'posixcheck' warning.
47148         * m4/fnmatch_h.m4: New file.
47149         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Require gl_FNMATCH_H. Remove
47150         code that is moved to fnmatch_h.m4. When fnmatch does not exist, don't
47151         bother testing whether it is working. Set HAVE_FNMATCH, REPLACE_FNMATCH
47152         as appropriate.
47153         * modules/fnmatch-h: New file.
47154         * modules/fnmatch (Files): Remove lib/fnmatch.in.h.
47155         (Dependencies): Add fnmatch-h. Remove extensions, snippet/*. Change
47156         conditions.
47157         (configure.ac): Test HAVE_FNMATCH and REPLACE_FNMATCH. Set module
47158         indicator.
47159         (Makefile.am): Remove code that is moved to fnmatch-h.
47160         * modules/fnmatch-gnu (configure.ac): Test HAVE_FNMATCH and
47161         REPLACE_FNMATCH.
47162         * doc/posix-headers/fnmatch.texi: Mention the 'fnmatch-h' module.
47163         * modules/posixcheck (Depends-on): Add fnmatch-h.
47165 2018-08-06  Bruno Haible  <bruno@clisp.org>
47167         Enable more C++ tests.
47168         * modules/inttypes-tests (Depends-on): Add inttypes-c++-tests.
47169         * modules/monetary-tests (Depends-on): Add monetary-c++-tests.
47170         * modules/strings-tests (Depends-on): Add strings-c++-tests.
47171         * modules/sys_resource-tests (Depends-on): Add sys_resource-c++-tests.
47172         * modules/utime-h-tests (Depends-on): Add utime-h-c++-tests.
47174 2018-08-06  Bruno Haible  <bruno@clisp.org>
47176         getopt-posix, utime-h: Ensure the .h file gets regenerated when needed.
47177         * modules/getopt-posix (Makefile.am): Add Makefile dependency for
47178         getopt.h.
47179         * modules/utime-h (Makefile.am): Add Makefile dependency for utime.h.
47181 2018-08-05  Bruno Haible  <bruno@clisp.org>
47183         utime-h: Generate header file when module 'posixcheck' is in use.
47184         * m4/utime_h.m4 (gl_UTIME_H): If module 'posixcheck' is in use, set
47185         UTIME_H to non-empty.
47187 2018-08-05  Bruno Haible  <bruno@clisp.org>
47189         monetary: Generate header file when module 'posixcheck' is in use.
47190         * m4/monetary_h.m4 (gl_MONETARY_H_BODY): If module 'posixcheck' is in
47191         use, set MONETARY_H to non-empty.
47193 2018-08-05  Bruno Haible  <bruno@clisp.org>
47195         iconv-h: Generate header file when module 'posixcheck' is in use.
47196         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): If module 'posixcheck' is in use,
47197         set ICONV_H to non-empty.
47199 2018-08-05  Bruno Haible  <bruno@clisp.org>
47201         Optimize the "checking whether ... is declared without a macro" checks.
47202         Suggested by Paul Eggert in
47203         <https://lists.gnu.org/archive/html/bug-gnulib/2011-01/msg00339.html>.
47204         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Expand to nothing if the
47205         Gnulib module 'posixcheck' is not in use.
47207 2018-08-05  Bruno Haible  <bruno@clisp.org>
47209         iconv-h: Enable 'posixcheck' warnings.
47210         * m4/iconv_h.m4 (gl_ICONV_H): Check for declarations of iconv and
47211         iconv_open.
47212         * lib/iconv.in.h (iconv_open, iconv): Use _GL_WARN_ON_USE.
47214 2018-08-05  Bruno Haible  <bruno@clisp.org>
47216         Fix link error regarding 'rpl_environ' (regression from 2012-11-21).
47217         * m4/extern-inline.m4: Add more comments.
47218         * lib/warn-on-use.h (_GL_WARN_ON_USE_ATTRIBUTE): New macro.
47219         * lib/unistd.in.h (rpl_environ): Use it instead of _GL_WARN_ON_USE.
47220         * lib/math.in.h (_GL_WARN_REAL_FLOATING_DECL): Likewise.
47222 2018-08-04  Bruno Haible  <bruno@clisp.org>
47224         New module 'posixcheck'.
47225         * modules/posixcheck: New file.
47226         * m4/posixcheck.m4: New file.
47227         * doc/gnulib-tool.texi (Finding POSIX substitutes): New section.
47228         (Which modules?): Reference it.
47230 2018-08-01  Assaf Gordon  <assafgordon@gmail.com>
47232         dfa: fix memory leak
47233         * lib/dfa.c (dfafree): Add missing free() on dfa->superset.
47235 2018-08-01  Paul Eggert  <eggert@cs.ucla.edu>
47237         ieee754-h: new module
47238         It looks like Emacs can use this for some NaN processing.
47239         Emacs uses it only on double NaNs so it should be safe.
47240         * MODULES.html.sh (func_all_modules): Add ieee754-h.
47241         * config/srclist.txt: Mention ieee754.h in a comment.
47242         * doc/glibc-headers/ieee754.texi (ieee754.h):
47243         Gnulib now has a substitute that should work
47244         except for long double and for non-IEEE platforms.
47245         * lib/ieee754.in.h, m4/ieee754-h.m4, modules/ieee754-h:
47246         * modules/ieee754-h-tests, tests/test-ieee754-h.c: New files.
47248 2018-07-27  Bruno Haible  <bruno@clisp.org>
47250         iswcntrl: Mention minor problem on macOS.
47251         * doc/posix-functions/iswcntrl.texi: Mention oddity on macOS.
47253 2018-07-26  Colin Watson  <cjwatson@debian.org>
47255         bootstrap, gnulib-tool: fix translations rsync
47256         Previously, we created files such as $pobase/Makefile.in.in and then the
47257         subsequent rsync would immediately delete them.
47258         * build-aux/bootstrap (po_download_command_format): Avoid deleting
47259         non-.po files in target directory when rsyncing translations.
47260         * gnulib-tool (func_import): Likewise.
47261         * pygnulib/GLImport.py (GLImport.execute): Likewise.
47263 2018-07-25  Jim Meyering  <meyering@fb.com>
47265         bootstrap: reinstate definition fo gnulib_mk.
47266         That variable is used at least by cppi.
47267         * build-aux/bootstrap (gnulib_mk): Restore definition.
47268         This reverts the deletion from v0.1-1844-gc66dba9ba.
47270 2018-07-23  Bruno Haible  <bruno@clisp.org>
47272         doc: For module names, use texinfo markup @code{} or @samp{}.
47273         * doc/alloca.texi: Mark gnulib module names with @code.
47274         * doc/alloca-opt.texi: Likewise.
47275         * doc/quote.texi: Likewise.
47276         * doc/posix-functions/freopen.texi: Likewise.
47277         * doc/posix-functions/open.texi: Likewise.
47278         * doc/posix-functions/readlink.texi: Likewise.
47279         * doc/posix-functions/readlinkat.texi: Likewise.
47280         * doc/posix-functions/stdout.texi: Likewise.
47281         * doc/posix-functions/stderr.texi: Likewise.
47282         * doc/posix-functions/unlink.texi: Likewise.
47283         * doc/posix-functions/unlinkat.texi: Likewise.
47284         * doc/posix-functions/utime.texi: Likewise.
47285         * doc/posix-functions/utimensat.texi: Likewise.
47286         * doc/posix-functions/utimes.texi: Likewise.
47287         * doc/posix-headers/stdint.texi: Likewise.
47288         * doc/glibc-functions/futimesat.texi: Likewise.
47289         * doc/glibc-functions/lutimes.texi: Likewise.
47290         * doc/glibc-functions/memmem.texi: Likewise.
47292 2018-07-23  Werner LEMBERG  <wl@gnu.org>
47294         doc: Avoid some overfull lines in the TeX output.
47295         * doc/glibc-functions/futimesat.texi: Replace a long @code with a
47296         @example.
47297         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Insert a
47298         newline before the long URL.
47299         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Likewise.
47300         * doc/relocatable-maint.texi: Use @smallexample instead of @example.
47301         Add line breaks in code snippets.
47303 2018-07-17  Paul Eggert  <eggert@cs.ucla.edu>
47305         hard-locale: simplify by removing hard-locale.m4
47306         * m4/hard-locale.m4: Remove.
47307         * modules/hard-locale (Files): Remove m4/hard-locale.m4.
47308         (configure.ac): Do not call gl_HARD_LOCALE.
47310         gnulib-tool: limit line length for git send-email
47311         * gnulib-tool (func_import): Break actioncmd log line
47312         into multiple lines.
47314 2018-07-16  Bruno Haible  <bruno@clisp.org>
47316         ffs: Ensure declaration on mingw.
47317         Reported by Daniel P. Berrangé <berrange@redhat.com>
47318         in https://lists.gnu.org/archive/html/bug-gnulib/2018-07/msg00061.html.
47319         * m4/ffs.m4 (gl_FUNC_FFS): Check whether ffs() not only exists but is
47320         also declared.
47322 2018-07-13  Paul Eggert  <eggert@cs.ucla.edu>
47324         regex-tests: add dependency
47325         * modules/regex-tests (Depends-on): Add gettext-h.
47326         This is needed given the recent changes to regex,
47327         which no longer depends on gettext-h.
47329 2018-07-06  Paul Eggert  <eggert@cs.ucla.edu>
47331         regex: now in sync with glibc
47332         * config/srclist.txt: Gnulib and glibc regex code
47333         are synchronized again.
47335 2018-07-05  Paul Eggert  <eggert@cs.ucla.edu>
47337         renameatu: rename from renameat2
47338         It's looking like Glibc will add a renameat2 function
47339         that is incompatible with Gnulib renameat2; see:
47340         https://sourceware.org/ml/libc-alpha/2018-07/msg00064.html
47341         To help avoid future confusion, rename renameat2 to something else.
47342         Use the name 'renameatu', as the Gnulib function is close to the
47343         Glibc function.  Perhaps someday there will also be a renameat2
47344         Gnulib module, which mimicks the future glibc renameat2, but that
47345         can wait as nobody seems to need such a module now.
47346         * NEWS: Mention this.
47347         * lib/renameatu.c: Rename from lib/renameat2.c.
47348         * lib/renameatu.h: Rename from lib/renameat2.h.
47349         * modules/renameatu: Rename from modules/renameat2.
47350         * modules/renameatu-tests: Rename from modules/renameat2-tests.
47351         All uses of "renameat2" in identifiers or file name
47352         changed to "renameatu", except for two instances in
47353         lib/renameatu.c that deal with the Linux kernel's
47354         renameat2 syscall.
47356 2018-07-04  Paul Eggert  <eggert@cs.ucla.edu>
47358         gnulib-tool: minor tweaks for --gnu-make
47359         * gnulib-tool: Do not allow --gnu-make in test modes,
47360         since they all require automake.
47361         (func_emit_lib_Makefile_am): Don’t emit automake comment
47362         if --gnu-make.
47364         regex: work around conditional-dependencies glitch
47365         * modules/regex (Depends-on): Add langinfo.
47366         Without this change, I had problems building an experimental
47367         version of GNU Emacs.  The symptom of the bug was a message
47368         ‘./configure: line 12726: test: =: unary operator expected’.
47369         This was due to a line in gl_FUNC_NL_LANGINFO that invokes
47370         ‘test $HAVE_LANGINFO_CODESET = 1’ even though HAVE_LANGINFO_CODESET
47371         was unset.  Although gl_FUNC_NL_LANGINFO has
47372         ‘AC_REQUIRE([gl_LANGINFO_H])’ and gl_LANGINFO_H always sets
47373         HAVE_LANGINFO_CODESET to 0 or 1, gnulib-tool with
47374         --conditional-dependencies sometimes arranges for the
47375         gl_FUNC_NL_LANGINFO code to be executed before the gl_LANGINFO_H
47376         code.  Since the regex code includes <langinfo.h> it should be
47377         depending on the langinfo module anyway, and this happens to work
47378         around the bug, so install that as a workaround for now.  To
47379         reproduce the original problem, run the following shell script on
47380         the version of Gnulib just before this patch was installed.
47381                 rm -fr foo
47382                 mkdir foo
47383                 cat >foo/configure.ac <<'EOF'
47384                 AC_INIT(GNU Emacs, 27.0.50, bug-gnu-emacs@gnu.org, , https://www.gnu.org/software/emacs/)
47385                 gl_EARLY
47386                 gl_INIT
47387                 AC_OUTPUT
47388                 EOF
47389                 ./gnulib-tool --import --conditional-dependencies --gnu-make --dir foo regex
47390                 ./gnulib-tool --copy build-aux/install-sh foo/install-sh
47391                 ./gnulib-tool --copy build-aux/config.sub foo/config.sub
47392                 ./gnulib-tool --copy build-aux/config.guess foo/config.guess
47393                 cd foo
47394                 aclocal -I m4
47395                 autoconf
47396                 ./configure --with-included-regex
47398 2018-07-01  Paul Eggert  <eggert@cs.ucla.edu>
47400         wchar: fix bug when checking for ‘inline’
47401         I discovered this when looking into using the regex module
47402         with Emacs.
47403         * m4/wchar_h.m4 (gl_WCHAR_H_INLINE_OK): Fix bug introduced in
47404         2016-08-17T23:09:38Z!skunk@iSKUNK.ORG; the code compiled
47405         conftest1.c and conftest2.c but these files were not created.
47406         As far as I can see, this check never worked and nobody reported
47407         it until now, which is a bit worrisome.
47409 2018-06-30  Jim Meyering  <meyering@fb.com>
47411         bootstrap: s/--option val/--option=val/
47412         * build-aux/bootstrap (gnulib_tool_options): Change the
47413         spelling of "--option val" pairs to "--option=val", for
47414         aesthetics, and also so that this file no longer triggers
47415         a common help2man syntax-check warning when copied into
47416         projects like grep, gzip, etc.
47418 2018-07-01  Paul Eggert  <eggert@cs.ucla.edu>
47420         manywarnings: omit -Wswitch-default
47421         This should make things more consistent, as we already ignore
47422         -Wswitch-enum.  Problem reported by Reuben Thomas; see:
47423         https://lists.gnu.org/r/bug-gnulib/2018-05/msg00179.html
47424         * build-aux/g++-warning.spec, build-aux/gcc-warning.spec:
47425         Add -Wswitch-default.
47426         * m4/manywarnings-c++.m4 (gl_MANYWARN_ALL_GCC_CXX_IMPL):
47427         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
47428         Remove -Wswitch-default.
47430         regex: revert most trimming
47431         Problems reported by Bruno Haible in:
47432         https://lists.gnu.org/r/bug-gnulib/2018-07/msg00001.html
47433         * modules/regex (Depends-on): Add lock, memcmp, memmove,
47434         and wctype back in.  lock because regex users shouldn’t
47435         need to know that regex needs locking, and the rest because
47436         gnulib-tool should ordinarily ignore them anyway.
47438 2018-06-30  Paul Eggert  <eggert@cs.ucla.edu>
47440         regex: trim module dependencies
47441         * modules/regex (Depends-on): Remove gettext-h and lock,
47442         since the regex code should work OK without these modules,
47443         and Emacs uses it that way.  Also remove memcmp, memmove,
47444         and wctype, as these modules are obsolete and should not be
47445         needed any more.
47447 2018-06-29  Paul Eggert  <eggert@cs.ucla.edu>
47449         regex: glibc does not use intprops.h
47450         Maybe we can talk glibc into using intprops.h someday, but
47451         now doesn’t seem to be a good time.
47452         * lib/regcomp.c (TYPE_SIGNED): Remove; regex_internal.h now defines.
47453         * lib/regex_internal.h [_LIBC]: Do not include intprops.h.
47454         (TYPE_SIGNED, INT_ADD_WRAPV): New macros.
47456 2018-06-28  Paul Eggert  <eggert@cs.ucla.edu>
47458         regex: port to recently proposed glibc regex merge
47459         This patch is inspired by Adhemerval Zanella's recent proposal
47460         https://www.sourceware.org/ml/libc-alpha/2018-06/msg00905.html
47461         to merge glibc and Gnulib regex.  It aims to simplify the merge on
47462         the glibc side, without keeping Gnulib portable.
47463         * lib/regex.h: Fix a problem with glibc installed-header checking,
47464         as follows:
47465         (_Restrict_): Prefer __restrict if defined or if GCC 2.95 or later.
47466         (_Restrict_arr_): Prefer __restrict_arr if defined,
47467         otherwise prefer _Restrict_ if C99 or GCC 3.1 or later (but not C++).
47468         * lib/regex_internal.c (re_string_realloc_buffers, build_wcs_buffer)
47469         (build_wcs_upper_buffer, build_upper_buffer)
47470         (re_string_translate_buffer, re_string_context_at):
47471         Move decls here from lib/regex_internal.h, for glibc internal tests.
47472         (build_wcs_upper_buffer): Use __wcrtomb, not wcrtomb, fixing
47473         glibc BZ #18496.
47474         * lib/regex_internal.h (lock_fini) [_LIBC]: Cast to 0 to pacify
47475         -Wunused-value.
47476         (bitset_set, bitset_clear, bitset_contain, bitset_empty)
47477         (bitset_set_all, bitset_copy, bitset_not, bitset_merge)
47478         (bitset_mask): Now static inline, and without any __attribute__
47479         ((unused)) decoration, for glibc internal tests.
47481 2018-06-25  Bruno Haible  <bruno@clisp.org>
47483         threadlib: Fix LIBMULTITHREAD on platforms where --as-needed is enabled.
47484         Reported by Erik Auerswald <auerswal@unix-ag.uni-kl.de>
47485         in <https://lists.gnu.org/archive/html/coreutils/2018-06/msg00063.html>.
47486         * m4/threadlib.m4 (gl_THREADLIB_BODY): Check whether the linker supports
47487         --as-needed/--no-as-needed and --push-state/--pop-state. When defining
47488         USE_POSIX_THREADS_WEAK or USE_SOLARIS_THREADS_WEAK or
47489         USE_PTH_THREADS_WEAK, define LIBMULTITHREAD in such a way that -lpthread
47490         / -lthread / -lpth does not get optimized away by a preceding
47491         --as-needed option.
47493 2018-06-25  Bruno Haible  <bruno@clisp.org>
47495         Continue to use spaces for indentation, not tabs.
47496         * MODULES.html.sh: Untabify.
47497         * doc/regex.texi: Likewise.
47498         * lib/acl-internal.c: Likewise.
47499         * lib/dfa.c: Likewise.
47500         * lib/exclude.c: Likewise.
47501         * lib/exclude.h: Likewise.
47502         * lib/get-permissions.c: Likewise.
47503         * lib/gettimeofday.c: Likewise.
47504         * lib/parse-datetime.y: Likewise.
47505         * lib/pselect.c: Likewise.
47506         * lib/set-permissions.c: Likewise.
47507         * lib/time.in.h: Likewise.
47508         * m4/canonicalize.m4: Likewise.
47509         * m4/gc.m4: Likewise.
47510         * m4/gnulib-common.m4: Likewise.
47511         * m4/pthread_sigmask.m4: Likewise.
47512         * m4/vararrays.m4: Likewise.
47513         * tests/test-digest.h: Likewise.
47514         * tests/test-fcntl-h.c: Likewise.
47515         * tests/test-timespec.c: Likewise.
47516         * tests/uniwbrk/test-uc-wordbreaks.c: Likewise.
47518 2018-06-25  Bruno Haible  <bruno@clisp.org>
47520         manywarnings: Don't enable -Wjump-misses-init warnings by default.
47521         * build-aux/gcc-warning.spec: Add -Wjump-misses-init.
47522         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C)): Remove
47523         -Wjump-misses-init.
47525 2018-06-25  Jim Meyering  <meyering@fb.com>
47527         acl-internal.h: remove _GL_ATTRIBUTE_CONST on void function
47528         * lib/acl-internal.h (free_permission_context): Remove that
47529         attribute directive.  Otherwise, it would provoke this from GCC 9:
47530         lib/acl-internal.h:300:3: error: 'const' attribute on function \
47531           returning 'void' [-Werror=attributes]
47533 2018-06-24  Jim Meyering  <meyering@fb.com>
47535         parse-datetime: accommodate gcc-4.8.5
47536         Bruno Haible reported the build failure in
47537         https://lists.gnu.org/r/bug-gnulib/2018-06/msg00066.html
47538         * lib/parse-datetime.y (parse_datetime2): Remove leading "static"
47539         on declaration of new local.
47541 2018-06-24  Bruno Haible  <bruno@clisp.org>
47543         af_alg: Fail in continuable manner on Linux/powerpc64le.
47544         Reported by Assaf Gordon <assafgordon@gmail.com>
47545         in <https://lists.gnu.org/archive/html/coreutils/2018-06/msg00034.html>.
47546         * lib/af_alg.c (afalg_stream): On non-seekable streams, try a single-
47547         byte send() as the first round.
47549 2018-06-24  Bruno Haible  <bruno@clisp.org>
47551         af_alg: Fix state of stream after sendfile() succeeds.
47552         * lib/af_alg.c (afalg_stream): Invoke fflush and lseek, to ensure that
47553         the stream is correctly positioned afterwards.
47554         * modules/crypto/af_alg (Depends-on): Add fflush.
47555         * tests/test-digest.h (test_digest_on_files): Verify that after the
47556         operation the stream is positioned at end of file.
47558 2018-06-24  Jim Meyering  <meyering@fb.com>
47560         canon-host: take GCC9's advice rather than ignoring warning
47561         Pádraig Brady suggested not to ignore this GCC9 advice.
47562         * lib/canon-host.c: Undo preceding change.
47563         * lib/canon-host.h: Instead, declare with _GL_ATTRIBUTE_MALLOC.
47565         parse-datetime.y: avoid spurious GCC 9 warning
47566         * lib/parse-datetime.y (parse_datetime2): Save RELATIVE_TIME_0 into
47567         a function local prior to the first "goto fail".  The prior use would
47568         evoke this:
47569         parse-datetime.y: In function 'parse_datetime2':
47570         parse-datetime.y:1791:19: error: jump skips variable initialization \
47571           [-Werror=jump-misses-init]
47572         parse-datetime.y:2385:2: note: label 'fail' defined here
47573         parse-datetime.y:188:43: note: '({anonymous})' declared here
47574         parse-datetime.y:1841:12: note: in expansion of macro 'RELATIVE_TIME_0'
47576         canon-host.c: avoid spurious GCC 9 warning
47577         * lib/canon-host.c: Suppress GCC9's -Wsuggest-attribute=malloc.
47579         manywarnings: accommodate GCC 9.0-pre: remove -Wchkp and -Wabi
47580         * build-aux/gcc-warning.spec: Add them here, each with an explanation.
47581         * m4/manywarnings.m4: Remove them.
47582         Otherwise, building coreutils, I would see this:
47583         cc1: error: deprecated command line option '-Wchkp' [-Werror]
47584         cc1: error: -Wabi won't warn about anything [-Werror=abi]
47585         cc1: note: -Wabi warns about differences from the most up-to-date ABI,\
47586           which is also used by default
47587         cc1: note: use e.g. -Wabi=11 to warn about changes from GCC 7
47589 2018-06-24  Bruno Haible  <bruno@clisp.org>
47591         af_alg tests: Add another test.
47592         * tests/test-digest.h (test_digest_on_files): Also check a large file
47593         with a skipped header.
47594         * tests/test-md5.c: Include macros.h.
47595         * tests/test-sha1.c: Likewise.
47596         * tests/test-sha256.c: Likewise.
47597         * tests/test-sha512.c: Likewise.
47598         * modules/crypto/md5-tests (Files): Add tests/macros.h.
47599         * modules/crypto/sha1-tests (Files): Likewise.
47600         * modules/crypto/sha256-tests (Files): Likewise.
47601         * modules/crypto/sha512-tests (Files): Likewise.
47603 2018-06-24  Pádraig Brady  <P@draigBrady.com>
47605         maint: clarify comments about sticky EOF
47606         * lib/af_alg.c: Be more direct that we can't
47607         assume stickiness of EOF for portability reasons.
47608         * lib/md5.c: Clarify that this isn't just a glibc issue.
47609         * lib/sha1.c: Likewise.
47610         * lib/sha256.c: Likewise.
47611         * lib/sha512.c: Likewise.
47613 2018-06-24  Bruno Haible  <bruno@clisp.org>
47615         af_alg: Comment and style improvements.
47616         * lib/af_alg.c (alg_socket): Use 'size_t' as index into a string.
47617         (afalg_buffer, afalg_stream): Improve comments.
47619 2018-06-24  Pádraig Brady  <P@draigBrady.com>
47621         af_alg: disable kernel hash functions by default
47622         All the kernel routines were seen to be significantly slower
47623         with these relatively recent components on an i3-2310M system:
47624           kernel-4.10.6-200.fc25.x86_64
47625           openssl-1.0.2m-1.fc25.x86_64
47626         sha1 was nearly twice as slow in the kernel for example.
47627         Further considerations why this should not be the default, at:
47628         https://lists.gnu.org/r/coreutils/2018-06/msg00034.html
47630         * m4/af_alg.m4: Require --with-linux-crypto to enable.
47631         * m4/gl-openssl.m4: Tweak accordingly.
47633 2018-06-24  Pádraig Brady  <P@draigBrady.com>
47635         af_alg: avoid hangs when reading from streams
47636         * lib/af_alg.c (afalg_stream): Don't assume EOF is sticky,
47637         and thus avoid doing a fread() when feof() is set.
47638         * lib/md5.c: Ensure feof() is called before fread().
47639         * lib/sha1.c: Likewise.
47640         * lib/sha256.c: Likewise.
47641         * lib/sha512.c: Likewise.
47643 2018-06-24  Pádraig Brady  <P@draigBrady.com>
47645         af_alg: fix error handling when hash not returned
47646         * lib/af_alg.c (afalg_stream): Handle the case where we've
47647         successfully written data to the kernel in the read/write loop,
47648         but the kernel doesn't respond with the hash.
47650 2018-06-24  Paul Eggert  <eggert@cs.ucla.edu>
47652         libc-config: merge from glibc
47653         * lib/cdefs.h (__inline, __restrict):
47654         Copy from current glibc.  This fixes glibc bug 17721,
47655         which Gnulib had already fixed in a different way.
47656         (__nonnull): Lessen the distance from glibc by using the
47657         glibc definition inside an ‘#ifndef __nonnull’.
47658         (__attribute_nonstring__): New macro, copied from
47659         current glibc.
47660         * lib/libc-config.h (__attribute_nonstring__): New undef.
47661         (__restrict): Remove; workaround no longer needed.
47662         Keep the __inline workaround, though, as it uses HAVE___INLINE to
47663         support more compilers than the glibc __inline can.
47665 2018-06-24  Bruno Haible  <bruno@clisp.org>
47667         mbrtowc, wcwidth: Fix MT-safety bug (regression from 2018-06-23).
47668         * lib/mbrtowc.c (enc_t): New enum type.
47669         (locale_enc, locale_enc_cached): New functions.
47670         (mbrtowc): Eliminate static variables. Use locale_enc_cached instead.
47671         * lib/wcwidth.c (is_locale_utf8, is_locale_utf8_cached): New functions.
47672         (wcwidth): Eliminate static variables. Use is_locale_utf8_cached
47673         instead.
47674         * m4/mbrtowc.m4 (gl_PREREQ_MBRTOWC): Require AC_C_INLINE.
47675         * m4/wcwidth.m4 (gl_PREREQ_WCWIDTH): New macro.
47676         * modules/wcwidth (configure.ac): Invoke it.
47678 2018-06-24  Bruno Haible  <bruno@clisp.org>
47680         wchar-single: Fix test failure in wcwidth tests.
47681         * tests/test-wcwidth.c (main): If the wchar-single module is present,
47682         skip the tests in the C locale.
47684 2018-06-23  Pádraig Brady  <P@draigBrady.com>
47686         crypto: mention --without-linux-crypto in --with-openssl --help
47687         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Mention that linux crypto
47688         routines take precedence in --with-openssl help output.
47690 2018-06-23  Pádraig Brady  <P@draigBrady.com>
47692         wchar-single: a new module to enable optimizations in wchar replacements
47693         * lib/mbrtowc.c (mbrtowc): Only check locale_charset() once if
47694         GNULIB_WCHAR_SINGLE is enabled.
47695         * lib/wcwidth.c (wcwidth): Likewise.
47697 2018-06-23  Bruno Haible  <bruno@clisp.org>
47699         libc-config: Fix conflict with FreeBSD include files.
47700         * lib/cdefs.h (__nonnull): Remove definition.
47701         * lib/libc-config.h (__nonnull): Remove undefinition.
47703 2018-06-21  Paul Eggert  <eggert@cs.ucla.edu>
47705         random_r: do not crash if state is unaligned
47706         Problem reported by Bruce Korb in:
47707         https://lists.gnu.org/r/bug-gnulib/2018-06/msg00030.html
47708         I reproduced the crash on 32-bit sparc with Oracle Studio 12.6
47709         with 'cc -O2 -xmemalign=8s'.
47710         * lib/random_r.c: Include string.h, for memcpy.
47711         (get_int32, set_int32): New functions.
47712         (__srandom_r, __initstate_r, __setstate_r, __random_r):
47713         Use them to avoid assumption that state pointer is aligned.
47714         (__random_r): Avoid integer overflow if INT_MAX == UINT32_MAX.
47715         * tests/test-random_r.c (test_failed): New function.
47716         (main): Use it, to test for alignment bugs.
47718         random_r: omit unnecessary include
47719         * lib/random_r.c: Do not include limits.h.
47721         random, random_r: merge from glibc
47722         * lib/random.c, lib/random_r.c:
47723         Include libc-config.h if !_LIBC, not config.h unilaterally.
47724         * lib/random.c:
47725         Do not include stdint.h or time.h; not needed.
47726         Include libc-lock.h if _LIBC, and define substitute macros otherwise.
47727         (unsafe_state): Rename from generator.  All uses changed.
47728         Use C99-style initializers.
47729         (__random, __srandom, __initstate, __setstate): Rename from
47730         non-underscored version, but define it to non-underscored version
47731         on Gnulib.  Add a lock.
47732         * lib/random_r.c (__srandom_r, __initstate_r, __setstate_r, __random_r):
47733         Likewise.
47734         Do not include <stdint.h>; not needed since stdlib.h defines int32_t.
47735         (weak_alias, __set_errno) [!_LIBC]: Remove; now done by libc-config.
47736         (__srandom_r): Use int32_t instead of long int where int32_t will do.
47737         (__random_r): Use uint32 to fix glibc bug 17343.
47738         * modules/random, modules/random_r (Depends-on): Add libc-config.
47739         Depend on stdint only if $HAVE_RANDOM = 0.
47741 2018-06-19  Jim Meyering  <meyering@fb.com>
47743         README-release: also run any check-very-expensive tests
47744         * top/README-release: Adjust instructions so they run the
47745         check-very-expensive tests when there is such a target.
47747 2018-06-18  Bruno Haible  <bruno@clisp.org>
47749         pthread_rwlock_rdlock: Add comments regarding glibc behaviour.
47750         * m4/pthread_rwlock_rdlock.m4: Add comment.
47751         * doc/posix-functions/pthread_rwlock_rdlock.texi: Mention that rwlocks
47752         are reader-preferring in glibc.
47753         * doc/posix-functions/pthread_rwlock_tryrdlock.texi: Likwise.
47754         * doc/posix-functions/pthread_rwlock_timedrdlock.texi: Likewise.
47756 2018-06-17  Paul Eggert  <eggert@cs.ucla.edu>
47758         crypto: use byteswap
47759         * lib/md4.c, lib/md5.c, lib/sha1.c, lib/sha256.c, lib/sha512.c:
47760         * lib/sm3.c: Include <byteswap.h>.
47761         (SWAP): Use its macros rather than reinventing the wheel.
47762         * modules/crypto/md4, modules/crypto/md5-buffer:
47763         * modules/crypto/sha1-buffer, modules/crypto/sha256-buffer:
47764         * modules/crypto/sha512-buffer, modules/crypto/sm3:
47765         (Depends-on): Add byteswap.
47767 2018-06-17  Pádraig Brady  <P@draigBrady.com>
47769         gendocs.sh: fix support for legacy --texi2html
47770         * build-aux/gendocs.sh: Restrict use of TOP_NODE_UP_URL
47771         to the default makeinfo invocation.
47772         Reported by Bruce Korb
47774 2018-06-17  Bruno Haible  <bruno@clisp.org>
47776         gettext po infrastructure: Update from current gettext git.
47777         Reported by Akim Demaille <akim@lrde.epita.fr>.
47778         * build-aux/po/Makefile.in.in: Update from current gettext git.
47779         * build-aux/po/remove-potcdate.sin: Likewise.
47780         * config/srclist.txt: Temporarily disable sync for these files.
47782 2018-06-17  Bruno Haible  <bruno@clisp.org>
47784         getloadavg: Return 0 on Windows without Cygwin.
47785         * lib/getloadavg.c: Don't assume that the symbol WINDOWS32 is defined.
47787 2018-06-17  Paul Smith  <psmith@gnu.org>
47789         getloadavg: Allow building on Windows without Cygwin
47790         * lib/getloadavg.c: Reinstate ifdef for HAVE_UNISTD_H.
47791         * m4/getloadavg.m4: Check for unistd.h.
47793 2018-06-03  Paul Eggert  <eggert@cs.ucla.edu>
47795         Port crypto/af_alg to GCC 4.8.4
47796         Problem reported by Peter Simons in:
47797         https://lists.gnu.org/r/bug-gnulib/2018-06/msg00002.html
47798         * modules/crypto/af_alg (Depends-on): Add c99 if USE_AF_ALG.
47800 2018-05-27  Colin Watson  <cjwatson@debian.org>
47802         bootstrap: document source fetching in --help
47803         * build-aux/bootstrap (usage): Document how Gnulib sources are fetched.
47805 2018-04-09  Colin Watson  <cjwatson@debian.org>
47807         bootstrap: allow non-submodule control of gnulib
47808         * build-aux/bootstrap: Honour GNULIB_URL and GNULIB_REVISION in
47809         bootstrap.conf when fetching gnulib using "git clone" or via
47810         GNULIB_SRCDIR.
47812 2018-05-21  Paul Eggert  <eggert@cs.ucla.edu>
47814         crypto: omit stream ops Emacs doesn’t need
47815         * lib/md5.c (md5_stream):
47816         * lib/sha1.c (sha1_stream):
47817         * lib/sha256.c (shaxxx_stream, sha256_stream, sha224_stream):
47818         * lib/sha512.c (shaxxx_stream, sha512_stream, sha384_stream):
47819         Compile stream functions only if GL_COMPILE_CRYPTO_STREAM is
47820         defined.  Emacs needs this, as it does not use the stream
47821         operations and doesn’t need all the af_alg stuff we’ve recently
47822         added.  Perhaps a similar change is needed to the other crypto
47823         modules, but this patch changes only those needed for Emacs.
47824         * modules/crypto/md5-buffer, modules/crypto/sha1-buffer:
47825         * modules/crypto/sha256-buffer, modules/crypto/sha512-buffer:
47826         New modules, used by Emacs.
47827         * modules/crypto/md5, modules/crypto/sha1, modules/crypto/sha256:
47828         * modules/crypto/sha512: Rewrite to depend on the new modules.
47830 2018-05-20  Pádraig Brady  <P@draigBrady.com>
47832         fts: avoid a memory leak edge case
47833         * lib/fts.c (fts_open): Set an appropriate fts_level
47834         so that an immediate fts_close() will free the allocation.
47835         * tests/test-fts.c (fts_dealloc): Add a test case which
47836         will trigger under valgrind or address sanitizer.
47837         Fixes https://bugs.gnu.org/31439
47839 2018-05-20  Bruno Haible  <bruno@clisp.org>
47841         wcwidth tests: Fix link error.
47842         * modules/wcwidth-tests (Makefile.am): Link test-wcwidth against
47843         $(LIBUNISTRING).
47845 2018-05-20  Bruno Haible  <bruno@clisp.org>
47847         regex: Fix "error: possibly undefined macro: gl_GLIBC21".
47848         * modules/regex (Files): Add m4/glibc21.m4.
47850 2018-05-20  Bruno Haible  <bruno@clisp.org>
47852         localcharset: Optimize.
47853         * lib/localcharset.c (alias_table): Comment out no-op mappings for
47854         platforms where these don't matter. This reduces the table size,
47855         which in turn reduces the lookup time.
47857 2018-05-19  Bruno Haible  <bruno@clisp.org>
47859         localcharset: Map the locale encodings found in newer OSes.
47860         * lib/localcharset.c (alias_table): Add mapping for locale encodings
47861         found in FreeBSD 11, NetBSD 7, Solaris 10, Openindiana, HP-UX 11.31,
47862         IRIX 6.5, Minix 3.3.
47863         * lib/localcharset.h: Update comments accordingly. Also for Cygwin 2.9.
47865 2018-05-19  Bruno Haible  <bruno@clisp.org>
47867         localcharset: Move mapping tables into the code. Use a binary search.
47868         * lib/localcharset.h: Document the GNU canonical names for character
47869         encodings here.
47870         * lib/localcharset.c: Don't include <fcntl.h>, <unistd.h>,
47871         relocatable.h, configmake.h.
47872         (O_NOFOLLOW, ISSLASH, DIRECTORY_SEPARATOR, getc, volatile): Remove
47873         macros.
47874         (charset_aliases): Remove variable.
47875         (get_charset_aliases): Remove function.
47876         (struct table_entry): New type.
47877         (alias_table, locale_table): New constants.
47878         (locale_charset): Use the alias_table or locale_table to get the
47879         canonicalized encoding name.
47880         * lib/config.charset: Remove file.
47881         * lib/ref-add.sin: Remove file.
47882         * lib/ref-del.sin: Remove file.
47883         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't require gl_FCNTL_O_FLAGS,
47884         AC_CANONICAL_HOST, gl_GLIBC21. Don't check for getc_unlocked.
47885         * modules/localcharset (Notice): Remove.
47886         (Files): Remove config.charset, ref-add.sin, ref-del.sin, fcntl-o.m4,
47887         glibc21.m4.
47888         (Depends-on): Remove configmake.
47889         (configure.ac): Define LOCALCHARSET_TESTS_ENVIRONMENT to empty.
47890         (Makefile.am): Simplify.
47891         * build-aux/prefix-gnulib-mk: Remove special code for the removed files.
47893 2018-05-19  Bruno Haible  <bruno@clisp.org>
47895         localcharset: Add a manual test.
47896         * tests/test-localcharset.c: New file.
47897         * modules/localcharset-tests: New file.
47899 2018-05-19  Bruno Haible  <bruno@clisp.org>
47901         localcharset: Remove support for obsolete platforms.
47902         * lib/config.charset: Remove support for Linux/libc5, glibc-2.0.x, and
47903         Mac OS X 10.2. Comment out dubious entry for Solaris.
47905 2018-05-19  Jim Meyering  <meyering@fb.com>
47907         gnupload: adjust comment
47908         * build-aux/gnupload: Add FIXME-2020 comment, to make it slightly
47909         more likely we'll remove the just-added code in a year or two.
47911 2018-05-19  Bruno Haible  <bruno@clisp.org>
47913         gnupload: Fix "gpg-agent is not available in this session" error.
47914         * build-aux/gnupload (GPG): Pick the right GNUPG executable to use.
47916 2018-05-16  Paul Eggert  <eggert@cs.ucla.edu>
47918         crypto/af_alg: fix --help
47919         * m4/af_alg.m4: Avoid spurious newline in --help output.
47921 2018-05-13  Bruno Haible  <bruno@clisp.org>
47923         nl_langinfo: Fix compilation error on Android.
47924         * lib/nl_langinfo.c (nl_langinfo): Define values for the items GROUPING,
47925         INT_CURR_SYMBOL, etc. only if these items are defined.
47927 2018-05-13  Bruno Haible  <bruno@clisp.org>
47929         truncate: Fix compilation error on Android.
47930         * m4/truncate.m4 (gl_FUNC_TRUNCATE): Test also whether 'truncate' is
47931         declared. Set HAVE_DECL_TRUNCATE, not HAVE_TRUNCATE.
47932         * lib/unistd.in.h (truncate): Test HAVE_DECL_TRUNCATE, not
47933         HAVE_TRUNCATE.
47934         * modules/truncate: Likewise.
47935         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_TRUNCATE,
47936         not HAVE_TRUNCATE.
47937         * modules/unistd (Makefile.am): Substitute HAVE_DECL_TRUNCATE, not
47938         HAVE_TRUNCATE.
47939         * doc/posix-functions/truncate.texi: Mention the issue.
47941 2018-05-13  Bruno Haible  <bruno@clisp.org>
47943         pthread: Fix compilation error on Android.
47944         * lib/pthread.in.h: Use _GL_ALREADY_INCLUDING_PTHREAD_H to shortcut
47945         recursive inclusion of this file.
47947 2018-05-13  Bruno Haible  <bruno@clisp.org>
47949         posix_spawn: Fix compilation error on Android.
47950         * lib/spawn.in.h (posix_spawnattr_t): Consider also the case
47951         HAVE_POSIX_SPAWNATTR_T = 1 && HAVE_POSIX_SPAWN = 0.
47952         (posix_spawn_file_actions_t): Consider also the case
47953         HAVE_POSIX_SPAWN_FILE_ACTIONS_T = 1 && HAVE_POSIX_SPAWN = 0.
47955 2018-05-13  Bruno Haible  <bruno@clisp.org>
47957         tsearch: Move from K&R C to ANSI C.
47958         * lib/tsearch.c (tfind): Convert definition to ANSI C.
47960 2018-05-13  Bruno Haible  <bruno@clisp.org>
47962         tsearch: Fix compilation error on Android.
47963         * lib/search.in.h (twalk): Declare when HAVE_TWALK, not HAVE_TSEARCH,
47964         is 0.
47965         (GNULIB_defined_tsearch, GNULIB_defined_twalk): New macros.
47966         * lib/tsearch.c (tsearch, tfind, tdelete): Define only if
47967         GNULIB_defined_tsearch is true.
47968         (twalk): Define only if GNULIB_defined_twalk is true.
47969         * modules/tsearch (configure.ac): Compile tsearch.c also if HAVE_TWALK
47970         is 0.
47971         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Set HAVE_TWALK.
47972         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize HAVE_TWALK.
47973         * modules/search (Makefile.am): Substitute HAVE_TWALK.
47975 2018-05-13  Bruno Haible  <bruno@clisp.org>
47977         imaxdiv: Fix compilation error on Android.
47978         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Set HAVE_IMAXDIV_T to 0 if imaxdiv_t
47979         is not defined.
47980         * lib/inttypes.in.h (imaxdiv_t): Define if HAVE_IMAXDIV_T, not
47981         HAVE_DECL_IMAXDIV, is 0.
47982         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Initialize HAVE_IMAXDIV_T.
47983         * modules/inttypes-incomplete (Makefile.am): Substitute HAVE_IMAXDIV_T.
47985 2018-05-13  Bruno Haible  <bruno@clisp.org>
47987         Support selective inclusion mechanism of recent mingw.org header files.
47988         Reported by Eli Zaretskii <eliz@gnu.org>.
47989         * lib/sys_types.in.h: On mingw, when __need_off_t, __need___off64_t,
47990         __need_ssize_t, or __need_time_t is defined, just include the system's
47991         <sys/types.h>.
47992         * lib/locale.in.h: On mingw, when __need_locale_t is defined, just
47993         include the system's <locale.h>.
47995 2018-05-13  Bruno Haible  <bruno@clisp.org>
47997         Avoid compilation error due to 'mmap' on Android.
47998         * lib/vma-iter.c (_FILE_OFFSET_BITS): Undefine on Android.
47999         * lib/get-rusage-as.c (_FILE_OFFSET_BITS): Likewise.
48000         * tests/zerosize-ptr.h (_FILE_OFFSET_BITS, __USE_FILE_OFFSET64):
48001         Undefine on Android.
48003 2018-05-13  Bruno Haible  <bruno@clisp.org>
48005         Add cross-compilation guesses for Linux systems without glibc.
48006         * m4/chown.m4 (AC_FUNC_CHOWN): Add cross-compilation guess for Linux.
48007         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
48008         * m4/link.m4 (gl_FUNC_LINK): Likewise.
48009         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
48010         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
48011         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
48012         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
48013         * m4/mknod.m4 (gl_FUNC_MKNOD): Likewise.
48014         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
48015         * m4/readlink.m4 (gl_FUNC_READLINK): Likewise.
48016         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
48017         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
48018         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
48019         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
48020         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
48021         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
48022         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
48023         * m4/utimens.m4 (gl_UTIMENS): Likewise.
48025 2018-05-13  Bruno Haible  <bruno@clisp.org>
48027         getpagesize: Fix compilation error on Android.
48028         * m4/getpagesize.m4 (gl_CHECK_FUNC_GETPAGESIZE): New macro.
48029         (gl_FUNC_GETPAGESIZE): Invoke it instead of AC_CHECK_FUNC.
48030         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Don't invoke
48031         AC_CHECK_FUNC. Instead, invoke gl_CHECK_FUNC_GETPAGESIZE and define
48032         HAVE_GETPAGESIZE accordingly.
48033         * modules/getcwd (Files): Add m4/getpagesize.m4.
48035 2018-05-13  Bruno Haible  <bruno@clisp.org>
48037         tcgetsid: Fix compilation error on Android.
48038         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Use AC_LINK_IFELSE instead of
48039         AC_CHECK_FUNC.
48041 2018-05-13  Bruno Haible  <bruno@clisp.org>
48043         getpass: Fix configure test for Android.
48044         * m4/getpass.m4 (gl_PREREQ_GETPASS): Use AC_LINK_IFELSE instead of
48045         AC_CHECK_FUNC.
48047 2018-05-13  Bruno Haible  <bruno@clisp.org>
48049         ffs: Fix compilation error on Android.
48050         * m4/ffs.m4 (gl_FUNC_FFS): Use AC_LINK_IFELSE instead of AC_CHECK_FUNC.
48052 2018-05-13  Bruno Haible  <bruno@clisp.org>
48054         mkfifo: Fix compilation error on Android.
48055         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Use AC_LINK_IFELSE instead of
48056         AC_CHECK_FUNC.
48058 2018-05-13  Bruno Haible  <bruno@clisp.org>
48060         c-strtod: Fix configure test for Android.
48061         * m4/c-strtod.m4 (gl_C_STRTOD): Use AC_LINK_IFELSE instead of
48062         AC_CHECK_FUNC.
48064 2018-05-13  Bruno Haible  <bruno@clisp.org>
48066         random: Fix compilation error on Android.
48067         * m4/random.m4 (gl_FUNC_RANDOM): Use AC_LINK_IFELSE instead of
48068         AC_CHECK_FUNC.
48070 2018-05-13  Bruno Haible  <bruno@clisp.org>
48072         grantpt: Fix compilation error on Android.
48073         * m4/grantpt.m4 (gl_FUNC_GRANTPT): Use AC_LINK_IFELSE instead of
48074         AC_CHECK_FUNC.
48076 2018-05-13  Bruno Haible  <bruno@clisp.org>
48078         stdioext: Fix compilation errors with newer Android headers.
48079         * lib/stdio-impl.h (fp_, fp_ub): Define differently for Android.
48080         (__SLBF, __SNBF, __SRD, __SWR, __SRW, __SEOF, __SERR, __SOFF): Define
48081         fallbacks for Android.
48082         * lib/fpending.c: Update comments.
48083         * lib/fpurge.c: Likewise.
48084         * lib/freadable.h: Likewise.
48085         * lib/freadable.c: Likewise.
48086         * lib/freadahead.c: Likewise.
48087         * lib/freading.h: Likewise.
48088         * lib/freadptr.c: Likewise.
48089         * lib/fseterr.c: Likewise.
48090         * lib/fwritable.h: Likewise.
48091         * lib/fwritable.c: Likewise.
48092         * lib/fwriting.h: Likewise.
48093         * lib/fwriting.c: Likewise.
48095 2018-05-13  Bruno Haible  <bruno@clisp.org>
48097         doc: Add info about Android versions 2.0 to 8.1.
48098         * doc/**/*.texi: Add info about functions in all released versions of
48099         Bionic.
48101 2018-05-12  Bruno Haible  <bruno@clisp.org>
48103         fseeko: On mingw, don't use the hidden function _fseeki64.
48104         Reported by Eli Zaretskii <eliz@gnu.org>.
48105         * m4/fseeko.m4 (gl_PREREQ_FSEEKO): Test whether _fseeki64 is declared.
48106         * lib/fseeko.c (fseeko): Use _fseeki64 only if it is declared.
48108 2018-05-12  Bruno Haible  <bruno@clisp.org>
48110         glob: Choose 'dirent_type' in a way that works better on mingw.
48111         Reported and suggested by Eli Zaretskii <eliz@gnu.org>.
48112         * lib/glob.c (dirent_type): Define as uint_fast32_t.
48114 2018-05-12  Bruno Haible  <bruno@clisp.org>
48116         execute, spawn-pipe: Avoid warning about redefining 'close'.
48117         Reported by Eli Zaretskii <eliz@gnu.org>.
48118         * lib/execute.c: Undefine 'close' before redefining it.
48119         * lib/spawn-pipe.c: Likewise.
48121 2018-05-12  Bruno Haible  <bruno@clisp.org>
48123         nanosleep: Avoid test failure on mingw when it has nanosleep.
48124         Reported by Eli Zaretskii <eliz@gnu.org>.
48125         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check whether alarm() exists.
48126         If it does not exist, use a simpler test program that does not call
48127         alarm().
48129 2018-05-10  Bruno Haible  <bruno@clisp.org>
48131         lock, cond, thread, tls: Use a different symbol as libpthread witness.
48132         Reported by Devin Hussey <husseydevin@gmail.com>.
48133         Based on a patch by Paul Eggert.
48134         * lib/glthread/lock.h (pthread_in_use): Use 'pthread_mutexattr_gettype'
48135         as witness of libpthread.
48136         * lib/glthread/cond.h (pthread_in_use): Likewise.
48137         * lib/glthread/thread.h (pthread_in_use): Likewise.
48138         * lib/glthread/tls.h (pthread_in_use): Likewise.
48140 2018-05-10  Bruno Haible  <bruno@clisp.org>
48142         cond tests: Fix compilation error on Solaris.
48143         * tests/test-cond.c: Include <unistd.h> before defining 'yield' as a
48144         macro.
48146 2018-05-10  Bruno Haible  <bruno@clisp.org>
48148         doc: Add partial info about Android 4.3.
48149         * doc/*-functions/*.texi: Add info about functions that were added
48150         to Bionic between Android 4.3 and Android 9.0.
48152 2018-05-10  Bruno Haible  <bruno@clisp.org>
48154         doc: Add info about Android 9.0.
48155         * doc/**/*.texi: Add info about functions and headers in Bionic from
48156         Android 9.0.
48158 2018-05-09  Paul Eggert  <eggert@cs.ucla.edu>
48160         af_alg: fix my typo in afalg_buffer
48161         * lib/af_alg.c (afalg_buffer): Fix typo I recently introduced.
48162         (afalg_stream): Simplify and avoid the need for a runtime test
48163         at the end.
48165         af_alg: recover better from crypto failures
48166         * lib/af_alg.c (afalg_stream): Recover from crypto failures if the
48167         input stream is seekable, by repositioning the stream back to
48168         where it was, possibly by just calling sendfile with an offset
48169         arg.  This lets us return -EAFNOSUPPORT instead of -EIO in some
48170         cases, which lets our callers try again with user-mode code.
48171         * modules/crypto/af_alg (Depends-on): Depend on fseeko and ftello
48172         instead of on fflush and lseek.
48174         af_alg: distiguish I/O errors better
48175         * lib/af_alg.c (afalg_buffer, afalg_stream): Return -EAFNOSUPPORT,
48176         not -EIO, if it’s OK for the caller to try again with user-mode code.
48177         (afalg_stream) [!_WIN32 || __CYGWIN__]: Return -EIO (not possibly
48178         some other error number) if fflush fails, as the caller should not
48179         try again that case.
48181         af_alg: avoid gotos
48182         * lib/af_alg.c (afalg_buffer, afalg_stream): Rewrite to avoid
48183         gotos, as they were a source of unreliability and made the code a
48184         bit harder to follow.
48186         af_alg: don’t leak file descriptors into children
48187         * lib/af_alg.c (alg_socket): Use SOCK_CLOEXEC when creating sockets.
48188         This code should be compiled only on recent GNU/Linux platforms
48189         so we shouldn’t have to also depend on the accept4 module.
48191         af_alg: coalesce socket creation
48192         * lib/af_alg.c (alg_socket): New function.
48193         (afalg_buffer, afalg_stream): Use it.  This avoids some
48194         code duplication and gotos.
48196         af_alg: fix file descriptor leak
48197         * lib/af_alg.c (afalg_stream): Close leak.
48199         af_alg: Pacify --enable-gcc-warnings on GCC 8
48200         * lib/af_alg.c (afalg_buffer, afalg_stream): Reorder local decls
48201         and checking to pacify gcc -Wjump-misses-init on GCC 8.
48203 2018-05-07  Paul Eggert  <eggert@cs.ucla.edu>
48205         af_alg: Pacify --enable-gcc-warnings
48206         Problem reported by Assaf Gordon in:
48207         https://lists.gnu.org/r/bug-gnulib/2018-05/msg00041.html
48208         * lib/af_alg.c (afalg_buffer): Move local decls to pacify
48209         gcc -Wjump-misses-init.
48210         * lib/sha512.c (shaxxx_stream): Now static.
48212 2018-05-06  Bruno Haible  <bruno@clisp.org>
48214         af_alg: Add ability to use Linux kernel crypto API on data in memory.
48215         * lib/af_alg.h (afalg_buffer): New declaration.
48216         * lib/af_alg.c (afalg_buffer): New function.
48218 2018-05-06  Bruno Haible  <bruno@clisp.org>
48220         af_alg: Avoid warnings.
48221         * lib/af_alg.h (afalg_stream): Mark fallback declaration as inline.
48222         * m4/af_alg.m4 (gl_AF_ALG): Require AC_C_INLINE.
48224 2018-05-06  Bruno Haible  <bruno@clisp.org>
48226         crypto/{md5,sha1,sha256,sha512} tests: Add benchmarks.
48227         * tests/bench-digest.h: New file.
48228         * tests/bench-md5.c: New file.
48229         * tests/bench-sha1.c: New file.
48230         * tests/bench-sha224.c: New file.
48231         * tests/bench-sha256.c: New file.
48232         * tests/bench-sha384.c: New file.
48233         * tests/bench-sha512.c: New file.
48234         * modules/crypto/md5-tests (Files): Add tests/bench-md5.c,
48235         tests/bench-digest.h.
48236         (Depends-on): Add getrusage, gettimeofday.
48237         (Makefile.am): Add variables to build bench-md5.
48238         * modules/crypto/sha1-tests (Files): Add tests/bench-sha1.c,
48239         tests/bench-digest.h.
48240         (Depends-on): Add getrusage, gettimeofday.
48241         (Makefile.am): Add variables to build bench-sha1.
48242         * modules/crypto/sha256-tests (Files): Add tests/bench-sha224.c,
48243         tests/bench-sha256.c, tests/bench-digest.h.
48244         (Depends-on): Add getrusage, gettimeofday.
48245         (Makefile.am): Add variables to build bench-sha224, bench-sha256.
48246         * modules/crypto/sha512-tests (Files): Add tests/bench-sha384.c,
48247         tests/bench-sha512.c, tests/bench-digest.h.
48248         (Depends-on): Add getrusage, gettimeofday.
48249         (Makefile.am): Add variables to build bench-sha384, bench-sha512.
48251 2018-05-06  Bruno Haible  <bruno@clisp.org>
48253         af_alg: Fix a resource leak.
48254         * lib/af_alg.c (afalg_stream): Close socket before returning -EINVAL.
48255         New local variable 'result'.
48257 2018-05-06  Bruno Haible  <bruno@clisp.org>
48259         af_alg: Fix bug with streams that are not at position 0.
48260         * lib/af_alg.c (afalg_stream): Before sendfile, invoke fflush. Don't
48261         assume that the stream is positioned at position 0.
48262         * lib/af_alg.h (afalg_stream): Mention restriction regarding the state
48263         of the stream.
48264         * lib/md5.h (md5_stream): Likewise.
48265         * lib/sha1.h (sha1_stream): Likewise.
48266         * lib/sha256.h (sha256_stream, sha224_stream): Likewise.
48267         * lib/sha512.h (sha512_stream, sha384_stream): Likewise.
48268         * modules/crypto/af_alg (Depends-on): Add fflush, lseek.
48270         crypto/{md5,sha1,sha256,sha512} tests: Enhance test.
48271         * tests/test-digest.h (test_digest_on_files): Add a test with a FILE
48272         stream that is not positioned at the beginning.
48274 2018-05-06  Bruno Haible  <bruno@clisp.org>
48276         af_alg: Add configure option to enable/disable use of Linux crypto API.
48277         Suggested by Assaf Gordon <assafgordon@gmail.com>.
48278         * m4/af_alg.m4 (gl_AF_ALG): Add AC_ARG_WITH invocation. Define C macro
48279         USE_LINUX_CRYPTO_API.
48280         * lib/af_alg.h: Test USE_LINUX_CRYPTO_API, not HAVE_LINUX_IF_ALG_H.
48281         * lib/af_alg.c: Likewise.
48283 2018-05-06  Bruno Haible  <bruno@clisp.org>
48285         Followup to 'af_alg: New module.'.
48286         * modules/crypto/md5 (Depends-on): Remove sys_socket, sys_stat.
48287         * modules/crypto/sha1 (Depends-on): Likewise.
48288         * modules/crypto/sha256 (Depends-on): Likewise.
48289         * modules/crypto/sha512 (Depends-on): Likewise.
48291 2018-05-05  Paul Eggert  <eggert@cs.ucla.edu>
48293         crypto/{md5,sha1,sha256,sha512}: simplify
48294         * lib/md5.c (md5_stream):
48295         * lib/sha1.c (sha1_stream):
48296         * lib/sha256.c (shaxxx_stream):
48297         Simplify, partly by assuming C99.
48298         * lib/sha256.c (shaxxx_stream):
48299         New function, which implements both sha256 and sha224.
48300         Simplify, partly by assuming C99.
48301         (sha256_stream, sha224_stream):
48302         Use it to avoid code duplication, removing a FIXME.
48303         * lib/sha512.c (shaxxx_stream, sha512_stream, sha384_stream):
48304         Likewise.
48306         af_alg: Improve comments.
48307         * lib/af_alg.h: Use imperatives and tighten up wording.
48309 2018-05-05  Bruno Haible  <bruno@clisp.org>
48311         af_alg: Improve comments.
48312         * lib/af_alg.c (afalg_stream): Improve comment about kernel bug.
48314 2018-05-05  Bruno Haible  <bruno@clisp.org>
48316         af_alg: New module.
48317         * lib/af_alg.h: Test HAVE_* macro through '#if', not '#ifdef'.
48318         * lib/af_alg.c: Include "af_alg.h" before the other header files.
48319         * lib/md5.c: Include "af_alg.h" unconditionally.
48320         (md5_stream): Invoke afalg_stream unconditionally.
48321         * lib/sha1.c: Include "af_alg.h" unconditionally.
48322         (sha1_stream): Invoke afalg_stream unconditionally.
48323         * lib/sha256.c: Include "af_alg.h" unconditionally.
48324         (sha256_stream, sha224_stream): Invoke afalg_stream unconditionally.
48325         * lib/sha512.c: Include "af_alg.h" unconditionally.
48326         (sha512_stream, sha384_stream): Invoke afalg_stream unconditionally.
48327         * m4/af_alg.m4: Renamed from m4/linux-if-alg.m4.
48328         (gl_AF_ALG): Renamed from gl_LINUX_IF_ALG_H.
48329         * modules/crypto/af_alg: New file.
48330         * modules/crypto/md5 (Files): Remove files that are now in the
48331         'crypto/af_alg' module.
48332         (Depends-on): Add crypto/af_alg.
48333         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
48334         (Makefile.am): Don't mention af_alg.c here.
48335         * modules/crypto/sha1 (Files): Remove files that are now in the
48336         'crypto/af_alg' module.
48337         (Depends-on): Add crypto/af_alg.
48338         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
48339         (Makefile.am): Don't mention af_alg.c here.
48340         * modules/crypto/sha256 (Files): Remove files that are now in the
48341         'crypto/af_alg' module.
48342         (Depends-on): Add crypto/af_alg.
48343         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
48344         (Makefile.am): Don't mention af_alg.c here.
48345         * modules/crypto/sha512 (Files): Remove files that are now in the
48346         'crypto/af_alg' module.
48347         (Depends-on): Add crypto/af_alg.
48348         (configure.ac): Remove gl_LINUX_IF_ALG_H invocation.
48349         (Makefile.am): Don't mention af_alg.c here.
48351 2018-05-05  Paul Eggert  <eggert@cs.ucla.edu>
48353         crypto tests: pacify GCC
48354         * tests/test-digest.h (test_digest_on_files):
48355         Don’t assume digest size fits in int (!).
48357         af_alg: minor style improvements
48358         * lib/af_alg.c (afalg_stream): Prefer C99 style
48359         decl-after-statement, since we’re already assuming C99.  Clarify
48360         by strengthening the bind test and omit unnecessary assignment.
48362 2018-05-05  Bruno Haible  <bruno@clisp.org>
48364         af_alg: Fix bug on empty files.
48365         * lib/af_alg.c (afalg_stream): Ignore the kernel's result if the input
48366         stream is empty.
48368 2018-05-05  Paul Eggert  <eggert@cs.ucla.edu>
48370         sys-limits.h: new file for crypto and safe I/O
48371         * lib/af_alg.c: Include sys-limits.h.
48372         (MAX_RW_COUNT): Remove.  Use replaced by SYS_BUFSIZE_MAX.
48373         (afalg_stream): Also reject negative sizes for sendfile; they
48374         should not happen and the code is a bit cleaner and faster this way.
48375         * lib/safe-read.c: Include sys-limits.h.
48376         (BUGGY_READ_MAXIMUM): Remove.  All uses replaced by SYS_BUFSIZE_MAX.
48377         * lib/sys-limits.h: New file, with values and commentary derived
48378         from the old safe-read.c and from GNU Emacs sysdep.c.
48379         * modules/crypto/md5, modules/crypto/sha1, modules/crypto/sha256:
48380         * modules/crypto/sha512, modules/safe-read, modules/safe-write:
48381         Add lib/sys-limits.h to Files section.
48383 2018-05-05  Bruno Haible  <bruno@clisp.org>
48385         af_alg: Improve function signature.
48386         * lib/af_alg.h (afalg_stream): Swap second and third argument.
48387         * lib/af_alg.c (afalg_stream): Likewise.
48388         * lib/md5.c, lib/sha1.c, lib/sha256.c, lib/sha512.c: Callers changed.
48390 2018-05-05  Bruno Haible  <bruno@clisp.org>
48392         crypto/{md5,sha1,sha256,sha512}: Fix compilation error (S_TYPEISTMO).
48393         * modules/crypto/md5 (Depends-on): Add 'sys_stat'.
48394         * modules/crypto/sha1 (Depends-on): Likewise.
48395         * modules/crypto/sha256 (Depends-on): Likewise.
48396         * modules/crypto/sha512 (Depends-on): Likewise.
48398 2018-05-05  Bruno Haible  <bruno@clisp.org>
48400         crypto/{md5,sha1,sha256,sha512}: Fix module description.
48401         * modules/crypto/md5 (Depends-on): Add 'sys_socket'.
48402         * modules/crypto/sha1 (Depends-on): Likewise.
48403         * modules/crypto/sha256 (Depends-on): Likewise.
48404         * modules/crypto/sha512 (Depends-on): Likewise.
48406 2018-05-05  Bruno Haible  <bruno@clisp.org>
48408         af_alg: Add documentation.
48409         * lib/af_alg.h: Add comments.
48411 2018-05-05  Bruno Haible  <bruno@clisp.org>
48413         sha512: Add tests.
48414         * tests/test-sha512.c: New file.
48415         * modules/crypto/sha512-tests: New file.
48417 2018-05-05  Bruno Haible  <bruno@clisp.org>
48419         sha256: Add tests.
48420         * tests/test-sha256.c: New file.
48421         * modules/crypto/sha256-tests: New file.
48423 2018-05-05  Bruno Haible  <bruno@clisp.org>
48425         sha1 tests: Add test for sha1_stream.
48426         * tests/test-sha1.c: Include test-digest.h.
48427         (main): Invoke test_digest_on_files on 'sha1_stream'.
48428         * modules/crypto/sha1-tests (Files): Add tests/test-digest.h.
48430 2018-05-05  Bruno Haible  <bruno@clisp.org>
48432         md5 tests: Add test for md5_stream.
48433         * tests/test-digest.h: New file.
48434         * tests/test-md5.c: Include test-digest.h.
48435         (main): Invoke test_digest_on_files on 'md5_stream'.
48436         * modules/crypto/md5-tests (Files): Add tests/test-digest.h.
48438 2018-04-28  Matteo Croce  <mcroce@redhat.com>
48440         md5sum: Use AF_ALG when available.
48441         * lib/md5.c: Include af_alg.h.
48442         (md5_stream): Use afalg_stream when available.
48443         * modules/crypto/md5 (Files): Add the af_alg files.
48444         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
48445         (Makefile.am): Add af_alg.c.
48447 2018-04-28  Matteo Croce  <mcroce@redhat.com>
48449         sha512sum: Use AF_ALG when available.
48450         * lib/sha512.c: Include af_alg.h.
48451         (sha512_stream, sha384_stream): Use afalg_stream when available.
48452         * modules/crypto/sha512 (Files): Add the af_alg files.
48453         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
48454         (Makefile.am): Add af_alg.c.
48456 2018-04-28  Matteo Croce  <mcroce@redhat.com>
48458         sha256sum: Use AF_ALG when available.
48459         * lib/sha256.c: Include af_alg.h.
48460         (sha256_stream, sha224_stream): Use afalg_stream when available.
48461         * modules/crypto/sha256 (Files): Add the af_alg files.
48462         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
48463         (Makefile.am): Add af_alg.c.
48465 2018-04-28  Matteo Croce  <mcroce@redhat.com>
48467         sha1sum: Use AF_ALG when available.
48468         * lib/af_alg.h: New file.
48469         * lib/af_alg.c: New file.
48470         * lib/sha1.c: Include af_alg.h.
48471         (sha1_stream): Use afalg_stream when available.
48472         * m4/linux-if-alg.m4: New file.
48473         * modules/crypto/sha1 (Files): Add the new files.
48474         (configure.ac): Invoke gl_LINUX_IF_ALG_H.
48475         (Makefile.am): Add af_alg.c.
48477 2018-05-05  Bruno Haible  <bruno@clisp.org>
48479         all: Replace more http URLs by https URLs.
48480         * lib/localename.c: Use https: URL.
48481         * lib/timespec.h: Likewise.
48483 2018-05-03  Paul Eggert  <eggert@cs.ucla.edu>
48485         maint: port more modules to GCC 8
48486         * lib/dirname.h (base_name):
48487         * lib/exclude.h (new_exclude):
48488         * lib/xstrndup.h (xstrndup):
48489         Add malloc attribute.
48490         * lib/readutmp.c: Pacify GCC 8 about safe use of strncpy.
48491         * lib/sig-handler.h (get_handler) [SA_SIGINFO]: Simplify.
48492         This pacifies GCC 8.
48493         * m4/gnulib-common.m4 (gl_COMMON_BODY):
48494         Define _GL_ATTRIBUTE_MALLOC here.  All other definitions removed.
48496 2018-05-03  Bruno Haible  <bruno@clisp.org>
48498         Simplify code. Drop support for Borland C++ on Windows.
48499         Reported by Gisle Vanem <gisle.vanem@gmail.com>.
48500         * lib/accept4.c: Simplify 'defined _WIN32 || defined __WIN32__' to just
48501         'defined _WIN32'.
48502         * lib/canonicalize-lgpl.c: Likewise.
48503         * lib/classpath.c: Likewise.
48504         * lib/clean-temp.c: Likewise.
48505         * lib/csharpexec.c: Likewise.
48506         * lib/ctime.c: Likewise.
48507         * lib/dosname.h: Likewise.
48508         * lib/dup2.c: Likewise.
48509         * lib/errno.in.h: Likewise.
48510         * lib/error.c: Likewise.
48511         * lib/euidaccess.c: Likewise.
48512         * lib/execute.c: Likewise.
48513         * lib/fcntl.in.h: Likewise.
48514         * lib/fcntl.c: Likewise.
48515         * lib/filename.h: Likewise.
48516         * lib/findprog.c: Likewise.
48517         * lib/flock.c: Likewise.
48518         * lib/fopen.c: Likewise.
48519         * lib/freopen.c: Likewise.
48520         * lib/fstat.c: Likewise.
48521         * lib/fsync.c: Likewise.
48522         * lib/gc-gnulib.c: Likewise.
48523         * lib/get-rusage-data.c: Likewise.
48524         * lib/getaddrinfo.c: Likewise.
48525         * lib/getdelim.c: Likewise.
48526         * lib/getdtablesize.c: Likewise.
48527         * lib/gethostname.c: Likewise.
48528         * lib/getlogin.c: Likewise.
48529         * lib/getlogin_r.c: Likewise.
48530         * lib/getopt.c: Likewise.
48531         * lib/getpagesize.c: Likewise.
48532         * lib/getpass.c: Likewise.
48533         * lib/getrusage.c: Likewise.
48534         * lib/gettimeofday.c: Likewise.
48535         * lib/glob.c: Likewise.
48536         * lib/inttypes.in.h: Likewise.
48537         * lib/isapipe.c: Likewise.
48538         * lib/javaexec.c: Likewise.
48539         * lib/link.c: Likewise.
48540         * lib/localcharset.c: Likewise.
48541         * lib/localename.h: Likewise.
48542         * lib/localename.c: Likewise.
48543         * lib/localtime.c: Likewise.
48544         * lib/lseek.c: Likewise.
48545         * lib/mbsinit.c: Likewise.
48546         * lib/mkdir.c: Likewise.
48547         * lib/msvc-nothrow.h: Likewise.
48548         * lib/nanosleep.c: Likewise.
48549         * lib/nl_langinfo.c: Likewise.
48550         * lib/nonblocking.c: Likewise.
48551         * lib/nproc.c: Likewise.
48552         * lib/open.c: Likewise.
48553         * lib/openpty.c: Likewise.
48554         * lib/pathmax.h: Likewise.
48555         * lib/pipe-filter-aux.c: Likewise.
48556         * lib/pipe-filter-gi.c: Likewise.
48557         * lib/pipe-filter-ii.c: Likewise.
48558         * lib/pipe.c: Likewise.
48559         * lib/pipe2.c: Likewise.
48560         * lib/poll.c: Likewise.
48561         * lib/popen.c: Likewise.
48562         * lib/posix_openpt.c: Likewise.
48563         * lib/printf-parse.c: Likewise.
48564         * lib/progreloc.c: Likewise.
48565         * lib/putenv.c: Likewise.
48566         * lib/read.c: Likewise.
48567         * lib/relocatable.c: Likewise.
48568         * lib/rename.c: Likewise.
48569         * lib/same-inode.h: Likewise.
48570         * lib/secure_getenv.c: Likewise.
48571         * lib/select.c: Likewise.
48572         * lib/sethostname.c: Likewise.
48573         * lib/setlocale.c: Likewise.
48574         * lib/sigaction.c: Likewise.
48575         * lib/sigprocmask.c: Likewise.
48576         * lib/sleep.c: Likewise.
48577         * lib/spawn-pipe.h: Likewise.
48578         * lib/spawn-pipe.c: Likewise.
48579         * lib/spawni.c: Likewise.
48580         * lib/stat-time.h: Likewise.
48581         * lib/stat-w32.c: Likewise.
48582         * lib/stat.c: Likewise.
48583         * lib/stdio.in.h: Likewise.
48584         * lib/stdio-impl.h: Likewise.
48585         * lib/stdio-read.c: Likewise.
48586         * lib/stdio-write.c: Likewise.
48587         * lib/stdlib.in.h: Likewise.
48588         * lib/strerror_r.c: Likewise.
48589         * lib/strftime-fixes.c: Likewise.
48590         * lib/sys_stat.in.h: Likewise.
48591         * lib/sys_types.in.h: Likewise.
48592         * lib/sys_wait.in.h : Likewise.
48593         * lib/system-quote.h: Likewise.
48594         * lib/system-quote.c: Likewise.
48595         * lib/tmpdir.c: Likewise.
48596         * lib/tzset.c: Likewise.
48597         * lib/uname.c: Likewise.
48598         * lib/unistd.in.h: Likewise.
48599         * lib/utime.in.h: Likewise.
48600         * lib/utime.c: Likewise.
48601         * lib/utimecmp.c: Likewise.
48602         * lib/utimens.c: Likewise.
48603         * lib/vasnprintf.c: Likewise.
48604         * lib/vma-iter.h: Likewise.
48605         * lib/vma-iter.c: Likewise.
48606         * lib/wait-process.c: Likewise.
48607         * lib/wcsftime.c: Likewise.
48608         * lib/wctype.in.h: Likewise.
48609         * lib/write.c: Likewise.
48610         * tests/nap.h: Likewise.
48611         * tests/test-cloexec.c: Likewise.
48612         * tests/test-dup-safer.c: Likewise.
48613         * tests/test-dup2.c: Likewise.
48614         * tests/test-dup3.c: Likewise.
48615         * tests/test-fcntl.c: Likewise.
48616         * tests/test-get-rusage-data.c: Likewise.
48617         * tests/test-getaddrinfo.c: Likewise.
48618         * tests/test-getlogin.h: Likewise.
48619         * tests/test-isatty.c: Likewise.
48620         * tests/test-localename.c: Likewise.
48621         * tests/test-mbrtowc-w32.c: Likewise.
48622         * tests/test-nonblocking.c: Likewise.
48623         * tests/test-nonblocking-pipe-main.c: Likewise.
48624         * tests/test-nonblocking-socket-main.c: Likewise.
48625         * tests/test-nonblocking-socket.h: Likewise.
48626         * tests/test-pipe.c: Likewise.
48627         * tests/test-pipe2.c: Likewise.
48628         * tests/test-poll.c: Likewise.
48629         * tests/test-pthread_sigmask1.c: Likewise.
48630         * tests/test-select.h: Likewise.
48631         * tests/test-sethostname2.c: Likewise.
48632         * tests/test-sigprocmask.c: Likewise.
48633         * tests/test-spawn-pipe-child.c: Likewise.
48634         * tests/test-stat-time.c: Likewise.
48635         * tests/test-system-quote-main.c: Likewise.
48636         * tests/test-utimens-common.h: Likewise.
48637         * tests/test-wcrtomb-w32.c: Likewise.
48638         * m4/csharpexec.m4 (gt_CSHARPEXEC): Likewise.
48639         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
48640         * m4/javacomp.m4 (gt_JAVACOMP): Likewise.
48641         * m4/javaexec.m4 (gt_JAVAEXEC): Likewise.
48642         * m4/locale-ar.m4 (gt_LOCALE_AR): Likewise.
48643         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
48644         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
48645         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
48646         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
48647         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Likewise.
48648         * m4/nocrash.m4 (GL_NOCRASH): Likewise.
48649         * m4/pathmax.m4 (gl_PATHMAX_SNIPPET): Likewise.
48650         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Likewise.
48651         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
48652         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Likewise.
48653         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
48655 2018-05-02  Bruno Haible  <bruno@clisp.org>
48657         localename: Fix test failures on mingw.
48658         * lib/localename.c (gl_locale_name_thread): Remove code specific to
48659         native Windows.
48660         (gl_locale_name_posix): Move code specific to native Windows here.
48661         * tests/test-localename.c (test_locale_name, test_locale_name_posix):
48662         Accept result without charset suffix, as it appears on mingw.
48664 2018-04-28  Paul Smith  <psmith@gnu.org>
48666         bootstrap: Avoid gnulib operations if not needed
48667         * build-aux/bootstrap: Remove unused variable gnulib_mk.
48668         Set $gnulib_extra_files early so it can be overridden in .conf.
48669         Remove redundant --import flag from $gnulib_tool_options.
48670         Set $use_gnulib to false if no gnulib modules or files are needed.
48671         If $use_gnulib is false, don't do anything related to gnulib.
48672         A lot of this is just whitespace (indentation) changes.
48674 2018-04-27  Paul Eggert  <eggert@cs.ucla.edu>
48676         manywarnings: port to GCC 8.0
48677         * build-aux/gcc-warning.spec: Add -Wcatch-value,
48678         -Wclass-memaccess, -Wdo-subscript, -Wextra-semi.  Adjust to the
48679         fact that the GCC help message now mentions operands for
48680         -Warray-bounds, -Wformat, -Wformat-overflow, -Wformat-truncation,
48681         -Wimplicit-fallthrough, -Wplacement-new, -Wshift-overflow,
48682         -Wstrict-aliasing, -Wstrict-overflow, -Wstringop-overflow,
48683         and -Wunused-const-variable.
48684         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wattribute-alias,
48685         -Wcast-align=strict, -Wcast-function-type, -Wif-not-aligned,
48686         -Wmissing-attributes, -Wmultistatement-macros,
48687         -Wpacked-not-aligned, -Wsizeof-pointer-div, -Wstringop-truncation,
48688         -Wsuggest-attribute=cold, -Wsuggest-attribute=malloc.
48690 2018-04-24  Bruno Haible  <bruno@clisp.org>
48692         sys_socket: Make SO_REUSEPORT available across platforms.
48693         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
48694         * lib/sys_socket.in.h (SO_REUSEPORT): New macro.
48695         * doc/posix-headers/sys_socket.texi: Mention the issue.
48696         * tests/test-poll.c (SO_REUSEPORT): Remove.
48697         * tests/test-select.h: Include <sys/socket.h>.
48698         (SO_REUSEPORT): Remove.
48699         * modules/select-tests (Depends-on): Add 'sys_socket'.
48701 2018-04-21  Benno Schulenberg  <bensberg@telfort.nl>  (tiny change)
48703         localcharset: short-circuit the search for an alias on a Mac
48704         * lib/localcharset.c (get_charset_aliases): Add a tautological
48705         UTF-8 entry to speed up the search for this case.
48706         Most machines default to a UTF-8 locale nowadays, so begin the
48707         list of aliases with a dummy UTF-8 entry so it will be found
48708         immediately and a time-consuming search through the rest of
48709         the list is avoided.
48711 2018-04-11  Paul Eggert  <eggert@cs.ucla.edu>
48713         fts: add comment
48714         * lib/fts.c (fts_build): Explain why ==, not >.
48715         See remark by Bernhard Voelker in:
48716         https://lists.gnu.org/r/bug-gnulib/2018-04/msg00041.html
48718         fts: fix bug in find across filesystems
48719         This fixes a bug I introduced last summer.
48720         Problem reported by Kamil Dudka in:
48721         https://lists.gnu.org/r/bug-gnulib/2018-04/msg00033.html
48722         * lib/fts.c (filesystem_type, dirent_inode_sort_may_be_useful)
48723         (leaf_optimization):
48724         New arg for file descriptor.  All callers changed.
48725         (fts_build): Check for whether inodes should be sorted
48726         before closing the directory.
48728 2018-04-07  Bruno Haible  <bruno@clisp.org>
48730         unicase/u*-context: Fix link errors with libunistring <= 0.9.9.
48731         Reported by Genki Sky <sky@genki.is>.
48732         * modules/unicase/u8-prefix-context (configure.ac): Require libunistring
48733         version 0.9.10 or newer.
48734         * modules/unicase/u8-suffix-context (configure.ac): Likewise.
48735         * modules/unicase/u16-prefix-context (configure.ac): Likewise.
48736         * modules/unicase/u16-suffix-context (configure.ac): Likewise.
48737         * modules/unicase/u32-prefix-context (configure.ac): Likewise.
48738         * modules/unicase/u32-suffix-context (configure.ac): Likewise.
48740 2018-04-07  Bruno Haible  <bruno@clisp.org>
48742         execute: Update comment.
48743         * lib/execute.h (execute): Refer to spawn-pipe.h, not pipe.h.
48745 2018-04-05  Paul Eggert  <eggert@cs.ucla.edu>
48747         fts: treat CIFS like NFS
48748         Problem reported by Kamil Dudka in:
48749         https://lists.gnu.org/r/bug-gnulib/2018-04/msg00015.html
48750         * lib/fts.c (S_MAGIC_CIFS): New macro.
48751         (dirent_inode_sort_may_be_useful, leaf_optimization):
48752         Treat CIFS like NFS.
48754 2018-03-28  Bruno Haible  <bruno@clisp.org>
48756         c-stack: Fix possible build failure on some platforms.
48757         * lib/c-stack.c (die): Define whenever this function is referenced.
48759 2018-03-28  Paul Eggert  <eggert@cs.ucla.edu>
48761         time_rz: fix workaround for Mac OS X 10.6 infloop
48762         Problems reported by Charles A. Roelli (Bug#27736#117).
48763         * m4/time_rz.m4 (gl_TIME_RZ): Use a slightly different timestamp.
48764         Also, discard output, which clutters the 'configure' log.
48766 2018-03-27  Paul Eggert  <eggert@cs.ucla.edu>
48768         havelib: port to Solaris 10 /bin/sh
48769         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Use 'test ! EXPR'
48770         instead of '! test EXPR'.
48772 2018-03-26  Paul Eggert  <eggert@cs.ucla.edu>
48774         time_rz: work around Mac OS X 10.6 infloop
48775         * doc/posix-functions/localtime.texi:
48776         * doc/posix-functions/localtime_r.texi: Mention the bug.
48777         * lib/time_rz.c (localtime_rz): Work around the bug.  It’d be
48778         better to fix localtime and localtime_r instead, but that would be
48779         more work and is not needed to fix the Emacs problem.
48780         * m4/time_rz.m4 (gl_TIME_RZ): Detect the bug.
48782 2018-03-24  Jim Meyering  <meyering@fb.com>
48784         test-version-etc.sh: don't use diff directly: use init.sh's compare
48785         We'd rather not sacrifice readable "diff -u" output even for
48786         "diff -c" output (not supported by busybox) or for even less
48787         readable ed-style "diff" output.  So use init.sh's compare function
48788         * tests/test-version-etc.sh: Source init.sh and add "." to path.
48789         Remove "./" from invocation of test-version-etc, so we use path.
48790         And s/diff/compare/.
48791         * modules/version-etc-tests (Depends-on): Add test-framework-sh,
48792         to get init.sh.
48793         Prompted by Eric Blake's comments in
48794         https://lists.gnu.org/r/sed-devel/2018-03/msg00015.html
48796 2018-03-24  Bruno Haible  <bruno@clisp.org>
48798         javacomp-script, javacomp: Add support for Java 10.
48799         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 10 and
48800         target-version 10.
48801         * lib/javaversion.h: Update comments.
48802         * lib/javacomp.c (default_target_version, SOURCE_VERSION_BOUND,
48803         source_version_index, get_goodcode_snippet, get_failcode_snippet,
48804         TARGET_VERSION_BOUND, target_version_index,
48805         corresponding_classfile_version): Accept source_version 10 and
48806         target_version 10.
48807         * lib/javacomp.h: Update comments accordingly.
48809 2018-03-24  Bruno Haible  <bruno@clisp.org>
48811         javacomp-script, javacomp: Update comments.
48812         * m4/javacomp.m4: Update comments regarding gcj.
48813         * lib/javacomp.h: Likewise.
48815 2018-03-24  Bruno Haible  <bruno@clisp.org>
48817         javacomp-script, javacomp: Fix support for Java 7, 8, 9.
48818         * lib/javaversion.h: Update comments.
48819         * lib/javacomp.h: Likewise.
48820         * lib/javacomp.c (default_target_version, source_version_index,
48821         get_goodcode_snippet, get_failcode_snippet): Recognize "9" instead of
48822         "1.9".
48823         (TARGET_VERSION_BOUND): Bump to 9.
48824         (target_version_index, corresponding_classfile_version): Recognize "9"
48825         instead of "1.9".
48826         (get_source_version_for_javac): New function.
48827         (is_envjavac_nongcj_usable, is_javac_usable): Add
48828         source_version_for_javac argument.
48829         (compile_java_class): Determine and pass source_version_for_javac.
48830         * m4/javacomp.m4: Recognize version '9' instead of '1.9'. When invoking
48831         $JAVAC or javac, pass '-source 1.6' instead of '-source 1.5' when
48832         appropriate.
48834 2018-03-23  Jim Meyering  <meyering@fb.com>
48836         test-version-etc.sh: port to diff without -c
48837         * tests/test-version-etc.sh: Don't use diff's -c option.
48838         This caused spurious test failure on Alpine Linux, which
48839         uses busybox's diff. Reported by Assaf Gordon in
48840         https://lists.gnu.org/r/sed-devel/2018-03/msg00013.html
48842 2018-03-23  Paul Eggert  <eggert@cs.ucla.edu>
48844         c-stack: port to recent GCC build
48845         Problem reported by The Fireplace (Bug#30913).
48846         * lib/c-stack.c (die): Define only if used.
48848 2018-03-20  Bruno Haible  <bruno@clisp.org>
48850         euidaccess: Port to native Windows.
48851         * lib/euidaccess.c (euidaccess): On native Windows, just use _access().
48852         * posix-modules (exclude_for_mingw): Remove 'euidaccess'.
48854 2018-03-19  Bruno Haible  <bruno@clisp.org>
48856         javacomp: Add support for Java 7, 8, 9.
48857         * lib/javacomp.c (default_target_version, SOURCE_VERSION_BOUND,
48858         source_version_index, get_goodcode_snippet, get_failcode_snippet,
48859         corresponding_classfile_version): Accept source_version 1,7, 1.8, 1.9
48860         and target_version 1,7, 1.8, 1.9.
48861         * lib/javacomp.h: Update comments accordingly.
48863 2018-03-19  Bruno Haible  <bruno@clisp.org>
48865         javacomp-script: Add support for Java 9.
48866         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 1.9 and
48867         target-version 1.9.
48869 2018-03-16  Bruno Haible  <bruno@clisp.org>
48871         glob: Don't compile replacements on recent glibc systems.
48872         * lib/glob.in.h: Use the usual idiom for the double-inclusion guard. If
48873         REPLACE_GLOB is 0, include the system's <glob.h> and use
48874         _GL_CXXALIAS_SYS.
48875         * m4/glob.m4 (gl_GLOB): Set REPLACE_GLOB instead of GLOB_H. Accept
48876         _GNU_GLOB_INTERFACE_VERSION 2 as well. Delete the file conf$$-globtest
48877         inside the AC_RUN_IFELSE block. Remove GL_GENERATE_GLOB_H conditional.
48878         * modules/glob (Dependencies): Test REPLACE_GLOB instead of GLOB_H.
48879         Remove snippet/warn-on-use.
48880         (configure.ac): Test REPLACE_GLOB instead of GLOB_H.
48881         (Makefile.am): Create glob.h always. Update list of substitutions in
48882         glob.h. Don't depend on $(WARN_ON_USE_H).
48884 2018-03-16  Bruno Haible  <bruno@clisp.org>
48886         glob: Fix link error on native Windows.
48887         * modules/glob (Depends-on): Add 'lstat'.
48889 2018-03-15  Bruno Haible  <bruno@clisp.org>
48891         glob: Fix compilation error in C++ mode.
48892         * lib/glob.in.h (_Restrict_): Define, like in regex.h and spawn.in.h.
48894 2018-03-15  Bruno Haible  <bruno@clisp.org>
48896         host-cpu-c-abi: Support for RISC-V CPU.
48897         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Recognize the various
48898         riscv32 and riscv64 ABIs.
48899         References:
48900         https://github.com/riscv/riscv-toolchain-conventions
48901         https://gcc.gnu.org/onlinedocs/gcc-7.3.0/gcc/RISC-V-Options.html
48902         https://gnu-mcu-eclipse.github.io/toolchain/riscv/
48904 2018-03-08  Paul Eggert  <eggert@cs.ucla.edu>
48906         fflush: be more paranoid about libio.h change
48907         Suggested by Eli Zaretskii in:
48908         https://lists.gnu.org/r/emacs-devel/2018-03/msg00270.html
48909         * lib/fbufmode.c (fbufmode):
48910         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
48911         (disable_seek_optimization, rpl_fflush):
48912         * lib/fpending.c (__fpending):
48913         * lib/fpurge.c (fpurge):
48914         * lib/freadable.c (freadable):
48915         * lib/freadahead.c (freadahead):
48916         * lib/freading.c (freading):
48917         * lib/freadptr.c (freadptr):
48918         * lib/freadseek.c (freadptrinc):
48919         * lib/fseeko.c (fseeko):
48920         * lib/fseterr.c (fseterr):
48921         * lib/fwritable.c (fwritable):
48922         * lib/fwriting.c (fwriting):
48923         Look at _IO_ftrylockfile as well as at _IO_EOF_SEEN.
48925 2018-03-07  Paul Eggert  <eggert@cs.ucla.edu>
48927         maint: write-file-hooks -> before-save-hook
48928         write-file-hooks is obsolete since Emacs 22.1 (released June 2007) and
48929         it's time to use the recommended replacement.
48930         Problem reported by Glenn Morris in:
48931         https://lists.gnu.org/r/bug-gnulib/2018-03/msg00008.html
48932         * build-aux/announce-gen, build-aux/bootstrap:
48933         * build-aux/do-release-commit-and-tag, build-aux/gendocs.sh:
48934         * build-aux/git-version-gen, build-aux/gitlog-to-changelog:
48935         * build-aux/gnu-web-doc-update, build-aux/gnupload:
48936         * build-aux/move-if-change, build-aux/prefix-gnulib-mk:
48937         * build-aux/update-copyright, build-aux/useless-if-before-free:
48938         * build-aux/vc-list-files:
48939         Update hook usage for files where Gnulib is the canonical source.
48941 2018-03-05  Paul Eggert  <eggert@cs.ucla.edu>
48943         binary-io: pacify gcc -Wunused-parameter
48944         Problem reported by Reuben Thomas in:
48945         https://lists.gnu.org/r/bug-gnulib/2018-03/msg00005.html
48946         * lib/binary-io.h (__gl_setmode, __gl_setmode_check):
48947         Use _GL_UNUSED where appropriate.
48949         fflush: adjust to glibc 2.28 libio.h removal
48950         Problem reported by Daniel P. Berrangé in:
48951         https://lists.gnu.org/r/bug-gnulib/2018-03/msg00000.html
48952         * lib/fbufmode.c (fbufmode):
48953         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
48954         (disable_seek_optimization, rpl_fflush):
48955         * lib/fpending.c (__fpending):
48956         * lib/fpurge.c (fpurge):
48957         * lib/freadable.c (freadable):
48958         * lib/freadahead.c (freadahead):
48959         * lib/freading.c (freading):
48960         * lib/freadptr.c (freadptr):
48961         * lib/freadseek.c (freadptrinc):
48962         * lib/fseeko.c (fseeko):
48963         * lib/fseterr.c (fseterr):
48964         * lib/fwritable.c (fwritable):
48965         * lib/fwriting.c (fwriting):
48966         Check _IO_EOF_SEEN instead of _IO_ftrylockfile.
48967         * lib/stdio-impl.h (_IO_IN_BACKUP) [_IO_EOF_SEEN]:
48968         Define if not already defined.
48970 2018-02-27  Paul Eggert  <eggert@cs.ucla.edu>
48972         environ: fix link error on 32-bit Cygwin
48973         Problem reported for GNU Emacs by Ken Brown in:
48974         https://lists.gnu.org/r/emacs-devel/2018-02/msg00765.html
48975         * lib/unistd.in.h (environ) [__i386__]: Do not redeclare.
48977 2018-02-24  Bruno Haible  <bruno@clisp.org>
48979         mbrtowc tests: Fix regression on glibc.
48980         Reported by Bernhard Voelker.
48981         * tests/test-mbrtowc.c (main): Fix expected value of wc.
48983 2018-02-24  Bruno Haible  <bruno@clisp.org>
48985         striconveha, uniconv/*: Avoid test failures on musl libc.
48986         * tests/iconvsupport.c: New file.
48987         * tests/test-striconveha.c (main): Skip autodetect_jp tests if iconv()
48988         does not support the ISO-2022-JP-2 encoding.
48989         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
48990         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
48991         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
48992         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
48993         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
48994         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
48995         * modules/striconveha-tests (Files): Add tests/iconvsupport.c.
48996         (Makefile.am): Link test-striconveha with iconvsupport.o.
48997         * modules/uniconv/u8-conv-from-enc-tests (Files): Add
48998         tests/iconvsupport.c.
48999         (Makefile.am): Link test-u8-conv-from-enc with iconvsupport.o.
49000         * modules/uniconv/u8-strconv-from-enc-tests (Files): Add
49001         tests/iconvsupport.c.
49002         (Makefile.am): Link test-u8-strconv-from-enc with iconvsupport.o.
49003         * modules/uniconv/u16-conv-from-enc-tests (Files): Add
49004         tests/iconvsupport.c.
49005         (Makefile.am): Link test-u16-conv-from-enc with iconvsupport.o.
49006         * modules/uniconv/u16-strconv-from-enc-tests (Files): Add
49007         tests/iconvsupport.c.
49008         (Makefile.am): Link test-u16-strconv-from-enc with iconvsupport.o.
49009         * modules/uniconv/u32-conv-from-enc-tests (Files): Add
49010         tests/iconvsupport.c.
49011         (Makefile.am): Link test-u32-conv-from-enc with iconvsupport.o.
49012         * modules/uniconv/u32-strconv-from-enc-tests (Files): Add
49013         tests/iconvsupport.c.
49014         (Makefile.am): Link test-u32-strconv-from-enc with iconvsupport.o.
49016 2018-02-24  Bruno Haible  <bruno@clisp.org>
49018         localename: Add support for musl libc.
49019         * m4/localename.m4 (gl_LOCALENAME): Check for <langinfo.h>.
49020         * lib/localename.c (gl_locale_name_thread_unsafe): Use NL_LOCALE_NAME
49021         on Linux platforms which define NL_LOCALE_NAME.
49023 2018-02-24  Bruno Haible  <bruno@clisp.org>
49025         mbrtowc tests: Don't make assumptions about the charset the C locale.
49026         * tests/test-mbrtowc.c (main): For bytes >= 0x80, don't assume a
49027         particular mapping in the C locale.
49029 2018-02-24  Bruno Haible  <bruno@clisp.org>
49031         ptsname_r: Don't expect that this function sets errno.
49032         * tests/test-ptsname_r.c (test_errors): Don't test errno after return
49033         from ptsname_r().
49034         * doc/glibc-functions/ptsname_r.texi: Mention the issue.
49036 2018-02-23  Bruno Haible  <bruno@clisp.org>
49038         xmalloca: pacify gcc -Wbad-function-cast
49039         * lib/xmalloca.h (xmalloca): Insert intermediate cast here as well.
49041 2018-02-23  Paul Eggert  <eggert@cs.ucla.edu>
49043         nl_langinfo: pacify gcc -Wunused-function
49044         * lib/nl_langinfo.c (ctype_codeset): Do not define if
49045         REPLACE_NL_LANGINFO && !GNULIB_defined_CODESET, as it is unused in
49046         this case.  Without this change, I got a diagnostic when building
49047         coreutils on Fedora 27 with gcc 7.3.1 20180130.
49049         same: pacify gcc -Wunused-variable
49050         * lib/same.c (same_nameat) [!CHECK_TRUNCATION]:
49051         Omit unused variable.
49053         malloca: pacify gcc -Wbad-function-cast
49054         * lib/malloca.h (malloca): Pacify gcc -Wbad-function-cast
49055         diagnostic that I got on Fedora 27 with gcc 7.3.1 20180130.
49056         To pacify GCC, I had to cast alloca’s result to some type other
49057         than void * before casting that to uintptr_t.
49059 2018-02-20  Paul Eggert  <eggert@cs.ucla.edu>
49061         utimecmp: new function utimecmpat
49062         * lib/utimecmp.c: Include fcntl.h, sys/stat.h and dirname.h.
49063         Do not include utimens.h.
49064         (utimecmpat): New function, generalizing utimecmp.
49065         (utimecmp): Now a thin layer around utimecmpat.
49066         * modules/utimecmp (Depends-on): Depend on dirname-lgpl, fstatat,
49067         utimensat instead of on lstat and utimens.
49069         same: new function same_nameat
49070         * lib/same.c: Include fcntl.h.
49071         * lib/same.c (same_nameat): New function, generalizing same_name.
49072         (same_name): Now a thin layer around same_nameat.
49073         * m4/same.m4 (gl_SAME): Check for fpathconf, not pathconf.
49074         * modules/same (Depends-on): Depend on fstatat, openat.
49076 2018-02-18  Eric Gallager  <egall@gwmail.gwu.edu>  (tiny change)
49078         warnings: Add support for Objective C.
49079         * m4/warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS(Objective C)): New
49080         macro.
49082 2018-02-17  Bruno Haible  <bruno@clisp.org>
49084         lock: Fix test-once1 crash on FreeBSD11.
49085         * lib/glthread/lock.h: On FreeBSD, test the weak value of the symbol
49086         'pthread_create', not 'pthread_cancel'.
49088 2018-02-17  Bruno Haible  <bruno@clisp.org>
49090         lock: Add test of gl_once.
49091         * tests/test-once.c: New file.
49092         * modules/lock-tests (Files): Add it.
49093         (Makefile.am): Build and test programs 'test-once1' and 'test-once2'.
49095 2018-02-17  Bruno Haible  <bruno@clisp.org>
49097         thread: Fix compilation error on IRIX.
49098         * lib/glthread/thread.h: Include <unistd.h>. Include <signal.h> when
49099         needed; include it outside the C++ extern "C" {} block.
49100         * doc/posix-headers/pthread.texi: Mention the problem with
49101         pthread_atfork on IRIX.
49103 2018-02-04  Bruno Haible  <bruno@clisp.org>
49105         nl_langinfo: Override the system's nl_langinfo() when needed.
49106         Reported by Jim Meyering.
49107         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Set REPLACE_NL_LANGINFO=1
49108         also when HAVE_LANGINFO_T_FMT_AMPM or HAVE_LANGINFO_ALTMON is 0.
49110 2018-02-04  Bruno Haible  <bruno@clisp.org>
49112         signal-h, monetary, strings: Fix build failure in some cases.
49113         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
49114         * modules/signal-h (Makefile.am): In the GNULIB_* substitutions, use '/'
49115         as delimiter in sed command, not '|'.
49116         * modules/monetary (Makefile.am): Likewise.
49117         * modules/strings (Makefile.am): Likewise.
49119 2018-02-03  Jim Meyering  <meyering@fb.com>
49121         maint.mk: exempt "/proc/filesystems" from "file system" syntax check
49122         * top/maint.mk (sc_file_system): Don't complain about
49123         "/proc/filesystems".
49125 2018-02-03  Bruno Haible  <bruno@clisp.org>
49127         stdlib: Fix compilation error on OpenIndiana.
49128         * lib/stdlib.in.h: Before including <sys/loadavg.h>, include
49129         <sys/time.h>.
49130         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
49131         * m4/getloadavg.m4 (gl_GETLOADAVG): Likewise.
49133 2018-02-03  Bruno Haible  <bruno@clisp.org>
49135         host-cpu-c-abi: Avoid use of 'grep -E' on OpenIndiana.
49136         * m4/asm-underscore.m4 (gl_ASM_SYMBOL_PREFIX): Require AC_PROG_EGREP,
49137         and use $EGREP instead of 'grep -E'.
49138         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Use 'grep' instead of
49139         'grep -E'.
49141 2018-02-02  Paul Eggert  <eggert@cs.ucla.edu>
49143         malloca: Add a compile-time verification.
49144         * lib/malloca.c (small_t): Verify that it is wide enough.
49145         * modules/malloca (Depends-on): Add verify.
49147 2018-02-02  Bruno Haible  <bruno@clisp.org>
49149         malloca: Add an argument check.
49150         Suggested by Paul Eggert.
49151         * lib/malloca.c (freea): Check against an invalid argument.
49153 2018-02-02  Bruno Haible  <bruno@clisp.org>
49155         localename: Add support for OpenIndiana.
49156         * lib/localename.c (gl_locale_name_thread_unsafe): Add code for
49157         Solaris 11 variants with uselocale() but without getlocalename_l().
49159 2018-02-02  Bruno Haible  <bruno@clisp.org>
49161         malloca, xmalloca: Make multithread-safe.
49162         Reported by Florian Weimer <fweimer@redhat.com>.
49163         Implements an idea by Ondřej Bílka <neleai@seznam.cz>.
49164         * lib/malloca.h (malloca): In the stack allocation case, return a
49165         pointer that is a multiple of 2 * sa_alignment_max.
49166         (sa_increment): Remove enum item.
49167         * lib/xmalloca.h (xmalloca): In the stack allocation case, return
49168         a pointer that is a multiple of 2 * sa_alignment_max.
49169         * lib/malloca.c (NO_SANITIZE_MEMORY): Remove macro.
49170         (MAGIC_NUMBER, MAGIC_SIZE, preliminary_header, HEADER_SIZE, header,
49171         HASH_TABLE_SIZE, mmalloca_results): Remove.
49172         (small_t): New type.
49173         (mmalloca, free): Rewritten.
49174         * lib/malloca.valgrind: Remove file.
49175         * modules/malloca (Files): Remove it.
49176         (Depends-on): Remove verify.
49178 2018-01-31  Bruno Haible  <bruno@clisp.org>
49180         environ: Fix link error on 64-bit Cygwin.
49181         * lib/unistd.in.h (environ): On Cygwin, redeclare with the
49182         __declspec(dllimport) attribute.
49183         * doc/posix-functions/environ.texi: Mention the Cygwin problem.
49185 2018-01-30  Bruno Haible  <bruno@clisp.org>
49187         get-rusage-data: Add support for Minix 3.
49188         * lib/get-rusage-data.c (get_rusage_data): Return 0 on Minix.
49190 2018-01-30  Bruno Haible  <bruno@clisp.org>
49192         vma-iter: Add support for Minix 3.
49193         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define on Minix.
49194         * lib/vma-iter.c: On Minix, read /proc/<pid>/map.
49196 2018-01-27  Bruno Haible  <bruno@clisp.org>
49198         Fix malfunction of socket functions on HP-UX in 64-bit mode.
49199         * m4/socketlib.m4 (gl_SOCKETLIB): Add comment.
49200         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define
49201         _HPUX_ALT_XOPEN_SOCKET_API.
49202         * modules/accept (Depends-on): Add 'extensions'.
49203         * modules/getpeername (Depends-on): Likewise.
49204         * modules/getsockname (Depends-on): Likewise.
49205         * modules/getsockopt (Depends-on): Likewise.
49206         * modules/recvfrom (Depends-on): Likewise.
49207         * doc/posix-functions/accept.texi: Mention the HP-UX socklen_t problem.
49208         * doc/posix-functions/getpeername.texi: Likewise.
49209         * doc/posix-functions/getsockname.texi: Likewise.
49210         * doc/posix-functions/getsockopt.texi: Likewise.
49211         * doc/posix-functions/recvfrom.texi: Likewise.
49213 2018-01-27  Bruno Haible  <bruno@clisp.org>
49215         getsockname tests: More tests.
49216         * tests/test-getsockname.c (open_server_socket): New function, mostly
49217         copied from test-poll.c.
49218         (main): Check that getsockname fills in addr.
49219         * modules/getsockname-tests (Depends-on): Add the necessary
49220         dependencies.
49221         (test_getsockname_LDADD): Link with $(INET_PTON_LIB).
49223 2018-01-26  Paul Eggert  <eggert@cs.ucla.edu>
49225         manywarnings: fix maintainer comment
49226         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Fix comment so that
49227         it does not mistakenly think that ‘-1)’ is an option.
49229 2018-01-26  Bruno Haible  <bruno@clisp.org>
49231         langinfo: Fix last commit.
49232         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
49233         * modules/langinfo (Makefile.am): Substitute HAVE_LANGINFO_ALTMON.
49235 2018-01-24  Bruno Haible  <bruno@clisp.org>
49237         langinfo, nl_langinfo: Add support for alternative month names.
49238         * m4/langinfo_h.m4 (gl_LANGINFO_H): Define HAVE_LANGINFO_ALTMON.
49239         * lib/langinfo.in.h (ALTMON_1...ALTMON_12): New macros.
49240         * lib/nl_langinfo.c (rpl_nl_langinfo): Treat ALTMON_i like MON_i.
49241         * tests/test-nl_langinfo.c (main): Test ALTMON_*.
49242         * doc/posix-headers/langinfo.texi: Document support of ALTMON_*.
49243         * doc/posix-functions/nl_langinfo.texi: Likewise.
49245 2018-01-23  Paul Eggert  <eggert@cs.ucla.edu>
49247         Merge strftime.c changes from glibc
49248         This incorporates:
49249         2017-11-14 [BZ #10871] Implement alternative month names
49250         2017-11-14 [BZ #10871] Abbreviated alternative month names (%Ob)
49251         2017-06-20 Use locale_t, not __locale_t, throughout glibc
49252         * lib/nstrftime.c (ABALTMON_1) [!COMPILE_WIDE]: New macro.
49253         (LOCALE_PARAM) [_LIBC && USE_IN_EXTENDED_LOCALE_MODEL]:
49254         Use locale_t, not __locale_t.
49255         (a_altmonth, f_altmonth, aam_len) [_NL_CURRENT]: New macros.
49256         (__strftime_internal): Add support for alternate months.
49258 2018-01-23  Bruno Haible  <bruno@clisp.org>
49260         doc: Mention another prerequisite for using Gnulib.
49261         Reported at <https://stackoverflow.com/questions/48378214/>.
49262         * doc/gnulib-tool.texi (Initial import): Mention requirement to use
49263         AC_CONFIG_HEADERS.
49265 2018-01-22  Mathieu Lirzin  <mthl@gnu.org>
49267         build: GuixSD doesn't have /bin/bash
49268         * Makefile (SHELL): Search 'bash' in the PATH environment variable.
49270 2018-01-21  Bruno Haible  <bruno@clisp.org>
49272         Avoid test failures on Microsoft Windows Subsystem for Linux.
49273         * tests/test-fcntl.c (main): Allow a different errno.
49274         * tests/test-rename.h (test_rename): Likewise.
49275         * tests/test-renameat.c (main): Likewise.
49276         * tests/test-renameat2.c (main): Likewise.
49278 2018-01-14  Paul Eggert  <eggert@cs.ucla.edu>
49280         filenamecat: make base a suffix of result
49281         * lib/filenamecat-lgpl.c (longest_relative_suffix): Remove.
49282         (mfile_name_concat): Always make BASE a suffix of the result, as
49283         cp expects this.  To implement this, separate with '.' instead of
49284         '/' in some rare cases.  Clarify spec to say ./BASE not BASE.
49285         * tests/test-filenamecat.c (main): Adjust tests to match
49286         current behavior.  Check that BASE_IN_RESULT points to
49287         a copy of BASE and is a suffix of the resultk, and that DIR
49288         is a prefix of the result that is no longer than the prefix
49289         indicated by BASE_IN_RESULT.
49291 2018-01-04  Mathieu Lirzin  <mthl@gnu.org>
49293         update-copyright: Handle use of ©
49294         * build-aux/update-copyright ($circle_c_re): Update regex to
49295         handle use of © in headers.
49297 2018-01-04  Tim Rühsen  <tim.ruehsen@gmx.de>
49299         Fix -Wundef warning in user-included header lib/cdefs.h.
49300         * lib/cdefs.h: Check if defined before using __USE_FORTIFY_LEVEL.
49302 2018-01-04  Bruno Haible  <bruno@clisp.org>
49304         pthread_sigmask: Avoid compilation error on mingw.
49305         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
49306         * lib/signal.in.h (pthread_sigmask): Don't declare it it's defined as a
49307         macro.
49309 2018-01-03  Paul Eggert  <eggert@cs.ucla.edu>
49311         test-framework-sh: ‘ps -ef’, not ‘ps ef’
49312         * tests/init.sh (rand_bytes_): Put ‘-’ before new-style ps options.
49313         Suggested by Bob Proulx (Bug#29968).
49314         * build-aux/mktempd (rand_bytes): Make it like tests/init.sh.
49316 2018-01-02  Eric Blake  <eblake@redhat.com>
49318         stat-time: silence -Wunused-parameter regression
49319         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime):
49320         Prefer attribute over cast-to-void.
49321         (stat_time_normalize): Mark st as potentially unused.
49323 2018-01-02  Paul Eggert  <eggert@cs.ucla.edu>
49325         test-framework-sh: avoid netstat
49326         Problem reported by Kristýna Streitová (Bug#29947).
49327         * tests/init.sh (rand_bytes_): Stop using netstat, as it's
49328         deprecated on SuSE and it's not that important anyway.
49330 2018-01-01  Jim Meyering  <meyering@fb.com>
49332         update-copyright: add code to handle more special cases
49333         After running "make update-copyright" this year, five files
49334         required additional manual changes.  Automate those adjustments
49335         for next year.
49336         * Makefile (_year_and_prev): Define.
49337         (update-copyright): Add perl commands to induce this year's post-
49338         update-copyright adjustments.
49340 2018-01-01  Paul Eggert  <eggert@cs.ucla.edu>
49342         version-etc: new year
49343         * build-aux/gendocs.sh (version):
49344         * doc/gendocs_template:
49345         * doc/gendocs_template_min:
49346         * doc/gnulib.texi:
49347         * lib/version-etc.c (COPYRIGHT_YEAR):
49348         Update copyright dates by hand in templates and the like.
49350         maint: fix 'make update-copyright'
49351         * Makefile (update-copyright): Adjust to 2016-11-23 change
49352         to config/srclist-update, which changed the format of srclist.txt.
49354 2017-12-30  Paul Eggert  <eggert@cs.ucla.edu>
49356         chdir-safer: remove this module
49357         * MODULES.html.sh (func_all_modules): Remove chdir-safer.
49358         * NEWS: Document removal.
49359         * lib/chdir-safer.c, lib/chdir-safer.h, m4/afs.m4, m4/chdir-safer.m4:
49360         * modules/chdir-safer: Remove these files.
49362 2017-12-29  Samuel Thibault  <samuel.thibault@gnu.org>
49364         Add cross-compilation results for GNU/Hurd.
49365         * m4/calloc.m4: Add GNU/Hurd guess.
49366         * m4/cbrtl.m4: Likewise.
49367         * m4/ceil.m4: Likewise.
49368         * m4/ceilf.m4: Likewise.
49369         * m4/ceill.m4: Likewise.
49370         * m4/chown.m4: Likewise.
49371         * m4/duplocale.m4: Likewise.
49372         * m4/exp2l.m4: Likewise.
49373         * m4/expm1.m4: Likewise.
49374         * m4/fchdir.m4: Likewise.
49375         * m4/floor.m4: Likewise.
49376         * m4/floorf.m4: Likewise.
49377         * m4/fmod.m4: Likewise.
49378         * m4/fmodf.m4: Likewise.
49379         * m4/fmodl.m4: Likewise.
49380         * m4/getcwd.m4: Likewise.
49381         * m4/getgroups.m4: Likewise.
49382         * m4/gettimeofday.m4: Likewise.
49383         * m4/hypot.m4: Likewise.
49384         * m4/hypotf.m4: Likewise.
49385         * m4/hypotl.m4: Likewise.
49386         * m4/link-follow.m4: Likewise.
49387         * m4/link.m4: Likewise.
49388         * m4/linkat.m4: Likewise.
49389         * m4/log.m4: Likewise.
49390         * m4/log10.m4: Likewise.
49391         * m4/log10f.m4: Likewise.
49392         * m4/log1p.m4: Likewise.
49393         * m4/log1pf.m4: Likewise.
49394         * m4/log1pl.m4: Likewise.
49395         * m4/log2.m4: Likewise.
49396         * m4/log2f.m4: Likewise.
49397         * m4/logf.m4: Likewise.
49398         * m4/lstat.m4: Likewise.
49399         * m4/malloc.m4: Likewise.
49400         * m4/mbrlen.m4: Likewise.
49401         * m4/mbrtowc.m4: Likewise.
49402         * m4/mkdir.m4: Likewise.
49403         * m4/mkfifo.m4: Likewise.
49404         * m4/mknod.m4: Likewise.
49405         * m4/mkstemp.m4: Likewise.
49406         * m4/modf.m4: Likewise.
49407         * m4/modff.m4: Likewise.
49408         * m4/modfl.m4: Likewise.
49409         * m4/printf.m4: Likewise.
49410         * m4/pselect.m4: Likewise.
49411         * m4/ptsname.m4: Likewise.
49412         * m4/putenv.m4: Likewise.
49413         * m4/readlink.m4: Likewise.
49414         * m4/realloc.m4: Likewise.
49415         * m4/remainder.m4: Likewise.
49416         * m4/remainderf.m4: Likewise.
49417         * m4/remainderl.m4: Likewise.
49418         * m4/rmdir.m4: Likewise.
49419         * m4/round.m4: Likewise.
49420         * m4/roundf.m4: Likewise.
49421         * m4/roundl.m4: Likewise.
49422         * m4/select.m4: Likewise.
49423         * m4/setenv.m4: Likewise.
49424         * m4/signbit.m4: Likewise.
49425         * m4/sleep.m4: Likewise.
49426         * m4/stat.m4: Likewise.
49427         * m4/strerror.m4: Likewise.
49428         * m4/strtok_r.m4: Likewise.
49429         * m4/symlink.m4: Likewise.
49430         * m4/symlinkat.m4: Likewise.
49431         * m4/trunc.m4: Likewise.
49432         * m4/truncf.m4: Likewise.
49433         * m4/truncl.m4: Likewise.
49434         * m4/tzset.m4: Likewise.
49435         * m4/ungetc.m4: Likewise.
49436         * m4/usleep.m4: Likewise.
49437         * m4/wcwidth.m4: Likewise.
49439 2017-12-28  Bruno Haible  <bruno@clisp.org>
49441         gnulib-tool: Make --conditional-dependencies work better.
49442         Reported by Dmitry Selyutin <ghostman.sd@gmail.com>.
49443         * gnulib-tool (Options): Don't reject the combination of
49444         --conditional-dependencies with --with-tests.
49445         (func_emit_autoconf_snippets): Add argument referenceable_modules.
49446         Don't reference $modules.
49447         (func_import, func_create_testdir): Pass it.
49449 2017-12-19  Paul Eggert  <eggert@cs.ucla.edu>
49451         regex: use re_malloc etc. consistently
49452         Problem and original patch reported by Arnold Robbins in:
49453         https://sourceware.org/ml/libc-alpha/2017-12/msg00241.html
49454         * lib/regcomp.c (re_comp):
49455         * lib/regexec.c (push_fail_stack, build_trtable, match_ctx_clean):
49456         Use re_malloc/re_realloc/re_free instead of malloc/realloc/free.
49458 2017-12-15  Tim Rühsen  <tim.ruehsen@gmx.de>
49459             Paul Eggert  <eggert@cs.ucla.edu>
49461         glob: Silence warning about void pointer arithmetic.
49462         * lib/glob.c (glob): Use a 'char *', not a 'void *', in pointer
49463         arithmetic.
49465 2017-12-15  Bruno Haible  <bruno@clisp.org>
49467         spawn-pipe: Silence a clang warning.
49468         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
49469         * lib/spawn-pipe.c: Disable clang -Wconditional-uninitialized warnings
49470         in this file.
49472 2017-12-12  Paul Eggert  <eggert@cs.ucla.edu>
49474         explicit_bzero: port to macOS + Clang 9.0.0
49475         Problem reported by Marcus Johnson (Bug#29658).
49476         * lib/explicit_bzero.c (explicit_bzero) [__clang__]:
49477         Don’t use asm.
49479 2017-12-11  Reuben Thomas  <rrt@sc3d.org>
49481         doc: Improve explanation of supporting relocatable libraries.
49482         * doc/relocatable-maint.texi (Supporting Relocation): Explain
49483         properly how to build the relocatable module for
49484         libraries. (Method and example code from Bruno Haible.)
49486 2017-12-11  Reuben Thomas  <rrt@sc3d.org>
49488         doc: Use better texinfo tags in a few cases.
49489         * doc/gnulib.texi (Extending Gnulib): Use @option or @command
49490         instead of @samp in a few places.
49492 2017-12-11  Bruno Haible  <bruno@clisp.org>
49494         unistr/base: Update comment.
49495         * lib/unistr.in.h: Update comment about u*_mbtouc_unsafe functions.
49497 2017-12-10  Pádraig Brady  <P@draigBrady.com>
49499         test-faccessat.c: unlink temp file to avoid subsequent test failure
49500         * tests/test-faccessat.c: Remove the file to avoid failure
49501         to open the file on subsequent runs due to being created
49502         with no permissions.
49504 2017-12-10  Bruno Haible  <bruno@clisp.org>
49506         doc: New sect. "Modifying the build rules of a Gnulib import directory".
49507         * doc/gnulib-tool.texi (Modified build rules): New node.
49509 2017-12-10  Bruno Haible  <bruno@clisp.org>
49511         doc: Tweak wording.
49512         * doc/gnulib-tool.texi (Multiple instances): Talk about "programs", not
49513         "binaries".
49515 2017-12-05  Sam Steingold  <sds@gnu.org>
49516             Bruno Haible  <bruno@clisp.org>
49518         no-c++: Avoid "egrep: repetition-operator operand invalid" error.
49519         * m4/no-c++.m4 (gt_NO_CXX): Don't use '+' characters nor spaces in the
49520         AC_EGREP_CPP pattern.
49522 2017-12-03  Bruno Haible  <bruno@clisp.org>
49524         all: Replace more http URLs by https URLs.
49525         * lib/sm3.h, lib/sm3.c, tests/test-sm3.c: Use https: URL.
49526         * lib/unigbrk/u-grapheme-breaks.h: Likewise.
49527         * lib/unigbrk/uc-grapheme-breaks.c: Likewise.
49528         * tests/unigbrk/test-uc-grapheme-breaks.c: Likewise.
49530 2017-11-28  Paul Eggert  <eggert@cs.ucla.edu>
49532         Port better to CentOS 5
49533         Problems reported by Tom G. Christensen in:
49534         https://lists.gnu.org/r/bug-gnulib/2017-11/msg00053.html
49535         * doc/glibc-functions/strverscmp.texi (strverscmp):
49536         Document strverscmp bug with glibc 2.9 and earlier.
49537         * doc/posix-functions/tzset.texi (tzset):
49538         Document that TZ with angle brackets is POSIX-2001 and later.
49539         * tests/test-nstrftime.c: Include unistd.h.
49540         (TZ_ANGLE_BRACKETS_SHOULD_WORK): New macro.
49541         (TZ): Use it to skip tests with angle brackets in TZ,
49542         for older systems.
49544         stat: add missing module dependencies
49545         * modules/lstat, modules/stat, modules/utimensat (Depends-on):
49546         Add stat-time.
49548 2017-11-28  Benno Schulenberg  <bensberg@telfort.nl>
49550         stat: fix compilation failure on macOS Sierra
49551         Reported by Marius Schamschula <mschamschula@gmail.com> in:
49552         https://savannah.gnu.org/bugs/?52546
49553         * lib/stat.c: Add missing include of stat-time.h.
49555 2017-11-28  Jim Meyering  <meyering@fb.com>
49557         test-faccessat.c: correct BASE definition to avoid parallel test failure
49558         * tests/test-faccessat.c (BASE): Define using this file's name, not
49559         that of test-lstat.c.  Using the latter caused this test to fail
49560         sometimes when run concurrently with test-lstat.
49562 2017-11-27  Daiki Ueno  <ueno@gnu.org>
49564         unicase: fix VPATH build
49565         * modules/unicase/special-casing (Makefile.am): Ensure that the
49566         base directory is created when generating
49567         unicase/special-casing.h.
49569 2017-11-27  Daiki Ueno  <ueno@gnu.org>
49571         libunistring: update to Unicode 9.0.0
49572         * lib/gen-uni-tables.c (fill_properties): Recognize
49573         Sentence_Terminal and Prepended_Concatenation_Mark.
49574         (is_property_default_ignorable_code_point): Exclude U+08E2.
49575         (fill_arabicshaping): Allow missing whitespace when parsing;
49576         recognize "AFRICAN FEH", "AFRICAN QAF", and "AFRICAN MOON".
49577         (output_blocks): Increase the element size of the level1 table to
49578         accommodate more blocks.
49579         (get_lbp): Recognize ZWJ, E_Base, and E_Modifier characters;
49580         Update each class according to the standard.
49581         (get_wbp): Recognize ZWJ, E_Base, E_Modifier, Glue_After_Zwj, and
49582         E_Base_GAZ characters.
49583         (output_gbp_table): Recognize ZWJ, E_Base, E_Modifier,
49584         Glue_After_Zwj, and E_Base_GAZ characters.
49585         * lib/unictype.in.h (UC_JOINING_GROUP_AFRICAN_FEH)
49586         (UC_JOINING_GROUP_AFRICAN_QAF, UC_JOINING_GROUP_AFRICAN_MOON): New
49587         enum value.
49588         * lib/unilbrk/lbrktables.h (LBP_ZWJ, LBP_EB, LBP_EM): New enum
49589         value.
49590         * lib/unilbrk/lbrktables.c (unilbrk_table): Extend the table with
49591         LBP_ZWJ, LBP_EB, and LBP_EM.
49592         * lib/uniwbrk.in.h (WBP_ZWJ, WBP_EB, WBP_EM, WBP_GAZ, WBP_EBG): New
49593         enum value.
49594         * lib/uniwbrk/u-wordbreaks.h: Implement WB3c, WB15, and WB16.
49595         * lib/uniwbrk/wbrktable.h (uniwbrk_prop_index): New variable
49596         declaration.
49597         * lib/uniwbrk/wbrktable.c (uniwbrk_prop_index): New variable.
49598         (uniwbrk_table): Implement WB14.
49599         * tests/uniwbrk/test-uc-wordbreaks.c (wordbreakproperty_to_string):
49600         Check WBP_ZWJ, WBP_EB, WBP_EM, WBP_GAZ, and WBP_EBG.
49601         * modules/unigbrk/u{32,16,8}-grapheme-breaks: No longer depend on
49602         uc-is-grapheme-break.
49603         * modules/unigbrk/uc-grapheme-breaks: New module.
49604         * modules/unigbrk/uc-grapheme-breaks-tests: New module.
49605         * lib/unigbrk.in.h (GBP_ZWJ, GBP_EB, GBP_EM, GBP_GAZ, GBP_EBG): New
49606         enum value.
49607         (uc_grapheme_breaks): New function, replacing uc_is_grapheme_break.
49608         * lib/unigbrk/u-grapheme-breaks.h: New file.
49609         * lib/unigbrk/u{32,16,8}-grapheme-breaks.c: Rewrite using
49610         u-grapheme-breaks.h instead of uc_is_grapheme_break.
49611         * lib/unigbrk/uc-grapheme-breaks.c: New file.
49612         * lib/unigbrk/uc-is-grapheme-break.c: Partially update to TR29 rev
49613         29.
49614         * tests/unigbrk/test-uc-gbrk-prop.c
49615         (graphemebreakproperty_to_string): Check GBP_ZWJ, GBP_EB, GBP_EM,
49616         GBP_GAZ, and GBP_EBG.
49617         * tests/unigbrk/test-uc-grapheme-breaks.c: New test.
49618         * tests/unigbrk/test-uc-is-grapheme-break.c
49619         (graphemebreakproperty_to_string): Check GBP_ZWJ, GBP_EB, GBP_EM,
49620         GBP_GAZ, and GBP_EBG.
49621         (main): Skip unsupported rules involving 3 or more characters,
49622         namely GB10, GB12, and GB13.
49623         * lib/uniwidth/width.c (nonspacing_table_data): Update.
49624         * all generated files under lib/uni* and tests/uni*: Regenerate.
49625         * all the affected modules: Bump version.
49627 2017-11-26  Bruno Haible  <bruno@clisp.org>
49629         strfmon_l: Fix compilation error with glibc 2.5.
49630         Reported by Tom G. Christensen <tgc@jupiterrise.com>
49631         in <https://lists.gnu.org/r/bug-gnulib/2017-11/msg00051.html>.
49632         * lib/monetary.in.h: Include also <locale.h>.
49634 2017-11-24  Paul Eggert  <eggert@cs.ucla.edu>
49636         posixtm: remove PDS_LEADING_YEAR
49637         This changes the API slightly, in a hopefully-innocuous way.
49638         Without this change the code had undefined behavior when a
49639         caller specified neither PDS_LEADING_YEAR nor PDS_TRAILING_YEAR.
49640         Problem reported by Pádraig Brady in:
49641         https://lists.gnu.org/r/bug-gnulib/2017-11/msg00048.html
49642         * NEWS: Mention this.
49643         * lib/posixtm.c (posix_time_parse): Treat the absence of
49644         PDS_TRAILING_YEAR as if PDS_LEADING_YEAR were present.
49645         * lib/posixtm.h (PDS_LEADING_YEAR): Remove (actually, leave it
49646         present, but define it as zero, for compatibility with existing
49647         source code).  All other PDS_* values moved up.
49648         * tests/test-posixtm.c (LY): New macro.
49649         (T): Use it.  Do not expect a particular numeric encoding
49650         for PDS_CENTURY etc.
49652 2017-11-23  Paul Eggert  <eggert@cs.ucla.edu>
49654         stat: work around Solaris bug with tv_nsec < 0
49655         * doc/posix-functions/fstat.texi (fstat):
49656         * doc/posix-functions/fstatat.texi (fstatat):
49657         * doc/posix-functions/lstat.texi (lstat):
49658         * doc/posix-functions/stat.texi (stat):
49659         Mention Solaris 11 bug.
49660         * lib/fstat.c, lib/fstatat.c, lib/lstat.c: Include stat-time.h.
49661         * lib/fstat.c (rpl_fstat) [!WINDOWS_NATIVE]:
49662         * lib/lstat.c (rpl_lstat):
49663         * lib/stat.c (rpl_stat):
49664         Normalize resulting timestamps.
49665         * lib/fstatat.c (normal_fstatat): New function.
49666         (rpl_fstatat): Use it.
49667         * lib/stat-time.h: Include intprops.h, errno.h, stddef.h.
49668         (stat_time_normalize): New function.
49669         * m4/fstat.m4 (gl_FUNC_FSTAT):
49670         * m4/fstatat.m4 (gl_FUNC_FSTATAT):
49671         * m4/lstat.m4 (gl_FUNC_LSTAT):
49672         * m4/stat.m4 (gl_FUNC_STAT):
49673         Replace on Solaris.
49674         * modules/fstat (Depends-on):
49675         * modules/fstatat (Depends-on):
49676         Add stat-time.
49677         * modules/stat-time (Depends-on): Add errno, intprops.
49679 2017-11-22  Paul Eggert  <eggert@cs.ucla.edu>
49681         regex: merge from glibc
49682         * lib/regcomp.c (init_word_char): Add comments.
49684 2017-11-20  Paul Eggert  <eggert@cs.ucla.edu>
49686         regex: merge from glibc
49687         * lib/regcomp.c (__regcomp, __regfree) [_LIBC]: Now hidden.
49688         * lib/regex_internal.h (internal_function): Remove.
49689         All uses removed.
49691 2017-11-20  Bruno Haible  <bruno@clisp.org>
49693         crypto/gc-sm3: Fix buffer overrun.
49694         * lib/gc-gnulib.c (MAX_DIGEST_SIZE): Bump to 32.
49695         Reported by Coverity.
49697 2017-11-12  Jim Meyering  <meyering@fb.com>
49699         maint: shorten https://lists.gnu.org/archive/html/... links
49700         Each /archive/html/ part can be replace with /r/.
49701         Run this to induce the change:
49702         git grep -l archive/html|xargs perl -pi -e 's,/archive/html/,/r/,g'
49703         * ChangeLog: Perform that substitution.
49704         * Makefile: Likewise.
49705         * STATUS-libposix: Likewise.
49706         * build-aux/bootstrap: Likewise.
49707         * doc/maintain.texi: Likewise.
49708         * gnulib-tool: Likewise.
49709         * lib/allocator.h: Likewise.
49710         * lib/argp-ba.c: Likewise.
49711         * lib/argp-pv.c: Likewise.
49712         * lib/canon-host.c: Likewise.
49713         * lib/canonicalize-lgpl.c: Likewise.
49714         * lib/float.in.h: Likewise.
49715         * lib/fstat.c: Likewise.
49716         * lib/getdelim.c: Likewise.
49717         * lib/getprogname.c: Likewise.
49718         * lib/glthread/thread.h: Likewise.
49719         * lib/intprops.h: Likewise.
49720         * lib/mbsrtowcs-state.c: Likewise.
49721         * lib/safe-read.c: Likewise.
49722         * lib/signal.in.h: Likewise.
49723         * lib/stat.c: Likewise.
49724         * lib/stdbool.in.h: Likewise.
49725         * lib/stdio-impl.h: Likewise.
49726         * lib/stdio.in.h: Likewise.
49727         * lib/sysexits.in.h: Likewise.
49728         * lib/timespec.h: Likewise.
49729         * lib/wcsrtombs-state.c: Likewise.
49730         * m4/alloca.m4: Likewise.
49731         * m4/extern-inline.m4: Likewise.
49732         * m4/fstatat.m4: Likewise.
49733         * m4/gnulib-common.m4: Likewise.
49734         * m4/lib-ignore.m4: Likewise.
49735         * m4/printf.m4: Likewise.
49736         * m4/regex.m4: Likewise.
49737         * m4/stat-size.m4: Likewise.
49738         * m4/std-gnu11.m4: Likewise.
49739         * m4/stdbool.m4: Likewise.
49740         * m4/sys_types_h.m4: Likewise.
49741         * m4/threadlib.m4: Likewise.
49742         * m4/vararrays.m4: Likewise.
49743         * pygnulib/GLImport.py: Likewise.
49744         * tests/test-exp.h: Likewise.
49745         * tests/test-exp2.h: Likewise.
49746         * tests/test-expm1.h: Likewise.
49747         * tests/test-fflush2.c: Likewise.
49748         * tests/test-getopt_long.h: Likewise.
49749         * tests/test-intprops.c: Likewise.
49750         * tests/test-log.h: Likewise.
49751         * tests/test-log10.h: Likewise.
49752         * tests/test-log1p.h: Likewise.
49753         * tests/test-log2.h: Likewise.
49754         * tests/test-printf-posix.h: Likewise.
49755         * tests/test-regex.c: Likewise.
49756         * tests/test-snprintf-posix.h: Likewise.
49757         * tests/test-sprintf-posix.h: Likewise.
49758         * tests/test-stdalign.c: Likewise.
49759         * tests/test-stdbool.c: Likewise.
49760         * tests/test-vasnprintf-posix.c: Likewise.
49761         * tests/test-vasprintf-posix.c: Likewise.
49762         * top/maint.mk: Likewise.
49764 2017-11-12  Bruno Haible  <bruno@clisp.org>
49766         faccessat: Make the last change more robust.
49767         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Require
49768         gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK. Treat "guessing yes" like "yes".
49770 2017-11-11  Paul Eggert  <eggert@cs.ucla.edu>
49772         faccessat: port to macOS (Bug#29231)
49773         macOS faccessat has the same bug that lstat does: if the file
49774         name ends in '/' it ignores the trailing slash.
49775         Problem reported for Emacs by Vincent Zhang.
49776         * doc/posix-functions/faccessat.texi (faccessat): Document this.
49777         * lib/faccessat.c (_GL_INCLUDING_UNISTD_H): Define and undef
49778         around the initial includes.  Include errno.h, string.h, sys/stat.h.
49779         (orig_faccessat) [HAVE_FACCESSAT]: New function.
49780         Include "unistd.h" after defining it.
49781         (rpl_faccessat) [HAVE_FACCESSAT]: New implementation.
49782         * lib/unistd.in.h (faccessat) [REPLACE_FACCESSAT]:
49783         Handle in the usual way.
49784         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Replace faccessat if
49785         lstat dereferences symlinks, since faccessat is likely to
49786         have the same problem.
49787         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Default REPLACE_ACCESSAT.
49788         * modules/faccessat (Depends-on): Add fstatat.
49789         Depend if REPLACE_FACCESSAT is 1, too.
49790         (configure.ac): Link if REPLACE_FACCESSAT is 1.
49791         * modules/faccessat-tests (Depends-on): Add symlink.
49792         * modules/unistd (unistd.h): Substitute REPLACE_FACCESSAT.
49793         * tests/test-faccessat.c (main): Test for the bug.
49795 2017-11-11  Bruno Haible  <bruno@clisp.org>
49797         getprogname: Fix compilation error on IRIX.
49798         * lib/getprogname.c (getprogname) [__sgi]: Fix type of local variable
49799         'namesize'.
49801 2017-11-11  Bruno Haible  <bruno@clisp.org>
49803         year2038: Tweak last patch.
49804         * m4/year2038.m4 (gl_YEAR2038): Correct indentation.
49806 2017-11-06  Paul Eggert  <eggert@cs.ucla.edu>
49808         year2038: be more insistent about 64-bit time_t
49809         Applications requiring access to arbitrary files should not be
49810         built with 32-bit time_t on hosts that have 64-bit timestamps,
49811         as this can lead to real trouble at runtime.
49812         * m4/year2038.m4 (gl_YEAR2038): Do not require AC_CANONICAL_HOST.
49813         Check on all systems, not just MinGW.  Use a heuristic involving
49814         TIME_T_32_BIT_OK, cross_compiling, and the touch command to
49815         output a failure or just a warning, to make it more likely that
49816         builders will select 64-bit time_t.
49818 2017-11-05  Paul Eggert  <eggert@cs.ucla.edu>
49820         havelib: fix typo in previous change
49821         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Fix typo.
49823         Don’t use AC_EGREP_CPP if affected by CFLAGS
49824         * m4/float_h.m4 (gl_FLOAT_H):
49825         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI):
49826         * m4/lib-ld.m4 (AC_LIB_PROG_LD):
49827         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB):
49828         * m4/year2038.m4 (gl_YEAR2038):
49829         Prefer AC_COMPILE_IFELSE to AC_EGREP_CPP when testing conditions
49830         likely to be affected by the choice of CFLAGS, since CFLAGS are
49831         not used by AC_EGREP_CPP.  Without this patch, ‘./configure
49832         CFLAGS="-m32"’ fails on gzip with GNU/Linux x86-64.
49834         fstatat: pacify GCC on unusual platform
49835         * lib/fstatat.c (orig_fstatat) [!HAVE_WORKING_FSTATAT_ZERO_FLAG]:
49836         Omit, as it’s unused in this case.
49838 2017-10-29  Paul Eggert  <eggert@cs.ucla.edu>
49840         timespec: prefer ‘assume’ to ‘assure’
49841         This avoids some runtime tests.  The rest of the module makes
49842         similar assumptions and there is little point to testing here.
49843         * lib/timespec.h: Include verify.h instead of assure.h.
49844         (timespec_cmp): Use ‘assume’, not ‘assure’.
49845         Also, remove an unnecessary cast to ‘int’, as lots of other
49846         code in this module now causes -Wconversion to complain, and
49847         this is a problem with -Wconversion not with the code.
49849         * modules/timespec (Depends-on): Depend on ‘verify’, not ‘assure’.
49851         Port recent gnulib-tool change to Dash
49852         * gnulib-tool (func_create_testdir): Don't assume that the shell
49853         retokenizes after expanding "$@" inside the call to
49854         func_execute_command.  Dash 0.5.8-2.1ubuntu2 does not.
49856 2017-10-27  Jim Meyering  <meyering@fb.com>
49858         timespec.h: use "assure" to avoid a spurious warning
49859         * lib/timespec.h: Include "assure.h" and use it to help
49860         gcc7's -Wstrict-overflow avoid a false positive warning
49861         for a use in coreutils' ls.c.  Suggested by Paul Eggert in
49862         https://lists.gnu.org/r/bug-gnulib/2017-10/msg00007.html
49863         * modules/timespec (Depends-on): Add assure.
49865 2017-10-29  Bruno Haible  <bruno@clisp.org>
49867         Avoid several test failures with traditional locales on Haiku.
49868         * m4/locale-ar.m4 (gt_LOCALE_AR): On BeOS and Haiku, set LOCALE_AR=none.
49869         * m4/locale-fr.m4 (gt_LOCALE_FR): On BeOS and Haiku, set LOCALE_FR=none.
49870         * m4/locale-ja.m4 (gt_LOCALE_JA): On BeOS and Haiku, set LOCALE_JA-none.
49871         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): On BeOS and Haiku, set
49872         LOCALE_ZH_CN=none.
49874 2017-10-29  Bruno Haible  <bruno@clisp.org>
49876         strerror_r-posix: Fix behaviour and test failure on Haiku.
49877         * lib/strerror_r.c (strerror_r): Don't assume that valid error numbers
49878         are positive. Work around return value 0 instead of ERANGE on Haiku.
49879         For unknown error numbers, use a format string consistent with perror().
49880         * doc/posix-functions/strerror_r.texi: Mention the Haiku problem.
49881         * tests/test-strerror_r.c (main): Don't assume that valid error numbers
49882         are positive.
49884 2017-10-29  Bruno Haible  <bruno@clisp.org>
49886         get-rusage-data: Avoid crash on Haiku.
49887         * lib/get-rusage-data.c: Avoid the setlimit-based implementation.
49889 2017-10-29  Bruno Haible  <bruno@clisp.org>
49891         get-rusage-as: Avoid crash on Haiku.
49892         * lib/get-rusage-as.c: Avoid the setlimit-based implementation.
49894 2017-10-29  Bruno Haible  <bruno@clisp.org>
49896         ilogbl: Ensure replacement on Haiku.
49897         * m4/ilogbl.m4 (gl_FUNC_ILOGBL): Invoke gl_FUNC_ILOGBL_WORKS and set
49898         REPLACE_ILOGBL if ilogbl does not work.
49899         (gl_FUNC_ILOGBL_WORKS): New macro.
49900         * lib/math.in.h (ilogbl): Replace if REPLACE_ILOGBL is 1.
49901         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_ILOGBL.
49902         * modules/math (Makefile.am): Substitute REPLACE_ILOGBL.
49903         * modules/ilogbl (Depends-on, configure.ac): Consider REPLACE_ILOGBL.
49904         * doc/posix-functions/ilogbl.texi: Mention the Haiku problem.
49906 2017-10-29  Bruno Haible  <bruno@clisp.org>
49908         expl: Ensure replacement on Haiku.
49909         * m4/expl.m4 (gl_FUNC_EXPL): Test whether an expl() return value is
49910         zero.
49911         * doc/posix-functions/expl.texi: Mention the Haiku problem.
49913 2017-10-29  Bruno Haible  <bruno@clisp.org>
49915         math: Fix test failure on Haiku.
49916         * lib/math.in.h (FP_ILOGB0, FP_ILOGBNAN): Override on Haiku.
49917         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Update accordingly.
49918         * m4/ilogbf.m4 (gl_FUNC_ILOGBF_WORKS): Likewise.
49919         * doc/posix-headers/math.texi: Mention the Haiku problem.
49921 2017-10-29  Bruno Haible  <bruno@clisp.org>
49923         gnulib-tool: Avoid unnecessary config.h.in remaking in testdirs.
49924         * gnulib-tool (func_create_testdir): Use workaround against 'autoheader'
49925         bug reported at <https://savannah.gnu.org/support/index.php?109406>.
49927 2017-10-29  Bruno Haible  <bruno@clisp.org>
49929         crypto/*: Verify that the header file is self-contained.
49930         * tests/test-gc-*.c: Include the module's header file immediately after
49931         <config.h>.
49932         * tests/test-hmac-*.c: Likewise.
49933         * tests/test-arcfour.c: Likewise.
49934         * tests/test-arctwo.c: Likewise.
49935         * tests/test-des.c: Likewise.
49936         * tests/test-md2.c: Likewise.
49937         * tests/test-md4.c: Likewise.
49938         * tests/test-md5.c: Likewise.
49939         * tests/test-rijndael.c: Likewise.
49940         * tests/test-sha1.c: Likewise.
49941         * tests/test-sm3.c: Likewise.
49943 2017-10-29  Jia Zhang  <qianyue.zj@alibaba-inc.com>
49944             Bruno Haible  <bruno@clisp.org>
49946         crypto/gc: fix build failure with -Werror=suggest-attribute=const
49947         * lib/gc.h (gc_hash_digest_length): Mark with 'const' attribute.
49949 2017-10-29  Jia Zhang  <qianyue.zj@alibaba-inc.com>
49951         New module: crypto/gc-sm3
49952         * lib/gc.h: Declare SM3-related stuffs.
49953         * lib/gc-gnulib.c: Support sm3 in internal functions.
49954         * lib/gc-libgcrypt.c: Support sm3 with libgcrypt.
49955         * m4/gc-sm3.m4: m4 file for gc-sm3 module.
49956         * modules/crypto/gc-sm3: Define gc-sm3 module.
49957         * tests/test-gc-sm3.c: Implement SM3 test case with libgcrypt.
49958         * modules/crypto/gc-sm3-tests: Define gc-sm3 test module.
49959         * MODULES.html.sh: List gc-sm3 module.
49961 2017-10-29  Bruno Haible  <bruno@clisp.org>
49963         random, random_r: Mention different prototypes on Haiku.
49964         * doc/posix-functions/random.texi: Mention different prototype on Haiku.
49965         * doc/glibc-functions/random_r.texi: Likewise.
49966         * doc/glibc-functions/initstate_r.texi: Likewise.
49967         * doc/glibc-functions/setstate_r.texi: Likewise.
49969 2017-10-28  Bruno Haible  <bruno@clisp.org>
49971         posix_spawn: Avoid spurious message in configure output.
49972         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Discard stderr output from
49973         'cmp' command.
49975 2017-10-28  Bruno Haible  <bruno@clisp.org>
49977         inet_ntop, inet_pton: Determine needed library correctly on Haiku.
49978         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Search also in libnetwork.
49979         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
49981 2017-10-28  Bruno Haible  <bruno@clisp.org>
49983         ioctl: Override non-POSIX declaration on Haiku.
49984         * m4/ioctl.m4 (gl_FUNC_IOCTL): Include also <unistd.h>.
49985         * lib/sys_ioctl.in.h: Add comment about Haiku.
49986         * doc/posix-functions/ioctl.texi: Mention Haiku problem.
49987         * doc/glibc-headers/sys_ioctl.texi: Likewise.
49989 2017-10-28  Bruno Haible  <bruno@clisp.org>
49991         crypto/sm3: Add overview documentation to the .h file.
49992         * lib/sm3.h: Add comments.
49994 2017-10-28  Jia Zhang  <qianyue.zj@alibaba-inc.com>
49996         New module: crypto/sm3
49997         This new module can be used to compute SM3 message digest of files or
49998         memory blocks according to the specification GM/T 004-2012
49999         Cryptographic Hash Algorithm SM3, published by State Cryptography
50000         Administration, China.
50001         The official SM3 cryptographic hash algorithm specification is
50002         available at
50003         http://www.sca.gov.cn/sca/xwdt/2010-12/17/content_1002389.shtml
50004         * lib/sm3.h: Declare the APIs of sm3 module.
50005         * lib/sm3.c: Implement SM3 hash algorithm.
50006         * m4/sm3.m4: m4 file for sm3 module.
50007         * modules/crypto/sm3: Define sm3 module.
50008         * tests/test-sm3.c: Implement SM3 test case.
50009         * modules/crypto/sm3-tests: Define sm3 test module.
50010         * MODULES.html.sh: List sm3 module.
50012 2017-10-28  Jia Zhang  <qianyue.zj@alibaba-inc.com>
50014         gc-libgcrypt: fix undefined enum type in switch statement
50015         Resolve the following build failure:
50016         lib/gc-libgcrypt.c: In function 'gc_hash_open':
50017         lib/gc-libgcrypt.c:317:5: error: case value '0' not in enumerated type
50018         'Gc_hash_mode {aka enum Gc_hash_mode}' [-Werror=switch]
50019              case 0:
50020              ^~~~
50021         * lib/gc.h (enum Gc_hash_mode): Add value GC_NULL.
50022         * lib/gc-libgcrypt.c (gc_hash_open): Use this enum value instead of 0.
50024 2017-10-28  Jia Zhang  <qianyue.zj@alibaba-inc.com>
50026         gc-libgcrypt: fix assignment error due to -Werror=pointer-sign
50027         Resolve the following build failure:
50028         lib/gc-libgcrypt.c: In function 'gc_hash_read':
50029         lib/gc-libgcrypt.c:460:14: error: pointer targets in assignment differ
50030         in signedness [-Werror=pointer-sign]
50031             digest = gcry_md_read (ctx->gch, 0);
50032                    ^
50033         * lib/gc-libgcrypt.c (gc_hash_read): Cast result of gcry_md_read.
50035 2017-10-26  Bruno Haible  <bruno@clisp.org>
50037         havelib: Fix value of LD for 32-bit compilation on NetBSD/sparc64.
50038         * m4/lib-ld.m4 (AC_LIB_PROG_LD): On NetBSD/sparc64 with CC="gcc -m32",
50039         set LD to '/usr/bin/ld -m elf32_sparc', not '/usr/bin/ld'.
50041 2017-10-21  Paul Eggert  <eggert@cs.ucla.edu>
50043         glob: fix another heap buffer overflow
50044         Problem reported by Tim Rühsen in:
50045         https://sourceware.org/bugzilla/show_bug.cgi?id=22332
50046         * lib/glob.c (glob): Avoid buffer overrun when unescaping.
50048 2017-10-19  Paul Eggert  <eggert@cs.ucla.edu>
50050         quotearg: pacify compiler re unsigned
50051         * lib/quotearg.c (quotearg_n_options):
50052         Rewrite to avoid diagnostic from overly-picky compiler.
50053         Problem reported by Sami Kerola in:
50054         https://lists.gnu.org/r/bug-gnulib/2017-10/msg00060.html
50056         glob: fix heap buffer overflow
50057         * lib/glob.c (glob): Fix off-by-one error introduced into
50058         glibc in commit dd7d45e838a42b0ed470c44b55901ea98d0c2bab
50059         dated 1997-10-29 20:33:40.  Problem reported by Tim Rühsen in:
50060         https://sourceware.org/bugzilla/show_bug.cgi?id=22320
50061         Fix suggested by Bruno Haible.
50063 2017-10-18  Paul Eggert  <eggert@cs.ucla.edu>
50065         glob: pacify fuzzer for mempcpy
50066         Problem reported by Tim Rühsen in:
50067         https://lists.gnu.org/r/bug-gnulib/2017-10/msg00054.html
50068         * lib/glob.c (glob): Do not pass NULL to mempcpy.
50070 2017-10-12  Bruno Haible  <bruno@clisp.org>
50072         doc: Fix syntax error (regression from 2017-10-03).
50073         * doc/posix-functions/strncpy.texi: Fix syntax error.
50075 2017-10-12  Bruno Haible  <bruno@clisp.org>
50077         doc: Update for Solaris 11.3.
50078         * doc/**/*.texi: For bugs that exist in both Solaris 11.0 and 11.3,
50079         mention Solaris 11.3.
50080         * m4/log2.m4: Fix comments.
50081         * m4/log2f.m4: Likewise.
50082         * m4/printf.m4: Update comments.
50083         * m4/rename.m4: Likewise.
50084         * m4/strncat.m4: Likewise.
50086         all: Write "Solaris 11.0" instead of "Solaris 11 2011-11".
50088 2017-10-10  Bruno Haible  <bruno@clisp.org>
50090         doc: Improve doc about ioctl.
50091         * doc/posix-functions/ioctl.texi: Fix list of platforms with non-POSIX
50092         prototype.
50094 2017-10-09  Bruno Haible  <bruno@clisp.org>
50096         wcwidth: Don't use obsolete syntax of 'test'.
50097         Reported by Eric Blake.
50098         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Don't optimize two 'test'
50099         invocations into one, as POSIX marks '-a' and '-o' as "obsolescent".
50101 2017-10-09  Bruno Haible  <bruno@clisp.org>
50103         getopt-posix: Fix build failure when using ac_cv_header_getopt_h=no.
50104         Reported by Christian Ehrhardt <christian.ehrhardt@canonical.com>
50105         and Daniel P. Berrange <berrange@redhat.com>.
50106         * lib/unistd.in.h (getopt): Don't attempt to avoid namespace pollution
50107         on glibc systems. The getopt-pfx-core.h file declares exactly what
50108         unistd.h needs, nothing more.
50110 2017-10-08  Bruno Haible  <bruno@clisp.org>
50112         vma-iter: Improve support for FreeBSD.
50113         * lib/vma-iter.c (vma_iterate_proc): New function, extracted from
50114         vma_iterate.
50115         (vma_iterate): Use it. For FreeBSD, try vma_iterate_bsd first.
50117 2017-10-08  Bruno Haible  <bruno@clisp.org>
50119         vma-iter: Fix truncated result on NetBSD (regression from 2017-10-07).
50120         * lib/vma-iter.c (MIN_LEFTOVER): Define to 1, not 0.
50122 2017-10-07  KO Myung-Hun  <komh@chollian.net>
50124         test-framework-sh: Fix 'invalid path dir' error.
50125         On OS/2, a path separator is ';' not ':'. And ':' is used as a
50126         separator between a drive letter and directory parts.
50127         As a result, an absolute path such as x:/path/to/dir on OS/2 is
50128         treated as an invalid path dir.
50129         * tests/init.sh (PATH_SEPARATOR): Set at startup.
50130         (path_prepend_): '?:*' is also an absolute path. Use $PATH_SEPARATOR
50131         instead of hard coded ':'.
50133 2017-10-07  Bruno Haible  <bruno@clisp.org>
50135         vma-iter: Fix truncated result on Linux (regression from 2017-09-26).
50136         * lib/vma-iter.c (MIN_LEFTOVER): New macro.
50137         (STACK_ALLOCATED_BUFFER_SIZE): Set to a minimal value if not needed.
50138         (rof_open): On Linux, do multiple read() calls and make sure
50139         MIN_LEFTOVER bytes are left when read() returns.
50141 2017-10-07  Bruno Haible  <bruno@clisp.org>
50143         vma-iter: Improve support for GNU/Hurd.
50144         * lib/vma-iter.c (vma_iterate): On GNU/Hurd, use the Mach vm_region()
50145         API, not the /proc file system.
50147 2017-10-07  Bruno Haible  <bruno@clisp.org>
50149         test-framework-sh: Don't require bash on Windows and OS/2.
50150         Reported by KO Myung-Hun.
50151         * tests/test-init.sh: Use 'shopt' only when running in bash.
50153 2017-10-06  KO Myung-Hun  <komh@chollian.net>
50155         wcwidth: check a macro version of wcwidth () as well
50156         * lib/wchar.in.h: Revert commit from 2016-01-14.
50157         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test if wcwidth is a macro.
50159 2017-10-06  Bruno Haible  <bruno@clisp.org>
50161         getopt-posix: Clarify copyright header.
50162         * lib/getopt.in.h: Don't state that gnulib is under LGPL.
50163         * lib/getopt-pfx-core.h: Likewise.
50164         * lib/getopt-pfx-ext.h: Likewise.
50165         * lib/getopt-cdefs.in.h: Likewise.
50167 2017-10-03  Bruno Haible  <bruno@clisp.org>
50169         Fix warning "`gl_HOST_CPU_C_ABI' was expanded before it was required".
50170         * modules/host-cpu-c-abi (configure.ac): Require, don't invoke
50171         gl_HOST_CPU_C_ABI.
50173 2017-10-03  Bruno Haible  <bruno@clisp.org>
50175         doc: warn about misuse of strncpy and wcsncpy.
50176         * doc/posix-functions/strcpy.texi: Describe requirements on prior
50177         memory allocation.
50178         * doc/posix-functions/wcscpy.texi: Likewise.
50179         * doc/posix-functions/strncpy.texi: Describe what this function is not
50180         useful for.
50181         * doc/posix-functions/wcsncpy.texi: Likewise.
50183 2017-10-02  Paul Eggert  <eggert@cs.ucla.edu>
50185         fsuage: fix typo in previous change
50186         * lib/fsusage.c: Remove stray include of full-read.h.
50187         Problem reported by Sam Steingold for macOS (Bug#28669).
50189 2017-10-01  Paul Eggert  <eggert@cs.ucla.edu>
50191         fsusage: remove SVR2 support
50192         SVR2 was obsolete by 1986 and is no longer supported by anybody,
50193         and its code was getting in the way of use of this module by
50194         Emacs, which has its own ‘read’ function anyway.
50195         * lib/fsusage.c: Do not include sys/filsys.h.
50196         (get_fs_usage): Remove SVR2-specific code.
50197         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE):
50198         Do not test for sys/filsys.h or set STAT_READ_FILSYS.
50199         * modules/fsusage (Depends-on): Do not depend on full-read.
50201         Simplify autoupdate of licenses
50202         * config/srclistvars.sh (GNUWWWLICENSES): Move to a more-typical
50203         place.
50205 2017-10-01  Bruno Haible  <bruno@clisp.org>
50207         vma-iter: Add support for GNU/Hurd.
50208         * lib/vma-iter.c: Treat GNU/Hurd like Linux.
50209         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on GNU/kFreeBSD.
50211 2017-09-30  Bruno Haible  <bruno@clisp.org>
50213         vma-iter: Make it work on 32-bit Solaris with module 'largefile'.
50214         * modules/vma-iter: Don't test for sys/procfs.h, as this test would
50215         fail when module 'largefile' is in use.
50216         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Don't test HAVE_SYS_PROCFS_H.
50217         * lib/vma-iter.c: Undefine _FILE_OFFSET_BITS early.
50218         Don't test HAVE_SYS_PROCFS_H.
50220 2017-09-30  Bruno Haible  <bruno@clisp.org>
50222         havelib: Make it work for CC="gcc -m32" (regression from 2017-02-19).
50223         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Require gl_HOST_CPU_C_ABI.
50224         When $CC produces 32-bit code, set acl_libdirstem to 'lib', not 'lib64'.
50225         * modules/havelib (Depends-on): Add host-cpu-c-abi.
50227 2017-09-30  Bruno Haible  <bruno@clisp.org>
50229         uniname/uniname: Don't assume C99 compiler (regression from 2015-02-16).
50230         * lib/uniname/uniname.c (unicode_name_character): Add braces around
50231         scope of local variables.
50233 2017-09-28  Bruno Haible  <bruno@clisp.org>
50235         string: code style
50236         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Reorder list of
50237         substitutable variables.
50238         * modules/string (Makefile.am): Likewise.
50240 2017-09-26  Bruno Haible  <bruno@clisp.org>
50242         uniname/uniname-tests: Tighten code.
50243         * tests/uniname/test-uninames.c (fill_names, fill_aliases): Merge two
50244         local variables into one.
50246 2017-09-26  Bruno Haible  <bruno@clisp.org>
50248         vma-iter: Improvements for Linux and BSD platforms.
50249         - Add support for DragonFly BSD.
50250         - Make it more reliable on Linux, GNU/kFreeBSD, FreeBSD, NetBSD.
50251         * lib/vma-iter.c (struct rofile, rof_open, rof_peekchar, rof_close):
50252         Read the entire file into memory in a single system call.
50253         (vma_iterate): Update. Read from /proc on DragonFly BSD like on FreeBSD.
50254         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on DragonFly BSD.
50256 2017-09-26  Bruno Haible  <bruno@clisp.org>
50258         vma-iter: Provide the protection flags on FreeBSD.
50259         * lib/vma-iter.c (vma_iterate) [FreeBSD]: When reading from /proc,
50260         skip three fields between the addresses and the protection flags.
50262 2017-09-26  Paul Eggert  <eggert@cs.ucla.edu>
50264         glob: remove bogus extern decl
50265         * lib/glob.c (__glob_pattern_type): Remove now-spurious
50266         extern declaration.  Problem reported by Adhemerval Zanella in:
50267         https://sourceware.org/ml/libc-alpha/2017-09/msg00972.html
50269 2017-09-25  Paul Eggert  <eggert@cs.ucla.edu>
50271         uniname/uniname-tests: integer overflow fix
50272         * tests/uniname/test-uninames.c (fill_names, fill_aliases):
50273         Check for integer overflow.
50275         duplocale-tests: fix unlikely crash
50276         * tests/test-duplocale.c (get_locale_dependent_values):
50277         Don’t crash with absurdly long month names.
50279         maint: fix overflow checking in nap.h
50280         * modules/chown-tests:
50281         * modules/fchownat-tests, modules/fdutimensat-tests:
50282         * modules/futimens-tests, modules/lchown-tests:
50283         * modules/stat-time-tests, modules/utime-tests:
50284         * modules/utimens-tests, modules/utimensat-tests:
50285         Depend on intprops.
50286         * tests/nap.h: Include intprops.h.
50287         (diff_timespec): Handle overflow properly.
50289         sys_types: update URL
50290         * m4/sys_types_h.m4: Use https: URL.
50292         parse-datetime: fix dependency
50293         * modules/parse-datetime (Depends-on): Depend
50294         on nstrftime, not strftime.
50296         parse-datetime, posixtm: avoid uninit access
50297         * lib/parse-datetime.y (parse_datetime2):
50298         * lib/posixtm.c (posixtime):
50299         Do not access uninitialized storage, even though the resulting
50300         value is never used.
50302 2017-09-25  Bruno Haible  <bruno@clisp.org>
50304         vma-iter: Improvements for BSD platforms.
50305         - Add support for GNU/kFreeBSD.
50306         - Make it work on FreeBSD and NetBSD even when /proc is not mounted.
50307         - Speed up on OpenBSD.
50308         * lib/vma-iter.c (struct rofile, rof*): Define also on GNU/kFreeBSD.
50309         (vma_iterate_bsd): New function.
50310         (vma_iterate): Use it as fallback on FreeBSD and NetBSD. Use it as
50311         first choice on OpenBSD. Treat GNU/kFreeBSD like Linux.
50312         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on GNU/kFreeBSD.
50313         * modules/vma-iter (configure.ac): Require AC_C_INLINE.
50315 2017-09-23  Bruno Haible  <bruno@clisp.org>
50317         strfmon_l: New module.
50318         * modules/strfmon_l: New file.
50319         * lib/strfmon_l.c: New file.
50320         * m4/strfmon_l.m4: New file.
50321         * doc/posix-functions/strfmon_l.texi: Mention the new module.
50322         * modules/strfmon_l-tests: New file.
50323         * tests/test-strfmon_l.c: New file.
50325         monetary: New module.
50326         * modules/monetary: New file.
50327         * lib/monetary.in.h: New file.
50328         * m4/monetary_h.m4: New file.
50329         * doc/posix-headers/monetary.texi: Mention the new module.
50330         * modules/monetary-tests: New file.
50331         * tests/test-monetary.c: New file.
50332         * modules/monetary-c++-tests: New file.
50333         * tests/test-monetary-c++.cc: New file.
50334         * modules/duplocale-tests (configure.ac): Use AC_CHECK_HEADERS_ONCE.
50336 2017-09-23  Bruno Haible  <bruno@clisp.org>
50338         duplocale tests: Fix test crash on Linux/x86.
50339         * tests/test-duplocale.c (test_with_uselocale): Disconnect the mixed2
50340         locale from the current thread before freeing it.
50342 2017-09-21  Paul Eggert  <eggert@cs.ucla.edu>
50344         mktime: port to OpenVMS
50345         Problem reported by John E. Malmberg in:
50346         https://lists.gnu.org/r/bug-gnulib/2017-09/msg00100.html
50347         * m4/mktime.m4 (TIME_T_IS_SIGNED): Default to 0.
50349 2017-09-16  Paul Eggert  <eggert@cs.ucla.edu>
50351         manywarnings: port to GCC on 64-bit MS-Windows
50352         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Work better if
50353         LONG_MAX < PTRDIFF_MAX.  Problem reported by Richard Copley in:
50354         https://lists.gnu.org/r/emacs-devel/2017-09/msg00392.html
50356 2017-09-13  Bruno Haible  <bruno@clisp.org>
50358         all: Replace many more http URLs by https URLs. Update stale URLs.
50359         * users.txt: Remove mention of 'newts'.
50360         * lib/localename.c: Update comment about LANG_SOTHO.
50362 2017-09-13  Paul Eggert  <eggert@cs.ucla.edu>
50364         all: Replace many http URLs by https URLs.
50366 2017-09-12  Bruno Haible  <bruno@clisp.org>
50368         doc: Prefer https URLs where possible.
50369         * doc/**/*.texi: Use https URLs instead of http URLs where possible.
50370         * doc/ld-output-def.texi: Remove unavailable URL.
50372 2017-09-12  Paul Eggert  <eggert@cs.ucla.edu>
50374         maintainer-makefile: FTP -> HTTPS
50375         * top/maint.mk (url_dir_list, ftp-gnu): Use HTTPS protocol instead
50376         of FTP, which is planned to be decommissioned on 2017-11-01.
50378 2017-09-12  Tim Rühsen  <tim.ruehsen@gmx.de>  (tiny change)
50380         libc-config: Fix __GNUC_PREREQ macro.
50381         * lib/libc-config.h (__GNUC_PREREQ): Use __GNUC_MINOR__, not
50382         __GNUC_MINOR.
50384 2017-09-09  Bruno Haible  <bruno@clisp.org>
50386         gnulib-tool: Simplify commit from 2015-08-20.
50387         * gnulib-tool (func_add_or_update): Remove local variable
50388         is_binary_file.
50390 2017-09-08  Bruno Haible  <bruno@clisp.org>
50392         stddef: Avoid conflict with system-defined max_align_t.
50393         The configure-determined HAVE_MAX_ALIGN_T may not always be accurate.
50394         Reported by Werner Lemberg <wl@gnu.org> in
50395         <https://lists.gnu.org/r/bug-gnulib/2017-08/msg00185.html>.
50396         * lib/stddef.in.h (rpl_max_align_t): Renamed from max_align_t.
50397         (max_align_t): Define as a macro.
50398         (GNULIB_defined_max_align_t): New macro. Guards against multiple
50399         definitions of rpl_max_align_t in different copies of gnulib-generated
50400         <stddef.h>.
50402 2017-09-05  Paul Eggert  <eggert@cs.ucla.edu>
50404         libc-config: port to MSVC
50405         Problems reported by Gisle Vanem in:
50406         http://lists.gnu.org/r/bug-gnulib/2017-09/msg00016.html
50407         * lib/libc-config.h (__inline): Don't define if HAVE___INLINE.
50408         (libc_hidden_proto): Stick to Standard C syntax for varargs macro.
50409         * m4/__inline.m4: New file.
50410         * modules/libc-config (Files): Add it.
50411         (Depends-on): Use it.
50413         glob: Use enum for __glob_pattern_type result
50414         From a patch proposed by Adhemerval Zanella in:
50415         https://sourceware.org/ml/libc-alpha/2017-09/msg00212.html
50416         * lib/glob_internal.h (GLOBPAT_NONE, GLOBPAT_SPECIAL)
50417         (GLOBPAT_BACKSLASH, GLOBPAT_BRACKET): New constants.
50418         * lib/glob_internal.h (__glob_pattern_type):
50419         * lib/glob.c (glob):
50420         * lib/glob_pattern_p.c (__glob_pattern_p):
50421         Use them.
50423         glob: fix for use in glibc
50424         Problem reported by Adhemerval Zanella in:
50425         https://sourceware.org/ml/libc-alpha/2017-09/msg00213.html
50426         * lib/glob.c (DT_UNKNOWN, DT_DIR, DT_LINK):
50427         Do not redefine if _LIBC.
50429 2017-09-02  Paul Eggert  <eggert@cs.ucla.edu>
50431         glob: fix bugs with long login names
50432         Problem reported by Adhemerval Zanella in:
50433         https://sourceware.org/ml/libc-alpha/2017-08/msg00455.html
50434         * lib/glob.c (GET_LOGIN_NAME_MAX): Remove.
50435         (glob): Use the same scratch buffer for both getlogin_r and
50436         getpwnam_r.  Don’t require preallocation of the login name.  This
50437         simplifies storage allocation, and corrects the handling of
50438         long login names.
50440 2017-09-02  Bruno Haible  <bruno@clisp.org>
50442         dirent: Update doc.
50443         * doc/posix-headers/dirent.texi: More concrete list of platforms.
50445 2017-09-02  Paul Eggert  <eggert@cs.ucla.edu>
50447         glob: fix getpwnam_r errno typo
50448         * lib/glob.c (glob): Fix longstanding misuse of errno after
50449         getpwnam_r, which returns an error number rather than setting
50450         errno.
50452         glob: fix typo in recent change
50453         * lib/glob.c (glob) [!HAVE_GETPWNAM_R && !_LIBC]:
50454         Fix recently-introduced typo.
50456 2017-09-02  Paul Eggert  <eggert@cs.ucla.edu>
50458         glob: don't save and restore errno unnecessarily
50459         * lib/glob.c (glob): Don't save and restore errno
50460         merely because we have getpwnam_r.
50462         glob: don't assume getpwnam_r
50463         * lib/glob.c (glob): Port recent patches to platforms
50464         lacking getpwnam_r.
50466         scratch_buffer: don’t use private glibc API
50467         Suggested by Florian Weimer in:
50468         http://lists.gnu.org/r/bug-gnulib/2017-09/msg00004.html
50469         * lib/scratch_buffer.h: Rename to lib/malloc/scratch_buffer.h.
50470         * lib/scratch_buffer_grow.c: Rename to
50471         lib/malloc/scratch_buffer_grow.c.
50472         * lib/scratch_buffer_grow_preserve.c: Rename to
50473         lib/malloc/scratch_buffer_grow_preserve.c.
50474         * lib/scratch_buffer_set_array_size.c: Rename to
50475         lib/malloc/scratch_buffer_set_array_size.c.
50476         * lib/scratch_buffer.h: New file.
50477         * modules/scratch_buffer (Files, Makefile.am):
50478         Adjust to source-file renaming.
50480 2017-09-01  Paul Eggert  <eggert@cs.ucla.edu>
50482         glob: use scratch_buffer instead of extend_alloca
50483         Much of the lib/glob.c part of this patch comes from a glibc patch
50484         proposed by Adhemerval Zanella in:
50485         https://sourceware.org/ml/libc-alpha/2017-08/msg00456.html
50486         * lib/glob.c: Do not include <config.h>, since <libc-config.h>,
50487         included via glob.h, does this for us now.
50488         (__set_errno): Remove, as libc-config does this for us now.
50489         Include <scratch_buffer.h>.
50490         (GETPW_R_SIZE_MAX): Remove.
50491         (glob): Use struct scratch_buffer instead of extend_alloca.
50492         * lib/glob.in.h: Include libc-config.h rather than
50493         including <sys/cdefs.h> conditionally.
50494         (__BEGIN_DECLS, __END_DECLS, __THROW, __THROWNL, attribute_hidden)
50495         (__glibc_unlikely, __restrict, weak_alias):
50496         Remove, as libc-config does this for us now.
50497         * m4/glob.m4 (gl_PREREQ_GLOB):
50498         Remove sys/cdefs.h tests; no longer needed.
50499         * modules/glob (Depends-on): Add libc-config, scratch_buffer.
50500         (glob.h): Do not replace HAVE_SYS_CDEFS_H.
50502         scratch_buffer: new module
50503         * lib/scratch_buffer.h, lib/scratch_buffer_grow.c:
50504         * lib/scratch_buffer_grow_preserve.c:
50505         * lib/scratch_buffer_set_array_size.c:
50506         New files, copied from glibc with very minor changes that can be
50507         copied back.
50508         * modules/scratch_buffer: New file.
50510         libc-config: new module
50511         * MODULES.html.sh: Add libc-config.
50512         * lib/cdefs.h: New file, copied from the GNU C Library with very
50513         minor changes that can be copied back.
50514         * lib/libc-config.h, modules/libc-config: New files.
50516 2017-08-31  Paul Eggert  <eggert@cs.ucla.edu>
50518         glob: match dangling symlinks
50519         This fixes a bug I inadvertently introduced to Gnulib when I
50520         merged glibc glob back into gnulib on 2007-10-16.  This fix is
50521         inspired by a patch proposed for glibc by Adhemerval Zanella in:
50522         https://sourceware.org/ml/libc-alpha/2017-08/msg00446.html
50523         * doc/posix-functions/glob.texi: Update list of affected platforms.
50524         * lib/glob.c (__lstat64): New macro.
50525         (is_dir): New function.
50526         (glob, glob_in_dir): Match symlinks even if they are dangling.
50527         (link_stat, link_exists_p): Remove.  All uses removed.
50528         * lib/glob.in.h (__attribute_noinline__): Remove; no longer used.
50529         * m4/glob.m4 (gl_PREREQ_GLOB): Do not check for fstatat.
50530         * modules/glob-tests (Depends-on): Add symlink.
50531         * tests/test-glob.c: Include errno.h, unistd.h.
50532         (BASE): New macro.
50533         (main): Test dangling symlinks, if symlinks are supported.
50535         glob, backupfile: inode 0 is a valid inode number
50536         * doc/posix-functions/readdir.texi (readdir):
50537         * doc/posix-headers/dirent.texi (dirent.h):
50538         Document more readdir portability issues.
50539         * lib/backupfile.c (REAL_DIR_ENTRY): Remove.
50540         (numbered_backup): Don’t treat inode 0 any differently from
50541         other inode values.
50542         * lib/glob.c (struct readdir_result): Remove skip_entry member.
50543         (readdir_result_skip_entry, D_INO_TO_RESULT): Remove.
50544         All uses removed.
50545         * modules/glob (Depends-on): Remove d-ino.
50547         glob: simplify symlink detection
50548         * lib/glob.c (dirent_type): New type.  Use uint_fast8_t not
50549         uint8_t, as C99 does not require uint8_t.
50550         (struct readdir_result): Use it.  Do not define skip_entry unless
50551         it is needed; this saves a byte on platforms lacking d_ino.
50552         (readdir_result_type, readdir_result_skip_entry):
50553         New functions, replacing ...
50554         (readdir_result_might_be_symlink, readdir_result_might_be_dir):
50555         ... these functions, which were removed.  This makes the callers
50556         easier to read.  All callers changed.
50557         (D_INO_TO_RESULT): Now empty if there is no d_ino.
50559 2017-08-30  Pádraig Brady  <P@draigBrady.com>
50561         fts-tests: tag as a longrunning-test so not included by default
50562         * modules/fts-tests: This test takes about 20s on current systems,
50563         and uses about 285M of space on ext4.
50565 2017-08-30  Pádraig Brady  <P@draigBrady.com>
50567         renameat2: fix compilation on alpine linux
50568         * m4/renameat.m4: Check for <linux/fs.h> presence.
50569         * lib/renameat2.h: Only include <linux/fs.h> if present.
50570         Reported by Assaf Gordon on Alpine Linux.
50572 2017-08-24  Paul Eggert  <eggert@cs.ucla.edu>
50574         glob: try to port recent changes to MS-Windows
50575         Problem reported by Bruno Haible in:
50576         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00170.html
50577         * lib/glob.c (__glob_pattern_p) [!_LIBC]: Move from here ...
50578         * lib/glob.in.h (__glob_pattern_p): ... to here.
50580 2017-08-24  Eric Blake  <eblake@redhat.com>
50582         warnings: fix compilation with old autoconf
50583         * m4/warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C))
50584         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C++)): Use m4_defun rather than
50585         AC_DEFUN.
50586         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C))
50587         (gl_MANYWARN_ALL_GCC(C++)): Likewise.
50589 2017-08-24  Bruno Haible  <bruno@clisp.org>
50591         glob: Fix compilation error on NetBSD 7.0 and OpenBSD 6.0.
50592         * modules/glob (Depends-on): Add c99.
50594 2017-08-24  Paul Eggert  <eggert@cs.ucla.edu>
50596         glob: fix typo that broke platforms lacking d_ino
50597         This typo also hurt performance on GNU/Linux and similar hosts.
50598         * lib/glob.c (D_INO_TO_RESULT): Fix typo (reversed ifdef)
50599         in previous change.
50601 2017-08-23  Paul Eggert  <eggert@cs.ucla.edu>
50603         glob: merge from glibc with Zanella glob changes
50604         Merge glob from glibc, with changes for glob proposed
50605         by Adhemerval Zanella in the thread starting here:
50606         https://sourceware.org/ml/libc-alpha/2017-08/msg01079.html
50607         plus some fixes for this merge.
50608         * lib/glob_internal.h, lib/glob_pattern_p.c, lib/globfree.c:
50609         New files, ported from glibc.
50610         * lib/glob-libc.h (_Restrict_): Remove.  All uses replaced
50611         with __restrict.
50612         (__size_t): Remove.  All uses replaced by size_t.
50613         (size_t): Define by defining __need_size_t and including <stddef.h>.
50614         This should work even in non-glibc platforms, where any name
50615         pollution is OK.
50616         Use __USE_MISC instead of __USE_BSD || __USE_GNU.
50617         (struct stat64): Don’t worry about __GLOB_GNULIB.
50618         (glob, globfree, glob_pattern_p): Remove macros for
50619         __USE_FILE_OFFSET64 && __GNUC__ < 2 && !defined __GLOB_GNULIB
50620         case.  Remove _GL_ARG_NONNULL as GNU behavior is to accept NULL
50621         but set errno.
50622         * lib/glob.c (_GL_ARG_NONNULL) [!_LIBC]: Remove.  All uses
50623         removed since the glibc behavior works on null pointers.
50624         Do not include stdio.h; old SunOS is irrelevant now.
50625         Do not worry about GLOB_ONLY_P as we now mimic glibc here.
50626         Include glob_internal.h.
50627         (D_INO_TO_RESULT): Depend on (_LIBC || D_INO_IN_DIRENT), not
50628         ((POSIX || WINDOWS32) && !__GNU_LIBRARY__).  The latter probably
50629         worked only coincidentally.
50630         (attribute_hidden, __attribute_noinline__, __glibc_unlikely):
50631         Remove macros; now done in glob.in.h.
50632         (size_add_wrapv): Do not use __builtin_add_overflow if __ICC.
50633         (glob): Properly initialize glob structure with
50634         GLOB_BRACE|GLOB_DOOFFS (bug 20707).
50635         Remove old code using SHELL since Bash no longer
50636         uses this.
50637         (glob, prefix_array): Separate MS code better.
50638         (glob, glob_in_dir): Use C99 decls before statements when glibc
50639         does.
50640         (glob_in_dir): Remove old Amiga and VMS code.
50641         (globfree, __glob_pattern_type, __glob_pattern_p): Move to
50642         separate files.
50643         * lib/glob.in.h (attribute_hidden, __attribute_noinline__)
50644         (__glibc_unlikely):
50645         Move here from glob.c.
50646         (__restrict): New macro here, replacing the _Restrict_ in glob.c.
50647         (weak_alias): New macro.
50648         (__size_t): Remove.  All uses replaced by size_t.
50649         * modules/d-ino (License): Now LGPLv2+, for compatibility with glob.
50650         * modules/glob (Files): Add +lib/glob_internal.h,
50651         lib/glob_pattern_p.c, lib/globfree.c.
50652         (Depends-on): Remove snippet/arg-nonnull.
50654 2017-08-22  Paul Eggert  <eggert@cs.ucla.edu>
50656         glob: port to clang's Undefined Sanitizer
50657         Problem reported by Tim Rühsen in:
50658         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00144.html
50659         * lib/glob.c (FLEXIBLE_ARRAY_MEMBER) [_LIBC]: Define to empty.
50660         (glob_in_dir): Do not rely on undefined behavior in accessing
50661         struct members beyond their bounds.  Use a flexible array member
50662         instead.
50664 2017-08-21  Paul Eggert  <eggert@cs.ucla.edu>
50666         vc-list-files: port to Solaris 10
50667         * build-aux/vc-list-files: Don't assume test -e works.
50669 2017-08-21  Karl Berry  <karl@freefriends.org>
50671         * doc/posix-functions/srandom.texi (srandom): typo }.
50673 2017-08-20  Paul Eggert  <eggert@cs.ucla.edu>
50675         git-version-gen: port to Solaris 10
50676         Problem reported by Dagobert Michelsen in:
50677         http://lists.gnu.org/r/grep-devel/2017-08/msg00002.html
50678         * build-aux/git-version-gen (v_from_git):
50679         Use expr instead of shell substitution.
50681 2017-08-19  Bruno Haible  <bruno@clisp.org>
50683         host-cpu-c-abi: Improve detection of MIPS ABI.
50684         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): For MIPS, test the value of
50685         _MIPS_SIM.
50687 2017-08-17  Bruno Haible  <bruno@clisp.org>
50689         hypot tests: Fix test failure on FreeBSD 11.0/x86.
50690         * tests/test-hypot.h (test_function): Declare z as 'volatile'.
50692 2017-08-17  Bruno Haible  <bruno@clisp.org>
50694         float: Fix LDBL_MIN value on FreeBSD/x86.
50695         * lib/float.in.h (LDBL_MIN) [__FreeBSD__]: Add more precision.
50697 2017-08-17  Bruno Haible  <bruno@clisp.org>
50699         random: Fix test compilation failure on Cygwin 1.5.25.
50700         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_INITSTATE,
50701         HAVE_DECL_SETSTATE.
50702         * m4/random.m4 (gl_FUNC_RANDOM): Test whether initstate and setstate are
50703         declared.
50704         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_INITSTATE,
50705         HAVE_DECL_SETSTATE.
50706         * lib/stdlib.in.h (initstate): Declare also if HAVE_DECL_INITSTATE is 0.
50707         (setstate): Declare also if HAVE_DECL_SETSTATE is 0.
50708         * doc/posix-functions/initstate.texi: Mention the Cygwin 1.5.x problem.
50709         * doc/posix-functions/random.texi: Likewise.
50710         * doc/posix-functions/setstate.texi: Likewise.
50711         * doc/posix-functions/srandom.texi: Likewise.
50713 2017-08-16  Bruno Haible  <bruno@clisp.org>
50715         stdnoreturn: Fix test compilation failure on Cygwin.
50716         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): On Cygwin, use gnulib's
50717         <stdnoreturn.h> replacement.
50718         * lib/stdnoreturn.in.h (noreturn): Treat Cygwin like MSVC.
50719         * doc/posix-headers/stdnoreturn.texi: Mention the Cygwin problem.
50721 2017-08-16  Bruno Haible  <bruno@clisp.org>
50723         thread: Fix conflict with pthread_sigmask module.
50724         * lib/glthread/thread.h (pthread_sigmask): Don't declare it weak if
50725         it's defined as a macro.
50726         * modules/thread (Depends-on): Add pthread_sigmask.
50728 2017-08-16  Paul Eggert  <eggert@cs.ucla.edu>
50730         rename: port better to NetBSD
50731         * doc/posix-functions/rename.texi (rename): NetBSD 7
50732         does not have the link-count bug.
50733         * m4/rename.m4 (gl_FUNC_RENAME): Don’t consider NetBSD to be
50734         broken merely because rename ("a", "b") removes "a" when the two
50735         names are hard links to the same file.
50737 2017-08-16  Bruno Haible  <bruno@clisp.org>
50739         iconv_open, uni*: Add support for VPATH builds with OpenBSD 'make'.
50740         * modules/iconv_open (Makefile.am): In the rules that use gperf, prefix
50741         the target file names with '$(srcdir)/'.
50742         * modules/unicase/locale-language (Makefile.am): Likewise.
50743         * modules/unicase/special-casing (Makefile.am): Likewise.
50744         * modules/unictype/bidiclass-byname (Makefile.am): Likewise.
50745         * modules/unictype/category-byname (Makefile.am): Likewise.
50746         * modules/unictype/combining-class-byname (Makefile.am): Likewise.
50747         * modules/unictype/joininggroup-byname (Makefile.am): Likewise.
50748         * modules/unictype/joiningtype-byname (Makefile.am): Likewise.
50749         * modules/unictype/property-byname (Makefile.am): Likewise.
50750         * modules/unictype/scripts (Makefile.am): Likewise.
50751         * modules/uninorm/composition (Makefile.am): Likewise.
50753 2017-08-16  Bruno Haible  <bruno@clisp.org>
50755         nonblocking-socket tests: Fix failure on OpenBSD 6.0.
50756         * tests/test-nonblocking-socket.h (SOCKET_DATA_BLOCK_SIZE): Increase
50757         value for OpenBSD.
50759 2017-08-16  Bruno Haible  <bruno@clisp.org>
50761         rename, renameat: Update doc regarding NetBSD.
50762         * doc/posix-functions/rename.texi: Clarify that when using
50763         -D_XOPEN_SOURCE=500 on NetBSD 7.0, the hard link bug is gone.
50764         * doc/posix-functions/renameat.texi: Be more precise about NetBSD
50765         version.
50767 2017-08-15  Paul Eggert  <eggert@cs.ucla.edu>
50769         renameat2: port better to macOS
50770         * lib/renameat2.c (renameat2): Use renameatx_np if available.
50772         futimens: don’t assume struct timespec layout
50773         * m4/futimens.m4 (gl_FUNC_FUTIMENS):
50774         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT):
50775         * tests/test-fdutimensat.c (main):
50776         * tests/test-futimens.h (test_futimens):
50777         * tests/test-lutimens.h (test_lutimens):
50778         * tests/test-utimens.h (test_utimens):
50779         * tests/test-utimensat.c (main):
50780         Don’t assume that struct timespec is a two-member structure in
50781         tv_sec, tv_nsec order.  Although this is true on all platforms we
50782         know about, POSIX does not guarantee it.
50784         rename: document+test NetBSD rename
50785         Test failure reported by Bruno Haible in:
50786         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00104.html
50787         This is an area where NetBSD is better-behaved than POSIX,
50788         so allow the NetBSD behavior in tests.
50789         * doc/posix-functions/rename.texi:
50790         * doc/posix-functions/renameat.texi: Document NetBSD behavior.
50791         * tests/test-rename.h (test_rename): Allow NetBSD behavior.
50793 2017-08-15  Bruno Haible  <bruno@clisp.org>
50795         renameat: Ensure declaration in <stdio.h> on NetBSD.
50796         * lib/stdio.in.h: Include <unistd,h> also on NetBSD.
50797         * doc/posix-functions/renameat.texi: Mention this problem.
50799 2017-08-15  Bruno Haible  <bruno@clisp.org>
50801         duplocale: Work around NetBSD 7.0 bug.
50802         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Test against the NetBSD 7.0 bug.
50803         * lib/duplocale.c: Add comment about NetBSD problem.
50804         * doc/posix-functions/duplocale.texi: Mention the NetBSD problem.
50806 2017-08-15  Bruno Haible  <bruno@clisp.org>
50808         duplocale tests: Verify use with *_l functions.
50809         * modules/duplocale-tests (configure.ac): Test for uselocale and
50810         some *_l functions.
50811         * tests/test-duplocale.c (test_with_uselocale): New function, extracted
50812         from main.
50813         (get_locale_dependent_values_from, test_with_locale_parameter): New
50814         functions.
50815         (main): Test both test_with_uselocale and test_with_locale_parameter.
50817 2017-08-15  Bruno Haible  <bruno@clisp.org>
50819         extensions: Enable NetBSD specific extensions.
50820         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define _NETBSD_SOURCE.
50822 2017-08-14  Bruno Haible  <bruno@clisp.org>
50824         open, openat: Update doc about O_CLOEXEC.
50825         * doc/posix-functions/open.texi: More concrete list of platforms.
50826         * doc/posix-functions/openat.texi: Likewise.
50828 2017-08-14  Paul Eggert  <eggert@cs.ucla.edu>
50830         open: support O_CLOEXEC
50831         * NEWS, doc/posix-functions/open.texi:
50832         * doc/posix-functions/openat.texi: Document this.
50833         * lib/fcntl.in.h (O_CLOEXEC): Default to a nonzero value.
50834         (GNULIB_defined_O_CLOEXEC): New symbol.
50835         * lib/open.c: Include cloexec.h.
50836         (open): Support O_CLOEXEC.
50837         * lib/openat.c: Include cloexec.h.
50838         (rpl_openat): Support O_CLOEXEC.
50839         * lib/popen-safer.c: Do not include cloexec.h.
50840         (open_noinherit): Remove.
50841         (popen_safer): Use O_CLOEXEC instead of set_cloexec_flag.
50842         * lib/save-cwd.c: Do not include cloexec.h.
50843         (save_cwd): Use O_CLOEXEC instead of set_cloexec_flag.
50844         * m4/open-cloexec.m4: New file.
50845         * m4/open.m4 (gl_FUNC_OPEN): Require gl_PREPROC_O_CLOEXEC.
50846         Replace 'open' if O_CLOEXEC is not present.
50847         * m4/openat.m4 (gl_FUNC_OPENAT): Require gl_PREPROC_O_CLOEXEC.
50848         Replace 'openat' if O_CLOEXEC is not present.
50849         * modules/freopen (Depends-on): Depend on 'open' if replacing freopen.
50850         * modules/open (Files): Add m4/open-cloexec.m4.
50851         (Depends-on): Depend on cloexec if replacing 'open'.
50852         * modules/openat (Files): Add m4/open-cloexec.m4.
50853         (Depends-on): Depend on cloexec if replacing openat.
50854         * modules/popen-safer (Depends-on): Remove cloexec.
50855         * modules/save-cwd (Depends-on): Remove cloexec, and add
50856         fd-safer-flag and 'open'.
50858 2017-08-13  Paul Eggert  <eggert@cs.ucla.edu>
50860         reallocarray: minor fixes
50861         * doc/glibc-functions/reallocarray.texi: Update version numbers.
50862         * m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY): Don't trust _cv_ contents.
50863         * modules/reallocarray (License): Change from GPL to LGPL.
50864         * tests/test-reallocarray.c (main): Fix ENOMEM typo.
50865         Indent properly and don't use tabs.
50867 2017-08-13  Darshit Shah  <darnir@gnu.org>
50869         reallocarray: New module
50870         reallocarray is a new function in glibc 2.26 to safely allocate an array
50871         of memory locations with integer overflow protection.
50872         * MODULES.html.sh: Add reallocarray.
50873         * doc/glibc-functions/reallocarray.texi: Documentation for reallocarray.
50874         * lib/reallocarray.c: New file to implement module reallocarray.
50875         * lib/stdlib.in.h: Add function declarations for reallocarray.
50876         * m4/reallocarray.m4: New file.
50877         * m4/stdlib_h.m4: Declare reallocarray.
50878         * modules/reallocarray: New file.
50879         * modules/reallocarray-test: New file.
50880         * modules/stdlib: Coerce stdlib.h to export reallocarray.
50881         * tests/test-reallocarray.c: New test.
50883 2017-08-12  Paul Eggert  <eggert@cs.ucla.edu>
50885         dirent-safer: fix cloexec race
50886         * lib/opendir-safer.c: Include fcntl.h instead of unistd-safer.h.
50887         (opendir_safer): Use F_DUPFD_CLOEXEC.
50888         * modules/dirent-safer (Depends-on): Add fcntl.  Remove unistd-safer.
50889         * tests/test-dirent-safer.c: Do not include unistd-safer.h,
50890         as it is no longer a prerequisite.  Use F_DUPFD_CLOEXEC
50891         instead of dup_safer.
50893         fts: fix cloexec races
50894         * lib/fts.c [!_LIBC]: Do not include dirent--.h, unistd--.h, cloexec.h.
50895         (opendirat, diropen): Use O_CLOEXEC instead of set_cloexec_flag.
50896         (fts_build): Use F_DUPD_CLOEXEC rinstad of set_cloexec_flag.
50897         (fd_ring_check): Set cloexec flag on new file descriptors.
50898         (fts_build, fd_ring_check): While we’re at it, make sure the
50899         resulting file descriptor is not 0, 1, or 2, since that is easy.
50901 2017-08-11  Bruno Haible  <bruno@clisp.org>
50903         fts tests: Fix link error.
50904         Reported by Tom G. Christensen in
50905         https://lists.gnu.org/r/bug-gnulib/2017-08/msg00078.html
50906         * modules/fts-tests (Makefile.am): Link test-fts against LIBINTL.
50908 2017-08-10  Paul Eggert  <eggert@cs.ucla.edu>
50910         fts: port recent changes to CentOS 6
50911         Problem reported by Tom G. Christensen in:
50912         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00064.html
50913         * lib/fts.c (fsword): New type.
50914         (struct dev_type, filesystem_type): Use it.
50915         * m4/fts.m4 (gl_FUNC_FTS_CORE): Check for __fsword_t.
50916         Also, check for f_type only if fstatfs and sys/vfs.h work.
50918 2017-08-09  Paul Eggert  <eggert@cs.ucla.edu>
50920         tempname: do not depend on secure_getenv
50921         Excess dependency noted by Eli Zaretskii (Bug#28023#17).
50922         * lib/tempname.c (__secure_getenv) [!_LIBC]: Remove; unused.
50923         * modules/tempname (Depends-on): Remove secure_getenv.
50925 2017-08-08  Paul Eggert  <eggert@cs.ucla.edu>
50927         extensions: add _OPENBSD_SOURCE
50928         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define _OPENBSD_SOURCE.
50930 2017-08-06  Reuben Thomas  <rrt@sc3d.org>
50931             Bruno Haible  <bruno@clisp.org>
50933         manywarnings: Add support for C++.
50934         * build-aux/g++-warning.spec: New file.
50935         * m4/manywarnings-c++.m4: New file.
50936         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C++)): New macro, that
50937         redirects to manywarnings-c++.m4.
50938         * modules/manywarnings (Files): Add m4/manywarnings-c++.m4.
50940 2017-08-06  Paul Eggert  <eggert@cs.ucla.edu>
50942         git-version-gen: another fix for tags with "-"
50943         * build-aux/git-version-gen: Improve fix for tags containing "-".
50944         Suggested by Markus Armbruster in:
50945         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00034.html
50947 2017-08-06  Bruno Haible  <bruno@clisp.org>
50949         warnings, manywarnings: Add support for multiple languages, not just C.
50950         * warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS_IMPL): Renamed from
50951         gl_UNKNOWN_WARNINGS_ARE_ERRORS.
50952         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C)): New macro.
50953         (gl_UNKNOWN_WARNINGS_ARE_ERRORS(C++)): New macro.
50954         (gl_UNKNOWN_WARNINGS_ARE_ERRORS): Dispatch to
50955         gl_UNKNOWN_WARNINGS_ARE_ERRORS(_AC_LANG).
50956         (gl_WARN_ADD): Require the gl_UNKNOWN_WARNINGS_ARE_ERRORS specialization
50957         of the current language. If C++ is the current language, modify
50958         WARN_CXXFLAGS instead of WARN_CFLAGS.
50959         * manywarnings.m4 (gl_MANYWARN_ALL_GCC(C)): New macro, extracted from
50960         gl_MANYWARN_ALL_GCC.
50961         (gl_MANYWARN_ALL_GCC): Dispatch to gl_MANYWARN_ALL_GCC(_AC_LANG).
50963 2017-08-06  Markus Armbruster  <armbru@pond.sub.org>
50965         git-version-gen: Fix for tags containing '-'
50967         Really old versions of git-describe (before v1.5.0, Feb 2007)
50968         don't have the number of commits in their long format output,
50969         i.e. where modern 'git describe --abbrev=4 --match="v*"' prints
50970         "v0.1-1494-g124b9", they print "v0.1-1494-g124b9".  git-version-gen
50971         recognizes both patterns, and normalizes the old format to the new one.
50973         Unfortunately, this normalization code gets confused when the tag
50974         contains '-'.  Reproducer:
50976             $ git-tag -m test v0.2-rc1
50977             $ build-aux/git-version-gen .tarball-version; echo
50978             build-aux/git-version-gen: WARNING: git rev-list failed
50979             UNKNOWN
50981         We take exact tag "v0.2-rc1" for the old format, extract the presumed
50982         tag "v0.2" from it, then run "git rev-list v0.2..HEAD" to count
50983         commits since tha tag.  Fails, because tag "v0.2" does not exist.
50985         * git-version-gen: We could perhaps drop support for versions from
50986         more than a decade ago.  But tightening the pattern match is easy
50987         enough, so do that.  Still breaks when you use version tags ending in
50988         something matching -g????, but you arguably get what you deserve then.
50990 2017-08-05  Paul Eggert  <eggert@cs.ucla.edu>
50992         valgrind-tests: use ls, and cache
50993         * m4/valgrind-tests.m4: Test ls, not bash.
50994         Problem reported by Reuben Thomas.
50995         Also, cache the result so that it can be overridden.
50997 2017-08-04  Paul Eggert  <eggert@cs.ucla.edu>
50999         manywarnings: port to 64-bit GCC builds of Emacs
51000         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Compute max safe
51001         object size rather than hardwiring 2147483647.  This is needed to
51002         build GNU Emacs, which has one conditional (and used
51003         only-in-theory) call to malloc with a literal greater than
51004         2147483647.
51006 2017-08-04  Bruno Haible  <bruno@clisp.org>
51008         Relax the license of some modules with no runtime code.
51009         * modules/std-gnu11 (License): Set to 'unlimited'.
51010         * modules/c99 (License): Likewise.
51011         Reported by Reuben Thomas <rrt@sc3d.org>.
51012         * modules/d-ino (License): Set to 'LGPL'.
51013         * modules/host-os (License): Likewise.
51014         * modules/longlong (License): Likewise.
51016 2017-08-03  Paul Eggert  <eggert@cs.ucla.edu>
51018         renameat2: port to RHEL 7 + NFS
51019         * lib/renameat2.c (renameat2) [SYS_renameat2]:
51020         Port to RHEL 7 + NFS.  Problem reported by Ted Zlatanov in:
51021         http://lists.gnu.org/r/emacs-devel/2017-08/msg00082.html
51023 2017-08-02  Paul Eggert  <eggert@cs.ucla.edu>
51025         renameat2: port to non-renameat platforms
51026         Problem reported for MSVC-2015 by Gisle Vanem in:
51027         http://lists.gnu.org/r/bug-gnulib/2017-08/msg00001.html
51028         * lib/renameat2.c [!HAVE_RENAMEAT]: Include <sys/stat.h> here too.
51029         (renameat2) [!HAVE_RENAMEAT]: Fix typo in arg passing.
51031 2017-08-01  Paul Eggert  <eggert@cs.ucla.edu>
51033         manywarnings: port to 32-bit GCC bug
51034         Problem reported by Pino Toscano in:
51035         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00150.html
51036         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Use 2**31 - 1,
51037         not 2**63 - 1, to work around the following GCC bug:
51038         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81650
51040 2017-07-30  Paul Eggert  <eggert@cs.ucla.edu>
51042         backupfile: new function to validate backup suffix
51043         * lib/backupfile.c (set_simple_backup_suffix): New function.
51044         (backupfile_internal): Use it.
51046         canonicalize: fix EOVERFLOW commentary
51047         Problem reported by Bruno Haible in:
51048         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00147.html
51049         * lib/canonicalize.c (canonicalize_filename_mode):
51050         * lib/canonicalize-lgpl.c (__realpath): Fix comments.
51052         Don't interpret EOVERFLOW to mean nonexistence
51053         * lib/fts.c (fts_stat): If lstat fails, report its errno, which
51054         may be EOVERFLOW; this is likely more useful than reporting the
51055         stat errno.
51056         * lib/glob.c (link_stat): Rename from link_exists2_p and
51057         return -1/0 instead of 0/1.  Caller changed.
51058         * lib/glob.c (link_exists_p):
51059         * lib/renameat2.c (rename_noreplace, renameat2):
51060         * lib/tempname.c (try_nocreate):
51061         If errno == EOVERFLOW then the directory entry exists, so do not
51062         act as if it does not exist.
51064         backup-rename: new module
51065         It is like backupfile, except it avoids some race conditions,
51066         and it does not output to stderr or exit.
51067         * MODULES.html.sh: Add backup-rename.
51068         * lib/backup-find.c, lib/backup-internal.h, lib/backup-rename.c:
51069         * modules/backup-rename: New files.
51070         * lib/backupfile.c: Turn this into an internals file, which
51071         contains code common to backupfile and backup_rename.  Include
51072         backupfile-internal.h instead of backupfile.h.  Do not include
51073         argmatch.h or xalloc.h: include xalloc-oversized.h.  Include
51074         renameat2.h and fcntl.h.
51075         (BACKUP_NOMEM): New constant.
51076         (numbered_backup): New args BASE_OFFSET and *DIRPP.  Do not exit
51077         on memory exhaustion; just return BACKUP_NOMEM.  Caller changed.
51078         (backupfile_internal): Rename from find_backup_file_name.
51079         Support new arg RENAME.
51080         (backup_args, backup_types, get_version, xget_version):
51081         Move to lib/backup-find.c.
51082         * lib/backupfile.h (backup_file_rename): New decl.
51083         * modules/backupfile (Files): Add lib/backup-internal.h,
51084         lib/backup-find.c.
51085         (Depends-on): Add dirfd, fcntl, renameat2.
51086         (lib_SOURCES): Add backup-find.c.
51088         renameat2: port better to older Solaris
51089         * lib/renameat2.c (renameat2): Set ret_val properly on old Solaris.
51090         Add goto to use a label, to silence picky compilers.
51092         fts-tests: port to gcc -Wwrite-strings
51093         * tests/test-fts.c (base, base_d): New static vars.
51094         (argv, remove_tree, main): Use them.
51096 2017-07-26  Reuben Thomas  <rrt@sc3d.org>
51098         relocatable-lib{,-lgpl}: improve documentation
51099         * doc/relocatable-maint.texi: Document use of relocatable-lib{,-lgpl}.
51100         Various other updates.
51102 2017-07-30  Reuben Thomas  <rrt@sc3d.org>
51103             Bruno Haible  <bruno@clisp.org>
51105         relocatable-lib{,-lgpl}: add Valgrind suppressions
51106         * lib/relocatable.valgrind: New file.
51107         * modules/relocatable-lib (Files): Add relocatable.valgrind.
51108         * modules/relocatable-lib-lgpl: Likewise.
51110 2017-07-26  Reuben Thomas  <rrt@sc3d.org>
51112         relocatable: Make the license on the sources the GPL.
51113         * lib/relocatable.h, lib/relocatable.c: Change the copyright notice from
51114         LGPL, which was a special case so that the relocatable source files
51115         could be used without gnulib-tool, to GPL. They can still be used under
51116         the LGPL, using the --lgpl option to gnulib-tool.
51118 2017-07-30  Bruno Haible  <bruno@clisp.org>
51120         host-cpu-c-abi: Detect ILP32 ABI on IA-64 HP-UX.
51121         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Distinguish ia64-ilp32
51122         from ia64. For arm64, test only __aarch64__, as __ARM_64BIT_STATE and
51123         __ARM_PCS_AAPCS64 are not reliable indicators: they are not defined on
51124         Ubuntu 14.04 (gcc 4.8.4) and Debian 8 (gcc 4.9.2).
51126 2017-07-27  Paul Eggert  <eggert@cs.ucla.edu>
51128         faccessat: document AT_SYMLINK_NOFOLLOW issue
51129         * doc/posix-functions/faccessat.texi: Modernize platform list.
51130         Document AT_SYMLINK_NOFOLLOW limitation.
51132         renameat2: port to Solaris 10
51133         * lib/renameat2.c (rename_noreplace): Use lstat, not faccessat
51134         with AT_SYMLINK_NOFOLLOW (which is not portable).
51135         (renameat): Undef before using, to avoid endless recursion when
51136         the replacement renameat calls renameat2 which calls the
51137         replacement renameat.
51138         (renameat2): Use lstatat, not faccessat with AT_SYMLINK_NOFOLLOW.
51139         * modules/renameat2 (Depends-on): Remove faccessat.
51140         * modules/renameat-tests (test_renameat_LDADD):
51141         * modules/renameat2-tests (test_renameat2_LDADD):
51142         Remove $(LIB_EACCESS).
51144         renameat2: new module
51145         Although the Linux syscall renameat2 is not in glibc (yet?), it is
51146         useful to have access to its RENAME_NOREPLACE flag.
51147         * MODULES.html.sh (func_all_modules): Add renameat2.
51148         * lib/renameat2.c, lib/renameat2.h, modules/renameat2:
51149         * modules/renameat2-tests, tests/test-renameat2.c: New files.
51150         * lib/renameat.c (renameat): Move most of the implementation
51151         to renameat2, and just call renameat2.
51152         * modules/renameat (Files): Remove lib/at-func2.c.
51153         (Depends-on): Depend only on renameat2.
51154         (Include): Remove <fcntl.h>.
51155         * modules/renameat-tests (test_renameat_LDADD): Add $(LIB_EACCESS),
51156         since renameat (via renameat2) might use faccessat.
51158 2017-07-27  Erik Skultety <eskultet@redhat.com>  (tiny change)
51160         vc-list-files: Adjust the script to support git worktrees
51161         * build-aux/vc-list-files: Require existence, not directory.
51163 2017-07-26  Paul Eggert  <eggert@cs.ucla.edu>
51165         doc: bring MODULES.html.sh up to date
51166         Somehow a few months ago we stopped updating MODULES.html.sh.
51167         I don’t recall explicitly deciding this, so I updated it now.
51168         Alternatively I suppose we could remove it.
51169         * MODULES.html.sh: Add builtin-expect, c99, ctime, explicit_bzero,
51170         localtime, localtime-buffer, noreturn, nstrftime, strftime-fixes,
51171         truncate, utime, utime-h, windows-stat-inodes,
51172         windows-stat-override, windows-stat-timespec, year2038.  Sort.
51174 2017-07-26  Jim Meyering  <meyering@fb.com>
51176         fprintftime: fix build-break caused by recent renaming
51177         * lib/fprintftime.c: Include "nstrftime.c", not the now-renamed
51178         "strftime.c".
51179         * modules/fprintftime: Depend directly on nstrftime.
51181 2017-07-26  Paul Eggert  <eggert@cs.ucla.edu>
51183         regex: work with GCC7's -Werror=implicit-fallthrough=
51184         * lib/regex_internal.h (FALLTHROUGH): New macro.
51185         * lib/regcomp.c (peek_token_bracket, parse_expression):
51186         * lib/regexec.c (check_node_accept): Use it.
51188 2017-07-24  Paul Eggert  <eggert@cs.ucla.edu>
51190         fts: simplify fts_build
51191         * lib/fts.c (fts_build): Simplify, and be lazier about
51192         calling leaf_optimization.
51194         fts: three levels of leaf optimization
51195         * lib/fts.c (enum leaf_optimization): New type with three values.
51196         (S_MAGIC_AFS): New macro.  Sort them.
51197         (leaf_optimization): Rename from leaf_optimization_applies, and
51198         return enum leaf_optimization instead of bool.  All uses changed.
51199         Add cases for unknown type and for AFS.
51200         (fts_build): Don’t rely on link counts if NO_LEAF_OPTIMIZATION.
51202         fts: cache dirent_inode_sort_may_be_useful too
51203         * lib/fts.c (struct dev_type): New struct.
51204         (DEV_TYPE_HT_INITIAL_SIZE): New constant.
51205         (dev_type_hash, dev_type_compare, filesystem_type): New functions.
51206         (dirent_inode_sort_may_be_useful, leaf_optimization_applies):
51207         Now takes FTSENT const *, not int.  All uses changed.  Use
51208         filesystem_type to cache.
51209         (link_count_optimize_ok): Remove.  Caller changed to use
51210         leaf_optimization_applies, which now uses shared cache.
51212         fts: introduce MIN_DIR_NLINK
51213         * lib/fts.c (MIN_DIR_NLINK): New constant.
51214         Use it instead of 2, whenever we are talking about link counts.
51216         fts: nlink_t signedness fixups
51217         * lib/fts.c (fts_open): Set rootparent n_dirs_remaining to -1
51218         so that root need not be a special case later.
51219         (fts_read): Remove now-redundant test for fts_level.
51220         Do not assume that nlink_t is signed.
51221         (fts_build): Remove useless decrement of nlinks.
51222         (fts_stat): Avoid unlikely signed integer overflow later, if
51223         nlink_t is signed.
51225         fts-tests: new module
51226         * modules/fts-tests, tests/test-fts.c: New files.
51228 2017-07-23  Bruno Haible  <bruno@clisp.org>
51230         Rename module 'strftime' to 'nstrftime'.
51231         * m4/nstrftime.m4: Renamed from m4/strftime.m4.
51232         * lib/nstrftime.c: Renamed from lib/strftime.c.
51233         * modules/nstrftime: Renamed from modules/strftime.
51234         (Files, Makefile.am): Update.
51235         * tests/test-nstrftime.c: Renamed from tests/test-strftime.c.
51236         Fix comment.
51237         * modules/nstrftime-tests: Renamed from modules/strftime-tests.
51238         (Files, Makefile.am): Update.
51239         * modules/strftime: New file, an obsolete indirection.
51240         * doc/posix-functions/strftime.texi: Update reference.
51241         * config/srclist.txt: Update info.
51242         * NEWS: Mention the change.
51244 2017-07-21  Tim Rühsen  <tim.ruehsen@gmx.de>
51246         malloca: Silence a warning from clang's memory sanitizer.
51247         * lib/malloca.c (NO_SANITIZE_MEMORY): New macro.
51248         (freea): Use it.
51250 2017-07-18  Bruno Haible  <bruno@clisp.org>
51252         host-cpu-c-abi: Fix detection of MIPS ABI.
51253         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): For MIPS, really test the
51254         ABI, not the CPU instruction set.
51256 2017-07-16  Paul Eggert  <eggert@cs.ucla.edu>
51258         explicit_bzero: new module
51259         The explicit_bzero function has been added to glibc.
51260         This module is intended to supports its use in GNU programs.
51261         * doc/glibc-functions/explicit_bzero.texi, lib/explicit_bzero.c:
51262         * m4/explicit_bzero.m4, modules/explicit_bzero:
51263         New files.
51264         * doc/gnulib.texi (Glibc string.h): Link to new doc.
51265         * lib/string.in.h (explicit_bzero): Declare.
51266         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Add defaults for it.
51267         * modules/string (string.h): Substitute its vars.
51269 2017-07-16  Bruno Haible  <bruno@clisp.org>
51271         threadlib: Support static linking.
51272         * m4/threadlib.m4 (gl_THREADLIB_BODY): When static linking is in use,
51273         set gl_cv_have_weak to 'no'.
51275 2017-07-16  Bruno Haible  <bruno@clisp.org>
51277         unicase/locale-language: Fix link dependencies.
51278         * modules/unicase/locale-language (Link): New section.
51279         * modules/unicase/locale-language-tests (Makefile.am): Link
51280         test-locale-language program with $(LIBTHREAD).
51282 2017-07-15  John E. Malmberg  <wb8tyw@gmail.com>
51284         sys_socket: Add support for OpenVMS.
51285         * lib/sys_socket.in.h [__VMS]: Define CMSG_SPACE, CMSG_LEN.
51286         * doc/posix-headers/sys_socket.texi: Mention OpenVMS issues.
51288 2017-07-15  John E. Malmberg  <wb8tyw@gmail.com>
51290         sys_resource: Add support for OpenVMS.
51291         * lib/resource.in.h [__VMS]: Define RUSAGE_SELF, RUSAGE_CHILDREN.
51292         * doc/posix-headers/sys_resource.texi: Mention OpenVMS issues.
51294 2017-07-15  John E. Malmberg  <wb8tyw@gmail.com>
51295             Bruno Haible  <bruno@clisp.org>
51297         math: Add support for OpenVMS.
51298         * lib/math.in.h [__VMS]: Include <fp.h>.
51299         * doc/posix-headers/math.texi: Mention OpenVMS issues.
51301 2017-07-15  Bruno Haible  <bruno@clisp.org>
51303         getdtablesize: Add minimal support for OpenVMS.
51304         Reported by John E. Malmberg <wb8tyw@qsl.net>.
51305         * modules/getdtablesize (Description): Fix.
51306         * lib/getdtablesize.c: Fix comment.
51307         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Don't replace the
51308         getdtablesize() function, even though the test fails.
51309         * doc/glibc-functions/getdtablesize.texi: Reference SUSv2. Describe
51310         limitation on OpenVMS.
51312 2017-07-13  Bruno Haible  <bruno@clisp.org>
51314         Revisit cross-compilation guesses.
51315         * m4/wctype_h.m4 (gl_WCTYPE_H): Add comment.
51317 2017-07-13  Bruno Haible  <bruno@clisp.org>
51319         Improve cross-compilation guesses for native Windows.
51320         * m4/btowc.m4 (gl_FUNC_BTOWC): Add cross-compilation guess for native
51321         Windows.
51322         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Likewise.
51323         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Likewise.
51324         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Likewise.
51325         * m4/cbrtf.m4 (gl_FUNC_CBRTF_WORKS): Likewise.
51326         * m4/cbrtl.m4 (gl_FUNC_CBRTL, gl_FUNC_CBRTL_WORKS): Likewise.
51327         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
51328         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
51329         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
51330         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
51331         * m4/dup.m4 (gl_FUNC_DUP): Likewise.
51332         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
51333         * m4/exp2.m4 (gl_FUNC_EXP2_WORKS): Likewise.
51334         * m4/exp2l.m4 (gl_FUNC_EXP2L): Likewise.
51335         * m4/expm1.m4 (gl_FUNC_EXPM1): Likewise.
51336         * m4/expm1f.m4 (gl_FUNC_EXPM1F_WORKS): Likewise.
51337         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Likewise.
51338         * m4/fabsl.m4 (gl_FUNC_FABSL_WORKS): Likewise.
51339         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
51340         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Likewise.
51341         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
51342         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
51343         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
51344         * m4/fma.m4 (gl_FUNC_FMA_WORKS): Likewise.
51345         * m4/fmaf.m4 (gl_FUNC_FMAF_WORKS): Likewise.
51346         * m4/fmal.m4 (gl_FUNC_FMAL_WORKS): Likewise.
51347         * m4/fmod.m4 (gl_FUNC_FMOD): Likewise.
51348         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
51349         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
51350         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Likewise.
51351         * m4/frexpf.m4 (gl_FUNC_FREXPF_WORKS): Likewise.
51352         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
51353         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Likewise.
51354         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
51355         * m4/hypotf.m4 (gl_FUNC_HYPOTF, gl_FUNC_HYPOTF_WORKS): Likewise.
51356         * m4/hypotl.m4 (gl_FUNC_HYPOTL, gl_FUNC_HYPOTL_WORKS): Likewise.
51357         * m4/ilogb.m4 (gl_FUNC_ILOGB_WORKS): Likewise.
51358         * m4/ilogbf.m4 (gl_FUNC_ILOGBF_WORKS): Likewise.
51359         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
51360         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
51361         * m4/isnanf.m4 (gl_ISNANF_WORKS): Likewise.
51362         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
51363         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Likewise.
51364         * m4/log.m4 (gl_FUNC_LOG, gl_FUNC_LOG_WORKS): Likewise.
51365         * m4/logf.m4 (gl_FUNC_LOGF, gl_FUNC_LOGF_WORKS): Likewise.
51366         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): Likewise.
51367         * m4/log10.m4 (gl_FUNC_LOG10, gl_FUNC_LOG10_WORKS): Likewise.
51368         * m4/log10f.m4 (gl_FUNC_LOG10F, gl_FUNC_LOG10F_WORKS): Likewise.
51369         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): Likewise.
51370         * m4/log1p.m4 (gl_FUNC_LOG1P): Likewise.
51371         * m4/log1pf.m4 (gl_FUNC_LOG1PF, gl_FUNC_LOG1PF_WORKS): Likewise.
51372         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Likewise.
51373         * m4/log2.m4 (gl_FUNC_LOG2, gl_FUNC_LOG2_WORKS): Likewise.
51374         * m4/log2f.m4 (gl_FUNC_LOG2F, gl_FUNC_LOG2F_WORKS): Likewise.
51375         * m4/log2l.m4 (gl_FUNC_LOG2L_WORKS): Likewise.
51376         * m4/logb.m4 (gl_FUNC_LOGB_WORKS): Likewise.
51377         * m4/logbf.m4 (gl_FUNC_LOGBF_WORKS): Likewise.
51378         * m4/logbl.m4 (gl_FUNC_LOGBL_WORKS): Likewise.
51379         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
51380         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT, gl_MBRTOWC_C_LOCALE): Likewise.
51381         * m4/mkdir.m4 (gl_FUNC_MKDIR): Likewise.
51382         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
51383         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): Likewise.
51384         * m4/modf.m4 (gl_FUNC_MODF): Likewise.
51385         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
51386         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
51387         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
51388         * m4/perror.m4 (gl_FUNC_PERROR): Likewise.
51389         * m4/popen.m4 (gl_FUNC_POPEN): Likewise.
51390         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE,
51391         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2,
51392         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): Likewise.
51393         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Likewise.
51394         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
51395         * m4/regex.m4 (gl_REGEX): Likewise.
51396         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
51397         * m4/remainderf.m4 (gl_FUNC_REMAINDERF,
51398         gl_FUNC_REMAINDERF_WORKS): Likewise.
51399         * m4/remainderl.m4 (gl_FUNC_REMAINDERL,
51400         gl_FUNC_REMAINDERL_WORKS): Likewise.
51401         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
51402         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
51403         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
51404         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
51405         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
51406         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
51407         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
51408         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
51409         * m4/sqrtl.m4 (gl_FUNC_SQRTL_WORKS): Likewise.
51410         * m4/stdint.m4 (gl_STDINT_H): Likewise.
51411         * m4/strerror.m4 (gl_FUNC_STRERROR_0): Likewise.
51412         * m4/strncat.m4 (gl_FUNC_STRNCAT): Likewise.
51413         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
51414         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
51415         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
51416         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
51417         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
51418         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
51419         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
51420         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
51421         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
51422         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
51423         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
51424         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
51425         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
51426         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
51427         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
51428         Likewise.
51429         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
51430         * m4/chown.m4 (AC_FUNC_CHOWN): Add cross-compilation guess for native
51431         Windows. Enable also on Autoconf 2.70.
51432         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE,
51433         gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE,
51434         gl_PRINTF_DIRECTIVE_A, gl_PRINTF_DIRECTIVE_F, gl_PRINTF_DIRECTIVE_N,
51435         gl_PRINTF_DIRECTIVE_LS, gl_PRINTF_FLAG_LEFTADJUST, gl_PRINTF_FLAG_ZERO,
51436         gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
51437         gl_SNPRINTF_DIRECTIVE_N, gl_SNPRINTF_SIZE1): Add cross-compilation guess
51438         for native Windows.
51439         (gl_PRINTF_POSITIONS, gl_PRINTF_FLAG_GROUPING,
51440         gl_VSNPRINTF_ZEROSIZE_C99): Add comment.
51442 2017-07-13  Bruno Haible  <bruno@clisp.org>
51444         Improve cross-compilation guesses for native Windows.
51445         * m4/memchr.m4 (gl_FUNC_MEMCHR): Add cross-compilation guess for native
51446         Windows.
51447         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Don't use internals of
51448         memchr.m4.
51449         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Likewise.
51451 2017-07-13  Bruno Haible  <bruno@clisp.org>
51453         Improve cross-compilation guesses for native Windows.
51454         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Add cross-compilation guess for
51455         native Windows.
51456         (gl_FUNC_FFLUSH): Update accordingly.
51457         * m4/fclose.m4 (gl_FUNC_FCLOSE): Likewise.
51458         * m4/fseeko.m4 (gl_FUNC_FFLUSH_STDIN): Likewise.
51460 2017-07-11  Bruno Haible  <bruno@clisp.org>
51462         More systematic m4 quoting and indentation.
51463         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Quote systematically.
51464         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
51465         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
51466         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
51467         * m4/host-os.m4 (gl_HOST_OS): Likewise.
51468         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H,
51469         gl_WINSIZE_IN_PTEM): Likewise.
51470         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Likewise.
51471         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Likewise.
51472         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
51473         * m4/fchownat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Quote systematically.
51474         Correct indentation.
51475         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
51476         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
51477         * m4/jm-winsz2.m4 (gl_HEADER_TIOCGWINSZ_NEEDS_SYS_IOCTL): Likewise.
51478         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
51479         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
51480         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
51482 2017-07-10  Bruno Haible  <bruno@clisp.org>
51484         round, roundf: Avoid compiler warning in configure test.
51485         * m4/round.m4 (gl_FUNC_ROUND): Use 'return' instead of exit().
51486         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
51488 2017-07-10  Bruno Haible  <bruno@clisp.org>
51490         getlogin tests: Avoid #ifdefs when sharing code between modules.
51491         * modules/getlogin_r-tests (Files): Add tests/test-getlogin.h.
51492         * modules/getlogin-tests (Files): Likewise. Remove
51493         tests/test-getlogin_r.c.
51494         * tests/test-getlogin.h: Extracted from tests/test-getlogin_r.c.
51495         * tests/test-getlogin.c: Extracted from tests/test-getlogin_r.c.
51496         * tests/test-getlogin_r.c: Include test-getlogin.h. Omit code that tests
51497         getlogin().
51499 2017-07-10  Paul Eggert  <eggert@cs.ucla.edu>
51501         getlogin: don’t assume one name per uid
51502         Problem reported by Wolfgang F. Muthmann (Bug#27640).
51503         * modules/getlogin-tests (Files): Add tests/test-getlogin_r.c.
51504         (ttyname): Remove test.
51505         * modules/getlogin_r-tests (ttyname): Remove test.
51506         * tests/test-getlogin.c: Replace this near-clone of test-getlogin_r.c
51507         with ‘#define TEST_LOGIN’ followed by ‘#include "test-getlogin_r.c"’.
51508         * tests/test-getlogin_r.c: If TEST_GETLOGIN is defined, test
51509         getlogin rather than getlogin_r.  This avoids code duplication.
51510         (main): Use isatty and fstat rather than ttyname and stat.
51511         Use getpwnam instead of getpwuid, to be portable to test platforms
51512         that have multiple login names for the same uid.
51514 2017-07-10  Tim Rühsen  <tim.ruehsen@gmx.de>
51515             Bruno Haible  <bruno@clisp.org>
51517         glob: Fix more memory leaks.
51518         * lib/glob.c (glob): Use 'goto out' in order to free dirname before
51519         returning.
51520         Reported by Tim Rühsen.
51522 2017-07-10  Bruno Haible  <bruno@clisp.org>
51524         Make sure $host and $host_os are defined when used.
51525         * m4/argz.m4 (gl_FUNC_ARGZ): Require AC_CANONICAL_HOST.
51526         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Likewise.
51527         * m4/csharpexec.m4 (gt_CSHARPEXEC): Likewise.
51528         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
51529         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
51530         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Likewise.
51531         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Likewise.
51532         * m4/opendir.m4 (gl_FUNC_OPENDIR): Likewise.
51533         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
51534         * m4/pselect.m4 (gl_FUNC_PSELECT): Likewise.
51535         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Likewise.
51536         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Likewise.
51537         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
51538         * m4/ceill.m4 (gl_FUNC_CEILL): Require AC_CANONICAL_HOST outside the
51539         m4_ifdef block.
51541 2017-07-09  Bruno Haible  <bruno@clisp.org>
51543         *printf: Fix cross-compilation guess for Solaris.
51544         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): Fix copy-and-paste mistake from
51545         2010-12-21.
51547 2017-07-07  Paul Eggert  <eggert@cs.ucla.edu>
51548             Bruno Haible  <bruno@clisp.org>
51550         vasnprintf: port to macOS 10.13
51551         Problem reported by comex in:
51552         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00056.html
51553         * lib/vasnprintf.c (VASNPRINTF): Don’t use %n on macOS.
51555 2017-07-06  Bruno Haible  <bruno@clisp.org>
51557         imaxdiv tests: Fix logic.
51558         * tests/test-imaxdiv.c (main): Use == instead of =.
51559         Reported by Coverity.
51561 2017-07-06  Bruno Haible  <bruno@clisp.org>
51563         uninorm/filter: Fix use-after-free bug.
51564         * lib/uninorm/uninorm-filter.c (uninorm_filter_write): Maintain
51565         sortbuf == filter->sortbuf invariant.
51566         Reported by Coverity.
51568 2017-07-06  Bruno Haible  <bruno@clisp.org>
51570         glob: Fix more memory leaks.
51571         * lib/glob.c (glob): Free dirname before returning.
51572         Reported by Coverity and Tim Rühsen.
51574 2017-07-06  Paul Eggert  <eggert@cs.ucla.edu>
51576         parse-datetime: fix uninit var bug
51577         Reported by Bruno Haible in:
51578         http://lists.gnu.org/r/bug-gnulib/2017-07/msg00038.html
51579         * lib/parse-datetime.y (parse_datetime2): Do not use
51580         uninitialized.
51582 2017-07-05  Bruno Haible  <bruno@clisp.org>
51584         doc: Update for MSVC 14.
51585         * doc/posix-headers/*.texi: Add info about MSVC 14.
51586         * doc/posix-functions/*.texi: Likewise.
51587         * doc/pastposix-functions/*.texi: Likewise.
51588         * doc/glibc-headers/*.texi: Likewise.
51589         * doc/glibc-functions/*.texi: Likewise.
51591 2017-07-05  Bruno Haible  <bruno@clisp.org>
51593         sched: Fix build failure on native Windows (regression from 2017-06-19).
51594         * m4/sched_h.m4 (gl_SCHED_H): Set HAVE_STRUCT_SCHED_PARAM always.
51596 2017-07-03  John E. Malmberg  <wb8tyw@gmail.com>
51598         stdioext: Port to OpenVMS.
51599         * lib/stdio-impl.h: OpenVMS uses struct _iobuf for FILE information.
51600         * lib/fpending.c (fpending): Remove non-working VMS specific code.
51601         * lib/fbufmode.c (fbufmode): Fix _IOLBF test to use fp_ macro.
51602         * lib/fflush.c (clear_ungetc_buffer): Add OpenVMS to comments.
51603         * lib/fpurge.c (fpurge): Likewise.
51604         * lib/freadable.c (freadable): Likewise.
51605         * lib/freadahead.c (freadahead): Likewise.
51606         * lib/freading.c (freading): Likewise.
51607         * lib/freadptr.c (freadptr): Likewise.
51608         * lib/freadseek.c (freadseek): Likewise.
51609         * lib/fseeko.c (fseeko): Likewise.
51610         * lib/fseterr.c (fseterr): Likewise.
51611         * lib/fwritable.c (fwriteable): Likewise.
51612         * lib/fwriting.c (fwriting): Likewise.
51614 2017-07-01  Benno Schulenberg  <bensberg@telfort.nl>
51616         glob: Declare variables at the very start of their scope.
51617         * lib/glob.c (convert_dirent, convert_dirent64): Give each fragment
51618         its separate scope, so the functions will compile on Haiku.
51620 2017-07-01  Bruno Haible  <bruno@clisp.org>
51622         logbl: Work around a glibc bug on PowerPC64LE.
51623         * m4/logbl.m4 (gl_FUNC_LOGBL_WORKS): Test also negative subnormal
51624         numbers.
51625         * doc/posix-functions/logbl.texi: Update.
51627 2017-06-29  Bruno Haible  <bruno@clisp.org>
51629         stat, fstat: Compile stat-w32.c only on platforms that need it.
51630         Suggested by Paul Eggert.
51631         * modules/stat (configure.ac): Request stat-w32.o only on native
51632         Windows.
51633         * modules/fstat (configure.ac): Likewise.
51635 2017-06-25  Bruno Haible  <bruno@clisp.org>
51637         stat: Improve last change.
51638         * lib/stat-w32.c: Revert last change. Use generic idiom instead.
51640 2017-06-25  Paul Eggert  <eggert@cs.ucla.edu>
51642         stat: port to xlc 12.01
51643         * lib/stat-w32.c: Always include <sys/types.h>.  Otherwise, xlc
51644         12.01 complains "Compilation unit is empty."
51646 2017-06-24  Paul Eggert  <eggert@cs.ucla.edu>
51648         xalloc-oversized: port to icc
51649         * lib/xalloc-oversized.h (xalloc_oversized): Do not use
51650         __builtin_mul_overflow if ICC is defined, as this results in
51651         "undefined reference to `__builtin_mul_overflow'" with icc 17.0.2
51652         20170213.
51654 2017-06-19  Bruno Haible  <bruno@clisp.org>
51656         classpath: Avoid including config.h twice, as it produces warnings.
51657         Reported by John E. Malmberg <wb8tyw@gmail.com>.
51658         * lib/classpath.h: Conditionalize the include of config.h.
51660 2017-06-19  Bruno Haible  <bruno@clisp.org>
51661             John E. Malmberg  <wb8tyw@gmail.com>  (tiny change)
51663         sched: Fix compilation failure on OpenVMS.
51664         * m4/sched_h.m4 (gl_SCHED_H): Require AC_CANONICAL_HOST. On OpenVMS,
51665         test whether <pthread.h> exists and defines struct sched_param.
51666         * lib/sched.in.h: On OpenVMS, include <pthread.h>.
51668 2017-06-17  Paul Eggert  <eggert@cs.ucla.edu>
51670         diffseq: port to GCC 7 with --enable-gcc-warnings
51671         * lib/diffseq.h (diag): Use an if, not an ifdef, for most of the
51672         heuristic check.  This way, GCC 7 with --enable-gcc-warnings does
51673         not complain about big_snake being defined but not used.
51675 2017-06-15  Bruno Haible  <bruno@clisp.org>
51677         gettext-h: Update theoretical condition for use of variable size arrays.
51678         Reported by Paul Eggert.
51679         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Extend comment
51680         to include the theoretical condition for availability of variable size
51681         arrays, if we could trust the value of __STDC_VERSION__.
51683 2017-06-12  Bruno Haible  <bruno@clisp.org>
51685         Relicense some modules under LGPLv2+.
51686         Daiki Ueno's approval is in
51687         https://lists.gnu.org/r/bug-gnulib/2017-06/msg00058.html.
51688         * modules/uniwidth/base (License): Change to LGPLv2+.
51689         * modules/uniwidth/width (License): Likewise.
51691 2017-06-11  Bruno Haible  <bruno@clisp.org>
51693         localename: Fix test failure on DragonFly BSD.
51694         * lib/localename.c (gl_locale_name_thread_unsafe): Treat DragonFly BSD
51695         like FreeBSD.
51697 2017-06-11  Bruno Haible  <bruno@clisp.org>
51699         float: Fix 'float' and 'isinf' failures on DragonFly BSD.
51700         * m4/float_h.m4 (gl_FLOAT_H): Treat DragonFly BSD like FreeBSD.
51701         * lib/float.in.h: Likewise.
51702         * m4/fmal.m4, m4/frexpl.m4, m4/logbl.m4: Update accordingly.
51704 2017-06-11  Bruno Haible  <bruno@clisp.org>
51706         gnulib-tool: Clean up after autotools.
51707         * gnulib-tool (func_create_testdir, func_create_megatestdir): Remove
51708         useless directory left over by the Autotools.
51710 2017-06-11  Paul Eggert  <eggert@cs.ucla.edu>
51712         getopt-posix: port to glibc 2.25.90
51713         Problem reported by Daniel P. Berrange in:
51714         http://lists.gnu.org/r/bug-gnulib/2017-06/msg00003.html
51715         * lib/getopt-pfx-core.h (_GETOPT_CORE_H):
51716         * lib/getopt-pfx-ext.h (_GETOPT_EXT_H):
51717         #undef if __GETOPT_PREFIX is defined.
51719 2017-06-11  Bruno Haible  <bruno@clisp.org>
51721         strtod-obsolete: Fix license.
51722         * modules/strtod-obsolete (License): Change to LGPL.
51724 2017-06-10  Jim Meyering  <meyering@fb.com>
51726         maint: update to work with GCC7's -Werror=implicit-fallthrough=
51727         * lib/savewd.c (FALLTHROUGH): Define.
51728         (savewd_save, savewd_restore): Use this, rather than a comment,
51729         whenever one switch case falls through into the next.
51731 2017-06-08  Bruno Haible  <bruno@clisp.org>
51733         host-cpu-c-abi: Support for aarch64 ILP32 ABI.
51734         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Recognize the aarch64 ILP32
51735         ABI. Set HOST_CPU_C_ABI=arm64-ilp32 and define __arm64_ilp32__ in this
51736         case.
51738 2017-06-08  Paul Eggert  <eggert@cs.ucla.edu>
51740         doc: remove robots, add prereqs
51741         * doc/build-automation.texi, doc/gnulib.texi: Mention prereqs for
51742         builds.  Simon's robot site does not seem to be up, so remove
51743         mentions of it for now.
51745 2017-06-08  Bruno Haible  <bruno@clisp.org>
51747         gnulib-tool: Fix bug in func_symlink_if_changed, from 2006-11-13.
51748         * gnulib-tool (func_symlink_target): New function, extracted from
51749         func_symlink.
51750         (func_symlink, func_symlink_if_changed): Use it.
51752 2017-06-08  Bruno Haible  <bruno@clisp.org>
51754         gnulib-tool: Fix bug in func_ln_s, from 2016-01-15.
51755         * gnulib-tool (func_ln_s): Determine cp_src correctly.
51757 2017-06-07  Bruno Haible  <bruno@clisp.org>
51759         canonicalize-lgpl: Avoid conflict with gnulib 'getcwd' module on VMS.
51760         Reported by John E. Malmberg <wb8tyw@gmail.com> in
51761         <https://lists.gnu.org/r/bug-gnulib/2017-06/msg00029.html>.
51762         * lib/canonicalize-lgpl.c (__getcwd): On VMS, when using gnulib's getcwd
51763         override, pass 2 arguments to getcwd, not 3.
51765 2017-06-04  Paul Eggert  <eggert@cs.ucla.edu>
51767         same-inode: port better to VMS 8.2 and later
51768         Problem reported by John E. Malmberg in:
51769         http://lists.gnu.org/r/bug-gnulib/2017-06/msg00005.html
51770         * lib/same-inode.h (SAME_INODE) [__VMS && 80200000 <= __CRTL_VER]:
51771         Use the usual POSIX definition.
51772         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Define _USE_STD_STAT.
51774 2017-06-01  Paul Eggert  <eggert@cs.ucla.edu>
51776         error: fix POSIX violation for va_end
51777         Problem reported by Bruno Haible in:
51778         http://lists.gnu.org/r/bug-gnulib/2017-06/msg00001.html
51779         * lib/error.c (error_tail): Do not call va_end here.
51780         (error, error_at_line): Call it here instead.
51782 2017-05-28  Bruno Haible  <bruno@clisp.org>
51784         c-strtod: Make it usable in C++ mode.
51785         * lib/c-strtod.h: Add 'extern "C"' marker for C++.
51787 2017-05-25  Jim Meyering  <meyering@fb.com>
51789         quotearg: fix compilation failure due to FALLTHROUGH misuse
51790         * lib/quotearg.c (quotearg_buffer_restyled): Revert one FALLTHROUGH
51791         macro back to /* fall through */ comment.  The macro can apply only
51792         to a following case statement.  Reported by Assaf Gordon.
51794 2017-05-25  Paul Eggert  <eggert@cs.ucla.edu>
51796         intprops: port to recent icc
51797         Port to icc (ICC) 17.0.4 20170411, which defines __GNUC__ to be 5
51798         but does not support __builtin_add_overflow etc.
51799         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW) [__ICC]:
51800         Define to 0.
51802 2017-05-23  Karl Berry  <karl@freefriends.org>
51804         * config/srclist.txt (iconv.m4): sync broken, comment out
51805         until (hopefully) the next gettext release.
51807 2017-05-22  Bjarni Ingi Gislason  <bjarniig@rhi.hi.is>
51809         Remove repeated words in comments.
51811 2017-05-22  Bernhard Voelker  <mail@bernhard-voelker.de>
51813         fallthrough: reinstate a FALLTHROUGH instance in quotearg
51814         quotearg.c: Reinstate this instance which is significant
51815         when the if branch is not taken.
51817 2017-05-21  Bruno Haible  <bruno@clisp.org>
51819         gnulib-tool: Add options to create hard links.
51820         * gnulib-tool (func_usage): Document options --hardlink,
51821         --local-hardlink, --more-hardlinks.
51822         (func_symlink): Renamed from func_ln.
51823         (func_symlink_if_changed): Renamed from func_ln_if_changed.
51824         (func_hardlink): New function.
51825         (copymode, lcopymode): New variables.
51826         (symbolic, lsymbolic): Remove variables.
51827         (Options): Implement options --hardlink, --local-hardlink,
51828         --more-hardlinks.
51829         (func_should_link): Renamed from func_should_symlink. Set copyaction.
51830         (func_add_file, func_update_file): Update invocation of
51831         func_should_link. Invoke func_hardlink when appropriate.
51832         (func_import): Update comments.
51833         (func_create_testdir): Update invocation of func_should_link. Invoke
51834         func_hardlink when appropriate.
51835         Finally, invoke 'git update-index --refresh' to mitigate the effects of
51836         the hard links on git.
51838 2017-05-20  Bruno Haible  <bruno@clisp.org>
51840         argp: Simplify bit manipulation.
51841         * lib/argp-parse.c (parser_parse_opt): Use &, |, ~ instead of shifts
51842         on a signed integer type.
51844 2017-05-20  Bruno Haible  <bruno@clisp.org>
51846         Avoid wrong configure results with gcc -fsanitize=address.
51847         This completes the work done on 2016-02-06 on this topic.
51848         * m4/memmem.m4 (gl_FUNC_MEMMEM): Free allocated memory before returning.
51849         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
51850         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
51851         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
51852         * m4/fopen.m4 (gl_FUNC_FOPEN): Close allocated FILE streams before
51853         returning.
51854         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Likewise.
51855         * m4/fpurge.m4 (gl_FUNC_FPURGE): Likewise.
51856         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
51857         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
51858         * m4/signbit.m4 (gl_FLOATTYPE_SIGN_LOCATION): Likewise.
51859         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Likewise.
51860         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Close allocated FILE streams and
51861         free allocated memory before returning.
51862         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
51863         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Close allocated DIR
51864         objects before returning.
51865         * m4/iconv.m4 (AM_ICONV_LINK): Close allocated iconv_t handles before
51866         returning.
51868 2017-05-20  Bruno Haible  <bruno@clisp.org>
51870         gnulib-tool: Don't create hard links between gnulib and its testdirs.
51871         * gnulib-tool (func_create_testdir): Don't invoke 'ln'.
51873 2017-05-20  Bruno Haible  <bruno@clisp.org>
51875         argp, tsearch tests: Fix file list.
51876         * modules/argp-tests (Files): Add tests/macros.h.
51877         * modules/tsearch-tests (Files): Likewise.
51879 2017-05-20  Bruno Haible  <bruno@clisp.org>
51881         getopt-posix tests: Remove redundant include.
51882         * tests/test-getopt.h: Don't include "macros.h". It's already included
51883         by tests/test-getopt-main.h.
51885 2017-05-19  Jim Meyering  <meyering@fb.com>
51887         dfa: two small simplifications
51888         * lib/dfa.c (build_state): Avoid repeating longer expressions.
51890 2017-05-18  Jim Meyering  <meyering@fb.com>
51892         fallthrough: update for GCC 7/8
51893         * lib/quotearg.c (FALLTHROUGH): New macro.
51894         Use it whenever one switch case falls through into the next,
51895         replacing "/* Fall through */" comments.  This exposed one
51896         instance of an unwarranted "fall through" comment: unwarranted
51897         because it preceded a "goto" label not a case statement.
51898         * lib/freopen-safer.c (freopen_safer): Likewise.
51899         * lib/fts.c (leaf_optimization_applies): Likewise.
51900         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Likewise.
51901         * tests/test-getopt_long.h (getopt_long_loop): Likewise.
51902         * tests/test-tsearch.c (mangle_tree): Likewise.  Also include
51903         tests/macros.h for the definition.
51904         * tests/test-argp.c (group1_parser): Likewise.
51905         * tests/test-getopt.h (getopt_loop): Likewise.
51907 2017-05-19  Paul Eggert  <eggert@cs.ucla.edu>
51909         argp: fix shift bug
51910         * lib/argp-parse.c (parser_parse_opt): Rework to avoid undefined
51911         behavior on shift overflow, caught by gcc -fsanitize=undefined.
51913         argp: fix pointer-subtraction bug
51914         * lib/argp-help.c (hol_append): Don’t subtract pointers to
51915         different arrays, as this can run afoul of -fcheck-pointer-bounds.
51916         See the thread containing Bruno Haible’s report in:
51917         http://lists.gnu.org/r/bug-gnulib/2017-05/msg00171.html
51919 2017-05-19  Bruno Haible  <bruno@clisp.org>
51921         printf-posix tests: Avoid test failure with "gcc --coverage".
51922         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
51923         * tests/test-printf-posix2.c (main): Test a width of 10000000 rather
51924         than 5000000.
51925         * tests/test-fprintf-posix2.c (main): Likewise.
51927 2017-05-19  Paul Eggert  <eggert@cs.ucla.edu>
51929         closeout: don’t close stderr when sanitizing
51930         * NEWS: Document this.
51931         * lib/closeout.c (__has_feature): New macro, if not already defined.
51932         (SANITIZE_ADDRESS): New constant.
51933         (close_stdout): Don’t close stderr if sanitizing addresses.
51935 2017-05-19  Bruno Haible  <bruno@clisp.org>
51937         get-rusage-data tests: Avoid failure on Linux/glibc.
51938         * tests/test-get-rusage-data.c (main): Don't expect a strict increase
51939         on glibc systems.
51941 2017-05-18  Bruno Haible  <bruno@clisp.org>
51943         localename: Include necessary header files on Cygwin.
51944         * lib/localename.c [__CYGWIN__]: Include <langinfo.h>, since this is
51945         where NL_LOCALE_NAME is defined.
51947 2017-05-18  Bruno Haible  <bruno@clisp.org>
51949         gettext: Update macros from gettext git.
51950         * m4/intldir.m4: Require Autoconf >= 2.60.
51951         * m4/progtest.m4: Fix typos in copyright notice.
51953 2017-05-18  Bruno Haible  <bruno@clisp.org>
51955         copy-file tests: Fix link error (regression from 2017-05-01).
51956         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
51957         * modules/copy-file-tests (Makefile.am): Link test-copy-file with
51958         $(LIB_CLOCK_GETTIME).
51960 2017-05-18  Bruno Haible  <bruno@clisp.org>
51962         unicase/special-casing: Fix incompatibility with gperf-3.0.4
51963         (regression from 2017-02-13).
51964         * lib/unicase/special-casing.in.h: Renamed from
51965         lib/unicase/special-casing.h.
51966         * modules/unicase/special-casing (Files): Add
51967         lib/unicase/special-casing.in.h. Remove lib/unicase/special-casing.h.
51968         (Makefile.am): Add rule for generating unicase/special-casing.h.
51969         Update BUILT_SOURCES and MOSTLYCLEANFILES accordingly.
51970         * lib/unicase/special-casing.c: Include "unicase/special-casing.h",
51971         not "special-casing.h".
51972         * lib/unicase/u*.c: Likewise.
51974 2017-05-17  Bruno Haible  <bruno@clisp.org>
51976         README: Don't ask people to read a TeXinfo file.
51977         Reported by Tim Rühsen <tim.ruehsen@gmx.de>.
51978         * README: Tell people how to read the HTML formatted manual.
51980 2017-05-16  Tim Rühsen  <tim.ruehsen@gmx.de>
51982         parse-datetime: Fix memleak
51983         * lib/parse-datetime.y (parse_datetime2): Cleanup on
51984         localtime_rz() failure.
51986 2017-05-16  Bruno Haible  <bruno@clisp.org>
51988         javacomp: Fix handle leak.
51989         Found by Coverity.
51990         * lib/javacomp.c (get_classfile_version): Close fd before returning.
51992 2017-05-16  Bruno Haible  <bruno@clisp.org>
51994         relocate: Make it easier to reclaim allocated memory.
51995         * lib/relocatable.h (relocate2): New declaration/macro.
51996         * lib/relocatable.c (relocate2): New function.
51997         * doc/relocatable-maint.texi (Supporting Relocation): Mention the
51998         relocate2 function.
51999         * lib/localcharset.c (relocate2): Define fallback.
52000         (get_charset_aliases): Invoke relocate2 instead of relocate. Free the
52001         allocated memory.
52002         * lib/javaversion.c (relocate2): Define fallback.
52003         (javaexec_version): Invoke relocate2 instead of relocate. Free the
52004         allocated memory.
52006 2017-05-16  Bruno Haible  <bruno@clisp.org>
52008         relocate: Simplify EMX specific code.
52009         * lib/relocatable.c (relocate): Assume pathname is non-NULL. Use
52010         ISSLASH macro consistently. Avoid dangerous string concatenation idiom.
52012 2017-05-16  Bruno Haible  <bruno@clisp.org>
52014         sigpipe tests: Fix file list.
52015         * modules/sigpipe-tests (Files): Add tests/macros.h.
52017 2017-05-16  Paul Eggert  <eggert@cs.ucla.edu>
52019         manywarnings: update for GCC 7
52020         * build-aux/gcc-warning.spec:
52021         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
52022         Add GCC 7 warnings, notably -Wimplicit-fallthrough=5, which
52023         requires a non-comment fallthrough attribute.  This is a bit
52024         cleaner than the comment versions.
52025         * lib/strftime.c, lib/dfa.c, lib/fnmatch.c, lib/mbrtowc.c:
52026         * lib/vasnprintf.c, tests/macros.h (FALLTHROUGH): New macro.
52027         Use it whenever one switch case falls through into the next.
52028         * lib/fnmatch_loop.c, tests/test-mbrtowc.c, tests/test-sigpipe.c:
52029         Use FALLTHROUGH macro.
52031 2017-05-15  Bruno Haible  <bruno@clisp.org>
52033         gnulib-tool: Fix generated code when libtests contains module 'alloca'.
52034         * gnulib-tool (func_emit_tests_Makefile_am): For libtests.a, use
52035         @ALLOCA@, not @LTALLOCA@.
52037 2017-05-15  Bruno Haible  <bruno@clisp.org>
52039         sys_select: Avoid "was expanded before it was required" warning.
52040         * modules/sys_select (configure.ac): Require, not invoke,
52041         gl_HEADER_SYS_SELECT.
52043 2017-05-14  Paul Eggert  <eggert@cs.ucla.edu>
52045         gnulib-tool: improve GNU Make debugging
52046         * gnulib-tool (func_emit_lib_Makefile_am): Omit unnecessary echo.
52047         Report autoconf diagnostics when it fails, in the output makefile.
52049 2017-05-14  Bruno Haible  <bruno@clisp.org>
52051         stat-time tests: Improve comment.
52052         * tests/test-stat-time.c: Add hyperlink, from Paul Eggert.
52054 2017-05-14  Bruno Haible  <bruno@clisp.org>
52056         same-inode: Adapt for windows-stat-inodes.
52057         * lib/same-inode.h: Include <sys/types.h>.
52058         (SAME_INODE) [_GL_WINDOWS_STAT_INODES]: Define specifically.
52059         * modules/same-inode (Depends-on): Add sys_types.
52061 2017-05-14  Bruno Haible  <bruno@clisp.org>
52063         windows-stat-inodes: New module.
52064         * m4/windows-stat-inodes.m4: New file.
52065         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Set WINDOWS_STAT_INODES.
52066         * modules/sys_types (Makefile.am): Substitute WINDOWS_STAT_INODES.
52067         * lib/sys_types.in.h [WINDOWS_STAT_INODES]: Override dev_t and ino_t.
52068         (_GL_WINDOWS_STAT_INODES): New macro.
52069         * lib/stat-w32.c: Set _WIN32_WINNT. Include <string.h>, verify.h.
52070         (GetFileInformationByHandleExFunc): New variable.
52071         (initialize): Initialize it.
52072         (_gl_fstat_by_handle) [_GL_WINDOWS_STAT_INODES]: Initialize st_dev and
52073         st_ino appropriately.
52074         * lib/stat.c (rpl_stat): Use the directory entry based approach only as
52075         a fallback, because it does not provide st_dev and st_ino values.
52076         * modules/fstat (Depends-on): Add 'verify'.
52077         * modules/windows-stat-inodes: New file.
52078         * doc/windows-stat-inodes.texi: New file.
52079         * doc/gnulib.texi: Include it.
52080         * doc/posix-headers/sys_stat.texi: Mention the new module.
52082 2017-05-14  Bruno Haible  <bruno@clisp.org>
52084         stat-time tests: Workaround for native Windows.
52085         * tests/test-stat-time.c: Include <stdio.h>, <time.h>.
52086         (filename_stamp1, filename_testfile, filename_stamp2, filename_stamp3):
52087         New variables.
52088         (initialize_filenames): New function.
52089         (main): Invoke it.
52090         (cleanup, prepare_test): Update.
52092 2017-05-14  Bruno Haible  <bruno@clisp.org>
52094         stat-time: Adapt for windows-stat-timespec.
52095         * lib/stat-time.h (get_stat_birthtime) [_GL_WINDOWS_STAT_TIMESPEC]: Use
52096         entire st_ctim field.
52098 2017-05-13  Jim Meyering  <meyering@fb.com>
52100         maint.mk: update regex to reflect 2013 addition of "assume" to verify.h
52101         * top/maint.mk (sc_prohibit_verify_without_use): Don't reject a source
52102         file that uses the assume macro, claiming that verify.h is unused.
52104 2017-05-13  Bruno Haible  <bruno@clisp.org>
52106         Use symbolic values for _WIN32_WINNT.
52107         * lib/ftruncate.c (_WIN32_WINNT): Use symbolic value _WIN32_WINNT_WIN2K.
52108         * lib/sethostname.c (_WIN32_WINNT): Likewise.
52110 2017-05-13  Bruno Haible  <bruno@clisp.org>
52112         year2038: New module.
52113         * m4/year2038.m4: New file.
52114         * modules/year2038: New file.
52115         * doc/year2038.texi: New file.
52116         * doc/gnulib.texi: Include it.
52118 2017-05-13  Bruno Haible  <bruno@clisp.org>
52120         largefile: Simplify.
52121         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Remove unused definition
52122         of _GL_WINDOWS_64_BIT_ST_SIZE.
52124 2017-05-13  Bruno Haible  <bruno@clisp.org>
52126         largefile: Improve and document.
52127         * m4/largefile.m4 (gl_LARGEFILE): Set WINDOWS_64_BIT_ST_SIZE to 0 if
52128         the mingw headers already define 'stat' appropriately.
52129         * modules/largefile (Description): Clarify.
52130         * doc/largefile.texi: New file.
52131         * doc/gnulib.texi: Include it.
52132         * doc/posix-headers/sys_types.texi: Update.
52134 2017-05-13  Bruno Haible  <bruno@clisp.org>
52136         truncate: New module.
52137         * lib/unistd.in.h (truncate): New declaration.
52138         * lib/truncate.c: New file.
52139         * m4/truncate.m4: New file.
52140         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether 'truncate' is declared.
52141         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_TRUNCATE, HAVE_TRUNCATE,
52142         REPLACE_TRUNCATE.
52143         * modules/unistd (Makefile.am): Substitute GNULIB_TRUNCATE,
52144         HAVE_TRUNCATE, REPLACE_TRUNCATE.
52145         * modules/truncate: New file.
52146         * tests/test-unistd-c++.cc (truncate): Test signature.
52147         * doc/posix-functions/truncate.texi: Mention the new module.
52149         * tests/test-truncate.c: New file.
52150         * modules/truncate-tests: New file.
52152 2017-05-13  Bruno Haible  <bruno@clisp.org>
52154         windows-stat-timespec: New module.
52155         * modules/windows-stat-timespec: New file.
52156         * m4/windows-stat-timespec.m4: New file.
52157         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Set WINDOWS_STAT_TIMESPEC.
52158         * modules/sys_stat (Makefile.am): Substitute WINDOWS_STAT_TIMESPEC.
52159         * lib/sys_stat.in.h (struct stat) [WINDOWS_STAT_TIMESPEC]: Declare with
52160         fields st_atim, st_mtim, st_ctim.
52161         (st_atime, st_mtime, st_ctime): Define as macros.
52162         (_GL_WINDOWS_STAT_TIMESPEC): New macro.
52163         * lib/stat-w32.h (_gl_convert_FILETIME_to_timespec)
52164         [_GL_WINDOWS_STAT_TIMESPEC]: New declaration.
52165         * lib/stat-w32.c (_gl_convert_FILETIME_to_timespec)
52166         [_GL_WINDOWS_STAT_TIMESPEC]: New function.
52167         (_gl_convert_FILETIME_to_POSIX): Adjust coding style.
52168         (_gl_fstat_by_handle): If _GL_WINDOWS_STAT_TIMESPEC, convert the
52169         FILETIME to 'struct timespec', not 'time_t'.
52170         * lib/stat.c (rpl_stat): If _GL_WINDOWS_STAT_TIMESPEC, convert the
52171         FILETIME to 'struct timespec', not 'time_t'.
52172         * lib/stat-time.h (STAT_TIMESPEC): Define also if
52173         _GL_WINDOWS_STAT_TIMESPEC.
52174         * doc/windows-stat-timespec.texi: New file.
52175         * doc/gnulib.texi: Include it.
52177 2017-05-13  Bruno Haible  <bruno@clisp.org>
52179         windows-stat-override: New module.
52180         * lib/sys_stat.in.h (stat) [GNULIB_OVERRIDES_STRUCT_STAT]: Provide own
52181         definition. Define GNULIB_defined_struct_stat.
52182         (fstat, fstatat, lstat, stat) [GNULIB_OVERRIDES_STRUCT_STAT]: Provoke
52183         link error if this symbol is used and the corresponding module is not
52184         in use.
52185         (_stat64, _stat32i64, _stati64, _stat32, _stat64i32): Don't redefine if
52186         GNULIB_OVERRIDES_STRUCT_STAT.
52187         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
52188         GNULIB_OVERRIDES_STRUCT_STAT.
52189         * modules/sys_stat (Makefile.am): Substitute
52190         GNULIB_OVERRIDES_STRUCT_STAT.
52191         * modules/windows-stat-override: New file.
52193 2017-05-13  Bruno Haible  <bruno@clisp.org>
52195         fstat: Fix module dependency conditions.
52196         * modules/fstat (Depends-on): Fix typo.
52198 2017-05-13  Bruno Haible  <bruno@clisp.org>
52200         stat, fstat: Complete removal of old native Windows code.
52201         * lib/stat.c: Remove old macrology for WINDOWS_NATIVE.
52202         * lib/fstat.c: Likewise.
52203         * lib/stat-w32.c: Likewise.
52205 2017-05-13  Bruno Haible  <bruno@clisp.org>
52207         stat: Complete removal of REPLACE_FUNC_STAT_DIR code.
52208         * lib/stat.c: Remove all REPLACE_FUNC_STAT_DIR code.
52210 2017-05-11  Paul Eggert  <eggert@cs.ucla.edu>
52212         getopt-posix: port to mingw
52213         * lib/getopt.c (flockfile, funlockfile): Define on mingw.
52214         Problem reported by Daniel P. Berrage in:
52215         http://lists.gnu.org/r/bug-gnulib/2017-05/msg00086.html
52217 2017-05-11  Bruno Haible  <bruno@clisp.org>
52219         gettimeofday: Increase precision on mingw.
52220         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Require AC_CANONICAL_HOST.
52221         Set REPLACE_GETTIMEOFDAY to 1 on mingw.
52222         * lib/gettimeofday.c (gettimeofday): On native Windows, use the
52223         GetSystemTimePreciseAsFileTime based implementation always.
52224         * doc/posix-functions/gettimeofday.texi: Mention precision problem on
52225         mingw.
52227 2017-05-11  Bruno Haible  <bruno@clisp.org>
52229         poll: Fix confusion between SOCKETs and FDs on native Windows.
52230         Fix proposed by Daniel P. Berrange <berrange@redhat.com>.
52231         * lib/poll.c [WINDOWS_NATIVE]: Undefine select.
52233 2017-05-11  Bruno Haible  <bruno@clisp.org>
52235         doc: Clarify doc about socket functions on native Windows.
52236         This reworks doc that was added on 2008-09-29.
52237         * doc/posix-functions/select.texi: Fix copy-and-paste mistake and use
52238         clearer wording.
52239         * doc/posix-functions/accept.texi: Use clearer wording.
52240         * doc/posix-functions/bind.texi: Likewise.
52241         * doc/posix-functions/connect.texi: Likewise.
52242         * doc/posix-functions/getpeername.texi: Likewise.
52243         * doc/posix-functions/getsockname.texi: Likewise.
52244         * doc/posix-functions/getsockopt.texi: Likewise.
52245         * doc/posix-functions/ioctl.texi: Likewise.
52246         * doc/posix-functions/listen.texi: Likewise.
52247         * doc/posix-functions/recv.texi: Likewise.
52248         * doc/posix-functions/recvfrom.texi: Likewise.
52249         * doc/posix-functions/send.texi: Likewise.
52250         * doc/posix-functions/sendto.texi: Likewise.
52251         * doc/posix-functions/setsockopt.texi: Likewise.
52252         * doc/posix-functions/shutdown.texi: Likewise.
52253         * doc/posix-functions/socket.texi: Likewise.
52255 2017-05-10  Bruno Haible  <bruno@clisp.org>
52257         poll: Fix link error on native Windows.
52258         * lib/poll.c [WINDOWS_NATIVE]: Undefine recv.
52260 2017-05-10  Bruno Haible  <bruno@clisp.org>
52262         time: Fix missing initialization of HAVE_TIMEZONE_T.
52263         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_TIMEZONE_T
52264         here...
52265         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): ... not here.
52266         * m4/time_rz.m4 (gl_TIME_RZ): Require gl_HEADER_TIME_H_DEFAULTS, not
52267         gl_HEADER_SYS_TIME_H_DEFAULTS.
52268         * modules/time_rz (Depends-on): Add 'time'. Remove useless quoting.
52269         (configure.ac): Remove useless quoting.
52271 2017-05-10  Bruno Haible  <bruno@clisp.org>
52273         Implement a way to opt out from MSVC support, part 2.
52274         * modules/msvc-inval (Include): Document recommended idiom.
52275         * modules/msvc-nothrow (Include): Likewise.
52277         Implement a way to opt out from MSVC support.
52278         This is useful for Emacs.
52279         * modules/msvc-nothrow (configure.ac): Invoke gl_MODULE_INDICATOR.
52280         * lib/accept4.c: Include <io.h> as an alternative to msvc-nothrow.h.
52281         * lib/error.c: Likewise.
52282         * lib/fcntl.c: Likewise.
52283         * lib/flock.c: Likewise.
52284         * lib/fstat.c: Likewise.
52285         * lib/fsync.c: Likewise.
52286         * lib/ioctl.c: Likewise.
52287         * lib/isapipe.c: Likewise.
52288         * lib/lseek.c: Likewise.
52289         * lib/nonblocking.c: Likewise.
52290         * lib/poll.c: Likewise.
52291         * lib/select.c: Likewise.
52292         * lib/sockets.h: Likewise.
52293         * lib/sockets.c: Likewise.
52294         * lib/stdio-read.c: Likewise.
52295         * lib/stdio-write.c: Likewise.
52296         * lib/utimens.c: Likewise.
52297         * lib/w32sock.h: Likewise.
52298         * lib/w32spawn.h: Likewise.
52299         * tests/test-cloexec.c: Likewise.
52300         * tests/test-dup-safer.c: Likewise.
52301         * tests/test-dup2.c: Likewise.
52302         * tests/test-dup3.c: Likewise.
52303         * tests/test-fcntl.c: Likewise.
52304         * tests/test-pipe.c: Likewise.
52305         * tests/test-pipe2.c: Likewise.
52306         * lib/ftruncate.c: Likewise.
52307         (chsize_nothrow): Renamed from chsize.
52308         * lib/msvc-nothrow.c: Don't include msvc-inval.h if
52309         HAVE_MSVC_INVALID_PARAMETER_HANDLER is not defined.
52310         * lib/close.c: Likewise.
52311         * lib/dup.c: Likewise.
52312         * lib/fclose.c: Likewise.
52313         * lib/raise.c: Likewise.
52314         * tests/test-fgetc.c: Likewise.
52315         * tests/test-fputc.c: Likewise.
52316         * tests/test-fread.c: Likewise.
52317         * tests/test-fwrite.c: Likewise.
52318         * lib/getdtablesize.c: Likewise.
52319         (_setmaxstdio_nothrow): Renamed from _setmaxstdio.
52320         * lib/isatty.c: Don't include msvc-inval.h if
52321         HAVE_MSVC_INVALID_PARAMETER_HANDLER is not defined.
52322         Include <io.h> as an alternative to msvc-nothrow.h.
52323         * lib/read.c: Likewise.
52324         * lib/write.c: Likewise.
52325         * lib/dup2.c: Likewise.
52326         (dup2_nothrow): New function.
52327         (ms_windows_dup2): Use it.
52328         * m4/close.m4 (gl_FUNC_CLOSE): Invoke gl_MSVC_INVAL and test
52329         HAVE_MSVC_INVALID_PARAMETER_HANDLER only if gl_MSVC_INVAL is defined.
52330         * m4/dup.m4 (gl_FUNC_DUP): Likewise.
52331         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Likewise.
52332         * m4/raise.m4 (gl_FUNC_RAISE): Likewise.
52333         * m4/read.m4 (gl_FUNC_READ): Likewise.
52334         * m4/write.m4 (gl_FUNC_WRITE): Likewise.
52335         * doc/windows-without-msvc.texi: New file.
52336         * doc/gnulib.texi (Native Windows Support without MSVC Support): New
52337         section.
52339 2017-05-10  Bruno Haible  <bruno@clisp.org>
52341         wait-process: Adjust native Windows support.
52342         * lib/wait-process.c: Use the usual condition for recognizing a native
52343         Windows platform.
52345 2017-05-10  Bruno Haible  <bruno@clisp.org>
52347         doc: New chapter "Native Windows Support".
52348         * doc/gnulib.texi (Native Windows Support): New chapter.
52349         * doc/windows-libtool.texi: Small wording changes.
52350         * doc/windows-sockets.texi: Small wording and formatting changes.
52352 2017-05-10  Bruno Haible  <bruno@clisp.org>
52354         doc: Move section "Library version handling".
52355         * doc/gnulib.texi: Move section "Library version handling"
52356         from chapter "Miscellaneous Notes" to chapter "Particular Modules".
52358 2017-05-10  Bruno Haible  <bruno@clisp.org>
52360         doc: Move section "Running self-tests under valgrind".
52361         * doc/gnulib.texi: Move section "Running self-tests under valgrind"
52362         from chapter "Particular Modules" to chapter "Miscellaneous Notes".
52364 2017-05-10  Bruno Haible  <bruno@clisp.org>
52366         doc: New chapter "Build Infrastructure Modules".
52367         * doc/gnulib.texi (Build Infrastructure Modules): New chapter.
52369 2017-05-10  Bruno Haible  <bruno@clisp.org>
52371         Prepare for reordering sections in the manual.
52372         * doc/gnulib.texi: Move several sections to separate files. Include
52373         these files.
52374         * doc/out-of-memory.texi: New file, extracted from doc/gnulib.texi.
52375         * doc/obsolete.texi: Likewise.
52376         * doc/extra-tests.texi: Likewise.
52377         * doc/transversal.texi: Likewise.
52378         * doc/namespace.texi: Likewise.
52379         * doc/check-version.texi: Likewise.
52380         * doc/windows-sockets.texi: Likewise.
52381         * doc/windows-libtool.texi: Likewise.
52382         * doc/licenses-texi.texi: Likewise.
52383         * doc/build-automation.texi: Likewise.
52384         * doc/c-locale.texi: Likewise.
52386 2017-05-10  Bruno Haible  <bruno@clisp.org>
52388         Fix instructions how to update manual on www.gnu.org.
52389         * doc/README: Add -I option, so that texi2dvi finds texinfo.tex.
52391 2017-05-09  Bruno Haible  <bruno@clisp.org>
52393         tzset: Expand comment about TZ problem on native Windows.
52394         * lib/tzset.c (tzset): Elaborate comment, based on explanations by
52395         Paul Eggert.
52396         * lib/ctime.c (rpl_ctime): Likewise.
52397         * lib/localtime.c (rpl_localtime): Likewise.
52398         * lib/mktime.c (mktime): Likewise.
52399         * lib/strftime-fixes.c (rpl_strftime): Likewise.
52400         * lib/wcsftime.c (rpl_wcsftime): Likewise.
52402 2017-05-08  Paul Eggert  <eggert@cs.ucla.edu>
52404         intprops: don’t depend on ‘verify’
52405         Problem reported by Ævar Arnfjörð Bjarmason in:
52406         http://lists.gnu.org/r/bug-gnulib/2017-05/msg00054.html
52407         * lib/intprops.h: Do not include verify.h, and move compile-time
52408         checks from here ...
52409         * tests/test-intprops.c (main): ... to here, if they’re not here
52410         already.  Check widths of other standard integer types.
52411         * modules/intprops (Depends-on): Remove ‘verify’.
52413 2017-05-07  Bruno Haible  <bruno@clisp.org>
52415         utimens: On native Windows, support 100ns resolution also if fd < 0.
52416         * lib/utime.in.h: Include <time.h>.
52417         (_gl_utimens_windows): New declaration.
52418         * lib/utime.c (_gl_utimens_windows): New function, based on utime.
52419         (utime): Invoke it.
52420         * lib/utimens.c (fdutimens): On native Windows, call _gl_utimens_windows
52421         instead of utime.
52422         * modules/utime (Depends-on): Add 'time'.
52424 2017-05-07  Bruno Haible  <bruno@clisp.org>
52426         utimens: Improve error code on native Windows.
52427         * lib/utimens.c (fdutimens): If fd was not opened with O_RDWR, fail with
52428         error code EACCES, not EINVAL.
52430 2017-05-07  Bruno Haible  <bruno@clisp.org>
52432         utime: Handle more Windows error codes.
52433         * lib/utime.c (utime): Handle ERROR_BAD_NETPATH.
52434         Based on explanations by Billy O'Neal.
52436 2017-05-05  Bruno Haible  <bruno@clisp.org>
52438         crypto/rijndael: Fix "strict-aliasing rules" warnings, alignment issues.
52439         * lib/rijndael-api-fst.c (rijndaelBlockEncrypt): Declare 'block' as a
52440         union.
52441         (rijndaelPadEncrypt, rijndaelBlockDecrypt): Likewise.
52442         (rijndaelPadDecrypt): Likewise. Use local variable 'iv' to cache the
52443         value of cipher->IV.
52445 2017-05-05  Bruno Haible  <bruno@clisp.org>
52447         wctype-h-c++-tests: Update.
52448         * tests/test-wctype-h-c++.cc: Reorder to match lib/wchar.in.h.
52450 2017-05-05  Bruno Haible  <bruno@clisp.org>
52452         wchar-c++-tests: Update.
52453         * tests/test-wchar-c++.cc (wcsftime): Declare, missing since 2017-04-30.
52455 2017-05-05  Bruno Haible  <bruno@clisp.org>
52457         utime-h-c++-tests: New module.
52458         * tests/test-utime-h-c++.cc: New file.
52459         (utime): Declare, missing since 2017-04-30.
52460         * modules/utime-h-c++-tests: New file.
52462 2017-05-05  Bruno Haible  <bruno@clisp.org>
52464         unistd-c++-tests: Update.
52465         * tests/test-unistd-c++.cc (isatty): Declare, missing since 2012-01-03.
52466         (read): Declare, missing since 2011-04-15.
52467         (sethostname): Declare, missing since 2011-12-03.
52469 2017-05-05  Bruno Haible  <bruno@clisp.org>
52471         time-c++-tests: Update.
52472         * tests/test-time-c++.cc (tzset): Declare, missing since 2017-05-01.
52473         (localtime, gmtime): Declare, missing since 2017-04-30.
52474         (ctime): Declare, missing since 2017-04-30.
52475         (strftime): Declare, missing since 2017-04-30.
52476         (tzalloc, tzfree, localtime_rz, mktime_z): Declare, missing since
52477         2015-07-24.
52479 2017-05-05  Bruno Haible  <bruno@clisp.org>
52481         sys_resource-c++-tests: New module.
52482         * tests/test-sys_resource-c++.cc: New file.
52483         (getrusage): Declare, missing since 2012-04-13.
52484         * modules/sys_resource-c++-tests: New file.
52486 2017-05-05  Bruno Haible  <bruno@clisp.org>
52488         strings-c++-tests: New module.
52489         * tests/test-strings-c++.cc: New file.
52490         (ffs): Declare, missing since 2011-07-12.
52491         * modules/strings-c++-tests: New file.
52493 2017-05-05  Bruno Haible  <bruno@clisp.org>
52495         string-c++-tests: Update.
52496         * tests/test-string-c++.cc (ffsl): Declare, missing since 2011-07-15.
52497         (ffsll): Declare, missing since 2011-07-15.
52499 2017-05-05  Bruno Haible  <bruno@clisp.org>
52501         stdlib-c++-tests: Update.
52502         * tests/test-stdlib-c++.cc (posix_openpt): Declare, missing since
52503         2011-10-18.
52504         (ptsname_r): Declare, missing since 2011-11-07.
52505         (qsort_r): Declare, missing since 2014-08-29.
52506         (random, srandom, initstate, setstate): Declare, missing since
52507         2012-01-14.
52508         (secure_getenv): Declare, missing since 2013-02-05.
52510 2017-05-05  Bruno Haible  <bruno@clisp.org>
52512         stdio-c++-tests: Update.
52513         * tests/test-stdio-c++.cc (pclose): Declare, missing since 2011-09-18.
52515 2017-05-05  Bruno Haible  <bruno@clisp.org>
52517         signal-h-c++-tests: Update.
52518         * tests/test-signal-h-c++.cc (raise): Remove redundant declaration.
52520 2017-05-05  Bruno Haible  <bruno@clisp.org>
52522         math-c++-tests: Update.
52523         * tests/test-math-c++.cc (fmaf): Declare, missing since 2011-10-17.
52524         (fma): Declare, missing since 2011-10-17.
52525         (fmal): Declare, missing since 2011-10-17.
52527 2017-05-05  Bruno Haible  <bruno@clisp.org>
52529         locale-c++-tests: Update.
52530         * tests/test-locale-c++.cc (localeconv): Declare, missing since
52531         2012-03-25.
52533 2017-05-05  Bruno Haible  <bruno@clisp.org>
52535         inttypes-c++-tests: New module.
52536         * tests/test-inttypes-c++.cc: New file.
52537         (strtoimax): Declare, missing since 2012-01-05.
52538         (strtoumax): Declare, missing since 2012-01-05.
52539         * modules/inttypes-c++-tests: New file.
52541 2017-05-05  Bruno Haible  <bruno@clisp.org>
52543         dirent-c++-tests: Update.
52544         * tests/test-dirent-c++.cc (readdir): Declare, missing since 2011-09-13.
52545         (rewinddir): Declare, missing since 2011-09-13.
52546         (dirfd): Declare, missing since 2010-03-08.
52548 2017-05-04  Bruno Haible  <bruno@clisp.org>
52550         argp: Fix mistake in 2017-04-23 commit.
52551         * lib/argp-help.c (__argp_failure): If GNULIB_STRERROR_R_POSIX is set,
52552         assume that strerror_r returns 'int', not 'char *'.
52554 2017-05-04  Reuben Thomas  <rrt@sc3d.org>
52556         argp: Fix typo.
52557         * lib/argp-help.c (argp_doc): Fix spelling mistake in comment.
52559 2017-05-02  Paul Eggert  <eggert@cs.ucla.edu>
52561         utimens: port to Emacs + MS-Windows
52562         Skip the new MS-Windows-specific code if Emacs.
52563         * lib/utimens.c [EMACS_CONFIGUATION]:
52564         Avoid new MS-Windows-specific code.
52565         (USE_SETFILETIME): New macro.
52566         (fdutimens): Use it.
52568 2017-05-01  Paul Eggert  <eggert@cs.ucla.edu>
52570         tzset: update doc for TZ problems on MS-Windows
52571         * doc/posix-functions/ctime.texi,  doc/posix-functions/daylight.texi:
52572         * doc/posix-functions/localtime.texi, doc/posix-functions/mktime.texi:
52573         * doc/posix-functions/strftime.texi, doc/posix-functions/timezone.texi:
52574         * doc/posix-functions/tzname.texi, doc/posix-functions/tzset.texi:
52575         * doc/posix-functions/wcsftime.texi:
52576         Mention some issues with TZ under MS-Windows.
52578 2017-05-01  Bruno Haible  <bruno@clisp.org>
52580         copy-file: Fix build error on mingw.
52581         * modules/copy-file (Depends-on): Add 'close'.
52583 2017-05-01  Bruno Haible  <bruno@clisp.org>
52585         tzset: Work around TZ problem on native Windows.
52586         * m4/tzset.m4 (gl_FUNC_TZSET): Require AC_CANONICAL_HOST. On native
52587         Windows, set REPLACE_TZSET to 1.
52588         * lib/tzset.c (tzset): On native Windows, fix TZ if necessary, and
52589         invoke '_tzset' instead of 'tzset'.
52590         * doc/posix-functions/tzset.texi: Mention the native Windows workaround.
52592         * modules/time_rz (Depends-on): Add tzset.
52593         * lib/time_rz.c (tzset): Remove fallback definition.
52594         * m4/time_rz.m4 (gl_TIME_RZ): Don't test for tzset.
52596 2017-05-01  Bruno Haible  <bruno@clisp.org>
52598         mktime: Fix dependencies.
52599         * modules/mktime (Depends-on): Add 'time'.
52601 2017-05-01  Bruno Haible  <bruno@clisp.org>
52603         New module 'localtime-buffer', split off from module 'gettimeofday'.
52604         * lib/localtime-buffer.h: New file.
52605         * lib/localtime-buffer.c: New file, extracted from lib/gettimeofday.c.
52606         * lib/time.in.h (tzset): New declaration.
52607         (localtime, gmtime): Don't test GNULIB_GETTIMEOFDAY.
52608         * lib/tzset.c: New file, extracted from lib/gettimeofday.c.
52609         * lib/gettimeofday.c: Include localtime-buffer.h. Remove code that was
52610         moved to lib/localtime-buffer.c or lib/tzset.c.
52611         * m4/localtime-buffer.m4: New file.
52612         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_TZSET,
52613         HAVE_TZSET, REPLACE_TZSET.
52614         * m4/tzset.m4 (gl_FUNC_TZSET): Move code from m4/gettimeofday.m4 to
52615         here, with modifications. Set HAVE_TZSET, REPLACE_TZSET. Invoke
52616         gl_LOCALTIME_BUFFER_NEEDED.
52617         (gl_FUNC_TZSET_CLOBBER): Don't require gl_HEADER_SYS_TIME_H; not needed
52618         since 2007-01-18.
52619         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Remove code that deals with
52620         tzset.
52621         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Require gl_LOCALTIME_BUFFER_DEFAULTS.
52622         Invoke gl_LOCALTIME_BUFFER_NEEDED instead of
52623         gl_GETTIMEOFDAY_REPLACE_LOCALTIME.
52624         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Remove macro.
52625         * modules/localtime-buffer: New file.
52626         * modules/time (Depends-on): Remove 'gettimeofday'.
52627         (Makefile.am): Substitute GNULIB_TZSET, HAVE_TZSET,
52628         REPLACE_TZSET. Don't substitute GNULIB_GETTIMEOFDAY.
52629         * modules/tzset (Description): Enable hyperlink to POSIX spec.
52630         (Files): Add lib/tzset.c.
52631         (Depends-on): Remove gettimeofday. Add localtime-buffer, time.
52632         (configure.ac): Arrange to conditionally compile lib/tzset.c. Invoke
52633         gl_TIME_MODULE_INDICATOR.
52634         * modules/gettimeofday (Depends-on): Add localtime-buffer.
52636 2017-05-01  Bruno Haible  <bruno@clisp.org>
52638         copy-file: Preserve sub-second time stamps.
52639         * lib/copy-file.c: Include stat-time.h, utimens.h instead of <utime.h>.
52640         (qcopy_file_preserving): Use 'struct timespec' and utimens() to
52641         transport the time stamps from the original file to the destination
52642         file.
52643         * m4/copy-file.m4 (gl_COPY_FILE): Don't test for utime, utimes.
52644         * modules/copy-file (Depends-on): Add stat-time, utimns instead of
52645         utime-h.
52647 2017-05-01  Bruno Haible  <bruno@clisp.org>
52649         wctype-t: Fix problems if <wchar.h> gets included after <wctype.h>.
52650         * lib/wctype.in.h: Include not only <ctype.h> but also <wchar.h>. Do so
52651         also on MSVC.
52652         Reported by Eli Zaretskii <eliz@gnu.org>.
52654 2017-05-01  Bruno Haible  <bruno@clisp.org>
52656         wchar: Fix compilation error with the original mingw.org mingw.
52657         * lib/wchar.in.h (rpl_wint_t): If <crtdefs.h> does not exist, include
52658         <stddef.h> instead.
52659         * m4/wint_t.m4 (gl_TYPE_WINT_T_PREREQ): New macro, extracted from
52660         gl_WCTYPE_H.
52661         * m4/wctype_h.m4 (gl_WCTYPE_H): Don't set HAVE_CRTDEFS_H here; require
52662         gl_TYPE_WINT_T_PREREQ instead.
52663         * m4/wchar_h.m4 (gl_WCHAR_H): Require gl_TYPE_WINT_T_PREREQ.
52664         * modules/wchar (Makefile.am): Substitute HAVE_CRTDEFS_H.
52665         Reported by Eli Zaretskii <eliz@gnu.org>.
52667 2017-04-30  Bruno Haible  <bruno@clisp.org>
52669         utimecmp: Add support for native Windows.
52670         * lib/utimecmp.c (SYSCALL_RESOLUTION): Set to 100 on native Windows.
52672 2017-04-30  Bruno Haible  <bruno@clisp.org>
52674         utimens: Add support for native Windows.
52675         * lib/utimens.c: Include <windows.h>, msvc-nothrow.h.
52676         (fdutimens): Provide a native Windows implementation, like utime.c with
52677         added tv_nsec support.
52678         * modules/utimens (Depends-on): Add msvc-nothrow, utime.
52679         Suggested by Tim Rühsen <tim.ruehsen@gmx.de>.
52681 2017-04-30  Bruno Haible  <bruno@clisp.org>
52683         wcsftime: New module.
52684         * lib/wchar.in.h (wcsftime): New declaration.
52685         * lib/wcsftime.c: New file.
52686         * m4/wcsftime.m4: New file.
52687         * m4/wchar_h.m4 (gl_WCHAR_H): Test for wcsftime declaration.
52688         (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_WCSFTIME,
52689         HAVE_WCSFTIME, REPLACE_WCSFTIME.
52690         * modules/wchar (Makefile.am): Substitute GNULIB_WCSFTIME,
52691         HAVE_WCSFTIME, REPLACE_WCSFTIME.
52692         * modules/wcsftime: New file.
52693         * doc/posix-functions/wcsftime.texi: Mention the new module.
52695 2017-04-30  Bruno Haible  <bruno@clisp.org>
52697         strftime-fixes: New module.
52698         * lib/time.in.h (strftime): New declaration.
52699         * lib/strftime-fixes.c: New file.
52700         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Inline gl_FUNC_STRFTIME macro.
52701         (gl_FUNC_STRFTIME): Remove macro.
52702         * m4/strftime-fixes.m4: New file.
52703         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_STRFTIME,
52704         REPLACE_STRFTIME.
52705         * modules/time (Makefile.am): Substitute GNULIB_STRFTIME,
52706         REPLACE_STRFTIME.
52707         * modules/strftime-fixes: New file.
52708         * doc/posix-functions/strftime.texi: Mention the new module.
52710 2017-04-30  Bruno Haible  <bruno@clisp.org>
52712         mktime: Work around TZ problem on native Windows.
52713         * lib/mktime.c: Add #ifs to make the algorithmic workaround independent
52714         from the native Windows workaround.
52715         * m4/mktime.m4 (gl_FUNC_MKTIME_WORKS): New macro, extracted from
52716         gl_FUNC_MKTIME. If guessing, set gl_cv_func_working_mktime to
52717         'guessing no'.
52718         (gl_FUNC_MKTIME): Require it. Require AC_CANONICAL_HOST.
52719         Set REPLACE_MKTIME to 1 on native Windows. Define NEED_MKTIME_WORKING,
52720         NEED_MKTIME_WINDOWS.
52721         (gl_FUNC_MKTIME_INTERNAL): Require gl_FUNC_MKTIME_WORKS, not
52722         gl_FUNC_MKTIME. Set WANT_MKTIME_INTERNAL, not REPLACE_MKTIME. Define
52723         NEED_MKTIME_INTERNAL.
52724         * m4/timegm.m4 (gl_FUNC_TIMEGM): Require gl_FUNC_MKTIME_WORKS, not
52725         gl_FUNC_MKTIME. Cope with 'guessing yes' value.
52726         * modules/mktime-internal (configure.ac): Test WANT_MKTIME_INTERNAL,
52727         not REPLACE_MKTIME.
52728         * doc/posix-functions/mktime.texi: Mention the native Windows
52729         workaround.
52731 2017-04-30  Bruno Haible  <bruno@clisp.org>
52733         localtime: New module.
52734         * lib/time.in.h (localtime): Declare also if requested by module
52735         'localtime'.
52736         * lib/localtime.c: New file.
52737         * m4/localtime.m4: New file.
52738         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_LOCALTIME.
52739         * modules/time (Makefile.am): Substitute GNULIB_LOCALTIME.
52740         * modules/localtime: New file.
52741         * doc/posix-functions/localtime.texi: Mention the new module.
52743 2017-04-30  Bruno Haible  <bruno@clisp.org>
52745         ctime: New module.
52746         * lib/time.in.h (ctime): New declaration.
52747         * lib/ctime.c: New file.
52748         * m4/ctime.m4: New file.
52749         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_CTIME,
52750         REPLACE_CTIME.
52751         * modules/time (Makefile.am): Substitute GNULIB_CTIME, REPLACE_CTIME.
52752         * modules/ctime: New file.
52753         * doc/posix-functions/ctime.texi: Mention the new module.
52755 2017-04-30  Bruno Haible  <bruno@clisp.org>
52757         gettimeofday: Provide higher resolution on native Windows.
52758         * lib/gettimeofday.c: Don't include <sys/timeb.h>.
52759         (GetSystemTimePreciseAsFileTimeFuncType): New variable.
52760         (initialize): Initialize it.
52761         (gettimeofday) [WINDOWS_NATIVE]: Use it, and convert from FILETIME to
52762         'struct timeval'. Don't use _ftime().
52763         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): Don't test for
52764         <sys/timeb.h> and _ftime.
52766 2017-04-30  Bruno Haible  <bruno@clisp.org>
52768         Document the problem with the Cygwin environment variable TZ.
52769         * doc/posix-functions/tzset.texi: Add note about TZ.
52770         * doc/posix-functions/ctime.texi: Likewise.
52771         * doc/posix-functions/localtime.texi: Likewise.
52772         * doc/posix-functions/mktime.texi: Likewise.
52773         * doc/posix-functions/strftime.texi: Likewise.
52774         * doc/posix-functions/wcsftime.texi: Likewise.
52775         * doc/pastposix-functions/ftime.texi: Likewise.
52777 2017-04-30  Bruno Haible  <bruno@clisp.org>
52779         utime-tests: New module.
52780         * tests/test-utime.c: New file, based on tests/test-utimens.h.
52781         * tests/test-utimens-common.h: Include <sys/stat.h>.
52782         * modules/utime-tests: New file.
52784 2017-04-29  Bruno Haible  <bruno@clisp.org>
52786         utime: New module.
52787         * lib/utime.in.h: Add comment for snippets.
52788         (utime): New declaration.
52789         * lib/utime.c: New file.
52790         * m4/utime.m4: New file.
52791         * m4/utime_h.m4 (gl_UTIME_H): Test for utime declaration.
52792         (gl_UTIME_H_DEFAULTS): Initialize GNULIB_UTIME, HAVE_UTIME,
52793         REPLACE_UTIME.
52794         * modules/utime-h (Depends-on): Add snippets.
52795         (Makefile.am): Substitute GNULIB_UTIME, HAVE_UTIME, REPLACE_UTIME.
52796         Insert snippets.
52797         * modules/utime: New file.
52798         * doc/posix-functions/utime.texi: Mention the new module.
52800 2017-04-29  Bruno Haible  <bruno@clisp.org>
52802         utime-h: Modernize handling of 'struct utimbuf'.
52803         * lib/utime.in.h: Include next <utime.h> if it exists.
52804         (utimbuf): Define to _utimbuf on native Windows.
52805         * m4/utime_h.m4 (gl_UTIME_H): Check for prerequisites of include_next.
52806         Set UTIME_H on native Windows.
52807         (gl_UTIME_MODULE_INDICATOR, gl_HEADER_UTIME_H_DEFAULTS): New macros.
52808         * modules/utime-h (Depends-on): Add include_next.
52809         (Makefile.am): Substitute also HAVE_UTIME_H, INCLUDE_NEXT,
52810         PRAGMA_SYSTEM_HEADER, PRAGMA_COLUMNS, NEXT_UTIME_H.
52812         * lib/utimens.c (utimbuf): Remove fallback definition.
52813         * m4/utimens.m4 (gl_UTIMENS): Don't require
52814         gl_CHECK_TYPE_STRUCT_UTIMBUF.
52815         * m4/utimbuf.m4: Remove file.
52816         * modules/utimens (Files): Remove m4/utimbuf.m4.
52818 2017-04-29  Bruno Haible  <bruno@clisp.org>
52820         Make use of module 'utime-h'.
52821         * modules/copy-file (Depends-on): Add utime-h.
52822         * lib/copy-file.c: Assume that <utime.h> exists.
52823         * m4/copy-file.m4 (gl_COPY_FILE): Don't test for <utime.h>.
52825         * modules/utimens (Depends-on): Add utime-h.
52826         * lib/utimens.c: Assume that <utime.h> exists.
52828 2017-04-29  Bruno Haible  <bruno@clisp.org>
52830         utime-h: New module.
52831         * m4/utime_h.m4: New file.
52832         * lib/utime.in.h: New file.
52833         * modules/utime-h: New file.
52834         * doc/posix-headers/utime.texi: Mention the new module.
52836         * tests/test-utime-h.c: New file.
52837         * modules/utime-h-tests: New file.
52839 2017-04-30  Bruno Haible  <bruno@clisp.org>
52841         Fix a few typos.
52842         * m4/fstat.m4 (gl_FUNC_FSTAT): Require AC_CANONICAL_HOST.
52843         * m4/stat.m4 (gl_FUNC_STAT): Fix comment.
52844         * doc/posix-functions/fstat.texi: Fix a plural typo.
52845         * doc/posix-functions/stat.texi: Likewise.
52846         * m4/include_next.m4: Update comments.
52848 2017-04-29  Bruno Haible  <bruno@clisp.org>
52850         error: Fix mistake in 2017-04-23 commit.
52851         * lib/error.c (print_errno_message): If GNULIB_STRERROR_R_POSIX is set,
52852         assume that strerror_r returns 'int', not 'char *'.
52854 2017-04-29  Bruno Haible  <bruno@clisp.org>
52856         stat: Fix time_t values and other problems on native Windows platforms.
52857         * doc/posix-functions/stat.texi: Mention the problem with the Microsoft
52858         implementations of stat().
52859         * lib/stat.c: Include filename.h instead of dosname.h. Include
52860         malloca.h, stat-w32.h.
52861         (is_unc_root): New function.
52862         (rpl_stat): New implementation for native Windows. Remove
52863         REPLACE_FUNC_STAT_DIR code.
52864         * m4/stat.m4 (gl_FUNC_STAT): On native Windows, set REPLACE_STAT always.
52865         Don't define REPLACE_FUNC_STAT_DIR.
52866         (gl_PREREQ_STAT): Require gl_HEADER_SYS_STAT_H.
52867         * modules/stat (Files): Add lib/stat-w32.h, lib/stat-w32.c.
52868         (Depends-on): Remove dosname. Add filename, malloca.
52869         (configure.ac): Also compile lib/stat-w32.c.
52871 2017-04-29  Bruno Haible  <bruno@clisp.org>
52873         fstat: Fix time_t values on native Windows platforms.
52874         * doc/posix-functions/fstat.texi: Mention the problem with st_*time.
52875         * lib/stat-w32.h: New file.
52876         * lib/stat-w32.c: New file.
52877         * lib/fstat.c: Don't include msvc-inval.h. Include msvc-nothrow.h,
52878         stat-w32.h instead.
52879         (fstat_nothrow): Remove function.
52880         (rpl_fstat): Implement by means of _gl_fstat_by_handle.
52881         * m4/fstat.m4 (gl_FUNC_FSTAT): On native Windows, set REPLACE_FSTAT
52882         always.
52883         (gl_PREREQ_FSTAT): Require gl_HEADER_SYS_STAT_H.
52884         * modules/fstat (Files): Add lib/stat-w32.h, lib/stat-w32.c.
52885         (Depends-on): Remove msvc-inval. Add pathmax, msvc-nothrow.
52886         (configure.ac): Also compile lib/stat-w32.c.
52888 2017-04-29  Paul Eggert  <eggert@cs.ucla.edu>
52890         getopt: port to Solaris 10 with circa-1997 glibc getopt.h
52891         Problem reported by Assaf Gordon and Gavin Smith in:
52892         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00157.html
52893         * lib/getopt-pfx-ext.h (_getopt_internal) [__GETOPT_PREFIX]:
52894         #define this, too.
52896 2017-04-29  Bruno Haible  <bruno@clisp.org>
52898         strerror_r-posix: Fixes for MSVC 14.
52899         * lib/strerror_r.c: Include <stdarg.h>.
52900         (strerror_r): Provide error messages for errno values 100...140.
52901         * doc/posix-functions/strerror_r.texi: Mention the MSVC 14 problem.
52903 2017-04-28  Bruno Haible  <bruno@clisp.org>
52905         noreturn: New module.
52906         * lib/noreturn.h: New file.
52907         * modules/noreturn: New file.
52908         * tests/test-noreturn.c: New file.
52909         * modules/noreturn-tests: New file.
52910         * tests/test-noreturn-c++.cc: New file.
52911         * modules/noreturn-c++-tests: New file.
52913 2017-04-27  Bruno Haible  <bruno@clisp.org>
52915         wctype-h: Fix compilation error with the original mingw.org mingw.
52916         * m4/wctype_h.m4 (gl_WCTYPE_H): Test for <crtdefs.h>. Set
52917         HAVE_CRTDEFS_H.
52918         * modules/wctype-h (Makefile.am): Substitute HAVE_CRTDEFS_H.
52919         * lib/wctype.in.h (rpl_wint_t): If <crtdefs.h> does not exist, include
52920         <stddef.h> instead.
52921         Reported and proposed by Eli Zaretskii <eliz@gnu.org>.
52923 2017-04-26  Pádraig Brady  <P@draigBrady.com>
52925         nap.h: Fix compilation on non windows platforms
52926         * tests/nap.h: Move misplaced endif.
52928 2017-04-26  Pádraig Brady  <P@draigBrady.com>
52929         and Paul Eggert  <eggert@cs.ucla.edu>
52931         time_rz: fix heap buffer overflow vulnerability
52932         Reported and analyzed at https://bugzilla.redhat.com/CVE-2017-7476
52933         * lib/time_rz.c (save_abbr): Rearrange the calculation determining
52934         whether there is enough buffer space available, thus avoiding
52935         the problematic promotion of signed to unsigned causing an invalid
52936         comparison when zone_copy is more than ABBR_SIZE_MIN bytes beyond
52937         the start of the buffer.
52938         * tests/test-parse-datetime.c (main): Add a test case written by
52939         Paul Eggert, which overwrites enough of the heap so that
52940         standard glibc will fail with "free(): invalid pointer"
52941         without the patch applied.
52943 2017-04-26  Paul Eggert  <eggert@cs.ucla.edu>
52945         xalloc: add missing integer overflow check
52946         * lib/xalloc.h (x2nrealloc): Also check for multiplication
52947         overflow when P is null.
52949 2017-04-25  Paul Eggert  <eggert@cs.ucla.edu>
52951         parse-datetime: make it standalone
52952         * lib/parse-datetime.y: Include <stdarg.h>, for va_start etc.
52953         (_GL_ATTRIBUTE_FORMAT): New macro.
52954         These are needed to get './gnulib-tool --test parse-datetime' to work.
52956 2017-04-23  Bruno Haible  <bruno@clisp.org>
52958         nap.h: Port to native Windows.
52959         * tests/nap.h (nap_get_stat): Renamed from get_stat. Remove argument fd;
52960         use nap_fd instead. On native Windows, close and reopen nap_fd.
52961         (nap_works): Don't compare the ctimes, because on native Windows, these
52962         are the creation times.
52963         (nap): Update.
52965 2017-04-23  Bruno Haible  <bruno@clisp.org>
52967         nap.h: Fix logic.
52968         * tests/nap.h (nap): Avoid signed integer overflow in loop.
52970 2017-04-23  Bruno Haible  <bruno@clisp.org>
52972         Fix conflict between strerror_r-posix module and AC_FUNC_STRERROR_R.
52973         * modules/strerror_r-posix (configure.ac): Invoke gl_MODULE_INDICATOR.
52974         * lib/error.c: Test GNULIB_STRERROR_R_POSIX before testing
52975         HAVE_DECL_STRERROR_R, HAVE_STRERROR_R, or STRERROR_R_CHAR_P.
52976         * lib/argp-help.c (__argp_failure): Likewise.
52978 2017-04-23  Bruno Haible  <bruno@clisp.org>
52980         strerror_r-posix: Revert commits from 2016-10-16,2016-11-04,2016-11-14.
52981         * m4/strerror_r.m4: Revert changes since 2016-10-16.
52982         * lib/strerror_r.c: Likewise.
52984 2017-04-23  Paul Eggert  <eggert@cs.ucla.edu>
52986         Target a C99 subset, not a C89 subset
52987         For many years Gnulib has targeted C89 and has resisted using C99
52988         features, as some Gnulib-using programs still wanted to target
52989         C89.  As this no longer seems to be the case, relax the porting
52990         requirements to allow some C99 features.  This is merely a change
52991         to the documentation, to give other Gnulib developers a chance to
52992         weigh in on the topic.
52993         * doc/extern-inline.texi (extern inline):
52994         * doc/gnulib-readme.texi (Portability guidelines):
52995         * doc/gnulib-tool.texi (Initial import):
52996         * doc/gnulib.texi (Header files):
52997         Modernize to talk about C99 and C11 instead of C89 and C99.
52998         * doc/gnulib-readme.texi (Portability guidelines):
52999         Now a section, not merely a subsection, so that it
53000         can be split up.  Modernize a bit.
53001         (C language versions, C99 features assumed)
53002         (C99 features avoided):
53003         New sections.
53005 2017-04-23  Bruno Haible  <bruno@clisp.org>
53007         doc: New section "Modules that modify the way other modules work".
53008         * doc/gnulib.texi (Modules that modify the way other modules work): New
53009         section.
53011 2017-04-23  Bruno Haible  <bruno@clisp.org>
53013         stat-time: Update comments.
53014         * lib/stat-time.h: Fix reference regarding st_ctime on Windows.
53015         * tests/test-utimens-common.h: Add reference regarding st_ctime on
53016         Windows.
53018 2017-04-01  Bruno Haible  <bruno@clisp.org>
53020         glob: Fix more memory leaks.
53021         * lib/glob.c (glob): Free allocated memory before returning.
53022         Reported by Coverity via Tim Rühsen.
53024 2017-04-22  Paul Eggert  <eggert@cs.ucla.edu>
53026         poll: improve fast check for out-of-range NFD
53027         * lib/poll.c: Do not include intprops.h.
53028         (poll): Compare NFD to INT_MAX, not to TYPE_MAXIMUM (nfds_t) / 2.
53029         * modules/poll (Depends-on): Remove intprops.
53031         ftoastr: cite a newer paper
53032         * lib/ftoastr.c (FTOASTR): In comment, cite Andrysco et al. 2016
53033         instead of Loitsch 2010.
53035 2017-04-22  Bruno Haible  <bruno@clisp.org>
53037         poll: Enable argument check also in the Windows implementation.
53038         * lib/poll.c (poll) [WINDOWS_NATIVE]: Check value of nfd correctly.
53039         Reported by Paul Eggert.
53041 2017-04-22  Bruno Haible  <bruno@clisp.org>
53043         getlogin_r: Work around bug in Mac OS X 10.12.
53044         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Test also against the Mac OS X
53045         bug.
53046         * lib/getlogin_r.c (getlogin_r): When getlogin_r returns a string of the
53047         given size minus 1, call getlogin_r a second time, on a larger buffer.
53048         * modules/getlogin_r (Depends-on): Add malloca.
53049         * doc/posix-functions/getlogin_r.texi: Mention the Mac OS X bug.
53051 2017-04-22  Paul Eggert  <eggert@cs.ucla.edu>
53053         parse-datetime: fix %z and prefer signed int
53054         %z problem reported by Pádraig Brady in:
53055         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00103.html
53056         While fixing it, I decided to prefer signed ints to size_t, as
53057         they are less error-prone (e.g., ubsan catches overflow).
53058         * lib/parse-datetime.y (textint, parser_control, lookup_word, yylex)
53059         (parse_datetime2): Prefer ptrdiff_t to size_t for sizes and object
53060         counts, since signed integers make for better debugging.
53061         (date): Don’t assume %z works in printf formats.
53062         (debug_strfdatetime, debug_strfdate, debug_strftime): Use int for
53063         sizes of buffers known to be small, e.g., because we’re using snprintf.
53064         (parse_datetime2): Simplify call to debug_mktime_not_ok.
53066 2017-04-22  Bruno Haible  <bruno@clisp.org>
53068         *printf: Work around rounding bug on Mac OS X.
53069         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Test for Mac OS X 10.12 bug.
53070         * doc/posix-functions/*printf.texi: Mention the rounding bugs of
53071         Mac OS X and FreeBSD.
53072         * doc/glibc-functions/*printf.texi: Likewise.
53074 2017-04-22  Bruno Haible  <bruno@clisp.org>
53076         vasnprintf tests: Avoid warnings.
53077         * tests/test-vasnprintf-posix3.c (test_function, my_asnprintf,
53078         test_vasnprintf, test_asnprintf): Don't define if there's nothing to
53079         test.
53081 2017-04-22  Bruno Haible  <bruno@clisp.org>
53083         sys_file tests: Avoid warning.
53084         * tests/test-sys_file.c (main): Add a default clause to the switch
53085         statement.
53087 2017-04-22  Bruno Haible  <bruno@clisp.org>
53089         sethostname: Update doc.
53090         * doc/glibc-functions/sethostname.texi: Mention differing prototype on
53091         Mac OS X.
53093 2017-04-22  Bruno Haible  <bruno@clisp.org>
53095         quotearg tests: Avoid warnings.
53096         * tests/test-quotearg.c: Don't include test-quotearg.h if ENABLE_NLS is
53097         false.
53099 2017-04-22  Bruno Haible  <bruno@clisp.org>
53101         poll: Enable argument check.
53102         * lib/poll.c: Include intprops.h.
53103         (poll): Check value of nfd correctly.
53104         * modules/poll (Depends-on): Add intprops.
53106 2017-04-22  Bruno Haible  <bruno@clisp.org>
53108         get-rusage-data: Avoid warnings on Mac OS X.
53109         * lib/get-rusage-data.c: On Mac OS X, don't define
53110         get_rusage_data_via_setrlimit nor get_rusage_data_via_iterator.
53111         (get_rusage_data) [Mac OS X]: Just return 0.
53113 2017-04-22  Bruno Haible  <bruno@clisp.org>
53115         xbinary-io: Fix build error.
53116         * modules/xbinary-io (Depends-on): Add gettext-h.
53117         * lib/xbinary-io.c: Include gettext.h and define _().
53118         Reported by Gisle Vanem <gisle.vanem@gmail.com> in
53119         <https://lists.gnu.org/r/bug-gnulib/2017-04/msg00089.html>.
53121 2017-04-22  Paul Eggert  <eggert@cs.ucla.edu>
53123         parse-datetime: overflow and debug cleanups
53124         This long patch was triggered by this bug report from Ruediger Meier:
53125         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00028.html
53126         I fixed the bug he noted, then found some others nearby, and then
53127         still others.  Oh my goodness, there were a lot of bugs.  I cleaned
53128         up some of the code to follow GNU standards while I was at it.
53129         * lib/parse-datetime.y (ISDIGIT): Remove; all callers changed to
53130         use c_isdigit.
53131         (EPOCH_YEAR): Remove; unused.
53132         (TM_YEAR_BASE): Now an enum rather than a macro.
53133         (HOUR, debug_strfdatetime): Multiply hour by 3600, not 60, to get
53134         time zone offset, since timezones now are in terms of seconds and
53135         not minutes.
53136         (long_time_t): Remove.  All uses replaced by time_t or intmax_t as
53137         appropriate.  Verify that intmax_t is wide enough.
53138         (time_overflow, time_zone_str): New functions, used to deal
53139         more reliably with overflow.
53140         (dbg_printf): Add printf attribute, to help catch integer width errors.
53141         (textint, relative_time, parser_control, time_zone_hhmm, set_hhmmss)
53142         (%union, to_hour, yylex, parse_datetime2):
53143         Use intmax_t instead of long int and/or long_time_t.
53144         All uses changed.
53145         (DBGBUFSIZE): Move earlier.
53146         (relative_time, set_hhmmss, parser_control):
53147         Just use int for nanoseconds and for time zones; that’s wide enough.
53148         (parser_control): Use bool for members like year_seen that can
53149         be booleans instead of counters.  All uses changed.
53150         Remove debug_default_input_timezone; no longer needed.
53151         All uses removed.
53152         (apply_relative_time): Return a bool overflow flag.
53153         All uses changed to check for overflow.
53154         (apply_relative_time, zone, date, relunit, relunit_snumber)
53155         (signed_seconds, unsigned_seconds, yylex, parse_datetime2):
53156         Check for integer overflow portably.
53157         (str_days): Use just int for N, as it’s wide enough.
53158         Prefer 2D char arrays to arrays of char * when it looks like
53159         2D is a win on typical platforms.
53160         Prefer snprintf to strncpy/strncat, for simplicity;
53161         all buffers are smaller than INT_MAX so this is safe.
53162         (TIME_ZONE_BUFSiZE, TM_YEAR_BUFSIZE): New constants.
53163         (debug_print_current_time): Don’t assume tv_nsec is of type long,
53164         as this is not true on x32.  Output "." before any nanoseconds.
53165         (debug_print_current_time, parse_datetime2):
53166         Output local zones using a more-consistent format.
53167         (debug_print_current_time, date, parse_datetime2):
53168         (main) [TEST]:
53169         Don’t assume time_t is the same width as long.
53170         (print_rel_part): New function, replacing ...
53171         (PRINT_REL_PART): ... this macro, which was removed.  All uses changed.
53172         (debug_print_relative_time): Use bool for boolean.
53173         (local_zone): dsts_seen now counts only tDST instances.
53174         (date): Fix printf of size_t to use %z.  Do not assume numeric
53175         tokens have negative values merely because the context suggests
53176         a syntax with "-" separating tokens.
53177         (time_zone_hhmm): Return bool success indicator, which checks for
53178         overflow.  Store result into PC->time_zone instead.  All callers
53179         changed.
53180         (tm_year_str): New function.  Return a bool success indicator and
53181         store the result into a buffer.  All callers changed.  Output the
53182         numerically correct string even if adding 1900 to the year would
53183         overflow.
53184         (to_tm_year): New function, replacing the old to_year.  All
53185         callers changed.
53186         (tm_diff): Sync with glibc.
53187         (lookup_word): Use to_uchar instead of doing it by hand.
53188         (TZBUFSIZE): Now local to the only function that needs it.
53189         (debug_strfdatetime): Simplify now that time zones are int seconds.
53190         (debug_strfdate): Work even if tm_year + 1900 would overflow.
53191         (get_effective_timezone): Remove.  All uses removed.
53192         (parse_datetime2): Use fprintf in pieces instead of snprintfing
53193         to a fixed-size buffer.  Don’t assume that gmtime succeeds iff
53194         localtime succeeds.  Use tm_gmtoff if available.  Simplify how
53195         ‘goto fail;’ works in conjunction with the ‘ok’ flag.
53196         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Don’t define
53197         TIME_T_FITS_IN_LONG_INT, as it is no longer needed.
53198         * modules/parse-datetime (Depends-on): Add inttypes.
53200 2017-04-21  Bruno Haible  <bruno@clisp.org>
53202         gettext-h: Avoid -Wundef warning.
53203         * lib/gettext.h: Test the value of ENABLE_NLS only if it is defined.
53204         Reported by Tim Rühsen <tim.ruehsen@gmx.de> in
53205         <https://lists.gnu.org/r/bug-gnulib/2017-04/msg00022.html>.
53207 2017-04-05  Tim Rühsen  <tim.ruehsen@gmx.de>
53209         error: Avoid "function declaration isn't a prototype" warning.
53210         * lib/error.c (strerror_r): Turn K&R C prototype to an ANSI C prototype.
53212 2017-04-21  Bruno Haible  <bruno@clisp.org>
53214         vasnprintf: Fix for MSVC 14.
53215         * lib/vasnprintf.c (USE_MSVC__SNPRINTF): New macro.
53216         Everywhere, use !HAVE_SNPRINTF_RETVAL_C99 || USE_MSVC__SNPRINTF instead
53217         of !HAVE_SNPRINTF_RETVAL_C99.
53219 2017-04-21  Bruno Haible  <bruno@clisp.org>
53221         mbrtowc tests: Fix test failures on MSVC 14.
53222         * tests/test-mbrtowc-w32.c (test_one_locale): Accept MSVC's conversion
53223         behaviour for invalid input.
53225 2017-04-21  Bruno Haible  <bruno@clisp.org>
53227         mbsinit: Fix for MSVC 14.
53228         * lib/mbsinit.c (mbsinit): If GNULIB_defined_mbstate_t, provide an
53229         implementation that is in sync with mbrtowc.c. On other platforms, use
53230         an adequate ad-hoc implementation.
53232 2017-04-21  Bruno Haible  <bruno@clisp.org>
53234         Fix test-mbrtowc5.sh failure on native Windows.
53235         * lib/setlocale.c (setlocale_unixlike): Accept "POSIX" as an alias for
53236         "C".
53238 2017-04-21  Bruno Haible  <bruno@clisp.org>
53240         Avoid accidental use of native Windows APIs on Cygwin.
53241         * lib/getaddrinfo.c (WINDOWS_NATIVE): Don't define on Cygwin.
53242         * lib/localcharset.c (WINDOWS_NATIVE): Likewise.
53243         * lib/localename.c (WINDOWS_NATIVE): Likewise.
53245 2017-04-20  Bruno Haible  <bruno@clisp.org>
53247         Remove red warnings from the generated MODULES.html.
53248         * modules/fcntl (Description): Disambiguate function references.
53249         * modules/getcwd-lgpl (Description): Likewise.
53250         * modules/hostent (Description): Likewise.
53251         * modules/servent (Description): Likewise.
53252         * modules/tempname (Description): Likewise.
53254 2017-04-20  Bruno Haible  <bruno@clisp.org>
53256         verify tests: Fix spurious failure with parallel make.
53257         * gnulib-tool (func_emit_tests_Makefile_am): Emit initialization of
53258         EXTRA_PROGRAMS.
53259         * tests/test-verify.sh: Build test-verify-try.o, not test-verify.o.
53260         * tests/test-verify-try.c: New file.
53261         * modules/verify-tests (Files): Add it.
53262         (EXTRA_PROGRAMS): Add test-verify-try.
53263         (MOSTLYCLEANFILES): Update accordingly.
53264         Reported by Adam James Stewart <ajstewart@anl.gov>.
53266 2017-04-18  Bruno Haible  <bruno@clisp.org>
53268         vma-iter: Fix compilation error on Solaris 7.
53269         * lib/vma-iter.c (vma_iterate): Treat missing MAP_ANONYMOUS on Solaris
53270         like on IRIX, OSF/1.
53271         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
53273 2017-04-18  Bruno Haible  <bruno@clisp.org>
53275         vma-iter: Fix conflict with module 'largefile' on 32-bit Solaris 9.
53276         * modules/vma-iter (configure.ac): Test whether <sys/procfs.h> can be
53277         included.
53278         * lib/vma-iter.c: On Solaris, test HAVE_SYS_PROCFS_H before including
53279         <sys/procfs.h>.
53280         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Don't define on Solaris when
53281         <sys/procfs.h> cannot be included.
53282         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
53284 2017-04-18  Bruno Haible  <bruno@clisp.org>
53286         getopt-gnu: Add comments.
53287         * m4/getopt.m4 (gl_FUNC_GETOPT_GNU): Add comments.
53288         * modules/getopt-gnu (configure.ac): Likewise.
53290 2017-04-16  Paul Eggert  <eggert@cs.ucla.edu>
53292         regex: port better to Solaris 10
53293         Solaris 10 <locale.h> includes <libintl.h>, which #defines
53294         gettext, and this causes a double #define.
53295         Problem reported by Gavin Smith in:
53296         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00056.html
53297         * lib/regex_internal.h (gettext): #undef before #defining.
53299 2017-04-15  Paul Eggert  <eggert@Penguin.CS.UCLA.EDU>
53301         intprops: improve comments
53302         * lib/intprops.h: Improve and shorten commentary.
53303         For the record, if we ever run into a pedantic compiler that
53304         behaves differently from GCC when converting an out-of-range value
53305         to a signed integer, we can work around the problem with something
53306         like the following code, where UCT is the signed counterpart of T
53307         (UCT is sometimes narrower than UT) and all callers are changed
53308         accordingly:
53309         #if __SUNPRO_C <= 0x5120
53310         # define _GL_INT_OP_WRAPV_VIA_UNSIGNED(a, b, op, uct, ut, t) \
53311            ((t) ((ut) (a) op (ut) (b)))
53312         #else
53313         # define _GL_INT_OP_WRAPV_VIA_UNSIGNED(a, b, op, uct, ut, t) \
53314            (TYPE_MINIMUM (t) <= (uct) ((ut) (a) op (ut) (b)) \
53315             ? ((t) (uct) (((ut) (a) op (ut) (b)) - TYPE_MINIMUM (t)) \
53316                + TYPE_MINIMUM (t)) \
53317             : (t) (uct) ((ut) (a) op (ut) (b)))
53318         #endif
53320 2017-04-14  Paul Eggert  <eggert@Penguin.CS.UCLA.EDU>
53322         intprops: try to avoid tickling similar bugs
53323         * lib/intprops.h (_GL_INT_OP_CALC): Document that UT no longer
53324         needs to be the same width as T; it can be wider.
53325         Change callers so that UT is at least as wide as unsigned int,
53326         as I suspect that this is less likely to run into compiler bugs.
53328         intprops: port to Oracle Studio 12.3 x86
53329         Problem reported by Gavin Smith in:
53330         http://lists.gnu.org/r/bug-gnulib/2017-04/msg00049.html
53331         * lib/intprops.h (_GL_INT_OP_WRAPV_VIA_UNSIGNED):
53332         Convert unsigned to signed via the usual rather than the standard way,
53333         to avoid a compiler bug in Oracle Studio 12.3 x86.
53335 2017-04-08  Paul Eggert  <eggert@cs.ucla.edu>
53337         getopt: prefer - to _ in new file names
53338         * lib/getopt-cdefs.in.h: Rename from lib/getopt_cdefs.in.h.
53339         * lib/getopt-core.h: Rename from lib/getopt_core.h.
53340         * lib/getopt-ext.h: Rename from lib/getopt_ext.h.
53341         * lib/getopt-pfx-core.h: Rename from lib/getopt_pfx_core.h.
53342         * lib/getopt-pfx-ext.h: Rename from lib/getopt_pfx_ext.h.
53343         All uses changed.
53345         getopt: port recent getopt changes to macOS
53346         Problem reported by Harald Maier (Bug#26398).
53347         The macOS C compiler uses __nonnull for its own purposes and that
53348         clashes with glibc's __nonnull.
53349         * lib/getopt.in.h: Add comment for _GL_ARG_NONNULL snippet.
53350         * lib/getopt_cdefs.in.h (__nonnull): Remove.
53351         * lib/getopt_core.h (getopt):
53352         * lib/getopt_ext.h (getopt_long, getopt_long_only):
53353         Use _GL_ARG_NONNULL, not __nonnull.
53354         * lib/unistd.in.h: Move snippet hooks to before where the getopt
53355         .h files are included, so that _GL_ARG_NONNULL is defined in time.
53356         * modules/getopt-posix (Depends-on): Add snippet/arg-nonnull.
53357         (getopt.h): Interpolate _GL_ARG_NONNULL snippet.
53359 2017-04-06  Paul Eggert  <eggert@cs.ucla.edu>
53361         getopt-gnu: omit some duplicate code
53362         * m4/getopt.m4 (gl_FUNC_GETOPT_GNU): Don’t require
53363         gl_FUNC_GETOPT_POSIX, as the configure.ac code generated by
53364         gnulib-tool already does this.
53365         * modules/getopt-gnu (configure.ac): Omit code duplicated from
53366         getopt-posix, which we depend on.
53368         getopt-posix: use angle-bracket include
53369         * lib/getopt1.c: Include <config.h>, not "config.h".
53371 2017-04-06  Zack Weinberg  <zackw@panix.com>
53373         getopt: annotate files with relationship to glibc
53375         As the final act in this patchset, adjust the message at the top of
53376         each file to indicate which files are synced with glibc.  (This has
53377         already been done for most of the headers.)
53379         * lib/getopt.c, lib/getopt1.c, lib/getopt_int.h:
53380         Mention in top-of-file boilerplate that these files are shared
53381         between glibc and gnulib.
53384         getopt: split up getopt.in.h and eliminate __need_getopt
53386         Over in glibc, all of the __need macros are being phased out in favor
53387         of small headers that declare only the necessary components, as this
53388         is much simpler and less prone to bugs.  As getopt is shared with
53389         glibc, gnulib needs to do the same for __need_getopt.
53391         __need_getopt is misnamed; what it really means is "we want only the
53392         getopt features specified in POSIX, not the GNU extensions".  glibc
53393         placed the "meat" of getopt.h into getopt_core.h and getopt_ext.h;
53394         these files can be shared verbatim with gnulib.  The portability
53395         wrapper, on the other hand, they have renounced altogether; glibc's
53396         getopt.h will no longer be shared with gnulib at all.  In exchange,
53397         certain glibc-specific quirks (having to do with __posix_getopt) no
53398         longer need appear in gnulib's headers at all.
53400         This patch merges getopt_core.h and getopt_ext.h from glibc, and
53401         splits up the current gnulib-side portability wrapper into three
53402         additional headers: getopt_pfx_core.h and getopt_pfx_ext.h handle
53403         __GETOPT_PREFIX for their respective headers, getopt_cdefs.in.h
53404         handles things like __BEGIN_DECLS and __THROW, and getopt.in.h and
53405         unistd.in.h just use them.  All new files are clearly marked with
53406         whether they are shared with glibc.
53408         * lib/getopt.in.h: Eliminate __need_getopt.  Break up into ...
53409         * lib/getopt_core.h, lib/getopt_ext.h: ... these new files shared
53410         with glibc, and ...
53411         * lib/getopt_cdefs.in.h, lib/getopt_pfx_core.h
53412         * lib/getopt_pfx_ext.h: ... these new files not shared with glibc.
53413         * lib/unistd.in.h: Include getopt_cdefs.h and getopt_pfx_core.h,
53414         instead of defining __need_getopt and including the full getopt.h.
53416         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): Check for sys/cdefs.h.
53417         Define substitution variables GETOPT_CDEFS_H and HAVE_SYS_CDEFS_H.
53418         * modules/getopt-posix (Files): Add new headers and sort list.
53419         (Depends-on): No longer need snippet/arg-nonnull.
53420         (Makefile.am): Generate getopt_cdefs.h.
53423         getopt: better handling of ambiguous options
53425         glibc's getopt uses alloca to construct a linked list of possibilities
53426         for an "ambiguous" long option.  In gnulib, malloc should be used
53427         instead.  Providing for both cases complicates things a fair bit.
53429         This patch rewrites ambiguous-option handling to use a boolean vector
53430         instead of a linked list.  There is then only one allocation that
53431         might need freeing; in glibc it can honor __libc_use_alloca as usual,
53432         and in gnulib we define __libc_use_alloca to always be false, so we
53433         don't need ifdefs in the middle of the function.  This should also be
53434         slightly more efficient in the normal case of long options being fully
53435         spelled out -- I think most people aren't even aware they _can_
53436         sometimes abbreviate long options.
53438         One interesting consequence is that the list of possibilities is now
53439         printed in exactly the order they appear in the list of long options,
53440         instead of the first possibility being shuffled to the end.
53442         (The patch looks bigger than it really is because there's a fair bit
53443         of reindentation and code rearrangement.)
53445         * lib/getopt.c: When used standalone, define __libc_use_alloca
53446         as always false and alloca to abort if called.
53447         (process_long_option): Rewrite handling of ambiguous long options
53448         to use a single boolean vector, not a linked list; use
53449         __libc_use_alloca to decide whether to allocate this using alloca.
53452         getopt: refactor long-option handling
53454         There were two copies of the bulk of the code to handle long options.
53455         Now there is only one.
53457         This change temporarily removes the logic to avoid using alloca when
53458         standalone; the next patch in the series will restore it.
53460         * lib/getopt.c (process_long_option): New function split out
53461         from _getopt_internal_r.
53462         (_getopt_internal_r): Replace both copies of the long-option
53463         processing code with calls to process_long_option.
53466         getopt: tidy up _getopt_initialize a bit
53468         _getopt_data.__posixly_correct is completely redundant to
53469         _getopt_data.__ordering, and some work that logically belongs in
53470         _getopt_initialize was being done by _getopt_internal_r, making the
53471         code harder to understand.
53473         As a side effect, getenv will no longer be called if the first
53474         character of the options string is '+' or '-', which is probably a
53475         Good Thing.  (Perhaps we should have a flag character that
53476         specifically asks for the permutation behavior?)
53478         * lib/getopt_int.h (_getopt_data): Remove __posixly_correct field.
53479         * lib/getopt.c (_getopt_internal_r): Move some initialization code...
53480         (_getopt_initialize): ...here. Don't set d->__posixly_correct.
53483         getopt: merge from glibc: repetition reduction
53485         The definitions of the entry point functions 'getopt' and
53486         '__posix_getopt' can be made substantially less repetitive with a
53487         helper macro.
53489         While I was merging the const-correctness changes from gnulib into
53490         glibc I noticed there are still some unnecessary casts in
53491         _getopt_internal_r.
53493         * lib/getopt.c (getopt, __posix_getopt): Eliminate repetition with
53494         a macro.  Consistently cast 'argv' to 'char **' when calling
53495         _getopt_internal.
53496         (_getopt_internal_r): Remove unnecessary casts when calling exchange.
53499         getopt: clean up error reporting
53501         getopt can print a whole bunch of error messages, and when used
53502         standalone (from gnulib) it uses fprintf to do that.  But fprintf is a
53503         cancellation point and getopt isn't, and also applying fprintf to a
53504         stream in wide-character mode is not allowed.  So every single error
53505         reporting case has an #ifdef _LIBC block in which it calls internal
53506         libc functions instead.  The counterpart patch series in glibc makes
53507         it possible to simplify all of that down to a set of #defines at the
53508         top of the file; core code is written as if it is safe to just call
53509         fprintf, flockfile, and funlockfile.  (One caveat: it's *not* safe to
53510         call any *other* stdio functions.)
53512         * lib/getopt.c: When _LIBC is defined, define fprintf to
53513         __fxprintf_nocancel, flockfile to _IO_flockfile, and funlockfile
53514         to _IO_funlockfile.  When neither _LIBC nor
53515         _POSIX_THREAD_SAFE_FUNCTIONS is defined, define flockfile and
53516         funlockfile as no-ops.
53517         (_getopt_internal_r): Remove all internal #ifdef _LIBC blocks; the
53518         standalone error-printing code can now be used for libc as well.
53519         Add an flockfile/funlockfile pair around one case where the error
53520         message is printed in several chunks.  Don't use fputc.
53523         getopt: fix fencepost error in ambiguous-W-option handling
53525         getopt_long contains an undocumented (AFAICT) feature in which, if you
53526         put "W;" in the short-options list, then '-W foo' and '-Wfoo' are
53527         treated as equivalent to '--foo'.  This is implemented with a partial
53528         second copy of the code for handling long options, and that code
53529         increments optind one too many times when recovering from an ambiguous
53530         abbreviated option, which can cause the main loop to walk past the end
53531         of argv and crash.
53533         I discovered this while writing a test case that tries to exercise all
53534         of getopt's error reporting paths; I wouldn't be surprised to learn
53535         that this feature is never used by real applications.
53537         * lib/getopt.c (_getopt_internal_r): Don't increment
53538         d->optind a second time when reporting ambiguous -W options.
53541         getopt: clean up getopt.c and getopt1.c file headers
53543         In getopt.c, there is no need to include wchar.h at all, and it is
53544         safe nowadays to assume that stdlib.h does declare getenv (several
53545         other gnulib modules make this assumption).
53547         In getopt1.c, the #ifdef _LIBC block at the top can be simplified
53548         by using "" inclusions consistently, and there is no actual need to
53549         include stdlib.h (except in the #ifdef TEST block, where it should be
53550         unconditional), nor to provide a backup definition of NULL at all.
53552         * lib/getopt1.c: Simplify #ifdeffage at top of file.
53553         Move inclusion of stdlib.h to #ifdef TEST block and make
53554         unconditional.  Do not define NULL.
53555         * lib/getopt.c: Don't include wchar.h. No need to declare getenv.
53556         * m4/getopt.m4 (gl_PREREQ_GETENV): Delete.
53557         * modules/getopt-gnu, modules/getopt-posix: Don't call
53558         gl_PREREQ_GETENV.
53561         getopt: harmonize comments with glibc
53563         The comments explaining how the behavior of 'getopt' varies depending
53564         on whether it's the standalone version and whether there are special
53565         characters at the beginning of the options string were inconsistent
53566         between gnulib and glibc, and also out of sync with the code.
53568         * lib/getopt.c, lib/getopt_int.h: Harmonize comments with glibc.
53571         getopt: remove USE_NONOPTION_FLAGS
53573         getopt includes code to parse an environment variable named
53574         _XXX_GNU_nonoption_argv_flags_ (where XXX is the current process's PID
53575         in decimal); but all of it has been #ifdefed out since 2001, with no
53576         official way to turn it back on.
53578         According to commentary in glibc's config.h.in, bash version 2.0
53579         set this environment variable to indicate argv elements that were
53580         the result of glob expansion and therefore should not be treated
53581         as options, but the feature was "disabled later" because "it
53582         caused problems".  According to bash's CHANGES file, "later" was
53583         release 2.01; it gives no more detail about what the problems
53584         were.
53586         Version 2.0 of bash was released on the last day of 1996, and version
53587         2.01 in June of 1997.  Twenty years later, I think it is safe to
53588         assume that this environment variable isn't coming back.
53590         * lib/getopt_int.h: Remove all #ifdef USE_NONOPTION_FLAGS blocks.
53591         * lib/getopt.c: Likewise. Also remove SWAP_FLAGS and the
53592         __libc_argc and __libc_argv externs, which were only used by
53593         #ifdef USE_NONOPTION_FLAGS blocks.
53596         getopt: tabify, in preparation for merge with glibc
53598         glibc sticks to the GNU default of indenting with a mix of
53599         8-column tabs and spaces; make the gnulib copy match.
53601         getopt.h is not included because it is *not* going to be merged in its
53602         present form.
53604         * getopt.c, getopt1.c, getopt_int.h: Tabify.
53606 2017-04-02  Bruno Haible  <bruno@clisp.org>
53608         relocatable-lib-lgpl: Fix link error (regression from 2011-06-16).
53609         * modules/relocatable-lib-lgpl (configure.ac): Add AC_LIBOBJ invocation,
53610         like it was done in modules/relocatable-lib on 2011-05-21 and in
53611         modules/relocatable-prog on 2011-08-15.
53612         Reported by Reuben Thomas <rrt@sc3d.org>.
53614 2017-03-31  Bruno Haible  <bruno@clisp.org>
53616         glob: Fix invalid free() call.
53617         * lib/glob.c (glob): Reset malloc_home_dir when assigning a pointer to
53618         static storage to home_dir.
53619         Reported by Coverity via Tim Rühsen.
53621 2017-03-31  Bruno Haible  <bruno@clisp.org>
53623         glob: Fix memory leaks.
53624         * lib/glob.c (glob): Free allocated memory before returning.
53625         Reported by Coverity via Tim Rühsen.
53627 2017-03-31  Bruno Haible  <bruno@clisp.org>
53629         md5, sha1, sha256, sha512: Add comments regarding correctness.
53630         * lib/md5.h (buflen): Add comments regarding range.
53631         * lib/sha1.h (buflen): Likewise.
53632         * lib/sha256.h (buflen): Likewise.
53633         * lib/sha512.h (buflen): Likewise.
53634         * lib/md5.c (md5_process_bytes): Add comment why memmove is not needed.
53635         * lib/sha1.c (sha1_process_bytes): Likewise.
53636         * lib/sha256.c (sha256_process_bytes): Likewise.
53637         * lib/sha512.c (sha512_process_bytes): Likewise.
53638         Reported by Coverity via Tim Rühsen.
53640 2017-03-22  Paul Eggert  <eggert@cs.ucla.edu>
53642         getopt: merge from glibc
53643         This does not change anything substantial; it merely simplifies
53644         hypothetical merges back to glibc.
53645         * lib/getopt.c, lib/getopt.in.h, lib/getopt1.c, lib/getopt_int.h:
53646         Change copyright notice to match what is in glibc.
53647         * lib/getopt.c: Reorder includes to match glibc.  Remove uses of
53648         USE_IN_LIBIO.  Remove 'register'.  In __LIBC code, use
53649         __open_memstream rather than open_memstream and __glibc_likely
53650         instead of __builtin_expect.
53651         * lib/getopt.in.h (__posix_getopt) [!__GETOPT_PREFIX]: New decl.
53653 2017-03-21  Paul Eggert  <eggert@cs.ucla.edu>
53655         dfa: make [0-9] faster in non-C locales
53656         Problem reported by John P. Linderman (Bug#26193).
53657         * lib/dfa.c (parse_bracket_exp): Remove redundant assignment.
53658         If both ends of the range are ASCII digits, do not worry about
53659         multi-character collating sequences and the like.  Be consistent
53660         about using isalpha as a precondition for setbit_case_fold_c.
53662 2017-03-19  Bruno Haible  <bruno@clisp.org>
53664         lock: Fix compilation error with HP-UX IA64 cc.
53665         * lib/glthread/lock.h (pthread_rwlockattr_setkind_np): Don't declare
53666         weak on non-glibc platforms.
53668 2017-03-19  Paul Eggert  <eggert@cs.ucla.edu>
53670         stdalign: tweak version# and test for HP-UX IA64
53671         Problems reported by Bruno Haible in:
53672         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00078.html
53673         * lib/stdalign.in.h (_Alignas):
53674         * m4/stdalign.m4 (gl_STDALIGN_H):
53675         Use octal, not decimal, for __HP_cc version.  Perhaps HP formerly
53676         used octal (as that is how they document it), but it is decimal in
53677         practice now and the ancient implementations no longer matter.
53678         * tests/test-stdalign.c (main) [__HP_cc && __ia64]: Skip test.
53680 2017-03-19  Bruno Haible  <bruno@clisp.org>
53682         vma-iter: Add support for Solaris.
53683         * lib/vma-iter.c (vma_iterate): On Solaris, use the /proc filesystem
53684         approach.
53685         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on Solaris.
53686         * lib/get-rusage-as.c: Update comment about Solaris.
53687         * lib/get-rusage-data.c: Likewise.
53689 2017-03-19  Bruno Haible  <bruno@clisp.org>
53691         vma-iter: Prefer HP-UX specific API on HP-UX.
53692         * lib/vma-iter.c (vma_iterate): Move HP-UX specific implementation up.
53693         * lib/vma-iter.h: Update.
53694         Just in case HP-UX ever implements mquery().
53696 2017-03-18  Paul Eggert  <eggert@cs.ucla.edu>
53698         stdalign: restore previous behavior for HP-UX IA64
53699         See Bruno Haible's email in:
53700         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00066.html
53701         which cites p 150 of a manual saying that 'aligned' works on Itanium.
53702         * lib/stdalign.in.h (_Alignas):
53703         Assume the '061200' applies to Itanium, not to PA-RISC.
53704         * m4/stdalign.m4 (gl_STDALIGN_H): Adjust to match stdalign.in.h.
53706 2017-03-17  Bruno Haible  <bruno@clisp.org>
53708         stat-time, timespec: Support use of the header files in C++ mode.
53709         * lib/stat-time.h: Add "C" linkage declaration.
53710         * lib/timespec.h: Likewise.
53712 2017-03-17  Bruno Haible  <bruno@clisp.org>
53714         stdalign: Make it work with HP-UX cc.
53715         * lib/stdalign.in.h (_Alignas): Don't define for HP-UX cc.
53716         * m4/stdalign.m4 (gl_STDALIGN_H): No need to enable the extra test
53717         for HP-UX cc.
53719 2017-03-17  Paul Eggert  <eggert@cs.ucla.edu>
53721         flexmember: try to detect HP-UX 11.31 cc bug
53722         Problem reported by Bruno Haible in:
53723         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00066.html
53724         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
53725         Attempt to detect bug in HP-UX 11.31 cc.
53727 2017-03-16  Bruno Haible  <bruno@clisp.org>
53729         stdint: Fix test compilation failure with HP-UX 11 cc.
53730         * lib/stdint.in.h (_STDINT_MIN): Remove macro.
53731         (_STDINT_UNSIGNED_MIN, _STDINT_SIGNED_MIN): New macros.
53732         (PTRDIFF_MIN, SIG_ATOMIC_MIN, WCHAR_MIN, WINT_MIN): Define using
53733         _STDINT_UNSIGNED_MIN, _STDINT_SIGNED_MIN.
53735 2017-03-14  Bruno Haible  <bruno@clisp.org>
53737         gnulib-tool: Don't produce a tests directory with only snippet .h files.
53738         * gnulib-tool (func_modules_transitive_closure_separately): If
53739         testsrelated_modules ends up with no "real" modules, aside from
53740         modules with applicability 'all', set it to empty.
53742 2017-03-14  Bruno Haible  <bruno@clisp.org>
53744         vma-iter: Add support for HP-UX.
53745         * modules/vma-iter (configure.ac): Check for 'pstat_getprocvm'.
53746         * lib/vma-iter.c (vma_iterate): On HP-UX, use pstat_getprocvm().
53747         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on HP-UX.
53748         * lib/get-rusage-as.c: Update comment about HP-UX.
53749         * lib/get-rusage-data.c: Likewise.
53750         (get_rusage_data): Use get_rusage_data_via_setrlimit.
53752 2017-03-14  Bruno Haible  <bruno@clisp.org>
53754         limits-h: Make it work with HP-UX cc.
53755         * lib/limits.in.h (LLONG_MIN, LLONG_MAX, ULLONG_MAX): Define if not
53756         defined.
53758 2017-03-14  Bruno Haible  <bruno@clisp.org>
53760         Fix test failures on DragonFlyBSD.
53761         * tests/test-localeconv.c (main): Treat DragonFlyBSD like FreeBSD.
53762         * tests/test-select.h (test_bad_fd): Likewise.
53763         * tests/test-get-rusage-data.c (main): Treat DragonFlyBSD like OpenBSD.
53765 2017-03-14  Bruno Haible  <bruno@clisp.org>
53767         freadahead: Silence warning on DragonFlyBSD.
53768         * lib/freadahead.c (__sreadahead): Declare ourselves.
53770 2017-03-14  Bruno Haible  <bruno@clisp.org>
53772         vma-iter: Add comment about AIX.
53773         * lib/vma-iter.c: Add comment about why this module is not implemented
53774         on AIX.
53776 2017-03-14  Paul Eggert  <eggert@cs.ucla.edu>
53778         snippets: move unadjusted snippet sources to lib
53779         Problem reported by Michal Privoznik in:
53780         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00039.html
53781         * lib/_Noreturn.h: Rename from build-aux/snippet/_Noreturn.h.
53782         * lib/arg-nonnull.h: Rename from build-aux/snippet/arg-nonnull.h.
53783         * lib/c++defs.h: Rename from build-aux/snippet/c++defs.h.
53784         * lib/unused-parameter.h: Rename from
53785         build-aux/snippet/unused-parameter.h.
53786         * lib/warn-on-use.h: Rename from build-aux/snippet/warn-on-use.h.
53787         * modules/snippet/_Noreturn (Files:, _NORETURN_H):
53788         * modules/snippet/arg-nonnull (Files:, ARG_NONNULL_H):
53789         * modules/snippet/c++defs (Files:, CXXDEFS_H):
53790         * modules/snippet/unused-parameter (Files:, UNUSED_PARAMETER_H):
53791         * modules/snippet/warn-on-use (Files: WARN_ON_USE_H):
53792         Adjust to file renamings.
53794 2017-03-14  Mathieu Lirzin  <mthl@gnu.org>
53796         gnulib-tool: don't automatically distribute files from top/
53797         * gnulib-tool (func_get_automake_snippet_unconditional): To be able to
53798         not distribute top/README-release by default, don't distribute files
53799         from top/ unconditionally.
53800         * modules/gnumakefile (Makefile.am): Distribute top/GNUmakefile.
53801         * modules/maintainer-makefile (Makefile.am): Distribute top/maint.mk.
53803 2017-03-14  Paul Eggert  <eggert@cs.ucla.edu>
53805         gnulib-tool: fix typo in comment output
53806         * gnulib-tool (func_import): Fix typo with previous change.
53808         snippets: work around GNU Make 3.82 VPATH
53809         When using 'gnulib-tool --gnu-make' on Emacs, and building
53810         the resulting tarball on Solaris 10 which bundles GNU Make 3.82,
53811         an out-of-source (VPATH) build failed because the sans-copyright
53812         snippet file was not built before the file that used it.
53813         Presumably this is some sort of VPATH thing.  Work around the
53814         problem by using the original snippet, i.e., don’t bother to
53815         remove its copyright notice.
53816         * modules/snippet/_Noreturn, modules/snippet/link-warning:
53817         Don’t assume Automake in comments.  Omit long-incorrect comment.
53818         * modules/snippet/arg-nonnull (BUILT_SOURCES, arg-nonnull.h)
53819         (MOSTLYCLEANFILES):
53820         * modules/snippet/c++defs (BUILT_SOURCES, c++defs.h)
53821         (MOSTLYCLEANFILES):
53822         * modules/snippet/unused-parameter (BUILT_SOURCES, unused-parameter.h)
53823         (MOSTLYCLEANFILES):
53824         * modules/snippet/warn-on-use (BUILT_SOURCES, warn-on-use.h)
53825         (MOSTLYCLEANFILES):
53826         Remove.
53827         * modules/snippet/arg-nonnull (ARG_NONNULL_H):
53828         * modules/snippet/c++defs (CXXDEFS_H):
53829         * modules/snippet/unused-parameter (UNUSED_PARAMETER_H):
53830         * modules/snippet/warn-on-use (WARN_ON_USE_H):
53831         Don’t bother to remove the copyright notice; just use the
53832         original snippet as-is.
53834 2017-03-13  Paul Eggert  <eggert@cs.ucla.edu>
53836         gnulib-tool: minor --gnu-make fixups
53837         * gnulib-tool (func_emit_lib_Makefile_am):
53838         Remove useless code that was a blind alley during implementation.
53839         Problem reported by Thien-Thi Nguyen in:
53840         http://lists.gnu.org/r/bug-gnulib/2017-03/msg00029.html
53841         (func_import): Note the "--gnu-make" option in the output comment.
53843 2017-03-12  Paul Eggert  <eggert@cs.ucla.edu>
53845         gnulib-tool: new option --gnu-make
53846         This is for applications like GNU Emacs that use GNU Make
53847         features instead of Automake.
53848         * doc/gnulib-tool.texi (Initial import): Mention --gnu-make.
53849         * doc/gnulib.texi (Unit test modules, Build robot for gnulib):
53850         Do not assume Automake.
53851         * gnulib-tool (func_determine_path_separator)
53852         (func_modules_transitive_closure, func_update_file)
53853         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
53854         (func_import): Add support for --gnu-make.
53856 2017-03-11  Paul Eggert  <eggert@cs.ucla.edu>
53858         gnulib-common.m4: avoid aclocal.m4 bloat
53859         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB):
53860         Hide AM_PROG_AR from aclocal, so that aclocal does not
53861         install irrelevant macro definitions into aclocal.m4.
53863 2017-03-10  Bruno Haible  <bruno@clisp.org>
53865         vma-iter: Let callers know about error.
53866         * lib/vma-iter.h (vma_iterate): Return 'int', not 'void'.
53867         * lib/vma-iter.c (vma_iterate): Return -1 in case of error.
53869 2017-03-05  Bruno Haible  <bruno@clisp.org>
53871         Fix value of LD for 64-bit compilers on AIX.
53872         * m4/lib-ld.m4 (AC_LIB_PROG_LD): For 64-bit compilers on AIX
53873         ("gcc -maix64" and "xlc -q64"), add option -b64 to $LD.
53875 2017-03-04  Paul Eggert  <eggert@cs.ucla.edu>
53877         dtotimespec: simplify
53878         * lib/dtotimespec.c (dtotimespec): Simplify.
53880 2017-03-04  Bruno Haible  <bruno@clisp.org>
53882         test-calloc-gnu: Reenable test also for GCC 7.
53883         * tests/test-calloc-gnu.c (eight): New function.
53884         (main): Don't skip test; use eight() instead.
53886 2017-03-04  Jim Meyering  <meyering@fb.com>
53888         test-calloc-gnu: port to GCC7
53889         * tests/test-calloc-gnu.c (main) [__GNUC__ >= 7]: Skip a test
53890         that attempts to calloc more than SIZE_MAX bytes, because GCC7
53891         and newer would detect that at compilation time.
53893 2017-03-04  Bruno Haible  <bruno@clisp.org>
53895         tests: Avoid compiler warning about uses of null_ptr.
53896         * tests/null-ptr.h: New file.
53897         * tests/test-canonicalize.c: Include null-ptr.h.
53898         (null_ptr): Remove function.
53899         * tests/test-canonicalize-lgpl.c: Likewise.
53900         * tests/test-memmem.c: Likewise.
53901         * tests/test-ptsname_r.c: Likewise.
53902         * modules/canonicalize-tests (Files): Add tests/null-ptr.h.
53903         * modules/canonicalize-lgpl-tests: Likewise.
53904         * modules/memmem-tests: Likewise.
53905         * modules/ptsname_r-tests: Likewise.
53906         Reported by Jim Meyering.
53908 2017-03-03  Bruno Haible  <bruno@clisp.org>
53910         doc: Mention Mac OS X deficiencies regarding semaphores.
53911         * doc/posix-functions/sem_init.texi: Mention status on Mac OS X.
53912         * doc/posix-functions/sem_destroy.texi: Likewise.
53913         * doc/posix-functions/sem_getvalue.texi: Likewise.
53915 2017-03-03  Bruno Haible  <bruno@clisp.org>
53917         lock tests: Fix test failure on Mac OS X (regression from 2017-01-05).
53918         Reported by Assaf Gordon <assafgordon@gmail.com> via
53919         Pádraig Brady <P@draigBrady.com>.
53920         * tests/test-lock.c: On Mac OS X, use named semaphores, not unnamed
53921         semaphores.
53922         (USE_NAMED_SEMAPHORE, USE_UNNAMED_SEMAPHORE): New macros.
53923         (atomic_int_semaphore): New macro.
53925 2017-02-28  Bruno Haible  <bruno@clisp.org>
53927         perror tests: Tweak for z/OS.
53928         Reported by Daniel Richard G. <skunk@iskunk.org>.
53929         * tests/test-perror.sh: Don't fail z/OS style perror output.
53931 2017-02-26  Bruno Haible  <bruno@clisp.org>
53933         nproc: Refactor large function.
53934         * lib/nproc.c (num_processors_ignoring_omp): New function, extracted
53935         from num_processors.
53936         (num_processors): In this function, only deal with OMP.
53938 2017-02-26  Pádraig Brady  <P@draigBrady.com>
53940         nproc: adjust handling of OpenMP environment variables
53941         to match the return value from omp_get_num_threads(), i.e.:
53942          - honor OMP_THREAD_LIMIT without OMP_NUM_THREADS
53943          - Treat 0 as an invalid value and ignore
53944         Also remove the call to omp_get_num_threads() because
53945         it's ineffective without the omp pragmas in place.
53946         * lib/nproc.c (parse_omp_threads): Return 0 if specified,
53947         so that it can be ignored.
53948         (num_processors): Honor OMP_THREAD_LIMIT even without
53949         OMP_NUM_THREADS being set.  Also fix a typo in the environment
53950         variable being checked, from the previous recent commit.
53952 2017-02-26  Pádraig Brady  <P@draigBrady.com>
53954         nproc: support nested OMP_NUM_THREADS, and OMP_THREAD_LIMIT
53955         * lib/nproc.c (parse_omp_threads): A new function refactored
53956         from num_processors() to support parsing both of the
53957         above environment variables.
53958         (num_processors): Prefer using omp_get_num_threads() with [_OPENMP]
53959         to accurately reflect the current OpenMP nesting level.
53960         Also support the OMP_THREAD_LIMIT environment variable
53961         to limit the max value determined from OMP_NUM_THREADS.
53962         * modules/nproc: Depend on minmax header.
53963         Suggested by Oliver Heimlich.
53965 2017-02-25  Bruno Haible  <bruno@clisp.org>
53967         maintainer-makefile: Fix AC_PROG_SED with autoconf cache.
53968         * m4/gnulib-common.m4 (AC_PROG_SED): Fix AC_CACHE_CHECK invocation.
53970 2017-02-24  Paul Eggert  <eggert@cs.ucla.edu>
53972         ftoastr: port to -Wdouble-promotion
53973         Work around -Wdouble-promotion false alarm in recent GCCs.
53974         * lib/ftoastr.c (PROMOTED_FLOAT): New macro.
53975         (ftoastr_snprintf, FTOASTR): Use it.
53977 2017-02-21  Bruno Haible  <bruno@clisp.org>
53979         lock tests: Fix build failure on GNU/Hurd (regression from 2017-01-05).
53980         Reported by Rene Saavedra <rennes@openmailbox.org> in
53981         https://debbugs.gnu.org/cgi/bugreport.cgi?bug=25821 via Paul Eggert.
53982         * lib/glthread/lock.h: On glibc systems without
53983         PTHREAD_RWLOCK_WRITER_NONRECURSIVE_INITIALIZER_NP, use the fallback
53984         implementation of rwlocks.
53985         * lib/glthread/lock.c: Likewise.
53987 2017-02-20  Bruno Haible  <bruno@clisp.org>
53989         lock tests: Fix build failure on z/OS.
53990         Reported by Daniel Richard G. <skunk@iskunk.org>.
53991         * modules/lock-tests (configure.ac): Test for <semaphore.h>.
53992         * tests/test-lock.c (USE_SEMAPHORE): Don't set if <semaphore.h> does not
53993         exist.
53995 2017-02-19  Bruno Haible  <bruno@clisp.org>
53997         havelib: Prefer the search path of /usr/bin/gcc over the one of $CC.
53998         This helps when CC=clang.
53999         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Prefer the search path
54000         of /usr/bin/gcc.
54002         havelib: Support overriding the result of AC_LIB_PREPARE_MULTILIB.
54003         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Use AC_CACHE_CHECK.
54005 2017-02-19  Bruno Haible  <bruno@clisp.org>
54007         gnulib-tool: Avoid conflict of havelib-tests with --single-configure.
54008         * gnulib_tool (func_create_testdir): Avoid havelib-tests when
54009         --with-tests --single-configure is specified.
54011 2017-02-16  Tim Rühsen  <tim.ruehsen@gmx.de>
54013         users.txt: Update links, use HTTPS where possible
54014         * users.txt: Updated to HTTPS where possible,
54015         fixed some links to new locations.
54017 2017-02-16  Bruno Haible  <bruno@clisp.org>
54019         xbinary-io: Fix inlining.
54020         * lib/xbinary-io.c: Set XBINARY_IO_INLINE, not XSETMODE_INLINE.
54022 2017-02-16  Paul Eggert  <eggert@cs.ucla.edu>
54024         xbinary-io: rename from xsetmode
54025         This patch is taken from suggestions by Bruno Haible in:
54026         http://lists.gnu.org/r/bug-gnulib/2017-02/msg00060.html
54027         http://lists.gnu.org/r/bug-gnulib/2017-02/msg00061.html
54028         * lib/binary-io.c (__gl_setmode_check): Set errno to EINVAL,
54029         not ENOTTY, when it is an inappropriate device.
54030         * lib/binary-io.h (SET_BINARY): Resurrect.
54031         * lib/xbinary-io.c: Rename from lib/xsetmode.c.
54032         (xset_binary_mode_error): Rename from xsetmode_error.
54033         * lib/xbinary-io.h: Rename from lib/xsetmode.h.
54034         (xset_binary_mode): Rename from xsetmode.
54035         All uses changed.
54036         * modules/xbinary-io: Rename from modules/xsetmode.
54037         Update file names.
54038         * tests/test-binary-io.sh (tmpfiles): Remove no-longer-used file name.
54039         * NEWS: Update to match revised behavior.
54041 2017-02-15  Paul Eggert  <eggert@cs.ucla.edu>
54043         tests: Adjust to recent SET_BINARY change
54044         * tests/test-binary-io.c (main):
54045         * tests/test-binary-io.sh: Remove test for SET_BINARY.
54046         * tests/test-closein.c, tests/test-fflush2.c, tests/test-ftell.c:
54047         * tests/test-ftello.c, tests/test-nonblocking-pipe-child.c:
54048         * tests/test-yesno.c: Use set_binary_mode, not SET_BINARY.
54050         xsetmode: new module
54051         This is to fix a problem noted by Eric Blake.
54052         Code was using xfreopen to change files to binary mode, but this
54053         fails for stdout when in append mode.  Such code should use
54054         xsetmode instead.
54055         * NEWS: Document incompatible changes to binary-io module.
54056         * lib/binary-io.c (__gl_setmode_check) [__DJGPP__ || __EMX__]:
54057         New function.
54058         * lib/binary-io.h (__gl_setmode): Rename from set_binary_mode.
54059         (set_binary_mode): New function, which also checks for tty.
54060         * lib/xsetmode.c, lib/xsetmode.h, modules/xsetmode: New files.
54062 2017-02-14  Paul Eggert  <eggert@cs.ucla.edu>
54064         headers: fix begin-end typos
54065         * lib/mbfile.h, lib/se-selinux.in.h: Fix typos by replacing
54066         _GL_INLINE_HEADER_BEGIN with _GL_INLINE_HEADER_END.
54068         selinux-h: port to PGI 16.10
54069         * lib/se-selinux.in.h: Don't assume that include_next skips over
54070         duplicate -I DIR options.
54072         argp: port to PGI 16.10
54073         * lib/argp-pin.c (dummy): Declare as needed to make file nonempty.
54075 2017-02-13  Darshit Shah  <darnir@gnu.org>
54077         unicase: Update function protoype to match definition.
54078         * lib/unicase/special-casing.h (gl_unicase_special_lookup): Gperf 3.1
54079         uses 'size_t' as the datatype for the 'len' parameter in the functions
54080         it generates. Update the prototype specified here to match the newly
54081         generated function.
54083 2017-02-12  Bruno Haible  <bruno@clisp.org>
54085         times test: Avoid gcc warnings on Linux/x32.
54086         * tests/test-times.c (main): Really cast printf arguments from clock_t
54087         to 'long int'.
54089 2017-02-12  Paul Eggert  <eggert@cs.ucla.edu>
54091         glob: port better to emscripten
54092         Problem reported by Bruno Haible in:
54093         http://lists.gnu.org/r/bug-gnulib/2017-02/msg00031.html
54094         * lib/glob.c (glob): Don't assume HAVE_GETPWNAM_R || _LIBC.
54096 2017-02-11  Bruno Haible  <bruno@clisp.org>
54098         host-cpu-c-abi: Support for 64-bit AIX, 32-bit armhf on arm64, hppa64.
54099         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Define also HOST_CPU.
54100         For the x32 ABI on x86_64, set HOST_CPU_C_ABI to 'x86_64-x32' and define
54101         both __x86_64__ and __x86_64_x32__. For the ELFv2 ABI on powerpc64,
54102         define both __powerpc64__ and __powerpc64_elfv2__. Recognize 64-bit
54103         compilation on AIX. Recognize 32-bit compilation on arm64/Linux.
54104         Distinguish hppa64 from hppa.
54106 2017-02-10  Bruno Haible  <bruno@clisp.org>
54108         search: Don't assume that tsearch() exists if 'VISIT' is defined.
54109         * m4/search_h.m4 (gl_SEARCH_H): Determine HAVE_TYPE_VISIT.
54110         * modules/search (Makefile.am): Substitute HAVE_TYPE_VISIT.
54111         * lib/search.in.h (VISIT): Define if HAVE_TYPE_VISIT is 0.
54113 2017-02-09  Bruno Haible  <bruno@clisp.org>
54115         doc: Don't mention obsolete AC_LIBTOOL_WIN32_DLL macro.
54116         * doc/gnulib.texi (Libtool and Windows): Recommend
54117         LT_INIT([win32-dll]) instead of AC_LIBTOOL_WIN32_DLL.
54118         Reported by Reuben Thomas <rrt@sc3d.org>.
54120 2017-02-08  Paul Eggert  <eggert@cs.ucla.edu>
54122         stddef-tests: port to SIZE_MAX <= INT_MAX
54123         * tests/test-stddef.c: Include <limits.h>, for INT_MAX.
54124         Do not assume that INT_MAX < SIZE_MAX.
54126 2017-02-01  Bruno Haible  <bruno@clisp.org>
54128         lock tests: Fix link error.
54129         * modules/lock-tests (test_rwlock1_LDADD): Add @YIELD_LIB@.
54130         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
54132 2017-01-31  Bruno Haible  <bruno@clisp.org>
54134         lock: Fix link error (regression from 2017-01-05).
54135         * lib/glthread/lock.h [USE_POSIX_THREADS_WEAK]: Declare also
54136         pthread_rwlockattr_init, pthread_rwlockattr_setkind_np,
54137         pthread_rwlockattr_destroy weak.
54138         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
54140 2017-01-30  Paul Eggert  <eggert@cs.ucla.edu>
54142         Port to PGI 16.10 x86-64
54143         This patch fixes one real bug in gl_anylinked_list2.h, along with
54144         some minor glitches that are not bugs.  It does not silence PGI’s
54145         thousands of bogus warnings when compiling test-intprops.c.
54146         Fortunately, the warnings do not cause a failure.
54147         * lib/c-ctype.h (_C_CTYPE_LOWER_A_THRU_F_N, _C_CTYPE_LOWER_N):
54148         Rename parameter to avoid PGI warning about ‘#define f(n) 'n'’.
54149         My goodness, PGI goes back a long ways - this predates C89!
54150         * lib/gl_anylinked_list2.h (ASYNCSAFE): Fix bug caught by PGI.
54151         For example, ASYNCSAFE (const void *) should expand to
54152         ‘const void *volatile’, not to ‘volatile const void *’.
54153         * lib/spawn.in.h (POSIX_SPAWN_USEVFORK): Don't define if already defined.
54154         * lib/verify.h (verify) [!__GNUC__]:
54155         Use shorter albeit meaningless string to bypass silly compiler limits.
54156         * tests/infinity.h (Infinityf, Infinityd, Infinityl) [__PGI]:
54157         * tests/nan.h (NaNf, NaNd, NaNl):
54158         Use static functions to avoid misguided compiler diagnostics.
54159         Is there some reason we don’t use static functions on all platforms?
54161 2017-01-20  Paul Eggert  <eggert@cs.ucla.edu>
54163         parse-datetime: handle timezones reentrantly
54164         This API change was prompted by a report by Pádraig Brady in:
54165         https://bug.debian.org/851934#10
54166         To help fix the bug, make parse_datetime2 more reentrant.
54167         * NEWS: Document this incompatible change.
54168         * lib/parse-datetime.h, lib/parse-datetime.y (parse_datetime2):
54169         Add two arguments, the timezone and the timezone name.
54170         All callers changed.  If TZ="..." is specified, use it for
54171         calculating defaults.
54172         * lib/parse-datetime.y: Don't include xalloc.h or use xmalloc, as
54173         this code should be usable in a library.
54174         (mktime_ok, get_effective_timezone):
54175         Accept timezone arg too.  All callers changed.
54176         (get_tz): Remove.
54177         (get_effective_timezone): Check for failures.
54179 2017-01-20  Eric Blake  <eblake@redhat.com>
54181         localename: port to cygwin 2.6
54182         * lib/localename.c (gl_locale_name_thread_unsafe): Add clause for
54183         Cygwin.
54184         * modules/localename (Depends-on): Add extensions, since
54185         NL_LOCALE_NAME() is not visible without it.
54187 2017-01-17  Pádraig Brady  <P@draigBrady.com>
54189         parse-datetime: fix dependence on AC_PROG_SED
54190         * modules/parse-datetime: Use `sed` directly like all other modules.
54191         Reported by J William Piggott
54193 2017-01-16  Paul Eggert  <eggert@cs.ucla.edu>
54195         intprops: update doc URLs
54196         * doc/intprops.texi (Integer Range Overflow): Update URLs.
54198 2017-01-16  Bruno Haible  <bruno@clisp.org>
54200         host-cpu-c-abi: Add support for armhf, arm64, x32, s390x.
54201         * m4/host-cpu-c-abi.m4 (gl_HOST_CPU_C_ABI): Require gl_C_ASM. On x86_64
54202         systems, distinguish x86_64 and x32. On arm systems, distinguish arm,
54203         armhf, arm64, and no longer distinguish arm and armel. On s390x systems,
54204         distinguish s390 and s390x.
54205         * modules/host-cpu-c-abi (Files): Add m4/asm-underscore.m4.
54206         * NEWS: Mention the change regarding 'armel'.
54208 2017-01-15  Paul Eggert  <eggert@cs.ucla.edu>
54210         localeinfo: case_folded_counterparts and WEOF
54211         * NEWS: Document this.
54212         * lib/localeinfo.c (case_folded_counterparts):
54213         First arg is now wint_t, not wchar_t.  This generalizes the
54214         function to also work on WEOF, where it returns 0.
54216         dfa: port to gcc -fsanitize=undefined
54217         * lib/dfa.c (copy): Don’t pass NULL with size 0 to memcpy,
54218         as this runs afoul of gcc -fsanitize=undefined.
54220 2017-01-14  Paul Eggert  <eggert@cs.ucla.edu>
54222         strftime: %z is -00 if unknown
54223         * lib/strftime.c (DO_TZ_OFFSET): Omit arg 'negative'; it's now
54224         the caller's responsibility to set 'negative_number'.  All uses changed.
54225         (__strftime_internal): Put '-' before a zero UTC offset if the time
54226         zone abbreviation starts with "-", which is the recently-introduced
54227         tzdb convention for an unknown UTC offset that is arbitrarily set to 0.
54228         * tests/test-strftime.c: Test for this.
54230 2017-01-10  Paul Eggert  <eggert@cs.ucla.edu>
54232         dfa: port to older GCC
54233         Problem reported by Assaf Gordon in:
54234         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00103.html
54235         * modules/c99: New module.  This merely attempts to use the latest
54236         C version, which should be enough to solve this particular problem.
54237         The idea is to document which Gnulib modules assume C99 or later.
54238         * modules/dfa (Depends-on): Add it.
54240 2017-01-10  Bruno Haible  <bruno@clisp.org>
54242         Update DEPENDENCIES.
54243         * DEPENDENCIES: List only https URLs. Update recommended version for
54244         autoconf, automake, gperf.
54246 2017-01-10  Jim Meyering  <meyering@fb.com>
54248         maint.mk: enforce spelling of "timestamp" (i.e., no space)
54249         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Also
54250         disallow /\btime\s+stamps?\b/.  Prefer "timestamp".
54252 2017-01-10  Paul Eggert  <eggert@cs.ucla.edu>
54254         dfa: minor simplification with emptyset
54255         * lib/dfa.c (build_state): Simplify by using emptyset.
54257 2017-01-09  Paul Eggert  <eggert@cs.ucla.edu>
54259         dfa: shrink constraints from 4 bits to 3
54260         * lib/dfa.c (newline_constraint, letter_constraint)
54261         (other_constraint, prev_newline_dependent)
54262         (prev_letter_dependent, NO_CONSTRAINT, BEGLINE_CONSTRAINT)
54263         (ENDLINE_CONSTRAINT, BEGWORD_CONSTRAINT, ENDWORD_CONSTRAINT)
54264         (LIMWORD_CONSTRAINT, NOTLIMWORD_CONSTRAINT):
54265         Constraints need only 3 bits, not 4.  Using smaller integers
54266         shrinks the code a bit and makes grep a tad faster on x86-64.
54268         dfa: omit unnecessary ptrdiff_t check
54269         * lib/dfa.c (alloc_position_set): Do not worry about ptrdiff_t
54270         overflow, since xnmalloc does that now.
54272         dfa: omit unnecessary allocation
54273         * lib/dfa.c (dfaanalyze): Do not allocate follow set, since
54274         an all-zero follow set works just fine.
54276         dfa: omit unused local
54277         * lib/dfa.c (build_state): Fix up recent change.
54279         maint: remove stray .texi files
54280         Although these were superseded by other files like
54281         doc/posix-functions/ctime.texi, the old files were not removed.
54282         * doc/ctime.texi, doc/inet_ntoa.texi: Remove.
54284 2017-01-08  Paul Eggert  <eggert@cs.ucla.edu>
54286         getprogname: fix port to IRIX
54287         * lib/getprogname.c (getprogname) [__sgi]:
54288         Don't dump core if malloc returns NULL.
54290         dfa: fix reallocation bug when matching newlines
54291         Problem reported for sed by S. Gilles (Bug#25390).
54292         * lib/dfa.c (realloc_trans_if_necessary): Move earlier.
54293         (dfastate): Reallocate before moving any newline transition ...
54294         (build_state): ... instead of reallocating here, where it is too late.
54296 2017-01-07  Tim Rühsen  <tim.ruehsen@gmx.de>  (tiny change)
54298         Avoid -Wundef warning about undefined WINDOWS_SOCKETS.
54299         * lib/sockets.h: Test if WINDOWS_SOCKETS is defined.
54301 2017-01-07  Tim Rühsen  <tim.ruehsen@gmx.de>  (tiny change)
54303         Avoid -Wundef warning about undefined __USE_FILE_OFFSET64.
54304         * lib/glob-libc.h: Test if __USE_FILE_OFFSET64 is defined.
54306 2017-01-07  Bruno Haible  <bruno@clisp.org>
54308         stdioext: Port to Minix 3.2 and newer.
54309         * lib/stdio-impl.h: Treat __minix like the newest NetBSD.
54310         * lib/fseeko.c (fseeko): Likewise.
54311         Reported by Nelson Beebe via Paul Eggert.
54313 2017-01-06  Paul Eggert  <eggert@cs.ucla.edu>
54315         getprogname: port to IRIX
54316         * lib/getprogname.c (getprogname): Port to IRIX.
54317         Based on an idea by Bastien Roucariès at:
54318         http://lists.gnu.org/r/bug-gnulib/2010-12/msg00096.html
54319         via code from Bruno Haible at:
54320         https://lists.gnu.org/r/bug-gnulib/2010-12/msg00249.html
54322         localename-tests: port to NetBSD 7
54323         Problem reported by Nelson H. F. Beebe.
54324         * tests/test-localename.c:
54325         Test newlocale and uselocale only if both exist.
54327         glob, intprops, xalloc: work around Clang bug
54328         Work around LLVM bug 16404, which is still not fixed.
54329         https://llvm.org/bugs/show_bug.cgi?id=16404
54330         Problem reported by Nelson H. F. Beebe.
54331         * lib/glob.c, lib/intprops.h, lib/xalloc-oversized.h (__has_builtin):
54332         Remove.
54333         * lib/glob.c (size_add_wrapv):
54334         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW, _GL_HAS_BUILTIN_OVERFLOW_P):
54335         * lib/xalloc-oversized.h (xalloc_oversized):
54336         Do not use overflow builtins if Clang.
54338         dfa: fix 'return' typo
54339         Problem reported by Nelson H. F. Beebe.
54340         * lib/dfa.c (merge): Fix typo that Sun compilers rejected.
54342 2017-01-05  Pádraig Brady  <P@draigBrady.com>
54344         parse-datetime: fix generated paths for coverage files
54345         * modules/parse-datetime: Adjust the paths for parse-datetime.y
54346         within parse-datetime.c, so that gcc generates appropriate .gcno
54347         files, allowing lcov to proceed without error.  Previously it
54348         would error trying to find "lib/lib/parse-datetime.y".
54350 2017-01-05  Pádraig Brady  <P@draigBrady.com>
54352         maint.mk: support parallel execution of coverage
54353         * top/maint.mk (coverage): Run dependencies serially,
54354         thus supporting parallel processing of each one,
54355         particularly build-coverage, which builds and runs tests.
54357 2017-01-05  Bruno Haible  <bruno@clisp.org>
54359         lock tests: Prefer semaphore over mutex.
54360         * tests/test-lock.c (USE_SEMAPHORE): New constant.
54361         (struct atomic_int, init_atomic_int, get_atomic_int_value,
54362         set_atomic_int_value) [USE_SEMAPHORE]: Define using a POSIX semaphore.
54363         Suggested by Torvald Riegel <triegel@redhat.com>.
54365 2017-01-05  Bruno Haible  <bruno@clisp.org>
54367         lock: Provide guarantee to avoid writer starvation for rwlocks.
54368         The rationale is: 1) Read-preferring read-write locks are prone to
54369         writer starvation if the number of reader threads multiplied by the
54370         percentage of time they have the lock held is too high. 2) Write-
54371         preferring read-write locks are the only reliable way to avoid this.
54372         3) There have been reports of 'test-lock' hanging on glibc systems
54373         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00009.html,
54374         and glibc indeed implements read-preferring rwlocks by default, see
54375         http://man7.org/linux/man-pages/man3/pthread_rwlockattr_setkind_np.3.html
54376         and https://sourceware.org/bugzilla/show_bug.cgi?id=13701 .
54377         * m4/pthread_rwlock_rdlock.m4: New file.
54378         * m4/lock.m4 (gl_LOCK): Invoke gl_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER.
54379         * lib/glthread/lock.h [USE_POSIX_THREADS]: Test
54380         HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER. Use a different implementation
54381         of rwlock initialization on glibc systems without
54382         HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER. Use a different implementation
54383         of rwlocks altogether on non-glibc systems without
54384         HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER.
54385         [USE_PTH_THREADS]: Use a different implementation of rwlocks altogether.
54386         * lib/glthread/lock.c [USE_POSIX_THREADS]
54387         (glthread_rwlock_init_for_glibc): New function.
54388         [USE_POSIX_THREADS] (glthread_rwlock_rdlock_multithreaded): Update
54389         comment.
54390         [USE_PTH_THREADS]: New implementation of rwlocks.
54391         [USE_WINDOWS_THREADS] (glthread_rwlock_rdlock_func): Prefer writers over
54392         readers.
54393         * modules/lock (Files): Add m4/pthread_rwlock_rdlock.m4.
54394         (Depends-on): Add 'extensions'.
54395         * tests/test-rwlock1.c: New file.
54396         * lock-tests (Files): Add it.
54397         (Depends-on): Add usleep.
54398         (Makefile.am): Add test-rwlock1 to the tests.
54400 2017-01-05  Bruno Haible  <bruno@clisp.org>
54402         thread: Fix pth port.
54403         * lib/glthread/thread.h (pth_init): Declare weak.
54404         (glthread_create, glthread_sigmask, glthread_join, gl_thread_self,
54405         gl_thread_exit): Make sure Pth is initialized before invoking any Pth
54406         function.
54408 2017-01-04  Assaf Gordon  <assafgordon@gmail.com>
54410         parse-datetime: fix debug message on lone year number
54411         Input dates such as
54412           date -d "Apr 11 22:59:00 2011"
54413         are parsed as date (Apr 11, with default year 2016), then time, then a
54414         number (2011). Based on the combination of previously seen tokens,
54415         'digits_to_date_time' determines 2011 to be a year value.
54416         This fixes the debug messages to correctly show the updated year.
54417         Before:
54418             $ date --debug -d 'Apr 11 22:59:00 2011'
54419             date: parsed date part: (Y-M-D) 2016-04-11
54420             date: parsed time part: 22:59:00
54421             date: parsed number part: today/this/now
54422         After:
54423             $ ./src/date --debug -d 'Apr 11 22:59:00 2011'
54424             date: parsed date part: (Y-M-D) 2016-04-11
54425             date: parsed time part: 22:59:00
54426             date: parsed number part: year: 2011
54427         * lib/parse-datetime.y (struct parser_control): Add 'year_seen',
54428         'debug_year_seen' member fields.
54429         (digits_to_date_time): Update 'year_seen' as needed.
54430         (debug_print_current_time): Inform about year updates.
54431         (parse_datetime2): Initialize year_seen,debug_year_seen member fields.
54433         parse-datetime: fix local timezone debug messages
54434         "Local timezones" are strings that affect only DST relative to the
54435         default timezone. The debug messages in parse-datetime.y printed
54436         wrong information when encountering local timezones.
54437         Examples:
54438         Here EET/EEST are time zones ('zone' token, with values +02:00/+03:00):
54439              TZ=Asia/Tokyo ./src/date --debug -d '2011-12-11 EET'
54440              TZ=Asia/Tokyo ./src/date --debug -d '2011-06-11 EEST'
54441         When the default timezone relates to the zone strings, EET/EEST are
54442         parsed as local timezones (tLOCAL_ZONE), and only change the DST
54443         value (0/1, respectively):
54444              TZ=Europe/Helsinki ./src/date --debug -d '2011-12-11 EET'
54445              TZ=Europe/Helsinki ./src/date --debug -d '2011-06-11 EEST'
54446         * lib/parse-datetime.y (debug_print_current_time): If local timezone
54447         was seen, inform about DST change, don't print actual timezone.
54448         (debug_strfdatetime): If local timezone was seen, use default timezone
54449         (and adjust as needed) instead of using incorrect timezone.
54450         (parse_datetime2): Use correct time-zone source string, and adjust
54451         default timezone as needed.
54453         parse-datetime: add debug warning about DST changes
54454         Incorrect date arithmetic due to daylight saving time (DST) are a
54455         common (false) bug report in coreutils.
54456         Detect two such cases and print a warning:
54457         1. year/month/day adjustments (performed on 'struct tm'),
54458            where 'mktime' returns a different isdst value.
54459         2. hour/minute/seconds/ns adjustments (performed on 'time_t'),
54460            where the result of 'localtime(3)' on the value will return a
54461            different isdst value.
54462         Note: DST changes could be harmless or unnoticeable.
54463         Examples (with 'TZ=America/New_York'):
54464         Unnoticeable: result is 2016-Dec-14
54465            $ date -d '2016-06-15 EDT + 6 months' +%b
54466            Dec
54467         Unnoticeable: result is 2016-Dec-15 11:00:00
54468            $ date -d '2016-06-15 12:00:00 EDT + 6 months' +%F
54469            2016-12-15
54470         This is unexpected:
54471            $ date -d '2016-06-01 EDT + 6 months' +%F
54472            2016-11-30
54473         The new debug warnings will show:
54474            $ ./src/date --debug -d '2016-06-01 EDT + 6 months' +%F
54475            ...
54476            date: warning: daylight saving time changed after date adjustment
54477            ...
54478         * lib/parse-datetime.y (parse_datetime2): Detect DST changes, and
54479         print an appropriate warning message.
54481         parse-datetime: add debug warning about date arithmetic
54482         Date arithmetic are done directly on the fields of 'struct tm',
54483         which can result in invalid dates. Normalization with 'mktime(3)'
54484         will then produce a different date - which might cause unexpected
54485         results.
54486         Examples:
54487           '2016-10-31 - 1 month' => 2016-09-31 normalized to 2016-10-01.
54488           '2016-02-29 + 1 year'  => 2017-02-29 normalized to 2017-03-01.
54489         Note that date normalization is not inherently wrong and not rejected,
54490         as it has legitimate uses:
54491           '2016-12-29 + 5 days' => 2016-12-34 noramlized to 2017-01-03.
54492         If the user asked to adjust months but 'mday' changed,
54493         or user asked to adjust years but 'month' changed - warn about it.
54494             $ ./src/date --debug -d '2016-10-31 - 1 month'
54495             ...
54496             date: warning: when adding relative months/years, \
54497                            it is recommended to specify the 15th of the month
54498             ...
54499             date: warning: month/year adjustment resulted in shifted dates:
54500             date:      adjusted Y M D: 2016 09 31
54501             date:    normalized Y M D: 2010 10 01
54502             ...
54503         * lib/parse-datetime.y (parse_datetime2): Detect such cases and print
54504         a warning message. Improve recommendation of when to use 15 of the
54505         month or noon for date arithmetic.
54507         parse-datetime: fix debug message of relative part after timezone
54508         Relative part (e.g '+8 days') after a timezone string was not
54509         reported (was only reported after a timezone number). Due to the
54510         parser's structure, timezone strings with numbers were handled
54511         separately.
54512         before:
54513              # Timezone number + relative part: OK
54514              $ ./src/date --debug +%F -d '2013-10-30 00:00:00 +00:00 -8 days'
54515              ...
54516              date: parsed relative part: -8 day(s)
54517              # Timezone string + relative part: missing
54518              $ ./src/date --debug +%F -d '2013-10-30 00:00:00 UTC -8 days'
54519              [ missing message ]
54520         After: messages are printed in both cases.
54521         * lib/parse-datetime.y ('zone' token): Call debug_print_relative_time.
54523         parse-datetime: fix incorrect debug message on lone number
54524         A lone number is an absolute value, not a relative time part.
54525         before:
54526            $ date --debug -d '20130101'
54527            date: parsed number part: today/this/now
54528         After:
54529            $ ./src/date --debug -d '20130101'
54530            date: parsed number part: (Y-M-D) 2013-01-01
54531         * lib/parse-datetime.y ('item'/'number' tokens): Call
54532         'debug_print_current_time' instead of 'debug_print_relative_time'.
54534 2017-01-02  Paul Eggert  <eggert@cs.ucla.edu>
54536         doc: modernize for C11 etc.
54537         * doc/gnulib-readme.texi (Portability guidelines): Modernize a bit
54538         for C11, MinGW, etc.  This responds to Paul Smith's question in:
54539         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00014.html
54541         dfa: prefer functions to FETCH_WC macro
54542         * lib/dfa.c (FETCH_WC): Remove, replacing with ...
54543         (fetch_wc, bracket_fetch_wc): ... new functions.  These store the
54544         wint_t result into DFA->lex.wctok instead of to a separate arg.
54545         All callers changed.  Move more local decls closer to where
54546         they're used.
54548         dfa: narrow more local var scopes
54549         * lib/dfa.c: Move more local decls to be more local.
54551         dfa: remove duplicate assignment
54552         Problem reported by Bruno Haible in:
54553         http://lists.gnu.org/r/bug-gnulib/2017-01/msg00007.html
54554         * lib/dfa.c (parse_bracket_exp): Simplify.
54556 2017-01-01  Paul Eggert  <eggert@cs.ucla.edu>
54558         dfa: simplify constraint-dependency checking
54559         * lib/dfa.c (prev_newline_constraint, prev_letter_constraint)
54560         (prev_other_constraint): Remove.
54561         (prev_newline_dependent, prev_letter_dependent):
54562         Simplify, to avoid an unnecessary bitwise AND operation.
54564         dfa: prefer functions and constants to macros
54565         * lib/dfa.c: Prefer constants to macros where either will do.
54566         (streq, isasciidigit, newline_constraint)
54567         (letter_constraint, other_constraint, succeeds_in_context)
54568         (prev_newline_constraint, prev_letter_constraint)
54569         (prev_other_constraint, prev_newline_dependent)
54570         (prev_letter_dependent, accepting, accepts_in_context):
54571         Now static functions instead of function-like macros.
54572         Use lower-case names accordingly.  All uses changed.
54574         dfa: narrow more local var scopes
54575         * lib/dfa.c: Move some more local decls down to nearer where
54576         they're needed.
54578 2016-12-31  Jim Meyering  <meyering@fb.com>
54580         dfa: narrow the scope of many local variables
54581         * lib/dfa.c: Now that we are no longer constrained to c89, move
54582         declarations of many variables (often indices) "down" into the
54583         scope(s) where used or to the point of definition.  This is a
54584         no-semantic-change diff.
54586 2017-01-01  Paul Eggert  <eggert@cs.ucla.edu>
54588         version-etc: new year
54589         * build-aux/gendocs.sh (version):
54590         * doc/gendocs_template:
54591         * doc/gendocs_template_min:
54592         * doc/gnulib.texi:
54593         * lib/version-etc.c (COPYRIGHT_YEAR):
54594         Update copyright dates by hand in templates and the like.
54595         * all files: Run 'make update-copyright'.
54597 2016-12-31  Eric Blake  <eblake@redhat.com>
54599         do-release-commit-and-tag: avoid shell syntax error
54600         * build-aux/do-release-commit-and-tag (curr_br): $branch can
54601         contain spaces when rebasing.
54603         maint.mk: hoist gnulib_dir definition earlier
54604         * top/maint.mk (gnulib_dir): Move near top of file.
54606 2016-12-31  Jim Meyering  <meyering@fb.com>
54608         maint.mk: do not always evaluate intprops-related shell
54609         * top/maint.mk (_intprops_names): Change := to just "=" to avoid
54610         using gnulib_dir undefined (gnulib_dir is defined later in the
54611         file, which will be fixed separately), and besides, there is no
54612         need to incur the cost of this shell invocation for every single
54613         use of this .mk file.  Reported by Eric Blake in
54614         https://lists.gnu.org/r/bug-gnulib/2016-12/msg00137.html
54616 2016-12-30  Jim Meyering  <meyering@fb.com>
54618         maint.mk: improve sc_prohibit_intprops_without_use
54619         * top/maint.mk (_intprops_names): Don't hard-code the list of
54620         symbol names.  Instead, derive it on the fly.
54622 2016-12-30  Paul Eggert  <eggert@cs.ucla.edu>
54624         dfa: shorten sbit, success
54625         * lib/dfa.c (struct regex_syntax.sbit):
54626         (struct dfa.success): Use char, not int, for array elements, since
54627         they are all in the range 0..7.
54629         dfa: simplify multibyte_prop etc.
54630         This follows up on a change made when dfa.c was in grep, namely grep
54631         commit c797046c7c13c2647182b919a79a4c5b4ecf82b1
54632         dated 2015-08-12 07:35:03 -0700, which removed unused multibyte support.
54633         That earlier simplification allows for some more simplification
54634         and trimming down here.
54635         * lib/dfa.c (struct mb_char_classes): New member nchars_alloc.
54636         (struct lexer_state): New mamber brack.
54637         (struct dfa, addtok_mb): multibyte_prop elements are now char, not int,
54638         since they must be in the range 0..3 now.
54639         Remove members mbcsets, nmbcsets, mbcsets_alloc, since
54640         the brack member now supersedes them.
54641         (parse_bracket_exp): Update dfa->lex.brack instead of dfa->mbcsets.
54642         (addtok): Use dfa->lex.brack instead of dfa->mbcsets.
54643         (dfaparse): Remove unnecessary initializations of already-0 storage.
54644         (free_mbdata): Free d->lex.brack.chars instead of d->mbcsets.
54645         (dfassbuild): No need to clear sup->mbcsets.
54647         dfa: minor performance tweak
54648         * lib/dfa.c (setbit_wc): Test < 0, not == EOF.
54650         dfa: wrap charclass inside a struct
54651         On my platform (gcc Ubuntu 5.4.0-6ubuntu1~16.04.4 x86-64,
54652         en_US.utf8 locale) this makes 'grep -Fi -f list.txt list.txt >out'
54653         about 5% faster, where list.txt is generated by 'aspell dump
54654         master | head -n 100000 >list.txt'.  See Bug#22239.
54655         * lib/dfa.c (charclass): Wrap inside a struct.  All uses changed.
54656         (CHARCLASS_INIT, tstbit, setbit, clrbit, zeroset, fillset, notset)
54657         (equal, emptyset, charclass_index, setbit_wc, setbit_case_fold_c):
54658         Adjust to this, e.g., by using charclass * rather than charclass.
54659         All callers changed as needed.
54660         (copyset): Remove.  All uses changed to simple assignment.
54661         (parse_bracket_exp): Use zeroset instead of memset.
54663 2016-12-30  Jim Meyering  <meyering@fb.com>
54665         maint.mk: update list of intprops.h symbol names
54666         * top/maint.mk (_intprops_names): Regenerate the list of symbol names.
54667         This avoids a false failure of the sc_prohibit_intprops_without_use
54668         rule in grep.
54670 2016-12-29  Eric Blake  <eblake@redhat.com>
54672         getopt: fix parallel test failure
54673         * tests/test-getopt-posix.c (TEST_GETOPT_TMP_NAME): Set name.
54674         * tests/test-getopt-gnu.c (TEST_GETOPT_TMP_NAME): Likewise.
54675         * tests/test-getopt-main.h (main): Use different file names
54676         in case test-getopt-gnu and test-getopt-posix run in parallel.
54678 2016-12-29  Paul Eggert  <eggert@cs.ucla.edu>
54680         xalloc: x2nrealloc check for ptrdiff_t overflow
54681         * lib/xalloc.h (x2nrealloc): Check for ptrdiff_t overflow, too.
54682         * modules/xalloc, modules/xvasprintf (Depends-on): Add stdint.
54684 2016-12-24  Bruno Haible  <bruno@clisp.org>
54686         lock test: Fix performance problem on multi-core machines.
54687         * tests/test-lock.c (USE_VOLATILE): New macro.
54688         (struct atomic_int): New type.
54689         (init_atomic_int, get_atomic_int_value, set_atomic_int_value): New
54690         functions.
54691         (lock_checker_done, rwlock_checker_done, reclock_checker_done): Define
54692         as 'struct atomic_int'.
54693         (lock_checker_thread, test_lock, rwlock_checker_thread, test_rwlock,
54694         reclock_checker_thread, test_recursive_lock): Use the new functions.
54695         Reported by Eric Blake in
54696         https://www.redhat.com/archives/libvir-list/2012-March/msg00854.html
54697         and by Pádraig Brady in
54698         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00117.html.
54700 2016-12-19  Bruno Haible  <bruno@clisp.org>
54702         vma-iter: Fix endless loop on 64-bit Windows.
54703         * lib/vma-iter.c (vma_iterate): On Windows, use 'uintptr_t' instead of
54704         'unsigned long'.
54706 2016-12-19  Bruno Haible  <bruno@clisp.org>
54708         stdint: Fix WINT_MAX to match the gnulib provided wint_t on minw.
54709         * m4/wint_t.m4 (gt_TYPE_WINT_T): Define GNULIB_OVERRIDES_WINT_T here.
54710         * m4/stdint.m4 (gl_STDINT_H): Don't define GNULIB_OVERRIDES_WINT_T.
54711         Invoke gt_TYPE_WINT_T instead.
54712         (gl_STDINT_TYPE_PROPERTIES): Test GNULIB_OVERRIDES_WINT_T.
54713         * modules/stdint (Files): Add m4/wint_t.m4.
54714         * modules/wchar (Makefile.am): Substitute GNULIB_OVERRIDES_WINT_T.
54715         * modules/wctype-h (Makefile.am): Likewise.
54716         * lib/wchar.in.h (wint_t): Override if GNULIB_OVERRIDES_WINT_T is set,
54717         not only on MSVC.
54718         * lib/wctype.in.h (wint_t): Likewise.
54720 2016-12-19  Paul Eggert  <eggert@cs.ucla.edu>
54722         getopt-posix-tests: fix Makefile typo
54723         * modules/getopt-posix-tests (test_getopt_posix_LDADD):
54724         Fix typo: the last ‘_’ was missing in the name.
54725         I suspect that the typo explains this build failure:
54726         https://buildfarm.opencsw.org/buildbot/builders/ggrep-solaris10-sparc/builds/39
54727         although I can’t reproduce the problem on Solaris 10 sparc.
54729 2016-12-18  Paul Eggert  <eggert@cs.ucla.edu>
54731         dfa: improve worst-case 'replace' performance
54732         See my note in Bug#22357#71.
54733         * lib/dfa.c (insert, delete): Rework to avoid duplicate test.
54734         (merge_constrained): New function, which is like
54735         the old 'merge' function, except with a new argument C2.
54736         Simplify the body by avoiding the need for different sections
54737         of code depending on whether one input is exhausted.
54738         (merge): Use the new function.
54739         (delete): Return the constraint of the deleted position,
54740         not the entire position.  Caller changed.
54741         (replace): Change from O(N*(N + log N)) to O(N log N) algorithm.
54743 2016-12-18  Norihiro Tanaka  <noritnk@kcn.ne.jp>
54745         dfa: performance improvement for removal of epsilon closure
54746         See Bug#22357#32.
54747         * lib/dfa.c (delete): Use binary search to find deleted index.
54748         (replace): New function.  It replaces a position with the followed set.
54749         (epsclosure): Replace it with a new algorithm.  Update caller.
54751 2016-12-18  Bruno Haible  <bruno@clisp.org>
54753         Split tests for getopt-posix and getopt-gnu.
54754         * tests/test-getopt-posix.c: New file.
54755         * tests/test-getopt-gnu.c: New file, with code from test-getopt.c.
54756         * tests/test-getopt-main.h: Renamed from tests/test-getopt.c. Remove
54757         stuff moved to test-getopt-gnu.c. Test TEST_GETOPT_GNU instead of
54758         GNULIB_TEST_GETOPT_GNU.
54759         * modules/getopt-posix-tests (Files): Add test-getopt-posix.c,
54760         test-getopt-main.h. Remove test-getopt.c, test-getopt_long.h.
54761         (Makefile.am): Test test-getopt-posix instead of test-getopt.
54762         * modules/getopt-gnu-tests: New file.
54763         * modules/getopt-gnu (configure.ac): Don't define GNULIB_TEST_GETOPT_GNU.
54765 2016-12-18  Bruno Haible  <bruno@clisp.org>
54767         posix-modules: Add options for specific platforms.
54768         * posix-modules (func_usage): Document options --for-mingw, --for-msvc.
54769         (exclude_for_mingw, exclude_for_msvc, exclude): New variables.
54770         Invoke func_tmpdir. Filter out the excludes.
54772 2016-12-18  Bruno Haible  <bruno@clisp.org>
54774         getopt: Fix link error for users of getopt() in <unistd.h>.
54775         * lib/getopt.in.h (getopt etc.): Do the macro definitions also when
54776         __need_getopt is defined. Undefine all macros before defining them.
54777         * modules/getopt (Include): Clarify that including <unistd.h> is also
54778         OK.
54779         * tests/test-getopt.c: Add comment.
54781 2016-12-17  Bruno Haible  <bruno@clisp.org>
54783         getaddrinfo tests: Avoid compilation error on MSVC.
54784         * tests/test-getaddrinfo.c: Don't check the prototypes of freeaddrinfo,
54785         getaddrinfo on native Windows.
54787 2016-12-17  Bruno Haible  <bruno@clisp.org>
54789         getlogin, getlogin_r: Fix link errors on MSVC.
54790         * m4/getlogin.m4 (gl_LIB_GETLOGIN): New macro.
54791         * modules/getlogin (configure.ac): Require gl_LIB_GETLOGIN.
54792         (Link): New section.
54793         * modules/getlogin_r (Files): Add m4/getlogin.m4.
54794         (configure.ac): Require gl_LIB_GETLOGIN.
54795         (Link): New section.
54796         * NEWS: Mention the new link requirements.
54797         * modules/getlogin-tests (test_getlogin_LDADD): New variable.
54798         * modules/getlogin_r-tests (test_getlogin_r_LDADD): New variable.
54800 2016-12-17  Bruno Haible  <bruno@clisp.org>
54802         Un-deprecate the 'progname' module.
54803         * NEWS: Describe the appropriate use-cases of 'progname' versus
54804         'getprogname'. Based on discussion summary at
54805         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00105.html
54807 2016-12-17  Bruno Haible  <bruno@clisp.org>
54809         Reorganize NEWS a bit.
54810         * NEWS: Move some not so important changes away from section
54811         "Important Notes".
54813 2016-12-17  Bruno Haible  <bruno@clisp.org>
54815         tanhf: Avoid redefinition error on MSVC.
54816         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_TANHF.
54817         * m4/tanhf.m4 (gl_FUNC_TANHF): Set REPLACE_TANHF to 1 if the function
54818         may be defined as an inline function.
54819         * modules/math (Makefile.am): Substitute REPLACE_TANHF.
54820         * lib/math.in.h (tanhf): Override if REPLACE_TANHF is 1.
54822 2016-12-17  Bruno Haible  <bruno@clisp.org>
54824         tanf: Avoid redefinition error on MSVC.
54825         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_TANF.
54826         * m4/tanf.m4 (gl_FUNC_TANF): Set REPLACE_TANF to 1 if the function
54827         may be defined as an inline function.
54828         * modules/math (Makefile.am): Substitute REPLACE_TANF.
54829         * lib/math.in.h (tanf): Override if REPLACE_TANF is 1.
54831 2016-12-17  Bruno Haible  <bruno@clisp.org>
54833         sqrtf: Avoid redefinition error on MSVC.
54834         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_SQRTF.
54835         * m4/sqrtf.m4 (gl_FUNC_SQRTF): Set REPLACE_SQRTF to 1 if the function
54836         may be defined as an inline function.
54837         * modules/math (Makefile.am): Substitute REPLACE_SQRTF.
54838         * lib/math.in.h (sqrtf): Override if REPLACE_SQRTF is 1.
54840 2016-12-17  Bruno Haible  <bruno@clisp.org>
54842         sinhf: Avoid redefinition error on MSVC.
54843         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_SINHF.
54844         * m4/sinhf.m4 (gl_FUNC_SINHF): Set REPLACE_SINHF to 1 if the function
54845         may be defined as an inline function.
54846         * modules/math (Makefile.am): Substitute REPLACE_SINHF.
54847         * lib/math.in.h (sinhf): Override if REPLACE_SINHF is 1.
54849 2016-12-17  Bruno Haible  <bruno@clisp.org>
54851         sinf: Avoid redefinition error on MSVC.
54852         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_SINF.
54853         * m4/sinf.m4 (gl_FUNC_SINF): Set REPLACE_SINF to 1 if the function
54854         may be defined as an inline function.
54855         * modules/math (Makefile.am): Substitute REPLACE_SINF.
54856         * lib/math.in.h (sinf): Override if REPLACE_SINF is 1.
54858 2016-12-17  Bruno Haible  <bruno@clisp.org>
54860         logf: Avoid redefinition error on MSVC.
54861         * m4/logf.m4 (gl_FUNC_LOGF): Set REPLACE_LOGF to 1 if the function
54862         may be defined as an inline function.
54864 2016-12-17  Bruno Haible  <bruno@clisp.org>
54866         log10l: Avoid redefinition error on MSVC.
54867         * m4/log10l.m4 (gl_FUNC_LOG10L): Set REPLACE_LOG10L to 1 if the function
54868         may be defined as an inline function.
54870 2016-12-17  Bruno Haible  <bruno@clisp.org>
54872         log10f: Avoid redefinition error on MSVC.
54873         * m4/log10f.m4 (gl_FUNC_LOG10F): Set REPLACE_LOG10F to 1 if the function
54874         may be defined as an inline function.
54876 2016-12-17  Bruno Haible  <bruno@clisp.org>
54878         hypotl: Avoid redefinition error on MSVC.
54879         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Set REPLACE_HYPOTL to 1 if the function
54880         may be defined as an inline function.
54882 2016-12-17  Bruno Haible  <bruno@clisp.org>
54884         hypotf: Avoid redefinition error on MSVC.
54885         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Set REPLACE_HYPOTF to 1 if the function
54886         may be defined as an inline function.
54888 2016-12-17  Bruno Haible  <bruno@clisp.org>
54890         fmodl: Avoid redefinition error on MSVC.
54891         * m4/fmodl.m4 (gl_FUNC_FMODL): Set REPLACE_FMODL to 1 if the function
54892         may be defined as an inline function.
54894 2016-12-17  Bruno Haible  <bruno@clisp.org>
54896         fmodf: Avoid redefinition error on MSVC.
54897         * m4/fmodf.m4 (gl_FUNC_FMODF): Set REPLACE_FMODF to 1 if the function
54898         may be defined as an inline function.
54900 2016-12-17  Bruno Haible  <bruno@clisp.org>
54902         expf: Avoid redefinition error on MSVC.
54903         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_EXPF.
54904         * m4/expf.m4 (gl_FUNC_EXPF): Set REPLACE_EXPF to 1 if the function
54905         may be defined as an inline function.
54906         * modules/math (Makefile.am): Substitute REPLACE_EXPF.
54907         * lib/math.in.h (expf): Override if REPLACE_EXPF is 1.
54909 2016-12-17  Bruno Haible  <bruno@clisp.org>
54911         coshf: Avoid redefinition error on MSVC.
54912         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_COSHF.
54913         * m4/coshf.m4 (gl_FUNC_COSHF): Set REPLACE_COSHF to 1 if the function
54914         may be defined as an inline function.
54915         * modules/math (Makefile.am): Substitute REPLACE_COSHF.
54916         * lib/math.in.h (coshf): Override if REPLACE_COSHF is 1.
54918 2016-12-17  Bruno Haible  <bruno@clisp.org>
54920         cosf: Avoid redefinition error on MSVC.
54921         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_COSF.
54922         * m4/cosf.m4 (gl_FUNC_COSF): Set REPLACE_COSF to 1 if the function
54923         may be defined as an inline function.
54924         * modules/math (Makefile.am): Substitute REPLACE_COSF.
54925         * lib/math.in.h (cosf): Override if REPLACE_COSF is 1.
54927 2016-12-17  Bruno Haible  <bruno@clisp.org>
54929         atan2f: Avoid redefinition error on MSVC.
54930         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ATAN2F.
54931         * m4/atan2f.m4 (gl_FUNC_ATAN2F): Set REPLACE_ATAN2F to 1 if the function
54932         may be defined as an inline function.
54933         * modules/math (Makefile.am): Substitute REPLACE_ATAN2F.
54934         * lib/math.in.h (atan2f): Override if REPLACE_ATAN2F is 1.
54936 2016-12-17  Bruno Haible  <bruno@clisp.org>
54938         atanf: Avoid redefinition error on MSVC.
54939         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ATANF.
54940         * m4/atanf.m4 (gl_FUNC_ATANF): Set REPLACE_ATANF to 1 if the function
54941         may be defined as an inline function.
54942         * modules/math (Makefile.am): Substitute REPLACE_ATANF.
54943         * lib/math.in.h (atanf): Override if REPLACE_ATANF is 1.
54945 2016-12-17  Bruno Haible  <bruno@clisp.org>
54947         asinf: Avoid redefinition error on MSVC.
54948         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ASINF.
54949         * m4/asinf.m4 (gl_FUNC_ASINF): Set REPLACE_ASINF to 1 if the function
54950         may be defined as an inline function.
54951         * modules/math (Makefile.am): Substitute REPLACE_ASINF.
54952         * lib/math.in.h (asinf): Override if REPLACE_ASINF is 1.
54954 2016-12-17  Bruno Haible  <bruno@clisp.org>
54956         acosf: Avoid redefinition error on MSVC.
54957         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Define REPLACE_ACOSF.
54958         * m4/acosf.m4 (gl_FUNC_ACOSF): Set REPLACE_ACOSF to 1 if the function
54959         may be defined as an inline function.
54960         * modules/math (Makefile.am): Substitute REPLACE_ACOSF.
54961         * lib/math.in.h (acosf): Override if REPLACE_ACOSF is 1.
54963 2016-12-17  Bruno Haible  <bruno@clisp.org>
54965         Avoid redefinition errors on MSVC.
54966         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): Set REPLACE_SNPRINTF to 1 if
54967         the function may be defined as an inline function.
54968         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): Set REPLACE_VSNPRINTF to 1 if
54969         the function may be defined as an inline function.
54971 2016-12-17  Bruno Haible  <bruno@clisp.org>
54973         Avoid redefinition errors on MSVC.
54974         * lib/stdio.in.h: Include <stdlib.h> and <io.h> when necessary.
54975         * lib/unistd.in.h: Include <stdio.h> when necessary.
54977 2016-12-17  Bruno Haible  <bruno@clisp.org>
54979         stdint: Fix WINT_MAX to match the gnulib provided wint_t on MSVC.
54980         * m4/stdint.m4 (gl_STDINT_H): Define GNULIB_OVERRIDES_WINT_T.
54981         * modules/stdint (Makefile.am): Substitute GNULIB_OVERRIDES_WINT_T.
54982         * lib/stdint.in.h [GNULIB_OVERRIDES_WINT_T]: Redefine WINT_MIN and
54983         WINT_MAX.
54985 2016-12-17  Bruno Haible  <bruno@clisp.org>
54987         Avoid autoconf warning.
54988         * modules/frexpl (configure.ac): Require, not invoke, gl_FUNC_FREXPL.
54989         * modules/frexp (configure.ac): Require, not invoke, gl_FUNC_FREXP.
54991 2016-12-17  Bruno Haible  <bruno@clisp.org>
54993         fpending: Revert workaround against Emacs bug.
54994         * lib/stdio-impl.h [__MINGW32__]: Revert conditional.
54995         The Emacs bug is fixed by Eli Zaretskii in
54996         http://lists.gnu.org/r/emacs-devel/2016-12/msg00715.html
54998 2016-12-17  Bruno Haible  <bruno@clisp.org>
55000         getlogin_r tests: Port to mingw.
55001         * tests/test-getlogin_r.c: Don't include <pwd.h> on native Windows. Fixes
55002         regression introduced on 2014-05-19.
55004 2016-12-17  Bruno Haible  <bruno@clisp.org>
55006         getlogin: Port to newer mingw.
55007         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_GETLOGIN.
55008         * m4/getlogin.m4 (gl_FUNC_GETLOGIN): Set HAVE_DECL_GETLOGIN.
55009         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETLOGIN, not
55010         HAVE_GETLOGIN.
55011         * lib/unistd.in.h (getlogin): Test HAVE_DECL_GETLOGIN, not
55012         HAVE_GETLOGIN.
55013         * doc/posix-functions/getlogin.texi: Mention the issue.
55014         * tests/test-getlogin.c: Don't include <pwd.h> on native Windows. Fixes
55015         regression introduced on 2014-05-14.
55017 2016-12-16  Paul Eggert  <eggert@cs.ucla.edu>
55019         builtin-expect: improve port to IBM XL C
55020         Problem reported for z/OS by Daniel Richard G. in:
55021         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00079.html
55022         * m4/builtin-expect.m4 (gl___BUILTIN_EXPECT):
55023         Test for <builtins.h> directly.
55025         builtin-expect: port to IBM XL C
55026         Problem reported for z/OS by Daniel Richard G. in:
55027         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00074.html
55028         * m4/builtin-expect.m4 (gl___BUILTIN_EXPECT):
55029         Also allow __builtin_expect defined via a standard include file.
55031         regex: fix dependency
55032         Problem reported by Bruno Haible in:
55033         http://lists.gnu.org/r/bug-gnulib/2016-12/msg00073.html
55034         * modules/regex: Depend on builtin-expect.
55036         builtin-expect: new module
55037         Fix fnmatch to use it.
55038         Problem reported for z/OS by Daniel Richard G.
55039         * lib/fnmatch.c (__builtin_expect):
55040         * lib/glob.c (__builtin_expect):
55041         * lib/grantpt.c (__builtin_expect) [!_LIBC]:
55042         * lib/memmem.c (__builtin_expect) [!_LIBC]:
55043         * lib/scandir.c (__builtin_expect):
55044         * lib/strstr.c (__builtin_expect) [!_LIBC]:
55045         Remove macro; config.h now does this.
55046         * lib/gl_anytreehash_list1.h (add_to_bucket):
55047         * lib/regex_internal.h (BE):
55048         Assume __builtin_expect.
55049         * m4/builtin-expect.m4, modules/builtin-expect: New files.
55050         * modules/avltreehash-list, modules/fnmatch, modules/glob:
55051         * modules/grantpt, modules/memmem-simple, modules/rbtreehash-list:
55052         * modules/scandir, modules/strstr-simple:
55053         Depend on builtin-expect.
55055 2016-12-15  Bruno Haible  <bruno@clisp.org>
55057         init.sh: Add possibility to not delete temporary files.
55058         * tests/init.sh (remove_tmp_): If the environment variable KEEP is set
55059         to yes, don't erase the temporary directory.
55061 2016-12-16  Paul Eggert  <eggert@cs.ucla.edu>
55063         regex: fix integer-overflow bug in never-used code
55064         Problem reported by Clément Pit–Claudel in:
55065         http://lists.gnu.org/r/emacs-devel/2016-12/msg00654.html
55066         * lib/regex_internal.h: Include intprops.h.
55067         * lib/regexec.c (re_search_2_stub): Use it to avoid undefined
55068         behavior on integer overflow.
55069         * modules/regex (Depends-on): Add intprops.
55071         fpending: fix port to MinGW on Emacs
55072         * lib/stdio-impl.h [__MINGW32__]: Do not include errno.h.
55073         Problem reported by Eli Zaretskii in:
55074         http://lists.gnu.org/r/emacs-devel/2016-12/msg00642.html
55075         Is Plan 9 still a valid porting target, anyway?
55077 2016-12-15  Paul Eggert  <eggert@cs.ucla.edu>
55079         safe-alloc: use xalloc-oversized
55080         * lib/safe-alloc.c: Include xalloc-oversized.h.
55081         (safe_alloc_oversized): Remove.  All uses changed to xalloc_oversized.
55082         * modules/safe-alloc (Depends-on): Add xalloc-oversized.
55084         xalloc: do not exceed PTRDIFF_MAX
55085         * lib/xmalloc.c (xcalloc) [HAVE_GNU_CALLOC]: Do not omit
55086         xalloc_oversized check, since objects larger than PTRDIFF_MAX
55087         bytes have pointer-subtraction problems.
55089         malloca: do not exceed PTRDIFF_MAX
55090         * lib/malloca.h: Include xalloc-oversized.
55091         (nmalloca): Use xalloc_oversized instead of rolling our own.
55092         * modules/malloca (Depends-on):
55093         * modules/relocatable-prog-wrapper (Depends-on):
55094         Add xalloc-oversized.
55096         quotearg: pacify GCC better
55097         * modules/quotearg (Depends-on): Add minmax, stdint.
55098         * lib/quotearg.c: Include minmax.h, stdint.h.
55099         (nslots): Now int, as there seems little point to going to extra
55100         work merely to support the INT_MAX slot, which nobody ever uses.
55101         (quotearg_n_options): Redo size-overflow checks to pacify GCC
55102         and to catch (mostly-theoretical) ptrdiff_t problems too.
55103         This can be done via one comparison.
55105 2016-12-14  Paul Eggert  <eggert@cs.ucla.edu>
55107         xalloc-oversized: check for PTRDIFF_MAX too
55108         This avoids undefined behavior when subtracting pointers to
55109         objects containing more than PTRDIFF_MAX bytes.
55110         * lib/xalloc-oversized.h (__xalloc_oversized, xalloc_oversized):
55111         Also return 1 if the result would exceed PTRDIFF_MAX>
55112         * modules/xalloc-oversized (Depends-on):
55113         Add stdint.
55115         dfa: fix glitches in previous commit
55116         Sorry, I don't know how I managed to commit the wrong version.
55117         * lib/dfa.c (MIN): Move up.
55118         (xpalloc): Now static.
55120         dfa: fix some unlikely integer overflows
55121         I found these while reviewing the recent Coverity-related fix.
55122         This patch changes part of dfa.c to prefer ptrdiff_t instead of
55123         size_t for object counts.  Using ptrdiff_t is the style typically
55124         used in Emacs; although it wastes a sign bit as sizes can never be
55125         negative, it makes -fsanitize=undefined more likely to catch
55126         integer overflows in index calculation, and nowadays the upside is
55127         typically more important than the downside.  Although perhaps the
55128         rest of dfa.c should be changed to prefer ptrdiff_t as well (much
55129         of dfa.c already does, since it uses state_num which is signed),
55130         that is a bigger change and is not needed to fix the bugs I found.
55131         * lib/dfa.c: Include stdint.h and intprops.h.
55132         (TOKEN_MAX): New macro.
55133         (position_set, struct mb_char_classes, struct dfa, maybe_realloc)
55134         (charclass_index, parse_bracket_exp, addtok, insert, merge)
55135         (realloc_trans_if_necessary, free_mbdata):
55136         Use ptrdiff_t instead of size_t for object counts related to xpalloc.
55137         This is safe because xpalloc checks that the sizes do not exceed
55138         either SIZE_MAX or PTRDIFF_MAX.
55139         (xpalloc): New function, mostly taken from Emacs.
55140         (maybe_realloc, copy, realloc_trans_if_necessary): Use it.
55141         (maybe_realloc): Add NITEMS_MAX to signature.  All callers changed.
55142         (charclass_index): Check for integer overflow in computing
55143         charclass index; it must not exceed TOKEN_MAX - CSET, as CSET is
55144         added to it later.
55145         (alloc_position_set): Check for integer overflow.  On typical
55146         platforms this check has zero overhead, since the constant
55147         expression is false.
55148         (realloc_trans_if_necessary):
55149         Remove assertion, which I hope Coverity no longer needs.
55151         * modules/dfa (Depends-on): Add intprops, stdint.
55153 2016-12-12  Jim Meyering  <meyering@fb.com>
55155         dfa: add an assertion to avoid coverity false positive
55156         * lib/dfa.c (realloc_trans_if_necessary): Otherwise, coverity
55157         warned that "newalloc1 - 2" could overflow.
55159 2016-12-13   Arnold D. Robbins  <arnold@skeeve.com>
55161         dfa: remove DFA_CASE_FOLD flag in favor of RE_ICASE
55162         * dfa.h (DFA_CASE_FOLD): Remove.
55163         * dfa.c (dfasyntax): Set dfa->syntax.case_fold based on RE_ICASE.
55165 2016-12-13  John W. Eaton  <gnu@jweaton.org>
55167         link: fix test to declare use of rename()
55168         * m4/link.m4 (gl_FUNC_LINK): Include <stdio.h> needed with
55169         -Werror=implicit-function-declaration
55171 2016-12-12  Bruno Haible  <bruno@clisp.org>
55173         fpending: Port to native Windows with MSVC.
55174         * lib/fpending.c: Include stdio-impl.h.
55175         (__fpending): Include all known implementations. Err out if it's not
55176         ported.
55177         * m4/fpending.m4 (gl_PREREQ_FPENDING): Remove macro.
55178         * modules/fpending (Files): Add lib/stdio-impl.h.
55179         (configure.ac): Don't invoke gl_PREREQ_FPENDING.
55181 2016-12-12  Bruno Haible  <bruno@clisp.org>
55183         stdioext: Port to native Windows with MSVC.
55184         * lib/stdio-impl.h (WINDOWS_OPAQUE_FILE): New macro.
55185         (struct _gl_real_FILE): New type.
55186         (fp_, _IOREAD, _IOWRT, _IORW, _IOEOF, _IOERR): New macros, for native
55187         Windows.
55188         * lib/fbufmode.c (fbufmode): Add code for native Windows.
55189         * lib/fflush.c (clear_ungetc_buffer): Treat native Windows like the
55190         other SystemV derived implementations.
55191         * lib/fpurge.c (fpurge): Likewise.
55192         * lib/freadable.c (freadable): Likewise.
55193         * lib/freadahead.c (freadahead): Likewise.
55194         * lib/freading.c (freading): Likewise.
55195         * lib/freadptr.c (freadptr): Likewise.
55196         * lib/freadseek.c (freadptrinc): Likewise.
55197         * lib/fseeko.c (fseeko): Likewise.
55198         * lib/fseterr.c (fseterr): Likewise.
55199         * lib/fwritable.c (fwritable): Likewise.
55200         * lib/fwriting.c (fwriting): Likewise.
55201         Reported by Gisle Vanem <gvanem@yahoo.no>.
55203 2016-12-11  Jim Meyering  <meyering@fb.com>
55205         non-recursive-gnulib-prefix-hack.m4: remove leading "(" in case stmt
55206         * m4/non-recursive-gnulib-prefix-hack.m4: That leading "(" happens
55207         to work with most shells, but not with the one provided by many
55208         Solaris 10 systems, so running configure with such a /bin/sh evokes
55209         e.g., "./configure: syntax error at line 33602: `(' unexpected".
55210         Reported by Assaf Gordon in
55211         https://lists.gnu.org/r/sed-devel/2016-12/msg00002.html
55213 2016-12-10  Bruno Haible  <bruno@clisp.org>
55215         threadlib: Optimize out runtime test on Solaris >= 10.
55216         * m4/threadlib.m4 (gl_THREADLIB_BODY): Don't set
55217         PTHREAD_IN_USE_DETECTION_HARD if configuring on Solaris 10 or newer.
55218         Reported by Peter Felecan at <https://savannah.gnu.org/bugs/?32087>.
55220 2016-12-10  Bruno Haible  <bruno@clisp.org>
55222         stdint: Update doc about Solaris 9.
55223         * doc/posix-headers/stdint.texi: Add info about Solaris 9.
55225 2016-12-09  Bruno Haible  <bruno@clisp.org>
55227         c-ctype tests: Fix link error on Solaris 9.
55228         * modules/c-ctype-tests (Depends-on): Add 'isblank'.
55229         Reported at <https://savannah.gnu.org/bugs/?46827>.
55231 2016-12-09  Paul Eggert  <eggert@cs.ucla.edu>
55233         dfa: fix performance bug that recomputes trans
55234         * lib/dfa.c (build_state): Fix performance bug introduced in Nov
55235         25 on-demand changes.  The bug caused build_state to reset all
55236         d->trans elements to -2 even when d->trans was already non-null.
55237         Use C99 style decls after statements in this function.
55239         same-inode: port to MinGW
55240         Here st_ino is always 0, so change the definition of SAME_INODE so
55241         that 1 means the two files are the same, 0 with st_ino != 0 means
55242         they differ, and 0 with st_ino == 0 means we don’t know.  Problem
55243         reported by Bruno Haible (Bug#25146).
55244         * doc/posix-headers/sys_stat.texi (sys/stat.h): Update.
55245         * lib/same-inode.h (SAME_INODE): Return 0 on MinGW.
55247 2016-12-04  Bruno Haible  <bruno@clisp.org>
55249         javacomp-script: Support Java 7 and 8.
55250         * m4/javacomp.m4 (gt_JAVACOMP): Accept source-version 1.7, 1.8 and
55251         target-version 1.7, 1.8.
55253 2016-12-02  Daiki Ueno  <ueno@gnu.org>
55255         * gnulib-tool (func_import): Relax the regex used for "LGPLv3+ or
55256         GPLv2" rewriting.
55258 2016-12-02  Nikos Mavrogiannopoulos  <nmav@gnutls.org>
55260         * gnulib-tool (func_import): Adhere to the license guideline when
55261         rewriting the license text to "LGPLv3+ or GPLv2":
55262         https://www.gnu.org/prep/maintain/maintain.html#Licensing-of-GNU-Packages
55264 2016-12-02  Bruno Haible  <bruno@clisp.org>
55266         localcharset: Avoid theoretical buffer overrun.
55267         * lib/localcharset.c (locale_charset) [WINDOWS_NATIVE]: Don't use the
55268         return value from setlocale if it would lead to a buffer overrun.
55270 2016-12-01  Bruno Haible  <bruno@clisp.org>
55272         Relicense some modules under LGPLv2+.
55273         Kevin Cernekee's approval is in
55274         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00090.html.
55275         * modules/fseterr (License): Change to LGPLv2+.
55276         * modules/mbchar (License): Likewise.
55277         * modules/mbiter (License): Likewise.
55278         * modules/mbsnlen (License): Likewise.
55279         * modules/wcwidth (License): Likewise.
55281 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
55283         scandir: Fix _D_ALLOC_NAMLEN() on OS/2 kLIBC
55284         * lib/scandir.c (_D_ALLOC_NAMLEN): Consider the fields after d_name on
55285         OS/2 kLIBC.
55287 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
55289         alphasort, scandir: Port to OS/2 kLIBC
55290         * lib/alphasort.c (alphasort): Implement according to OS/2 kLIBC
55291         declaration.
55292         * lib/scandir.c (scandir): Add declaration for OS/2 kLIBC.
55294 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
55296         relocatable: Fix that /@unixroot prefix is not working on OS/2 kLIBC
55297         * lib/relocatable.c (relocate): Do not touch pathname if it is started
55298         with '/@unixroot'.
55300 2016-12-01  KO Myung-Hun  <komh78@gmail.com>
55302         sys_socket: typedef sa_family_t correctly on OS/2 kLIBC
55303         * lib/sys_socket.in.h (sa_family_t): Typedef to unsigned char on
55304         OS/2 kLIBC unless TCPV40HDRS is defined.
55306 2016-11-29  Jim Meyering  <meyering@fb.com>
55308         dfa: avoid new infinite loop
55309         This would infloop: echo cx | LC_ALL=C grep -E 'c\b[x ]'
55310         * lib/dfa.c (dfastate): When constructing a new state table, we could
55311         initially declare that we had found a match, and later find that
55312         constraints eliminate that possibility, yet continue to use the
55313         now stale "matched" indicator.  That would lead to an infinite loop.
55314         The solution is to update "matched" when necessary.
55315         Introduced by commit v0.1-983-g403adf1.
55317 2016-11-27  Norihiro Tanaka  <noritnk@kcn.ne.jp>
55319         dfa: avoid match middle in multibyte character
55320         * lib/dfa.c (transit_state): If fails in matching single byte characters
55321         on a state including period expression in non-UTF8 multibyte locales,
55322         skip trailing bytes.
55323         (dfa_supported): Revert previous change.
55325 2016-11-27  Jim Meyering  <meyering@fb.com>
55327         dfa: avoid false match in non-UTF8 multibyte locales
55328         * lib/dfa.c (dfa_supported): Treat any non-UTF8 multibyte locale
55329         as "not supported" so that callers will resort to using regex-based
55330         matcher.  This will surely hurt performance, but correctness trumps
55331         performance here, and the affected locales are less and less relevant,
55332         these days.  See grep's bug report https://bugs.gnu.org/24975.
55334 2016-11-27  Mike Frysinger  <vapier@gentoo.org>
55336         ptsname_r: leverage AC_HEADER_MAJOR to provide major()
55337         * lib/ptsname_r.c: Include the appropriate headers.
55338         [__sun]: Delete sys/sysmacros.h include.
55339         [_AIX || __osf__]: Likewise.
55340         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Depend on AC_HEADER_MAJOR.
55342 2016-11-27  Pádraig Brady  <P@draigBrady.com>
55344         md4,md5,sha*: allow _STRING_INLINE_unaligned enable unaligned operation
55345         * lib/md4.c (md4_process_bytes): The existing define is made internal
55346         in recent versions of glibc, so also use this new public define.
55347         * lib/md5.c (md5_process_bytes): Likewise.
55348         * lib/sha1.c (sha1_process_bytes): Likewise.
55349         * lib/sha256.c (sha256_process_bytes): Likewise.
55350         * lib/sha512.c (sha512_process_bytes): Likewise.
55352 2016-11-27  Pádraig Brady  <P@draigBrady.com>
55354         maint: use a more standard return from mbrtowc test
55355         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): Don't return 1
55356         from the test program as this often indicates an
55357         unhandled case in the test program.
55358         (gl_MBRTOWC_INCOMPLETE_STATE): Likewise.
55359         (gl_MBRTOWC_SANITYCHECK): Likewise.
55360         (gl_MBRTOWC_NULL_ARG2): Likewise.
55361         (gl_MBRTOWC_NUL_RETVAL): Likewise.
55363 2016-11-26  Paul Eggert  <eggert@cs.ucla.edu>
55365         freopen: work around glibc bug with closed fd
55366         Work around glibc bug#15589, where freopen mishandles the case
55367         where stdin etc. are already closed.
55368         * doc/posix-functions/freopen.texi (freopen): Document the bug.
55369         * lib/freopen.c (_GL_ALREADY_INCLUDING_STDIO_H): Define this
55370         instead of __need_FILE, as the latter does not work with glibc.
55371         Include <fcntl.h>, for open flags.
55372         (rpl_freopen): Work around glibc bug.
55373         * m4/freopen.m4 (gl_FUNC_FREOPEN): Check for bug.
55374         * modules/freopen (Depends-on): Add fcntl-h.
55375         * tests/test-freopen.c (main): Test for bug.
55377 2016-11-25  Paul Eggert  <eggert@cs.ucla.edu>
55379         fnmatch: fix typo introduced on 2016-08-17
55380         This fixes the port to non-GCC compilers that lack __builtin_expect.
55381         * lib/fnmatch.c (__builtin_expect): Change A&&B to !A||B.
55383         dfa: simplify with new function fillset
55384         * lib/dfa.c (fillset): New function.
55385         Use it for clarity when applicable.
55387         dfa: fix glitches with on-demand states
55388         Also, adjust commentary to better match new code.
55389         Some of these glitches predate the recent change.
55390         * lib/dfa.c (dfaanalyze): Clear trcount here, so that it counts
55391         only non-initial states.
55392         (dfastate): Rename locals to better match new roles.
55393         Move them into nested scopes if this is easy.
55394         Omit unnecessary calls to zeroset.
55395         Simplify test for whether to throw in the positions of state 0.
55396         Omit C99-ism (decl after statement) since Gawk still wants C89.
55397         (build_state): Omit unnecessary test and assignment.
55398         Fix some confusion that counted transition tables inaccurately
55399         and could cause a memory leak.
55400         (dfaexec_main): Redo to make it clearer to the compiler that
55401         -1 and -2 are the only negative state numbers here.
55403 2016-11-25  Norihiro Tanaka  <noritnk@kcn.ne.jp>
55405         dfa: addition of new state on demand
55406         * src/dfa.c (dfastate): Add argument UC, the current input character.
55407         Fill only a group including the character in transition table.
55408         (realloc_trans_if_necessary): Add the dummy state which means that a
55409         transition table is assigned but the next state is not assigned.
55410         (build_state): Return the next state.  All callers updated.
55411         (transit_state_singlebyte): If we get the dummy state,
55412         fill the transition table.
55413         (dfaexec_main): Handle the dummy state.
55414         (free_mbdata, dfafree): Consider the dummy state.
55416 2016-11-24  Daiki Ueno  <ueno@gnu.org>
55418         srclist: sync with released gettext
55419         * config/srclist.txt: Set "release" option to the files under
55420         $GETTEXT.
55422 2016-11-24  Daiki Ueno  <ueno@gnu.org>
55424         srclist: add "release" option
55425         * config/srclist.txt: Change the format so that the first column
55426         of each line points to the top-level directory of the source
55427         archive.
55428         * config/srclist-update: Accept "release" option that checks files
55429         from the most recently tagged revision in the source archive.
55431 2016-11-21  Bruno Haible  <bruno@clisp.org>
55433         snippet/c++defs: Simplify _GL_CXXALIAS_* macros.
55434         * build-aux/snippet/c++defs.h [__cplusplus && GNULIB_NAMESPACE]
55435         (_GL_CXXALIAS_RPL_1, _GL_CXXALIAS_RPL_CAST_1,
55436         _GL_CXXALIAS_SYS, _GL_CXXALIAS_SYS_CAST, _GL_CXXALIAS_SYS_CAST2):
55437         Inline and remove member function 'rpl ()' of the wrapper struct.
55439 2016-11-20  Paul Eggert  <eggert@cs.ucla.edu>
55441         dfa: fix logic typo
55442         Problem reported by Stephane Chazelas (Bug#24973).
55443         * lib/dfa.c (using_simple_locale): Fix typo that caused some
55444         non-simple locales like fr_FR to be treated as simple.
55446 2016-11-20  Jim Meyering  <meyering@fb.com>
55448         fix test driver leaks: exclude, malloc, realloc
55449         * tests/test-exclude.c (main): Fix trivial leak.
55450         * tests/test-malloc-gnu.c (main): Likewise.
55451         * tests/test-realloc-gnu.c (main): Likewise.
55452         With these changes, grep's tests are now leak free.
55453         I.e., running them with ASAN elicits no failure:
55454           make CFLAGS='-O0 -ggdb3' AM_CFLAGS=-fsanitize=address \
55455             AM_LDFLAGS='-fsanitize=address -static-libasan' check
55457 2016-11-11  Bruno Haible  <bruno@clisp.org>
55459         libunistring: Relicense under dual "LGPLv3+ or GPLv2" license.
55460         * modules/libunistring: (License): Change from LGPL to
55461         "LGPLv3+ or GPLv2".
55462         * modules/libunistring-optional: Likewise.
55463         * modules/unicase/*: Likewise.
55464         * modules/uniconv/*: Likewise.
55465         * modules/unictype/*: Likewise.
55466         * modules/unigbrk/*: Likewise.
55467         * modules/unilbrk/*: Likewise.
55468         * modules/uniname/*: Likewise.
55469         * modules/uninorm/*: Likewise.
55470         * modules/unistdio/*: Likewise.
55471         * modules/unistr/*: Likewise.
55472         * modules/uniwbrk/*: Likewise.
55473         * modules/uniwidth/*: Likewise.
55475 2016-11-12  Bruno Haible  <bruno@clisp.org>
55477         Relicense some modules under LGPLv2+.
55478         Paul Eggert's approval is in
55479         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00037.html.
55480         Eric Blake's approval is in
55481         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00042.html.
55482         Ludovic Courtès's approval is in
55483         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00038.html.
55484         * modules/isnand-nolibm (License): Change to LGPLv2+.
55485         * modules/isnanf-nolibm (License): Likewise.
55486         * modules/isnanl-nolibm (License): Likewise.
55488 2016-11-19  Bruno Haible  <bruno@clisp.org>
55490         Relicense some modules under LGPLv2+.
55491         lib/float+.h is already under LGPLv2+ since 2007-07-13, per
55492         modules/vasnprintf.
55493         Paolo Bonzini's approval for lib/frexp.c and lib/frexpl.c is in
55494         http://lists.gnu.org/r/bug-gnulib/2016-11/msg00074.html.
55495         All other significant changes to the files in lib/ of these modules
55496         are from me.
55497         * modules/memcmp2 (License): Change to LGPLv2+.
55498         * modules/amemxfrm (License): Likewise.
55499         * modules/fpieee (License): Likewise.
55500         * modules/fpucw (License): Likewise.
55501         * modules/frexp-nolibm (License): Likewise.
55502         * modules/frexpl-nolibm (License): Likewise.
55503         * modules/printf-frexp (License): Likewise.
55504         * modules/printf-frexpl (License): Likewise.
55505         * modules/printf-safe (License): Likewise.
55506         * modules/signbit (License): Likewise.
55508 2016-11-17  Bruno Haible  <bruno@clisp.org>
55510         Enable Unicode decoder safety unconditionally.
55511         * lib/unistr.in.h (u32_mbtouc_unsafe): Assume CONFIG_UNICODE_SAFETY.
55512         * lib/unistr/u8-mblen.c (u8_mblen): Likewise.
55513         * lib/unistr/u8-mbtouc-unsafe.c (u8_mbtouc_unsafe): Likewise.
55514         * lib/unistr/u8-mbtouc-unsafe-aux.c (u8_mbtouc_unsafe_aux): Likewise.
55515         * lib/unistr/u8-prev.c (u8_prev): Likewise.
55516         * lib/unistr/u8-strmblen.c (u8_strmblen): Likewise.
55517         * lib/unistr/u8-strmbtouc.c (u8_strmbtouc): Likewise.
55518         * lib/unistr/u16-mblen.c (u16_mblen): Likewise.
55519         * lib/unistr/u16-mbtouc-unsafe.c (u16_mbtouc_unsafe): Likewise.
55520         * lib/unistr/u16-mbtouc-unsafe-aux.c (u16_mbtouc_unsafe_aux): Likewise.
55521         * lib/unistr/u16-prev.c (u16_prev): Likewise.
55522         * lib/unistr/u16-strmblen.c (u16_strmblen): Likewise.
55523         * lib/unistr/u16-strmbtouc.c (u16_strmbtouc): Likewise.
55524         * lib/unistr/u32-mblen.c (u32_mblen): Likewise.
55525         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Likewise.
55526         * lib/unistr/u32-prev.c (u32_prev): Likewise.
55527         * lib/unistr/u32-next.c (u32_next): Likewise.
55528         * lib/unistr/u32-strmblen.c (u32_strmblen): Likewise.
55529         * lib/unistr/u32-strmbtouc.c (u32_strmbtouc): Likewise.
55530         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
55531         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
55532         * tests/unistr/test-u16-prev.c (check_invalid): Enable the
55533         CONFIG_UNICODE_SAFETY tests unconditionally.
55534         * tests/unistr/test-u32-mblen.c (main): Likewise.
55535         * tests/unistr/test-u32-mbtouc.h (test_function): Likewise.
55536         * tests/unistr/test-u32-prev.c (check_invalid): Likewise.
55537         * tests/unistr/test-u32-next.c (main): Likewise.
55538         * tests/unistr/test-u32-strmblen.c (main): Likewise.
55539         * tests/unistr/test-u32-strmbtouc.c (main): Likewise.
55540         * tests/unistr/test-u32-mbtouc.c (FULL_SAFETY): Remove macro.
55541         * lib/unistr/u8-check.c (u8_check): Remove old dead code.
55542         * lib/unistr/u8-mbtouc.c (u8_mbtouc): Likewise.
55543         * lib/unistr/u8-mbtouc-aux.c (u8_mbtouc_aux): Likewise.
55544         * lib/unistr/u8-mbtoucr.c (u8_mbtoucr): Likewise.
55545         * lib/unistr/u8-uctomb.c (u8_uctomb): Likewise.
55546         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Likewise.
55547         * lib/unistr/u16-check.c (u16_check): Update comment.
55548         * NEWS: Mention the changes that callers should be aware of.
55550 2016-11-19  Bruno Haible  <bruno@clisp.org>
55552         relocatable-prog-wrapper: Fix breakage on Cygwin.
55553         * modules/relocatable-prog-wrapper (Files): Add lib/stat.c, lib/lstat.c.
55554         (Depends-on): Remove intprops.
55555         * lib/relocwrapper.c: Update dependency tree.
55556         (strerror): Undefine.
55557         * build-aux/install-reloc (func_create_wrapper): Do not compile
55558         strerror.c and strerror-override.c. Erase stat.o and lstat.o.
55560 2016-11-19  Bruno Haible  <bruno@clisp.org>
55562         strerror: Make it compile in C++ mode.
55563         * lib/strerror.c (strerror): Ignore the return value of memcpy().
55565 2016-11-15  Pedro Alves  <palves@redhat.com>
55567         sys_time: add gnulib::timeval for C++
55568         * lib/sys_time.in.h [__cplusplus && defined GNULIB_NAMESPACE]:
55569         Define "timeval" in the GNULIB_NAMESPACE namespace, and #undef any
55570         timeval macro.
55572 2016-11-14  Pedro Alves  <palves@redhat.com>
55574         snippet/c++defs: fix real-floating arg functions in C++ mode
55575         Also, define isfinite, isinf, isnan, signbit in the gnulib
55576         namespace instead of in the global namespace.
55577         * build-aux/snippet/c++defs.h (_GL_BEGIN_NAMESPACE)
55578         (_GL_END_NAMESPACE): New.
55579         * lib/math.in.h (_GL_MATH_CXX_REAL_FLOATING_DECL_2): Use them.
55580         (isfinite, isinf, isnan, signbit) [__cplusplus &&
55581         GNULIB_NAMESPACE]: Define them in the GNULIB_NAMESPACE namespace
55582         instead of in the global namespace.
55583         * tests/test-math-c++.cc: Check that the isfinite, isinf, isnan,
55584         signbit overloads exist in the GNULIB_NAMESPACE namespace, instead
55585         of in the global namespace.
55587 2016-11-13  Jim Meyering  <meyering@fb.com>
55589         strftime: don't use __THROW
55590         Each use of __THROW would provoke this from gcc-7-to-be:
55592           lib/strftime.c:371:1: warning: '__leaf__' attribute has no effect \
55593             on unit local functions [-Wattributes]
55594           static int iso_week_days (int, int) __THROW;
55595           ^~~~~~
55596         * lib/strftime.c (__THROW): Don't define.
55597         Remove each use of __THROW.
55598         * lib/strftime.c (memcpy_lowcase, memcpy_uppcase): Remove __THROW.
55599         (tm_diff, iso_week_days, __strftime_internal): Likewise.
55601 2016-11-14  Paul Eggert  <eggert@union>
55603         obstack: port to gcc -fcheck-pointer-bounds
55604         Problem found by 'make check' failure on bleeding-edge coreutils
55605         on an MPX-enabled CPU (Intel Core i3-7100U) running GCC (Ubuntu
55606         6.2.0-5ubuntu12), configured via "./configure
55607         --enable-gcc-warnings CFLAGS='-mmpx -fcheck-pointer-bounds -g3
55608         -O2' LDFLAGS='-static-libmpx -static-libmpxwrappers'".
55609         * lib/obstack.h (__FLEXIBLE_ARRAY_MEMBER):
55610         New macro, copied from fts_.h.
55611         (struct _obstack_chunk.contents): Use it.
55613 2016-11-14  Eric Blake  <eblake@redhat.com>
55615         strerror_r-posix: Another fix, for HAVE_DECL_STRERROR_R on mingw.
55616         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R, gl_FUNC_STRERROR_R_WORKS):
55617         Avoid _ONCE variants, which may supply a conflicting AC_DEFINE().
55619 2016-11-14  Pádraig Brady  <P@draigBrady.com>
55621         strptime: fix compile error in recent change
55622         * lib/strptime.c (__strptime_internal): Fix ported code.
55624 2016-11-11  Bruno Haible  <bruno@clisp.org>
55626         gnulib-tool: Support for the dual "LGPLv3+ or GPLv2" license.
55627         * gnulib-tool (--lgpl): Accept value 3orGPLv2.
55628         (func_import): Extend determination of license_incompatibilities.
55629         (func_create_testdir): Extend table of license compatibility. Handle
55630         also the licenses GPLv3+, GPL, LGPLv3+.
55632 2016-11-12  Paul Eggert  <eggert@cs.ucla.edu>
55634         strftime: tune %q
55635         * lib/strftime.c (__strftime_internal): Assume tp->tm_mon is in range.
55637         Merge strftime.c changes from glibc
55638         This incorporates:
55639         2007-10-16 [BZ #5184] Add tzset_called argument
55640         2008-06-13 [BZ #6612] pass reference to tzset_called around
55641         2009-10-30 Implement Burmese language locale for Myanmar
55642         2010-01-09 Add support for XPG7 testing
55643         2015-09-26 [BZ #18985] out of range data to strftime() causes a segfault
55644         2015-10-20 Convert miscellaneous function definitions to prototype style
55645         * lib/strftime.c: Copy glibc license, since gnulib-tool rewrites
55646         it anyway and this lessens the difference between gnulib and glibc.
55647         (USE_IN_EXTENDED_LOCALE_MODEL) [_LIBC]: Define.
55648         (__THROW): Define if standard headers do not.
55649         (LOCALE_PARAM): Rename from LOCALE_PARAM_PROTO.  All uses changed.
55650         (memcpy_locase, memcpy_uppcase, tm_diff, __strftime_internal):
55651         Declare with __THROW.
55652         (__strftime_internal): Rename from strftime_case_. Add arg for
55653         whether tzset is called.  All uses changed.  Call tzset at most
55654         once.  Allow %OC, for Burmese.
55655         (a_wkday, f_wkday, a_month, f_month) [_NL_CURRENT]:
55656         Don't assume values are in range.
55658 2016-11-12  Eric Blake  <eblake@redhat.com>
55660         strerror_r-posix: Fix override of AC_FUNC_STRERROR_R
55661         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): New override.
55662         (gl_FUNC_STRERROR_R): Don't reuse AC_DEFINE() with a potentially
55663         different value.
55665 2006-11-12  Pedro Alves  <palves@redhat.com>
55667         Fix gnulib C++ namespace support and std::frexp
55668         * lib/math.in.h (frexp): Use _GL_CXXALIASWARN1 instead of
55669         _GL_CXXALIASWARN.
55671 2006-11-12  Pedro Alves  <palves@redhat.com>
55673         GNULIB_NAMESPACE::func need not pull in rpl_func
55674         * build-aux/snippet/c++defs.h [__cplusplus && GNULIB_NAMESPACE]
55675         (_GL_CXXALIAS_RPL_1, _GL_CXXALIAS_RPL_CAST_1, _GL_CXXALIAS_SYS)
55676         (_GL_CXXALIAS_SYS_CAST, _GL_CXXALIAS_SYS_CAST2): Define a wrapper
55677         struct instead of a function pointer.
55679 2016-11-09  Frediano Ziglio  <fziglio@redhat.com>
55681         manywarnings: fix -Wno-missing-field-initializers detection
55682         * m4/manywarnings.m4: Fix -Wno-missing-field-initializers detection
55683         to be independent of -Wunused-variable.  I.E. ensure the latter
55684         warning doesn't occur so that detection of the former is accurate.
55686 2016-11-05  Pádraig Brady  <pbrady@fb.com>
55688         strftime,strptime: support %q to represent the quarter
55689         * lib/strftime.c (strftime_case_): Add %q case.
55690         * lib/strptime.c (__strptime_internal): Likewise.
55691         * tests/test-strftime.c (quarter_test): A new test case.
55693 2016-11-03  Eric Blake  <eblake@redhat.com>
55695         bootstrap: Fix get_version() for AIX 5.3
55696         * build-aux/bootstrap (get_version): Factor out sed script, since
55697         indented comments choke AIX 5.3 sed.
55698         Reported-by: Michael Felt <aixtools@gmail.com>
55700 2016-11-03  Paul Eggert  <eggert@cs.ucla.edu>
55702         intprops: port to older XL C
55703         Problem reported by Alexander Samoilov in:
55704         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00166.html
55705         http://savannah.nongnu.org/bugs/?49448
55706         * lib/intprops.h (_GL_HAVE___TYPEOF__) [__IBM__TYPEOF__]:
55707         Define to 1 only for XL C 12.1 or later, since this bug
55708         occurs in XL C for AIX 6.0 but not in 12.1.
55710 2016-11-02  Pádraig Brady  <P@draigBrady.com>
55712         backupfile: initialize default suffix within the implementation
55713         * lib/backupfile.c (find_backup_file_name): Initialize the
55714         global variable here, to simplify usage, and to only call
55715         getenv() when needed.
55717 2016-11-01  Paul Eggert  <eggert@cs.ucla.edu>
55719         futimens: remove FIXME for old Linux kernels
55720         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Belatedy do a "simplify
55721         this in 2012" FIXME, like that for utimensat.
55723         utimensat: remove FIXME for old Linux kernels
55724         * lib/utimensat.c (rpl_utimensat): Update FIXME comment.
55725         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Belatedy do a "simplify
55726         this in 2012" FIXME, by assuming the file system bug is absent
55727         unless demonstrated to be present.  We no longer need to worry
55728         about Linux kernel 2.6.32 when building with newer kernels.
55730 2016-10-16  Bruno Haible  <bruno@clisp.org>
55732         qsort_r: Fix macrology for platforms that lack the function.
55733         * m4/stdlib_h.m4 (gl_STDLIB_H): Check for qsort_r.
55734         (gl_STDLIB_H_DEFAULTS): Initialize HAVE_QSORT_R.
55735         * modules/stdlib (Makefile.am): Substitute HAVE_QSORT_R.
55736         * lib/stdlib.in.h (qsort_r): Provide declaration if the function does
55737         not exist.
55738         * m4/qsort_r.m4 (gl_FUNC_QSORT_R): Use AC_CHECK_FUNCS to test whether
55739         the function exists.
55740         * modules/qsort_r: Add comments.
55742 2016-10-26  Paul Eggert  <eggert@cs.ucla.edu>
55744         sys_types: fix Texinfo typos
55745         * doc/glibc-functions/gnu_dev_major.texi:
55746         * doc/glibc-functions/gnu_dev_makedev.texi:
55747         * doc/glibc-functions/gnu_dev_minor.texi: Fix typos.
55749 2016-10-26  John David Anglin  <dave.anglin@bell.net>
55751         getprogname: port to HP-UX
55752         See Bug#24805.
55753         * lib/getprogname.c (getprogname) [__hpux]: Port.
55754         * tests/test-getprogname.c (STREQ) [__hpux]:
55755         Special-case for HP-UX limitations on program name length.
55757 2016-10-20  Bruno Haible  <bruno@clisp.org>
55759         Update doc about target platforms.
55760         * doc/gnulib-intro.texi (Target Platforms): Update list.
55762 2016-10-15  Bruno Haible  <bruno@clisp.org>
55764         opendir, readdir, closedir: Relicense under LGPLv2+.
55765         * modules/opendir (License): Change to LGPLv2+.
55766         * modules/readdir (License): Likewise.
55767         * modules/closedir (License): Likewise.
55769 2016-10-16  Bruno Haible  <bruno@clisp.org>
55771         Fix conflict between strerror_r-posix module and AC_FUNC_STRERROR_R.
55772         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Override the values set by the
55773         AC_FUNC_STRERROR_R macro. Define HAVE_DECL_STRERROR_R_ORIG.
55774         * lib/strerror_r.c: Use HAVE_DECL_STRERROR_R_ORIG instead of
55775         HAVE_DECL_STRERROR_R.
55777 2016-10-16  Bruno Haible  <bruno@clisp.org>
55779         Make the 'argp' module work without the 'error' module.
55780         * m4/argp.m4 (gl_ARGP): Require AC_FUNC_STRERROR_R.
55782 2016-10-25  Paul Eggert  <eggert@cs.ucla.edu>
55784         diffseq: restore TOO_EXPENSIVE heuristic
55785         * lib/diffseq.h: Problem with diffutils reported by Andreas Schwab
55786         (Bug#24715).  The simplest solution is to restore the
55787         TOO_EXPENSIVE heuristic that I added to GNU diff in 1993, while
55788         using a higher threshold to avoid Bug#16848 on smaller files.
55789         * lib/diffseq.h (struct context): Restore member too_expensive.
55790         (struct partition): Restore members lo_minimal, hi_minimal.
55791         (diag, compareseq): Restore arg find_minimal.  All uses changed.
55792         (diag): Restore the TOO_EXPENSIVE heuristic that I added back in
55793         1993 to make 'diff' run faster (but not as well) on large inputs,
55794         but use a threshold of 4096 instead of the old 256.
55795         * lib/fstrcmp.c (strcmp_bounded):
55796         * lib/git-merge-changelog.c (compute_differences):
55797         Adjust to diffseq.h changes.
55799 2016-10-22  Bruno Haible  <bruno@clisp.org>
55801         iconv: Avoid compilation error when bootstrapping GNU libiconv.
55802         * m4/iconv.m4 (AM_ICONV): When the system does not have an iconv()
55803         declaration yet, define ICONV_CONST to empty.
55805 2016-10-15  Bruno Haible  <bruno@clisp.org>
55807         Avoid gnulib-tool warnings about the dependencies of 'parse-datetime'.
55808         * gnulib-tool (func_get_license): Special-case the 'parse-datetime'
55809         module.
55811 2016-10-16  Bruno Haible  <bruno@clisp.org>
55813         system-quote tests: Avoid compiler warning on AIX.
55814         * tests/test-system-quote-child.c (fopen): Redefine like the system's
55815         <stdio.h> does.
55817 2016-10-16  Bruno Haible  <bruno@clisp.org>
55819         Fix some "gcc -Wall" warnings.
55820         * tests/test-ffsl.c (main): Use variable x, not i.
55821         * tests/test-posix_spawn3.c (parent_main): Consider the return value of
55822         freopen.
55823         * tests/test-sethostname1.c (main): Explicitly ignore the return value
55824         of sethostname.
55826 2016-10-16  Bruno Haible  <bruno@clisp.org>
55828         gnulib-tool: Make --create-testdir on all modules work again.
55829         * gnulib-tool (func_create_testdir): Don't include the
55830         non-recursive-gnulib-prefix-hack module.
55832 2016-10-21  Daiki Ueno  <ueno@gnu.org>
55834         libunistring: change the maintainer to 'all'
55835         * modules/gen-uni-tables, modules/libunistring:
55836         * modules/ucs4-utf16, modules/ucs4-utf8, modules/unicodeio:
55837         * modules/unitypes, modules/utf16-ucs4, modules/utf16-ucs4-unsafe:
55838         * modules/utf8-ucs4, modules/utf8-ucs4-unsafe:
55839         * modules/unicase/*, modules/uniconv/*, modules/unictype/*:
55840         * modules/unilbrk/*, modules/uniname/*, modules/uninorm/*:
55841         * modules/unistdio/*, modules/unistr/*, modules/uniwbrk/*:
55842         * modules/uniwidth/*: Change the maintainer to 'all'.
55844 2016-10-16  Bruno Haible  <bruno@clisp.org>
55846         Simplify "configure: checking ..." messages.
55847         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use AC_MSG_CHECKING instead of
55848         AC_MSG_NOTICE.
55849         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
55851 2016-10-20  Paul Eggert  <eggert@cs.ucla.edu>
55853         quotearg-tests: pacify gcc -Wall
55854         Problem reported by Bruno Haible in:
55855         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00066.html
55856         * tests/test-quotearg-simple.c (use_quote_double_quotes): Move here ...
55857         * tests/test-quotearg.h: ... from here.
55859 2016-10-20  Pádraig Brady  <P@draigBrady.com>
55861         canonicalize-lgpl: fix for missing SIZE_MAX on older systems
55862         * lib/canonicalize-lgpl.c [SIZE_MAX]: Define if needed.
55863         Needed on Centos <= 4.
55865 2016-10-20  Jim Meyering  <meyering@fb.com>
55867         printf.m4: fix a bug in detecting printf %j support
55868         * m4/printf.m4 (gl_PRINTF_SIZES_C99): Fail any system for which
55869         uintmax_t is defined in neither stdint.h nor inttypes.h.
55870         Before, this macro might have mistakenly set
55871         gl_cv_func_printf_sizes_c99=yes on such a system.
55872         Spotted by Zev Weiss.
55874 2016-10-19  Paul Eggert  <eggert@cs.ucla.edu>
55876         sched: substitute HAVE_SYS_CDEFS_H too
55877         Problem reported by Tom G. Christensen in:
55878         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00084.html
55879         * m4/sched_h.m4 (gl_SCHED_H): Set and substitute HAVE_SYS_CDEFS_H.
55880         * modules/sched (Depends-on): Substitute HAVE_SYS_CDEFS_H.
55882 2016-10-19  Pádraig Brady  <P@draigBrady.com>
55884         quotearg: never write beyond the returned length
55885         * lib/quotearg.c (quotearg_buffer_restyled): Switch to a read-only
55886         scan of the string when we initially encounter a single quote when
55887         shell quoting, so that if we then switch to a more concise quoting method
55888         we will not have written beyond that returned length.
55889         This is significant for sh-quote, which has separate routines
55890         to determine the length and do the actual quoting.
55891         * tests/test-quotearg.h: Reinstate the buffer bounds checking
55892         now that we never write more than the returned length.
55894 2016-10-18  Bruno Haible  <bruno@clisp.org>
55896         getprogname tests: Avoid failure in packages that use libtool.
55897         * tests/test-getprogname.c (main): Strip "lt-" prefix.
55898         Based on a patch by Jim Meyering.
55900 2016-10-16  Bruno Haible  <bruno@clisp.org>
55902         getprogname: Fix test failure on Cygwin. Comments.
55903         * lib/getprogname.h: Add comments.
55904         * lib/getprogname.c: Add comments. Fix #elif indentation.
55905         * tests/test-getprogname.c (main): On Cygwin, expect a result without
55906         ".exe" suffix.
55908 2016-10-16  Bruno Haible  <bruno@clisp.org>
55910         Make sure the libunistring detection rejects older versions with a
55911         known bug.
55912         * modules/unistr/u8-strtok (configure.ac): Bump required version.
55913         * modules/unistr/u16-strtok (configure.ac): Likewise.
55914         * modules/unistr/u32-strtok (configure.ac): Likewise.
55916 2016-10-18  Bruno Haible  <bruno@clisp.org>
55918         sh-quote, system-quote: revert regression of unit test.
55919         * tests/test-sh-quote.c (check_one): Do detect buffer overruns.
55920         * tests/test-system-quote-main.c (check_one): Likewise.
55922 2016-10-16  Pádraig Brady  <P@draigBrady.com>
55924         quotearg: fix stale tests
55925         * tests/test-quotearg.c [locale_results]: Add the missing str7
55926         entries to the expected results.
55927         * tests/test-system-quote-main.c (check_one): Don't enforce that we
55928         don't write beyond the returned length, since that's no longer the
55929         case if we switch to a more concise quoting style.
55930         * tests/test-sh-quote.c (check_one): Likewise.
55931         (main): Adjust for the new more concise quoting style.
55932         Reported by Bruno Haible.
55934 2016-10-16  Jim Meyering  <meyering@fb.com>
55936         non-recursive-gnulib-prefix-hack: fix inconsequential typo
55937         * m4/non-recursive-gnulib-prefix-hack.m4: Change a hard-coded "lib"
55938         to "$1".  This macro is always invoked with $1 == lib.
55939         Spotted by Bruno Haible
55941 2016-10-16  Bruno Haible  <bruno@clisp.org>
55943         Fix a test crash.
55944         * tests/test-duplocale.c (main): Skip the test if the 'newlocale' call
55945         fails.
55947 2016-10-16  Pádraig Brady  <P@draigBrady.com>
55949         test-limits-h: suppress -Woverlength-strings
55950         * tests/test-limits-h.c [__GNUC__]: Ignore -Woverlength-strings.
55952 2016-10-15  Bruno Haible  <bruno@clisp.org>
55954         gettime, timespec, utimens: Relicense under LGPL.
55955         * modules/gettime (License): Change to LGPL.
55956         * modules/timespec (License): Likewise.
55957         * modules/utimens (License): Likewise.
55959 2016-10-14  Bruno Haible  <bruno@clisp.org>
55960             Pádraig Brady  <P@draigBrady.com>
55962         canonicalize-lgpl: Support the case path_max > INT_MAX.
55963         * lib/canonicalize-lgpl.c (__realpath): Declare n as ssize_t, not int.
55964         Fix overflow check, for platforms where 'size_t' is larger than 'long'.
55966 2016-10-13  Jim Meyering  <meyering@fb.com>
55968         getprogname: IBM z/OS: avoid NULL-dereference
55969         * lib/getprogname.c (getprogname) [__MVS__]: Don't dereference NULL
55970         upon strdup failure.
55972 2016-10-12  Jim Meyering  <meyering@fb.com>
55974         test-stdint: use _GL_VERIFY rather than "verify" for some tests
55975         * tests/test-stdint.c (verify_width): Implement with _GL_VERIFY
55976         and an abbreviated diagnostic rather than verify with the full one,
55977         because the full-length strings would evoke warnings from gcc with
55978         -Woverlength-strings.
55980 2016-10-13  Paul Eggert  <eggert@cs.ucla.edu>
55982         stdint: port SIZE_MAX to glibc s390
55983         Problem reported by Eric Blake in:
55984         http://lists.gnu.org/r/bug-gnulib/2016-10/msg00031.html
55985         * doc/posix-headers/stdint.texi (stdint.h): Document the fix.
55986         * m4/stdint.m4 (gl_STDINT_H): Check that SIZE_MAX has the
55987         correct type, if possible.
55989 2016-10-13  Daniel Richard G.  <skunk@iSKUNK.ORG>
55991         getprogname: port to IBM z/OS
55992         * lib/getprogname.c (getprogname): Use w_getpsent() to get the name.
55994 2016-10-11  Jim Meyering  <meyering@fb.com>
55996         maint: remove stray space after "." in AC_DEFINE comment.
55997         * m4/st_dm_mode.m4 (AC_STRUCT_ST_DM_MODE): Remove space-after-".".
55998         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
56000 2016-10-05  Jim Meyering  <meyering@fb.com>
56002         long-options: avoid new GCC 7 warning from -Wimplicit-fallthrough
56003         * lib/long-options.c (parse_long_options): Add a break statement
56004         to avoid this new warning/failure:
56005         $ CFLAGS='-O -Werror=implicit-fallthrough' ./gnulib-tool \
56006           --create-testdir --dir=/t/x --with-tests --test long-options
56007         ../../gllib/long-options.c: In function 'parse_long_options':
56008         ../../gllib/long-options.c:66:12: error: this statement may \
56009           fall through [-Werror=implicit-fallthrough]
56010                    (*usage_func) (EXIT_SUCCESS);
56011                    ~^~~~~~~~~~~~~~~~~~~~~~~~~~~
56013 2016-10-05  Jim Meyering  <meyering@fb.com>
56015         utimecmp: avoid new GCC 7 warning from -Wbool-operation
56016         Testing this module would fail when using GCC 7 like this:
56017         $ CFLAGS='-O -Werror=bool-operation' ./gnulib-tool --create-testdir \
56018           --dir=/tmp/x --with-tests --test utimecmp
56019         ../../gllib/utimecmp.c: In function ‘utimecmp’:
56020         ../../gllib/utimecmp.c:291:36: error: ‘~’ on a boolean expression \
56021           [-Werror=bool-operation]
56022                          time_t s = src_s & ~ (res == 2 * BILLION);
56023                                             ^
56024         ../../gllib/utimecmp.c:370:16: error: ‘~’ on a boolean expression \
56025           [-Werror=bool-operation]
56026                src_s &= ~ (res == 2 * BILLION);
56027                         ^
56028         * lib/utimecmp.c (utimecmp): Do not apply "~" to a boolean.
56029         Instead, make it explicit that we intend to apply it to 0 or 1.
56031 2016-10-10  Norihiro Tanaka  <noritnk@kcn.ne.jp>
56033         dfa: save memory for states
56034         * src/dfa (dfaexec_main): Beginning of dfa execution, release caches of
56035         states if dfa has a lot of caches.
56037 2016-10-10  Eli Zaretskii  <eliz@gnu.org>
56039         wchar, wctype-h: fix for MinGW 3.22.2
56040         * lib/wchar.in.h [__MINGW32__]: Add one more condition for
56041         special invocation, to fix issues with MinGW 3.22.2 wchar.h
56042         when included from <string.h>.
56043         * lib/wctype.in.h [__MINGW32__]: Add special invocation
56044         convention for MinGW 3.22.2, to solve issues with their
56045         wctype.h when included from <ctype.h>.
56047 2016-10-05  Jim Meyering  <meyering@fb.com>
56049         long-options: avoid new GCC 7 warning from -Wimplicit-fallthrough
56050         * lib/long-options.c (parse_long_options): Add a break statement
56051         to avoid this new warning/failure:
56052         $ CFLAGS='-O -Werror=implicit-fallthrough' ./gnulib-tool \
56053           --create-testdir --dir=/t/x --with-tests --test long-options
56054         ../../gllib/long-options.c: In function ‘parse_long_options’:
56055         ../../gllib/long-options.c:66:12: error: this statement may \
56056           fall through [-Werror=implicit-fallthrough]
56057                    (*usage_func) (EXIT_SUCCESS);
56058                    ~^~~~~~~~~~~~~~~~~~~~~~~~~~~
56060         utimecmp: avoid new GCC 7 warning from -Wbool-operation
56061         Testing this module would fail when using GCC 7 like this:
56062         $ CFLAGS='-O -Werror=bool-operation' ./gnulib-tool --create-testdir \
56063           --dir=/tmp/x --with-tests --test utimecmp
56064         ../../gllib/utimecmp.c: In function ‘utimecmp’:
56065         ../../gllib/utimecmp.c:291:36: error: ‘~’ on a boolean expression \
56066           [-Werror=bool-operation]
56067                          time_t s = src_s & ~ (res == 2 * BILLION);
56068                                             ^
56069         ../../gllib/utimecmp.c:370:16: error: ‘~’ on a boolean expression \
56070           [-Werror=bool-operation]
56071                src_s &= ~ (res == 2 * BILLION);
56072                         ^
56073         * lib/utimecmp.c (utimecmp): Do not apply "~" to a boolean.
56074         Instead, make it explicit that we intend to apply it to 0 or 1.
56076 2016-10-03  Pádraig Brady  <P@draigBrady.com>
56078         quotearg: minimize shell quoting using double quotes
56079         * lib/quotearg.c (quotearg_buffer_restyled): If an ASCII single
56080         quote in encountered then use double quotes (c style quoting)
56081         when possible, as it simplifies the quoting.
56082         * tests/test-quotearg-simple.c: Add test cases.
56083         * tests/test-quotearg.h (use_quotearg_buffer): Adjust to account
56084         for the fact we now may write beyond the returned length.
56086 2016-10-02  Jim Meyering  <meyering@fb.com>
56088         vasnprintf.c: avoid spurious warning from GCC 7
56089         The presence of cpp directives renders this "FALLTHROUGH" comment
56090         ineffective, so does not suppress the -Wimplicit-fallthrough warning
56091         from GCC 7 built from git on 2016-10-02.
56092         * lib/vasnprintf.c (VASNPRINTF): Move comment down past two cpp
56093         directives, so that it takes effect once again.  This is clearly
56094         not a proper change, and I will revert it once this bug is fixed:
56095         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77817
56097 2016-10-01  Jim Meyering  <meyering@fb.com>
56099         getprogname: correct the test for a __progname variable
56100         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Use AC_CACHE_CHECK
56101         and AC_LINK_IFELSE to check for a global __progname.  If found,
56102         define HAVE_VAR___PROGNAME.
56103         * lib/getprogname.c (getprogname): Reflect the new name of the
56104         feature- checked preprocessor symbol:
56105         s/HAVE_DECL___PROGNAME/HAVE_VAR___PROGNAME/
56107 2016-09-28  Jim Meyering  <meyering@fb.com>
56109         u8-uctomb-aux.c: build: placate GCC 7's new -Wimplicit-fallthrough
56110         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Mark each end of
56111         fall-through case with a /* fallthrough */ comment.
56113         dfa: build: avoid warning from GCC 7's new -Wimplicit-fallthrough
56114         * lib/dfa.c (dfassbuild): Mark the end of this case with a
56115         /* fallthrough */ comment.
56117         getprogname: avoid __progname vs program_invocation_short_name pitfall
56118         I.e., don't let the OpenBSD 5.1 fix induce failure when using newer
56119         glibc.  Would have caused failure with Fedora 25's glibc-2.24-3, but
56120         not with Fedora 24's glibc-2.23.1-10.
56121         * lib/getprogname.c (__progname): Move this declaration down...
56122         (getprogname): ... into the #elif block where used, and make it
56123         explicitly "extern".
56125         getprogname: port to OpenBSD 5.1
56126         * lib/getprogname.c (__progname) [HAVE_DECL___PROGNAME]: Declare.
56127         (getprogname) [HAVE_DECL___PROGNAME]: Return __progname or "?".
56128         * modules/getprogname (configure.ac): Move most of this code...
56129         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): ... to this function,
56130         increment serial number, and add a test for __progname.
56131         https://bugs.gnu.org/24562
56132         Reported by Nelson H. F. Beebe.
56134 2016-09-24  Paul Eggert  <eggert@cs.ucla.edu>
56136         sched: port to GCC 6.2.1 on macOS Sierra
56137         Problem reported by Denis Davydov in:
56138         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00056.html
56139         * lib/sched.in.h [HAVE_SYS_CDEFS_H]:
56140         Include <sys/cdefs.h> before <sched.h>.
56141         * m4/nproc.m4 (gl_PREREQ_NPROC): Include errno.h before sched.h,
56142         so that we needn’t worry about the sched.h include bug here.
56143         * m4/sched_h.m4 (gl_SCHED_H): Check for sys/cdefs.h,
56144         and include it before <sched.h> if it exists, when
56145         checking for <sched.h>.
56147         tests/init.sh: port Alpine fix to AIX 7.1
56148         * tests/init.sh (compare_): When attempting to use diff -U3,
56149         prefer diff -u to -U3 to -c to plain diff.  Do not insist on
56150         diff -u not outputting a space after leading '+', as the users
56151         of 'compare' should not be that picky about its output format.
56152         In the AIX 7.1 case, return with diff exit status (or with 2 if
56153         trouble), instead of some random nonzero exit status.
56154         * tests/test-init.sh (test_compare): Remove space after leading
56155         '+', so that AIX 7.1 'diff' passes the test.
56157 2016-09-22  Paul Eggert  <eggert@cs.ucla.edu>
56159         nl_langinfo: pacify GCC
56160         * lib/nl_langinfo.c (ctype_codeset): Remove unused local.
56161         (rpl_nl_langinfo): Cast string literals to char *, to pacify GCC.
56163         stdint: also set GL_GENERATE_LIMITS_H
56164         Problem reported by Jim Meyering in:
56165         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00052.html
56166         * m4/stdint.m4 (gl_STDINT_H): Also redo the AM_CONDITIONAL.
56168         limits-h, stdint: Don't assume extensions, fix typo
56169         * m4/limits-h.m4 (gl_LIMITS_H):
56170         * m4/stdint.m4 (gl_STDINT_H):
56171         Don't assume AC_USE_SYSTEM_EXTENSIONS.
56172         * m4/stdint.m4 (gl_STDINT_H): Fix typo in setting of LIMITS_H,
56173         reported by Jim Meyering in:
56174         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00050.html
56176 2016-09-21  Jim Meyering  <meyering@fb.com>
56178         getprogname: port to AIX
56179         * lib/getprogname.c (getprogname) [_AIX]: Use getpid, getprocs64
56180         and strdup to obtain a short program name string.  Using code from
56181         Bruno Haible and an idea from Bastien ROUCARIÈS, in
56182         https://lists.gnu.org/r/bug-gnulib/2010-12/msg00249.html
56183         Assaf Gordon reported that this new file would fail to compile on
56184         AIX-7.1 32bit.
56186 2016-09-16  Paul Eggert  <eggert@cs.ucla.edu>
56188         extensions: fix typo in comment
56189         * m4/extensions.m4: Sync from Autoconf master.
56191         stdint: support new _WIDTH macros
56192         * doc/posix-headers/stdint.texi: Document this.
56193         * lib/stdint.in.h: Add support for INTMAX_WIDTH. etc.
56194         * m4/stdint.m4 (gl_STDINT_H): Require gl_LIMITS_H.  Check for
56195         support for INTMAX_WIDTH, etc. as well as for support for just C99.
56196         * modules/stdint (Depends-on): Add limits-h.
56197         (Makefile.am): Substitute HAVE_C99_STDINT_H.
56198         * modules/stdint-tests (Depends-on): Add extensions, so that
56199         INTMAX_MAX etc. are defined.
56200         * tests/test-stdint.c: Verify the new macros.
56202         limits-h: new module
56203         This adds ISO/IEC TS 18661-1:2014 support to limits.h.
56204         * MODULES.html.sh: Add limits-h,and move size_max to stdint section.
56205         * doc/posix-headers/limits.texi: Document new module.
56206         * lib/limits.in.h, m4/limits-h.m4, modules/limits-h:
56207         * modules/limit-h-tests, tests/test-limits-h.c: New files.
56209         stdio: don't redefine __USE_MINGW_ANSI_STDIO
56210         * m4/stdio_h.m4 (gl_STDIO_H): Don't define __USE_MINGW_ANSI_STDIO
56211         if it is already defined.  Apparently GNU Emacs relies on this.  See:
56212         http://lists.gnu.org/r/emacs-devel/2016-09/msg00416.html
56214 2016-09-15  Eric Blake  <eblake@redhat.com>
56216         sys_types: avoid glibc 2.25 warnings about major()
56217         * m4/sys_types_h.m4 (AC_HEADER_MAJOR): Replace broken version in
56218         older autoconf.
56219         * doc/posix-headers/sys_types.texi (sys/types.h): Document fix.
56220         * doc/glibc-functions/gnu_dev_major.texi (gnu_dev_major): Likewise.
56221         * doc/glibc-functions/gnu_dev_makedev.texi (gnu_dev_makedev): Likewise.
56222         * doc/glibc-functions/gnu_dev_minor.texi (gnu_dev_minor): Likewise.
56224         mountlist: include sysmacros.h for glibc
56225         * m4/mountlist.m4 (gl_PREREQ_MOUTLIST_EXTRA): Include
56226         AC_HEADER_MAJOR.
56227         * lib/mountlist.c (includes): Use correct headers.
56229 2016-09-15  Paul Eggert  <eggert@cs.ucla.edu>
56231         extensions: port to more ISO C TSes
56232         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Sync from Autoconf
56233         master, to add support for more recent ISO C TRs and TSes.
56235 2016-09-13  Paul Eggert  <eggert@cs.ucla.edu>
56237         intprops: new macro TYPE_WIDTH
56238         * lib/intprops.h (TYPE_WIDTH): New macro.
56239         (TYPE_MAXIMUM, _GL_SIGNED_INT_MAXIMUM, INT_STRLEN_BOUND):
56240         * lib/ftoastr.h (_GL_FLOAT_DIG_BITS_BOUND):
56241         * lib/parse-datetime.y (parse_datetime2):
56242         Use it.
56244         extensions: port to recent ISO C TRs
56245         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
56246         Sync from Autoconf master, to add support for recent ISO C TRs.
56247         * m4/stdio_h.m4 (gl_STDIO_H): Define __USE_MINGW_ANSI_STDIO here,
56248         since AC_USE_SYSTEM_EXTENSIONS no longer does that as
56249         the MinGW option is not an extension.
56251 2016-09-11  Paul Eggert  <eggert@cs.ucla.edu>
56253         dfa: port to Solaris 9
56254         Problems reported by Tom G. Christensen in:
56255         http://lists.gnu.org/r/bug-gnulib/2016-09/msg00031.html
56256         * modules/dfa (Depends-on): Add isblank.
56257         * modules/dfa-tests (dfa_match_aux_LDADD):
56258         Rename from test_stat_LDADD, to fix typo.
56259         * tests/dfa-match.sh: Don't require 'timeout'; use it if available.
56261 2016-09-10  Jim Meyering  <meyering@fb.com>
56263         strverscmp: avoid link failure on OS X
56264         * lib/strverscmp.c [!weak_alias]: Define __strverscmp to strverscmp.
56265         Reported by Assaf Gordon in https://bugs.gnu.org/24256#26
56267 2016-08-16  Jim Meyering  <meyering@fb.com>
56269         dfa: new module, importing grep's DFA matcher
56270         Since grep's DFA matcher is now being used by two gnulib-enabled
56271         projects, grep and sed, it makes sense to version-control its
56272         sources and unit tests in one place: here.
56273         * modules/dfa: New module.
56274         * modules/dfa-tests: New file.
56275         * lib/dfa.c: New file, from grep.
56276         * lib/dfa.h: Likewise.
56277         * lib/localeinfo.c: Likewise.
56278         * lib/localeinfo.h: Likewise.
56279         * tests/dfa-match-aux.c: Likewise.
56280         * tests/dfa-invalid-char-class.sh: Likewise.
56281         * tests/dfa-match.sh: Likewise, with minor changes.
56282         * MODULES.html.sh (Misc): Add "dfa" to this list.
56284 2016-09-09  Jim Meyering  <meyering@fb.com>
56286         getprogname-tests: don't depend on assert-h
56287         * modules/getprogname-tests (Depends-on): Remove assert-h.
56288         It was not needed, and in fact would cause build failure for
56289         coreutils on some systems.  Reported by Assaf Gordon in https:
56290         //lists.gnu.org/r/coreutils/2016-09/msg00016.html
56292 2016-09-07  Jim Meyering  <meyering@fb.com>
56294         getprogname-tests: work also when EXEEXT is nonempty
56295         * modules/getprogname-tests (Makefile.am): Define EXEEXT.
56296         * tests/test-getprogname.c (main): Use it.
56297         Suggested by Gisle Vanem.
56299 2016-09-07  Gisle Vanem  <gvanem@yahoo.no>
56301         getprogname: fix errors in previous change
56302         * lib/getprogname.c (getprogname) [HAVE_GETEXECNAME]:
56303         s/program_invocation_name/base/
56304         [HAVE_DECL___ARGV]: Handle NULL __argv or __argv[0].
56306 2016-09-08  Pádraig Brady  <P@draigBrady.com>
56308         parse-datetime: restrict debug output to input string
56309         * lib/parse-datetime.y (parse_datetime2): If we parse
56310         all of the input but determine it's invalid, ensure
56311         we don't output the now invalid input pointer.
56312         This issue was seen with `date -d 'now +1'`.
56314 2016-09-07  Paul Eggert  <eggert@cs.ucla.edu>
56316         flexmember: new macro FLEXALIGNOF
56317         * lib/flexmember.h: Include <stddef.h>, for offsetof.
56318         (FLEXALIGNOF): Rename from _GL_XALLOC_ALIGNOF, as Emacs can use
56319         this macro.  Update comments.
56321 2016-09-07  Jim Meyering  <meyering@fb.com>
56323         getprogname: port to systems with __argv (mingw, msvc)
56324         * lib/getprogname.c (getprogname): Include "dirname.h" and use
56325         last_component: more general than open coding it with hard-coded "/".
56326         * lib/getprogname.h (getprogname): Prefer "char const *" consistently.
56327         * modules/getprogname (Depends-on): Add dirname-lgpl.
56328         (configure.ac): Check for __argv in <stdlib.h>.
56329         * modules/getprogname-tests: New file.
56330         * tests/test-getprogname.c: New file.
56331         Suggested by Gisle Vanem in
56332         https://lists.gnu.org/r/bug-gnulib/2016-09/msg00014.html
56334 2016-09-07  Paul Eggert  <eggert@cs.ucla.edu>
56336         flexmember: port better to GCC + valgrind
56337         With a char[] flexible array member in a struct with nontrivial
56338         alignment, GCC-generated code can access past the end of the
56339         array, because GCC assumes there are padding bytes to get the
56340         struct aligned.  So the common idiom of malloc (offsetof (struct
56341         s, m), n) does not properly allocate an n-byte trailing member, as
56342         malloc’s argument should be the next multiple of alignof (struct s).
56343         See GCC Bug#66661: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66661
56344         Although C11 apparently permits this GCC optimization (i.e., there
56345         was a bug in Gnulib not in GCC), possibly this is a defect in C11.
56346         See the thread containing:
56347         https://gcc.gnu.org/ml/gcc-patches/2016-09/msg00317.html
56348         * lib/flexmember.h: New file.
56349         * lib/fnmatch.c, lib/fts.c, lib/glob.c, lib/idcache.c:
56350         * lib/localename.c, lib/time_rz.c:
56351         Include flexmember.h.
56352         * lib/fnmatch_loop.c (struct patternlist):
56353         * lib/localename.c (struct hash_node):
56354         Use FLEXIBLE_ARRAY_MEMBER.
56355         * lib/fnmatch_loop.c (EXT):
56356         * lib/fts.c (fts_alloc):
56357         * lib/glob.c (glob_in_dir):
56358         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
56359         * lib/localename.c (gl_lock_define_initialized):
56360         * lib/time_rz.c (tzalloc):
56361         Use FLEXSIZEOF instead of offsetof.
56362         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
56363         Check that the size of the struct can be taken.
56364         * modules/flexmember (Files): Add lib/flexmember.h.
56365         * modules/fnmatch, modules/glob, modules/localename (Depends-on):
56366         Add flexmember.
56368 2016-09-06  Paul Eggert  <eggert@cs.ucla.edu>
56370         getprogname: port to Solaris 10
56371         * lib/getprogname.c: Include stdlib.h, for getexecname decl.
56372         (getprogname) [HAVE_GETEXECNAME]: Use that, for Solaris 10.
56373         * m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Check for getexecname.
56375         stdalign: correct mistake in alignof doc
56376         Problem reported by Joseph Myers in:
56377         https://gcc.gnu.org/ml/gcc-patches/2016-09/msg00340.html
56378         * doc/posix-headers/stdalign.texi: Do not imply that C11 prohibits
56379         alignof(S) where S is a structure containing a flexible array
56380         member.  The Gnulib substitute does not support this, but C11 does.
56382 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
56384         main.mk: remove sc_program_name, since there is no more need to
56385         use set_program_name in tools (getprogname is enough for most
56386         of the cases).
56387         * cfg.mk (local-checks-to-skip): Remove sc_program_name.
56388         * top/maint.mk (sc_program_name): Remove.
56390 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
56392         Port tests away from progname, since modules that need the
56393         program name already depend on getprogname.
56394         * modules/acl-tests (Depends-on): Remove progname.
56395         * modules/argmatch (Depends-on): Likewise.
56396         * modules/argmatch-tests (Depends-on): Likewise.
56397         * modules/argp-tests (Depends-on): Likewise.
56398         * modules/argp-version-etc-tests (Depends-on): Likewise.
56399         * modules/array-list-tests (Depends-on): Likewise.
56400         * modules/array-oset-tests (Depends-on): Likewise.
56401         * modules/avltree-list-tests (Depends-on): Likewise.
56402         * modules/avltree-oset-tests (Depends-on): Likewise.
56403         * modules/avltreehash-list-tests (Depends-on): Likewise.
56404         * modules/carray-list-tests (Depends-on): Likewise.
56405         * modules/copy-file-tests (Depends-on): Likewise.
56406         * modules/exclude-tests (Depends-on): Likewise.
56407         * modules/fchownat-tests (Depends-on): Likewise.
56408         * modules/fdopendir-tests (Depends-on): Likewise.
56409         * modules/filenamecat-tests (Depends-on): Likewise.
56410         * modules/fstatat-tests (Depends-on): Likewise.
56411         * modules/fstrcmp-tests (Depends-on): Likewise.
56412         * modules/linked-list-tests (Depends-on): Likewise.
56413         * modules/linkedhash-list-tests (Depends-on): Likewise.
56414         * modules/mkdirat-tests (Depends-on): Likewise.
56415         * modules/nonblocking-pipe-tests (Depends-on): Likewise.
56416         * modules/nonblocking-socket-tests (Depends-on): Likewise.
56417         * modules/obstack-printf-tests (Depends-on): Likewise.
56418         * modules/openat-tests (Depends-on): Likewise.
56419         * modules/parse-datetime-tests (Depends-on): Likewise.
56420         * modules/pipe-filter-gi-tests (Depends-on): Likewise.
56421         * modules/pipe-filter-ii-tests (Depends-on): Likewise.
56422         * modules/quotearg-simple-tests (Depends-on): Likewise.
56423         * modules/quotearg-tests (Depends-on): Likewise.
56424         * modules/rbtree-list-tests (Depends-on): Likewise.
56425         * modules/rbtree-oset-tests (Depends-on): Likewise.
56426         * modules/rbtreehash-list-tests (Depends-on): Likewise.
56427         * modules/spawn-pipe-tests (Depends-on): Likewise.
56428         * modules/system-quote-tests (Depends-on): Likewise.
56429         * modules/uniname/uniname-tests (Depends-on): Likewise.
56430         * modules/uninorm/nfc-tests (Depends-on): Likewise.
56431         * modules/uninorm/nfd-tests (Depends-on): Likewise.
56432         * modules/uninorm/nfkc-tests (Depends-on): Likewise.
56433         * modules/uninorm/nfkd-tests (Depends-on): Likewise.
56434         * modules/unistdio/u16-vsnprintf-tests (Depends-on): Likewise.
56435         * modules/unistdio/u16-vsprintf-tests (Depends-on): Likewise.
56436         * modules/unistdio/u32-vsnprintf-tests (Depends-on): Likewise.
56437         * modules/unistdio/u32-vsprintf-tests (Depends-on): Likewise.
56438         * modules/unistdio/u8-vsnprintf-tests (Depends-on): Likewise.
56439         * modules/unistdio/u8-vsprintf-tests (Depends-on): Likewise.
56440         * modules/unistdio/ulc-vsnprintf-tests (Depends-on): Likewise.
56441         * modules/unistdio/ulc-vsprintf-tests (Depends-on): Likewise.
56442         * modules/unlinkat-tests (Depends-on): Likewise.
56443         * modules/version-etc-tests (Depends-on): Likewise.
56444         * modules/xalloc-die-tests (Depends-on): Likewise.
56445         * modules/xmemdup0-tests (Depends-on): Likewise.
56446         * modules/xprintf-posix-tests (Depends-on): Likewise.
56447         * modules/xvasprintf-tests (Depends-on): Likewise.
56448         * tests/test-argmatch.c: Do not include progname.h.
56449         (main) Stop calling set_program_name.
56450         * tests/test-argp-version-etc.c: Likewise.
56451         * tests/test-argp.c: Likewise.
56452         * tests/test-argv-iter.c: Likewise.
56453         * tests/test-array_list.c: Likewise.
56454         * tests/test-array_oset.c: Likewise.
56455         * tests/test-avltree_list.c: Likewise.
56456         * tests/test-avltree_oset.c: Likewise.
56457         * tests/test-avltreehash_list.c: Likewise.
56458         * tests/test-carray_list.c: Likewise.
56459         * tests/test-copy-acl.c: Likewise.
56460         * tests/test-copy-file.c: Likewise.
56461         * tests/test-exclude.c: Likewise.
56462         * tests/test-fchownat.c: Likewise.
56463         * tests/test-fdopendir.c: Likewise.
56464         * tests/test-filenamecat.c: Likewise.
56465         * tests/test-fstatat.c: Likewise.
56466         * tests/test-fstrcmp.c: Likewise.
56467         * tests/test-linked_list.c: Likewise.
56468         * tests/test-linkedhash_list.c: Likewise.
56469         * tests/test-mkdirat.c: Likewise.
56470         * tests/test-nonblocking-pipe-main.c: Likewise.
56471         * tests/test-nonblocking-socket-main.c: Likewise.
56472         * tests/test-obstack-printf.c: Likewise.
56473         * tests/test-openat.c: Likewise.
56474         * tests/test-parse-datetime.c: Likewise.
56475         * tests/test-pipe-filter-gi1.c: Likewise.
56476         * tests/test-pipe-filter-gi2-main.c: Likewise.
56477         * tests/test-pipe-filter-ii1.c: Likewise.
56478         * tests/test-pipe-filter-ii2-main.c: Likewise.
56479         * tests/test-quotearg-simple.c: Likewise.
56480         * tests/test-quotearg.c: Likewise.
56481         * tests/test-rbtree_list.c: Likewise.
56482         * tests/test-rbtree_oset.c: Likewise.
56483         * tests/test-rbtreehash_list.c: Likewise.
56484         * tests/test-sameacls.c: Likewise.
56485         * tests/test-set-mode-acl.c: Likewise.
56486         * tests/test-spawn-pipe-main.c: Likewise.
56487         * tests/test-system-quote-main.c: Likewise.
56488         * tests/test-unlinkat.c: Likewise.
56489         * tests/test-version-etc.c: Likewise.
56490         * tests/test-xalloc-die.c: Likewise.
56491         * tests/test-xfprintf-posix.c: Likewise.
56492         * tests/test-xmemdup0.c: Likewise.
56493         * tests/test-xprintf-posix.c: Likewise.
56494         * tests/test-xvasprintf.c: Likewise.
56495         * tests/uniname/test-uninames.c: Likewise.
56496         * tests/uninorm/test-u32-nfc-big.c: Likewise.
56497         * tests/uninorm/test-u32-nfd-big.c: Likewise.
56498         * tests/uninorm/test-u32-nfkc-big.c: Likewise.
56499         * tests/uninorm/test-u32-nfkd-big.c: Likewise.
56500         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
56501         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
56502         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
56503         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
56504         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
56505         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
56506         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
56507         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
56508         * tests/test-c-stack.c: (program_name): Do not define.
56509         (main): Do not set program_name.
56510         * tests/test-closein.c: Likewise.
56511         * tests/test-xstrtol.c: Likewise.
56512         * tests/test-yesno.c: Likewise.
56514 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
56516         Port modules to use getprogname explicitly, instead of requiring
56517         progname to be used (or program_name to be provided).
56518         * lib/argmatch.c: Do not include progname.h.
56519         [TEST] (program_name): Do not define.
56520         [TEST] (main): Call getprogname instead of using program_name.
56521         * lib/c-stack.c: Do not include progname.h.
56522         (program_name): Do not define.
56523         (die): Call getprogname instead of using program_name.
56524         * lib/chdir-long.c: Do not include progname.h.
56525         [TEST_CHDIR] (main): Do not set program_name.
56526         * lib/error.c [!_LIBC]: Include progname.h.
56527         [!_LIBC] (program_name): Define using getprogname.
56528         * lib/euidaccess.c: Do not include progname.h.
56529         [TEST] (main): Do not set program_name.
56530         * lib/git-merge-changelog.c: Include getprogname.h instead of
56531         progname.h.
56532         (usage): Call getprogname instead of using program_name.
56533         (main): Likewise.  Stop calling set_program_name.
56534         * lib/group-member.c: Do not include progname.h.
56535         [TEST] (main): Do not set program_name.
56536         * modules/argmatch (Depends-on): Add getprogname.
56537         * modules/c-stack (Depends-on): Likewise.
56538         * modules/error (Depends-on): Likewise.
56539         * modules/git-merge-changelog (Depends-on): Likewise.
56540         Also remove progname.
56542 2016-09-05  Pino Toscano  <ptoscano@redhat.com>
56544         * NEWS: Document the deprecation of the 'progname' module.
56546 2016-08-18  Pino Toscano  <ptoscano@redhat.com>
56548         getprogname: new module
56549         This provides a LGPL module for getting the name of the current
56550         program, using the same API found on *BSD systems.
56551         * lib/getprogname.c, lib/getprogname.h, m4/getprogname.m4:
56552         * modules/getprogname: New files.
56553         * MODULES.html.sh (Misc): Add getprogname.
56555 2016-09-02  Jim Meyering  <meyering@fb.com>
56557         manywarnings: add -fno-common
56558         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -fno-common
56559         to the list.  Quoting the manual, "Compiling with -fno-common is
56560         useful on targets for which it provides better performance, or if
56561         you wish to verify that the program will work on other systems that
56562         always treat uninitialized variable declarations this way [putting
56563         it in the data section]."  If diffutils had been using this sooner,
56564         it would have prevented this duplicate declaration issue:
56565         http://git.sv.gnu.org/cgit/diffutils.git/commit/?id=v3.4-10-gc2dc91f
56567 2016-08-31  Simon Josefsson  <simon@josefsson.org>
56569         parse-datetime: Fix typo.
56570         * lib/parse-datetime.y (parse_datetime2): Fix typo.
56572 2016-08-30  Paul Eggert  <eggert@cs.ucla.edu>
56574         intprops: tune INT_NEGATE_OVERFLOW for GCC 5 and 6
56575         * lib/intprops.h (INT_NEGATE_OVERFLOW): Tune for platforms like
56576         GCC 5 and 6 that have __builtin_sub_overflow but not
56577         __builtin_sub_overflow_p.  With the recent changes, these
56578         platforms are a tiny bit faster with the INT_NEGATE_RANGE_OVERFLOW
56579         implementation than with INT_SUBTRACT_OVERFLOW implementation,
56580         since the former needs just one runtime comparison whereas the
56581         latter needs two.
56583         strverscmp: sync with glibc
56584         Although this doesn't exactly synchronize with glibc
56585         byte-for-byte, it makes the code behave the same as glibc.
56586         * lib/strverscmp.c (S_I, S_F, S_Z): Now masks, not powers of 2.
56587         (ISDIGIT): Remove, as glibc is sticking with isdigit, and the
56588         difference shouldn't matter in practical use.  All uses changed
56589         back to isdigit.
56590         (__strverscmp, strverscmp): Use new glibc method for weak aliases.
56591         (next_state): Now unsigned char array; redo elements.
56592         (result_type): Now signed char array; redo elements.
56593         (__strverscmp): Fix glibc bug 9913 by using new states.
56594         * tests/test-strverscmp.c (main): Test glibc bug 9913.
56596 2016-08-29  Jim Meyering  <meyering@fb.com>
56598         xalloc-oversized.h: port __builtin_mul_overflow change to GCC 6.2.0
56599         * lib/xalloc-oversized.h: Port this change to GCC 6.2.0, too,
56600         similarly to how it was done to intprops.h.
56602 2016-08-29  Paul Eggert  <eggert@cs.ucla.edu>
56604         intprops.h: port recent changes to GCC 6.2.0
56605         * lib/intprops.h (__has_builtin): Move earlier.
56606         (_GL_HAS_BUILTIN_OVERFLOW): Rename from
56607         _GL_HAS_BUILTIN_OVERFLOW_WITH_NULL and don't worry about whether
56608         the last argument can be null.  All uses changed.
56609         (_GL_HAS_BUILTIN_OVERFLOW_P): Also test __has_builtin.
56610         (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW, _GL_MULTIPLY_OVERFLOW):
56611         Don't try to use 3rd arg null, as this doesn't work on GCC 6.2.0
56612         and it's not clear which GCC versions it works for.
56613         (_GL_INT_OP_WRAPV): Use _GL_HAS_BUILTIN_OVERFLOW instead of
56614         its definiens.
56616         intprops.h: use __typeof__ with GCC 7
56617         * lib/intprops.h (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW)
56618         (_GL_MULTIPLY_OVERFLOW): Use __typeof__ as in the GCC manual.
56619         This avoids computing the expression's value (which might overflow!).
56621 2016-08-29  Jim Meyering  <meyering@fb.com>
56623         intprops.h, xalloc-oversized.h: work with gcc 7
56624         In gcc 6, __builtin_add_overflow, __builtin_sub_overflow and
56625         __builtin_mul_overflow each accept a NULL pointer as the third
56626         argument.  However in gcc 7, that is no longer accepted.
56627         Instead, one must use the "_p"-suffixed names, with which, the
56628         third parameter is no longer a pointer.
56629         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_WITH_NULL): Correct
56630         the definition: not true for gcc 7 and subsequent.
56631         (_GL_HAS_BUILTIN_OVERFLOW_P): Define.
56632         (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW, _GL_MULTIPLY_OVERFLOW):
56633         Provide new definitions for gcc 7 and subsequent.
56634         * lib/xalloc-oversized.h (xalloc_oversized): Provide a definition
56635         that works with gcc-7.
56637         intprops.h: fix missing-backslash problems
56638         * lib/intprops.h (_GL_ADD_OVERFLOW): Add backslash.
56639         (_GL_SUBTRACT_OVERFLOW,_GL_MULTIPLY_OVERFLOW): Likewise.
56641 2016-08-24  Paul Eggert  <eggert@cs.ucla.edu>
56643         intprops: fix paren typo on old platforms
56644         Problem reported by John E. Malmberg in: https://bugs.gnu.org/24300#13
56645         * lib/intprops.h (_GL_INT_OP_WRAPV_LONGISH)
56646         [__GNUC__ < 5 && !__has_builtin (__builtin_add_overflow)
56647         && (__STDC_VERSION__ < 201112 || _GL__GENERIC_BOGUS)
56648         && !defined LLONG_MAX]:
56649         Remove stray paren.
56651         intprops: port to OpenVMS
56652         Problem reported by John E. Malmberg in: https://bugs.gnu.org/24300
56653         * doc/posix-headers/limits.texi: Document the problem.
56654         * lib/intprops.h (LLONG_MAX, LLONG_MIN) [__INT64_MAX]:
56655         Define if not already defined.
56657 2016-08-19  Assaf Gordon  <assafgordon@gmail.com>
56659         parse-datetime: improve debug implementation
56660         Follow-up to commit 12ad79069 ("add optional debug printing").
56661         Improve parse-datetime's debug implementation: remove macros,
56662         replace global debug flag variable with a function parameter,
56663         use nstrftime for formatting.
56664         See: https://lists.gnu.org/r/bug-gnulib/2016-08/msg00021.html
56665         * lib/parse-datetime.h: (parse_datetime_debug): Remove global extern.
56666         (parse_datetime2): New function, accepts 'flags' parameter, supporting
56667         debug flag. Existing interface 'parse_datetime' left unmodified.
56668         * lib/parse-datetime.c: (parse_datetime_debug): Remove global variable.
56669         (struct parser_control): add 'parse_datetime_debug' member variable.
56670         (parse_datetime): Call new function 'parse_datetime2' without debug.
56671         (parse_datetime2): Adapted from previous 'parse_datetime', initialize
56672         pc.parse_datetime_debug variable as needed.
56673         (to_year): Accept new flags parameter, instead of using global variable.
56674         (debug_print_current_time,debug_print_relative_time,debug_mktime_not_ok):
56675         use struct 'debug' variable instead of global variable.
56676         (DEBUG,DEBUG_PRINT_CURRENT_TIME,DEBUG_PRINT_RELATIVE_TIME,
56677         DEBUG_MKTIME_NOT_OK,PROGRESS,PROGRESS0): Remove macros. Call
56678         correspnding functions directly instead of using macros.
56679         * modules/parse-datetime: Add gnulib's strftime module.
56681 2016-08-19  Daniel Richard G.  <skunk@iSKUNK.ORG>
56683         c-strcase-tests: port to EBCDIC
56684         * tests/test-c-strncasecmp.c: Allow two c_strncasecmp calls
56685         which assume ASCII encoding semantics to run only in ASCII
56686         mode, as they fail in EBCDIC.
56688         sigpipe-tests: fix typo
56689         * tests/test-sigpipe.sh: C, not B.
56691 2016-08-18  Paul Eggert  <eggert@cs.ucla.edu>
56693         canonicalize-lgpl: fix errno after malloca fails
56694         This fixes a typo I recently introduced.  Suggested by Bruno Haible in:
56695         http://lists.gnu.org/r/bug-gnulib/2016-08/msg00039.html
56696         * lib/canonicalize-lgpl.c (__realpath):
56697         Don't assume malloca sets errno on failure.
56699 2016-08-17  Paul Eggert  <eggert@cs.ucla.edu>
56701         strtod: port errno handling to z/OS
56702         * lib/strtod.c (strtod): Save and restore errno more reliably.
56704 2016-08-17  Daniel Richard G.  <skunk@iSKUNK.ORG>
56706         strtod: port to z/OS
56707         * lib/strtod.c (strtod): Address a couple quirks in the z/OS
56708         implementation.
56710 2016-08-17  Paul Eggert  <eggert@cs.ucla.edu>
56712         strtod: port to z/OS
56713         * lib/strtod.c (strtod): Address a couple quirks in the z/OS
56714         implementation.
56716         regex, string: rename to avoid '__string'
56717         * lib/regex.h, lib/string.in.h: Do not use the identifier
56718         '__string', as it is effectively reserved by string.h on z/OS.
56720         c-strcase-tests, wcwidth-tests: depend on c-ctype
56721         * modules/c-strcase-tests, modules/wcwidth-tests (Depends-on):
56722         Add c-ctype.
56724 2016-08-17  Daniel Richard G.  <skunk@iSKUNK.ORG>
56726         thread: port to z/OS
56727         * lib/glthread/thread.c, lib/glthread/thread.h:
56728         Rudimentary gl_thread support for z/OS.
56730         maint: port tests to z/OS errno behavior
56731         * tests/test-nonblocking-reader.h:
56732         * tests/test-nonblocking-writer.h:
56733         Accommodate z/OS errno code preferences. (I believe this should
56734         still be within spec; IBM is good at following the letter if not
56735         the spirit of such things.)
56737         maint: preprocessor changes to support z/OS
56738         * lib/alloca.in.h, lib/fnmatch.c, lib/get-rusage-as.c:
56739         * lib/glob.c, lib/math.in.h, lib/ptsname_r.c:
56740         * tests/infinity.h, tests/nan.h, tests/test-canonicalize-lgpl.c:
56741         * tests/test-nonblocking-pipe.h:
56743         fclose, strstr-simple, wchar: port to z/OS
56744         * m4/fclose.m4, m4/strstr.m4, m4/wchar_h.m4:
56745         Changes to the Autoconf M4 code to support z/OS.  Note that
56746         fclose() is broken in a different way on z/OS than it is on other
56747         systems, thus the special-case in fclose.m4.
56749         iconv_open-utf-tests, iconv-tests: port to EBCDIC
56750         * tests/test-iconv-utf.c, tests/test-iconv.c:
56751         Added appropriately conditional #pragmas so that the test strings
56752         in test-iconv-utf.c are correctly interpreted in ASCII instead of
56753         EBCDIC (i.e. 'J' == 0x4A and not 0xD1). This issue could be
56754         addressed in a more portable way by simply rewriting all the ASCII
56755         literal characters as octal escapes, but then you would lose the
56756         partial readability that the strings have now. Also, iconv_open()
56757         on z/OS does not recognize "ISO-8859-1", but "ISO8859-1" works.
56759         c-strcase-tests, wcwidth-tests: port to EBCDIC
56760         * tests/test-c-strcasecmp.c: Include c-ctype.h.
56761         (main) [!C_CTYPE_ASCII]: Skip tests that assume ASCII.
56762         * tests/test-wcwidth.c: Likewise.
56764 2016-08-17  Paul Eggert  <eggert@cs.ucla.edu>
56766         stdbool: don't require _Bool for C++
56767         Problem reported by David Seifert in:
56768         http://lists.gnu.org/r/bug-gnulib/2016-06/msg00005.html
56769         * NEWS, doc/posix-headers/stdbool.texi (stdbool.h): Document this.
56770         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Make the check
56771         more-forgiving for C++, in that it requires only 'bool'.  Be a bit
56772         stricter about checking that bool and _Bool are compatible in C.
56774 2016-08-16  Paul Eggert  <eggert@cs.ucla.edu>
56776         getdelim: remove dependency on realloc-posix
56777         * lib/canonicalize-lgpl.c (alloc_failed)
56778         [!FUNC_REALPATH_WORKS || defined _LIBC]: New function,
56779         (__realpath) [!FUNC_REALPATH_WORKS || defined _LIBC]: Use it.
56780         Use __set_errno where needed, for consistency.
56781         * lib/getdelim.c (alloc_failed): New function.
56782         (getdelim): Use it.
56784 2016-08-09  Assaf Gordon  <assafgordon@gmail.com>
56786         parse-datetime: add optional debug printing
56787         Print parsing information, warnings, and errors to stderr.
56788         * lib/parse-datetime.h (parse_datetimte_debug): New global variable.
56789         * lib/parse-datetime.y:
56790         (DEBUG_*):  Macros calling debug functions if debugging is enabled.
56791         (PROGRESS*): Same as DEBUG, for progress reporting.
56792         (dbg_printf): Print message to stderr, with 'date' prefix.
56793         (struct parser_control): Add 'debug_*_seen' variables.
56794         (str_days): Converts day ordinal/number to string (e.g. 'last wed').
56795         (debug_print_current_time, debug_print_relateive_time): Prints the
56796         current/relative date/time value of parser_control.
56797         (YACC parser syntax): Print parsed parts with DEBUG_* macros.
56798         (to_year): Warn about 2-digit year parsing.
56799         (yylex):   Warn about unrecognized words.
56800         (get_effective_timezone): Returns current timezone in minutes.
56801         (debug_strf{time,date,datetime}): Convert 'struct tm' to string as
56802         clearly and unambigiously as possible.
56803         (debug_mktime_not_ok): Print detailed information about failed
56804         date/time values.
56805         (parse_datetime): Add DEBUG messages for failures, warnings. Add
56806         PROGRESS messages for status messages.
56807         * modules/parse-datetime: Add 'timegm', 'gettext-h' dependencies.
56809 2016-08-06  Jim Meyering  <meyering@fb.com>
56811         tests/init.sh: exclude dash with bad "local" semantics
56812         * tests/init.sh (gl_shell_test_script_): Add a function to
56813         eliminate a shell like "dash" (unlike bash, zsh) that has
56814         surprising/risky "local var='...'" semantics.  Inspired by
56815         the problem and discussion in https://bugs.gnu.org/24116#11.
56817 2016-08-02  Ján Tomko  <jtomko@redhat.com>
56819         maint.mk: expand the prohibit_doubled_word regex
56820         This check has a static list of words that are checked for
56821         repetitions.  Expand it before running the perl script to
56822         avoid using expensive captures.  This decreases the cost
56823         for libvirt from 1.66s to 0.66s.
56824         * top/maint.mk (prohibit_doubled_word_expanded_): Define.
56825         (sc_prohibit_doubled_word): Use it.
56827 2016-07-26  Ján Tomko  <jtomko@redhat.com>
56829         useless-if-before-free: skip non-matching lines early
56830         * build-aux/useless-if-before-free: First match each line with the
56831         simple/quick /\bif\b/ and reject if there is no match. This often
56832         saves the cost of the much more involved regular expression.
56833         For libvirt, this decreases the cost from 1.44s to 1.02s.
56835 2016-07-26  Ján Tomko  <jtomko@redhat.com>
56837         maint.mk: speed up sc_po_check
56838         sc_po_check would skip files based on their names, or on the
56839         existence of files with derived names. Rewrite it to use perl
56840         instead of shell to make the check faster.
56841         * top/maint.mk (perl_translatable_files_list_): Define.
56842         (sc_po_check): Use it.
56844 2016-07-30  Ján Tomko  <jtomko@redhat.com>
56846         maint.mk: speed up require_config_h_first
56847         Instead of spawning three processes per file,
56848         rewrite the check in perl and run it once for all the files.
56849         * top/maint.mk (perl_config_h_first_): Define.
56850         (sc_require_config_h_first): Use it in place of shell code.
56852 2016-07-26  Ján Tomko  <jtomko@redhat.com>
56854         maint.mk: speed up sc_po_check
56855         sc_po_check would skip files based on their names, or on the
56856         existence of files with derived names. Rewrite it to use perl
56857         instead of shell to make the check faster.
56858         * top/maint.mk (perl_translatable_files_list_): Define.
56859         (sc_po_check): Use it.
56861 2016-07-15  Paul Eggert  <eggert@cs.ucla.edu>
56863         obstack: pacify GCC 6 with -Wnull-dereference
56864         Problem reported by Assaf Gordon in:
56865         http://lists.gnu.org/r/bug-gnulib/2016-07/msg00028.html
56866         * lib/obstack.c, lib/obstack.h (obstack_alloc_failed_handler):
56867         Declare with __attribute_noreturn__.
56868         * lib/obstack.h (__attribute_noreturn__): New macro.
56870 2016-07-13  Eric Blake  <eblake@redhat.com>
56872         doc: mention glibc, OS X, Cygwin [S]SIZE_MAX buglet
56873         * doc/posix-headers/stdint.texi (stdint.h): Document the bugs.
56874         * doc/posix-headers/limits.texi (limits.h): Document the bugs.
56876 2016-07-13  Paul Eggert  <eggert@cs.ucla.edu>
56878         doc: mention glibc SSIZE_MAX buglet
56879         * doc/posix-headers/limits.texi (limits.h): Document the bug.
56881 2016-07-04  Martin Kletzander  <mkletzan@redhat.com>
56883         printf-posix: Fix mingw build
56884         Commit 54615b95ff238e235e806855efc46a9abad09f2e changed the regular
56885         expression for detecting C symbol prefixes but forgot to qoute square
56886         brackets in the command line arguments for grep.  That way when
56887         building with mingw the condition was false although it ought to be
56888         true instead.  In particular scenarios this led to the following
56889         compile error:
56891             Cannot export rpl_printf: symbol not found
56892             Cannot export rpl_scanf: symbol not found
56893             collect2: error: ld returned 1 exit status
56895         Fix this by properly quoting square brackets.
56897 2016-07-03  Paul Eggert  <eggert@cs.ucla.edu>
56899         mktime: call tzset as per POSIX
56900         Problem reported by Ludovic Courtès in:
56901         http://lists.gnu.org/r/bug-gnulib/2016-06/msg00068.html
56902         * lib/mktime.c (mktime) [!_LIBC && HAVE_TZSET]: Call tzset.
56903         * m4/mktime.m4 (gl_FUNC_MKTIME): Check for tzset.
56905 2016-06-26  Pádraig Brady  <P@draigBrady.com>
56907         fts: handle readdir() errors
56908         * lib/fts.c (fts_build): readdir(3) returns NULL when finished,
56909         but also upon error when it will also set errno.  Therefore
56910         flag the error case from readdir().  We treat the case where
56911         no items are read the same as if the dir can't be accessed,
56912         i.e. by setting fts_errno to FTS_DNR.
56914 2016-06-24  Paul Eggert  <eggert@cs.ucla.edu>
56916         intprops: port better to GCC 7
56917         GCC 7 __builtin_add_overflow supports a new usage form, where the
56918         last argument is a null pointer, and which merely returns 1 if an
56919         overflow would occur.  This is a constant expression if all
56920         arguments are constants, and should generate faster code when code
56921         needs to be generated.
56922         * lib/intprops.h (_GL_HAS_BUILTIN_OVERFLOW_WITH_NULL): New macro.
56923         (_GL_ADD_OVERFLOW, _GL_SUBTRACT_OVERFLOW, _GL_MULTIPLY_OVERFLOW):
56924         Use builtin operations if available.
56925         (INT_NEGATE_OVERFLOW): Prefer INT_SUBTRACT_OVERFLOW if builtin
56926         operations are available, as it's almost surely faster.
56928 2016-06-23  Paul Eggert  <eggert@cs.ucla.edu>
56930         intprops-test: port to GCC 6
56931         * tests/test-intprops.c: Ignore -Woverflow if any GCC version,
56932         since the bug is not fixed in GCC 6.1.
56934 2016-06-13  Paul Eggert  <eggert@cs.ucla.edu>
56936         xalloc-oversized: port to GCC 7; fewer warnings
56937         GCC 7 will have a better way to deal with integer overflow.
56938         Plus, fix a warnings problem reported by Tim Ruehsen in:
56939         http://lists.gnu.org/r/bug-gnulib/2016-06/msg00022.html
56940         * lib/xalloc-oversized.h (__xalloc_oversized): New macro.
56941         (xalloc_oversized): Use plain __builtin_mul_overflow if GCC 7 or later.
56942         For GCC 5, use __xalloc_oversized if both args are constants,
56943         or if pedantic.
56945 2016-06-08  Paul Eggert  <eggert@cs.ucla.edu>
56947         regex: port to Sun C
56948         Reported by Daiki Ueno.
56949         * lib/regcomp.c (regcomp, regerror): Use _Restrict_, not
56950         __restrict, in prototype.  This fixes a problem I introduced in
56951         the 2016-02-19 merge from glibc.
56953 2016-05-31  Paul Eggert  <eggert@cs.ucla.edu>
56955         stdbool: Restore __bool_true_false_are_defined check
56956         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL):
56957         __bool_true_false_are_defined is still defined, even with C++11.
56959 2016-05-31  David Seifert  <soap@gentoo.org>  (tiny change)
56961         stdbool: Port AC_CHECK_HEADER_STDBOOL to C++11
56962         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Port to C++11.
56964 2016-05-30  Paul Eggert  <eggert@cs.ucla.edu>
56966         Use GCC_LINT, not lint
56967         FreeBSD and Cygwin #define _Noreturn to empty if 'lint' is defined.
56968         Problem reported by Ken Brown in: http://bugs.gnu.org/23640
56969         * doc/posix-headers/stdnoreturn.texi (stdnoreturn.h):
56970         Document problem with lint and _Noreturn.
56971         * lib/diffseq.h (IF_LINT, IF_LINT2):
56972         * lib/fts.c (sccsid):
56973         * lib/getndelim2.c (IF_LINT):
56974         * lib/gl_anylinked_list2.h (gl_linked_iterator)
56975         (gl_linked_iterator_from_to):
56976         * lib/gl_anytree_list2.h (gl_tree_iterator)
56977         (gl_tree_iterator_from_to):
56978         * lib/gl_anytree_oset.h (gl_tree_iterator):
56979         * lib/gl_array_list.c (gl_array_iterator)
56980         (gl_array_iterator_from_to):
56981         * lib/gl_array_oset.c (gl_array_iterator):
56982         * lib/gl_carray_list.c (gl_carray_iterator)
56983         (gl_carray_iterator_from_to):
56984         * lib/idcache.c:
56985         * lib/inet_ntop.c (IF_LINT):
56986         * lib/regcomp.c (build_charclass_op, create_tree):
56987         * lib/regex_internal.c (re_acquire_state)
56988         (re_acquire_state_context):
56989         * lib/trigl.c (rcsid):
56990         * lib/trim.c (IF_LINT):
56991         * lib/vasnprintf.c (IF_LINT):
56992         * lib/verify.h (assume):
56993         Treat GCC_LINT like lint.
56995 2016-05-29  Bruno Haible  <bruno@clisp.org>
56997         secure_getenv: Port to many more platforms.
56998         * m4/secure_getenv.m4 (gl_PREREQ_SECURE_GETENV): Also check for get*id
56999         functions.
57000         * lib/secure_getenv.c (secure_getenv): Add alternate implementations
57001         for non-BSD Unix platforms and for native Windows.
57002         * doc/glibc-functions/secure_getenv.texi: Remove known issue.
57003         Prompted by a request from Nikos Mavrogiannopoulos.
57005 2016-05-27  Eric Blake  <eblake@redhat.com>
57007         canonicalize: Fix broken probe for realpath.
57008         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Fix regression
57009         in logic introduced in 54615b95.
57011 2016-05-26  Eric Blake  <eblake@redhat.com>
57013         unsetenv: relax to LGPLv2+
57014         * modules/unsetenv (License): Match setenv license.
57016 2016-05-20  Ludovic Courtès  <ludo@gnu.org>
57018         gendocs.sh: Set default TOP_NODE_UP_URL in HTML output.
57019         Suggested by Gavin Smith <gavinsmith0123@gmail.com>.
57020         Reported by myglc2 <myglc2@gmail.com> in <http://bugs.gnu.org/22651>.
57021         * build-aux/gendocs.sh (MANUAL_TITLE, PACKAGE, EMAIL)
57022         (commonarg, dirargs, dirs, infoarg, generate_ascii)
57023         (generate_html, generate_info, generate_tex, outdir)
57024         (source_extra, split, srcfile, texarg): Move above 'version'.
57025         (htmlarg): Likewise, and add "-c TOP_NODE_UP_URL=/manual".
57027 2016-05-17  Paul Eggert  <eggert@cs.ucla.edu>
57029         manywarnings: update for GCC 6.1
57030         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
57031         Add GCC 6.1 options that apply to C.
57032         * build-aux/gcc-warning.spec: Add GCC 6.1 options that
57033         do not apply to C, are obsolescent, etc.
57035 2016-05-12  Paul Eggert  <eggert@cs.ucla.edu>
57037         glob: size_t overflow checks
57038         * lib/glob.c (__has_builtin): New macro.
57039         (size_add_wrapv, glob_use_alloca): New static functions.
57040         (glob, glob_in_dir): Check for size_t overflow in several places,
57041         and fix some size_t checks that were not quite right.
57043         glob: don't assume INT_MAX < SIZE_MAX
57044         * lib/glob.c (glob): Prefer SIZE_MAX to ~((size_t) 0), as the
57045         latter is not portable to (probably theoretical) hosts where
57046         SIZE_MAX <= INT_MAX.
57048 2016-05-09  Bruno Haible  <bruno@clisp.org>
57050         Fix undefined behaviour in gettext.h.
57051         * lib/gettext.h (dcpgettext_expr, dcnpgettext_expr): Avoid accessing a
57052         pointer's value after the storage it points to has been freed.
57053         Reported by Michael Pyne in https://savannah.gnu.org/bugs/?47847.
57054         Spotted by Coverity.
57056 2016-05-08  Paul Eggert  <eggert@cs.ucla.edu>
57058         git-version-gen: avoid undefined shift
57059         Problem reported by Mosè Giordano in:
57060         http://lists.gnu.org/r/bug-gnulib/2016-05/msg00012.html
57061         * build-aux/git-version-gen: Avoid undefined behavior if invoked
57062         with --prefix or --fallback but without a later argument.  While
57063         we're at it, omit unnecessary quotes.
57065 2016-05-04  Paul Eggert  <eggert@cs.ucla.edu>
57067         glob: merge glibc changes into lib/glob.c
57068         * lib/glob.c (glob_in_dir): Sync with glibc/posix/glob.c,
57069         dated 2016-05-04 12:09:35 2016 +0200.  Here are the changes:
57070         2016-05-04 CVE-2016-1234: glob: Do not copy d_name field of
57071           struct dirent [BZ #19779]
57072         2016-04-29 glob: Simplify the interface for the GLOB_ALTDIRFUNC
57073           callback gl_readdir
57074         2015-10-20 Convert miscellaneous function definitions to prototype style
57075         2015-10-20 Convert 113 more function definitions to prototype style
57076           (files with assertions)
57077         2015-06-12 Fix getlogin_r namespace (bug 18527).
57078         2014-02-10 Use glibc_likely instead __builtin_expect.
57079         2013-10-20 When glob pattern contains a trailing slash match only
57080           directories. Fixes bug 10278.
57081         2013-09-04 glob: silence -Wattribute warnings
57082         2013-06-07 Avoid use of "register" as optimization hint.
57083         2012-09-25 Use size_t instead of int for internal variables in glob
57084           (bug 14621)
57085         2011-07-20 Check for overflows in expressions
57086         2011-05-28 Remove unused variable
57087         2011-05-22 Add a few more alloca size checks
57088         2010-03-27 Whitespace fixes
57089         2010-03-27 Fix one more issue with the glob patch
57090         2010-03-24 Fix glob with empty pattern
57091         2008-05-27 Remove useless more "if" tests before "free"
57092         * modules/glob (Depends-on): Add stdint.
57094 2016-05-01  Paul Eggert  <eggert@cs.ucla.edu>
57096         mktime: port to stricter signed overflow checking
57097         * lib/mktime.c: Omit 'pragma GCC optimize ("wrapv")'.
57098         (long_int): Require width for INT_MAX * 3 * (seconds per year),
57099         instead of merely for INT_MAX * 2.  In practice platforms that
57100         do the latter also do the former.
57101         (TIME_T_MIN, TIME_T_MAX, TIME_T_MIDPOINT, SHR): Remove.
57102         (shr): New static function, replacing SHR.  All uses changed.
57103         (mktime_min, mktime_max): New constants, replacing TIME_T_MIN
57104         and TIME_T_MAX.  All uses changed.
57105         (ydhms_diff, guess_time_tm, ranged_convert, __mktime_internal):
57106         Use long_int, not time_t.
57107         (long_int_avg): New static function, replacing time_t_avg.
57108         All uses changed.  Round toward positive infinity, as that
57109         generates slightly better code.
57110         (time_t_add_ok, time_t_int_add_ok): Remove.  All uses replaced
57111         by INT_ADD_WRAPV.
57112         (guess_time_tm): Accept time, not a pointer to it.  All uses changed.
57113         (convert_time): New static function.
57114         (ranged_convert): Use it
57115         (ranged_convert): Check for *T out of [mktime_min, mktime_max] range.
57116         Use simpler test for loop exit.
57117         (__mktime_internal): Store negative of guessed offset, to simplify
57118         overflow checking.  Remove no-longer-needed test for small time_t
57119         overflows.
57121         mktime: speed up DEBUG_MKTIME benchmarks
57122         Call tzset just once, at the start, rather than for every test
57123         case.  This lets us measure the CPU cost of mktime as opposed to
57124         that of tzset.  This is relevant when TZ is not set and glibc is
57125         being used.  This speeds up tests by a factor of 40 on my Fedora
57126         23 x86-64 platform.
57127         * lib/mktime.c (main) [DEBUG_MKTIME]: Call localtime at the start,
57128         to call tzset and as a sanity check.  Later on, use localtime_r
57129         instead of localtime.
57131         mktime: resurrect DEBUG_MKTIME testing
57132         * lib/mktime.c [DEBUG_MKTIME]: Do not include <config.h>.
57133         Include <string.h>, for strcmp.
57135         mktime: simplify DEBUG_MKTIME
57136         * lib/mktime.c (DEBUG_MKTIME): Define to 0 if not defined.
57137         Simplify later usage accordingly.
57139         Port mktime_internal offset to unsigned time_t
57140         This avoids some assumptions about wraparound arithmetic on
57141         signed integer overflow.
57142         * lib/mktime-internal.h (mktime_offset_t): New type.
57143         (mktime_internal): Use it in decl.
57144         * lib/mktime.c, lib/timegm.c (mktime_offset_t) [_LIBC]: New type.
57146         * lib/mktime.c (__mktime_internal, localtime_offset):
57147         * lib/timegm.c (timegm): Use it.
57148         * m4/mktime.m4 (gl_TIME_T_IS_SIGNED): New macro.
57149         (gl_FUNC_MKTIME): Require it.
57151 2016-04-27  Paul Eggert  <eggert@cs.ucla.edu>
57153         xstrtol: prohibit monstrosities like "1bB"
57154         Problem reported by Young Mo Kang in: http://bugs.gnu.org/23388
57155         * lib/xstrtol.c (__xstrtol): Allow trailing second suffixes like
57156         "B" only if the first suffix needs a base.
57157         * tests/test-xstrtol.sh: Test this.
57159 2016-04-21  Pádraig Brady  <P@draigBrady.com>
57161         xstrtod: reinstate setting of *result upon ERANGE
57162         * lib/xstrtod.c (XSTRTOD): The user may decide to use
57163         the returned limits upon ERANGE, so allow and document that.
57165 2016-04-20  Tino Calancha  <f92capac@gmail.com>  (tiny change)
57167         xstrtod: modify *result only if no errors
57168         * lib/xstrtod.c (XSTRTOD).
57170 2016-04-19  Paul Eggert  <eggert@cs.ucla.edu>
57172         btowc: document problems in C locale
57173         * doc/posix-functions/btowc.texi (btowc): Mention incompatibility
57174         with mbrtowc.  See: http://bugs.gnu.org/23269#32
57176 2016-04-13  Paul Eggert  <eggert@cs.ucla.edu>
57178         mktime: improve integer overflow checking
57179         * lib/mktime.c: Include stdbool.h, intprops.h, verify.h.
57180         (WRAPV): Remove; no longer needed.
57181         (verify): Remove.  Replace all uses with call to verify.h 'verify'.
57182         (TYPE_IS_INTEGER, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
57183         Remove.  Use intprops.h defns instead.
57184         (leapyear, isdst_differ, time_t_add_ok, time_t_int_ok):
57185         Use bool for Boolean, for clarity.
57186         (time_t_add_ok, time_t_int_add_ok): Use INT_ADD_WRAPV to
57187         detect integer overflow.
57188         * modules/mktime (Depends-on): Add intprops, stdbool, verify.
57190         intprops: check two's complement assumption
57191         Suggested by Eric Blake in:
57192         http://lists.gnu.org/r/bug-gnulib/2016-04/msg00016.html
57193         * lib/intprops.h: Include <verify.h>.  Verify that signed char,
57194         short, int, long, and (if available) long long are two's complement.
57195         * modules/intprops (Depends-on): Add 'verify'.
57197         intprops, mktime, strtol: assume two's complement
57198         These macros were not portable to every conforming C11 ones'
57199         complement platform.  It's not worth the hassle of porting to some
57200         platforms that use ones' complement or signed magnitude, as such
57201         platforms are almost purely theoretical nowadays and porting even
57202         to some of them makes the code harder to review for little
57203         practical benefit.  Problem reported by Florian Weimer in:
57204         https://sourceware.org/ml/libc-alpha/2016-04/msg00295.html
57205         * lib/intprops.h (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT)
57206         (TYPE_SIGNED_MAGNITUDE, _GL_INT_TWOS_COMPLEMENT):
57207         * lib/mktime.c (TYPE_TWOS_COMPLEMENT):
57208         * lib/strtol.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT)
57209         (TYPE_SIGNED_MAGNITUDE):
57210         Remove.  All uses rewritten to assume two's complement, which is
57211         all we can reasonably test nowadays anyway.
57212         * top/maint.mk (_intprops_names): Remove the removed macros.
57214 2016-04-11  Paul Eggert  <eggert@cs.ucla.edu>
57216         stdint: port to strict C11 left shift
57217         * lib/stdint.in.h (_STDINT_MIN, _STDINT_MAX):
57218         Pacify clang -Wshift-negative-value, which should be an issue only
57219         on clang setups where stdint.h does not conform to C11 or to C++11.
57220         Problem reported by Philipp Stephani in: http://bugs.gnu.org/23261
57222 2016-04-09  Paul Eggert  <eggert@penguin.cs.ucla.edu>
57224         mbrtowc: work around glibc bug#19932
57225         Fix mbrtowc so that it never returns -1 in the C locale,
57226         as this conflicts with a future version of POSIX
57227         http://austingroupbugs.net/view.php?id=663#c2738
57228         and causes problems with GNU grep: http://bugs.gnu.org/23234
57229         See glibc bug 19932:
57230         https://sourceware.org/bugzilla/show_bug.cgi?id=19932
57231         * doc/posix-functions/mbrlen.texi (mbrlen):
57232         * doc/posix-functions/mbrtowc.texi (mbrtowc):
57233         Document the glibc bug.
57234         * lib/mbrtowc.c [C_LOCALE_MAYBE_EILSEQ]:
57235         Include hard-locale.h, locale.h.
57236         (rpl_mbrtowc): Work around the C_LOCALE_MAYBE_EILSEQ bug,
57237         if the bug is possible.
57238         * m4/mbrtowc.m4 (gl_MBRTOWC_C_LOCALE): New macro.
57239         (gl_FUNC_MBRTOWC): Use it, and define C_LOCALE_MAYBE_EILSEQ as needed.
57240         * modules/hard-locale (License): Now LGPLv2+, for mbrtowc.
57241         * modules/mbrtowc (Depends-on): Add hard-locale.
57242         * modules/mbrtowc-tests (Files, TESTS): Add tests/test-mbrtowc5.sh.
57243         * tests/test-mbrtowc.c (main): Test for bug fix if arg is '5'.
57244         * tests/test-mbrtowc5.sh: New file.
57246 2016-04-03  Pedro Alves  <palves@redhat.com>
57248         stdint: detect good enough pre-C++11 stdint.h in C++ mode
57249         When gnulib is configured in C++ mode for a system with a working C99
57250         implementation of stdint.h that predates C++11, gnulib ends up
57251         substituting stdint.h anyway.  This works on most targets, but on e.g.,
57252         64-bit MinGW, it doesn't, as gnulib's substitute assumes LP64, while
57253         MinGW is LLP64.  Instead of trying to detect the right types, detect
57254         good-enough-pre-C++11 stdint.h and in such case define
57255         __STDC_CONSTANT_MACROS/__STDC_LIMIT_MACROS in config.h.
57256         * m4/stdint.m4 (gl_STDINT_H): Always define __STDC_CONSTANT_MACROS
57257         / __STDC_LIMIT_MACROS while checking whether the system stdint.h
57258         conforms to C99.  If it does, check whether it hides symbols
57259         behind the __STDC_{CONSTANT|LIMIT}_MACROS macros.  Then if it
57260         does, define those macros in config.h.
57262 2016-04-03  Paul Eggert  <eggert@cs.ucla.edu>
57264         argp: merge changes from glibc
57265         Among other things, this should fix problems found by a Coverity
57266         scan and reported by Andrei Borzenkov:
57267         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00015.html
57268         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00016.html
57269         * lib/argp-ba.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h:
57270         * lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h:
57271         * lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c:
57272         * lib/argp.h:
57273         Merge changes from glibc.
57274         * tests/test-argp-2.sh: Adjust to match new behavior.
57276 2016-04-01  Paul Eggert  <eggert@cs.ucla.edu>
57278         stddef: support configuring with g++
57279         Problem reported by Ángel González in:
57280         http://lists.gnu.org/r/bug-gnulib/2016-04/msg00003.html
57281         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS, max_align_t):
57282         Do not define if _GCC_MAX_ALIGN_T is defined.
57284 2016-03-25  Paul Eggert  <eggert@cs.ucla.edu>
57286         test-framework-sh: minor cleanups
57287         * tests/init.sh (testdir_prefix_): Output a trailing newline,
57288         since strictly speaking POSIX requires this.
57289         (setup_): Do not use the variable 'fail', as that makes the
57290         trace output harder to read ('fail' is typically used by
57291         tests to mean the test failed).  Treat // portably.
57292         Check that new directory is not merely a sibling of the tmp dir.
57293         Avoid unnecessary invocation of tr.
57295         test-framework-sh: revert port to NetBSD 7.0
57296         It was a false alarm; I misinterpreted Assaf Gordon's report.
57297         * tests/init.sh (testdir_prefix_, pfx_, template_length_):
57298         Restore.
57299         (test_dir_): Adjust to mktempd_ change.
57300         (mktempd_): Restore 2nd arg.  Use -t again.
57301         (base_template_, template_, nx_): Resurrect old code.
57303         Port better to Alpine Linux
57304         Its diff implementation does not support -c, but does support -U3.
57305         Problem reported by Assaf Gordon in: http://bugs.gnu.org/23107#13
57306         * tests/init.sh (diff_opt_): New var.
57307         (compare_): Prefer diff -U3 to diff -c to plain diff.
57309 2016-03-24  Paul Eggert  <eggert@cs.ucla.edu>
57311         test-framework-sh: port to NetBSD 7.0
57312         Problem reported by Assaf Gordon in: http://bugs.gnu.org/23107#13
57313         * tests/init.sh (testdir_prefix_, pfx_, template_length_):
57314         Remove.  All uses removed.
57315         (test_dir_): Adjust to mktempd_ change.
57316         (mktempd_): Omit 2nd arg.  Stop using -t, as it is not portable.
57317         (base_template_, template_, nx_): Simplify by hardcoding.
57319 2016-03-22  Paul Eggert  <eggert@cs.ucla.edu>
57321         gitlog-to-changelog: suppress ignored chatter
57322         * build-aux/gitlog-to-changelog: Do not warn about skipping
57323         an SHA if it would have been ignored anyway.
57325 2016-03-22  Geert Janssens  <janssens-geert@telenet.be>
57327         setlocale: add "sv" to Windows language table
57328         * lib/setlocale.c (language_table) [W32]: Add "sv".
57329         Reported in <https://savannah.gnu.org/bugs/?44588>.
57331 2016-03-21  Paul Eggert  <eggert@cs.ucla.edu>
57333         sys_select: port to new Cygwin
57334         Problem reported by Ken Brown in:
57335         https://lists.gnu.org/r/bug-gnulib/2016-03/msg00054.html
57336         * lib/sys_select.in.h [__CYGWIN__]: Avoid "unknown type name"
57337         diagnostics.
57339 2016-03-17  Jim Meyering  <meyering@fb.com>
57341         test-userspec.c: do not trigger gcc's new -Wmisleading-indentation
57342         * tests/test-userspec.c (main): Remove unnecessary braces and fix
57343         misleading indentation. Here is the diagnostic gcc-6.0-to-be issued:
57344           test-userspec.c:176:9: error: statement is indented as if it were \
57345             guarded by... [-Werror=misleading-indentation]
57346                    {
57347                    ^
57348           test-userspec.c:173:7: note: ...this 'if' clause, but it is not
57349                  if (!diag && !T[i].result)
57350                  ^~
57352 2016-03-15  Paul Eggert  <eggert@cs.ucla.edu>
57354         time_rz: port to clang -Wunused-const-variable
57355         * lib/time_rz.c (TZ): Remove.  All uses removed.
57357         std-gnu11: improve clang support
57358         * m4/std-gnu11.m4: Sync with autoconf, incorporating:
57359         2016-03-15 Also try clang
57360         2016-03-15 Port C11 and C++11 testing to clang
57362         select: port more to Intel 2016.1.150 compiler
57363         Problem reported by Balázs Hajgató in:
57364         http://lists.gnu.org/r/bug-gnulib/2016-03/msg00036.html
57365         * m4/select.m4 (gl_FUNC_SELECT): Require AC_C_RESTRICT.
57367 2016-03-14  Paul Eggert  <eggert@cs.ucla.edu>
57369         select: try to port to 2016.1.150 compiler
57370         Problem reported by Balázs Hajgató in:
57371         http://lists.gnu.org/r/bug-gnulib/2016-03/msg00026.html
57372         * lib/sys_select.in.h (select): Use 'restrict' on arguments where
57373         POSIX specifies 'restrict'.
57375 2016-03-13  Paul Eggert  <eggert@cs.ucla.edu>
57377         localename-tests: memory allocation fixes
57378         * tests/test-localename.c (test_locale_name)
57379         (test_locale_name_thread): Don't call freelocale on a locale
57380         that was the base of a successful newlocale, as that
57381         results in a double free.  Problem reported by Assaf Gordon.
57382         (test_locale_name_thread): Free saved names after use, to pacify
57383         gcc -fsanitize=address.
57385 2016-03-08  Paul Eggert  <eggert@cs.ucla.edu>
57387         intprops: make .h file license match module
57388         * lib/intprops.h: Change the license wording to match glibc format.
57389         This is what is in modules/intprops anyway.  See:
57390         https://sourceware.org/bugzilla/show_bug.cgi?id=19738#c8
57392 2016-03-08  Eric Blake  <eblake@redhat.com>
57394         acl: fix missing return on Cygwin
57395         * lib/set-permissions.c (set_acls) [HAVE_FACL && GETACL]: Don't
57396         fall off end of function. Fixes http://bugs.gnu.org/22949
57398 2016-03-05  Bruno Haible  <bruno@clisp.org>
57400         extern-inline: port to PGI CC
57401         * m4/extern-inline.m4 (gl_EXTERN_INLINE): For PGI CC, don't use the
57402         keyword 'inline'.
57403         Reported by Adam James Stewart in:
57404         http://lists.gnu.org/r/bug-gnulib/2016-03/msg00006.html
57406 2016-02-20  Paul Eggert  <eggert@cs.ucla.edu>
57408         signbit: port back to pre-C++11 GCC
57409         * lib/math.in.h (signbit): Do previous change only if
57410         __cplusplus < 201103.  See Jonathan Wakely in:
57411         https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/UY3VX3W7XEXYTUKHG5BALU4ACUD7ZLGE/
57413 2016-02-19  Kamil Dudka  <kdudka@redhat.com>
57415         mountlist: recognize autofs-mounted remote file systems, too
57416         Originally reported at: https://bugzilla.redhat.com/1309247
57417         * lib/mountlist.c (ME_REMOTE): Return true if a file system is named
57418         "-hosts" because it is used by autofs to mount remote file systems.
57420 2016-02-19  Paul Eggert  <eggert@cs.ucla.edu>
57422         signbit: port to C++ with GCC 6
57423         * lib/math.in.h (signbit) [__cplusplus]:
57424         Do not replace with GCC builtin.  Reported by Orion Poplawski in:
57425         http://lists.gnu.org/r/bug-gnulib/2016-02/msg00005.html
57427         * lib/regex_internal.h (IDX_MAX) [_REGEX_LARGE_OFFSETS]: Now SSIZE_MAX.
57429         regex: make it closer to libc
57430         Make Idx a signed type, rather than possibly unsigned.
57431         The unsignedness was not really buying us anything, since the code
57432         overflows for other reasons before getting to PTRDIFF_MAX.  Making
57433         it signed allows us to use -1 and -2 with abandon, like libc does,
57434         thus lessening the number of differences between gnulib and libc.
57435         Also, it should help avoid gratuitous warnings like the one
57436         reported by Nelson H. F. Beebe in: http://bugs.gnu.org/22702
57437         * lib/regex.h (__re_idx_t): Remove.  All uses changed to regoff_t.
57440         regex: merge patches from libc
57442         2015-10-21  Joseph Myers  <joseph@codesourcery.com>
57443         2015-10-20  Joseph Myers  <joseph@codesourcery.com>
57444         Convert miscellaneous function definitions to prototype style.
57445         * lib/regcomp.c (re_compile_pattern, re_set_syntax)
57446         (re_compile_fastmap, regcomp, regerror, regfree, re_comp):
57447         * lib/regexec.c (regexec, re_match, re_search, re_match_2, re_search_2)
57448         (re_search_2_stub, re_search_stub, re_set_registers, re_exec)
57449         (re_search_internal):
57450         Convert to prototype-style function definition.
57451         Use internal_function for internal functions.
57453 2016-02-10  Paul Eggert  <eggert@cs.ucla.edu>
57455         stdalign: port to older HP and IBM cc
57456         * lib/stdalign.in.h (_Alignas): Port better to older HP and IBM
57457         C compilers, by checking their version numbers.  These version
57458         numbers appear in MariaDB and in Qt code that dates way back and
57459         that conditiionally uses the 'aligned' attribute.
57461 2016-02-09  Paul Eggert  <eggert@cs.ucla.edu>
57463         stdalign: port to clang 3.7.0
57464         Problem reported by Herbert J. Skuhra in:
57465         http://lists.gnu.org/r/emacs-devel/2016-02/msg00476.html
57466         * lib/stdalign.in.h (alignas): Fix typo that prevented 'alignas'
57467         from being defined on clang 3.7.0, which has a buggy stdalign.h.  See:
57468         https://llvm.org/bugs/show_bug.cgi?id=26547
57470 2016-02-08  Paul Eggert  <eggert@cs.ucla.edu>
57472         readdir_r: now obsolescent
57473         * doc/posix-functions/readdir_r.texi (readdir_r): Now obsolescent.
57474         * lib/mountlist.c (read_file_system_list): Add a FIXME.
57476 2016-02-06  Paul Eggert  <eggert@cs.ucla.edu>
57478         misc: port better to gcc -fsanitize=address
57479         Without these patches, ./configure CFLAGS='-fsanitize=address'
57480         would compute incorrect values.  This patch fixes some (but not all)
57481         test failures with recent glibc, with this configuration.
57482         * m4/acl.m4 (gl_ACL_GET_FILE):
57483         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF):
57484         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS):
57485         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO):
57486         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE):
57487         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
57488         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
57489         * m4/getgroups.m4 (gl_FUNC_GETGROUPS):
57490         * m4/getline.m4 (gl_FUNC_GETLINE):
57491         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF):
57492         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF):
57493         * m4/regex.m4 (gl_REGEX):
57494         * m4/strndup.m4 (gl_FUNC_STRNDUP):
57495         * tests/test-calloc-gnu.c (main):
57496         * tests/test-duplocale.c (main):
57497         * tests/test-getgroups.c (main):
57498         * tests/test-getline.c (main):
57499         * tests/test-inttostr.c (main):
57500         * tests/test-localename.c (test_locale_name)
57501         (test_locale_name_thread, test_locale_name_environ)
57502         (test_locale_name_default):
57503         * tests/test-regex.c (main):
57504         * tests/test-setlocale1.c (main):
57505         * tests/test-stat.h (test_stat_func):
57506         Free heap-allocated storage before exiting.
57507         * m4/asm-underscore.m4 (gl_ASM_SYMBOL_PREFIX):
57508         Don't match *_foo symbols inserted by AddressSanitizer.
57509         * tests/test-regex.c, tests/test-stat.c: Include stdlib.h, for 'free'.
57511 2016-02-02  Jim Meyering  <meyering@fb.com>
57513         verify-tests: also remove stray test-verify.Tpo
57514         * modules/verify-tests (Makefile.am): Arrange for "make clean"
57515         to remove the test-verify.Tpo file that is left behind by
57516         the automake-generated rule upon compilation failure.
57517         Otherwise, that .Tpo file would cause a failed "make distcheck"
57518         at least for grep.
57520 2016-02-02  Paul Eggert  <eggert@cs.ucla.edu>
57522         std-gnu11: new module
57523         This makes it easier for applications to prefer C11 and C++11
57524         to older variants, when compiling C and C++ code.
57525         Unlike most m4/*.m4 files, m4/std-gnu11.m4 is GPLed, as it copies
57526         a nontrivial chunk of GPLed Autoconf source code.
57527         * COPYING: Mention the m4/*.m4 copyright situation.
57528         * MODULES.html.sh (std-gnu11): New module.
57529         * m4/std-gnu11.m4, modules/std-gnu11: New files.
57531 2016-01-25  Paul Eggert  <eggert@cs.ucla.edu>
57533         get-permissions, strftime: fix grammar in comments
57534         * lib/get-permissions.c, lib/strftime.c: Merge into the comments
57535         some grammar fixes Alan Mackenzie made to GNU Emacs.
57537 2016-01-25  Daiki Ueno  <ueno@gnu.org>
57539         gettext: mark as obsolete
57540         Suggested by Paul Eggert in:
57541         https://lists.gnu.org/r/bug-gnulib/2016-01/msg00101.html
57542         * modules/gettext (Status): Mark as obsolete.
57543         (Notice): Suggest to use 'gettext-h' instead.
57544         * modules/gettext-h (Description): Suggest GNU gettext, instead of
57545         the 'gettext' module.
57547 2016-01-24  Paul Eggert  <eggert@cs.ucla.edu>
57549         gnulib-tool: don't give up on ln -s so easily
57550         * gnulib-tool (func_ln_s): Don't give up on a later ln -s merely
57551         because an earlier one failed.  The targets could be on different
57552         file systems.  Problem reported by KO Myung-Hun in:
57553         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00081.html
57555         closedir: fix OS/2-related typos
57556         Problem reported by KO Myung-Hun in:
57557         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00107.html
57558         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Fix a couple of typos
57559         in the last couple of changes.
57561 2016-01-24  KO Myung-Hun  <komh78@gmail.com>
57563         openat_proc_name: fix that last '/' is overwritten on OS/2 kLIBC
57564         * lib/openat-proc.c (openat_proc_name): Increase dirlen by 1 after
57565         copying a directory.
57567 2016-01-24  Paul Eggert  <eggert@cs.ucla.edu>
57569         regex: treat [x] as x if x is a unibyte encoding error
57570         Problem reported by Aharon Robbins in:
57571         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00091.html
57572         * lib/regcomp.c (parse_byte) [!_LIBC && RE_ENABLE_I18N]: New function.
57573         (build_range_exp) [!_LIBC && RE_ENABLE_I18N]: Use it.
57575         closedir, dirfd, opendir: port to OpenSolaris 5.10
57576         * m4/closedir.m4 (gl_FUNC_CLOSEDIR):
57577         * m4/dirfd.m4 (gl_FUNC_DIRFD):
57578         * m4/opendir.m4 (gl_FUNC_OPENDIR):
57579         Don't use ${word##pat} substitution, as it doesn't work in
57580         OpenSolaris 5.10 /bin/sh.  Problem reported by Assaf Gordon in:
57581         http://bugs.gnu.org/22443#11
57583 2016-01-23  Paul Eggert  <eggert@cs.ucla.edu>
57585         bootstrap: use American spelling
57586         * build-aux/bootstrap: Honor American spelling.
57588 2016-01-22  Karl Berry  <karl@freefriends.org>
57590         * doc/posix-functions/localtime.texi,
57591         * doc/posix-functions/localtime_r.texi: @item needed for @itemize text.
57593 2016-01-21  Bruno Haible  <bruno@clisp.org>
57595         hash-pjw-bare: fix comment
57596         * lib/hash-pjw-bare.h (hash_pjw_bare): Fix comment.
57598         wcwidth: Replace also on OpenBSD 5.8
57599         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check the value of wcwidth(0xFF1A).
57600         * doc/posix-functions/wcwidth.texi: Update.
57602 2016-01-20  Pádraig Brady  <P@draigBrady.com>
57604         gnu-web-doc-update: fix addition of new files
57605         If there were already added (emnpty) dirs,
57606         then cvs aborts the add with the message:
57607           cvs [add aborted]: there is a version in <./dirname> already
57608         * build-aux/gnu-web-doc-update: Add directories separately
57609         to the addition of files, to avoid the above issue
57610         impacting the addition of files.
57612 2016-01-19  Daiki Ueno  <ueno@gnu.org>
57614         utimens-tests: avoid pulling gettext .m4 files
57615         Although this is not the right fix to the original problem:
57616         http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html
57617         it makes it possible again for consumer projects to use arbitrary
57618         version of gettext, through the steps described at:
57619         http://www.gnu.org/software/gnulib/manual/html_node/gettextize-and-autopoint.html
57620         See here for details:
57621         https://lists.gnu.org/r/bug-gnulib/2016-01/msg00079.html
57622         * modules/futimens-tests (Depends-on): Add 'gettext-h' in place of
57623         'gettext'.
57624         * modules/utimens-tests (Depends-on): Add 'gettext-h' in place of
57625         'gettext'.
57627 2016-01-18  Paul Eggert  <eggert@cs.ucla.edu>
57629         regex: pacify static checkers
57630         Problem and draft fix reported by Aharon Robbins in:
57631         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00082.html
57632         * lib/regcomp.c (build_charclass_op, create_tree) [lint]:
57633         Clear memory to pacify static checkers.
57635         regex: fix [ diagnostic
57636         Problem and fix reported by Aharon Robbins in:
57637         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00082.html
57638         * lib/regcomp.c (REG_EBRACK_IDX): Fix misleading diagnostic about [.
57640         regex: fix memory leaks
57641         Problem and draft fix reported by Aharon Robbins in:
57642         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00082.html
57643         * lib/regcomp.c (build_range_exp, build_charclass_op)
57644         * lib/regex_internal.c (re_dfa_add_node):
57645         Fix memory leak on failure.
57647 2016-01-18  Pádraig Brady  <P@draigBrady.com>
57649         fts: don't unconditionally use leaf optimization for NFS
57650         NFS st_nlink are not accurate on all implementations,
57651         leading to aborts() if that assumption is made.
57652         See <https://bugzilla.redhat.com/1299169>
57653         * lib/fts.c (leaf_optimization_applies): Remove NFS from
57654         the white list, and document the issue.
57656 2016-01-15  Paul Eggert  <eggert@cs.ucla.edu>
57657             KO Myung-Hun  <komh@chollian.net>
57659         gnulib-tool: don't assume ln -s works
57660         * gnulib-tool (func_ln_s): New function.
57661         (func_ln): Use it.
57663 2016-01-15  KO Myung-Hun  <komh@chollian.net>
57665         utimes: detect utimes() correctly on OS/2 kLIBC
57666         utimes() of OS/2 kLIBC has some limitations.
57667         1. OS/2 itself supports a file date since 1980 year in local time.
57668         2. OS/2 itself supports only even seconds for a file time.
57669         3. utimes() of OS/2 kLIBC does not work on an opened file.
57670         * m4/utimes.m4: Detect utimes() correctly on OS/2 kLIBC.
57671         * doc/posix-functions/utimes.texi: Document the above limitations of
57672         utimes() on OS/2 kLIBC.
57674 2016-01-15  Paul Eggert  <eggert@cs.ucla.edu>
57675             KO Myung-Hun  <komh@chollian.net>
57677         openat_proc_name: port to OS/2 kLIBC
57678         OS/2 kLIBC provides a function to retrive a path from a fd. Use it
57679         instead of /proc/self/fd.
57680         * lib/openat-proc.c (openat_proc_name):
57681         Don't assume file name length is less than INT_MAX.
57682         Port to OS/2 kLIBC with __libc_Back_ioFHToPath().
57684 2016-01-14  KO Myung-Hun  <komh@chollian.net>
57686         stdint: check _INTPTR_T_DECLARED for intptr_t etc.
57687         OS/2 kLIBC's stdint.h defines _INTPTR_T_DECLARED and needs its own
57688         definitions of intptr_t and uintptr_t (which use int and unsigned)
57689         to avoid clashes with declarations of system functions like sbrk.
57690         * lib/stdint.in.h (intptr_t, uintptr_t): Check
57691         _INTPTR_T_DECLARED before defining them.
57693         opendir, closedir, dirfd, fdopendir: port to OS/2 kLIBC
57694         * lib/closedir.c (closedir): Unregister fd if closedir() succeeds.
57695         * lib/dirent.in.h (_gl_register_dirp_fd, _gl_unregister_dirp_fd):
57696         Declare on kLIBC.
57697         * lib/dirfd.c (struct dirp_fd_list): New. Structures to keep track of
57698         fd associated with dirp.
57699         (_gl_register_dirp_fd): New. Register fd associated with dirp to
57700         dirp_fd_list.
57701         (_gl_unregister_dirp_fd): New. Unregister fd with closing it.
57702         (dirfd): Implemented for kLIBC.
57703         * lib/fdopendir.c (fdopendir): Implemented for kLIBC.
57704         * lib/opendir.c (opendir): New. Register fd and dirp pair if open()
57705         succeeds.
57706         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Replace if OS/2.
57707         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
57708         (REPLACE_DIRFD): Define to 1 if replaced.
57709         * m4/opendir.m4 (gl_FUNC_OPENDIR): Likewise.
57710         * modules/closedir (Depends-on): Add dirfd.
57711         * modules/dirfd (Depends-on): Add 'test $REPLACE_DIRFD = 1' to errno
57712         condition.
57713         (configure.ac): Add dirfd to LIBOBJS if $REPLACE_DIRFD = 1 as well.
57714         * modules/opendir (Depends-on): Add dirfd.
57716         dup, dup2, fcntl: support a directory fd on OS/2 kLIBC
57717         On OS/2 kLIBC, dup(), dup2() and fcntl() do not work on a directory fd.
57718         * lib/dup.c (dup_nothrow): New.
57719         * lib/dup2.c (klibc_dup2dirfd): New. dup2() for a directory fd.
57720         (klibc_dup2): New.
57721         * lib/fcntl.c (klibc_fcntl): New.
57722         * m4/dup.m4 (gl_FUNC_DUP): Check if dup() works on a directory fd.
57723         * m4/dup2.m4 (gl_FUNC_DUP2): Check if dup2() works on a directory fd.
57724         * m4/fcntl.m4 (gl_FUNC_FCNTL): Check if F_DUPFD works on a directory
57725         fd.
57727         pipe_filter_ii_execute: port to OS/2 kLIBC
57728         Pipes on kLIBC do not support O_NONBLOCK like Win32.
57729         * lib/pipe-filter-ii.c (start_wrapper, _beginthreadex, CloseHandle,
57730         WaiForSingleObject, WaitForMultipleObjects): New on OS/2 kLIBC.
57731         Reuse Win32 code on OS/2 kLIBC.
57732         * lib/spawn-pipe.c: Reuse Win32 code on OS/2 kLIBC.
57733         * lib/w32spawn.h: Do not include windows.h on OS/2 kLIBC.
57735         wchar: fix "conflicting types" error for __wcwidth on OS/2 kLIBC
57736         On OS/2 kLIBC, wcwidth is a macro that expands to the name of a
57737         static inline function.  The implementation of wcwidth in wcwidth.c
57738         causes a "conflicting types" error.
57739         * lib/wchar.in.h: Undefine wcwidth on OS/2 kLIBC.
57741         w32spawn: clear SHELL_SPECIAL_CHARS and SHELL_SPACE_CHAR on OS/2 kLIBC
57742         spawn() on OS/2 kLIBC is not silly like one on Windows
57743         * libc/w32spawn.h (SHELL_SPECIAL_CHARS, SHELL_SPACE_CHAR): Set both to
57744         empty string on OS/2 kLIBC.
57746         pipe-filter-aux: undefine HAVE_SELECT on KLIBC
57747         On OS/2 kLIBC, select() works only on sockets.
57748         * lib/pipe-filter-aux.h (HAVE_SELECT): Undefine on OS/2 kLIBC.
57750         binary-io: don't put fd in binary mode if it is a console on EMX
57751         * lib/binary-io.h (SET_BINARY): Don't put fd in binary mode if it is
57752         a console on EMX.
57754 2016-01-15  Pádraig Brady  <P@draigBrady.com>
57756         doc: mention unfixed issues with unsupported localtime() values
57757         * doc/posix-functions/localtime.texi: Mention that FreeBSD 10
57758         returns nonsense for localtime(2^56).
57759         * doc/posix-functions/localtime_r.texi: Likewise.
57761 2016-01-14  Pádraig Brady  <P@draigBrady.com>
57763         doc: mention setlocale() issues on OpenBSD
57764         * doc/posix-functions/setlocale.texi: Mention setlocale(LC_ALL,"")
57765         never fails, and the need to check categories individually.
57767 2016-01-14  Pádraig Brady  <P@draigBrady.com>
57769         sig2str: list all signals on FreeBSD >= 7
57770         FreeBSD >= 7 is contravening POSIX by not defining NSIG
57771         to the maximal statically defined signal value.
57772         It does define _SIG_MAXSIG though, so base SIGNUM_BOUND on that.
57773         * lib/sig2str.h (SIGNUM_BOUND): Define to (_SIG_MAXSIG - 2)
57774         where available, even when NSIG is defined.
57776 2016-01-13  Paul Eggert  <eggert@cs.ucla.edu>
57778         acl-permissions: port to USE_ACL==0 platforms
57779         I ran into this problem when building bleeding-edge GNU Emacs
57780         with gcc -fsanitize=address on Fedora 23.  On this platform
57781         the ACL library does not pass the 'configure' test and Emacs
57782         then does not build due in part to what appear to be typos in the
57783         ACL part of Gnulib.
57784         * lib/acl-internal.c (free_permission_context):
57785         * lib/acl-internal.h (struct permission_context):
57786         Test whether USE_ACL is nonzero, not whether it is defined.
57788 2016-01-12  Martin Sebor  <msebor@redhat.com>
57790         mktime: rename macro to avoid glibc clash
57791         * lib/mktime.c [DEBUG] (DEBUG): Rename to DEBUG_MKTIME.  See:
57792         https://sourceware.org/ml/libc-alpha/2016-01/msg00267.html
57794 2016-01-12  Paul Eggert  <eggert@cs.ucla.edu>
57796         Port "$@" to OpenIndiana ksh93
57797         In http://lists.gnu.org/r/bug-autoconf/2015-12/msg00000.html
57798         Pavel Raiskup reports that ${1+"$@"} runs afoul of a bug in /bin/sh
57799         (derived from ksh 93t+ 2010-03-05).  ${1+"$@"} works around an ancient
57800         bug long-dead shells, so remove the workaround.
57801         * build-aux/announce-gen, build-aux/do-release-commit-and-tag:
57802         * build-aux/gitlog-to-changelog, build-aux/gnu-web-doc-update:
57803         * build-aux/prefix-gnulib-mk, build-aux/update-copyright:
57804         * build-aux/useless-if-before-free, tests/test-update-copyright.sh:
57805         Use "$@" instead of ${1+"$@"}.
57807         Port Universal Time settings to strict POSIX
57808         * build-aux/announce-gen, build-aux/bootstrap:
57809         * build-aux/do-release-commit-and-tag, build-aux/git-version-gen:
57810         * build-aux/gitlog-to-changelog, build-aux/gnu-web-doc-update:
57811         * build-aux/gnupload, build-aux/mkinstalldirs:
57812         * build-aux/move-if-change, build-aux/prefix-gnulib-mk:
57813         * build-aux/update-copyright, build-aux/useless-if-before-free:
57814         * build-aux/vc-list-files, tests/test-strftime.c:
57815         Use TZ="UTC0", not TZ="UTC".  Either works on GNU platforms,
57816         but POSIX says the behavior of TZ="UTC" is undefined.
57818 2016-01-02  Paul Eggert  <eggert@cs.ucla.edu>
57820         msvc-inval: fix problem with unset shell var
57821         Problem reported by Karl Berry in:
57822         http://lists.gnu.org/r/bug-gnulib/2016-01/msg00004.html
57823         * modules/msvc-inval (Depends-on):
57824         AC_REQUIRE gl_MSVC_INVAL instead of merely calling it.
57825         * modules/msvc-nothrow (Depends-on): Likewise for gl_MSVC_NOTHROW.
57827 2016-01-01  Pádraig Brady  <P@draigBrady.com>
57829         tests: for compare_(), use cmp -s where available
57830         * tests/init.sh (compare_): Only fall back to cmp without
57831         the POSIX defined -s option, where this is not available.
57833 2016-01-01  Paul Eggert  <eggert@cs.ucla.edu>
57835         version-etc: new year
57836         * build-aux/gendocs.sh (version):
57837         * doc/gendocs_template:
57838         * doc/gendocs_template_min:
57839         * doc/gnulib.texi:
57840         * lib/version-etc.c (COPYRIGHT_YEAR):
57841         Update copyright dates by hand in templates and the like.
57842         * all files: Run 'make update-copyright'.
57844 2015-12-31  Paul Eggert  <eggert@cs.ucla.edu>
57846         human: fix output buffer overrun by 1
57847         * lib/human.c (human_readable): Fix off-by-one typo in buffer
57848         calculation that could lead to a one-byte buffer overrun.
57850 2015-12-28  Daiki Ueno  <ueno@gnu.org>
57852         maint: fix operator precedence in mbrtowc test
57853         This is a fix for test breakage introduced by commit 45228d96; the
57854         equality expression must be parenthesized when negated with '!',
57855         otherwise we always get:
57857           test-mbrtowc.c:49: assertion 'ret == (size_t)(-2)' failed
57859         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT): Negate the entire expression.
57860         * m4/mbrlen.m4 (gl_MBRLEN_EMPTY_INPUT): Likewise.
57862 2015-12-23  James Youngman  <jay@gnu.org>
57864         regexprops-generic: update from regex.h
57865         * doc/regexprops-generic.texi: update by running the regexprops binary
57866         from findutils (the command line is 'regexprops "Regular Expressions"
57867         generic').  The recent (ish) change (5a5a9388) to regex.h aligning
57868         gnulib with GNU grep had made this document out-of-date.
57870 2015-12-23  Pádraig Brady  <P@draigBrady.com>
57872         strftime-tests: avoid false failure on OS X
57873         * tests/test-strftime.c (struct localtime_rz_test): Add an
57874         ahistorical member which is used to warn rather than fail
57875         when tm_isdst isn't set for such entries.  This is the case for
57876         "1970-01-01 13:00:00 +1300 (NZDT)" on Darwin 13/14 at least.
57878 2015-12-20  Kamil Dudka  <kdudka@redhat.com>
57880         fts: ensure leaf optimization is used for NFS
57881         NFS provides usable dirent.d_type but not necessarily for all entries
57882         of large directories.  See <https://bugzilla.redhat.com/1252549>
57883         * lib/fts.c (leaf_optimization_applies): Append NFS on the white list.
57885 2015-12-20  Pádraig Brady  <P@draigBrady.com>
57887         fts: enable leaf optimization for XFS
57888         XFS provides usable dirent.d_type only for DT_DIR,
57889         but the noleaf optimization still applies.
57890         * lib/fts.c (leaf_optimization_applies): Add XFS to the white list.
57892 2015-12-17  Paul Eggert  <eggert@cs.ucla.edu>
57894         intprops: comment fix
57895         * lib/intprops.h: Fix comment.  Reported by Pádraig Brady in:
57896         http://lists.gnu.org/r/bug-gnulib/2015-12/msg00013.html
57898         intprops-test: work around GCC bug 68971
57899         Problem reported by Pádraig Brady in:
57900         http://lists.gnu.org/r/bug-gnulib/2015-12/msg00011.html
57901         * tests/test-intprops.c: Ignore -Woverflow in GCC 6 and earlier.
57902         (main): Add a case that better tests 64-bit long in this area.
57904 2015-12-09  Pavel Raiskup  <praiskup@redhat.com>
57906         gnulib-tool: allow multiple --local-dir usage
57907         * gnulib-tool: Use --local-dir to construct compound
57908         $local_gnulib_path path instead of $local_gnulib_dir.  Determine
57909         PATH_SEPARATOR early.
57910         (local_gnulib_dir): Rename into $local_gnulib_path everywhere.
57911         (func_gnulib_dir): Cut out PATH_SEPARATOR detection code into
57912         func_determine_path_separator because that needs to be detected
57913         earlier now.
57914         (func_determine_path_separator): New function.
57915         (func_path_foreach, func_path_foreach_inner): New functions.
57916         (func_path_prepend, func_path_append): Likewise.
57917         (func_lookup_local_file, func_lookup_local_file_cb): Likewise.
57918         (func_lookup_file, func_all_modules): Use new functions to work
57919         with local_gnulib_path.
57920         (func_modules_in_dir, func_exists_module): New callbacks for
57921         func_path_foreach.
57922         (func_exists_module, func_get_tests_module): Likewise.
57923         (func_is_local_file, func_should_symlink): New helper methods.
57924         (func_add_file, func_update_file): Use new func_should_symlink
57925         instead, DRY.
57926         (func_reconstruct_cached_local_gnulib_path): New helper.
57927         (func_reconstruct_cached_dir): New callback.
57928         (func_import): The cached_local_gnulib_dir renamed to
57929         cached_local_gnulib_path similarly to local_gnulib_dir.
57930         Use new func_reconstruct_cached_local_gnulib_path.
57931         (func_count_relative_local_gnulib_path): New sub-method.
57932         (func_create_testdir): Use func_should_symlink, DRY.
57933         (func_create_megatestdir): Use new functions to work with
57934         local_gnulib_path correctly.
57935         (func_append_local_dir): New helper.
57937 2015-12-08  Pádraig Brady  <P@draigBrady.com>
57939         fix freadptr to work with ungetc on all uClibc configs
57940         Reported at https://bugs.busybox.net/show_bug.cgi?id=4099
57941         where GNU coreutils cut(1) generates invalid output on uClibc
57942         when __UCLIBC_HAS_STDIO_GETC_MACRO__ is not defined.
57943         * lib/freadptr.c (freadptr): Return NULL if there are
57944         ungotten chars.  In this case freadseek() will iterate
57945         again to process the ungotten character.
57947 2015-11-13  Paul Eggert  <eggert@cs.ucla.edu>
57949         xalloc-oversized: improve performance with GCC 5
57950         * lib/xalloc-oversized.h (xalloc_oversized):
57951         Improve performance with GCC 5 by using __builtin_mul_overflow.
57953 2015-11-10  Paul Eggert  <eggert@cs.ucla.edu>
57955         intprops: new public macro EXPR_SIGNED
57956         Emacs can use this macro, so make it public.
57957         * doc/intprops.texi (Arithmetic Type Properties): Rename from
57958         'Integer Type Determination', since some of these macros apply
57959         to non-integer types.  Clarify what kinds of constant expressions
57960         these macros return.  Say when the arguments can be non-integers.
57961         Mention newly published macro EXPR_SIGNED.
57962         * lib/intprops.h (EXPR_SIGNED): Rename from _GL_INT_SIGNED, to
57963         make it public.  All uses changed.
57965         intprops: fix typo in clang port
57966         * lib/intprops.h (_GL_INT_OP_WRAPV): Fix misspelling of
57967         '__builtin_add_overflow' that is not caught by compiler.
57969 2015-11-05  Paul Eggert  <eggert@cs.ucla.edu>
57971         test-timespec: fix typo in previous change
57972         * tests/test-timespec.c (main): Fix typo that reduced test quality.
57974         timespec-sub: fix overflow bug; add tests
57975         * lib/timespec-add.c (timespec_add):
57976         * lib/timespec-sub.c (timespec_sub):
57977         Work even if time_t is narrower than int (a theoretical
57978         possibility).  Redo code for a bit more clarity.
57979         * lib/timespec-sub.c (timespec_sub):
57980         Fix off-by-2 bug if a.tv_sec == TYPE_MINIMUM (time_t) and 0 < b.tv_sec.
57981         * modules/timespec-tests, tests/test-timespec.c: New files.
57983         intprops-test: suppress -Woverlength-strings
57984         Problem reported by Pádraig Brady in:
57985         http://lists.gnu.org/r/bug-gnulib/2015-11/msg00008.html
57986         It is not worth the hassle to port this test to compilers that
57987         cannot handle long strings in diagnostics.
57988         * tests/test-intprops.c [__GNUC__]: Ignore -Woverlength-strings.
57990 2015-11-03  Pádraig Brady  <P@draigBrady.com>
57992         quotearg: add quotearg_n_style_colon()
57993         This quotes with default options of the specified style,
57994         but with quoting enabled for instances of ':'.
57995         * lib/quotearg.h (quotearg_n_style_colon): Description and declaration.
57996         * lib/quotearg.c (quotearg_n_style_colon): New function implementation.
57998 2015-11-04  Paul Eggert  <eggert@cs.ucla.edu>
58000         intprops: revise _WRAPV macros, revert _OVERFLOW
58001         The incompatible changes to the _OVERFLOW macros were too much of
58002         a hassle in practice, so revert them.  Instead, change the new
58003         _WRAPV macros to make them closer in behavior to GCC 5's new
58004         builtin_add_overflow etc. functions.  No other software was using
58005         these newly-added macros yet, so this should be OK.
58006         * NEWS: Revert previous change, since the incompatible change
58007         has been reverted, and nobody used the incompatible version.
58008         * doc/intprops.texi (Wraparound Arithmetic, Integer Type Overflow):
58009         Document revised behavior.
58010         (Integer Range Overflow): Adjust example to match above revisions.
58011         * lib/intprops.h (INT_ADD_OVERFLOW, INT_SUBTRACT_OVERFLOW)
58012         (INT_MULTIPLY_OVERFLOW): Revert previous change, so that
58013         these can be used in integer constant expressions again.
58014         (INT_CONST_ADD_OVERFLOW, INT_CONST_SUBTRACT_OVERFLOW)
58015         (INT_CONST_MULTIPLY_OVERFLOW): Remove, as these are no longer
58016         needed.
58017         (INT_CONST_ADD_WRAPV, INT_CONST_SUBTRACT_WRAPV)
58018         (INT_NEGATE_WRAPV, INT_CONST_MULTIPLY_WRAPV, INT_DIVIDE_WRAPV)
58019         (INT_REMAINDER_WRAPV, INT_LEFT_SHIFT_WRAPV):
58020         Remove, as they did not seem that useful.
58021         (INT_ADD_WRAPV, INT_SUBTRACT_WRAPV, INT_MULTIPLY_WRAPV)
58022         (_GL_INT_OP_WRAPV, _GL_INT_OP_WRAPV_LONGISH)
58023         (_GL_INT_OP_WRAPV_VIA_UNSIGNED):
58024         Support new semantics.
58025         (__has_builtin): New macro, if not alreay defined.
58026         (_GL__GENERIC_BOGUS, _GL_INT_OP_CALC, _GL_INT_OP_CALC1): New macros.
58027         * tests/test-intprops.c (INT_CONST_DIVIDE_OVERFLOW)
58028         (INT_CONST_REMAINDER_OVERFLOW, INT_CONST_LEFT_SHIFT_OVERFLOW)
58029         (INT_CONST_DIVIDE_WRAPV, INT_CONST_REMAINDER_WRAPV)
58030         (INT_CONST_LEFT_SHIFT_WRAPV): Remove.
58031         (CHECK_SBINOP, CHECK_SSUM, CHECK_SUM1, CHECK_SSUM1)
58032         (CHECK_SDIFFERENCE, CHECK_SPRODUCT, CHECK_PRODUCT1, CHECK_SPRODUCT1):
58033         New macros.
58034         (CHECK_BINOP, CHECK_UNOP, main, CHECK_SUM): Test new behavior.
58036 2015-11-03  Jim Meyering  <meyering@fb.com>
58038         intprops: add parentheses for when OP has precedence lower than "-"
58039         * lib/intprops.h (_GL_INT_OP_WRAPV_VIA_UNSIGNED): In "a OP b - c",
58040         "a OP b" must be parenthesized for when OP is like "<<", which has
58041         lower precedence than the following "-". Reported by Pádraig Brady.
58043 2015-11-03  Pádraig Brady  <P@draigBrady.com>
58045         quotearg: constify get_quoting_style parameters
58046         * lib/quotearg.h (get_quoting_style): Mark parameter as const.
58047         * lib/quotearg.c (get_quoting_style): Likewise.
58049 2015-11-02  Pádraig Brady  <P@draigBrady.com>
58051         quotearg: add support for $'' shell escaping
58052         * lib/quotearg.h: Add "shell-escape" and "shell-escape-always"
58053         items and descriptions.
58054         * lib/quotearg.c (quotearg_buffer_restyled): Add support for the
58055         above types by quoting like "shell", but using $'...' syntax
58056         for non printable characters, which should provide unambiguous
58057         printable output for any input.
58058         * tests/test-quotearg-simple.c: Update accordingly.
58060 2015-11-02  Pádraig Brady  <P@draigBrady.com>
58062         maint: use a more standard return from mbrtowc test
58063         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT): Don't return 1
58064         from the test program as this is non standard and often
58065         indicates an unhandled case in the test program.
58066         * m4/mbrlen.m4 (gl_MBRLEN_EMPTY_INPUT): Likewise.
58068 2015-10-30  Paul Eggert  <eggert@cs.ucla.edu>
58070         intprops: add WRAPV and const flavors for GCC 5
58071         If available, use GCC 5's builtin functions for efficient integer
58072         overflow checking.  Also, add macros like INT_ADD_WRAPV efficently
58073         and safely compute the low-order bits of the correct answer.
58074         A downside of these efficient functions is that they cannot be
58075         used in constant expressions, so add macros like INT_CONST_ADD_OVERFLOW
58076         and INT_CONST_ADD_WRAPV that can be used even in constant expressions.
58077         * NEWS: Document the incompatible changes to INT_ADD_OVERFLOW etc.
58078         * doc/intprops.texi (Integer Properties, Integer Type Overflow):
58079         Document the changes.
58080         (Wraparound Arithmetic): New section.
58081         (Integer Range Overflow):
58082         Put this subsection last, since it's least useful.
58083         * lib/intprops.h (INT_CONST_ADD_OVERFLOW)
58084         (INT_CONST_SUBTRACT_OVERFLOW, INT_CONST_MULTIPLY_OVERFLOW):
58085         New macros, with the meaning that INT_ADD_OVERFLOW etc. used to have.
58086         (INT_CONST_ADD_WRAPV, INT_CONST_SUBTRACT_WRAPV)
58087         (INT_NEGATE_WRAPV, INT_CONST_MULTIPLY_WRAPV, INT_DIVIDE_WRAPV)
58088         (INT_REMAINDER_WRAPV, _GL_INT_OP_WRAPV, _GL_EXPR_CAST)
58089         (_GL_INT_OP_WRAPV_LONGISH, INT_ADD_WRAPV, INT_SUBTRACT_WRAPV)
58090         (INT_MULTIPLY_WRAPV, _GL_OP_OVERFLOW, _GL_OP_WRAPV, _GL_OP_WRAPV_GENSYM):
58091         New macros.
58092         (INT_ADD_OVERFLOW, INT_SUBTRACT_OVERFLOW, INT_MULTIPLY_OVERFLOW):
58093         Generate calls to GCC builtins if available, for speed.
58094         * tests/test-intprops.c (INT_CONST_DIVIDE_OVERFLOW)
58095         (INT_CONST_REMAINDER_OVERFLOW, INT_CONST_LEFT_SHIFT_OVERFLOW)
58096         (INT_CONST_DIVIDE_WRAPV, INT_CONST_REMAINDER_WRAPV)
58097         (INT_CONST_LEFT_SHIFT_WRAPV): New macros.
58098         (main, CHECK_BINOP, CHECK_UNOP, CHECK_SUM, CHECK_PRODUCT)
58099         (CHECK_QUOTIENT, CHECK_REMAINDER):
58100         Test WRAPV and CONST flavors (when available) too.
58102 2015-10-30  Pádraig Brady  <P@draigBrady.com>
58104         doc: use extended timezone format in iso-8601 example
58105         * doc/parse-datetime.texi: The standard states that extended format
58106         is to be used consistently throughout.
58107         Note that lib/parse-datetime.y can handle either tz format.
58109 2015-10-25  Paul Eggert  <eggert@cs.ucla.edu>
58111         stdalign: port to Sun C 5.9
58112         * doc/posix-headers/stdalign.texi: Document this.
58113         * lib/stdalign.in.h (_Alignas): Sun C 5.9 also supports
58114         __attribute__ ((__aligned__ (...))).
58116 2015-10-20  Paul Eggert  <eggert@cs.ucla.edu>
58118         time_rz: fix comment about tzalloc
58119         * lib/time_rz.c (tzalloc): Fix comment.
58121 2015-10-18  Paul Eggert  <eggert@cs.ucla.edu>
58123         stdalign: work around pre-4.9 GCC x86 bug
58124         * lib/stdalign.in.h (_Alignof): Work around bug in pre-4.9 GCC on
58125         x86, when -std=gnu11 is used.  Problem reported by Jim Meyering in:
58126         http://lists.gnu.org/r/bug-gnulib/2015-10/msg00038.html
58128 2015-10-18  Pádraig Brady  <P@draigBrady.com>
58130         maint.mk: sc_tight_scope: remove extraneous expressions
58131         * top/maint.mk (tight_scope): This is not really required since
58132         commit 3ef58f46 as sed_wrap ensures we don't get an empty expression
58133         that matches all nm entries.  But it does remove extraneous entries
58134         that may be confusing or cause issue in future maintenance.
58136 2015-10-18  Paul Eggert  <eggert@cs.ucla.edu>
58138         time_rz: return NULL if localtime_r fails
58139         * lib/time_rz.c (localtime_rz): Return NULL if localtime_r fails,
58140         while still attempting to pacify bleeding-edge GCC.
58142         fts: port to C11 alignof
58143         * doc/posix-headers/stdalign.texi (stdalign.h):
58144         Document the C11 restriction.
58145         * lib/fts.c: Include stddef.h, for max_align_t.
58146         (fts_alloc): Align using max_align_t, not FTSENT.
58147         * modules/fts (Depends-on): Add stddef.
58149 2015-10-18  Jim Meyering  <meyering@fb.com>
58151         time_rz: avoid warning from bleeding-edge gcc's -Wnonnull
58152         Compiling with gcc version 6.0.0 20151017 (experimental) (GCC), I
58153         would see this:
58155         lib/time_rz.c: In function 'localtime_rz':
58156         lib/time_rz.c:292:15: error: nonnull argument 'tm' compared to NULL \
58157           [-Werror=nonnull]
58158                    if (tm && !save_abbr (tz, tm))
58159                        ^
58161         That was complaining about "tm" because it is a parameter that was
58162         declared with the __nonnull__ attribute.
58163         * lib/time_rz.c (localtime_rz): Don't bother setting "tm" to the
58164         result of localtime_r.
58166 2015-10-17  Jim Meyering  <meyering@fb.com>
58168         maint.mk: _gl_TS_function_match: fix "extern" name extracting regexp
58169         * top/maint.mk (_gl_TS_function_match): This heuristic extern-function-
58170         name-extraction regexp mistakenly used \S+, and would mistakenly
58171         extract "*F" from "extern int *F()" rather than the desired "F".
58172         Use \w+ instead.
58174 2015-10-17  Jim Meyering  <meyering@fb.com>
58176         maint.mk: sc_tight_scope: factor and support OS X
58177         * top/maint.mk (_gl_tight_scope): Address three issues:
58178         - factor out four instances of code that wraps a string in "^...$"
58179         - allow nm-reported symbol names to have an optional leading "_"
58180         - add "main" to the list of ignored variable names, because on os x,
58181         "main" has nm-reported type "S" in the variable-checking section.
58183 2015-10-16  Dmitry Smirnov  <onlyjob@member.fsf.org>
58185         safe-alloc-tests: fix typo in license header
58186         * tests/test-safe-alloc.c: Mention LGPL 2.1, not 3.1
58188 2015-10-15  Simon Reinhardt  <simon@keinstein.org>
58190         copy-file: fix mem leak in error case
58191         * lib/copy-file.c (qcopy_file_preserving): Free the 32KiB buffer
58192         upon error opening or performing I/O to the src and dest files.
58194 2015-10-15  Mike Frysinger  <vapier@chromium.org>
58196         localename: control langinfo.h inclusion
58197         This header is only used to work around buggy behavior in old
58198         versions of glibc, so do not include it all the time.  Otherwise
58199         we get build failures on systems that do not provide langinfo.h.
58200         * lib/localename.c: Wrap langinfo.h include with same ifdefs used
58201         in the source later on.
58202         The patch was originally submitted to gettext as:
58203         https://lists.gnu.org/r/bug-gettext/2015-10/msg00011.html
58205 2015-10-13  Paul Eggert  <eggert@cs.ucla.edu>
58207         binary-io, math, pthread, sys_socket, u64, unistd: port to strict C
58208         * lib/binary-io.c, lib/math.c, lib/pthread.c, lib/sys_socket.c:
58209         * lib/u64.c, lib/unistd.c:
58210         Append 'typedef int dummy;', to pacify compilers that are picky
58211         about empty translation units.
58213 2015-10-12  Pino Toscano  <ptoscano@redhat.com>
58215         accept4-tests: fix to avoid non portable flags
58216         * tests/test-accept4.c (main): Pass only SOCK_* flags to accept4(),
58217         as they are the only documented ones, and passing others may trigger
58218         EINVAL (seen on FreeBSD 10.1-RELEASE).
58219         * doc/glibc-functions/accept4.texi: Mention that we don't provide
58220         the SOCK_CLOEXEC or SOCK_NONBLOCK defines.
58222 2015-10-06  Pavel Raiskup  <praiskup@redhat.com>
58224         gnulib-tool: fix tests of 'extensions' module
58225         This complements f8fe25fab60e3c687a124 commit.
58226         * gnulib-tool (func_emit_pre_early_macros): New function, it wraps
58227         emitting of initial gl_EARLY macros.
58228         (func_import, func_create_testdir): All dumps of gl_PROG_AR_RANLIB
58229         replaced with func_emit_pre_early_macros call.
58231 2015-10-06  Paul Eggert  <eggert@cs.ucla.edu>
58233         unicase/locale-language: fix typo in utf-8 cookie
58234         * lib/unicase/locale-languages.gperf: Fix gperf input file format.
58235         Problem reported by Zbigniew Jędrzejewski-Szmek.
58237 2015-10-02  Paul Eggert  <eggert@cs.ucla.edu>
58239         xalloc: do not worry about GCC 5 warning on 32 bit
58240         * lib/xalloc.h: Revert previous change.
58241         I found a better way to fix this in coreutils.
58243 2015-10-02  Pádraig Brady  <P@draigBrady.com>
58245         xalloc: avoid GCC 5.1 warning on 32 bit
58246         * lib/xalloc.h: Disable -Wstrict-overflow for uses of
58247         xalloc_oversized(), which was seen to give this warning
58248         on GCC 5.1 on 32 bit: "assuming signed overflow does not occur
58249         when simplifying conditional".
58251 2015-10-02  Daiki Ueno  <ueno@gnu.org>
58253         uniname/uniname-tests: avoid compiler warnings
58254         * tests/uniname/test-uninames.c (fill_names, fill_aliases): Remove
58255         unused local variables.
58256         (test_alias_lookup): Fix alias name display in failure cases.
58258 2015-09-26  Paul Eggert  <eggert@cs.ucla.edu>
58260         c-ctype: do not worry about EBCDIC + char signed
58261         Drop support for EBCDIC with char being signed, as this breaks too
58262         many programs.  Problem reported by Ben Pfaff in:
58263         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00053.html
58264         * lib/c-ctype.h: Verify that we are not using EBCDIC with
58265         char being signed.
58266         (_C_CTYPE_LOWER_A_THRU_F_N): New macro.
58267         (_C_CTYPE_LOWER_N, _C_CTYPE_A_THRU_F): Use it.
58268         (_C_CTYPE_DIGIT, _C_CTYPE_LOWER, _C_CTYPE_PUNCT, _C_CTYPE_UPPER):
58269         (c_isascii, c_isgraph, c_isprint, c_ispunct, c_tolower, c_toupper):
58270         * tests/test-c-ctype.c (test_all):
58271         Simplify by assuming standard char values cannot be negative.
58272         * tests/test-c-ctype.c (NCHARS, to_char): Remove; all uses removed.
58274 2015-09-25  Paul Eggert  <eggert@cs.ucla.edu>
58276         c-ctype: port better to z/OS EBCDIC
58277         Problems reported by Daniel Richard G. in:
58278         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00050.html
58279         * lib/c-ctype.h (_C_CTYPE_CNTRL): Rewrite in terms of
58280         the C standard escapes and _C_CTYPE_OTHER_CNTRL.
58281         (_C_CTYPE_OTHER_CNTRL): New macro.
58282         * tests/test-c-ctype.c (test_all): Test from CHAR_MIN, not
58283         from SCHAR_MIN, as the functions are defined only from values
58284         promoted from char or from unsigned char, not necessarily from
58285         signed char.
58287 2015-09-25  Pavel Raiskup  <praiskup@redhat.com>
58289         gnulib-common.m4: fix gl_PROG_AR_RANLIB/AM_PROG_AR clash
58291         The gl_PROG_AR_RANLIB (it is always called by gl_EARLY) sets AR
58292         and ARFLAGS variables.  Doing this unconditionally could break
58293         later Automake's AM_PROG_AR invocation (at least it's
58294         AC_CHECK_TOOLS call to detect correct 'ar' binary).
58296         Original purpose of the gl_PROG_AR_RANLIB was only to handle the
58297         Amsterdam Compiler Kit, so make the previous code to have effects
58298         only on ACK, and rather automatically call the Automake's
58299         AM_PROG_AR as soon as possible to decide other cases.
58301         References:
58302         http://lists.gnu.org/r/bug-gnulib/2015-07/msg00001.html
58304         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): AC_BEFORE AM_PROG_AR.
58305         Set the AR/ARFLAGS to ACK defaults OR call AM_PROG_AR.  If neither
58306         is possible, keep setting AR/ARFLAGS to reasonable defaults.
58307         * gnulib-tool (func_import): Put the gl_USE_SYSTEM_EXTENSIONS
58308         right before gl_PROG_AR_RANLIB into gnulib-comp.m4 (if the
58309         'extensions' module is used.
58310         * modules/extensions (configure.ac-early): Remove as this snippet
58311         is added to gnulib-comp.m4 earlier anyway.
58313 2015-09-25  Paul Eggert  <eggert@cs.ucla.edu>
58315         sockets: MS Windows initalization fixes
58316         Problem reported by Test User in:
58317         http://lists.gnu.org/r/help-shishi/2015-09/msg00001.html
58318         * lib/sockets.h (SOCKETS_1_0, SOCKETS_2_0, SOCKETS_2_1):
58319         Correct the endianness.
58320         * lib/sockets.c (gl_sockets_startup): Return 2 on any version
58321         number mismatch, not just on <.  Cleanup before any such failure.
58323 2015-09-25  Mats Erik Andersson  <gnu@gisladisker.se>
58325         gc: fix detection of installed libgcrypt version
58326         * m4/gc.m4: Use AM_PATH_LIBCRYPT to test for libcrypt versions
58327         at least as recent as 1.4.4.  The previously used macro is not
58328         available now, since modules were removed in version 1.6.0.
58330 2015-09-25  Paul Eggert  <eggert@cs.ucla.edu>
58332         c-ctype: rewrite to use inline functions
58333         This simplifies maintenance, since it makes for just one
58334         implementation of each function, letting the compiler have the fun
58335         of optimization.  In practice this works well nowadays with GCC.
58336         E.g., c_isascii might need only three instructions even though the
58337         source code lists every ASCII character individually in a large
58338         switch statement.
58339         Also, fix some z/OS porting bugs reported by Daniel Richard G. in:
58340         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00037.html
58341         * NEWS: Document the API change.
58342         * lib/c-ctype.c: Drastically simplify, since this now just expands
58343         inline functions.
58344         * lib/c-ctype.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
58345         (C_CTYPE_INLINE): New macro.
58346         (C_CTYPE_CONSECUTIVE_DIGITS, C_CTYPE_CONSECUTIVE_LOWERCASE)
58347         (C_CTYPE_CONSECUTIVE_UPPERCASE): Remove.
58348         Verify that either ASCII or EBCDIC is being used.
58349         (_C_CTYPE_SIGNED_EBCDIC, _C_CTYPE_CNTRL, _C_CTYPE_A_THRU_F_N)
58350         (_C_CTYPE_DIGIT_N, _C_CTYPE_LOWER_N, _C_CTYPE_UPPER_N)
58351         (_C_CTYPE_CASES, _C_CTYPE_A_THRU_F, _C_CTYPE_DIGIT, _C_CTYPE_LOWER)
58352         (_C_CTYPE_UPPER, _C_CTYPE_PUNCT_PLAIN):
58353         New private macros.
58354         (_C_CTYPE_CNTRL): In EBCDIC, '\x07' is a control, not '\xff'.
58355         (c_isalnum, c_isalpha, c_isascii, c_isblank, c_iscntrl, c_isdigit)
58356         (c_isgraph, c_islower, c_isprint, c_ispunct, c_isspace, c_isupper)
58357         (c_isxdigit, c_tolower, c_toupper): Now inline functions.
58358         (c_tolower, c_toupper): When converting, return the unsigned char,
58359         as that is what z/OS does.
58360         * lib/c-strcaseeq.h (CASEEQ): Simplify in the light of the removal
58361         of some c-ctype.h macros.
58362         * modules/c-ctype (Depends-on): Add extern-inline; remove verify.
58363         * tests/test-c-ctype.c (test_all): Fix test for c_toupper and
58364         c_tolower promotion to be compatible with z/OS.
58366 2015-09-24  Pavel Raiskup  <praiskup@redhat.com>
58368         gitlog-to-changelog: trim only trailing whitespaces
58369         This is fix for --format regression introduced by commit
58370         2b93079a5d1baa4d;  it caused that --format='%s%n%n%b%n' (see the
58371         doubled %n string) had no effect anymore.  This format
58372         specification has been used e.g. by GNU paxuitils (commit
58373         edfd8bcc3).
58375         * build-aux/gitlog-to-changelog (main): Stop squashing multiple
58376         newlines in commmit messages.
58378 2015-09-23  Paul Eggert  <eggert@cs.ucla.edu>
58380         Test that c_iscntrl agrees with iscntrl, etc.
58381         Suggested by Daniel Richard G. in:
58382         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00034.html
58383         * modules/c-ctype-tests (Depends-on): Add ctype.
58384         * tests/test-c-ctype.c: Include <ctype.h>.
58385         (NCHARS): New constant.
58386         (test_agree_with_C_locale): New function.
58387         (main): Use it.
58388         (test_all): Use named constants.
58390         c-ctype: improve c_isascii testing
58391         * tests/test-c-ctype.c (test_all): Port c_isascii test to EBCDIC.
58392         Add a test to count the number of ASCII characters.
58394 2015-09-22  Paul Eggert  <eggert@cs.ucla.edu>
58396         savewd: remove SAVEWD_CHDIR_READABLE
58397         It was problematic in the light of file systems that ignore umask.
58398         Problem reported by Sebastian Unger in: http://bugs.gnu.org/21534
58399         * NEWS: Document this.
58400         * lib/mkancesdirs.c (mkancesdirs): MAKE_DIR now returns 0 if
58401         successful, -1 (setting errno) on failure, rather than something
58402         more complicated than that.
58403         * lib/mkdir-p.c (make_dir_parents):
58404         Do not use SAVEWD_CHDIR_READABLE.
58405         * lib/savewd.c (savewd_chdir):
58406         Remove support for SAVEWD_CHDIR_READABLE.
58407         * lib/savewd.h (SAVEWD_CHDIR_READABLE): Remove.
58409         c-ctype: port better to EBCDIC
58410         Problems reported by Daniel Richard G. in
58411         http://lists.gnu.org/r/bug-gnulib/2015-09/msg00020.html
58412         * lib/c-ctype.c: Include <limits.h>, for CHAR_MIN and CHAR_MAX.
58413         Include "verify.h".
58414         (C_CTYPE_ASCII, C_CTYPE_CONSECUTIVE_DIGITS)
58415         (C_CTYPE_CONSECUTIVE_LOWERCASE, C_CTYPE_CONSECUTIVE_UPPERCASE):
58416         Define as enum constants with value false, if not defined, so that
58417         code can use 'if' instead of 'ifdef'.  Using 'if' helps make the
58418         code more portable, as both branches of the 'if' are compiled on
58419         all platforms.
58420         (C_CTYPE_EBCDIC): New constant.
58421         Verify that the character set is either ASCII or EBCDIC.
58422         (to_char): New static function.
58423         (c_isascii, c_iscntrl):
58424         Assume standard control-character assignments for EBCDIC.
58425         (c_isalnum, c_isalpha, c_isdigit, c_islower, c_isgraph, c_isprint)
58426         (c_ispunct, c_isupper, c_isxdigit, c_tolower, c_toupper):
58427         Rewrite to use 'if' instead of 'ifdef'.
58428         Use to_char if non-ASCII.  Prefer <= to >=.
58429         Prefer true and false to 1 and 0, for booleans.
58430         (c_iscntrl): Use 'if', not 'ifdef'.
58431         * modules/c-ctype (Depends-on): Add verify.
58432         * tests/test-c-ctype.c: Include <limits.h>, for CHAR_MIN
58433         (to_char): New function.
58434         (test_all): Port to EBCDIC.  Add some more tests, e.g., for c_ispunct.
58436 2015-09-21  Pádraig Brady  <P@draigBrady.com>
58438         nanosleep: fix return code for interrupted replacement
58439         * lib/nanosleep.c (nanosleep): In the replaced nanosleep, ensure
58440         that we return -1 in the case the call is interrupted by a signal,
58441         rather than the current value of 1.
58442         Diagnosed and tested by Daniel Richard G.
58444 2015-09-19  Paul Eggert  <eggert@cs.ucla.edu>
58446         Diagnose ERE '()|\1'
58447         Problem reported by Hanno Böck in: http://bugs.gnu.org/21513
58448         * lib/regcomp.c (parse_reg_exp): While parsing alternatives, keep
58449         track of the set of previously-completed subexpressions available
58450         before the first alternative, and restore this set just before
58451         parsing each subsequent alternative.  This lets us diagnose the
58452         invalid back-reference in the ERE '()|\1'.
58454         regex: merge patches from libc
58456         2015-09-08  Joseph Myers  <joseph@codesourcery.com>
58457         Move bits/libc-lock.h and bits/libc-lockP.h out of bits/ (bug 14912).
58458         * lib/regex_internal.h:
58459         Include <libc-lock.h> instead of <bits/libc-lock.h>.
58461         2015-06-09  Joseph Myers  <joseph@codesourcery.com>
58462         Fix regcomp wcscoll, wcscmp namespace (bug 18497).
58463         * lib/regcomp.c (build_range_exp): Call __wcscoll instead of
58464         wcscoll.
58465         * lib/regexec.c (check_node_accept_bytes): Likewise.
58467         2015-06-05  Joseph Myers  <joseph@codesourcery.com>
58468         Fix regex wcrtomb namespace (bug 18496).
58469         * lib/regex_internal.c (build_wcs_upper_buffer): Call __wcrtomb
58470         instead of wcrtomb.
58472         2015-06-05  Joseph Myers  <joseph@codesourcery.com>
58473         Fix regex wctype namespace (bug 18495).
58474         * lib/regcomp.c (re_compile_fastmap_iter): Call __towlower
58475         instead of towlower.
58476         * lib/regex_internal.c (build_wcs_upper_buffer): Call __iswlower
58477         instead of iswlower.  Call __towupper instead of towupper.
58478         * lib/regex_internal.h (IS_WIDE_WORD_CHAR): Call __iswalnum
58479         instead of iswalnum.
58481         2015-01-07  Chris Metcalf  <cmetcalf@ezchip.com>
58482         * lib/regcomp.c (parse_bracket_exp): Initialize type to
58483         COLL_SYM in a couple of places to avoid uninitialized variable
58484         wanings on tilegx gcc 4.8.2.
58486         2014-11-24  Siddhesh Poyarekar  <siddhesh@redhat.com>
58487         * lib/regex_internal.h: Remove NOT_IN_libc.
58489         2014-11-17  Andreas Schwab  <schwab@suse.de>
58490         * lib/regex_internal.h: Don't include <locale/elem-hash.h>.
58492         2014-09-11  Roland McGrath  <roland@hack.frob.com>
58493         Move findidx nested functions to top-level.
58494         * lib/regcomp.c [_LIBC]: #include <locale/weight.h>.
58495         (build_equiv_class) [_LIBC]: Don't #include it inside the function.
58496         Pass new arguments to findidx.
58497         * lib/regexec.c [RE_ENABLE_I18N] [_LIBC]: #include <locale/weight.h>.
58498         [RE_ENABLE_I18N] (check_node_accept_bytes) [_LIBC]:
58499         Don't #include it inside the function.  Pass new arguments to findidx.
58500         * lib/regex_internal.h:
58501         [!NOT_IN_libc] [_LIBC]: #include <locale/weight.h>.
58502         (re_string_elem_size_at): Don't #include it inside the function.
58503         Pass new arguments to findidx.
58505         2014-08-01  Siddhesh Poyarekar  <siddhesh@redhat.com>
58506         Check if DEBUG is defined in regex_internal.c
58507         * lib/regex_internal.c: Check if DEBUG is defined and is set.
58509 2015-09-08   Assaf Gordon  <assafgordon@gmail.com>
58511         ceill: detect buggy OpenBSD implementation
58512         * m4/ceill.m4 (gl_FUNC_CEILL): Detect buggy openBSD implementation
58513         which returns zero for small values.  Discussed here:
58514         http://lists.gnu.org/r/bug-gnulib/2015-08/msg00010.html
58516 2015-09-08  Dave Chiluk  <chiluk@canonical.com>
58518         mountlist: add me_mntroot field on Linux machines
58519         * lib/mountlist.c (read_file_system_list): Populate me_mntroot in
58520         mount_entry so Linux machines based on /proc/self/mountinfo can
58521         distinguish between bind mounts and original mounts.  In reality bind
58522         mounts aren't treated differently than mountroot=/ mounts by the
58523         kernel, but the user often wants these bind mounts distinguished.
58524         * lib/mountlist.h (struct mount_entry): Add me_mntroot element.
58525         More details at https://pad.lv/1432871
58527 2015-09-08  Christian Egli  <christian.egli@sbs.ch>
58529         doc: Describe to use multiple instances of gnulib
58530         * doc/gnulib-tool.texi: Add a section to the manual outlining how two
58531         instances of gnulib with different modules can be used, for example one
58532         for a lib and another one for associated tools.
58534 2015-09-01  Pádraig Brady  <P@draigBrady.com>
58536         base32: mark function as __attribute__ const
58537         * lib/base32.h (isbase32): Mark __attribute__ const as
58538         suggested by GCC, and consistent with the base64 module.
58540 2015-08-20  Daiki Ueno  <ueno@gnu.org>
58542         gnulib-tool: don't transform binary files with sed
58543         * gnulib-tool (func_add_or_update): Don't apply sed_transform_* to
58544         .mo and .class files.
58545         Reported by Denis Denisov.
58547 2015-08-10  Daiki Ueno  <ueno@gnu.org>
58549         gperf: respect silent rules
58550         * modules/gperf (Makefile.am): Define V_GPERF, V_GPERF_, and
58551         V_GPERF_0 for silent rules.
58552         * modules/iconv_open (Makefile.am): Use V_GPERF.
58553         * modules/unicase/locale-language (Makefile.am): Likewise.
58554         * modules/unicase/special-casing (Makefile.am): Likewise.
58555         * modules/unictype/category-byname (Makefile.am): Likewise.
58556         * modules/unictype/combining-class-byname (Makefile.am): Likewise.
58557         * modules/unictype/joininggroup-byname (Makefile.am): Likewise.
58558         * modules/unictype/joiningtype-byname (Makefile.am): Likewise.
58559         * modules/unictype/property-byname (Makefile.am): Likewise.
58560         * modules/unictype/scripts (Makefile.am): Likewise.
58561         * modules/uninorm/composition (Makefile.am): Likewise.
58563 2015-08-03  Paul Eggert  <eggert@cs.ucla.edu>
58565         Improve port of stdalign to C++11
58566         Problem reported by Sundaram in:
58567         http://lists.gnu.org/r/bug-gnulib/2015-08/msg00003.html
58568         * lib/stdalign.in.h (alignof, alignas): Don't define if C++11 or newer.
58569         (__alignas_is_defined): Define if C++11 or newer.
58571 2015-08-01  Assaf Gordon  <assafgordon@gmail.com>  (tiny change)
58573         pmccabe2html: fix gawk regex escaping
58574         * build-aux/pmccabe2html: Add one more backslash to properly
58575         escape the gsub replacement value.  Fixes this error:
58576         gawk: ./build-aux/pmccabe2html:425: \
58577         warning: escape sequence `\&' treated as plain `&'
58579 2015-07-29  Paul Eggert  <eggert@cs.ucla.edu>
58581         time_rz: port to pedantic memcpy
58582         * lib/time_rz.c (tzalloc): Pacify pedantic memcpy implementations
58583         that reject memcpy (..., NULL, 0).
58585 2015-07-27  Paul Eggert  <eggert@cs.ucla.edu>
58587         time_rz: port better to MinGW
58588         Don't change tzname, as this makes MinGW dump core (Bug#21020).
58589         Instead, store the tzname copy in the struct tm_zone object.
58590         Problem reported by Eli Zaretskii in: http://bugs.gnu.org/21020#48
58591         * lib/strftime.c [!_LIBC]:
58592         * lib/time_rz.c: Include time-internal.h.
58593         * lib/strftime.c (strftime_case_) [!HAVE_TM_ZONE]: Infer the zone
58594         name from *TZ rather than from TZNAME, doable because *TZ now has
58595         a tzname_copy member.
58596         * lib/time-internal.h: New file, with contents taken from
58597         lib/time_rz.c.  It's separate because strftime.c now accesses
58598         struct tm_zone members.
58599         (struct tm_zone) [HAVE_TZNAME && !HAVE_TM_ZONE]:
58600         New member tzname_copy.
58601         * lib/time_rz.c (struct tm_zone): Move to time-internal.h.
58602         (tzalloc) [HAVE_TZNAME && !HAVE_TM_ZONE]:
58603         Initialize tzname_copy member.
58604         (save_abbr) [HAVE_TZNAME && !HAVE_TM_ZONE]: Save abbreviation
58605         in tzname_copy member.
58606         (revert_tz) [HAVE_TZNAME]: Remove no-longer-needed tzname saving.
58607         (restore_tzname): Remove; no longer needed.  All calls removed.
58608         * modules/time_rz (Files): Add lib/time-internal.h.
58610         time: port __need_time_t to MinGW
58611         * lib/time.in.h (__need_time_t): Do not treat specially on MinGW.
58612         Fix reported by Eli Zaretskii in: http://bugs.gnu.org/21020#36
58614 2015-07-25  Paul Eggert  <eggert@cs.ucla.edu>
58616         strftime: fix newly-introduced bug on Solaris
58617         * lib/strftime.c (strftime_case_): Set the local variable 'zone'
58618         consistently at the start, rather than doing some of the setup at
58619         the start and some in the %Z format spec.  This is cleaner, and
58620         works better with time_rz on platforms like Solaris where struct
58621         tm lacks a tm_zone member, as when !HAVE_TM_GMTOFF %z's calls to
58622         mktime_z and localtime_rz can mess up the tzname cache.
58624         test-strftime: test for Solaris bug
58625         * modules/strftime-tests (Depends-on): Add strerror.
58626         * tests/test-strftime.c: Include <errno.h>.
58627         (posixtm_test): New function, containing the old 'main'.
58628         (struct tzalloc_test, struct localtime_rz_test): New types.
58629         (TZ, LT): New static vars.
58630         (tzalloc_test): New function.
58631         (main): Rewrite in terms of posixtm_test and tzalloc_test.
58633         time_rz: port to Solaris etc.
58634         Works around a tzname problem on platforms like Solaris that have
58635         tzname but not tm_zone, by setting tzname at the appropriate time
58636         and restoring it later.
58637         * lib/time_rz.c (tzname_address, tzname_value) [HAVE_TZNAME]:
58638         New static vars.
58639         (save_abbr) [HAVE_TZNAME]: Set them.
58640         (revert_tz) [HAVE_TZNAME]: Clear or use them.
58641         (restore_tzname): New function.
58642         (localtime_rz, mktime_z): Use it.
58644         time_rz: now LGPL
58645         * modules/time_rz (License): Now LGPL, because strftime depends on it.
58647         time_rz: make a constant 'const'
58648         * lib/time_rz.c (local_tz): Now const.
58650         time_rz: fix off-by-one typo
58651         * lib/time_rz.c (extend_abbrs): Fix off-by-one typo.
58653 2015-07-23  Paul Eggert  <eggert@cs.ucla.edu>
58655         fprintftime, strftime: use timezone_t args
58656         * NEWS: Document the change.
58657         * lib/fprintftime.h (fprintftime):
58658         * lib/strftime.c (extra_args) [my_strftime]:
58659         * lib/strftime.h (nstrftime):
58660         Time zone arg is now of type timezone_t, not int.
58661         * lib/strftime.c (mktime_z) [_LIBC]: New macro.
58662         (__gmtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: Remove; no longer used.
58663         (my_strftime) [emacs && !my_strftime]:
58664         (emacs_strftimeu) [emacs && !FPRINTFTIME]:
58665         Remove; Emacs doesn't need this any more.
58666         (HAVE_TZSET) [my_strftime]: Unset, since we no longer want
58667         fprintftime and nstrftime to call tzset.
58668         (ut) [!my_strftime]: Remove, replacing with ...
58669         (tz) [!my_stftime]: ... this new macro.  All uses changed.
58670         (strftime_case_): Use localtime_rz and mktime_z instead
58671         of localtime_r and mktime.
58672         * modules/fprintftime (Depends-on): Add time_rz.
58673         * modules/strftime (Depends-on): Add time_rz.  Remove time_r.
58674         * tests/test-strftime.c (main): Adjust to new nstrftime API.
58676         time_rz: new module
58677         * MODULES.html.sh: Add time_rz.
58678         * lib/time_rz.c, m4/time_rz.m4, modules/time_rz: New files.
58679         * lib/time.in.h (timezone_t, tzalloc, tzfree, localtime_rz, mktime_z):
58680         New decls if _GNU_SOURCE && @GNULIB_TIME_RZ@ && ! @HAVE_TIMEZONE_T@.
58681         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS):
58682         New var HAVE_TIMEZONE_T (default 0).
58683         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS):
58684         New var GNULIB_TIME_RZ (default 0).
58685         * modules/time (time.h): Substitute the new vars.
58687         flexmember: license is now unlimited
58688         * modules/flexmember (License): Change to unlimited,
58689         since its only source file gives an unlimited license.
58691 2015-07-15  Eric Blake  <eblake@redhat.com>
58693         maint: update copyright paper procedures
58694         * config/srclist.txt: Drop outdated files.
58695         * doc/Copyright/conditions.txt: Update to latest.
58696         * doc/Copyright/assign.changes.manual: Delete.
58697         * doc/Copyright/assign.future.manual: Likewise.
58698         * doc/Copyright/assign.manual: Likewise.
58699         * doc/Copyright/assign.translation.manual: Likewise.
58700         * doc/Copyright/disclaim.changes.manual: Likewise.
58701         * doc/Copyright/disclaim.manual: Likewise.
58702         * doc/Copyright/disclaim.program: Likewise.
58704 2015-07-07  Daiki Ueno  <ueno@gnu.org>
58706         localename: fix link error on Illumos
58707         Illumos defines __sun, but does not have getlocalename_l nor the
58708         equivalent.  This partially reverts commit 387c214.
58709         * m4/localename.m4 (gl_LOCALENAME): Check if getlocalename_l is
58710         available, as well as uselocale.
58711         * lib/localename.c [HAVE_USELOCALE && __sun]: Don't fallback to
58712         use getlocalename_l if it is not available.
58714 2015-07-07  Daiki Ueno  <ueno@gnu.org>
58716         unistr/uN-strtok-tests: avoid a trivial leak
58717         * tests/unistr/test-u-strtok.h (test_u_strtok): Untabify.  Free
58718         input and delim after the multibyte delimiter tests.
58720 2015-07-04  Paul Eggert  <eggert@cs.ucla.edu>
58722         file-has-acl, acl-permissions: fix HP-UX typos
58723         Problem reported by John David Anglin in: http://bugs.gnu.org/20979
58724         * lib/file-has-acl.c (file_has_acl):
58725         * lib/set-permissions.c (context_acl_from_mode)
58726         (context_aclv_from_mode, set_acls):
58727         Fix some obvious typos when HAVE_GETCL /* HP-UX */.
58728         They were introduced by the recent ACL changes.
58730         regex: match current GNU grep behavior
58731         These symbols have not matched GNU grep behavior for quite some time.
58732         Fix prompted by Balazs Kezes bug report at: http://bugs.gnu.org/20974
58733         * lib/regex.h (RE_SYNTAX_GREP, RE_SYNTAX_EGREP):
58734         Change to match current GNU behavior.
58735         Simplify by expressing it as differences from POSIX BREs and EREs.
58736         (RE_SYNTAX_POSIX_EGREP): No longer differs from GNU behavior.
58738 2015-07-03  Jim Meyering  <meyering@fb.com>
58740         set-permissions.c: adjust acl_from_mode's cpp guard
58741         * lib/set-permissions.c (acl_from_mode): Guard with #ifdef
58742         directives identical to those guarding the sole use.
58743         Otherwise, on some systems, we'd get a warning about
58744         the function being defined but not used.
58745         Also, filter through cppi to correct misleading indentation
58746         of cpp directives.
58748 2015-07-03  Pádraig Brady  <P@draigBrady.com>
58750         tests: restrict shells to those that support 'local'
58751         The local keyword is very widely supported and used
58752         in tests in coreutils and grep at least.  Therefore
58753         restrict to testing with shells that support it.
58754         This mainly excludes /bin/sh on Solaris.
58755         * tests/init.sh (gl_shell_test_script_): Add a test for 'local'.
58757 2015-07-03  Seiya Kawashima  <skawashima@uchicago.edu>  (tiny change)
58758         and Daiki Ueno  <ueno@gnu.org>
58760         unistr/uN-strtok: handle multibyte delimiters
58761         Previously, uN_strtok moved PTR to the next unit to the token end.
58762         When DELIM contained a multibyte character, the new position could
58763         be a middle of a multibyte character.
58764         * lib/unistr/u-strtok.h (FUNC): Place PTR at the next character
58765         after the token.
58766         * lib/unistr/u8-strtok.c (U_STRMBLEN): New macro.
58767         * lib/unistr/u16-strtok.c (U_STRMBLEN): New macro.
58768         * lib/unistr/u32-strtok.c (U_STRMBLEN): New macro.
58769         * modules/unistr/u8-strtok (Depends-on): Depend on
58770         unistr/u8-strmblen.
58771         * modules/unistr/u16-strtok (Depends-on): Depend on
58772         unistr/u16-strmblen.
58773         * modules/unistr/u32-strtok (Depends-on): Depend on
58774         unistr/u32-strmblen.
58775         * tests/unistr/test-u-strtok.h: New file.
58776         * tests/unistr/test-u8-strtok.c: New file.
58777         * tests/unistr/test-u16-strtok.c: New file.
58778         * tests/unistr/test-u32-strtok.c: New file.
58779         * modules/unistr/u8-strtok-tests: New file.
58780         * modules/unistr/u32-strtok-tests: New file.
58781         * modules/unistr/u16-strtok-tests: New file.
58783 2015-07-02  Friedrich Haubensak  <hsk@fli-leibniz.de>
58785         update-copyright: fix test failure with perl >= 5.22 (trivial)
58786         * build-aux/update-copyright: Escape a literal left curly bracket,
58787         required with perl >= 5.22
58789 2015-07-02  Daiki Ueno  <ueno@gnu.org>
58791         u{16,32}-strstr-tests: relax timeout condition
58792         On slower platforms (e.g., Solaris 10/SPARC), u{16,32}-strstr
58793         tests can take longer than 5 seconds to complete.
58794         Reported by Dagobert Michelsen in:
58795         https://lists.gnu.org/r/bug-libunistring/2015-06/msg00006.html
58796         * tests/unistr/test-u16-strstr.c (main): Increase timeout from 5
58797         seconds to 10 seconds.
58798         * tests/unistr/test-u32-strstr.c (main): Likewise.
58800 2015-07-01  Pavel Raiskup  <praiskup@redhat.com>
58802         gnulib-common.m4: change the ARFLAGS default to 'cr'
58803         In some GNU/Linux distributions people started to compile 'ar'
58804         binary with --enable-deterministic-archives (binutils project).
58805         That, however, in combination with previous autotools long time
58806         working default AR{_,}FLAGS=cru causes warnings on such
58807         installations:
58808         ar: `u' modifier ignored since `D' is the default (see `U')
58809         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): Set ARFLAGS='cr' if not
58810         set already.
58812 2015-07-01  Pavel Raiskup  <praiskup@redhat.com>
58814         selinux-h: avoid double free after *getfilecon()
58815         Originally reported by Ben Shelton on bug-tar:
58816         http://lists.gnu.org/r/bug-tar/2015-04/msg00009.html
58817         * lib/getfilecon.c (map_to_failure): Set the already freed '*con'
58818         pointer to NULL.  Man getfilecon(3) says that any non-NULL '*con'
58819         param should be freed by freecon(3) (regardless the return value).
58821 2015-07-01  Pavel Fedin  <p.fedin@samsung.com>
58823         fix pty related tests issues on Windows (trivial)
58824         * lib/grantpt.c (grantpt): grantpt.c seems to be never used on Windows,
58825         however it's still present in tests/ subdirectory of the final project.
58826         Therefore avoid it to pass `make check`.
58827         * tests/test-openpty.c (main): Windows has no PTYs and gnulib's openpty()
58828         will just return -ENOSYS, so avoid this non applicable test allowing
58829         the build to proceed.
58831 2015-07-01  Pádraig Brady  <P@draigBrady.com>
58833         acl: fix definition of acl_from_mode on FreeBSD
58834         This was causing basic coreutils copy operations to fail
58835         with ENOTSUP or ENOENT error messages.
58836         * lib/acl-internal.h (acl_from_mode): Only define when
58837         ! defined HAVE_ACL_FROM_TEXT.  That allows the version
58838         of acl_from_mode() defined in lib/set-permissions.c to
58839         be used on FreeBSD at least.
58840         * lib/set-permissions.c: Fix up comment spelling,
58841         and a redundant variable assignment; noticed in passing.
58843 2015-06-30  Pádraig Brady  <P@draigBrady.com>
58845         readutmp: port to FreeBSD >= 9
58846         * lib/readutmp.h: Map utmpxname() to setutxdb().
58847         With that coreutils who(1) and pinky(1) tests pass.
58849 2015-06-30  Paul Eggert  <eggert@cs.ucla.edu>
58851         mgetgroups: port to strict OS X
58852         The previous fix wasn't working, so use a bigger hammer (Bug#20923).
58853         * lib/mgetgroups.c: Ignore -Wpointer-sign diagnostics.
58854         (getgrouplist_gids) [HAVE_GETGROUPLIST]: Remove.  All uses removed.
58855         * m4/mgetgroups.m4 (gl_MGETGROUPS): Revert recent changes.
58857 2015-06-29  Paul Eggert  <eggert@cs.ucla.edu>
58859         mgetgroups: port to strict OS X
58860         * doc/glibc-functions/getgrouplist.texi (getgrouplist):
58861         Document the getgrouplist problem.
58862         * lib/mgetgroups.c (getgrouplist_gids) [HAVE_GETGROUPLIST]:
58863         New macro.
58864         (mgetgroups): Use it.
58865         * m4/mgetgroups.m4 (gl_MGETGROUPS):
58866         Check for OS X signature for getgrouplist.
58868 2015-06-29  Jim Meyering  <meyering@fb.com>
58870         linkat: fix invalid definition of LINKAT_SYMLINK_NOTSUP on OS X
58871         It started like this when building coreutils' latest on OS X,
58872         invoking ./configure with a nonempty --cache=.cache:
58874           lib/linkat.c:46:42: error: operator '||' has no right operand
58875           lib/linkat.c: In function 'rpl_linkat':
58876           lib/linkat.c:330:27: error: #if with no expression
58878         Here's linkat.c's line 46:
58880           #if !HAVE_LINKAT || LINKAT_SYMLINK_NOTSUP
58882         Here's some context:
58884           $ grep linkat_nofoll .cache
58885           gl_cv_func_linkat_nofollow=${gl_cv_func_linkat_nofollow=no}
58886           $ grep LINKAT_SYM lib/config.h
58887           #define LINKAT_SYMLINK_NOTSUP
58889         The problem is that m4/linkat.m4's gl_FUNC_LINKAT
58890         uses AC_CACHE_CHECK to set LINKAT_SYMLINK_NOTSUP,
58891         but that violates a tenet of AC_CACHE_CHECK: it must
58892         have no side effect other than setting its cache variable.
58894         What happens is that when the cache is set, we'd skip the
58895         code in that AC_CACHE_CHECK call, and leave LINKAT_SYMLINK_NOTSUP
58896         defined to whatever value it happened to have in configure's
58897         environment.  In my case, it was not defined, so this later code:
58899           AC_DEFINE_UNQUOTED([LINKAT_SYMLINK_NOTSUP], [$LINKAT_SYMLINK_NOTSUP],
58900             [Define to 1 if linkat can create hardlinks to symlinks])
58902         would emit code with an empty RHS.
58904         * m4/linkat.m4 (gl_FUNC_LINKAT): Move the setting of
58905         $LINKAT_SYMLINK_NOTSUP out of the AC_CACHE_CHECK code block.
58907 2015-06-28  Jim Meyering  <meyering@fb.com>
58909         mountlist: avoid an unused-label warning on OS X
58910         * lib/mountlist.c (read_file_system_list) [MOUNTED_GETMNTINFO]:
58911         Building on OS X, I saw a warning about the "free_then_fail" label
58912         being unused.  Give it the _GL_UNUSED_LABEL attribute.
58914         error.c: correct printf-style format: %d -> %u
58915         * lib/error.c (error_at_line): Correct __fxprintf format to use %u,
58916         rather than %d, to match the type of "line_number", unsigned int.
58918 2015-06-25  Pádraig Brady  <P@draigBrady.com>
58920         fts: avoid reading beyond the heap allocation
58921         GCC 5.1.1 with -O2 and -fsanitize=address reports
58922         a read of size 4 from a heap object of size 3 is indeed invalid,
58923         though this may be due to incorrect padding assumptions by GCC, see:
58924         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66661
58925         * lib/fts.c (fts_alloc): Increase allocation to alignof(FTSENT).
58926         * modules/fts: Depend on stdalign.
58928 2015-06-24  Pádraig Brady  <P@draigBrady.com>
58930         savedir: avoid undefined behavior in qsort call
58931         GCC 5.1.1 -fsanitize=undefined with glibc 2.21 is returning:
58932         "runtime error: null pointer passed as argument 1,
58933          which is declared to never be null"
58934         * lib/savedir.c (streamsavedir): Avoid the call with no entries.
58936 2015-06-24  Pádraig Brady  <P@draigBrady.com>
58938         userspec: avoid undefined behavior in gettext call
58939         GCC 5.1.1 -fsanitize=undefined with glibc 2.21 is returning:
58940         "runtime error: null pointer passed as argument 2,
58941          which is declared to never be null"
58942         * lib/userspec.c (parse_with_separator): Avoid passing NULL to gettext()
58944 2015-06-20  Glenn Morris  <rgm@gnu.org>
58946         gitlog-to-changelog: improve gitmerge.el commits
58947         Let the Emacs ChangeLog generation process exclude "skipped"
58948         messages from merge commits (Bug#20717).
58949         * build-aux/gitlog-to-changelog: Handle gitmerge.el skipped commits.
58951 2015-06-20  Paul Eggert  <eggert@cs.ucla.edu>
58953         wchar: fix MinGW compilation warnings
58954         This lets Texinfo compile cleanly.  See Eli Zaretskii in:
58955         http://lists.gnu.org/r/bug-gnulib/2015-06/msg00050.html
58956         * lib/wchar.in.h: Do not use special invocation convention on MinGW.
58958 2015-06-20  Daiki Ueno  <ueno@gnu.org>
58960         uniname/uniname-tests: use pristine data files
58961         For copyright and maintenance reasons, use the data files from UCD
58962         without modification.
58963         * tests/uniname/test-uninames.c (FIELDLEN): Remove.
58964         (getfield): Remove.
58965         (aliases_count): New global variable.
58966         (fill_names): Skip comments and empty lines in the input.  Don't
58967         use getfield.
58968         (fill_aliases): Likewise.
58969         (main): Change the expected command line arguments to:
58970         NAMES... ["--" ALIASES...].
58971         * tests/uniname/test-uninames.sh: Adjust to the change in
58972         test-uninames.c.
58973         * tests/uniname/UnicodeDataNames.txt: Remove.
58974         * tests/uniname/UnicodeData.txt: New file, from Unicode 8.0.0.
58975         * tests/uniname/NameAliases.txt: Use the pristine copy of the data
58976         file from Unicode 8.0.0.
58978 2015-06-19  Pádraig Brady  <P@draigBrady.com>
58980         linked-list, linkedhash-list: avoid compiler warnings
58981         * lib/gl_anytree_list2.h: Add _GL_ATTRIBUTE_PURE to avoid
58982         -Werror=suggest-attribute=pure (from GCC 5.1.1).
58984 2015-06-19  Daiki Ueno  <ueno@gnu.org>
58986         libunistring: bump minimum version to 0.9.6
58987         * all modules depending on updated Unicode data: Regenerate.
58988         The modules are listed by a script that does:
58989         - for each file listed by: git show --oneline --name-only 705f4efc
58990           - deduce the containing modules, based on "Files:"
58991         - deduce the modules which depend on the containing modules, based
58992           on "Depends-on:"
58994 2015-06-18  Daiki Ueno  <ueno@gnu.org>
58996         uniname/uniname: update to Unicode 8.0.0
58997         * lib/uniname/uninames.h: Regenerate.
58998         * tests/uniname/NameAliases.txt: Update from Unicode 8.0.0.
58999         * tests/uniname/UnicodeDataNames.txt: Update from Unicode 8.0.0.
59001 2015-06-18  Daiki Ueno  <ueno@gnu.org>
59003         libunistring: update to Unicode 8.0.0
59004         * lib/gen-uni-tables.c (SIZEOF): New macro.
59005         (output_numeric): Increase the maximum number of fractions from
59006         128 to 160.  Increase the level3 value width from 7 bits to 8
59007         bits.  Use SIZEOF instead of a hard-coded integer.
59008         (output_blocks): Decrease the cut-off threshold from 0x30000 to
59009         0x28000.
59010         (fill_blocks): Increase the maximum number of blocks from 256 to
59011         384.  Use SIZEOF instead of a hard-coded integer.
59012         (get_lbp): Adjust to new characters added in Unicode 8.0.0.
59013         * lib/unictype/numeric.c (uc_numeric_value): Adjust the level3
59014         value width.
59015         * lib/unilbrk/lbrktables.c (unilbrk_table): Implement LBP21b and
59016         a new case added to LBP22.
59017         * lib/uniwidth/width.c (nonspacing_table_data): Add U+08E3,
59018         U+A69E, U+FE2E..U+FE2F, U+111CA..U+111CC, U+11300,
59019         U+115DC..U+115DD, U+1171D..U+1171F, U+11722..U+11725,
59020         U+11727..U+1172B, U+1DA00..U+1DA36, U+1DA3B..U+1DA6C, U+1DA75,
59021         U+1DA84, U+1DA9B..U+1DA9F, and U+1DAA1..U+1DAAF.
59022         * tests/uniwidth/test-uc_width2.sh: Same updates as in
59023         lib/uniwidth/width.c.
59024         * all generated files under lib/uni* and tests/uni*: Regenerate.
59026 2015-06-16  Pádraig Brady  <P@draigBrady.com>
59028         gnu-web-doc-update: add --mirror to remove stale files
59029         * build-aux/gnu-web-doc-update: Add a --mirror option to remove
59030         out of date files from the CVS server.  Since this is usually
59031         appropriate, a prompt is given when the option is not specified,
59032         along with the `cvs remove` command that would be run.
59034 2015-06-06  Paul Eggert  <eggert@cs.ucla.edu>
59036         acl-permissions: pacify -Wsuggest-attribute=const
59037         Problem reported by Masanari Iida in: http://bugs.gnu.org/20753
59038         * lib/acl-internal.h (free_permission_context):
59039         Declare with attribute const if ! (defined USE_ACL &&
59040         (HAVE_ACL_GET_FILE || defined GETACL)).
59042         fsync: document AIX misbehavior
59043         * doc/posix-functions/fsync.texi (fsync):
59044         Document failure on AIX with read-only file descriptor.
59046 2015-06-05  Jonathan Perkin  <jperkin@joyent.com>  (tiny change)
59048         stdio: Don't redefine gets when using C++
59049         * lib/stdio.in.h (gets): Disable warning on C++.
59051 2015-06-05  Paul Eggert  <eggert@cs.ucla.edu>
59053         acl-permissions: port to AIX, C89 HP-UX
59054         Problems reported by Michael Felt.
59055         * lib/file-has-acl.c (file_has_acl) [HAVE_STATACL]:
59056         * lib/get-permissions.c (get_permissions) [USE_ACL && HAVE_STATACL]:
59057         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]:
59058         * lib/set-permissions.c (set_acls) [HAVE_ACLX_GET && ACL_AIX_WIP]:
59059         Add cast for AIX, whose system calls are declared to accept
59060         char * even though the arguments are really char const *.
59061         * lib/get-permissions.c (get_permissions):
59062         If USE_ACL && HAVE_GETACL /* HP-UX */, don't assume C99.
59063         If USE_ACL && HAVE_STATACL /* older AIX */, add missing decl
59064         that broke a build.
59065         * lib/mountlist.c (read_file_system_list) [MOUNTED_VMOUNT]:
59066         Rework types to pacify xlc.
59068 2015-06-03  Pádraig Brady  <P@draigBrady.com>
59070         vasprintf-posix: avoid compiling vasnprintf where possible
59071         * modules/vasprintf-posix: Avoid compiling the large vasnprintf
59072         module where not required.  For example on a GNU/Linux system
59073         when gnulib-tool is run with the --conditional-dependencies option.
59075 2015-06-02  Pádraig Brady  <P@draigBrady.com>
59077         file-has-acl: fix build on Mac OS X 10
59078         This reverts commit f1b37e3a which doesn't work on Mac OS X >= 10.4
59079         which has an incompatible 6 parameter getxattr() call.
59080         * doc/glibc-functions/getxattr.texi: Mention the divergent getxattr()
59081         call on Mac OS X >= 10.4.
59082         * doc/glibc-functions/fgetxattr.texi: Likewise.
59083         * lib/file-has-acl.c: Revert to more complete combined check.
59084         * m4/acl.m4 (gl_FILE_HAS_ACL): Likewise.
59085         Reported by Jack Howarth.
59087 2015-06-02  Pádraig Brady  <P@draigBrady.com>
59089         prefix-gnulib-mk: remove no longer needed special case
59090         * build-aux/prefix-gnulib-mk (prefix): Since commit e3704b9c,
59091         continued lib_SOURCES lines are no longer present,
59092         so special case handling of such entries is not required.
59094 2015-06-01  Pádraig Brady  <P@draigBrady.com>
59096         acl: don't depend on the deprecated qacl module
59097         * modules/acl (Depends-on): Use q{copy,set}-acl instead.
59099 2015-06-01  Pádraig Brady  <P@draigBrady.com>
59101         gnulib-tool: concatenate lib_SOURCES to a single line
59102         * gnulib-tool: Refactor the line merging sed logic,
59103         and use that to output a single lib_SOURCES line for each module.
59104         gnulib using projects often postprocess this output to prepend
59105         subdir paths to each item, and having a single line simplifies this
59106         processing allowing better decoupling from the gnulib-tool output.
59108 2015-06-01  Pavel Fedin  <p.fedin@samsung.com>
59110         pthread_sigmask: discount system version if a simple macro (trivial)
59111         MinGW64 has: #define pthread_sigmask(H, S1, S2) 0
59112         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Call the
59113         function to ensure it's available.
59115 2015-05-31  Pádraig Brady  <P@draigBrady.com>
59117         readlinkat: avoid OS X 10.10 trailing slash bug
59118         * doc/posix-functions/readlink.texi: Mention that OS X 10.10
59119         has this bug.
59120         * doc/posix-functions/readlinkat.texi: Likewise.  Also mention
59121         that OS X 10.10 has this function.
59122         * lib/readlinkat.c (rpl_readlinkat): Handle the trailing slash bug,
59123         as done for readlink().
59124         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Check for the readlink()
59125         trailing slash bug, and assume readlinkat() has the same issue.
59126         Also fix a typo where $gl_cv_decl_readlink_works was tested,
59127         rather than the correct $gl_cv_decl_readlinkat_works.
59129 2015-05-29  Andreas Gruenbacher  <andreas.gruenbacher@gmail.com>
59131         acl-permissions: Fix build on Mac OS X and older AIX (Bug#20681)
59132         * lib/set-permissions.c (set_acls): Fix more errors introduced in the acl
59133         module rewrite.
59135         acl-permissions: Fix build on Solaris and Cygwin
59136         Reported by Tom G. Christensen <tgc@jupiterrise.com>:
59137         * lib/set-permissions.c (set_acls): The count, entries, ace_count, and
59138         ace_entries variables have moved into struct permission_context but
59139         they were still accessed as local variables here.
59141 2015-05-29  Pádraig Brady  <P@draigBrady.com>
59143         linkat: avoid OS X 10.10 trailing slash with symlink bug
59144         On Darwin 14.3.0 linkat(,"path1",,"dangling_symlink/",)
59145         causes the symlink to be dereferenced, and if it points
59146         to a non existent file, that file will be created as
59147         a hard link to "path1".
59148         This fixes a test failure in test-linkat.c.
59149         * m4/linkat.m4 (gl_FUNC_LINKAT): Augment the test with
59150         this case.  The existing workaround in linkat.c for
59151         trailing slash issues, suffices for this case.
59152         * doc/posix-functions/linkat.texi: Add OS X 10.10 to
59153         the list of platforms with trailing slash issues.
59155 2015-05-28  Pádraig Brady  <P@draigBrady.com>
59157         unlinkat: handle ignoring of ".." on Darwin 14
59158         * lib/unlinkat.c: unlinkat() has the same bug as unlink()
59159         on Mac OS X 10.10, where it ignores paths with a trailing "..",
59160         so handle in the same manner.
59161         * m4/unlinkat.m4: Comment on this Darwin issue.
59162         * doc/posix-functions/unlink.texi: Update the latest version
59163         where the issue was seen.
59164         * doc/posix-functions/unlinkat.texi: Mention this issue.
59165         Fixes a test failure in test-unlinkat.c.
59167 2015-05-27  Paul Eggert  <eggert@cs.ucla.edu>
59169         qacl: split into qcopy-acl and qset-acl
59170         Emacs needs the former, but not the latter.
59171         * modules/acl-permissions: New file, containing most of the old qacl.
59172         * modules/file-has-acl (Depends-on): Depend on acl-permissions, not qacl.
59173         * modules/qacl: Now merely depends on qcopy-acl and qset-acl.
59174         * modules/qcopy-acl, modules/qset-acl: New files.
59175         * MODULES.html.sh (File system functions):
59176         Mention the new modules, and mention qacl while we're at it.
59178 2015-05-27  Glenn Morris  <rgm@gnu.org>
59180         gitlog-to-changelog: new option --ignore-line
59181         (This patch is imported from the GNU Emacs master.)
59182         This option ignores individual commit lines matching a pattern.
59183         * build-aux/gitlog-to-changelog: Add --ignore-line option.
59185 2015-05-27  Andreas Gruenbacher  <agruenba@redhat.com>
59187         qacl: Reimplement qset_acl and qcopy_acl (Bug#20666)
59188         Implement get_permissions and set_permissions primitives for getting all
59189         the permissions of a file, storing them, and later setting them. (In the
59190         minimal case, the permissions consist only of a file mode.) Reimplement
59191         qset_acl and qcopy_acl based on these new primitives: this avoids code
59192         duplication and makes error handling more consistent.
59193         The Solaris and Cygwin code still uses duplicate code paths for setting
59194         a file mode while making sure that no acls exist and setting an explicit
59195         acl; this is no worse than before, but could be cleaned up.  The AIX
59196         code still doesn't read ACLs, it only makes sure that acls don't get in
59197         the way when setting a file mode.
59198         * lib/acl-internal.h (struct permission_context): New data structure.
59199         (get_permissions, set_permissions, free_permission_context): Declare.
59200         * lib/acl-internal.c (free_permission_context): New helper function.
59201         * lib/get-permissions.c (get_permissions): New helper function split off
59202         from qcopy_acl.
59203         * lib/set-permissions.c: (set_acls_from_mode): On Solaris, Cygwin, and
59204         AIX, set a file's permissions based only on a file mode.
59205         (acl_from_mode, context_acl_from_mode, context_aclv_from_mode): All
59206         other platforms construct a temporary acl from the file mode and set
59207         that acl in the same way as setting an acl read from the source file.
59208         This should help avoid code duplication and inconsistent / buggy
59209         behavior.
59210         (set_acls): New helper function Split off from qcopy_acl.
59211         (chmod_or_fchmod): Moved here from qset-acl.c.
59212         (set_permissions): New helper function.
59213         * lib/qcopy-acl.c (qcopy_acl): Rewrite using get_permissions and
59214         set_permissions.
59215         * lib/qset-acl.c (qset_acl): Rewrite using set_permissions.
59216         * modules/qacl: Add get-permissions.c and set-permissions.c.
59218         file-has-acl: Split feature tests again (Bug#20667)
59219         * lib/file-has-acl.c: Instead of testing for
59220         XATTR_NAME_POSIX_ACL_ACCESS and XATTR_NAME_POSIX_ACL_DEFAULT,
59221         define them when needed.
59222         * m4/acl.m4 (gl_FILE_HAS_ACL): With that, Paul's
59223         GETXATTR_WITH_POSIX_ACLS change shouldn't be needed anymore.
59225 2015-05-27  Pádraig Brady  <P@draigBrady.com>
59227         string: fix build failure on BSD/OSX with FORTIFY_SOURCE
59228         This avoids a conflict with "FORTIFY_SOURCE" variants
59229         of the string functions when they're replaced on NetBSD-6.0.1
59230         and Darwin-14.3.0 at least.
59231         * lib/string.in.h: Avoid including our "lib/string.h" while
59232         including the system <string.h>.
59234 2015-05-26  Eric Blake  <eblake@redhat.com>
59236         stdio: limit __gnu_printf__ witness to gcc 4.4+
59237         * lib/error.h (_GL_ATTRIBUTE_SPEC_PRINTF): Move gcc version probe...
59238         * m4/stdio_h.m4 (gl_STDIO_H): ...here.
59240         error: use correct printf attributes on mingw
59241         * lib/stdio.in.h (_GL_ATTRIBUTE_SPEC_PRINTF): New define.
59243         inttypes: force correct mingw PRIdMAX even without <stdio.h>
59244         * modules/inttypes (Depends-on): Require extensions, so that mingw
59245         always uses GNU style inttypes.
59246         * lib/inttypes.in.h: On mingw, include <stdio.h>.
59248         stdio: fix probe on mingw under gcc 5.1
59249         * m4/stdio_h.m4 (gl_STDIO_H): Change to compile test, to work
59250         around new gcc preprocessor rules.
59252 2015-05-07  Glenn Morris  <rgm@gnu.org>
59254         gitlog-to-changelog: parse "Tiny-change"
59255         * build-aux/gitlog-to-changelog: Treat "Tiny-change" like
59256         "Copyright-paperwork-exempt".  (Bug#20324)
59258 2015-05-06  Pádraig Brady  <P@draigBrady.com>
59260         doc: document glibc posix_fallocate() issues
59261         * doc/posix-functions/posix_fallocate.texi: Mention the
59262         glibc efficiency problems and issues with NFS.
59264 2015-05-05  Karl Berry  <karl@freefriends.org>
59266         * build-aux/gendocs.sh (usage): document new css default
59267         for HTML (--htmlarg).
59269 2015-04-29  Paul Eggert  <eggert@cs.ucla.edu>
59271         extern-inline: no need for workaround in GCC 5.1
59272         * doc/extern-inline.texi (extern inline):
59273         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
59274         GCC bugs 54113 and 63877 are fixed in GCC 5.1, so don't work
59275         around these bugs in GCC 5.1 and later.  Maybe in a decade or
59276         two we can remove these workarounds.
59278 2015-04-28  Pádraig Brady  <P@draigBrady.com>
59280         eealloc, pagealign_alloc, xalloc: avoid clang warnings
59281         Avoid [-Wunknown-attributes] warnings like:
59282         warning: unknown attribute '__alloc_size__' ignored
59283         * lib/xalloc.h: Don't use the __alloc_size__  attribute
59284         with clang, as support has been fully removed as of clang 3.5:
59285         https://github.com/llvm-mirror/clang/commit/c047507a
59286         * lib/eealloc.h: Likewise.
59287         * lib/pagealign_alloc.h: Likewise.
59289 2015-04-27  Paul Eggert  <eggert@cs.ucla.edu>
59291         tests: pacify GCC 5.1's stricter printf checking
59292         * tests/test-dirname.c (main):
59293         * tests/test-getaddrinfo.c (simple):
59294         * tests/test-getlogin.c (main):
59295         * tests/test-getndelim2.c (main):
59296         * tests/test-inttostr.c (CK):
59297         * tests/test-md5.c (main):
59298         * tests/test-read-file.c (main):
59299         * tests/test-sha1.c (main):
59300         Fix mismatches between printf format and value signedness.
59301         * tests/test-inttostr.c (FMT, CAST_VAL, V_min, V_max):
59302         Remove, as CAST_VAL always returned a value of type uintmax_t.
59304         fts: port to GCC 5.1 with --enable-gcc-warnings
59305         Without this fix, GCC 5.1 (correctly) warns about a subscript
59306         error on the fts_name component of FTSENT.  It's actually a
59307         flexible member, so define it that way on C99 or later hosts.
59308         * lib/fts.c (fts_alloc): Use offsetof, not sizeof, for a
59309         structure that now has a flexible array member.
59310         * lib/fts_.h (__FLEXIBLE_ARRAY_MEMBER): New macro.
59311         (FTSENT): fts_name is now flexible on C99-or-later platforms.
59312         * modules/fts (Depends-on): Add flexmember.
59314 2015-04-26  Paul Eggert  <eggert@cs.ucla.edu>
59316         file-has-acl: port to CentOS 6
59317         Problem reported by Tom G. Christensen in:
59318         http://lists.gnu.org/r/bug-gnulib/2015-04/msg00074.html
59319         * lib/file-has-acl.c: Use GETXATTR_WITH_POSIX_ACLS instead of a
59320         combination of HAVE_SYS_XATTR_H, HAVE_LINUX_XATTR_H, and
59321         HAVE_GETXATTR.
59322         * m4/acl.m4 (gl_FILE_HAS_ACL): Test fot the entire combination of
59323         linux/xattr.h, sys/xattr.h, getxattr, XATTR_NAME_POSIX_ACL_ACCESS,
59324         and XATTR_NAME_POSIX_ACL_DEFAULT, since that's what
59325         file-has-acl.c actually needs.
59327 2015-04-26  Pádraig Brady  <P@draigBrady.com>
59329         file-has-acl: always return false when ACLs aren't supported
59330         * lib/file-has-acl.c (file_has_acl): Consistent with other paths,
59331         change the GNU/Linux getxattr path, to transform "not supported"
59332         errors to a false return rather than an error.  This is handled
59333         within file_has_acl() due to the platform specific tests to
59334         determine if ACLs are not supported.
59336 2015-04-25  Paul Eggert  <eggert@cs.ucla.edu>
59338         gettext: propagate po/Makefile.in.in too
59339         * build-aux/po/Makefile.in.in: Copy from latest gettext.
59340         * config/srclist.txt: In build-aux/po, copy Makefile.in.in and
59341         remove-potcdate.sin from $GETTEXT.  This fixes a version mismatch
59342         between Makefile.in.in and the gettext-runtime m4 files.
59344 2015-04-24  Paul Eggert  <eggert@cs.ucla.edu>
59346         file-has-acl: new module, split from acl
59347         And add a new module file-has-acl-tests to match.
59348         I ran into a problem with the recent changes to the acl module,
59349         as they introduced a typo 'test use_xattrs = 0' into 'configure'.
59350         When using the fixed version with Emacs, I discovered that
59351         file-has-acl wasn't separated out well enough for Emacs (e.g., it
59352         had multiple libraries, but needed only one), so I fixed that too.
59353         * NEWS: Document this incompatible change.
59354         * modules/file-has-acl, modules/file-has-acl-tests: New files.
59355         * m4/acl.m4 (gl_FUNC_ACL_ARG): New macro, split from gl_FUNC_ACL.
59356         Initialize gl_need_lib_has_acl.
59357         (gl_FUNC_ACL): Require it.
59358         Simplify use of 'test'.  Set LIB_HAS_ACL if gl_need_lib_has_acl.
59359         Move the file-has-acl.c-relevant stuff to ...
59360         (gl_FILE_HAS_ACL): ... this new macro.  Rewrite to fix 'test
59361         use_xattrs = 0' typo, and omit some needless work.  Set
59362         gl_need_lib_has_acl=1 if we'll need LIB_HAS_ACL to be set
59363         when gl_FUNC_ACL is called.
59364         * modules/acl (Files, lib_SOURCES): Remove lib/file-has-acl.c.
59365         (Link): Remove $(LIB_HAS_ACL).
59366         * modules/acl-tests (Files, Depends-on, configure.ac, TESTS)
59367         (check_PROGRAMS): Move stuff relevant to file-has-acl to
59368         modules/file-has-acl-tests.
59369         (test_file_has_acl_LDADD): Move to modules/file-has-acl-tests.
59371         manywarnings: add GCC 5.1 warnings
59372         * build-aux/gcc-warning.spec: Add -Wabi=, -Warray-bounds,
59373         -Warray-bounds=, -Wc++14-compat, -Wc90-c99-compat,
59374         -Wc99-c11-compat, -Wshadow-ivar, -Wsized-deallocation,
59375         -Wsuggest-override, -Wuse-without-only.  Change
59376         -Wnormalized=... operands to match 5.1.
59377         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wbool-compare,
59378         -Wchkp, -Wdesignated-init, -Wdiscarded-array-qualifiers,
59379         -Wdiscarded-qualifiers, -Wformat-signedness,
59380         -Wincompatible-pointer-types, -Wint-conversion,
59381         -Wlogical-not-parentheses, -Wmemset-transposed-args, -Wodr,
59382         -Wshift-count-negative, -Wshift-count-overflow,
59383         -Wsizeof-array-argument, -Wsuggest-final-methods,
59384         -Wsuggest-final-types, -Wswitch-bool.  Remove -Warray-bounds,
59385         and add -Warray-bounds=2 as a special case.
59387 2015-04-21  Simon Josefsson  <simon@josefsson.org>
59389         doc: update FDL template to match FDL examples.
59390         * doc/alloca-opt.texi:
59391         * doc/alloca.texi:
59392         * doc/c-ctype.texi:
59393         * doc/c-strcase.texi:
59394         * doc/c-strcaseeq.texi:
59395         * doc/c-strcasestr.texi:
59396         * doc/c-strstr.texi:
59397         * doc/c-strtod.texi:
59398         * doc/c-strtold.texi:
59399         * doc/ctime.texi:
59400         * doc/error.texi:
59401         * doc/gcd.texi:
59402         * doc/gnulib-tool.texi:
59403         * doc/inet_ntoa.texi:
59404         * doc/intprops.texi:
59405         * doc/lib-symbol-visibility.texi:
59406         * doc/maintain.texi:
59407         * doc/parse-datetime.texi:
59408         * doc/quote.texi:
59409         * doc/regexprops-generic.texi:
59410         * doc/standards.texi: Remove spurious 'with' in FDL license
59411         template.
59413 2015-04-21  Paul Eggert  <eggert@cs.ucla.edu>
59415         lstat: fix cross-compilation 'ln -s' problem
59416         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK):
59417         Have the test program call 'symlink' rather than a separate
59418         script run 'ln -s'; this is more likely to work in
59419         cross-compilation environments.  Reported by Pavel Fedin in:
59420         http://lists.gnu.org/r/bug-gnulib/2015-04/msg00060.html
59422 2015-04-16  Ludovic Courtès  <ludo@gnu.org>
59424         gendocs.sh: default to a common CSS style sheet for HTML output
59425         * build-aux/gendocs.sh (htmlarg): Change default value.
59427 2015-04-15  Mats Erik Andersson  <gnu@gisladisker.se>
59429         gnulib-tool: output bold attribute more portably
59430         * gnulib-tool (func_show_module_list): Change hexadecimal
59431         numbers to octal in BOLD_ON and BOLD_OFF.  The use of hex
59432         encoded numbers as arguments to `printf' is not portable,
59433         and is not claimed by POSIX.  This is the case with FreeBSD.
59435 2015-04-15  Andreas Gruenbacher  <andreas.gruenbacher@gmail.com>
59437         qacl: Simplify HP-UX acl_nontrivial check
59438         * lib/acl-internal.c: Remove struct stat parameter from HP-UX's version of
59439         acl_nontrivial. Check if the acl has at most three entries instead (it must
59440         have exactly three entries according to the HP-UX documentation). Ignore
59441         uids and gids as long as an entry is either for a user (i.e., the owner),
59442         a group (i.e., the owning group), or others.
59443         * lib/acl-internal.h: Change HP-UX's acl_nontrivial prototype.
59444         * lib/qcopy-acl.c (qcopy_acl): With that, we no longer need to stat the file.
59446 2015-04-15  Andreas Gruenbacher   <andreas.gruenbacher@gmail.com>
59448         acl: On Linux, check for acls without libacl
59449         On Linux, use the getxattr syscall instead of the acl_extended_file libacl
59450         library function to check for the presence of acls, avoiding a library.
59451         * lib/file-has-acl.c: Include xattr headers if we have them.
59452         (file_has_acl): On Linux, use getxattr().
59453         * m4/acl.m4 (gl_FUNC_ACL): Define LIB_HAS_ACL as the libraries to link with for
59454         file_has_acl(). Check for xattr headers and getxattr().
59456 2015-04-14  Ángel González  <keisial@gmail.com>
59458         tempname: avoid unused parameter warnings (trivial)
59459         * lib/tempname.c (try_dir): Tag with __GL_UNUSED.
59460         (try_nocreate): Likewise.
59462 2015-04-14  HIRAMATSU Yoshifumi  <hiramatu@boreas.dti.ne.jp>
59464         fseeko: fix build failure on NetBSD >= 6 (trivial)
59465         * lib/fseeko.c (feeko): NetBSD 6 changed the definition of _offset
59466         from 'fpos_t struct' to __off_t, which is a typedef of __int64_t.
59468 2015-04-09  Paul Eggert  <eggert@cs.ucla.edu>
59470         gitlog-to-changelog: port to MS-Windows
59471         * build-aux/gitlog-to-changelog (git_dir_option):
59472         Use strftime with "%Y-%m-%d", not "%F", to avoid a bug in
59473         MS-Windows Perl.  Reported by Eli Zaretskii in:
59474         http://lists.gnu.org/r/emacs-devel/2015-04/msg00504.html
59476 2015-04-07  Karl Berry  <karl@gnu.org>
59478         gendocs: new option --tex for passing args to texi2dvi.
59479         * build-aux/gendocs.sh: new option --tex, default -t @finalout.
59480         (TEXI2DVI): cut to just command name.
59481         (usage): mention new option, and update copyright.
59482         <generate_tex>: use it.
59484 2015-04-07  Karl Berry  <karl@gnu.org>
59486         * config/srclistvars.sh (GETTEXT): new definition.
59487         * config/srclist.txt: use it for gettext .m4 files.
59488         Thread starting at http://lists.gnu.org/r/bug-gnulib/201
59489         and confirmed at http://lists.gnu.org/r/bug-gnulib/2015-02/msg00146.html
59490         and continuing into April.
59492 2015-04-07  Daiki Ueno  <ueno@gnu.org>
59494         uniname/uniname-tests: fix failure due to alias
59495         Reported by Jack Howarth in:
59496         <https://lists.gnu.org/r/bug-libunistring/2015-04/msg00000.html>.
59497         * tests/uniname/test-uninames.c (name_has_alias): New function.
59498         (test_inverse_lookup): Exclude character name with valid alias,
59499         from randomly generated character names.
59500         (main): Fill unicode_aliases before calling test functions.
59502 2015-04-03  Giuseppe Scrivano  <gscrivan@redhat.com>
59504         hash: remove deprecated hash_insert0 function
59505         * lib/hash.h (hash_insert0): Remove deprecated function.
59506         * lib/hash.c (hash_insert0): Likewise.
59508 2015-04-02  Pádraig Brady  <P@draigBrady.com>
59510         mountlist: remove dependency on libmount
59511         * lib/mountlist.c (read_file_system_list): Parse /proc/self/mountinfo
59512         directly, rather than depending on libmount, which has many
59513         dependencies due to its dependence on libselinux, as detailed at:
59514         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00063.html
59515         Note we restrict this to __linux__ as that's probably where this
59516         interface will remain.  If ever porting, it would be best
59517         to first pull the makedev() wrapper from coreutils to a gnulib module.
59518         Note also we don't add a getline dependency to the mountlist module,
59519         as all Linux versions are sufficient.
59521 2015-04-02  Paul Eggert  <eggert@cs.ucla.edu>
59523         stddef: port to pre-C11 GCC on x86
59524         On this platform, max_align_t should have an alignment of 8 even
59525         though the storage alignments of double, long, etc. max out at 4.
59526         Inspired by a comment of Andreas Schwab's here:
59527         https://sourceware.org/ml/libc-alpha/2015-04/msg00017.html
59528         * lib/stddef.in.h (_GL_STDDEF_ALIGNAS) [!HAVE_MAX_ALIGN_T]: New macro.
59529         (max_align_t) [!HAVE_MAX_ALIGN_T]: Use it.
59530         * tests/test-stddef.c: Test __alignof__ too, if available.
59532 2015-03-24  Pádraig Brady  <P@draigBrady.com>
59534         quotearg-simple-tests: add missing gl_FUNC_MMAP_ANON dependency
59535         * modules/quotearg-simple-tests: Reference m4/mmap-anon.m4
59537 2015-03-24  Tobias Stoeckmann  <tobias@stoeckmann.org>
59539         yesno: make EOL optional in ENABLE_NLS case also (trival)
59540         * lib/yesno.c (yesno): Check for EOL before replacing.
59541         * tests/test-yesno.sh: Add a test case (test along with gettext).
59543 2015-03-22  Paul Eggert  <eggert@cs.ucla.edu>
59545         fdopendir-tests: test it does not close its arg
59546         * tests/test-fdopendir.c (main): Test that fdopendir does not
59547         close its argument.  From a suggestion by David Grayson in:
59548         http://lists.gnu.org/r/bug-gnulib/2015-03/msg00039.html
59550 2015-03-20  Paul Eggert  <eggert@cs.ucla.edu>
59552         gitlog-to-changelog: trim trailing white space
59553         * build-aux/gitlog-to-changelog (main):
59554         Trim trailing white space from commit message lines.
59555         This is helpful for processing the GNU Emacs repository,
59556         which dates back to 1985 and contains a lot of such lines.
59558         gitlog-to-changelog: new option --ignore-matching
59559         * build-aux/gitlog-to-changelog (usage, git_dir_option, main):
59560         Support new option --ignore-matching=PAT, which ignores all
59561         commit messages whose first line matches PAT.
59563 2015-03-19  Paul Eggert  <eggert@cs.ucla.edu>
59565         fdopendir: port better to MinGW
59566         * lib/fdopendir.c (fd_clone_opendir) [REPLACE_FCHDIR]:
59567         Use 'dup' if dirfd fails.  Suggested by Eli Zaretskii in:
59568         http://lists.gnu.org/r/bug-gnulib/2015-03/msg00033.html
59569         * modules/fdopendir (Depends-on): Add dirfd.
59571 2015-03-18  Paul Eggert  <eggert@cs.ucla.edu>
59573         fdopendir: fix typo in comment
59574         * lib/fdopendir.c (fdopendir_with_dup): REPLACE_FCHDIR was misspelled.
59576 2015-03-09  Eric Blake  <eblake@redhat.com>
59578         error: document all entry points provided
59579         * doc/glibc-functions/error_print_progname.texi
59580         (error_print_progname): Mention the error module.
59581         * doc/glibc-functions/error_at_line.texi (error_at_line):
59582         Likewise.
59583         * doc/glibc-functions/error_message_count.texi
59584         (error_message_count): Likewise.
59585         * doc/glibc-functions/error_one_per_line.texi
59586         (error_one_per_line): Likewise.
59588 2015-03-03  Paul Eggert  <eggert@cs.ucla.edu>
59590         vasnprintf: pacify clang 3.5.0
59591         Problem reported by Werner Lemberg in:
59592         http://lists.gnu.org/r/bug-gnulib/2015-03/msg00000.html
59593         * lib/vasnprintf.c (VASNPRINTF): Omit casts that clang objects to.
59594         The casts aren't needed, since the characters in question are ASCII.
59596 2015-02-24  Paul Eggert  <eggert@cs.ucla.edu>
59598         glob, etc.: port to MSVC v18 on MS-Windows 8.1
59599         * lib/dirent--.h (GNULIB_defined_opendir):
59600         * lib/dirent.in.h (GNULIB_defined_opendir)
59601         (GNULIB_defined_closedir):
59602         * lib/getcwd.c, lib/glob.c, lib/mountlist.c (opendir, closedir):
59603         #undef only if Gnulib defined it.
59605         poll: port to MSVC v18 on MS-Windows 8.1
59606         Problem reported by Gisle Vanem in:
59607         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00139.html
59608         * lib/poll.c: Always include <sys/select.h> and <sys/socket.h>.
59609         * modules/poll (Depends-on) [!HAVE_POLL || REPLACE_POLL]:
59610         Add sys_socket.
59612 2015-02-24  Pádraig Brady  <P@draigBrady.com>
59614         tests: support stderr verification with returns_()
59615         * tests/init.sh (returns_): Disable tracing for this wrapper
59616         function, so that stderr of the wrapped command is unchanged,
59617         allowing for verification of the contents.
59619 2015-02-24  Pavel Hrdina  <phrdina@redhat.com>
59621         passfd: avoid valgrind uninitalised data warning
59622         * lib/passfd.c (sendfd): Reset the msg_controllen of msghdr,
59623         to include just the fd we've initialized, rather than including
59624         the extra space used for alignment.
59626 2015-02-23  Paul Eggert  <eggert@cs.ucla.edu>
59628         uniwbrk/u32-wordbreaks-tests: fix copyright
59629         * tests/uniwbrk/test-uc-wordbreaks.c: Fix copyright date.
59631         dup2: doc and test for Android bug
59632         Reported by Kevin Cernekee in:
59633         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00125.html
59634         * doc/posix-functions/dup2.texi (dup2): Document the bug.
59635         * m4/dup2.m4 (gl_FUNC_DUP2): Test for the bug.
59637 2015-02-23  Kevin Cernekee  <cernekee@google.com>
59639         Replace dup2() on Android
59640         * m4/dup2.m4 (gl_FUNC_DUP2): Android implements dup2() using dup3().
59641         Since dup3(fd, fd) fails but dup2(fd, fd) should pass, test-dup2
59642         fails.  Using rpl_dup2() fixes this because it has an explicit test
59643         for this condition.
59645 2015-02-22  Paul Eggert  <eggert@cs.ucla.edu>
59647         Android doesn't define RLIM_SAVED_*
59648         Portability problem reported by Kevin Cernekee in:
59649         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00122.html
59650         * doc/posix-headers/sys_resource.texi (sys/resource.h):
59651         Mention the portability problem.
59652         * lib/getdtablesize.c (RLIM_SAVED_CUR, RLIM_SAVED_MAX):
59653         Define if not defined.
59654         * m4/dup2.m4 (gl_FUNC_DUP2):
59655         * m4/fcntl.m4 (gl_FUNC_FCNTL):
59656         Likewise.
59658 2015-02-21  Paul Eggert  <eggert@cs.ucla.edu>
59660         vasnprintf-posix-tests: use consistent test
59661         * tests/test-vasnprintf-posix.c (test_function):
59662         Use "<" in assert instead of "<=", for consistency with other tests.
59664 2015-02-20  Paul Eggert  <eggert@cs.ucla.edu>
59666         printf, isinf, etc.: noncanonical != NaN
59667         Do not require that isinf, printf, etc. treat noncanonical
59668         values as NaNs.  Instead, require only that they do not crash.
59669         Problem reported by Joseph Myers in:
59670         https://sourceware.org/ml/libc-alpha/2015-02/msg00244.html
59671         * doc/posix-functions/dprintf.texi (dprintf):
59672         * doc/posix-functions/fprintf.texi (fprintf):
59673         * doc/posix-functions/isfinite.texi (isfinite):
59674         * doc/posix-functions/isinf.texi (isinf):
59675         * doc/posix-functions/isnan.texi (isnan):
59676         * doc/posix-functions/printf.texi (printf):
59677         * doc/posix-functions/snprintf.texi (snprintf):
59678         * doc/posix-functions/sprintf.texi (sprintf):
59679         * doc/posix-functions/vdprintf.texi (vdprintf):
59680         * doc/posix-functions/vfprintf.texi (vfprintf):
59681         * doc/posix-functions/vprintf.texi (vprintf):
59682         * doc/posix-functions/vsnprintf.texi (vsnprintf):
59683         * doc/posix-functions/vsprintf.texi (vsprintf):
59684         Document this.
59685         * m4/isfinite.m4 (gl_ISFINITEL_WORKS):
59686         * m4/isinf.m4 (gl_ISINFL_WORKS):
59687         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS):
59688         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE):
59689         * tests/test-isfinite.c (test_isfinitel):
59690         * tests/test-isinf.c (test_isinfl):
59691         * tests/test-isnan.c (test_long_double):
59692         * tests/test-isnanl.h (main):
59693         * tests/test-snprintf-posix.h (test_function):
59694         * tests/test-sprintf-posix.h (test_function):
59695         * tests/test-vasnprintf-posix.c (test_function):
59696         * tests/test-vasprintf-posix.c (test_function):
59697         Test only that noncanonical values do not cause crashes, not that
59698         they are treated as NaNs.  In some cases this means a larger
59699         output buffer is needed.
59701 2015-02-20  Jaroslav Skarvada  <jskarvad@redhat.com>
59703         fts: remove redundant close() (trivial)
59704         * lib/fts.c (fts_read): Remove redundant call to close().
59705         Spotted by coverity.
59707 2015-02-20  Paul Eggert  <eggert@cs.ucla.edu>
59709         getdtablesize: port better for Android
59710         Problem reported by Kevin Cernekee in:
59711         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00112.html
59712         * doc/glibc-functions/getdtablesize.texi (getdtablesize): Mention bug.
59713         * lib/getdtablesize.c (getdtablesize): Don't fall back on _SC_OPEN_MAX.
59714         Instead, just use getrlimit, taking care to avoid Cygwin bug.
59716         poll: fixes for large fds
59717         * lib/poll.c (poll): Don't check directly for NFD too large.
59718         Don't rely on undefined behavior in FD_SET when an arg exceeds
59719         FD_SETSIZE.  Always set revents afterwards, even if to zero.
59720         * tests/test-poll.c (poll1): Set revents to -1 instead of 0,
59721         as that makes the test a bit stricter.
59723 2015-02-19  Kevin Cernekee  <cernekee@google.com>
59725         fcntl: Fix cross compiling
59726         * m4/fcntl.m4 (gl_FUNC_FCNTL): Assign the guessed result to the
59727         correct variable name (gl_cv_func_fcntl_f_dupfd_works).
59729 2015-02-18  Paul Eggert  <eggert@cs.ucla.edu>
59731         dup2, fcntl: cross-compile better for Android
59732         Problem reported by Kevin Cernekee in:
59733         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00109.html
59734         * m4/dup2.m4 (gl_FUNC_DUP2): Don't guess no when cross-compiling
59735         for a Linux kernel.  That kernel bug was fixed on 2009-05-11, and
59736         there's little need to cross-compile for older kernels nowadays.
59737         * m4/fcntl.m4 (gl_FUNC_FCNTL): When cross-compiling, guess no only
59738         for systems where the bug is known to occur (AIX, Cygwin, Haiku).
59740 2015-02-18  Pádraig Brady  <P@draigBrady.com>
59742         getopt: don't crash on memory exhaustion
59743         * lib/getopt.c (_getopt_internal_r): Use degraded diagnostics on
59744         memory exhaustion.  In the _LIBC case we use alloca() as is
59745         already done in glibc, so we don't need to consider the separate
59746         error path in that awkward case.  Also fix a memory leak when
59747         ambiguous options are present.
59748         Reported by Tobias Stoeckmann
59750 2015-02-17  Mike Miller  <mtmiller@ieee.org>
59752         tempname: allow compilation with C++ (trivial)
59753         * lib/tempname.h [C++]: Specify extern "C" linkage.
59754         * lib/tempname.h (try_tempname):
59755         * lib/tempname.c (__try_tempname, __gen_tempname):
59756         Rename 'try' to 'tryfunc'.
59758 2015-02-17  Paul Eggert  <eggert@cs.ucla.edu>
59760         dup2, fcntl: port to AIX
59761         * m4/dup2.m4 (gl_FUNC_DUP2):
59762         * m4/fcntl.m4 (gl_FUNC_FCNTL):
59763         Prefer getrusage (RLIM_NOFILE ...)/rlim_cur to sysconf (_SC_OPEN_MAX).
59764         The former works on AIX 7.1 but the latter does not.
59765         Also, this may work better with Android; see:
59766         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00100.html
59768 2015-02-16  Paul Eggert  <eggert@cs.ucla.edu>
59770         getdtablesize, dup2, fcntl: port to Android
59771         Problem reported by Kevin Cernekee in:
59772         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00092.html
59773         * doc/glibc-functions/getdtablesize.texi (getdtablesize):
59774         Mention that getdtablesize doesn't work on Android.
59775         * lib/getdtablesize.c: Use getrlimit substitute only if
59776         getdtablesize is declared.  This should suffice for Cygwin
59777         while not breaking Android.
59778         * m4/dup2.m4 (gl_FUNC_DUP2):
59779         * m4/fcntl.m4 (gl_FUNC_FCNTL):
59780         Prefer sysconf (_SC_OPEN_MAX) to getdtablesize, as the former is
59781         standardized but the latter is not, and sysconf works on Android.
59782         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE):
59783         Also check that getdtablesize is declared.
59784         This removes the need for a special case for Android.
59786 2015-02-16  Kevin Cernekee  <cernekee@google.com>
59788         localename: Implement gl_locale_name_thread_unsafe for Android
59789         * lib/localename.c: Android API level >= 21 supports two hardcoded
59790         locales: C (POSIX) and C.UTF-8.  Distinguish them by checking
59791         the internal __locale_t struct.
59793 2015-02-16  Kamil Dudka  <kdudka@redhat.com>
59795         fts: avoid crash when a cycle is added while traversing
59796         This could be triggered by auto-mounting a recursive bind mount.
59797         Reported by Michael Chapman in: https://bugzilla.redhat.com/1188498
59798         * lib/fts.c (fts_read): Avoid removing the original hash table item
59799         when leaving a directory that caused a cycle, and preserve the FTS_DC
59800         flag.
59802 2015-02-16  Daiki Ueno  <ueno@gnu.org>
59804         uniname/uniname: support character alias
59805         * lib/uniname/gen-uninames.lisp (main): New argument ALIASFILE.
59806         Generate one-way mapping from aliases to codepoints in the
59807         generated tables.  Special case variation selectors to reduce
59808         table size.
59809         * lib/uniname/uniname.c (unicode_character_name): Special case
59810         variation selectors.
59811         (unicode_name_character): Special case variation selectors and
59812         their aliases.
59813         * lib/uniname/uninames.h: Regenerate.
59814         * tests/uniname/NameAliases.txt: New file, taken from UCD 7.0.0.
59815         * modules/uniname/uniname-tests (Files): Add
59816         tests/uniname/NameAliases.txt.
59817         * tests/uniname/test-uninames.c: Mark as static.
59818         (ALIASLEN): Define.
59819         (struct unicode_alias): New struct.
59820         (unicode_aliases): New variable.
59821         (fill_aliases): New function.
59822         (test_alias_lookup): New test function.
59823         (main): Run the 'test_alias_lookup' test if the second argument is
59824         given.
59825         * tests/uniname/test-uninames.sh: Supply NameAliases.txt as the
59826         second argument.
59828 2015-02-11  Kevin Cernekee  <cernekee@google.com>
59830         Fix FILE struct compatibility with Android API level >= 21
59831         * lib/stdio-impl.h: Test explicitly for __ANDROID__ instead of
59832         __sferror.  Recent versions of Bionic's stdio.h no longer define
59833         __sferror.
59834         * lib/fbufmode.c: Likewise.
59835         * lib/fflush.c: Likewise.
59836         * lib/fpurge.c: Likewise.
59837         * lib/freadable.c: Likewise.
59838         * lib/freadahead.c: Likewise.
59839         * lib/freading.c: Likewise.
59840         * lib/freadptr.c: Likewise.
59841         * lib/freadseek.c: Likewise.
59842         * lib/fseeko.c: Likewise.
59843         * lib/fseterr.c: Likewise.
59844         * lib/fwritable.c: Likewise.
59846         Assume unbroken ungetc() on Android
59847         * m4/ungetc.m4: Add Android case to host OS check.  The ungetc()
59848         test case passed when running on an Android host, and the code
59849         hasn't really changed since 2009.
59851         getdtablesize: Fix Android build
59852         * m4/getdtablesize.m4: Add Android case to host OS check.  Recent NDK
59853         versions have this symbol in the .so library (at least 32-bit
59854         platforms) but are missing the declaration in the header file,
59855         causing the m4 logic to guess incorrectly.
59857         localename: Fix Android build
59858         * modules/localename (Depends-on): Add langinfo.
59860         getugroups: Fix Android build
59861         * lib/getugroups.c: Don't reference unsupported {get,set,end}grent
59862         functions.
59864         euidaccess: Fix Android build
59865         * modules/euidaccess (Depends-on): Add fcntl-h to ensure that
59866         AT_EACCESS gets declared.
59868         linkat_nofollow: Add fallback case for cross compiling
59869         * m4/linkat.m4: Guess no for Darwin, yes otherwise.
59871         net_if: Handle content-free <net/if.h> system headers
59872         * m4/net_if_h.m4: Check to make sure <net/if.h> actually defines
59873         struct if_nameindex.  If not, enable the replacement header.
59875         signal_h: Fix Android build
59876         * lib/signal.in.h: Add Android to the list of platforms that declare
59877         pthread_sigmask() in <pthread.h> instead of <signal.h>.
59879         duplocale: Fix Android build of duplocale-tests
59880         * modules/duplocale-tests (Depends-on): Add langinfo, as the header
59881         is included by test-duplocale.c (but not by duplocale.c).
59882         * modules/duplocale-tests (configure.ac): Check for monetary.h.
59883         * tests/test-duplocale.c: Skip test if monetary.h is absent.
59884         * doc/posix-headers/monetary.texi: Add Android to the list of
59885         platforms missing monetary.h.
59887 2015-02-11  Pádraig Brady  <P@draigBrady.com>
59889         tests: avoid recent -Werror=unused-variable regression in test-locale
59890         * tests/test-locale.c (main): Reference the variable to avoid the
59891         "unused variable" warning.
59893 2015-02-11  Pádraig Brady  <P@draigBrady.com>
59895         maint: various whitespace cleanups in tempname
59896         * lib/tempname.c: Normalize spacing and line length.
59897         * lib/tempname.h: Likewise.
59898         * modules/tempname: Likewise.
59900 2015-02-11  Pádraig Brady  <P@draigBrady.com>
59902         tests: provide returns_() to simplify exit status checking
59903         * tests/init.sh (returns_): A new function for use in tests,
59904         to allow for easier checking of return values, where you expect
59905         a command to exit with failure status.  By checking for a particular
59906         exit code, you don't hide any crashes for example.
59908 2015-02-11  Pádraig Brady  <P@draigBrady.com>
59910         mountlist: only use libmount when specified
59911         There are currently many shared libs dependencies introduced by
59912         libmount with associated runtime and virt mem overhead.
59913         Therefore don't enable by default.
59914         * m4/ls-mntd-fs.m4: Use --with-libmount to enable at build time.
59916 2015-02-08  Daiki Ueno  <ueno@gnu.org>
59918         uniname/unimame-tests: don't link with -lunistring
59919         * modules/uniname/uniname-tests (Makefile.am): Don't link against
59920         $(LIBUNISTRING).  Document the rationale why we need to
59921         conditionalize the test.
59923 2015-02-07  Paul Eggert  <eggert@cs.ucla.edu>
59925         fstrcmp: don't assume strlen < INT_MAX
59926         * lib/fstrcmp.c: Include stddef.h and stdint.h.
59927         (uintptr_t): Remove, as we're now assuming stdint.
59928         (OFFSET, EXTRA_CONTEXT_FIELDS, fstrcmp_bounded):
59929         Prefer ptrdiff_t to int when the value could exceed INT_MAX
59930         if the input string is long.
59931         (fstrcmp_bounded): Check for size-calculation overflow.  Prefer
59932         uintptr_t to size_t when the underlying value is a pointer casted
59933         to an unsigned integer.  Avoid unnecessary 'buffer != NULL' test.
59934         * modules/fstrcmp (Depends-on): Add stdint.
59936         diffseq: prefer ptrdiff_t to ssize_t
59937         * lib/diffseq.h: In commentary, prefer ptrdiff_t to ssize_t.
59938         ptrdiff_t is the natural type for signed indexes.
59939         On a few older platforms, ssize_t is narrower than size_t.
59941         xalloc: fix typo that suppressed warnings
59942         * lib/xalloc.h: Add missing _GL_INLINE_HEADER_END.
59943         This typo, introduced a couple of years ago, mistakenly suppressed
59944         some -Wsuggest-attribute=const, -Wmissing-prototypes, and
59945         -Wmissing-declarations warnings.
59947         full-read: fix license notice typo
59948         * lib/full-read.h: Remove a stray line in the license notice.
59949         Reported by Sam Ellis in: http://bugs.gnu.org/19808
59951         crypto/gc: fix a -Wswitch warning
59952         Reported by Bruce Korb in:
59953         http://lists.gnu.org/r/bug-gnulib/2015-02/msg00046.html
59954         * lib/gc-gnulib.c (gc_hash_open): Fail faster if MODE is nonzero.
59956 2015-02-03  Pádraig Brady  <P@draigBrady.com>
59958         gnulib-tool: fix handling of patch(1) diagnostics
59959         * gnulib-tool: Send diagnostics from patch(1) to stderr,
59960         as otherwise gnulib-tool will reparse that output and attempt
59961         to lookup modules.
59963 2015-02-03  Pádraig Brady  <P@draigBrady.com>
59965         bootstrap: exit immediately upon gnulib-tool failure
59966         * build-aux/bootstrap: Exit immediately if gnulib-tool fails.
59967         This was noticed when gnulib-tool exited early due to failure
59968         to apply a patch in coreutils at http://hydra.nixos.org/eval/1172233,
59969         but various confusing errors were then given as the build proceeded.
59971 2015-02-02  Andreas Gruenbacher  <agruen@gnu.org>
59973         symlinkat: include all required header files
59974         * lib/symlinkat.c (HAVE_SYMLINK_AT): Add <sys/stat.h> for fstatat(),
59975         and string.h for strlen(), required at least on OS X 10.10 (Yosemite).
59976         Reported at https://savannah.gnu.org/bugs/index.php?44151
59977         and by Jack Howarth.
59979 2015-01-29  Pádraig Brady  <P@draigBrady.com>
59981         localename: support Solaris 12 and illumos
59982         * lib/localename.c (gl_locale_name_thread_unsafe): call
59983         getlocalename_l() on newer __sun platforms.
59984         Reported by Alexander Pyhalov.
59985         Fix suggested by Rich Burridge.
59987 2015-01-29  Alexander Pyhalov  <alp@rsu.ru>
59989         locale: fix tests on illumos (trivial)
59990         * tests/test-locale.c: LC_GLOBAL_LOCALE is a function call on illumos,
59991         so move from global scope to main().
59993 2015-01-24  Daiki Ueno  <ueno@gnu.org>
59995         unictype: avoid undefined left-shift behavior
59996         * lib/unictype/bidi_of.c (uc_bidi_class): Building libunistring with
59997         gcc's -fsanitize=shift and running its tests triggered:
59998           unictype/bidi_of.c:43:60: runtime error: left shift of 40167 by 16 \
59999             places cannot be represented in type 'int'
60000         Cast LHS to 'unsigned int' after integer promotion.
60001         * lib/unictype/categ_of.c (lookup_withtable): Likewise.
60002         * lib/unictype/joininggroup_of.c (uc_joining_group): Likewise.
60004 2015-01-20  Daiki Ueno  <ueno@gnu.org>
60006         libunistring: bump version of unitypes dependants
60007         Due to the header file search order, all the headers which depend
60008         on unitypes.h need to be generated, when the preinstalled
60009         libunistring is older.
60010         * modules/unicase/base (configure.ac): Bump minimum version to
60011         0.9.4.
60012         * modules/uniconv/base (configure.ac): Likewise.
60013         * modules/unilbrk/base (configure.ac): Likewise.
60014         * modules/uninorm/base (configure.ac): Likewise.
60015         * modules/unistdio/base (configure.ac): Likewise.
60016         * modules/unistr/base (configure.ac): Likewise.
60017         * modules/uniwbrk/base (configure.ac): Likewise.
60018         * modules/uniwidth/base (configure.ac): Likewise.
60020 2015-01-20  Daiki Ueno  <ueno@gnu.org>
60022         unictype/category-none: fix link with libunistring
60023         Since _UC_CATEGORY_NONE is not a public symbol, it will be
60024         prefixed with "libstring_" when compiled as part of libunistring.
60025         To avoid undefined symbol at link time, increase the minimum
60026         version when the dependant modules are updated.
60027         * modules/unictype/category-none (configure.ac): Bump minimum
60028         version to 0.9.5.
60030 2015-01-20  Daiki Ueno  <ueno@gnu.org>
60032         unitypes: fix build with installed libunistring
60033         The minimum version has not bumped after _UC_ATTRIBUTE_CONST and
60034         _UC_ATTRIBUTE_PURE were added to unitypes.in.h.
60035         * modules/unitypes (configure.ac): Bump minimum version to 0.9.4.
60037 2015-01-15  Paul Eggert  <eggert@cs.ucla.edu>
60039         time: port to MinGW32 3.21
60040         Problem reported by Eli Zaretskii in:
60041         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00042.html
60042         * lib/time.in.h:
60043         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC):
60044         * modules/time (Depends-on):
60045         Fall back on unistd.h if the other include files don't define
60046         struct timespec.
60048         update-copyright: apply to self
60049         * build-aux/update-copyright: Fix copyright date.  How ironic!
60051 2015-01-15  Daiki Ueno  <ueno@gnu.org>
60053         libunistring: update to Unicode 7.0.0
60054         * lib/unictype/joininggroup_byname.gperf: Add Straight Waw and
60055         Manichaean names.
60056         * lib/unictype/joininggroup_name.h: Likewise.
60057         * lib/unictype.in.h (UC_JOINING_GROUP_STRAIGHT_WAW)
60058         (UC_JOINING_GROUP_MANICHAEAN_ALEPH): New enumeration values.
60059         * lib/gen-uni-tables.c (UC_JOINING_GROUP_STRAIGHT_WAW)
60060         (UC_JOINING_GROUP_MANICHAEAN_*): New enumeration values.
60061         (fill_arabicshaping, joining_group_as_c_identifier): Support those
60062         enum values.
60063         (is_property_alphabetic): Accept newly added characters to
60064         cuneiform numeric signs.
60065         (is_property_default_ignorable_code_point): Reject U+0605.
60066         (FIELDLEN): Increase from 120 to 160.
60067         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0605,
60068         U+08FF, U+0C00, U+0C81, U+0D01, U+1AB0..U+1ABE, U+1BAC..U+1BAD,
60069         U+1CF8..U+1CF9, U+1DE7..U+1DF5, U+A9E5, U+AA7C, U+FE27..U+FE2D,
60070         U+102E0, U+10376..U+1037A, U+10AE5..U+10AE6, U+1107F, U+11173,
60071         U+1122F..U+11231, U+11234, U+11236..U+11237, U+112DF,
60072         U+112E3..U+112EA, U+11301, U+1133C, U+11340, U+11366..U+1136C,
60073         U+11370..U+11374, U+114B3..U+114B8, U+114BA, U+114BF..U+114C0,
60074         U+114C2..U+114C3, U+115B2..U+115B5, U+115BC..U+115C0,
60075         U+11633..U+1163A, U+1163D, U+1163F..U+11640, U+16AF0..U+16AF4,
60076         U+16B30..U+16B36, U+1BC9D..U+1BC9E, U+1BCA0..U+1BCA3, and
60077         U+1E8D0..U+1E8D6.
60078         (uc_width): Adjust nonspacing_table_ind boundary from 240 to 248.
60079         * tests/uniwidth/test-uc_width2.sh: Same updates as in
60080         lib/uniwidth/width.c.
60081         * all generated files under lib/uni* and tests/uni*: Regenerate.
60083 2015-01-14  Daiki Ueno  <ueno@gnu.org>
60085         libunistring: update to Unicode 6.3.0
60086         * lib/uniwbrk.in.h (WBP_DQ, WBP_SQ, WBP_HL): New enumeration values.
60087         * lib/uniwbrk/u-wordbreaks.h (FUNC): Support WB7a, WB7b, and WB7c.
60088         Update WB5, WB6, WB7, WB9, WB11, WB12, WB13a, and WB13b.
60089         * lib/uniwbrk/wbrktable.h (uniwbrk_table): Adjust table size.
60090         * lib/uniwbrk/wbrktable.c (uniwbrk_table): Support rule WB7a.
60091         Update WB5, WB9, WB10, WB13a, and WB13b.
60092         * tests/uniwbrk/test-uc-wordbreaks.c
60093         (wordbreakproperty_to_string): Support WBP_DQ, WBP_SQ, and WBP_HL.
60094         * lib/gen-uni-tables.c (UC_BIDI_LRI, UC_BIDI_RLI, UC_BIDI_FSI)
60095         (UC_BIDI_PDI): New enumeration values.
60096         (bidi_category_byname): Support those enum values.
60097         (is_WBP_MIDNUMLET): Exclude 0x0027 (SINGLE QUOTE), which is now a
60098         dedicated property assigned.
60099         (is_property_case_ignorable): Check 0x0027.
60100         (WBP_DQ, WBP_SQ, WBP_HL): New enumeration values.
60101         (get_wbp, debug_output_wbp, fill_org_wbp, debug_output_org_wbp)
60102         (output_wbp): Support those enum values.
60103         * lib/unictype.in.h (UC_BIDI_LRI, UC_BIDI_RLI, UC_BIDI_FSI)
60104         (UC_BIDI_PDI): New enumeration values.
60105         * lib/unictype/bidi_byname.gperf: Add those property names.
60106         * lib/uniwidth/width.c (nonspacing_table_data): Add U+061C,
60107         U+180E, U+1A1B, and U+2066..U+2069.
60108         * tests/uniwidth/test-uc_width2.sh: Same updates as in
60109         lib/uniwidth/width.c.
60110         * all generated files under lib/uni* and tests/uni*: Regenerate.
60112 2015-01-14  Daiki Ueno  <ueno@gnu.org>
60114         libunistring: update to Unicode 6.2.0
60115         * lib/unilbrk/lbrktables.h (LBP_RI): New enumeration value.
60116         (unilbrk_table): Adjust table size.
60117         * lib/unilbrk/lbrktables.c (unilbrk_table): Add a row and column
60118         for LBP_RI.
60119         * lib/uniwbrk.in.h (WBP_RI): New enumeration value.
60120         * lib/uniwbrk/u-wordbreaks.h (FUNC): Support rule WB13c.
60121         Normalize table index skipping ignored properties.
60122         * lib/uniwbrk/wbrktable.c (uniwbrk_table): Support WBP_RI.  Remove
60123         WBP_EXTEND and WBP_FORMAT, which are now computed without using
60124         the table.
60125         * lib/uniwbrk/wbrktable.h: Adjust table size.
60126         * lib/unigbrk.in.h (GBP_RI): New enumeration value.
60127         * lib/unigbrk/uc-is-grapheme-break.c (UC_IS_GRAPHEME_BREAK):
60128         Support rule GB8a.
60129         (UC_GRAPHEME_BREAKS_FOR, gb_table): Support GBP_RI.
60130         * tests/unigbrk/test-uc-is-grapheme-break.c
60131         (graphemebreakproperty_to_string): Support GBP_RI.
60132         * tests/uniwbrk/test-uc-wordbreaks.c
60133         (wordbreakproperty_to_string): Support WBP_RI.
60134         * lib/gen-uni-tables.c (LBP_RI): New enumeration value.
60135         (get_lbp, debug_output_lbp, fill_org_lbp, debug_output_org_lbp)
60136         (output_lbp): Support LBP_RI.  Adjust some characters changed from
60137         LBP_AL to LBP_ID.
60138         (output_lbp): Support LBP_RI.
60139         (WBP_RI): New enumeration value.
60140         (debug_output_wbp, fill_org_wbp, debug_output_org_wbp)
60141         (output_wbp): Support WBP_RI.
60142         (GBP_RI): New enumeration value.
60143         (output_gbp_test, fill_org_gbp): Support GBP_RI.
60144         * all generated files under lib/uni* and tests/uni*: Regenerate.
60146 2015-01-14  Daiki Ueno  <ueno@gnu.org>
60148         libunistring: update to Unicode 6.1.0
60149         * lib/gen-uni-tables.c (output_joining_group): Switch to
60150         3-level table to accommodate joining groups defined with higher
60151         codepoint value.  Since there are only 88 groups defined in
60152         Unicode 7.0.0, use 7-bit packed format for level3 entries.
60153         (get_lbp): Update for Unicode 6.1.0.
60154         * lib/unictype/joininggroup_of.c (uc_joining_group): Adjust to use
60155         3-level table.
60156         * lib/unictype/joininggroup_byname.gperf: Add Rohingya Yeh
60157         joining group name.
60158         * lib/unictype/joininggroup_name.h: Likewise.
60159         * lib/unilbrk/lbrktables.h (LBP_HL): New enumeration value.
60160         (unilbrk_table): Adjust table size.
60161         * lib/unilbrk/lbrktables.c (unilbrk_table): Add a row and column
60162         for LBP_HL.
60163         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0604,
60164         U+08E4..U+08FE, U+1BAB, U+1CF4, U+A674..U+A67B, U+A69F,
60165         U+AAEC..U+AAED, U+AAF6, U+11100..U+11102, U+11127..U+1112B,
60166         U+1112D..U+11134, U+11180..U+11181, U+111B6..U+111BE, U+116AB,
60167         U+116AD, U+116B0..U+116B5, U+116B7, U+16F8F..U+16F92.  Remove
60168         U+302E..U+302F.
60169         * tests/uniwidth/test-uc_width2.sh: Same updates as in
60170         lib/uniwidth/width.c.
60171         * all generated files under lib/uni* and tests/uni*: Regenerate.
60172         * modules/uni*/* (configure.ac): Bump minimum version to 0.9.5.
60174 2015-01-15  Daiki Ueno  <ueno@gnu.org>
60176         uniwbrk/u32-wordbreaks-tests: add conformance test
60177         * modules/uniwbrk/u32-wordbreaks-tests (Files): Add
60178         tests/uniwbrk/test-uc-wordbreaks.c,
60179         tests/uniwbrk/test-uc-wordbreaks.sh, and
60180         tests/uniwbrk/WordBreakTest.txt.
60181         (Makefile.am): Add uniwbrk/test-uc-wordbreaks.sh to $(TESTS), add
60182         test-uc-wordbreaks to $(check_PROGRAMS), and define
60183         test_uc_wordbreaks_SOURCES and test_uc_wordbreaks_LDADD.
60184         * tests/uniwbrk/test-uc-wordbreaks.sh: New file.
60185         * tests/uniwbrk/test-uc-wordbreaks.c: New file.
60187 2015-01-15  Daiki Ueno  <ueno@gnu.org>
60189         uniwbrk: ignore Extended/Format characters at BOL not BOS
60190         * lib/uniwbrk/u-wordbreaks.h (FUNC): Ignore Extend and Format
60191         characters if the previous character property is one of
60192         WBP_NEWLINE, WBP_CR, and WBP_LF.
60194 2015-01-11  Jim Meyering  <meyering@fb.com>
60196         test-strstr.c: avoid a trivial leak
60197         * tests/test-strstr.c (main): Free haystack.
60199         update-copyright: recognize groff's \(co marker
60200         * build-aux/update-copyright (circle_c_re): Also accept
60201         uses of \(co, as found in gzip.1.
60203 2015-01-08  Pádraig Brady  <P@draigBrady.com>
60205         maint.mk: fix compatibility with OS X nm
60206         * top/maint.mk (_gl_tight_scope): Use the -g option to
60207         show exported items rather than the -e option which is
60208         ignored on all platforms except OS X where it gives an error.
60209         Reported by Assaf Gordon.
60211 2015-01-07  KO Myung-Hun  <komh@chollian.net>
60213         localcharset: improve charset detection on OS/2
60214         Use system codepage when appropriate.  Map OS/2 codepages to
60215         GNU canonical charset names if possible.
60216         * lib/config.charset: Don't output aliases if "$os" is os2*.
60217         * lib/localcharset.c (get_charset_aliases) [OS2]: Hardcode the
60218         result for OS/2.
60219         (locale_charset) [OS2]: Use system codepage if codeset is omitted
60220         from the locale name which is neither "C" nor "POSIX".
60222 2015-01-06  Paul Eggert  <eggert@cs.ucla.edu>
60224         count-leading-zeros: use 64-bit intrinsics on 32-bit Windows
60225         This reverts the last patch but one, as it shouldn't be needed now
60226         that the typo is fixed.
60227         * lib/count-leading-zeros.h (count_leading_zeros_ll):
60228         * lib/count-trailing-zeros.h:
60229         * lib/count-one-bits.h:
60230         Go back to using 64-bit intrinsics.
60232         count-leading-zeros: fix pragma typos
60233         * lib/count-leading-zeros.h (_BitScanReverse, _BitScanReverse64):
60234         Fix typos in declaration of intrinsics when _MSC_VER.
60236 2015-01-06  Pádraig Brady  <P@draigBrady.com>
60238         count-leading-zeros: avoid 64-bit intrinsics on 32-bit Windows
60239         * lib/count-leading-zeros.h (count_leading_zeros_ll): Use 32 bit
60240         intrinsics in this case.
60241         * lib/count-trailing-zeros.h: Likewise.
60242         * lib/count-one-bits.h: Likewise.
60244 2015-01-06  Daiki Ueno  <ueno@gnu.org>
60246         uniname/uniname: update to Unicode 7.0.0
60247         To accommodate new characters added since Unicode 5.1.0, this
60248         changes the internal representation of codepoint ranges.
60249         Previously, we grouped codepoint ranges by manually assigned 4-bit
60250         tag, which only allowed 16 groups.  This removes the limitation by
60251         switching to binary search on a table.  For the detail rationale
60252         and the benchmark results, see:
60253         https://lists.gnu.org/r/bug-libunistring/2014-06/msg00001.html
60254         * lib/uniname/gen-uninames.lisp (unicode-char): Rename CODE member
60255         to INDEX, as it no longer represents a codepoint.
60256         (range): New struct.
60257         (main): Switch to intervals list from a bit-pattern based
60258         classification.
60259         * lib/uniname/uninames.h: Regenerate.
60260         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 7.0.0.
60261         * modules/uniname/base (configure.ac): Bump minimum version to
60262         0.9.5.
60263         * modules/uniname/uniname (configure.ac): Bump minimum version to
60264         0.9.5.
60266 2015-01-05  Eric Blake  <eblake@redhat.com>
60268         doc: update INSTALL from autoconf
60269         * doc/install.texi: Resync from autoconf.
60270         * doc/INSTALL: Reflect recent autoconf update.
60271         * doc/INSTALL.ISO: Likewise.
60272         * doc/INSTALL.UTF-8: Likewise.
60274         stdio: fix use of PRIdMAX on modern mingw
60275         * m4/stdio_h.m4 (gl_STDIO_H): Probe for printf flavor via inttypes.
60276         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM): Use result
60277         to work with modern mingw.
60279 2015-01-05  Daniel P. Berrange  <berrange@redhat.com>  (tiny change)
60281         pthread: detect git mingw builds with only partial pollution
60282         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for additional
60283         pollution, as seen temporarily in Fedora 21.
60285 2015-01-04  Paul Eggert  <eggert@cs.ucla.edu>
60287         lib-symbol-versions: cache script check
60288         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT):
60289         Cache the check for linker version scripts.
60290         From a suggestion by Christophe Curis in:
60291         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00011.html
60293 2015-01-04  Benno Schulenberg  <bensberg@justemail.net>
60295         maint: fix grammar nits in propername (trivial change)
60296         * lib/propername.h: Remove a mistaken comma and a duplicate "from",
60297         and use an adequate verb and tense.
60299 2015-01-02  Ludovic Courtès  <ludo@gnu.org>
60301         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
60302         * module/gendocs: Add 'doc/gendocs_template_min'.
60304         * build-aux/gendocs.sh: Change email addresses and upstream URLs
60305         from to Gnulib's.
60306         (scripturl, templateurl): Adjust accordingly.
60308 2015-01-01  Paul Eggert  <eggert@cs.ucla.edu>
60310         gendocs: copyright date and version fix
60311         Reported by Karl Berry in:
60312         http://lists.gnu.org/r/bug-gnulib/2015-01/msg00002.html
60313         * build-aux/gendocs.sh, doc/gendocs_template, doc/gendocs_template_min:
60314         Fix copyright date.
60315         * build-aux/gendocs.sh (scriptversion): Update.
60317 2015-01-01  Karl Berry  <karl@gnu.org>
60319         * doc/install.texi,
60320         * build-aux/mdate-sh,
60321         * build-aux/depcomp,
60322         * build-aux/config.guess,
60323         * build-aux/config.sub,
60324         * build-aux/ar-lib,
60325         * build-aux/compile: revert copyright updates (some from last
60326         year) in slaved files.
60328 2015-01-01  Paul Eggert  <eggert@cs.ucla.edu>
60330         version-etc: new year
60331         * doc/gnulib.texi:
60332         * lib/version-etc.c (COPYRIGHT_YEAR): Update copyright date.
60333         * all files: Run 'make update-copyright'.
60335 2014-12-30  Pádraig Brady  <P@draigBrady.com>
60337         xstrtol: ensure errno is reset
60338         Since commit 3bf75404, on 26-09-1998, errno may not have been reset.
60339         Noticed with a spurious coreutils test failure on Darwin 14.0.0.
60341         * lib/xstrtol.c (__xstrtol): Always reset errno before returning.
60343 2014-12-28  Paul Eggert  <eggert@cs.ucla.edu>
60345         utimens: fix dependency typo
60346         * modules/utimens (Depends-on): Remove 'assure'.
60347         This bug was introduced in the recent 'assure' patch.
60349 2014-12-22  Eric Blake  <eblake@redhat.com>
60351         docs: mention why libgen.h is bad
60352         * doc/posix-headers/libgen.texi (libgen.h): Refer to dirname module.
60354 2014-12-20  Paul Eggert  <eggert@cs.ucla.edu>
60356         assure: new module
60357         This works better than 'assert' when compiling with -DNDEBUG,
60358         as it avoids some compiler diagnostics in that case.
60359         Reported by Norihiro Tanaka in:
60360         http://lists.gnu.org/r/bug-gnulib/2014-12/msg00215.html
60361         * MODULES.html.sh (func_all_modules): Add 'assure'.
60362         * lib/assure.h, modules/assure: New files.
60363         * lib/chdir-long.c, lib/cycle-check.c, lib/fchdir.c, lib/fts.c:
60364         * lib/poll.c, lib/savewd.c, lib/xstrtol.c:
60365         Prefer 'assure' to 'assert'.
60366         * lib/utimens.c: Stop using 'assert'; it wasn't helpful.
60367         * modules/chdir-long, modules/cycle-check, modules/fchdir:
60368         * modules/poll, modules/savewd, modules/utimens, modules/xstrtol:
60369         Depend on 'assure'.
60371 2014-12-16  Paul Eggert  <eggert@cs.ucla.edu>
60373         stdalign: port better to HP compilers
60374         * m4/stdalign.m4 (gl_STDALIGN_H): Try the test if __HP_cc or
60375         __HP_aCC are nonzero, to be consistent with the 2014-01-20 patch.
60377         stdalign: work around Apple GCC 4.0 bug
60378         Reported by David Fang in:
60379         http://lists.gnu.org/r/bug-gnulib/2014-12/msg00194.html
60380         * lib/stdalign.in.h (_Alignas):
60381         * m4/stdalign.m4 (gl_STDALIGN_H):
60382         Do not use aligned attribute with GCC 4.0 on Apple.
60384 2014-12-16  Pádraig Brady  <P@draigBrady.com>
60386         getcwd: fix test failure on OS X 10.9
60387         * m4/getcwd-path-max.m4: Avoid the replacement if it
60388         won't be effective due to the PATH_MAX limitation of lstat().
60389         (gl_cv_func_getcwd_path_max): Adjust to indicate this case.
60390         * m4/getcwd.m4 (gl_FUNC_GETCWD): Define HAVE_GETCWD_SHORTER
60391         for this case for use in tests, and also exclude this
60392         case when setting REPLACE_GETCWD.
60393         * tests/test-getcwd.c (test_long_name): Restrict the
60394         tested path length so that lstat() will not be passed
60395         a path greater than PATH_MAX.
60396         Also key a test condition on HAVE_OPENAT_SUPPORT rather
60397         than AT_FDCWD, since the latter is set unconditionally
60398         since Sep 2009 in commit 52c658e9.
60400 2014-12-14  Tim Rühsen  <tim.ruehsen@gmx.de>
60402         parse-datetime: avoid a compiler warning with byacc (trivial)
60403         * lib/parse-datetime.y (yylex): Use the same prototype in the
60404         function definition as the declaration, to avoid a -Wstrict-prototypes
60405         warning seen when using byacc.
60407 2014-12-12  Daiki Ueno  <ueno@gnu.org>
60409         unicase/locale-language-tests: fix LOCALE_FR test
60410         * tests/unicase/test-locale-language.sh: Really use $LOCALE_FR for
60411         a French locale with traditional encoding.
60412         Reported by umerqayam in:
60413         http://lists.gnu.org/r/bug-libunistring/2014-12/msg00000.html
60415 2014-12-12  Paul Eggert  <eggert@cs.ucla.edu>
60417         stddef: support C11's max_align_t
60418         * doc/posix-headers/stddef.texi (stddef.h): Document max_align_t.
60419         * lib/stddef.in.h (_@GUARD_PREFIX@_STDDEF_H) [__need_wint_t]:
60420         Do not undef, as that might cause max_align_t to be defined twice.
60421         Instead, change use to check for _GL_STDDEF_WINT_T too.
60422         (max_align_t) [!HAVE_MAX_ALIGN_T]: New decl.
60423         * m4/stddef_h.m4 (gl_STDDEF_H, gl_STDDEF_H_DEFAULTS):
60424         Check for max_align_t.
60425         * modules/stddef (stddef.h): Substitute HAVE_MAX_ALIGN_T.
60426         * modules/stddef-tests (Depends-on): Add stdalign.
60427         * tests/test-stddef.c: Test max_align_t.
60429 2014-12-11  Daiki Ueno  <ueno@gnu.org>
60431         unistd: fix iOS check conditional
60432         On Mac OS X 10.8, the TARGET_* macros are unconditonally defined
60433         as 0 or 1 in <TargetConditionals.h>, and the previous check always
60434         yielded true on non-iOS environment.
60435         * lib/unistd.in.h (environ) [__APPLE__]: Check the values of
60436         TARGET_OS_IPHONE and TARGET_IPHONE_SIMULATOR, instead of whether
60437         they are defined.
60439 2014-12-09  Paul Eggert  <eggert@cs.ucla.edu>
60441         posixtm: avoid compiler warning in a better way
60442         * lib/posixtm.c (IF_LINT): Remove.
60443         (year, posix_time_parse):
60444         Return true (not 0) if successful.  All callers changed.
60445         (posix_time_parse): Simplify to pacify GCC without need for IF_LINT.
60447 2014-12-08  KO Myung-Hun  <komh78@gmail.com>
60449         * lib/relocatable.c (relocate): Prepend $UNIXROOT to pathname if it is
60450         started with '/' on EMX.
60452 2014-12-08  KO Myung-Hun  <komh78@gmail.com>
60454         freopen: workaround freopen() on OS/2 kLIBC
60455         * lib/freopen.c (rpl_freopen): Workaround.
60456         * m4/freopen.m4: Add os2* case.
60458         get_shared_library_fullname: port to EMX
60459         * lib/relocatable.c: Define strcmp and strncmp to stricmp and strnicmp
60460         on EMX, respectively.
60461         (_DLL_InitTerm): New on EMX.
60462         (get_shared_library_fullname): Implement on EMX.
60464         find_executable: port to EMX
60465         * lib/progreloc.c (find_executable): Implement on EMX.
60467         sched: check struct sched_param in spawn.h as well
60468         * lib/sched.in.h: Include spawn.h on kLIBC.
60469         * lib/sched_h.m4: Check struct sched_param in spawn.h as well.
60471 2014-12-08  Martin Kletzander  <mkletzan@redhat.com>  (tiny change)
60473         bootstrap: Allow perl modules in $buildreq
60474         * build-aux/bootstrap: Add case for perl modules.
60476 2014-12-08  Pádraig Brady  <P@draigBrady.com>
60478         apply _GL_ATTRIBUTE_PURE to some inline functions
60479         clang 3.4.2 flagged these inline functions as pure
60480         * lib/savewd.h (savewd_errno): Set _GL_ATTRIBUTE_PURE.
60481         * lib/sig-handler.h (get_handler): Likewise.
60482         * lib/stat-time.h (get_stat_{a,c,m,birth}time{,_ns}): Likewise.
60483         * lib/timespec.h (timespec_cmp, timespec_sign): Likewise.
60485 2014-12-06  Pádraig Brady  <P@draigBrady.com>
60487         vasnprintf: fix potential use after free
60488         * lib/vasnprintf.c (VASNPRINTF): Fix free-memory read,
60489         flagged by clang-analyzer 3.4.2.
60491 2014-12-05  Pádraig Brady  <P@draigBrady.com>
60493         filevercmp, posixtm: avoid compiler warnings with -O3
60494         * lib/filevercmp.h (filevercmp): Tag with _GL_ATTRIBUTE_PURE
60495         * lib/posixtm.c: (IF_LINT): Define.
60496         (posix_time_parse): Use it to void a "may be used uninitialized"
60497         warning, seen only with -O3.
60499 2014-12-05  Bruno Haible  <bruno@clisp.org>
60501         Fix LDBL80_WORDS macro on big endian platforms.
60502         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Add missing parenthesis in
60503         LDBL80_WORDS macro.
60504         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
60505         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
60506         * tests/test-isfinite.c (test_isfinitel): Likewise.
60507         * tests/test-isinf.c (test_isinfl): Likewise.
60508         * tests/test-isnan.c (test_long_double): Likewise.
60509         * tests/test-isnanl.h (main): Likewise.
60510         * tests/test-snprintf-posix.h (LDBL80_WORDS): Add missing parenthesis.
60511         * tests/test-sprintf-posix.h (LDBL80_WORDS): Likewise.
60512         * tests/test-vasnprintf-posix.c (LDBL80_WORDS): Likewise.
60513         * tests/test-vasprintf-posix.c (LDBL80_WORDS): Likewise.
60514         Reported by Pádraig Brady.
60516 2014-12-02  KO Myung-Hun  <komh78@gmail.com>
60518         git-version-gen: do not print new line characters
60519         * build-aux/git-version-gen: Use printf instead of echo and tr.
60521         gnulib-tool: recognize x:* as an absolute path
60522         * gnulib-tool (func_gnulib_dir): Add ?:* case.
60523         (func_relconcat): Likewise.
60525 2014-12-02  Andrei Borzenkov  <arvidjaar@gmail.com>
60527         argp: avoid extraneous translation and mem leak with empty pre doc
60528         * lib/argp-help.c (argp_doc): Never translate the empty string,
60529         when "\v" is the first or last character of the string, as that
60530         has a reserved meaning to return the header info from a po file.
60531         This also fixes a small memory leak in the !post case.
60532         The issue can be seen with this command for example:
60533         LC_MESSAGES=en_US grub2-mknetdir --help
60535 2014-11-27  Daiki Ueno  <ueno@gnu.org>
60537         uniname/uniname-tests: skip if system's libunistring is used
60538         * modules/uniname/uniname-tests (Makefile.am): Skip test if
60539         uniname/uniname module is not compiled.
60541 2014-11-27  Pádraig Brady  <P@draigBrady.com>
60543         printf: fix configure check on big endian systems
60544         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Add missing bracket.
60546 2014-11-22  Daiki Ueno  <ueno@gnu.org>
60548         pipe-filter-gi, pipe-filter-ii: port to AIX
60549         On AIX 7.1, 'select' is defined as static and cannot be referred
60550         to from inline function.
60551         * lib/pipe-filter-aux.h (nointr_select): Remove, manually expand
60552         the definition...
60553         * lib/pipe-filter-gi.c (filter_loop): ...here, and...
60554         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): ...here.
60556 2014-11-20  Paul Eggert  <eggert@cs.ucla.edu>
60558         gitlog-to-changelog: add --until
60559         * build-aux/gitlog-to-changelog: Support new --until option.
60560         Need described by Eli Zaretskii in: http://bugs.gnu.org/19113
60562 2014-11-14  Paul Eggert  <eggert@cs.ucla.edu>
60564         extern-inline: update commentary about GCC bugs
60565         * m4/extern-inline.m4: Add another GCC bug number to comments.
60567 2014-11-13  Daiki Ueno  <ueno@gnu.org>
60569         gen-uni-tables: untabify
60570         * lib/gen-uni-tables.c: Untabify.
60572 2014-11-13  Daiki Ueno  <ueno@gnu.org>
60574         gen-uni-tables: check out-of-range values added to 3-level tables
60575         * lib/gen-uni-tables.c (output_category, output_bidi_category)
60576         (output_joining_type, output_ident_category): Check out-of-range
60577         values added to 3-level tables.
60579 2014-11-13  Daiki Ueno  <ueno@gnu.org>
60581         gen-uni-tables: utilize 'assert'
60582         * lib/gen-uni-tables.c: Include <assert.h>.
60583         (output_category, output_combclass, output_decimal_digit_test)
60584         (output_decimal_digit, output_digit_test, output_digit)
60585         (output_numeric, get_mirror_value, fill_properties)
60586         (fill_property30, is_property_alphabetic)
60587         (is_property_default_ignorable_code_point)
60588         (is_property_uppercase, is_property_lowercase)
60589         (is_property_cased, is_property_case_ignorable)
60590         (is_property_changes_when_lowercased, is_property_iso_control)
60591         (is_property_math, fill_arabicshaping, output_joining_group)
60592         (fill_scripts, fill_blocks, output_lbp, fill_org_wbp)
60593         (output_wbp, fill_org_gbp, get_decomposition)
60594         (output_decomposition, fill_composition_exclusions)
60595         (debug_output_composition_tables, output_composition_tables)
60596         (redistribute_casefolding_rules, output_casing_rules): Use
60597         'assert (EXPR);' instead of 'if (!EXPR) abort ();' for better error
60598         reporting.
60600 2014-11-13  Daiki Ueno  <ueno@gnu.org>
60602         gen-uni-tables: cosmetic improvements
60603         * lib/gen-uni-tables.c: Escape newlines in the Emacs file local
60604         variables specification.
60605         (is_outdigit): Remove unused function.
60607 2014-11-12  Jeroen Roovers  <jer@gentoo.org>  (tiny change)
60609         fcntl-h-tests: port to PA-RISC GNU/Linux
60610         * tests/test-fcntl-h.c (main): Check O_SYNC is different from O_DSYNC.
60612 2014-11-10  Paul Eggert  <eggert@cs.ucla.edu>
60614         fts: port to C89
60615         Problem reported for MSVC 16 by Gisle Vanem in:
60616         http://lists.gnu.org/r/bug-gnulib/2014-11/msg00027.html
60617         * lib/fts.c (fts_build): Avoid declaration before statement.
60619 2014-11-06  Paul Eggert  <eggert@cs.ucla.edu>
60621         unistd: port to iOS
60622         Problem reported by André Klitzing in:
60623         http://lists.gnu.org/r/bug-gnulib/2014-11/msg00013.html
60624         * lib/unistd.in.h (environ): Do not include crt_externs.h on iOS.
60626 2014-11-05  Paul Eggert  <eggert@cs.ucla.edu>
60628         obstack: do not reject malloc-style obstack_chunkfun, obstack_freefun
60629         Problem reported by Alan Modra in:
60630         http://lists.gnu.org/r/bug-gnulib/2014-11/msg00007.html
60631         * lib/obstack.h (obstack_chunkfun, obstack_freefun):
60632         Always cast the function arg, reverting this part of the previous
60633         change.
60635 2014-11-04  Paul Eggert  <eggert@cs.ucla.edu>
60637         obstack: avoid potentially-nonportable function casts
60638         * lib/obstack.c (CALL_CHUNKFUN, CALL_FREEFUN):
60639         Remove, replacing with ...
60640         (call_chunkfun, call_freefun): New static functions.
60641         All uses changed.  Avoid potentially-nonportable casts.
60642         (chunkfun_type, freefun_type): Remove typedefs; no longer used.
60643         (_obstack_begin_worker): Omit last two args, since they
60644         rely on potentially-nonportable casts.  All callers changed.
60645         * lib/obstack.h (_OBSTACK_CAST): New macro.
60646         Use it everywhere the old API used a potentially-nonportable cast.
60647         The new API doesn't cast.
60648         (struct obstack): Use unions rather than requiring
60649         potentially-nonportable casts.
60650         (obstack_chunkfun, obstack_freefun): Return void.
60652 2014-11-03  Alan Modra  <amodra@gmail.com>
60654         obstack: fix macro return values
60655         * lib/obstack.h (obstack_next_free): Return void *.
60656         (obstack_1grow_fast, obstack_blank_fast): Return void.
60657         For __GNUC__ macros:
60658         (obstack_1grow, obstack_blank): Remove now unnecessary (void) 0.
60659         For !__GNUC__ macros:
60660         (obstack_make_room, obstack_grow, obstack_grow0)
60661         (obstack_ptr_grow_fast, obstack_int_grow_fast): Return void.
60663 2014-11-03  Paul Eggert  <eggert@cs.ucla.edu>
60665         obstack: do not assume system-supplied obstack is size_t safe
60666         * m4/obstack.m4: New file.
60667         * modules/obstack (Files): Add it.
60669         obstack: port to platforms that #define __alignof__
60670         * lib/obstack.c: Include <alignof.h> if !defined __alignof__,
60671         not if !_LIBC.  We don't know of any platforms that #define
60672         __alignof__, but it might be useful in tests.  Conversely,
60673         glibc assumes GCC.
60675 2014-11-03  Pádraig Brady  <P@draigBrady.com>
60677         linkat: don't unconditionally replace on GNU/Linux
60678         * m4/linkat.m4 (gl_FUNC_LINKAT): The compile check for AT_SYMLINK_FOLLOW
60679         was redundant for a few reasons.  It was present to support compiling
60680         on new systems but running on the old narrow window of Linux 2.6.1[67].
60681         It setup and cleaned up test files which weren't actually used.
60682         On non __linux__ it compile tested AT_SYMLINK_FOLLOW, but that is
60683         implicit in the following check.
60685 2014-11-03  Pádraig Brady  <P@draigBrady.com>
60687         linkat: wrap to handle symlinks on OS X 10.10
60688         * m4/linkat.m4 (gl_FUNC_LINKAT): linkat() is available on Yosemite
60689         but not usable because it doesn't support creating hardlinks
60690         to symlinks.  Therefore add a generic test for this capability
60691         and fallback to our emulation if linkat() fails with ENOTSUP.
60693 2014-11-02  Paul Eggert  <eggert@cs.ucla.edu>
60695         open, openat: document nonstandard FreeBSD, NetBSD O_NOFOLLOW errno
60696         * doc/posix-functions/open.texi (open):
60697         * doc/posix-functions/openat.texi (openat):
60698         Document that these functions do not set errno to ELOOP when
60699         a symlink is opened with O_NOFOLLOW.
60701 2014-10-31  Paul Eggert  <eggert@cs.ucla.edu>
60703         obstack: add NEWS entry for recent incompatible changes
60704         * NEWS: Describe recent changes.
60706 2014-10-30  Pádraig Brady  <P@draigBrady.com>
60708         mountlist: don't use libmount to decide on dummy/remote
60709         * lib/mountlist.c (read_file_system_list): Don't use the libmount
60710         routines to determine whether a file system is dummy or remote,
60711         as they're not currently compatible.  For example the remoteness
60712         is determined on file system type (for which the list seems incomplete),
60713         rather than simply checking for a ':' in the device name.
60714         Also libmount currently determines that 'tmpfs' is a dummy file system
60715         even though it has associated storage.
60717 2014-10-29  Paul Eggert  <eggert@cs.ucla.edu>
60719         obstack: prefer __alignof__ to alignof
60720         This is for portability to pre-4.7 GCC when compiling glibc.
60721         See Joseph S. Myers in:
60722         http://sourceware.org/ml/libc-alpha/2014-10/msg00703.html
60723         * lib/obstack.c (__alignof__) [!_LIBC && !__GNUC__]:
60724         New macro, defined by including and using <alignof.h>.
60725         (MAX): New macro.
60726         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Redefine in terms of these.
60727         Do not use enums as they are not portable to some broken compilers.
60728         * modules/obstack (Depends-on): Depend on alignof, not stdalign.
60730         obstack: prefer alignof to calculating alignments by hand
60731         * lib/obstack.c: Include <stdalign.h>.
60732         (struct fooalign): Remove.
60733         (DEFAULT_ALIGNMENT): Use alignof rather than the old offsetof hack.
60734         * modules/obstack (Depends-on): Add stdalign.
60736 2014-10-28  Paul Eggert  <eggert@cs.ucla.edu>
60738         obstack: use size_t alignments and check for overflow
60739         * lib/obstack.c, lib/obstack.h (_obstack_begin, _obstack_begin_1):
60740         * lib/obstack.c (_obstack_begin_worker, _obstack_newchunk):
60741         * lib/obstack.h (struct obstack.alignment_mask):
60742         Use _OBSTACK_SIZE_T, not int, for alignments.
60743         * lib/obstack.c (_obstack_newchunk): Fail if the size calculation
60744         overflows, e.g., when adding the alignment.
60746 2014-10-29  Alan Modra  <amodra@gmail.com>
60748         obstack: 64-bit obstack support, part 3
60749         This finally enables full 64-bit obstack support.  The glibc
60750         shared library specific code is removed from obstack.c too, and
60751         the error handling code conditionally compiled under control of
60752         another macro, _OBSTACK_NO_ERROR_HANDLER.
60753         * lib/obstack.h: Include string.h earlier.
60754         (_OBSTACK_INTERFACE_VERSION): Define.
60755         (_OBSTACK_SIZE_T, _CHUNK_SIZE_T): Define as size_t for version 2.
60756         * lib/obstack.c: Don't include shlib-compat.h.
60757         (OBSTACK_INTERFACE_VERSION): Delete.
60758         (_OBSTACK_ELIDE_CODE): Rename from ELIDE_CODE.  Define when version 1
60759         glibc code is compatible with version 2.  Don't include stdio.h for
60760         __GNU_LIBRARY.
60761         (obstack_exit_failure, print_and_abort, obstack_alloc_failed_handler):
60762         Omit when _OBSTACK_NO_ERROR_HANDLER defined.  Include stdio.h here.
60763         (_obstack_compat, _obstack, _obstack_newchunk, obstack_free): Delete
60764         glibc shared library specific source.
60766         obstack: 64-bit obstack support, part 2
60767         This gets us 4G obstack support, without changing ABI
60768         compatibility, apart from possibly introducing some
60769         signed/unsigned comparison warnings in code that uses obstack.h.
60770         a) Replace "int" size parameters, return values, and macro local vars
60771            with _OBSTACK_SIZE_T, an "unsigned int" for now.
60772         b) Make obstack.chunk_size a _CHUNK_SIZE_T, an "unsigned long" for now.
60773         c) Make all obstack macros checking available room use obstack_room.
60774            "next_free + desired > chunk_limit" may wrap the lhs for chunks
60775            allocated near the top of memory.
60776         d) Use unsigned comparisons, and macro locals to support >2G on 32-bit.
60777         * lib/obstack.h (_OBSTACK_SIZE_T): Define.  Use throughout
60778         in place of "int" size parameters, return values and local vars.
60779         (_CHUNK_SIZE_T): Define.
60780         (struct obstack): Make chunk_size a _CHUNK_SIZE_T.  Make temp
60781         union use an _OBSTACK_SIZE_T integer type.
60782         For __GNUC__ versions of the following macros...
60783         (obstack_room): Rename local var.
60784         (obstack_make_room): Use obstack_room.
60785         (obstack_grow, obstack_grow0, obstack_1grow, obstack_ptr_grow,
60786         obstack_int_grow, obstack_blank): Likewise.
60787         (obstack_finish): Use unsigned comparison when comparing aligned
60788         next_free against chunk_limit.
60789         (obstack_free): Cast OBJ to remove possible const qualifier.
60790         For !__GNUC__ versions of the following macros...
60791         (obstack_make_room): Use obstack_room.
60792         (obstack_grow, obstack_grow0, obstack_1grow, obstack_ptr_grow,
60793         obstack_int_grow, obstack_blank): Likewise.
60794         (obstack_finish): Use unsigned comparision when comparing aligned
60795         next_free against chunk_limit.
60796         (obstack_free): Use temp.p and same comparisons as __GNUC__ version.
60797         * lib/obstack.c (_obstack_begin_worker): Make "size" parameter
60798         _OBSTACK_SIZE_T.
60799         (_obstack_begin, _obstack_begin_1): Likewise.
60800         (_obstack_newchunk): Likewise for length parameter.  Use size_t locals.
60801         (_obstack_memory_used): Return and use _OBSTACK_SIZE_T local.
60803         obstack: 64-bit obstack support, part 1
60804         a) Correct calls to alloc function, to use a size_t arg.  "long" is
60805            just wrong on targets like x86_64-mingw64 where "long" is 32 bits
60806            and "size_t" 64 bits.
60807         b) Consolidate _obstack_begin and _obstack_begin1 code.
60808         * lib/obstack.h (struct obstack <chunkfun>): Correct prototype to
60809         use "size_t" rather than "long".
60810         (_obstack_begin, _obstack_begin1): Likewise.
60811         (obstack_init, obstack_begin, obstack_specify_allocation_with_arg,
60812         obstack_chunkfun): Update alloc function casts.
60813         * lib/obstack.c (CALL_CHUNKFUN): Update chunkfun cast.
60814         (chunkfun_type, freefun_type): New typdefs.
60815         (_obstack_begin_worker): Split out from ..
60816         (_obstack_begin, _obstack_begin_1): ..here.
60818         obstack: tidy part 2
60819         a) Don't be concerned about "not polluting the namespace with stddef.h
60820            symbols" in obstack.h, since gnulib string.h includes stddef.h
60821            anyway, and it seems unlikely that anyone would care.
60822         b) Don't roll our own slow memcpy in _obstack_newchunk.
60823         c) Rename obstack_free to _obstack_free.  This makes the naming
60824            consistent with other obstack functions and obviates the need for
60825            __obstack_free.  Ancient obstack.c defined both obstack_free and
60826            _obstack_free.  We continue to do that for _LIBC via an alias.
60827         d) Miscellaneous macro fixes.  The expression used to test for gcc-2.8
60828            is clever, but nowadays gcc warns on undefined macros.  You'll get
60829            an undefined macro warning if simulating an old gcc with -U__GNUC__
60830            -U__GNUC_MINOR__ -D__GNUC__=1.
60831         * lib/obstack.h: Include stddef.h unconditionally.  Formatting fixes.
60832         (PTR_INT_TYPE): Delete, replace with ptrdiff_t.
60833         (__obstack_free): Delete, update refs.
60834         (_obstack_free): Rename from obstack_free.
60835         (__extension__): Avoid undefined macro warning for __GNUC_MINOR__.
60836         (obstack_object_size, obstack_room): Parenthesise !__GNUC__ versions.
60837         * lib/obstack.c: Don't include stddef.h.
60838         (COPYING_UNIT): Delete.
60839         (_obstack_begin): Formatting fix.
60840         (_obstack_newchunk): Use memcpy to move existing object to new chunk.
60841         (_obstack_free): Rename from __obstack_free, update alias.  Move
60842         undef of obstack_free to where it is needed.
60844         obstack: tidy part 1
60845         a) Rename temp fields.  temp.tempint and temp.tempptr just looks ugly
60846            to me, and result in overlong lines after later patches.
60847         b) Move error handling code, to avoid a forward declaration and to
60848            simplify later patches in this series.
60849         * lib/obstack.h (struct obstack <temp>): Rename fields of union
60850         and update all uses.
60851         * lib/obstack.c: Include stdlib.h earlier.
60852         (obstack_exit_failure, obstack_alloc_failed_handler): Move later
60853         in file.
60854         (print_and_abort): Remove now redundant forward declaration.
60856 2014-10-24  Paul Eggert  <eggert@cs.ucla.edu>
60858         socketlib, sockets, sys_socket: Use AC_REQUIRE to pacify autoconf.
60859         Without this change, in bleeding-edge fileutils Autoconf complains
60860         that gl_SOCKETLIB etc. are AC_REQUIREd after being invoked.
60861         * modules/socketlib (configure.ac): AC_REQUIRE gl_SOCKETLIB.
60862         * modules/sockets (configure.ac): AC_REQUIRE gl_SOCKETS.
60863         * modules/sys_socket (configure.ac): AC_REQUIRE gl_HEADER_SYS_SOCKET.
60865 2014-10-24  Daiki Ueno  <ueno@gnu.org>
60867         iconv: avoid false detection of non-working iconv
60868         The INBUF arguments of iconv can be either 'const char **'
60869         or 'char **'.  If CC is g++, the difference causes a compile error
60870         and thus leads to a false detection of non-working iconv.
60871         Reported by Eli Zaretskii and Werner LEMBERG in:
60872         <https://lists.gnu.org/r/bug-gnulib/2014-10/msg00023.html>.
60873         * m4/iconv.m4 (AM_ICONV_LINK): Try all possible argument types of
60874         iconv.  Bump serial number.
60876 2014-10-23  Pádraig Brady  <P@draigBrady.com>
60878         bootstrap: print more diagnostics for missing programs
60879         * build-aux/bootstrap: only suppress stderr when checking for
60880         alternative program names.  This supports programs issuing non
60881         standard error messages.
60883 2014-10-23  Pádraig Brady  <P@draigBrady.com>
60885         bootstrap: only update the gnulib submodule
60886         * build-aux/bootstrap: Restrict the "submodule update" command
60887         to the gnulib path.
60889 2014-10-18  Paul Eggert  <eggert@cs.ucla.edu>
60891         symlinkat: port to AIX 7.1
60892         * doc/posix-functions/symlinkat.texi (symlinkat):
60893         Mention AIX porting problem.
60894         * lib/symlinkat.c: Always include errno.h.
60895         (rpl_symlinkat) [HAVE_SYMLINKAT]: New function.
60896         * lib/unistd.in.h (symlinkat): Add replacement machinery.
60897         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Check symlinkat behavior.
60898         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_SYMLINKAT.
60899         * modules/symlinkat (Depends-on): Add fstatat if REPLACE_SYMLINKAT.
60900         (configure.ac): Also compile replacement if REPLACE_SYMLINKAT.
60901         * modules/unistd (unistd.h): Substitute REPLACE_SYMLINKAT.
60903         readlinkat: port to AIX 7.1
60904         * doc/posix-functions/readlink.texi (readlink):
60905         * doc/posix-functions/readlinkat.texi (readlinkat):
60906         Mention AIX porting problem.
60907         * lib/readlinkat.c (rpl_readlinkat) [HAVE_READLINKAT]:
60908         New function.
60909         * lib/unistd.in.h (readlinkat): Add replacement machinery.
60910         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Check readlinkat signature.
60911         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_READLINKAT.
60912         * modules/readlinkat (configure.ac): Also compile replacement
60913         if REPLACE_READLINKAT.
60914         * modules/unistd (unistd.h): Substitute REPLACE_READLINKAT.
60916 2014-10-12  Karl Berry  <karl@gnu.org>
60918         * doc/posix-functions/dirname.texi: remove spurious {.
60920 2014-09-28  Ben Pfaff  <blp@cs.stanford.edu>
60922         basename, dirname: Improve documentation.
60923         * doc/posix-functions/basename.texi: Mention dirname module and
60924         base_name() function.
60925         * doc/posix-functions/dirname.texi: Mention dir_name() and
60926         mdir_name() functions.
60927         Suggested by Werner LEMBERG <wl@gnu.org>.
60929 2014-09-24  Jim Meyering  <meyering@fb.com>
60931         exclude: declare exclude_patopts static
60932         * lib/exclude.c (exclude_patopts): Declare static,
60933         to avoid triggering a -Wmissing-prototypes warning.
60934         The alternative (declaring it in the .h file) would
60935         require publicizing the private "struct patopts".
60937 2014-09-21  Werner Lemberg  <wl@gnu.org>
60939         dirname: support compilation with C++
60940         * lib/dirname.h: Add necessary C linkage declarations.
60942 2014-09-16  Paul Eggert  <eggert@cs.ucla.edu>
60944         qsort_r: include <config.h>
60945         Problem reported by Tom G. Christensen in:
60946         http://lists.gnu.org/r/bug-gnulib/2014-09/msg00071.html
60947         * lib/qsort.c [!_LIBC]: Include <config.h> first.
60949 2014-09-16  Dylan Cali  <calid1984@gmail.com>
60951         avltree-list: avoid compiler warnings (trivial)
60952         * lib/gl_anytree_list2.h: Add _GL_ATTRIBUTE_PURE to avoid
60953         -Werror=suggest-attribute=pure.
60954         * lib/gl_array_list.c: Likewise.
60955         * lib/gl_avltree_list.c (gl_avltree_list_check_invariants): Add extern
60956         declaration to avoid -Werror=missing-prototypes.  This is not added
60957         to a header as only exported for tests.  Add (void) to the
60958         check_invariants() call to indicate we're discarding the result
60959         in this context which avoids -Werror=unused-value.  Note we don't
60960         use ignore_value here to avoid a dependency as we know we'll not
60961         be adding __attribute__((warn_unused_result)) to check_invariants().
60962         Add _GL_ATTRIBUTE_CONST to avoid -Werror=suggest-attribute=const.
60964 2014-09-15  Paul Eggert  <eggert@cs.ucla.edu>
60966         qsort_r: new module, for GNU-style qsort_r
60967         * m4/qsort_r.m4: New file.  Forgot to add this earlier.
60969 2014-09-15  Werner LEMBERG  <wl@gnu.org>
60971         strerror_r-posix: support compilation with C++
60972         * lib/strerror_r.c: Add necessary C linkage declarations.
60974 2014-09-11  Johannes Zarl  <johannes.zarl@jku.at>
60976         fcntl-h: fix compilation with Intel C++ compiler (trivial)
60977         * lib/fcntl.in.h: ICC has the same issue as GCC <= 4.2.
60979 2014-09-09  Fridolin Pokorny  <fpokorny@redhat.com>
60981         mountlist: use /proc/self/mountinfo when available
60982         Use libmount to propagate device IDs provided by Linux in
60983         /proc/self/mountinfo.  This will give more accurate output when
60984         using df in chroot'ed environments as the device IDs are not
60985         determined by stat() which may be inaccurate within the chroot.
60986         * lib/mountlist.c (read_file_system_list): Use the libmount routines
60987         from util-linux to parse "/proc/self/mountinfo" or fall back to
60988         standard getmntent() processing.
60989         * m4/ls-mntd-fs.m4: Check for libmount only when 1-argument
60990         getmntent() is used, as is the case on GNU/Linux.
60992 2014-09-07  Eric Wong  <normalperson@yhbt.net>
60994         users.txt: add cmogstored
60995         cmogstored has used gnulib since the beginning in 2012 to support
60996         GNU/Linux, FreeBSD, and GNU/kFreeBSD.
60998 2014-09-05  Mathieu Anquetin  <mathieu@anquetin.eu>
61000         Trivial change.
61001         * gnulib-tool: Use same options as build-aux/bootstrap to download
61002         PO files.
61004 2014-09-05  Mathieu Anquetin  <mathieu@anquetin.eu>
61006         Trivial change.
61007         * gnulib-tool: Fallback to wget when rsync of PO files fails.
61009 2014-09-04  Eric Blake  <eblake@redhat.com>
61011         maintainer-makefile: add syntax check for useless ';;'
61012         * top/maint.mk (sc_prohibit_double_semicolon): New rule.
61014 2014-09-04  Paul Eggert  <eggert@cs.ucla.edu>
61016         pthread, pthread_sigmask, threadlib: port to Ubuntu 14.04
61017         Problem reported by Assaf Gordon in:
61018         http://lists.gnu.org/r/bug-gnulib/2014-09/msg00023.html
61019         Apparently Ubuntu is doing some fancy link-time optimization
61020         that doesn't work with -lpthread but does work with -pthread.
61021         Work around the bug by preferring -pthread to -lpthread.
61022         * m4/pthread.m4 (gl_PTHREAD_CHECK):
61023         * m4/threadlib.m4 (gl_THREADLIB_BODY): Prefer -pthread to -lpthread.
61024         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
61025         Treat -pthread like -lpthread.
61027 2014-09-04  Eric Blake  <eblake@redhat.com>
61029         error: drop spurious semicolon
61030         * lib/error.c (__error_at_line): Fix ';;'.
61032 2014-09-02  Paul Eggert  <eggert@cs.ucla.edu>
61034         gnulib-common.m4: port to GCC 4.2.1 and Sun Studio 12 C++
61035         * m4/gnulib-common.m4 (AC_C_RESTRICT):
61036         Override AC_C_RESTRICT unconditionally.
61037         Update from autoconf, incorporating:
61038         2014-09-02 autoconf: port 'restrict' to GCC 4.2.1
61039         2009-01-28 Fix AC_C_RESTRICT for Sun Studio 12 C++.
61041 2014-09-01  Paul Eggert  <eggert@cs.ucla.edu>
61043         manywarnings: add GCC 4.9 warnings
61044         Also, make it easier to maintain this in the future.
61045         * build-aux/gcc-warning.spec: Add -Wabi-tag,
61046         -Wconditionally-supported, -Wdelete-incomplete,
61047         -Winherited-variadic-ctor, -Wvirtual-move-assign, -Wzerotrip.
61048         Remove duplicates.  Use tabs uniformly, as that's what 'cut' wants.
61049         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add -Wdate-time,
61050         -Wopenmp-simd.  Use -fdiagnostics-show-option and -funit-at-a-time
61051         only for older GCC versions that need them.  Handle
61052         -Wnormalized=nfc specially, so that the 'comm' command used
61053         for maintenance doesn't get confused.
61055 2014-08-31  Paul Eggert  <eggert@cs.ucla.edu>
61057         vasnprintf: fix bugs in width computation
61058         * lib/vasnprintf.c (VASNPRINTF):
61059         Rework previous change, which introduced a bug,
61060         to avoid the warning in a different way.
61061         Avoid undefined behavior if the width arg is less than -INT_MAX.
61062         Avoid unnecessary use of HAS_WIDTH local.
61064 2014-08-31  Thien-Thi Nguyen  <ttn@gnu.org>  (tiny change)
61066         vasnprintf: Avoid signed/unsigned comparison warning.
61067         * lib/vasnprintf.c (VASNPRINTF): To calculate padding,
61068         compare end addr of generated string w/ maximum end addr.
61070 2013-08-30  Mats Erik Andersson  <gnu@gisladisker.se>  (tiny change)
61072         parse-datetime: Avoid pointer difference.
61073         * lib/parse-datetime.y (yylex): Compare pointer to end of buffer,
61074         instead of calculating difference of pointers.  This removes an
61075         annoying warning, devoid of any use.
61077 2014-08-29  Paul Eggert  <eggert@cs.ucla.edu>
61079         qsort_r: new module, for GNU-style qsort_r
61080         This works even on FreeBSD, which has an incompatible qsort_r API.
61081         * MODULES.html.sh: Add it.
61082         * doc/glibc-functions/qsort_r.texi: It's now supported.
61083         * lib/qsort.c: New file, taken from glibc with minor changes
61084         inside "#ifndef _LIBC" and with an unnecessary "#include <alloca.h>"
61085         removed.
61086         * lib/qsort_r.c: New file, compiled only on FreeBSD.
61087         * lib/stdlib.in.h (qsort_r): Declare in the usual way.
61088         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS):
61089         * modules/qsort_r, modules/qsort_r-tests: New files.
61090         * modules/stdlib (Makefile): Set up its defaults.
61091         * tests/test-qsort_r.c: New file.
61093 2014-08-08  Paul Eggert  <eggert@cs.ucla.edu>
61095         vla: new module
61096         GNU RCS can use this, mostly for documentation I expect.  See:
61097         http://lists.gnu.org/r/bug-gnulib/2014-08/msg00025.html
61098         * MODULES.html.sh: Add vla.
61099         * lib/vla.h, modules/vla: New files.
61101 2014-08-07  Daiki Ueno  <ueno@gnu.org>
61103         localename: make gl_locale_name_thread really thread-safe on Windows
61104         * lib/localename.c [WINDOWS_NATIVE && !IN_LIBINTL]: Include
61105         "glthread/lock.h".
61106         (get_lcid_lock) [WINDOWS_NATIVE]: New variable.
61107         (get_lcid) [WINDOWS_NATIVE]: Lock while looking for an LCID.
61109 2014-08-07  Paul Eggert  <eggert@cs.ucla.edu>
61111         getpass: don't assume struct termios
61112         Problem report and trivial fix by Jonas 'Sortie' Termansen in:
61113         http://lists.gnu.org/r/bug-gnulib/2014-08/msg00015.html
61114         * lib/getpass.c (getpass): Port to systems lacking struct termios.
61116         getdtablesize: fall back on sysconf (_SC_OPEN_MAX)
61117         Problem reported by Jonas 'Sortie' Termansen in:
61118         http://lists.gnu.org/r/bug-gnulib/2014-08/msg00023.html
61119         * lib/getdtablesize.c (getdtablesize) [_SC_OPEN_MAX]:
61120         Implement via sysconf for platforms that lack getdtablesize.
61122         vararrays: modernize AC_C_VARARRAYS for C11
61123         This backports a change I recently made to Autoconf.
61124         * m4/vararrays.m4 (AC_C_VARARRAYS): Define __STDC_NO_VLA__ if
61125         VLAs are not supported, as this is what C11 does.  The old macro
61126         HAVE_C_VARARRAYS is still defined if they are supported, but is
61127         now obsolescent.  Also, check for VLA bug in GCC 3.4.3.
61129 2014-08-07  Alessandro Degano  <degano@cern.ch>  (tiny change)
61131         relocatable-prog-wrapper: port gettext to OS X 10.8 + GCC 4.8.1
61132         * build-aux/install-reloc (func_create_wrapper): Also wrap
61133         strerror-override, stat, stat.
61135 2014-08-05  Paul Eggert  <eggert@cs.ucla.edu>
61137         sys_select: fix FD_ZERO problem on Solaris 10
61138         * lib/sys_select.in.h: Fix Solaris 10 bug where "#include
61139         <sys/time.h>" followed by "#include <sys/select.h>" caused FD_ZERO
61140         to expand to an expression that invoked memset without necessarily
61141         including <string.h>.  The problem was that the first include
61142         defined _SYS_TIME_H, causing the second include to short-circuit.
61143         Fix a similar problem with <sys/types.h> followed by <sys/select.h>.
61144         Also, fix what appears to be a cut-and-paste typo, by replacing
61145         _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H with
61146         _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TYPES_H.
61148         accept: document Solaris 10 type glitch
61149         * doc/posix-functions/accept.texi (accept): Mention that
61150         Solaris 10 'accept' takes void * last arg, not socklen_t *.
61152 2014-08-04  Paul Eggert  <eggert@cs.ucla.edu>
61154         extern-inline: port to FreeBSD, DragonFly
61155         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Also assume the bug
61156         is present if either __DragonFly__ or __FreeBSD__ is defined.
61157         FreeBSD problem reported by Andrey Borzenkov in:
61158         http://lists.gnu.org/r/bug-gnulib/2014-07/msg00104.html
61159         Also, worry about __APPLE__ only if __MACH__ is also defined,
61160         as this is more consistent with the rest of gnulib.
61161         (_GL_EXTERN_INLINE_STDHEADER_BUG): Rename this internal macro from
61162         _GL_EXTERN_INLINE_APPLE_BUG, since the bug is not limited to Apple.
61164 2014-08-01  Siddhesh Poyarekar  <siddhesh@redhat.com>
61166         regex: Make #if/#ifdef usage consistent for DEBUG
61167         * lib/regex_internal.c: Use "#if defined DEBUG && DEBUG" instead
61168         of the inconsistent usage of #if and #ifdef as that works with
61169         both Glibc and Gnulib's style.
61171 2014-07-31  Eric Blake  <eblake@redhat.com>
61173         openat-die: use _Noreturn markup
61174         * modules/openat-die (Depends-on): Add snippet/_Noreturn.
61175         * lib/openat-die.c (openat_save_fail, openat_restore_fail): Mark
61176         _Noreturn.
61178 2014-07-30  Eric Blake  <eblake@redhat.com>
61180         test-open: port to cygwin, which lacks Fortify
61181         * tests/test-open.h (ALWAYS_INLINE): New macro.
61182         (__always_inline): Don't abuse internal symbol on non-glibc.
61184 2014-07-19  Eli Zaretskii  <eliz@gnu.org>
61186         localename: Enforce declarations before statements.
61187         * localename.c (gl_locale_name_thread): Declare 'lcid' before the
61188         first statement.
61190 2014-07-18  Jim Meyering  <meyering@fb.com>
61192         test-userspec: don't look up numeric user names
61193         * tests/test-userspec.c: I found a system for which getpwnam("0")
61194         returned a pointer to a non-root user's entry, and that made the
61195         test fail.
61196         (T): Prefix each numeric input with "+", to inhibit lookup.
61198 2014-07-15  Eli Zaretskii  <eliz@gnu.org>
61200         localcharset, localename: MS-Windows support for non-default locales
61201         * lib/localcharset.c (locale_charset) [WINDOWS_NATIVE]: Before
61202         falling back on the default system codepage, try extracting
61203         the codepage from what 'setlocale' returns.  This allows to
61204         take into account changes of the codeset due to non-default
61205         locale set by a previous call to 'setlocale'.
61206         * lib/localename.c (LOCALE_NAME_MAX_LENGTH) [WINDOWS_NATIVE]:
61207         Define if not already defined.
61208         (enum_locales_fn, get_lcid) [WINDOWS_NATIVE]: New functions.
61209         (gl_locale_name_thread) [WINDOWS_NATIVE]: Produce the
61210         current locale by calling 'setlocale', then converting the
61211         locale name into LCID by calling 'get_lcid'.  This allows to
61212         take into account changes in the current locale from the
61213         default one, in contrast to GetThreadLocale.
61215 2014-07-14  Daiki Ueno  <ueno@gnu.org>
61217         announce-gen: avoid failure when Digest::SHA is installed
61218         When Digest::SHA is available, Digest::SHA1 is not loaded and thus
61219         Digest::SHA1->new in print_checksums fails.
61220         * build-aux/announce-gen (digest_classes): New associative array
61221         for available message digest implementations.
61222         (print_locations): Use it.
61224 2014-07-13  Pádraig Brady  <P@draigBrady.com>
61226         gettext: revert "update macros to version 0.19"
61227         This reverts commit 9b9370ca, as it currently requires that
61228         developers of any project that explicitly uses the gettext module
61229         or implicitly uses it through the utimens-tests or
61230         futimens-tests modules, use gettext >= 0.19.
61231         However there are some stability and availablity issues with
61232         that version at present.  We can reinstate this soon, when stability
61233         is addressed and packages are more readily available.
61235 2014-07-12  Jim Meyering  <meyering@fb.com>
61237         regex: don't deref NULL upon heap allocation failure
61238         * lib/regcomp.c (parse_dup_op): Handle duplicate_tree
61239         failure in one more place.
61240         To trigger the segfault, configure grep -with-included-regex,
61241         build it, and run these commands:
61242         ( ulimit -v 300000; echo a|src/grep -E a+++++++++++++++++++++ )
61243         I discovered this while replying to a private report from
61244         Jens Schleusener about excessive memory consumption by grep
61245         when using a regular expression like the one above.
61247 2014-07-11  Paul Eggert  <eggert@cs.ucla.edu>
61249         regex: fix memory leak in compiler
61250         Fix by Andreas Schwab in:
61251         https://sourceware.org/ml/libc-alpha/2014-06/msg00503.html
61252         * lib/regcomp.c (parse_reg_exp): Deallocate partially
61253         constructed tree before returning error.
61255 2014-07-10  Assaf Gordon  <assafgordon@gmail.com>
61257         announce-gen: avoid perl warnings
61258         * build-aux/announce-gen: add two minor checks to avoid
61259         "use of uninitialized value" warnings when command-line parameters are
61260         missing.
61262 2014-07-10  Assaf Gordon  <assafgordon@gmail.com>
61264         localename: avoid -Wsuggest-attribute={const,pure} warnings
61265         * lib/localename.c (string_has): Tag internal function as pure.
61266         * lib/localename.h (gl_locale_name_default): Tag extern declaration
61267         as const when appropriate.
61269 2014-07-10  Eli Zaretskii  <eliz@gnu.org>
61271         nl_langinfo: Fix last change.
61272         * lib/nl_langinfo.c (includes): Drop redundant include.
61274 2014-07-10  Siddhesh Poyarekar  <siddhesh@redhat.com>
61276         error: Fix -Wundef warnings in glibc
61277         * lib/error.c [_LIBC]: Define default macros for
61278         glibc.
61279         (print_errno_message) [defined HAVE_STRERROR_R || _LIBC]:
61280         Check _LIBC before STRERROR_R_CHAR_P.
61282         error: Sync from glibc master
61283         * lib/error.c [_LIBC]: Remove INTUSE usage.
61284         (error_tail): Remove unused macro ALLOCA_LIMIT.
61285         Fix potential buffer overflow.  Fix potential NULL dereference
61286         in strcmp.
61288 2014-07-09  Pavel Hrdina  <phrdina@redhat.com> (tiny change)
61290         nl_langinfo: fix build under mingw
61291         * lib/nl_langinfo.c (includes): Pick up <windows.h> for GetACP().
61293 2014-07-09  Andrew D Warshall  <warshall@99main.com>
61295         mountlist: do not classify a bind-mounted dir entry as "dummy"
61296         * m4/ls-mntd-fs.m4: Check for hasmntopt() on platforms with
61297         1-argument getmntent() (instead of assuming absence).
61299 2014-07-08  Eric Blake  <eblake@redhat.com>
61301         maint.mk: less syntax-check noise when SIGPIPE is ignored
61302         * top/maint.mk (_sc_header_without_use)
61303         (sc_require_config_h_first): Parse full list.
61305 2014-07-07  Eli Zaretskii  <eliz@gnu.org>
61306             Paul Eggert  <eggert@cs.ucla.edu>
61308         nl_langinfo: CODESET on MS-Windows and more items from localeconv
61309         * lib/langinfo.in.h (DECIMAL_POINT, THOUSANDS_SEP, GROUPING)
61310         (CURRENCY_SYMBOL, INT_CURR_SYMBOL, MON_DECIMAL_POINT)
61311         (MON_THOUSANDS_SEP, MON_GROUPING, POSITIVE_SIGN, NEGATIVE_SIGN)
61312         (FRAC_DIGITS, INT_FRAC_DIGITS, P_CS_PRECEDES, N_CS_PRECEDES)
61313         (P_SEP_BY_SPACE, N_SEP_BY_SPACE, P_SIGN_POSN, N_SIGN_POSN): Define.
61314         * lib/nl_langinfo.c: Include <locale.h> and <string.h> early.
61315         Include <stdio.h> if Microsoft Windows.
61316         Include <time.h> if !REPLACE_NL_LANGINFO.
61317         (ctype_codeset): New function, taken from rpl_nl_langinfo,
61318         and with improvements for Microsoft Windows.
61319         (rpl_nl_langinfo): Use it.
61320         (nl_langinfo) [!REPLACE_NL_LANGINFO]: Likewise.
61321         Compute the values of RADIXCHAR, THOUSEP, GROUPING, CRNCYSTR,
61322         INT_CURR_SYMBOL, MON_DECIMAL_POINT, MON_THOUSANDS_SEP,
61323         MON_GROUPING, POSITIVE_SIGN, NEGATIVE_SIGN, FRAC_DIGITS,
61324         INT_FRAC_DIGITS, P_CS_PRECEDES, N_CS_PRECEDES, P_SEP_BY_SPACE,
61325         N_SEP_BY_SPACE, P_SIGN_POSN, and N_SIGN_POSN from the
61326         corresponding values returned by 'localeconv'.  Compute the values
61327         of AM_STR, PM_STR, DAY_n, ABDAY_n, MON_n, and ABMON_n by calling
61328         'strftime' with a suitable struct tm value.
61330 2014-07-05  Paul Eggert  <eggert@cs.ucla.edu>
61332         Bruno Haible has stepped down as maintainer.
61333         See Karl Berry in:
61334         http://lists.gnu.org/r/bug-gnulib/2014-07/msg00004.html
61335         Daiki Ueno has volunteered to maintain libunistring; see:
61336         http://lists.gnu.org/r/bug-gnulib/2014-07/msg00005.html
61337         * modules/gen-uni-tables, modules/libunistring:
61338         * modules/libunistring-optional, modules/ucs4-utf16, modules/ucs4-utf8:
61339         * modules/unicase/base, modules/unicase/cased:
61340         * modules/unicase/empty-prefix-context:
61341         * modules/unicase/empty-suffix-context, modules/unicase/ignorable:
61342         * modules/unicase/locale-language, modules/unicase/special-casing:
61343         * modules/unicase/tocasefold, modules/unicase/tolower:
61344         * modules/unicase/totitle, modules/unicase/toupper:
61345         * modules/unicase/u16-casecmp, modules/unicase/u16-casecoll:
61346         * modules/unicase/u16-casefold, modules/unicase/u16-casemap:
61347         * modules/unicase/u16-casexfrm, modules/unicase/u16-ct-casefold:
61348         * modules/unicase/u16-ct-tolower, modules/unicase/u16-ct-totitle:
61349         * modules/unicase/u16-ct-toupper, modules/unicase/u16-is-cased:
61350         * modules/unicase/u16-is-casefolded, modules/unicase/u16-is-invariant:
61351         * modules/unicase/u16-is-lowercase, modules/unicase/u16-is-titlecase:
61352         * modules/unicase/u16-is-uppercase, modules/unicase/u16-prefix-context:
61353         * modules/unicase/u16-suffix-context, modules/unicase/u16-tolower:
61354         * modules/unicase/u16-totitle, modules/unicase/u16-toupper:
61355         * modules/unicase/u32-casecmp, modules/unicase/u32-casecoll:
61356         * modules/unicase/u32-casefold, modules/unicase/u32-casemap:
61357         * modules/unicase/u32-casexfrm, modules/unicase/u32-ct-casefold:
61358         * modules/unicase/u32-ct-tolower, modules/unicase/u32-ct-totitle:
61359         * modules/unicase/u32-ct-toupper, modules/unicase/u32-is-cased:
61360         * modules/unicase/u32-is-casefolded, modules/unicase/u32-is-invariant:
61361         * modules/unicase/u32-is-lowercase, modules/unicase/u32-is-titlecase:
61362         * modules/unicase/u32-is-uppercase, modules/unicase/u32-prefix-context:
61363         * modules/unicase/u32-suffix-context, modules/unicase/u32-tolower:
61364         * modules/unicase/u32-totitle, modules/unicase/u32-toupper:
61365         * modules/unicase/u8-casecmp, modules/unicase/u8-casecoll:
61366         * modules/unicase/u8-casefold, modules/unicase/u8-casemap:
61367         * modules/unicase/u8-casexfrm, modules/unicase/u8-ct-casefold:
61368         * modules/unicase/u8-ct-tolower, modules/unicase/u8-ct-totitle:
61369         * modules/unicase/u8-ct-toupper, modules/unicase/u8-is-cased:
61370         * modules/unicase/u8-is-casefolded, modules/unicase/u8-is-invariant:
61371         * modules/unicase/u8-is-lowercase, modules/unicase/u8-is-titlecase:
61372         * modules/unicase/u8-is-uppercase, modules/unicase/u8-prefix-context:
61373         * modules/unicase/u8-suffix-context, modules/unicase/u8-tolower:
61374         * modules/unicase/u8-totitle, modules/unicase/u8-toupper:
61375         * modules/unicase/ulc-casecmp, modules/unicase/ulc-casecoll:
61376         * modules/unicase/ulc-casexfrm, modules/unicodeio:
61377         * modules/uniconv/base, modules/uniconv/u16-conv-from-enc:
61378         * modules/uniconv/u16-conv-to-enc:
61379         * modules/uniconv/u16-strconv-from-enc:
61380         * modules/uniconv/u16-strconv-from-locale:
61381         * modules/uniconv/u16-strconv-to-enc:
61382         * modules/uniconv/u16-strconv-to-locale:
61383         * modules/uniconv/u32-conv-from-enc, modules/uniconv/u32-conv-to-enc:
61384         * modules/uniconv/u32-strconv-from-enc:
61385         * modules/uniconv/u32-strconv-from-locale:
61386         * modules/uniconv/u32-strconv-to-enc:
61387         * modules/uniconv/u32-strconv-to-locale:
61388         * modules/uniconv/u8-conv-from-enc, modules/uniconv/u8-conv-to-enc:
61389         * modules/uniconv/u8-strconv-from-enc:
61390         * modules/uniconv/u8-strconv-from-locale:
61391         * modules/uniconv/u8-strconv-to-enc:
61392         * modules/uniconv/u8-strconv-to-locale, modules/unictype/base:
61393         * modules/unictype/bidicategory-all:
61394         * modules/unictype/bidicategory-byname:
61395         * modules/unictype/bidicategory-name, modules/unictype/bidicategory-of:
61396         * modules/unictype/bidicategory-test, modules/unictype/bidiclass-all:
61397         * modules/unictype/bidiclass-byname:
61398         * modules/unictype/bidiclass-longname, modules/unictype/bidiclass-name:
61399         * modules/unictype/bidiclass-of, modules/unictype/bidiclass-test:
61400         * modules/unictype/block-all, modules/unictype/block-list:
61401         * modules/unictype/block-of, modules/unictype/block-test:
61402         * modules/unictype/category-C, modules/unictype/category-Cc:
61403         * modules/unictype/category-Cf, modules/unictype/category-Cn:
61404         * modules/unictype/category-Co, modules/unictype/category-Cs:
61405         * modules/unictype/category-L, modules/unictype/category-LC:
61406         * modules/unictype/category-Ll, modules/unictype/category-Lm:
61407         * modules/unictype/category-Lo, modules/unictype/category-Lt:
61408         * modules/unictype/category-Lu, modules/unictype/category-M:
61409         * modules/unictype/category-Mc, modules/unictype/category-Me:
61410         * modules/unictype/category-Mn, modules/unictype/category-N:
61411         * modules/unictype/category-Nd, modules/unictype/category-Nl:
61412         * modules/unictype/category-No, modules/unictype/category-P:
61413         * modules/unictype/category-Pc, modules/unictype/category-Pd:
61414         * modules/unictype/category-Pe, modules/unictype/category-Pf:
61415         * modules/unictype/category-Pi, modules/unictype/category-Po:
61416         * modules/unictype/category-Ps, modules/unictype/category-S:
61417         * modules/unictype/category-Sc, modules/unictype/category-Sk:
61418         * modules/unictype/category-Sm, modules/unictype/category-So:
61419         * modules/unictype/category-Z, modules/unictype/category-Zl:
61420         * modules/unictype/category-Zp, modules/unictype/category-Zs:
61421         * modules/unictype/category-all, modules/unictype/category-and:
61422         * modules/unictype/category-and-not, modules/unictype/category-byname:
61423         * modules/unictype/category-longname, modules/unictype/category-name:
61424         * modules/unictype/category-none, modules/unictype/category-of:
61425         * modules/unictype/category-or, modules/unictype/category-test:
61426         * modules/unictype/category-test-withtable:
61427         * modules/unictype/combining-class:
61428         * modules/unictype/combining-class-all:
61429         * modules/unictype/combining-class-byname:
61430         * modules/unictype/combining-class-longname:
61431         * modules/unictype/combining-class-name, modules/unictype/ctype-alnum:
61432         * modules/unictype/ctype-alpha, modules/unictype/ctype-blank:
61433         * modules/unictype/ctype-cntrl, modules/unictype/ctype-digit:
61434         * modules/unictype/ctype-graph, modules/unictype/ctype-lower:
61435         * modules/unictype/ctype-print, modules/unictype/ctype-punct:
61436         * modules/unictype/ctype-space, modules/unictype/ctype-upper:
61437         * modules/unictype/ctype-xdigit, modules/unictype/decimal-digit:
61438         * modules/unictype/digit, modules/unictype/joininggroup-all:
61439         * modules/unictype/joininggroup-byname:
61440         * modules/unictype/joininggroup-name, modules/unictype/joininggroup-of:
61441         * modules/unictype/joiningtype-all:
61442         * modules/unictype/joiningtype-byname:
61443         * modules/unictype/joiningtype-longname:
61444         * modules/unictype/joiningtype-name, modules/unictype/joiningtype-of:
61445         * modules/unictype/mirror, modules/unictype/numeric:
61446         * modules/unictype/property-all, modules/unictype/property-alphabetic:
61447         * modules/unictype/property-ascii-hex-digit:
61448         * modules/unictype/property-bidi-arabic-digit:
61449         * modules/unictype/property-bidi-arabic-right-to-left:
61450         * modules/unictype/property-bidi-block-separator:
61451         * modules/unictype/property-bidi-boundary-neutral:
61452         * modules/unictype/property-bidi-common-separator:
61453         * modules/unictype/property-bidi-control:
61454         * modules/unictype/property-bidi-embedding-or-override:
61455         * modules/unictype/property-bidi-eur-num-separator:
61456         * modules/unictype/property-bidi-eur-num-terminator:
61457         * modules/unictype/property-bidi-european-digit:
61458         * modules/unictype/property-bidi-hebrew-right-to-left:
61459         * modules/unictype/property-bidi-left-to-right:
61460         * modules/unictype/property-bidi-non-spacing-mark:
61461         * modules/unictype/property-bidi-other-neutral:
61462         * modules/unictype/property-bidi-pdf:
61463         * modules/unictype/property-bidi-segment-separator:
61464         * modules/unictype/property-bidi-whitespace:
61465         * modules/unictype/property-byname:
61466         * modules/unictype/property-case-ignorable:
61467         * modules/unictype/property-cased:
61468         * modules/unictype/property-changes-when-casefolded:
61469         * modules/unictype/property-changes-when-casemapped:
61470         * modules/unictype/property-changes-when-lowercased:
61471         * modules/unictype/property-changes-when-titlecased:
61472         * modules/unictype/property-changes-when-uppercased:
61473         * modules/unictype/property-combining:
61474         * modules/unictype/property-composite:
61475         * modules/unictype/property-currency-symbol:
61476         * modules/unictype/property-dash:
61477         * modules/unictype/property-decimal-digit:
61478         * modules/unictype/property-default-ignorable-code-point:
61479         * modules/unictype/property-deprecated:
61480         * modules/unictype/property-diacritic:
61481         * modules/unictype/property-extender:
61482         * modules/unictype/property-format-control:
61483         * modules/unictype/property-grapheme-base:
61484         * modules/unictype/property-grapheme-extend:
61485         * modules/unictype/property-grapheme-link:
61486         * modules/unictype/property-hex-digit:
61487         * modules/unictype/property-hyphen:
61488         * modules/unictype/property-id-continue:
61489         * modules/unictype/property-id-start:
61490         * modules/unictype/property-ideographic:
61491         * modules/unictype/property-ids-binary-operator:
61492         * modules/unictype/property-ids-trinary-operator:
61493         * modules/unictype/property-ignorable-control:
61494         * modules/unictype/property-iso-control:
61495         * modules/unictype/property-join-control:
61496         * modules/unictype/property-left-of-pair:
61497         * modules/unictype/property-line-separator:
61498         * modules/unictype/property-logical-order-exception:
61499         * modules/unictype/property-lowercase, modules/unictype/property-math:
61500         * modules/unictype/property-non-break:
61501         * modules/unictype/property-not-a-character:
61502         * modules/unictype/property-numeric:
61503         * modules/unictype/property-other-alphabetic:
61504         * modules/unictype/property-other-default-ignorable-code-point:
61505         * modules/unictype/property-other-grapheme-extend:
61506         * modules/unictype/property-other-id-continue:
61507         * modules/unictype/property-other-id-start:
61508         * modules/unictype/property-other-lowercase:
61509         * modules/unictype/property-other-math:
61510         * modules/unictype/property-other-uppercase:
61511         * modules/unictype/property-paired-punctuation:
61512         * modules/unictype/property-paragraph-separator:
61513         * modules/unictype/property-pattern-syntax:
61514         * modules/unictype/property-pattern-white-space:
61515         * modules/unictype/property-private-use:
61516         * modules/unictype/property-punctuation:
61517         * modules/unictype/property-quotation-mark:
61518         * modules/unictype/property-radical:
61519         * modules/unictype/property-sentence-terminal:
61520         * modules/unictype/property-soft-dotted:
61521         * modules/unictype/property-space:
61522         * modules/unictype/property-terminal-punctuation:
61523         * modules/unictype/property-test, modules/unictype/property-titlecase:
61524         * modules/unictype/property-unassigned-code-value:
61525         * modules/unictype/property-unified-ideograph:
61526         * modules/unictype/property-uppercase:
61527         * modules/unictype/property-variation-selector:
61528         * modules/unictype/property-white-space:
61529         * modules/unictype/property-xid-continue:
61530         * modules/unictype/property-xid-start:
61531         * modules/unictype/property-zero-width, modules/unictype/scripts:
61532         * modules/unictype/scripts-all, modules/unictype/syntax-c-ident:
61533         * modules/unictype/syntax-c-whitespace:
61534         * modules/unictype/syntax-java-ident:
61535         * modules/unictype/syntax-java-whitespace, modules/unigbrk/base:
61536         * modules/unigbrk/u16-grapheme-breaks:
61537         * modules/unigbrk/u16-grapheme-next, modules/unigbrk/u16-grapheme-prev:
61538         * modules/unigbrk/u32-grapheme-breaks:
61539         * modules/unigbrk/u32-grapheme-next, modules/unigbrk/u32-grapheme-prev:
61540         * modules/unigbrk/u8-grapheme-breaks, modules/unigbrk/u8-grapheme-next:
61541         * modules/unigbrk/u8-grapheme-prev, modules/unigbrk/uc-gbrk-prop:
61542         * modules/unigbrk/uc-is-grapheme-break:
61543         * modules/unigbrk/ulc-grapheme-breaks, modules/unilbrk/base:
61544         * modules/unilbrk/tables, modules/unilbrk/u16-possible-linebreaks:
61545         * modules/unilbrk/u16-width-linebreaks:
61546         * modules/unilbrk/u32-possible-linebreaks:
61547         * modules/unilbrk/u32-width-linebreaks:
61548         * modules/unilbrk/u8-possible-linebreaks:
61549         * modules/unilbrk/u8-width-linebreaks, modules/unilbrk/ulc-common:
61550         * modules/unilbrk/ulc-possible-linebreaks:
61551         * modules/unilbrk/ulc-width-linebreaks, modules/uniname/base:
61552         * modules/uniname/uniname, modules/uninorm/base:
61553         * modules/uninorm/canonical-decomposition:
61554         * modules/uninorm/compat-decomposition, modules/uninorm/composition:
61555         * modules/uninorm/decompose-internal, modules/uninorm/decomposing-form:
61556         * modules/uninorm/decomposition, modules/uninorm/decomposition-table:
61557         * modules/uninorm/filter, modules/uninorm/nfc, modules/uninorm/nfd:
61558         * modules/uninorm/nfkc, modules/uninorm/nfkd:
61559         * modules/uninorm/u16-normalize, modules/uninorm/u16-normcmp:
61560         * modules/uninorm/u16-normcoll, modules/uninorm/u16-normxfrm:
61561         * modules/uninorm/u32-normalize, modules/uninorm/u32-normcmp:
61562         * modules/uninorm/u32-normcoll, modules/uninorm/u32-normxfrm:
61563         * modules/uninorm/u8-normalize, modules/uninorm/u8-normcmp:
61564         * modules/uninorm/u8-normcoll, modules/uninorm/u8-normxfrm:
61565         * modules/unistdio/base, modules/unistdio/u-printf-args:
61566         * modules/unistdio/u16-asnprintf, modules/unistdio/u16-asprintf:
61567         * modules/unistdio/u16-printf-parse, modules/unistdio/u16-snprintf:
61568         * modules/unistdio/u16-sprintf, modules/unistdio/u16-u16-asnprintf:
61569         * modules/unistdio/u16-u16-asprintf, modules/unistdio/u16-u16-snprintf:
61570         * modules/unistdio/u16-u16-sprintf:
61571         * modules/unistdio/u16-u16-vasnprintf:
61572         * modules/unistdio/u16-u16-vasprintf:
61573         * modules/unistdio/u16-u16-vsnprintf:
61574         * modules/unistdio/u16-u16-vsprintf, modules/unistdio/u16-vasnprintf:
61575         * modules/unistdio/u16-vasprintf, modules/unistdio/u16-vsnprintf:
61576         * modules/unistdio/u16-vsprintf, modules/unistdio/u32-asnprintf:
61577         * modules/unistdio/u32-asprintf, modules/unistdio/u32-printf-parse:
61578         * modules/unistdio/u32-snprintf, modules/unistdio/u32-sprintf:
61579         * modules/unistdio/u32-u32-asnprintf:
61580         * modules/unistdio/u32-u32-asprintf, modules/unistdio/u32-u32-snprintf:
61581         * modules/unistdio/u32-u32-sprintf:
61582         * modules/unistdio/u32-u32-vasnprintf:
61583         * modules/unistdio/u32-u32-vasprintf:
61584         * modules/unistdio/u32-u32-vsnprintf:
61585         * modules/unistdio/u32-u32-vsprintf, modules/unistdio/u32-vasnprintf:
61586         * modules/unistdio/u32-vasprintf, modules/unistdio/u32-vsnprintf:
61587         * modules/unistdio/u32-vsprintf, modules/unistdio/u8-asnprintf:
61588         * modules/unistdio/u8-asprintf, modules/unistdio/u8-printf-parse:
61589         * modules/unistdio/u8-snprintf, modules/unistdio/u8-sprintf:
61590         * modules/unistdio/u8-u8-asnprintf, modules/unistdio/u8-u8-asprintf:
61591         * modules/unistdio/u8-u8-snprintf, modules/unistdio/u8-u8-sprintf:
61592         * modules/unistdio/u8-u8-vasnprintf, modules/unistdio/u8-u8-vasprintf:
61593         * modules/unistdio/u8-u8-vsnprintf, modules/unistdio/u8-u8-vsprintf:
61594         * modules/unistdio/u8-vasnprintf, modules/unistdio/u8-vasprintf:
61595         * modules/unistdio/u8-vsnprintf, modules/unistdio/u8-vsprintf:
61596         * modules/unistdio/ulc-asnprintf, modules/unistdio/ulc-asprintf:
61597         * modules/unistdio/ulc-fprintf, modules/unistdio/ulc-printf-parse:
61598         * modules/unistdio/ulc-snprintf, modules/unistdio/ulc-sprintf:
61599         * modules/unistdio/ulc-vasnprintf, modules/unistdio/ulc-vasprintf:
61600         * modules/unistdio/ulc-vfprintf, modules/unistdio/ulc-vsnprintf:
61601         * modules/unistdio/ulc-vsprintf, modules/unistr/base:
61602         * modules/unistr/u16-check, modules/unistr/u16-chr:
61603         * modules/unistr/u16-cmp, modules/unistr/u16-cmp2:
61604         * modules/unistr/u16-cpy, modules/unistr/u16-cpy-alloc:
61605         * modules/unistr/u16-endswith, modules/unistr/u16-mblen:
61606         * modules/unistr/u16-mbsnlen, modules/unistr/u16-mbtouc:
61607         * modules/unistr/u16-mbtouc-unsafe, modules/unistr/u16-mbtoucr:
61608         * modules/unistr/u16-move, modules/unistr/u16-next:
61609         * modules/unistr/u16-prev, modules/unistr/u16-set:
61610         * modules/unistr/u16-startswith, modules/unistr/u16-stpcpy:
61611         * modules/unistr/u16-stpncpy, modules/unistr/u16-strcat:
61612         * modules/unistr/u16-strchr, modules/unistr/u16-strcmp:
61613         * modules/unistr/u16-strcoll, modules/unistr/u16-strcpy:
61614         * modules/unistr/u16-strcspn, modules/unistr/u16-strdup:
61615         * modules/unistr/u16-strlen, modules/unistr/u16-strmblen:
61616         * modules/unistr/u16-strmbtouc, modules/unistr/u16-strncat:
61617         * modules/unistr/u16-strncmp, modules/unistr/u16-strncpy:
61618         * modules/unistr/u16-strnlen, modules/unistr/u16-strpbrk:
61619         * modules/unistr/u16-strrchr, modules/unistr/u16-strspn:
61620         * modules/unistr/u16-strstr, modules/unistr/u16-strtok:
61621         * modules/unistr/u16-to-u32, modules/unistr/u16-to-u8:
61622         * modules/unistr/u16-uctomb, modules/unistr/u32-check:
61623         * modules/unistr/u32-chr, modules/unistr/u32-cmp:
61624         * modules/unistr/u32-cmp2, modules/unistr/u32-cpy:
61625         * modules/unistr/u32-cpy-alloc, modules/unistr/u32-endswith:
61626         * modules/unistr/u32-mblen, modules/unistr/u32-mbsnlen:
61627         * modules/unistr/u32-mbtouc, modules/unistr/u32-mbtouc-unsafe:
61628         * modules/unistr/u32-mbtoucr, modules/unistr/u32-move:
61629         * modules/unistr/u32-next, modules/unistr/u32-prev:
61630         * modules/unistr/u32-set, modules/unistr/u32-startswith:
61631         * modules/unistr/u32-stpcpy, modules/unistr/u32-stpncpy:
61632         * modules/unistr/u32-strcat, modules/unistr/u32-strchr:
61633         * modules/unistr/u32-strcmp, modules/unistr/u32-strcoll:
61634         * modules/unistr/u32-strcpy, modules/unistr/u32-strcspn:
61635         * modules/unistr/u32-strdup, modules/unistr/u32-strlen:
61636         * modules/unistr/u32-strmblen, modules/unistr/u32-strmbtouc:
61637         * modules/unistr/u32-strncat, modules/unistr/u32-strncmp:
61638         * modules/unistr/u32-strncpy, modules/unistr/u32-strnlen:
61639         * modules/unistr/u32-strpbrk, modules/unistr/u32-strrchr:
61640         * modules/unistr/u32-strspn, modules/unistr/u32-strstr:
61641         * modules/unistr/u32-strtok, modules/unistr/u32-to-u16:
61642         * modules/unistr/u32-to-u8, modules/unistr/u32-uctomb:
61643         * modules/unistr/u8-check, modules/unistr/u8-chr:
61644         * modules/unistr/u8-cmp, modules/unistr/u8-cmp2, modules/unistr/u8-cpy:
61645         * modules/unistr/u8-cpy-alloc, modules/unistr/u8-endswith:
61646         * modules/unistr/u8-mblen, modules/unistr/u8-mbsnlen:
61647         * modules/unistr/u8-mbtouc, modules/unistr/u8-mbtouc-unsafe:
61648         * modules/unistr/u8-mbtoucr, modules/unistr/u8-move:
61649         * modules/unistr/u8-next, modules/unistr/u8-prev:
61650         * modules/unistr/u8-set, modules/unistr/u8-startswith:
61651         * modules/unistr/u8-stpcpy, modules/unistr/u8-stpncpy:
61652         * modules/unistr/u8-strcat, modules/unistr/u8-strchr:
61653         * modules/unistr/u8-strcmp, modules/unistr/u8-strcoll:
61654         * modules/unistr/u8-strcpy, modules/unistr/u8-strcspn:
61655         * modules/unistr/u8-strdup, modules/unistr/u8-strlen:
61656         * modules/unistr/u8-strmblen, modules/unistr/u8-strmbtouc:
61657         * modules/unistr/u8-strncat, modules/unistr/u8-strncmp:
61658         * modules/unistr/u8-strncpy, modules/unistr/u8-strnlen:
61659         * modules/unistr/u8-strpbrk, modules/unistr/u8-strrchr:
61660         * modules/unistr/u8-strspn, modules/unistr/u8-strstr:
61661         * modules/unistr/u8-strtok, modules/unistr/u8-to-u16:
61662         * modules/unistr/u8-to-u32, modules/unistr/u8-uctomb, modules/unitypes:
61663         * modules/uniwbrk/base, modules/uniwbrk/table:
61664         * modules/uniwbrk/u16-wordbreaks, modules/uniwbrk/u32-wordbreaks:
61665         * modules/uniwbrk/u8-wordbreaks, modules/uniwbrk/ulc-wordbreaks:
61666         * modules/uniwbrk/wordbreak-property, modules/uniwidth/base:
61667         * modules/uniwidth/u16-strwidth, modules/uniwidth/u16-width:
61668         * modules/uniwidth/u32-strwidth, modules/uniwidth/u32-width:
61669         * modules/uniwidth/u8-strwidth, modules/uniwidth/u8-width:
61670         * modules/uniwidth/width, modules/utf16-ucs4:
61671         * modules/utf16-ucs4-unsafe, modules/utf8-ucs4:
61672         * modules/utf8-ucs4-unsafe:
61673         Change maintainer from Bruno Haible to Daiki Ueno.
61674         This is my guess at the libunistring modules; please feel free
61675         to fix if I guessed incorrectly.
61676         * modules/accept4, modules/acl, modules/acos, modules/acosf:
61677         * modules/alignof, modules/amemxfrm, modules/ansi-c++-opt:
61678         * modules/areadlink, modules/array-list, modules/array-mergesort:
61679         * modules/array-oset, modules/asin, modules/asinf, modules/astrxfrm:
61680         * modules/atan, modules/atan2, modules/atan2f, modules/atanf:
61681         * modules/avltree-list, modules/avltree-oset, modules/avltreehash-list:
61682         * modules/binary-io, modules/bison-i18n, modules/btowc:
61683         * modules/c-ctype, modules/c-strcase, modules/c-strcaseeq:
61684         * modules/c-strcasestr, modules/c-strstr, modules/calloc-posix:
61685         * modules/canonicalize-lgpl, modules/careadlinkat, modules/carray-list:
61686         * modules/cbrt, modules/cbrt-ieee, modules/cbrtf, modules/cbrtf-ieee:
61687         * modules/cbrtl, modules/cbrtl-ieee, modules/ceil, modules/ceil-ieee:
61688         * modules/ceilf, modules/ceilf-ieee, modules/ceill, modules/ceill-ieee:
61689         * modules/chdir, modules/classpath, modules/clean-temp, modules/close:
61690         * modules/closedir, modules/concat-filename, modules/copy-file:
61691         * modules/copysign, modules/copysignf, modules/copysignl, modules/cos:
61692         * modules/cosf, modules/cosh, modules/coshf, modules/csharpcomp:
61693         * modules/csharpcomp-script, modules/csharpexec:
61694         * modules/csharpexec-script, modules/ctype, modules/diffseq:
61695         * modules/dprintf, modules/dprintf-posix, modules/dup:
61696         * modules/dup2-obsolete, modules/dup3, modules/duplocale:
61697         * modules/eealloc, modules/environ, modules/erf, modules/erfc:
61698         * modules/errno, modules/execute, modules/exp, modules/exp-ieee:
61699         * modules/exp2, modules/exp2-ieee, modules/exp2f, modules/exp2f-ieee:
61700         * modules/exp2l, modules/exp2l-ieee, modules/expf, modules/expf-ieee:
61701         * modules/expl, modules/expl-ieee, modules/expm1, modules/expm1-ieee:
61702         * modules/expm1f, modules/expm1f-ieee, modules/expm1l:
61703         * modules/expm1l-ieee, modules/fabs, modules/fabs-ieee, modules/fabsf:
61704         * modules/fabsf-ieee, modules/fabsl, modules/fabsl-ieee:
61705         * modules/fatal-signal, modules/fbufmode, modules/fchdir:
61706         * modules/fclose, modules/fd-hook, modules/fdopen, modules/filename:
61707         * modules/findprog, modules/findprog-lgpl, modules/floor:
61708         * modules/floor-ieee, modules/floorf, modules/floorf-ieee:
61709         * modules/floorl, modules/floorl-ieee, modules/fma, modules/fma-ieee:
61710         * modules/fmaf, modules/fmaf-ieee, modules/fmal, modules/fmal-ieee:
61711         * modules/fmod, modules/fmod-ieee, modules/fmodf, modules/fmodf-ieee:
61712         * modules/fmodl, modules/fmodl-ieee, modules/fopen, modules/fpieee:
61713         * modules/fprintf-posix, modules/fpucw, modules/fpurge:
61714         * modules/freadable, modules/freadahead, modules/freadptr:
61715         * modules/freadseek, modules/freopen, modules/frexp:
61716         * modules/frexp-ieee, modules/frexp-nolibm, modules/frexpf:
61717         * modules/frexpf-ieee, modules/frexpl, modules/frexpl-ieee:
61718         * modules/frexpl-nolibm, modules/fseek, modules/fseeko:
61719         * modules/fseterr, modules/fstat, modules/fstrcmp, modules/ftell:
61720         * modules/ftello, modules/full-read, modules/full-write:
61721         * modules/fwritable, modules/fwriteerror, modules/gcd:
61722         * modules/get-rusage-as, modules/get-rusage-data:
61723         * modules/getdtablesize, modules/getrusage, modules/gettext:
61724         * modules/gettext-h, modules/git-merge-changelog, modules/gperf:
61725         * modules/grantpt, modules/havelib, modules/host-cpu-c-abi:
61726         * modules/hostent, modules/hypot, modules/hypot-ieee, modules/hypotf:
61727         * modules/hypotf-ieee, modules/hypotl, modules/hypotl-ieee:
61728         * modules/iconv, modules/iconv-h, modules/iconv_open:
61729         * modules/iconv_open-utf, modules/idpriv-drop, modules/idpriv-droptemp:
61730         * modules/ilogb, modules/ilogbf, modules/ilogbl, modules/imaxabs:
61731         * modules/imaxdiv, modules/integer_length, modules/integer_length_l:
61732         * modules/integer_length_ll, modules/ioctl, modules/isatty:
61733         * modules/isblank, modules/isnand, modules/isnand-nolibm:
61734         * modules/isnanf, modules/isnanf-nolibm, modules/isnanl:
61735         * modules/isnanl-nolibm, modules/iswblank, modules/iswctype:
61736         * modules/j0, modules/j1, modules/javacomp, modules/javacomp-script:
61737         * modules/javaexec, modules/javaexec-script, modules/javaversion:
61738         * modules/jn, modules/langinfo, modules/ldd, modules/ldexp:
61739         * modules/ldexp-ieee, modules/ldexpf, modules/ldexpf-ieee:
61740         * modules/ldexpl, modules/ldexpl-ieee, modules/lgamma:
61741         * modules/lib-symbol-visibility, modules/libsigsegv:
61742         * modules/linked-list, modules/linkedhash-list, modules/list:
61743         * modules/localcharset, modules/locale, modules/localeconv:
61744         * modules/localename, modules/lock, modules/log, modules/log-ieee:
61745         * modules/log10, modules/log10-ieee, modules/log10f:
61746         * modules/log10f-ieee, modules/log10l, modules/log10l-ieee:
61747         * modules/log1p, modules/log1p-ieee, modules/log1pf:
61748         * modules/log1pf-ieee, modules/log1pl, modules/log1pl-ieee:
61749         * modules/log2, modules/log2-ieee, modules/log2f, modules/log2f-ieee:
61750         * modules/log2l, modules/log2l-ieee, modules/logb, modules/logb-ieee:
61751         * modules/logbf, modules/logbf-ieee, modules/logbl, modules/logbl-ieee:
61752         * modules/logf, modules/logf-ieee, modules/login_tty:
61753         * modules/logl-ieee, modules/malloc-posix, modules/malloca:
61754         * modules/mbchar, modules/mbfile, modules/mbiter, modules/mbmemcasecmp:
61755         * modules/mbmemcasecoll, modules/mbrlen, modules/mbrtowc:
61756         * modules/mbscasecmp, modules/mbscasestr, modules/mbschr:
61757         * modules/mbscspn, modules/mbsinit, modules/mbslen:
61758         * modules/mbsncasecmp, modules/mbsnlen, modules/mbsnrtowcs:
61759         * modules/mbspbrk, modules/mbspcasecmp, modules/mbsrchr:
61760         * modules/mbsrtowcs, modules/mbssep, modules/mbsspn, modules/mbsstr:
61761         * modules/mbstok_r, modules/mbswidth, modules/mbtowc, modules/mbuiter:
61762         * modules/memchr-obsolete, modules/memcmp2, modules/minmax:
61763         * modules/mkdtemp, modules/mkostemp, modules/mktime-internal:
61764         * modules/modf, modules/modf-ieee, modules/modff, modules/modff-ieee:
61765         * modules/modfl, modules/modfl-ieee, modules/msvc-inval:
61766         * modules/msvc-nothrow, modules/multiarch, modules/nextafter:
61767         * modules/nl_langinfo, modules/no-c++, modules/nocrash:
61768         * modules/nonblocking, modules/open, modules/opendir, modules/openmp:
61769         * modules/oset, modules/pclose, modules/pipe, modules/pipe-filter-gi:
61770         * modules/pipe-filter-ii, modules/pipe2, modules/poll-h:
61771         * modules/posix_spawn, modules/posix_spawn-internal:
61772         * modules/posix_spawn_file_actions_addclose:
61773         * modules/posix_spawn_file_actions_adddup2:
61774         * modules/posix_spawn_file_actions_addopen:
61775         * modules/posix_spawn_file_actions_destroy:
61776         * modules/posix_spawn_file_actions_init:
61777         * modules/posix_spawnattr_destroy, modules/posix_spawnattr_getflags:
61778         * modules/posix_spawnattr_getpgroup:
61779         * modules/posix_spawnattr_getschedparam:
61780         * modules/posix_spawnattr_getschedpolicy:
61781         * modules/posix_spawnattr_getsigdefault:
61782         * modules/posix_spawnattr_getsigmask, modules/posix_spawnattr_init:
61783         * modules/posix_spawnattr_setflags, modules/posix_spawnattr_setpgroup:
61784         * modules/posix_spawnattr_setschedparam:
61785         * modules/posix_spawnattr_setschedpolicy:
61786         * modules/posix_spawnattr_setsigdefault:
61787         * modules/posix_spawnattr_setsigmask, modules/posix_spawnp:
61788         * modules/pow, modules/powf, modules/printf-frexp:
61789         * modules/printf-frexpl, modules/printf-posix, modules/printf-safe:
61790         * modules/progname, modules/propername, modules/pselect:
61791         * modules/pthread_sigmask, modules/ptsname, modules/ptsname_r:
61792         * modules/qacl, modules/quotearg-simple, modules/raise, modules/random:
61793         * modules/rbtree-list, modules/rbtree-oset, modules/rbtreehash-list:
61794         * modules/read, modules/readdir, modules/readlink:
61795         * modules/realloc-posix, modules/regex-quote, modules/relocatable-lib:
61796         * modules/relocatable-lib-lgpl, modules/relocatable-perl:
61797         * modules/relocatable-prog, modules/relocatable-prog-wrapper:
61798         * modules/relocatable-script, modules/remainder:
61799         * modules/remainder-ieee, modules/remainderf, modules/remainderf-ieee:
61800         * modules/remainderl, modules/remainderl-ieee, modules/rewinddir:
61801         * modules/rint, modules/rint-ieee, modules/rintf, modules/rintf-ieee:
61802         * modules/rintl, modules/rintl-ieee, modules/round-ieee:
61803         * modules/roundf-ieee, modules/roundl-ieee, modules/safe-read:
61804         * modules/safe-write, modules/sched, modules/servent, modules/setenv:
61805         * modules/setlocale, modules/sh-quote, modules/shutdown:
61806         * modules/signal, modules/signbit, modules/sigpipe:
61807         * modules/sigpipe-die, modules/sigprocmask, modules/sin, modules/sinf:
61808         * modules/sinh, modules/sinhf, modules/size_max, modules/sleep:
61809         * modules/snippet/arg-nonnull, modules/snippet/c++defs:
61810         * modules/snippet/link-warning, modules/snippet/unused-parameter:
61811         * modules/snprintf, modules/snprintf-posix, modules/spawn:
61812         * modules/spawn-pipe, modules/sprintf-posix, modules/sqrt:
61813         * modules/sqrt-ieee, modules/sqrtf, modules/sqrtf-ieee:
61814         * modules/sqrtl-ieee, modules/stdalign, modules/stdarg:
61815         * modules/stdbool, modules/stpcpy, modules/stpncpy, modules/strcase:
61816         * modules/strcasestr, modules/strcasestr-simple, modules/strcspn:
61817         * modules/streq, modules/strerror_r-posix, modules/striconv:
61818         * modules/striconveh, modules/striconveha, modules/strncat:
61819         * modules/strnlen1, modules/strpbrk, modules/strtod-obsolete:
61820         * modules/sublist, modules/sys_resource, modules/sys_utsname:
61821         * modules/sys_wait, modules/system-posix, modules/system-quote:
61822         * modules/tan, modules/tanf, modules/tanh, modules/tanhf:
61823         * modules/tcgetsid, modules/termios, modules/threadlib, modules/tls:
61824         * modules/tmpdir, modules/towctrans, modules/trunc, modules/trunc-ieee:
61825         * modules/truncf, modules/truncf-ieee, modules/truncl:
61826         * modules/truncl-ieee, modules/ttyname_r, modules/uname:
61827         * modules/unlockpt, modules/unsetenv, modules/vasnprintf:
61828         * modules/vasnprintf-posix, modules/vasprintf, modules/vasprintf-posix:
61829         * modules/vdprintf, modules/vdprintf-posix, modules/vfprintf-posix:
61830         * modules/vfscanf, modules/vma-iter, modules/vprintf-posix:
61831         * modules/vscanf, modules/vsnprintf-posix, modules/vsprintf-posix:
61832         * modules/wait-process, modules/waitpid, modules/wcpcpy:
61833         * modules/wcpncpy, modules/wcrtomb, modules/wcscasecmp, modules/wcscat:
61834         * modules/wcschr, modules/wcscmp, modules/wcscoll, modules/wcscpy:
61835         * modules/wcscspn, modules/wcsdup, modules/wcslen, modules/wcsncasecmp:
61836         * modules/wcsncat, modules/wcsncmp, modules/wcsncpy, modules/wcsnlen:
61837         * modules/wcsnrtombs, modules/wcspbrk, modules/wcsrchr:
61838         * modules/wcsrtombs, modules/wcsspn, modules/wcsstr, modules/wcstok:
61839         * modules/wcswidth, modules/wcsxfrm, modules/wctob, modules/wctomb:
61840         * modules/wctrans, modules/wctype, modules/wcwidth, modules/wmemchr:
61841         * modules/wmemcmp, modules/wmemcpy, modules/wmemmove, modules/wmemset:
61842         * modules/write, modules/xconcat-filename, modules/xlist:
61843         * modules/xmalloca, modules/xoset, modules/xprintf-posix:
61844         * modules/xreadlink, modules/xsetenv, modules/xsize, modules/xstriconv:
61845         * modules/xstriconveh, modules/xsublist, modules/xvasprintf-posix:
61846         * modules/y0, modules/y1, modules/yn:
61847         Remove Bruno Haible as maintainer; if he's the sole maintainer,
61848         change the maintainer to 'all'.  Let's hope someone volunteers.
61850 2014-06-27  Paul Eggert  <eggert@cs.ucla.edu>
61852         mktime: merge #if/#ifdef usage from glibc
61853         * lib/mktime.c: Use "#if defined DEBUG && DEBUG", not "#if DEBUG",
61854         as that works with both Glibc's and Gnulib's style.
61855         See thread starting at Siddhesh Poyarekar's bug report at:
61856         http://lists.gnu.org/r/bug-gnulib/2014-06/msg00102.html
61858 2014-06-20  Alfred M. Szmidt  <ams@gnu.org>
61860         git-version-gen: improve option descriptions
61861         * build-aux/git-version-gen: Mention that --prefix and --fallback
61862         have a mandatory argument.
61864 2014-06-19  Paul Eggert  <eggert@penguin.cs.ucla.edu>
61866         regex: fix memory leak in compiler
61867         Fix by Andreas Schwab in:
61868         https://sourceware.org/ml/libc-alpha/2014-06/msg00462.html
61869         * lib/regcomp.c (parse_expression): Deallocate partially
61870         constructed tree before returning error.
61872         regex: merge patch from libc
61873         2014-02-12  Joseph Myers  <joseph@codesourcery.com>
61874         Combine __USE_BSD and __USE_SVID into __USE_MISC.
61875         * lib/regex.h [__USE_BSD]: Change condition to [__USE_MISC].
61877 2014-06-17  Paul Eggert  <eggert@cs.ucla.edu>
61879         acl: port to gcc -Wredundant-decls
61880         From a request by Dmitry Antipov in:
61881         http://lists.gnu.org/r/emacs-devel/2014-06/msg00263.html
61882         * lib/acl.h (_GL_ACL_H): New macro.  Protect entire contents with
61883         "#ifndef _GL_ACL_H".
61885 2014-06-11  Bruce Korb  <bkorb@gnu.org>
61886         Jim Meyering  <meyering@fb.com>
61888         parse-duration: eliminate 68-year duration limit
61889         * lib/parse-duration.c: Include "intprops.h".
61890         (TIME_MAX): Rename to MAX_DURATION and define to
61891         TYPE_MAXIMUM(time_t).
61892         * modules/parse-duration (Depends-on): Add intprops.
61893         Reported by Jonas 'Sortie' Termansen.
61895 2014-06-14  Paul Eggert  <eggert@cs.ucla.edu>
61897         pthread: don't assume AC_CANONICAL_HOST, port better to Solaris, etc.
61898         * modules/pthread (Depends-on): Add 'extensions', as it defines
61899         _POSIX_PTHREAD_SEMANTICS, which is needed on Solaris.
61900         (configure.ac-early): New section.
61901         * m4/pthread.m4 (gl_PTHREAD_CHECK): Revert previous change, as
61902         it is no longer needed.
61904 2014-06-14  Pádraig Brady  <P@draigBrady.com>
61906         pthread: define thread-safe macros on some platforms
61907         * m4/pthread.m4 (gl_PTHREAD_CHECK): Define macros needed
61908         for thread-safe operation on some platforms.
61910 2014-06-13  Paul Eggert  <eggert@cs.ucla.edu>
61912         regex: don't be multithreaded if USE_UNLOCKED_IO.
61913         Problem reported by Michael Felt in: http://bugs.gnu.org/17773
61914         * lib/regex_internal.h: Do not use multithreaded version if
61915         USE_UNLOCKED_IO is defined.  This is a hack, but it works
61916         around a porting bug with coreutils 8.22 on AIX 7.1.
61918 2014-06-11  Daiki Ueno  <ueno@gnu.org>
61920         gettext: update macros to version 0.19
61921         * m4/intl.m4, m4/po.m4: Update from gettext-0.19.  In particular,
61922         depend on gl_EXTERN_INLINE and drop support for older Bison
61923         versions.
61925 2014-06-10  Pádraig Brady  <P@draigBrady.com>
61927         select,poll: fix console handle check on windows 8
61928         lib/poll.c (IsConsoleHandle): Change from testing the lower
61929         2 bits of the handle to the more expensive but accurate syscall.
61930         lib/select.c: Likewise.
61932 2014-06-10  Eli Zaretskii  <eliz@gnu.org>
61934         select: fix waiting on anonymous pipes on MS-Windows
61935         * lib/select.c (rpl_select): Fall back to polling when select()
61936         indicates there is nothing to check, while due to the timeout not
61937         expiring, activity is indicated on one of the handles.
61938         Also clear the TIMEOUT argument if the timer does expire.
61940 2014-06-10  Eli Zaretskii  <eliz@gnu.org>
61942         times: fix to return non constant value on MS-Windows
61943         * lib/times.c (times): Don't use the process creation time,
61944         rather clock() which on windows returns the number of
61945         clock ticks since the process started.
61947 2014-06-09  Michael Goffioul  <michael.goffioul@gmail.com>
61949         isatty: fix to work on windows 8
61950         * lib/isatty.c (IsConsoleHandle): Change from testing the lower
61951         2 bits of the handle to the more expensive but accurate syscall.
61953 2014-06-07  Paul Eggert  <eggert@cs.ucla.edu>
61955         maint: fix typo in fdl.texi
61956         * doc/fdl.texi: Fix typo (missing '@').
61957         Somehow this was in fdl.texi but not fdl-1.3.texi.
61959 2014-06-06  Ben Walton  <bdwalton@gmail.com>
61961         mountlist: avoid hasmntopt const type warning on solaris
61962         * lib/mountlist.c: Solaris defines the OPT param of hasmntopt()
61963         with char * instead of const char *.  Passing the constant string
61964         "ignore" generates a compiler warning.  For Solaris cast MNT_IGNORE
61965         to avoid the warning.
61967 2014-06-04  Eric Blake  <eblake@redhat.com>
61969         maintainer-makefile: delete obsolete code
61970         * top/maint.mk (build_aux): Drop old code, as threatened.
61972         maintainer-makefile: avoid spurious error messages
61973         * top/maint.mk (syntax-check): Guard definition and use of
61974         $(shell) by whether Makefile is present.
61976 2014-06-03  Ben Walton  <bdwalton@gmail.com>
61978         rename: avoid unused-but-set-variable compiler warning
61979         * lib/rename.c (rpl_rename):  In the non-Win32 variant of rpl_rename,
61980         it is possible that dst_exists may be set but not used.  Mark it with
61981         the unused attribute to avoid compiler warnings.
61983 2014-06-02  Ben Walton  <bdwalton@gmail.com>
61985         rename: mark a label as potentially unused
61986         * lib/rename.c (rpl_rename): Avoid compiler warnings seen on Solaris,
61987         by marking the out label as potentially unused.
61988         * m4/gnulib-common.m4: Mention the need for the trailing ; for C++.
61990 2014-06-01  Paul Eggert  <eggert@cs.ucla.edu>
61992         gnulib-common.m4: Fix typo in _GL_UNUSED_LABEL.
61993         * m4/gnulib-common.m4 (_GL_UNUSED_LABEL): Omit trailing semicolon.
61995 2014-06-02  Ben Walton  <bdwalton@gmail.com>
61997         acl: apply pure attribute to two functions
61998         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial):
61999         Mark as "pure" as flagged by gcc 4.9 on Solaris 10.
62001 2014-06-01  Pádraig Brady  <P@draigBrady.com>
62003         gnulib-common.m4: add _GL_UNUSED_LABEL
62004         * m4/gnulib-common.m4: Add _GL_UNUSED_LABEL which is similar to
62005         _GL_UNUSED, but handles g++ < 4.5 not supporting this syntax.
62007 2014-05-31  Paul Eggert  <eggert@cs.ucla.edu>
62009         dup2, fcntl, fcntl-h: port to AIX 7.1
62010         This fixes some porting problems discovered when testing the latest
62011         grep snapshot on AIX 7.1.  I don't think if fixes any bugs
62012         in grep but it could be important for other applications.
62013         * doc/posix-functions/dup2.texi:
62014         * doc/posix-functions/fcntl.texi:
62015         * doc/posix-headers/fcntl.texi:
62016         Document AIX bugs.
62017         * lib/fcntl.in.h (O_CLOEXEC, O_NOFOLLOW, O_TTY_INIT) [_AIX]:
62018         Define to 0 if outside 'int' range.
62019         * m4/dup2.m4 (gl_FUNC_DUP2):
62020         * m4/fcntl.m4 (gl_FUNC_FCNTL):
62021         Check for getdtablesize.  If it's available, test a value just
62022         outside its range instead of testing 1000000.  When cross-compiling,
62023         guess that AIX will fail this improved test.
62025 2014-05-30  Paul Eggert  <eggert@cs.ucla.edu>
62027         printf, config.rpath: Port to FreeBSD 10.
62028         Problem reported by Tijl Coosemans in:
62029         http://lists.gnu.org/r/bug-gnulib/2014-05/msg00078.html
62030         * build-aux/config.rpath (hardcode_libdir_flag_spec)
62031         (hardcode_direct): Simplify FreeBSD configuration.
62032         (library_names_spec): Don't mishandle FreeBSD 10+.
62033         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE)
62034         (gl_PRINTF_INFINITE_LONG_DOUBLE, gl_PRINTF_DIRECTIVE_F)
62035         (gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99)
62036         (gl_SNPRINTF_DIRECTIVE_N, gl_VSNPRINTF_ZEROSIZE_C99):
62037         Don't mishandle FreeBSD 10+ when cross-compiling.
62039         ftoastr: work around compiler bug in IBM xlc 12.1
62040         * lib/ftoastr.h (_GL_FLT_PREC_BOUND, _GL_DBL_PREC_BOUND)
62041         (_GL_LDBL_PREC_BOUND): Make these macros, not enums, to work
62042         around a compiler bug in IBM xlc 12.1.0.0: it complains
62043         '"ftoastr.c", line 80.37: 1506-045 (S) Undeclared identifier
62044         _GL_FLT_PREC_BOUND.'
62046 2014-05-30  Kieran Colford  <colfordk@gmail.com>
62048         valgrind-tests: fixed misleading help message
62049         * m4/valgrind-tests.m4: The help message generated by configure
62050         implied that valgrind was disabled by default, which it wasn't.
62051         Adjusted the help message using s/enable/disable/ to clarify.
62053 2014-05-30  Ulrich Weigand  <uweigand@de.ibm.com>
62055         isfinite, isinf, isnan tests: fix for little-endian PowerPC
62056         * tests/test-isfinite.c (test_isfinitel): Only manipulate the
62057         first double of a PowerPC "double double" pair.
62058         * tests/test-isinf.c (test_isinfl): Likewise.
62059         * tests/test-isnan.c (test_long_double): Likewise.
62060         * tests/test-isnanl.h (main): Likewise.
62061         * tests/test-signbit.c (test_signbitl): Likewise.
62063 2014-05-29  Paul Eggert  <eggert@cs.ucla.edu>
62065         exclude-tests: port to AIX 7.1
62066         * modules/exclude-tests (test_exclude_LDADD): Add $(LIBTHREAD).
62067         Needed on AIX 7.1 with xlc V12.1, otherwise it won't link because
62068         the regex code uses locks.
62070 2014-05-28  Paul Eggert  <eggert@cs.ucla.edu>
62072         pthread_sigmask, timer-time: use gl_THREADLIB only if needed
62073         Without this fix, Emacs would sometimes call sigprocmask instead
62074         of pthread_sigmask, which is a no-no in multithreaded applications.
62075         Problem reported by Jorgen Schaefer in <http://bugs.gnu.org/17561>.
62076         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
62077         Suppress check for pthread_sigmask working without -lpthread if
62078         the application always links with -lpthread.  Do not link with
62079         $LIBMULTITHREAD if gl_THREADLIB is not defined.
62080         * m4/timer_time.m4 (gl_TIMER_TIME):
62081         Require gl_THREADLIB only if it is defined.  Do not append
62082         $LIBMULTITHREAD to LIB_TIMER_TIME if gl_THREADLIB is not defined.
62084 2014-05-27  Sylvain Beucler  <beuc@beuc.net>.
62086         gnulib-tool: wget translations using --no-verbose rather than --quiet
62087         This allows the user to see error messages if any (--quiet hides them)
62088         * gnulib-tool: Invoke wget with --no-verbose, rather than --quiet.
62090 2014-05-27  Sylvain Beucler  <beuc@beuc.net>
62092         gnulib-tool: adjust translation wget to avoid a https redirection
62093         Context: http://translationproject.org/latest/gnulib redirects to
62094            https://translationproject.org/latest/gnulib/
62095         Rationale: if the user falls back to wget, she doesn't have rsync and
62096         is probably in a minimal build environment, where packages such as
62097         'ca-certificates' are missing as well, resulting in a failed (and
62098         difficult to detect since ignored) translation initial fetch.
62099         Consequently let's avoid https if possible, and add the missing
62100         trailing slash.  This also avoids an unnecessary 302 redirection.
62101         * gnulib-tool: Add trailing slash to gnulib URL.
62103 2014-05-22  Pádraig Brady  <P@draigBrady.com>
62105         getlogin_r-tests: check return value rather than errno
62106         * tests/test-getlogin_r.c (main): As per POSIX we should be
62107         verifying the return value from getlogin_r() rather than errno.
62109 2014-05-22  Pádraig Brady  <P@draigBrady.com>
62111         getlogin_r-tests: fix various issues in recent change
62112         * tests/test-getlogin_r.c: Include required headers that were
62113         missed in recent commit eec20b4e.
62114         Also consistently check the errno rather than the return value from
62115         getlogin_r as POSIX only specifies that non zero is returned on error.
62116         * modules/getlogin_r-tests (configure.ac): Add the check for ttyname().
62118 2014-05-21  Paul Eggert  <eggert@cs.ucla.edu>
62120         fchdir: port 'open' and 'close' redefinitions to AIX 7.1
62121         * lib/chown.c, lib/clean-temp.c, lib/copy-file.c, lib/execute.c:
62122         * lib/fsusage.c, lib/gc-gnulib.c, lib/javacomp.c, lib/mountlist.c:
62123         * lib/openat-proc.c, lib/pagealign_alloc.c, lib/progreloc.c:
62124         * lib/spawn-pipe.c:
62125         Do not #undef 'open' and 'close'.  AIX 7 does '#define open open64'
62126         and then 'int open64(const char *, int, ...);', which means the
62127         declaration for 'open' gets lost if we later '#undef open'.
62128         Discovered while building grep pretest 2.18.151-1c770 on AIX 7.1,
62129         where the compilation reported the non-fatal error "In function
62130         'openat_proc_name' ... warning: implicit declaration of function
62131         'open'".  In this case the error is relatively harmless, but in
62132         other cases it might not be so minor.
62134 2014-05-20  Paul Eggert  <eggert@cs.ucla.edu>
62136         xalloc: don't potentially generate invalid code for xmemdup calls
62137         * lib/xalloc.h (xmemdup): Do not mark with _GL_ATTRIBUTE_ALLOC, as
62138         this function can initialize the newly-allocated storage with new
62139         pointers, which means this function is not malloc-like.  See:
62140         https://gcc.gnu.org/bugzilla/show_bug.cgi?id=56955
62142 2014-05-19  Pádraig Brady  <P@draigBrady.com>
62144         getlogin_r-tests: avoid false failure under sudo/ssh etc.
62145         * tests/test-getlogin_r.c (main): Sync up with test-getlogin.c
62146         changes from commit 97249cf29 to not depend on environment variables.
62148 2014-05-18  Pádraig Brady  <P@draigBrady.com>
62150         getlogin-tests: avoid false failure under cron
62151         * tests/test-getlogin.c (main): Avoid verifying errnos from ttyname()
62152         since that's not what's under test.  Centos 6 was seen to return
62153         EINVAL for ttyname() when run from cron.
62155 2014-05-16  Jim Meyering  <meyering@fb.com>
62157         mbrtowc.m4: fix a comment typo
62158         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Fix typo s/2/-2/ in
62159         emitted documentation string.
62161 2014-05-16  Paul Eggert  <eggert@cs.ucla.edu>
62163         mbrlen, mbrtowc: fix bug with empty input
62164         * lib/mbrtowc.c (rpl_mbrtowc) [MBRTOWC_EMPTY_INPUT_BUG]: Fix the bug.
62165         * m4/mbrlen.m4 (gl_MBRLEN_EMPTY_INPUT): New macro.  It's not used,
62166         so this is mainly for documentation.
62167         * m4/mbrtowc.m4 (gl_MBRTOWC_EMPTY_INPUT): New macro.
62168         (gl_FUNC_MBRTOWC): Use it.
62169         * tests/test-mbrtowc.c (main): Test for the bug.
62171 2014-05-15  Paul Eggert  <eggert@cs.ucla.edu>
62173         doc: document mbrtowc and mbrlen problem with empty input
62174         * doc/posix-functions/mbrlen.texi (mbrlen):
62175         * doc/posix-functions/mbrtowc.texi (mbrtowc):
62176         Document portability problem when the input string is empty.  See:
62177         https://sourceware.org/bugzilla/show_bug.cgi?id=16950
62179         doc: document exec* = spawn+exit bug with non-Cygwin Windows platforms
62180         Problem reported by Eli Zaretskii in:
62181         http://lists.gnu.org/r/bug-grep/2014-05/msg00118.html
62182         * doc/posix-functions/execl.texi (execl):
62183         * doc/posix-functions/execle.texi (execle):
62184         * doc/posix-functions/execlp.texi (execlp):
62185         * doc/posix-functions/execv.texi (execv):
62186         * doc/posix-functions/execve.texi (execve):
62187         * doc/posix-functions/execvp.texi (execvp):
62188         Mention spawn+exit problem on non-Cygwin Windows platforms.
62190 2014-05-14  Guilherme de Almeida Suckevicz  <guito.linux@gmail.com>
62192         getlogin-tests: avoid false failure under sudo/ssh etc.
62193         * modules/getlogin-tests (configure.ac): Check for ttyname().
62194         * tests/test-getlogin.c (main): Don't depend on environment variables
62195         to correlate with getlogin(), since sudo and ssh etc. can tamper
62196         with the LOGNAME and USER env vars.  Instead lookup the name from
62197         the uid associated with the stdin tty.
62199 2014-05-11  Paul Eggert  <eggert@cs.ucla.edu>
62201         mbsstr, quotearg, xstrtol: pacify IRIX 6.5 cc
62202         These were found when building the latest grep snapshot on IRIX 6.5.
62203         * lib/mbsstr.c (knuth_morris_pratt_multibyte): Break "a=b=c;" into
62204         "b=c; a=b;", since IRIX 6.5 cc complains about the former if b is
62205         never used later.
62206         * lib/quotearg.c (quoting_options_from_style):
62207         * lib/xstrtol.c (__xstrtol):
62208         Use enum instead of 0, to pacify IRIX 6.5 cc.
62210 2014-04-18  Pádraig Brady  <P@draigBrady.com>
62212         gitlog-to-changelog: revert inclusion of git-log-fix file
62213         * build-aux/git-log-fix: Delete dummy file.
62214         * modules/gitlog-to-changelog: Don't reference (overwrite)
62215         the project specific git-log-fix file.
62217 2014-04-18  Assaf Gordon  <agordon@wi.mit.edu>
62219         maint.mk: Relax the copyright check to cater for non FSF projects
62220         * top/maint.mk (sc_copyright_check): Relax the check for $PACKAGE.texi
62221         to not require the "Free" suffix after the copyright years.
62223 2014-04-18  Natanael Copa  <ncopa@alpinelinux.org>
62225         physmem: use sysinfo on linux-gnu if _SC_PHYS_PAGES unavailable
62226         * lib/physmem.c (physmem_total): Some systems like musl libc don't yet
62227         support _SC_PHYS_PAGES.  Use the linux syscall sysinfo as fallback
62228         if _SC_PHYS_PAGES or _SC_PAGESIZE fails.
62229         (physmem_available): Likewise for _SC_AVPHYS_PAGES.
62231 2014-04-18  Paul Eggert  <eggert@cs.ucla.edu>
62233         exclude: port to strict C99
62234         Strict C does not allow converting a function pointer to void *
62235         and vice versa.  Pass a pointer to a function pointer instead.
62236         * lib/exclude.c (add_exclude_file):
62237         Pass the address of the function pointer.
62238         (call_addfn): And deference the address here, to match.
62240 2014-04-17  Paul Eggert  <eggert@cs.ucla.edu>
62242         regex: do not depend on malloc-gnu
62243         * modules/regex (Depends-on): Remove malloc-gnu.
62244         It's no longer needed, because of the 2012-12-29 patch
62245         "regex: port to hosts where malloc (0) == NULL".
62246         Reported by Nathan Kennedy in:
62247         http://lists.gnu.org/r/bug-gnulib/2014-04/msg00026.html
62249 2014-04-16  Assaf Gordon  <agordon@wi.mit.edu>
62251         expl: avoid incorrect expl(small_value) on OpenBSD 5.4
62252         * m4/expl.m4 (gl_FUNC_EXPL): Add a check for this condition.
62253         * doc/posix-functions/expl.texi: Mention the workaround.
62255 2014-04-12  Paul Eggert  <eggert@cs.ucla.edu>
62257         xalloc: allow x2nrealloc (P, PN, S) where P && !*PN
62258         * lib/xalloc.h (x2nrealloc): Extend slightly, to allow the current
62259         size to be zero even when the pointer is nonnull.  This
62260         accommodates the use case where P is malloc (0) and *PN is 0 on a
62261         host where malloc (0) yields nonnull.
62263 2014-04-09  Eric Blake  <eblake@redhat.com>
62265         fts: avoid unnecessary strlen calls
62266         * lib/fts.c (_D_EXACT_NAMLEN): Restore definition when needed.
62268 2014-04-09  Paul Eggert  <eggert@cs.ucla.edu>
62270         fts: avoid unnecessary strlen calls
62271         * lib/fts.c (fts_build): Go back to using _D_EXECT_NAMLEN
62272         when that can be faster than strlen.
62274 2014-03-26  Bernhard Voelker  <mail@bernhard-voelker.de>
62276         fts: avoid unnecessary strlen calls
62277         * lib/fts.c (_D_EXACT_NAMLEN): Remove macro.
62278         (fts_build): Store the length of the dp->d_name entry in a local variable
62279         instead of calling strlen() several times via the above, removed macro.
62280         For 'rm -rf some-dir' with e.g. 1M directory entries, this speeds up the
62281         run by ~4%, yet this reduces the execution time by about a third if run
62282         via "ltrace -c rm -rf some-dir".
62284 2014-03-27  Paul Eggert  <eggert@cs.ucla.edu>
62286         obstack: Remove ancient NeXTSTEP gcc support conditional
62287         This change will ease merging with glibc.  The "#if ... __NEXT__"
62288         causes a warning with -Wundef which glibc now enables by default.
62289         Problem reported by Will Newton in
62290         <http://lists.gnu.org/r/bug-gnulib/2014-03/msg00032.html>.
62291         glibc <sys/cdefs.h> now uses __extension__ for GCC 2.8 or later,
62292         so go with that.
62293         * lib/obstack.h (__extension__):
62295 2014-03-27  Paul Eggert  <eggert@cs.ucla.edu>
62297         obstack: merge with glibc changes
62298         * lib/obstack.c, lib/obstack.h: Merge from glibc.
62299         This is mostly indenting and commentary changes.
62300         Instances of 'register' have been removed.
62302 2014-03-26  Bernhard Voelker  <mail@bernhard-voelker.de>
62304         strftime: wrap macros in "do {...} while(0)"
62305         * lib/strftime.c (DO_NUMBER): Wrap multi-statement code block of
62306         this macro in "do {...} while(0)" to prevent false use as a
62307         single statement, e.g., in an un-braced "{}" else-block.
62308         (DO_SIGNED_NUMBER, DO_TZ_OFFSET, DO_NUMBER_SPACEPAD): Likewise.
62309         (strftime_case_): Remove 'else' after 'goto' - which was the
62310         only non-fatal, un-braced use of one of the above macros.
62311         Spotted by coverity (NESTING_INDENT_MISMATCH).
62313 2014-03-26  Bernhard Voelker  <mail@bernhard-voelker.de>
62315         modechange: avoid memory leaks for invalid octal modes
62316         * lib/modechange.c (mode_compile): During the parsing of
62317         notations like +40, free the 'mc' buffer for invalid mode
62318         strings like +17777 (greater than the maximum octal mode),
62319         =18 (bad octal mode characters) or u=1 ('affected' with
62320         octal modes).
62321         Reproducer, e.g.:
62322             $ valgrind --leak-check=full chmod +17777 file
62323         Introduced via the 2012-03-09 commit, 4730c3e3, "modechange:
62324         add notations +40, 00440, etc.".
62325         Spotted by coverity (RESOURCE_LEAK).
62327 2014-03-24  Paul Eggert  <eggert@cs.ucla.edu>
62329         gitlog-to-changelog: include a dummy git-log-fix file
62330         Problem reported by Nathan Stratton Treadway in:
62331         http://lists.gnu.org/r/bug-tar/2014-03/msg00082.html
62332         * build-aux/git-log-fix: New file.
62334 2014-03-13  Jim Meyering  <meyering@fb.com>
62336         gitlog-to-changelog: also include the file, git-log-fix
62337         * modules/gitlog-to-changelog (Files): Add git-log-fix.
62338         Reported by Assaf Gordon.
62340 2014-03-06  Paul Eggert  <eggert@cs.ucla.edu>
62342         regex: port to OS X 10.8.5 en_US.UTF-8 locale
62343         This fixes a bug when ignoring case and when comparing the
62344         titlecase letter 'Lj' (U+01C8 LATIN CAPITAL LETTER L WITH SMALL
62345         LETTER J) to the corresponding uppercase letter 'LJ' (U+01C7 LATIN
62346         CAPITAL LETTER LJ).  In the OS X 10.8.5 en_US.UTF-8 locale, the
62347         titlecase letter is neither lowercase nor uppercase, but
62348         uppercasing the titlecase letter (via towupper) yields the
62349         uppercase letter, so the two letters should match when ignoring case.
62350         Problem reported by Jim Meyering in <http://debbugs.gnu.org/16911#16>.
62351         * lib/regex_internal.c (build_wcs_upper_buffer, build_upper_buffer):
62352         Don't test whether a character is lowercase before uppercasing it.
62354 2014-03-04  Kevin Cernekee  <cernekee@gmail.com>
62356         stdint, read-file: fix missing SIZE_MAX on Android (tiny change)
62357         This is basically one of the options Bruno Haible proposed in:
62358         http://lists.gnu.org/r/bug-gnulib/2012-01/msg00282.html
62359         * lib/sys_types.in.h (_GL_INCLUDING_UNISTD_H): New macro.
62360         * lib/stdint.in.h: Use it.
62361         * modules/stdint (Depends-on): Add sys_types.
62363 2014-02-26  Pádraig Brady  <P@draigBrady.com>
62365         parse-datetime: fix crash or infloop in TZ="" parsing
62366         * lib/parse-datetime.y (parse_datetime): Break out of the
62367         TZ="" parsing loop once the second significant " is found.
62368         Also skip over any subsequent whitespace to be consistent
62369         with the non TZ= case.
62370         * tests/test-parse-datetime.c: Add test cases for TZ="" parsing.
62372 2014-02-26  Paul Eggert  <eggert@cs.ucla.edu>
62374         savedir: new symbol for fast-read version
62375         * lib/savedir.h (SAVEDIR_SORT_FASTREAD): New symbol, for programs
62376         like GNU cp that want to use SAVEDIR_SORT_INODE if available,
62377         SAVEDIR_SORT_NONE otherwise.  Problem reported by Bernhard Voelker in:
62378         http://lists.gnu.org/r/coreutils/2014-02/msg00037.html
62380 2014-02-25  Paul Eggert  <eggert@penguin.cs.ucla.edu>
62382         unistd: port readlink to Mac OS X 10.3.9
62383         * lib/unistd.in.h (_GL_INCLUDING_UNISTD_H): New macro, to work
62384         around self-include problem in Mac OS X 10.3.9 when combined with
62385         readlink module.  Problem reported by Klaus Zietler in
62386         <http://bugs.gnu.org/16825>.
62388 2014-02-23  Paul Eggert  <eggert@cs.ucla.edu>
62390         diffseq: remove TOO_EXPENSIVE heuristic
62391         Problem with diffutils reported by Vincent Lefevre in
62392         <http://bugs.gnu.org/16848>.  The simplest solution is to remove
62393         the TOO_EXPENSIVE heuristic that I added to GNU diff in 1993.
62394         Although appropriate for circa-1993 hardware, these days the heuristic
62395         seems to be more trouble than it's worth.
62396         * lib/diffseq.h: Modernize citations.
62397         (struct context): Remove member too_expensive.
62398         All uses changed.
62399         (struct partition): Remove members lo_minimal, hi_minimal.
62400         All uses changed.
62401         (diag, compareseq): Remove arg find_minimal.  All uses changed.
62402         (diag): Remove the TOO_EXPENSIVE heuristic that I added back in
62403         1993 to make 'diff' run faster (but not as well) on large inputs.
62404         These days, computers are fast enough that it's typically better
62405         to run slower but more accurately.
62406         * lib/fstrcmp.c: Remove duplicate comment.
62407         * lib/fstrcmp.c (strcmp_bounded):
62408         * lib/git-merge-changelog.c (compute_differences):
62409         Adjust to diffseq.h changes.
62410         * NEWS: Document the change.
62412         savedir: simplify by using stpcpy
62413         * lib/savedir.c (direntry_t): Remove size member.  All uses removed.
62414         (streamsavedir): Use stpcpy instead.
62415         * modules/savedir (Depends-on): Add stpcpy.
62417 2014-02-21  Pádraig Brady  <P@draigBrady.com>
62419         spawn: fix link error on uclibc
62420         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): use AC_SEARCH_LIBS,
62421         to incorporate -lrt if needed (on uclibc for example).
62422         * modules/posix_spawn: Reference the substituted LIB.
62424 2014-02-21  Thomas Petazzoni  <thomas.petazzoni@free-electrons.com>  (tiny change)
62425         timer: fix uClibc detection of threading
62426         * m4/time_time.m4 (gl_TIMER_TIME): Detect whether threads are
62427         enabled in uClibc.
62429 2014-02-21  Eric Blake  <eblake@redhat.com>
62431         maintainer-makefiles: provide AC_PROG_SED for older autoconf
62432         * m4/gnulib-common.m4 (AC_PROG_SED): Copy from newer autoconf.
62434 2014-02-21  Sergey Poznyakoff  <gray@gnu.org.ua>
62436         exclude: add support for posix regexps
62438         This commit adds support for POSIX extended regular expressions
62439         and fixes a long-standing memory leak (pattern buffer was never
62440         freed).  It also implements a new interface function to read
62441         exclude patterns from a FILE, which passes an additional parameter
62442         to its callback function, thereby allowing to preserve its state
62443         between invocations.
62445         * lib/exclude.c (struct patopts): Pack regex and pattern into union.
62446         (pattern_buffer): New struct.
62447         (exclude): New member patbuf.
62448         (exclude_add_pattern_buffer): New function.
62449         (free_exclude_segment): Free regexps.
62450         (free_exclude): Free allocated pattern buffers.
62451         (exclude_patopts): New function.
62452         (file_pattern_matches): Use exclude_patopts.
62453         (add_exclude): support regexps.
62454         (add_exclude_fp): New function.
62455         (add_exclude_file): Rewrite using add_exclude_fp.
62456         (fnmatch_pattern_has_wildcards): Support posix extended regexps.
62457         * lib/exclude.h (EXCLUDE_REGEX, EXCLUDE_ALLOC): New flags.
62458         (add_exclude_fp)
62459         (add_exclude_file): Rewrite using add_exclude_fp.
62460         (fnmatch_pattern_has_wildcards): Support posix extended regexps.
62461         * lib/exclude.h (EXCLUDE_REGEX, EXCLUDE_ALLOC): New flags.
62462         (add_exclude_fp)
62463         (exclude_add_pattern_buffer): New prototypes.
62464         * modules/exclude: Depends on regex and filename.
62466 2014-02-20  Eric Blake  <eblake@redhat.com>
62468         maintainer-makefiles: use $(SED) for syntax check
62469         * modules/maintainer-makefile (configure.ac): Check for sane sed.
62470         * top/maint.mk: Change sed to $(SED).
62472 2014-02-11  Sergey Poznyakoff  <gray@gnu.org.ua>
62473             Paul Eggert  <eggert@cs.ucla.edu>
62475         savedir: add sorting arg to savedir, streamsavedir; remove fdsavedir
62476         Patch based on an idea by Dick Streefland in
62477         <https://savannah.gnu.org/patch/?7892>.
62478         * NEWS: Document this.
62479         * lib/savedir.c (NAME_SIZE_DEFAULT): Remove.
62480         (direntry_t, comparison_function): New types.
62481         (direntry_cmp_name): New function.
62482         (direntry_cmp_inode) [D_INO_IN_DIRENT]: New function.
62483         (streamsavedir, savedir): New arg OPTION.
62484         (streamsavedir): Simplify memory allocation.
62485         (fdsavedir): Remove.
62486         * lib/savedir.h (enum savedir_option): New type.
62487         (streamsavedir, savedir): New arg OPTION.
62488         (fdsavedir): Remove.
62490 2014-02-05  Paul Eggert  <eggert@cs.ucla.edu>
62492         file-type: add support for doors and other less-common file types
62493         Problem with S_ISDOOR reported by Rich Burridge.
62494         * lib/file-type.c (file_type): Do S_ISLNK early too.  Do S_TYPEIS*
62495         macros before the rest.  Add S_ISCTG, S_ISDOOR, S_ISMPB, S_ISMPC,
62496         S_ISMPX, S_ISNAM, S_ISNWK, S_ISOFD, S_ISOFL, S_ISPORT, S_ISWHT.
62498 2014-01-23  Eric Blake  <eblake@redhat.com>
62500         pthread: work around winpthread header pollution on mingw
62501         * lib/time.in.h: Move pthread workarounds...
62502         * lib/pthread.in.h: ...here.
62503         * m4/pthread.m4 (gl_PTHREAD_CHECK): Also build pthread.h when we
62504         detect macro pollution on mingw.
62505         * doc/posix-headers/pthread.texi (pthread.h): Document the problems.
62507 2014-01-22  Paul Eggert  <eggert@cs.ucla.edu>
62509         qacl: check for fchmod
62510         * m4/acl.m4 (gl_FUNC_ACL): Check for fchmod, since acl-internal.h
62511         and qset-acl.c both use HAVE_FCHMOD.
62513 2014-01-20  Paul Eggert  <eggert@cs.ucla.edu>
62515         fdopen-tests: port to Tru64
62516         * tests/test-fdopen.c (main): Don't invoke fdopen on a file
62517         descriptor that is not open, as POSIX doesn't specify the
62518         resulting behavior and the test does not work on Tru64.
62519         Problem reported by Steven M. Schweda in:
62520         http://lists.gnu.org/r/bug-gnulib/2014-01/msg00079.html
62522         stdalign: port to HP-UX compilers
62523         * lib/stdalign.in.h (_Alignas): Use __attribute__ (__aligned__ (x))
62524         if __HP_cc or __HP_aCC are nonzero.
62526 2014-01-16  Paul Eggert  <eggert@cs.ucla.edu>
62528         strtoimax: port to platforms lacking 'long long'
62529         VMS's pre-C99 compiler lacks 'long long', so 'configure' doesn't
62530         check whether strtoll is declared, which causes the C file to
62531         wrongly report an error.  Problem reported by Steven M. Schweda in:
62532         http://lists.gnu.org/r/bug-diffutils/2014-01/msg00003.html
62533         * lib/strtoimax.c (strtoull):
62534         Declare only if HAVE_UNSIGNED_LONG_LONG_INT.
62535         (strtoll): Declare only if HAVE_LONG_LONG_INT.
62537 2014-01-16  Daniel Albers  <daniel@lbe.rs>  (tiny change)
62539         relocatable-perl: fix texi syntax
62540         * doc/relocatable-maint.texi: Escape braces.
62542 2014-01-09  Reuben Thomas  <rrt@sc3d.org>
62544         relocatable-perl: like relocatable-script, but for Perl scripts
62545         * build-aux/relocatable.pl.in: Add.
62546         * doc/relocatable-maint.texi: Add documentation.
62547         * modules/relocatable-perl: Add.
62549 2014-01-07  Paul Eggert  <eggert@cs.ucla.edu>
62551         tests: fix export bug in previous patch
62552         Problem reported by Jim Meyering.
62553         * tests/init.sh (re_shell): New var, which is exported instead of
62554         re_shell_.
62556         tests: simplify porting to Solaris 10 /bin/sh
62557         Some test cases in 'grep' need a shell that groks '$(';
62558         export re_shell_ for their benefit.  Problem reported for 'grep'
62559         by Dagobert Michelsen in <http://bugs.gnu.org/16380>.
62560         * tests/init.sh (re_shell_): Export if it's used.
62562 2014-01-06  Eric Blake  <eblake@redhat.com>
62564         md5, sha1, sha256, sha512: support older autoconf
62565         * m4/00gnulib.m4 (m4_divert_push): Wrap diversion stack
62566         for autoconf < 2.63b.
62568         include_next: port to autoconf 2.63
62569         * m4/gnulib-common.m4 (AS_VAR_COPY): Define if missing.
62571 2014-01-04  Jim Meyering  <meyering@fb.com>
62573         maint: add a gnulib-local rule to keep non-ascii out of .texi files
62574         * cfg.mk (sc_keep_gnulib_texi_files_mostly_ascii): New rule,
62575         so that "make sc_maint" will ding anyone who puts non-ascii
62576         in any of gnulib's .texi files.
62578 2014-01-03  Jim Meyering  <meyering@fb.com>
62580         freadable, fwritable, fwriting: declare with the "pure" attribute
62581         * lib/freadable.h (freadable): Declare with the "pure" attribute.
62582         * lib/fwritable.h (fwritable): Likewise.
62583         * lib/fwriting.h (fwriting): Likewise.
62584         Suggested by Bruno Haible.
62586         maint.mk: adapt openat.h-include-without-use test
62587         * top/maint.mk (sc_prohibit_openat_without_use): Also check for
62588         FCHMODAT_INLINE, FCHOWNAT_INLINE and STATAT_INLINE, to avoid
62589         failing on gnulib's own lib/{chmod,chown,stat}at.c files.
62590         With this change, running "make sc_maint" in gnulib's top-level
62591         directory now passes for me.
62593 2014-01-03  Paul Eggert  <eggert@cs.ucla.edu>
62595         doc: use ASCII in .texi files where UTF-8 isn't needed
62596         * doc/posix-functions/crypt.texi, doc/posix-functions/encrypt.texi:
62597         * doc/posix-functions/setkey.texi, doc/regex.texi:
62598         Use ASCII input, not UTF-8.
62600 2014-01-02  Jim Meyering  <meyering@fb.com>
62602         freading: declare with the "pure" attribute
62603         * lib/freading.h (freading): Declare with the "pure" attribute.
62605         manywarnings: remove -Wmudflap
62606         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Remove -Wmudflap, since
62607         it is no longer supported in gcc-4.9-to-be.
62609 2014-01-01  Paul Eggert  <eggert@cs.ucla.edu>
62611         relocatable-script: remove unused code
62612         Problem reported by Reuben Thomas in:
62613         http://lists.gnu.org/r/bug-gnulib/2013-12/msg00117.html
62614         * build-aux/relocatable.sh.in (func_tmpdir): Remove unused function.
62616 2014-01-01  Jim Meyering  <meyering@fb.com>
62618         maint: fix public-submodule-commit to work with newer git
62619         * top/maint.mk (public-submodule-commit): Remove excess quoting.
62620         We were over-quoting the test arguments, and somewhere prior to
62621         version 1.8.5.2.229, git stopped removing those excess quotes,
62622         which made the test fail, since the unexpanded strings would
62623         always differ; using GIT_TRACE=1 confirmed that the git merge-base
62624         command wasn't even being run.
62626 2014-01-01  Paul Eggert  <eggert@cs.ucla.edu>
62628         doc: update main copyright year
62629         * doc/gnulib.texi: Update copyright date.
62631 2014-01-01  Eric Blake  <eblake@redhat.com>
62633         version-etc: new year
62634         * lib/version-etc.c (COPYRIGHT_YEAR): Bump to 2014.
62635         * all files: run 'make update-copyright'
62637 2013-12-24  Eric Blake  <eblake@redhat.com>
62639         passfd: give nicer error for recvfd at eof
62640         * lib/passfd.c (recvfd): Fake ENOTCONN if other end closes early.
62641         * tests/test-passfd.c (main): Enhance test to cover this.
62643 2013-12-17  Paul Eggert  <eggert@cs.ucla.edu>
62645         gettimeofday: port recent C++ fix to Emacs
62646         Without this further patch, Emacs won't build due to
62647         the portcheck failing.  Also, this simplifies the patch a bit.
62648         * lib/time.in.h (localtime, gmtime): Don't replace unless
62649         GNULIB_GETTIMEOFDAY.  Treat them more like mktime.
62650         * lib/time.in.h (localtime, gmtime):
62651         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME):
62652         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS):
62653         * modules/time (time.h):
62654         Don't worry about the possibility of localtime and gmtime
62655         being absent; they're present in all C libraries we know about.
62656         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS):
62657         Don't assume sys_time is present and has been initialized.
62658         Instead, use a hack that should work even if it hasn't been.
62659         Don't use a portcheck for gmtime or localtime; this supports
62660         the hack.
62661         * modules/time (time.h): Substitute GNULIB_GETTIMEOFDAY.
62663 2013-12-17  John W. Eaton  <jwe@gnu.org>
62665         gettimeofday: fix C++ crosscompilation
62667         Never replace gmtime and localtime by macros when compiling with
62668         C++, this prevents <ctime> from being included.
62670         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Do not
62671         define gmtime and localtime as preprocessor macros.  Instead
62672         define some HAVE_GMTIME, HAVE_LOCALTIME, REPLACE_GMTIME, and
62673         REPLACE_LOCALTIME substitutions.
62674         * lib/time.in.h: Declare gmtime and localtime when needed.
62675         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): AC_SUBST HAVE_GMTIME,
62676         HAVE_LOCALTIME, REPLACE_GMTIME, and REPLACE_LOCALTIME.
62677         * modules/time: Depend on gettimeofday, and substitute the above
62678         variables in time.h.
62680 2013-12-17  Paul Eggert  <eggert@cs.ucla.edu>
62682         qacl: port to Windows better
62683         See Eli Zaretskii in
62684         <http://lists.gnu.org/r/emacs-devel/2013-12/msg00593.html>.
62685         * lib/file-has-acl.c (acl_access_nontrivial):
62686         Return -1 and set errno if !HAVE_ACL_FIRST_ENTRY &&
62687         !HAVE_ACL_TO_SHORT_TEXT && !HAVE_ACL_FREE_TEXT.
62689 2013-12-12  Alexander V. Lukyanov  <lav@netis.ru>
62691         md5, sha1, sha256, sha512: fix (trivial) compile error in c++ mode.
62692         * lib/gl_openssl.h: Cast void pointers to a specific type.
62694 2013-12-07  Pádraig Brady  <P@draigBrady.com>
62696         open-tests: fix build failure with -Werror=old-style-declaration
62697         * tests/test-open.h: Reorder the inline to avoid the issue.
62699 2013-12-07  Pádraig Brady  <P@draigBrady.com>
62701         md5, sha1, sha256, sha512: fix link error with partial libcrypto
62702         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): Only clear LIB_CRYPTO at
62703         init time, so that if early checks find crypto routines,
62704         while the last does not, then @LIB_CRYPTO@ is replaced correctly,
62705         avoiding link failures.
62707 2013-12-07  Paul Eggert  <eggert@cs.ucla.edu>
62709         md5, sha1, sha256, sha512: add gl_SET_CRYPTO_CHECK_DEFAULT
62710         This provides a new way to specify the default for
62711         gl_CRYPTO_CHECK, one that is reflected in the --help message.
62712         Emacs uses this, as well as the old way.
62713         This attempts to implement a suggestion by Pádraig Brady in
62714         <http://lists.gnu.org/r/coreutils/2013-12/msg00080.html>.
62715         * m4/gl-openssl.m4(gl_SET_CRYPTO_CHECK_DEFAULT): New macro.
62716         (gl_CRYPTO_CHECK): Use it.  Mention the default in --help output.
62718         md5, sha1, sha256, sha512: add 'auto', and a way to specify default
62719         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK):
62720         Add support for a new option, --with-openssl=auto, which causes
62721         the library to be used if available and silently ignored if not.
62722         Add support to allow configure.ac to specify its own
62723         default, by setting with_openssl_default before invoking gl_INIT.
62725 2013-12-05  Paul Eggert  <eggert@cs.ucla.edu>
62727         open-tests: port to glibc with _FORTIFY_SOURCE and -O1
62728         Problem reported by Daiki Ueno in:
62729         http://lists.gnu.org/r/bug-gnulib/2013-06/msg00052.html
62730         * tests/test-open.h (__always_inline):
62731         New macro, if not already defined.
62732         (test_open): Use it.
62734 2013-12-04  Eric Blake  <eblake@redhat.com>
62736         include_next: minimize code duplication
62737         * modules/include_next (Depends-on): Add absolute-header.
62738         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Reuse
62739         gl_ABSOLUTE_HEADER_ONE instead of open-coding it.
62741 2013-12-04  Pádraig Brady  <P@draigBrady.com>
62743         getcwd: fix compile error in configure check
62744         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Include errno.h
62746 2013-12-04  Pádraig Brady  <P@draigBrady.com>
62748         regex: suppress core dumps from detection code
62749         * m4/regex.m4 (gl_REGEX): Catch the SIGABRT and convert to SIGTERM
62750         to suppress core dumps that may well occur on glibc systems.
62751         These core dumps might not be cleaned up automatically, or could
62752         trigger some system core dump handling logic.
62754 2013-12-03  Pádraig Brady  <P@draigBrady.com>
62756         md5, sha1, sha256, sha512: support mandating use of openssl
62757         * m4/gl-openssl.m4 (gl_crypto_check): Adjust the --with-openssl
62758         description, to list the now 3 separate options.  also don't
62759         mention the default=no, since this is implicit given the option
62760         is described as --with-openssl rather than --without-openssl.
62761         If projects change the default they're free to document that.
62762         with --with-openssl[=yes] we now error out when the specified
62763         hash algorithm is not available in libcrypto.
62765 2013-12-03  Ivailo  <xakepa10@gmail.com>
62767         test-xvasprintf: (trivial) fix to disable some -Wformat-security diags
62768         * tests/test-xvasprintf.c: Disable -Wformat-zero-length and
62769         -Wformat-nonliteral checks, as these edge cases are part of the test.
62771 2013-12-03  Eric Blake  <eblake@redhat.com>
62773         regex: avoid glibc deadlock during configure
62774         * m4/regex.m4 (gl_REGEX): Avoid recursive malloc deadlock when
62775         glibc bug 15078 in turn triggers bug 16159.
62776         Reported by Michal Privoznik.
62778 2013-12-02  Pádraig Brady  <P@draigBrady.com>
62780         md5, sha1, sha256, sha512: use openssl routines if available.
62781         --with-openssl the libcrypto md5, sha1, sha224, sha256, sha384, sha256
62782         routines will be used if available, requiring apps to link @LIB_CRYPTO@
62783         * lib/gl_openssl.h: Provide wrappers for specified openssl hash.
62784         * m4/gl-openssl.m4 (gl_CRYPTO_CHECK): New function to lookup libcrypto
62785         in the standard system location.
62786         * m4/sha1.m4: Call gl_CRYPTO_CHECK() for SHA1.
62787         * m4/sha256.m4: Likewise with SHA256.
62788         * m4/sha512.m4: Likewise with SHA512.
62789         * m4/md5.m4: Likewise with MD5.
62790         * m4/gc.m4: Ensure @LIB_CRYPTO@ set for tests.
62791         * lib/sha1.h: Include wrappers if HAVE_OPENSSL_SHA1.
62792         * lib/sha256.h: Likewise with SHA256.
62793         * lib/sha512.h: Likewise with SHA512.
62794         * lib/md5.h: Likewise with MD5.
62795         * lib/sha1.c: Exlude functionality if HAVE_OPENSSL_SHA1.
62796         * lib/sha256.c: Likewise with SHA256.
62797         * lib/sha512.c: Likewise with SHA512.
62798         * lib/md5.c: Likewise with MD5.
62799         * modules/crypto/sha1 (Link:): Add the new optional lib.
62800         (Depends-on:): Add dependency on extern-inline.
62801         * modules/crypto/sha256: Likewise.
62802         * modules/crypto/sha512: Likewise.
62803         * modules/crypto/md5: Likewise.
62804         * modules/crypto/sha1-tests: Reference the lib here too.
62805         * modules/crypto/md5-tests: Likewise.
62806         * modules/crypto/gc-des-tests: Likewise.
62807         * modules/crypto/gc-hmac-md5-tests: Likewise.
62808         * modules/crypto/gc-hmac-sha1-tests: Likewise.
62809         * modules/crypto/gc-hmac-sha256-tests: Likewise.
62810         * modules/crypto/gc-hmac-sha512-tests: Likewise.
62811         * modules/crypto/gc-md5-tests: Likewise.
62812         * modules/crypto/gc-pbkdf2-sha1-tests: Likewise.
62813         * modules/crypto/gc-sha1-tests: Likewise.
62814         * modules/crypto/gc-tests: Likewise.
62815         * modules/crypto/hmac-md5-tests: Likewise.
62816         * modules/crypto/hmac-sha1-tests: Likewise.
62817         * modules/crypto/hmac-sha256-tests: Likewise.
62818         * modules/crypto/hmac-sha512-tests: Likewise.
62820 2013-11-29  RV1971  <rv1971@web.de>
62822         base64: (trivial) fix compilation regression on some compilers
62823         * lib/base64.c: Don't return the void function,
62824         instead split to a separate return statement.
62826 2013-11-28  Paul Eggert  <eggert@cs.ucla.edu>
62828         ignore-value: revert previous code change
62829         * lib/ignore-value.h (ignore_value): Use __extension__ and
62830         __typeof__ only for GCC 3.4 and later.  Reported by Eric Blake in
62831         <http://lists.gnu.org/r/bug-gnulib/2013-11/msg00102.html>.
62832         Change the comment to try to explain this better.
62834 2013-11-27  Pádraig Brady  <P@draigBrady.com>
62836         selinux-h: improve stub types and add more stub functions
62838         * lib/se-selinux.in.h: Change security_context_t to a typedef
62839         rather than a define, as it's a pointer type and so is better
62840         as a typedef to avoid issues declaring multiple variables
62841         with the comma operator.  Also add stub for string_to_security_class().
62842         * lib/se-context.in.h: Add stub functions for
62843         context_{type,range,role,user}_get().
62845 2013-11-27  Paul Eggert  <eggert@cs.ucla.edu>
62847         ignore-value: prefer GCC version back through 2.0
62848         The code didn't match the comments, so I did a bit of software
62849         archaeology.  GCC 2.0 seems to support __extension__ and
62850         __typeof__, so fix both code and comments to use 2.0.
62851         * lib/ignore-value.h (ignore_value): Use __extension__ and
62852         __typeof__ for GCC 2.0 through 3.3, too.
62854 2013-11-25  Mats Erik Andersson  <gnu@gisladisker.se>
62856         pty: Activate the signature wrapper of forkpty.
62857         The intended preprocessor macro HAVE_FORKPTY is
62858         never defined, yet `lib/forkpty.c' depends on it.
62860         * m4/pty.m4 (gl_FUNC_FORKPTY): At completed analysis,
62861         apply AC_DEFINE_UNQUOTED to HAVE_FORKPTY with value
62862         $HAVE_FORKPTY for access to wrapper in `lib/forkpty.c'.
62864 2013-11-18  Jim Meyering  <meyering@fb.com>
62865         and Paul Eggert  <eggert@cs.ucla.edu>
62867         quotearg: don't attempt to store 1 << 31 into an "int"
62868         * lib/quotearg.c (quotearg_buffer_restyled): Building coreutils with
62869         gcc's new -fsanitize=undefined and running its tests triggered some
62870         new test failures due to undefined behavior, all with this diagnostic:
62871           lib/quotearg.c:629:62: runtime error: left shift of 1 by 31 places \
62872             cannot be represented in type int
62873         Rather than shifting "1" left to form a mask, shift the bits right and
62874         simply use "1" as the mask.
62876 2013-11-21  Paul Eggert  <eggert@cs.ucla.edu>
62878         error: depend on stdio
62879         Problem reported by Nikos Mavrogiannopoulos in
62880         <http://lists.gnu.org/r/bug-gnulib/2013-11/msg00084.html>
62881         * modules/error (Depends-on): Add stdio.
62883 2013-11-18  Ben Pfaff  <blp@cs.stanford.edu>
62885         * doc/relocatable-maint.texi (Supporting Relocation): Improve
62886         wording.
62887         Reported by Reuben Thomas <rrt@sc3d.org>.
62889 2013-11-13  Paul Eggert  <eggert@cs.ucla.edu>
62891         * lib/getgroups.c (posix_getgroups, getgroups) [__APPLE__]:
62892         New function and macro, to work around _DARWIN_C_SOURCE problem.
62893         Reported by Jack Howarth in <http://bugs.gnu.org/14463>.
62895 2013-11-11  Pádraig Brady  <P@draigBrady.com>
62897         base64: provide a fast path for encoding well sized buffers
62898         Avoid conditionals in the base64 encoding loop,
62899         which was seen to give 60% better throughput.
62900         * lib/base64.c (base64_encode_fast): A new function to be called
62901         when we don't want to NUL terminate, and we have enough space
62902         in the output to encode the given input.
62903         (base64_encode): Call the _fast() version when appropriate.
62904         Also remove a redundant mask with 0x3F on the first encoded byte.
62906 2013-11-08  Paul Eggert  <eggert@cs.ucla.edu>
62908         extern-inline: port better to OS X 10.9
62909         * m4/extern-inline.m4: Omit serial number; this file doesn't use them.
62910         (gl_EXTERN_INLINE): Do not suppress the use of extern inline on
62911         OS X 10.9, except for g++ where the bug is still present.
62912         See <http://trac.macports.org/ticket/41033>.
62914 2013-11-08  Eric Blake  <eblake@redhat.com>
62916         fpending: fix regression on DragonFly BSD
62917         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for declaration.
62918         * lib/fpending.h (__fpending): Don't declare twice.
62919         Reported by GW in
62920         <https://lists.gnu.org/r/bug-m4/2013-11/msg00000.html>
62922 2013-11-05  Jim Meyering  <meyering@fb.com>
62924         hash: relax license to LGPLv2+, for libguestfs
62925         * modules/hash (License): Change from GPL to LGPLv2+.
62927 2013-11-03  Paul Eggert  <eggert@cs.ucla.edu>
62929         intprops: port to Oracle Studio c99
62930         * lib/intprops.h (_GL_HAVE___TYPEOF__) [__SUNPRO_C && __STDC__]:
62931         Define to 0, to avoid diagnostics when Oracle Studio is pedantic.
62933 2013-10-31  Paul Eggert  <eggert@cs.ucla.edu>
62935         obstack: pacify HP C
62936         * lib/obstack.h (obstack_free) [!__GNUC__]: Rewrite to avoid
62937         warning "conversion from pointer to smaller integer" from HP
62938         C-ANSI-C - cc version B9007AA/B3910B A.06.26.  It's safe to assume
62939         C89 or later nowadays, so cast to void instead of int.  Privately
62940         reported by H.Merijn Brand.  Also, change header to match glibc's,
62941         to make checking against glibc easier.
62943 2013-10-29  Jim Meyering  <meyering@fb.com>
62945         maint.mk: prefer gpgv2 over gpgv
62946         * top/maint.mk (gpgv): Use gpgv2 if present, else gpgv.
62947         (gpg_key_ID): Use $(gpgv), rather than hard-coding "gpgv".
62948         Reported by Gary Vaughan.
62950 2013-10-30  Paul Eggert  <eggert@cs.ucla.edu>
62952         isnan: port to VAX
62953         Reported by John Klos for NetBSD-5/VAX in
62954         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00133.html>.
62955         * lib/isnan.c (IEEE_FLOATING_POINT): New macro, stolen from Emacs.
62956         (FUNC): Use it.
62958 2013-10-28  Jim Meyering  <meyering@fb.com>
62960         gnulib-tool: protect against CDPATH
62961         * gnulib-tool: Many "cd" built-in functions print a directory name
62962         to stdout when CDPATH is set, e.g.,
62963           $ bash -c 'CDPATH=/; cd tmp'
62964           /tmp
62965         Unset it, when possible.  Prompted by a comment from Bruce Korb.
62967         maint.mk: restore functionality removed by recent change...
62968         Sunday's change, v0.0-8062-g6b24f60, may have appeared correct from
62969         the context of a shallow-cloned gnulib repository: "git describe"
62970         would fail in such a directory.  However, that change made it so
62971         the reported gnulib revision no longer includes the version number
62972         or a commit count, even when run from a full clone.
62973         * top/maint.mk (gnulib-version): Use the full "git describe"
62974         output when possible, e.g., the form above, rather than the
62975         abbreviated, no-tag, no-commit-count string, and fall back to
62976         using a 10-byte hash, rather than the default minimal-length
62977         hash prefix, since while the minimal-length one may be fine today,
62978         it is likely not to be unique for very long.
62980 2013-10-26  Jim Meyering  <meyering@fb.com>
62982         maint.mk: fix "release" target to build _version
62983         This fixes a bug in README-release whereby following the outlined
62984         steps, one would publish a tarball whose programs would report
62985         --version output not consistent with the package version number.
62986         This bug caused grep-2.15 to produce a grep program whose
62987         --version option made it print 2.14.56-1e3d rather than 2.15.
62988         * top/maint.mk (release): Making this target build "_version"
62989         ensures that the new version number is reflected in configure.
62991 2013-10-21  Ben Pfaff  <blp@cs.stanford.edu>
62993         install-reloc: Support multi-binary installation.
62994         * build-aux/install-reloc: Support installing multiple programs in
62995         one invocation, as done by Automake starting with commit
62996         4295fe33eb23f (Multi-file install for PROGRAMS.).  From Bruno
62997         Haible <bruno@clisp.org>, archived at
62998         http://lists.debian.org/debian-bsd/2012/05/msg00032.html.
62999         Reported by Sylvain <beuc@gnu.org>.
63001 2013-10-21  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
63003         selinux-h: Really build without selinux when library is missing.
63004         * m4/selinux-selinux-h.m4: When the selinux library is missing, really
63005         continue without selinux, as already told in the warning message.
63007 2013-10-21  Jim Meyering  <meyering@fb.com>
63009         regex: also remove dependency on HAVE_WCSCOLL
63010         * lib/regex_internal.h: Remove final vestige of the wcscoll dependency.
63012 2013-10-21  Reuben Thomas  <rrt@sc3d.org>
63014         xfreopen: Fix typo. s/frepoen/freopen/
63015         * lib/xfreopen.c: Fix description.
63016         * modules/xfreopen: Likewise.
63018 2013-10-21  Jim Meyering  <meyering@fb.com>
63020         regex: don't depend on wcscoll
63021         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wcscoll.
63022         It is no longer used.
63024 2013-10-20  Jim Meyering  <meyering@fb.com>
63026         error: add the printf attribute to a static function
63027         * lib/error.c (error_tail): Add the printf attribute, to placate
63028         gcc's -Werror=suggest-attribute=format option.
63030 2013-09-30  Jim Meyering  <meyering@fb.com>
63032         fpending, obstack, strerror-override: use pure+const function attrs
63033         * lib/fpending.h (__fpending): Declare with the "pure" attribute.
63034         * lib/obstack.c (_obstack_allocated_p): Likewise.
63035         * lib/obstack.h (_obstack_memory_used): Likewise.
63036         (_obstack_memory_used): Likewise.
63037         * lib/strerror-override.h (strerror_override): Declare with
63038         the "const" attribute.
63040 2013-10-18  Eric Blake  <eblake@redhat.com>
63042         extern-inline: make safe for -Wundef usage
63043         Reported by Vladimir 'phcoder' Serbinenko in
63044         https://lists.gnu.org/r/bug-gnulib/2013-10/msg00078.html
63045         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Port to older gcc.
63047 2013-10-16  Paul Eggert  <eggert@cs.ucla.edu>
63049         mkfifo-tests, etc.: allow HP-UX 11.11 bug
63050         Problem reported by Daniel Richard G. in
63051         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00068.html>.
63052         * doc/posix-functions/mkfifo.texi (mkfifo):
63053         * doc/posix-functions/mkfifoat.texi (mkfifoat):
63054         * doc/posix-functions/mknod.texi (mknod):
63055         * doc/posix-functions/mknodat.texi (mknodat):
63056         Document the HP-UX 11.11 bug.
63057         * tests/test-mkfifo.h (test_mkfifo):
63058         Allow the HP-UX 11.11 bug.
63060 2013-10-14  Paul Eggert  <eggert@cs.ucla.edu>
63062         acl: allow cross-compilation to Gentoo
63063         Problem reported by Gabriel Marcano in
63064         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00058.html>.
63065         * m4/acl.m4 (gl_ACL_GET_FILE): When cross-compiling,
63066         test only whether it links.
63068 2013-10-13  Paul Eggert  <eggert@cs.ucla.edu>
63070         mgetgroups: remove dependency on realloc-gnu
63071         The dependency violates the comment in realloc-gnu, which
63072         says that tests can't depend on realloc-gnu; some tests depend
63073         on mgetgroups, so mgetgroups can't depend on realloc-gnu.
63074         Problem reported by Daniel Richard G. in
63075         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00056.html>.
63076         * lib/mgetgroups.c (mgetgroups): Don't call realloc (NULL, 0).
63077         * modules/mgetgroups (Depends-on): Depend on realloc-posix,
63078         not realloc-gnu.
63080 2013-10-12  Paul Eggert  <eggert@cs.ucla.edu>
63082         regex-tests: port to HP-UX 11.11
63083         Problem reported by Daniel Richard G. in
63084         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00052.html>.
63085         * modules/regex-tests (test_regex_LDADD): Add LIBTHREAD, LIB_PTHREAD.
63087 2013-10-10  Paul Eggert  <eggert@cs.ucla.edu>
63089         verify: document some 'assume' pitfalls
63090         * doc/verify.texi (Compile-time Assertions):
63091         Mention that 'assume (E)' can sometimes slow things down.
63092         Use CHAR_MAX + 1, not UCHAR_MAX + 1.
63094 2013-10-10  Eric Blake  <eblake@redhat.com>
63096         strtoumax: fix typo in previous commit.
63097         * modules/strtoumax (Depends-on): Fix typo.
63098         * modules/strtoimax (Depends-on): Likewise.
63100 2013-10-10  Paul Eggert  <eggert@cs.ucla.edu>
63102         strtoumax: port to Solaris 8
63103         This problem was introduced in the recent HP-UX patch.
63104         Reported by Tom G. Christensen in
63105         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00037.html>.
63106         * modules/strtoumax (Depends-on): Test HAVE_STRTOUMAX
63107         and REPLACE_STRTOUMAX rather than ac_cv_func_strtoumax.
63109 2013-10-09  Paul Eggert  <eggert@cs.ucla.edu>
63111         strtoimax, strtoumax: port to HP-UX 11.11
63112         Problem reported by Daniel Richard G. in
63113         <http://lists.gnu.org/r/bug-gnulib/2013-10/msg00023.html>.
63114         * lib/inttypes.in.h (strtoumax): Replace strtoumax if
63115         REPLACE_STRTOUMAX, thus treating it consistently with strtoimax.
63116         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Add default for
63117         REPLACE_STRTOUMAX.
63118         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX):
63119         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX):
63120         Replace the function if defined as a macro but not as a function.
63121         * modules/inttypes-incomplete (inttypes.h): Substitute
63122         REPLACE_STRTOUMAX.
63123         * modules/strtoumax (configure.ac): Replace strtoumax if
63124         REPLACE_STRTOUMAX.
63126 2013-10-08  Paul Eggert  <eggert@cs.ucla.edu>
63128         strtoimax: port to HP-UX 11.11
63129         Problem reported by Daniel Richard G.
63130         * lib/strtoimax.c (Strtoimax, Strtol, Strtoll): New macros.
63131         (strtoimax, strtol, strtoll) [UNSIGNED]: Remove, since
63132         they might clash with inttypes.h.
63134 2013-10-06  Paul Eggert  <eggert@cs.ucla.edu>
63136         New module 'count-trailing-zeros'.
63137         * MODULES.html.sh: Mention it.
63138         * lib/count-trailing-zeros.c, lib/count-trailing-zeros.h:
63139         * m4/count-trailing-zeros.m4, modules/count-trailing-zeros:
63140         * modules/count-trailing-zeros-tests:
63141         * tests/test-count-trailing-zeros.c:
63142         New files.
63144         count-leading-zeros: port to MSC; support types wider than 64 bits
63145         The ideas behind the MSC port are stolen from Emacs.
63146         * lib/count-leading-zeros.h:
63147         Don't include verify.h: it's no longer needed, as types wider than
63148         64 bits are now supported.
63149         (COUNT_LEADING_ZEROS): New arg MSC_BUILTIN, for better
63150         performance with MSC.  All uses changed.  Do not assume that TYPE
63151         has at most 64 bits.
63152         (count_leading_zeros_32): Assume 0 < X < 2**32, for speed.
63153         All uses changed.  Fold the subtraction from 31 into the table.
63155         count-one-bits: port to MSC; support types wider than 64 bits
63156         The ideas behind the MSC port are stolen from Emacs.
63157         * lib/count-one-bits.c (popcount_support) [_MSC_VER]: New variable.
63158         * lib/count-one-bits.h: Include limits.h, for CHAR_BIT.
63159         Don't include verify.h: it's no longer needed, as types wider than
63160         64 bits are now supported.
63161         (COUNT_ONE_BITS_GENERIC): New macro.
63162         (popcount_supported) [_MSC_VER]: New inline function.
63163         (COUNT_ONE_BITS): Use it.  New arg MSC_BUILTIN, for better
63164         performance with MSC.  All uses changed.  Do not assume that TYPE
63165         has at most 64 bits.
63166         * modules/count-one-bits (Depends-on): Do not depend on 'verify'.
63168 2013-10-06  Andrew Borodin  <aborodin@vmail.ru>
63170         mountlist: fix resource leak with MOUNTED_INTERIX_STATVFS
63171         * lib/mountlist.c (read_file_system_list): fix leak of directory
63172         streams in case of #ifdef MOUNTED_INTERIX_STATVFS.
63174 2013-10-06  Paul Eggert  <eggert@cs.ucla.edu>
63176         tests: improve diagnostic when an assertion fails
63177         * tests/macros.h (ASSERT): Report the assertion that failed.
63179 2013-10-02  Paul Eggert  <eggert@cs.ucla.edu>
63181         verify: new macro 'assume'
63182         This is taken from Emacs, and should be generally useful.
63183         * doc/verify.texi (assume): Document it.
63184         * lib/verify.h (assume): New macro.
63185         (__has_builtin): Expand to 0 if not defined.
63187 2013-09-26  Eric Blake  <eblake@redhat.com>
63189         dup2, dup3: work around another cygwin crasher
63190         * m4/dup2.m4 (gl_FUNC_DUP2): Expose the bug.
63191         * m4/dup3.m4 (gl_FUNC_DUP3): Likewise.
63192         * tests/test-dup2.c (main): Likewise.
63193         * lib/dup2.c (rpl_dup2): Use setdtablesize to avoid it.
63194         * lib/dup3.c (dup3): Likewise.
63195         * doc/posix-functions/dup2.texi (dup2): Document it.
63196         * doc/glibc-functions/dup3.texi (dup3): Likewise.
63198         getdtablesize: work around cygwin issue
63199         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Detect problem.
63200         * modules/getdtablesize (configure.ac): Build replacement.
63201         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set up a witness.
63202         * modules/unistd (Makefile.am): Expose the witness.
63203         * lib/unistd.in.h (getdtablesize): Declare replacement.
63204         * lib/getdtablesize.c (rpl_getdtablesize): Work around it.
63205         * tests/test-getdtablesize.c (main): Test it.
63206         * doc/glibc-functions/getdtablesize.texi (getdtablesize): Document it.
63208 2013-09-25  Mats Erik Andersson  <gnu@gisladisker.se>
63210         pmccabe2html: escaping of special characters
63211         Escape all '<', '>', and '&' in HTML output.
63212         * build-aux/pmccabe2html (html_fnc): Call gsub()
63213         instead of sub() to capture all '<', '>', and '&'.
63214         Neither of '<' and '>' is special in a regexp,
63215         so first arguments to gsub() are corrected. Also,
63216         in replacement strings, ampersand must be escaped.
63217         Finally, '&' must be handled first, then '<' and '>'.
63219 2013-09-24  Eric Blake  <eblake@redhat.com>
63221         manywarnings: enable nicer gcc warning messages
63222         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Older gcc requires
63223         some -f options for optimal warnings.
63225 2013-09-21  Jim Meyering  <meyering@fb.com>
63227         timespec: use the new TIMESPEC_RESOLUTION in a few more places
63228         * lib/timespec-add.c (timespec_add): Also replace 999999999
63229         with TIMESPEC_RESOLUTION - 1.
63230         * lib/timespec-sub.c (timespec_sub): Likewise.
63232 2013-09-23  Paul Eggert  <eggert@cs.ucla.edu>
63234         warnings: port --enable-gcc-warnings to Solaris Studio 12.3
63235         Problem reported by Dagobert Michelsen via Eric Blake in
63236         <http://lists.gnu.org/r/bug-gnulib/2013-09/msg00052.html>.
63237         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Use AC_LINK_IFELSE,
63238         not AC_COMPILE_IFELSE.
63240 2013-09-23  Eric Blake  <eblake@redhat.com>
63242         configmake: support new --runstatedir option
63243         * m4/configmake.m4 (gl_CONFIGMAKE_PREP): Substitute runstatedir
63244         even if autoconf was too old to provide the command line option.
63245         * modules/configmake (Makefile.am): Propagate it to .h file.
63247 2013-09-22  Paul Eggert  <eggert@cs.ucla.edu>
63249         ctype, string: depend on extern-inline
63250         This is needed to complete the recent OS X fixes.
63251         Also, fix related documentation as suggested by Eric Blake.
63252         * doc/posix-functions/isalnum.texi, doc/posix-functions/isalpha.texi:
63253         * doc/posix-functions/isascii.texi, doc/posix-functions/iscntrl.texi:
63254         * doc/posix-functions/isdigit.texi, doc/posix-functions/isgraph.texi:
63255         * doc/posix-functions/islower.texi, doc/posix-functions/isprint.texi:
63256         * doc/posix-functions/ispunct.texi, doc/posix-functions/isspace.texi:
63257         * doc/posix-functions/isupper.texi, doc/posix-functions/isxdigit.texi:
63258         * doc/posix-functions/toascii.texi, doc/posix-functions/tolower.texi:
63259         * doc/posix-functions/toupper.texi:
63260         List the 'ctype' gnulib module.
63261         * doc/posix-functions/strcat.texi, doc/posix-functions/strcpy.texi:
63262         * doc/posix-functions/strncpy.texi:
63263         List the 'string' gnulib module.
63264         * modules/memcpy, modules/memmove, modules/memset (Depends-on):
63265         Add string.
63266         * modules/ctype, modules/string (Depends-on): Add extern-inline.
63268 2013-09-19  Pádraig Brady  <P@draigBrady.com>
63270         userspec: support optional parameters to parse_user_spec()
63271         * lib/userspec.c (parse_user_spec): If the GID param is NULL,
63272         then avoid group processing and treat the full spec as a user.
63273         (parse_with_separator): Allow the USERNAME and GROUPNAME to
63274         be optional params (NULL), in which case they're ignored.
63276 2013-09-19  Paul Eggert  <eggert@cs.ucla.edu>
63278         timespec: new function make_timespec, and new constants
63279         * lib/timespec.h: Incorporate recent changes on the Emacs trunk.
63280         (TIMESPEC_RESOLUTION, LOG10_TIMESPEC_RESOLUTION): New constants.
63281         (make_timespec): New function.
63282         * lib/dtotimespec.c (dtotimespec):
63283         * lib/timespec-add.c (timespec_add):
63284         * lib/timespec-sub.c (timespec_sub):
63285         * lib/utimens.c (validate_timespec):
63286         * lib/utimensat.c (rpl_utimensat):
63287         Use these new constants and functions.
63289         stdio: OS X port of putc_unlocked + extern inline
63290         * lib/stdio.in.h (putc_unlocked): #undef on problematic Apple platforms.
63291         * doc/posix-functions/putc_unlocked.texi:
63292         * doc/posix-functions/putchar_unlocked.texi:
63293         Document this portability problem.
63295         signal: OS X port of sigaddset etc. + extern inline
63296         * lib/signal.in.h (sigaddset, sigdelset, sigemptyset, sigfillset)
63297         (sigismember): #undef on problematic Apple platforms.
63298         * doc/posix-functions/sigaddset.texi:
63299         * doc/posix-functions/sigdelset.texi:
63300         * doc/posix-functions/sigemptyset.texi:
63301         * doc/posix-functions/sigfillset.texi:
63302         * doc/posix-functions/sigismember.texi:
63303         Document this portability problem.
63305         extern-inline: do not always suppress extern inline on OS X
63306         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Suppress the use of
63307         extern inline on Apple only if the particular compile-time
63308         configuration is known to have the problem.
63309         (_GL_EXTERN_INLINE_APPLE_BUG): New private macro, to implement this.
63310         (_GL_EXTERN_INLINE_IN_USE): New macro, intended for use by
63311         other Gnulib modules.
63313         extern-inline: document fixes for ctype and wctype macros
63314         * doc/posix-functions/isalnum.texi, doc/posix-functions/isalpha.texi:
63315         * doc/posix-functions/isascii.texi, doc/posix-functions/isblank.texi:
63316         * doc/posix-functions/iscntrl.texi, doc/posix-functions/isdigit.texi:
63317         * doc/posix-functions/isgraph.texi, doc/posix-functions/islower.texi:
63318         * doc/posix-functions/isprint.texi, doc/posix-functions/ispunct.texi:
63319         * doc/posix-functions/isspace.texi, doc/posix-functions/isupper.texi:
63320         * doc/posix-functions/iswalnum.texi, doc/posix-functions/iswalpha.texi:
63321         * doc/posix-functions/iswcntrl.texi, doc/posix-functions/iswctype.texi:
63322         * doc/posix-functions/iswdigit.texi, doc/posix-functions/iswgraph.texi:
63323         * doc/posix-functions/iswlower.texi, doc/posix-functions/iswprint.texi:
63324         * doc/posix-functions/iswpunct.texi, doc/posix-functions/iswspace.texi:
63325         * doc/posix-functions/iswupper.texi, doc/posix-functions/iswxdigit.texi:
63326         * doc/posix-functions/isxdigit.texi, doc/posix-functions/toascii.texi:
63327         * doc/posix-functions/memcpy.texi, doc/posix-functions/memmove.texi:
63328         * doc/posix-functions/memset.texi, doc/posix-functions/stpcpy.texi:
63329         * doc/posix-functions/stpncpy.texi, doc/posix-functions/strcat.texi:
63330         * doc/posix-functions/strcpy.texi, doc/posix-functions/strncat.texi:
63331         * doc/posix-functions/strncpy.texi:
63332         * doc/posix-functions/tolower.texi, doc/posix-functions/toupper.texi:
63333         * doc/posix-functions/towlower.texi, doc/posix-functions/towupper.texi:
63334         Document that Gnulib fixes portability problems with these
63335         functions on OS X 10.8 and earlier when called from plain inline
63336         or extern inline functions.
63338 2013-09-17  Kevin Cernekee  <cernekee@gmail.com>
63340         fflush, freadahead, fseeko: Fix for Android
63341         Suggested by Bruno Haible in:
63342         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00306.html>
63343         * lib/stdio-impl.h: Use local __sfileext definition.
63345 2013-09-17  Mats Erik Andersson  <gnu@gisladisker.se>
63347         pmccabe2html: Portability to other awk versions.
63348         The functions systime() and strftime() are available
63349         in Gawk only.  Properly close two HTML-tags 'style'
63350         and 'span'.
63351         * build-aux/pmccabe2html (BEGIN): Store timing
63352         strings in EPOCH_TIME and CHRONOS_TIME.  Replace
63353         systime() in HTML_COMMENT.
63354         (html_header): Correctly close tag 'style'.
63355         (END): Replace strftime() by CHRONOS_TIME.  Close
63356         tag 'span' correctly, not as 'div'.
63358 2013-09-17  Mats Erik Andersson  <gnu@gisladisker.se>  (tiny change)
63360         getgroups: statement without effect
63361         * lib/getgroups.c (rpl_getgroups) [HAVE_GETGROUPS]:
63362         Change equality conditional to expected assignment.
63364 2013-09-09  Eric Blake  <eblake@redhat.com>
63366         glob: fix compilation
63367         * lib/glob.in.h (__THROW): Fix missing line in previous commit.
63369 2013-09-07  Eric Blake  <eblake@redhat.com>
63371         glob: fix build for platforms without __THROW
63372         * lib/glob.in.h (__THROW): Add definition again.
63374 2013-09-04  Anton Ovchinnikov  <revolver112@gmail.com>  (tiny change)
63376         regex-quote: fix buffer access out of bounds
63377         http://lists.gnu.org/r/bug-gnulib/2013-09/msg00001.html
63378         * lib/regex-quote.c (regex_quote_spec_pcre):
63379         Fix typo that resulted in an out-of-bounds read.
63381 2013-09-04  Eric Blake  <eblake@redhat.com>
63383         glob: avoid -Wattribute warnings on glibc
63384         * lib/glob.c (next_brace_sub, prefix_array, collated_compare): Use
63385         __THROWNL, not __THROW, on static functions.
63386         * lib/glob.in.h (__THROW): Adjust...
63387         (__THROWNL): ...accordingly.
63389 2013-08-28  Paul Eggert  <eggert@cs.ucla.edu>
63391         headers: check that _GL_INLINE_HEADER_BEGIN is defined
63392         Suggested by Bruce Korb in:
63393         http://lists.gnu.org/r/bug-gnulib/2013-08/msg00070.html
63394         * doc/extern-inline.texi (extern inline):
63395         Suggest checking that _GL_INLINE_HEADER_BEGIN is defined.
63396         * lib/acl-internal.h, lib/argp-fmtstream.h, lib/argp.h:
63397         * lib/binary-io.h, lib/bitrotate.h, lib/count-leading-zeros.h:
63398         * lib/count-one-bits.h, lib/eealloc.h, lib/execinfo.in.h:
63399         * lib/gethrxtime.h, lib/gl_list.h, lib/gl_oset.h, lib/gl_xlist.h:
63400         * lib/gl_xoset.h, lib/gl_xsublist.h, lib/glthread/cond.h:
63401         * lib/glthread/thread.h, lib/math.in.h, lib/mbchar.h, lib/mbfile.h:
63402         * lib/mbiter.h, lib/mbuiter.h, lib/openat.h, lib/pipe-filter-aux.h:
63403         * lib/priv-set.h, lib/pthread.in.h, lib/savewd.h, lib/se-context.in.h:
63404         * lib/se-selinux.in.h, lib/sig-handler.h, lib/stat-time.h:
63405         * lib/sys_socket.in.h, lib/timespec.h, lib/u64.h, lib/unistd.in.h:
63406         * lib/utimens.h, lib/wctype.in.h, lib/xalloc.h, lib/xsize.h:
63407         * lib/xtime.h:
63408         Check that _GL_INLINE_HEADER_BEGIN is defined.
63410 2013-08-29  Pádraig Brady  <P@draigBrady.com>
63412         bootstrap: remove the --version requirement from ancillary tools
63413         * build-aux/bootstrap (check_exists): A new refactored function to
63414         determine if a command exists.
63415         (find_tool): Use the new function which does not require the
63416         --version option to be supported.
63417         (check_versions): Use the new function.
63419 2013-08-26  Simon Josefsson  <simon@josefsson.org>
63421         gc: support HMAC-SHA256 and HMAC-SHA512.
63422         * lib/gc.h: Add gc_hmac_sha256 and gc_hmac_sha512.
63423         * lib/gc-libgcrypt.c (gc_hmac_sha256, gc_hmac_sha512): New
63424         functions.
63425         (gc_hmac_md5): Use symbolic constant.
63426         * lib/gc-gnulib.c: Include hmac.h for HMAC-SHA256/512 too.
63427         (gc_hmac_sha256, gc_hmac_sha512): New functions.
63428         * lib/hmac.h: Add hmac_sha256 and hmac_sha512 prototypes.
63429         * m4/sha256.m4: Protect against empty expansion.
63430         * m4/sha512.m4: Likewise.
63431         * lib/hmac-sha256.c: New file.
63432         * lib/hmac-sha512.c: Likewise.
63433         * m4/gc-hmac-sha256.m4: Likewise.
63434         * m4/gc-hmac-sha512.m4: Likewise.
63435         * m4/gc-sha256.m4: Likewise.
63436         * m4/gc-sha512.m4: Likewise.
63437         * modules/crypto/gc-hmac-sha256: Likewise.
63438         * modules/crypto/gc-hmac-sha256-tests: Likewise.
63439         * modules/crypto/gc-hmac-sha512: Likewise.
63440         * modules/crypto/gc-hmac-sha512-tests: Likewise.
63441         * modules/crypto/hmac-sha256: Likewise.
63442         * modules/crypto/hmac-sha256-tests: Likewise.
63443         * modules/crypto/hmac-sha512: Likewise.
63444         * modules/crypto/hmac-sha512-tests: Likewise.
63445         * tests/test-gc-hmac-sha256.c: Likewise.
63446         * tests/test-gc-hmac-sha512.c: Likewise
63447         * tests/test-hmac-sha256.c: Likewise.
63448         * tests/test-hmac-sha512.c: Likewise
63450 2013-08-24  Daiki Ueno  <ueno@gnu.org>
63452         * m4/intl.m4: Update from gettext-0.18.3.1, which fixes a misuse
63453         of AC_CHECK_DECLS.
63455 2013-08-23  Paul Eggert  <eggert@cs.ucla.edu>
63457         selinux-at: omit unnecessary include
63458         * lib/selinux-at.c: Don't include dosname.h; not needed, since
63459         this source file doesn't use its macros, and subsidiary files that
63460         use the macros already include it.
63462 2013-08-21  Eric Blake  <eblake@redhat.com>
63464         d-ino: avoid false negative on symlink
63465         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use lstat.
63466         Reported by Stephane Chazelas.
63468 2013-08-12  Mike Miller  <mtmiller@ieee.org>  (tiny change)
63470         bootstrap: port to OpenBSD sed
63471         * build-aux/bootstrap (insert_if_absent): Port to OpenBSD sed which
63472         does not interpret `-' as a file argument to mean stdin.
63474 2013-08-15  Eric Blake  <eblake@redhat.com>
63476         warnings: minor optimization
63477         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): Use fewer processes.
63479         warnings: check -Wfoo rather than -Wno-foo
63480         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): If name begins with
63481         -Wno-, test if the compiler recognizes the positive form instead.
63483 2013-08-15  Karl Berry  <karl@gnu.org>
63485         * config/srclist-update: add option "doclicense" to placate
63486         pulling *.texi files from Emacs.  Write terse usage
63487         documentation at the top.
63489 2013-08-13  Paul Eggert  <eggert@cs.ucla.edu>
63491         xvasprintf-tests: port to GCC with hardening flags
63492         * tests/test-xvasprintf.c (test_xasprintf): Pass another arg to
63493         xasprintf, to pacify GCC.  Reported by Santiago Vila in:
63494         http://lists.gnu.org/r/bug-diffutils/2013-08/msg00002.html
63496 2013-08-11  Paul Eggert  <eggert@cs.ucla.edu>
63498         fpending: port to recent Cygwin change to stdio_ext.h
63499         Reported by LRN in
63500         <http://lists.gnu.org/r/bug-gnulib/2013-08/msg00028.html>.
63501         * lib/fpending.h: Don't worry about HAVE_DECL___FPENDING;
63502         just declare __fpending unless it's a macro.
63503         A duplicate decl shouldn't hurt.
63504         * m4/fpending.m4 (gl_FUNC_FPENDING): Check that an __fpending
63505         call compiles and links, instead of separately checking for
63506         decl and lib function.
63507         * modules/fpending (configure-ac):
63508         Adjust to fpending.m4's renaming of shell variable.
63510 2013-08-10  Paul Eggert  <eggert@cs.ucla.edu>
63512         sys_time: port to OpenBSD
63513         * lib/sys_time.in.h: Simply delegate to the system's header
63514         in the BSDish cases as well.  Problem reported by Mike Miller in
63515         <http://lists.gnu.org/r/bug-gnulib/2013-08/msg00016.html>.
63516         * tests/test-sys_select.c, tests/test-sys_time.c (verify_tv_sec_type):
63517         Allow platforms like 64-bit OpenBSD where timeval's tv_sec is
63518         wider than time_t.
63520 2013-08-09  Pádraig Brady  <P@draigBrady.com>
63522         bootstrap: support checksum utils having -c but not --status
63523         * build-aux/bootstrap: Only look for sha1sum if updating po files.
63524         Add sha1 to the list of supported checksum utils since it's now
63525         supported through adjustments below.
63526         (update_po_files): Remove the use of --status
63527         in a way that will suppress all error messages, but since this is
63528         only used to minimize updates, it shouldn't cause an issue.
63529         Exit early if there is a problem updating the po file checksums.
63530         (find_tool): Remove the check for --version support as this
63531         is optional as per commit 86186b17.  Don't even check for the
63532         presence of the command as if that is needed, it's supported
63533         through configuring prerequisites in bootstrap.conf.
63534         Prompt that when a tool isn't found, one can define an environment
63535         variable to add to the hardcoded search list.
63537 2013-08-05  Jim Meyering  <meyering@fb.com>
63539         regex: port to non-glibc/lock-using systems
63540         Since 29-05-2013 commit, 55ba71f4, compilation on a non-glibc
63541         system with GNULIB_LOCK would fail due to absence of the
63542         included "glthread/lock.h".  This would affect any package
63543         for which the "lock" module is used only by the regex module,
63544         and not explicitly used.
63545         * m4/regex.m4 (gl_PREREQ_REGEX): Require gl_GLIBC21.
63546         * modules/regex (Depends-on) [!GLIBC && $ac_use_included_regex]:
63547         Add a dependency on the "lock" module.
63549 2013-07-20  Daiki Ueno  <ueno@gnu.org>
63551         localecharset: make locale_charset thread-safe on Mac OS X
63552         * lib/localcharset.c (locale_charset) [DARWIN7]: Use MB_CUR_MAX_L
63553         instead of MB_CUR_MAX.
63555 2013-07-20  Daiki Ueno  <ueno@gnu.org>
63557         gettext: update to version 0.18.3
63558         * m4/intl.m4, m4/po.m4: Update from gettext-0.18.3.  In particular,
63559         require AC_PROG_SED to allow user to specify custom sed command when
63560         generating en@quot PO file.
63562 2013-07-18  Werner Lemberg  <wl@gnu.org>  (tiny change)
63564         bootstrap: use correct source when copying build-aux files
63565         * build-aux/bootstrap (gnulib_extra_files): This variable is
63566         relative to upstream gnulib layout, not downstream.
63568 2013-07-17  Paul Eggert  <eggert@cs.ucla.edu>
63570         tmpdir: fix bug in VMS port
63571         * lib/tmpdir.c (path_search) [__VMS]: Never add slash.
63572         See Steven M. Schweda in
63573         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00026.html>.
63575 2013-07-15  Paul Eggert  <eggert@cs.ucla.edu>
63577         tmpdir: port to VMS, to // != /, and to long dirs
63578         * lib/tmpdir.c (__libc_secure_getenv) [!_LIBC]: Rename from
63579         __secure_getenv, so that we're more like the glibc version.
63580         All uses changed.
63581         (path_search): Don't put slash after directory if __VMS.
63582         Problem reported by Steven M. Schweda in
63583         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00019.html>.
63584         Simplify code to add slash; no need for a loop.
63585         Do not remove trailing slash from "//".
63586         Do not assume dlen <= INT_MAX.
63588 2013-07-09  Paul Eggert  <eggert@cs.ucla.edu>
63590         regex: port to --with-included-regex --enable-gcc-warnings non-threaded
63591         * lib/regex_internal.h (lock_fini, lock_lock): Rework to avoid
63592         gcc warnings in the non-threaded case.  Reported by Charlie Brown in
63593         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00015.html>.
63595         accept4, dup3, pipe2: port to Cygwin
63596         Problem reported for Emacs by Ken Brown in <http://bugs.gnu.org/14821>.
63597         * lib/accept4.c (accept4) [O_BINARY]:
63598         * lib/dup3.c (dup3) [O_BINARY]:
63599         * lib/pipe2.c (pipe2) [O_BINARY]:
63600         Use set_binary_mode, not setmode.
63601         * lib/pipe2.c [!GNULIB_BINARY_IO]: Include binary-io.h.
63602         * modules/binary-io (Depends-on): Remove module indicator.
63603         These last two bits undo the previous change to pipe2 and binary-io.
63605 2013-07-09  Pádraig Brady  <P@draigBrady.com>
63607         mountlist: add support for deallocating returned list entries
63608         * lib/mountlist.c (free_mount_entry): A new exported function
63609         to deallocate a mount list entry.
63610         (read_file_system_list): Refactor to use the new deallocation function.
63611         Suggested by Anton Ovchinnikov.
63613 2013-07-07  Paul Eggert  <eggert@cs.ucla.edu>
63615         stdalign, verify: port to FreeBSD 9.1, to C11, and to C++11
63616         Problem reported by Ulrich Mueller in <http://bugs.gnu.org/14812>.
63617         * lib/stdalign.in.h (_Alignas, _Alignof):
63618         Port to FreeBSD 9.1, and to C11 and C++11.
63619         (_Alignas): Also support ICC.
63620         * lib/verify.h (_Static_assert): Undef if <stddef.h> defines it.
63621         * m4/stdalign.m4 (gl_STDALIGN_H): Port to ICC and to C++11.
63623 2013-07-06  Paul Eggert  <eggert@cs.ucla.edu>
63625         fnmatch: don't goto over declaration
63626         * lib/fnmatch_loop.c (FCT): Hoist local up one level, to avoid
63627         undefined behavior for goto over a declaration.
63628         Problem reported by Charlie Brown in
63629         <http://lists.gnu.org/r/bug-gnulib/2013-07/msg00009.html>.
63631         pipe2: decouple from binary-io a bit
63632         This is for Emacs, which needs pipe2 but not binary-io.
63633         * lib/pipe2.c [!GNULIB_BINARY_IO]: Don't include binary-io.h.
63634         * modules/binary-io (Depends-on): Add module indicator.
63636 2013-07-03  Eric Blake  <eblake@redhat.com>
63638         mgetgroups: relax license to LGPLv2+
63639         * modules/getugroups (License): Change from GPLv3+.
63640         * modules/mgetgroups (License): Likewise.
63641         * modules/getgroups (License): Change from LGPLv3+.
63643         xalloc-oversized: relax license to LGPLv2+
63644         * modules/xalloc-oversized (License): Change from GPLv3+.
63646         nproc: relax license to LGPLv2+
63647         * modules/nproc (License): Change from LGPLv3+.
63649         bootstrap: honor --no-git
63650         * build-aux/bootstrap: Don't even try to use git when user is
63651         pointing to a static checkout.
63653 2013-06-23  Paul Eggert  <eggert@cs.ucla.edu>
63655         ignore-value: port to gcc -pedantic
63656         * lib/ignore-value.h (ignore_value):
63657         Port to gcc -pedantic, by using __extension__.
63658         Reindent as per usual gnulib style nowadays.
63659         Simplify GCC version check.
63661 2013-06-21  Paul Eggert  <eggert@cs.ucla.edu>
63663         extern-inline: port to gcc -std=c89
63664         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
63665         Do not use __gnu_inline__ if pedantic and pre-C99.
63667 2013-06-18  Paul Eggert  <eggert@cs.ucla.edu>
63669         doc: document extern-inline
63670         * doc/extern-inline.texi: New file.
63671         * doc/gnulib.texi (alloca-opt): Include it.
63672         * m4/extern-inline.m4: Move some comments to documentation,
63673         and others closer to what they describe.
63675         doc: chatter less
63676         * doc/Makefile (NEWEST_GNULIB_TEXI_FILE): New macro.
63677         (updated-stamp): Use it.  This causes 'make' to output just
63678         one file name rather than zillions.
63680         fflush, fseeko: port to musl cross-compiles
63681         * lib/fseeko.c (fseeko): Assume that fflushing stdin works if
63682         on some implementation that (1) is not known to be buggy,
63683         (2) claims conformance to POSIX.1-2008 or later, and (3) is being
63684         cross-compiled to so we can't easily check for lack of
63685         conformance.  This is for cross-compiling to musl.
63686         Reported by Rich Felker in
63687         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00043.html>.
63688         * m4/fclose.m4 (gl_FUNC_FCLOSE):
63689         * m4/fflush.m4 (gl_FUNC_FFLUSH):
63690         * m4/fseeko.m4 (gl_FUNC_FSEEKO):
63691         Adjust to above change.
63692         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): Set gl_cv_func_fflush_stdin
63693         to 'cross', not to 'no', when cross-compiling.  AC_DEFINE
63694         FUNC_FFLUSH_STDIN to 1, 0, -1 if fflushing stdin is known to work,
63695         known not to work, or unknown.
63697 2013-06-15  Paul Eggert  <eggert@cs.ucla.edu>
63699         msvc-inval: port to mingw-w64
63700         * lib/msvc-inval.c (gl_msvc_invalid_parameter_handler):
63701         Use __cdecl, not cdecl, for mingw-w64.  Reported by LRN in
63702         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00039.html>.
63704 2013-06-11  Paul Eggert  <eggert@cs.ucla.edu>
63706         getcwd-lgpl: port to Tru64
63707         * lib/getcwd-lgpl.c: Include <stdlib.h>, for malloc etc.
63708         Problem reported by Steven M. Schweda in
63709         <http://lists.gnu.org/r/bug-gzip/2013-06/msg00010.html>.
63711         tests: port large-fd POSIX spawn tests to OS X
63712         Problem reported by Daiki Ueno in
63713         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00031.html>.
63714         * tests/test-posix_spawn_file_actions_addclose.c:
63715         * tests/test-posix_spawn_file_actions_adddup2.c:
63716         * tests/test-posix_spawn_file_actions_addopen.c:
63717         Include <limits.h>, for OPEN_MAX, if available.
63718         (big_fd): New static function.
63719         (main): Use it.
63721 2013-06-04  Bernhard Voelker  <mail@bernhard-voelker.de>
63723         tests/nap.h: use an adaptive delay to avoid ctime update issues
63724         The recent change in nap.h (5191133e) decreased the probability of lost
63725         races to about a third, however such problems could still be observed
63726         in virtual machines and openSUSE's OBS.
63727         Before, nap() detected the needed time once empirically and then used
63728         that delay (together with a small correction multiplier) in further
63729         calls.  This problem has been reported and discussed several times,
63730         including guesses about possible kernel issues:
63731         https://lists.gnu.org/r/bug-gnulib/2013-04/msg00071.html
63732         http://lists.gnu.org/r/coreutils/2012-03/msg00088.html
63733         https://lists.gnu.org/r/bug-gnulib/2011-11/msg00226.html
63734         http://bugs.gnu.org/12820
63735         https://lists.gnu.org/r/bug-gnulib/2010-11/msg00113.html
63736         https://lists.gnu.org/r/bug-gnulib/2009-11/msg00007.html
63737         Now, nap() avoids the race alltogether by verifying on a reference
63738         file whether a timestamp difference has happened.
63739         * tests/nap.h (nap_fd): Define file descriptor variable for the
63740         witness file.
63741         (nap_works): Change return value to bool.  Change passing
63742         the old file's status by value instead of by reference as this function
63743         does no longer update that timestamp; rename the function argument from
63744         st to old_st.  Remove the local variables cdiff and mdiff because that
63745         function now returns true/false instead of the precise delay.
63746         (guess_delay): Remove function.
63747         (clear_tmp_file): Add new function to close and unlink the witness file.
63748         (nap): Instead of re-using the delay which has been calculated during
63749         the first call, avoid the race by actually verifying that a timestamp
63750         difference can be observed on the current file system.  Use an adaptive
63751         approach for the delay to minimize execution time.  Assert that the
63752         maximum delay is <= ~2 seconds, more precisely sum(2^n) from 0 to 30
63753         = 2^31 - 1 = 2.1s.
63754         Use atexit to call clear_tmp_file when the process terminates.
63756 2013-06-02  Paul Eggert  <eggert@cs.ucla.edu>
63758         sig2str: port to C++
63759         * lib/sig2str.h (sig2str, str2sig): Declare as extern "C".
63760         Reported by Daniel J Sebald in
63761         <http://lists.gnu.org/r/bug-gnulib/2013-06/msg00000.html>.
63763 2013-05-30  Eric Blake  <eblake@redhat.com>
63765         docs: mention cygwin shortcoming in <sys/un.h>
63766         * doc/posix-headers/sys_un.texi (sys/un.h): Mention problem.
63768         vasnprintf: silence mingw compiler warning
63769         * lib/vasnprintf.c (VASNPRINTF): Avoid unused variable warning.
63771 2013-05-29  Paul Eggert  <eggert@cs.ucla.edu>
63773         c-ctype, regex, verify: port to gcc -std=c90 -pedantic
63774         Avoid constructions that are rejected by gcc -std=c90 -pedantic.
63775         This fixes a porting bug I recently reintroduced in regex, and
63776         some other instances that I discovered while testing the fix.
63777         * lib/c-ctype.h [__STRICT_ANSI__]: Avoid ({ ... }).
63778         * lib/regcomp.c (utf8_sb_map) [__STRICT_ANSI__]: Avoid [0 ... N] = E.
63779         * lib/regex_internal.h [!_LIBC && GNULIB_LOCK]: Do not use a macro
63780         with an empty argument if this is a pedantic pre-C99 GCC.
63781         * lib/verify.h: Do not use _Static_assert if this is a pedantic
63782         pre-C11 GCC.
63784         regex: adapt to locking regime instead of depending on pthread
63785         Instead of depending on pthread, adapt to whatever thread
63786         modules are in use.  Problem reported by Ludovic Courtès in
63787         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00082.html>
63788         and by Mats Erik Andersson in
63789         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00100.html>.
63790         * lib/regex_internal.h (lock_define, lock_init, lock_fini):
63791         Support either the 'lock' module, or the 'pthread' module, or
63792         no module.
63793         (lock_lock, lock_unlock): New macros.
63794         * lib/regexec.c (regexec, re_search_stub): Use the new macros.
63795         * modules/lock, modules/pthread (configure.ac): Add module indicator.
63796         * modules/regex (Depends-on): Remove pthread.
63798 2013-05-22  Eric Blake  <eblake@redhat.com>
63800         getgroups: document portability issues
63801         * doc/glibc-functions/initgroups.texi (initgroups): Mention
63802         multithread safety.
63803         * doc/posix-functions/getpwuid.texi (getpwuid): Likewise.
63804         * doc/posix-functions/getpwuid_r.texi (getpwuid_r): Likewise.
63805         * doc/glibc-functions/getgrouplist.texi (getgrouplist): Mention
63806         getugroups.
63807         * doc/posix-functions/getgroups.texi (getgroups): Mention
63808         multithread safety and mgetgroups.
63810 2013-05-22  Bernhard Voelker  <mail@bernhard-voelker.de>
63812         test-lchown, test-chown: also skip test if chown fails with EPERM
63813         * tests/test-lchown.h (test_lchown): Add EPERM to the condition to
63814         skip this test, to handle FAT file systems.
63815         * tests/test-chown.h (test_chown): Likewise.
63817 2013-05-19  Paul Eggert  <eggert@cs.ucla.edu>
63819         regex: fix dfa race in multithreaded uses
63820         Problem reported by Ludovic Courtès in
63821         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00058.html>.
63822         * lib/regex_internal.h (lock_define, lock_init, lock_fini):
63823         New macros.  All uses of __libc_lock_define, __libc_lock_init
63824         changed to use the first two of these.
63825         (__libc_lock_lock, __libc_lock_unlock): New macros, for
63826         non-glibc platforms.
63827         (struct re_dfa_t): Define the lock unconditionally.
63828         * lib/regexec.c (regexec, re_search_stub): Remove some now-incorrect
63829         '#ifdef _LIBC"s.
63830         * modules/regex (Depends-on): Add pthread, if we use the
63831         included regex.
63833         * lib/regcomp.c: Do actions that are not needed for glibc,
63834         but may be needed elsewhere.
63835         (regfree, re_compile_internal): Destroy the lock.
63836         (re_compile_internal): Check for lock-initialization failure.
63838         malloca: port to compilers that reject size-zero arrays
63839         This fixes a bug introduced in my previous patch.
63840         * lib/malloca.c (struct preliminary_header): Use an int
63841         rather than a character array of size int; that's simpler.
63842         (struct header): Remove, replacing with ...
63843         (union header): New type.  This avoids the need for declaring a
63844         character array of size zero, which is not allowed on some platforms.
63845         All uses changed.
63847 2013-05-18  Paul Eggert  <eggert@cs.ucla.edu>
63849         parse-datetime, tests: don't use "string" + int
63850         Recent versions of 'clang' complain about C source code that
63851         uses expressions of the form '"string literal" + integer',
63852         I guess on the theory that it's confusing for readers who are
63853         used to C++.  On those grounds I suppose it's OK to make this
63854         minor style change.
63855         * lib/parse-datetime.y (parse_datetime):
63856         * tests/test-fchdir.c (main):
63857         * tests/test-snprintf-posix.h (test_function):
63858         * tests/test-snprintf.c (main):
63859         * tests/test-vasnprintf-posix.c (test_function):
63860         * tests/test-vasnprintf.c (test_function):
63861         * tests/test-vsnprintf.c (main):
63862         * tests/unistdio/test-ulc-asnprintf1.h (test_function):
63863         Rewrite '"str" + E' to '&"str"[E]'.
63865 2013-05-17  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
63867         argmatch: port to C++
63868         * lib/argmatch.h [__cplusplus]: Add extern "C".
63870         argp: typo fix
63871         * lib/argp-help.c: Typo in comment.
63873 2013-05-15  Paul Eggert  <eggert@cs.ucla.edu>
63875         manywarnings: update for GCC 4.8.0
63876         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC):
63877         Add -Waggressive-loop-optimizations, -Wreturn-local-addr, which
63878         are new to GCC 4.8.  Remove -Wformat=2, -Wmissing-format-attribute,
63879         -Wmissing-noreturn, as they are duplicates of other warnings.
63880         Remove -Wunreachable-code, as it is removed in GCC 4.8 and
63881         was documented to be flaky in earlier versions of GCC.
63883         spawn-tests, sys_socket-tests, sys_wait-tests: port to clang
63884         * tests/test-spawn.c (main):
63885         * tests/test-sys_socket.c (main):
63886         * tests/test-sys_wait.c (main):
63887         Don't have a switch value that isn't covered by a case.
63889         getaddrinfo-tests: port --enable-gcc-warnings to clang
63890         * tests/test-getaddrinfo.c (simple):
63891         Avoid casts from looser to stricter-aligned pointers.
63893         thread: port --enable-gcc-warnings to clang
63894         * lib/glthread/thread.h [__clang__ && USE_POSIX_THREADS_WEAK]:
63895         Include <signal.h>, to pacify a warning about pthread_sigmask.
63897         stdio: use __REDIRECT for fwrite, fwrite_unlocked
63898         * lib/stdio.in.h (fwrite):
63899         When working around bug 11959, use __REDIRECT rather than '#define
63900         fwrite(...) ... fwrite (...) ...'.  This is a more-targeted way to
63901         fix the -Wunused-value issue with clang, and it works with GCC too.
63902         Problem with targeting reported by Eric Blake in
63903         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00067.html>.
63904         (fwrite_unlocked): Treat like fwrite.  I ran into this issue while
63905         debugging the fwrite issue.
63907         stdio: port --enable-gcc-warnings to clang
63908         * lib/stdio.in.h (fwrite) [__clang__]: Ignore -Wunused-value entirely,
63909         since the GCC workaround for fwrite does not pacify clang.
63911         sig2str: port --enable-gcc-warnings to clang
63912         * lib/sig2str.c (sig2str): Avoid warning about unused printf argument.
63914         obstack: port --enable-gcc-warnings to clang
63915         * lib/obstack.h (obstack_ptr_grow_fast, obstack_int_grow_fast):
63916         Avoid casts from looser to stricter-aligned pointers.
63918         memchr2: port --enable-gcc-warnings to clang
63919         * lib/memchr2.c (memchr2):
63920         Avoid casts from looser to stricter-aligned pointers.
63922         mbsstr: port --enable-gcc-warnings to clang
63923         * lib/mbsstr.c (knuth_morris_pratt_multibyte):
63924         Avoid casts from looser to stricter-aligned pointers.
63926         malloca: port --enable-gcc-warnings to clang
63927         * lib/malloca.c (struct header): New member 'magic', to avoid casts.
63928         (mmalloca): Avoid casts from looser to stricter-aligned pointers.
63930         inttostr: port --enable-gcc-warnings to clang
63931         * lib/anytostr.c [__clang__]: Ignore -Wtautological-compare.
63933         warnings: port to clang
63934         Problem reported by Daniel P. Berrange via Eric Blake in
63935         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00055.html>.
63936         * m4/warnings.m4 (gl_UNKNOWN_WARNINGS_ARE_ERRORS): New macro.
63937         (gl_WARN_ADD): Use it.
63939 2013-05-11  Jim Meyering  <meyering@fb.com>
63941         quotearg: do not read beyond end of buffer
63942         * lib/quotearg.c (quotearg_buffer_restyled): Do not read beyond the
63943         end of an ARG for which no length was specified.  With an N-byte
63944         quote string, (e.g., N is 3 in the fr_FR.UTF-8 locale), this function
63945         would read N-2 bytes beyond ARG's trailing NUL.  This was triggered
63946         via coreutils' misc/sort-debug-keys.sh test and detected by running
63947         the test against a binary compiled with gcc-4.8.0's -fsanitize=address.
63948         * tests/test-quotearg-simple.c (main): Add a test to trigger the bug.
63949         * modules/quotearg-simple-tests (Files): Add tests/zerosize-ptr.h.
63950         Introduced via the 2000-01-15 commit, c4b7f3f8, "Quote multibyte
63951         characters correctly."
63953 2013-05-11  Daiki Ueno  <ueno@gnu.org>
63955         lock: work around pthread recursive mutexes bug in Mac OS X 10.6
63956         * m4/lock.m4: Don't define HAVE_PTHREAD_MUTEX_RECURSIVE if the
63957         compilation target is Mac OS X 10.6.
63958         Problem reported by parafin and Andoni Morales in
63959         <http://savannah.gnu.org/bugs/?37844> and
63960         <http://lists.gnu.org/r/bug-gettext/2013-05/msg00007.html>.
63962 2013-05-11  Paul Eggert  <eggert@cs.ucla.edu>
63964         mkdir-p: remove assumptions about umask and mode
63965         * lib/mkdir-p.c (make_dir_parents): Do not assume that the current
63966         umask is 0, or that MODE is a subset of MODE_BITS.
63968 2013-05-10  Eric Blake  <eblake@redhat.com>
63970         maint.mk: catch more abuse of HAVE_DECL in syntax-check
63971         * top/maint.mk (sc_prohibit_defined_have_decl_tests): Relax regex.
63973 2013-05-10  Stefano Lattarini  <stefano.lattarini@gmail.com>
63975         deps: require Automake >= 1.9.6 in generated Makefile fragments
63977         That is the same minimal version required in the DEPENDENCIES file.
63978         Moreover, the old code generated a requirement of Automake >= 1.5,
63979         and that is an insanely outdated version.
63981         * gnulib-tool: Bump minimal version requirement in AUTOMAKE_OPTIONS.
63982         * tests/havelib/rpathlx/Makefile.am: Likewise.
63983         * tests/havelib/rpathly/Makefile.am: Likewise.
63984         * tests/havelib/rpathlyx/Makefile.am: Likewise.
63985         * tests/havelib/rpathlz/Makefile.am: Likewise.
63986         * tests/havelib/rpathlzyx/Makefile.am: Likewise.
63987         * tests/havelib/rpathx/Makefile.am: Likewise.
63988         * tests/havelib/rpathy/Makefile.am: Likewise.
63989         * tests/havelib/rpathz/Makefile.am: Likewise.
63991 2013-05-08  Eric Blake  <eblake@redhat.com>
63993         bootstrap: AC_INIT may have more than four parameters
63994         * build-aux/bootstrap (extract_package_name): Correctly extract
63995         non-empty tarname field.  Avoid range in regex.
63996         Based on a report by Sami Kerola <kerolasa@iki.fi>.
63998 2013-05-07  Paul Eggert  <eggert@cs.ucla.edu>
64000         qacl: port to MS-Windows port of GNU Emacs
64001         * lib/acl-errno-valid.c (acl_errno_valid) [ENOTSUP == ENOSYS]:
64002         Omit the duplicate ENOTSUP case.  Needed for the MS-Windows
64003         port of GNU Emacs.  Problem reported by Eli Zaretskii in
64004         <http://bugs.gnu.org/14295#14>.
64006 2013-05-07  Mike Frysinger  <vapier@gentoo.org>
64008         acl: include quote.h
64009         * lib/copy-acl.c: Include quote.h.
64010         * lib/set-acl.c: Likewise.
64012 2013-05-06  Mike Frysinger  <vapier@gentoo.org>
64014         fchownat, renameat, unlinkat: update statat dependencies
64015         These modules use statat and lstatat, not fstatat; so depend on
64016         the statat module, which was split out recently from fstatat.
64017         * modules/fchownat, modules/unlinkat: Change fstatat to statat.
64018         * modules/renameat: Likewise.  Also delete fstat.
64019         URL: http://bugs.gentoo.org/468790
64021 2013-05-04  Stefano Lattarini  <stefano.lattarini@gmail.com>
64023         Assume gnulib is checked out from Git, not CVS
64025         In fact, access to the gnulib repository through CVS has been
64026         disabled, or more precisely, got broken and was never restored; see:
64027         <http://lists.gnu.org/r/bug-gnulib/2013-05/msg00008.html>
64029         Note that support for CVS is not removed completely and unthinkingly
64030         by this change: only support for CVS checkouts of gnulib itself is
64031         removed.  For example, the 'bootstrap' script still cater to .cvsingore
64032         files and CVS directories, for the benefit of those poor gnulib clients
64033         still stuck with CVS.  Ditto for the 'gnulib-tool' script itself.
64035         * gnulib-tool: Simplify accordingly.
64036         * posix-modules: Likewise.
64037         * MODULES.html.sh: Likewise.
64038         * doc/gnulib.texi: No longer mention the decommissioned CVS gnulib
64039         repository.
64040         * doc/gnulib-intro.texi: Likewise.
64041         * doc/gnulib-readme.texi: Likewise.
64042         * doc/gnulib-tool.texi: In the examples and explanations, refer to a
64043         sample '.gitignore' file rather than a sample '.cvsignore'.
64044         * NEWS: Update.
64045         * m4/extensions.m4: While at it, remove a comment mistakenly referring
64046         to "CVS Autoconf" rather than "git Autoconf".
64048 2013-04-30  Paul Eggert  <eggert@cs.ucla.edu>
64050         utimensat-tests, etc.: try to fix some races
64051         Problem reported by Bernhard Voelker in
64052         <http://lists.gnu.org/r/bug-gnulib/2013-04/msg00071.html>.
64053         I don't know whether this patch fixes that race condition, but it
64054         fixes *some* race conditions, so it should be a win.
64055         * modules/chown-tests (Depends-on):
64056         * modules/fchownat-tests (Depends-on):
64057         * modules/fdutimensat-tests (Depends-on):
64058         * modules/futimens-tests (Depends-on):
64059         * modules/lchown-tests (Depends-on):
64060         * modules/stat-time-tests (Depends-on):
64061         * modules/utimens-tests (Depends-on):
64062         * modules/utimensat-tests (Depends-on):
64063         Depend on nanosleep, not usleep.
64064         * modules/chown-tests (test_chown_LDADD):
64065         * modules/lchown-tests (test_lchown_LDADD):
64066         * modules/stat-time-tests (test_stat_time_LDADD):
64067         New macro.
64068         * modules/fchownat-tests (test_fchownat_LDADD):
64069         * modules/fdutimensat-tests (test_fdutimensat_LDADD):
64070         * modules/futimens-tests (test_futimens_LDADD):
64071         * modules/utimens-tests (test_utimens_LDADD):
64072         * modules/utimensat-tests (test_utimensat_LDADD):
64073         Add $(LIB_NANOSLEEP).
64074         * modules/stat-time-tests (Files): Add tests/nap.h.
64075         * tests/nap.h: Include <limits.h>, for INT_MAX.
64076         (lt_mtime): Remove.
64077         (diff_timespec): New function.
64078         (get_stat): Rename from get_mtime.  All callers changed.
64079         (nap_works): Determine the needed delay by inspecting the
64080         file system's timestamp jumps; this should be more reliable.
64081         Look at both mtime and ctime, and take the maximum of the two jumps.
64082         (nap_works, guess_delay):
64083         Return a nanosecond count, not a microsecond count.
64084         All callers changed.
64085         (nap_works, nap): Use nanosleep, not usleep.  Check for nanosleep
64086         failure.
64087         (nap): Multiply the guess by 1.125, to accommodate the case where
64088         the file system's clock is a bit slower than nanosleep's clock.
64089         * tests/test-stat-time.c (BASE): New macro.
64090         Include nap.h.
64091         (nap): Remove; nap.h now defines this.  This removes a duplicate
64092         implementation of 'nap'.
64094         utimens, utimensat: work around Solaris UTIME_OMIT bug
64095         Solaris 11.1 and Solaris 10 have the same UTIME_OMIT bug that
64096         Linux kernel 2.6.32 does.  Work around it in the same way.
64097         * doc/posix-functions/futimens.texi (futimens):
64098         * doc/posix-functions/utimensat.texi (utimensat): Document the bug.
64099         * lib/utimens.c (fdutimens, lutimens):
64100         * lib/utimensat.c (rpl_utimensat): Work around the bug.
64102         gettext: now it's your responsibility to add -I$(top_builddir)/intl
64103         Formerly, it was your responsibility to do this for all Makefile.ams
64104         other than Gnulib's.  Now it's your responsibility to do it for
64105         Gnulib's Makefile.am, too.
64106         * NEWS: Document this.
64107         * modules/gettext (AM_CPPFLAGS): Don't append -$(top_builddir)/intl.
64109         acl: include errno.h to get errno
64110         Reported by Daiki Ueno in
64111         <http://lists.gnu.org/r/bug-gnulib/2013-04/msg00073.html>.
64112         * lib/copy-acl.c, lib/set-acl.c: Include errno.h.
64114 2013-04-29  Paul Eggert  <eggert@cs.ucla.edu>
64116         tests: don't assume getdtablesize () <= 10000000
64117         * modules/cloexec-tests:
64118         * modules/dup2-tests:
64119         * modules/dup3-tests:
64120         * modules/nonblocking-tests:
64121         * modules/posix_spawn_file_actions_addclose-tests:
64122         * modules/posix_spawn_file_actions_adddup2-tests:
64123         * modules/posix_spawn_file_actions_addopen-tests:
64124         * modules/unistd-safer-tests:
64125         Depend on the getdtablesize module.
64126         * tests/test-cloexec.c:
64127         * tests/test-dup-safer.c:
64128         * tests/test-dup2.c:
64129         * tests/test-dup3.c:
64130         * tests/test-fcntl.c:
64131         * tests/test-nonblocking.c:
64132         * tests/test-posix_spawn_file_actions_addclose.c:
64133         * tests/test-posix_spawn_file_actions_adddup2.c:
64134         * tests/test-posix_spawn_file_actions_addopen.c:
64135         Don't assume getdtablesize () <= 10000000.
64137 2013-04-28  Paul Eggert  <eggert@cs.ucla.edu>
64139         extern-inline: work around bug in Sun c99
64140         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE):
64141         Work around bug in Sun C 5.12 c99's implementation of 'inline'.
64143 2013-04-27  Paul Eggert  <eggert@cs.ucla.edu>
64145         qacl: new module, broken out from the acl module
64146         This is for GNU Emacs, which wants the acl functions but does
64147         not want 'error' invoked when they fail.
64148         * lib/acl-internal.h: Do not include error.h, quote.h.
64149         (ENOSYS, ENOTSUP): Remove; no longer needed.
64150         (ACL_NOT_WELL_SUPPORTED): Remove; replaced by acl_errno_valid.
64151         * lib/acl.h: Include <stdbool.h>.
64152         (acl_errno_valid): New function.
64153         * lib/copy-acl.c, lib/set-acl.c: Include errno,h, not acl-internal.h.
64154         * lib/copy-acl.c (qcopy_acl): Move to lib/qcopy-acl.c.
64155         * lib/set-acl.c: Rename from lib/set-mode-acl.c.
64156         (chmod_or_fchmod, qset_acl): Move to lib/qset-acl.c.
64157         (ACL_INTERNAL_INLINE): Remove; no longer needed.
64158         * lib/file-has-acl.c (file_has_acl):
64159         * lib/qcopy-acl.c (qcopy_acl):
64160         * lib/qset-acl.c (qset_acl):
64161         Use acl_errno_valid instead of ACL_NOT_WELL_SUPPORTED.
64162         * modules/acl (Files): Move lib/acl.h, lib/acl-internal.h,
64163         lib/acl_entries.c, lib/set-mode-acl.c (renamed to lib/set-acl.c),
64164         lib/file-has-acl.c, m4/acl.m4 to qacl module.
64165         Add lib/set-acl.c.
64166         (Depends-on): Move extern-inline, fstat, sys_stat to qacl module.
64167         Add qacl.
64168         (configure.ac): Move gl_FUNC_ACL to qacl module.
64169         (lib_SOURCES): Remove file-has-acl.c (moved to qacl module).
64170         Rename set-mode-acl.c to set-acl.c.
64171         * lib/acl-errno-valid.c: New file.
64172         * lib/qcopy-acl.c: New file, moved from the old lib/copy-acl.c; the
64173         copy_acl function remains in copy-acl.c.
64174         * lib/qcopy-acl.c, lib/qset-acl.c: Do not include gettext.h.
64175         (_): Remove; not needed.
64176         * lib/qset-acl.c: New file, moved from the old lib/set-mode-acl.c; the
64177         set_acl function remains in set-acl.c (renamed from set-mode-acl.c).
64178         * modules/qacl: New file, moved from the old modules/acl.
64179         (Files, lib_SOURCES): Add acl-errno-valid.c, qcopy-acl.c, qset-acl.c.
64180         Remove set-mode-acl.c, copy-acl.c.
64181         (Depends-on): Remove error, gettext-h, quote.  Add stdbool.
64183         alignof, intprops, malloca: port better to IBM's C compiler
64184         * lib/alignof.h (alignof_type) [__IBM_ALIGNOF__]: Use __alignof__.
64185         * lib/intprops.h (_GL_HAVE___TYPEOF__) [__IBM_TYPEOF__]: Now 1.
64186         * lib/malloca.h (sa_alignof): [__IBM_ALIGNOF__]: Use __alignof__.
64188 2013-04-25  Daiki Ueno  <ueno@gnu.org>
64190         wctype-h: fix gettext link error on mingw
64191         Reported by Josue Andrade Gomes and Takayuki Tsunakawa in
64192         <https://lists.gnu.org/r/bug-gettext/2013-03/msg00086.html>.
64193         * lib/wctype.in.h [__MINGW32__]: Include <ctype.h> before defining
64194         rpl_towupper and rpl_towupper.
64196 2013-04-11  Dmitry V. Levin  <ldv@altlinux.org>
64198         regex-tests, regex: allow glibc re_search behavior
64199         * tests/test-regex.c (main): In test for glibc bug 15078, reformat
64200         re_search input data to make the multi-character collating element
64201         in it clearly visible, and treat re_search return code 0 as valid.
64202         * m4/regex.m4 (gl_REGEX): Likewise.
64204 2013-03-30  Paul Eggert  <eggert@cs.ucla.edu>
64206         stdalign: doc fix
64207         * doc/posix-headers/stdalign.texi (stdalign.h):
64208         Gnulib doesn't support '_Alignof expr'.
64210 2013-03-29  Paul Eggert  <eggert@cs.ucla.edu>
64212         stdalign: port to stricter ISO C11
64213         ISO C11 says that _Alignof's operand must be a parenthesized type.
64214         Problem reported by Eli Zaretskii in
64215         <http://lists.gnu.org/r/emacs-devel/2013-03/msg00960.html>.
64216         * doc/posix-headers/stdalign.texi (stdalign.h): Document this.
64217         * m4/stdalign.m4 (gl_STDALIGN_H): Don't use _Alignof (expr).
64219 2013-03-21  Paul Eggert  <eggert@cs.ucla.edu>
64221         sys_select, sys_time: port 2013-01-30 Solaris 2.6 fix to Cygwin
64222         Problem reported by Marco Atzeri in
64223         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00000.html>.
64224         * lib/sys_select.in.h [HAVE_SYS_SELECT_H && _CYGWIN_SYS_TIME_H]:
64225         Simply delegate to the system <sys/select.h> in this case too.
64226         Also, pay attention to _GL_SYS_SELECT_H_REDIRECT_FROM_SYS_TIME_H only
64227         if OSF/1, since otherwise Cygwin breaks, and it doesn't seem to
64228         be needed on Solaris either.
64229         * lib/sys_time.in.h [_CYGWIN_SYS_TIME_H]:
64230         Simply delegate to the system <sys/time.h> in this case.
64232 2013-03-19  Karl Berry  <karl@gnu.org>
64234         * build-aux/gnupload: check for erroneous (with gnupload) use of
64235         ftp-upload.gnu.org, tweak help.
64237 2013-03-19  Paul Eggert  <eggert@cs.ucla.edu>
64239         copy-file, rpmatch: fix problems found by cppcheck
64240         Reported by Arno Onken in
64241         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00069.html>.
64242         * lib/rpmatch.c (try): Fix memory leak.
64243         * lib/copy-file.c: Include "ignore-value.h".
64244         (qcopy_file_preserving): Ignore chown value.
64245         * modules/copy-file (Depends-on): Add ignore-value.
64247 2013-01-27  Jim Meyering  <jim@meyering.net>
64249         prefix-gnulib-mk: give better diagnostics
64250         * build-aux/prefix-gnulib-mk: Don't just "die".
64251         Give better diagnostics upon failure.
64253 2013-03-13  Paul Eggert  <eggert@cs.ucla.edu>
64255         putenv: port to Solaris 10
64256         * lib/putenv.c (_unsetenv, putenv): Use HAVE_DECL__PUTENV, not
64257         HAVE__PUTENV.  Solaris 10 has a _putenv that's not declared and
64258         is not what is wanted here.
64259         * m4/putenv.m4 (gl_PREREQ_PUTENV): Check for _putenv's
64260         declaration, not for its existence.
64262 2013-03-12  Paul Eggert  <eggert@cs.ucla.edu>
64264         mktime: fix configure typo
64265         * m4/mktime.m4 (gl_FUNC_MKTIME): Fix typo in previous change.
64267 2013-03-12  Eric Blake  <eblake@redhat.com>
64269         regex-tests: skip UTF-8 test on mingw
64270         * modules/regex-tests (Depends-on): Add localcharset.
64271         * tests/test-regex.c (main): Use it to skip test on mingw.
64273 2013-03-11  Eric Blake  <eblake@redhat.com>
64275         tests: make it easier to bypass alarm time in debugger
64276         * tests/test-file-has-acl.c (main): Allow gdb to override alarm.
64277         * tests/test-memmem.c (main): Likewise.
64278         * tests/test-passfd.c (main): Likewise.
64279         * tests/test-ptsname.c (main): Likewise.
64280         * tests/test-ptsname_r.c (main): Likewise.
64281         * tests/test-strcasestr.c (main): Likewise.
64282         * tests/test-strstr.c (main): Likewise.
64284         regex: port to mingw's recent addition of undeclared alarm
64285         * doc/posix-functions/alarm.texi (alarm): Document that alarm
64286         exists but still doesn't work in newer mingw.
64287         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Check for alarm declaration,
64288         not existence.  Ensure SIGALRM is not trapped.
64289         * m4/mktime.m4 (gl_FUNC_MKTIME): Likewise.
64290         * m4/regex.m4 (gl_REGEX): Likewise.
64291         * m4/remainderf.m4 (gl_FUNC_REMAINDERF_WORKS): Likewise.
64292         * tests/test-regex.c (main): Use correct probe for alarm.
64294         putenv: avoid compilation warning on mingw
64295         * lib/putenv.c (_unsetenv): Protect variable declaration.
64296         (putenv): Fix indentation.
64298 2013-03-11  Gary V. Vaughan  <gary@gnu.org>
64300         unistd: don't prevent Tru64 Unix from using gnulib strtod.
64301         * lib/unistd.in.h: be careful not to include un-needed system
64302         stdlib.h from here, because that prevents gnulib stdlib.h from
64303         defining rpl_strtod correctly.
64305 2013-03-09  Gary V. Vaughan  <gary@gnu.org>
64307         vasprintf-posix-tests: allow rounding 1.51 to 1, per the previous
64308         changesets, but for the 'precision 0' test.
64309         * tests/test-vasprintf-posix.c (test_function): Don't insist on
64310         round-to-even, since POSIX says rounding is implementation-defined
64311         and OS X 10.8.2 rounds 1.51 to 1 here.
64313         vasprintf-posix-tests: allow rounding 1.5 to 1, per the previous
64314         changeset.
64315         * tests/test-vasprintf-posix.c (test_function): Don't insist on
64316         round-to-even, since POSIX says rounding is implementation-defined
64317         and OS X 10.8.2 rounds 1.5 to 1 here.
64319 2013-03-08  Paul Eggert  <eggert@cs.ucla.edu>
64321         vasnprintf-posix-tests: allow rounding 1.5 to 1
64322         * tests/test-vasnprintf-posix.c (test_function): Don't insist on
64323         round-to-even, since POSIX says rounding is implementation-defined
64324         and OS X 10.8.2 rounds 1.5 to 1 here.  Reported by Gary V. Vaughan in
64325         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00019.html>.
64327         bootstrap: port to FreeBSD
64328         * build-aux/bootstrap (bootstrap_sync): Port sh -c usage to shells
64329         that treat '--' differently.  Reported by Mats Erik Andersson in
64330         <http://lists.gnu.org/r/bug-gnulib/2013-03/msg00012.html>.
64332 2013-03-08  Gary V. Vaughan  <gary@gnu.org>
64334         regex: rename remaining __attribute calls to __attribute__.
64335         2012-02-25 changed definition of __attribute, but left some uses
64336         unchanged, preventing compilation of regex module on most non-gcc
64337         environments.
64338         * lib/regcomp.c (re_set_fastmap, seek_collating_symbol_entry)
64339         (lookup_collation_sequence_value, build_range_exp)
64340         (build_collating_symbol): Set attributes with newly renamed
64341         __attribute__ decorator.
64342         * lib/regex_internal.c (re_string_peek_byte_case)
64343         (re_node_set_compare, re_node_set_contains): Likewise.
64344         * lib/regexec.c (acquire_init_state_context): Likewise.
64346 2013-03-06  Bruno Haible  <bruno@clisp.org>
64348         execute: Revert last change, but use a different condition.
64349         * lib/execute.c (nonintr_close, nonintr_open): Reintroduce, but only
64350         on Windows.
64352 2013-03-05  Eric Blake  <eblake@redhat.com>
64354         execute: drop dead code
64355         * lib/execute.c (nonintr_close, nonintr_open): Delete.
64357 2013-03-04  Paul Eggert  <eggert@cs.ucla.edu>
64359         non-recursive-gnulib-prefix-hack: port coreutils 8.21 to HP NonStop
64360         * m4/non-recursive-gnulib-prefix-hack.m4
64361         (gl_NON_RECURSIVE_GNULIB_PREFIX_HACK): Don't mess with ALLOCA.
64362         Problem reported for HP NonStop + coreutils 8.21 by Joachim Schmitz in
64363         <http://bugs.gnu.org/10305#237>.
64365 2013-03-04  Eric Blake  <eblake@redhat.com>
64367         test-getsockopt: avoid compiler warning
64368         * tests/test-getsockopt.c (includes): Ensure close is declared.
64370 2013-03-02  Bruno Haible  <bruno@clisp.org>
64372         sys_types: Avoid autoconf warning about gl_SYS_TYPES_H.
64373         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Define through AC_DEFUN_ONCE.
64375 2013-03-02  Bruno Haible  <bruno@clisp.org>
64377         gettext: Update to version 0.18.2.
64378         * m4/intl.m4, m4/po.m4: Update from gettext-0.18.2. In particular:
64379         2012-12-07  Stefano Lattarini  <stefano.lattarini@gmailcom>
64380                 * intl.m4, po.m4: Bump requirement in AC_PREREQ to 2.60.
64382 2013-02-25  Paul Eggert  <eggert@cs.ucla.edu>
64384         regex: merge patches from libc
64386         2013-02-26  Siddhesh Poyarekar  <siddhesh@redhat.com>
64387         * lib/regex_internal.h (__attribute__): Rename from __attribute.
64388         All uses changed.
64389         (bitset_not, bitset_merge, bitset_mask, re_string_char_size_at)
64390         (re_string_wchar_at, re_string_elem_size_at):
64391         Mark function as possibly unused.
64393         2013-02-12  Andreas Schwab  <schwab@suse.de>  [BZ #11561]
64394         * lib/regcomp.c (parse_bracket_exp) [_LIBC]: When looking up collating
64395         elements compare against the byte sequence of it, not its name.
64397 2013-02-21  Paul Eggert  <eggert@cs.ucla.edu>
64399         putenv: port better to native Windows
64400         * lib/putenv.c [(_WIN32 || __WIN32__) && ! __CYGWIN__]:
64401         Define WIN32_LEAN_AND_MEAN and include <windows.h>.
64402         (_unsetenv): Use _putenv if available.
64403         (putenv): Temporarily set NAME=' ' rather than NAME='x' as that's
64404         a bit less likely to cause damage.
64405         (putenv) [(_WIN32 || __WIN32__) && ! __CYGWIN__]:
64406         Fix the wrong value with SetEnvironmentVariable.
64407         (putenv) [!HAVE__PUTENV]: Simplify and match the HAVE__PUTENV
64408         code better.
64410 2013-02-20  Paul Eggert  <eggert@cs.ucla.edu>
64412         regex: ignore old-style-definition warnings
64413         * lib/regex.c: Add pragma to ignore these warnings.
64414         Problem reported for GNU tar by Pavel Raiskup.
64416 2013-02-19  Paul Eggert  <eggert@cs.ucla.edu>
64418         getcwd: support coreutils better
64419         Like strtod, getcwd incorrectly referred to HAVE_RAW_DECL_GETCWD,
64420         but this might not be correct in coreutils, which disables
64421         the raw decl checks.  Problem reported by Nagendra in
64422         <http://bugs.gnu.org/10305#192>.
64423         * lib/getcwd.c (__getcwd): Do not depend on HAVE_RAW_DECL_GETCWD.
64424         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
64425         Test the getcwd function, not any macro, since getcwd.c wants the
64426         function.
64427         * m4/getcwd.m4 (gl_FUNC_GETCWD):
64428         Don't define HAVE_MINIMALLY_WORKING_GETCWD if the code doesn't
64429         compile, as might happen if there's a macro but no function.
64431         strtod: support coreutils better
64432         * lib/strtod.c (underlying_strtod): Just invoke the underlying strtod.
64433         HAVE_RAW_DECL_STRTOD might not be correct in coreutils, which
64434         disables the raw decl checks.  This assumes there is an underlying
64435         strtod, but that's a safe assumption these days.
64436         (HAVE_RAW_DECL_STRTOD): Remove; no longer used.
64438         mountlist: port to HP NonStop
64439         Reported by Joachim Schmitz in
64440         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00084.html>.
64441         * lib/mountlist.c (hasmntopt) [!HAVE_HASMNTOPT]: New function.
64442         (MNT_IGNORE) [MNTOPT_IGNORE]: Use it.
64444 2013-02-18  Paul Eggert  <eggert@cs.ucla.edu>
64446         extern-inline: avoid compilation error with HP-UX cc
64447         Reported by Richard Lloyd in
64448         <http://lists.gnu.org/r/bug-texinfo/2013-02/msg00030.html>.
64449         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE):
64450         Suppress extern inline with HP-UX cc.  This should be safe,
64451         though it may hurt performance.  Perhaps someone with some HP-UX
64452         experience can come up with a higher-performance fix.
64454 2013-02-14  Paul Eggert  <eggert@cs.ucla.edu>
64456         putenv: fix heap corruption with mixed putenv/_putenv
64457         Problem reported by Michael Goffioul in
64458         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00061.html>.
64459         * lib/putenv.c (putenv) [HAVE__PUTENV]:
64460         Rely on _putenv to allocate the new environment.
64461         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
64462         * modules/putenv (configure.ac): Use it.
64464 2013-02-11  Paul Eggert  <eggert@cs.ucla.edu>
64466         unsetenv etc.: port to Solaris 11 + GNU Emacs
64467         * lib/canonicalize-lgpl.c, lib/getaddrinfo.c, lib/getdelim.c:
64468         * lib/glob.c, lib/random_r.c, lib/setenv.c, lib/tsearch.c:
64469         * lib/unsetenv.c (_GL_ARG_NONNULL): Define before including <config.h>.
64470         GNU Emacs's <config.h> includes <stdlib.h> (which is not a great
64471         idea but is too painful to fix right now), and without this gnulib
64472         change <stdlib.h> was defining _GL_ARG_NONNULL incorrectly when
64473         compiling unsetenv.c on Solaris 11.  Fix the problem for
64474         unsetenv.c, and fix other similar occurrences.
64476 2013-02-09  Paul Eggert  <eggert@cs.ucla.edu>
64478         secure_getenv: fix C++ declaration typo
64479         * lib/stdlib.in.h (secure_getenv): Fix typo with return type
64480         in _GL_CXXALIAS_SYS macro.  Reported by John W. Eaton in
64481         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00057.html>.
64483 2013-02-08  Paul Eggert  <eggert@cs.ucla.edu>
64485         careadlinkat: stop exporting careadlinkatcwd
64486         Only Emacs used it directly, and Emacs no longer needs it.
64487         * NEWS: Document this simplification.
64488         * lib/areadlink.c (careadlinkatcwd): Move here from careadlinkat.c,
64489         and make it static.  Include <stdlib.h>, for abort, and unistd.h,
64490         for readlink.
64491         * lib/careadlinkat.c (careadlinkatcwd): Move to areadlink.c.
64492         Don't include stdlib.h; no longer needed.
64493         * lib/careadlinkat.h (careadlinkatcwd): Remove decl.
64494         * lib/relocwrapper.c: Adjust comment to match new dependencies.
64495         * modules/areadlink (Depends-on): Add readlink.
64496         (Maintainer): Add self.
64497         * modules/careadlinkat (Depends-on): Remove readlink.
64499         extensions: port better to HP-UX
64500         This is merged from git Autoconf.
64501         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
64502         On hosts that need _XOPEN_SOURCE, define it when configuring, too,
64503         so that it's compatible with the value used when compiling.
64505         openpty: fix bug where HAVE_OPENPTY is mistakenly 1
64506         Problem reported by Mats Erik Andersson in
64507         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00051.html>.
64508         * m4/pty.m4 (gl_FUNC_OPENPTY): Define HAVE_OPENPTY when the
64509         openpty function exists, not merely when we intend to replace it.
64510         This corrects the 2013-01-31 patch, which mistakenly defined
64511         HAVE_OPENPTY even on hosts that lacked it.
64513 2013-02-07  Paul Eggert  <eggert@cs.ucla.edu>
64515         secure_getenv: fix include typo
64516         * lib/secure_getenv.c: Include config.h.  Somehow I forgot!
64518         secure_getenv: port better to FreeBSD and Solaris
64519         * lib/secure_getenv.c [!HAVE___SECURE_GETENV]:
64520         Include unistd.h if HAVE_ISSETUGID, otherwise define a dummy issetugid.
64521         (secure_getenv) [!HAVE___SECURE_GETENV]: Use getenv if not issetugid.
64522         This works better on BSDish platforms.
64523         * m4/secure_getenv.m4 (gl_PREREQ_SECURE_GETENV):
64524         Test for issetugid if __secure_getenv is missing.
64526 2013-02-06  Paul Eggert  <eggert@cs.ucla.edu>
64528         extensions: port better to MINIX 3, HP-UX, autoheader 2.62
64529         Some of these changes are merged in from git Autoconf.
64530         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
64531         When deciding whether to define _XOPEN_SOURCE, inspect the
64532         preprocessor macro __hpux instead of the more-heavyweight
64533         operation of requiring AC_CANONICAL_HOST.  Define _NETBSD_HOST on
64534         MINIX, for MINIX 3.  Use USE_SYSTEM_EXTENSIONS, not __EXTENSIONS__,
64535         as the key for __EXTENSIONS__.
64537         unistd: avoid namespace pollution on non-glibc systems
64538         * lib/unistd.in.h: #define __need_getopt before including <getopt.h>.
64539         This avoids namespace pollution on non-glibc systems, by causing
64540         gnulib unistd.h to behave more like glibc unistd.h.  I also hope
64541         that this fixes a bug on FreeBSD, reported by Mats Erik Andersson in
64542         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00027.html>.
64544 2013-02-04  Paul Eggert  <eggert@cs.ucla.edu>
64546         tmpdir: use secure_getenv
64547         * lib/tmpdir.c (__secure_getenv) [!LIBC]:
64548         Define to secure_getenv, not getenv.
64549         * m4/tmpdir.m4 (gt_TMPDIR): Don't check for __secure_getenv,
64550         as that's now secure_getenv's job.
64551         * modules/tmpdir (Depends-on): Add secure_getenv.
64553         tempname: use secure_getenv
64554         * lib/tempname.c (__secure_getenv) [!_LIBC]:
64555         Define to secure_getenv, not getenv.
64556         * modules/tempname (Depends-on):
64557         Add secure_getenv.
64559         secure_getenv: new module
64560         * MODULES.html.sh (Extra functions based on ANSI C 89):
64561         Add secure_getenv.
64562         * doc/glibc-functions/secure_getenv.texi: New file.
64563         * doc/gnulib.texi: Include it.
64564         * lib/secure_getenv.c, m4/secure_getenv.m4, modules/secure_getenv:
64565         New files.
64566         * lib/stdlib.in.h (secure_getenv): New decl.
64567         * m4/stdlib_h.m4 (gl_STDLIB_H, gl_STDLIB_H_DEFAULTS):
64568         * modules/stdlib (stdlib.h):
64569         Add secure_getenv checks.
64571 2013-02-03  Paul Eggert  <eggert@cs.ucla.edu>
64573         getcwd: break fdopendir + save_cwd recursive loop (Bug#13516)
64574         Reported for OS X 10.8.2 by Assaf Gordon in
64575         <http://bugs.gnu.org/13516>.
64576         * lib/getcwd.c (HAVE_OPENAT_SUPPORT): Do not define if
64577         !HAVE_OPENAT && !HAVE_FDOPENDIR.
64578         * m4/getcwd-abort-bug.m4: Reformat to match test-getcwd.c
64579         so that they can be kept in sync more easily.  Avoid PATH_MAX
64580         test on the Hurd.  Sync from test-getcwd.c for errno tests after
64581         mkdir or chdir failure.
64582         * tests/test-getcwd.c (HAVE_OPENAT_SUPPORT): New macro, from
64583         lib/getcwd.c.
64584         (test_abort_bug): Do not test for the deep directory bug unless we
64585         have openat support.  Avoid PATH_MAX test on the Hurd.
64587         regex-tests, regex: fix bug: memset undeclared
64588         * tests/test-regex.c: Don't include regex.h twice.  Include
64589         string.h, to declare memset.  Christensen's report also mentioned
64590         this issue.
64591         * m4/regex.m4 (gl_REGEX): Keep test program more in sync with
64592         test-regex.c, to avoid future problems like this.  Remove
64593         AC_INCLUDES_DEFAULT.  Include <string.h>.  Don't include <regex.h>
64594         twice.
64596         regex-tests: fix link errors on older Solaris
64597         These need to link with @LIBINTL@ to get libintl_gettext.
64598         Problem reported by Tom G. Christensen in
64599         <http://lists.gnu.org/r/bug-gnulib/2013-02/msg00003.html>.
64600         * modules/regex-tests (test_regex_LDADD): New macro.
64602 2013-01-31  Paul Eggert  <eggert@cs.ucla.edu>
64604         regex-tests: new module
64605         * modules/regex-tests, tests/test-regex.c: New files.
64607         regex: fix off-by-one error in configure test
64608         * m4/regex.m4 (gl_REGEX): Test should return 21, not 20.
64610 2013-01-31  Eric Blake  <eblake@redhat.com>
64612         regex: avoid infinite configure test
64613         * m4/regex.m4 (gl_REGEX): Add an alarm escape hatch.
64615 2013-01-31  Reuben Thomas  <rrt@sc3d.org>
64617         openpty: fix bug where HAVE_OPENPTY wasn't defined
64618         See the thread starting at:
64619         http://lists.gnu.org/r/bug-gnulib/2013-01/msg00185.html
64620         * m4/pty.m4 (gl_FUNC_OPENPTY): Define HAVE_OPENPTY when the
64621         openpty function exists, not merely when we intend to replace it.
64623 2013-01-30  Paul Eggert  <eggert@cs.ucla.edu>
64625         sys_time: port to Solaris 2.6
64626         There is a circularity problem on Solaris 2.6, where <time.h> includes
64627         <sys/time.h> for struct timespec.  The include nesting is gnulib
64628         <time.h>, system <time.h>, gnulib <sys/time.h>, system
64629         <sys/time.h>, gnulib <sys/types.h>, system <sys/types.h>, gnulib
64630         <sys/select.h>, gnulib <signal.h>, system <sys/signal.h>, system
64631         <sys/siginfo.h>; the last, innermost file needs struct
64632         timestruc_t, which is defined in <sys/time.h>, which has not been
64633         fully parsed.  Problem reported by Tom G. Christensen in
64634         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00113.html>.
64635         * lib/sys_select.in.h: Treat Solaris 2.6's problem with
64636         <sys/time.h> and <sys/types.h> like OSF/1's similar problem.
64637         * lib/sys_time.in.h: Redo to resemble sys_select.in.h, which
64638         uses split double-inclusion guards.
64640 2013-01-29  Paul Eggert  <eggert@cs.ucla.edu>
64642         regex: test for buffer overrun
64643         * m4/regex.m4 (gl_REGEX): Add test case, by Andreas Schwab,
64644         for the just-fixed regex bug.
64646 2013-01-29  Andreas Schwab  <schwab@suse.de>
64648         regex: fix buffer overrun in regexp matcher [BZ #15078]
64649         * lib/regexec.c (extend_buffers): Add parameter min_len.
64650         (check_matching): Pass minimum needed length.
64651         (clean_state_log_if_needed): Likewise.
64652         (get_subexp): Likewise.
64654 2013-01-28  Pádraig Brady  <P@draigBrady.com>
64656         mountlist: don't consider "devtmpfs" as dummy
64657         * lib/mountlist.c (ME_DUMMY_0): Remove "devtmpfs"
64658         as there is storage associcated with it.
64660 2013-01-27  Paul Eggert  <eggert@cs.ucla.edu>
64662         futimens-tests, utimens-tests: Depend on gettext.
64663         This works around a problem introduced in my 2013-01-12 patch,
64664         which added @LIBINTL@ to these modules.
64665         * modules/futimens-tests (Depends-on):
64666         * modules/utimens-tests (Depends-on): Add gettext.
64668 2013-01-26  Eric Blake  <eblake@redhat.com>
64670         test-getpeername: fix typo
64671         * tests/test-getpeername.c: Fix typo introduced in fd cleanup.
64673 2013-01-20  Bernhard Voelker  <mail@bernhard-voelker.de>
64675         bootstrap: remove the need for a sorted .gitignore file
64676         * build-aux/bootstrap (insert_sorted_if_absent): Adjust and
64677         rename to insert_if_absent(), so that we don't need or generate
64678         a sorted .gitignore file.  We do require a .gitignore with no
64679         existing duplicate entries and enforce that.
64680         (sort_patterns): Remove this function as we now use the simpler
64681         technigue of inserting blacklist entries at the top of the file,
64682         assuming gnulib won't be inserting !whitelist entries.
64684 2013-01-23  Paul Eggert  <eggert@cs.ucla.edu>
64686         readlinkat: don't depend on gl_FUNC_OPENAT
64687         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Don't require gl_FUNC_OPENAT.
64688         Perhaps a similar change needs to be made for linkat.m4, mkfifoat.m4,
64689         renameat.m4, symlinkat.m4; but one thing at a time.
64691         statat: new module, split out from fstatat
64692         GNU Emacs needs the POSIX-specified fstatat, but not the
64693         gnulib-specified statat and lstat.  Split the latter two into a
64694         new module 'statat'.
64695         * lib/openat.h: Depend on GNULIB_STATAT, not GNULIB_FSTATAT.
64696         * lib/openat.h, lib/statat.c (STATAT_INLINE):
64697         Rename from FSTATAT_INLINE. All uses changed.
64698         * modules/fstatat (Files): Remove lib/statat.c.
64699         (gl_MODULE_INDICATOR([fstatat])): Remove.
64700         (lib_SOURCES): Remove.
64701         (Maintainer): Add self.
64702         * modules/statat, modules/statat-tests, tests/test-statat.c: New files.
64703         * tests/test-fstatat.c (BASE): Don't define if already defined.
64704         (do_stat, do_lstat) [!TEST_STATAT]: Test fstatat instead.
64706 2013-01-22  Paul Eggert  <eggert@cs.ucla.edu>
64708         tests: don't assume fd 99 is closed
64709         * tests/test-accept.c, tests/test-accept4.c, tests/test-bind.c:
64710         * tests/test-close.c, tests/test-connect.c, tests/test-dprintf.c:
64711         * tests/test-dup.c, tests/test-dup2.c, tests/test-faccessat.c:
64712         * tests/test-fchdir.c, tests/test-fchmod.c, tests/test-fchmodat.c:
64713         * tests/test-fchown.c, tests/test-fchownat.c, tests/test-fclose.c:
64714         * tests/test-fdatasync.c, tests/test-fdopen.c, tests/test-fdopendir.c:
64715         * tests/test-fflush.c, tests/test-fgetc.c, tests/test-fputc.c:
64716         * tests/test-fread.c, tests/test-freopen.c, tests/test-fseeko4.c:
64717         * tests/test-fstat.c, tests/test-fstatat.c, tests/test-fsync.c:
64718         * tests/test-ftello4.c, tests/test-ftruncate.c, tests/test-futimens.h:
64719         * tests/test-fwrite.c, tests/test-getpeername.c:
64720         * tests/test-getsockname.c, tests/test-getsockopt.c:
64721         * tests/test-grantpt.c, tests/test-ioctl.c, tests/test-isatty.c:
64722         * tests/test-linkat.c, tests/test-listen.c, tests/test-lseek.c:
64723         * tests/test-mkdirat.c, tests/test-mkfifoat.c, tests/test-openat.c:
64724         * tests/test-pread.c, tests/test-pwrite.c, tests/test-read.c:
64725         * tests/test-readlinkat.c, tests/test-recv.c, tests/test-recvfrom.c:
64726         * tests/test-renameat.c, tests/test-select.h, tests/test-send.c:
64727         * tests/test-sendto.c, tests/test-setsockopt.c, tests/test-shutdown.c:
64728         * tests/test-symlinkat.c, tests/test-ttyname_r.c:
64729         * tests/test-unlinkat.c, tests/test-unlockpt.c:
64730         * tests/test-utimensat.c, tests/test-vdprintf.c, tests/test-write.c:
64731         Close file descriptor 99, instead of assuming it's already closed.
64733 2013-01-21  Paul Eggert  <eggert@cs.ucla.edu>
64735         stpncpy: port to OS X 10.8
64736         * lib/stpncpy.c (__stpncpy): Parenthesize name when defining function.
64737         Problem reported by Assaf Gordon in <http://bugs.gnu.org/13495>.
64739 2013-01-16  Paul Eggert  <eggert@cs.ucla.edu>
64741         unistd: port to recent mingw
64742         * lib/unistd.in.h: Remove special invocation convention for mingw,
64743         which breaks for the latest mingw version.  See John W. Eaton in
64744         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00100.html>.
64746         largefile: port better to Mac OS X 10.5
64747         This patch is backported from Autoconf git.
64748         * m4/largefile.m4 (AC_SYS_LARGEFILE): Use AC_DEFINE, not
64749         AH_VERBATIM, to define _DARWIN_USE_64_BIT_INODE, to avoid problems
64750         with ino_t size being different for configuration time versus
64751         build/run time.  Problem reported by PHO in
64752         <http://lists.gnu.org/r/bug-autoconf/2013-01/msg00040.html>.
64754 2013-01-15  Paul Eggert  <eggert@cs.ucla.edu>
64756         doc: clarify -Werror
64757         * doc/warnings.texi (warnings): -Werror is not always a bad idea;
64758         clarify that it's intended for developers, not for ordinary builds,
64759         and mention --enable-gcc-warnings as one possible use.
64761 2013-01-15  Andoni Morales Alastruey  <ylatuya@gmail.com>  (tiny change)
64763         stdint: fix build with Android's Bionic fox x86
64764         * lib/stdint.in.h: fix check to test if included-fixed/sys/types.h
64765         was already included as _SSIZE_T_DEFINED_ might also be defined
64766         in include/machine/_types.h, which is included by stdio.h
64768 2013-01-13  Paul Eggert  <eggert@cs.ucla.edu>
64770         net_if-tests: port to Solaris 7 + GCC 3.4.6
64771         Problem reported by Tom G. Christensen in
64772         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00091.html>.
64773         * tests/test-net_if.c (ni): Move to next the code that uses it,
64774         so that it's declared only if needed.
64776 2013-01-12  Paul Eggert  <eggert@cs.ucla.edu>
64778         net_if-tests: port to older Solaris
64779         Problem reported by Tom G. Christensen in
64780         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html>.
64781         * modules/net_if-tests (NET_IF_LIB): New substitution.
64782         (test_net_if_LDADD): New makefile macro, which uses NET_IF_LIB.
64783         (HAVE_IF_NAMEINDEX): New C macro.
64784         * tests/test-net_if.c: Bypass most of the test if !HAVE_IF_NAMEINDEX.
64786         system-quote-tests: port to older Solaris
64787         Problem reported by Tom G. Christensen in
64788         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html>.
64789         * tests/test-system-quote-child.c (fopen, fread): Undef.
64791         c-xvasprintf etc.: fix link errors on older Solaris
64792         These need to link with @LIBINTL@ to get libintl_gettext.
64793         Problem reported by Tom G. Christensen in
64794         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00086.html>.
64795         * modules/c-xvasprintf-tests (test_c_xvasprintf_LDADD):
64796         * modules/readtokens-tests (test_readtokens_LDADD): New macros.
64797         * modules/futimens-tests (test_futimens_LDADD):
64798         * modules/utimens-tests (test_utimens_LDADD): Add @LIBINTL@.
64800 2013-01-10  Paul Eggert  <eggert@cs.ucla.edu>
64802         locale: port to Solaris 2.6 and 7 + GNU gettext
64803         * lib/locale.in.h: Just include_next <locale.h> when
64804         being invoked recursively.  This prevents problems on Solaris 2.6 and 7
64805         when combining the localename module with GNU gettext 0.18.2.
64806         Problem reported by Tom G. Christensen in
64807         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00084.html>.
64809 2013-01-09  Paul Eggert  <eggert@cs.ucla.edu>
64811         stdlib: port to Solaris 2.6
64812         Also, the code worked on Solaris 7 through 9 only by accident.
64813         Problem reported by Tom G. Christensen in
64814         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00059.html>.
64815         * lib/stdlib.in.h: If __need_system_stdlib_h is defined,
64816         simply include the system stdlib.h.
64817         * lib/getopt.in.h (__need_system_stdlib_h):
64818         * lib/pthread.in.h (__need_system_stdlib_h):
64819         * lib/unistd.in.h (__need_system_stdlib_h) [!__GLIBC__]:
64820         Define when including <stdlib.h>, to avoid problems at least for
64821         the pthread case on Solaris 2.6 and 7.  These .h files can get by
64822         with the system stdlib.h.
64824 2013-01-06  Paul Eggert  <eggert@cs.ucla.edu>
64826         doc: update main copyright year
64827         * doc/gnulib.texi: Update copyright date.
64829         doc: improve ISO 8601 discussion
64830         * doc/parse-datetime.texi (Combined date and time of day items):
64831         Specify more carefully what formats are supported and what is
64832         done with excess precision.
64834 2013-01-05  Paul Eggert  <eggert@cs.ucla.edu>
64836         doc: avoid small caps
64837         * doc/parse-datetime.texi, doc/regex.texi: Don't use small caps;
64838         they're more trouble than they're worth.  Suggested by Karl Berry
64839         in <http://bugs.gnu.org/13360>.
64841         regex: conform to strict C
64842         * lib/regcomp.c (parse_bracket_exp): Add cast to conform to strict C.
64843         From Aharon Robbins.
64845         gnulib-tool: fix incompatibility with autopoint 0.18.2
64846         * gnulib-tool: Don't indent AM_GNU_GETTEXT_VERSION line.
64847         Problem reported by Tom G. Christensen in
64848         <http://lists.gnu.org/r/bug-gnulib/2013-01/msg00053.html>.
64850 2013-01-04  Paul Eggert  <eggert@cs.ucla.edu>
64852         fprintftime: bring back and reword fwrite comment
64853         * lib/strftime.c (cpy) [FPRINTFTIME]: Re-add reworded comment.
64855         stdio: remove now-unnecessary stdio.c
64856         Since stdio.in.h no longer uses inline functions, we no longer
64857         need to compile the extern versions.
64858         * lib/stdio.c: Remove.
64859         * modules/stdio (Files): Remove lib/stdio.c.
64860         (lib_SOURCES): Remove.
64862         unicodeio: depend on stdio, not ignore-value
64863         * lib/unicodeio.c: Do not include ignore-value.h.
64864         (fwrite_success_callback): Use plain fwrite, not ignore_value + fwrite.
64865         * modules/unicodeio (Depends-on): Depend on stdio, not ignore-value.
64867         fprintftime: depend on stdio, not ignore-value
64868         * lib/strftime.c [FPRINTFTIME]: Do not include ignore-value.h.
64869         (cpy) [FPRINTFTIME]: Use plain fwrite, not ignore_value of fwrite,
64870         since the stdio module arranges to silence that warning now.
64871         * modules/fprintftime (Depends-on): Depend on stdio, not ignore-value.
64873 2012-10-04  Simon Josefsson  <simon@josefsson.org>
64875         stdint-tests: Fix expanded-before-required-warning.
64876         * modules/stdint-tests (Depends-on): Use AC_REQUIRE.
64878 2013-01-03  Paul Eggert  <eggert@cs.ucla.edu>
64880         fwrite: silence __wur only for older glibc versions
64881         * lib/stdio.in.h (fwrite): Limit workaround to glibc 2.4 through 2.15.
64882         This will help us remove this workaround some time in the far future.
64884 2013-01-03  Eric Blake  <eblake@redhat.com>
64886         fwrite: silence __wur without using inline
64887         * lib/stdio.in.h (fwrite): Limit warn_unused_result workaround to
64888         just gcc, and in a way that avoids inline issues.
64889         * modules/stdio (Depends-on): Drop extern-inline.
64891 2013-01-03  Jim Meyering  <jim@meyering.net>
64893         update-copyright: avoid copyright notice date corruption
64894         Given a sequence of copyright year numbers in which the final
64895         one was a two-digit number that happened to be a substring of
64896         a preceding four-digit year number, we would mistakenly update
64897         the substring (from two- to four-digit) rather than the two-digit
64898         number at the end, which, combined with the addition of the current
64899         4-digit year number would yield two 5-digit year numbers, e.g.,
64900         here, it would convert the first "99" to "1999, 2013" rather than
64901         the final one:
64902           1991, 99
64903           11999, 20131, 1999
64904         * build-aux/update-copyright: Tighten a regexp.
64905         * tests/test-update-copyright.sh: Add a test case to trigger the bug.
64906         Reported by Joseph Myers in
64907         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/32281
64909 2013-01-01  Paul Eggert  <eggert@cs.ucla.edu>
64911         regex: omit needless signed-pointer casts
64912         * lib/regcomp.c (build_charclass, build_charclass_op):
64913         Use char *, not unsigned char *, for class name and extra.
64914         The char values are always nonnegative so there's no need to
64915         insist on unsigned char * here, and using char * removes the need
64916         for casts.  Reported by Aharon Robbins in
64917         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
64919         regex: support Gawk, which never uses alloca
64920         * lib/regex_internal.h [!_LIBC && !HAVE_ALLOCA]:
64921         Do not include in this case.  Gawk doesn't supply a substitute
64922         alloca.h and doesn't need one.
64924         regex: port __libc_lock_define usage to C89
64925         * lib/regex_internal.h (__libc_lock_define) [!_LIBC]: Remove.
64926         (struct re_dfa_t): Use #ifdef instead.  '__libc_lock_define (, lock)'
64927         does not conform to C89, as it has an empty macro argument.
64928         Reported by Aharon Robbins in
64929         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
64931 2013-01-01  Eric Blake  <eblake@redhat.com>
64933         maint: update all copyright year number ranges
64934         Run "make update-copyright".
64936         version-etc: bump copyright year reported in --version
64937         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2013.
64939 2012-12-31  Eric Blake  <eblake@redhat.com>
64941         sigprocmask-tests: skip test if pid is unexpectedly large
64942         * tests/test-sigprocmask.c (main): Add range check.
64944         git-version-gen: avoid test -z portability glitch
64945         * build-aux/git-version-gen: Prefer portable test spelling, since
64946         git-version-gen is run on more than just developer machines.
64948 2012-12-31  Peter Rosin  <peda@lysator.liu.se>  (tiny change)
64950         git-version-gen: add --fallback option to use if git is not present
64951         * build-aux/git-version-gen: Add support for the new option --fallback,
64952         which comes into play when there is no $tarball_version_file and
64953         git is not working.
64954         (scriptversion): Update.
64956         maint.mk: handle missing git with more grace
64957         * top/maint.mk (no-submodule-changes, public-submodule-commit):
64958         Quietly proceed if git is not present.
64960 2012-12-31  Eric Blake  <eblake@redhat.com>
64962         dup2: work around cygwin bug
64963         * m4/dup2.m4 (gl_FUNC_DUP2): Flush out cygwin core dump.
64964         * lib/dup2.c (rpl_dup2): Work around it.
64965         * doc/posix-functions/dup2.texi (dup2): Document it.
64967 2012-12-30  Paul Eggert  <eggert@cs.ucla.edu>
64969         regex: remove unnecessary dependency on localcharset.h
64970         * lib/regex_internal.h [!_LIBC]: Don't include localcharset.h;
64971         hasn't been needed for years.
64972         * modules/regex (Depends-on): Remove localcharset.
64974         regex: revert single-byte change
64975         * lib/regexec.c (check_node_accept_bytes): Revert previous change
64976         to this function.  This was alredy fixed in a different way, at
64977         bdb56bacd57070eced9998569ffe3f3c37ef5964 in the glibc git; see
64978         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=510219> and
64979         <http://sourceware.org/bugzilla/show_bug.cgi?id=9697>.
64981         regex: simplify based on Gawk version
64982         * lib/regex_internal.c (re_dfa_add_node): Simplify.
64983         Reported by Aharon Robbins in
64984         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
64986 2012-12-29  Paul Eggert  <eggert@cs.ucla.edu>
64988         regex: check that pattern char is single-byte
64989         Reported by Aharon Robbins in
64990         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
64991         * lib/regexec.c (check_node_accept_bytes):
64992         Return 0 if the pattern string has a multibyte character here.
64994         regex: implement rational ranges
64995         Reported by Aharon Robbins in
64996         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
64997         * lib/regcomp.c (build_range_exp) [!_LIBC]:
64998         * lib/regexec.c (check_node_accept_bytes) [!_LIBC]:
64999         Implement rational ranges.
65001         regex: avoid redefining __wctype
65002         Reported by Aharon Robbins in
65003         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
65004         * lib/regex_internal.h (__wctype, __iswctype) [!_LIBC]:
65005         #undef before defining.
65007         regex: port to hosts where malloc (0) == NULL
65008         Reported by Aharon Robbins in
65009         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
65010         * lib/regex_internal.c (re_node_set_alloc):
65011         Don't assume that malloc (0) yields nonnull.
65012         * lib/regex_internal.h (MALLOC_0_IS_NONNULL): New macro.
65013         * m4/regex.m4 (gl_PREREQ_REGEX): Require gl_EEMALLOC.
65014         * modules/regex (Files): Add m4/eealloc.m4.
65016         regex: port to C89
65017         Reported by Aharon Robbins in
65018         <http://sourceware.org/ml/libc-alpha/2012-12/msg00456.html>.
65019         * lib/regcomp.c (init_word_char): Declaration before statement.
65021         regex: merge glibc changes
65022         Also, copy the license wording from glibc.  This simplifies
65023         merging changes.  gnulib-tool will change the wording to GPL as
65024         appropriate, when importing it to other packages.  The only
65025         glibc change made since the last merge, which needs merging, is:
65026         2012-05-24 Andreas Schwab <schwab@linux-m68k.org>
65027         * lib/regex_internal.h (gettext): Remove use of INTUSE.
65029         * users.txt: Add Emacs.
65031         doc: omit mention of version when not needed
65032         * doc/gnulib-intro.texi (Portability and Application Code):
65033         * doc/gnulib.texi (Brief Overview, Legacy Function Substitutes):
65034         Don't mention particular dates or versions when not necessary, so
65035         that the documentation won't go out of date so quickly.
65037         * doc/intprops.texi (Integer Properties): Fix Texinfo typo.
65039 2012-12-28  Akim Demaille  <akim@lrde.epita.fr>
65041         bootstrap: pass --force to autoreconf.
65042         * build-aux/bootstrap (AUTORECONFFLAGS): New.
65043         Add "--force" so that Automake's ylwrap and other such tools
65044         be updated at each bootstrap invocation.
65045         Use it.
65047 2012-12-27  Paul Eggert  <eggert@cs.ucla.edu>
65049         argp: fix port of port new 'inline' approach to Sun C 5.12 + Solaris 10
65050         The earlier patch forgot to update one of the #if conditions, causing
65051         a problem on Debian testing i386 reported by Mats Erik Andersson
65052         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00124.html>.
65053         * lib/argp-fmtstream.h (__argp_fmtstream_putc, argp_fmtstream_putc)
65054         (__argp_fmtstream_puts, argp_fmtstream_puts)
65055         (__argp_fmtstream_write, argp_fmtstream_write)
65056         [!_LIBC && !__OPTIMIZE__]: Declare as ARGP_FS_EI, not as extern.
65058         * doc/gnulib-readme.texi: Minor fixups.
65059         (Portability guidelines): Modernize URLs.  Remove some repetition.
65060         (Indent with spaces not TABs): Reword to avoid too-long lines.
65061         Remove some '@ifset standalone' stuff that isn't used.
65063         * doc/gnulib-readme.texi (Portability guidelines):
65064         ctype.h, not ctime.h.
65066         Correct name of POSIX.1-2001.
65067         * doc/posix-functions/fgetc.texi (fgetc):
65068         * doc/posix-functions/fgets.texi (fgets):
65069         * doc/posix-functions/fread.texi (fread):
65070         * doc/posix-functions/fscanf.texi (fscanf):
65071         * doc/posix-functions/getc.texi (getc):
65072         * doc/posix-functions/getchar.texi (getchar):
65073         * doc/posix-functions/scanf.texi (scanf):
65074         POSIX.1-2001, not POSIX-2001.
65076         doc: move README into manual
65077         * README: Move contents to new file doc/gnulib-readme.texi.
65078         Replace with a one-line summary.
65079         * doc/gnulib.texi (Brief Overview): New section,
65080         with old intro preface.  Include gnulib-readme.texi for contents.
65081         (Philosophy): Rename from "Introduction", since this
65082         section no longer introduces the rest.  Write a new preface.
65083         * doc/gnulib-readme.texi: New file, with the old contents of
65084         README texinfo-ized.  This way, the README info appears
65085         in the online and printed manual.
65087 2012-12-25  Ben Pfaff  <blp@cs.stanford.edu>
65089         c-xvasprintf: Fix "implicit declaration of function" GCC warning.
65090         * lib/c-xvasprintf.c: Add missing #include "c-vasprintf.h", for
65091         c_vasprintf() prototype.
65093 2012-12-24  Ben Pfaff  <blp@cs.stanford.edu>
65095         c-vasprintf: Fix "empty declaration" warning reported by GCC.
65096         * lib/c-vasprintf.h: Remove stray semicolon.
65098 2012-12-23  Paul Eggert  <eggert@cs.ucla.edu>
65100         gettext: avoid obsolete macro AM_PROG_MKDIR_P
65101         It is obsolete and is planned to be removed from Automake 1.14; see
65102         <http://lists.gnu.org/r/automake/2012-12/msg00029.html>.
65103         * build-aux/po/Makefile.in.in (install-data, install-data-yes)
65104         (installdirs-data, installdirs-data-yes):
65105         Use $(MKDIR_P), not $(mkdir_p).
65106         * m4/intl.m4 (AM_INTL_SUBDIR):
65107         * m4/po.m4 (AM_PO_SUBDIRS):
65108         Require AC_PROG_MKDIR_P, not AM_PROG_MKDIR_P.
65110 2012-12-22  Paul Eggert  <eggert@cs.ucla.edu>
65112         argp: port new 'inline' approach to Sun C 5.12 + Solaris 10
65113         On this platform, we are not optimizing but we are using
65114         the substitute for extern inlines, so compile as if
65115         C99-style extern inline, or a substitute, is available.
65116         * lib/argp-fmtstream.h (argp_fmtstream_set_lmargin)
65117         (__argp_fmtstream_set_lmargin, argp_fmtstream_set_rmargin)
65118         (__argp_fmtstream_set_rmargin, argp_fmtstream_set_wmargin)
65119         (__argp_fmtstream_set_wmargin, argp_fmtstream_point)
65120         (__argp_fmtstream_point) [!_LIBC && !__OPTIMIZE__]:
65121         Declare as ARGP_FS_EI, not as extern.
65122         * lib/argp.h (argp_usage, __argp_usage, _option_is_short)
65123         (__option_is_short, _option_is_end, __option_is_end)
65124         [!_LIBC && __USE_EXTERN_INLINES]:
65125         Declare as ARGP_EI, not as extern.
65127 2012-12-21  Paul Eggert  <eggert@cs.ucla.edu>
65129         AC_PROG_MKDIR_P: port workaround to pre-2.62 Autoconf
65130         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P, AC_C_RESTRICT):
65131         Use m4_ifndef([AC_AUTOCONF_VERSION], ...), not
65132         m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]),[2.62]),[-1],
65133         ...), as the latter is fatal with older Autoconfs.
65134         Problem reported and fix suggested by Eric Blake in thread starting at
65135         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00097.html>.
65137 2012-12-20  Paul Eggert  <eggert@cs.ucla.edu>
65139         AC_PROG_MKDIR_P: don't workaround if not buggy
65140         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P):
65141         Define only for Autoconf versions before 2.62.
65142         (AC_C_RESTRICT): Use documented AC_AUTOCONF_VERSION, not
65143         undocumented m4_PACKAGE_VERSION, for consistency with the
65144         abovementioned change to AC_PROG_MKDIR_P.  This should suffice
65145         since we're checking for 2.62 or later, and AC_AUTOCONF_VERSION
65146         was introduced in 2.62.
65148 2012-12-15  Ben Pfaff  <blp@cs.stanford.edu>
65150         New 'c-*printf' modules for formatted output in C locale.
65152         New module 'c-vasnprintf'.
65153         * modules/c-vasnprintf: New file.
65154         * lib/c-vasnprintf.c: New file.
65155         * lib/c-vasnprintf.h: New file.
65157         New module 'c-snprintf'.
65158         * modules/c-snprintf: New file.
65159         * modules/c-snprintf-tests: New file.
65160         * lib/c-snprintf.c: New file.
65161         * lib/c-snprintf.h: New file.
65162         * tests/test-c-snprintf.c: New file.
65163         * tests/test-c-snprintf.sh: New file.
65165         New module 'c-vsnprintf'.
65166         * modules/c-vsnprintf: New file.
65167         * modules/c-vsnprintf-tests: New file.
65168         * lib/c-vsnprintf.c: New file.
65169         * lib/c-vsnprintf.h: New file.
65170         * tests/test-c-vsnprintf.c: New file.
65171         * tests/test-c-vsnprintf.sh: New file.
65173         New module 'c-vasprintf'.
65174         * modules/c-vasprintf: New file.
65175         * modules/c-vasprintf-tests: New file.
65176         * lib/c-asprintf.c: New file.
65177         * lib/c-vasprintf.c: New file.
65178         * lib/c-vasprintf.h: New file.
65179         * tests/test-c-vasprintf.c  +: New file.
65180         * tests/test-c-vasprintf.sh: New file.
65182         New module 'c-xvasprintf'.
65183         * modules/c-xvasprintf: New file.
65184         * modules/c-xvasprintf-tests: New file.
65185         * lib/c-xasprintf.c: New file.
65186         * lib/c-xvasprintf.c: New file.
65187         * lib/c-xvasprintf.h: New file.
65188         * tests/test-c-xvasprintf.c: New file.
65189         * tests/test-c-xvasprintf.sh: New file.
65191 2012-12-18  Paul Eggert  <eggert@cs.ucla.edu>
65193         argp: better 'inline'
65194         Use extern-inline module to declare extern inline functions.
65195         This avoids some bogus warning diagnostics.  Problem discovered
65196         when modifying GNU tar to use the manywarnings module.
65197         * lib/argp.h, lib/argp-xinl.c (ARGP_EI) [!_LIBC]:
65198         * lib/argp-fmtstream.h, lib/argp-fs-xinl.c (ARGP_FS_EI) [!_LIBC]:
65199         Define based on extern-inline.
65200         * modules/argp (Depends-on): Add extern-inline.
65202 2012-12-17  Paul Eggert  <eggert@cs.ucla.edu>
65204         filemode, sys_stat: Handle MPX files a la AIX.
65205         * lib/filemode.c (ftypelet): Report 'm' for MPX files.
65206         * lib/sys_stat.in.h (S_ISMPX): New macro.
65207         * tests/test-sys_stat.c: Add tests for MPX files.
65209 2012-12-16  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
65211         x-to-1: honor $PERL
65212         * build-aux/x-to-1.in: Run $HELP2MAN via $PERL so that the user gets
65213         a chance to use his preferred version of Perl.  This is typically
65214         required by Darwin users whose default /usr/bin/perl does not have all
65215         the libraries required by help2man, and who need to use their MacPorts
65216         installation of Perl instead.
65218 2012-12-16  Akim Demaille  <akim@lrde.epita.fr>
65220         gnu-web-doc-update: add all the new files, even in new directories
65221         See http://lists.gnu.org/r/bug-gnulib/2012-12/msg00057.html
65222         * build-aux/gnu-web-doc-update (--dry-run, $dryrun): New.
65223         Use it.
65224         (main): Don't use cvsutils to get the list of unknown files,
65225         just add all the existing files and directories.
65227 2012-12-16  Akim Demaille  <akim@lrde.epita.fr>
65229         gnu-web-doc-update: improve --help
65230         * build-aux/gnu-web-doc-update: Move comments into --help.
65232 2012-12-07  Eric Wong  <normalperson@yhbt.net>
65234         mountlist: recognize more "dummy" file systems
65235         * lib/mountlist.c (ME_DUMMY_0):
65236         Add these dummy FS names to the list:
65237         - "debugfs" virtual filesystem for kernel debugging
65238         - "devpts" PTY slave filesystem
65239         - "devtmpfs" device filesystem on top of tmpfs/ramfs
65240         - "fusectl" control filesystem for FUSE
65241         - "mqueue" enumerates POSIX message queues
65242         - "rpc_pipefs" kernel <-> userspace bridge for NFS
65243         - "sysfs" is for exporting kernel objects
65244         - "devfs" device filesystem for Linux 2.4 and FreeBSD
65246 2012-12-11  Paul Eggert  <eggert@cs.ucla.edu>
65248         extern-inline: avoid incompatibility with Darwin Libc
65249         * m4/extern-inline.m4 (_GL_INLINE, _GL_EXTERN_INLINE): Do not use
65250         extern inline if __APPLE__.  Use _GL_UNUSED in the non-inline branch.
65251         Problem reported by Akim Demaille in
65252         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00023.html>.
65254 2012-12-11  Simon Josefsson  <simon@josefsson.org>
65256         gnupload: Work with GnuPG using gpg-agent (for smartcards).
65257         * build-aux/gnupload: If GnuPG is configured to use gpg-agent,
65258         let it handle password prompting.
65260 2012-12-10  Eli Zaretskii  <eliz@gnu.org>
65262         canonicalize, canonicalize-lgpl: Microsoft Windows prefix fixes
65263         * lib/canonicalize.c (canonicalize_filename_mode):
65264         * lib/canonicalize-lgpl.c (__realpath): Recompute prefix_len after
65265         fetching the current directory.  Don't overrun the beginning of
65266         rpath if there's no slashes after the MS-Windows drive letter.
65268 2012-12-08  Stefano Lattarini  <stefano.lattarini@gmail.com>
65270         maint.mk: avoid extra forks
65271         * top/maint.mk (_cfg_mk): The GNU make manual documents that
65272         "$(wildcard FILE)" expands to empty if FILE doesn't exist.
65273         So use that instead of "$(shell test -f FILE && echo FILE)".
65275 2012-12-07  Paul Eggert  <eggert@cs.ucla.edu>
65277         vasnprintf: fix ASCII_ONLY typo
65278         * lib/unistdio/u8-vasnprintf.c (FCHAR_T_ONLY_ASCII):
65279         * lib/unistdio/u16-vasnprintf.c (FCHAR_T_ONLY_ASCII):
65280         * lib/unistdio/u32-vasnprintf.c (FCHAR_T_ONLY_ASCII):
65281         New macro, replacing ASCII_ONLY.  This fixes a typo.  See thread at
65282         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00021.html>.
65284 2012-12-05  Paul Eggert  <eggert@cs.ucla.edu>
65286         list, oset, xlist, xoset: fix extern inline issue with C99
65287         This was introduced by my recent changes for 'inline'.
65288         Problem reported for gettext by Daiki Ueno in
65289         <http://lists.gnu.org/r/bug-gnulib/2012-12/msg00000.html>.
65290         * lib/gl_list.h (gl_list_nx_create_empty, gl_list_create)
65291         (gl_list_nx_create, gl_list_size, gl_list_node_value)
65292         (gl_list_node_set_value, gl_list_node_nx_set_value, gl_list_next_node)
65293         (gl_list_previous_node, gl_list_get_at)
65294         (gl_list_nx_set_at, gl_list_search, gl_list_search_from)
65295         (gl_list_search_from_to, gl_list_indexof, gl_list_indexof_from)
65296         (gl_list_indexof_from_to, gl_list_nx_add_first, gl_list_nx_add_last)
65297         (gl_list_nx_add_before, gl_list_nx_add_after, gl_list_nx_add_at)
65298         (gl_list_remove_node, gl_list_remove_at, gl_list_remove, gl_list_free)
65299         (gl_list_iterator, gl_list_iterator_from_to, gl_list_iterator_next)
65300         (gl_list_iterator_free, gl_sortedlist_search)
65301         (gl_sortedlist_search_from_to, gl_sortedlist_indexof)
65302         (gl_sortedlist_indexof_from_to, gl_sortedlist_add, gl_sortedlist_nx_add)
65303         (gl_sortedlist_remove):
65304         * lib/gl_oset.h (go_oset_nx_create_empty, gl_oset_size, gl_oset_search)
65305         (gl_oset_search_atleast, gl_oset_nx_add, gl_oset_remove, gl_oset_free)
65306         (gl_oset_iterator, gl_oset_iterator_next, gl_oset_iterator_free):
65307         * lib/gl_xlist.h (gl_list_create_empty, gl_list_create)
65308         (gl_list_node_set_value, gl_list_set_at, gl_list_add_first)
65309         (gl_list_add_last, gl_list_add_before, gl_list_add_after)
65310         (gl_list_add_at, gl_sortedlist_add):
65311         * lib/gl_xoset.h (gl_oset_create_empty, gl_oset_add):
65312         Wrap these extern decls inside "#if 0", because they are implemented
65313         as inline functions, and extern inline is not what's wanted here.
65314         It would simplify these .h files to remove the extern decls entirely,
65315         although a downside would be less-clear separation between
65316         specification and implementation.
65318 2012-11-29  Paul Eggert  <eggert@cs.ucla.edu>
65320         sys_stat: no 'static inline'
65321         * lib/sys_stat.in.h (rpl_mkdir): Now static, not static inline.
65322         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Do not require AC_C_INLINE.
65324         extern-inline: no 'static inline'
65325         * m4/extern-inline.m4 (gl_EXTERN_INLINE):
65326         Do not require AC_C_INLINE.
65327         (_GL_INLINE, _GL_EXTERN_INLINE): Define as 'static', not as
65328         'static inline', for older compilers.
65330         snippet/warn-on-use: no 'static inline'
65331         * build-aux/snippet/warn-on-use.h:
65332         Remove unnecessary 'inline' in comment.
65334         rbtree-list, rbtreehash-list: no 'static inline'
65335         * lib/gl_anyrbtree_list2.h (rotate_left, rotate_right):
65336         * lib/gl_anytree_list2.h (node_at):
65337         * lib/gl_anytreehash_list1.h (hash_resize_after_add)
65338         (gl_oset_first, add_nodes_to_buckets):
65339         Now static, not static inline.
65341         regex: no 'static inline'
65342         * lib/regex_internal.c (calc_state_hash):
65343         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain)
65344         (bitset_empty, bitset_set_all, bitset_copy, bitset_not, bitset_merge)
65345         (bitset_mask, re_string_char_size_at, re_string_wchar_at):
65346         Now static, not static inline.
65347         (inline) [__GNUC__ < 3 && _LIBC]:
65348         Remove macro; no longer needed.
65350         xvasprintf: no 'static inline'
65351         * lib/xvasprintf.c (xstrcat):
65352         Now static, not static inline.
65353         * m4/xvasprintf.m4 (gl_XVASPRINTF):
65354         Do not require AC_C_INLINE.
65356         parse-datetime, parse-duration: no 'static inline'
65357         * lib/parse-datetime.y (to_uchar):
65358         * lib/parse-duration.c (str_const_to_ul, str_const_to_l)
65359         (scale_n_add):
65360         Now static, not static inline.
65361         * m4/parse-datetime.m4 (gl_PARSE_DATETIME):
65362         * modules/parse-duration (configure.ac):
65363         Do not require AC_C_INLINE.
65365         getaddrinfo: no 'static inline'
65366         * lib/getaddrinfo.c (validate_family):
65367         Now static, not static inline.
65368         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO):
65369         Do not require AC_C_INLINE.
65371         ftruncate, fts, lstat, openat, raise: no 'static inline'
65372         * lib/ftruncate.c (chsize_nothrow):
65373         * lib/fts.c (opendirat, diropen):
65374         * lib/lstat.c (orig_lstat):
65375         * lib/openat.c (orig_openat):
65376         * lib/raise.c (raise_nothrow):
65377         Now static, not static inline.
65378         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE):
65379         * m4/fts.m4 (gl_FUNC_FTS_CORE):
65380         * m4/lstat.m4 (gl_PREREQ_LSTAT):
65381         * m4/openat.m4 (gl_PREREQ_OPENAT):
65382         * m4/raise.m4 (gl_PREREQ_RAISE):
65383         Do not require AC_C_INLINE.
65385         fflush, stat: no 'static inline'
65386         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
65387         (clear_ungetc_buffer, disable_seek_optimization)
65388         (restore_seek_optimization, update_fpos_cache):
65389         * lib/stat.c (orig_stat):
65390         Now static, not static inline.
65391         * lib/fflush.c (disable_seek_optimization, restore_seek_optimization)
65392         (update_fpos_cache):
65393         Define only if ! (defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1).
65394         * m4/fflush.m4 (gl_PREREQ_FFLUSH):
65395         * m4/stat.m4 (gl_PREREQ_STAT):
65396         Do not require AC_C_INLINE.
65398         error, filevercmp: no 'static inline'
65399         * lib/error.c (is_open, flush_stdout):
65400         * lib/filevercmp.c (order):
65401         Now static, not static inline.
65402         * m4/error.m4 (gl_PREREQ_ERROR):
65403         * modules/filevercmp (configure.ac):
65404         Do not require AC_C_INLINE.
65406         dup, execute, fatal-signal, etc.: no 'static inline'
65407         * lib/dup.c (dup_nothrow):
65408         * lib/execute.c (nonintr_close, nonintr_open):
65409         * lib/fatal-signal.c (uninstall_handlers, install_handlers):
65410         * lib/fopen.c (orig_fopen):
65411         * lib/freadseek.c (freadptrinc):
65412         * lib/freopen.c (orig_freopen):
65413         * lib/fstat.c (orig_fstat, fstat_nothrow):
65414         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit)
65415         (get_rusage_as_via_iterator):
65416         * lib/get-rusage-data.c (get_rusage_data_via_setrlimit):
65417         * lib/getdtablesize.c (_setmaxstdio_nothrow):
65418         * lib/isatty.c (_isatty_nothrow):
65419         * lib/open.c (orig_open):
65420         * lib/read.c (read_nothrow):
65421         * lib/sigprocmask.c (signal_nothrow):
65422         * lib/spawn-pipe.c (nonintr_close, nonintr_open):
65423         * lib/vasnprintf.c (MAX_ROOM_NEEDED):
65424         * lib/wait-process.c (unregister_slave_subprocess):
65425         * lib/write.c (write_nothrow):
65426         Now static, not static inline.
65427         * lib/spawn-pipe.c (nonintr_open): Define only if
65428         (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__.
65429         * m4/dup.m4 (gl_PREREQ_DUP):
65430         * m4/execute.m4 (gl_EXECUTE):
65431         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL):
65432         * m4/fopen.m4 (gl_PREREQ_FOPEN):
65433         * m4/freadseek.m4 (gl_FUNC_FREADSEEK):
65434         * m4/freopen.m4 (gl_PREREQ_FREOPEN):
65435         * m4/fstat.m4 (gl_PREREQ_FSTAT):
65436         * m4/getdtablesize.m4 (gl_PREREQ_GETDTABLESIZE):
65437         * m4/isatty.m4 (gl_PREREQ_ISATTY):
65438         * m4/open.m4 (gl_PREREQ_OPEN):
65439         * m4/read.m4 (gl_PREREQ_READ):
65440         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK):
65441         * m4/spawn-pipe.m4 (gl_SPAWN_PIPE):
65442         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF):
65443         * m4/wait-process.m4 (gl_WAIT_PROCESS):
65444         * m4/write.m4 (gl_PREREQ_WRITE):
65445         * modules/get-rusage-as, modules/get-rusage-data (configure.ac):
65446         Do not require AC_C_INLINE.
65448         c-strtod, memcoll, readutmp: no 'static inline'
65449         * lib/c-strtod.c (c_locale):
65450         * lib/memcoll.c (strcoll_loop):
65451         * lib/readutmp.c (desirable_utmp_entry):
65452         Now static, not static inline.
65453         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOLD):
65454         * m4/memcoll.m4 (gl_MEMCOLL):
65455         * m4/readutmp.m4 (gl_READUTMP):
65456         Do not require AC_C_INLINE.
65458         arctwo, md4, md5, sha1, sha256, sha512: no 'static inline'
65459         * lib/arctwo.c (to_uchar):
65460         * lib/md4.c (set_uint32):
65461         * lib/md5.c (set_uint32):
65462         * lib/sha1.c (set_uint32):
65463         * lib/sha256.c (set_uint32):
65464         * lib/sha512.c (set_uint64):
65465         Now static, not static inline.  This is a bit simpler, and doesn't
65466         affect performance with GCC and default optimization.
65467         * m4/arctwo.m4 (gl_ARCTWO):
65468         * m4/md4.m4 (gl_MD4):
65469         * m4/md5.m4 (gl_MD5):
65470         * m4/sha1.m4 (gl_SHA1):
65471         * m4/sha256.m4 (gl_SHA256):
65472         * m4/sha512.m4 (gl_SHA512):
65473         Do not require AC_C_INLINE.
65475         cond, lock, thread: better 'inline'
65476         * lib/glthread/cond.c, lib/glthread/cond.h (_GLTHREAD_COND_INLINE):
65477         * lib/glthread/thread.c, lib/glthread/thread.h (_GLTHREAD_THREAD_INLINE):
65478         New macros.  Use them instead of static inline, for header functions.
65479         * lib/glthread/cond.c (gl_waitqueue_init, gl_waitqueue_remove)
65480         (gl_waitqueue_notify_first, gl_waitqueue_notify_all):
65481         * lib/glthread/lock.c (gl_waitqueue_init)
65482         (gl_waitqueue_notify_first, gl_waitqueue_notify_all):
65483         * lib/glthread/thread.c (get_current_thread_handle):
65484         Change 'static inline' to 'inline'.
65485         * lib/glthread/cond.h, lib/glthread/thread.h:
65486         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65487         * m4/cond.m4 (gl_COND):
65488         * m4/lock.m4 (gl_PREREQ_LOCK):
65489         * m4/thread.m4 (gl_THREAD):
65490         Do not require AC_C_INLINE.
65491         * modules/cond, modules/thread (Depends-on): Add extern-inline.
65493         chdir-long, cycle-check, savewd: better 'inline'
65494         * lib/chdir-long.c (cdb_init, cdb_fchdir, cdb_free)
65495         (find_non_slash):
65496         * lib/cycle-check.c (is_zero_or_power_of_two):
65497         * lib/savewd.c (savewd_delegating):
65498         Change 'static inline' to 'inline'.
65499         * lib/savewd.c, lib/savewd.h (SAVEWD_INLINE): New macro.
65500         Replace all remaining uses of 'static inline' with it.
65501         * lib/savewd.h:
65502         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65503         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG):
65504         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
65505         * m4/savewd.m4 (gl_SAVEWD):
65506         Do not require AC_C_INLINE.
65507         * modules/savewd (Depends-on): Add extern-inline.
65509         base32, base64: no need for 'inline'
65510         * lib/base32.c (to_uchar, get_8, decode_8):
65511         * lib/base64.c (to_uchar, get_4, decode_4):
65512         Change 'static inline' to 'inline'.
65513         * m4/base32.m4 (gl_PREREQ_BASE32):
65514         * m4/base64.m4 (gl_PREREQ_BASE64):
65515         Do not require AC_C_INLINE.
65517         array-oset, linkedhash-list, rbtree-oset: no need for 'inline'
65518         * lib/gl_array_oset.c (gl_array_nx_add_at):
65519         (gl_array_remove_at):
65520         * lib/gl_linkedhash_list.c (hash_resize_after_add)
65521         (add_to_bucket, remove_from_bucket):
65522         * lib/gl_rbtree_oset.c (rotate_left, rotate_right):
65523         Change 'static inline' to 'static', as it's simpler to omit
65524         'inline' unless there's a significant performance advantage.
65526         list, oset, xlist, xoset, xsublist: simplify via extern inline
65527         * lib/gl_list.h, lib/gl_list.c (GL_LIST_INLINE):
65528         * lib/gl_oset.c, lib/gl_oset.h (GL_OSET_INLINE):
65529         * lib/gl_xlist.c, lib/gl_xlist.h (GL_XLIST_INLINE):
65530         * lib/gl_xoset.c, lib/gl_xoset.h (GL_XOSET_INLINE):
65531         * lib/gl_xsublist.c, lib/gl_xsublist.h (GL_XSUBLIST_INLINE):
65532         New macro.  Replace all uses of 'static inline' with it.
65533         [HAVE_INLINE]: Implement functions as *_INLINE functions,
65534         instead of as macros FOO that are defined to static inline
65535         functions FOO_inline.
65536         * lib/gl_list.c, lib/gl_oset.c, lib/gl_xlist.c, lib/gl_xoset.c:
65537         * lib/gl_xsublist.c:
65538         Reimplement from scratch, by defining the corresponding *_INLINE
65539         macro and including the corresponding .h file.  This is simpler.
65540         * modules/list, modules/oset, modules/xlist, modules/xoset:
65541         (Files): Remove m4/gl_list.m4.
65542         (configure.ac): Remove gl_LIST.
65543         * m4/gl_list.m4: Remove.
65544         * modules/list, modules/oset, modules/xlist, modules/xoset:
65545         * modules/xsublist:
65546         (Depends-on): Depend on extern-inline, not inline.
65548         xalloc: better 'inline'
65549         * lib/xmalloc.c, lib/xalloc.h (XALLOC_INLINE):
65550         New macro.  Replace all uses of 'static inline' with it.
65551         (static_inline): Remove.
65552         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
65553         Let 'extern inline' do the work automatically, instead of doing
65554         it by hand.
65555         * m4/xalloc.m4 (gl_PREREQ_XALLOC, gl_PREREQ_XMALLOC):
65556         Remove.  All uses removed.
65557         * modules/xalloc (Depends-on): Remove 'inline'.  Add 'extern-inline'.
65559         gethrxtime: better 'inline'
65560         * lib/xtime.c: New file.
65561         * lib/gethrxtime.c, lib/gethrxtime.h (GETHRXTIME_INLINE):
65562         * lib/xtime.h (XTIME_INCLUDE):
65563         New macros.  Replace all uses of 'static inline' with them.
65564         * lib/gethrxtime.c (gethrxtime): Define only if
65565         ! (HAVE_ARITHMETIC_HRTIME_T && HAVE_DECL_GETHRTIME), since
65566         this source file is now always compiled, because of the extern inline.
65567         * lib/gethrxtime.h, lib/xtime.h:
65568         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65569         * m4/gethrxtime.m4 (gl_GETHRXTIME): Do not check for clock macros
65570         if gethrtime works, as they're not needed in that case.
65571         (gl_XTIME): Do not require AC_C_INLINE.
65572         (gl_PREREQ_GETHRXTIME): Remove; all uses removed, as it's always
65573         compiled now.  Move the check into gl_GETHRXTIME.
65574         * modules/gethrxtime (Files, lib_SOURCES): Add lib/xtime.c.
65575         (Depends-on): Add extern-inline.
65576         (configure.ac): gethrxtime is always compiled now.
65577         (lib_SOURCES): Add gethrxtime.c.
65579         wctype-h: better 'inline'
65580         * lib/wctype-h.c: New file.
65581         * lib/wctype.in.h (_GL_WCTYPE_INLINE):
65582         New macro.  Replace all uses of 'static inline' with it.
65583         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65584         * m4/wctype_h.m4 (gl_WCTYPE_H): Do not require AC_C_INLINE.
65585         * modules/wctype-h (Files, lib_SOURCES): Add lib/wctype-h.c.
65586         (Depends-on): Add extern-inline.
65588         unistd: better 'inline'
65589         * lib/unistd.c: New file.
65590         * lib/unistd.in.h (_GL_UNISTD_INLINE):
65591         New macro.  Replace all uses of 'static inline' with it.
65592         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65593         * m4/unistd_h.m4 (gl_UNISTD_H): Do not require AC_C_INLINE.
65594         * modules/unistd (Files, lib_SOURCES): Add lib/unistd.c.
65595         (Depends-on): Add extern-inline.
65597         sys_socket: better 'inline'
65598         * lib/sys_socket.c: New file.
65599         * lib/sys_socket.in.h (_GL_SYS_SOCKET_INLINE):
65600         New macro.  Replace all uses of 'static inline' with it.
65601         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65602         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Do not require AC_C_INLINE.
65603         * modules/sys_socket (Files, lib_SOURCES): Add lib/sys_socket.c.
65604         (Depends-on): Add extern-inline.
65606         stdio: better 'inline'
65607         * lib/stdio.c: New file.
65608         * lib/stdio.in.h (_GL_STDIO_INLINE):
65609         New macro.  Replace all uses of 'static inline' with it.
65610         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65611         * m4/stdio_h.m4 (gl_STDIO_H): Do not require AC_C_INLINE.
65612         * modules/stdio (Files, lib_SOURCES): Add lib/stdio.c.
65613         (Depends-on): Add extern-inline.
65615         sigaction: better 'inline'
65616         * lib/sig-handler.c: New file.
65617         * lib/sig-handler.h (SIG_HANDLER_INLINE):
65618         New macro.  Replace all uses of 'static inline' with it.
65619         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65620         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): Do not require AC_C_INLINE.
65621         * modules/sigaction (Files, lib_SOURCES): Add lib/sig-handler.c.
65622         (Depends-on): Add extern-inline.
65624         selinux-h: better 'inline'
65625         * lib/se-context.c, lib/se-selinux.c: New files.
65626         * lib/getfilecon.c (map_to_failure): Omit 'inline' for static function.
65627         * lib/se-context.in.h (SE_CONTEXT_INLINE):
65628         New macro.  Replace all uses of 'static inline' with it.
65629         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65630         * lib/se-selinux.in.h (SE_SELINUX_INLINE):
65631         New macro.  Replace all uses of 'static inline' with it.
65632         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65633         * modules/selinux-h (Files, lib_SOURCES):
65634         Add lib/se-context.c, lib/se-selinux.c.
65635         (Depends-on): Add extern-inline.
65636         (configure.ac): Do not require AC_C_INLINE.
65638         pthread: better 'inline'
65639         * lib/pthread.c: New file.
65640         * lib/pthread.in.h (_GL_PTHREAD_INLINE):
65641         New macro.  Replace all uses of 'static inline' with it.
65642         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65643         * m4/pthread.m4 (gl_PTHREAD_CHECK):
65644         Add AC_LIBOBJ([pthread]).  Do not require AC_C_INLINE.
65645         * modules/pthread (Files): Add lib/pthread.c.
65646         (Depends-on): Add extern-inline.
65648         math: better 'inline'
65649         * lib/math.c: New file.
65650         * lib/math.in.h (_GL_MATH_INLINE):
65651         New macro.  Replace all uses of 'static inline' with it.
65652         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65653         * m4/math_h.m4 (gl_MATH_H):
65654         Do not require AC_C_INLINE.
65655         * modules/math (Files, lib_SOURCES):
65656         Add lib/math.c.
65657         (Depends-on): Add extern-inline.
65659         count-one-bits: better 'inline'
65660         * lib/count-one-bits.c: New file.
65661         * lib/count-one-bits.h (COUNT_ONE_BITS_INLINE):
65662         New macro.  Replace all uses of 'static inline' with it.
65663         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65664         * m4/count-one-bits.m4 (gl_COUNT_ONE_BITS):
65665         Do not require AC_C_INLINE.
65666         * modules/count-one-bits (Files, lib_SOURCES):
65667         Add lib/count-one-bits.c.
65668         (Depends-on): Add extern-inline.
65670         count-leading-zeros: better 'inline'
65671         * lib/count-leading-zeros.c: New file.
65672         * lib/count-leading-zeros.h (COUNT_LEADING_ZEROS_INLINE):
65673         New macro.  Replace all uses of 'static inline' with it.
65674         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65675         * m4/count-leading-zeros.m4 (gl_COUNT_LEADING_ZEROS):
65676         Do not require AC_C_INLINE.
65677         * modules/count-leading-zeros (Files, lib_SOURCES):
65678         Add lib/count-leading-zeros.c.
65679         (Depends-on): Add extern-inline.
65681         bitrotate: better 'inline'
65682         * lib/bitrotate.c: New file.
65683         * lib/bitrotate.h (BITROTATE_INLINE):
65684         New macros.
65685         Replace all uses of 'static inline' with them.
65686         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
65687         * modules/bitrotate (Files, lib_SOURCES): Add lib/bitrotate.c.
65688         (Depends-on): Add extern-inline.
65689         (configure.ac): Do not require AC_C_INLINE.
65691 2012-11-20  Theophile Ranquet  <ranquet@lrde.epita.fr>
65693         maint.mk: avoid gratuitous failure
65694         Reported by Stefano Lattarini in
65695         <http://lists.gnu.org/r/bug-bison/2012-11/msg00022.html>
65696         * top/maint.mk (public-submodule-commit): Quote more safely.
65698 2012-11-20  Eli Zaretskii  <eliz@gnu.org>
65700         canonicalize, canonicalize-lgpl: support MS-Windows file names
65701         See <http://lists.gnu.org/r/bug-gnulib/2012-11/msg00074.html>
65702         for test cases, which it'd be nice to add at some point.
65703         * lib/canonicalize.c, lib/canonicalize-lgpl.c: Include dosname.h.
65704         * lib/canonicalize.c (canonicalize_filename_mode):
65705         * lib/canonicalize-lgpl.c (__realpath):
65706         Use FILE_SYSTEM_PREFIX_LEN instead of assuming that the first
65707         slash is at the beginning of the file name.  Use ISSLASH, instead
65708         of a literal '/'.  Use IS_ABSOLUTE_FILE_NAME instead of comparing
65709         the first character with '/'.  Test for
65710         DOUBLE_SLASH_IS_DISTINCT_ROOT only if the file name does not begin
65711         with a drive letter.
65712         * lib/canonicalize.c (SLASHES): New macro.
65713         (canonicalize_filename_mode): Use SLASHES instead of a literal "/".
65715 2012-11-17  Dmitry V. Levin  <ldv@altlinux.org>
65717         fts: introduce FTS_VERBATIM
65718         * lib/fts_.h (FTS_VERBATIM): New bit flag.
65719         (FTS_OPTIONMASK, FTS_NAMEONLY, FTS_STOP): Adjust.
65720         * lib/fts.c (fts_open): Honor it.
65722 2012-11-09  Pádraig Brady  <P@draigBrady.com>
65724         getlogin-tests: allow errno == ENXIO
65725         * tests/test-getlogin.c (main): Skip tests if getlogin fails
65726         with errno == ENXIO (No controlling tty).
65727         getlogin_r-tests: Likewise. Also allow errno == ENOENT
65728         * tests/test-getlogin_r.c (main): Skip tests if getlogin_r fails
65729         with errno == ENOENT.  This was reported to happen in various
65730         situations on GNU/Linux.
65732 2012-11-09  Paul Eggert  <eggert@cs.ucla.edu>
65734         getlogin-tests: allow errno == ENOENT
65735         * tests/test-getlogin.c (main): Skip tests if getlogin fails
65736         with errno == ENOENT.  This happened to me on Ubuntu 12.04.1 x86,
65737         when running a test in an Emacs shell buffer.
65739 2012-11-08  Jim Meyering  <jim@meyering.net>
65741         tests/nap.h: avoid warning about unused variable
65742         * tests/nap.h (nap_works): Remove now-unused declaration of "result".
65744         prefix-gnulib-mk: avoid overzealous "lib/"-prefix addition
65745         * build-aux/prefix-gnulib-mk (prefix): Tighten a regexp to require
65746         white space before each of the special-cased file names, to avoid
65747         adding "lib/" after $(libdir)/.  Reported by Matias A. fonzo
65748         in http://bugs.gnu.org/12830.
65750 2012-11-08  Paul Eggert  <eggert@cs.ucla.edu>
65752         fcntl-h: default O_SEARCH, O_EXEC back to O_RDONLY
65753         O_PATH doesn't work with Linux kernel 3.6.5, as fchmod (fd, ...)
65754         fails with errno == EBADF when fd is opened with O_PATH.
65755         Reported by Jim Meyering in
65756         <http://lists.gnu.org/r/bug-gnulib/2012-11/msg00026.html>.
65757         * doc/posix-headers/fcntl.texi (fcntl.h): Document this.
65758         * lib/fcntl.in.h (O_EXEC, O_SEARCH) [O_PATH]: Default back to O_RDONLY.
65760 2012-11-07  Paul Eggert  <eggert@cs.ucla.edu>
65762         test-utimens: speed up by taking shorter naps
65763         * tests/nap.h (lt_mtime, get_mtime, nap_works, guess_delay):
65764         New functions.
65765         (nap): Use them, to do a better job of guessing the delay.
65766         On Fedora 17 with ext4 atop md atop hard disks, this made
65767         test-utimens run 10x faster, because the test napped for
65768         1 ms at a time rather than 20 ms.  Reported by Stefano Lattarini in
65769         <http://bugs.gnu.org/12820#11>.
65771 2012-11-07  Jim Meyering  <jim@meyering.net>
65773         mountlist.c: fix a compilation failure
65774         * lib/mountlist.c (read_file_system_list): Fix a compilation failure
65775         I introduced while transforming commit v0.0-7683-g613bcb6
65777 2012-11-05  Paul Eggert  <eggert@cs.ucla.edu>
65779         errno: port to LynxOS 178 2.2.2
65780         Problem reported by Joel Brobecker in
65781         <http://lists.gnu.org/r/bug-gnulib/2012-10/msg00088.html>.
65782         * doc/posix-headers/errno.texi (errno.h): Document this.
65783         * lib/errno.in.h (EILSEQ, GNULIB_defined_EILSEQ) [!EILSEQ]: New macros.
65784         * lib/strerror-override.c, lib/strerror-override.h (strerror_override):
65785         Supply a string for EILSEQ.
65786         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Check for EILSEQ.
65788 2012-11-05  Paul Eggert  <eggert@cs.ucla.edu>
65790         fcntl-h: default O_SEARCH, O_EXEC to O_PATH if available
65791         Linux kernel 2.6.39 introduced O_PATH (see
65792         <http://lwn.net/Articles/433854/>) and this is a better fallback
65793         for O_SEARCH and O_EXEC than O_RDONLY, if O_PATH is available.
65794         * doc/posix-headers/fcntl.texi (fcntl.h): Document this.
65795         * lib/fcntl.in.h (O_EXEC, O_SEARCH) [O_PATH]: Default to O_PATH.
65796         * lib/fcntl.in.h (O_ACCMODE):
65797         * tests/test-fcntl-h.c (main):
65798         Do not reject O_ACCMODE merely because it has more than the
65799         minimal number of bits, as POSIX allows extensions here.
65801 2012-11-04  Andrew Warshall  <warshall@99main.com>  (tiny change)
65803         mountlist: do not classify a bind-mounted dir entry as "dummy"
65804         * lib/mountlist.c (ME_DUMMY_0): Rename from ME_DUMMY, but omit
65805         the "none"-testing clause.
65806         (ME_DUMMY) [MOUNTED_GETMNTENT1]: New macro to encapsulate the
65807         exception for bind-mounted directories.
65809 2012-11-01  Akim Demaille  <akim@lrde.epita.fr>
65811         quote: provide a means to escape strings with nul characters
65812         * lib/quote.h, lib/quotearg.c (quote_mem, quote_n_mem): New functions.
65813         (quote, quote_n): Rename formal arguments for consistency with
65814         quotearg.
65816 2012-10-30  Paul Eggert  <eggert@cs.ucla.edu>
65818         test-raise: don't assume 199 is an invalid signal
65819         * tests/test-raise.c (main): Don't assume 199 is not a signal number.
65821         sh-quote-tests: port to Solaris 9
65822         * modules/sh-quote-tests (test_sh_quote_LDADD): Add @LIBINTL@.
65823         Problem reported by Dagobert Michelsen in
65824         <http://lists.gnu.org/r/bug-gnulib/2012-10/msg00114.html>.
65826 2012-10-28  Jim Meyering  <jim@meyering.net>
65828         maint.mk: rename a new configurable variable
65829         * top/maint.mk (_gl_translatable_string_re): Rename from
65830         translation-markers: _gl_ prefix to insulate from user Makefile code,
65831         and the _re suffix to inform that it's a regular expression.
65833 2012-10-26  Eric Blake  <eblake@redhat.com>
65835         maint.mk: let packages tweak sc_po_check pattern
65836         * top/maint.mk (sc_po_check): Add translation-markers, to allow
65837         finding files with other translation markers.
65839 2012-10-16  Paul Eggert  <eggert@cs.ucla.edu>
65841         euidaccess: speed up 'configure' on GNU hosts
65842         * m4/euidaccess.m4 (gl_FUNC_NONREENTRANT_EUIDACCESS):
65843         Check for setregid here, not in gl_PREREQ_EUIDACCESS, since
65844         it's needed only in this case.  Use AC_CHECK_DECLS, not
65845         AC_CHECK_DECLS_ONCE.
65846         (gl_PREREQ_EUIDACCESS): Do not use AC_CHECK_HEADERS_ONCE libgen.h
65847         or AC_REQUIRE for AC_FUNC_GETGROUPS.
65849         * lib/regexec.c (re_search_internal): Fix grammar in comment.
65851 2012-10-15  Paul Eggert  <eggert@cs.ucla.edu>
65853         fchmodat, fchownat, fstatat: port to non-inlining compilers
65854         Problem reported for FreeBSD 9 by Jim Meyering in
65855         <http://lists.gnu.org/r/bug-gnulib/2012-10/msg00070.html>.
65856         * lib/chmodat.c, lib/chownat.c, lib/statat.c:
65857         New files, which define FCHMODAT_INLINE etc.
65858         * lib/fchmodat.c (FCHMODAT_INLINE):
65859         * lib/fchownat.c (FCHOWNAT_INLINE):
65860         * lib/fstatat.c (FSTATAT_INLINE):
65861         Remove, as chmodat.c etc. now do this.
65862         * modules/fchmodat (Files): Add lib/chmodat.c.
65863         * modules/fchownat (Files): Add lib/chownat.c.
65864         * modules/fstatat (Files): Add lib/statat.c.
65866 2012-10-15  Jim Meyering  <jim@meyering.net>
65868         fchmodat.c, fchownat.c: compile-impeding typos
65869         * lib/fchmodat.c (FCHMODAT_INLINE): Fix typo: s/#include/#define/
65870         * lib/fchownat.c (FCHOWNAT_INLINE): Likewise.
65871         Introduced in commit v0.0-7636-gd202279.
65873 2012-10-15  Paul Eggert  <eggert@cs.ucla.edu>
65875         fcntl-h: support GNU flags like O_IGNORE_CTTY
65876         * doc/posix-headers/fcntl.texi (fcntl.h): Support O_IGNORE_CTTY,
65877         O_NOLINK, and O_NOTRANS.  These flags are nonzero on GNU/Hurd
65878         systems.  Discovered when using fcntl-h with GNU Emacs, which uses
65879         O_IGNORE_CTTY.  Fix misspelling of F_SETLKW.
65880         * lib/fcntl.in.h (O_IGNORE_CTTY, O_NOLINK, O_NOTRANS):
65881         Define to 0 if not already defined.
65882         * tests/test-fcntl-h.c: Test these new flags.
65884 2012-10-14  Paul Eggert  <eggert@cs.ucla.edu>
65886         faccessat, etc.: support AT_FDCWD-only use
65887         * lib/at-func.c: If GNULIB_SUPPORT_ONLY_AT_FDCWD, then support
65888         this function only if its first argument is AT_FDCWD.
65889         Emacs wants faccessat for AT_EACCESS but not for any first-arg
65890         values other than AT_FDCWD, so it doesn't want all the openat
65891         machinery with fchdir etc.
65892         * modules/faccessat, modules/fchmodat, modules/fchownat (Files):
65893         * modules/fstatat, modules/mkdirat, modules/openat (Files):
65894         * modules/unlinkat (Files):
65895         Remove lib/openat-priv.h, as at-internal supplies this file.
65896         Removing this file here allows us to support programs like Emacs
65897         that avoid at-internal.
65899         faccessat: speed up 'configure' on mainstream hosts
65900         * m4/faccessat.m4 (gl_PREREQ_FACCESSAT):
65901         Use AT_CHECK_FUNCS for 'access', not AC_CHECK_FUNCS_ONCE,
65902         since it's only on unusual platforms that we need to check for
65903         'access', and it's better not to slow 'configure' down on all
65904         platforms.
65906         faccessat: port to Solaris 10
65907         * lib/faccessat.c: Include <fcntl.h>, for AT_EACCESS.
65908         Needed on Solaris 10, which doesn't have AT_EACCESS,
65909         so we need the Gnulib fcntl.h, which defines it.
65911 2012-10-14  Pádraig Brady  <P@draigBrady.com>
65912         canonicalize: fix C89 compilation
65913         * lib/canonicalize.c (canonicalize_filename_mode): Swap order of
65914         declarations so C89 is supported.  Also remove the comment
65915         referencing memorty allocation as the suggested feature could
65916         not be implemented as suggested.
65917         Reported by Michael Goffioul.
65919 2012-10-12  Paul Eggert  <eggert@cs.ucla.edu>
65921         group-member: omit unnecessary dependencies
65922         This is for Emacs, which has its own allocator and where we
65923         don't want to use xalloc.
65924         * lib/group-member.c: Include xalloc-oversized.h, not xalloc.h,
65925         since we no longer use xmalloc.  Do not include stdbool.h, since
65926         the changes below happen to remove the only use of bool.
65927         (GROUPBUF_SIZE): New constant.
65928         (struct group_info): Remove n_groups member.  Add groupbuf member.
65929         This lets us get the groups without using malloc, usually.
65930         (free_group_info, get_group_info): Adjust to this.
65931         (get_group_info): Return the number of groups found, or -1 on error.
65932         Use plain malloc not xmalloc, and treat its failure as if there
65933         are no groups, as the user already loses in case of error.
65934         (group_member): Simplify, based on changes to get_group_info.
65935         * modules/group-member (Depends-on): Remove dependencies on
65936         xalloc and stdbool.  Add dependency on xalloc-oversized.
65938 2012-10-08  Alexandre Duret-Lutz  <adl@lrde.epita.fr>  (tiny change)
65940         gethrxtime: port to C++
65941         * lib/gethrxtime.h, lib/xtime.h [__cplusplus]: Add extern "C".
65943 2012-10-04  Paul Eggert  <eggert@cs.ucla.edu>
65945         ptsname: fix macro-name typo
65946         * lib/stdlib.in.h (ptsname): Fix misspelling of GNULIB_NAMESPACE.
65948 2012-10-03  Simon Josefsson  <simon@josefsson.org>
65950         inttostr: Relax license.
65951         * modules/inttostr (License): Change from LGPL to LGPLv2+.
65953 2012-10-03  Eric Blake  <eblake@redhat.com>
65955         ptsname_r: support ptys returned by FreeBSD posix_openpt
65956         * lib/ptsname_r.c (__ptsname_r): Don't munge name if it already
65957         lives in /dev/pts/.
65959 2012-10-02  Eric Blake  <eblake@redhat.com>
65961         pselect: reject invalid file descriptors
65962         * m4/pselect.m4 (gl_FUNC_PSELECT): Probe for FreeBSD bug.
65963         * lib/pselect.c (rpl_pselect) [!win32]: Work around it.
65964         * modules/pselect (Depends-on): Add dup2.
65965         * doc/posix-functions/pselect.texi (pselect): Document this.
65967         select: reject invalid file descriptors
65968         * m4/select.m4 (gl_FUNC_SELECT): Probe for FreeBSD bug.
65969         * lib/select.c (rpl_select) [!win32]: Work around it.
65970         * modules/select (Depends-on): Add dup2.
65971         * doc/posix-functions/select.texi (select): Document this.
65973         select: enhance test
65974         * tests/test-select.h (do_select_bad_nfd_nowait, test_bad_nfd):
65975         New functions.
65976         (test_function): Enhance test.
65977         (do_select_bad_fd): Avoid any stale errno values.
65979         ptsname: reject invalid file descriptors
65980         http://www.austingroupbugs.net/view.php?id=503
65981         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Probe for FreeBSD bug.
65982         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Add new witness.
65983         * modules/stdlib (Makefile.am): Replace witness.
65984         * lib/stdlib.in.h (ptsname): Allow for replacement.
65985         * modules/ptsname (configure.ac): Trigger replacement.
65986         * doc/posix-functions/ptsname.texi (ptsname): Document this.
65988 2012-10-02  Nikos Mavrogiannopoulos  <nmav@gnutls.org>  (tiny change)
65990         hash-pjw-bare: new module
65991         * lib/hash-pjw-bare.c: New file, very much like hash-pjw.c.
65992         * lib/hash-pjw-bare.h: Likewise.
65993         * modules/hash-pjw-bare: New file.
65994         * MODULES.html.sh (Misc): Add it.
65996 2012-10-02  Eric Blake  <eblake@redhat.com>
65998         manywarnings: cater to more gcc infelicities
65999         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add test for
66000         -Wuninitialized without -O.
66002 2012-10-01  Ed Maste  <emaste@freebsd.org>  (tiny change)
66004         select, poll tests: Make setsockopt invocation effective.
66005         * tests/test-poll.c (open_server_socket): Move setsockopt() call before
66006         the bind() call.
66007         * tests/test-select.h (open_server_socket): Likewise.
66009 2012-09-30  Paul Eggert  <eggert@cs.ucla.edu>
66011         sockets, sys_stat: restore AC_C_INLINE
66012         This undoes the 2012-09-22 patch.
66013         * m4/sockets.m4 (gl_SOCKETS):
66014         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H):
66015         Restore AC_C_INLINE, since MSVC requires __inline or _inline
66016         and does not support plain 'inline'.  Reported by Bruno Haible in
66017         <http://lists.gnu.org/r/bug-gnulib/2012-09/msg00183.html>.
66019 2012-09-30  Bruno Haible  <bruno@clisp.org>
66021         localeconv tests: Avoid test failure on OpenIndiana.
66022         * tests/test-localeconv.c (main): On OpenIndiana (a Solaris 11 variant)
66023         skip the 'grouping' and 'mon_grouping' tests.
66024         Reported by Jim Meyering.
66026 2012-09-30  Bruno Haible  <bruno@clisp.org>
66028         havelib: Follow libtool developments.
66029         * m4/lib-ld.m4: Rebase on libtool.m4 from libtool-2.4.
66030         Suggested by Simon Josefsson.
66032 2012-09-29  Jim Meyering  <meyering@redhat.com>
66034         fstatat.c: fix a compile-impeding typo
66035         * lib/fstatat.c (FSTATAT_INLINE): Fix typo: s/#include/#define/
66036         Introduced in commit v0.0-7636-gd202279.
66037         Mats Erik Andersson reported the resulting OpenBSD compilation failure.
66039 2012-09-28  Akim Demaille  <akim@lrde.epita.fr>
66041         extern-inline: provide a -Wundef safe config.h
66042         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Protect
66043         "#if __GNUC_STDC_INLINE__" with "defined __GNUC_STDC_INLINE__"
66044         to produce a -Wundef warning free config.h.
66046 2012-09-26  Paul Eggert  <eggert@cs.ucla.edu>
66048         hash-pjw: relax license to LGPLv2+
66049         * modules/hash-pjw (License): Relax, with consent of author.
66051 2012-09-25  Akim Demaille  <akim@lrde.epita.fr>
66053         maint.mk: fix strict vs. lazy variable issues with RELEASE
66054         * top/maint.mk (_equal): New function.
66055         (member_check): Strip the result to avoid spurious spaces.
66056         (url_dir_list): Do not use ifeq, which is strict, as it will
66057         require RELEASE_TYPE to be defined.
66058         (announcement_Cc_, announcement_mail_headers_): Likewise: instead
66059         of relying on ifeq, use $(release_type) to dispatch (lazily) onto...
66060         (announcement_Cc_alpha,announcement_mail_headers_alpha)
66061         (announcement_Cc_beta,announcement_mail_headers_beta)
66062         (announcement_Cc_stable,announcement_mail_headers_stable): these.
66063         (release): Do not depend on $(release-type), as it forces its
66064         evaluation.  Bounce to it.
66066 2012-09-25  Akim Demaille  <akim@lrde.epita.fr>
66068         maint.mk: formatting changes
66069         * top/maint.mk: Indent bodies of if's.
66071 2012-09-21  Akim Demaille  <akim@lrde.epita.fr>
66073         maint.mk: factor the validation of RELEASE_TYPE
66074         With help from Jim Meyering.
66075         http://lists.gnu.org/r/bug-gnulib/2012-09/msg00132.html
66076         * top/maint.mk (_empty, _sp): Move their definition earlier.
66077         (member-check, release-type): New.
66078         Use the latter instead of $(RELEASE_TYPE).
66079         Remove now useless local checks.
66081 2012-09-20  Akim Demaille  <akim@lrde.epita.fr>
66083         maint.mk: provide "make upload" to ease uploading
66084         See
66085         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00028.html>.
66086         Do not depend simply on the current $(VERSION), as there may have been
66087         new commits since the tarball generation.  Rather, rely on $(RELEASE),
66088         as "make release-commit" already does.
66090         For consistency, add "make release RELEASE='X.Y TYPE'" as an alias for
66091         "make TYPE".
66093         * top/maint.mk (upload_command, upload, release): New.
66094         (RELEASE_TYPE): If undefined, default to the second word of $(RELEASE).
66095         (VERSION): first word of $(RELEASE) is always right.
66096         (emit_upload_commands): Adjust.
66097         * top/README-release: Update.
66099 2012-09-20  Akim Demaille  <akim@lrde.epita.fr>
66101         maint.mk: silent rules
66102         With help from Stefano Lattarini.
66103         * top/maint.mk (writable-files): Use $(AM_V_GEN).
66104         (announcement): Use $(AM_V_at).
66106 2012-09-24  Paul Eggert  <eggert@cs.ucla.edu>
66108         localename: port gl_locale_name_thread_unsafe to FreeBSD
66109         * lib/localename.c (gl_locale_name_thread_unsafe): Port to FreeBSD,
66110         and use the simpler FreeBSD implementation on Mac OS X as well.
66111         Original idea suggested by Ed Maste in
66112         <http://lists.gnu.org/r/bug-gnulib/2012-09/msg00094.html>.
66114 2012-09-22  Paul Eggert  <eggert@cs.ucla.edu>
66116         binary-io, eealloc, mbfile, mbiter, mbutil, xsize: better 'inline'
66117         * lib/binary-io.c, lib/eealloc.c, lib/mbfile.c, lib/mbiter.c:
66118         * lib/mbuiter.c, lib/xsize.c: New files.
66119         * lib/binary-io.h (BINARY_IO_INLINE):
66120         * lib/eealloc.h (EEALLOC_INLINE):
66121         * lib/mbfile.h (MBFILE_INLINE):
66122         * lib/mbiter.h (MBITER_INLINE):
66123         * lib/mbuiter.h (MBUITER_INLINE):
66124         * lib/xsize.h (XSIZE_INLINE):
66125         New macros.
66126         Replace all uses of 'static inline' with them.
66127         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66128         * m4/eealloc.m4 (gl_EEALLOC):
66129         * m4/mbfile.m4 (gl_MBFILE):
66130         * m4/mbiter.m4 (gl_MBITER):
66131         * m4/xsize.m4 (gl_XSIZE):
66132         Do not require AC_C_INLINE.
66133         * modules/binary-io (Files, lib_SOURCES): Add lib/binary-io.c
66134         * modules/eealloc (Files, lib_SOURCES): Add lib/eealloc.c.
66135         * modules/mbfile (Files, lib_SOURCES): Add lib/mbfile.c.
66136         * modules/mbiter (Files, lib_SOURCES): Add lib/mbiter.c.
66137         * modules/mbuiter (Files, lib_SOURCES): Add lib/mbuiter.c.
66138         * modules/xsize (Files, lib_SOURCES): Add lib/xsize.c.
66139         * modules/binary-io, modules/eealloc, modules/mbfile:
66140         * modules/mbiter, modules/mbuiter:
66141         (Depends-on): Add extern-inline.
66143         pipe-filter-gi, pipe-filter-ii: better use of 'inline'
66144         * lib/pipe-filter-aux.c: New file.
66145         * lib/pipe-filter-aux.h (PIPE_FILTER_AUX_INLINE): New macro.
66146         Replace all uses of 'static inline' with it.
66147         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66148         * lib/pipe-filter-gi.c (filter_init, filter_cleanup)
66149         (filter_retcode): No real need for inline here.
66150         * modules/pipe-filter-gi, modules/pipe-filter-ii:
66151         (Files): Add lib/pipe-filter-aux.c.
66152         (Depends-on): Add extern-inline.
66153         (configure.ac): Do not require AC_C_INLINE.
66154         (lib_SOURCES): Add pipe-filter-aux.c.
66156         fdutimensat: omit unnecessary AC_C_INLINE
66157         * modules/fdutimensat (configure.ac): Remove AC_C_INLINE.
66159         fchmodat, fchownat, fstatat: use extern-inline
66160         * lib/fchmodat.c, lib/openat.h (FCHMODAT_INLINE):
66161         * lib/fchownat.c, lib/openat.h (FCHOWNAT_INLINE):
66162         * lib/fstatat.c, lib/openat.h (FSTATAT_INLINE):
66163         New macros.
66164         * lib/openat.h:
66165         Replace all uses of 'static inline' with them.
66166         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66167         * modules/fchmodat, modules/fchownat, modules/fstatat:
66168         * modules/openat-h:
66169         (Depends-on):
66170         Add extern-inline.
66171         (configure.ac): Remove AC_C_INLINE.
66173         acl, mbchar, priv-set: use extern-inline
66174         * lib/set-mode-acl.c, lib/acl-internal.h (ACL_INTERNAL_INLINE):
66175         * lib/mbchar.c, lib/mbchar.h (MBCHAR_INLINE):
66176         * lib/priv-set.c, lib/priv-set.h (PRIV_SET_INLINE):
66177         New macros.
66178         * lib/acl-internal.h, lib/mbchar.h, lib/priv-set.h:
66179         Replace all uses of 'static inline' with it.
66180         Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66181         * m4/acl.m4 (gl_FUNC_ACL):
66182         * m4/mbchar.m4 (gl_MBCHAR):
66183         * m4/priv-set.m4 (gl_PRIV_SET):
66184         Remove AC_C_INLINE, since 'inline' is no longer used directly.
66185         * modules/acl, modules/mbchar, modules/priv-set (Depends-on):
66186         Add extern-inline.
66188         sockets, sys_stat: remove AC_C_INLINE in MSVC-only cases
66189         * m4/sockets.m4 (gl_SOCKETS):
66190         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H):
66191         Remove AC_C_INLINE.  Here, 'inline' is used only in MSVC
66192         environments where it's already guaranteed to work, so we needn't
66193         check for it at 'configure'-time.
66195         tls-tests: omit unnecessary 'inline'
66196         * tests/test-tls.c (perhaps_yield): No longer inline.
66197         Simplicity and portability trump efficiency in test cases.
66199         utimens-tests: avoid unnecessary 'inline'
66200         * modules/fdutimensat-tests (configure.ac):
66201         * modules/futimens-tests (configure.ac):
66202         * modules/utimens-tests (configure.ac):
66203         * modules/utimensat-tests (configure.ac):
66204         Remove AC_C_INLINE.
66205         * tests/test-utimens-common.h (ctime_compare):
66206         No longer inline.  Simplicity and portability trump efficiency here.
66208         misc: don't limit commentary to inline functions
66209         * lib/binary-io.h, lib/malloca.h, lib/safe-alloc.c:
66210         * lib/xalloc-oversized.h, lib/xsize.h:
66211         Contrast macros to functions in general, not just to inline functions,
66212         when the commentary does not apply only to inline functions.
66214 2012-09-20  Jim Meyering  <meyering@redhat.com>
66216         non-recursive-gnulib-prefix-hack: new module
66217         * build-aux/prefix-gnulib-mk: Copied from coreutils, derived from
66218         the file that originated in Bison.
66219         * m4/non-recursive-gnulib-prefix-hack.m4: Likewise, this code is
66220         largely copied from a snippet that resided in bison's configure.ac.
66221         * modules/non-recursive-gnulib-prefix-hack: New file.
66222         * MODULES.html.sh (Support for maintaining and releasing projects):
66223         Add it.
66225 2012-09-18  Jim Meyering  <meyering@redhat.com>
66227         maint.mk: generalize _gl_tight_scope for non-recursive make
66228         * top/maint.mk (_gl_tight_scope): Remove a hard-coded assumption
66229         that *.h would describe additional .h files in the directory
66230         specified by $(_gl_TS_dir).  I.e., add this...
66231         (_gl_TS_other_headers): New variable.
66233         maint.mk: exempt trailing blanks found in "binary" files
66234         * top/maint.mk (sc_trailing_blank): Filter out any matches found in
66235         "binary" files, as reported by grep.  Suggested by Richard W.M. Jones
66236         in http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
66238 2012-09-17  Jim Meyering  <meyering@redhat.com>
66240         maint.mk: sc_prohibit_path_max_allocation: don't FP for UNIX_PATH_MAX
66241         * top/maint.mk (sc_prohibit_path_max_allocation): Avoid false-positive
66242         match for symbols like UNIX_PATH_MAX. Reported by Richard W.M. Jones
66243         in http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
66245 2012-09-17  Jim Meyering  <meyering@redhat.com>
66247         maint.mk: teach sc_prohibit_magic_number_exit to accept 77
66248         * top/maint.mk (sc_prohibit_magic_number_exit): Do not complain about
66249         uses like "exit (77)".  "77" is automake's "skip this test" exit code.
66250         It is not in the same category as "exit (0)" or "exit (1)", and
66251         besides, I know of no symbolic name for that 77.  Reported by
66252         Richard W.M. Jones in
66253         http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
66255 2012-09-17  Jim Meyering  <meyering@redhat.com>
66257         maint.mk: relax sc_prohibit_strcmp, to avoid a false positive
66258         * top/maint.mk (sc_prohibit_strcmp): Relax regexp, so as to match
66259         all uses of #define, not just those that start in column 1.
66260         Richard W.M. Jones reported a false positive in
66261         http://thread.gmane.org/gmane.comp.emulators.guestfs/1902
66263 2012-09-16  Paul Eggert  <eggert@cs.ucla.edu>
66265         localcharset: work around Mac OS X bug with UTF-8 and MB_CUR_MAX
66266         * lib/localcharset.c (locale_charset) [DARWIN7]:
66267         Return "ASCII" if the system reports "UTF-8" and MB_CUR_MAX <= 1,
66268         as these two values are incompatible.  Problem reported by Max Horn.
66269         For more discussion, please see
66270         <http://lists.gnu.org/r/bug-gnulib/2012-09/msg00061.html>.
66272         doc: document sticky-EOF issue
66273         * doc/posix-functions/fgetc.texi (fgetc):
66274         * doc/posix-functions/fgets.texi (fgets):
66275         * doc/posix-functions/fread.texi (fread):
66276         * doc/posix-functions/fscanf.texi (fscanf):
66277         * doc/posix-functions/getc.texi (getc):
66278         * doc/posix-functions/getchar.texi (getchar):
66279         * doc/posix-functions/scanf.texi (scanf):
66280         Mention that glibc and default Solaris do not conform to
66281         C99 and POSIX-2001 or later, with respect to how getchar
66282         etc. behave when feof reports nonzero.
66284 2012-09-13  Joachim Schmitz  <jojo@schmitz-digital.de>  (tiny change)
66286         poll: fix poll(0, NULL, msec)
66287         * lib/poll.c: don't exit early if NULL is the 1st arg to poll(),
66288         but nfd is 0.  In that case poll should behave like select.
66290 2012-09-13  Joachim Schmitz  <jojo@schmitz-digital.de>  (tiny change)
66291             Paolo Bonzini  <bonzini@gnu.org>
66293         poll: fix for systems that can't recv() on a non-socket
66294         * lib/poll.c: if recv returns ENOTSOCK, assume the descriptor
66295         is readable.  In this case POLLHUP will not be supported.
66296         * doc/posix-functions/poll.texi: Document this.
66298 2012-09-13  Paolo Bonzini  <bonzini@gnu.org>
66300         poll/select: document portability problems not fixed by Gnulib.
66301         * doc/posix-functions/poll.texi: poll does not work well on
66302         pipes under Windows.  It has the same limitations as select on
66303         BeOS.
66304         * doc/posix-functions/select.texi: select does not work well
66305         on pipes under Windows.
66307 2012-09-10  Paul Eggert  <eggert@cs.ucla.edu>
66309         fcntl-h: check for AIX 7.1 bug with O_NOFOLLOW and O_CREAT
66310         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Check for AIX 7.1 bug
66311         that caused a GNU tar test failure.  Problem reported by Jez Wain; see
66312         <http://lists.gnu.org/r/bug-tar/2012-07/msg00018.html>.
66314 2012-09-06  Eric Blake  <eblake@redhat.com>
66316         net_if: give more details about the bug being fixed
66317         * doc/posix-headers/net_if.texi: Add clarification.
66319 2012-09-05  Eric Blake  <eblake@redhat.com>
66321         net_if: new module
66322         * modules/net_if: New module, borrowing ideas from netinet_in.
66323         * m4/net_if_h.m4: New file.
66324         * lib/net_if.in.h: Likewise.
66325         * doc/posix-headers/net_if.texi (net/if.h): Document it.
66326         * MODULES.html.sh (lacking POSIX:2008): Likewise.
66327         * tests/test-net_if.c: Make function checks conditional.
66328         Reported by Jasper Lievisse Adriaanse <jasper@humppa.nl>.
66330 2012-09-05  Mats Erik Andersson  <gnu@gisladisker.se>  (tiny change)
66332         readutmp: fix non-portable UT_PID use
66333         * lib/readutmp.c (desirable_utmp_entry) <READ_UTMP_CHECK_PIDS>:
66334         Use `UT_PID (u) > 0' as absolute condition.
66336 2012-09-04  Jim Meyering  <meyering@redhat.com>
66338         fts: reduce two or more trailing spaces to just one, usually
66339         * lib/fts.c (fts_open): Upon initialization, if a name ends in two
66340         or more slashes, trim all but the final one.  But if a name consists
66341         solely of two slashes, don't modify it.  If it consists solely of
66342         three or more slashes, strip all but one.
66344         This is part of the solution to a minor problem with rm:
66345         it would print a bogus ELOOP diagnostic when failing to remove
66346         the slash-decorated name of a symlink-to-directory:
66348             $ mkdir d && ln -s d s && env rm -r s/
66349             rm: cannot remove 's': Too many levels of symbolic links
66351         With the change below and a trivial don't-trim-trailing-slashes
66352         adjustment to remove.c, it does this:
66354             $ env rm -r s/
66355             rm: cannot remove 's/': Not a directory
66357         Improved by: Eric Blake
66359         fts: when there is no risk of overlap, use memcpy, not memmove
66360         * lib/fts.c (fts_alloc): Fix unjustified memcopy: s/memmove/memcpy/
66362 2012-08-29  Paul Eggert  <eggert@cs.ucla.edu>
66364         stdbool: be more compatible with mixed C/C++ compiles
66365         * lib/stdbool.in.h (_Bool, true, false) [__cplusplus]:
66366         Define to bool, true, false, respectively, as GCC's builtin
66367         stdbool.h does.  Problem reported by Michael Goffioul in
66368         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00143.html>.
66370 2012-08-28  Jim Meyering  <meyering@redhat.com>
66372         revert last change: it was not needed
66373         * tests/test-vc-list-files-git.sh: There's already a test for
66374         a working git, just below.
66376 2012-08-28  Jim Meyering  <meyering@redhat.com>
66378         tests: test-vc-list-files-git.sh: skip if git is not available
66379         * tests/test-vc-list-files-git.sh: Skip this test when git is
66380         not available.
66382 2012-08-26  Bruno Haible  <bruno@clisp.org>
66384         gnulib-tool: Remove no-op option --no-changelog.
66385         * gnulib-tool (func_usage): Don't mention --no-changelog.
66386         (do_changelog): Remove variable.
66387         Reported by Dmitriy Selyutin <ghostman.sd@gmail.com>.
66389 2012-08-24  Paul Eggert  <eggert@cs.ucla.edu>
66391         doc: remove fdl-1.2.texi
66392         It is no longer used or maintained, and its use of @acronym
66393         is problematic.  See the thread containing
66394         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00134.html>.
66395         * config/srclist.txt: Remove doc/old-licenses/fdl-1.2.texi.
66396         * doc/old-licenses/fdl-1.2.texi: Remove.
66398         execinfo: port to FreeBSD
66399         * m4/execinfo.m4 (gl_EXECINFO_H): Set LIB_EXECINFO to -lexecinfo
66400         if needed, as in FreeBSD.  Reported by Bastien Roucariès in
66401         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00113.html>.
66402         * modules/execinfo (Link): Add $(LIB_EXECINFO).
66404 2012-08-23  Jim Meyering  <meyering@redhat.com>
66406         xstrtol.h: avoid "_Noreturn is not at beginning of declaration" warning
66407         * lib/xstrtol.h: Put "_Noreturn" before "void" in declaration,
66408         to placate gcc's -Wold-style-declaration.
66410 2012-08-24  Paul Eggert  <eggert@cs.ucla.edu>
66412         doc: do not use @acronym
66413         * doc/inet_ntoa.texi (inet_ntoa):
66414         * doc/parse-datetime.texi (Seconds since the Epoch)
66415         (Specifying time zone rules):
66416         * doc/posix-functions/inet_ntoa.texi (inet_ntoa):
66417         Don't use @acronym.  Problem reported by John Darlington in
66418         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00124.html>.
66420 2012-08-23  Paul Eggert  <eggert@cs.ucla.edu>
66422         stdnoreturn: port to newer GCCs
66423         * m4/stdnoreturn.m4 (gl_STDNORETURN_H): Avoid problems with
66424         bleeding-edge GCC that complains about 'int _Noreturn foo (void);'.
66425         Problem reported by Jim Meyering in
66426         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00121.html>.
66427         Also, rename the 'test' function to a void a clash with the
66428         already-supplied 'main' function; this fixes a bug that incorrectly
66429         rejected GCC 4.7.1's <stdnoreturn.h>.
66430         * doc/posix-headers/stdnoreturn.texi (stdnoreturn.h):
66431         Document GCC problem.
66433 2012-08-22  Reuben Thomas  <rrt@sc3d.org>
66435         pipe-filter: fix comment typo
66436         * lib/pipe-filter.h: Mention correct function.
66438 2012-08-22  Paul Eggert  <eggert@cs.ucla.edu>
66440         execinfo: new module
66441         This is for Emacs.  Currently, it provides a no-effect stub
66442         on all platforms where it does not already work.
66443         It already works on glibc-based systems, and on Solaris 11.
66444         * lib/execinfo.c, lib/execinfo.in.h, m4/execinfo.m4, modules/execinfo:
66445         New files.
66446         * doc/glibc-headers/execinfo.texi (execinfo.h):
66447         * MODULES.html.sh (Misc): Document it.
66449 2012-08-20  Paul Eggert  <eggert@cs.ucla.edu>
66451         extern-inline: support old GCC 'inline'
66452         * m4/extern-inline.m4 (gl_EXTERN_INLINE): Use pre-C99 GCC 'inline'
66453         if available.  This applies to GCC versions 2.7 through 4.2, or
66454         when newer GCC is using -fgnu89-inline.  The goal is to address
66455         some of the performance issues mentioned by Bruno Haible in
66456         <http://lists.gnu.org/r/bug-gnulib/2012-08/msg00097.html>.
66458 2012-08-20  Eric Blake  <eblake@redhat.com>
66460         maint.mk: avoid redundant file name in message
66461         * top/maint.mk (sc_prohibit_strcmp, sc_unmarked_diagnostics)
66462         (sc_prohibit_defined_have_decl_tests, sc_const_long_option)
66463         (sc_makefile_path_separator_check): Remove bogus $(ME).
66465 2012-08-20  Mike Frysinger  <vapier@gentoo.org>
66467         timer-time: fix link order when static linking on glibc
66468         * m4/timer_time.m4 (LIB_TIMER_TIME): Add -lpthread
66469         _after_ -lrt so that it's significant.
66471 2012-08-19  Paul Eggert  <eggert@cs.ucla.edu>
66473         timespec: omit unnecessary AC_C_INLINE
66474         * m4/timespec.m4 (gl_TIMESPEC): Do not require AC_C_INLINE.
66476         stat-time: omit unnecessary AC_C_INLINE
66477         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
66478         Do not require AC_C_INLINE.
66480         ignore-value: omit unnecessary AC_C_INLINE
66481         * modules/ignore-value (configure.ac): Do not require AC_C_INLINE.
66483         sys_select: avoid 'static inline'
66484         * lib/sys_select.in.h (rpl_fd_isset): Now static, not static inline.
66486         mktime: avoid 'static inline'
66487         * lib/mktime.c (leapyear, ydhms_diff): Now static, not static inline.
66488         * m4/mktime.m4 (gl_PREREQ_MKTIME): Do not require AC_C_INLINE.
66490 2012-08-19  Bruno Haible  <bruno@clisp.org>
66492         gnulib-tool: Improve coding style.
66493         * gnulib-tool (func_emit_tests_Makefile_am): Set perhapsLT, like in
66494         func_emit_lib_Makefile_am.
66495         Reported and fix suggested by Dmitriy Selyutin <ghostman.sd@gmail.com>.
66497 2012-08-19  Bruno Haible  <bruno@clisp.org>
66499         gnulib-tool: Fix indentation.
66500         * gnulib-tool (func_import): Fix indentation.
66502 2012-08-19  Bruno Haible  <bruno@clisp.org>
66504         gnulib-tool: Remove old file names from .cvsignore, .gitignore.
66505         * gnulib-tool (func_update_ignorelist): Don't use 'join -v 1' command
66506         on the list of removed files.
66508 2012-08-17  Paul Eggert  <eggert@cs.ucla.edu>
66510         test-parse-datetime: avoid glibc leap-second glitch
66511         * tests/test-parse-datetime.c (main): Set TZ to US Eastern time
66512         with the 2012 rules.  Problem reported by Bruce Dubbs in
66513         <http://bugs.gnu.org/12206>.
66515 2012-08-14  Bruno Haible  <bruno@clisp.org>
66517         gnulib-tool: Fix indentation of generated gnulib-comp.m4 file.
66518         * gnulib-tool (func_emit_autoconf_snippet): Initialize indentation
66519         from argument.
66520         Reported and fix suggested by Dmitriy Selyutin <ghostman.sd@gmail.com>.
66522 2012-08-14  Eric Blake  <eblake@redhat.com>
66524         ldexp: relax license
66525         * modules/ldexp (License): Trivial relax, since the module only
66526         provides a permissively licensed m4 file.
66528 2012-08-13  Bruno Haible  <bruno@clisp.org>
66530         gnulib-tool: Fix persistence of --witness-c-macro option.
66531         * gnulib-tool (func_import): Fix typo in emit of gl_WITNESS_C_MACRO.
66532         Reported by Dmitriy Selyutin <ghostman.sd@gmail.com>.
66534 2012-08-11  Eric Blake  <eblake@redhat.com>
66536         count-leading-zeros: use a lookup table on non-gcc compilers
66537         * lib/count-leading-zeros.h (count_leading_zeros_32): Use an
66538         alternate implementation, suggested by Jim Meyering.
66540 2012-08-10  Eric Blake  <eblake@redhat.com>
66542         count-leading-zeros: new module
66543         * modules/count-leading-zeros: New module.
66544         * m4/count-leading-zeros.m4: New file.
66545         * lib/count-leading-zeros.h: Likewise.
66546         * modules/count-leading-zeros-tests: New test.
66547         * tests/test-count-leading-zeros.c: New file.
66548         * MODULES.html.sh (Integer arithmetic functions): Document it.
66550 2012-08-07  Simon Josefsson  <simon@josefsson.org>
66551             Jim Meyering  <meyering@redhat.com>
66553         maintainer-makefile: Fix syntax error with dash.
66554         * top/maint.mk (sc_vulnerable_makefile_CVE-2009-4029): Quote arguments.
66555         (sc_vulnerable_makefile_CVE-2012-3386): Likewise.
66557 2012-08-05  Jim Meyering  <meyering@redhat.com>
66559         extern-inline: also ignore -Wmissing-declarations
66560         * m4/extern-inline.m4: Also ignore -Wmissing-declarations,
66561         required with gcc-4.8.0-to-be.
66563         maint.mk: sc_prohibit_magic_number_exit: avoid new false positives
66564         * top/maint.mk (sc_prohibit_magic_number_exit): Also filter out matches
66565         for /error ?([^,]*)/.  This avoids false-positives for strings like
66566         "Unknown error (252)", introduced via commit v0.0-7538-g92875a6.
66568 2012-08-02  Stefano Lattarini  <stefano.lattarini@gmail.com>
66570         gnumakefile: better interaction with Automake-NG
66571         * modules/gnumakefile [Makefile.am]: The makefiles generated by
66572         Automake-NG always contain a definition of VPATH, even in non-VPATH
66573         builds (its value being simply '.' in that case).  So, in the
66574         'clean-GNUmakefile' rule, to determine whether running under a
66575         VPATH setup, compare '$(srcdir)' to '.' rather than checking whether
66576         '$(VPATH)' expands to the empty string.
66578 2012-08-02  Carlo de Falco  <carlo.defalco@polimi.it>  (tiny change)
66580         base64: Use extern C scope in header file, for C++.
66581         * lib/base64.h: Add C++ namespace protection.
66583 2012-08-02  Paul Eggert  <eggert@cs.ucla.edu>
66585         stat-time, timespec, u64: support naive out-of-dir builds
66586         * lib/stat-time.c, lib/timespec.c, lib/u64.c:
66587         Use '#include "foo.h"', not '#include <foo.h>', when including
66588         one's own interface.  This works better when configuring with
66589         out-of-directory builds, since packages need not add an
66590         otherwise-unnecessary -I$(topdir_src)/lib to DEFAULT_INCLUDES.
66592 2012-08-01  Paul Eggert  <eggert@cs.ucla.edu>
66594         utimens: use extern-inline
66595         * lib/utimens.c (_GL_UTIMENS_INLINE): Define when including utimens.h.
66596         * lib/utimens.h: Add copyright notice, since this is now large enough
66597         to copyright.  Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66598         (_GL_UTIMENS_INLINE): New macro.  Use it instead of 'static inline'.
66599         * modules/utimens (Depends-on): Add extern-inline.
66601         u64: use extern-inline
66602         * lib/u64.c: New file.
66603         * lib/u64.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66604         (_GL_U64_INLINE): New macro.  Use it instead of 'static inline'.
66605         * modules/u64 (Files): Add lib/u64.c.
66606         (Depends-on): Add extern-inline.
66607         (configure.ac): No need to require AC_C_INLINE, since extern-inline
66608         does that now.
66609         (lib_SOURCES): Add u64.c.
66611         timespec: use extern-inline
66612         * lib/timespec.c: New file.
66613         * lib/timespec.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66614         (_GL_TIMESPEC_INLINE): New macro.  Use it instead of 'static inline'.
66615         * modules/timespec (Files): Add lib/timespec.c.
66616         (Depends-on): Add extern-inline.
66617         (lib_SOURCES): Add timespec.c.
66619         stat-time: use extern-inline
66620         * lib/stat-time.c: New file.
66621         * lib/stat-time.h: Use _GL_INLINE_HEADER_BEGIN, _GL_INLINE_HEADER_END.
66622         (_GL_STAT_TIME_INLINE): New macro.  Use it instead of 'static inline'.
66623         * modules/stat-time (Files): Add lib/stat-time.c.
66624         (Depends-on): Add extern-inline.
66625         (lib_SOURCES): Add stat-time.c.
66627         extern-inline: new module
66628         * modules/extern-inline, m4/extern-inline.m4: New files.
66629         This is for better support of 'extern inline' a la ISO C99,
66630         with a portable alternative on compilers that do not support
66631         C99-style 'extern inline'.  Using 'extern inline' shrinks the size
66632         of the Emacs executable, when compiled with debugging disabled,
66633         which is a typical way that Emacs is built while developing.
66635 2012-08-01  Akim Demaille  <akim@lrde.epita.fr>
66637         maint.mk: a "release-commit" wrapper to do-release-commit-and-tag
66638         * build-aux/do-release-commit-and-tag: Move variable definitions
66639         together.
66640         ($branch): Instead of defaulting to "master", default to the current
66641         branch (as gnu-web-doc-update does).
66642         (help): Display the current values of the option arguments.
66643         * top/maint.mk (release-commit): New.
66644         * top/README-release: Simplify the corresponding step.
66646 2012-07-30  Eric Blake  <eblake@redhat.com>
66648         passfd: fix comment on recvfd
66649         * lib/passfd.c (recvfd): Fix comment.
66650         Reported by Jann Horn <jannhorn@googlemail.com>.
66652 2012-07-30  Jim Meyering  <meyering@redhat.com>
66654         maint.mk: avoid a sub-shell
66655         * top/maint.mk (release-prep): Remove unneeded sub-shell.
66657 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
66659         maint.mk: use silent-rules support from Automake
66660         * top/maint.mk (news-check, vc-diff-check, announcement)
66661         (no-submodule-changes, alpha beta stable, release-prep)
66662         (web-manual, update-copyright): Use $(AM_V_GEN) and $(AM_V_at).
66664 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
66666         maint.mk: provide a web-manual-update target
66667         * top/maint.mk: here.
66668         * top/README-release: Use it to simplify the web manual update step.
66670 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
66672         README-release: shorten the circuit to post a news
66673         * top/README-release: Point directly to the news submission form.
66675 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
66677         gnu-web-doc-update: fix --help
66678         * build-aux/gnu-web-doc-update: The information "top level" was written
66679         twice.
66681 2012-07-30  Akim Demaille  <akim@lrde.epita.fr>
66683         maint.mk: absolute VPATH issue
66684         * top/maint.mk (release-prep): Help Git find .git/.
66685         From Jim Meyering.
66687 2012-07-29  Akim Demaille  <akim@lrde.epita.fr>
66689         gitlog-to-changelog: fix previous change
66690         * build-aux/gitlog-to-changelog: Fix condition.
66691         Add missing ";".
66693 2012-07-29  Akim Demaille  <akim@lrde.epita.fr>
66695         gitlog-to-changelog: don't expect .git to be in $srcdir
66696         Reported by Bruno Haible.
66697         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00265.html>
66698         * build-aux/gitlog-to-changelog (&git_dir_option): New.
66699         Use it.
66701 2012-07-29  Akim Demaille  <akim@lrde.epita.fr>
66703         maint.mk: absolute VPATH build fix
66704         * top/maint.mk (gpg_key_ID): Help git find .git when, for instance,
66705         $(srcdir) is not a parent of $(builddir).
66707 2012-07-28  John Darrington  <john@darrington.wattle.id.au>
66709         clean-temp: Fix memory leak.
66710         * lib/clean-temp.c (cleanup_temp_dir): Free also the 'subdirs' and
66711         'files' members of tmpdir.
66713 2012-07-27  Jim Meyering  <meyering@redhat.com>
66715         maint.mk: new rule: refresh-gnulib-patches
66716         I noticed that 8 of coreutils' 9 gl/**/*.diff files were stale.
66717         Use this rule to refresh them.
66718         * top/maint.mk (refresh-gnulib-patches): New rule.
66720 2012-07-24  Bruno Haible  <bruno@clisp.org>
66722         gnulib-tool: Fix handling of inctests variable.
66723         * gnulib-tool: Canonicalize $inctests also in 'update' mode.
66724         Reported by Nick Bowler <nbowler@elliptictech.com>.
66726 2012-07-22  Bruno Haible  <bruno@clisp.org>
66728         getpass: Assume AC_CHECK_DECLS_ONCE invocation, like in getpass.m4.
66729         * lib/getpass.h: Assume HAVE_DECL_GETPASS is defined.
66730         * cfg.mk (exclude_file_name_regexp--sc_prohibit_defined_have_decl_tests):
66731         Remove exemption for getpass.h.
66732         Suggested by Eric Blake.
66734 2012-07-20  Eric Blake  <eblake@redhat.com>
66736         verify: document conflict with -Wnested-externs
66737         * lib/verify.h: Give hint about usage when gcc warnings are enabled.
66739         maint.mk: forbid exit(-1)
66740         * top/maint.mk (sc_prohibit_magic_number_exit): Detect negatives.
66742 2012-07-20  Paul Eggert  <eggert@cs.ucla.edu>
66744         fsusage: port back to Solaris
66745         * lib/fsusage.c (get_fs_usage): Fix busted logic causing compile-time
66746         error (fsd not declared) on Solaris 10.  Reported privately by
66747         Andrew Borodin.
66749 2012-07-19  Akim Demaille  <akim@lrde.epita.fr>
66751         gnu-web-doc-update: fix error messages
66752         * build-aux/gnu-web-doc-update: Don't pass $ME to die.
66754         gnu-web-doc-update: check the requirements.
66755         * build-aux/gnu-web-doc-update (find_tool): Import from bootstrap.
66756         ($CVS, $CVSU, $GIT, $RSYNC, $XARGS): New.
66757         * build-aux/bootstrap (find_tool): Comment change.
66759 2012-07-17  Akim Demaille  <akim@lrde.epita.fr>
66761         maint.mk: minor simplication.
66762         * top/maint.mk (_sc_excl): Use $(or...) instead of $(if...)
66763         for default values.
66765 2012-07-15  Akim Demaille  <akim@lrde.epita.fr>
66767         gitlog-to-changelog: VPATH build issues
66768         If builddir is not a subdirectory of srcdir, running git from it will
66769         fail.
66770         * build-aux/gitlog-to-changelog (--srcdir): New option.
66772 2012-07-15  Bruno Haible  <bruno@clisp.org>
66774         fpending: Assume AC_CHECK_DECLS_ONCE invocation, like in fpending.m4.
66775         * lib/fpending.h: Assume HAVE_DECL___FPENDING is defined.
66776         * cfg.mk (exclude_file_name_regexp--sc_prohibit_defined_have_decl_tests)
66777         Remove exemption for fpending.h.
66778         Suggested by Eric Blake.
66780 2012-07-15  Paul Eggert  <eggert@cs.ucla.edu>
66782         pthread_sigmask: fix bug on FreeBSD 9
66783         * lib/pthread_sigmask.c [PTHREAD_SIGMASK_INEFFECTIVE]:
66784         Include string.h.
66785         (pthread_sigmask) [PTHREAD_SIGMASK_INEFFECTIVE]:
66786         When calling pthread_sigmask (1729, NEW, OLD), specify non-null NEW;
66787         this avoids a bug on FreeBSD 9, where pthread_sigmask is effective
66788         but pthread_sigmask (1729, NULL, NULL) returns zero.
66789         See <http://bugs.gnu.org/11884>.
66790         Avoid the need to call pthread_sigmask (1729, ...) in most cases,
66791         by inspecting whether the main call changed the old mask.
66793 2012-07-15  Reuben Thomas  <rrt@sc3d.org>
66795         README-release: make it more legible
66796         * top/README-release: Improve typography slightly.
66798 2012-07-15  Jim Meyering  <meyering@redhat.com>
66800         maint: require that each sc_... command start with "@"
66801         * Makefile (sc_prohibit_sc_omitted_at): New rule so that
66802         "make sc_maint" helps us avoid this nit.
66804 2012-07-15  Jim Meyering  <meyering@redhat.com>
66806         maint.mk: add leading "@" to quiet new "make syntax-check" rule
66807         * top/maint.mk (sc_prohibit_defined_have_decl_tests): Add "@".
66809 2012-07-13  Eric Blake  <eblake@redhat.com>
66811         maint.mk: new syntax check for HAVE_DECL checks
66812         * top/maint.mk (sc_prohibit_defined_have_decl_tests): New rule.
66813         * cfg.mk
66814         (exclude_file_name_regexp--sc_prohibit_defined_have_decl_tests):
66815         Exempt some false positives.
66816         Based on a report by Karel Zak.
66818         argp: make HAVE_DECL usage consistent
66819         * lib/argp-parse.c (__argp_parse): Check contents of HAVE_DECL
66820         macros, not whether they are defined.
66821         * m4/argp.m4 (gl_ARGP): Always define HAVE_DECL_* macros, per
66822         convention with other declaration checks.
66823         Reported by Karel Zak, with suggestions from Paul Eggert.
66825         stat-time: relax license to LGPLv2+
66826         * modules/stat-time (License): Relax, with consent of all authors.
66828         strndup: fix m4 usage error
66829         * m4/strndup.m4 (gl_FUNC_STRNDUP): HAVE_DECL_STRNDUP is always
66830         defined, to either 0 or 1.
66831         Reported by Karel Zak.
66833 2012-07-11  Jim Meyering  <meyering@redhat.com>
66835         maint: enable the sc_avoid_if_before_free syntax-check rule
66836         * cfg.mk (local-checks-to-skip): Enable sc_avoid_if_before_free.
66837         (if_before_free_offenders_): Define.
66838         (if_before_free_basename_re_): Define.
66839         Exempt current files with useless if-before-free.
66841 2012-07-11  Paul Eggert  <eggert@cs.ucla.edu>
66843         gettext: do not assume '#define ... defined ...' behavior
66844         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS):
66845         Do not use '#define FOO ... defined BAR ...', as the C standard says
66846         it's not portable to expect that this works after macro expansion.
66847         Problem reported for gzip by Steven M. Schweda in
66848         <http://lists.gnu.org/r/bug-gzip/2012-07/msg00000.html>.
66850 2012-07-10  Paul Eggert  <eggert@cs.ucla.edu>
66852         getloadavg: clean out old Emacs and Autoconf cruft
66853         See Glenn Morris in <http://bugs.gnu.org/11905>.
66854         * lib/getloadavg.c: Include <config.h>, <stdbool.h> always.
66855         Include <sys/param.h> if HAVE_SYS_PARAM_H, not if unix or __unix.
66856         (LDAV_CVT): Remove no-longer-used LOAD_AVE_CVT hook.
66857         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Check for <sys/param.h>.
66859 2012-07-10  Akim Demaille  <akim@lrde.epita.fr>
66861         bootstrap: let warn be like tests/init.sh's warn_
66862         Reported by Jim Meyering.
66863         * build-aux/bootstrap (warn): Remove, replaced by...
66864         (warnf_, warn_): these.
66865         Adjust callers.
66866         Shorten messages that no longer fit in 80 columns.
66868 2012-07-09  Bruno Haible  <bruno@clisp.org>
66870         getopt: Simplify after Emacs changed.
66871         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX): Inline gl_GETOPT_IFELSE.
66872         (gl_GETOPT_IFELSE): Remove macro.
66874 2012-07-09  Jim Meyering  <meyering@redhat.com>
66876         maint.mk: add sc_vulnerable_makefile_CVE-2012-3386
66877         * top/maint.mk (sc_vulnerable_makefile_CVE-2012-3386): New rule.
66879         maint.mk: _sc_search_regexp, sc_vulnerable_makefile_CVE-2009-4029: fix
66880         Bugs in both of those conspired to make the
66881         sc_vulnerable_makefile_CVE-2009-4029 rule 99% useless.
66882         _sc_search_regexp's handling of non-empty $in_files would filter
66883         out any offending file names.  sc_vulnerable_makefile_CVE-2009-4029's
66884         choice of in_files value meant there would be no match in most
66885         projects, due to the presence of two or more Makefile.in files.
66886         * top/maint.mk (_sc_search_regexp) [in_vc_files,in_files]: Clarify.
66887         Fix a bug in how a non-empty $$in_files was processed:
66888         (sc_vulnerable_makefile_CVE-2009-4029): Fix erroneous use of in_files:
66889         in spite of the name, it's a regexp, not a list of file names.
66891 2012-07-09  Paul Eggert  <eggert@cs.ucla.edu>
66893         getloadavg, getopt: fix commentary re configure.in
66894         Autoconf is deprecating the name 'configure.in', so change it to
66895         to the new name 'configure.ac' in a couple of places.
66896         * lib/getloadavg.c: configure.in -> configure.ac, in comment.
66897         * m4/getopt.m4 (gl_GETOPT_IFELSE, gl_GETOPT_SUBSTITUTE_HEADER)
66898         (gl_PREREQ_GETOPT): Remove obsolete commentary re Emacs configure.in.
66899         Emacs has renamed it to configure.ac, and it no longer refers
66900         to these macros anyway.
66902         timespec: mark functions with const attributes
66903         * lib/timespec.h (timespec_add, timespec_sub, dtotimespec):
66904         Mark with _GL_ATTRIBUTE_CONST.
66906 2012-07-07  Ludovic Courtès  <ludo@gnu.org>
66908         canonicalize[-lgpl]: handle "guessing" values when cross-building
66909         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
66910         (gl_CANONICALIZE_LGPL): Check whether $gl_cv_func_realpath_works
66911         matches "*yes" instead of just "yes".  Regression introduced in commit
66912         e0bcf6626cde8dad4bfbdc4045c744f0cd8b9e24.
66914 2012-07-07  Ludovic Courtès  <ludo@gnu.org>
66915             Bruno Haible  <bruno@clisp.org>
66917         canonicalize: make the right guess when cross-compiling to GNU
66918         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Match also "gnu*" to
66919         determine whether cross-compiling to glibc systems, so as to
66920         include GNU/Hurd.
66922 2012-07-06  Paul Eggert  <eggert@cs.ucla.edu>
66924         timespec-sub: avoid duplicate include
66925         * lib/timespec-sub.c: Do not include <config.h> twice.
66926         Reported by Juanma Barranquero.
66928 2012-07-06  Akim Demaille  <akim@lrde.epita.fr>
66930         bootstrap: use a more consistent error reporting scheme
66931         * build-aux/bootstrap (warn, die): New.
66932         Use them.
66934 2012-07-05  Paul Eggert  <eggert@cs.ucla.edu>
66936         sys_time: allow too-wide tv_sec
66937         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Allow struct
66938         timeval even if tv_sec is wider than time_t.  This allows
66939         OpenBSD 5.1 amd64 and fixes an Emacs porting glitch with utimens.c,
66940         as without this patch gnulib replaces struct timeval
66941         and OpenBSD futimes therefore has a type mismatch.
66942         * doc/posix-headers/sys_time.texi: Mention this.
66944         pthread: check for both pthread_create and pthread_join
66945         * m4/pthread.m4 (gl_PTHREAD_CHECK): Revert previous change, but
66946         alter the check so that it tests for both pthread_create and
66947         pthread_join.  This should be more portable to hosts like OSF/1 5.1.
66948         Suggested by Bruno Haible and Richard Yao in
66949         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00048.html>.
66951         parse-datetime: doc tuneup
66952         * doc/parse-datetime.texi: Index "leap seconds" and fix minor
66953         spacing issues.
66955 2012-07-05  Akim Demaille  <akim@lrde.epita.fr>
66957         do-release-commit-and-tag: fix the previous commit
66958         * build-aux/do-release-commit-and-tag: Actually the test was right,
66959         but the comment and the error message were misleading.
66960         Fix comment, and improve error message.
66961         Perform check first, so that NEWS is not modified uselessly.
66963         do-release-commit-and-tag: fix typo
66964         * build-aux/do-release-commit-and-tag: Be sure that NEWS does
66965         _not_ start with a stub.
66967 2012-07-04  Paul Eggert  <eggert@cs.ucla.edu>
66969         pthread: check for pthread_create, not pthread_join
66970         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for pthread_create, not
66971         pthread_join.  On FreeBSD 9, pthread_create is in libpthread but
66972         pthread_join in libc.  I hope this removes the need for all the
66973         OSF/1 5.1 pthread_join business.  Reported by Richard Yao in
66974         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00042.html>.
66976 2012-07-04  Jim Meyering  <meyering@redhat.com>
66978         parse-datetime: fix failure to diagnose invalid input
66979         date -d "$(printf '\xb0')" would print 00:00:00 with today's date
66980         rather than diagnosing the invalid input.  Now it reports this:
66981         date: invalid date '\260'
66982         * lib/parse-datetime.y (to_uchar): Define.
66983         (yylex): Don't sign-extend "other" bytes.
66984         * m4/parse-datetime.m4: Require AC_C_INLINE for first use of "inline".
66985         Thanks to Bruno Haible for the patch to this file.
66986         * tests/test-parse-datetime.c (main): Add a test to trigger the bug.
66987         Peter Evans reported the bug in GNU date: http://bugs.gnu.org/11843
66989 2012-07-03  Jim Meyering  <meyering@redhat.com>
66991         bootstrap: do not require now-removed build-aux/missing
66992         Now that build-aux/missing is, er, missing, bootstrap would
66993         silently fail.
66994         * build-aux/bootstrap (gnulib_extra_files): Remove $build_aux/missing
66995         from the list, now that (since commit v0.0-7489-gd0f486f) the file is
66996         no longer part of gnulib.
66997         Diagnose the failure.
66999 2012-07-03  Paul Eggert  <eggert@cs.ucla.edu>
67001         alloca: add support for HP NonStop TNS/E native
67002         * lib/alloca.in.h (alloca): Support the new host.
67003         From a suggestion by Joachim Schmitz in
67004         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00355.html>.
67006 2012-07-02  Pádraig Brady  <P@draigBrady.com>
67008         fsusage: remove code not needed on non GNU/Linux systems.
67010         * lib/fsusage.c [STAT_STATVFS || STAT_STATVFS64]:
67011         Don't include headers no longer needed in this case.
67012         * lib/fsusage.c [STAT_STATVFS &&
67013         ! (__linux__ && (__GLIBC__||__UCLIBC__))]: Undefine
67014         STAT_STATFS2_FRSIZE to exclude code not used in this case.
67016 2012-07-02  Paul Eggert  <eggert@cs.ucla.edu>
67018         fsusage: include files needed for glibc 2.6 fallback
67019         * lib/fsusage.c [STAT_STATVFS || STAT_STATVFS64]:
67020         Include <sys/param.h>, <sys/mount.h>, <sys/vfs.h>
67021         as they are needed for the 2.6 < glibc/Linux < 2.6.36 fallback.
67022         Problem reported by Ludovic Courtès in
67023         <http://lists.gnu.org/r/bug-gnulib/2012-07/msg00005.html>.
67025         fsusage: avoid needless check on GNU/Linux
67026         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Omit STAT_STATFS3_OSF1 check
67027         on GNU/Linux systems, since it can't possibly work.
67029 2012-07-01  Bruno Haible  <bruno@clisp.org>
67031         log: Fix an autoconf >= 2.64 warning.
67032         * modules/log (configure.ac): Require, not invoke, gl_FUNC_LOG.
67033         Reported by Carlos O'Donell <carlos_odonell@mentor.com>.
67035 2012-06-28  Bruno Haible  <bruno@clisp.org>
67037         log10f: Fix possible configuration problem.
67038         * m4/log10f.m4 (gl_FUNC_LOG10F): Augment LIBS by $LOG10F_LIBM, not
67039         $LOGF_LIBM.
67040         Reported by Carlos O'Donell <carlos_odonell@mentor.com>.
67042 2012-06-28  Bruno Haible  <bruno@clisp.org>
67044         remove: No longer override on all platforms. Fixes bug from 2010-03-20.
67045         * m4/remove.m4 (gl_FUNC_REMOVE): Test gl_cv_func_unlink_honors_slashes,
67046         not gl_cv_func_unlink_works.
67047         Reported by Carlos O'Donell <carlos_odonell@mentor.com>.
67049 2012-06-27  Eric Blake  <eblake@redhat.com>
67051         config: drop scripts that automake says are not independent
67052         * config/srclist.txt: Drop elisp-comp, missing, and ylwrap.
67053         * build-aux/elisp-comp: Delete.
67054         * build-aux/missing: Likewise.
67055         * build-aux/ylwrap: Likewise.
67056         * modules/elisp-comp: Likewise.
67057         * MODULES.html.sh: Drop mention of elisp-comp.
67058         * NEWS: Mention this.
67060 2012-06-26  Paul Eggert  <eggert@cs.ucla.edu>
67062         root-uid: new module
67063         This is for portability to Tandem's NonStop Kernel.
67064         * lib/root-uid.h, modules/root-uid: New files.
67065         * lib/euidaccess.c, lib/pt_chown.c, lib/unlinkdir.c:
67066         * lib/write-any-file.c, tests/test-sethostname2.c:
67067         Include "root-uid.h".
67068         * lib/euidaccess.c (euidaccess):
67069         * lib/pt_chown.c (main):
67070         * lib/unlinkdir.c (cannot_unlink_dir):
67071         * lib/write-any-file.c (can_write_any_file):
67072         * m4/mknod.m4 (gl_FUNC_MKNOD):
67073         * tests/test-sethostname2.c (geteuid, main):
67074         Don't assume ROOT_UID == 0.
67075         * modules/euidaccess (Depends-on):
67076         * modules/pt_chown (Depends-on):
67077         * modules/sethostname-tests (Depends-on):
67078         * modules/unlinkdir (Depends-on):
67079         * modules/write-any-file (Depends-on):
67080         Add root-uid.
67082         regex: use locale-independent comparison for codeset name
67083         See Bruno Haible's comment in <http://bugs.gnu.org/10305#120>.
67084         * lib/regcomp.c (init_dfa): Use just ASCII case comparison
67085         for codeset name.
67086         * lib/regex_internal.h: Do not include <strings.h>, since we
67087         no longer use strcasecmp.
67088         * modules/regex (Depends-on): Remove strcase.
67090 2012-06-23  Bruno Haible  <bruno@clisp.org>
67092         getopt-posix: No longer guarantee that option processing is resettable.
67093         * doc/posix-functions/getopt.texi: Drop description of problem with
67094         internal state. Fix info about mingw and msvc9.
67095         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Don't require a resettable
67096         option processing by getopt(). Run three test programs instead of one.
67097         Simplify cross-compilation guess.
67098         * NEWS: Mention the change.
67099         Reported by Rich Felker <dalias@aerifal.cx>.
67101 2012-06-26  Bruno Haible  <bruno@clisp.org>
67103         argp, regex: Ensure strcasecmp gets declared.
67104         * lib/argp-help.c: Include <strings.h>.
67105         * lib/regex_internal.h: Likewise.
67106         Reported and suggested by Joachim Schmitz <jojo@schmitz-digital.de>.
67108 2012-06-24  Bruno Haible  <bruno@clisp.org>
67110         ptsname_r: Make it consistent with ptsname on AIX.
67111         * lib/ptsname_r.c (__ptsname_r): For AIX, use nearly the same
67112         implementation as for OSF/1.
67113         * tests/test-ptsname_r.c (main) [AIX]: Use the modern way of opening
67114         a pty master.
67116         ptsname_r: Make it consistent with ptsname on OSF/1.
67117         * lib/ptsname_r.c (__ptsname_r): Add a different implementation for
67118         OSF/1.
67120 2012-06-24  Bruno Haible  <bruno@clisp.org>
67122         ttyname_r: Fix result on OSF/1, Solaris.
67123         * lib/ttyname_r.c (ttyname_r): Produce a NUL-terminated result.
67125 2012-06-24  Bruno Haible  <bruno@clisp.org>
67127         ptsname_r: Add support for Solaris.
67128         * lib/ptsname_r.c (__ptsname_r): Add a different implementation for
67129         Solaris.
67131         ptsname_r: Fix test failure on native Windows.
67132         * modules/ptsname_r (Depends-on): Add isatty.
67134         ptsname_r: Fix test failures on IRIX, Solaris.
67135         * m4/ptsname_r.m4 (gl_PREREQ_PTSNAME_R): Test whether isatty sets
67136         errno when it fails. Define ISATTY_FAILS_WITHOUT_SETTING_ERRNO
67137         accordingly.
67138         * lib/ptsname_r.c: Include <fcntl.h>.
67139         (__ptsname_r): When isatty returned false, then on IRIX, Solaris
67140         set errno if fd is invalid.
67141         * tests/test-isatty.c (main): Update comments.
67143 2012-06-24  Bruno Haible  <bruno@clisp.org>
67145         ptsname test: Extend test.
67146         * tests/test-ptsname.c: Include <errno.h>.
67147         (main): Test behaviour with invalid file descriptor.
67149 2012-06-23  Paul Eggert  <eggert@cs.ucla.edu>
67151         time: fix obsolete comment
67152         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Remove obsolete
67153         reference to HAVE_STRUCT_TIMESPEC in comment.
67155 2012-06-23  Bruno Haible  <bruno@clisp.org>
67157         getopt-gnu: Handle suboptimal getopt_long's abbreviation handling.
67158         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): If getopt_long exists but
67159         does not handle abbreviated long options with equivalent
67160         disambiguations, set gl_replace_getopt to yes.
67161         * doc/posix-functions/getopt.texi: Mention the OpenBSD 5.0 problem.
67163 2012-06-22  Paul Eggert  <eggert@cs.ucla.edu>
67165         time_r: fix typo that always overrode localtime_r decl
67166         * m4/time_r.m4 (gl_TIME_R): Use AC_CHECK_DECLS, not
67167         AC_CHECK_DECLS_ONCE, since localtime_r is declared in <time.h>,
67168         not in a standard include.
67170 2012-06-22  Bruno Haible  <bruno@clisp.org>
67172         Write "Mac OS X" instead of "MacOS X".
67173         * README: Write "Mac OS X" instead of "MacOS X".
67174         * build-aux/bootstrap: Likewise.
67175         * build-aux/install-reloc: Likewise.
67176         * lib/acl-internal.h: Likewise.
67177         * lib/acl_entries.c: Likewise.
67178         * lib/argp-ba.c: Likewise.
67179         * lib/argp-pv.c: Likewise.
67180         * lib/config.charset: Likewise.
67181         * lib/copy-acl.c: Likewise.
67182         * lib/csharpexec.c: Likewise.
67183         * lib/euidaccess.c: Likewise.
67184         * lib/fbufmode.c: Likewise.
67185         * lib/fflush.c: Likewise.
67186         * lib/file-has-acl.c: Likewise.
67187         * lib/filemode.h: Likewise.
67188         * lib/fpurge.c: Likewise.
67189         * lib/freadable.c: Likewise.
67190         * lib/freadahead.c: Likewise.
67191         * lib/freading.c: Likewise.
67192         * lib/freadptr.c: Likewise.
67193         * lib/freadseek.c: Likewise.
67194         * lib/fseeko.c: Likewise.
67195         * lib/fseterr.c: Likewise.
67196         * lib/fsusage.c: Likewise.
67197         * lib/fwritable.c: Likewise.
67198         * lib/fwriting.c: Likewise.
67199         * lib/get-rusage-as.c: Likewise.
67200         * lib/get-rusage-data.c: Likewise.
67201         * lib/getdomainname.c: Likewise.
67202         * lib/idpriv-drop.c: Likewise.
67203         * lib/idpriv-droptemp.c: Likewise.
67204         * lib/localcharset.c: Likewise.
67205         * lib/locale.in.h: Likewise.
67206         * lib/localename.c: Likewise.
67207         * lib/mbsrtowcs-state.c: Likewise.
67208         * lib/nproc.c: Likewise.
67209         * lib/passfd.c: Likewise.
67210         * lib/posix_openpt.c: Likewise.
67211         * lib/printf-parse.c: Likewise.
67212         * lib/progreloc.c: Likewise.
67213         * lib/safe-read.h: Likewise.
67214         * lib/safe-write.h: Likewise.
67215         * lib/sched.in.h: Likewise.
67216         * lib/set-mode-acl.c: Likewise.
67217         * lib/signal.in.h: Likewise.
67218         * lib/stdint.in.h: Likewise.
67219         * lib/stdio-impl.h: Likewise.
67220         * lib/stdlib.in.h: Likewise.
67221         * lib/strtod.c: Likewise.
67222         * lib/sys_select.in.h: Likewise.
67223         * lib/tcgetsid.c: Likewise.
67224         * lib/unistd.in.h: Likewise.
67225         * lib/unlockpt.c: Likewise.
67226         * lib/vasnprintf.c: Likewise.
67227         * lib/vma-iter.c: Likewise.
67228         * lib/wcsrtombs-state.c: Likewise.
67229         * m4/acl.m4: Likewise.
67230         * m4/acosl.m4: Likewise.
67231         * m4/asinl.m4: Likewise.
67232         * m4/atanl.m4: Likewise.
67233         * m4/c-stack.m4: Likewise.
67234         * m4/cosl.m4: Likewise.
67235         * m4/expl.m4: Likewise.
67236         * m4/extensions.m4: Likewise.
67237         * m4/fdatasync.m4: Likewise.
67238         * m4/fmal.m4: Likewise.
67239         * m4/frexp.m4: Likewise.
67240         * m4/frexpf.m4: Likewise.
67241         * m4/frexpl.m4: Likewise.
67242         * m4/fsusage.m4: Likewise.
67243         * m4/getdomainname.m4: Likewise.
67244         * m4/getloadavg.m4: Likewise.
67245         * m4/getopt.m4: Likewise.
67246         * m4/gettext.m4: Likewise.
67247         * m4/gnulib-common.m4: Likewise.
67248         * m4/intdiv0.m4: Likewise.
67249         * m4/intlmacosx.m4: Likewise.
67250         * m4/largefile.m4: Likewise.
67251         * m4/ldexpl.m4: Likewise.
67252         * m4/link-follow.m4: Likewise.
67253         * m4/locale-ar.m4: Likewise.
67254         * m4/locale-fr.m4: Likewise.
67255         * m4/locale-ja.m4: Likewise.
67256         * m4/locale-tr.m4: Likewise.
67257         * m4/locale-zh.m4: Likewise.
67258         * m4/locale_h.m4: Likewise.
67259         * m4/lock.m4: Likewise.
67260         * m4/logl.m4: Likewise.
67261         * m4/mathfunc.m4: Likewise.
67262         * m4/minus-zero.m4: Likewise.
67263         * m4/mktime.m4: Likewise.
67264         * m4/mmap-anon.m4: Likewise.
67265         * m4/multiarch.m4: Likewise.
67266         * m4/nanosleep.m4: Likewise.
67267         * m4/nocrash.m4: Likewise.
67268         * m4/poll.m4: Likewise.
67269         * m4/printf-frexpl.m4: Likewise.
67270         * m4/printf.m4: Likewise.
67271         * m4/signbit.m4: Likewise.
67272         * m4/sinl.m4: Likewise.
67273         * m4/sqrtl.m4: Likewise.
67274         * m4/strerror_r.m4: Likewise.
67275         * m4/tanl.m4: Likewise.
67276         * m4/threadlib.m4: Likewise.
67277         * m4/ttyname_r.m4: Likewise.
67278         * m4/unlink.m4: Likewise.
67279         * m4/visibility.m4: Likewise.
67280         * m4/wcwidth.m4: Likewise.
67281         * tests/minus-zero.h: Likewise.
67282         * tests/test-alloca-opt.c: Likewise.
67283         * tests/test-copy-acl.sh: Likewise.
67284         * tests/test-copy-file.sh: Likewise.
67285         * tests/test-fdatasync.c: Likewise.
67286         * tests/test-file-has-acl.sh: Likewise.
67287         * tests/test-flock.c: Likewise.
67288         * tests/test-fsync.c: Likewise.
67289         * tests/test-localename.c: Likewise.
67290         * tests/test-malloca.c: Likewise.
67291         * tests/test-nonblocking-pipe.h: Likewise.
67292         * tests/test-nonblocking-socket.h: Likewise.
67293         * tests/test-openpty.c: Likewise.
67294         * tests/test-posix_openpt.c: Likewise.
67295         * tests/test-ptsname.c: Likewise.
67296         * tests/test-ptsname_r.c: Likewise.
67297         * tests/test-sameacls.c: Likewise.
67298         * tests/test-select.h: Likewise.
67299         * tests/test-set-mode-acl.sh: Likewise.
67300         * tests/test-snprintf-posix.h: Likewise.
67301         * tests/test-sprintf-posix.h: Likewise.
67302         * tests/test-strtod.c: Likewise.
67303         * tests/test-time.c: Likewise.
67304         * tests/test-vasnprintf-posix.c: Likewise.
67305         * tests/test-vasprintf-posix.c: Likewise.
67306         * doc/acl-resources.txt: Likewise.
67307         * doc/**/*.texi: Likewise.
67308         Reported by Max Horn <max@quendi.de>.
67310 2012-06-22  Bruno Haible  <bruno@clisp.org>
67312         grantpt: Relax requirement regarding invalid file descriptors.
67313         * lib/grantpt.c: Don't include <fcntl.h>.
67314         (grantpt): Don't verify the validity of the file descriptor.
67315         * modules/grantpt (Depends-on): Remove fcntl-h.
67316         * tests/test-grantpt.c (main): Allow grantpt to succeed for invalid
67317         file descriptors.
67318         * doc/posix-functions/grantpt.texi: Document more platforms on which
67319         grantpt succeeds for invalid file descriptors.
67320         Reported by Rich Felker <dalias@aerifal.cx>.
67322 2012-06-22  Bruno Haible  <bruno@clisp.org>
67324         fbufmode test: Don't test unportable behaviour.
67325         * tests/test-fbufmode.c (test_mode): New function, extracted from main.
67326         (main): Invoke it three times.
67327         Reported by Szabolcs Nagy <nsz@port70.net>
67328         and Rich Felker <dalias@aerifal.cx>.
67330 2012-06-21  Bruno Haible  <bruno@clisp.org>
67332         gnulib-tool: Refactor inctests variable.
67333         * gnulib-tool: Normalize inctests to 'true' or 'false', not ''.
67334         (func_modules_transitive_closure,
67335         func_modules_transitive_closure_separately,
67336         func_import, func_create_testdir): Update.
67338         gnulib-tool: --create-[mega]testdir, --[mega]test implies --with-tests.
67339         * gnulib-tool: Accept option --without-tests.
67340         (func_usage): Document --without-tests option. Rearrange.
67341         (inctests): Normalize according to the mode.
67342         * NEWS: Mention the change.
67343         Suggested by Simon Josefsson.
67345 2012-06-21  Bruce Korb  <bkorb@gnu.org>
67347         parse-duration test: Avoid spurious output.
67348         * tests/test-parse-duration.sh: Reindent with leading tabs.
67350 2012-06-21  Jim Meyering  <meyering@redhat.com>
67352         maint: disable the strncpy prohibition
67353         * cfg.mk: Do not prohibit strncpy here.
67355 2012-06-21  Bruno Haible  <bruno@clisp.org>
67357         nonblocking: Avoid compilation error on mingw64.
67358         * m4/stdio_h.m4 (gl_STDIO_H): Invoke gl_MODULE_INDICATOR for scanf,
67359         fscanf.
67360         * modules/vscanf (configure.ac): Invoke gl_MODULE_INDICATOR.
67361         * modules/vfscanf (configure.ac): Likewise.
67362         * lib/stdio-read.c (scanf, fscanf, vscanf, vfscanf): Enable function
67363         definition only if stdio.h has prepared it.
67364         Reported by Daniel P. Berrange <berrange@redhat.com>.
67366 2012-06-20  Bernd Jendrissek  <bernd.jendrissek@gmail.com>  (tiny change)
67368         gnulib-tool: Use readlink if it is available.
67369         * gnulib-tool (func_readlink): Choose function more appropriately.
67371 2012-06-21  Paul Eggert  <eggert@cs.ucla.edu>
67373         posixtm-tests: port to buggy compiler
67374         Problem reported by Simon Josefsson in
67375         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00246.html>.
67376         * modules/posixtm-tests (Depends-on): Add stdint.
67377         * tests/test-posixtm.c (struct posixtm_test.t_expected):
67378         Now of type int_least64_t, not int64_t, both because that's
67379         what INT64_C returns and because int_least64_t works even
67380         on 72-bit hosts.
67381         (T): Use INT64_C on constants outside the traditional int range,
67382         to work around compiler bug noted by Simon.
67384         mktime: fix integer overflow in 'configure'-time test
67385         * m4/mktime.m4 (gl_FUNC_MKTIME): Do not rely on undefined behavior
67386         after integer overflow.  Problem reported by Rich Felker in
67387         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00257.html>.
67388         Also, don't look for further instances of a bug if we've already
67389         found one instance; this helps 'configure' run faster.
67391 2012-06-20  John Darrington  <john@darrington.wattle.id.au>  (tiny change)
67393         tmpfile, clean-temp: Fix invocation of GetVersionEx.
67394         * lib/tmpfile.c (supports_delete_on_close): Initialize parameter for
67395         GetVersionEx correctly.
67396         * lib/clean-temp.c (supports_delete_on_close): Likewise.
67398 2012-06-20  Bruno Haible  <bruno@clisp.org>
67400         fdopen: Allow implementations that don't reject invalid fd arguments.
67401         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Let the test pass if fdopen(-1,...)
67402         succeeds.
67403         Reported by Rich Felker <dalias@aerifal.cx>.
67405 2012-06-20  Simon Josefsson  <simon@josefsson.org>
67407         * modules/parse-duration-tests (test_parse_duration_LDADD): Don't
67408         bring in LIBINTL.
67410 2012-06-20  Paul Eggert  <eggert@cs.ucla.edu>
67412         init.sh: do not rely on autoupated PWD
67413         This addresses symptoms of the problem reported by Nelson H.F. Beebe in
67414         <http://lists.gnu.org/r/bug-gzip/2012-06/msg00008.html>.
67415         Although Nelson's bug was not necessarily fixed by this patch,
67416         it seems wise to make the change for safety.
67417         * tests/init.sh (path_prepend_): Do not rely on PWD updating
67418         automagically after 'cd'; this is not reliable on older shells.
67419         (setup_): Fail if we cannot cd to temporary directory.
67421 2012-06-19  Bruno Haible  <bruno@clisp.org>
67423         stat, fstat: Avoid warnings on mingw64.
67424         * lib/stat.c (stat) [_GL_WINDOWS_64_BIT_ST_SIZE]: Undefine before
67425         redefining.
67426         * lib/fstat.c (stat, fstat) [_GL_WINDOWS_64_BIT_ST_SIZE]: Likewise.
67427         Reported by Daniel P. Berrange <berrange@redhat.com>.
67429 2012-06-19  Bruno Haible  <bruno@clisp.org>
67431         stdioext: Add support for musl libc.
67433         * m4/fbufmode.m4 (gl_FUNC_FBUFMODE): Test whether __fbufsize exists.
67434         * lib/fbufmode.c (fbufmode): Add conditional code for musl.
67436         * m4/fseterr.m4: New file.
67437         * lib/fseterr.h (fseterr): Define as an alias of __fseterr if that
67438         function exists.
67439         * modules/fseterr (Files): Add m4/fseterr.m4.
67440         (configure.ac): Invoke gl_FUNC_FSETERR. Compile fseterr.c if
67441         __fseterr does not exist.
67442         (Makefile.am): Remove fseterr.c from lib_SOURCES.
67444         * lib/freadable.h: Update comment.
67446         * lib/fwritable.h: Update comment.
67448         * lib/freading.h: Update comment.
67450         * lib/fwriting.h: Update comment.
67452         * m4/freadahead.m4: New file.
67453         * lib/freadahead.h (freadahead): Define as an alias of __freadahead if
67454         that function exists.
67455         * modules/freadahead (Files): Add m4/freadahead.m4.
67456         (configure.ac): Invoke gl_FUNC_FREADAHEAD. Compile freadahead.c if
67457         __freadahead does not exist.
67458         (Makefile.am): Remove freadahead.c from lib_SOURCES.
67460         * m4/freadptr.m4: New file.
67461         * lib/freadptr.h (freadptr): Define as an alias of __freadptr if that
67462         function exists.
67463         * modules/freadptr (Files): Add m4/freadptr.m4.
67464         (configure.ac): Invoke gl_FUNC_FREADPTR. Compile freadptr.c if
67465         __freadptr does not exist.
67466         (Makefile.am): Remove freadptr.c from lib_SOURCES.
67468         * m4/freadseek.m4: New file.
67469         * lib/freadseek.c (freadptrinc): Use __freadptrinc if that function
67470         exists.
67471         * modules/freadseek (Files): Add m4/freadseek.m4.
67472         (configure.ac): Invoke gl_FUNC_FREADSEEK.
67474         * lib/fpurge.c (fpurge): Update comment.
67476         Reported by and with help from Rich Felker <dalias@aerifal.cx>.
67478 2012-06-19  Bruno Haible  <bruno@clisp.org>
67480         *printf-posix: Put more info into config.log.
67481         * m4/printf.m4 (gl_PRINTF_ENOMEM): Emit conftest's error output and
67482         exit code into config.log.
67484 2012-06-19  Bruno Haible  <bruno@clisp.org>
67486         getopt-gnu: Fix exit code overflow in autoconf test.
67487         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Squash exit code values,
67488         to keep them below < 128.
67490 2012-06-17  Jim Meyering  <meyering@redhat.com>
67492         maint.mk: fix typo in code to derive GPG key at release time
67493         * top/maint.mk (gpg_key_ID): Fix typo: $3 -> $$3
67495 2012-06-17  Paul Eggert  <eggert@cs.ucla.edu>
67497         regex: avoid warning when pointers are not long
67498         * lib/regcomp.c (parse_dup_op, mark_opt_subexp): Cast between void *
67499         and uintptr_t, not long, for portability to hosts where pointers and
67500         long have different sizes.  Issue noted by Daniel P. Berrange in
67501         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00122.html>
67502         and fix suggested by Bruno Haible in
67503         <http://lists.gnu.org/r/bug-gnulib/2012-06/msg00128.html>.
67505 2012-06-17  Bruno Haible  <bruno@clisp.org>
67507         dummy: Relicense into the public domain.
67508         * modules/dummy (License): Set to "public domain".
67509         Suggested by Reuben Thomas.
67511 2012-06-12  Akim Demaille  <akim@lrde.epita.fr>
67513         announce-gen: VPATH issues
67514         * build-aux/announce-gen (--srcdir): New option, used to trim the
67515         $srcdir part of the path from $builddir to NEWS.
67516         * top/maint.mk (announcement): Adjust.
67518 2012-06-12  Akim Demaille  <akim@lrde.epita.fr>
67520         gnu-web-doc-update: VPATH builds
67521         * build-aux/gnu-web-doc-update (--builddir): New option.
67522         Revamp the handling of options.
67523         Prefer $(...) to `...`.
67524         Don't pass --tmpdir=. to mktemp, it is useless given that we specify
67525         the template, and it is GNU mktemp specific.
67526         Prefer set -e to long series of &&.
67527         Restore the initial git branch, not "master".
67528         Properly initialize submodules (don't rely only on bootstrap).
67529         Do not reconfigure blindly, use config.status.
67530         * top/README-release: Update instructions for gnu-web-doc-update.
67532 2012-06-11  Jim Meyering  <meyering@redhat.com>
67534         maint.mk: revert most of the previous change re "all these"
67535         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Remove that pair.
67536         For rationale, see the discussion at
67537         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30912
67539 2012-06-10  Karl Berry  <karl@gnu.org>
67541         * build-aux/gnupload: with --dry-run, do not ask for gpg pw.
67543         * build-aux/gnupload: implement --replace, ftp-upload protocol v1.2.
67545 2012-06-10  Bruce Korb  <bkorb@gnu.org>
67547         parse-duration: Relicense under LGPLv2+.
67548         * modules/parse-duration (License): Change to LGPLv2+.
67550 2012-06-10  Jim Meyering  <meyering@redhat.com>
67552         maint.mk: prohibit common grammar error: "all these"
67553         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Add "all these" to
67554         the list of prohibited word sequences.  It should be "all of these".
67555         * lib/tempname.c (__gen_tempname): Fix one of them.
67557 2012-06-07  Akim Demaille  <akim@lrde.epita.fr>
67559         do-release-commit-and-tag: support VPATH builds
67560         * build-aux/do-release-commit-and-tag: Prefer $(...) to `...`.
67561         (noteworthy): Defined earlier to factor its value.
67562         (noteworthy_stub): New.
67563         Use it to factor.
67564         (help_version): Split into...
67565         (help, version): these.
67566         Adjust the option processing part.
67567         Support "--option=value" in addition to "--option value".
67568         (builddir): New.
67569         (--builddir): New option.
67570         * top/README-release: Document this.
67571         Reword slightly so that the reader cannot understand that he
67572         has to do these steps before calling do-release-commit-and-tag.
67574 2012-06-07  Akim Demaille  <akim@lrde.epita.fr>
67576         readme-release: also require announce-gen and maintainer-makefile
67577         * modules/readme-release (Depends-on): here.
67578         * modules/announce-gen, modules/do-release-commit-and-tag,
67579         modules/gnu-web-doc-update, modules/maintainer-makefile
67580         (Description): Point to readme-release.
67582 2012-06-07  Akim Demaille  <akim@lrde.epita.fr>
67584         maint.mk: fix VPATH issues.
67585         * top/maint.mk (news-check): GNU Make understand $< very well.
67586         (release-prep): NEWS is in $(srcdir).
67588 2012-06-05  Akim Demaille  <akim@lrde.epita.fr>
67590         readme-release: require the promoted modules.
67591         * modules/readme-release (Depends-on): Add
67592         do-release-commit-and-tag, gnupload, and gnu-web-doc-update, used
67593         in this text.
67595 2012-05-21  Paolo Bonzini  <bonzini@gnu.org>
67596             Bruno Haible  <bruno@clisp.org>
67598         error, strerror-override: Support mingw64 from Fedora 17.
67599         * lib/errno.in.h (GNULIB_defined_ESTREAMS): Use a different indicator
67600         for ETXTBSY, ENODATA, ENOSR, ENOSTR, ETIME, EOTHER, compared to
67601         EINPROGRESS.
67602         * lib/strerror-override.h (strerror_override): Test it.
67603         * lib/strerror-override.c (strerror_override): Likewise.
67604         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Test also ETXTBSY.
67606 2012-05-21  Paolo Bonzini  <bonzini@gnu.org>
67607             Bruno Haible  <bruno@clisp.org>
67609         error, strerror-override: Support mingw64 from Fedora 17.
67610         * lib/errno.in.h (GNULIB_defined_ENOTRECOVERABLE): Use a different
67611         indicator for ENOTRECOVERABLE, compared to EOWNERDEAD.
67612         * lib/strerror-override.h (strerror_override): Test it.
67613         * lib/strerror-override.c (strerror_override): Likewise.
67615 2012-06-03  Bruno Haible  <bruno@clisp.org>
67617         error, strerror-override: Support new errno values from POSIX:2008.
67618         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Test also EOWNERDEAD and
67619         ENOTRECOVERABLE.
67620         * lib/errno.in.h (EOWNERDEAD, ENOTRECOVERABLE): Define on all
67621         platforms.
67622         * lib/strerror-override.c (strerror_override): Conditionalize the
67623         EOWNERDEAD, ENOTRECOVERABLE handling on GNULIB_defined_EOWNERDEAD.
67624         * lib/strerror-override.h (strerror_override): Declare also if
67625         GNULIB_defined_EOWNERDEAD is defined.
67626         * tests/test-errno.c (e130, e131): New variables.
67627         * doc/posix-headers/errno.texi: Mention the status for EOWNERDEAD,
67628         ENOTRECOVERABLE.
67629         Reported by Paolo Bonzini.
67631 2012-05-31  Jim Meyering  <meyering@redhat.com>
67633         savewd: add missing dependency on sys_wait module
67634         * modules/savewd (Depends-on): Add sys_wait, needed at least
67635         for MSVC.  Report and suggested change by Michael Goffioul.
67637 2012-05-29  Paul Eggert  <eggert@cs.ucla.edu>
67639         system-quote-tests: port to CentOS 5
67640         Problem reported by Tom G. Christensen in
67641         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00255.html>.
67642         * tests/test-system-quote-child.c (fclose, fprintf): Undef.
67644 2012-05-29  Jim Meyering  <meyering@redhat.com>
67646         maint: fix typos in comments and ChangeLog
67647         Culprits identified and fixed mostly automatically using these commands:
67648         git ls-files | misspellings -f - |grep -v '^ERROR:' |perl -pe \
67649         's/^(.*?)\[(\d+)\]: (\w+) -> "(.*?)"$/sed -i '\''${2}s!$3!$4!'\'' $1/'
67650         using http://github.com/lyda/misspell-check
67651         * ChangeLog: Fix typos.
67652         * doc/solaris-versions: Likewise.
67653         * lib/regexec.c (re_search_stub): Likewise.
67654         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
67656 2012-05-27  Paul Eggert  <eggert@cs.ucla.edu>
67658         manywarnings: remove duplicate -Wmultichar entry
67659         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Remove duplicate
67660         entry for -Wmultichar.  -Wno-multichar is in the GCC 4.7.0 manual,
67661         so keep the entry marked as documented.
67663 2012-05-27  Karl Berry  <karl@gnu.org>
67665         * config/srclist.txt (mktime.c): remove last libc sync,
67666         perhaps just temporarily.
67668 2012-05-26  Paul Eggert  <eggert@cs.ucla.edu>
67670         regex: don't assume uint64_t or uint32_t
67671         * lib/regcomp.c (init_word_char): Don't assume that the types
67672         uint64_t and uint32_t exist.  The C standard doesn't guarantee
67673         them, and on some 32-bit compilers there is no uint64_t.
67674         Problem reported by Gianluigi Tiesi in
67675         <http://lists.gnu.org/r/bug-gnulib/2012-03/msg00154.html>.
67677 2012-05-25  Jim Meyering  <meyering@redhat.com>
67679         maint.mk: add strncpy-prohibiting syntax-check rule
67680         * top/maint.mk (sc_prohibit_strncpy): New rule, from coreutils.
67682 2012-05-24  Jim Meyering  <meyering@redhat.com>
67684         maint.mk: compute $(gpg_key_ID) more portably
67685         * top/maint.mk (gpg_key_ID): Use awk in place of sed '{...;...;}'.
67686         That use of sed is not portable to some fringe systems.
67687         Reported by Paul Eggert in
67688         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30793/focus=30802
67690 2012-05-23  Paul Eggert  <eggert@cs.ucla.edu>
67692         mktime: sync from glibc
67693         * config/srclist.txt: Uncomment mktime.c.
67694         * lib/mktime.c: Sync from glibc master.  This incorporates 3 changes.
67695         First, indent with tabs, since glibc uses tabs and doesn't want to
67696         change and we'd rather be identical to glibc.  Also, two small
67697         coding changes:
67698         (isdst_differ): Use &&, not &, as && is the usual style.
67699         (__mktime_internal): Rename local var from abs_diff to approx_abs_diff
67700         for clarity.
67702 2012-05-23  Akim Demaille  <akim@lrde.epita.fr>
67704         announce-gen: du -h is more portable than du --human
67705         * build-aux/announce-gen (sizes): Invoke du with -h instead
67706         of --human.  Accept leading white space in its output.
67708 2012-05-23  Akim Demaille  <akim@lrde.epita.fr>
67710         announce-gen: Improve diagnostics.
67711         * build-aux/announce-gen: When parsing command line options,
67712         prefer "announce-gen: option --release-type requires an argument"
67713         to "Option release-type requires an argument".
67715 2012-05-23  Akim Demaille  <akim@lrde.epita.fr>
67717         maint.mk: gpg_key_ID: use sed more portably
67718         * top/maint.mk (gpg_key_ID): End sed block with a semicolon before
67719         the closing brace.
67720         (refresh-po): Fuse two sed invocations into one.
67722 2012-05-15  Akim Demaille  <akim@lrde.epita.fr>
67724         gitlog-to-changelog: support the log message format used in Bison.
67725         * build-aux/gitlog-to-changelog: Support --strip-tab and
67726         --strip-cherry-picked.
67728 2012-05-21  Paolo Bonzini  <bonzini@gnu.org>
67730         poll/select: prevent busy-waiting.  SwitchToThread() only gives away
67731         the rest of the current time slice to another thread in the current
67732         process. So if the thread that feeds the file decscriptor we're
67733         polling is not in the current process, we get busy-waiting.
67734         * lib/poll.c: Use SleepEx(1, TRUE) instead of SwitchToThread().
67735         Patch from Theodore Leblond.
67736         * lib/select.c: Split polling out of the loop that sets the output
67737         fd_sets.  Check for zero result and loop if the wait timeout is
67738         infinite.
67740 2012-05-21  Simon Josefsson  <simon@josefsson.org>
67742         select: Fix build error on IRIX 6.5.
67743         * lib/select.c: Include stddef.h for NULL.
67745 2012-05-21  Simon Josefsson  <simon@josefsson.org>
67747         gc: fix libgcrypt detection on older machines.
67748         * m4/gc.m4: Reject libgcrypt earlier than 1.4.4.  Collapse
67749         copyright years because the file has been distributed every year
67750         since it was created.
67752 2012-05-18  Paul Eggert  <eggert@cs.ucla.edu>
67754         crypto: fix bug in large buffer handling
67755         Problem reported by Serge Belyshev for glibc in
67756         <http://sourceware.org/bugzilla/show_bug.cgi?id=14090> and for gnulib in
67757         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00226.html>.
67758         * lib/md4.c (md4_process_block):
67759         * lib/md5.c (md5_process_block):
67760         * lib/sha1.c (sha1_process_block):
67761         * lib/sha256.c (sha256_process_block):
67762         Don't assume the buffer length is less than 2**32.
67763         * lib/sha512.c (sha512_process_block): Likewise.
67764         Here, the bug is present only in the rare case where the host does
67765         not support uint64_t or where size_t is wider than 64 bits.
67766         Use u64size to work around the problems.
67767         * lib/u64.h (u64size): New macro.
67769 2012-05-15  Pádraig Brady  <P@draigBrady.com>
67771         fsusage: fix block size returned on older Linux 2.6
67773         * lib/fsusage.c: Fall back to (struct statfs).f_frsize
67774         which is available since Linux 2.6.
67775         * m4/fsusage.m4 (STAT_STATFS2_FRSIZE): Always define
67776         when the member is available so it can be used as a fallback.
67777         * doc/posix-functions/statvfs.texi: Mention the hang issue
67778         on Linux < 2.6.36.
67780 2012-05-14  Paul Eggert  <eggert@cs.ucla.edu>
67782         bootstrap: suppress stderr chatter
67783         * build-aux/bootstrap (insert_sorted_if_absent, main program):
67784         Omit unnecessary chatter to stderr.  The main program chatter
67785         was there only inadvertantly.
67787         bootstrap: .gitignore files created by autopoint, libtool
67788         I ran into this problem when bootstrapping the latest diffutils.
67789         After './bootstrap', 'git status' reported lots of untracked files
67790         m4/codeset.m4, m4/gettext.m4, etc.  These files were created by
67791         autopoint and do not need to be version-controlled.
67792         * build-aux/bootstrap: Put into .gitignore the files that
67793         autopoint and libtool create, by keeping track of files that exist
67794         after but not before these programs are run.
67795         (version_controlled_file): Move up.  2nd arg is now full file
67796         name, not base name; this is more convenient.  Put CVS at the end,
67797         as it's now somewhat deprecated.
67799 2012-05-14  Jim Meyering  <meyering@redhat.com>
67801         ignore-value.h: remove unused _GL_ATTRIBUTE_DEPRECATED definition
67802         * lib/ignore-value.h (_GL_ATTRIBUTE_DEPRECATED): Remove now-unused
67803         definition.  Reported by Bruno Haible.
67805 2012-05-13  Bruno Haible  <bruno@clisp.org>
67806             Paul Eggert  <eggert@cs.ucla.edu>
67808         binary-io: Define set_binary_mode function.
67809         * lib/binary-io.h (set_binary_mode): New function.
67810         (SET_BINARY): Define in terms of set_binary_mode.
67811         * modules/binary-io (configure.ac): Require AC_C_INLINE.
67812         * tests/test-binary-io.c (main): Accept an argument, and test either
67813         set_binary_mode or SET_BINARY depending on the argument.
67814         * tests/test-binary-io.sh: Invoke test-binary-io twice, with an
67815         argument. Clean up also t-bin-out0.tmp.
67817 2012-05-13  Stefano Lattarini  <stefano.lattarini@gmail.com>
67819         bootstrap: take advantage of POSIX shell features
67821         The 'bootstrap' script offered by Gnulib script already uses POSIX
67822         shell features (like $((...)) arithmetic expansions) that are not
67823         supported by legacy Bourne shells like Solaris 10 /bin/sh.  This
67824         means that bootstrap must already be run using a proper POSIX shell,
67825         which will thus provide more features, like ${var#pattern} parameter
67826         expansion or inversion of a command exit status with '!'.  We can
67827         thus use these features to improve the clarity and the performances
67828         of the bootstrap script.
67830         Suggested by Eric Blake.
67832         * build-aux/bootstrap: Prefer xpg4 parameter expansions over use
67833         of sed/expr plus command substitutions, to save some forks.  While
67834         we are at it, prefer the POSIX $(...) form of command substitution,
67835         rather than the legacy form `...` (since the former is visually
67836         clearer and interacts better with quoting), and prefer the idiom:
67837           "if ! CMD; then ACTION ..."
67838         over the idiom:
67839           "if CMD; then :; else ACTION ..."
67840         which was required by legacy Bourne shells not supporting '!'.
67842 2012-05-12  Bruno Haible  <bruno@clisp.org>
67844         system-quote: Add more comments.
67845         * lib/system-quote.h: Add more comments about wilcards and limitations.
67846         Suggested by Eli Zaretskii <eliz@gnu.org>.
67848         sh-quote, system-quote: Add comments about wildcards.
67849         * lib/sh-quote.h: Clarify what happens with wildcard characters.
67850         * lib/system-quote.h: Likewise.
67851         Reported by Eli Zaretskii <eliz@gnu.org>.
67853 2012-05-11  Paul Eggert  <eggert@cs.ucla.edu>
67855         fsusage: check for GNU/Linux statvfs problem dynamically
67856         * lib/fsusage.c [STAT_STATVFS && __linux__ && (__GLIBC__||__UCLIBC__)]:
67857         Define STAT_STATFS2_BSIZE too, since in this case the code now
67858         checks dynamically whether statvfs is reliable, falling back on
67859         Linux-style statfs otherwise.
67860         (statvfs_works): New function, for dynamically testing statvfs.
67861         (get_fs_usage) [STAT_STATVFS]: Use it.
67862         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Remove static check for
67863         statvfs on GNU/Linux hosts, since it's now done dynamically.
67865 2012-05-10  Bruno Haible  <bruno@clisp.org>
67867         system-quote, execute, spawn-pipe: Escape '?' on Windows.
67868         * lib/system-quote.c (SHELL_SPECIAL_CHARS, CMD_SPECIAL_CHARS): Add the
67869         '?' character.
67870         * lib/w32spawn.h (SHELL_SPECIAL_CHARS): Likewise.
67871         * tests/test-system-quote-main.c (check_all): Check also strings like
67872         "??????????".
67873         Reported by Eli Zaretskii <eliz@gnu.org>.
67875 2012-05-10  Paul Eggert  <eggert@cs.ucla.edu>
67877         _Noreturn: port config.h to gcc -Wundef
67878         * m4/gnulib-common.m4 (gl_COMMON_BODY): Check that __STDC_VERSION__ is
67879         defined before using it, for gcc -Wundef.  Reported by Akim Demaille in
67880         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00147.html>.
67882 2012-05-10  Bruno Haible  <bruno@clisp.org>
67884         system-quote: Refactor.
67885         * lib/system-quote.h (system_quote_copy): Fix comment.
67886         * lib/system-quote.c (windows_createprocess_quote, windows_cmd_quote):
67887         New functions, extracted from system_quote_copy.
67888         (system_quote_length, system_quote_copy): Use these functions.
67889         Reported by Paul Eggert.
67891 2012-05-08  Bruno Haible  <bruno@clisp.org>
67893         execute, spawn-pipe: Escape '*' characters in arguments on Windows.
67894         * lib/w32spawn.h (SHELL_SPECIAL_CHARS): Add the '*' character.
67896 2012-05-08  Bruno Haible  <bruno@clisp.org>
67898         Tests for module 'system-quote'.
67899         * modules/system-quote-tests: New file.
67900         * tests/test-system-quote.sh: New file.
67901         * tests/test-system-quote-main.c: New file.
67902         * tests/test-system-quote-child.c: New file.
67904         New module 'system-quote'.
67905         * lib/system-quote.h: New file.
67906         * lib/system-quote.c: New file.
67907         * modules/system-quote: New file.
67909 2012-05-08  Bruno Haible  <bruno@clisp.org>
67911         sh-quote: Make C++ safe and allow multiple inclusion.
67912         * lib/sh-quote.h: Add double-inclusion guard. For C++, wrap function
67913         declarations in extern "C".
67915 2012-05-08  Bruno Haible  <bruno@clisp.org>
67917         sh-quote tests: Make tests stricter.
67918         * tests/test-sh-quote.c (check_one): Check the return value of
67919         shell_quote_copy.
67920         (main): Check a string with a CR character. Check a string that
67921         contains UCHAR_MAX.
67923 2012-05-08  Akim Demaille  <akim@lrde.epita.fr>
67925         warnings.m4: provide a means to specify the program to compile.
67926         * m4/warnings.m4 (gl_COMPILER_OPTION_IF): New, extracted from...
67927         (gl_WARN_ADD): here.
67928         Use gl_AS_VAR_APPEND.
67929         Support an argument to specify the program to compile.
67930         (gl_WARN_ADD): Accept an argument to specify the program to compile.
67931         AC_SUBST the WARN_CFLAGS when they are used.
67932         * modules/warnings (configure.ac): Don't AC_SUBST WARN_CFLAGS,
67933         leave this to gl_WARN_ADD.
67935 2012-05-08  Eric Blake  <eblake@redhat.com>
67937         doc: recommendations on gettext version
67938         * doc/gnulib-tool.texi (gettextize and autopoint): Document the
67939         choice between versions.
67940         * DEPENDENCIES (gettext): Cover both approaches.
67942 2012-05-08  Jim Meyering  <meyering@redhat.com>
67944         init.sh: explain why EXEEXT support uses aliases rather than functions
67945         * tests/init.sh: Add a comment.
67947         init.sh: don't let bash aliases interfere with tests
67948         * tests/init.sh: Undefine any pre-defined aliases if the selected shell
67949         is bash.  This avoids problems for those who alias standard commands to
67950         non-conforming uses, like those reported in http://bugs.gnu.org/11256.
67951         Suggested by Tim Mooney <Tim.Mooney@ndsu.edu>.
67953 2012-05-07  Paul Eggert  <eggert@cs.ucla.edu>
67955         stdint: be more consistent with glibc, SunOS libc
67956         * lib/stdint.in.h (gl_int_fast8_t, gl_uint_fast8_t)
67957         (gl_int_fast16_t, gl_uint_fast16_t)
67958         (gl_int_fast32_t, gl_uint_fast32_t)
67959         (INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX)
67960         (INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX)
67961         (INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
67962         Be consistent with glibc by default, and with SunOS 5.10 and later
67963         if __sun is defined.  This lessens the likelihood of clashes if
67964         code compiled for older hosts is combined with code compiled for
67965         newer ones.  Problem reported by Niels Möller in
67966         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00074.html>.
67968 2012-05-07  Eric Blake  <eblake@redhat.com>
67970         isatty: relax license to LGPLv2+
67971         * modules/isatty (License): Relax license.
67973 2012-05-06  Paul Eggert  <eggert@cs.ucla.edu>
67975         stat-size: comment fix
67976         * lib/stat-size.h: Remove obsolete comment about indenting.
67978 2012-05-06  Bruno Haible  <bruno@clisp.org>
67980         Tests for module 'sh-quote'.
67981         * modules/sh-quote-tests: New file.
67982         * tests/test-sh-quote.c: New file.
67984 2012-05-06  Bruno Haible  <bruno@clisp.org>
67986         sh-quote: Improve shell_quote_argv's signature.
67987         * lib/sh-quote.h (shell_quote_argv): Make argument array a 'const *'.
67988         * lib/sh-quote.c (shell_quote_argv): Likewise.
67990 2012-05-06  Paul Eggert  <eggert@cs.ucla.edu>
67992         stdint: document issues with int_fast8_t etc.
67993         * doc/posix-headers/stdint.texi (stdint.h): Say that other
67994         stdint.h substitutes may define these types differently.  See
67995         <http://lists.gnu.org/r/bug-gnulib/2012-05/msg00071.html>.
67997 2012-05-05  Bruno Haible  <bruno@clisp.org>
67999         nanosleep: Avoid guessing wrong when cross-compiling to Linux.
68000         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require AC_CANONICAL_HOST. When
68001         cross-compiling, set gl_cv_func_nanosleep to either 'guessing no'
68002         or 'guessing no (mishandles large arguments)'.
68004 2012-05-05  Bruno Haible  <bruno@clisp.org>
68006         link-follow: Avoid guessing wrong when cross-compiling to glibc/Linux.
68007         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Require
68008         AC_CANONICAL_HOST. When cross-compiling to a glibc/Linux platform,
68009         set gl_cv_func_link_follows_symlink to "guessing no".
68011 2012-05-05  Bruno Haible  <bruno@clisp.org>
68013         tzset: Avoid guessing wrong when cross-compiling to glibc systems.
68014         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require AC_CANONICAL_HOST. When
68015         cross-compiling to a glibc platform, set gl_cv_func_tzset_clobber to
68016         "guessing no".
68017         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Update.
68019 2012-05-05  Bruno Haible  <bruno@clisp.org>
68021         d-ino: Avoid guessing "no" when cross-compiling to glibc/Linux systems.
68022         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Require
68023         AC_CANONICAL_HOST. When cross-compiling to a glibc/Linux platform,
68024         set gl_cv_struct_dirent_d_ino to "guessing yes".
68026 2012-05-05  Bruno Haible  <bruno@clisp.org>
68028         fseeko-tests, ftello-tests: Avoid "guessing no" when cross-compiling.
68029         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Require AC_CANONICAL_HOST. When
68030         cross-compiling to a glibc platform, set gl_cv_func_ungetc_works to
68031         "guessing yes".
68033 2012-05-05  Bruno Haible  <bruno@clisp.org>
68035         signbit: Avoid "guessing no" when cross-compiling to glibc systems.
68036         * m4/signbit.m4 (gl_SIGNBIT): Require AC_CANONICAL_HOST. When cross-
68037         compiling to a glibc system, set gl_cv_func_signbit and
68038         gl_cv_func_signbit_gcc to "guessing yes".
68040 2012-05-05  Bruno Haible  <bruno@clisp.org>
68042         strerror: Avoid "guessing no" when cross-compiling to glibc systems.
68043         * m4/strerror.m4 (gl_FUNC_STRERROR): Require AC_CANONICAL_HOST. When
68044         cross-compiling to a glibc platform, set gl_cv_func_working_strerror
68045         to "guessing yes".
68046         (gl_FUNC_STRERROR_0): Require AC_CANONICAL_HOST. When cross-compiling
68047         to a glibc platform, set gl_cv_func_strerror_0_works to "guessing yes".
68049 2012-05-05  Bruno Haible  <bruno@clisp.org>
68051         canonicalize[-lgpl]: Avoid "guessing no" when cross-compiling to glibc.
68052         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Require
68053         AC_CANONICAL_HOST. When cross-compiling to a glibc system, set
68054         gl_cv_func_realpath_works to "guessing yes".
68056 2012-05-05  Bruno Haible  <bruno@clisp.org>
68058         gettimeofday: Avoid bad guess when cross-compiling to glibc systems.
68059         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY_CLOBBER): Require
68060         AC_CANONICAL_HOST. When cross-compiling, guess no on glibc platforms.
68062 2012-05-04  Bruno Haible  <bruno@clisp.org>
68064         Tweak last commit.
68065         * m4/off_t.m4 (gl_TYPE_OFF_T): Tweak comments.
68066         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
68068 2012-05-04  Paul Eggert  <eggert@cs.ucla.edu>
68070         unistd_h: make it easier to avoid sys_types_h
68071         This is useful for Emacs, which has its own method of porting to
68072         Windows, and which therefore does not need the sys_types_h module.
68073         * m4/off_t.m4: New file, defining gl_TYPE_OFF_T, which contains
68074         code moved here from gl_SYS_TYPES_H.
68075         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Require it instead of
68076         using the code directly.
68077         * m4/unistd_h.m4 (gl_UNISTD_H): Require gl_TYPE_OFF_T, not
68078         gl_SYS_TYPES_H.
68079         * modules/sys_types (Files):
68080         * modules/unistd (Files): Add m4/off_t.m4.
68082 2012-05-03  Bruno Haible  <bruno@clisp.org>
68084         lstat: Avoid "guessing no" when cross-compiling to glibc systems.
68085         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): When cross-
68086         compiling, set gl_cv_func_lstat_dereferences_slashed_symlink to
68087         "guessing yes" or "guessing no".
68088         (gl_FUNC_LSTAT): Update.
68089         * m4/fstatat.m4 (gl_FUNC_FSTATAT): Update.
68090         * m4/openat.m4 (gl_FUNC_OPENAT): Update.
68091         * m4/unlinkat.m4 (gl_FUNC_UNLINKAT): Update.
68093 2012-05-03  Bruno Haible  <bruno@clisp.org>
68095         *alloc-gnu, eealloc: Avoid "guessing no" when cross-compiling to glibc.
68096         * m4/malloc.m4 (_AC_FUNC_MALLOC_IF): Override in autoconf < 2.70.
68097         * m4/realloc.m4 (_AC_FUNC_REALLOC_IF): Override in autoconf < 2.70.
68098         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Require AC_CANONICAL_HOST. When
68099         cross-compiling, choose the first alternative on glibc systems.
68100         * modules/eealloc (Files): Add m4/malloc.m4, m4/realloc.m4.
68102 2012-05-03  Bruno Haible  <bruno@clisp.org>
68104         getgroups: Avoid "guessing no" when cross-compiling to glibc systems.
68105         * m4/getgroups.m4 (AC_FUNC_GETGROUPS): Override in autoconf < 2.70.
68106         (gl_FUNC_GETGROUPS): Adapt to change of ac_cv_func_getgroups_works.
68108 2012-05-03  Bruno Haible  <bruno@clisp.org>
68110         chown: Avoid "guessing no" when cross-compiling to glibc systems.
68111         * m4/chown.m4 (AC_FUNC_CHOWN): Override in autoconf < 2.70.
68113 2012-05-03  Bruno Haible  <bruno@clisp.org>
68115         Avoid "guessing no" guesses when cross-compiling to glibc systems.
68116         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Require AC_CANONICAL_HOST. When cross-
68117         compiling to glibc systems, set gl_cv_func_cbrtl_ieee to "guessing yes".
68118         * m4/ceil.m4 (gl_FUNC_CEIL): Require AC_CANONICAL_HOST. When cross-
68119         compiling to glibc systems, set gl_cv_func_ceil_ieee to "guessing yes".
68120         * m4/ceilf.m4 (gl_FUNC_CEILF): Require AC_CANONICAL_HOST. When cross-
68121         compiling to glibc systems, set gl_cv_func_ceilf_ieee to "guessing yes".
68122         * m4/ceill.m4 (gl_FUNC_CEILL): Require AC_CANONICAL_HOST. When cross-
68123         compiling to glibc systems, set gl_cv_func_ceill_ieee to "guessing yes".
68124         * m4/chown.m4 (gl_FUNC_CHOWN): Require AC_CANONICAL_HOST. When cross-
68125         compiling to glibc systems, set gl_cv_func_chown_slash_works,
68126         gl_cv_func_chown_ctime_works to "guessing yes".
68127         * m4/lchown.m4 (gl_FUNC_LCHOWN): Update.
68128         * m4/exp2l.m4 (gl_FUNC_EXP2L): Require AC_CANONICAL_HOST. When cross-
68129         compiling to glibc systems, set gl_cv_func_exp2l_ieee to "guessing yes".
68130         * m4/expm1.m4 (gl_FUNC_EXPM1): Require AC_CANONICAL_HOST. When cross-
68131         compiling to glibc systems, set gl_cv_func_expm1_ieee to "guessing yes".
68132         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require AC_CANONICAL_HOST. When cross-
68133         compiling to glibc systems, set gl_cv_func_open_directory_works to
68134         "guessing yes".
68135         * m4/fstat.m4 (gl_FUNC_FSTAT): Update.
68136         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Require AC_CANONICAL_HOST. When
68137         cross-compiling to glibc systems, set gl_cv_func_fdopendir_works to
68138         "guessing yes".
68139         * m4/floor.m4 (gl_FUNC_FLOOR): Require AC_CANONICAL_HOST. When cross-
68140         compiling to glibc systems, set gl_cv_func_floor_ieee to "guessing yes".
68141         * m4/floorf.m4 (gl_FUNC_FLOORF): Require AC_CANONICAL_HOST. When cross-
68142         compiling to glibc systems, set gl_cv_func_floorf_ieee to
68143         "guessing yes".
68144         * m4/fmod.m4 (gl_FUNC_FMOD): Require AC_CANONICAL_HOST. When cross-
68145         compiling to glibc systems, set gl_cv_func_fmod_ieee to "guessing yes".
68146         * m4/fmodf.m4 (gl_FUNC_FMODF): Require AC_CANONICAL_HOST. When cross-
68147         compiling to glibc systems, set gl_cv_func_fmodf_ieee to "guessing yes".
68148         * m4/fmodl.m4 (gl_FUNC_FMODL): Require AC_CANONICAL_HOST. When cross-
68149         compiling to glibc systems, set gl_cv_func_fmodl_ieee to "guessing yes".
68150         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Require AC_CANONICAL_HOST. When
68151         cross-compiling to glibc systems, set gl_cv_func_getgroups_works to
68152         "guessing yes".
68153         * m4/hypot.m4 (gl_FUNC_HYPOT): Require AC_CANONICAL_HOST. When cross-
68154         compiling to glibc systems, set gl_cv_func_hypot_ieee to "guessing yes".
68155         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Require AC_CANONICAL_HOST. When cross-
68156         compiling to glibc systems, set gl_cv_func_hypotf_ieee to
68157         "guessing yes".
68158         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Require AC_CANONICAL_HOST. When cross-
68159         compiling to glibc systems, set gl_cv_func_hypotl_ieee to
68160         "guessing yes".
68161         * m4/link.m4 (gl_FUNC_LINK): Require AC_CANONICAL_HOST. When cross-
68162         compiling to glibc systems, set gl_cv_func_link_works to "guessing yes".
68163         * m4/log.m4 (gl_FUNC_LOG): Require AC_CANONICAL_HOST. When cross-
68164         compiling to glibc systems, set gl_cv_func_log_ieee to "guessing yes".
68165         * m4/logf.m4 (gl_FUNC_LOGF): Require AC_CANONICAL_HOST. When cross-
68166         compiling to glibc systems, set gl_cv_func_logf_ieee to "guessing yes".
68167         * m4/log10.m4 (gl_FUNC_LOG10): Require AC_CANONICAL_HOST. When cross-
68168         compiling to glibc systems, set gl_cv_func_log10_ieee to "guessing yes".
68169         * m4/log10f.m4 (gl_FUNC_LOG10F): Require AC_CANONICAL_HOST. When cross-
68170         compiling to glibc systems, set gl_cv_func_log10f_ieee to
68171         "guessing yes".
68172         * m4/log1p.m4 (gl_FUNC_LOG1P): Require AC_CANONICAL_HOST. When cross-
68173         compiling to glibc systems, set gl_cv_func_log1p_ieee to "guessing yes".
68174         * m4/log1pf.m4 (gl_FUNC_LOG1PF): Require AC_CANONICAL_HOST. When cross-
68175         compiling to glibc systems, set gl_cv_func_log1pf_ieee to
68176         "guessing yes".
68177         * m4/log1pl.m4 (gl_FUNC_LOG1PL): Require AC_CANONICAL_HOST. When cross-
68178         compiling to glibc systems, set gl_cv_func_log1pl_ieee to
68179         "guessing yes".
68180         * m4/log2.m4 (gl_FUNC_LOG2): Require AC_CANONICAL_HOST. When cross-
68181         compiling to glibc systems, set gl_cv_func_log2_ieee to "guessing yes".
68182         * m4/log2f.m4 (gl_FUNC_LOG2F): Require AC_CANONICAL_HOST. When cross-
68183         compiling to glibc systems, set gl_cv_func_log2f_ieee to "guessing yes".
68184         * m4/mkdir.m4 (gl_FUNC_MKDIR): Require AC_CANONICAL_HOST. When cross-
68185         compiling to glibc systems, set gl_cv_func_mkdir_trailing_slash_works,
68186         gl_cv_func_mkdir_trailing_dot_works to "guessing yes".
68187         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Require AC_CANONICAL_HOST. When cross-
68188         compiling to glibc systems, set gl_cv_func_mkfifo_works to
68189         "guessing yes".
68190         * m4/mknod.m4 (gl_FUNC_MKNOD): Require AC_CANONICAL_HOST. When cross-
68191         compiling to glibc systems, set gl_cv_func_mknod_works to
68192         "guessing yes".
68193         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_CANONICAL_HOST. When
68194         cross-compiling to glibc systems, set gl_cv_func_working_mkstemp to
68195         "guessing yes".
68196         * m4/modf.m4 (gl_FUNC_MODF): Require AC_CANONICAL_HOST. When cross-
68197         compiling to glibc systems, set gl_cv_func_modf_ieee to "guessing yes".
68198         * m4/modff.m4 (gl_FUNC_MODFF): Require AC_CANONICAL_HOST. When cross-
68199         compiling to glibc systems, set gl_cv_func_modff_ieee to "guessing yes".
68200         * m4/modfl.m4 (gl_FUNC_MODFL): Require AC_CANONICAL_HOST. When cross-
68201         compiling to glibc systems, set gl_cv_func_modfl_ieee to "guessing yes".
68202         * m4/putenv.m4 (gl_FUNC_PUTENV): Require AC_CANONICAL_HOST. When cross-
68203         compiling to glibc systems, set gl_cv_func_svid_putenv to
68204         "guessing yes".
68205         * m4/readlink.m4 (gl_FUNC_READLINK): Require AC_CANONICAL_HOST. When
68206         cross-compiling to glibc systems, set gl_cv_func_readlink_works to
68207         "guessing yes".
68208         * m4/remainder.m4 (gl_FUNC_REMAINDER): Require AC_CANONICAL_HOST. When
68209         cross-compiling to glibc systems, set gl_cv_func_remainder_ieee to
68210         "guessing yes".
68211         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Require AC_CANONICAL_HOST.
68212         When cross-compiling to glibc systems, set gl_cv_func_remainderf_ieee
68213         to "guessing yes".
68214         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Require AC_CANONICAL_HOST.
68215         When cross-compiling to glibc systems, set gl_cv_func_remainderl_ieee
68216         to "guessing yes".
68217         * m4/rmdir.m4 (gl_FUNC_RMDIR): Require AC_CANONICAL_HOST. When cross-
68218         compiling to glibc systems, set gl_cv_func_rmdir_works to
68219         "guessing yes".
68220         * m4/unlink.m4 (gl_FUNC_UNLINK): Require AC_CANONICAL_HOST. When cross-
68221         compiling to glibc systems, set gl_cv_func_unlink_honors_slashes,
68222         gl_cv_func_unlink_parent_fails to "guessing yes".
68223         * m4/remove.m4 (gl_FUNC_REMOVE): Update.
68224         * m4/rename.m4 (gl_FUNC_RENAME): Require AC_CANONICAL_HOST. When cross-
68225         compiling to glibc systems, set gl_cv_func_rename_slash_dst_works,
68226         gl_cv_func_rename_slash_src_works, gl_cv_func_rename_link_works,
68227         gl_cv_func_rename_dest_works to "guessing yes".
68228         * m4/round.m4 (gl_FUNC_ROUND): Require AC_CANONICAL_HOST. When cross-
68229         compiling to glibc systems, set gl_cv_func_round_ieee to "guessing yes".
68230         * m4/roundf.m4 (gl_FUNC_ROUNDF): Require AC_CANONICAL_HOST. When cross-
68231         compiling to glibc systems, set gl_cv_func_roundf_ieee to
68232         "guessing yes".
68233         * m4/roundl.m4 (gl_FUNC_ROUNDL): Require AC_CANONICAL_HOST. When cross-
68234         compiling to glibc systems, set gl_cv_func_roundl_ieee to
68235         "guessing yes".
68236         * m4/setenv.m4 (gl_FUNC_SETENV): Require AC_CANONICAL_HOST. When cross-
68237         compiling to glibc systems, set gl_cv_func_setenv_works to
68238         "guessing yes".
68239         (gl_FUNC_UNSETENV): Require AC_CANONICAL_HOST. When cross-
68240         compiling to glibc systems, set gl_cv_func_unsetenv_works to
68241         "guessing yes".
68242         * m4/sleep.m4 (gl_FUNC_SLEEP): Require AC_CANONICAL_HOST. When cross-
68243         compiling to glibc systems, set gl_cv_func_sleep_works to
68244         "guessing yes".
68245         * m4/stat.m4 (gl_FUNC_STAT): Require AC_CANONICAL_HOST. When cross-
68246         compiling to glibc systems, set gl_cv_func_stat_file_slash to
68247         "guessing yes".
68248         * m4/symlink.m4 (gl_FUNC_SYMLINK): Require AC_CANONICAL_HOST. When
68249         cross-compiling to glibc systems, set gl_cv_func_symlink_works to
68250         "guessing yes".
68251         * m4/trunc.m4 (gl_FUNC_TRUNC): Require AC_CANONICAL_HOST. When cross-
68252         compiling to glibc systems, set gl_cv_func_trunc_ieee to "guessing yes".
68253         * m4/truncf.m4 (gl_FUNC_TRUNCF): Require AC_CANONICAL_HOST. When cross-
68254         compiling to glibc systems, set gl_cv_func_truncf_ieee to
68255         "guessing yes".
68256         * m4/truncl.m4 (gl_FUNC_TRUNCL): Require AC_CANONICAL_HOST. When cross-
68257         compiling to glibc systems, set gl_cv_func_truncl_ieee to
68258         "guessing yes".
68259         * m4/usleep.m4 (gl_FUNC_USLEEP): Require AC_CANONICAL_HOST. When cross-
68260         compiling to glibc systems, set gl_cv_func_usleep_works to
68261         "guessing yes".
68262         * m4/utimens.m4 (gl_UTIMENS): Require AC_CANONICAL_HOST. When cross-
68263         compiling to glibc systems, set gl_cv_func_futimesat_works to
68264         "guessing yes".
68266 2012-05-03  Bruno Haible  <bruno@clisp.org>
68268         Say "guessing yes" or "guessing no" when cross-compiling.
68269         * m4/dup2.m4 (gl_FUNC_DUP2): When cross-compiling, set
68270         gl_cv_func_dup2_works to "guessing yes" or "guessing no".
68271         * m4/getdelim.m4 (gl_FUNC_GETDELIM): When cross-compiling, set
68272         gl_cv_func_working_getdelim to "guessing yes" or "guessing no".
68273         * m4/getline.m4 (gl_FUNC_GETLINE): When cross-compiling, set
68274         am_cv_func_working_getline to "guessing yes" or "guessing no".
68275         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): When cross-compiling, set
68276         gl_cv_func_memmem_works_always to "guessing yes" or "guessing no".
68277         (gl_FUNC_MEMMEM): When cross-compiling, set
68278         gl_cv_func_memmem_works_fast to "guessing yes" or "guessing no".
68279         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): When cross-compiling, set
68280         gl_cv_func_stpncpy to "guessing yes" or "guessing no".
68281         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): When cross-compiling,
68282         set gl_cv_func_strcasestr_works_always to "guessing yes" or
68283         "guessing no".
68284         (gl_FUNC_STRCASESTR): When cross-compiling, set
68285         gl_cv_func_strcasestr_linear to "guessing yes" or "guessing no".
68286         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): When cross-compiling, set
68287         gl_cv_func_strstr_works_always to "guessing yes" or "guessing no".
68288         (gl_FUNC_STRSTR): When cross-compiling, set
68289         gl_cv_func_strstr_linear to "guessing yes" or "guessing no".
68290         * m4/strtod.m4 (gl_FUNC_STRTOD): When cross-compiling, set
68291         gl_cv_func_strtod_works to "guessing yes" or "guessing no".
68292         * m4/wctype_h.m4 (gl_WCTYPE_H): When cross-compiling, set
68293         gl_cv_func_iswcntrl_works to "guessing yes" or "guessing no".
68295 2012-05-01  Bruno Haible  <bruno@clisp.org>
68297         relocatable-prog: Enable ELF ORIGIN trick also on GNU/kFreeBSD.
68298         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Treat kFreeBSD like Linux.
68299         * build-aux/reloc-ldflags: Likewise.
68300         Suggested by Steven Chamberlain <steven@pyro.eu.org>.
68302 2012-05-01  Bruno Haible  <bruno@clisp.org>
68304         gnulib-tool: Remove transitional code.
68305         * gnulib-tool: Don't warn about --import with 0 arguments any more.
68306         Reported by Dmitriy Selyutin <ghostman.sd@gmail.com>.
68308 2012-05-01  Bruno Haible  <bruno@clisp.org>
68310         getcwd: Fix misindentation.
68311         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Fix indentation.
68313 2012-04-29  Paul Eggert  <eggert@cs.ucla.edu>
68315         exclude: process exclude and include directives in order
68316         This restores the pre-2009 behavior, and is part of a fix of a
68317         grep bug reported by Quentin Arce in
68318         <http://lists.gnu.org/r/bug-grep/2012-04/msg00056.html>.
68319         * lib/exclude.c (struct exclude): Remove 'tail' member.
68320         (new_exclude_segment): Prepend the new segment instead of appending.
68321         Return void, since that's now more convenient.
68322         (file_pattern_matches): Renamed from excluded_file_pattern_p.
68323         (file_name_matches): Renamed from excluded_file_name_p.
68324         (file_pattern_matches, file_name_matches):
68325         Return true if the pattern matches, not if it excludes.
68326         All callers changed.
68327         (excluded_file_name): Process the list in reverse order;
68328         since the list is now reversed this restores the pre-2009 behavior.
68329         (add_exclude): Adjust to new reversed-order list.  Use local var
68330         rather than macro, for clarity.
68331         * tests/test-exclude7.sh: Adjust to corrected behavior.
68333         exclude: handle wildcards with FNM_NOESCAPE and with trailing \
68334         * lib/exclude.c (unescape_pattern): Don't worry about unescaped [;
68335         it's not possible here.  Handle the case of \ at end of pattern
68336         without dumping core.
68337         (add_exclude): Do not unescape the pattern if FNM_NOESCAPE is used.
68339         _Noreturn: future-proof non-GNU and non-MSVC compilers
68340         * build-aux/snippet/_Noreturn.h (_Noreturn):
68341         * m4/gnulib-common.m4 (gl_COMMON_BODY):
68342         Do not define _Noreturn if __STDC_VERSION__ indicates this is
68343         C11 or later.  This is more likely to work with random future C
68344         compilers that are neither GNUish nor MSVCish.  See Vincent Lefevre in
68345         <http://lists.gnu.org/r/bug-gnulib/2012-04/msg00195.html>.
68347         exclude: handle wildcards with FNM_EXTMATCH
68348         * lib/exclude.c (fnmatch_pattern_has_wildcards): Also treat '+(',
68349         '+@', '!(' as wildcards, if FNM_EXTMATCH.  Make it clear in a
68350         comment that "has wildcards" really means "has or may have
68351         wildcards".  Simplify by avoiding the need to call strcspn.
68353 2012-04-29  Bruno Haible  <bruno@clisp.org>
68355         gnulib-tool: Fix list of authors.
68356         * gnulib-tool (func_version): Add Paul Eggert to list of authors.
68358 2012-04-26  Stefano Lattarini  <stefano.lattarini@gmail.com>
68360         bootstrap: support Automake-NG in $buildreq
68361         * bootstrap (check_versions): Handle automake and aclocal from
68362         Automake-NG specially.  They can be specified as respectively
68363         the "automake-ng" and "aclocal-ng" requirements.
68365 2012-04-25  Eric Blake  <eblake@redhat.com>
68367         bootstrap: only force latest Makefile.in.in for gettext module
68368         * build-aux/bootstrap (with_gettext): Only install latest
68369         Makefile.in.in for projects requesting bleeding edge gettext.
68371 2012-04-22  Bruno Haible  <bruno@clisp.org>
68373         doc: Mention reason for replacement on glibc/Linux systems.
68374         * doc/posix-functions/dprintf.texi: Mention the problem with special
68375         'long double' values.
68376         * doc/posix-functions/fprintf.texi: Likewise.
68377         * doc/posix-functions/printf.texi: Likewise.
68378         * doc/posix-functions/snprintf.texi: Likewise.
68379         * doc/posix-functions/sprintf.texi: Likewise.
68380         * doc/posix-functions/vdprintf.texi: Likewise.
68381         * doc/posix-functions/vfprintf.texi: Likewise.
68382         * doc/posix-functions/vprintf.texi: Likewise.
68383         * doc/posix-functions/vsnprintf.texi: Likewise.
68384         * doc/posix-functions/vsprintf.texi: Likewise.
68385         * doc/posix-functions/fcntl.texi: Add glibc/Linux to the list of
68386         platforms with F_DUPFD_CLOEXEC problems.
68387         * doc/posix-functions/glob.texi: Mention which platforms are affected
68388         by the problem with symbolic links.
68389         * doc/posix-functions/linkat.texi: Mention the problem with
68390         AT_SYMLINK_FOLLOW on Linux.
68392 2012-04-22  Bruno Haible  <bruno@clisp.org>
68394         pwrite: Don't replace on all platforms.
68395         * m4/pwrite.m4 (gl_FUNC_PWRITE): Fix syntax error in test program.
68397 2012-04-22  Bruno Haible  <bruno@clisp.org>
68399         rint* tests: Avoid gcc warnings.
68400         * tests/test-rint.c (INFINITY, NAN): Undefine before redefining.
68401         * tests/test-rintf.c (INFINITY, NAN): Likewise.
68402         * tests/test-rintl.c (INFINITY, NAN): Likewise.
68404 2012-04-21  Bruno Haible  <bruno@clisp.org>
68406         users.txt: Update.
68407         * users.txt: Add freedink, wdiff. Update URLs for projects that have
68408         switched from CVS to git, bzr, or svn.
68410 2012-04-21  Bruno Haible  <bruno@clisp.org>
68412         Large File Support for native Windows platforms.
68414         * m4/largefile.m4 (gl_LARGEFILE): New macro.
68415         * modules/largefile (configure.ac): Require gl_LARGEFILE.
68417         * lib/sys_types.in.h (off_t) [WINDOWS_64_BIT_OFF_T]: Define to a 64-bit
68418         type.
68419         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Set WINDOWS_64_BIT_OFF_T.
68420         * modules/sys_types (Makefile.am): Substitute WINDOWS_64_BIT_OFF_T.
68421         * doc/posix-headers/sys_types.texi: Mention the effect of the
68422         'largefile' module.
68424         * lib/fcntl.in.h: Add comments about off_t.
68425         * modules/fcntl-h (Depends-on): Add sys_types.
68427         * lib/unistd.in.h [WINDOWS_64_BIT_OFF_T]: Include <sys/types.h>.
68428         (ftruncate): Replace it if REPLACE_FTRUNCATE is 1.
68429         * m4/unistd_h.m4 (gl_UNISTD_H): Require gl_SYS_TYPES_H.
68430         (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_FTRUNCATE.
68431         * modules/unistd (Depends-on): Add sys_types.
68432         (Makefile.am): Substitute WINDOWS_64_BIT_OFF_T, REPLACE_FTRUNCATE.
68434         * lib/lseek.c (rpl_lseek) [_GL_WINDOWS_64_BIT_OFF_T]: Use _lseeki64
68435         instead of lseek.
68436         * m4/lseek.m4 (gl_FUNC_LSEEK): Require gl_SYS_TYPES_H. Set
68437         REPLACE_LSEEK if WINDOWS_64_BIT_OFF_T is 1.
68438         * modules/lseek (Depends-on): Add sys_types.
68440         * lib/ftruncate.c: Put under GPLv3+. Include <windows.h>,
68441         msvc-nothrow.h.
68442         (SetFileSize): New function.
68443         (ftruncate) [_GL_WINDOWS_64_BIT_OFF_T]: New implementation.
68444         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Set REPLACE_FTRUNCATE on Windows
68445         if Large File Support is requested.
68446         * modules/ftruncate (configure.ac): Consider REPLACE_FTRUNCATE.
68447         (Depends-on): Add sys_types, msvc-nothrow. Update conditions.
68449         * lib/stdio.in.h: Add comments about off_t.
68450         * modules/stdio (Depends-on): Add sys_types.
68452         * lib/ftello.c [_GL_WINDOWS_64_BIT_OFF_T]: Use _ftelli64 or ftello64
68453         instead of ftello.
68454         * m4/ftello.m4 (gl_FUNC_FTELLO): Require gl_SYS_TYPES_H. Set
68455         REPLACE_FTELLO if WINDOWS_64_BIT_OFF_T is 1.
68456         (gl_PREREQ_FTELLO): New macro.
68457         * modules/ftello (Depends-on): Add sys_types.
68458         (configure.ac): Incoke gl_PREREQ_FTELLO.
68460         * lib/fseeko.c [_GL_WINDOWS_64_BIT_OFF_T]: Use _fseeki64 or fseeko64
68461         instead of fseeko.
68462         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Require gl_SYS_TYPES_H. Set
68463         REPLACE_FSEEKO if WINDOWS_64_BIT_OFF_T is 1.
68464         (gl_PREREQ_FSEEKO): New macro.
68465         * modules/fseeko (Depends-on): Add sys_types.
68466         (configure.ac): Invoke gl_PREREQ_FSEEKO.
68468         * lib/sys_stat.in.h: Add comments about off_t.
68469         (stat, fstat) [WINDOWS_64_BIT_ST_SIZE]: Define to variants that use a
68470         64-bit integer for st_size in 'struct stat'.
68471         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Set WINDOWS_64_BIT_ST_SIZE.
68472         Define _GL_WINDOWS_64_BIT_ST_SIZE.
68473         * modules/sys_stat (Depends-on): Add sys_types.
68474         (Makefile.am): Substitute WINDOWS_64_BIT_ST_SIZE.
68476         * lib/stat.c (stat) [_GL_WINDOWS_64_BIT_ST_SIZE]: Define to _stati64
68477         instead of stat or _stat.
68479         * lib/fstat.c [_GL_WINDOWS_64_BIT_ST_SIZE]: Use _fstati64 and
68480         'struct _stati64' instead of fstat and 'struct stat'.
68481         * m4/fstat.m4 (gl_FUNC_FSTAT): Require gl_HEADER_SYS_STAT_H. Set
68482         REPLACE_FSTAT if WINDOWS_64_BIT_ST_SIZE is 1.
68484         Reported by Ray Satiro <raysatiro@yahoo.com>.
68486 2012-04-19  Eric Blake  <eblake@redhat.com>
68488         bootstrap: accommodate older libtool
68489         * build-aux/bootstrap (use_libtool): Cater to libtool 1.5.22.
68490         Reported by Daniel P. Berrange.
68492 2012-04-19  Jim Meyering  <meyering@redhat.com>
68494         announce-gen: avoid failure due to lack of Digest::SHA1
68495         Even with the preferred Digest::SHA available, this script
68496         would fail when the backup module, Digest::SHA1, was not installed.
68497         * build-aux/announce-gen: Quote the conditional use of "use".
68498         Reported by Reuben Thomas in:
68499         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30444
68501         bootstrap: don't let a user's CDPATH setting affect this script
68502         When CDPATH is set, cd will sometimes generate output.
68503         When "cd" is run in a subshell whose output matters, that
68504         surprising-to-some output can cause malfunction.
68505         Unsetting CDPATH turns off this shell "feature."
68506         * build-aux/bootstrap (CDPATH): Unset.
68507         Reported by Reuben Thomas in:
68508         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30435
68509         and inspired by his patch here:
68510         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/30440
68512 2012-04-16  Akim Demaille  <akim@lrde.epita.fr>
68513         and Jim Meyering  <meyering@redhat.com>
68515         maint.mk: catch "see @xref{}" and similar
68516         * top/maint.mk (prohibit_undesirable_word_seq_RE_): Also
68517         prohibit "See also @xref{", "Also see @pxref{", and similar.
68519 2012-04-16  Jim Meyering  <meyering@redhat.com>
68521         bootstrap: really use gnulib's po/Makefile.in.in
68522         * build-aux/bootstrap: Correct the source file name in previous change.
68523         Reported by Akim Demaille.
68525         configmake: correct minor inconsistency in Makefile rule
68526         * modules/configmake (Makefile.am): All other rules like this one
68527         run the final "mv -f ..." in the same backslash-continued command
68528         as the one that does everything else.  This one put the mv -f ...
68529         command on a separate, non-backslash-continued line.
68530         Make it like the others.
68532         bootstrap: use gnulib's po/Makefile.in.in, not the one from gettext
68533         * build-aux/bootstrap: Use gnulib's po/Makefile.in.in, not
68534         the one from gettext.  Reported by Akim Demaille.
68536 2012-04-16  Joel E. Denny  <joeldenny@joeldenny.org>
68538         Fix recursion of install-* into po directories.
68539         Bison's install-pdf bug reported by Hans Aberg at
68540         <http://lists.gnu.org/r/bug-bison/2011-05/msg00008.html>.
68541         * build-aux/po/Makefile.in.in (install-dvi, install-html)
68542         (install-info, install-pdf, install-ps): New targets.
68544 2012-04-16  Jim Meyering  <meyering@redhat.com>
68546         maint: avoid spurious "make sc_maint" failure
68547         * cfg.mk (exclude_file_name_regexp--sc_trailing_blank): Also
68548         exempt all *.class file names, for lib/javaversion.class.
68550 2012-04-15  Bruno Haible  <bruno@clisp.org>
68552         lseek: Make configure test independent of environment.
68553         * m4/lseek.m4 (gl_FUNC_LSEEK): Require AC_CANONICAL_HOST. On native
68554         Windows, we know that lseek() on pipes is broken; skip the runtime
68555         test.
68557 2012-04-14  Bruno Haible  <bruno@clisp.org>
68559         stat: Bypass buggy override in mingw64.
68560         * m4/stat.m4 (gl_FUNC_STAT): Update comments.
68561         * lib/stat.c (stat) [mingw64]: Define to _stat.
68562         * doc/posix-functions/stat.texi: Mention mingw64 bug.
68564 2012-04-14  Bruno Haible  <bruno@clisp.org>
68566         pathmax: Fix compilation error on MSVC 9.
68567         * modules/pathmax (Depends-on): Add unistd.
68569 2012-04-12  Paul Eggert  <eggert@cs.ucla.edu>
68571         README: document pointer comparison assumption
68572         * README (Portability guidelines): Document assumption about
68573         pointer comparisons, in response to a recent bug-gnulib comment by
68574         Jeffrey Kegler.
68576 2012-04-12  Bruno Haible  <bruno@clisp.org>
68578         Tests for module 'getrusage'.
68579         * modules/getrusage-tests: New file.
68580         * tests/test-getrusage.c: New file.
68582         New module 'getrusage'.
68583         * lib/sys_resource.in.h: Include arg-nonnull.h, c++defs.h,
68584         warn-on-use.h.
68585         (getrusage): New declaration.
68586         * lib/getrusage.c: New file.
68587         * m4/getrusage.m4: New file.
68588         * m4/sys_resource_h.m4 (gl_HEADER_SYS_RESOURCE): Test whether getrusage
68589         is declared.
68590         (gl_SYS_RESOURCE_H_DEFAULTS): Initialize GNULIB_GETRUSAGE,
68591         HAVE_GETRUSAGE.
68592         * modules/sys_resource (Depends-on): Add snippet/arg-nonnull,
68593         snippet/c++defs, snippet/warn-on-use.
68594         (Makefile.am): Update generation of sys/resource.h. Substitute
68595         GNULIB_GETRUSAGE, HAVE_GETRUSAGE.
68596         * modules/getrusage: New file.
68597         * doc/posix-functions/getrusage.texi: Mention the new module.
68599 2012-04-12  Bruno Haible  <bruno@clisp.org>
68601         Tests for module 'sys_resource'.
68602         * modules/sys_resource-tests: New file.
68603         * tests/test-sys_resource.c: New file.
68605         New module 'sys_resource'.
68606         * lib/sys_resource.in.h: New file.
68607         * m4/sys_resource_h.m4: New file.
68608         * modules/sys_resource: New file.
68609         * doc/posix-headers/sys_resource.texi: Mention the new module.
68611 2012-04-12  LRN  <lrn1986@gmail.com>  (tiny change)
68613         ioctl: Fix compilation error on mingw.
68614         * lib/ioctl.c: Include <windows.h>.
68615         Also reported by Ray Satiro <raysatiro@yahoo.com>.
68617 2012-04-04  Jim Meyering  <meyering@redhat.com>
68619         regex: correct #pragma guard expression
68620         * lib/regex.c: -Wsuggest-attribute=pure was introduced in gcc-4.6,
68621         not 4.3.  Correct its cpp guard expression.
68623 2012-04-04  Paul Eggert  <eggert@cs.ucla.edu>
68625         regex: remove unnecessary type punning
68626         Problem reported by Vladimir Serbinenko in
68627         <http://lists.gnu.org/r/bug-gnulib/2012-04/msg00006.html>.
68628         * lib/regex.h (struct re_pattern_buffer): Change the type of
68629         __REPB_PREFIX(buffer) from unsigned char * to struct re_dfa_t *.
68630         Fix comment to match code.
68631         * lib/regcomp.c (re_compile_fastmap, re_compile_fastmap_iter, regfree)
68632         (re_compile_internal, free_workarea_compile, analyze, lower_subexp)
68633         (parse, parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
68634         * lib/regexec.c (regexec, re_search_stub, re_search_internal)
68635         (set_regs):
68636         Omit no-longer-necessary casts.
68638 2012-04-03  Bruno Haible  <bruno@clisp.org>
68640         Tests for module 'ilogbl'.
68641         * modules/ilogbl-tests: New file.
68642         * tests/test-ilogbl.c: New file.
68644         New module 'ilogbl'.
68645         * lib/math.in.h (ilogbl): New declaration.
68646         * lib/ilogbl.c: New file.
68647         * m4/ilogbl.m4: New file.
68648         * m4/math_h.m4 (gl_MATH_H): Test whether ilogbl is declared.
68649         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ILOGBL, HAVE_ILOGBL.
68650         * modules/math (Makefile.am): Substitute GNULIB_ILOGBL, HAVE_ILOGBL.
68651         Split sed invocation, to avoid the limit of 100 substitutions of
68652         HP-UX 'sed'.
68653         * modules/ilogbl: New file.
68654         * tests/test-math-c++.cc: Check the declaration of ilogbl.
68655         * doc/posix-functions/ilogbl.texi: Mention the new module.
68657 2012-04-03  Bruno Haible  <bruno@clisp.org>
68659         Tests for module 'ilogbf'.
68660         * modules/ilogbf-tests: New file.
68661         * tests/test-ilogbf.c: New file.
68663         New module 'ilogbf'.
68664         * lib/math.in.h (ilogbf): New declaration.
68665         * lib/ilogbf.c: New file.
68666         * m4/ilogbf.m4: New file.
68667         * m4/math_h.m4 (gl_MATH_H): Test whether ilogbf is declared.
68668         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ILOGBF, HAVE_ILOGBF,
68669         REPLACE_ILOGBF.
68670         * modules/math (Makefile.am): Substitute GNULIB_ILOGBF, HAVE_ILOGBF,
68671         REPLACE_ILOGBF.
68672         * modules/ilogbf: New file.
68673         * tests/test-math-c++.cc: Check the declaration of ilogbf.
68674         * doc/posix-functions/ilogbf.texi: Mention the new module.
68676 2012-04-03  Bruno Haible  <bruno@clisp.org>
68678         Tests for module 'ilogb'.
68679         * modules/ilogb-tests: New file.
68680         * tests/test-ilogb.c: New file.
68681         * tests/test-ilogb.h: New file, based on tests/test-logb.h and
68682         tests/test-logb-ieee.h.
68684         New module 'ilogb'.
68685         * lib/math.in.h (ilogb): New declaration.
68686         * lib/ilogb.c: New file.
68687         * m4/ilogb.m4: New file.
68688         * m4/math_h.m4 (gl_MATH_H): Test whether ilogb is declared.
68689         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ILOGB, HAVE_ILOGB,
68690         REPLACE_ILOGB.
68691         * modules/math (Makefile.am): Substitute GNULIB_ILOGB, HAVE_ILOGB,
68692         REPLACE_ILOGB.
68693         * modules/ilogb: New file.
68694         * tests/test-math-c++.cc: Check the declaration of ilogb.
68695         * doc/posix-functions/ilogb.texi: Mention the new module.
68697 2012-04-03  Bruno Haible  <bruno@clisp.org>
68699         math: Provide FP_ILOGB0 and FP_ILOGBNAN.
68700         * lib/math.in.h (FP_ILOGB0, FP_ILOGBNAN): Define fallback.
68701         * tests/test-math.c: Check that FP_ILOGB0, FP_ILOGBNAN are defined.
68702         (main): Check their values.
68703         * doc/posix-headers/math.texi: Mention the FP_ILOGB0, FP_ILOGBNAN
68704         problem.
68706 2012-04-03  Bruno Haible  <bruno@clisp.org>
68708         Tests for module 'logbl-ieee'.
68709         * modules/logbl-ieee-tests: New file.
68710         * tests/test-logbl-ieee.c: New file.
68712         New module 'logbl-ieee'.
68713         * modules/logbl-ieee: New file.
68715         Tests for module 'logb-ieee'.
68716         * modules/logb-ieee-tests: New file.
68717         * tests/test-logb-ieee.c: New file.
68719         New module 'logb-ieee'.
68720         * modules/logb-ieee: New file.
68722         Tests for module 'logbf-ieee'.
68723         * modules/logbf-ieee-tests: New file.
68724         * tests/test-logbf-ieee.c: New file.
68725         * tests/test-logb-ieee.h: New file.
68727         New module 'logbf-ieee'.
68728         * modules/logbf-ieee: New file.
68730 2012-04-03  Bruno Haible  <bruno@clisp.org>
68732         Tests for module 'logbl'.
68733         * modules/logbl-tests: New file.
68734         * tests/test-logbl.c: New file.
68736         New module 'logbl'.
68737         * lib/math.in.h (logbl): New declaration.
68738         * lib/logbl.c: New file.
68739         * m4/logbl.m4: New file.
68740         * m4/math_h.m4 (gl_MATH_H): Test whether logbl is declared.
68741         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGBL, HAVE_LOGBL,
68742         REPLACE_LOGBL.
68743         * modules/math (Makefile.am): Substitute GNULIB_LOGBL, HAVE_LOGBL,
68744         REPLACE_LOGBL.
68745         * modules/logbl: New file.
68746         * tests/test-math-c++.cc: Check the declaration of logbl.
68747         * doc/posix-functions/logbl.texi: Mention the new module.
68749 2012-04-02  Bruno Haible  <bruno@clisp.org>
68751         Tests for module 'logbf'.
68752         * modules/logbf-tests: New file.
68753         * tests/test-logbf.c: New file.
68755         New module 'logbf'.
68756         * lib/math.in.h (logbf): New declaration.
68757         * lib/logbf.c: New file.
68758         * m4/logbf.m4: New file.
68759         * m4/math_h.m4 (gl_MATH_H): Test whether logbf is declared.
68760         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGBF, HAVE_LOGBF,
68761         REPLACE_LOGBF.
68762         * modules/math (Makefile.am): Substitute GNULIB_LOGBF, HAVE_LOGBF,
68763         REPLACE_LOGBF.
68764         * modules/logbf: New file.
68765         * tests/test-math-c++.cc: Check the declaration of logbf.
68766         * doc/posix-functions/logbf.texi: Mention the new module.
68768 2012-04-02  Bruno Haible  <bruno@clisp.org>
68770         logb tests: More tests.
68771         * tests/test-logb.h: New file, based on tests/test-logb.c and
68772         tests/test-frexp.h.
68773         * tests/test-logb.c: Include minus-zero.h, test-logb.h.
68774         (main): Just invoke test_function.
68775         * modules/logb-tests (Files): Add tests/test-logb.h,
68776         tests/minus-zero.h, tests/randomd.c.
68777         (Makefile.am): Add randomd.c to test_logb_SOURCES.
68779         logb: Provide replacement and workarounds.
68780         * lib/math.in.h (logb): Ensure declaration. Replace if REPLACE_LOGB
68781         is 1.
68782         * lib/logb.c: New file.
68783         * m4/logb.m4 (gl_FUNC_LOGB_WORKS): New macro.
68784         (gl_FUNC_LOGB): Invoke it. Set HAVE_LOGB, REPLACE_LOGB.
68785         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOGB.
68786         * modules/math (Makefile.am): Substitute REPLACE_LOGB.
68787         * modules/logb (Files): Add lib/logb.c.
68788         (Depends-on): Add isfinite, frexp, isnand.
68789         (configure.ac): Compile the replacement code logb.c if needed.
68790         * tests/test-math-c++.cc: Check the declaration of logb.
68791         * doc/posix-functions/logb.texi: Mention the replacement and the bug
68792         with subnormal numbers.
68794 2012-04-02  Bruno Haible  <bruno@clisp.org>
68796         log10* tests: Speed up.
68797         * tests/test-log10.h (test_function): Reduce amount of random numbers
68798         to test.
68800 2012-04-01  Bruno Haible  <bruno@clisp.org>
68802         logf-ieee: Fix test whether logf works.
68803         * m4/logf.m4 (gl_FUNC_LOGF): Fix typo in test program.
68805 2012-04-01  Bruno Haible  <bruno@clisp.org>
68807         log10l: Work around log10l-ieee test failure on IRIX 6.5.
68808         * lib/log10l.c: Include <float.h>
68809         (log10l): On IRIX, normalize the +Infinity value.
68810         * modules/log10l (Depends-on): Add 'float'.
68811         * doc/posix-functions/log10l.texi: Mention the IRIX problem with
68812         +Infinity.
68814         log10f-ieee: Work around test failure on NetBSD 5.1.
68815         * m4/log10f-ieee.m4: New file.
68816         * m4/log10f.m4 (gl_FUNC_LOG10F): If gl_FUNC_LOG10F_IEEE is present,
68817         test whether log10f works with a negative argument. Replace it if not.
68818         * lib/log10f.c (log10f): For negative arguments, return NaN.
68819         * modules/log10f-ieee (Files): Add m4/log10f-ieee.m4.
68820         (configure.ac): Invoke gl_FUNC_LOG10F_IEEE.
68821         * doc/posix-functions/log10f.texi: Mention the log10f-ieee module.
68823         log10f-ieee: Work around test failure on Solaris 9.
68824         * modules/log10f-ieee (Depends-on): Add log10-ieee.
68825         (configure.ac): Require gl_FUNC_LOG10F.
68827         log10-ieee: Work around test failure on NetBSD 5.1 and Solaris 11.
68828         * m4/log10-ieee.m4: New file.
68829         * m4/log10.m4 (gl_FUNC_LOG10): If gl_FUNC_LOG10_IEEE is present, test
68830         whether log10 works with a negative argument. Replace it if not.
68831         * lib/log10.c (log10): For negative arguments, return NaN.
68832         * modules/log10-ieee (Files): Add m4/log10-ieee.m4.
68833         (configure.ac): Invoke gl_FUNC_LOG10_IEEE.
68834         * doc/posix-functions/log10.texi: Mention the log10-ieee module.
68836         Tests for module 'log10l-ieee'.
68837         * modules/log10l-ieee-tests: New file.
68838         * tests/test-log10l-ieee.c: New file.
68840         New module 'log10l-ieee'.
68841         * modules/log10l-ieee: New file.
68843         Tests for module 'log10-ieee'.
68844         * modules/log10-ieee-tests: New file.
68845         * tests/test-log10-ieee.c: New file.
68847         New module 'log10-ieee'.
68848         * modules/log10-ieee: New file.
68850         Tests for module 'log10f-ieee'.
68851         * modules/log10f-ieee-tests: New file.
68852         * tests/test-log10f-ieee.c: New file.
68853         * tests/test-log10-ieee.h: New file.
68855         New module 'log10f-ieee'.
68856         * modules/log10f-ieee: New file.
68858 2012-04-01  Bruno Haible  <bruno@clisp.org>
68860         log10l: Work around AIX 5.1, IRIX 6.5, OSF/1 5.1 bug.
68861         * lib/math.in.h (log10l): Override if REPLACE_LOG10L is 1.
68862         * lib/log10l.c (log10l): If log10l exists, use it and provide just the
68863         workaround.
68864         * m4/log10l.m4 (gl_FUNC_LOG10L_WORKS): New macro.
68865         (gl_FUNC_LOG10L): Invoke it. Set REPLACE_LOG10L.
68866         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG10L.
68867         * modules/math (Makefile.am): Substitute REPLACE_LOG10L.
68868         * modules/log10l (configure.ac): Consider REPLACE_LOG10L.
68869         (Depends-on): Update conditions.
68870         * doc/posix-functions/log10l.texi: Mention the MSVC9, AIX 5.1,
68871         IRIX 6.5, OSF/1 5.1 problems.
68873 2012-04-01  Bruno Haible  <bruno@clisp.org>
68875         log10f: Work around OSF/1 5.1 bug.
68876         * lib/math.in.h (log10f): Override if REPLACE_LOG10F is 1.
68877         * lib/log10f.c (log10f): If logf exists, use it and provide just the
68878         workaround.
68879         * m4/log10f.m4 (gl_FUNC_LOG10F_WORKS): New macro.
68880         (gl_FUNC_LOG10F): Invoke it. Set REPLACE_LOG10F.
68881         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG10F.
68882         * modules/math (Makefile.am): Substitute REPLACE_LOG10F.
68883         * modules/log10f (configure.ac): Consider REPLACE_LOG10F.
68884         (Depends-on): Update conditions.
68885         * doc/posix-functions/log10f.texi: Mention the OSF/1 5.1 problem.
68887 2012-04-01  Bruno Haible  <bruno@clisp.org>
68889         log10: Work around OSF/1 5.1 bug.
68890         * lib/math.in.h (log10): New declaration.
68891         * lib/log10.c: New file.
68892         * m4/log10.m4 (gl_FUNC_LOG10_WORKS): New macro.
68893         (gl_FUNC_LOG10): Invoke it. Set REPLACE_LOG10.
68894         * m4/math_h.m4 (gl_MATH_H): Test whether log10 is declared.
68895         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG10, REPLACE_LOG10.
68896         * modules/math (Makefile.am): Substitute GNULIB_LOG10, REPLACE_LOG10.
68897         * modules/log10 (Files): Add lib/log10.c.
68898         (Depends-on): Add math.
68899         (configure.ac): If REPLACE_LOG10 is 1, compile an override.
68900         * tests/test-math-c++.cc: Check the declaration of log10.
68901         * doc/posix-functions/log10.texi: Mention the OSF/1 5.1 problem.
68903 2012-03-31  Bruno Haible  <bruno@clisp.org>
68905         log10l tests: More tests.
68906         * modules/log10l-tests (Files): Add tests/test-log10l.h,
68907         tests/minus-zero.h, tests/randoml.c.
68908         (Makefile.am): Add randoml.c to test_log10l_SOURCES.
68909         * tests/test-log10l.c: Include <float.h>, minus-zero.h, test-log10l.h.
68910         (main): Invoke test_function.
68912         log10f tests: More tests.
68913         * modules/log10f-tests (Files): Add tests/test-log10.h,
68914         tests/minus-zero.h, tests/randomf.c.
68915         (Makefile.am): Add randomf.c to test_log10f_SOURCES.
68916         * tests/test-log10f.c: Include <float.h>, minus-zero.h, test-log10.h.
68917         (main): Invoke test_function.
68919         log10 tests: More tests.
68920         * tests/test-log10.h: New file.
68921         * modules/log10-tests (Files): Add tests/test-log10.h,
68922         tests/minus-zero.h, tests/randomd.c.
68923         (Makefile.am): Add randomd.c to test_log10_SOURCES.
68924         * tests/test-log10.c: Include <float.h>, minus-zero.h, test-log10.h.
68925         (main): Invoke test_function.
68927 2012-03-31  Simon Josefsson  <simon@josefsson.org>
68929         fflush: Fix syntax error.
68930         * lib/fflush.c: Include unused-parameter.h, needed for
68931         _GL_UNUSED_PARAMETER.
68932         * modules/fflush (Depends-on): Add snippet/unused-parameter.
68934 2012-03-30  Paul Eggert  <eggert@cs.ucla.edu>
68936         regex: pacify GCC when compiling GRUB
68937         * lib/regcomp.c (init_dfa): Make a pointer 'const', to avoid
68938         a diagnostic.  Reported by Vladimir Serbinenko in
68939         <http://lists.gnu.org/r/bug-gnulib/2012-03/msg00163.html>.
68941 2012-03-29  Eric Blake  <eblake@redhat.com>
68943         stdio: don't assume gets any more
68944         * m4/stdio_h.m4 (gl_STDIO_H, gl_STDIO_H_DEFAULTS): Drop gets
68945         support.
68946         * modules/stdio (Makefile.am): Likewise.
68947         * lib/stdio-read.c (gets): Likewise.
68948         * tests/test-stdio-c++.cc: Likewise.
68949         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Fix comment.
68950         * lib/stdio.in.h (gets): Make warning occur in more places.
68951         * doc/posix-functions/gets.texi (gets): Update documentation.
68952         Reported by Christer Solskogen.
68954         maint.mk: fix syntax checks without exclusions
68955         * top/maint.mk (_sc_search_regexp): Allow for empty variable.
68956         Reported by Daniel P. Berrange.
68958         strerror_r: avoid compiler warning
68959         * lib/strerror_r.c (strerror_r): Hoist extern declaration to top
68960         level.
68962         fflush: avoid compiler warning
68963         * lib/fflush.c (update_fpos_cache): Mark variables that are
68964         potentially unused.
68966 2012-03-25  Bruno Haible  <bruno@clisp.org>
68968         Tests for module 'localeconv'.
68969         * modules/localeconv-tests: New file.
68970         * tests/test-localeconv.c: New file.
68972         New module 'localeconv'.
68973         * lib/locale.in.h (localeconv): New declaration.
68974         * lib/localeconv.c: New file.
68975         * m4/localeconv.m4: New file.
68976         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize GNULIB_LOCALECONV,
68977         REPLACE_LOCALECONV.
68978         * modules/locale (Makefile.am): Substitute GNULIB_LOCALECONV,
68979         REPLACE_LOCALECONV.
68980         * modules/localeconv: New file.
68981         * modules/nl_langinfo (Depends-on): Add localeconv.
68982         * modules/human (Depends-on): Likewise.
68983         * doc/posix-functions/localeconv.texi: Mention the new module.
68985 2012-03-25  Bruno Haible  <bruno@clisp.org>
68987         locale: Provide a complete 'struct lconv'.
68988         * m4/locale_h.m4 (gl_LOCALE_H): Set REPLACE_STRUCT_LCONV to 1 if
68989         'struct lconv' does not contain int_p_cs_precedes.
68990         * tests/test-locale.c (main): Check that 'struct lconv' is complete.
68991         * doc/posix-headers/locale.texi: Update.
68993         locale: Provide a complete 'struct lconv' on Solaris 10, 11.
68994         * m4/locale_h.m4 (gl_LOCALE_H): On Solaris, define _LCONV_C99.
68995         * doc/posix-headers/locale.texi: Update.
68997         locale: Provide a working 'struct lconv'.
68998         * lib/locale.in.h (lconv): Override if REPLACE_STRUCT_LCONV is 1.
68999         * m4/locale_h.m4 (gl_LOCALE_H): Set REPLACE_STRUCT_LCONV to 1 if
69000         'struct lconv' does not even contain decimal_point.
69001         (gl_LOCALE_H_DEFAULTS): Initialize REPLACE_STRUCT_LCONV.
69002         * modules/locale (Makefile.am): Substitute REPLACE_STRUCT_LCONV.
69003         * tests/test-locale.c (main): Check that 'struct lconv' is complete.
69004         * doc/posix-headers/locale.texi: Mention the problems with
69005         'struct lconv'.
69006         Reported by Gianluigi Tiesi <sherpya@netfarm.it>.
69008 2012-03-24  Bruno Haible  <bruno@clisp.org>
69010         Enable common subexpression optimization in GCC.
69011         * lib/unitypes.in.h (_UC_ATTRIBUTE_CONST, _UC_ATTRIBUTE_PURE): New
69012         macros.
69013         * lib/unicase.in.h (uc_toupper, uc_tolower, uc_totitle): Declare with
69014         GCC attribute 'const'.
69015         (uc_locale_language): Declare with GCC attribute 'pure'.
69016         * lib/unicase/caseprop.h (uc_is_cased, uc_is_case_ignorable): Declare
69017         with GCC attribute 'const'.
69018         * lib/unictype.in.h (uc_is_general_category_withtable,
69019         uc_combining_class, uc_combining_class_name,
69020         uc_combining_class_long_name, uc_bidi_class_name,
69021         uc_bidi_category_name, uc_bidi_class_long_name, uc_bidi_class,
69022         uc_bidi_category, uc_is_bidi_class, uc_is_bidi_category,
69023         uc_decimal_value, uc_digit_value, uc_numeric_value,
69024         uc_joining_type_name, uc_joining_type_long_name, uc_joining_type,
69025         uc_joining_group_name, uc_joining_group, uc_is_property_*, uc_script,
69026         uc_block, uc_is_c_whitespace, uc_is_java_whitespace,
69027         uc_c_ident_category, uc_java_ident_category, uc_is_alnum, uc_is_alpha,
69028         uc_is_cntrl, uc_is_digit, uc_is_graph, uc_is_lower, uc_is_print,
69029         uc_is_punct, uc_is_space, uc_is_upper, uc_is_xdigit, uc_is_blank):
69030         Declare with GCC attribute 'const'.
69031         (uc_general_category_name, uc_general_category_long_name,
69032         uc_general_category_byname, uc_general_category,
69033         uc_is_general_category, uc_combining_class_byname,
69034         uc_bidi_class_byname, uc_bidi_category_byname, uc_joining_type_byname,
69035         uc_joining_group_byname, uc_script_byname, uc_is_script, uc_is_block):
69036         Declare with GCC attribute 'pure'.
69037         * lib/unigbrk.in.h (uc_graphemeclusterbreak_property,
69038         uc_is_grapheme_break, u8_grapheme_next, u16_grapheme_next,
69039         u32_grapheme_next, u8_grapheme_prev, u16_grapheme_prev,
69040         u32_grapheme_prev, lib/uniname.in.h (unicode_name_character): Declare
69041         with GCC attribute 'pure'.
69042         * lib/uninorm.in.h (uc_composition): Declare with GCC attribute
69043         'const'.
69044         (uninorm_decomposing_form): Declare with GCC attribute 'pure'.
69045         * lib/unistr.in.h (): Declare with GCC attribute 'const'.
69046         (u8_check, u16_check, u32_check, u8_mblen, u16_mblen, u32_mblen,
69047         u8_cmp, u16_cmp, u32_cmp, u8_cmp2, u16_cmp2, u32_cmp2, u8_chr, u16_chr,
69048         u32_chr, u8_mbsnlen, u16_mbsnlen, u32_mbsnlen, u8_strmblen,
69049         u16_strmblen, u32_strmblen, u8_strlen, u16_strlen, u32_strlen,
69050         u8_strnlen, u16_strnlen, u32_strnlen, u8_strcmp_gnu, u8_strcmp,
69051         u16_strcmp, u32_strcmp, u8_strncmp, u16_strncmp, u32_strncmp,
69052         u8_strchr, u16_strchr, u32_strchr, u8_strrchr, u16_strrchr,
69053         u32_strrchr, u8_strcspn, u16_strcspn, u32_strcspn, u8_strspn,
69054         u16_strspn, u32_strspn, u8_strpbrk, u16_strpbrk, u32_strpbrk,
69055         u8_strstr, u16_strstr, u32_strstr, u8_startswith, u16_startswith,
69056         u32_startswith, u8_endswith, u16_endswith, u32_endswith): Declare with
69057         GCC attribute 'pure'.
69058         * lib/uniwbrk.in.h (uc_wordbreak_property): Declare with GCC attribute
69059         'const'.
69060         * lib/uniwidth.in.h (uc_width): Simplify declaration.
69061         (u8_width, u16_width, u32_width, u8_strwidth, u16_strwidth,
69062         u32_strwidth): Declare with GCC attribute 'pure'.
69064         Enable common subexpression optimization in GCC.
69065         * lib/dirent.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
69066         (alphasort): Declare with GCC attribute 'pure'.
69067         * lib/stdlib.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
69068         (atoll): Declare with GCC attribute 'pure'.
69069         * lib/string.in.h (mbslen, mbsnlen, mbschr, mbsrchr, mbsstr,
69070         mbscasecmp, mbsncasecmp, mbspcasecmp, mbscasestr, mbscspn, mbspbrk,
69071         mbsspn, strverscmp): Declare with GCC attribute 'pure'.
69072         * lib/wchar.in.h (_GL_ATTRIBUTE_PURE): Define, like in string.in.h.
69073         (btowc, wctob, wcwidth, wmemchr, wmemcmp, wcslen, wcsnlen, wcscmp,
69074         wcsncmp, wcscasecmp, wcsncasecmp, wcschr, wcsrchr, wcscspn, wcsspn,
69075         wcspbrk, wcsstr, wcswidth): Declare with GCC attribute 'pure'.
69077 2012-03-24  Bruno Haible  <bruno@clisp.org>
69079         gnulib-tool: Avoid unintended error output from 'cmp'.
69080         * gnulib-tool (func_add_file, func_update_file, func_import): Use
69081         "cmp -s", not "cmp > /dev/null".
69083 2012-03-23  Stefano Lattarini  <stefano.lattarini@gmail.com>
69085         gnulib-tool: fix imprecise comments w.r.t. an automake bug
69087         It's not just Automake versions < 1.9b that creates an empty
69088         pkgdatadir at installation time if pkgdata_DATA is specified
69089         to empty; modern automake versions do this as well, at least
69090         until automake 1.11.4 (not yet released at the moment of writing,
69091         but soon to appear).  That behaviour was generally considered a
69092         feature rather than a bug, at least until this discussion:
69093         <http://lists.gnu.org/r/automake/2012-03/msg00014.html>
69095         See also automake bugs #10997 and #11030.
69097         * gnulib-tool (func_emit_lib_Makefile_am): Adjust comments.  Add
69098         reference to relevant automake bug numbers.
69099         (func_emit_tests_Makefile_am): Likewise.
69101 2012-03-20  Reuben Thomas  <rrt@sc3d.org>
69103         announce-gen: use Digest::SHA when possible
69104         * build-aux/announce-gen: Use Digest::SHA when possible, falling
69105         back to Digest::SHA1 if necessary.
69107 2012-03-20  Jim Meyering  <meyering@redhat.com>
69109         tests: avoid gcc warnings about argv vs. const initializers
69110         * tests/test-posix_spawn1.c (main): Cast to "(char *)" to avoid two
69111         warnings about discarding 'const' qualifier from pointer target type.
69112         * tests/test-posix_spawn2.c (main): Likewise.
69114 2012-03-20  Reuben Thomas  <rrt@sc3d.org>
69116         README-release: simplify slightly
69117         * top/README-release: Run "git checkout master" only once.
69119 2012-03-15  Mark Wielaard  <mark@klomp.org>
69121         git-merge-changelog: add specific example on how to use with hg.
69122         * lib/git-merge-changelog.c: Add example on how to use in .hgrc.
69124 2012-03-18  Mark Wielaard  <mark@klomp.org>
69126         lib/git-merge-changelog.c (status): Report bugs to bug-gnulib@gnu.org.
69128 2012-03-18  Andreas Oberritter  <obi@opendreambox.org>
69130         git-version-gen: don't let "prefix" envvar cause trouble
69131         * build-aux/git-version-gen (prefix): Initialize properly,
69132         so as not to use a value specified via the environment.
69133         Details here: http://thread.gmane.org/gmane.comp.gnu.parted.bugs/10810
69135 2012-03-16  Paul Eggert  <eggert@cs.ucla.edu>
69137         regex: diagnose too-large repeat counts in EREs
69138         Previously, the code did not diagnose the too-large repeat count
69139         in EREs like 'b{1000000000}'; instead, it silently treated the ERE
69140         as if it were 'b\{1000000000}', which is unexpected.
69141         * lib/regcomp.c (parse_dup_op): Fail with REG_ESIZE if a repeat count
69142         is too large.  REG_ESIZE is used nowhere else, and the diagnostic
69143         is a reasonable one for this problem.  Another option would be to
69144         create a new REG_OVERFLOW error for repeat counts that are too large.
69145         (fetch_number): Return RE_DUP_MAX + 1, not REG_ERROR, if the repeat
69146         count is too large, so that the caller can distinguish the two cases.
69147         * lib/regex.h (_REG_ESIZE): Document that this is now a generic
69148         "Too large" return code, and that repeat counts are one example of this.
69150 2012-03-16  Paul Eggert  <eggert@cs.ucla.edu>
69152         doc: some glibc x32 integer width issues
69153         * doc/posix-headers/sys_types.texi (sys/types.h):
69154         * doc/posix-headers/time.texi (time.h):
69155         Mention that glibc x32 does not conform to POSIX in a couple of
69156         areas related to integer widths.
69158 2012-03-15  Bruno Haible  <bruno@clisp.org>
69160         fmal: Avoid test failure on OpenBSD 5.1/SPARC64.
69161         * lib/fma.c (VOLATILE): New macro.
69162         (FUNC): Use it to work around a GCC compiler bug.
69164 2012-03-13  Bruno Haible  <bruno@clisp.org>
69166         hypotl: Bypass broken implementation in OpenBSD 5.1/SPARC.
69167         * m4/hypotl.m4 (gl_FUNC_HYPOTL_WORKS): New macro.
69168         (gl_FUNC_HYPOTL): Invoke it. If the function does not work, set
69169         REPLACE_HYPOTL to 1.
69170         * doc/posix-functions/hypotl.texi: Mention the OpenBSD 5.1/SPARC bug.
69172 2012-03-13  Bruno Haible  <bruno@clisp.org>
69174         remainderl: Bypass broken implementation in OpenBSD 5.1/SPARC.
69175         * m4/remainderl.m4 (gl_FUNC_REMAINDERL_WORKS): New macro.
69176         (gl_FUNC_REMAINDERL): Invoke it. If the function does not work, set
69177         REPLACE_REMAINDERL to 1.
69178         * doc/posix-functions/remainderl.texi: Mention the OpenBSD 5.1/SPARC
69179         bug.
69181 2012-03-13  Bruno Haible  <bruno@clisp.org>
69183         sqrtl: Bypass broken implementation in OpenBSD 5.1/SPARC.
69184         * lib/math.in.h (sqrtl): Replace it if REPLACE_SQRTL is 1.
69185         * m4/sqrtl.m4 (gl_FUNC_SQRTL_WORKS): New macro.
69186         (gl_FUNC_SQRTL): Invoke it. Set REPLACE_SQRTL to 1 if sqrtl() produces
69187         too big rounding errors.
69188         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_SQRTL.
69189         * modules/math (Makefile.am): Substitute REPLACE_SQRTL.
69190         * modules/sqrtl (configure.ac): Consider REPLACE_SQRTL.
69191         (Depends-on): Update conditions.
69192         * tests/test-sqrtl.c (my_ldexpl): New function.
69193         (main): Add test of a particular value.
69194         * doc/posix-functions/sqrtl.texi: Mention the OpenBSD 5.1/SPARC bug.
69196 2012-03-13  Pádraig Brady  <P@draigBrady.com>
69198         doc: Update timer_* platform portability notes.
69199         * doc/posix-functions/timer_create.texi: Add platforms (OpenBSD 4.9)
69200         that always return ENOSYS.
69201         * doc/posix-functions/timer_delete.texi: Likewise.
69202         * doc/posix-functions/timer_gettime.texi: Likewise.
69203         * doc/posix-functions/timer_settime.texi: Likewise.
69205 2012-03-13  Bruno Haible  <bruno@clisp.org>
69207         cbrtl: Bypass broken implementation in OpenBSD 5.1/SPARC.
69208         * m4/cbrtl.m4 (gl_FUNC_CBRTL_WORKS): New macro.
69209         (gl_FUNC_CBRTL): Invoke it. If the function does not work, set
69210         REPLACE_CBRTL to 1.
69211         * doc/posix-functions/cbrtl.texi: Mention the OpenBSD 5.1/SPARC bug.
69213 2012-03-13  Bruno Haible  <bruno@clisp.org>
69215         remainderl: Avoid compilation error on AIX >= 5.2.
69216         * lib/math.in.h (remainderl): Undefine macro from the system header.
69218 2012-03-13  Bruno Haible  <bruno@clisp.org>
69220         Avoid compilation errors with MSVC option -fp:strict.
69221         * lib/cbrt.c: Use MSVC specific pragma fenv_access.
69222         * lib/cbrtf.c: Likewise.
69223         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
69225 2012-03-12  Bruno Haible  <bruno@clisp.org>
69227         uninorm: Don't crash in out-of-memory conditions.
69228         * lib/uninorm/u-normalize-internal.h (FUNC): Handle malloc() failure
69229         gracefully.
69230         * lib/uninorm/uninorm-filter.c (uninorm_filter_write): Likewise.
69231         Based on a report and patch by Stephen Gallagher <sgallagh@redhat.com>.
69233 2012-03-13  Akim Demaille  <akim@lrde.epita.fr>
69235         quote: fix syntax-check
69236         * top/maint.mk (sc_prohibit_quote_without_use): quote.h
69237         also exports quote_quoting_options.
69239 2012-03-12  Simon Josefsson  <simon@josefsson.org>
69241         Collapse list of copyright years to ranges.  See
69242         <https://lists.gnu.org/r/bug-gnulib/2012-03/msg00051.html>.
69243         * build-aux/bootstrap.conf, build-aux/csharpcomp.sh.in,
69244         build-aux/csharpexec.sh.in, build-aux/gnupload,
69245         build-aux/install-reloc, build-aux/javacomp.sh.in,
69246         build-aux/javaexec.sh.in, build-aux/ldd.sh.in,
69247         build-aux/move-if-change, build-aux/reloc-ldflags,
69248         build-aux/relocatable.sh.in, build-aux/x-to-1.in: Fix copyright.
69250 2012-03-11  Bruno Haible  <bruno@clisp.org>
69252         log2f-ieee: Work around test failure on NetBSD 5.1 and Solaris 10.
69253         * m4/log2f-ieee.m4: New file.
69254         * m4/log2f.m4 (gl_FUNC_LOG2F): If gl_FUNC_LOG2F_IEEE is present, test
69255         whether log2f works with a minus zero argument. Replace it if not.
69256         * modules/log2f-ieee (Files): Add m4/log2f-ieee.m4.
69257         (Depends-on): Add log2-ieee.
69258         (configure.ac): Invoke gl_FUNC_LOG2F_IEEE.
69259         * doc/posix-functions/log2f.texi: Mention the log2f-ieee module.
69261         log2-ieee: Work around test failure on NetBSD 5.1 and Solaris 10.
69262         * m4/log2-ieee.m4: New file.
69263         * m4/log2.m4 (gl_FUNC_LOG2): If gl_FUNC_LOG2_IEEE is present, test
69264         whether log2 works with a minus zero argument. Replace it if not.
69265         * modules/log2-ieee (Files): Add m4/log2-ieee.m4.
69266         (configure.ac): Invoke gl_FUNC_LOG2_IEEE.
69267         * doc/posix-functions/log2.texi: Mention the log2-ieee module.
69269         Tests for module 'log2l-ieee'.
69270         * modules/log2l-ieee-tests: New file.
69271         * tests/test-log2l-ieee.c: New file.
69273         New module 'log2l-ieee'.
69274         * modules/log2l-ieee: New file.
69276         Tests for module 'log2-ieee'.
69277         * modules/log2-ieee-tests: New file.
69278         * tests/test-log2-ieee.c: New file.
69280         New module 'log2-ieee'.
69281         * modules/log2-ieee: New file.
69283         Tests for module 'log2f-ieee'.
69284         * modules/log2f-ieee-tests: New file.
69285         * tests/test-log2f-ieee.c: New file.
69286         * tests/test-log2-ieee.h: New file.
69288         New module 'log2f-ieee'.
69289         * modules/log2f-ieee: New file.
69291 2012-03-11  Bruno Haible  <bruno@clisp.org>
69293         Tests for module 'log2l'.
69294         * modules/log2l-tests: New file.
69295         * tests/test-log2l.c: New file.
69297         New module 'log2l'.
69298         * lib/math.in.h (log2l): New declaration.
69299         * lib/log2l.c: New file.
69300         * m4/log2l.m4: New file.
69301         * m4/math_h.m4 (gl_MATH_H): Test whether log2l is declared.
69302         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG2L, HAVE_DECL_LOG2L,
69303         REPLACE_LOG2L.
69304         * modules/math (Makefile.am): Substitute GNULIB_LOG2L, HAVE_DECL_LOG2L,
69305         REPLACE_LOG2L.
69306         * modules/log2l: New file.
69307         * tests/test-math-c++.cc: Check the declaration of log2l.
69308         * doc/posix-functions/log2l.texi: Mention the new module and the IRIX
69309         and OSF/1 problems.
69311 2012-03-11  Bruno Haible  <bruno@clisp.org>
69313         Tests for module 'log2f'.
69314         * modules/log2f-tests: New file.
69315         * tests/test-log2f.c: New file.
69317         New module 'log2f'.
69318         * lib/math.in.h (log2f): New declaration.
69319         * lib/log2f.c: New file.
69320         * m4/log2f.m4: New file.
69321         * m4/math_h.m4 (gl_MATH_H): Test whether log2f is declared.
69322         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG2F, HAVE_DECL_LOG2F,
69323         REPLACE_LOG2F.
69324         * modules/math (Makefile.am): Substitute GNULIB_LOG2F, HAVE_DECL_LOG2F,
69325         REPLACE_LOG2F.
69326         * modules/log2f: New file.
69327         * tests/test-math-c++.cc: Check the declaration of log2f.
69328         * doc/posix-functions/log2f.texi: Mention the new module and the IRIX
69329         and OSF/1 and Cygwin problems.
69331 2012-03-11  Bruno Haible  <bruno@clisp.org>
69333         Tests for module 'log2'.
69334         * modules/log2-tests: New file.
69335         * tests/test-log2.c: New file.
69336         * tests/test-log2.h: New file.
69338         New module 'log2'.
69339         * lib/math.in.h (log2): New declaration.
69340         * lib/log2.c: New file.
69341         * m4/log2.m4: New file.
69342         * m4/math_h.m4 (gl_MATH_H): Test whether log2 is declared.
69343         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG2, HAVE_DECL_LOG2,
69344         REPLACE_LOG2.
69345         * modules/math (Makefile.am): Substitute GNULIB_LOG2, HAVE_DECL_LOG2,
69346         REPLACE_LOG2.
69347         * modules/log2: New file.
69348         * tests/test-math-c++.cc: Check the declaration of log2.
69349         * doc/posix-functions/log2.texi: Mention the new module and the IRIX
69350         and OSF/1 and Cygwin problems.
69352 2012-03-11  Bruno Haible  <bruno@clisp.org>
69354         exp2* tests: More tests.
69355         * tests/test-exp2.h (test_function): Test all integral arguments that
69356         don't need to overflow or denormalized numbers.
69357         * tests/test-exp2.c (MAX_EXP, MIN_EXP): New macros.
69358         * tests/test-exp2f.c (MAX_EXP, MIN_EXP): Likewise.
69359         * tests/test-exp2l.c (MAX_EXP, MIN_EXP): Likewise.
69361 2012-03-10  Bruno Haible  <bruno@clisp.org>
69363         log1pl-ieee: Work around test failure on AIX 7.1.
69364         * modules/log1pl-ieee (Depends-on): Add log1p-ieee.
69366         log1pl-ieee: Work around test failure on IRIX 6.5.
69367         * m4/log1pl-ieee.m4: New file.
69368         * m4/log1pl.m4 (gl_FUNC_LOG1PL): If gl_FUNC_LOG1PL_IEEE is present,
69369         test whether log1pl works with a minus zero argument. Replace it if
69370         not.
69371         * lib/math.in.h (log1pl): Override if REPLACE_LOG1PL is 1.
69372         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG1PL.
69373         * modules/math (Makefile.am): Substitute REPLACE_LOG1PL.
69374         * modules/log1pl (configure.ac): Consider REPLACE_LOG1PL.
69375         (Depends-on): Update conditions.
69376         * modules/log1pl-ieee (Files): Add m4/log1p-ieee.m4, m4/minus-zero.m4,
69377         m4/signbit.m4.
69378         (configure.ac): Invoke gl_FUNC_LOG1PL_IEEE.
69379         * doc/posix-functions/log1pl.texi: Mention the log1pl-ieee module.
69381         log1pf-ieee: Work around test failure on OpenBSD 4.9 and AIX 7.1.
69382         * m4/log1pf-ieee.m4: New file.
69383         * m4/log1pf.m4 (gl_FUNC_LOG1PF): If gl_FUNC_LOG1PF_IEEE is present,
69384         test whether log1pf works with a minus zero argument. Replace it if
69385         not.
69386         * modules/log1pf-ieee (Files): Add m4/log1pf-ieee.m4, m4/minus-zero.m4,
69387         m4/signbit.m4.
69388         (configure.ac): Invoke gl_FUNC_LOG1PF_IEEE.
69389         * doc/posix-functions/log1pf.texi: Mention the log1pf-ieee module.
69391         log1pf-ieee: Work around test failure on AIX 5.1 and HP-UX 11.
69392         * modules/log1pf-ieee (Depends-on): Add log1p-ieee.
69393         (configure.ac): Require gl_FUNC_LOG1PF.
69395         log1p-ieee: Work around test failure on AIX 7.1 and HP-UX 11.
69396         * m4/log1p-ieee.m4: New file.
69397         * m4/log1p.m4 (gl_FUNC_LOG1P): If gl_FUNC_LOG1P_IEEE is present, test
69398         whether log1p works with a minus zero argument. Replace it if not.
69399         * lib/math.in.h (log1p): Override if REPLACE_LOG1P is 1.
69400         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOG1P.
69401         * modules/math (Makefile.am): Substitute REPLACE_LOG1P.
69402         * modules/log1p (configure.ac): Consider REPLACE_LOG1P.
69403         (Depends-on): Update conditions.
69404         * modules/log1p-ieee (Files): Add m4/log1p-ieee.m4, m4/minus-zero.m4,
69405         m4/signbit.m4.
69406         (configure.ac): Invoke gl_FUNC_LOG1P_IEEE.
69407         * doc/posix-functions/log1p.texi: Mention the log1p-ieee module.
69409         Tests for module 'log1pl-ieee'.
69410         * modules/log1pl-ieee-tests: New file.
69411         * tests/test-log1pl-ieee.c: New file.
69413         New module 'log1pl-ieee'.
69414         * modules/log1pl-ieee: New file.
69416         Tests for module 'log1p-ieee'.
69417         * modules/log1p-ieee-tests: New file.
69418         * tests/test-log1p-ieee.c: New file.
69420         New module 'log1p-ieee'.
69421         * modules/log1p-ieee: New file.
69423         Tests for module 'log1pf-ieee'.
69424         * modules/log1pf-ieee-tests: New file.
69425         * tests/test-log1pf-ieee.c: New file.
69426         * tests/test-log1p-ieee.h: New file.
69428         New module 'log1pf-ieee'.
69429         * modules/log1pf-ieee: New file.
69431 2012-03-10  Bruno Haible  <bruno@clisp.org>
69433         Tests for module 'log1pl'.
69434         * modules/log1pl-tests: New file.
69435         * tests/test-log1pl.c: New file.
69437         New module 'log1pl'.
69438         * lib/math.in.h (log1pl): New declaration.
69439         * lib/log1pl.c: New file.
69440         * m4/log1pl.m4: New file.
69441         * m4/math_h.m4 (gl_MATH_H): Test whether log1pl is declared.
69442         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG1PL, HAVE_LOG1PL.
69443         * modules/math (Makefile.am): Substitute GNULIB_LOG1PL, HAVE_LOG1PL.
69444         * modules/log1pl: New file.
69445         * tests/test-math-c++.cc: Check the declaration of log1pl.
69446         * doc/posix-functions/log1pl.texi: Mention the new module.
69448 2012-03-10  Bruno Haible  <bruno@clisp.org>
69450         Tests for module 'log1pf'.
69451         * modules/log1pf-tests: New file.
69452         * tests/test-log1pf.c: New file.
69454         New module 'log1pf'.
69455         * lib/math.in.h (log1pf): New declaration.
69456         * lib/log1pf.c: New file.
69457         * m4/log1pf.m4: New file.
69458         * m4/math_h.m4 (gl_MATH_H): Test whether log1pf is declared.
69459         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG1PF, HAVE_LOG1PF,
69460         REPLACE_LOG1PF.
69461         * modules/math (Makefile.am): Substitute GNULIB_LOG1PF, HAVE_LOG1PF,
69462         REPLACE_LOG1PF.
69463         * modules/log1pf: New file.
69464         * tests/test-math-c++.cc: Check the declaration of log1pf.
69465         * doc/posix-functions/log1pf.texi: Mention the new module.
69467 2012-03-10  Bruno Haible  <bruno@clisp.org>
69469         log1p tests: More tests.
69470         * tests/test-log1p.h: New file.
69471         * modules/log1p-tests (Files): Add tests/test-log1p.h, tests/randomd.c.
69472         (Makefile.am): Add randomd.c to test_log1p_SOURCES.
69473         * tests/test-log1p.c: Include <float.h> and test-log1p.h.
69474         (main): Invoke test_function.
69476         log1p: Provide replacement for Minix and MSVC.
69477         * lib/math.in.h (log1p): New declaration.
69478         * lib/log1p.c: New file.
69479         * m4/log1p.m4: New file.
69480         * m4/math_h.m4 (gl_MATH_H): Test whether log1p is declared.
69481         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG1P, HAVE_LOG1P.
69482         * modules/math (Makefile.am): Substitute GNULIB_LOG1P, HAVE_LOG1P.
69483         * modules/log1p (Files): Add lib/log1p.c, m4/log1p.m4.
69484         (Depends-on): Add math, isnand, log, round.
69485         (configure.ac): Invoke gl_FUNC_LOG1P. Arrange to compile replacement if
69486         HAVE_LOG1P is 0.
69487         * tests/test-math-c++.cc: Check the declaration of log1p.
69488         * doc/posix-functions/log1p.texi: Mention the replacement.
69490 2012-03-10  Bruno Haible  <bruno@clisp.org>
69492         math tests: Small simplification.
69493         * tests/test-exp.h (test_function): Use the same err_bound for
69494         'double' on platforms with sizeof (long double) == sizeof (double)
69495         than on platforms with sizeof (long double) > sizeof (double).
69496         * tests/test-exp2.h (test_function): Likewise.
69497         * tests/test-expm1.h (test_function): Likewise.
69498         * tests/test-log.h (test_function): Likewise.
69500 2012-03-10  Bruno Haible  <bruno@clisp.org>
69502         Fix some comments.
69503         * lib/expl.c: Fix an ambiguous comment.
69504         * lib/expm1.c: Likewise.
69505         * lib/expm1l.c: Likewise.
69506         * lib/exp2.c: Likewise.
69507         * lib/exp2l.c: Likewise.
69509 2012-03-10  Paul Eggert  <eggert@cs.ucla.edu>
69511         regex: allow inclusion of <regex.h> before <limits.h>
69512         Without this patch, portable programs had to include <limits.h> before
69513         <regex.h> if they wanted a consistent value for RE_DUP_MAX.
69514         I ran into this problem with a test version of GNU grep on Solaris 8.
69515         * lib/regex.h: Include <limits.h> if _REGEX_INCLUDE_LIMITS_H.
69516         This is done conditionally so that this change can be merged
69517         back to glibc.
69518         * m4/regex.m4 (gl_REGEX): Define _REGEX_INCLUDE_LIMITS_H if
69519         using the included regex.
69521         fts: depend on fdopendir
69522         * modules/fts (Depends-on): Depend on fdopendir.  This is needed
69523         on Solaris 8, at least, since it lacks fdopendir.  Evidently the
69524         problem was introduced when fdopendir was split out.
69526 2012-03-10  Bruno Haible  <bruno@clisp.org>
69528         Remove unused variables.
69529         * m4/fmodf.m4 (gl_FUNC_FMODF): Remove unused variable 'i'.
69530         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
69532 2012-03-10  Bruno Haible  <bruno@clisp.org>
69534         isnanf-nolibm: Fix last commit.
69535         * lib/isnanf-nolibm.h [IRIX]: Don't include <ieeefp.h>. Declare isnanf.
69537         isnanf-nolibm: Make it work on IRIX 6.5 with cc.
69538         * lib/isnanf-nolibm.h [IRIX]: Include <ieeefp.h>.
69540 2012-03-10  Bruno Haible  <bruno@clisp.org>
69542         logf-ieee: Work around test failure on NetBSD 5.1.
69543         * m4/logf-ieee.m4: New file.
69544         * m4/logf.m4 (gl_FUNC_LOGF): If gl_FUNC_LOGF_IEEE is present, test
69545         whether logf works with a negative argument. Replace it if not.
69546         * lib/logf.c (logf): For negative arguments, return NaN.
69547         * modules/logf-ieee (Files): Add m4/logf-ieee.m4.
69548         (configure.ac): Invoke gl_FUNC_LOGF_IEEE.
69549         * doc/posix-functions/logf.texi: Mention the logf-ieee module.
69551         logf-ieee: Work around test failure on Solaris 9.
69552         * modules/logf-ieee (Depends-on): Add log-ieee.
69553         (configure.ac): Require gl_FUNC_LOGF.
69555         log-ieee: Work around test failure on NetBSD 5.1 and Solaris 11.
69556         * m4/log-ieee.m4: New file.
69557         * m4/log.m4 (gl_FUNC_LOG): If gl_FUNC_LOG_IEEE is present, test whether
69558         log works with a negative argument. Replace it if not.
69559         * lib/log.c (log): For negative arguments, return NaN.
69560         * modules/log-ieee (Files): Add m4/log-ieee.m4.
69561         (configure.ac): Invoke gl_FUNC_LOG_IEEE.
69562         * doc/posix-functions/log.texi: Mention the log-ieee module.
69564         Tests for module 'logl-ieee'.
69565         * modules/logl-ieee-tests: New file.
69566         * tests/test-logl-ieee.c: New file.
69568         New module 'logl-ieee'.
69569         * modules/logl-ieee: New file.
69571         Tests for module 'log-ieee'.
69572         * modules/log-ieee-tests: New file.
69573         * tests/test-log-ieee.c: New file.
69575         New module 'log-ieee'.
69576         * modules/log-ieee: New file.
69578         Tests for module 'logf-ieee'.
69579         * modules/logf-ieee-tests: New file.
69580         * tests/test-logf-ieee.c: New file.
69581         * tests/test-log-ieee.h: New file.
69583         New module 'logf-ieee'.
69584         * modules/logf-ieee: New file.
69586 2012-03-10  Bruno Haible  <bruno@clisp.org>
69588         log: Fix bug introduced on 2012-03-09.
69589         * m4/log.m4 (gl_FUNC_LOG): Require gl_MATH_H_DEFAULTS.
69591 2012-03-10  Pádraig Brady  <P@draigBrady.com>
69593         timer-time: link explicitly with pthreads on glibc
69594         * m4/timer_time.m4 (LIB_TIMER_TIME): Add -lpthread
69595         to support static linking, when newer glibc is
69596         detected, as that contains pthread emulation of
69597         POSIX timer functions where required.
69598         * modules/timer-time: Depend on threadlib to
69599         pull in the appropriate library to link.
69601 2012-03-10  Bruno Haible  <bruno@clisp.org>
69603         log* tests: More tests.
69604         * tests/test-log.h: New file.
69605         * tests/test-log.c: Include <float.h>, minus-zero.h, test-log.h.
69606         (main): Invoke test_function.
69607         * tests/test-logf.c: Include <float.h>, minus-zero.h, test-log.h.
69608         (main): Invoke test_function.
69609         * tests/test-logl.c: Include <float.h>, minus-zero.h, test-log.h.
69610         (main): Invoke test_function.
69611         * modules/log-tests (Files): Add tests/test-log.h, tests/minus-zero.h,
69612         tests/randomd.c.
69613         (Makefile.am): Add randomd.c to test_log_SOURCES.
69614         * modules/logf-tests (Files): Add tests/test-log.h, tests/minus-zero.h,
69615         tests/randomf.c.
69616         (Makefile.am): Add randomf.c to test_logf_SOURCES.
69617         * modules/logl-tests (Files): Add tests/test-log.h, tests/minus-zero.h,
69618         tests/randoml.c.
69619         (Depends-on): Add 'float'.
69620         (Makefile.am): Add randoml.c to test_logl_SOURCES.
69622 2012-03-09  Bruno Haible  <bruno@clisp.org>
69624         logl: Work around OSF/1 5.1 bug.
69625         * lib/math.in.h (logl): Override if REPLACE_LOGL is 1.
69626         * lib/logl.c (logl): If logl exists, use it and provide just the
69627         workaround.
69628         * m4/logl.m4 (gl_FUNC_LOGL_WORKS): New macro.
69629         (gl_FUNC_LOGL): Invoke it. Set REPLACE_LOGL.
69630         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOGL.
69631         * modules/math (Makefile.am): Substitute REPLACE_LOGL.
69632         * modules/logl (configure.ac): Consider REPLACE_LOGL.
69633         (Depends-on): Update conditions.
69634         * doc/posix-functions/logl.texi: Mention the OSF/1 5.1 problem.
69636 2012-03-09  Bruno Haible  <bruno@clisp.org>
69638         logf: Work around OSF/1 5.1 bug.
69639         * lib/math.in.h (logf): Override if REPLACE_LOGF is 1.
69640         * lib/logf.c (logf): If logf exists, use it and provide just the
69641         workaround.
69642         * m4/logf.m4 (gl_FUNC_LOGF_WORKS): New macro.
69643         (gl_FUNC_LOGF): Invoke it. Set REPLACE_LOGF.
69644         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_LOGF.
69645         * modules/math (Makefile.am): Substitute REPLACE_LOGF.
69646         * modules/logf (configure.ac): Consider REPLACE_LOGF.
69647         (Depends-on): Update conditions.
69648         * doc/posix-functions/logf.texi: Mention the OSF/1 5.1 problem.
69650 2012-03-09  Bruno Haible  <bruno@clisp.org>
69652         log: Work around OSF/1 5.1 bug.
69653         * lib/math.in.h (log): New declaration.
69654         * lib/log.c: New file.
69655         * m4/log.m4 (gl_FUNC_LOG_WORKS): New macro.
69656         (gl_FUNC_LOG): Invoke it. Set REPLACE_LOG.
69657         * m4/math_h.m4 (gl_MATH_H): Test whether log is declared.
69658         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG, REPLACE_LOG.
69659         * modules/math (Makefile.am): Substitute GNULIB_LOG, REPLACE_LOG.
69660         * modules/log (Files): Add lib/log.c.
69661         (Depends-on): Add math.
69662         (configure.ac): If REPLACE_LOG is 1, compile an override.
69663         * tests/test-math-c++.cc: Check the declaration of log.
69664         * doc/posix-functions/log.texi: Mention the OSF/1 5.1 problem.
69666 2012-03-09  Jim Meyering  <meyering@redhat.com>
69668         readtokens.c: adjust wording in a comment
69669         * lib/readtokens.c: Insert omitted "that" in a comment.
69671 2012-03-08  Paul Eggert  <eggert@cs.ucla.edu>
69673         modechange: add notations +40, 00440, etc.
69674         * lib/modechange.c (mode_compile): Support new notations
69675         +40, -40, =440, 00440.  See <http://debbugs.gnu.org/8391>.
69677 2012-03-08  Bruno Haible  <bruno@clisp.org>
69679         exp2l-ieee: Work around test failure on OpenBSD 4.9 and IRIX 6.5.
69680         * m4/exp2l-ieee.m4: New file.
69681         * m4/exp2l.m4 (gl_FUNC_EXP2L): If gl_FUNC_EXP2L_IEEE is present,
69682         test whether exp2l works with a NaN argument and with a negative
69683         infinity argument. Replace it if not.
69684         * lib/math.in.h (exp2l): Override if REPLACE_EXP2L is 1.
69685         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXP2L.
69686         * modules/math (Makefile.am): Substitute REPLACE_EXP2L.
69687         * modules/exp2l (configure.ac): Consider REPLACE_EXP2L.
69688         (Depends-on): Update conditions.
69689         * modules/exp2l-ieee (Files): Add m4/exp2l-ieee.m4.
69690         (configure.ac): Invoke gl_FUNC_EXP2L_IEEE.
69691         * doc/posix-functions/exp2l.texi: Mention the exp2l-ieee module.
69693         Tests for module 'exp2l-ieee'.
69694         * modules/exp2l-ieee-tests: New file.
69695         * tests/test-exp2l-ieee.c: New file.
69697         New module 'exp2l-ieee'.
69698         * modules/exp2l-ieee: New file.
69700         Tests for module 'exp2-ieee'.
69701         * modules/exp2-ieee-tests: New file.
69702         * tests/test-exp2-ieee.c: New file.
69704         New module 'exp2-ieee'.
69705         * modules/exp2-ieee: New file.
69707         Tests for module 'exp2f-ieee'.
69708         * modules/exp2f-ieee-tests: New file.
69709         * tests/test-exp2f-ieee.c: New file.
69710         * tests/test-exp2-ieee.h: New file.
69712         New module 'exp2f-ieee'.
69713         * modules/exp2f-ieee: New file.
69715 2012-03-08  Bruno Haible  <bruno@clisp.org>
69717         Tests for module 'exp2l'.
69718         * modules/exp2l-tests: New file.
69719         * tests/test-exp2l.c: New file.
69721         New module 'exp2l'.
69722         * lib/math.in.h (exp2l): New declaration.
69723         * lib/exp2l.c: New file.
69724         * lib/expl-table.c: New file, extracted from lib/expl.c.
69725         * lib/expl.c (gl_expl_table): New declaration.
69726         (expl): Remove expl_table. Update reference.
69727         * m4/exp2l.m4: New file.
69728         * m4/math_h.m4 (gl_MATH_H): Test whether exp2l is declared.
69729         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXP2L, HAVE_DECL_EXP2L.
69730         * modules/math (Makefile.am): Substitute GNULIB_EXP2L, HAVE_DECL_EXP2L.
69731         * modules/exp2l: New file.
69732         * modules/expl (Files): Add lib/expl-table.c.
69733         (configure.ac): Compile also expl-table.c.
69734         * tests/test-math-c++.cc: Check the declaration of exp2l.
69735         * doc/posix-functions/exp2l.texi: Mention the new module and the IRIX
69736         problem.
69738 2012-03-08  Bruno Haible  <bruno@clisp.org>
69740         Tests for module 'exp2f'.
69741         * modules/exp2f-tests: New file.
69742         * tests/test-exp2f.c: New file.
69744         New module 'exp2f'.
69745         * lib/math.in.h (exp2f): New declaration.
69746         * lib/exp2f.c: New file.
69747         * m4/exp2f.m4: New file.
69748         * m4/math_h.m4 (gl_MATH_H): Test whether exp2f is declared.
69749         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXP2F, HAVE_DECL_EXP2F.
69750         * modules/math (Makefile.am): Substitute GNULIB_EXP2F, HAVE_DECL_EXP2F.
69751         * modules/exp2f: New file.
69752         * tests/test-math-c++.cc: Check the declaration of exp2f.
69753         * doc/posix-functions/exp2f.texi: Mention the new module and the
69754         IRIX problem.
69756 2012-03-08  Bruno Haible  <bruno@clisp.org>
69758         Tests for module 'exp2'.
69759         * modules/exp2-tests: New file.
69760         * tests/test-exp2.c: New file.
69761         * tests/test-exp2.h: New file.
69763         New module 'exp2'.
69764         * lib/math.in.h (exp2): New declaration.
69765         * lib/exp2.c: New file.
69766         * m4/exp2.m4: New file.
69767         * m4/math_h.m4 (gl_MATH_H): Test whether exp2 is declared.
69768         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXP2, HAVE_DECL_EXP2,
69769         REPLACE_EXP2.
69770         * modules/math (Makefile.am): Substitute GNULIB_EXP2, HAVE_DECL_EXP2,
69771         REPLACE_EXP2.
69772         * modules/exp2: New file.
69773         * tests/test-math-c++.cc: Check the declaration of exp2.
69774         * doc/posix-functions/exp2.texi: Mention the new module and the IRIX
69775         and OpenBSD problems.
69777 2012-03-08  Paul Eggert  <eggert@cs.ucla.edu>
69779         savedir: fix comment typo
69780         * lib/savedir.c (savedirstream): Fix typo in comment.
69782 2012-03-08  Bruno Haible  <bruno@clisp.org>
69784         test-readtokens.c: use const; remove unwarranted cast
69785         * tests/test-readtokens.c: Declare delim to be const, to avoid a cast.
69787 2012-03-08  Bruno Haible  <bruno@clisp.org>
69789         fmal: Avoid compilation error on AIX.
69790         * lib/math.in.h (fmal): Undefine macro before declaration. Needed on
69791         AIX 5.2..7.1.
69793 2012-03-08  Bruno Haible  <bruno@clisp.org>
69795         fma, fmaf, fmal: Override undeclared system functions on IRIX 6.5.
69796         * m4/fma.m4 (gl_FUNC_FMA): If fma() exists but is not declared,
69797         arrange to set REPLACE_FMA=1, not HAVE_FMA=0.
69798         * m4/fmaf.m4 (gl_FUNC_FMAF): If fmaf() exists but is not declared,
69799         arrange to set REPLACE_FMAF=1, not HAVE_FMAF=0.
69800         * m4/fmal.m4 (gl_FUNC_FMAL): If fmal() exists but is not declared,
69801         arrange to set REPLACE_FMAL=1, not HAVE_FMAL=0.
69803 2012-03-08  Bruno Haible  <bruno@clisp.org>
69805         remainderf: Override buggy system function on IRIX 6.5.
69806         * m4/remainderf.m4 (gl_FUNC_REMAINDERF_WORKS): New macro.
69807         (gl_FUNC_REMAINDERF): Invoke it. Don't assume remainderf() is declared
69808         when it exists.
69809         * doc/posix-functions/remainderf.texi: Mention the IRIX problems.
69811 2012-03-08  Jim Meyering  <meyering@redhat.com>
69813         test-readtokens.c: avoid const-related compilation warnings
69814         * tests/test-readtokens.c: Avoid const-related compilation warnings.
69816 2012-03-07  Jim Meyering  <meyering@redhat.com>
69817             Bruno Haible  <bruno@clisp.org>
69819         frexp-nolibm, frexpl-nolibm tests: Fix bug introduced on 2012-03-03.
69820         * modules/frexp-nolibm-tests (Files): Add tests/test-frexp.h,
69821         tests/randomd.c.
69822         (Makefile.am): Add randomd.c to test_frexp_nolibm_SOURCES.
69823         * modules/frexpl-nolibm-tests (Files): Add tests/test-frexp.h,
69824         tests/randoml.c.
69825         (Makefile.am): Add randoml.c to test_frexpl_nolibm_SOURCES.
69827 2012-03-07  Bruno Haible  <bruno@clisp.org>
69829         expm1l: Avoid compilation error on AIX.
69830         * lib/math.in.h (expm1l): Undefine macro before declaration. Needed on
69831         AIX 5.2..7.1.
69833 2012-03-07  Bruno Haible  <bruno@clisp.org>
69835         expm1l: Don't override undeclared system function on IRIX 6.5.
69836         * lib/math.in.h (expm1l): Test HAVE_DECL_EXPM1L, not HAVE_EXPM1L.
69837         * m4/expm1l.m4 (gl_FUNC_EXPM1L): Don't assume expm1l() is declared when
69838         it exists. Set HAVE_DECL_EXPM1L.
69839         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_EXPM1L, not
69840         HAVE_EXPM1L.
69841         * modules/math (Makefile.am): Substitute HAVE_DECL_EXPM1L, not
69842         HAVE_EXPM1L.
69843         * doc/posix-functions/expm1l.texi: Mention missing declaration problem.
69845 2012-03-07  Bruno Haible  <bruno@clisp.org>
69847         remainderl: Don't override undeclared system function on IRIX 6.5.
69848         * lib/math.in.h (remainderl): Test HAVE_DECL_REMAINDERL, not
69849         HAVE_REMAINDERL.
69850         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Don't assume remainderl() is
69851         declared when it exists. Set HAVE_DECL_REMAINDERL.
69852         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_REMAINDERL,
69853         not HAVE_REMAINDERL.
69854         * modules/math (Makefile.am): Substitute HAVE_DECL_REMAINDERL, not
69855         HAVE_REMAINDERL.
69856         * doc/posix-functions/remainderl.texi: Mention missing declaration
69857         problem.
69859 2012-03-07  Bruno Haible  <bruno@clisp.org>
69861         rintf: Don't override undeclared system function on IRIX 6.5.
69862         * lib/math.in.h (rintf): Test HAVE_DECL_RINTF, not HAVE_RINTF.
69863         * m4/rintf.m4 (gl_FUNC_RINTF): Don't assume rintf() is declared when it
69864         exists. Set HAVE_DECL_RINTF.
69865         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_RINTF, not
69866         HAVE_RINTF.
69867         * modules/math (Makefile.am): Substitute HAVE_DECL_RINTF, not
69868         HAVE_RINTF.
69869         * doc/posix-functions/rintf.texi: Mention missing declaration problem.
69871 2012-03-07  Bruno Haible  <bruno@clisp.org>
69873         roundl: Avoid compilation error on AIX.
69874         * lib/math.in.h (roundl): Undefine macro before declaration. Needed on
69875         AIX 5.2..7.1.
69877 2012-03-07  Bruno Haible  <bruno@clisp.org>
69879         roundl: Don't override undeclared system function on IRIX 6.5.
69880         * m4/roundl.m4 (gl_FUNC_ROUNDL): Search for roundl() in the libraries
69881         also when it is not declared. Set HAVE_ROUNDL. For replacement code,
69882         test HAVE_ROUNDL, not HAVE_DECL_ROUNDL.
69883         * modules/roundl (configure.ac): For replacement code, test
69884         HAVE_ROUNDL, not HAVE_DECL_ROUNDL.
69885         (Depends-on): Update conditions.
69886         * doc/posix-functions/roundl.texi: Mention the IRIX problem.
69888 2012-03-07  Bruno Haible  <bruno@clisp.org>
69890         roundf: Don't override undeclared system function on IRIX 6.5.
69891         * m4/roundf.m4 (gl_FUNC_ROUNDF): Search for roundf() in the libraries
69892         also when it is not declared. Set HAVE_ROUNDF. For replacement code,
69893         test HAVE_ROUNDF, not HAVE_DECL_ROUNDF.
69894         * modules/roundf (configure.ac): For replacement code, test
69895         HAVE_ROUNDF, not HAVE_DECL_ROUNDF.
69896         (Depends-on): Update conditions.
69897         * modules/roundf-ieee (Depends-on): Update conditions.
69898         * doc/posix-functions/roundf.texi: Mention the IRIX problem.
69900 2012-03-07  Bruno Haible  <bruno@clisp.org>
69902         round: Don't override undeclared system function on IRIX 6.5.
69903         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Accept an optional third
69904         argument.
69905         * m4/round.m4 (gl_FUNC_ROUND): Search for round() in the libraries
69906         also when it is not declared. Set HAVE_ROUND. For replacement code,
69907         test HAVE_ROUND, not HAVE_DECL_ROUND.
69908         * modules/round (configure.ac): For replacement code, test HAVE_ROUND,
69909         not HAVE_DECL_ROUND.
69910         (Depends-on): Update conditions.
69911         * modules/round-ieee (Depends-on): Update conditions.
69912         * doc/posix-functions/round.texi: Mention the IRIX problem.
69914 2012-03-07  Bruno Haible  <bruno@clisp.org>
69916         copysignf: Don't override undeclared system function on IRIX 6.5.
69917         * lib/math.in.h (copysignf): Test HAVE_DECL_COPYSIGNF, not
69918         HAVE_COPYSIGNF.
69919         * m4/copysignf.m4 (gl_FUNC_COPYSIGNF): Don't assume copysignf() is
69920         declared when it exists. Set HAVE_DECL_COPYSIGNF.
69921         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_COPYSIGNF,
69922         not HAVE_COPYSIGNF.
69923         * modules/math (Makefile.am): Substitute HAVE_DECL_COPYSIGNF, not
69924         HAVE_COPYSIGNF.
69925         * doc/posix-functions/copysignf.texi: Mention missing declaration
69926         problem.
69928 2012-03-07  Jim Meyering  <meyering@redhat.com>
69930         readtokens: add tests
69931         * modules/readtokens-tests: New file.
69932         * tests/test-readtokens.c: New file.
69934 2012-03-07  Jim Meyering  <meyering@redhat.com>
69936         quotearg: the module must now include quote.h
69937         With commit v0.0-7133-g6417476, quotearg.c includes "quote.h".
69938         So must the module.
69939         * modules/quotearg (Files): Add quote.h.
69941 2012-03-06  Paul Eggert  <eggert@cs.ucla.edu>
69943         readtokens: avoid core dumps with unusual calling patterns
69944         Reported by Xu Zhongxing in <http://debbugs.gnu.org/10953>.
69945         * lib/readtokens.c: Include limits.h.
69946         (word, bits_per_word, get_nth_bit, set_nth_bit): New.
69947         (readtoken): Don't cache the delimiters; the cache code was buggy
69948         if !delim && saved_delim, or if the new n_delim differs from the old.
69949         Also, it wasn't thread-safe.
69951 2012-03-07  Bruno Haible  <bruno@clisp.org>
69953         quote: Adhere to common module description layout.
69954         * modules/quote (Makefile.am): Add back empty section.
69956 2012-03-06  Akim Demaille  <demaille@gostai.com>
69958         quote: fuse into quotearg
69959         This patch is made for the benefit of Bison.
69960         quote does not leave the choice of the quoting style to the user.
69961         quoting_style provides poor customizability, yet quoting_options,
69962         which is very rich, is hidden inside quotearg.c.  So in order to
69963         allow quote customization, move its implementation to quotearg.c.
69964         * lib/quote.c: Remove.
69965         * modules/quote: Adjust.
69966         * lib/quotearg.c (quoting_options_from_style): Fix a compiler
69967         warning: provide all the members of literal structs.
69968         (quote_quoting_options): New.
69969         (quote, quote_n): Import implementation from quote.c.
69970         * lib/quote.h: Import the comments from quote.c.
69971         (quote_quoting_options): New.
69973 2012-03-06  Bruno Haible  <bruno@clisp.org>
69975         Tests for module 'expm1l-ieee'.
69976         * modules/expm1l-ieee-tests: New file.
69977         * tests/test-expm1l-ieee.c: New file.
69979         New module 'expm1l-ieee'.
69980         * modules/expm1l-ieee: New file.
69982         Tests for module 'expm1f-ieee'.
69983         * modules/expm1f-ieee-tests: New file.
69984         * tests/test-expm1f-ieee.c: New file.
69986         New module 'expm1f-ieee'.
69987         * modules/expm1f-ieee: New file.
69989         Tests for module 'expm1-ieee'.
69990         * modules/expm1-ieee-tests: New file.
69991         * tests/test-expm1-ieee.c: New file.
69992         * tests/test-expm1-ieee.h: New file.
69994         New module 'expm1-ieee'.
69995         * modules/expm1-ieee: New file.
69996         * m4/expm1-ieee.m4: New file.
69997         * m4/expm1.m4 (gl_FUNC_EXPM1): If gl_FUNC_EXPM1_IEEE is present, test
69998         whether expm1 works with a minus zero argument. Replace it if not.
69999         * lib/math.in.h (expm1): Override if REPLACE_EXPM1 is 1.
70000         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPM1.
70001         * modules/math (Makefile.am): Substitute REPLACE_EXPM1.
70002         * modules/expm1 (configure.ac): Consider REPLACE_EXPM1.
70003         (Depends-on): Update conditions.
70004         * doc/posix-functions/expm1.texi: Mention the expm1-ieee module and the
70005         AIX problem.
70007 2012-03-06  Bruno Haible  <bruno@clisp.org>
70009         Work around expm1f bug on IRIX 6.5.
70010         * lib/math.in.h (expm1f): Override if REPLACE_EXPM1F is 1.
70011         * m4/expm1f.m4 (gl_FUNC_EXPM1F_WORKS): New macro.
70012         (gl_FUNC_EXPM1F): Invoke it. Set REPLACE_EXPM1F to 1 if expm1f() does
70013         not work.
70014         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_EXPM1F.
70015         * modules/math (Makefile.am): Substitute REPLACE_EXPM1F.
70016         * modules/expm1f (configure.ac): Consider REPLACE_EXPM1F.
70017         (Depends-on): Update conditions.
70018         * doc/posix-functions/expm1f.texi: Mention the IRIX 6.5 bug.
70020 2012-03-06  Bruno Haible  <bruno@clisp.org>
70022         Tests for module 'expm1l'.
70023         * modules/expm1l-tests: New file.
70024         * tests/test-expm1l.c: New file.
70026         New module 'expm1l'.
70027         * lib/math.in.h (expm1l): New declaration.
70028         * lib/expm1l.c: New file.
70029         * m4/expm1l.m4: New file.
70030         * m4/math_h.m4 (gl_MATH_H): Test whether expm1l is declared.
70031         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPM1L, HAVE_EXPM1L.
70032         * modules/math (Makefile.am): Substitute GNULIB_EXPM1L, HAVE_EXPM1L.
70033         * modules/expm1l: New file.
70034         * tests/test-math-c++.cc: Check the declaration of expm1l.
70035         * doc/posix-functions/expm1l.texi: Mention the new module.
70037 2012-03-06  Bruno Haible  <bruno@clisp.org>
70039         Tests for module 'expm1f'.
70040         * modules/expm1f-tests: New file.
70041         * tests/test-expm1f.c: New file.
70043         New module 'expm1f'.
70044         * lib/math.in.h (expm1f): New declaration.
70045         * lib/expm1f.c: New file.
70046         * m4/expm1f.m4: New file.
70047         * m4/math_h.m4 (gl_MATH_H): Test whether expm1f is declared.
70048         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPM1F, HAVE_EXPM1F.
70049         * modules/math (Makefile.am): Substitute GNULIB_EXPM1F, HAVE_EXPM1F.
70050         * modules/expm1f: New file.
70051         * tests/test-math-c++.cc: Check the declaration of expm1f.
70052         * doc/posix-functions/expm1f.texi: Mention the new module.
70054 2012-03-06  Bruno Haible  <bruno@clisp.org>
70056         Tests for module 'expm1'.
70057         * modules/expm1-tests: New file.
70058         * tests/test-expm1.c: New file.
70059         * tests/test-expm1.h: New file.
70061         New module 'expm1'.
70062         * lib/math.in.h (expm1): New declaration.
70063         * lib/expm1.c: New file.
70064         * m4/expm1.m4: New file.
70065         * m4/math_h.m4 (gl_MATH_H): Test whether expm1 is declared.
70066         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPM1, HAVE_EXPM1.
70067         * modules/math (Makefile.am): Substitute GNULIB_EXPM1, HAVE_EXPM1.
70068         * modules/expm1: New file.
70069         * tests/test-math-c++.cc: Check the declaration of expm1.
70070         * doc/posix-functions/expm1.texi: Mention the new module.
70072 2012-03-06  Bruno Haible  <bruno@clisp.org>
70074         math: Ensure declarations of math functions.
70075         * modules/acosf (Depends-on): Add 'extensions'.
70076         * modules/asinf (Depends-on): Likewise.
70077         * modules/atan2f (Depends-on): Likewise.
70078         * modules/atanf (Depends-on): Likewise.
70079         * modules/cbrt (Depends-on): Likewise.
70080         * modules/cbrtf (Depends-on): Likewise.
70081         * modules/cbrtl (Depends-on): Likewise.
70082         * modules/copysignf (Depends-on): Likewise.
70083         * modules/copysignl (Depends-on): Likewise.
70084         * modules/cosf (Depends-on): Likewise.
70085         * modules/coshf (Depends-on): Likewise.
70086         * modules/expf (Depends-on): Likewise.
70087         * modules/fabsf (Depends-on): Likewise.
70088         * modules/fabsl (Depends-on): Likewise.
70089         * modules/fmaf (Depends-on): Likewise.
70090         * modules/fmal (Depends-on): Likewise.
70091         * modules/fmodf (Depends-on): Likewise.
70092         * modules/fmodl (Depends-on): Likewise.
70093         * modules/frexpf (Depends-on): Likewise.
70094         * modules/frexpl (Depends-on): Likewise.
70095         * modules/hypot (Depends-on): Likewise.
70096         * modules/hypotf (Depends-on): Likewise.
70097         * modules/hypotl (Depends-on): Likewise.
70098         * modules/ldexpf (Depends-on): Likewise.
70099         * modules/ldexpl (Depends-on): Likewise.
70100         * modules/log10f (Depends-on): Likewise.
70101         * modules/log10l (Depends-on): Likewise.
70102         * modules/log1p (Depends-on): Likewise.
70103         * modules/logb (Depends-on): Likewise.
70104         * modules/logf (Depends-on): Likewise.
70105         * modules/modff (Depends-on): Likewise.
70106         * modules/modfl (Depends-on): Likewise.
70107         * modules/powf (Depends-on): Likewise.
70108         * modules/remainderf (Depends-on): Likewise.
70109         * modules/remainderl (Depends-on): Likewise.
70110         * modules/rintf (Depends-on): Likewise.
70111         * modules/rintl (Depends-on): Likewise.
70112         * modules/sinf (Depends-on): Likewise.
70113         * modules/sinhf (Depends-on): Likewise.
70114         * modules/sqrtf (Depends-on): Likewise.
70115         * modules/tanf (Depends-on): Likewise.
70116         * modules/tanhf (Depends-on): Likewise.
70117         * m4/acosf.m4 (gl_FUNC_ACOSF): Require gl_USE_SYSTEM_EXTENSIONS.
70118         * m4/asinf.m4 (gl_FUNC_ASINF): Likewise.
70119         * m4/atan2f.m4 (gl_FUNC_ATAN2F): Likewise.
70120         * m4/atanf.m4 (gl_FUNC_ATANF): Likewise.
70121         * m4/cbrt.m4 (gl_FUNC_CBRT): Likewise.
70122         * m4/cbrtf.m4 (gl_FUNC_CBRTF): Likewise.
70123         * m4/cbrtl.m4 (gl_FUNC_CBRTL): Likewise.
70124         * m4/copysignf.m4 (gl_FUNC_COPYSIGNF): Likewise.
70125         * m4/copysignl.m4 (gl_FUNC_COPYSIGNL): Likewise.
70126         * m4/cosf.m4 (gl_FUNC_COSF): Likewise.
70127         * m4/coshf.m4 (gl_FUNC_COSHF): Likewise.
70128         * m4/expf.m4 (gl_FUNC_EXPF): Likewise.
70129         * m4/fabsf.m4 (gl_FUNC_FABSF): Likewise.
70130         * m4/fabsl.m4 (gl_FUNC_FABSL): Likewise.
70131         * m4/fmaf.m4 (gl_FUNC_FMAF): Likewise.
70132         * m4/fmal.m4 (gl_FUNC_FMAL): Likewise.
70133         * m4/fmodf.m4 (gl_FUNC_FMODF): Likewise.
70134         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
70135         * m4/frexpf.m4 (gl_FUNC_FREXPF): Likewise.
70136         * m4/frexpl.m4 (gl_FUNC_FREXPL): Likewise.
70137         * m4/hypot.m4 (gl_FUNC_HYPOT): Likewise.
70138         * m4/hypotf.m4 (gl_FUNC_HYPOTF): Likewise.
70139         * m4/hypotl.m4 (gl_FUNC_HYPOTL): Likewise.
70140         * m4/ldexpf.m4 (gl_FUNC_LDEXPF): Likewise.
70141         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Likewise.
70142         * m4/log10f.m4 (gl_FUNC_LOG10F): Likewise.
70143         * m4/log10l.m4 (gl_FUNC_LOF10L): Likewise.
70144         * m4/logb.m4 (gl_FUNC_LOGB): Likewise.
70145         * m4/logf.m4 (gl_FUNC_LOGF): Likewise.
70146         * m4/modff.m4 (gl_FUNC_MODFF): Likewise.
70147         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
70148         * m4/powf.m4 (gl_FUNC_POWF): Likewise.
70149         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Likewise.
70150         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
70151         * m4/rintf.m4 (gl_FUNC_RINTF): Likewise.
70152         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
70153         * m4/sinf.m4 (gl_FUNC_SINF): Likewise.
70154         * m4/sinhf.m4 (gl_FUNC_SINHF): Likewise.
70155         * m4/sqrtf.m4 (gl_FUNC_SQRTF): Likewise.
70156         * m4/tanf.m4 (gl_FUNC_TANF): Likewise.
70157         * m4/tanhf.m4 (gl_FUNC_TANHF): Likewise.
70159 2012-03-06  Bruno Haible  <bruno@clisp.org>
70161         math: Update module names in warnings.
70162         * lib/math.in.h (acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl,
70163         tanl): Use specific module name in warn-on-use warning.
70165 2012-03-06  Bruno Haible  <bruno@clisp.org>
70167         expl: Simplify computation.
70168         * lib/expl.c (expl): Simplify computation of exp_y. Fix comment.
70170 2012-03-05  Bruno Haible  <bruno@clisp.org>
70172         exp* tests: More tests.
70173         * tests/test-exp.h: New file.
70174         * tests/test-exp.c: Include <float.h> and test-exp.h.
70175         (main): Invoke test_function.
70176         * tests/test-expf.c: Include <float.h> and test-exp.h.
70177         (main): Invoke test_function.
70178         * tests/test-expl.c: Include <float.h> and test-exp.h.
70179         (main): Invoke test_function.
70180         * modules/exp-tests (Files): Add tests/test-exp.h, tests/randomd.c.
70181         (Makefile.am): Add randomd.c to test_exp_SOURCES.
70182         * modules/expf-tests (Files): Add tests/test-exp.h, tests/randomf.c.
70183         (Makefile.am): Add randomf.c to test_expf_SOURCES.
70184         * modules/expl-tests (Files): Add tests/test-exp.h, tests/randoml.c.
70185         (Depends-on): Add 'float'.
70186         (Makefile.am): Add randoml.c to test_expl_SOURCES.
70188         expl: Fix precision of computed result.
70189         * lib/expl.c: Completely rewritten.
70190         * modules/expl (Depends-on): Add isnanl, roundl, ldexpl. Remove floorl.
70191         (Maintainer): Add me.
70192         * m4/expl.m4 (gl_FUNC_EXPL): Update computation of EXPL_LIBM.
70194 2012-03-05  Bruno Haible  <bruno@clisp.org>
70196         cbrt* tests: More tests.
70197         * tests/test-cbrt.h: New file.
70198         * tests/test-cbrt.c: Include <float.h> and test-cbrt.h.
70199         (main): Invoke test_function.
70200         * tests/test-cbrtf.c: Include <float.h> and test-cbrt.h.
70201         (main): Invoke test_function.
70202         * tests/test-cbrtl.c: Include <float.h> and test-cbrt.h.
70203         (main): Invoke test_function.
70204         * modules/cbrt-tests (Files): Add tests/test-cbrt.h, tests/randomd.c.
70205         (Makefile.am): Add randomd.c to test_cbrt_SOURCES.
70206         * modules/cbrtf-tests (Files): Add tests/test-cbrt.h, tests/randomf.c.
70207         (Makefile.am): Add randomf.c to test_cbrtf_SOURCES.
70208         * modules/cbrtl-tests (Files): Add tests/test-cbrt.h, tests/randoml.c.
70209         (Depends-on): Add 'float'.
70210         (Makefile.am): Add randoml.c to test_cbrtl_SOURCES.
70212 2012-03-05  Bruno Haible  <bruno@clisp.org>
70214         hypot* tests: More tests.
70215         * tests/test-hypot.h: New file, partially extracted from
70216         tests/test-hypotl.c.
70217         * tests/test-hypot.c: Include test-hypot.h.
70218         (main): Invoke test_function.
70219         * tests/test-hypotf.c: Include test-hypot.h.
70220         (main): Invoke test_function.
70221         * tests/test-hypotl.c: Include fpucw.h and test-hypot.h.
70222         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING and test_function.
70223         * modules/hypot-tests (Files): Add tests/test-hypot.h, tests/randomd.c.
70224         (Makefile.am): Add randomd.c to test_hypot_SOURCES.
70225         * modules/hypotf-tests (Files): Add tests/test-hypot.h,
70226         tests/randomf.c.
70227         (Makefile.am): Add randomf.c to test_hypotf_SOURCES.
70228         * modules/hypotl-tests (Files): Add tests/test-hypot.h,
70229         tests/randoml.c.
70230         (Depends-on): Add 'fpucw', 'float'.
70231         (Makefile.am): Add randoml.c to test_hypotl_SOURCES.
70233 2012-03-05  Bruno Haible  <bruno@clisp.org>
70235         fpucw: Doc about FreeBSD.
70236         * lib/fpucw.h: Mention FreeBSD in comments.
70238 2012-03-04  Bruno Haible  <bruno@clisp.org>
70240         sqrt* tests: More tests.
70241         * tests/test-sqrt.h: New file.
70242         * tests/test-sqrt.c: Include <float.h> and test-sqrt.h.
70243         (main): Invoke test_function.
70244         * tests/test-sqrtf.c: Include <float.h> and test-sqrt.h.
70245         (main): Invoke test_function.
70246         * tests/test-sqrtl.c: Include <float.h> and test-sqrt.h.
70247         (main): Invoke test_function.
70248         * modules/sqrt-tests (Files): Add tests/test-sqrt.h, tests/randomd.c.
70249         (Makefile.am): Add randomd.c to test_sqrt_SOURCES.
70250         * modules/sqrtf-tests (Files): Add tests/test-sqrt.h, tests/randomf.c.
70251         (Makefile.am): Add randomf.c to test_sqrtf_SOURCES.
70252         * modules/sqrtl-tests (Files): Add tests/test-sqrt.h, tests/randoml.c.
70253         (Depends-on): Add 'float'.
70254         (Makefile.am): Add randoml.c to test_sqrtl_SOURCES.
70256 2012-03-04  Bruno Haible  <bruno@clisp.org>
70258         remainder* tests: More tests.
70259         * tests/test-remainder.h: New file, based on tests/test-fmod.h.
70260         * tests/test-remainder.c: Include <float.h> and test-remainder.h.
70261         (main): Invoke test_function.
70262         * tests/test-remainderf.c: Include <float.h> and test-remainder.h.
70263         (main): Invoke test_function.
70264         * tests/test-remainderl.c: Include <float.h> and test-remainder.h.
70265         (main): Invoke test_function.
70266         * modules/remainder-tests (Files): Add tests/test-remainder.h,
70267         tests/randomd.c.
70268         (Makefile.am): Add randomd.c to test_remainder_SOURCES.
70269         * modules/remainderf-tests (Files): Add tests/test-remainder.h,
70270         tests/randomf.c.
70271         (Makefile.am): Add randomf.c to test_remainderf_SOURCES.
70272         * modules/remainderl-tests (Files): Add tests/test-remainder.h,
70273         tests/randoml.c.
70274         (Depends-on): Add 'float'.
70275         (Makefile.am): Add randoml.c to test_remainderl_SOURCES.
70277 2012-03-04  Bruno Haible  <bruno@clisp.org>
70279         remainder, remainderf, remainderl: Fix computation for large quotients.
70280         * lib/remainder.c: Completely rewritten.
70281         * lib/remainderf.c (remainderf): Use implementation of remainder.c with
70282         USE_FLOAT.
70283         * lib/remainderl.c (remainderl): Use implementation of remainder.c with
70284         USE_LONG_DOUBLE.
70285         * modules/remainder (Depends-on): Add isfinite, signbit, fabs, fmod,
70286         isnand, isinf. Remove round, fma.
70287         * modules/remainderf (Files): Add lib/remainder.c.
70288         (Depends-on): Add isfinite, signbit, fabsf, fmodf, isnanf, isinf.
70289         Remove roundf, fmaf.
70290         * modules/remainderl (Files): Add lib/remainder.c.
70291         (Depends-on): Add float, isfinite, signbit, fabsl, fmodl, isnanl,
70292         isinf. Remove roundl, fmal.
70293         * m4/remainder.m4 (gl_FUNC_REMAINDER): Update computation of
70294         REMAINDER_LIBM.
70295         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): Update computation of
70296         REMAINDERF_LIBM.
70297         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Update computation of
70298         REMAINDERL_LIBM.
70300 2012-03-04  Bruno Haible  <bruno@clisp.org>
70302         fmod* tests: More tests.
70303         * tests/test-fmod.h (my_ldexp): New function.
70304         (test_function): Reduce amount of random numbers to test. Add tests
70305         of very large quotients x / y.
70306         * tests/test-fmod.c (MAX_EXP): New macro.
70307         * tests/test-fmodf.c (MAX_EXP): Likewise.
70308         * tests/test-fmodl.c (MAX_EXP): Likewise.
70310 2012-03-04  Bruno Haible  <bruno@clisp.org>
70312         fmod, fmodl: Fix computation for large quotients x / y.
70313         * lib/fmod.c: Completely rewritten.
70314         * lib/fmodl.c (fmodl): Use implementation of fmod.c with
70315         USE_LONG_DOUBLE.
70316         * modules/fmod (Depends-on): Add isfinite, signbit, fabs, frexp, ldexp,
70317         isnand. Remove fma.
70318         * modules/fmodl (Files): Add lib/fmod.c.
70319         (Depends-on): Add float, isfinite, signbit, fabsl,
70320         frexpl, ldexpl, isnanl. Remove fma.
70321         * m4/fmod.m4 (gl_FUNC_FMOD): Update computation of FMOD_LIBM.
70322         * m4/fmodl.m4 (gl_FUNC_FMODL): Update computation of FMODL_LIBM.
70324 2012-03-03  Bruno Haible  <bruno@clisp.org>
70326         fmod* tests: More tests.
70327         * tests/test-fmod.h: New file.
70328         * tests/test-fmod.c: Include <float.h> and test-fmod.h.
70329         (main): Invoke test_function.
70330         * tests/test-fmodf.c: Include <float.h> and test-fmod.h.
70331         (main): Invoke test_function.
70332         * tests/test-fmodl.c: Include <float.h> and test-fmod.h.
70333         (main): Invoke test_function.
70334         * modules/fmod-tests (Files): Add tests/test-fmod.h, tests/randomd.c.
70335         (Makefile.am): Add randomd.c to test_fmod_SOURCES.
70336         * modules/fmodf-tests (Files): Add tests/test-fmod.h, tests/randomf.c.
70337         (Makefile.am): Add randomf.c to test_fmodf_SOURCES.
70338         * modules/fmodl-tests (Files): Add tests/test-fmod.h, tests/randoml.c.
70339         (Depends-on): Add 'float'.
70340         (Makefile.am): Add randoml.c to test_fmodl_SOURCES.
70342 2012-03-03  Bruno Haible  <bruno@clisp.org>
70344         rint* tests: More tests.
70345         * tests/test-rint.h: New file, partially extracted from
70346         tests/test-rintl.c.
70347         * tests/test-rint.c: Include test-rint.h.
70348         (main): Invoke test_function.
70349         * tests/test-rintf.c: Include test-rint.h.
70350         (main): Invoke test_function.
70351         * tests/test-rintl.c: Include test-rint.h.
70352         (main): Invoke test_function.
70353         * modules/rint-tests (Files): Add tests/test-rint.h, tests/randomd.c.
70354         (Makefile.am): Add randomd.c to test_rint_SOURCES.
70355         * modules/rintf-tests (Files): Add tests/test-rint.h, tests/randomf.c.
70356         (Makefile.am): Add randomf.c to test_rintf_SOURCES.
70357         * modules/rintl-tests (Files): Add tests/test-rint.h, tests/randoml.c.
70358         (Makefile.am): Add randoml.c to test_rintl_SOURCES.
70360 2012-03-03  Bruno Haible  <bruno@clisp.org>
70362         modf* tests: More tests.
70363         * tests/test-modf.h: New file.
70364         * tests/test-modf.c: Include <float.h> and test-modf.h.
70365         (main): Invoke test_function.
70366         * tests/test-modff.c: Include <float.h> and test-modf.h.
70367         (main): Invoke test_function.
70368         * tests/test-modfl.c: Include <float.h> and test-modf.h.
70369         (main): Invoke test_function.
70370         * modules/modf-tests (Files): Add tests/test-modf.h, tests/randomd.c.
70371         (Makefile.am): Add randomd.c to test_modf_SOURCES.
70372         * modules/modff-tests (Files): Add tests/test-modf.h, tests/randomf.c.
70373         (Makefile.am): Add randomf.c to test_modff_SOURCES.
70374         * modules/modfl-tests (Files): Add tests/test-modf.h, tests/randoml.c.
70375         (Depends-on): Add 'float'.
70376         (Makefile.am): Add randoml.c to test_modfl_SOURCES.
70378 2012-03-03  Bruno Haible  <bruno@clisp.org>
70380         fabs* tests: More tests.
70381         * tests/test-fabs.h: New file, partially extracted from
70382         tests/test-fabsl.c.
70383         * tests/test-fabs.c (RANDOM): New macro.
70384         * tests/test-fabsf.c (RANDOM): New macro.
70385         * tests/test-fabsl.c (RANDOM): New macro.
70386         * modules/fabs-tests (Files): Add tests/randomd.c.
70387         (Makefile.am): Add randomd.c to test_fabs_SOURCES.
70388         * modules/fabsf-tests (Files): Add tests/randomf.c.
70389         (Makefile.am): Add randomf.c to test_fabsf_SOURCES.
70390         * modules/fabsl-tests (Files): Add tests/randoml.c.
70391         (Makefile.am): Add randoml.c to test_fabsl_SOURCES.
70393 2012-03-03  Bruno Haible  <bruno@clisp.org>
70395         ldexp* tests: More tests.
70396         * tests/test-ldexp.h (test_function): Add some pseudo-randomized tests.
70397         * tests/test-ldexp.c (RANDOM): New macro.
70398         * tests/test-ldexpf.c (RANDOM): New macro.
70399         * tests/test-ldexpl.c (RANDOM): New macro.
70400         * modules/ldexp-tests (Files): Add tests/randomd.c.
70401         (Makefile.am): Add randomd.c to test_ldexp_SOURCES.
70402         * modules/ldexpf-tests (Files): Add tests/randomf.c.
70403         (Makefile.am): Add randomf.c to test_ldexpf_SOURCES.
70404         * modules/ldexpl-tests (Files): Add tests/randoml.c.
70405         (Makefile.am): Add randoml.c to test_ldexpl_SOURCES.
70407 2012-03-03  Bruno Haible  <bruno@clisp.org>
70409         frexp* tests: More tests.
70410         * tests/test-frexp.h (test_function): Add some pseudo-randomized tests.
70411         * tests/test-frexp.c (RANDOM): New macro.
70412         * tests/test-frexpf.c (RANDOM): New macro.
70413         * tests/test-frexpl.c (RANDOM): New macro.
70414         * modules/frexp-tests (Files): Add tests/randomd.c.
70415         (Makefile.am): Add randomd.c to test_frexp_SOURCES.
70416         * modules/frexpf-tests (Files): Add tests/randomf.c.
70417         (Makefile.am): Add randomf.c to test_frexpf_SOURCES.
70418         * modules/frexpl-tests (Files): Add tests/randoml.c.
70419         (Makefile.am): Add randoml.c to test_frexpl_SOURCES.
70421 2012-03-03  Bruno Haible  <bruno@clisp.org>
70423         Support for pseudo-random numbers in tests.
70424         * tests/randomf.c: New file.
70425         * tests/randomd.c: New file.
70426         * tests/randoml.c: New file.
70427         * tests/macros.h (randomf, randomd, randoml): New declarations.
70429 2012-03-03  Bruno Haible  <bruno@clisp.org>
70431         frexp* tests: Refactor.
70432         * tests/test-frexp.h: New file, extracted from tests/test-frexpl.c.
70433         * tests/test-frexp.c: Include and use it.
70434         * tests/test-frexpf.c: Likewise.
70435         * tests/test-frexpl.c: Likewise.
70436         * modules/frexp-tests (Files): Add tests/test-frexp.h.
70437         * modules/frexpf-tests (Files): Likewise.
70438         * modules/frexpl-tests (Files): Likewise.
70440 2012-03-02  Jim Meyering  <meyering@redhat.com>
70442         maint: don't specify XZ_OPT=-9ev in dist-related rule
70443         Using xz's -9 option is warranted only if you have a very large
70444         tarball (see xz's documentation for the sizes vs. presets), and
70445         requires 64MiB of memory at decompression time.
70446         * top/maint.mk (alpha beta stable): Don't specify XZ_OPT=-9ev.
70447         Automake's default of just "-e" is fine.  Override on a
70448         per-package basis by setting XZ_OPT e.g., in cfg.mk.
70450 2012-03-01  Eric Blake  <eblake@redhat.com>
70452         maint.mk: allow announcement for non-gnulib project
70453         * maint.mk (announcement): Skip gnulib version if not used.
70455 2012-03-01  Jim Meyering  <meyering@redhat.com>
70457         maint.mk: avoid spurious failure of _sc_search_regexp-using tests
70458         * top/maint.mk: Initialize _sc_search_regexp parameters, so that
70459         envvar settings cannot interfere.  Otherwise, setting envvars like
70460         prohibit=foo require=bar, etc. would cause spurious test failures.
70462 2012-03-01  Eric Blake  <eblake@redhat.com>
70464         maint.mk: add per-line exclusions to prohibitions
70465         * maint.mk (_sc_search_regexp): Add $exclude parameter.
70466         (sc_prohibit_strcmp, sc_unmarked_diagnostics)
70467         (sc_const_long_option): Use it.
70469 2012-03-01  Bruno Haible  <bruno@clisp.org>
70471         Tests for module 'expl-ieee'.
70472         * modules/expl-ieee-tests: New file.
70473         * tests/test-expl-ieee.c: New file.
70475         New module 'expl-ieee'.
70476         * modules/expl-ieee: New file.
70478         Tests for module 'exp-ieee'.
70479         * modules/exp-ieee-tests: New file.
70480         * tests/test-exp-ieee.c: New file.
70482         New module 'exp-ieee'.
70483         * modules/exp-ieee: New file.
70485         Tests for module 'expf-ieee'.
70486         * modules/expf-ieee-tests: New file.
70487         * tests/test-expf-ieee.c: New file.
70488         * tests/test-exp-ieee.h: New file.
70490         New module 'expf-ieee'.
70491         * modules/expf-ieee: New file.
70493 2012-02-29  Bruno Haible  <bruno@clisp.org>
70495         cbrtl-ieee: Work around test failure on IRIX 6.5.
70496         * m4/cbrtl-ieee.m4: New file.
70497         * m4/cbrtl.m4 (gl_FUNC_CBRTL): If gl_FUNC_CBRTL_IEEE is present,
70498         test whether cbrtl works with a minus zero argument. Replace it if not.
70499         * lib/math.in.h (cbrtl): Override if REPLACE_CBRTL is 1.
70500         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_CBRTL.
70501         * modules/math (Makefile.am): Substitute REPLACE_CBRTL.
70502         * modules/cbrtl (configure.ac): Consider REPLACE_CBRTL.
70503         (Depends-on): Update conditions.
70504         * modules/cbrtl-ieee (Files): Add m4/cbrtl-ieee.m4, m4/minus-zero.m4,
70505         m4/signbit.m4.
70506         (configure.ac): Invoke gl_FUNC_CBRTL_IEEE.
70507         * lib/cbrtl.c (cbrtl) [IRIX]: Avoid an unnecessary addition.
70508         * doc/posix-functions/cbrtl.texi: Mention the cbrtl-ieee module.
70510         Tests for module 'cbrtl-ieee'.
70511         * modules/cbrtl-ieee-tests: New file.
70512         * tests/test-cbrtl-ieee.c: New file.
70514         New module 'cbrtl-ieee'.
70515         * modules/cbrtl-ieee: New file.
70517         Tests for module 'cbrt-ieee'.
70518         * modules/cbrt-ieee-tests: New file.
70519         * tests/test-cbrt-ieee.c: New file.
70521         New module 'cbrt-ieee'.
70522         * modules/cbrt-ieee: New file.
70524         Tests for module 'cbrtf-ieee'.
70525         * modules/cbrtf-ieee-tests: New file.
70526         * tests/test-cbrtf-ieee.c: New file.
70527         * tests/test-cbrt-ieee.h: New file.
70529         New module 'cbrtf-ieee'.
70530         * modules/cbrtf-ieee: New file.
70532 2012-02-29  Bruno Haible  <bruno@clisp.org>
70534         cbrtf: Work around bug in IRIX 6.5 system function.
70535         * lib/math.in.h (cbrtf): Override if REPLACE_CBRTF is 1.
70536         * m4/cbrtf.m4 (gl_FUNC_CBRTF_WORKS): New macro.
70537         (gl_FUNC_CBRTF): Invoke it. Set REPLACE_CBRTF to 1 if cbrtf() does not
70538         work.
70539         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_CBRTF.
70540         * modules/math (Makefile.am): Substitute REPLACE_CBRTF.
70541         * modules/cbrtf (configure.ac): Consider REPLACE_CBRTF.
70542         (Depends-on): Update conditions.
70543         * doc/posix-functions/cbrtf.texi: Mention the IRIX 6.5 problem.
70545 2012-02-29  Bruno Haible  <bruno@clisp.org>
70547         Tests for module 'cbrtl'.
70548         * modules/cbrtl-tests: New file.
70549         * tests/test-cbrtl.c: New file.
70551         New module 'cbrtl'.
70552         * lib/math.in.h (cbrtl): New declaration.
70553         * lib/cbrtl.c: New file.
70554         * m4/cbrtl.m4: New file.
70555         * m4/math_h.m4 (gl_MATH_H): Test whether cbrtl is declared.
70556         (gl_MATH_H_DEFAULTS): Initialize GNULIB_CBRTL, HAVE_CBRTL,
70557         HAVE_DECL_CBRTL.
70558         * modules/math (Makefile.am): Substitute GNULIB_CBRTL, HAVE_CBRTL,
70559         HAVE_DECL_CBRTL.
70560         * modules/cbrtl: New file.
70561         * tests/test-math-c++.cc: Check the declaration of cbrtl.
70562         * doc/posix-functions/cbrtl.texi: Mention the new module.
70564 2012-02-29  Bruno Haible  <bruno@clisp.org>
70566         Tests for module 'cbrtf'.
70567         * modules/cbrtf-tests: New file.
70568         * tests/test-cbrtf.c: New file.
70570         New module 'cbrtf'.
70571         * lib/math.in.h (cbrtf): New declaration.
70572         * lib/cbrtf.c: New file.
70573         * m4/cbrtf.m4: New file.
70574         * m4/math_h.m4 (gl_MATH_H): Test whether cbrtf is declared.
70575         (gl_MATH_H_DEFAULTS): Initialize GNULIB_CBRTF, HAVE_CBRTF,
70576         HAVE_DECL_CBRTF.
70577         * modules/math (Makefile.am): Substitute GNULIB_CBRTF, HAVE_CBRTF,
70578         HAVE_DECL_CBRTF.
70579         * modules/cbrtf: New file.
70580         * tests/test-math-c++.cc: Check the declaration of cbrtf.
70581         * doc/posix-functions/cbrtf.texi: Mention the new module.
70583 2012-02-29  Bruno Haible  <bruno@clisp.org>
70585         cbrt: Provide replacement on MSVC and Minix.
70586         * lib/math.in.h (cbrt): New declaration.
70587         * lib/cbrt.c: New file.
70588         * m4/cbrt.m4: New file.
70589         * m4/math_h.m4 (gl_MATH_H): Test whether cbrt is declared.
70590         (gl_MATH_H_DEFAULTS): Initialize GNULIB_CBRT, HAVE_CBRT.
70591         * modules/math (Makefile.am): Substitute GNULIB_CBRT, HAVE_CBRT.
70592         * modules/cbrt (Files): Add lib/cbrt.c, m4/cbrt.m4.
70593         (Depends-on): Add dependencies.
70594         (configure.ac): Arrange to compile replacement if HAVE_CBRT is 0.
70595         * tests/test-math-c++.cc: Check the declaration of cbrt.
70596         * doc/posix-functions/cbrt.texi: Mention that the module provides a
70597         replacement.
70599 2012-02-29  Bruno Haible  <bruno@clisp.org>
70601         hypotl-ieee: Work around test failure on OSF/1 and native Windows.
70602         * m4/hypotl-ieee.m4: New file.
70603         * m4/hypotl.m4 (gl_FUNC_HYPOTL): If gl_FUNC_HYPOTL_IEEE is present,
70604         test whether hypotl works with mixed NaN and Infinity arguments.
70605         Replace it if not.
70606         * lib/math.in.h (hypotl): Override if REPLACE_HYPOTL is 1.
70607         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_HYPOTL.
70608         * modules/math (Makefile.am): Substitute REPLACE_HYPOTL.
70609         * modules/hypotl (configure.ac): Consider REPLACE_HYPOTL.
70610         (Depends-on): Update conditions.
70611         * modules/hypotl-ieee (Files): Add m4/hypotl-ieee.m4.
70612         (Depends-on): Add hypot-ieee.
70613         (configure.ac): Invoke gl_FUNC_HYPOTL_IEEE.
70614         * doc/posix-functions/hypotl.texi: Mention the hypotl-ieee module.
70616         hypotf-ieee: Work around test failure on OSF/1 and native Windows.
70617         * m4/hypotf-ieee.m4: New file.
70618         * m4/hypotf.m4 (gl_FUNC_HYPOTF): If gl_FUNC_HYPOTF_IEEE is present,
70619         test whether hypotf works with mixed NaN and Infinity arguments.
70620         Replace it if not.
70621         * modules/hypotf-ieee (Files): Add m4/hypotf-ieee.m4.
70622         (Depends-on): Add hypot-ieee.
70623         (configure.ac): Invoke gl_FUNC_HYPOTF_IEEE.
70624         * doc/posix-functions/hypotf.texi: Mention the hypotf-ieee module.
70626         hypot-ieee: Work around test failure on OSF/1 and native Windows.
70627         * lib/math.in.h (hypot): New declaration.
70628         * lib/hypot.c: New file.
70629         * m4/hypot-ieee.m4: New file.
70630         * m4/hypot.m4 (gl_FUNC_HYPOT): If gl_FUNC_HYPOT_IEEE is present, test
70631         whether hypot works with mixed NaN and Infinity arguments. Replace it
70632         if not.
70633         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_HYPOT,
70634         REPLACE_HYPOT.
70635         * modules/math (Makefile.am): Substitute GNULIB_HYPOT, REPLACE_HYPOT.
70636         * modules/hypot (Files): Add lib/hypot.c.
70637         (Depends-on): Add dependencies.
70638         (configure.ac): Arrange to compile replacement if REPLACE_HYPOT is 1.
70639         * modules/hypot-ieee (Files): Add m4/hypot-ieee.m4.
70640         (configure.ac): Invoke gl_FUNC_HYPOT_IEEE.
70641         * tests/test-math-c++.cc: Check the declaration of hypot.
70642         * doc/posix-functions/hypot.texi: Mention the hypot-ieee module.
70644         Tests for module 'hypotl-ieee'.
70645         * modules/hypotl-ieee-tests: New file.
70646         * tests/test-hypotl-ieee.c: New file.
70648         New module 'hypotl-ieee'.
70649         * modules/hypotl-ieee: New file.
70651         Tests for module 'hypot-ieee'.
70652         * modules/hypot-ieee-tests: New file.
70653         * tests/test-hypot-ieee.c: New file.
70655         New module 'hypot-ieee'.
70656         * modules/hypot-ieee: New file.
70658         Tests for module 'hypotf-ieee'.
70659         * modules/hypotf-ieee-tests: New file.
70660         * tests/test-hypotf-ieee.c: New file.
70661         * tests/test-hypot-ieee.h: New file.
70663         New module 'hypotf-ieee'.
70664         * modules/hypotf-ieee: New file.
70666 2012-02-29  Bruno Haible  <bruno@clisp.org>
70668         Remove unused variables.
70669         * m4/fmod.m4 (gl_FUNC_FMOD): Remove unused variable 'i'.
70670         * m4/fmodl.m4 (gl_FUNC_FMODL): Likewise.
70671         * m4/remainder.m4 (gl_FUNC_REMAINDER): Likewise.
70672         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): Likewise.
70674 2012-02-29  Eric Blake  <eblake@redhat.com>
70676         termios: fix pid_t always, not just for tcgetsid
70677         * doc/posix-headers/termios.texi (termios.h): Mention problem.
70678         * lib/termios.in.h (include): Ensure pid_t on all platforms, not
70679         just when building tcgetsid.
70681 2012-02-29  Bruno Haible  <bruno@clisp.org>
70683         Tests for module 'hypotl'.
70684         * modules/hypotl-tests: New file.
70685         * tests/test-hypotl.c: New file.
70687         New module 'hypotl'.
70688         * lib/math.in.h (hypotl): New declaration.
70689         * lib/hypotl.c: New file.
70690         * m4/hypotl.m4: New file.
70691         * m4/math_h.m4 (gl_MATH_H): Test whether hypotf is declared.
70692         (gl_MATH_H_DEFAULTS): Initialize GNULIB_HYPOTL, HAVE_HYPOTL.
70693         * modules/math (Makefile.am): Substitute GNULIB_HYPOTL, HAVE_HYPOTL.
70694         * modules/hypotl: New file.
70695         * tests/test-math-c++.cc: Check the hypotl declaration.
70696         * doc/posix-functions/hypotl.texi: Mention the new module.
70698 2012-02-29  Eric Blake  <eblake@redhat.com>
70700         tcgetsid: fix cygwin header bug
70701         * lib/termios.in.h (includes) [Cygwin]: Ensure pid_t is defined.
70703         docs: update cygwin progress
70704         * doc/posix-functions/llround.texi (llround): Added in cygwin
70705         1.7.8.
70706         * doc/posix-functions/llroundf.texi (llroundf): Likewise.
70707         * doc/glibc-functions/program_invocation_name.texi
70708         (program_invocation_name): Likewise.
70709         * doc/glibc-functions/program_invocation_short_name.texi
70710         (program_invocation_short_name): Likewise.
70711         * doc/glibc-functions/madvise.texi (madvise): Likewise.
70712         * doc/glibc-functions/pthread_yield.texi (pthread_yield):
70713         Likewise.
70714         * doc/posix-functions/pthread_spin_destroy.texi
70715         (pthread_spin_destroy): Added in cygwin 1.7.10.
70716         * doc/posix-functions/pthread_spin_init.texi (pthread_spin_init):
70717         Likewise.
70718         * doc/posix-functions/pthread_spin_lock.texi (pthread_spin_lock):
70719         Likewise.
70720         * doc/posix-functions/pthread_spin_trylock.texi
70721         (pthread_spin_trylock): Likewise.
70722         * doc/posix-functions/pthread_spin_unlock.texi
70723         (pthread_spin_unlock): Likewise.
70724         * doc/posix-functions/pthread_setschedprio.texi
70725         (pthread_setschedprio): Likewise.
70726         * doc/posix-functions/pthread_attr_getstack.texi
70727         (pthread_attr_getstack): Likewise.
70728         * doc/pastposix-functions/pthread_attr_getstackaddr.texi
70729         (pthread_attr_getstackaddr): Likewise.
70730         * doc/glibc-functions/pthread_getattr_np.texi
70731         (pthread_getattr_np): Likewise.
70732         * doc/glibc-functions/sys_siglist.texi (sys_siglist): Likewise.
70733         * doc/glibc-functions/sysinfo.texi (sysinfo): Likewise.
70734         * doc/posix-functions/clock_settime.texi (clock_settime):
70735         Likewise.
70736         * doc/posix-functions/pthread_attr_getguardsize.texi
70737         (pthread_attr_getguardsize): Likewise.
70738         * doc/posix-functions/pthread_attr_setguardsize.texi
70739         (pthread_attr_setguardsize): Likewise.
70740         * doc/posix-functions/pthread_attr_setstack.texi
70741         (pthread_attr_setstack): Likewise.
70742         * doc/pastposix-functions/pthread_attr_setstackaddr.texi
70743         (pthread_attr_setstackaddr): Likewise.
70744         * doc/posix-functions/clock_getcpuclockid.texi
70745         (clock_getcpuclockid): Likewise.
70746         * doc/posix-functions/pthread_getcpuclockid.texi
70747         (pthread_getcpuclockid): Likewise.
70748         * doc/glibc-functions/error.texi (error): Likewise.
70749         * doc/glibc-functions/error_at_line.texi (error_at_line):
70750         Likewise.
70751         * doc/glibc-functions/error_message_count.texi
70752         (error_message_count): Likewise.
70753         * doc/glibc-functions/error_one_per_line.texi
70754         (error_one_per_line): Likewise.
70755         * doc/glibc-functions/error_print_progname.texi
70756         (error_print_progname): Likewise.
70757         * doc/posix-functions/pthread_condattr_getclock.texi
70758         (pthread_condattr_getclock): Likewise.
70759         * doc/posix-functions/pthread_condattr_setclock.texi
70760         (pthread_condattr_setclock): Likewise.
70761         * doc/posix-functions/clock_nanosleep.texi (clock_nanosleep):
70762         Likewise.
70763         * doc/glibc-functions/getgrouplist.texi (getgrouplist): Likewise.
70764         * doc/glibc-functions/getpt.texi (getpt): Likewise.
70765         * doc/glibc-functions/get_current_dir_name.texi
70766         (get_current_dir_name): Likewise.
70767         * doc/glibc-functions/pthread_sigqueue.texi (pthread_sigqueue):
70768         Likewise.
70769         * doc/posix-functions/tcgetsid.texi (tcgetsid): Likewise, but with
70770         wrong return type.
70771         * doc/glibc-functions/scandirat.texi (scandirat): Added in cygwin
70772         1.7.11.
70774 2012-02-29  Bruno Haible  <bruno@clisp.org>
70776         Tests for module 'hypotf'.
70777         * modules/hypotf-tests: New file.
70778         * tests/test-hypotf.c: New file.
70780         New module 'hypotf'.
70781         * lib/math.in.h (hypotf): New declaration.
70782         * lib/hypotf.c: New file.
70783         * m4/hypotf.m4: New file.
70784         * m4/math_h.m4 (gl_MATH_H): Test whether hypotf is declared.
70785         (gl_MATH_H_DEFAULTS): Initialize GNULIB_HYPOTF, HAVE_HYPOTF,
70786         REPLACE_HYPOTF.
70787         * modules/math (Makefile.am): Substitute GNULIB_HYPOTF, HAVE_HYPOTF,
70788         REPLACE_HYPOTF.
70789         * modules/hypotf: New file.
70790         * tests/test-math-c++.cc: Check the hypotf declaration.
70791         * doc/posix-functions/hypotf.texi: Mention the new module.
70793         hypot: Prepare for hypotf module.
70794         * m4/hypot.m4: New file.
70795         * modules/hypot (Files): Add m4/hypot.m4.
70796         (configure.ac): Invoke gl_FUNC_HYPOT.
70798 2012-02-29  Bruno Haible  <bruno@clisp.org>
70800         hypot tests: More tests.
70801         * tests/test-hypot.c: Include <float.h>.
70802         (main): Add tests about overflow and underflow.
70804 2012-02-29  Bruno Haible  <bruno@clisp.org>
70806         math code: Add comments.
70807         * lib/acosl.c: Add comment about related glibc source files.
70808         * lib/asinl.c: Likewise.
70809         * lib/atanl.c: Likewise.
70810         * lib/expl.c: Likewise.
70811         * lib/logl.c: Likewise.
70812         * lib/sincosl.c: Likewise.
70813         * lib/sinl.c: Likewise.
70814         * lib/tanl.c: Likewise.
70815         * lib/trigl.c: Likewise.
70816         * lib/cosl.c: Likewise. Fix comments.
70818 2012-02-28  Bruno Haible  <bruno@clisp.org>
70820         math: Ensure HUGE_VAL, HUGE_VALF, HUGE_VALL are defined.
70821         * lib/math.in.h (HUGE_VAL, HUGE_VALF, HUGE_VALL): Define fallbacks.
70822         * tests/test-math.c: Include macros.h. Check that HUGE_VAL, HUGE_VALF,
70823         HUGE_VALL are defined.
70824         (numeric_equald): Renamed from numeric_equal.
70825         (numeric_equalf, numeric_equall): New functions.
70826         (main): Check also HUGE_VALF, HUGE_VALL.
70827         * modules/math-tests (Files): Add tests/macros.h.
70828         * doc/posix-headers/math.texi: Document the problems with HUGE_VALF and
70829         HUGE_VALL.
70831 2012-02-28  Bruno Haible  <bruno@clisp.org>
70833         doc: Move ISO C11 feature notes into POSIX chapters.
70834         * doc/posix-functions/aligned_alloc.texi: Renamed from
70835         doc/glibc-functions/aligned_alloc.texi.
70836         * doc/posix-functions/quick_exit.texi: Renamed from
70837         doc/glibc-functions/quick_exit.texi.
70838         * doc/posix-headers/uchar.texi: Renamed from
70839         doc/glibc-headers/uchar.texi.
70840         * doc/posix-functions/c16rtomb.texi: Renamed from
70841         doc/glibc-functions/c16rtomb.texi.
70842         * doc/posix-functions/c32rtomb.texi: Renamed from
70843         doc/glibc-functions/c32rtomb.texi.
70844         * doc/posix-functions/mbrtoc16.texi: Renamed from
70845         doc/glibc-functions/mbrtoc16.texi.
70846         * doc/posix-functions/mbrtoc32.texi: Renamed from
70847         doc/glibc-functions/mbrtoc32.texi.
70848         * doc/gnulib.texi: Update.
70849         (Glibc uchar.h): Remove section.
70850         Suggested by Eric Blake.
70852 2012-02-29  Paul Eggert  <eggert@cs.ucla.edu>
70854         stdnoreturn: port to MSVC better
70855         MSVC standard headers use __declspec(noreturn), so #define noreturn
70856         to empty on that platform.  Reported by Bruno Haible in
70857         <http://lists.gnu.org/r/bug-gnulib/2012-02/msg00152.html>.
70858         * lib/stdnoreturn.in.h (noreturn): Define to empty on MSVC.
70859         * doc/posix-headers/stdnoreturn.texi (stdnoreturn.h): Document this.
70861 2012-02-28  Bruno Haible  <bruno@clisp.org>
70863         doc: Mention new glibc headers and functions.
70864         * doc/glibc-headers/uchar.texi: New file.
70865         * doc/glibc-functions/aligned_alloc.texi: New file.
70866         * doc/glibc-functions/c16rtomb.texi: New file.
70867         * doc/glibc-functions/c32rtomb.texi: New file.
70868         * doc/glibc-functions/clock_adjtime.texi: New file.
70869         * doc/glibc-functions/fanotify_init.texi: New file.
70870         * doc/glibc-functions/fanotify_mark.texi: New file.
70871         * doc/glibc-functions/inet6_opt_append.texi: New file.
70872         * doc/glibc-functions/inet6_opt_find.texi: New file.
70873         * doc/glibc-functions/inet6_opt_finish.texi: New file.
70874         * doc/glibc-functions/inet6_opt_get_val.texi: New file.
70875         * doc/glibc-functions/inet6_opt_init.texi: New file.
70876         * doc/glibc-functions/inet6_opt_next.texi: New file.
70877         * doc/glibc-functions/inet6_opt_set_val.texi: New file.
70878         * doc/glibc-functions/inet6_rth_add.texi: New file.
70879         * doc/glibc-functions/inet6_rth_getaddr.texi: New file.
70880         * doc/glibc-functions/inet6_rth_init.texi: New file.
70881         * doc/glibc-functions/inet6_rth_reverse.texi: New file.
70882         * doc/glibc-functions/inet6_rth_segments.texi: New file.
70883         * doc/glibc-functions/inet6_rth_space.texi: New file.
70884         * doc/glibc-functions/login.texi: New file.
70885         * doc/glibc-functions/mbrtoc16.texi: New file.
70886         * doc/glibc-functions/mbrtoc32.texi: New file.
70887         * doc/glibc-functions/name_to_handle_at.texi: New file.
70888         * doc/glibc-functions/ntp_gettimex.texi: New file.
70889         * doc/glibc-functions/open_by_handle_at.texi: New file.
70890         * doc/glibc-functions/prlimit.texi: New file.
70891         * doc/glibc-functions/process_vm_readv.texi: New file.
70892         * doc/glibc-functions/process_vm_writev.texi: New file.
70893         * doc/glibc-functions/recvmmsg.texi: New file.
70894         * doc/glibc-functions/scandirat.texi: New file.
70895         * doc/glibc-functions/sendmmsg.texi: New file.
70896         * doc/glibc-functions/setns.texi: New file.
70897         * doc/glibc-functions/timespec_get.texi: New file.
70898         * doc/gnulib.texi: Include them.
70899         (Glibc sys/fanotify.h, Glibc sys/resource.h, Glibc uchar.h): New
70900         sections.
70901         Reported by Eric Blake.
70903 2012-02-28  Bruno Haible  <bruno@clisp.org>
70905         Avoid compilation errors with MSVC option -fp:strict.
70906         * lib/floor.c: Use MSVC specific pragma fenv_access.
70907         * lib/ceil.c: Likewise.
70908         * lib/trunc.c: Likewise.
70909         * lib/round.c: Likewise.
70910         * lib/rint.c: Likewise.
70911         * lib/fma.c: Likewise.
70912         * lib/integer_length.c: Likewise.
70913         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
70914         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
70915         * tests/test-floor2.c: Likewise.
70916         * tests/test-floorf2.c: Likewise.
70917         * tests/test-ceil2.c: Likewise.
70918         * tests/test-ceilf2.c: Likewise.
70919         * tests/test-trunc2.c: Likewise.
70920         * tests/test-truncf2.c: Likewise.
70921         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
70923 2012-02-27  Bruno Haible  <bruno@clisp.org>
70925         Tests for module 'sqrtl-ieee'.
70926         * modules/sqrtl-ieee-tests: New file.
70927         * tests/test-sqrtl-ieee.c: New file.
70929         New module 'sqrtl-ieee'.
70930         * modules/sqrtl-ieee: New file.
70932         Tests for module 'sqrt-ieee'.
70933         * modules/sqrt-ieee-tests: New file.
70934         * tests/test-sqrt-ieee.c: New file.
70936         New module 'sqrt-ieee'.
70937         * modules/sqrt-ieee: New file.
70939         Tests for module 'sqrtf-ieee'.
70940         * modules/sqrtf-ieee-tests: New file.
70941         * tests/test-sqrtf-ieee.c: New file.
70942         * tests/test-sqrt-ieee.h: New file.
70944         New module 'sqrtf-ieee'.
70945         * modules/sqrtf-ieee: New file.
70947 2012-02-27  Bruno Haible  <bruno@clisp.org>
70949         remainderl-ieee: Work around test failure on OSF/1.
70950         * m4/remainderl-ieee.m4: New file.
70951         * m4/remainderl.m4 (gl_FUNC_REMAINDERL): If gl_FUNC_REMAINDERL_IEEE is
70952         present, test whether remainderl works with a zero second argument.
70953         Replace it if not.
70954         * lib/math.in.h (remainderl): Override if REPLACE_REMAINDERL is 1.
70955         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_REMAINDERL.
70956         * modules/math (Makefile.am): Substitute REPLACE_REMAINDERL.
70957         * modules/remainderl (configure.ac): Consider REPLACE_REMAINDERL.
70958         (Depends-on): Update conditions.
70959         * modules/remainderl-ieee (Files): Add m4/remainderl-ieee.m4.
70960         (Depends-on): Add remainder-ieee.
70961         (configure.ac): Invoke gl_FUNC_REMAINDERL_IEEE.
70962         * doc/posix-functions/remainderl.texi: Mention the remainderl-ieee
70963         module.
70965         remainderf-ieee: Work around test failure on OSF/1.
70966         * m4/remainderf-ieee.m4: New file.
70967         * m4/remainderf.m4 (gl_FUNC_REMAINDERF): If gl_FUNC_REMAINDERF_IEEE is
70968         present, test whether remainderf works with a zero second argument.
70969         Replace it if not.
70970         * lib/math.in.h (remainderf): Override if REPLACE_REMAINDERF is 1.
70971         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_REMAINDERF.
70972         * modules/math (Makefile.am): Substitute REPLACE_REMAINDERF.
70973         * modules/remainderf (configure.ac): Consider REPLACE_REMAINDERF.
70974         (Depends-on): Update conditions.
70975         * modules/remainderf-ieee (Files): Add m4/remainderf-ieee.m4.
70976         (Depends-on): Add remainder-ieee.
70977         (configure.ac): Invoke gl_FUNC_REMAINDERF_IEEE.
70978         * doc/posix-functions/remainderf.texi: Mention the remainderf-ieee
70979         module.
70981         remainder-ieee: Work around test failure on OSF/1.
70982         * m4/remainder-ieee.m4: New file.
70983         * m4/remainder.m4 (gl_FUNC_REMAINDER): If gl_FUNC_REMAINDER_IEEE is
70984         present, test whether remainder works with a zero second argument.
70985         Replace it if not.
70986         * lib/math.in.h (remainder): Override if REPLACE_REMAINDER is 1.
70987         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_REMAINDER.
70988         * modules/math (Makefile.am): Substitute REPLACE_REMAINDER.
70989         * modules/remainder (configure.ac): Consider REPLACE_REMAINDER.
70990         (Depends-on): Update dependencies.
70991         * modules/remainder-ieee (Files): Add m4/remainder-ieee.m4.
70992         (configure.ac): Invoke gl_FUNC_REMAINDER_IEEE.
70993         * doc/posix-functions/remainder.texi: Mention the remainder-ieee module.
70995         Tests for module 'remainderl-ieee'.
70996         * modules/remainderl-ieee-tests: New file.
70997         * tests/test-remainderl-ieee.c: New file.
70999         New module 'remainderl-ieee'.
71000         * modules/remainderl-ieee: New file.
71002         Tests for module 'remainder-ieee'.
71003         * modules/remainder-ieee-tests: New file.
71004         * tests/test-remainder-ieee.c: New file.
71006         New module 'remainder-ieee'.
71007         * modules/remainder-ieee: New file.
71009         Tests for module 'remainderf-ieee'.
71010         * modules/remainderf-ieee-tests: New file.
71011         * tests/test-remainderf-ieee.c: New file.
71012         * tests/test-remainder-ieee.h: New file.
71014         New module 'remainderf-ieee'.
71015         * modules/remainderf-ieee: New file.
71017 2012-02-27  Bruno Haible  <bruno@clisp.org>
71019         modff, modfl: Fix configure syntax error.
71020         * m4/modff.m4 (gl_FUNC_MODFF): Insert ':' command in 'if'.
71021         * m4/modfl.m4 (gl_FUNC_MODFL): Likewise.
71023 2012-02-27  Bruno Haible  <bruno@clisp.org>
71025         fmodl-ieee: Work around test failures on OSF/1, MSVC 9.
71026         * m4/fmodl-ieee.m4: New file.
71027         * m4/fmodl.m4 (gl_FUNC_FMODL): If gl_FUNC_FMODL_IEEE is present, test
71028         whether fmodl works with zero arguments. Replace it if not.
71029         * modules/fmodl-ieee (Files): Add m4/fmodl-ieee.m4.
71030         (Depends-on): Add fmod-ieee.
71031         (configure.ac): Invoke gl_FUNC_FMODL_IEEE.
71032         * doc/posix-functions/fmodl.texi: Mention the fmodl-ieee module.
71034         fmodf-ieee: Work around test failure on OSF/1.
71035         * m4/fmodf-ieee.m4: New file.
71036         * m4/fmodf.m4 (gl_FUNC_FMODF): If gl_FUNC_FMODF_IEEE is present, test
71037         whether fmodf works with zero arguments. Replace it if not.
71038         * lib/math.in.h (fmodf): Override if REPLACE_FMODF is 1.
71039         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FMODF.
71040         * modules/math (Makefile.am): Substitute REPLACE_FMODF.
71041         * modules/fmodf (configure.ac): Consider REPLACE_FMODF.
71042         (Depends-on): Update dependencies.
71043         * modules/fmodf-ieee (Files): Add m4/fmodf-ieee.m4.
71044         (configure.ac): Invoke gl_FUNC_FMODF_IEEE.
71045         * doc/posix-functions/fmodf.texi: Mention the problem on OSF/1.
71047         fmodf-ieee: Work around test failure on MSVC 9.
71048         * modules/fmodf-ieee (Depends-on): Add fmod-ieee.
71049         * doc/posix-functions/fmodf.texi: Mention the fmodf-ieee module.
71051         fmod-ieee: Work around test failures on OSF/1, mingw.
71052         * m4/fmod-ieee.m4: New file.
71053         * m4/fmod.m4 (gl_FUNC_FMOD): If gl_FUNC_FMOD_IEEE is present, test
71054         whether fmod works with zero arguments. Replace it if not.
71055         * lib/math.in.h (fmod): New declaration.
71056         * lib/fmod.c: New file.
71057         * m4/math_h.m4 (gl_MATH_H): Test whether fmod is declared.
71058         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMOD, REPLACE_FMOD.
71059         * modules/math (Makefile.am): Substitute GNULIB_FMOD, REPLACE_FMOD.
71060         * modules/fmod (Files): Add lib/fmod.c.
71061         (Depends-on): Add math, isinf, trunc, fma.
71062         (configure.ac): Arrange to compile lib/fmod.c if needed.
71063         * modules/fmod-ieee (Files): Add m4/fmod-ieee.m4, m4/minus-zero.m4,
71064         m4/signbit.m4.
71065         (configure.ac): Invoke gl_FUNC_FMOD_IEEE.
71066         * tests/test-math-c++.cc: Check the declaration of fmod.
71067         * doc/posix-functions/fmod.texi: Mention the fmod-ieee module.
71069         fmodl-ieee: Fix test failures.
71070         * lib/fmodl.c (fmodl): Treat Inf specially.
71071         * modules/fmodl (Depends-on): Add isinf.
71073         Tests for module 'fmodl-ieee'.
71074         * modules/fmodl-ieee-tests: New file.
71075         * tests/test-fmodl-ieee.c: New file.
71077         New module 'fmodl-ieee'.
71078         * modules/fmodl-ieee: New file.
71080         Tests for module 'fmod-ieee'.
71081         * modules/fmod-ieee-tests: New file.
71082         * tests/test-fmod-ieee.c: New file.
71084         New module 'fmod-ieee'.
71085         * modules/fmod-ieee: New file.
71087         Tests for module 'fmodf-ieee'.
71088         * modules/fmodf-ieee-tests: New file.
71089         * tests/test-fmodf-ieee.c: New file.
71090         * tests/test-fmod-ieee.h: New file.
71092         New module 'fmodf-ieee'.
71093         * modules/fmodf-ieee: New file.
71095 2012-02-27  Bruno Haible  <bruno@clisp.org>
71097         Tests for module 'rintl-ieee'.
71098         * modules/rintl-ieee-tests: New file.
71099         * tests/test-rintl-ieee.c: New file.
71101         New module 'rintl-ieee'.
71102         * modules/rintl-ieee: New file.
71104         Tests for module 'rint-ieee'.
71105         * modules/rint-ieee-tests: New file.
71106         * tests/test-rint-ieee.c: New file.
71108         New module 'rint-ieee'.
71109         * modules/rint-ieee: New file.
71111         Tests for module 'rintf-ieee'.
71112         * modules/rintf-ieee-tests: New file.
71113         * tests/test-rintf-ieee.c: New file.
71114         * tests/test-rint-ieee.h: New file.
71116         New module 'rintf-ieee'.
71117         * modules/rintf-ieee: New file.
71119 2012-02-26  Paul Eggert  <eggert@cs.ucla.edu>
71121         regex: re_search etc. should return -2 when memory exhausted
71122         This bug was uncovered when testing 'grep'.  Without the fix,
71123         re_search and friends return -1 when memory is exhausted, but -1
71124         means no match, and this causes grep to falsely report no-match
71125         instead of memory-exhaustion.  See
71126         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=13762>.
71127         * lib/regexec.c (re_search_stub): Return -2 (not -1) if there is
71128         trouble; this can occur if re_search_internal ran out of memory.
71130 2012-02-26  Bruno Haible  <bruno@clisp.org>
71132         modfl-ieee: Work around test failures on IRIX, OSF/1, mingw.
71133         * m4/modfl-ieee.m4: New file.
71134         * m4/modfl.m4 (gl_FUNC_MODFL): If gl_FUNC_MODFL_IEEE is present, test
71135         whether modfl works with Inf. Replace it if not.
71136         * lib/math.in.h (modfl): Override if REPLACE_MODFF is 1.
71137         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_MODFL.
71138         * modules/math (Makefile.am): Substitute REPLACE_MODFL.
71139         * modules/modfl (configure.ac): Consider REPLACE_MODFL.
71140         (Depends-on): Update dependencies.
71141         * modules/modfl-ieee (Files): Add m4/modfl-ieee.m4, m4/minus-zero.m4,
71142         m4/signbit.m4.
71143         (configure.ac): Invoke gl_FUNC_MODFL_IEEE.
71144         * doc/posix-functions/modfl.texi: Mention the modfl-ieee module.
71146         modfl-ieee: Fix dependencies.
71147         * modules/modfl-ieee (Depends-on): Add modf-ieee.
71149         modfl-ieee: Fix test failures.
71150         * lib/modfl.c (modfl): Treat NaN and Inf specially.
71151         * modules/modfl (Depends-on): Add isfinite, isinf.
71153         modff-ieee: Work around test failures on *BSD, IRIX, OSF/1, etc.
71154         * m4/modff-ieee.m4: New file.
71155         * m4/modff.m4 (gl_FUNC_MODFF): If gl_FUNC_MODFF_IEEE is present, test
71156         whether modff works with NaN and Inf. Replace it if not.
71157         * lib/math.in.h (modff): Override if REPLACE_MODFF is 1.
71158         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_MODFF.
71159         * modules/math (Makefile.am): Substitute REPLACE_MODFF.
71160         * modules/modff (configure.ac): Consider REPLACE_MODFF.
71161         (Depends-on): Update dependencies.
71162         * modules/modff-ieee (Files): Add m4/modff-ieee.m4, m4/minus-zero.m4,
71163         m4/signbit.m4.
71164         (Depends-on): Add modf-ieee.
71165         (configure.ac): Invoke gl_FUNC_MODFF_IEEE.
71166         * doc/posix-functions/modff.texi: Mention the modff-ieee module.
71168         modf-ieee: Work around test failures on *BSD, IRIX, OSF/1, Cygwin.
71169         * m4/modf-ieee.m4: New file.
71170         * m4/modf.m4 (gl_FUNC_MODF): If gl_FUNC_MODF_IEEE is present, test
71171         whether modf works with NaN and Inf. Replace it if not.
71172         * lib/math.in.h (modf): New declaration.
71173         * lib/modf.c: New file.
71174         * m4/math_h.m4 (gl_MATH_H): Test whether modf is declared.
71175         (gl_MATH_H_DEFAULTS): Initialize GNULIB_MODF, REPLACE_MODF.
71176         * modules/math (Makefile.am): Substitute GNULIB_MODF, REPLACE_MODF.
71177         * modules/modf (Files): Add lib/modf.c.
71178         (Depends-on): Add math, isfinite, trunc, isinf.
71179         (configure.ac): Addrange to compile lib/modf.c if needed.
71180         * modules/modf-ieee (Files): Add m4/modf-ieee.m4, m4/minus-zero.m4,
71181         m4/signbit.m4.
71182         (configure.ac): Invoke gl_FUNC_MODF_IEEE.
71183         * tests/test-math-c++.cc: Check the declaration of modf.
71184         * doc/posix-functions/modf.texi: Mention the modf-ieee module.
71186         Tests for module 'modfl-ieee'.
71187         * modules/modfl-ieee-tests: New file.
71188         * tests/test-modfl-ieee.c: New file.
71190         New module 'modfl-ieee'.
71191         * modules/modfl-ieee: New file.
71193         Tests for module 'modf-ieee'.
71194         * modules/modf-ieee-tests: New file.
71195         * tests/test-modf-ieee.c: New file.
71197         New module 'modf-ieee'.
71198         * modules/modf-ieee: New file.
71200         Tests for module 'modff-ieee'.
71201         * modules/modff-ieee-tests: New file.
71202         * tests/test-modff-ieee.c: New file.
71203         * tests/test-modf-ieee.h: New file.
71205         New module 'modff-ieee'.
71206         * modules/modff-ieee: New file.
71208 2012-02-26  Bruno Haible  <bruno@clisp.org>
71210         Tests for module 'fabsl-ieee'.
71211         * modules/fabsl-ieee-tests: New file.
71212         * tests/test-fabsl-ieee.c: New file.
71214         New module 'fabsl-ieee'.
71215         * modules/fabsl-ieee: New file.
71217         Tests for module 'fabs-ieee'.
71218         * modules/fabs-ieee-tests: New file.
71219         * tests/test-fabs-ieee.c: New file.
71221         New module 'fabs-ieee'.
71222         * modules/fabs-ieee: New file.
71224         Tests for module 'fabsf-ieee'.
71225         * modules/fabsf-ieee-tests: New file.
71226         * tests/test-fabsf-ieee.c: New file.
71227         * tests/test-fabs-ieee.h: New file.
71229         New module 'fabsf-ieee'.
71230         * modules/fabsf-ieee: New file.
71232 2012-02-26  Bruno Haible  <bruno@clisp.org>
71234         Tests for module 'fmal-ieee'.
71235         * modules/fmal-ieee-tests: New file.
71236         * tests/test-fmal-ieee.c: New file.
71238         New module 'fmal-ieee'.
71239         * modules/fmal-ieee: New file.
71241         Tests for module 'fma-ieee'.
71242         * modules/fma-ieee-tests: New file.
71243         * tests/test-fma-ieee.c: New file.
71245         New module 'fma-ieee'.
71246         * modules/fma-ieee: New file.
71248         Tests for module 'fmaf-ieee'.
71249         * modules/fmaf-ieee-tests: New file.
71250         * tests/test-fmaf-ieee.c: New file.
71251         * tests/test-fma-ieee.h: New file.
71253         New module 'fmaf-ieee'.
71254         * modules/fmaf-ieee: New file.
71256 2012-02-26  Bruno Haible  <bruno@clisp.org>
71258         Tests for module 'ldexpl-ieee'.
71259         * modules/ldexpl-ieee-tests: New file.
71260         * tests/test-ldexpl-ieee.c: New file.
71262         New module 'ldexpl-ieee'.
71263         * modules/ldexpl-ieee: New file.
71265         Tests for module 'ldexp-ieee'.
71266         * modules/ldexp-ieee-tests: New file.
71267         * tests/test-ldexp-ieee.c: New file.
71269         New module 'ldexp-ieee'.
71270         * modules/ldexp-ieee: New file.
71272         Tests for module 'ldexpf-ieee'.
71273         * modules/ldexpf-ieee-tests: New file.
71274         * tests/test-ldexpf-ieee.c: New file.
71275         * tests/test-ldexp-ieee.h: New file.
71277         New module 'ldexpf-ieee'.
71278         * modules/ldexpf-ieee: New file.
71280 2012-02-26  Bruno Haible  <bruno@clisp.org>
71282         Refactor frexp*-ieee tests.
71283         * tests/test-frexp-ieee.h: New file.
71284         * tests/test-frexpf-ieee.c: Include test-frexp-ieee.h.
71285         (main): Just call test_function.
71286         * tests/test-frexp-ieee.c: Include test-frexp-ieee.h.
71287         (main): Just call test_function.
71288         * tests/test-frexpl-ieee.c: Include test-frexp-ieee.h.
71289         (main): Just call test_function.
71290         * modules/frexpf-ieee-tests (Files): Add tests/test-frexp-ieee.h.
71291         * modules/frexp-ieee-tests (Files): Likewise.
71292         * modules/frexpl-ieee-tests (Files): Likewise.
71294         Tests for module 'frexpl-ieee'.
71295         * modules/frexpl-ieee-tests: New file.
71296         * tests/test-frexpl-ieee.c: New file.
71298         New module 'frexpl-ieee'.
71299         * modules/frexpl-ieee: New file.
71301         Tests for module 'frexp-ieee'.
71302         * modules/frexp-ieee-tests: New file.
71303         * tests/test-frexp-ieee.c: New file.
71305         New module 'frexp-ieee'.
71306         * modules/frexp-ieee: New file.
71308         Tests for module 'frexpf-ieee'.
71309         * modules/frexpf-ieee-tests: New file.
71310         * tests/test-frexpf-ieee.c: New file.
71312         New module 'frexpf-ieee'.
71313         * modules/frexpf-ieee: New file.
71315 2012-02-26  Bruno Haible  <bruno@clisp.org>
71317         roundl-ieee tests: More tests.
71318         * tests/test-roundl-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
71319         (main): Add tests for [MX] shaded specification in POSIX.
71320         * modules/roundl-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71321         (Depends-on): Add isnanl-nolibm.
71323         round-ieee tests: More tests.
71324         * tests/test-round-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
71325         (main): Add tests for [MX] shaded specification in POSIX.
71326         * modules/round-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71327         (Depends-on): Add isnand-nolibm.
71329         roundf-ieee tests: More tests.
71330         * tests/test-roundf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
71331         (main): Add tests for [MX] shaded specification in POSIX.
71332         * modules/roundf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71333         (Depends-on): Add isnanf-nolibm.
71335         truncl-ieee tests: More tests.
71336         * tests/test-truncl-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
71337         (main): Add tests for [MX] shaded specification in POSIX.
71338         * modules/truncl-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71339         (Depends-on): Add isnanl-nolibm.
71341         trunc-ieee tests: More tests.
71342         * tests/test-trunc-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
71343         (main): Add tests for [MX] shaded specification in POSIX.
71344         * modules/trunc-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71345         (Depends-on): Add isnand-nolibm.
71347         truncf-ieee tests: More tests.
71348         * tests/test-truncf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
71349         (main): Add tests for [MX] shaded specification in POSIX.
71350         * modules/truncf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71351         (Depends-on): Add isnanf-nolibm.
71353         ceill-ieee tests: More tests.
71354         * tests/test-ceill-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
71355         (main): Add tests for [MX] shaded specification in POSIX.
71356         * modules/ceill-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71357         (Depends-on): Add isnanl-nolibm.
71359         ceil-ieee tests: More tests.
71360         * tests/test-ceil-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
71361         (main): Add tests for [MX] shaded specification in POSIX.
71362         * modules/ceil-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71363         (Depends-on): Add isnand-nolibm.
71365         ceilf-ieee tests: More tests.
71366         * tests/test-ceilf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
71367         (main): Add tests for [MX] shaded specification in POSIX.
71368         * modules/ceilf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71369         (Depends-on): Add isnanf-nolibm.
71371         floorl-ieee tests: More tests.
71372         * tests/test-floorl-ieee.c: Include isnanl-nolibm.h, infinity.h, nan.h.
71373         (main): Add tests for [MX] shaded specification in POSIX.
71374         * modules/floorl-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71375         (Depends-on): Add isnanl-nolibm.
71377         floor-ieee tests: More tests.
71378         * tests/test-floor-ieee.c: Include isnand-nolibm.h, infinity.h, nan.h.
71379         (main): Add tests for [MX] shaded specification in POSIX.
71380         * modules/floor-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71381         (Depends-on): Add isnand-nolibm.
71383         floorf-ieee tests: More tests.
71384         * tests/test-floorf-ieee.c: Include isnanf-nolibm.h, infinity.h, nan.h.
71385         (main): Add tests for [MX] shaded specification in POSIX.
71386         * modules/floorf-ieee-tests (Files): Add tests/infinity.h, tests/nan.h.
71387         (Depends-on): Add isnanf-nolibm.
71389 2012-02-26  Bruno Haible  <bruno@clisp.org>
71391         fpieee: More comments.
71392         * m4/fpieee.m4 (gl_FP_IEEE): Add more comments.
71394 2012-02-25  Bruno Haible  <bruno@clisp.org>
71396         Tests for module 'log10l'.
71397         * modules/log10l-tests: New file.
71398         * tests/test-log10l.c: New file.
71399         * tests/test-math-c++.cc: Check the declaration of log10l.
71401         New module 'log10l'.
71402         * lib/math.in.h (log10l): New declaration.
71403         * lib/log10l.c: New file.
71404         * m4/log10l.m4: New file.
71405         * modules/log10l: New file.
71406         * m4/math_h.m4 (gl_MATH_H): Test whether log10l is declared.
71407         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG10L, HAVE_LOG10L,
71408         HAVE_DECL_LOG10L.
71409         * modules/math (Makefile.am): Substitute GNULIB_LOG10L, HAVE_LOG10L,
71410         HAVE_DECL_LOG10L.
71411         * doc/posix-functions/log10l.texi: Mention the new module.
71413 2012-02-25  Bruno Haible  <bruno@clisp.org>
71415         fmodl, remainder*: Avoid wrong results due to rounding errors.
71416         * lib/fmodl.c (fmodl): Correct the result if it is not within the
71417         expected bounds.
71418         * lib/remainderf.c (remainderf): Likewise.
71419         * lib/remainder.c (remainder): Likewise.
71420         * lib/remainderl.c (remainderl): Likewise.
71422 2012-02-25  Bruno Haible  <bruno@clisp.org>
71424         Tests for module 'remainderl'.
71425         * modules/remainderl-tests: New file.
71426         * tests/test-remainderl.c: New file.
71427         * tests/test-math-c++.cc: Check the declaration of remainderl.
71429         New module 'remainderl'.
71430         * lib/math.in.h (remainderl): New declaration.
71431         * lib/remainderl.c: New file.
71432         * m4/remainderl.m4: New file.
71433         * modules/remainderl: New file.
71434         * m4/math_h.m4 (gl_MATH_H): Test whether remainderl is declared.
71435         (gl_MATH_H_DEFAULTS): Initialize GNULIB_REMAINDERL, HAVE_REMAINDERL.
71436         * modules/math (Makefile.am): Substitute GNULIB_REMAINDERL,
71437         HAVE_REMAINDERL.
71438         * doc/posix-functions/remainderl.texi: Mention the new module.
71440 2012-02-25  Bruno Haible  <bruno@clisp.org>
71442         Tests for module 'remainderf'.
71443         * modules/remainderf-tests: New file.
71444         * tests/test-remainderf.c: New file.
71445         * tests/test-math-c++.cc: Check the declaration of remainderf.
71447         New module 'remainderf'.
71448         * lib/math.in.h (remainderf): New declaration.
71449         * lib/remainderf.c: New file.
71450         * m4/remainderf.m4: New file.
71451         * modules/remainderf: New file.
71452         * m4/math_h.m4 (gl_MATH_H): Test whether remainderf is declared.
71453         (gl_MATH_H_DEFAULTS): Initialize GNULIB_REMAINDERF, HAVE_REMAINDERF.
71454         * modules/math (Makefile.am): Substitute GNULIB_REMAINDERF,
71455         HAVE_REMAINDERF.
71456         * doc/posix-functions/remainderf.texi: Mention the new module.
71458 2012-02-25  Bruno Haible  <bruno@clisp.org>
71460         remainder: Support for MSVC.
71461         * lib/math.in.h (remainder): New declaration.
71462         * lib/remainder.c: New file.
71463         * m4/remainder.m4: New file.
71464         * modules/remainder (Files): Add lib/remainder.c, m4/remainder.m4.
71465         (Depends-on): Add math, round, fma.
71466         (configure.ac): Use results of gl_FUNC_REMAINDER.
71467         * m4/math_h.m4 (gl_MATH_H): Test whether remainder is declared.
71468         (gl_MATH_H_DEFAULTS): Initialize GNULIB_REMAINDER, HAVE_REMAINDER,
71469         HAVE_DECL_REMAINDER.
71470         * modules/math (Makefile.am): Substitute GNULIB_REMAINDER,
71471         HAVE_REMAINDER, HAVE_DECL_REMAINDER.
71472         * tests/test-math-c++.cc: Check the declaration of remainder.
71473         * doc/posix-functions/remainder.texi: Mention that the MSVC and IRIX 5
71474         problems are fixed.
71476 2012-02-25  Bruno Haible  <bruno@clisp.org>
71478         Tests for module 'fmodl'.
71479         * modules/fmodl-tests: New file.
71480         * tests/test-fmodl.c: New file.
71481         * tests/test-math-c++.cc: Check the declaration of fmodl.
71483         New module 'fmodl'.
71484         * lib/math.in.h (fmodl): New declaration.
71485         * lib/fmodl.c: New file.
71486         * m4/fmodl.m4: New file.
71487         * m4/math_h.m4 (gl_MATH_H): Test whether fmodl is declared.
71488         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMODL, HAVE_FMODL,
71489         REPLACE_FMODL.
71490         * modules/math (Makefile.am): Substitute GNULIB_FMODL, HAVE_FMODL,
71491         REPLACE_FMODL.
71492         * modules/fmodl: New file.
71493         * doc/posix-functions/fmodl.texi: Mention the new module.
71495 2012-02-25  Bruno Haible  <bruno@clisp.org>
71497         Tests for module 'modfl'.
71498         * modules/modfl-tests: New file.
71499         * tests/test-modfl.c: New file.
71500         * tests/test-math-c++.cc: Check the declaration of modfl.
71502         New module 'modfl'.
71503         * lib/math.in.h (modfl): New declaration.
71504         * lib/modfl.c: New file.
71505         * m4/modfl.m4: New file.
71506         * m4/math_h.m4 (gl_MATH_H): Test whether modfl is declared.
71507         (gl_MATH_H_DEFAULTS): Initialize GNULIB_MODFL, HAVE_MODFL.
71508         * modules/math (Makefile.am): Substitute GNULIB_MODFL, HAVE_MODFL.
71509         * modules/modfl: New file.
71510         * doc/posix-functions/modfl.texi: Mention the new module.
71512 2012-02-25  Bruno Haible  <bruno@clisp.org>
71514         Tests for module 'fabsl'.
71515         * modules/fabsl-tests: New file.
71516         * tests/test-fabsl.c: New file.
71517         * tests/test-math-c++.cc: Check the declaration of fabsl.
71519         New module 'fabsl'.
71520         * lib/math.in.h (fabsl): New declaration.
71521         * lib/fabsl.c: New file.
71522         * m4/fabsl.m4: New file.
71523         * m4/math_h.m4 (gl_MATH_H): Test whether fabsl is declared.
71524         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FABSL, HAVE_FABSL,
71525         REPLACE_FABSL.
71526         * modules/math (Makefile.am): Substitute GNULIB_FABSL, HAVE_FABSL,
71527         REPLACE_FABSL.
71528         * modules/fabsl: New file.
71529         * doc/posix-functions/fabsl.texi: Mention the new module.
71531 2012-02-25  Bruno Haible  <bruno@clisp.org>
71533         fabs tests: More tests.
71534         * tests/test-fabs.c: Include <string.h>, minus-zero.h.
71535         (zero): New variable.
71536         (main): Add tests for signed zero.
71537         * modules/fabs-tests (Files): Add tests/minus-zero.h.
71539         fabsf tests: More tests.
71540         * tests/test-fabsf.c: Include <string.h>, minus-zero.h.
71541         (zero): New variable.
71542         (main): Add tests for signed zero.
71543         * modules/fabsf-tests (Files): Add tests/minus-zero.h.
71545 2012-02-24  Bruno Haible  <bruno@clisp.org>
71547         atanl: Provide function definition on MSVC.
71548         * m4/atanl.m4 (gl_FUNC_ATANL): Test also whether atanl can be used as a
71549         function pointer.
71550         * lib/math.in.h (atanl): Undefine if it does not exist as a function.
71552 2012-02-24  Bruno Haible  <bruno@clisp.org>
71554         acosl: Provide function definition on MSVC.
71555         * m4/acosl.m4 (gl_FUNC_ACOSL): Test also whether acosl can be used as a
71556         function pointer.
71557         * lib/math.in.h (acosl): Undefine if it does not exist as a function.
71559 2012-02-24  Bruno Haible  <bruno@clisp.org>
71561         asinl: Provide function definition on MSVC.
71562         * m4/asinl.m4 (gl_FUNC_ASINL): Test also whether asinl can be used as a
71563         function pointer.
71564         * lib/math.in.h (asinl): Undefine if it does not exist as a function.
71566 2012-02-24  Bruno Haible  <bruno@clisp.org>
71568         tanl: Provide function definition on MSVC.
71569         * m4/tanl.m4 (gl_FUNC_TANL): Test also whether tanl can be used as a
71570         function pointer.
71571         * lib/math.in.h (tanl): Undefine if it does not exist as a function.
71573 2012-02-24  Bruno Haible  <bruno@clisp.org>
71575         cosl: Provide function definition on MSVC.
71576         * m4/cosl.m4 (gl_FUNC_COSL): Test also whether cosl can be used as a
71577         function pointer.
71578         * lib/math.in.h (cosl): Undefine if it does not exist as a function.
71580 2012-02-24  Bruno Haible  <bruno@clisp.org>
71582         sinl: Provide function definition on MSVC.
71583         * m4/sinl.m4 (gl_FUNC_SINL): Test also whether sinl can be used as a
71584         function pointer.
71585         * lib/math.in.h (sinl): Undefine if it does not exist as a function.
71587 2012-02-24  Bruno Haible  <bruno@clisp.org>
71589         logl: Provide function definition on MSVC.
71590         * m4/logl.m4 (gl_FUNC_LOGL): Test also whether logl can be used as a
71591         function pointer.
71592         * lib/math.in.h (logl): Undefine if it does not exist as a function.
71594 2012-02-24  Bruno Haible  <bruno@clisp.org>
71596         expl: Provide function definition on MSVC.
71597         * m4/expl.m4 (gl_FUNC_EXPL): Test also whether expl can be used as a
71598         function pointer.
71599         * lib/math.in.h (expl): Undefine if it does not exist as a function.
71601 2012-02-24  Bruno Haible  <bruno@clisp.org>
71603         sqrtl: Provide function definition on MSVC.
71604         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Test also whether sqrtl can be used as
71605         a function pointer.
71606         * lib/math.in.h (sqrtl): Undefine if it does not exist as a function.
71608 2012-02-24  Bruno Haible  <bruno@clisp.org>
71610         ceill: Provide function definition on MSVC.
71611         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Test also whether ceill can be
71612         used as a function pointer.
71613         * lib/math.in.h (ceill): Undefine if it is not declared as a function.
71615 2012-02-24  Bruno Haible  <bruno@clisp.org>
71617         floorl: Provide function definition on MSVC.
71618         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Test also whether floorl can be
71619         used as a function pointer.
71620         * lib/math.in.h (floorl): Undefine if it is not declared as a function.
71622 2012-02-24  Bruno Haible  <bruno@clisp.org>
71624         ceilf: Provide function definition on MSVC.
71625         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Test also whether ceilf can be
71626         used as a function pointer.
71627         * lib/math.in.h (ceilf): Undefine if it is not declared as a function.
71629 2012-02-24  Bruno Haible  <bruno@clisp.org>
71631         floorf: Provide function definition on MSVC.
71632         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Test also whether floorf can be
71633         used as a function pointer.
71634         * lib/math.in.h (floorf): Undefine if it is not declared as a function.
71636 2012-02-24  Paul Eggert  <eggert@cs.ucla.edu>
71638         stdnoreturn: new module
71639         This implements a replacement for C11's <stdnoreturn.h>.
71640         * doc/gnulib.texi (Header File Substitutes): Add stdnoreturn.
71641         * doc/posix-headers/stdnoreturn.texi, lib/stdnoreturn.in.h:
71642         * m4/stdnoreturn.m4, modules/stdnoreturn, modules/stdnoreturn-tests:
71643         * tests/test-stdnoreturn.c: New files.
71645 2012-02-24  Stanislav Brabec  <sbrabec@suse.cz>  (tiny change)
71647         regex: fix false multibyte matches in some regular expressions
71648         See <http://sourceware.org/bugzilla/show_bug.cgi?id=13637>
71649         and <http://sourceware.org/ml/libc-alpha/2012-02/msg00521.html>.
71650         * lib/regex_internal.c (re_string_skip_chars):
71651         Fix miscomputation of remain_len that may cause incomplete
71652         multi-byte character and false match.
71654 2012-02-24  Jim Meyering  <meyering@redhat.com>
71656         maint.mk: tell sc_prohibit_strcmp to ding "0 == strcmp (...)", too
71657         * top/maint.mk (sc_prohibit_strcmp): Also prohibit uses of strcmp
71658         uses with "==" *before* the call, e.g., 0 == strcmp (...)
71659         Remove now-unnecessary str''cmp obfuscation.
71660         Suggested by Akim Demaille.
71662 2012-02-24  Bruno Haible  <bruno@clisp.org>
71664         streq: Rename macro.
71665         * lib/streq.h (STREQ_OPT): Renamed from STREQ.
71666         * NEWS: Mention the change.
71667         * lib/mbrtowc.c (mbrtowc): Update.
71668         * lib/uniwidth/cjk.h (is_cjk_encoding): Update.
71669         * lib/wcwidth.c (wcwidth): Update.
71670         Suggested by Akim Demaille and Jim Meyering.
71672 2012-02-20  Paul Eggert  <eggert@cs.ucla.edu>
71674         regex: fix typo in definition of MIN
71675         * lib/regex_internal.h (MIN): Fix typo.  Problem reported by Thomas
71676         Schwinge in <http://sourceware.org/bugzilla/show_bug.cgi?id=11638#c4>.
71678 2012-02-19  Paul Eggert  <eggert@cs.ucla.edu>
71679             Bruno Haible  <bruno@clisp.org>
71681         acl: Don't use ACL_CNT and similar ops, since they are unreliable.
71682         * lib/file-has-acl.c (file_has_acl) [HP-UX, NonStop Kernel]: Read the
71683         entries into a stack-allocated buffer directly.
71684         * lib/copy-acl.c (qcopy_acl) [HP-UX, NonStop Kernel]: Likewise.
71686 2012-02-19  Paul Eggert  <eggert@cs.ucla.edu>
71687             Bruno Haible  <bruno@clisp.org>
71689         acl: Don't use GETACLCNT and similar ops, since they are unreliable.
71691          - There were several instances of this pattern:
71693              for (;;) {
71694                n = acl (f, GETACLCNT, 0, NULL);
71695                [ allocate an array A of size N ]
71696                if (acl (f, GETACL, n, a) == n)
71697                  break;
71698              }
71700            This loop might never terminate if some other process is constantly
71701            manipulating the file's ACL.  The loop should be rewritten to
71702            terminate.
71704          - The acl (... GETACLNT ...) call is merely an optimization; its value
71705            is merely a hint as to how big to make the array.  A better
71706            optimization is to avoid the acl (... GETACLNT ...)  call entirely,
71707            and just guess a reasonably-big size, growing the size and trying
71708            again if it's not large enough.  This guarantees termination, and
71709            saves a system call.
71711         * lib/acl-internal.h: Include <limits.h>.
71712         (MIN, SIZE_MAX): New macros.
71713         * lib/file-has-acl.c (file_has_acl) [Solaris]: Read the entries into
71714         a stack-allocated buffer, and use malloc if it does not fit. Don't
71715         use GETACLCNT.
71716         * lib/set-mode-acl.c (qset_acl) [Solaris]: Likewise.
71718 2012-02-19  Bruno Haible  <bruno@clisp.org>
71720         acl: Fix endless loop on Solaris with vxfs.
71721         * lib/file-has-acl.c (file_has_acl) [Solaris]: Treat a failing
71722         acl()/facl() call for ACE_GETACL like a failing call for ACE_GETACLCNT.
71723         * lib/set-mode-acl.c (qset_acl) [Solaris]: Likewise.
71724         * lib/copy-acl.c (qcopy_acl)[Solaris]: Likewise.
71725         * tests/test-sameacls.c (main)[Solaris]: Likewise.
71726         Reported by Bill Jones in
71727         <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=10639>, via Paul Eggert.
71729 2012-02-19  Bruno Haible  <bruno@clisp.org>
71731         acl: Fix copy-acl test failure on Solaris 11.0.
71732         * lib/file-has-acl.c (NEW_ACE_WRITEA_DATA): New macro.
71733         (acl_ace_nontrivial): Relax the restrictions on access_masks[] so
71734         that this function returns 0 in some more cases.
71736 2012-02-19  Bruno Haible  <bruno@clisp.org>
71738         acl: Update doc references.
71739         * doc/acl-resources.txt: Update links to Solaris documentation.
71741 2012-02-19  Bruno Haible  <bruno@clisp.org>
71743         Fix test failure in many locales on Solaris 11.
71744         * tests/test-pipe-filter-gi1.c (main): Don't use range expression in
71745         'tr' arguments.
71746         * tests/test-pipe-filter-ii1.c (main): Likewise.
71747         * build-aux/bootstrap (check_versions): Run 'tr' command with range
71748         expressions in the C locale.
71749         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
71750         * m4/host-os.m4 (gl_HOST_OS): Likewise.
71752 2012-02-19  Bruno Haible  <bruno@clisp.org>
71754         gnulib-tool: Improve usage message.
71755         * gnulib-tool (func_usage): Move doc of --help and --version to the
71756         section "Operation modes".
71758 2012-02-18  Reuben Thomas  <rrt@sc3d.org>
71760         README-release: make it easier to execute commands
71761         * top/README-release: break commands out on to separate lines.
71763 2012-02-16  Stefano Lattarini  <stefano.lattarini@gmail.com>
71765         GNUmakefile: simplify detection of unconfigured trees
71766         * top/GNUmakefile: Use $(wildcard) instead of $(shell) to determine
71767         whether the tree make is being run from is already configured or
71768         not.  Related simplifications.
71770 2012-02-13  Simon Josefsson  <simon@josefsson.org>
71772         * gnulib-tool (func_usage): Document --help and --version.
71774 2012-02-11  Jim Meyering  <meyering@redhat.com>
71776         bootstrap: don't exit 0 upon gnulib-tool failure
71777         * build-aux/bootstrap (gnulib_tool): If gnulib-tool fails, exit with
71778         its exit status, not 0.
71780 2011-12-19  Reuben Thomas  <rrt@sc3d.org>
71782         README-release: various improvements
71783         * top/README-release: Give a command to push changes for the
71784         release.  Add "distcheck" to list of other pre-release checks.
71785         Fix instance of "make stable" which should be "make TYPE".
71787 2012-02-09  Paul Eggert  <eggert@cs.ucla.edu>
71789         maint: replace FSF snail-mail addresses with URLs
71790         * config/argz.mk, lib/accept4.c, lib/alignof.h, lib/alloca.in.h:
71791         * lib/alphasort.c, lib/arcfour.c, lib/arcfour.h, lib/arctwo.c:
71792         * lib/arctwo.h, lib/argz.c, lib/arpa_inet.in.h, lib/asnprintf.c:
71793         * lib/asprintf.c, lib/assert.in.h, lib/base32.c, lib/base32.h:
71794         * lib/base64.c, lib/base64.h, lib/c-ctype.c, lib/c-ctype.h:
71795         * lib/c-strcase.h, lib/c-strcasecmp.c, lib/c-strncasecmp.c:
71796         * lib/check-version.c, lib/check-version.h, lib/config.charset:
71797         * lib/ctype.in.h, lib/des.c, lib/des.h, lib/dup3.c, lib/errno.in.h:
71798         * lib/float+.h, lib/fnmatch.c, lib/fnmatch.in.h, lib/fnmatch_loop.c:
71799         * lib/fseeko.c, lib/gai_strerror.c, lib/gc-gnulib.c:
71800         * lib/gc-libgcrypt.c, lib/gc-pbkdf2-sha1.c, lib/gc.h:
71801         * lib/getaddrinfo.c, lib/getdelim.c, lib/getfilecon.c, lib/getline.c:
71802         * lib/getlogin_r.c, lib/getpass.c, lib/getpass.h, lib/gettext.h:
71803         * lib/gettimeofday.c, lib/glob.in.h, lib/glthread/cond.c:
71804         * lib/glthread/cond.h, lib/glthread/lock.c, lib/glthread/lock.h:
71805         * lib/glthread/thread.c, lib/glthread/thread.h:
71806         * lib/glthread/threadlib.c, lib/glthread/yield.h, lib/hmac-md5.c:
71807         * lib/hmac-sha1.c, lib/hmac.h, lib/iconv.c, lib/iconv.in.h:
71808         * lib/iconv_close.c, lib/iconv_open.c, lib/inet_ntop.c, lib/isfinite.c:
71809         * lib/isinf.c, lib/iswblank.c, lib/langinfo.in.h, lib/link.c:
71810         * lib/localcharset.c, lib/localcharset.h, lib/lseek.c, lib/malloc.c:
71811         * lib/malloca.c, lib/malloca.h, lib/md2.c, lib/md2.h, lib/md4.c:
71812         * lib/md4.h, lib/md5.c, lib/md5.h, lib/memmem.c, lib/mempcpy.c:
71813         * lib/memset.c, lib/memxor.c, lib/memxor.h, lib/minmax.h, lib/mktime.c:
71814         * lib/msvc-inval.c, lib/msvc-inval.h, lib/msvc-nothrow.c:
71815         * lib/msvc-nothrow.h, lib/netdb.in.h, lib/netinet_in.in.h, lib/nproc.c:
71816         * lib/nproc.h, lib/obstack_printf.c, lib/pathmax.h, lib/pipe.c:
71817         * lib/pipe2.c, lib/poll.c, lib/poll.in.h, lib/printf-args.c:
71818         * lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h:
71819         * lib/pselect.c, lib/pthread.in.h, lib/pty-private.h, lib/pty.in.h:
71820         * lib/read-file.c, lib/read-file.h, lib/ref-add.sin, lib/ref-del.sin:
71821         * lib/regcomp.c, lib/regex.c, lib/regex.h, lib/regex_internal.c:
71822         * lib/regex_internal.h, lib/regexec.c, lib/rijndael-alg-fst.c:
71823         * lib/rijndael-alg-fst.h, lib/rijndael-api-fst.c:
71824         * lib/rijndael-api-fst.h, lib/rint.c, lib/rintf.c, lib/rintl.c:
71825         * lib/round.c, lib/roundf.c, lib/roundl.c, lib/scandir.c, lib/select.c:
71826         * lib/sha1.c, lib/sha1.h, lib/size_max.h, lib/snprintf.c:
71827         * lib/stdalign.in.h, lib/stdarg.in.h, lib/stdbool.in.h:
71828         * lib/stddef.in.h, lib/stdint.in.h, lib/stdio.in.h, lib/str-kmp.h:
71829         * lib/str-two-way.h, lib/strcasecmp.c, lib/strcasestr.c, lib/strdup.c:
71830         * lib/striconv.c, lib/striconv.h, lib/string.in.h, lib/strings.in.h:
71831         * lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c, lib/strpbrk.c:
71832         * lib/strptime.c, lib/strsep.c, lib/strstr.c, lib/strverscmp.c:
71833         * lib/sys_file.in.h, lib/sys_ioctl.in.h, lib/sys_select.in.h:
71834         * lib/sys_socket.in.h, lib/sys_stat.in.h, lib/sys_time.in.h:
71835         * lib/sys_times.in.h, lib/sys_types.in.h, lib/sys_uio.in.h:
71836         * lib/sys_utsname.in.h, lib/sys_wait.in.h, lib/tcgetsid.c:
71837         * lib/termios.in.h, lib/time.in.h, lib/time_r.c, lib/timegm.c:
71838         * lib/times.c, lib/unictype/3level.h, lib/unictype/3levelbit.h:
71839         * lib/unistd.in.h, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c:
71840         * lib/vsnprintf.c, lib/waitpid.c, lib/wchar.in.h, lib/wctype.in.h:
71841         * lib/xsize.h, tests/test-closein.c, tests/test-des.c:
71842         * tests/test-fclose.c, tests/test-fgetc.c, tests/test-filevercmp.c:
71843         * tests/test-fputc.c, tests/test-fread.c, tests/test-fwrite.c:
71844         * tests/test-gc-arcfour.c, tests/test-gc-arctwo.c, tests/test-gc-des.c:
71845         * tests/test-gc-hmac-md5.c, tests/test-gc-hmac-sha1.c:
71846         * tests/test-gc-md2.c, tests/test-gc-md4.c, tests/test-gc-md5.c:
71847         * tests/test-gc-pbkdf2-sha1.c, tests/test-gc-rijndael.c:
71848         * tests/test-gc-sha1.c, tests/test-gc.c, tests/test-getdelim.c:
71849         * tests/test-getline.c, tests/test-getndelim2.c, tests/test-md2.c:
71850         * tests/test-md4.c, tests/test-parse-datetime.c, tests/test-perror.c:
71851         * tests/test-perror2.c, tests/test-pipe.c, tests/test-pipe2.c:
71852         * tests/test-poll.c, tests/test-quotearg-simple.c:
71853         * tests/test-quotearg.c, tests/test-quotearg.h:
71854         * tests/test-round-ieee.c, tests/test-round1.c:
71855         * tests/test-roundf-ieee.c, tests/test-roundf1.c:
71856         * tests/test-roundl-ieee.c, tests/test-roundl.c:
71857         * tests/test-safe-alloc.c, tests/test-sigpipe.c:
71858         * tests/test-spawn-pipe-child.c, tests/test-spawn-pipe-main.c:
71859         * tests/test-strerror.c, tests/test-strerror_r.c:
71860         * tests/test-strsignal.c, tests/test-strverscmp.c:
71861         * tests/test-xmemdup0.c:
71862         Replace FSF snail mail addresses with URLs, as per GNU coding
71863         standards.  See glibc bug
71864         <http://sourceware.org/bugzilla/show_bug.cgi?id=13673>.
71866 2011-12-22  Reuben Thomas  <rrt@sc3d.org>
71868         README-release: capitalize a word and split a line
71869         * top/README-release: Fix punctuation and spacing.
71871 2012-02-08  Akim Demaille  <demaille@gostai.com>
71873         fatal-signal: use C prototypes (with explicit void).
71874         * lib/fatal-signal.c (uninstall_handlers, install_handlers)
71875         (init_fatal_signal_set, block_fatal_signals): Fix signatures.
71877 2012-02-07  Paul Eggert  <eggert@cs.ucla.edu>
71879         regex: spelling fix
71880         * lib/regexec.c: spelling fix
71882         regex: rely on stdint.h for SIZE_MAX
71883         * lib/regex_internal.h (SIZE_MAX): Remove; stdint.h supplies this now.
71885 2012-02-07  Paul Eggert  <eggert@cs.ucla.edu>
71887         regex: merge glibc changes
71889         * lib/regcomp.c (init_dfa): Tighten overflow checks to test
71890         for IDX_MAX too, since IDX_MAX can be much less than SIZE_MAX.
71891         (init_word_char): Work even if bitset words are not exactly 32 or
71892         64 bits wide.  Don't assume there are no padding bits.
71893         * lib/regex.c [_LIBC]: Do not include <config.h>.
71894         [!_LIBC]: Add pragmas to ignore -Wsuggest-attributes=pure
71895         and -Wtype-limits.
71896         * lib/regex.h (__USE_GNU): Renamed from __USE_GNU_REGEX, to avoid
71897         needless disagreement with glibc.  All uses changed.  Define it to
71898         1 only if _GNU_SOURCE, to match glibc.
71899         (_REG_RM_NAME): Remove; no longer needed, since the names in
71900         question are now all protected by __USE_GNU.
71901         (_REG_RE_NAME): Remove; replaced by glibc's __REPB_PREFIX.
71902         (REG_TRANSLATE_TYPE): Remove; replaced by glibc's __RE_TRANSLATE_TYPE.
71903         * lib/regex_internal.h (MIN): New macro.
71905         2012-01-03 Ulrich Drepper <drepper@gmail.com>
71906         * lib/regcomp.c (init_word_char): Optimize regex a bit.
71908         2011-12-30 Jakub Jelinek <jakub@redhat.com>
71909         * lib/regex_internal.c (re_string_fetch_byte_case):
71910         Fix up regcomp/regexec.  The problem is that parse_bracket_symbol
71911         is miscompiled, and it turns out it is because of an incorrect
71912         attribute on re_string_fetch_byte_case.  Unlike
71913         re_string_peek_byte_case, this one is really not pure, it modifies
71914         memory (increments pstr->cur_idx), and with the pure attribute GCC
71915         assumed it doesn't and it cached the presumed value of
71916         regexp->cur_idx in a variable across the
71917          for (;; ++i)
71918            {
71919              if (i >= BRACKET_NAME_BUF_SIZE)
71920                return REG_EBRACK;
71921              if (token->type == OP_OPEN_CHAR_CLASS)
71922                ch = re_string_fetch_byte_case (regexp);
71923              else
71924                ch = re_string_fetch_byte (regexp);
71925              if (re_string_eoi(regexp))
71926                return REG_EBRACK;
71927              if (ch == delim && re_string_peek_byte (regexp, 0) == ']')
71928                break;
71929              elem->opr.name[i] = ch;
71930            }
71932         2011-11-29 Andreas Schwab <schwab@redhat.com>
71933         * lib/regcomp.c (build_equiv_class):
71934         Fix access after end of search string in regex matcher.
71936         2011-11-12 Ulrich Drepper <drepper@redhat.com>
71937         * lib/regex_internal.c, lib/regex_internal.h: Fix warnings in regex.
71939         2011-10-12 Ulrich Drepper <drepper@redhat.com>
71940         * lib/regcomp.c (parse_branch): One more regex memory leak fixed.
71942         2011-10-11 Ulrich Drepper <drepper@redhat.com>
71943         * lib/regcomp.c (parse_branch, parse_sub_exp):
71944         More regex memory leak fixes and tests.
71945         (parse_sub_exp, parse_bracket_exp):
71946         Fix memory leak for some invalid regular expressions.
71948         2011-05-28 Ulrich Drepper <drepper@gmail.com>
71949         * lib/regex_internal.c, lib/regexec.c:
71950         Fix unnecessary overallocation due to incomplete character.  When
71951         incomplete characters are found at the end of a string the code
71952         ran amok and allocated lots of memory.  Stricter limits are now in
71953         place.
71955         2011-05-20 Reuben Thomas <rrt@sc3d.org>
71956         * lib/regex.h: Update documentation.
71958         2011-05-16 Aharon Robbins <arnold@skeeve.com>
71959         * lib/regex.h: Update RE_SYNTAX*_AWK constants.
71961         2010-05-05 Andreas Schwab <schwab@redhat.com>
71962         * lib/regexec.c (find_collation_sequence_value):
71963         Fix lookup of collation sequence value during regexp matching.
71965         2010-01-22 Ulrich Drepper <drepper@redhat.com>
71966         * lib/regex_internal.c (re_dfa_add_node): Extend overflow detection.
71968         2008-01-16 Ulrich Drepper <drepper@redhat.com>
71969         * lib/regex.h: Cleanup namespace.
71971         2007-11-26 Ulrich Drepper <drepper@redhat.com>
71972         * lib/regex.h (REG_ENOSYS): Define REG_ENOSYS also for __USE_XOPEN2K.
71974         2007-08-26 Ulrich Drepper <drepper@redhat.com>
71975         * lib/regex_internal.h: Prevent some declarations and definitions
71976         to be seen when used in tests.
71978         2005-05-06 Ulrich Drepper <drepper@redhat.com>
71979         * lib/regex_internal.h: Include bits/libc-lock.h or define dummy
71980         __libc_lock_* macros if not _LIBC.
71981         (struct re_dfa_t): Add lock.
71983 2012-02-07  Eric Blake  <eblake@redhat.com>
71985         maint.mk: also prohibit lower-case @var@
71986         * top/maint.mk (sc_makefile_at_at_check): Enhance check to cover
71987         lower case, like @top_srcdir@.
71989 2012-02-04  Eric Blake  <eblake@redhat.com>
71991         canonicalize: avoid uninitialized memory use
71992         * lib/canonicalize-lgpl.c (__realpath): Avoid possibility of
71993         random '/' left in dest.
71994         * lib/canonicalize.c (canonicalize_filename_mode): Likewise.
71996 2012-02-04  Bruno Haible  <bruno@clisp.org>
71998         isatty: Fix test failure of ptsname_r on native Windows.
71999         * lib/isatty.c (_isatty_nothrow): Upon exception, return 0, not -1,
72000         and don't set errno.
72001         (isatty): Test first whether fd is valid. Set errno when returning 0.
72003 2012-02-04  Bruno Haible  <bruno@clisp.org>
72005         spawn-pipe tests: Fix a NULL program name in a diagnostic.
72006         * tests/test-spawn-pipe-main.c: Include progname.h.
72007         (main): Invoke set_program_name.
72008         * modules/spawn-pipe-tests (Depends-on): Add progname.
72010         nonblocking-socket tests: Fix a NULL program name in a diagnostic.
72011         * tests/test-nonblocking-socket-main.c: Include progname.h.
72012         (main): Invoke set_program_name.
72013         * modules/nonblocking-socket-tests (Depends-on): Add progname.
72015         nonblocking-pipe tests: Fix a NULL program name in a diagnostic.
72016         * tests/test-nonblocking-pipe-main.c: Include progname.h.
72017         (main): Invoke set_program_name.
72018         * modules/nonblocking-pipe-tests (Depends-on): Add progname.
72020 2012-02-04  Eric Blake  <eblake@redhat.com>
72022         canonicalize-lgpl: fix // handling
72023         * lib/canonicalize-lgpl.c (__realpath): Don't convert /// to //.
72025         canonicalize: fix // handling
72026         * lib/canonicalize.c (canonicalize_filename_mode): Don't convert
72027         /// to //, since only // is special.
72029 2012-02-04  Bruno Haible  <bruno@clisp.org>
72031         ioctl: Fix test failure on native Windows.
72032         * lib/ioctl.c: Include msvc-nothrow.h.
72033         (primary_ioctl): If fd is not a valid handle, set errno to EBADF.
72035 2012-02-04  Bruno Haible  <bruno@clisp.org>
72037         fsync: Avoid test failure on native Windows.
72038         * lib/fsync.c (fsync) [Windows]: Don't fail if the handle is merely
72039         read-only.
72041 2012-02-04  Bruno Haible  <bruno@clisp.org>
72043         sys_select: Avoid syntax error on OpenBSD 5.0.
72044         * lib/sys_select.in.h [OpenBSD]: When /usr/include/pthread.h is
72045         currently being included, just include the system's <sys/select.h>.
72047 2012-02-04  Bruno Haible  <bruno@clisp.org>
72049         sys_select: Avoid syntax error on OpenBSD 5.0.
72050         * lib/sys_select.in.h: Include <signal.h> only after the include_next
72051         <sys/select.h>, not before.
72052         Reported by Jiri B <jirib@devio.us>.
72054 2012-02-04  Bruno Haible  <bruno@clisp.org>
72056         get-rusage-as, get-rusage-data tests: Avoid test failure with gcc-4.7.
72057         * tests/test-get-rusage-as.c (main): Assign the malloc() results to
72058         global variables.
72059         * tests/test-get-rusage-data.c (main): Likewise.
72060         Reported by Jim Meyering.
72062 2012-02-04  Bruno Haible  <bruno@clisp.org>
72064         stdioext: Fix last commit.
72065         * lib/fwritable.c [EPLAN9]: Include <fcntl.h>.
72067 2012-02-03  Bruno Haible  <bruno@clisp.org>
72069         stdioext: Add tentative support for Plan9.
72070         * lib/stdio-impl.h: Include <errno.h>.
72071         * lib/fseterr.c (fseterr) [EPLAN9]: Add conditional code.
72072         * lib/freadable.c (freadable): Likewise.
72073         * lib/fwritable.c (fwritable): Likewise.
72074         * lib/fbufmode.c (fbufmode): Likewise.
72075         * lib/freading.c (freading): Likewise.
72076         * lib/fwriting.c (fwriting): Likewise.
72077         * lib/freadptr.c (freadptr): Likewise.
72078         * lib/freadseek.c (freadptrinc): Likewise.
72079         * lib/freadahead.c (freadahead): Likewise.
72080         * lib/fpurge.c (fpurge): Likewise.
72081         * lib/fseeko.c (rpl_fseeko): Likewise.
72082         * m4/fpending.m4 (gl_PREREQ_FPENDING): Add a variant for Plan9.
72083         Reported by Jens Staal <staal1978@gmail.com>.
72085 2012-02-02  Jim Meyering  <meyering@redhat.com>
72087         file-has-acl: suppress a warning from gcc -Wsuggest-attribute=const
72088         * lib/file-has-acl.c (file_has_acl): This function (for some #ifdefs)
72089         would evoke a new gcc warning.  Given all of the #ifdefs, it is better
72090         not even to try to add the attribute.  Instead, add a pragma to suppress
72091         the suggestion/warning.
72093 2012-01-31  Karl Berry  <karl@gnu.org>
72095         setstate doc: typo.
72096         * doc/posix-functions/setstate.texi (setstate): { not (.
72098 2012-01-31  Bruno Haible  <bruno@clisp.org>
72100         popen: Make more robust on Windows.
72101         * lib/popen.c: On native Windows, use the _popen based code even if
72102         HAVE_POPEN is set.
72103         * doc/posix-functions/popen.texi: Mention necessity of COMSPEC
72104         environment variable on native Windows.
72106 2012-01-30  Bruno Haible  <bruno@clisp.org>
72108         pclose: Fix typo.
72109         * lib/stdio.in.h (pclose): Fix typo in warning message.
72111 2012-01-30  Bruno Haible  <bruno@clisp.org>
72113         doc about getlogin_r, setstate.
72114         * doc/posix-functions/getlogin_r.texi: List the incompatible
72115         declaration problem under "not fixed by gnulib".
72116         * doc/posix-functions/setstate.texi: Mention incompatible declaration
72117         problem on Solaris 11 and other platforms.
72119 2012-01-30  Chuanchang Jia  <chuanchang.jia@gmail.com>  (tiny change)
72120             Bruno Haible  <bruno@clisp.org>
72122         poll tests: Make test more robust.
72123         * tests/test-poll.c: Include macros.h.
72124         (test_accept_first, test_pair, test_socket_pair, test_pipe): Verify
72125         return value of various I/O operations.
72126         * modules/poll-tests (Files): Add tests/macros.h.
72128 2012-01-30  Bruno Haible  <bruno@clisp.org>
72130         sys_stat: Fix support for mingw64 and MSVC.
72131         * lib/sys_stat.in.h (stat) [AIX]: Don't redefine 'stat' if the system
72132         header files already do it.
72133         (stat) [mingw, msvc]: Redefine the symbol to which stat is defined, not
72134         stat itself.
72135         Reported by Marc-André Lureau <marcandre.lureau@redhat.com>.
72137 2012-01-30  Bruno Haible  <bruno@clisp.org>
72139         wcwidth: Work around bug in UTF-8 locale on OpenBSD 5.0.
72140         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test also wcwidth of U+05B0.
72141         * doc/posix-functions/wcwidth.texi: Mention the OpenBSD 5.0 bug.
72143 2012-01-29  Bruno Haible  <bruno@clisp.org>
72145         quotearg: Fix test failure on MacOS X 10.5.
72146         * tests/test-quotearg-simple.c: Include localcharset.h.
72147         (main): If the locale encoding is not ASCII, bypass the tests of
72148         locale_quoting_style and clocale_quoting_style.
72149         * modules/quotearg-tests (Depends-on): Add 'localcharset'.
72151 2012-01-29  Jim Meyering  <meyering@redhat.com>
72153         maint.mk: sc_prohibit_canonicalize_without_use: avoid false positive
72154         * top/maint.mk (sc_prohibit_canonicalize_without_use): Also
72155         detect uses of canonicalize_file_name.
72157 2012-01-28  Bruno Haible  <bruno@clisp.org>
72159         test-framework-sh: Fix test failure with AIX 7.1 diff.
72160         * tests/init.sh (compare_): Don't use 'diff -u' if it inserts a space
72161         in column 1, like 'diff -c' does.
72162         * tests/test-init.sh (test_compare): Don't repeat the test from init.sh
72163         whether 'diff -u' is used. Instead, test whether the output contains
72164         some '@' character.
72166 2012-01-28  Paul Eggert  <eggert@cs.ucla.edu>
72168         strtoimax: eliminate need for stdint.h, inttypes.h checks
72169         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Don't use
72170         gl_AC_HEADER_STDINT_H or gl_AC_HEADER_INTTYPES_H.  This reduces
72171         the prerequisites for a recently-introduced strtoimax test.
72172         I guess this might cause strtoimax to be replaced when not
72173         strictly necessary on older hosts, but this shouldn't introduce
72174         any bugs and it should make Emacs 'configure' faster on typical
72175         modern hosts.  Problem discovered when importing the latest gnulib
72176         to an Emacs test version.
72177         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4.
72179 2012-01-28  Bruno Haible  <bruno@clisp.org>
72181         sys_time: Override 'struct timeval' on some native Windows platforms.
72182         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Test whether tv_sec
72183         has the right type. Set REPLACE_STRUCT_TIMEVAL if not.
72184         (gl_HEADER_SYS_TIME_H_DEFAULTS): Initialize REPLACE_STRUCT_TIMEVAL.
72185         * lib/sys_time.in.h: Include <winsock2.h> also when 'struct timeval'
72186         needs to be overridden.
72187         (timeval): Override if REPLACE_STRUCT_TIMEVAL is set.
72188         * modules/sys_time (Makefile.am): Substitute REPLACE_STRUCT_TIMEVAL.
72189         * tests/test-sys_select.c: Check that the tv_sec member has the same
72190         size as a 'time_t'.
72191         * tests/test-sys_time.c: Likewise.
72192         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): If REPLACE_STRUCT_TIMEVAL
72193         is set, set also REPLACE_GETTIMEOFDAY.
72194         * lib/gettimeofday.c (gettimeofday): If 'struct timeval' is overridden,
72195         convert the resulting 'struct timeval' before returning.
72196         * lib/select.c: Include <sys/time.h>.
72197         (select, timeval): Undefine at the right place.
72198         * modules/select (Depends-on): Add sys_time.
72199         * doc/posix-headers/sys_time.texi: Mention the problem with tv_sec on
72200         some Windows platforms.
72201         Reported by Marc-André Lureau <marcandre.lureau@redhat.com>.
72203 2012-01-28  Marc-André Lureau  <marcandre.lureau@redhat.com>  (tiny change)
72205         accept4, fcntl, socket modules: Avoid warnings on x86_64 mingw64.
72206         * lib/accept4.c (accept4): Use intptr_t to convert handle pointer to
72207         an integer.
72208         * lib/fcntl.c (dupfd): Likewise.
72209         * lib/w32sock.h (SOCKET_TO_FD): Likewise.
72211 2012-01-28  Bruno Haible  <bruno@clisp.org>
72213         fcntl: Avoid compilation error on native Windows.
72214         * modules/fcntl (Depends-on): Add 'close'.
72216 2012-01-28  Marc-André Lureau  <marcandre.lureau@redhat.com>  (tiny change)
72218         select, poll, isatty: Avoid warnings on x86_64 mingw64.
72219         * lib/select.c (IsConsoleHandle): Use intptr_t to convert handle
72220         pointer to an integer.
72221         * lib/poll.c (IsConsoleHandle): Likewise.
72222         * lib/isatty.c (IsConsoleHandle): Likewise.
72224 2012-01-28  Jim Meyering  <meyering@redhat.com>
72226         doc: clarify README-release
72227         * top/README-release: Clarify: you should make a point to have
72228         the latest stable versions of build tools in your PATH, and the
72229         reference to buildreq is solely for its list of tool names, not
72230         for its minimal-functional version numbers.
72231         Prompted by discussion with Reuben Thomas and Gary V. Vaughan.
72233         maint.mk: use more readable (yet functionally equivalent) quoting
72234         It is common to quote a single quote in a single quoted string like
72235         this:  '...'\''...'.  Unless you know the idiom, that looks like
72236         gibberish, so prefer to double-quote the string when possible.
72237         Then you can use a more readable, lone single quote: "...'..."
72238         * top/maint.mk (sc_cast_of_argument_to_free): Quoting like this
72239         "don't" is more readable than the equivalent 'don'\''t'.
72240         (sc_cast_of_x_alloc_return_value): Likewise.
72241         (sc_cast_of_alloca_return_value): Likewise.
72242         (sc_makefile_path_separator_check): Similar: use ":" in '...',
72243         rather than '\'':'\''.
72245 2012-01-27  Paul Eggert  <eggert@cs.ucla.edu>
72247         stdalign: relax _Alignof and tighten _Alignas test
72248         * m4/stdalign.m4 (gl_STDALIGN_H): Relax the _Alignof test,
72249         as it was too strict: alignof must divide offsetof, but it need
72250         not equal offsetof.  Inspired by Joseph S. Myers's comment
72251         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023#c10>.
72252         Conversely, tighten the _Alignas test a bit, as the resulting
72253         alignment must be exactly 8.
72255 2012-01-27  Bruno Haible  <bruno@clisp.org>
72257         stdalign: Document the last change.
72258         * doc/posix-headers/stdalign.texi: Mention GCC bug 52023.
72260 2012-01-27  Paul Eggert  <eggert@cs.ucla.edu>
72262         stdalign: check that alignof and offsetof are consistent
72263         * m4/stdalign.m4 (gl_STDALIGN_H): Check for GCC bug 52023.
72264         Problem reported for gnulib by Richard W.M. Jones in
72265         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00340.html>.
72267 2012-01-27  Jim Meyering  <meyering@redhat.com>
72269         update-copyright: accept new option: UPDATE_COPYRIGHT_USE_INTERVALS=2
72270         * build-aux/update-copyright: When UPDATE_COPYRIGHT_USE_INTERVALS=2,
72271         convert a sequence with gaps to the minimal containing range.
72272         For example, convert 2000, 2004-2007, 2009 to 2000-2009.
72273         * tests/test-update-copyright.sh: Test for this.
72274         The FSF confirmed it is ok to do this, assuming there is at
72275         least one significant change per year in the affected range:
72276         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/29554/focus=29860
72278 2012-01-26  Bruno Haible  <bruno@clisp.org>
72280         pipe2: refine doc about thread-safety
72281         * doc/glibc-functions/pipe2.texi: Clarify the extent of the
72282         multithread-safety problem.
72283         * doc/glibc-functions/accept4.texi: Likewise.
72285 2012-01-26  Bruno Haible  <bruno@clisp.org>
72287         posix_spawn_file_actions_addopen: Fix 2012-01-08 commit.
72288         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN):
72289         In the test program, include <fcntl.h>, for O_RDONLY.
72291 2012-01-26  Eric Blake  <eblake@redhat.com>
72293         pipe2: document lack of thread-safety in replacement
72294         * doc/glibc-functions/pipe2.texi (pipe2): Mention thread safety
72295         issue in replacement.
72296         * doc/glibc-functions/accept4.texi (accept4): Likewise.
72297         Based on a report by Eric Wong.
72299 2012-01-24  Marc-André Lureau  <marcandre.lureau@redhat.com>  (tiny change)
72300             Bruno Haible  <bruno@clisp.org>
72302         malloca: Avoid warnings on x86_64 mingw64.
72303         * lib/malloca.c: Include <stdint.h>.
72304         (mmalloca, freea): Use uintptr_t to convert pointers to integers.
72305         * modules/malloca (Depends-on): Add stdint.
72306         * modules/relocatable-prog-wrapper (Depends-on): Likewise.
72308 2012-01-25  Paul Eggert  <eggert@cs.ucla.edu>
72310         obstack: remove __STDC__ conditionals
72311         * lib/obstack.h: Remove __STDC__ conditionals, as suggested by Joseph
72312         S. Myers in <http://cygwin.com/ml/libc-alpha/2012-01/msg00104.html>.
72313         This leaves lib/localcharset.c, m4/iconv.m4, and a confusing comment in
72314         m4/include_next.m4 as the only gnulib-maintained places that still
72315         refer to __STDC__.
72317 2012-01-24  Bruno Haible  <bruno@clisp.org>
72319         havelib: Modern quoting.
72320         * build-aux/config.rpath: Quote 'like this', not `like this', as per
72321         the recent change to the GNU coding standards.
72323 2012-01-24  Bruno Haible  <bruno@clisp.org>
72325         stdint: Improve support for Android.
72326         * lib/stdint.in.h: Test __ANDROID__, not __BIONIC__.
72327         Reported by Simon Josefsson <simon@josefsson.org>.
72329 2012-01-23  Paul Eggert  <eggert@cs.ucla.edu>
72331         doc: omit trailing empty lines from INSTALL etc.
72332         * doc/Makefile (INSTALL): Omit trailing empty lines.
72333         (INSTALL.ISO, INSTALL.UTF-8): Build from INSTALL, so that these also
72334         omit trailing empty lines.  This simplifies the build procedure.
72336 2012-01-23  Jim Meyering  <meyering@redhat.com>
72338         tests: avoid spurious warnings about gl_sockets_startup
72339         Fedora rawhide's gcc version 4.7.0 20120119 with -Wunused-value
72340         would warn about every use of "gl_sockets_startup (SOCKETS_1_1);"
72341         reporting a "statement with no effect".
72342         * tests/test-accept.c (main): Mark as "(void)".
72343         * tests/test-accept4.c (main): Likewise.
72344         * tests/test-bind.c (main): Likewise.
72345         * tests/test-connect.c (main): Likewise.
72346         * tests/test-getpeername.c (main): Likewise.
72347         * tests/test-getsockname.c (main): Likewise.
72348         * tests/test-getsockopt.c (main): Likewise.
72349         * tests/test-listen.c (main): Likewise.
72350         * tests/test-recv.c (main): Likewise.
72351         * tests/test-recvfrom.c (main): Likewise.
72352         * tests/test-send.c (main): Likewise.
72353         * tests/test-sendto.c (main): Likewise.
72354         * tests/test-setsockopt.c (main): Likewise.
72355         * tests/test-shutdown.c (main): Likewise.
72357 2012-01-21  Bruno Haible  <bruno@clisp.org>
72359         locale-fr.m4: Fix for Android.
72360         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Avoid compilation
72361         failure of the test program on Bionic libc.
72363 2012-01-21  Jim Meyering  <meyering@redhat.com>
72365         bootstrap: fail when bootstrap_post_import_hook fails
72366         Otherwise, it's far too easy to miss diagnostics emitted
72367         between gnulib-tool's output and that of running configure.
72368         * build-aux/bootstrap: Fail when bootstrap_post_import_hook fails.
72370 2012-01-17  Jim Meyering  <meyering@redhat.com>
72372         maint: enable sc_trailing_blank
72373         * build-aux/pmccabe.css: Remove trailing blanks.
72374         * doc/acl-cygwin.txt: Likewise.
72375         * doc/gnu-oids.texi: Likewise
72376         * cfg.mk: Enable sc_trailing_blank.
72377         Exempt build-aux/texinfo.tex and doc/Copyright/assign.future.manual.
72379 2012-01-17  Jim Meyering  <meyering@redhat.com>
72381         maint: enable sc_prohibit_openat_without_use
72382         * cfg.mk: Enable sc_prohibit_openat_without_use.
72383         Exempt lib/selinux-at.c.
72385 2012-01-17  Jim Meyering  <meyering@redhat.com>
72387         maint: enable sc_prohibit_cloexec_without_use
72388         * cfg.mk: Enable sc_prohibit_cloexec_without_use.
72389         * lib/dup-safer-flag.c: Don't include "cloexec.h".  Not needed.
72391 2012-01-17  Jim Meyering  <meyering@redhat.com>
72393         maint: enable sc_prohibit_intprops_without_use
72394         * cfg.mk: Enable sc_prohibit_intprops_without_use
72395         * tests/test-nanosleep.c: Don't include "intprops.h".  Not needed.
72397 2012-01-17  Jim Meyering  <meyering@redhat.com>
72399         maint: enable sc_prohibit_hash_pjw_without_use
72400         * cfg.mk: Enable sc_prohibit_hash_pjw_without_use.
72401         * top/maint.mk (sc_prohibit_hash_pjw_without_use): Adjust regexp
72402         to match any use of \<hash_pjw\>, i.e., not necessarily with a
72403         following " (".
72405 2012-01-17  Jim Meyering  <meyering@redhat.com>
72407         maint: enable double-word-prohibiting rule
72408         * cfg.mk (local-checks-to-skip): Enable sc_prohibit_doubled_word.
72409         Exempt three files.
72411 2012-01-17  Jim Meyering  <meyering@redhat.com>
72413         maint: remove empty lines at EOF, but excluding modules/*
72414         Apply syntax rules at home as well as abroad.  Most changes
72415         were induced by running this:
72416           make srcdir=. _build-aux=build-aux -f top/maint.mk \
72417             sc_prohibit_empty_lines_at_EOF | grep -v modules/ \
72418             | xargs perl -pi -0777 -e 's/\n\n+$/\n/'
72419         * cfg.mk (local-checks-to-skip): Enable sc_prohibit_empty_lines_at_EOF.
72420         Exempt modules/* and two binary files.
72421         Also exempt doc/INSTALL*, per request from Bruno Haible.
72422         * doc/regexprops-generic.texi: *Add* a newline at EOF.  There was none.
72423         * doc/Copyright/assign.translation.manual: Remove empty lines at EOF.
72424         * doc/Copyright/request-assign.future: Likewise.
72425         * doc/Copyright/request-disclaim.changes: Likewise.
72426         * doc/INSTALL: Likewise.
72427         * doc/INSTALL.ISO: Likewise.
72428         * doc/INSTALL.UTF-8: Likewise.
72429         * doc/acl-cygwin.txt: Likewise.
72430         * doc/acl-resources.txt: Likewise.
72431         * doc/fdl-1.2.texi: Likewise.
72432         * doc/fdl-1.3.texi: Likewise.
72433         * doc/fdl.texi: Likewise.
72434         * lib/argp-pin.c: Likewise.
72435         * lib/round.c: Likewise.
72436         * lib/unicase/u16-totitle.c: Likewise.
72437         * lib/unictype/block_test.c: Likewise.
72438         * lib/uninorm/canonical-decomposition.c: Likewise.
72439         * m4/README: Likewise.
72440         * m4/relocatable-lib.m4: Likewise.
72441         * tests/test-isnand-nolibm.c: Likewise.
72442         * tests/test-isnand.c: Likewise.
72443         * tests/uninorm/NormalizationTest.txt: Likewise.
72445 2012-01-17  Jim Meyering  <meyering@redhat.com>
72447         maint: add framework to run syntax-check rules against gnulib sources
72448         * cfg.mk: New file, to disable all currently-failing tests.
72449         We'll enable them one by one, as they are made to pass.
72450         * Makefile (sc_maint): New rule.
72452 2012-01-21  Bruno Haible  <bruno@clisp.org>
72454         stdint: Add support for Android.
72455         * lib/stdint.in.h: When included from Bionic <sys/types.h>, just
72456         include the system's <stdint.h>.
72457         Reported by Simon Josefsson <simon@josefsson.org>.
72459 2012-01-19  Jim Meyering  <meyering@redhat.com>
72461         bootstrap: add bootstrap_post_import_hook
72462         Bison does still need something like the gnulib_mk_hook whose
72463         invocation I had to remove along with slurp in commit 767ccd40.
72464         Technically, we could get along without it, but doing so would
72465         have required living with a warning and a mandatory post-bootstrap
72466         automake rerun.
72467         * build-aux/bootstrap (gnulib_mk_hook): Remove definition, too.
72468         (bootstrap_post_import_hook): New function.
72469         Invoke it after gnulib-tool --import and before autoreconf.
72471 2012-01-18  Jim Meyering  <meyering@redhat.com>
72473         gitlog-to-changelog: don't use "no_"-prefixed variable name
72474         * build-aux/gitlog-to-changelog (main): Use getopt's "!" attribute
72475         to enable both --cluster and --no-cluster.  Change variable name,
72476         s/\$no_cluster/$cluster/, and reverse usage to match.
72478         gitlog-to-changelog: use "||", not "or" in expressions
72479         * build-aux/gitlog-to-changelog (main): Use "||", not "or" in
72480         expressions.
72482 2012-01-17  Joel E. Denny  <joeldenny@joeldenny.org>
72484         gitlog-to-changelog: new option --no-cluster
72485         * build-aux/gitlog-to-changelog: New option --no-cluster, disables
72486         clustering of adjacent commit messages.
72488 2012-01-17  Jim Meyering  <meyering@redhat.com>
72490         maint: spell file systems with two words, not one
72491         * m4/ls-mntd-fs.m4 (MOUNTED_INTERIX_STATVFS): Spell file systems with
72492         two words, not one.
72494 2012-01-16  Jim Meyering  <meyering@redhat.com>
72496         bootstrap: add a FIXME comment to ensure we eventually remove the hack
72497         * build-aux/bootstrap (gnulib_tool_options): Add comment.
72499 2012-01-16  Eric Blake  <eblake@redhat.com>
72501         bootstrap: cater to autoconf 2.59
72502         * build-aux/bootstrap (AUTORECONF): Work even when --no-recursive
72503         is not available.
72505         bootstrap: properly check for libtool
72506         * build-aux/bootstrap (libtoolize): Also run libtool when older
72507         usage is detected.
72509 2012-01-15  Bruno Haible  <bruno@clisp.org>
72511         Improve support for MSVC 9.
72512         * lib/unistd.in.h: Include <io.h> when needed to avoid redefinition
72513         clashes on MSVC.
72514         * lib/fcntl.in.h: Likewise.
72515         * lib/stdlib.in.h: Likewise.
72516         * lib/sys_stat.in.h: Likewise.
72518 2011-01-15  Stefano Lattarini  <stefano.lattarini@gmail.com>
72520         gnupload: we hold the master copy of this script now
72521         For motivation and more information, see:
72522         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00222.html>
72523         * build-aux/gnupload: Make it clear in the heading comments that the
72524         master copy of this file is maintained by gnulib.  Since we are at
72525         it, bump its copyright year and ...
72526         ($scriptversion): ... the date in its version.
72527         ($usage): Patches and bug reports should be sent to the gnulib list,
72528         not the automake one.
72529         * config/srclist.txt: Don't try to sync 'gnupload' from automake
72530         anymore.
72532 2012-01-15  Bruno Haible  <bruno@clisp.org>
72534         Fix module 'random'.
72535         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether random, srandom,
72536         initstate, setstate are declared.
72538 2012-01-14  Bruno Haible  <bruno@clisp.org>
72540         Tests for module 'random'.
72541         * modules/random-tests: New file.
72542         * tests/test-random.c: New file, based on tests/test-random_r.c.
72544         New module 'random'.
72545         * lib/stdlib.in.h (random, srandom, initstate, setstate): New
72546         declarations.
72547         * lib/random.c: New file, based on glibc/stdlib/random.c.
72548         * m4/random.m4: New file.
72549         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_RANDOM,
72550         HAVE_RANDOM.
72551         * modules/stdlib (Makefile.am): Substitute GNULIB_RANDOM, HAVE_RANDOM.
72552         * modules/random: New file.
72553         * config/srclist.txt: Add an entry for random.c.
72554         * doc/posix-functions/random.texi: Mention the 'random' module.
72555         * doc/posix-functions/initstate.texi: Likewise.
72556         * doc/posix-functions/setstate.texi: Likewise.
72557         * doc/posix-functions/srandom.texi: Likewise.
72559 2012-01-12  Bruno Haible  <bruno@clisp.org>
72561         random_r: Use common idioms.
72562         * lib/random_r.c: Include <stdlib.h> first.
72564         random_r: Override incompatible API on AIX, OSF/1.
72565         * lib/stdlib.in.h (random_r, srandom_r, initstate_r, setstate_r):
72566         Override the system function if REPLACE_RANDOM_R is 1.
72567         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Require AC_CANONICAL_HOST. On AIX
72568         and OSF/1, set REPLACE_RANDOM_R.
72569         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_RANDOM_R.
72570         * modules/stdlib (Makefile.am): Substitute REPLACE_RANDOM_R.
72571         * modules/random_r (configure.ac): Test REPLACE_RANDOM_R.
72572         * doc/glibc-functions/initstate_r.texi: Mention the AIX, OSF/1 problem.
72573         * doc/glibc-functions/random_r.texi: Likewise.
72574         * doc/glibc-functions/setstate_r.texi: Likewise.
72576         random_r: Support for MSVC 9.
72577         * lib/random_r.c: Include stdint.h, not inttypes.h.
72579 2012-01-12  Eric Blake  <eblake@redhat.com>
72581         inet_ntop: guard extra work by IF_LINT
72582         * lib/inet_ntop.c (inet_ntop6): Mark spurious initialization, for
72583         better code generation when not checking for warnings.
72584         Suggested by Paul Eggert and Jim Meyering.
72586         strptime: fix regression on mingw
72587         * lib/strptime.c (__strptime_internal) [!_LIBC && !HAVE_TM_GMTOFF]:
72588         Fix regression.  Reported by Bruno Haible.
72590 2012-01-11  Reuben Thomas  <rrt@sc3d.org>
72591             Bruno Haible  <bruno@clisp.org>
72593         copy-file: add error-code-returning variant.
72594         * lib/copy-file.h (GL_COPY_ERR_*): New enumeration items.
72595         (qcopy_file_preserving): New declaration.
72596         * lib/copy-file.c (qcopy_file_preserving): Renamed from
72597         copy_file_preserving. Change return type to 'int'. Don't emit an error
72598         message here.
72599         (copy_file_preserving): New function.
72600         * tests/test-copy-file.c: Include <stdlib.h>.
72601         (main): Test qcopy_file_preserving if the environment variable
72602         NO_STDERR_OUTPUT is set.
72603         * tests/test-copy-file-1.sh: Invoke test-copy-file.sh a second time,
72604         with NO_STDERR_OUTPUT
72605         * tests/test-copy-file-2.sh: Likewise.
72607 2012-01-10  Bruno Haible  <bruno@clisp.org>
72609         copy-file: Use 'quote' module consistently.
72610         * lib/copy-file.c (copy_file_preserving): Use quote().
72612         copy-file: Refactor.
72613         * lib/copy-file.c: Include quote.h.
72614         (copy_file_preserving): Call qcopy_acl instead of copy_acl. Emit error
72615         message here.
72616         * modules/copy-file (Depends-on): Add quote.
72618         acl: Export qcopy_acl.
72619         * lib/acl.h (qcopy_acl): New declaration.
72620         * lib/copy-acl.c (qcopy_acl): Make non-static.
72622         acl: Rename a local variable.
72623         * lib/set-mode-acl.c (set_acl): Use same variable name as in copy_acl.
72625         acl: Align return values of copy_acl and qcopy_acl.
72626         * lib/copy-acl.c (copy_acl): Return the same value as qcopy_acl,
72627         maybe < -1.
72629 2012-01-11  Eric Blake  <eblake@redhat.com>
72631         strptime: silence gcc warnings
72632         * lib/strptime.c (__strptime_internal) [!_NL_CURRENT],
72633         [!_LIBC && !HAVE_TM_GMTOFF]: Avoid unused variables.
72634         Reported by Daniel P. Berrange.
72636         inet_ntop: silence gcc warning
72637         * lib/inet_ntop.c (inet_ntop6): Initialize best.base.
72638         Reported by Daniel P. Berrange.
72640 2012-01-11  Dmitry V. Levin  <ldv@altlinux.org>
72642         getloadavg test: skip the test on GNU/Linux without /proc mounted
72643         GNU libc implements getloadavg(3) on Linux by parsing /proc/loadavg
72644         file.  When /proc is not mounted, it always fails with ENOENT.
72645         * tests/test-getloadavg.c (main): Treat ENOENT return code from
72646         getloadavg(3) the same way as ENOSYS and ENOTSUP.
72648 2012-01-10  Bruno Haible  <bruno@clisp.org>
72650         regex: Avoid link error on MSVC 9.
72651         * modules/regex (Depends-on): Add wctype.
72653 2012-01-10  Bruno Haible  <bruno@clisp.org>
72655         doc: Mention --with-tests option.
72656         * gnulib-tool (func_usage): Suggest --with-tests for --test etc.
72657         * doc/gnulib.texi (Extra tests modules): Mention the need to pass
72658         --with-tests.
72659         Reported by Reuben Thomas.
72661 2012-01-10  Reuben Thomas  <rrt@sc3d.org>
72663         users.txt: order package names lexicographically.
72664         * users.txt: Order package names lexicographically.
72666 2012-01-10  Jim Meyering  <meyering@redhat.com>
72668         maint.mk: fix description in comment
72669         * top/maint.mk (require_exactly_one_NL_at_EOF_): Fix comment.
72671         ignore-value: remove deprecated ignore_ptr function
72672         * lib/ignore-value.h (ignore_ptr): Remove deprecated function.
72673         * NEWS: Note this.
72675 2012-01-09  Jim Meyering  <meyering@redhat.com>
72677         test-init.sh: avoid a subshell
72678         * tests/test-init.sh: Remove protective subshell.
72679         Suggested by Bernhard Voelker.  While a subshell is normally
72680         required to protect against older shells (Solaris, FreeBSD) that
72681         warn about a missing program before performing redirection, the
72682         shell-selection tests performed by init.sh probably exclude any
72683         offending shell.
72685 2012-01-08  Bruno Haible  <bruno@clisp.org>
72687         setlocale tests: Avoid test failure on Solaris 11.0.
72688         * tests/test-setlocale2.sh: Use 'env' to set the LC_ALL environment
72689         variable.
72691 2012-01-08  Bruno Haible  <bruno@clisp.org>
72693         posix_spawn_file_actions_addopen: Work around Solaris 11.0 bug.
72694         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Initialize
72695         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN.
72696         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN): New
72697         macro.
72698         * lib/spawn.in.h (posix_spawn_file_actions_addopen): Test
72699         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN, not REPLACE_POSIX_SPAWN.
72700         * lib/spawn_faction_addopen.c: Add workaround implementation if
72701         HAVE_WORKING_POSIX_SPAWN.
72702         * modules/spawn (Makefile): Substitute
72703         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN.
72704         * modules/posix_spawn_file_actions_addopen (configure.ac): Invoke
72705         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN. Test
72706         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN, not REPLACE_POSIX_SPAWN.
72707         (Depends-on): Update conditions.
72708         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Mention
72709         the Solaris 11 bug.
72711 2012-01-08  Bruno Haible  <bruno@clisp.org>
72713         posix_spawn_file_actions_adddup2: Work around Solaris 11.0 bug.
72714         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Initialize
72715         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2.
72716         * m4/posix_spawn.m4 (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2): New
72717         macro.
72718         * lib/spawn.in.h (posix_spawn_file_actions_adddup2): Test
72719         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2, not REPLACE_POSIX_SPAWN.
72720         * lib/spawn_faction_adddup2.c: Add workaround implementation if
72721         HAVE_WORKING_POSIX_SPAWN.
72722         * modules/spawn (Makefile): Substitute
72723         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2.
72724         * modules/posix_spawn_file_actions_adddup2 (configure.ac): Invoke
72725         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2. Test
72726         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2, not REPLACE_POSIX_SPAWN.
72727         (Depends-on): Update conditions.
72728         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Mention
72729         the Solaris 11 bug.
72731 2012-01-08  Bruno Haible  <bruno@clisp.org>
72733         posix_spawn_file_actions_addclose: Work around Solaris 11.0 bug.
72734         * m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Initialize
72735         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE.
72736         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Define
72737         HAVE_WORKING_POSIX_SPAWN.
72738         (gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE): New macro.
72739         * lib/spawn.in.h (posix_spawn_file_actions_addclose): Test
72740         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE, not REPLACE_POSIX_SPAWN.
72741         * lib/spawn_faction_addclose.c: Add workaround implementation if
72742         HAVE_WORKING_POSIX_SPAWN.
72743         * modules/spawn (Makefile): Substitute
72744         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE.
72745         * modules/posix_spawn_file_actions_addclose (configure.ac): Invoke
72746         gl_FUNC_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE. Test
72747         REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE, not REPLACE_POSIX_SPAWN.
72748         (Depends-on): Update conditions.
72749         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
72750         the Solaris 11 bug.
72752 2012-01-08  Bruno Haible  <bruno@clisp.org>
72754         doc: Update for Solaris 11.0.
72755         * doc/*/*.texi: Mention Solaris 11.0 where appropriate.
72756         * m4/printf.m4: Update comments.
72758 2012-01-08  Bruno Haible  <bruno@clisp.org>
72760         mktime: Avoid compilation error on Solaris 11.
72761         * lib/mktime.c (WRAPV): Define to 0 on all non-glibc systems.
72763 2012-01-08  Bruno Haible  <bruno@clisp.org>
72765         doc: Small fix.
72766         * doc/posix-headers/nl_types.texi: Correct platforms list.
72768 2012-01-08  Simon Josefsson  <simon@josefsson.org>
72770         Add lgpl-3.0 module.
72771         * MODULES.html.sh (Support for building documentation): Add
72772         lgpl-3.0.
72773         * modules/lgpl-3.0: New file.
72775 2012-01-08  Jim Meyering  <meyering@redhat.com>
72777         select.c: indent with spaces, not TABs
72778         * lib/select.c (windows_poll_handle): Indent with spaces, not TABs.
72780 2012-01-07  Paolo Bonzini  <bonzini@gnu.org>
72782         quotearg: do not use grave accent for left quote
72783         * lib/quotearg.c (gettext_quote): Map "`" to "'" for
72784         locale_quoting_style.
72785         (quotearg_buffer_restyled): Fix example.
72786         * tests/test-quotearg-simple.c (results_g): Adjust test vectors.
72788 2012-01-07  Paolo Bonzini  <bonzini@gnu.org>
72790         quotearg: fall back to Unicode single quotes in UTF-8, GB-18030 locales
72791         Most programs do not have translation catalogs for English and much
72792         less separate catalogs for British and American English.  Drop the
72793         suggestion to translators about these two, and provide it
72794         automatically for Unicode locales.  Like most programs, even those
72795         using American English, we use single quotation marks.  This conflicts
72796         with the American typographic convention, but works better when you
72797         cite the entire error message within double quotes.  It also tries not
72798         to clash with established practice and with what non-gnulib programs
72799         will usually do.
72800         * lib/quotearg.c (gettext_quote): Hard-code U+2018 and U+2019 when
72801         using an UTF-8 or GB-18030 locale.  The list of other locales with
72802         quotes was provided by Bruno Haible.
72803         (quotearg_buffer_restyled): Adjust instructions to translators.
72804         * lib/quotearg.h (locale_quoting_style): Do not put an example in the
72805         text, since this would be wrong when using Unicode.
72806         * modules/quotearg: Depend on c-strcaseeq.
72808 2012-01-07  Paolo Bonzini  <bonzini@gnu.org>
72810         quotearg: fix Wikipedia link
72811         * lib/quotearg.c (quotearg_buffer_restyled): Fix link to Wikipedia.
72813 2012-01-07  Simon Josefsson  <simon@josefsson.org>
72815         Fix for mingw with MSVC9.
72816         * m4/ld-version-script.m4: Check that compiler rejects version
72817         scripts with syntax errors.  Reported by Bruno Haible
72818         <bruno@clisp.org>.
72820 2012-01-06  Bruno Haible  <bruno@clisp.org>
72822         Talk about "native Windows API", not "Woe32".
72823         * lib/accept4.c: Update comments to mention native Windows.
72824         * lib/execute.c: Likewise.
72825         * lib/fatal-signal.c: Likewise.
72826         * lib/localcharset.c: Likewise.
72827         * lib/nanosleep.c: Likewise.
72828         * lib/nl_langinfo.c: Likewise.
72829         * lib/pclose.c: Likewise.
72830         * lib/pipe-filter-gi.c: Likewise.
72831         * lib/pipe-filter-ii.c: Likewise.
72832         * lib/pipe.c: Likewise.
72833         * lib/pipe2.c: Likewise.
72834         * lib/popen.c: Likewise.
72835         * lib/progreloc.c: Likewise.
72836         * lib/relocatable.c: Likewise.
72837         * lib/sigaction.c: Likewise.
72838         * lib/sigprocmask.c: Likewise.
72839         * lib/spawn-pipe.h: Likewise.
72840         * lib/spawn-pipe.c: Likewise.
72841         * lib/spawni.c: Likewise.
72842         * lib/stat-time.h: Likewise.
72843         * lib/w32spawn.h: Likewise.
72844         * tests/test-isatty.c: Likewise.
72845         * lib/config.charset: More comments.
72846         * doc/gnulib-intro.texi: Mention native Windows.
72847         * doc/posix-functions/_Exit_C99.texi: Likewise.
72848         * doc/posix-headers/fcntl.texi: Likewise.
72850 2012-01-06  Guillem Jover  <guillem@hadrons.org>  (tiny change)
72852         argp: Avoid crash if translator uses % characters in a translation.
72853         * lib/argp-parse.c (argp_version_parser): Use a "%s" format string.
72854         Reported by Mats Erik Andersson <gnu@gisladisker.se>.
72856 2012-01-06  Paul Eggert  <eggert@cs.ucla.edu>
72858         doc: C11 and C++11 are now official
72859         * doc/posix-headers/assert.texi, doc/posix-headers/stdalign.texi:
72860         * doc/verify.texi, stdalign.in.h, verify.h, m4/gnulib-common.m4:
72861         * m4/stdalign.m4, modules/assert-h, modules/snippet/_Noreturn:
72862         * modules/stdalign:
72863         Replace references to draft C1X to C11, and to draft C++0X to C++11.
72865 2012-01-06  Bruno Haible  <bruno@clisp.org>
72867         uc-is-grapheme-break tests: Tweak.
72868         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Fix an error
72869         message.
72871 2012-01-06  Bruno Haible  <bruno@clisp.org>
72873         test-init.sh: correct the test for diff -u
72874         * tests/test-init.sh: Also redirect stdout to /dev/null.
72876 2012-01-05  Paul Eggert  <eggert@cs.ucla.edu>
72878         Use ', not `, for quoting output.
72879         * build-aux/announce-gen (usage, sizes, print_news_deltas)
72880         (print_changelog_deltas, get_tool_versions, main program):
72881         * build-aux/git-version-gen:
72882         * build-aux/gitlog-to-changelog (usage, parse_amend_file):
72883         * build-aux/move-if-change (help):
72884         * build-aux/useless-if-before-free (usage, main program):
72885         * check-module (parse_module_file, usage)
72886         (find_included_lib_files, check_module):
72887         * lib/argmatch.c (main) [TEST]:
72888         * lib/argp-help.c (_help):
72889         * lib/getopt1.c (main) [TEST]:
72890         * lib/git-merge-changelog.c (usage):
72891         * lib/xstrtol-error.c (xstrtol_error):
72892         * m4/alloca.m4 (_AC_LIBOBJ_ALLOCA):
72893         * m4/argz.m4 (gl_FUNC_ARGZ):
72894         * m4/bison.m4 (gl_BISON):
72895         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU):
72896         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS):
72897         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
72898         * m4/fpending.m4 (gl_PREREQ_FPENDING):
72899         * m4/gc-random.m4 (gl_GC_RANDOM):
72900         * m4/intl.m4 (gt_CHECK_DECL):
72901         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK):
72902         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT)
72903         (AC_TYPE_UNSIGNED_LONG_LONG_INT):
72904         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS):
72905         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK):
72906         * m4/onceonly.m4 (AC_CHECK_FUNCS_ONCE):
72907         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION):
72908         * tests/test-dirname.c (main):
72909         * tests/test-getpass.c (main):
72910         * tests/test-iconvme.c (main):
72911         * tests/test-parse-datetime.c (LOG):
72912         * tests/test-xstrtoimax.sh:
72913         * tests/test-xstrtol.sh:
72914         * tests/test-xstrtoll.sh:
72915         * tests/test-xstrtoumax.sh:
72916         * tests/unigbrk/test-uc-is-grapheme-break.c (main):
72917         * top/GNUmakefile (abort-due-to-no-makefile):
72918         Quote 'like this', not `like this', as per the recent change to
72919         the GNU coding standards.
72921 2012-01-05  Bruno Haible  <bruno@clisp.org>
72923         strtoimax: Don't force a replacement on systems where intmax_t is int.
72924         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Use a different test if
72925         'intmax_t' is not larger than 'int'.
72926         Reported by Pádraig Brady <P@draigBrady.com>.
72928 2012-01-05  Bruno Haible  <bruno@clisp.org>
72930         doc: Mention NetBSD bugs.
72931         * doc/posix-functions/*printf.texi: Mention a NetBSD 5.1 bug.
72932         * doc/posix-functions/nl_langinfo.texi: Mention another NetBSD 5.1 bug.
72934 2012-01-05  Bruno Haible  <bruno@clisp.org>
72936         strtoumax tests: Enhance tests.
72937         * tests/test-strtoumax.c (main): Add tests for large values.
72939 2012-01-05  Bruno Haible  <bruno@clisp.org>
72941         strtoimax: Work around AIX 5.1 bug.
72942         * lib/inttypes.in.h (strtoimax): Allow overriding the system's
72943         definition.
72944         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Check against the AIX 5.1 bug.
72945         Set HAVE_STRTOIMAX.
72946         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Initialize
72947         REPLACE_STRTOIMAX.
72948         * modules/inttypes-incomplete (Makefile.am): Substitute
72949         REPLACE_STRTOIMAX.
72950         * modules/strtoimax (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
72951         (configure.ac): Test HAVE_STRTOIMAX, REPLACE_STRTOIMAX.
72952         (Depends-on): Update conditions.
72953         * tests/test-strtoimax.c (main): Add tests for large values.
72954         * doc/posix-functions/strtoimax.texi: Mention the AIX 5.1 bug.
72956 2012-01-05  Bruno Haible  <bruno@clisp.org>
72958         inttypes: Modernize.
72959         * lib/inttypes.in.h (strtoimax, strtoumax): Use the C++ safe idioms.
72960         * modules/inttypes-incomplete (Depends-on): Add snippet/c++defs.
72961         (Makefile.am): Update inttypes.h rule.
72963 2012-01-05  Jim Meyering  <meyering@redhat.com>
72965         init.sh: don't waste a subshell just to redirect stderr
72966         * tests/init.sh: In testing for diff -u and diff -c, use a
72967         stderr-redirecting exec inside `...` rather than a subshell.
72969         test-init.sh: avoid failure on HP-UX 11.00
72970         * tests/test-init.sh: Skip "diff -u"-comparing step when compare
72971         resolves to diff -c or cmp.  Reported by Bruno Haible.
72973 2012-01-05  Bruno Haible  <bruno@clisp.org>
72975         Tests for module 'strtoull'.
72976         * modules/strtoull-tests: New file.
72977         * tests/test-strtoull.c: New file, based on tests/test-strtoumax.c.
72979 2012-01-05  Bruno Haible  <bruno@clisp.org>
72981         Tests for module 'strtoll'.
72982         * modules/strtoll-tests: New file.
72983         * tests/test-strtoll.c: New file, based on tests/test-strtoimax.c.
72985 2012-01-05  Bruno Haible  <bruno@clisp.org>
72987         Tests for module 'strtoul'.
72988         * modules/strtoul-tests: New file.
72989         * tests/test-strtoul.c: New file, based on tests/test-strtoumax.c.
72991 2012-01-05  Bruno Haible  <bruno@clisp.org>
72993         Tests for module 'strtol'.
72994         * modules/strtol-tests: New file.
72995         * tests/test-strtol.c: New file, based on tests/test-strtoimax.c.
72997 2012-01-04  Jim Meyering  <meyering@redhat.com>
72999         test-init.sh: accommodate Solaris 5.10's different diff -u output
73000         * tests/test-init.sh: Also exempt @@ lines from the comparison
73001         of diff output, since Solaris 5.10 and GNU diff formats differ.
73002         Reported by Stefano Lattarini.
73004 2012-01-04  Paul Eggert  <eggert@cs.ucla.edu>
73006         test-posixtm: don't assume signed integer wraparound
73007         * tests/test-posixtm.c (main): Don't assume wraparound semantics
73008         after signed integer overflow.  Inspired by (though it may not
73009         fix) Bruno Haible's bug report in
73010         <http://lists.gnu.org/r/bug-gnulib/2012-01/msg00066.html>.
73012         Spell out "Windows 9x" and "Windows XP".
73013         * lib/poll.c, lib/select.c: In comments, replace "Win9x" with
73014         "Windows 9x" and "WinXP" with "Windows XP".
73016 2012-01-04  Jim Meyering  <meyering@redhat.com>
73018         test-vc-list-files-cvs.sh: remove obsolete comment
73019         * tests/test-vc-list-files-cvs.sh: Remove obsolete comment about
73020         double exit.  Now that's all encapsulated via skip_ and Exit.
73022 2012-01-04  Bruno Haible  <bruno@clisp.org>
73024         Talk about "native Windows API", not "Win32".
73025         * lib/classpath.c: Update comments to mention native Windows.
73026         * lib/csharpexec.c: Likewise.
73027         * lib/dup2.c: Likewise.
73028         * lib/error.c: Likewise.
73029         * lib/fcntl.c: Likewise.
73030         * lib/filename.h: Likewise.
73031         * lib/findprog.c: Likewise.
73032         * lib/get-rusage-as.c: Likewise.
73033         * lib/get-rusage-data.c: Likewise.
73034         * lib/getpagesize.c: Likewise.
73035         * lib/javaexec.c: Likewise.
73036         * lib/msvc-inval.c: Likewise.
73037         * lib/msvc-nothrow.c: Likewise.
73038         * lib/nanosleep.c: Likewise.
73039         * lib/nonblocking.c: Likewise.
73040         * lib/printf-parse.c: Likewise.
73041         * lib/setlocale.c: Likewise.
73042         * lib/sigaction.c: Likewise.
73043         * lib/strerror_r.c: Likewise.
73044         * lib/tmpdir.c: Likewise.
73045         * lib/vasnprintf.c: Likewise.
73046         * lib/w32spawn.h: Likewise.
73047         * lib/waitpid.c: Likewise.
73048         * lib/stdio.in.h (fdopen, fopen, freopen): Likewise.
73049         * m4/locale-ar.m4: Likewise.
73050         * m4/locale-fr.m4: Likewise.
73051         * m4/locale-ja.m4: Likewise.
73052         * m4/locale-tr.m4: Likewise.
73053         * m4/locale-zh.m4: Likewise.
73054         * m4/printf.m4: Likewise.
73055         * tests/test-cloexec.c: Likewise.
73056         * tests/test-copy-acl.sh: Likewise.
73057         * tests/test-copy-file.sh: Likewise.
73058         * tests/test-file-has-acl.sh: Likewise.
73059         * tests/test-set-mode-acl.sh: Likewise.
73060         * tests/test-dup-safer.c: Likewise.
73061         * tests/test-dup2.c: Likewise.
73062         * tests/test-dup3.c: Likewise.
73063         * tests/test-fcntl.c: Likewise.
73064         * tests/test-nonblocking-pipe.h: Likewise.
73065         * tests/test-nonblocking-socket.h: Likewise.
73066         * tests/test-pipe.c: Likewise.
73067         * tests/test-pipe2.c: Likewise.
73068         * tests/test-spawn-pipe-child.c: Likewise.
73069         * doc/acl-resources.txt: Likewise.
73070         * lib/getaddrinfo.c (WINDOWS_NATIVE): Renamed from WIN32_NATIVE.
73071         * tests/test-poll.c (WINDOWS_NATIVE): Likewise.
73072         * tests/test-select.h (WINDOWS_NATIVE): Likewise.
73073         * lib/localcharset.c: Update comments to mention native Windows.
73074         (WINDOWS_NATIVE): Renamed from WIN32_NATIVE.
73075         * lib/localename.c: Likewise.
73076         * lib/progreloc.c: Likewise.
73077         * lib/relocatable.c: Likewise.
73078         * lib/poll.c (WINDOWS_NATIVE): Renamed from WIN32_NATIVE.
73079         (windows_compute_revents): Renamed from win32_compute_revents.
73080         (windows_compute_revents_socket): Renamed from
73081         win32_compute_revents_socket.
73082         * lib/select.c: Update comments to mention native Windows.
73083         (windows_poll_handle): Renamed from win32_poll_handle.
73084         * m4/threadlib.m4: Update comments to mention native Windows.
73085         (gl_THREADLIB_EARLY_BODY, gl_THREADLIB_BODY): Expect
73086         --enable-threads=windows instead of --enable-threads=win32. Set
73087         USE_WINDOWS_THREADS, not USE_WIN32_THREADS.
73088         * lib/glthread/lock.h: Update comments to mention native Windows.
73089         (USE_WINDOWS_THREADS): Renamed from USE_WIN32_THREADS.
73090         * lib/glthread/lock.c (USE_WINDOWS_THREADS): Renamed from
73091         USE_WIN32_THREADS.
73092         * lib/glthread/cond.h (USE_WINDOWS_THREADS): Likewise.
73093         * lib/glthread/cond.c (USE_WINDOWS_THREADS): Likewise.
73094         * lib/glthread/thread.h (USE_WINDOWS_THREADS): Likewise.
73095         * lib/glthread/thread.c (USE_WINDOWS_THREADS): Likewise.
73096         * lib/glthread/tls.h (USE_WINDOWS_THREADS): Likewise.
73097         * lib/glthread/tls.c (USE_WINDOWS_THREADS): Likewise.
73098         * lib/glthread/yield.h (USE_WINDOWS_THREADS): Likewise.
73099         * tests/test-cond.c (USE_WINDOWS_THREADS): Likewise.
73100         * tests/test-thread_create.c (USE_WINDOWS_THREADS): Likewise.
73101         * tests/test-lock.c (USE_WINDOWS_THREADS): Likewise.
73102         (TEST_WINDOWS_THREADS): Renamed from TEST_WIN32_THREADS.
73103         * tests/test-tls.c: Likewise.
73104         Rationale:
73105         Microsoft renamed the "Win32 API" to "Windows API", as it is available
73106         on both 32-bit and 64-bit Windows systems.
73107         But in gnulib, we treat Cygwin like a Unix platform, therefore the main
73108         line of distinction is between "native Windows" on one side and Unix/
73109         POSIX systems on the other side. More details in
73110         <https://lists.gnu.org/r/bug-gnulib/2012-01/msg00027.html>.
73111         Suggested by Paul Eggert.
73113 2012-01-03  Bruno Haible  <bruno@clisp.org>
73115         isatty: Support for MSVC 9.
73116         * doc/posix-functions/isatty.texi: Mention the MSVC problem.
73117         * lib/isatty.c: Include <errno.h>, msvc-inval.h.
73118         (_isatty_nothrow): New function.
73119         (isatty): Use it instead of _isatty.
73120         (IsConsoleHandle): Add comment, from Paolo Bonzini.
73121         * lib/poll.c (IsConsoleHandle): Likewise.
73122         * lib/select.c (IsConsoleHandle): Likewise.
73123         * m4/isatty.m4 (gl_FUNC_ISATTY): Fix comment. Reported by Eli Zaretskii.
73124         (gl_PREREQ_ISATTY): New macro.
73125         * modules/isatty (Depends-on): Add msvc-inval.
73126         (configure.ac): Invoke gl_PREREQ_ISATTY.
73128 2012-01-03  Jim Meyering  <meyering@redhat.com>
73130         maint.mk: remove temporary transition aid from over 1.5 years ago
73131         * top/maint.mk (_prohibit_regexp): Remove definition whose sole
73132         purpose was to aid in the transition (avoiding silent malfunction)
73133         from that old name to the new _sc_search_regexp.  This shim was
73134         added by commit 219c504b.
73136         init.sh: do not try to accommodate compare arguments starting with "-"
73137         * tests/init.sh (compare_dev_null_): Do not try to accommodate
73138         compare arguments that start with "-".  Besides, we do not worry
73139         about this when invoking diff or cmp; why start now with sed?
73140         Using "--" to separate options from argument would trigger sed
73141         failure in at least Solaris 7, HP-UX 11.00, IRIX 6.5, FreeBSD 6.4,
73142         OpenBSD 4.9 and NetBSD 5.1.  Reported by Bruno Haible.
73144 2012-01-02  Bruno Haible  <bruno@clisp.org>
73146         Enhance tests for module 'isatty'.
73147         * modules/isatty-tests (Depends-on): Add pipe-posix.
73148         * tests/test-isatty.c: Include <fcntl.h>.
73149         (DEV_NULL): New macro.
73150         (main): Test the resut of isatty() also on regular files, pipes, and
73151         /dev/null.
73153         New module 'isatty'.
73154         * lib/unistd.in.h (isatty): New declaration.
73155         * lib/isatty.c: New file, based on an idea of
73156         Bastien Roucariès <roucaries.bastien@gmail.com>.
73157         * m4/isatty.m4: New file.
73158         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether isatty is declared.
73159         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ISATTY, REPLACE_ISATTY.
73160         * modules/unistd (Makefile.am): Substitute GNULIB_ISATTY,
73161         REPLACE_ISATTY.
73162         * modules/isatty: New file.
73163         * doc/posix-functions/isatty.texi: Mention the new module.
73164         Suggested by Paolo Bonzini.
73166 2012-01-02  Bruno Haible  <bruno@clisp.org>
73168         canonicalize: Tweak 2011-12-29 commit.
73169         * lib/canonicalize.c (canonicalize_filename_mode): Fix typo in comment.
73170         * lib/canonicalize.h (canonicalize_filename_mode): Update specification.
73172 2012-01-02  Jim Meyering  <meyering@redhat.com>
73174         gitlog-to-changelog: describe input syntax in --help output
73175         * build-aux/gitlog-to-changelog (usage) [SPECIAL SYNTAX]: New section.
73177         gitlog-to-changelog: fix typo in --help: show backslash before email @
73178         * build-aux/gitlog-to-changelog (usage): An "@" was backslash-escaped
73179         in sources, but not in actual output.
73181 2011-12-30  Jim Meyering  <meyering@redhat.com>
73183         gitlog-to-changelog: don't malfunction when name contains %-directive
73184         * build-aux/gitlog-to-changelog (main): Don't let a %-directive
73185         in a name string cause trouble.  E.g., with a user name of "%s",
73186         gitlog-to-changelog would fail with "Missing argument in sprintf at..."
73188 2011-12-30  Gary V. Vaughan  <gary@gnu.org>
73190         gitlog-to-changelog: Copyright-paperwork-exempt: yes == (tiny change)
73191         * build-aux/gitlog-to-changelog (main): Map the string, at beginning
73192         of line in a git commit log, "Copyright-paperwork-exempt: yes", to
73193         the "  (tiny change)" notation that is appended to the standard
73194         ChangeLog "date  name  email" header line.
73196 2012-01-01  Jim Meyering  <meyering@redhat.com>
73198         test-framework-sh: init.sh: fix "make dist" failure
73199         When using gnulib-tool's --with-tests option and any module that
73200         depends on test-framework-sh, "make dist" would fail due to the
73201         lack of init.sh *in lib/*.  The EXTRA_DIST += init.sh is required
73202         in the gltests directory, and not in the gllib/ directory.
73203         One way to work around that is to move the EXTRA_DIST += init.sh
73204         from the primary module to the -tests one:
73205         * modules/test-framework-sh-tests (EXTRA_DIST): Add init.sh here, ...
73206         * modules/test-framework-sh (Makefile.am): ...not here.
73207         Reported by Tom G. Christensen in
73208         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/29519
73210         version-etc: update copyright year reported by --version
73211         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2012.
73213 2011-12-31  Pádraig Brady  <P@draigBrady.com>
73215         canonicalize: only stat() if required
73216         * lib/canonicalize.c (canonicalize_filename_mode):
73217         Avoid calling l?stat() when both CAN_MISSING,
73218         and CAN_NOLINKS are set, as we neither need
73219         to resolve symlinks or test component existence.
73221 2011-12-31  Paul Eggert  <eggert@cs.ucla.edu>
73223         doc: cover st_ino issues once; add OpenVMS etc.
73224         * doc/posix-functions/stat.texi (stat):
73225         * doc/posix-functions/lstat.texi (lstat):
73226         * doc/posix-functions/fstatat.texi (fstatat):
73227         * doc/posix-functions/fstat.texi (fstat):
73228         Move general 'struct stat' stuff to sys_stat.texi,
73229         leaving behind a pointer.
73230         * doc/posix-headers/sys_stat.texi (sys/stat.h):
73231         Merge duplicate info about 'struct stat' problems into here.
73232         Mention issues with OpenVMS, GNU/Linux NFS, NetApp, ClearCase,
73233         and suggest partial workarounds.
73235         same-inode: port to OpenVMS
73236         * lib/same-inode.h (SAME_INODE): Port to OpenVMS by checking all
73237         three st_ino values.
73239 2011-12-30  Pádraig Brady  <P@draigBrady.com>
73241         canonicalize: fix references to stat() and lstat()
73242         * lib/canonicalize.c (canonicalize_filename_mode):
73243         Ensure references always resolve to a replacement
73244         function if required (even via a macro).
73246 2011-12-30  Jim Meyering  <meyering@redhat.com>
73248         gitlog-to-changelog: remove a little duplication
73249         * build-aux/gitlog-to-changelog (main): Grep @lines once,
73250         rather than twice.
73252 2011-12-29  Pádraig Brady  <P@draigBrady.com>
73254         canonicalize: add support for not resolving symlinks
73255         * lib/canonicalize.h: Add the CAN_NOLINKS flag to
73256         indicate we don't want to follow symlinks.  Also
73257         provide CAN_MODE_MASK to aid setting these existing
73258         mutually exclusive values.
73259         * lib/canonicalize.c (canonicalize_filename_mode):
73260         Extract the flags from can_mode parameter, which
73261         are currently just used to select between stat()
73262         and lstat().  Also ensure that mutually exclusive
73263         values are flagged immediately as invalid.
73264         * tests/test-canonicalize.c: Verify symlinks are
73265         not followed, and that invalid flag combinations
73266         are diagnosed.
73268 2011-12-25  Jim Meyering  <meyering@redhat.com>
73270         gitlog-to-changelog: do not clump multi-paragraph entries
73271         Identical header lines (date,name,email+coauthors) are suppressed,
73272         thus putting all entries with those same characteristics under
73273         a single header.  However, when a log entry consists of two or
73274         more paragraphs, it may not be clear where it starts and ends.
73275         This change makes it so that such an entry is always separated
73276         from others by a header line, even when that header would
73277         otherwise be suppressed.
73278         * build-aux/gitlog-to-changelog: Implement the above.
73279         Inspired by a related request from Stefano Lattarini in
73280         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/29456
73282 2011-12-25  Paul Eggert  <eggert@cs.ucla.edu>
73284         announce-gen: fix `cmd' typo in diagnostic
73285         * build-aux/announce-gen (print_changelog_deltas): Fix typo in
73286         diagnostic: a missing '$' meant that the command was not output.
73288 2011-12-23  Jim Meyering  <meyering@redhat.com>
73290         test-framework-sh: distribute init.sh
73291         * modules/test-framework-sh (EXTRA_DIST): Append init.sh.
73292         Otherwise, "make -C gnulib-tests check" (at least in grep) would
73293         fail due to the lack of init.sh.
73295         maint: remove explicit Files: tests/init.sh; depend on test-framework-sh
73296         * modules/atexit-tests: Rather than listing tests/init.sh,
73297         now that there's a module for it, simply depend on that new module.
73298         * modules/closein-tests: Likewise.
73299         * modules/exclude-tests: Likewise.
73300         * modules/getcwd-tests: Likewise.
73301         * modules/perror-tests: Likewise.
73302         * modules/pread-tests: Likewise.
73303         * modules/pwrite-tests: Likewise.
73304         * modules/vc-list-files-tests: Likewise.
73305         * modules/verify-tests: Likewise.
73306         * modules/xalloc-die-tests: Likewise.
73307         * modules/xstrtoimax-tests: Likewise.
73308         * modules/xstrtol-tests: Likewise.
73309         * modules/xstrtoll-tests: Likewise.
73310         * modules/xstrtoumax-tests: Likewise.
73311         * modules/yesno-tests: Likewise.
73313 2011-12-22  Jim Meyering  <meyering@redhat.com>
73315         test-framework-sh: add minimal tests of init.sh's compare function
73316         * modules/test-framework-sh-tests: New file.
73317         * tests/test-init.sh: New file.
73319         test-framework-sh: new module
73320         * modules/test-framework-sh: New file.
73321         * MODULES.html.sh (Support for maintaining and releasing projects):
73322         List it.
73324         init.sh: do not emit simulated diff output to stderr
73325         * tests/init.sh (compare_dev_null_): Print to stdout, not stderr.
73327 2011-12-22  Reuben Thomas  <rrt@sc3d.org>
73329         .gitignore: ignore gnulib.dvi and regex.info
73330         * doc/.gitignore:add gnulib.dvi and regex.info
73332 2011-12-22  Jim Meyering  <meyering@redhat.com>
73334         init.sh: correct previous change
73335         * tests/init.sh (compare): My previous change was wrong.
73336         Don't clobber "$?".  Spotted by Stefano Lattarini and Pádraig Brady.
73338         init.sh: avoid unwarranted test failure when using "set -e"
73339         * tests/init.sh (compare): Ignore nonzero exit from compare_dev_null_.
73340         Otherwise, in a test script that uses "set -e" (like many in vc-dwim)
73341         a use like "compare exp out" would get evoke an unconditional failure.
73343 2011-12-21  Alfred M. Szmidt  <ams@gnu.org>
73345         bootstrap: fix it to honor $ACLOCAL_FLAGS once again
73346         The 2011-12-17 change, commit 767ccd40, replaced a manual invocation
73347         of aclocal that used explicit $ACLOCAL_FLAGS with an invocation of
73348         autoreconf that did not.
73349         * build-aux/bootstrap: Use $ACLOCAL_FLAGS when invoking autoreconf.
73350         Reported by Mats Erik Andersson <gnu@gisladisker.se>.
73352 2011-12-17  Jim Meyering  <meyering@redhat.com>
73354         bootstrap: remove some now-unneeded code
73355         This script arose back when gnulib-tool was young.
73356         Since then, it has seen improvements that render much of this
73357         script unnecessary.  In particular, it can now make symlinks
73358         to the files it uses.  Also, I no longer see as much value in
73359         marking files as read-only via comments.
73360         If you relied on the symlink-creation feature of the preceding
73361         version of this script, you can get most of that functionality
73362         by adding the --symlink option to the definition of
73363         gnulib_tool_option_extras in your bootstrap.conf file.
73364         * build-aux/bootstrap (AUTOPOINT, AUTORECONF): Factor out definitions.
73365         Run autopoint and libtoolize *before* gnulib-tool.
73366         After it, run an abbreviated autoreconf, rather than a loop around
73367         all tools.
73368         (slirp, bt_mark_as_generated): Remove functions.
73370 2011-12-18  Paul Eggert  <eggert@cs.ucla.edu>
73372         ftoastr: fix typo
73373         * lib/ftoastr.h: Fix misspelling in comment.
73375 2011-12-18  Reuben Thomas  <rrt@sc3d.org>
73377         * top/README-release: fix punctuation.
73379 2011-12-17  Jim Meyering  <meyering@redhat.com>
73381         bootstrap: correct the recent buildreq change
73382         The 2011-12-07 commit, 39f5f1e4, omitted some '*'s, and thus
73383         had no effect.
73384         * build-aux/bootstrap (buildreq): Bracket each search term with
73385         "*...*", so that the shell "case" statement works as intended.
73386         Add comments.
73388 2011-12-17  Bernhard Voelker  <mail@bernhard-voelker.de>
73390         build: let bootstrap resort to wget when downloading .po files
73391         * build-aux/bootstrap (download_po_files): Fallback to wget when
73392         downloading the .po files via rsync fails.  This is necessary to
73393         bootstrap from behind a strict firewall.
73395 2011-12-15  Paul Eggert  <eggert@cs.ucla.edu>
73397         stdint: don't assume C++11 when compiling with g++
73398         Problem reported for glibc 2.14 and g++ by Alexander V. Lukyanov in
73399         <http://lists.gnu.org/r/bug-gnulib/2011-12/msg00099.html>.
73400         * m4/stdint.m4 (gl_STDINT_H): Don't go to extra work to make it
73401         work also in C++ before C++11, as that improperly inhibits
73402         generating a substitute stdint.h for that case.
73404 2011-12-15  Paul Eggert  <eggert@cs.ucla.edu>
73406         alloca: protect comment from gnulib-tool
73407         * lib/alloca.c: Change "GCC version 2" to "GCC 2" in comment, so
73408         that gnulib-tool doesn't think it's a license, and munge it to
73409         say "GCC version 3".
73411 2011-12-15  Ludovic Courtès  <ludo@gnu.org>  (tiny change)
73413         localcharset: Use an absolute path in TESTS_ENVIRONMENT.
73414         * modules/localcharset (LOCALCHARSET_TESTS_ENVIRONMENT): Use
73415         $(abs_top_builddir) instead of $(top_builddir).
73417 2011-12-14  Alex Nelson  <ajnelson@cs.ucsc.edu>  (tiny change)
73419         strftime-tests: also test nanoseconds
73420         * tests/test-strftime.c (T): Add a test of %N.
73422 2011-12-13  Paul Eggert  <eggert@cs.ucla.edu>
73424         inttypes, stdint: add C++11 support
73425         C++11 says there's no need to define __STDC_CONSTANT_MACROS etc.
73426         when including inttypes.h and stdint.h.  Support this change to
73427         the standard.
73428         * doc/posix-headers/inttypes.texi (inttypes.h):
73429         * doc/posix-headers/stdint.texi (stdint.h): Document this.
73430         * lib/inttypes.in.h (__STDC_FORMAT_MACROS) [! __cplusplus]:
73431         Define if not defined already, for the benefit of pre-C++11 hosts.
73432         Define the standard format macros (e.g., PRId8) always.
73433         * lib/stdint.in.h (__STDC_CONSTANT_MACROS, __STDC_LIMIT_MACROS):
73434         Likewise, if __cpluspus.  Define the standard constant and limit
73435         macros (e.g., INT8_C, INT8_MAX) always.
73436         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): Do not define
73437         GL_TRIGGER_STDC_LIMIT_MACROS or __STDC_LIMIT_MACROS; no longer needed.
73438         * m4/stdint.m4 (gl_STDINT_H): Update comments about these macros.
73439         * tests/test-inttypes.c (__STDC_LIMIT_MACROS, __STDC_CONSTANT_MACROS)
73440         (__STDC_FORMAT_MACROS): Do not define, since we assume C++11 API now.
73441         * tests/test-stdint.c (__STDC_LIMIT_MACROS, __STDC_CONSTANT_MACROS):
73442         Likewise.
73444 2011-12-12  Paul Eggert  <eggert@cs.ucla.edu>
73446         nonblocking tests: Fix test failure on Linux/PPC.
73447         Suggested by Prerna Saxena in
73448         <http://lists.gnu.org/r/bug-gnulib/2011-12/msg00080.html>.
73449         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/PPC64]:
73450         Set to 1100000.
73452 2011-12-12  Jim Meyering  <meyering@redhat.com>
73454         argmatch: don't hard-code `' when listing valid option arguments
73455         * lib/argmatch.c (argmatch_valid): Don't hard-code `%s'.  Instead,
73456         use the quote function to add quotes.  Use fputs rather than
73457         fprintf for the format string with no format directive.
73459 2011-12-07  Eric Blake  <eblake@redhat.com>
73461         bootstrap: detect tools required by gnulib-tool
73462         * build-aux/bootstrap (buildreq): Provide minimum implicit
73463         dependencies.
73464         * DEPENDENCIES: Mention patch as a prereq.
73466 2011-12-04  Bruno Haible  <bruno@clisp.org>
73468         sethostname: Port to Windows platforms.
73469         * lib/sethostname.c: Provide an alternate implementation for Windows
73470         platforms.
73471         * tests/test-sethostname2.c (geteuid): Redefine on Cygwin.
73472         (main): Skip the test if sethostname() fails with EPERM. On Windows
73473         platforms, don't check the result of gethostname().
73475 2011-12-04  Bruno Haible  <bruno@clisp.org>
73476             Jim Meyering  <meyering@redhat.com>
73478         tests: Avoid spurious error message on platforms without mktemp program.
73479         * tests/init.sh (mktempd_): Run mktemp in a subcommand.
73481 2011-12-04  Bruno Haible  <bruno@clisp.org>
73483         sethostname: Fix documentation.
73484         * doc/glibc-functions/sethostname.texi: Move the Solaris problem to the
73485         "not fixed" section.
73487 2011-12-03  Bruno Haible  <bruno@clisp.org>
73489         gnulib-tool: Verify that the License field is present and non-empty.
73490         * gnulib-tool (func_get_license_raw): New function, extracted from
73491         func_get_license.
73492         (func_get_license): Use it. Warn if the module is not a test module and
73493         has no license.
73494         Suggested by Jim Meyering.
73496 2011-12-03  Bruno Haible  <bruno@clisp.org>
73498         sethostname tests: Fix link error on mingw.
73499         * tests/test-sethostname1.c: New file, extracted from
73500         tests/test-sethostname.c.
73501         * tests/test-sethostname2.c: New file, extracted from
73502         tests/test-sethostname.c.
73503         * tests/test-sethostname.c: Remove file.
73504         * modules/sethostname-tests (Files): Add tests/test-sethostname1.c,
73505         tests/test-sethostname2.c. Remove tests/test-sethostname.c.
73506         (Depends-on): Add gethostname.
73507         (Makefile.am): Compile both test-sethostname1 and test-sethostname2.
73508         Link the latter with $(GETHOSTNAME_LIB).
73510         sethostname tests: Fix compilation error on mingw.
73511         * tests/test-sethostname.c: Don't include <sys/types.h>.
73512         (geteuid): Use a dummy value without uid_t.
73513         * modules/sethostname-tests (Depends-on): Remove sys_types.
73515         sethostname tests: Avoid a gcc warning.
73516         * tests/test-sethostname.c (main): Remove an unused variable.
73518         Tweak last commit.
73519         * modules/sethostname-tests (Files): Sort by decreasing importance.
73520         (configure.ac): Check for geteuid.
73521         * tests/test-sethostname.c (main): Emit error messages to stderr. Skip
73522         the test when there's nothing to test. Drop an unnecessary cast.
73523         Improve an error message. Verify that the final sethostname() call
73524         succeeds.
73526 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
73528         Add a test suite for the sethostname module.
73529         * modules/sethostname-tests: New file.  A test program
73530         for the sethostname module.
73531         * tests/test-sethostname.c: Likewise.
73533 2011-12-03  Bruno Haible  <bruno@clisp.org>
73535         Tweak last commit.
73536         * lib/unistd.in.h (sethostname): Keep declarations in alphabetic order.
73537         Fix preprocessor directives indentation. Fix typos.
73538         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Keep alphabetic order.
73539         * modules/unistd (Makefile): Likewise.
73541 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
73543         Integrate the sethostname module into unistd.
73544         * lib/unistd.in.h: Integrate the SETHOSTNAME preprocessor handling
73545         into the unistd.h header.
73546         * m4/unistd_h.m4: Setup the autoconf handling for the SETHOSTNAME
73547         preprocessor directives.
73548         * modules/unistd: Setup the Makefile substitutions of the
73549         SETHOSTNAME preprocessor directives.
73551 2011-12-03  Bruno Haible  <bruno@clisp.org>
73553         Tweak last commit.
73554         * lib/sethostname.c: Don't include <string.h>.
73555         (sethostname): No need to copy the argument string to the stack. Don't
73556         call clearerr. Preserve errno when fprintf failed.
73557         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): Comment about HOST_NAME_MAX.
73558         Don't invoke AC_REPLACE_FUNCS.
73559         * modules/sethostname (Link): Remove empty section.
73560         * doc/glibc-functions/sethostname.texi: Gnulib does not fix the ENOSYS
73561         failure problem.
73563 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
73565         New module 'sethostname'.
73566         * lib/sethostname.c (sethostname): New file.  Provide sethostname
73567         for systems that lack it.
73568         * m4/sethostname.m4 (gl_FUNC_SETHOSTNAME): New file.  Detection of
73569         sethostname declaration and function.
73570         * modules/sethostname: New file.  Define the sethostname module.
73572 2011-12-03  Bruno Haible  <bruno@clisp.org>
73574         Tweak last commit.
73575         * m4/gethostname.m4 (gl_PREREQ_HOST_NAME_MAX): Trim blank line.
73577 2011-12-01  Ben Walton  <bwalton@artsci.utoronto.ca>
73579         Split the HOST_NAME_MAX detection into a separate m4 macro.
73580         * m4/gethostname.m4 (gl_PREREQ_HOST_NAME_MAX): Make this a separate
73581         macro so it can be used by the pending sethostname module.
73583 2011-12-03  Bruno Haible  <bruno@clisp.org>
73585         Fix module descriptions syntax.
73586         * modules/argv-iter (License): Fix syntax.
73587         * modules/di-set (License): Likewise.
73588         * modules/ino-map (License): Likewise.
73589         Reported by Stefano Lattarini <stefano.lattarini@gmail.com>.
73591 2011-12-02  Paul Eggert  <eggert@cs.ucla.edu>
73593         stdalign: port to Clang 3.0
73594         Problem reported by Simon Josefsson in
73595         <http://lists.gnu.org/r/bug-gnulib/2011-12/msg00005.html>.
73596         * doc/posix-headers/stdalign.texi (stdalign.h): Mention Clang 3.0,
73597         which has <stdalign.h> but which does not define alignof.
73598         * m4/stdalign.m4 (gl_STDALIGN_H): Check for Clang 3.0's problem.
73600 2011-12-01  Eric Blake  <eblake@redhat.com>
73602         mktempd: silence dd usage
73603         * build-aux/mktempd (rand_bytes): Silence dd.
73605 2011-11-30  Simon Josefsson  <simon@josefsson.org>
73607         manywarnings: Don't mention gcc version in docstring.
73608         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Doc fix.  Suggested by
73609         Jim Meyering <meyering@redhat.com>.
73611 2011-11-30  Jim Meyering  <meyering@redhat.com>
73613         hash: mark a few floating point constants with "f" suffix
73614         * lib/hash.c (DEFAULT_GROWTH_THRESHOLD, DEFAULT_GROWTH_FACTOR)
73615         (DEFAULT_SHRINK_THRESHOLD, DEFAULT_SHRINK_FACTOR): Mark literal
73616         floating point constants with "f", since they're destined to be
73617         saved/used as "float"s.
73619 2011-11-29  Paolo Bonzini  <bonzini@gnu.org>
73621         float tests: Correct and re-enable assertion about LDBL_MIN_EXP.
73622         * tests/test-float.c (test_long_double): Correct and re-enable the
73623         assertion about LDBL_MIN_EXP that was disabled on 2011-08-31.
73625 2011-11-29  Matthew Wala  <wala1@illinois.edu>  (tiny change)
73627         Avoid subtracting two pointers that don't point into the same block.
73628         * lib/argp-help.c (hol_append): Reorder pointer subtractions so that
73629         only pointers into the same memory block are subtracted. We cannot
73630         assume that sizeof (ptrdiff_t) == sizeof (void *).
73632 2011-11-29  Eric Blake  <eblake@redhat.com>
73634         maint.mk: add syntax check for use of compare from init.sh
73635         * top/maint.mk (sc_prohibit_reversed_compare_failure): New rule,
73636         moved here from coreutils.
73638         manywarnings: drop -Wunsuffixed-float-constants
73639         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): C99 does not allow
73640         '1.0D', which is the only way to silence this warning for 'double'.
73642 2011-11-29  Jim Meyering  <meyering@redhat.com>
73644         hash: mark compute_bucket_size with the pure attribute
73645         * lib/hash.c (compute_bucket_size): Use _GL_ATTRIBUTE_PURE.
73647         quotearg, propername: correct pragma guard expression
73648         * lib/quotearg.c: Enable pragma for gcc-4.6 and newer, not 4.3 and newer.
73649         * lib/propername.c: Likewise.  Reported by Bernhard Voelker.
73651 2011-11-28  Jim Meyering  <meyering@redhat.com>
73653         propername: do not mark proper_name with the const attribute
73654         * lib/propername.h (proper_name): Do *not* mark as _GL_ATTRIBUTE_CONST,
73655         since it examines data pointed to by its parameter.
73656         * lib/propername.c (proper_name): Instead, add a pragma to suppress
73657         the suggestion from -Wsuggest-attribute=const.
73659         propername: mark one more function as const
73660         * lib/propername.h (proper_name): Mark as _GL_ATTRIBUTE_CONST.
73662 2011-11-27  Jim Meyering  <meyering@redhat.com>
73664         mark functions with const and pure attributes
73666         Mark functions per suggestions from gcc-4.6 when using these options:
73667         -Wsuggest-attribute=pure -Wsuggest-attribute=const.
73668         Use gnulib's _GL_ATTRIBUTE_PURE and _GL_ATTRIBUTE_CONST macros.
73669         Follow these guidelines: when possible, apply the attribute to
73670         an extern declaration, not to its definition.  Apply it to the
73671         definition only when the definition is static.
73672         * lib/argmatch.h (argmatch, argmatch_to_argument): Mark.
73673         * lib/argv-iter.h (argv_iter_n_args): Likewise.
73674         * lib/base64.h (isbase64): Likewise.
73675         * lib/basename-lgpl.c (last_component, base_len): Likewise.
73676         * lib/c-ctype.h (c_isascii, c_isalnum, c_isalpha): Likewise.
73677         (c_isblank, c_iscntrl, c_isdigit, c_islower, c_isgraph): Likewise.
73678         (c_isprint, c_ispunct, c_isspace, c_isupper, c_isxdigit): Likewise.
73679         (c_tolower, c_toupper): Likewise.
73680         * lib/c-strcase.h (c_strcasecmp, c_strncasecmp): Likewise.
73681         * lib/chdir-long.c (find_non_slash): Likewise.
73682         * lib/dirname.h (base_len, dir_len, last_component): Likewise.
73683         * lib/exclude.h (fnmatch_pattern_has_wildcards): Likewise.
73684         * lib/file-type.h (file_type): Likewise.
73685         * lib/filenamecat-lgpl.c (longest_relative_suffix): Likewise.
73686         * lib/filevercmp.c (verrevcmp): Likewise.
73687         * lib/freadahead.h (freadahead): Likewise.
73688         * lib/fts.c (fts_maxarglen): Likewise.
73689         * lib/hash-pjw.h (hash_pjw): Likewise.
73690         * lib/hash-triple.h (triple_hash_no_name, triple_compare_ino_str):
73691         * lib/hash.c (is_prime, next_prime): Likewise.
73692         * lib/hash.c (hash_get_n_buckets, hash_get_n_buckets_used): Likewise.
73693         (hash_get_n_entries, hash_get_max_bucket_length): Likewise.
73694         (hash_table_ok, hash_get_first, hash_string): Likewise.
73695         (compute_bucket_size): Likewise.
73696         * lib/i-ring.h (i_ring_empty): Likewise.
73697         * lib/isnan.c (isnanl): Likewise.
73698         * lib/math.h (isnanl, rpl_isnanl): Likewise.
73699         * lib/memcasecmp.h (memcasecmp): Likewise.
73700         * lib/memchr2.h (memchr2): Likewise.
73701         * lib/memcmp2.h (memcmp2): Likewise.
73702         * lib/parse-datetime.y (lookup_zone): Likewise.
73703         * lib/sockets.h (gl_sockets_startup, gl_sockets_cleanup)
73704         [!WINDOWS_SOCKETS]: Likewise.
73705         * lib/strnlen1.h (strnlen1): Likewise.
73706         * lib/uniwidth.in.h (uc_width): Likewise.
73707         * lib/quotearg.c: Add pragma to avoid unwarranted suggestion from
73708         gcc's -Wsuggest-attribute=pure for quoting_options_from_style.
73709         (quoting_options_from_style): Add a comment.
73710         * lib/propername.h (proper_name): Add a comment.
73712 2011-11-27  Bruno Haible  <bruno@clisp.org>
73714         Remove unused macros from !_LIBC code in glibc-borrowed files.
73715         * lib/fnmatch.c (STRCOLL): Remove macro.
73716         * lib/fnmatch_loop.c (STRCOLL): Remove undef.
73717         * lib/glob.c (__stat, __readdir64): Remove macros.
73718         * lib/tempname.c (__open64, __xstat64): Remove macros.
73719         Suggested by Paul Eggert.
73721 2011-11-27  Bruno Haible  <bruno@clisp.org>
73723         getcwd: Fix link error on MSVC 9.
73724         * modules/getcwd (Depends-on): Add readdir, rewinddir.
73726 2011-11-27  Bruno Haible  <bruno@clisp.org>
73728         Don't set REPLACE_FOO to 1 if HAVE_FOO is 0.
73729         * m4/opendir.m4 (gl_FUNC_OPENDIR): Don't set REPLACE_OPENDIR to 1 if
73730         HAVE_OPENDIR is 0.
73731         * m4/closedir.m4 (gl_FUNC_CLOSEDIR): Don't set REPLACE_CLOSEDIR to 1 if
73732         HAVE_CLOSEDIR is 0.
73733         * m4/dup2.m4 (gl_FUNC_DUP2): Don't set REPLACE_DUP2 to 1 if HAVE_DUP2
73734         is 0.
73735         * m4/dup3.m4 (gl_FUNC_DUP3): Update comments.
73737 2011-11-27  Bruno Haible  <bruno@clisp.org>
73739         getcwd: Fix bug from 2011-08-17.
73740         * m4/getcwd.m4 (gl_FUNC_GETCWD): Set REPLACE_GETCWD to 1 only on
73741         platforms that need it.
73742         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Consider a return
73743         code of 4 to be a failure, not a success. This ensures that
73744         REPLACE_GETCWD becomes 1 on OpenBSD 4.9 and NetBSD 5.1.
73746 2011-11-27  Bruno Haible  <bruno@clisp.org>
73748         binary-io tests: Avoid test failure on mingw when libtool is used.
73749         * tests/test-binary-io.c (main): Don't remove t-bin-out2.tmp here.
73750         Don't verify the size of t-bin-out1.tmp here.
73751         * tests/test-binary-io.sh: Verify it here.
73752         Reported by Simon Josefsson.
73754 2011-11-26  Bruno Haible  <bruno@clisp.org>
73756         Fix conflict between two instantiations of module 'unistd'.
73757         * gnulib-tool (func_emit_autoconf_snippet): Substitute
73758         ${include_guard_prefix} also in the autoconf snippet.
73759         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX): Don't set GNULIB_UNISTD_H_GETOPT.
73760         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Don't initialize
73761         GNULIB_UNISTD_H_GETOPT.
73762         * modules/getopt-posix (configure.ac): Set the
73763         GNULIB_${gl_include_guard_prefix}_UNISTD_H_GETOPT variable.
73764         * modules/getopt-gnu (configure.ac): Likewise.
73765         * modules/unistd (Makefile.am): Change the substitution value of
73766         GNULIB_UNISTD_H_GETOPT to depend on the include guard prefix.
73767         Reported by Simon Josefsson.
73769 2011-11-25  Bruno Haible  <bruno@clisp.org>
73771         pagealign_alloc: Doc and comments.
73772         * doc/posix-functions/posix_memalign.texi: Refer to the pagealign_alloc
73773         module.
73774         * lib/pagealign_alloc.c (pagealign_alloc): Add comment.
73776 2011-11-25  Jim Meyering  <meyering@redhat.com>
73778         test-update-copyright.sh: avoid false-positive failure
73779         * tests/test-update-copyright.sh: Use $TMP.? (not $TMP.*), to work
73780         around false positive failure on Cygwin/Windows.  The latter was
73781         matching erroneously-created files with names like
73782         update-copyright.test-ex.4.bak.  Reported by Simon Josefsson.
73784 2011-11-25  Simon Josefsson  <simon@josefsson.org>
73786         valgrind-tests.m4: Avoid breakage if valgrind on bash fails.
73787         * m4/valgrind-tests.m4: Check that the parameters that will be
73788         used works, not just a subset of them.  Reported by Bruno Haible
73789         <bruno@clisp.org>.
73791 2011-11-24  Jim Meyering  <meyering@redhat.com>
73793         test-stdalign.c: comment out long double tests
73794         * tests/test-stdalign.c: Don't try to reduce alignment of long double
73795         variables.  That provokes errors like this from gcc-4.7.0 20111124:
73796         error: '_Alignas' specifiers cannot reduce alignment of \
73797         'static_longdouble_alignas'.
73799 2011-11-22  Jim Meyering  <meyering@redhat.com>
73801         init.sh: make "compare /dev/null FILE" output more readable
73802         * tests/init.sh (compare_): Document the preferred order of arguments.
73803         (emit_diff_u_header_): New function.
73804         (compare_dev_null_): Emit a simulated diff, rather than just the
73805         contents of the unexpected file.  Suggestion from Bruno Haible.
73807 2011-11-21  Jim Meyering  <meyering@redhat.com>
73808             Eric Blake  <eblake@redhat.com>
73810         init.sh: work around OSF/1 5.1's mishandling of /dev/null
73811         * tests/init.sh: Make our compare function slightly more portable.
73812         Reported by Bruno Haible in
73813         http://thread.gmane.org/gmane.comp.gnu.grep.bugs/4020
73815 2011-11-21  Simon Josefsson  <simon@josefsson.org>
73817         * m4/gnulib-common.m4 (_Noreturn): Check that _MSC_VER is defined
73818         before using it, in code that ends up in config.h.
73820 2011-11-20  Bruno Haible  <bruno@clisp.org>
73822         getcwd: Work around getcwd bug on AIX 5..7.
73823         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Require
73824         AC_CANONICAL_HOST. Assign exit code 31 to the bug seen on AIX 5.1..7.1.
73825         Use a different value for gl_cv_func_getcwd_path_max. Move the
73826         definition of HAVE_PARTLY_WORKING_GETCWD from here...
73827         * m4/getcwd.m4 (gl_FUNC_GETCWD): ... to here. Invoke
73828         gl_FUNC_GETCWD_PATH_MAX also when $gl_cv_func_getcwd_null is 'no'.
73829         Define HAVE_MINIMALLY_WORKING_GETCWD.
73830         * lib/getcwd.c (__getcwd): Don't use the system's getcwd on platforms
73831         where it is not even minimally working, that is, on AIX.
73832         * tests/test-getcwd.c (test_long_name): Distinguish the same cases as
73833         m4/getcwd-path-max.m4.
73834         (main): Update exit code computation.
73835         * doc/posix-functions/getcwd.texi: Mention list of platforms where
73836         getcwd does not handle long file names.
73838 2011-11-20  Bruno Haible  <bruno@clisp.org>
73840         getcwd: Fix bug from 2009-09-10.
73841         * m4/getcwd.m4 (gl_FUNC_GETCWD): Treat "guessing yes" like "yes", not
73842         like "no".
73844 2011-11-20  Simon Josefsson  <simon@josefsson.org>
73846         * m4/manywarnings.m4: Add more warnings from gcc 4.6.2.
73848 2011-11-20  Bruno Haible  <bruno@clisp.org>
73850         fma tests: Avoid shadowing local variables.
73851         * tests/test-fma2.h (test_function): Reduce scope of x, y, z, result,
73852         expected.
73854 2011-11-20  Bruno Haible  <bruno@clisp.org>
73856         copysignf tests: Fix.
73857         * tests/test-copysignf.c: Fix signature check.
73859 2011-11-20  Bruno Haible  <bruno@clisp.org>
73861         fma: Remove unused code.
73862         * lib/fma.c (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): Remove
73863         unused macros.
73865 2011-11-20  Bruno Haible  <bruno@clisp.org>
73867         sethostname: Fix doc about AIX.
73868         * doc/glibc-functions/sethostname.texi: Drop mention that AIX 5.1 lacks
73869         sethostname; it has it.
73871         sethostname: Mention more portability problems.
73872         * doc/glibc-functions/sethostname.texi: Mention the missing declaration
73873         problem.
73874         Reported by Ben Walton <bwalton@artsci.utoronto.ca>.
73876 2011-11-19  Bruno Haible  <bruno@clisp.org>
73878         Depend on module fcntl-h when AT_FDCWD is used.
73879         * modules/utimens (Depends-on): Add fcntl-h.
73880         * modules/areadlinkat (Depends-on): Likewise.
73881         * modules/areadlinkat-with-size (Depends-on): Likewise.
73882         * modules/faccessat (Depends-on): Likewise.
73883         * modules/fchmodat (Depends-on): Likewise.
73884         * modules/fchownat (Depends-on): Likewise.
73885         * modules/getcwd (Depends-on): Likewise.
73886         * modules/mkdirat (Depends-on): Likewise.
73887         * modules/mkfifoat (Depends-on): Likewise.
73888         * modules/readlinkat (Depends-on): Likewise.
73889         * modules/symlinkat (Depends-on): Likewise.
73890         * modules/dup2-tests (Depends-on): Likewise.
73891         * modules/fdutimensat-tests (Depends-on): Likewise.
73892         * modules/futimens-tests (Depends-on): Likewise.
73894 2011-11-19  Bruno Haible  <bruno@clisp.org>
73896         euidaccess: Update a comment.
73897         * lib/euidaccess.c: Update comment about platforms with faccessat.
73899 2011-11-19  Bruno Haible  <bruno@clisp.org>
73901         openat: Fix file list.
73902         * modules/openat (Files): Remove lib/at-func.c.
73904 2011-11-19  Bruno Haible  <bruno@clisp.org>
73906         fstatat: Simplify.
73907         * lib/fstatat.c (AT_FUNC_NAME): Define as fstatat. On platforms where
73908         gnulib should define rpl_fstatat, there is a
73909         "#define fstatat rpl_fstatat" in <sys/stat.h>.
73911 2011-11-19  Bruno Haible  <bruno@clisp.org>
73913         Ensure 'inline' can be used in tests/test-utimens-common.h.
73914         * modules/fdutimensat-tests (configure.ac): Require AC_C_INLINE.
73915         * modules/futimens-tests (configure.ac): Likewise.
73916         * modules/utimens-tests (configure.ac): Likewise.
73917         * modules/utimensat-tests (configure.ac): Likewise.
73919 2011-11-19  Simon Josefsson  <simon@josefsson.org>
73921         * lib/hash.c (hash_insert): Use hash_insert_if_absent,
73922         not hash_insert0.
73923         (hash_insert_if_absent): Doc fix.
73925 2011-11-19  Simon Josefsson  <simon@josefsson.org>
73927         * m4/readline.m4 (gl_FUNC_READLINE): Check for readline/history.h.
73929 2011-11-18  Paul Eggert  <eggert@cs.ucla.edu>
73931         test-getcwd: disambiguate exit status
73932         * tests/test-getcwd.c (test_long_name): Return 0..7.
73933         (main): Exit with an unambiguous exit status.  The old
73934         code yielded a mysterious mixture of two failure codes.
73936         fstatat: fix configuration bug on mingw, OpenBSD 4, Solaris 8
73937         * lib/fstatat.c (AT_FUNC_NAME): Use HAVE_FSTAT, not
73938         HAVE_WORKING_FSTATAT_ZERO_FLAG, to decide whether to define
73939         rpl_fstatat or fstatat.  This should fix the other problem
73940         reported by Kai Habel in
73941         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00237.html>.
73942         A similar problem was reported for OpenBSD 4.6 by Mats Erik Andersson
73943         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00239.html>
73944         and I reproduced it on a Solaris 8 host we still have in production.
73946 2011-11-18  Jim Meyering  <meyering@redhat.com>
73948         hash: deprecate poorly-named hash_insert0: use hash_insert_if_absent
73949         * lib/hash.c (hash_insert_if_absent): Rename from hash_insert0.
73950         Add a sentence to the comment.
73951         (hash_insert0): New function that simply calls hash_insert_if_absent.
73952         * lib/hash.h (hash_insert_if_absent): Declare it.
73953         (hash_insert0): Add deprecation attribute.
73954         (_GL_ATTRIBUTE_DEPRECATED): Define.
73955         * lib/di-set.c (di_set_insert): Use hash_insert_if_absent,
73956         not hash_insert0.
73957         * NEWS: Mention it, even though it's not really an incompatible change.
73959 2011-11-18  Dagobert Michelsen  <dam@opencsw.org>  (tiny change)
73961         openat: avoid compilation failure due to lack of <errno.h> inclusion
73962         * lib/openat.c: Include <errno.h>.
73964 2011-11-17  Paul Eggert  <eggert@cs.ucla.edu>
73966         * modules/getcwd (Depends-on): Add fdopendir.
73967         This fixes one of the two problems reported by Kai Habel in
73968         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00237.html>.
73970         modules/crypto/gc-*: simplify dependencies and fix stdalign.h bug
73971         stdalign problem reported by Ian Beckwith in
73972         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00238.html>.
73973         * modules/crypto/gc-arcfour (Depends-on):
73974         Depend conditionally on crypto/arcfour.
73975         * modules/crypto/gc-arctwo (Depends-on):
73976         Depend conditionally on crypto/arctwo.
73977         * modules/crypto/gc-des (Depends-on):
73978         Depend conditionally on crypto/des.
73979         * modules/crypto/gc-hmac-md5 (Depends-on):
73980         Depend conditionally on crypto/hmac-md5.
73981         * modules/crypto/gc-hmac-sha1 (Depends-on):
73982         Depend conditionally on crypto/hmac-sha1.
73983         * modules/crypto/gc-md2 (Depends-on): Remove stdint, minmax.
73984         * modules/crypto/gc-md4 (Depends-on):
73985         Depend conditionally on crypto/md4.
73986         * modules/crypto/gc-md5 (Depends-on):
73987         Depend conditionally on crypto/md5.
73988         * modules/crypto/gc-rijndael (Depends-on):
73989         Depend conditionally on crypto/rijndael.
73990         * modules/crypto/gc-sha1 (Depends-on):
73991         Depend conditionally on crypto/sha1.
73992         * modules/crypto/gc-arcfour:
73993         * modules/crypto/gc-arctwo:
73994         * modules/crypto/gc-des:
73995         * modules/crypto/gc-hmac-md5:
73996         * modules/crypto/gc-hmac-sha1:
73997         * modules/crypto/gc-md2:
73998         * modules/crypto/gc-md4:
73999         * modules/crypto/gc-md5:
74000         * modules/crypto/gc-rijndael:
74001         * modules/crypto/gc-sha1:
74002         (Files, Depends-on, configure.ac): Remove now-unnecessary stuff,
74003         now that the conditional dependencies do the work for us.
74005 2011-11-17  Jim Meyering  <meyering@redhat.com>
74007         tests: factor st_ctime-comparison out of two headers
74008         * tests/test-utimens-common.h (ctime_compare): Define.
74009         * tests/test-futimens.h (test_futimens): Replace open-coded equivalent.
74010         * tests/test-lutimens.h (test_lutimens): Likewise.
74011         * tests/test-utimens.h (test_utimens): Likewise.
74013         test-getcwd: don't leave behind a confdir3/ directory upon interrupt
74014         Invoke the test program via an init.sh-using wrapper.
74015         * tests/test-getcwd.sh: New file.
74016         * modules/getcwd-tests (Files): Add it.
74017         (Makefile.am) [TESTS]: Invoke the shell script wrapper.
74019 2011-11-01  Gary V. Vaughan  <gary@gnu.org>
74021         gitlog-to-changelog: support multi-author commits.
74022         The FSF cares about keeping track of all authors of patches to its
74023         projects, but Git doesn't provide obvious support for multi-author
74024         changesets. Consensus seems to be forming around the use of extra
74025         Signed-off-by inspired lines in the log message formatted as
74026         `Co-authored-by: A U Thor <email@example.com>' for round-tripping
74027         multi-author commits between version control systems.
74028         * gitlog-to-changelog: Extract `Co-authored-by:' lines from the git
74029         log message and output in standard ChangeLog multi-author format.
74030         Reported by Peter Rosin <peda@lysator.liu.se>
74032 2011-11-15  Ben Walton  <bwalton@artsci.utoronto.ca>  (tiny change)
74033             Bruno Haible  <bruno@clisp.org>
74035         Fix some modules' file list.
74036         * modules/fstatat (Files): Add m4/lstat.m4.
74037         * modules/openat (Files): Likewise.
74038         * modules/unlinkat (Files): Likewise.
74040 2011-11-15  Gary V. Vaughan  <gary@gnu.org>
74042         maint.mk: fix tight-scope.mk generation in VPATH builds.
74043         * top/maint.mk (tight-scope.mk): Make sure to prefix file
74044         reference with $(srcdir) so that the file is found correctly even
74045         when running `make syntax-check' in a VPATH build.
74047 2011-11-13  Bruno Haible  <bruno@clisp.org>
74048             Jim Meyering  <meyering@redhat.com>
74050         Silence successful tests that use 'compare' on AIX, HP-UX, Solaris.
74051         * tests/init.sh (compare): Remove "No differences encountered" or
74052         synonymous output from the 'diff' program.
74054 2011-11-13  Bruno Haible  <bruno@clisp.org>
74056         Makefile: Tweak indentation.
74057         * Makefile: Use tab as first character in every line that contains rule
74058         commands.
74060 2011-11-13  Bruno Haible  <bruno@clisp.org>
74062         Syntax check for copyright statements.
74063         * check-copyright: New file.
74064         * Makefile (sc_check_copyright): New rule.
74066 2011-11-13  Simon Josefsson  <simon@josefsson.org>
74068         * build-aux/git-version-gen: Add --prefix to configure the tag
74069         match string.
74071 2011-11-13  Simon Josefsson  <simon@josefsson.org>
74073         * build-aux/git-version-gen: Add --help and --version.
74075 2011-11-12  Jim Meyering  <meyering@redhat.com>
74077         revamp the other test-exclude?.sh scripts to use init.sh, too
74078         * tests/test-exclude1.sh: Use init.sh.
74079         * tests/test-exclude2.sh: Likewise.
74080         * tests/test-exclude3.sh: Likewise.
74081         * tests/test-exclude4.sh: Likewise.
74082         * tests/test-exclude5.sh: Likewise.
74083         * tests/test-exclude6.sh: Likewise.
74084         * tests/test-exclude7.sh: Likewise.
74085         * tests/test-exclude8.sh: Likewise.
74086         * modules/exclude-tests (Files): List init.sh.
74088         test-exclude2.sh, test-exclude5.sh: fail if test-exclude fails
74089         These shell scripts ignored failure of the binary test-exclude,
74090         so making the latter return 77 didn't cause them to be skipped.
74091         * tests/test-exclude5.sh: Exit with test-exclude's error status
74092         when that program fails.  Revamp to use init.sh.
74093         * tests/test-exclude2.sh: Likewise.
74095         test-exclude: fix a typo
74096         * tests/test-exclude.c (main): Test for "leading_dir", not "leading-dir".
74098 2011-11-11  Bruno Haible  <bruno@clisp.org>
74100         obstack: Fix compilation error on MSVC 9.
74101         * lib/obstack.c (print_and_abort): Declare with _Noreturn specifier.
74103 2011-11-11  Jim Meyering  <meyering@redhat.com>
74105         test-exclude: skip tests rather than failing on deficient systems
74106         * tests/test-exclude.c (main): Skip tests that use FNM_CASEFOLD
74107         and FNM_LEADING_DIR on systems that lack the definitions.  This affects
74108         at least Solaris 9.  Reported and diagnosed by Dagobert Michelsen in
74109         http://thread.gmane.org/gmane.comp.gnu.grep.bugs/3947/focus=3950
74111 2011-11-10  Bruno Haible  <bruno@clisp.org>
74113         ptsname_r test: Avoid gcc warning on glibc systems.
74114         * tests/test-ptsname_r.c (null_ptr): New function.
74115         (test_errors): Use it.
74117 2011-11-10  Bruno Haible  <bruno@clisp.org>
74119         ptsname_r: Avoid compilation error on OSF/1 5.1.
74120         * lib/stdlib.in.h (ptsname_r): Override if REPLACE_PTSNAME_R is 1.
74121         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_PTSNAME_R.
74122         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): Set REPLACE_PTSNAME_R if the
74123         function is not declared or incompatibly declared.
74124         * modules/stdlib (Makefile.am): Substitute REPLACE_PTSNAME_R.
74125         * modules/ptsname_r (Depends-on, configure.ac): Update.
74126         * doc/glibc-functions/ptsname_r.texi: Mention the OSF/1 problems.
74128 2011-11-10  Bruno Haible  <bruno@clisp.org>
74130         fstatat: Make cross-compilation guess succeed everywhere except on AIX.
74131         * m4/fstatat.m4 (gl_FUNC_FSTATAT): Require AC_CANONICAL_HOST.
74132         When cross-compiling, guess yes on all platforms except AIX.
74133         Reported by Ludovic Courtès <ludo@gnu.org>.
74135 2011-11-09  Bruno Haible  <bruno@clisp.org>
74137         ptsname_r tests: Fix bugs.
74138         * tests/test-ptsname_r.c (test_errors): Change return type to 'void'.
74139         Fix ptsname_r calls. Reduce loop rounds to a reasonable amount.
74141 2011-11-09  Paul Eggert  <eggert@cs.ucla.edu>
74143         fstatat: work with cross-compilation
74144         Problem reported by Ludovic Courtès in
74145         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00136.html>.
74146         * m4/fstatat.m4 (gl_FUNC_FSTATAT): When cross-compiling, report
74147         "cross-compiling" and assume the bug is present.  Replace
74148         FSTATAT_ZERO_FLAG_BROKEN with HAVE_WORKING_FSTATAT_ZERO_FLAG with
74149         an inverted sense, to be more conservative about our assumptions.
74150         * lib/fstatat.c (rpl_fstatat): Adjust to renamed macro.
74152 2011-11-09  Bruno Haible  <bruno@clisp.org>
74154         Improve MODULES.html output.
74155         * modules/mkfifoat (Description): Use the word "function".
74156         * modules/readlinkat (Description): Likewise.
74157         * modules/symlinkat (Description): Likewise.
74159 2011-11-09  Eric Blake  <eblake@redhat.com>
74161         ptsname_r-tests: new test module
74162         * modules/ptsname_r-tests: New module.
74163         * tests/test-ptsname_r.c: New file.
74165         ptsname_r: new module
74166         * modules/ptsname_r: New module.
74167         * m4/ptsname_r.m4 (gl_FUNC_PTSNAME_R): New file.
74168         * lib/ptsname.c (__ptsname_r): Split...
74169         * lib/ptsname_r.c: ...into new file.
74170         * m4/stdlib_h.m4 (gl_STDLIB_H): Check for decl.
74171         (gl_STDLIB_H_DEFAULTS): Set witness defaults.
74172         * modules/stdlib (Makefile.am): Substitute witnesses.
74173         * lib/stdlib.in.h (ptsname_r): Declare it.
74174         * doc/glibc-functions/ptsname_r.texi (ptsname_r): Document it.
74175         * MODULES.html.sh (Misc): Likewise.
74176         * modules/ptsname (Depends-on): Alter dependency.
74177         * doc/posix-functions/ptsname.texi (ptsname): Mention new module.
74179 2011-11-09  Jim Meyering  <meyering@redhat.com>
74181         announce-gen: be more concise when there's only one URL+tarball
74182         * build-aux/announce-gen (get_tool_versions): When you distribute
74183         only one type of tarball, combine the first two "Here are..."
74184         sections and make the key-checking grammar independent of
74185         how many tarballs there are.
74187 2011-11-09  Eric Blake  <eblake@redhat.com>
74189         openpty: provide a stub on mingw
74190         * lib/pty.in.h (includes): Provide forward declarations.
74191         * lib/openpty.c (openpty) [mingw]: Provide ENOSYS stub.
74193         raise: fix mingw handling of SIGPIPE
74194         * lib/sigprocmask.c (_gl_raise_SIGPIPE): Provide a return value.
74196 2011-11-08  Bruno Haible  <bruno@clisp.org>
74198         More conditional dependencies.
74199         * modules/faccessat (Depends-on): Add conditions.
74200         * modules/fchmodat (Depends-on): Likewise.
74201         * modules/fchownat (Depends-on): Likewise.
74202         * modules/fstatat (Depends-on): Likewise.
74203         * modules/mkfifoat (Depends-on): Likewise.
74204         * modules/readlinkat (Depends-on): Likewise.
74205         * modules/symlinkat (Depends-on): Likewise.
74206         * modules/unlinkat (Depends-on): Likewise.
74207         * modules/utimensat (Depends-on): Likewise.
74208         * modules/mkdirat (Depends-on): Add sys_stat. Add conditions.
74209         * modules/linkat (Depends-on): Refine the conditions.
74210         * modules/renameat (Depends-on): Likewise.
74212 2011-11-08  Bruno Haible  <bruno@clisp.org>
74214         faccessat: Move AC_LIBOBJ invocation to module description.
74215         * m4/faccessat.m4 (gl_PREREQ_FACCESSAT): New macro.
74216         (gl_FUNC_FACESSAT): Don't test for access() here. Move AC_LIBOBJ
74217         invocation from here...
74218         * modules/faccessat (configure.ac): ... to here. Invoke
74219         gl_PREREQ_FACCESSAT.
74221 2011-11-08  Bruno Haible  <bruno@clisp.org>
74223         faccessat: Simplify autoconf macro.
74224         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Don't require gl_FUNC_OPENAT,
74225         gl_FUNC_EUIDACCESS.
74227 2011-11-08  Bruno Haible  <bruno@clisp.org>
74229         renameat: Fix dependencies.
74230         * modules/renameat (Depends-on): Add stdbool.
74232 2011-11-08  Bruno Haible  <bruno@clisp.org>
74234         mkfifoat: Fix module description.
74235         * modules/mkfifoat (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR,
74236         not gl_UNISTD_MODULE_INDICATOR.
74238 2011-11-08  Bruno Haible  <bruno@clisp.org>
74240         fstatat: Remove unused dependency.
74241         * modules/fstatat (Depends-on): Remove fstat.
74243 2011-11-08  Simon Josefsson  <simon@josefsson.org>
74245         GNUmakefile: behave when Makefile is missing.
74246         * top/GNUmakefile: Always initialize _build-aux and _autoreconf.
74248 2011-11-08  Bruno Haible  <bruno@clisp.org>
74250         openat: Conditionalize dependencies.
74251         * lib/openat.c: Reduce the scope of some #includes.
74252         * modules/openat (Depends-on): Add conditions.
74254 2011-11-07  Jim Meyering  <meyering@redhat.com>
74256         maint.mk: extract GPG key ID without using a temporary file
74257         * top/maint.mk (gpg_key_ID): Extract GPG key ID from signed tag, but
74258         without using a temporary file.  Based on a suggestion from Werner Koch
74259         in http://thread.gmane.org/gmane.comp.encryption.gpg.devel/16496
74261 2011-11-07  Eric Blake  <eblake@redhat.com>
74263         grantpt: fix typo
74264         * lib/stdlib.in.h (grantpt): Check correct function.
74266         maint.mk: silence new syntax check
74267         * top/maint.mk (sc_prohibit_dirent_without_use): Add missing @.
74269 2011-11-06  Bruno Haible  <bruno@clisp.org>
74271         Doc about floating-point and math API.
74272         * doc/posix-headers/float.texi: Mention problem with FLT_ROUNDS.
74273         * doc/posix-headers/math.texi: Mention problem with math_errhandling.
74275 2011-11-06  Bruno Haible  <bruno@clisp.org>
74277         stdalign tests: Skip the test when compiled by Sun C.
74278         * tests/test-stdalign.c (main): Skip the test on Sun C.
74280 2011-11-06  Bruno Haible  <bruno@clisp.org>
74282         ansi-c++-opt: Complete the 2011-06-05 change.
74283         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): When a C++ compiler is found but
74284         does not support namespaces, set the variable to "no", not to ":".
74286 2011-11-06  Paul Eggert  <eggert@cs.ucla.edu>
74288         * doc/posix-headers/stdalign.texi (stdalign.h): Mention Sun review ID.
74290 2011-11-06  Bruno Haible  <bruno@clisp.org>
74292         copysignl: Fix result for zero argument on HP-UX 11 with HP C.
74293         * lib/copysignl.c (compute_minus_zerol) [HP-UX]: New function.
74294         (minus_zerol) [HP-UX]: New macro.
74295         (unary_minus) [HP-UX]: New function.
74296         (copysignl) [HP-UX]: Use unary_minus function.
74298 2011-11-06  Bruno Haible  <bruno@clisp.org>
74300         ldexp, ldexpf, ldexpl: Enhance tests.
74301         * tests/test-ldexp.h: New file, combining code from tests/test-ldexp.c
74302         and tests/test-ldexpl.c.
74303         * tests/test-ldexpl.c: (DOUBLE, ISNAN, INFINITY, NAN, L_, MINUS_ZERO,
74304         LDEXP, MIN_EXP, MAX_EXP): New macros.
74305         Include test-ldexp.h.
74306         (main): Just call test_function.
74307         * tests/test-ldexp.c: Include float.h, isnand-nolibm.h, minus-zero.h,
74308         infinity.h, nan.h.
74309         (DOUBLE, ISNAN, INFINITY, NAN, L_, MINUS_ZERO, LDEXP, MIN_EXP,
74310         MAX_EXP): New macros.
74311         Include test-ldexp.h.
74312         (x, y): Remove variables.
74313         (main): Just call test_function.
74314         * tests/test-ldexpf.c: Include float.h, isnanf-nolibm.h, minus-zero.h,
74315         infinity.h, nan.h.
74316         (DOUBLE, ISNAN, INFINITY, NAN, L_, MINUS_ZERO, LDEXP, MIN_EXP,
74317         MAX_EXP): New macros.
74318         Include test-ldexp.h.
74319         (x, y): Remove variables.
74320         (main): Just call test_function.
74321         * modules/ldexpl-tests (Files): Add tests/test-ldexp.h.
74322         * modules/ldexp-tests (Files): Add tests/test-ldexp.h,
74323         tests/minus-zero.h, tests/infinity.h, tests/nan.h.
74324         (Depends-on): Add isnand-nolibm, signbit, float.
74325         * modules/ldexpf-tests (Files): Add tests/test-ldexp.h,
74326         tests/minus-zero.h, tests/infinity.h, tests/nan.h.
74327         (Depends-on): Add isnanf-nolibm, signbit, float.
74329 2011-11-06  Bruno Haible  <bruno@clisp.org>
74331         math tests: Cosmetics.
74332         * tests/test-math-c++.cc: Reorder declarations.
74334 2011-11-05  Bruno Haible  <bruno@clisp.org>
74336         fma*: Simplify test.
74337         * tests/test-fma2.h (FORGIVE_GLIBC_BUG): Remove macro.
74338         (test_function): Remove all if (FORGIVE_GLIBC_BUG) statements.
74340         Tests for module 'fmal'.
74341         * modules/fmal-tests: New file.
74342         * tests/test-fmal1.c: New file.
74343         * tests/test-fmal2.c: New file.
74345         New module 'fmal'.
74346         * lib/math.in.h (fmal): New declaration.
74347         * lib/fmal.c: New file.
74348         * m4/fmal.m4: New file.
74349         * m4/math_h.m4 (gl_MATH_H): Test whethern fmal is declared.
74350         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMAL, HAVE_FMAL, REPLACE_FMAL.
74351         * modules/math (Makefile.am): Substitute GNULIB_FMAL, HAVE_FMAL,
74352         REPLACE_FMAL.
74353         * modules/fmal: New file.
74354         * doc/posix-functions/fmal.texi: Mention the new module and the various
74355         bugs.
74357         Tests for module 'fmaf'.
74358         * modules/fmaf-tests: New file.
74359         * tests/test-fmaf1.c: New file.
74360         * tests/test-fmaf2.c: New file.
74362         New module 'fmaf'.
74363         * lib/math.in.h (fmaf): New declaration.
74364         * lib/fmaf.c: New file.
74365         * m4/fmaf.m4: New file.
74366         * m4/math_h.m4 (gl_MATH_H): Test whethern fmaf is declared.
74367         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMAF, HAVE_FMAF, REPLACE_FMAF.
74368         * modules/math (Makefile.am): Substitute GNULIB_FMAF, HAVE_FMAF,
74369         REPLACE_FMAF.
74370         * modules/fmaf: New file.
74371         * doc/posix-functions/fmaf.texi: Mention the new module and the various
74372         bugs.
74374         Tests for module 'fma'.
74375         * modules/fma-tests: New file.
74376         * tests/test-fma1.c: New file.
74377         * tests/test-fma1.h: New file.
74378         * tests/test-fma2.c: New file.
74379         * tests/test-fma2.h: New file.
74381         New module 'fma'.
74382         * lib/math.in.h (fma): New declaration.
74383         * lib/fma.c: New file.
74384         * m4/fma.m4: New file.
74385         * m4/fegetround.m4: New file.
74386         * m4/math_h.m4 (gl_MATH_H): Test whethern fma is declared.
74387         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMA, HAVE_FMA, REPLACE_FMA.
74388         * modules/math (Makefile.am): Substitute GNULIB_FMA, HAVE_FMA,
74389         REPLACE_FMA.
74390         * modules/fma: New file.
74391         * doc/posix-functions/fma.texi: Mention the new module and the various
74392         bugs.
74394         Extend gl_MATHFUNC.
74395         * m4/mathfunc.m4 (gl_MATHFUNC): Accept an 4th parameter of INCLUDES.
74396         Support 'void' as argument type.
74397         * m4/rint.m4 (gl_FUNC_RINT): Update gl_MATHFUNC invocation.
74399 2011-11-05  Jim Meyering  <meyering@redhat.com>
74401         maint.mk: also prohibit inclusion of dirent.h without use
74402         * top/maint.mk (sc_prohibit_dirent_without_use): New rule.
74404 2011-11-05  Bruno Haible  <bruno@clisp.org>
74406         ldexpl tests: Avoid test failure on MSVC 9.
74407         * tests/test-ldexpl.c (main): Use a temporary variable for the expected
74408         value. Needed in order to enforce the conversion from a value greater
74409         than LDBL_MAX to Infinity.
74411 2011-11-05  Bruno Haible  <bruno@clisp.org>
74413         New modules 'at-internal', 'openat-h', split off from module 'openat'.
74414         * modules/at-internal: New file, extracted from modules/openat.
74415         * modules/openat-h: New file.
74416         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_OPENAT. Don't
74417         invoke gl_PREREQ_OPENAT and gl_MODULE_INDICATOR.
74418         * modules/openat (Description): Add reference to POSIX function.
74419         (Files): Remove lib/openat.h, lib/openat-proc.c.
74420         (Depends-on): Add at-internal, openat-h. Remove fdopendir, gettext-h,
74421         intprops, unistd.
74422         (configure.ac): Remove AC_LIBOBJ of openat-proc. Invoke
74423         gl_PREREQ_OPENAT, gl_MODULE_INDICATOR here. Invoke
74424         gl_FCNTL_MODULE_INDICATOR.
74425         (Include): Remove unistd.h, openat.h.
74426         * modules/areadlinkat (Files): Add lib/at-func.c.
74427         (Depends-on): Add at-internal, dosname, errno, extensions, fchdir,
74428         openat-die, openat-h, save-cwd.
74429         * modules/areadlinkat-with-size (Files): Add lib/at-func.c.
74430         (Depends-on): Add at-internal, dosname, errno, extensions, fchdir,
74431         openat-die, openat-h, save-cwd, unistd.
74432         * modules/faccessat (Files): Add lib/at-func.c, lib/openat-priv.h.
74433         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
74434         openat-h, save-cwd. Remove fcntl-h, openat.
74435         * modules/fchmodat (Files): Remove lib/openat.h.
74436         (Depends-on): Add at-internal, openat-h. Remove dirent, fcntl-h,
74437         openat, stdbool, unistd.
74438         * modules/fchownat (Files): Remove lib/openat.h.
74439         (Depends-on): Add at-internal, openat-h. Remove dirent, fcntl-h,
74440         openat, stdbool, sys_stat.
74441         * modules/fdopendir (Files): Remove lib/openat-priv.h,
74442         lib/openat-proc.c.
74443         (Depends-on): Add at-internal.
74444         (condigure.ac): Remove AC_LIBOBJ of openat-proc.
74445         * modules/fstatat (Files): Remove lib/openat.h.
74446         (Depends-on): Add at-internal, openat-h. Remove dirent, openat,
74447         stdbool, unistd.
74448         * modules/fts (Depends-on): Add openat-h.
74449         * modules/linkat (Depends-on): Add at-internal, openat-h. Remove
74450         openat.
74451         * modules/mkdirat (Files): Remove lib/openat.h.
74452         (Depends-on): Add at-internal, openat-h. Remove dirent, fcntl-h,
74453         openat, stdbool, sys_stat.
74454         * modules/mkfifoat (Files): Add lib/at-func.c.
74455         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
74456         openat-h, save-cwd. Remove fcntl-h, openat.
74457         * modules/openat-die (Depends-on): Add openat-h. Remove openat.
74458         * modules/readlinkat (Files): Add lib/at-func.c.
74459         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
74460         openat-h, save-cwd. Remove fcntl-h, openat.
74461         * modules/renameat (Depends-on): Add at-internal, openat-h. Remove
74462         openat.
74463         * modules/selinux-at (Files): Add lib/at-func.c.
74464         (Depends-on): Add at-internal, dosname, errno, extensions, fchdir,
74465         fcntl-h, openat-die, openat-h, save-cwd, unistd. Remove openat.
74466         * modules/symlinkat (Files): Add lib/at-func.c.
74467         (Depends-on): Add at-internal, dosname, errno, fchdir, openat-die,
74468         openat-h, save-cwd. Remove fcntl-h, openat.
74469         * modules/unlinkat (Files): Remove lib/openat.h.
74470         (Depends-on): Add at-internal, openat-h. Remove dirent, openat,
74471         stdbool.
74472         * modules/utimensat (Files): Add lib/at-func.c.
74473         (Depends-on): Add at-internal, dosname, errno, fchdir, fcntl-h,
74474         openat-die, openat-h, save-cwd.
74475         * modules/fchownat-tests (Depends-on): Add openat-h. Remove openat.
74476         * modules/fdutimensat-tests (Depends-on): Add openat.
74477         * modules/fstatat-tests (Depends-on): Add openat-h.
74478         * modules/readlinkat-tests (Depends-on): Add openat.
74479         * modules/symlinkat-tests (Depends-on): Add openat.
74481 2011-11-05  Bruno Haible  <bruno@clisp.org>
74483         openat: Include <stdbool.h>.
74484         * lib/openat.c: Include <stdbool.h>.
74486 2011-11-04  Bruno Haible  <bruno@clisp.org>
74488         fchownat, renameat, unlinkat: Fix dependencies.
74489         * modules/fchownat (Depends-on): Add fstatat.
74490         * modules/renameat (Depends-on): Likewise.
74491         * modules/unlinkat (Depends-on): Likewise.
74493 2011-11-04  Paul Eggert  <eggert@cs.ucla.edu>
74495         openat: remove direct dependency on dirent
74496         * lib/openat.h: Don't include <dirent.h>; it's no longer needed,
74497         and hasn't been needed ever since fdopendir was split into its own
74498         module on 2009-08-31.
74499         * modules/openat (Depends-on): Remove dirent.
74501 2011-11-04  Bruno Haible  <bruno@clisp.org>
74503         renameat: Optimize code size.
74504         * modules/renameat (configure.ac): Don't compile at-func2.c if
74505         REPLACE_RENAMEAT is 1.
74507 2011-11-04  Bruno Haible  <bruno@clisp.org>
74509         openat tests: Fix file list.
74510         * modules/openat-tests (Files): Add tests/test-open.h.
74512 2011-11-04  Bruno Haible  <bruno@clisp.org>
74514         openat, fchmodat, fchownat, linkat, renameat: Fix dependencies.
74515         * modules/fchmodat (Depends-on): Add openat-die.
74516         * modules/fchownat (Depends-on): Likewise.
74517         * modules/linkat (Depends-on): Likewise.
74518         * modules/renameat (Depends-on): Likewise.
74519         * modules/openat (Depends-on): Add dirent.
74521 2011-11-04  Jim Meyering  <meyering@redhat.com>
74523         at-func*.c: fix comments
74524         * lib/at-func2.c: Correct/improve first-line comment.
74525         * lib/at-func.c: Correct grammar in first-line comment.
74527 2011-11-04  Bruno Haible  <bruno@clisp.org>
74529         New module 'mkdirat', split off from module 'openat'.
74530         * m4/mkdirat.m4: New file. extracted from m4/openat.m4.
74531         * m4/openat.m4 (gl_FUNC_OPENAT): Don't require gl_SYS_STAT_H_DEFAULTS.
74532         Don't test for mkdirat. Don't set GNULIB_MKDIRAT, HAVE_MKDIRAT.
74533         * modules/mkdirat: New file, extracted from modules/openat.
74534         * modules/openat (Files): Remove lib/mkdirat.c.
74535         (Depends-on): Remove mkdir.
74536         (configure.ac): Remove AC_LIBOBJ of mkdirat.
74537         (Include): Remove <sys/stat.h>.
74538         * modules/mkdirat-tests: New file, extracted from modules/openat-tests.
74539         * modules/openat-tests (Files): Remove tests/test-mkdirat.c,
74540         tests/test-mkdir.h.
74541         (Depends-on): Remove ignore-value.
74542         (Makefile.am): Remove rules for test-mkdirat.
74543         * doc/posix-functions/mkdirat.texi: Mention module 'mkdirat' instead
74544         of module 'openat'.
74545         * NEWS: Mention the change.
74547 2011-11-04  Bruno Haible  <bruno@clisp.org>
74549         closedir: Avoid warning on mingw.
74550         * lib/closedir.c: Include <unistd.h>.
74552 2011-11-04  Bruno Haible  <bruno@clisp.org>
74554         New module 'fstatat', split off from module 'openat'.
74555         * lib/openat.h (statat, lstatat): Enable only if GNULIB_FSTATAT is
74556         defined.
74557         * m4/fstatat.m4: New file. extracted from m4/openat.m4.
74558         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FSTATAT. Don't invoke
74559         gl_FUNC_FSTATAT.
74560         (gl_FUNC_FSTATAT): Moved to m4/fstatat.m4.
74561         * modules/fstatat: New file, extracted from modules/openat.
74562         * modules/openat (Files): Remove lib/fstatat.c.
74563         (Depends-on): Remove lstat.
74564         (configure.ac): Remove AC_LIBOBJ of fstatat.
74565         * modules/fstatat-tests: New file, extracted from modules/openat-tests.
74566         * modules/openat-tests (Files): Remove tests/test-fstatat.c,
74567         tests/test-lstat.h, tests/test-stat.h.
74568         (Depends-on): Remove getcwd-lgpl.
74569         (Makefile.am): Remove rules for test-fstatat.
74570         * doc/posix-functions/fstatat.texi: Mention module 'fstatat' instead
74571         of module 'openat'.
74572         * NEWS: Mention the change.
74573         * modules/getcwd (Depends-on): Add fstatat.
74574         * modules/linkat (Depends-on): Likewise.
74575         * modules/mkfifoat-tests (Depends-on): Likewise.
74576         * modules/utimensat (Depends-on): Add fstatat. Remove openat.
74578 2011-11-03  Bruno Haible  <bruno@clisp.org>
74580         New module 'unlinkat', split off from module 'openat'.
74581         * m4/unlinkat.m4: New file, extracted from m4/openat.m4.
74582         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_UNLINKAT,
74583         REPLACE_UNLINKAT, HAVE_UNLINKAT. Don't test for unlinkat.
74584         * modules/unlinkat: New file, extracted from modules/openat. Correct
74585         the dependency conditions.
74586         * modules/openat (Files): Remove lib/unlinkat.c.
74587         (Depends-on): Remove rmdir, unlink.
74588         (configure.ac): Remove AC_LIBOBJ of unlinkat.
74589         * modules/unlinkat-tests: New file, extracted from modules/openat-tests.
74590         * modules/openat-tests (Files): Remove tests/test-unlinkat.c,
74591         tests/test-rmdir.h, tests/test-unlink.h.
74592         (Depends-on): Remove unlinkdir.
74593         (Makefile.am): Remove rules for test-unlinkat.
74594         * doc/posix-functions/unlinkat.texi: Mention module 'unlinkat' instead
74595         of module 'openat'.
74596         * NEWS: Mention the change.
74597         * modules/linkat-tests (Depends-on): Add unlinkat.
74598         * modules/mkfifoat-tests (Depends-on): Likewise.
74599         * modules/readlinkat-tests (Depends-on): Likewise.
74601 2011-11-02  Bruno Haible  <bruno@clisp.org>
74603         New module 'fchmodat', split off from module 'openat'.
74604         * lib/openat.h (chmodat, lchmodat): Enable only if GNULIB_FCHMODAT is
74605         defined.
74606         * m4/fchmodat.m4: New file, extracted from m4/openat.m4.
74607         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FCHMODAT. Don't test
74608         for fchmodat, lchmod. Don't set HAVE_FCHMODAT.
74609         * modules/fchmodat: New file, extracted from modules/openat.
74610         * modules/openat (Files): Remove lib/fchmodat.c.
74611         (configure.ac): Remove AC_LIBOBJ of fchmodat.
74612         * modules/fchmodat-tests: New file, extracted from modules/openat-tests.
74613         * modules/openat-tests (Files): Remove tests/test-fchmodat.c.
74614         (Makefile.am): Remove rules for test-fchmodat.
74615         * doc/posix-functions/fchmodat.texi: Mention module 'fchmodat' instead
74616         of module 'openat'.
74617         * NEWS: Mention the change.
74619 2011-11-02  Jim Meyering  <meyering@redhat.com>
74621         putenv: indent #definition of "environ" to placate cppi
74622         * lib/putenv.c (environ): Make indentation reflect cpp nesting.
74624         gitlog-to-changelog: provide a ChangeLog-repair mechanism
74625         Git logs are often treated as immutable, because editing them
74626         changes the SHA1 checksums of all descendants.  Thus, errors in
74627         git logs tend to stay there forever.  However, when we generate
74628         a ChangeLog file -- typically for distribution -- from that git log,
74629         we can actually make corrections in the generated file.  The key
74630         lies in recording in machine-readable/applicable form the desired
74631         corrections.  See --help for description and an example.
74632         * build-aux/gitlog-to-changelog (parse_amend_file): New function.
74633         (usage): Describe it; alphabetize option descriptions.
74634         (main): Honor the new option, carefully.
74636 2011-11-01  Jim Meyering  <meyering@redhat.com>
74638         gitlog-to-changelog: avoid an infloop
74639         * build-aux/gitlog-to-changelog: Don't infloop for a commit log
74640         that ends up being empty.
74642 2011-11-01  Paul Eggert  <eggert@cs.ucla.edu>
74644         * MODULES.html.sh: Fix sed-script shell quoting and locale issues.
74645         (func_module): Replace foo=` ... sed -e COMPLICATED ... ` with
74646         bar=COMPLICATED; foo=` ... sed -e "$bar" ... ` when COMPLICATED
74647         contains (possibly-quoted) backslashes.  This should avoid
74648         all-too-common shell bugs if COMPLICATED contains backslashes in
74649         the "wrong" places.  Reported by David Evans in
74650         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00013.html>.
74651         When 'sed' uses character ranges like A-Z, invoke it in the C locale,
74652         because we want ASCII ranges.  Is there some reason we don't use
74653         the C locale everywhere in this script?
74654         (func_module, top level): Avoid unwanted pathname expansion when
74655         $repo_url_prefix or $repo_url_suffix_repl contain shell
74656         metacharacters like '?' and '*'.
74658 2011-11-01  Bruno Haible  <bruno@clisp.org>
74660         fchownat: Improve description.
74661         * modules/fchownat (Description): Add link to function.
74663 2011-11-01  Paul Eggert  <eggert@cs.ucla.edu>
74665         * tests/test-stdalign.c (TEST_ALIGNMENT): Shrink back to 8.
74666         mingw supports alignments only up to 8 (!).  Reported by Bruno Haible in
74667         <http://lists.gnu.org/r/bug-gnulib/2011-11/msg00006.html>.
74668         * doc/posix-headers/stdalign.texi (stdalign.h): Document this.
74670 2011-11-01  Bruno Haible  <bruno@clisp.org>
74672         alignof: Avoid collision with stdalign module.
74673         * lib/alignof.h (alignof): Remove macro.
74674         * NEWS: Mention the change.
74675         Reported by Paul Eggert.
74677 2011-11-01  Bruno Haible  <bruno@clisp.org>
74679         New module 'fchownat', split off from module 'openat'.
74680         * lib/openat.h (chownat, lchownat): Enable only if GNULIB_FCHOWNAT is
74681         defined.
74682         * m4/fchownat.m4: New file, extracted from m4/openat.m4.
74683         * m4/openat.m4 (gl_FUNC_OPENAT): Don't set GNULIB_FCHOWNAT. Don't
74684         invoke gl_FUNC_FCHOWNAT.
74685         (gl_FUNC_FCHOWNAT_DEREF_BUG, gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG,
74686         gl_FUNC_FCHOWNAT): Moved to m4/fchownat.m4.
74687         * modules/fchownat: New file, extracted from modules/openat.
74688         * modules/openat (Files): Remove lib/fchownat.c.
74689         (Depends-on): Remove lchown.
74690         (configure.ac): Remove AC_LIBOBJ of fchownat.
74691         * modules/fchownat-tests: New file, extracted from modules/openat-tests.
74692         * modules/openat-tests (Files): Remove tests/test-fchownat.c,
74693         tests/test-chown.h, tests/test-lchown.h, tests/nap.h.
74694         (Depends-on): Remove mgetgroups, usleep, stat-time.
74695         (configure.ac): Remove test for getegid.
74696         (Makefile.am): Remove rules for test-fchownat.
74697         * doc/posix-functions/fchownat.texi: Mention module 'fchownat' instead
74698         of module 'openat'.
74699         * NEWS: Mention the change.
74701 2011-10-31  Paul Eggert  <eggert@cs.ucla.edu>
74703         stdalign: port better to MSVC and to Sun C 5.11
74704         This fixes some of the problems reported by Bruno Haible in
74705         <http://lists.gnu.org/r/bug-gnulib/2011-10/msg00300.html>.
74706         * doc/posix-headers/stdalign.texi (stdalign.h): Document more
74707         shortcomings of MSVC and of Sun C 5.11.
74708         * lib/stdalign.in.h (_Alignas): Omit bogus extra parenthesis
74709         around __declspec arg.
74710         * modules/stdalign-tests (Files): Add tests/macros.h.
74711         * tests/test-stdalign.c: Do not include <stdlib.h>; no longer needed.
74712         Include macros.h, for ASSERT.
74713         (DECLARE_ALIGNED): Remove.
74714         (TEST_ALIGNMENT): Define to 16 if alignment is supported (more likely
74715         to catch bug), and to 1 if not (simplifies the rest of the code).
74716         (CHECK_STATIC): Always declare the alignment test vars; that's simpler.
74717         (CHECK_AUTO): Remove.
74718         (CHECK_ALIGNED): Check only the alignment of the static vars,
74719         since auto var alignment isn't supported by Sun C 5.11.
74720         (CHECK_TYPES): Remove.  All uses replaced by inline code, so that
74721         ASSERT failures are easier to diagnose.
74723 2011-10-31  Bruno Haible  <bruno@clisp.org>
74725         doc about some IRIX 5.3 problems.
74726         * doc/posix-functions/getpwnam_r.texi: Mention incompatible declaration
74727         on IRIX 5.3.
74728         * doc/posix-headers/poll.texi: Mention missing nfds_t on IRIX 5.3.
74729         * doc/posix-functions/ptsname.texi: Mention missing declaration on IRIX
74730         5.3.
74731         * doc/posix-functions/grantpt.texi: Likewise.
74732         * doc/posix-functions/unlockpt.texi: Likewise.
74733         * doc/posix-functions/lgamma.texi: Likewise.
74734         * doc/posix-functions/nextafter.texi: Likewise.
74735         * doc/posix-functions/remainder.texi: Likewise.
74736         * doc/posix-functions/select.texi: Mention misplaced declaration on
74737         IRIX 5.3.
74738         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
74740 2011-10-31  Dmitry V. Levin  <ldv@altlinux.org>
74742         gitlog-to-changelog: fix git-log invocation.
74743         git-log mishandles date strings before 1970-01-01 UTC, and there is
74744         no use to specify --since=1970-01-01 by default anyway.
74745         * build-aux/gitlog-to-changelog: By default, when no --since option
74746         was given, do not specify explicit --since option to git-log.
74748 2011-10-30  Dmitry V. Levin  <ldv@altlinux.org>
74750         gitlog-to-changelog: new option --append-dot.
74751         * build-aux/gitlog-to-changelog: New option --append-dot, makes the
74752         first non-blank line of each commit message terminated with a dot.
74754 2011-10-30  Bruno Haible  <bruno@clisp.org>
74756         ffsl, ffsll: Avoid compilation error due to 'restrict'.
74757         * lib/ffsl.h: Include <config.h>.
74758         Suggested by Tom G. Christensen <tgc@jupiterrise.com>.
74760 2011-10-30  Jim Meyering  <meyering@redhat.com>
74762         GNUmakefile: reenable "make syntax-check" for most projects
74763         Since Friday's commit 05e2d798, "maint.mk: don't maintain a second
74764         build-aux variable", "syntax-check" would do nothing but succeed with
74765         the "No version control files detected..." diagnostic (unless you
74766         happened to override _build-aux via cfg.mk).
74767         * top/GNUmakefile (_autoreconf, _build-aux): Move default definitions
74768         to precede inclusion of maint.mk.  Otherwise, these variables would
74769         be used undefined in any project that does not override the default.
74771 2011-10-29  Dmitry V. Levin  <ldv@altlinux.org>
74773         gitlog-to-changelog: treat a message with only blank lines as empty.
74774         * build-aux/gitlog-to-changelog: Move the code that removes leading and
74775         trailing blank lines before the code that issues a warning about an
74776         empty commit message.
74778 2011-10-30  Jim Meyering  <meyering@redhat.com>
74780         test-parse-datetime.c: avoid new DST-related false positive test failure
74781         * tests/test-parse-datetime.c (gmt_offset): Determine the "gmt_offset"
74782         based on the time/date we'll convert, not the current time.
74783         Otherwise, the moment we cross a DST boundary like today's in
74784         Europe, (CEST to CET), that offset ends up being one hour off.
74786 2011-10-27  Bruno Haible  <bruno@clisp.org>
74788         fstat: Tweak documentation.
74789         * modules/fstat (Description): More precise description.
74791 2011-10-27  Bruno Haible  <bruno@clisp.org>
74793         Update documentation regarding 'largefile' module.
74794         * doc/posix-functions/fstat.texi: Tweak wording.
74795         * doc/posix-functions/opendir.texi: Mention that the module fixes the
74796         problems with huge directories and/or small ino_t types.
74797         * doc/posix-functions/readdir.texi: Likewise.
74798         * doc/posix-functions/rewinddir.texi: Likewise.
74800 2011-10-28  Gary V. Vaughan  <gary@gnu.org>
74802         maint.mk: don't maintain a second build-aux variable.
74803         * maint.mk (build_aux): Removed.  The maintainer-makefile module
74804         depends on GNUmakefile, which already maintains a cfg.mk
74805         overridable $(_build-aux) for projects with a non-standard
74806         build-aux directory location, although without the $(srcdir)
74807         prefix.  Use that variable consistently instead of introducing a
74808         second one.  Adjust all call sites.
74810 2011-10-27  Paul Eggert  <eggert@cs.ucla.edu>
74812         Add stdalign module and use it in other modules.
74813         This is based on a previous proposal by Bruno Haible
74814         <https://lists.gnu.org/r/bug-gnulib/2011-07/msg00226.html>.
74816         stdalign: new module
74817         * doc/posix-headers/stdalign.texi, lib/stdalign.in.h, m4/stdalign.m4:
74818         * modules/stdalign: New files.
74819         * MODULES.html.sh (c1x_core_properties): Add stdalign.
74820         * doc/gnulib.texi (Header File Substitutes): Add stdalign.
74822         stdalign-tests: new module
74823         * modules/stdalign-tests, tests/test-stdalign.c: New files.
74825         argp: use stdalign
74826         * lib/argp-parse.c: Include <stdalign.h>.
74827         (alignof): Remove.
74828         * modules/argp (Depends-on): Add stdalign.
74830         crypto libraries: use stdalign
74831         * lib/md4.c, lib/md5.c, lib/sha1.c, lib/sha256.c, lib/sha512.c:
74832         Include <stdalign.h> and <stdint.h>.  Do not include <stddef.h>.
74833         Do not include <stdlib.h> twice, in md4.c.
74834         (UNALIGNED_P): Simplify by using alignof.  Use uintptr_t, not size_t,
74835         because we are accessing a pointer's bit-pattern, not a size.
74836         * modules/crypto/gc-md4 (Depends-on): Add stdalign.
74837         * modules/crypto/gc-md5, modules/crypto/gc-sha1, modules/crypto/md4:
74838         * modules/crypto/md5, modules/crypto/sha1, modules/crypto/sha256:
74839         * modules/crypto/sha512: Likewise.
74841         sys_socket: use stdalign, not alignof
74842         * lib/sys_socket.in.h: Include <stdalign.h> instead of <alignof.h>.
74843         * modules/sys_socket (Depends-on): Depend on stdalign, not alignof.
74845 2011-10-27  Bruno Haible  <bruno@clisp.org>
74847         raise test: Avoid a test failure on Linux/MIPS.
74848         * tests/test-raise.c (main): Try raising signal 199, not 99. Needed
74849         because 99 is a valid signal on Linux/MIPS.
74851 2011-10-27  Bruno Haible  <bruno@clisp.org>
74853         nonblocking tests: Fix test failure on Linux/MIPS.
74854         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/MIPS]:
74855         Set to 270000.
74857 2011-10-27  Bruno Haible  <bruno@clisp.org>
74859         utimensat: Work around problem on Linux/hppa.
74860         * lib/utimensat.c (rpl_utimensat) [Linux/hppa]: Reject invalid tv_nsec
74861         values.
74862         * doc/posix-functions/utimensat.texi: Mention the problem on Linux/hppa.
74864 2011-10-25  Jim Meyering  <meyering@redhat.com>
74866         maint.mk: fix a bug in sc_prohibit_stddef_without_use
74867         * top/maint.mk (sc_prohibit_stddef_without_use): Don't require / *\(/
74868         after symbols like NULL, size_t, etc.
74869         Reported by Alfred M. Szmidt.
74871         maint.mk: exempt ENODATA from a syntax-check rule
74872         * top/maint.mk (gl_extract_significant_defines_): Also exempt ENODATA
74873         from the sc_prohibit_always-defined_macros syntax-check rule.
74874         Add a comment.  See this for more details:
74875         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28739/focus=28795
74877 2011-10-23  Jim Meyering  <meyering@redhat.com>
74879         fts: close parent dir FD before returning from post-traversal fts_read
74880         The problem: the fts-using "mkdir -p A/B; rm -rf A" would attempt to
74881         unlink A, even though an FD open on A remained.  This is suboptimal
74882         (holding a file descriptor open longer than needed), but otherwise not
74883         a problem on Unix-like kernels.  However, on Cygwin with certain Novell
74884         file systems, (see http://cygwin.com/ml/cygwin/2011-10/msg00365.html),
74885         that represents a real problem: it causes the removal of A to fail
74886         with e.g., "rm: cannot remove `A': Device or resource busy"
74888         fts visits each directory twice and keeps a cache (fts_fd_ring) of
74889         directory file descriptors.  After completing the final, FTS_DP,
74890         visit of a directory, RESTORE_INITIAL_CWD intended to clear the FD
74891         cache, but then proceeded to add a new FD to it via the subsequent
74892         FCHDIR (which calls cwd_advance_fd and i_ring_push).  Before, the
74893         final file descriptor would be closed only via fts_close's call to
74894         fd_ring_clear.  Now, it is usually closed earlier, via the final
74895         FTS_DP-returning fts_read call.
74896         * lib/fts.c (restore_initial_cwd): New function, converted from
74897         the macro.  Call fd_ring_clear *after* FCHDIR, not before it.
74898         Update callers.
74899         Reported by Franz Sirl via the above URL, with analysis by Eric Blake
74900         in http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28739
74902 2011-10-23  Gary V. Vaughan  <gary@gnu.org>
74903             Bruno Haible  <bruno@clisp.org>
74904             Jim Meyering  <jim@meyering.net>
74906         readme-release: improve safety of release prep instructions.
74907         * README-release: Don't git pull all branches when only master
74908         is needed for the release process.
74909         Run make maintainer-clean before changing trees and merging.
74910         Don't try to run ./configure right after git pull in case files
74911         that influence the bootstrap process have changed, move the
74912         ./configure step to after running ./bootstrap.
74913         Don't bootstrap "one last time"... it's the first time!
74915 2011-10-22  Bruno Haible  <bruno@clisp.org>
74917         errno, strerror-override: Support for MSVC 10.
74918         * lib/errno.in.h (GNULIB_defined_ETXTBSY): Remove macro.
74919         (ENOMSG, EIDRM, ENOLINK, EPROTO, EBADMSG, EOVERFLOW, ENOTSUP,
74920         ENETRESET, ECONNABORTED, ECANCELED, EINPROGRESS, EALREADY, ENOTSOCK,
74921         EDESTADDRREQ, EMSGSIZE, EPROTOTYPE, ENOPROTOOPT, EPROTONOSUPPORT,
74922         EOPNOTSUPP, EAFNOSUPPORT, EADDRINUSE, EADDRNOTAVAIL, ENETDOWN,
74923         ENETUNREACH, ECONNRESET, ENOBUFS, EISCONN, ENOTCONN, ETIMEDOUT,
74924         ECONNREFUSED, ELOOP, EHOSTUNREACH, EWOULDBLOCK, ETXTBSY) [Win32]:
74925         Assign values compatible with MSVC 10.
74926         (ENODATA, ENOSR, ENOSTR, ENOTRECOVERABLE, EOWNERDEAD, ETIME, EOTHER):
74927         New macros.
74928         (GNULIB_defined_EWINSOCK): New macro.
74929         * lib/strerror-override.c (strerror_override): Update accordingly.
74930         * lib/strerror-override.h: Likewise.
74931         * lib/w32sock.h (set_winsock_errno): Map those WSA* values that are no
74932         longer equal to the corresponding errno value.
74933         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
74935 2011-10-22  Bruno Haible  <bruno@clisp.org>
74937         perror: Recognize when test program crashes.
74938         * m4/perror.m4 (gl_FUNC_PERROR): If the test program crashes due to
74939         strerror, set gl_cv_func_perror_works to no.
74940         Reported by Daniel Richard G. <skunk@iskunk.org>.
74942         perror: Fix indentation.
74943         * m4/perror.m4 (gl_FUNC_PERROR): Fix indentation.
74945 2011-10-22  Bruno Haible  <bruno@clisp.org>
74947         isfinite, isinf, isnan, signbit: Don't define as a macro in C++.
74948         * lib/math.in.h (_GL_MATH_CXX_REAL_FLOATING_DECL_1,
74949         _GL_MATH_CXX_REAL_FLOATING_DECL_2): nEW MACROS.
74950         (isfinite, isinf, isnan, signbit): In C++, define as overloaded
74951         functions, not as a macro.
74952         * tests/test-math-c++.cc (REAL_FLOATING_CHECK, OVERLOADED_CHECK): New
74953         macros.
74954         (isfinite, isinf, isnan, signbit): Check overloaded functions and
74955         absence of macro.
74956         Suggested by Eric Blake.
74957         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
74959 2011-10-21  Bruno Haible  <bruno@clisp.org>
74961         relocatable-prog-wrapper: Don't leave object files behind.
74962         * build-aux/install-reloc: Re-synchronize list of .o files to be
74963         removed with list of compilation units.
74965 2011-10-20  Bruno Haible  <bruno@clisp.org>
74967         openpty, posix_openpt: Remove code duplication.
74968         * lib/posix_openpt.c: Add comments about platforms, from lib/openpty.c.
74969         * lib/openpty.c: Include <stdlib.h>.
74970         (openpty): Use posix_openpt on all platforms except IRIX.
74971         * modules/openpty (Depends-on): Add posix_openpt. Add conditions.
74973 2011-10-20  Bruno Haible  <bruno@clisp.org>
74975         unlockpt: Detect invalid argument.
74976         * lib/unlockpt.c: Include <fcntl.h>.
74977         (unlockpt): Check whether fd is valid, using fcntl().
74978         * modules/unlockpt (Depends-on): Add fcntl-h.
74980 2011-10-20  Bruno Haible  <bruno@clisp.org>
74982         openpty: Avoid compilation error on AIX 6.1.
74983         * lib/pty.in.h [AIX]: Include <sys/ioctl.h>, for 'struct winsize'.
74985 2011-10-20  Bruno Haible  <bruno@clisp.org>
74987         posix_openpt: Support for OpenBSD.
74988         * lib/posix_openpt.c [OpenBSD]: Include <sys/ioctl.h>, <sys/tty.h>.
74989         (posix_openpt) [OpenBSD]: New code.
74990         * lib/grantpt.c: Include <fcntl.h>.
74991         (grantpt) [OpenBSD]: Only test whether fd is valid, nothing else.
74992         * modules/grantpt (Depends-on): Add fcntl-h.
74994 2011-10-20  Bruno Haible  <bruno@clisp.org>
74996         posix_openpt test: Coding style.
74997         * tests/test-posix_openpt.c: Use GNU coding style.
74999 2011-10-20  Bruno Haible  <bruno@clisp.org>
75001         grantpt: Support --avoid=pt_chown.
75002         * modules/grantpt (Files): Add lib/pty-private.h.
75004 2011-10-20  Bruno Haible  <bruno@clisp.org>
75006         posix_openpt: Fix autoconf macro.
75007         * m4/posix_openpt.m4 (gl_FUNC_POSIX_OPENPT): Fix variable name. Remove
75008         unneeded check for _getpty.
75010 2011-10-20  Bruno Haible  <bruno@clisp.org>
75012         openpty: Update comments.
75013         * lib/openpty.c: Add comments about Minix.
75015 2011-10-19  Eric Blake  <eblake@redhat.com>
75017         openpty: relax license
75018         * modules/openpty (License): Change from LGPLv3+ to LGPLv2+.
75020         pt_chown: use configmake to simplify build
75021         * modules/pt_chown (Makefile.am): Drop line guaranteed by configmake.
75023         ptsname and others: relax license
75024         * modules/grantpt (License): Change from LGPLv3+ to LGPLv2+.
75025         * modules/unlockpt (License): Likewise.
75026         * modules/pt_chown (License): Likewise.
75027         * modules/ptsname (License): Likewise.
75028         * modules/ttyname_r (License): Likewise.
75030 2011-10-19  Jim Meyering  <meyering@redhat.com>
75032         posix_openpt: remove spurious #endif
75033         * lib/posix_openpt.c (posix_openpt): Remove spurious #endif.
75035 2011-10-19  Gary V. Vaughan  <gary@gnu.org>
75037         maint.mk: Respect $(build_aux) in web-manual rule.
75038         * top/maint.mk (web-manual): Find gen-announce script in user's
75039         $(build_aux) directory instead of hard-coding 'build-aux'.
75041 2011-10-19  Bruno Haible  <bruno@clisp.org>
75043         posix_openpt: Fix compilation error.
75044         * lib/posix_openpt.c (posix_openpt): Renamed from posix_openpty.
75045         * doc/posix-functions/posix_openpt.texi: Mention ENOENT error code.
75046         Mention the openpty module as an alternative.
75048 2011-10-19  Bruno Haible  <bruno@clisp.org>
75050         Support for old NeXTstep 3.3 frexp().
75051         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Check for alarm. Limit the
75052         execution time of the test to 5 seconds.
75053         Reported by Daniel Richard G. <skunk@iskunk.org>.
75055 2011-10-19  Bruno Haible  <bruno@clisp.org>
75057         Support for old NeXTstep 3.3 sed.
75058         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): In the sed address
75059         part, use /.../, not \|...|. Escape periods in the header file name.
75060         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Likewise.
75061         Reported by Daniel Richard G. <skunk@iskunk.org>.
75063 2011-10-18  Daniel Richard G.  <skunk@iskunk.org>  (tiny change)
75065         Support for old NeXTstep 3.3 gcc.
75066         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Write
75067         'defined __STRICT_ANSI__', not '__STRICT_ANSI__'.
75068         * lib/math.in.h (_GL_NUM_UINT_WORDS etc.): Likewise.
75069         * lib/spawn.in.h (_Restrict_arr_): Likewise.
75070         * lib/regex.h (_Restrict_arr_): Likewise.
75071         * lib/regex_internal.h (re_token_t): Likewise.
75072         * lib/regexec.c (check_node_accept_bytes): Likewise.
75073         * tests/test-printf-posix.c (func1, func2, func3, func4): Likewise.
75075 2011-10-18  Eric Blake  <eblake@redhat.com>
75077         posix_openpt: new module
75078         * modules/posix_openpt: New module.
75079         * m4/posix_openpt.m4: New file.
75080         * lib/posix_openpt.c: Likewise.
75081         * m4/stdlib_h.m4 (gl_STDLIB_H): Check for decl.
75082         (gl_STDLIB_H_DEFAULTS): Set defaults.
75083         * modules/stdlib (Makefile.am): Substitute macros.
75084         * lib/stdlib.in.h (posix_openpt): Declare.
75085         * MODULES.html.sh (systems lacking POSIX:2008): Document it.
75086         * doc/posix-functions/posix_openpt.texi (posix_openpt): Likewise.
75087         * modules/posix_openpt-tests: New test module.
75088         * tests/test-posix_openpt.c: New test.
75090 2011-10-15  Bruno Haible  <bruno@clisp.org>
75092         xstrtoll: Fix compilation failure.
75093         * lib/xstrtol.c (ULLONG_MAX, LLONG_MAX, LLONG_MIN): New macros, taken
75094         from lib/strtol.c.
75095         * doc/posix-headers/limits.texi: Mention missing numerical limits on
75096         some platforms.
75097         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
75099 2011-10-15  Bruno Haible  <bruno@clisp.org>
75101         vasnprintf: Optimize bit search operation.
75102         * lib/vasnprintf.c (divide): Use optimizations from integer_length.c.
75103         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Require
75104         gl_DOUBLE_EXPONENT_LOCATION.
75105         * modules/vasnprintf (Files): Add m4/exponentd.m4.
75106         * modules/unistdio/u8-vasnprintf (Files): Likewise.
75107         * modules/unistdio/u8-u8-vasnprintf (Files): Likewise.
75108         * modules/unistdio/u16-vasnprintf (Files): Likewise.
75109         * modules/unistdio/u16-u16-vasnprintf (Files): Likewise.
75110         * modules/unistdio/u32-vasnprintf (Files): Likewise.
75111         * modules/unistdio/u32-u32-vasnprintf (Files): Likewise.
75112         * modules/unistdio/ulc-vasnprintf (Files): Likewise.
75113         * m4/isnand.m4 (gl_PREREQ_ISNAND): Use AC_REQUIRE.
75115 2011-10-15  Bruno Haible  <bruno@clisp.org>
75117         vasnprintf: Fix comments.
75118         * lib/vasnprintf.c (decode_long_double, decode_double): Fix comments.
75120 2011-10-14  Bruno Haible  <bruno@clisp.org>
75122         Tests for module 'integer_length_ll'.
75123         * modules/integer_length_ll-tests: New file.
75124         * tests/test-integer_length_ll.c: New file.
75126         New module 'integer_length_ll'.
75127         * lib/integer_length_ll.c: New file.
75128         * modules/integer_length_ll: New file.
75130 2011-10-14  Bruno Haible  <bruno@clisp.org>
75132         Tests for module 'integer_length_l'.
75133         * modules/integer_length_l-tests: New file.
75134         * tests/test-integer_length_l.c: New file.
75136         New module 'integer_length_l'.
75137         * lib/integer_length_l.c: New file.
75138         * modules/integer_length_l: New file.
75140 2011-10-14  Bruno Haible  <bruno@clisp.org>
75142         Tests for module 'integer_length'.
75143         * modules/integer_length-tests: New file.
75144         * tests/test-integer_length.c: New file.
75146         New module 'integer_length'.
75147         * lib/integer_length.h: New file.
75148         * lib/integer_length.c: New file.
75149         * modules/integer_length: New file.
75151 2011-10-14  Daniel Richard G.  <skunk@iskunk.org>  (tiny change)
75153         popen: Fix dependency conditions.
75154         * modules/popen (Depends-on, configure.ac): Fix shell syntax error.
75156 2011-10-14  Daniel Richard G.  <skunk@iskunk.org>  (tiny change)
75158         perror: Fix autoconf test.
75159         * m4/perror.m4 (gl_FUNC_PERROR): In the test program, include
75160         <stdlib.h> and <string.h>.
75162 2011-10-14  Bruno Haible  <bruno@clisp.org>
75164         ffsl: Optimize on 64-bit platforms.
75165         * lib/ffsl.h (FUNC): Omit a test from the last loop round. Do loop
75166         unrolling.
75168 2011-10-13  Bruno Haible  <bruno@clisp.org>
75170         ffsl: Optimize on 32-bit platforms.
75171         * lib/ffsl.h (FUNC): If TYPE has the same representation as 'int', just
75172         use ffs() without a loop.
75174         ffsl, ffsll: Optimize for GCC.
75175         * lib/ffsl.h (FUNC): Use GCC_BUILTIN if defined.
75176         * lib/ffsl.c (GCC_BUILTIN): New macro.
75177         * lib/ffsll.c (GCC_BUILTIN): Likewise.
75179 2011-10-13  Bruno Haible  <bruno@clisp.org>
75181         ffs, bcopy, memset: Support symbol renaming via config.h.
75182         * lib/ffs.c: Include <config.h>.
75183         * lib/bcopy.c: Likewise.
75184         * lib/memset.c: Likewise.
75186 2011-10-10  Bruno Haible  <bruno@clisp.org>
75188         atanl: Simplify for platforms where 'long double' == 'double'.
75189         * lib/atanl.c (atanl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
75190         alternative implementation.
75191         * m4/atanl.m4 (gl_FUNC_ATANL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75192         Determine ATANL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75193         * modules/atanl (Depends-on): Add atan. Update conditions.
75195 2011-10-10  Bruno Haible  <bruno@clisp.org>
75197         acosl: Simplify for platforms where 'long double' == 'double'.
75198         * lib/acosl.c (acosl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
75199         alternative implementation.
75200         * m4/acosl.m4 (gl_FUNC_ACOSL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75201         Determine ACOSL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75202         * modules/acosl (Depends-on): Add acos. Update conditions.
75204 2011-10-10  Bruno Haible  <bruno@clisp.org>
75206         asinl: Simplify for platforms where 'long double' == 'double'.
75207         * lib/asinl.c (asinl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
75208         alternative implementation.
75209         * m4/asinl.m4 (gl_FUNC_ASINL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75210         Determine ASINL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75211         * modules/asinl (Depends-on): Add asin. Update conditions.
75213 2011-10-10  Bruno Haible  <bruno@clisp.org>
75215         tanl: Simplify for platforms where 'long double' == 'double'.
75216         * lib/tanl.c (tanl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
75217         implementation.
75218         * m4/tanl.m4 (gl_FUNC_TANL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75219         Determine TANL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75220         * modules/tanl (Depends-on): Add tan. Update conditions.
75221         (configure.ac): Don't compile trigl.c if
75222         HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75224 2011-10-10  Bruno Haible  <bruno@clisp.org>
75226         cosl: Simplify for platforms where 'long double' == 'double'.
75227         * lib/cosl.c (cosl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
75228         implementation.
75229         * m4/cosl.m4 (gl_FUNC_COSL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75230         Determine COSL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75231         * modules/cosl (Depends-on): Add cos. Update conditions.
75232         (configure.ac): Don't compile sincosl.c and trigl.c if
75233         HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75235 2011-10-10  Bruno Haible  <bruno@clisp.org>
75237         sinl: Simplify for platforms where 'long double' == 'double'.
75238         * lib/sinl.c (sinl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
75239         implementation.
75240         * m4/sinl.m4 (gl_FUNC_SINL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75241         Determine SINL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75242         * modules/sinl (Depends-on): Add sin. Update conditions.
75243         (configure.ac): Don't compile sincosl.c and trigl.c if
75244         HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75246 2011-10-10  Bruno Haible  <bruno@clisp.org>
75248         logl: Simplify for platforms where 'long double' == 'double'.
75249         * lib/logl.c (logl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
75250         implementation.
75251         * m4/logl.m4 (gl_FUNC_LOGL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75252         Determine LOGL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75253         * modules/logl (Depends-on): Add log. Update conditions.
75255 2011-10-10  Bruno Haible  <bruno@clisp.org>
75257         expl: Simplify for platforms where 'long double' == 'double'.
75258         * lib/expl.c (expl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New alternative
75259         implementation.
75260         * m4/expl.m4 (gl_FUNC_EXPL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75261         Determine EXPL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75262         * modules/expl (Depends-on): Add exp. Update conditions.
75264 2011-10-10  Bruno Haible  <bruno@clisp.org>
75266         sqrtl: Simplify for platforms where 'long double' == 'double'.
75267         * lib/sqrtl.c (sqrtl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
75268         alternative implementation.
75269         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75270         Determine SQRTL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75271         * modules/sqrtl (Depends-on): Update conditions.
75273 2011-10-10  Bruno Haible  <bruno@clisp.org>
75275         ldexpl: Simplify for platforms where 'long double' == 'double'.
75276         * lib/ldexpl.c (ldexpl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
75277         alternative implementation.
75278         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75279         Determine LDEXPL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75280         * modules/ldexpl (Depends-on): Add ldexp. Update conditions.
75282 2011-10-10  Tom G. Christensen  <tgc@jupiterrise.com>  (tiny change)
75284         ffsll: set correct witness
75285         * modules/ffsll (configure.ac): Fix typo.
75287 2011-10-10  Bruno Haible  <bruno@clisp.org>
75289         printf-frexpl: Simplify for platforms where 'long double' == 'double'.
75290         * lib/printf-frexpl.c: Include <config.h>.
75291         (printf_frexpl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
75292         * lib/printf-frexp.c [!USE_LONG_DOUBLE]: Don't include <config.h> a
75293         second time.
75294         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Require
75295         gl_LONG_DOUBLE_VS_DOUBLE.
75296         * modules/printf-frexpl (Depends-on): Add printf-frexp. Update
75297         conditions.
75299 2011-10-10  Bruno Haible  <bruno@clisp.org>
75301         frexpl: Simplify for platforms where 'long double' == 'double'.
75302         * lib/frexpl.c: Include <config.h>.
75303         (frexpl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
75304         * lib/frexp.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
75305         time.
75306         * m4/frexpl.m4 (gl_FUNC_FREXPL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75307         Determine FREXPL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75308         (gl_FUNC_FREXPL_NO_LIBM): Require gl_LONG_DOUBLE_VS_DOUBLE.
75309         * modules/frexpl (Depends-on): Add frexp. Update conditions.
75310         * modules/frexpl-nolibm (Depends-on): Add frexp-nolibm. Update
75311         conditions.
75313 2011-10-10  Jim Meyering  <meyering@redhat.com>
75315         test-renameat: don't leave behind a temporary file
75316         * tests/test-renameat.c (main): Don't forget to remove a temporary file.
75317           ERROR: files left in build directory after distclean:
75318           ./gltests/test-renameat.too
75319           make[1]: *** [distcleancheck] Error 1
75320         Reported by Tom G. Christensen.
75322 2011-10-09  Bruno Haible  <bruno@clisp.org>
75324         rint: Determine RINT_LIBM correctly on AIX 7.
75325         * m4/mathfunc.m4 (gl_MATHFUNC): Try to invoke the function also
75326         directly, not only through a function pointer. Also accept an optional
75327         4th argument with extra code.
75328         * m4/rint.m4 (gl_FUNC_RINT): Pass an extra code that gets turned into a
75329         rintf() call by gcc when optimizing.
75331         mathfunc.m4: Refactor.
75332         * m4/mathfunc.m4 (gl_MATHFUNC): Assign the argument list to a temporary
75333         m4 variable.
75335 2011-10-09  Bruno Haible  <bruno@clisp.org>
75337         rintl: Simplify for platforms where 'long double' == 'double'.
75338         * lib/rintl.c: Include <config.h>.
75339         (rintl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
75340         * lib/rint.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
75341         time.
75342         * m4/rintl.m4 (gl_FUNC_RINTL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75343         Determine RINTL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75344         * modules/rintl (Depends-on): Add rint. Update conditions.
75346 2011-10-09  Bruno Haible  <bruno@clisp.org>
75348         roundl: Simplify for platforms where 'long double' == 'double'.
75349         * lib/roundl.c: Include <config.h>.
75350         (roundl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
75351         * lib/round.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
75352         time.
75353         * m4/roundl.m4 (gl_FUNC_ROUNDL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75354         Determine ROUNDL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75355         * modules/roundl (Depends-on): Add round. Update conditions.
75357 2011-10-09  Bruno Haible  <bruno@clisp.org>
75359         truncl: Simplify for platforms where 'long double' == 'double'.
75360         * lib/truncl.c: Include <config.h>.
75361         (truncl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
75362         * lib/trunc.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
75363         time.
75364         * m4/truncl.m4 (gl_FUNC_TRUNCL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75365         Determine TRUNCL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75366         * modules/truncl (Depends-on): Add trunc. Update conditions.
75368 2011-10-09  Bruno Haible  <bruno@clisp.org>
75370         ceill: Simplify for platforms where 'long double' == 'double'.
75371         * lib/ceill.c: Include <config.h>.
75372         (ceill) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
75373         * lib/ceil.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
75374         time.
75375         * m4/ceill.m4 (gl_FUNC_CEILL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75376         Determine CEILL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75377         * modules/ceill (Depends-on): Add ceil. Update conditions.
75379 2011-10-09  Bruno Haible  <bruno@clisp.org>
75381         floorl: Simplify for platforms where 'long double' == 'double'.
75382         * lib/floorl.c: Include <config.h>.
75383         (floorl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New function.
75384         * lib/floor.c [!USE_LONG_DOUBLE]: Don't include <config.h> a second
75385         time.
75386         * m4/floorl.m4 (gl_FUNC_FLOORL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75387         Determine FLOORL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75388         * modules/floorl (Depends-on): Add floor. Update conditions.
75390 2011-10-09  Bruno Haible  <bruno@clisp.org>
75392         rint: Fix ordering constraints.
75393         * m4/rint.m4 (gl_FUNC_RINT): Require gl_MATH_H_DEFAULTS.
75394         * m4/rintf.m4 (gl_FUNC_RINTF): Likewise.
75395         * m4/rintl.m4 (gl_FUNC_RINTL): Likewise.
75397 2011-10-09  Bruno Haible  <bruno@clisp.org>
75399         copysignl: Simplify for platforms where 'long double' == 'double'.
75400         * lib/copysignl.c (copysignl) [HAVE_SAME_LONG_DOUBLE_AS_DOUBLE]: New
75401         alternative.
75402         * m4/copysignl.m4 (gl_FUNC_COPYSIGNL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75403         Determine COPYSIGNL_LIBM according to HAVE_SAME_LONG_DOUBLE_AS_DOUBLE.
75404         * modules/copysignl (Depends-on): Add copysign. Update conditions.
75406 2011-10-09  Bruno Haible  <bruno@clisp.org>
75408         Tests for module 'rintl'.
75409         * modules/rintl-tests: New file.
75410         * tests/test-rintl.c: New file.
75412         New module 'rintl'.
75413         * lib/math.in.h (rintl): New declaration.
75414         * lib/rintl.c: New file.
75415         * m4/rintl.m4: New file.
75416         * m4/math_h.m4 (gl_MATH_H): Test whether rintl is declared.
75417         (gl_MATH_H_DEFAULTS): Initialize GNULIB_RINTL, HAVE_RINTL.
75418         * modules/math (Makefile.am): Substitute GNULIB_RINTL, HAVE_RINTL.
75419         * modules/rintl: New file.
75420         * tests/test-math-c++.cc: Check the declaration of rintl.
75421         * modules/math-c++-tests (Makefile.am): Link test-math-c++ against
75422         $(RINTL_LIBM). Needed on IRIX 6.5 with cc.
75423         * doc/posix-functions/rintl.texi: Mention the new module.
75425 2011-10-09  Bruno Haible  <bruno@clisp.org>
75427         Tests for module 'rintf'.
75428         * modules/rintf-tests: New file.
75429         * tests/test-rintf.c: New file.
75431         New module 'rintf'.
75432         * lib/math.in.h (rintf): New declaration.
75433         * lib/rintf.c: New file.
75434         * m4/rintf.m4: New file.
75435         * m4/math_h.m4 (gl_MATH_H): Test whether rintf is declared.
75436         (gl_MATH_H_DEFAULTS): Initialize GNULIB_RINTF, HAVE_RINTF.
75437         * modules/math (Makefile.am): Substitute GNULIB_RINTF, HAVE_RINTF.
75438         * modules/rintf: New file.
75439         * tests/test-math-c++.cc: Check the declaration of rintf.
75440         * doc/posix-functions/rintf.texi: Mention the new module.
75442 2011-10-09  Bruno Haible  <bruno@clisp.org>
75444         rint: Support for MSVC.
75445         * lib/math.in.h (rint): New declaration.
75446         * lib/rint.c: New file.
75447         * m4/rint.m4: New file.
75448         * m4/math_h.m4 (gl_MATH_H): Test whether rint is declared.
75449         (gl_MATH_H_DEFAULTS): Initialize GNULIB_RINT, HAVE_RINT.
75450         * modules/math (Makefile.am): Substitute GNULIB_RINT, HAVE_RINT.
75451         * modules/rint (Description): Fix.
75452         (Files): Add lib/rint.c, m4/rint.m4.
75453         (Depends-on): Add math.
75454         (configure.ac): Invoke gl_FUNC_RINT, AC_LIBOBJ,
75455         gl_MATH_MODULE_INDICATOR.
75456         * tests/test-math-c++.cc: Check the declaration of rint.
75457         * modules/math-c++-tests (Makefile.am): Link test-math-c++ against
75458         $(RINT_LIBM). Needed on IRIX 6.5 with cc.
75459         * doc/posix-functions/rint.texi: Mention the replacement provided by
75460         the module.
75462         rint tests: More tests.
75463         * tests/test-rint.c: Include <float.h>, <stdio.h>, isnand-nolibm.h,
75464         minus-zero.h, infinity.h, nan.h.
75465         (main): Skip the test if the current rounding mode is not standard. Add
75466         tests for negative numbers, minus zero, infinity, NaN.
75467         * modules/rint-tests (Files): Add tests/minus-zero.h, tests/infinity.h,
75468         tests/nan.h.
75469         (Depends-on): Add isnand-nolibm.
75471 2011-10-09  Bruno Haible  <bruno@clisp.org>
75473         Tests for module 'copysignl'.
75474         * modules/copysignl-tests: New file.
75475         * tests/test-copysignl.c: New file.
75477         New module 'copysignl'.
75478         * lib/math.in.h (copysignl): New declaration.
75479         * lib/copysignl.c: New file.
75480         * m4/copysignl.m4: New file.
75481         * m4/math_h.m4 (gl_MATH_H): Test whether copysignl is declared.
75482         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COPYSIGNL, HAVE_COPYSIGNL.
75483         * modules/math (Makefile.am): Substitute GNULIB_COPYSIGNL,
75484         HAVE_COPYSIGNL.
75485         * modules/copysignl: New file.
75486         * tests/test-math-c++.cc: Check the declaration of copysignl.
75487         * modules/math-c++-tests (Makefile.am): Link test-math-c++ against
75488         $(COPYSIGNL_LIBM). Needed on IRIX 6.5 with cc.
75489         * doc/posix-functions/copysignl.texi: Mention the new module.
75491 2011-10-09  Bruno Haible  <bruno@clisp.org>
75493         Tests for module 'copysignf'.
75494         * modules/copysignf-tests: New file.
75495         * tests/test-copysignf.c: New file.
75497         New module 'copysignf'.
75498         * lib/math.in.h (copysignf): New declaration.
75499         * lib/copysignf.c: New file.
75500         * m4/copysignf.m4: New file.
75501         * m4/math_h.m4 (gl_MATH_H): Test whether copysignf is declared.
75502         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COPYSIGNF, HAVE_COPYSIGNF.
75503         * modules/math (Makefile.am): Substitute GNULIB_COPYSIGNF,
75504         HAVE_COPYSIGNF.
75505         * modules/copysignf: New file.
75506         * tests/test-math-c++.cc: Check the declaration of copysignf.
75507         * doc/posix-functions/copysignf.texi: Mention the new module.
75509 2011-10-09  Bruno Haible  <bruno@clisp.org>
75511         Ensure that HAVE_* variables are set to 1 before they are set to 0.
75512         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Require gl_DIRENT_H_DEFAULTS.
75513         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Require gl_ARPA_INET_H_DEFAULTS.
75514         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
75515         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Require
75516         gl_SIGNAL_H_DEFAULTS.
75518 2011-10-09  Bruno Haible  <bruno@clisp.org>
75520         poll: Make macro safer.
75521         * m4/poll.m4 (gl_FUNC_POLL): Complain if, after invoking gl_POLL_H,
75522         ac_cv_header_poll_h is not set.
75524 2011-10-09  Bruno Haible  <bruno@clisp.org>
75526         copysign: Provide replacement.
75527         * lib/math.in.h (copysign): New declaration.
75528         * lib/copysign.c: New file.
75529         * m4/copysign.m4: New file.
75530         * m4/math_h.m4 (gl_MATH_H): Test whether copysign is declared.
75531         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COPYSIGN, HAVE_COPYSIGN.
75532         * modules/math (Makefile.am): Substitute GNULIB_COPYSIGN,
75533         HAVE_COPYSIGN.
75534         * modules/copysign (Description): Clarify.
75535         (Files): Add lib/copysign.c, m4/copysign.m4.
75536         (Depends-on): Add math, signbit.
75537         (configure.ac): Invoke gl_FUNC_COPYSIGN, AC_LIBOBJ,
75538         gl_MATH_MODULE_INDICATOR.
75539         * tests/test-math-c++.cc: Check the declaration of copysign.
75540         * doc/posix-functions/copysign.texi: Mention the effects of the module
75541         on Minix and MSVC.
75543 2011-10-09  Bruno Haible  <bruno@clisp.org>
75545         isinf: Ensure macro on AIX 5.1.
75546         * m4/isinf.m4 (gl_ISINF): Also test whether isinf is defined as a
75547         macro.
75548         * doc/posix-functions/isinf.texi: Mention also AIX 5.1 as deficient.
75550 2011-10-09  Bruno Haible  <bruno@clisp.org>
75552         *printf-posix tests: Fix for platforms where 'long double' == 'double'.
75553         * modules/snprintf-posix-tests (configure.ac): Require
75554         gl_LONG_DOUBLE_VS_DOUBLE.
75555         * modules/sprintf-posix-tests (configure.ac): Likewise.
75556         * modules/vasnprintf-posix-tests (configure.ac): Likewise.
75557         * modules/vasprintf-posix-tests (configure.ac): Likewise.
75558         * modules/vsnprintf-posix-tests (configure.ac): Likewise.
75559         * modules/vsprintf-posix-tests (configure.ac): Likewise.
75560         * tests/test-snprintf-posix.h (test_function): Avoid 80-bit long double
75561         tests on platforms where 'long double' is the same as 'double'.
75562         * tests/test-sprintf-posix.h (test_function): Likewise.
75563         * tests/test-vasnprintf-posix.c (test_function): Likewise.
75564         * tests/test-vasprintf-posix.c (test_function): Likewise.
75566         *printf: Fix for platforms where 'long double' == 'double'.
75567         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
75568         gl_LONG_DOUBLE_VS_DOUBLE. Don't blindly assume 80-bit 'long double'.
75569         * modules/dprintf-posix (Files): Add m4/math_h.m4.
75570         * modules/fprintf-posix (Files): Likewise.
75571         * modules/obstack-printf-posix (Files): Likewise.
75572         * modules/snprintf-posix (Files): Likewise.
75573         * modules/sprintf-posix (Files): Likewise.
75574         * modules/vasnprintf (Files): Likewise.
75575         * modules/vasnprintf-posix (Files): Likewise.
75576         * modules/vasprintf-posix (Files): Likewise.
75577         * modules/vdprintf-posix (Files): Likewise.
75578         * modules/vfprintf-posix (Files): Likewise.
75579         * modules/vsnprintf-posix (Files): Likewise.
75580         * modules/vsprintf-posix (Files): Likewise.
75581         * modules/unistdio/u8-vasnprintf (Files): Likewise.
75582         * modules/unistdio/u8-u8-vasnprintf (Files): Likewise.
75583         * modules/unistdio/u16-vasnprintf (Files): Likewise.
75584         * modules/unistdio/u16-u16-vasnprintf (Files): Likewise.
75585         * modules/unistdio/u32-vasnprintf (Files): Likewise.
75586         * modules/unistdio/u32-u32-vasnprintf (Files): Likewise.
75587         * modules/unistdio/ulc-vasnprintf (Files): Likewise.
75589         isnanl[-nolibm]: Fix for platforms where 'long double' == 'double'.
75590         * lib/isnan.c (rpl_isnanl): Don't blindly assume 80-bit 'long double'.
75591         * m4/isnanl.m4 (gl_PREREQ_ISNANL): Require gl_LONG_DOUBLE_VS_DOUBLE.
75592         (gl_FUNC_ISNANL_WORKS): Likewise. Don't blindly assume 80-bit
75593         'long double'.
75594         * modules/isnanl-nolibm (Files): Add m4/math_h.m4.
75596         isinf: Fix for platforms where 'long double' == 'double'.
75597         * m4/isinf.m4 (gl_ISINFL_WORKS): Require gl_LONG_DOUBLE_VS_DOUBLE.
75598         Don't blindly assume 80-bit 'long double'.
75600         isfinite: Fix for platforms where 'long double' == 'double'.
75601         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Require gl_LONG_DOUBLE_VS_DOUBLE.
75602         Don't blindly assume 80-bit 'long double'.
75604         isfinite, isinf, isnan tests: Avoid syntax error on MSVC 9.
75605         * m4/math_h.m4 (gl_LONG_DOUBLE_VS_DOUBLE): New macro.
75606         * modules/isfinite-tests (configure.ac): Require
75607         gl_LONG_DOUBLE_VS_DOUBLE.
75608         * modules/isinf-tests (configure.ac): Likewise.
75609         * modules/isnan-tests (configure.ac): Likewise.
75610         * modules/isnanl-tests (configure.ac): Likewise.
75611         * modules/isnanl-nolibm-tests (configure.ac): Likewise.
75612         * tests/test-isfinite.c (test_isfinitel): Avoid 80-bit long double
75613         tests on platforms where 'long double' is the same as 'double'.
75614         * tests/test-isinf.c (test_isinfl): Likewise.
75615         * tests/test-isnan.c (test_long_double): Likewise.
75616         * tests/test-isnanl.h (main): Likewise.
75618 2011-10-08  Bruno Haible  <bruno@clisp.org>
75620         Tests for module 'tanhf'.
75621         * modules/tanhf-tests: New file.
75622         * tests/test-tanhf.c: New file.
75624         New module 'tanhf'.
75625         * lib/math.in.h (tanhf): New declaration.
75626         * lib/tanhf.c: New file.
75627         * m4/tanhf.m4: New file.
75628         * m4/math_h.m4 (gl_MATH_H): Test whether tanhf is declared.
75629         (gl_MATH_H_DEFAULTS): Initialize GNULIB_TANHF, HAVE_TANHF.
75630         * modules/math (Makefile.am): Substitute GNULIB_TANHF, HAVE_TANHF.
75631         * modules/tanhf: New file.
75632         * tests/test-math-c++.cc: Check the declaration of tanhf.
75633         * doc/posix-functions/tanhf.texi: Mention the new module.
75635         tanh: Use a .m4 file.
75636         * m4/tanh.m4: New file.
75637         * modules/tanh (Files): Add it.
75638         (configure.ac): Just invoke gl_FUNC_TANH.
75640 2011-10-08  Bruno Haible  <bruno@clisp.org>
75642         Tests for module 'coshf'.
75643         * modules/coshf-tests: New file.
75644         * tests/test-coshf.c: New file.
75646         New module 'coshf'.
75647         * lib/math.in.h (coshf): New declaration.
75648         * lib/coshf.c: New file.
75649         * m4/coshf.m4: New file.
75650         * m4/math_h.m4 (gl_MATH_H): Test whether coshf is declared.
75651         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COSHF, HAVE_COSHF.
75652         * modules/math (Makefile.am): Substitute GNULIB_COSHF, HAVE_COSHF.
75653         * modules/coshf: New file.
75654         * tests/test-math-c++.cc: Check the declaration of coshf.
75655         * doc/posix-functions/coshf.texi: Mention the new module.
75657         cosh: Use a .m4 file.
75658         * m4/cosh.m4: New file.
75659         * modules/cosh (Files): Add it.
75660         (configure.ac): Just invoke gl_FUNC_COSH.
75662 2011-10-08  Bruno Haible  <bruno@clisp.org>
75664         Tests for module 'sinhf'.
75665         * modules/sinhf-tests: New file.
75666         * tests/test-sinhf.c: New file.
75668         New module 'sinhf'.
75669         * lib/math.in.h (sinhf): New declaration.
75670         * lib/sinhf.c: New file.
75671         * m4/sinhf.m4: New file.
75672         * m4/math_h.m4 (gl_MATH_H): Test whether sinhf is declared.
75673         (gl_MATH_H_DEFAULTS): Initialize GNULIB_SINHF, HAVE_SINHF.
75674         * modules/math (Makefile.am): Substitute GNULIB_SINHF, HAVE_SINHF.
75675         * modules/sinhf: New file.
75676         * tests/test-math-c++.cc: Check the declaration of sinhf.
75677         * doc/posix-functions/sinhf.texi: Mention the new module.
75679         sinh: Use a .m4 file.
75680         * m4/sinh.m4: New file.
75681         * modules/sinh (Files): Add it.
75682         (configure.ac): Just invoke gl_FUNC_SINH.
75684 2011-10-08  Bruno Haible  <bruno@clisp.org>
75686         Tests for module 'atan2f'.
75687         * modules/atan2f-tests: New file.
75688         * tests/test-atan2f.c: New file.
75690         New module 'atan2f'.
75691         * lib/math.in.h (atan2f): New declaration.
75692         * lib/atan2f.c: New file.
75693         * m4/atan2f.m4: New file.
75694         * m4/math_h.m4 (gl_MATH_H): Test whether atan2f is declared.
75695         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ATAN2F, HAVE_ATAN2F.
75696         * modules/math (Makefile.am): Substitute GNULIB_ATAN2F, HAVE_ATAN2F.
75697         * modules/atan2f: New file.
75698         * tests/test-math-c++.cc: Check the declaration of atan2f.
75699         * doc/posix-functions/atan2f.texi: Mention the new module.
75701         atan2: Use a .m4 file.
75702         * m4/atan2.m4: New file.
75703         * modules/atan2 (Files): Add it.
75704         (configure.ac): Just invoke gl_FUNC_ATAN2.
75706 2011-10-08  Bruno Haible  <bruno@clisp.org>
75708         Tests for module 'atanf'.
75709         * modules/atanf-tests: New file.
75710         * tests/test-atanf.c: New file.
75712         New module 'atanf'.
75713         * lib/math.in.h (atanf): New declaration.
75714         * lib/atanf.c: New file.
75715         * m4/atanf.m4: New file.
75716         * m4/math_h.m4 (gl_MATH_H): Test whether atanf is declared.
75717         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ATANF, HAVE_ATANF.
75718         * modules/math (Makefile.am): Substitute GNULIB_ATANF, HAVE_ATANF.
75719         * modules/atanf: New file.
75720         * tests/test-math-c++.cc: Check the declaration of atanf.
75721         * doc/posix-functions/atanf.texi: Mention the new module.
75723         atan: Use a .m4 file.
75724         * m4/atan.m4: New file.
75725         * modules/atan (Files): Add it.
75726         (configure.ac): Just invoke gl_FUNC_ATAN.
75728 2011-10-08  Bruno Haible  <bruno@clisp.org>
75730         Tests for module 'acosf'.
75731         * modules/acosf-tests: New file.
75732         * tests/test-acosf.c: New file.
75734         New module 'acosf'.
75735         * lib/math.in.h (acosf): New declaration.
75736         * lib/acosf.c: New file.
75737         * m4/acosf.m4: New file.
75738         * m4/math_h.m4 (gl_MATH_H): Test whether acosf is declared.
75739         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ACOSF, HAVE_ACOSF.
75740         * modules/math (Makefile.am): Substitute GNULIB_ACOSF, HAVE_ACOSF.
75741         * modules/acosf: New file.
75742         * tests/test-math-c++.cc: Check the declaration of acosf.
75743         * doc/posix-functions/acosf.texi: Mention the new module.
75745         acos: Use a .m4 file.
75746         * m4/acos.m4: New file.
75747         * modules/acos (Files): Add it.
75748         (configure.ac): Just invoke gl_FUNC_ACOS.
75750 2011-10-08  Bruno Haible  <bruno@clisp.org>
75752         Tests for module 'asinf'.
75753         * modules/asinf-tests: New file.
75754         * tests/test-asinf.c: New file.
75756         New module 'asinf'.
75757         * lib/math.in.h (asinf): New declaration.
75758         * lib/asinf.c: New file.
75759         * m4/asinf.m4: New file.
75760         * m4/math_h.m4 (gl_MATH_H): Test whether asinf is declared.
75761         (gl_MATH_H_DEFAULTS): Initialize GNULIB_ASINF, HAVE_ASINF.
75762         * modules/math (Makefile.am): Substitute GNULIB_ASINF, HAVE_ASINF.
75763         * modules/asinf: New file.
75764         * tests/test-math-c++.cc: Check the declaration of asinf.
75765         * doc/posix-functions/asinf.texi: Mention the new module.
75767         asin: Use a .m4 file.
75768         * m4/asin.m4: New file.
75769         * modules/asin (Files): Add it.
75770         (configure.ac): Just invoke gl_FUNC_ASIN.
75772 2011-10-08  Bruno Haible  <bruno@clisp.org>
75774         Tests for module 'tanf'.
75775         * modules/tanf-tests: New file.
75776         * tests/test-tanf.c: New file.
75778         New module 'tanf'.
75779         * lib/math.in.h (tanf): New declaration.
75780         * lib/tanf.c: New file.
75781         * m4/tanf.m4: New file.
75782         * m4/math_h.m4 (gl_MATH_H): Test whether tanf is declared.
75783         (gl_MATH_H_DEFAULTS): Initialize GNULIB_TANF, HAVE_TANF.
75784         * modules/math (Makefile.am): Substitute GNULIB_TANF, HAVE_TANF.
75785         * modules/tanf: New file.
75786         * tests/test-math-c++.cc: Check the declaration of tanf.
75787         * doc/posix-functions/tanf.texi: Mention the new module.
75789         tan: Use a .m4 file.
75790         * m4/tan.m4: New file.
75791         * modules/tan (Files): Add it.
75792         (configure.ac): Just invoke gl_FUNC_TAN.
75794 2011-10-08  Bruno Haible  <bruno@clisp.org>
75796         Tests for module 'cosf'.
75797         * modules/cosf-tests: New file.
75798         * tests/test-cosf.c: New file.
75800         New module 'cosf'.
75801         * lib/math.in.h (cosf): New declaration.
75802         * lib/cosf.c: New file.
75803         * m4/cosf.m4: New file.
75804         * m4/math_h.m4 (gl_MATH_H): Test whether cosf is declared.
75805         (gl_MATH_H_DEFAULTS): Initialize GNULIB_COSF, HAVE_COSF.
75806         * modules/math (Makefile.am): Substitute GNULIB_COSF, HAVE_COSF.
75807         * modules/cosf: New file.
75808         * tests/test-math-c++.cc: Check the declaration of cosf.
75809         * doc/posix-functions/cosf.texi: Mention the new module.
75811         cos: Use a .m4 file.
75812         * m4/cos.m4: New file.
75813         * modules/cos (Files): Add it.
75814         (configure.ac): Just invoke gl_FUNC_COS.
75816 2011-10-08  Bruno Haible  <bruno@clisp.org>
75818         Tests for module 'sinf'.
75819         * modules/sinf-tests: New file.
75820         * tests/test-sinf.c: New file.
75822         New module 'sinf'.
75823         * lib/math.in.h (sinf): New declaration.
75824         * lib/sinf.c: New file.
75825         * m4/sinf.m4: New file.
75826         * m4/math_h.m4 (gl_MATH_H): Test whether sinf is declared.
75827         (gl_MATH_H_DEFAULTS): Initialize GNULIB_SINF, HAVE_SINF.
75828         * modules/math (Makefile.am): Substitute GNULIB_SINF, HAVE_SINF.
75829         * modules/sinf: New file.
75830         * tests/test-math-c++.cc: Check the declaration of sinf.
75831         * doc/posix-functions/sinf.texi: Mention the new module.
75833         sin: Use a .m4 file.
75834         * m4/sin.m4: New file.
75835         * modules/sin (Files): Add it.
75836         (configure.ac): Just invoke gl_FUNC_SIN.
75838 2011-10-08  Bruno Haible  <bruno@clisp.org>
75840         Tests for module 'powf'.
75841         * modules/powf-tests: New file.
75842         * tests/test-powf.c: New file.
75844         New module 'powf'.
75845         * lib/math.in.h (powf): New declaration.
75846         * lib/powf.c: New file.
75847         * m4/powf.m4: New file.
75848         * m4/math_h.m4 (gl_MATH_H): Test whether powf is declared.
75849         (gl_MATH_H_DEFAULTS): Initialize GNULIB_POWF, HAVE_POWF.
75850         * modules/math (Makefile.am): Substitute GNULIB_POWF, HAVE_POWF.
75851         * modules/powf: New file.
75852         * tests/test-math-c++.cc: Check the declaration of powf.
75853         * doc/posix-functions/powf.texi: Mention the new module.
75855         pow: Use a .m4 file.
75856         * m4/pow.m4: New file.
75857         * modules/pow (Files): Add it.
75858         (configure.ac): Just invoke gl_FUNC_POW.
75860 2011-10-08  Bruno Haible  <bruno@clisp.org>
75862         Tests for module 'log10f'.
75863         * modules/log10f-tests: New file.
75864         * tests/test-log10f.c: New file.
75866         New module 'log10f'.
75867         * lib/math.in.h (log10f): New declaration.
75868         * lib/log10f.c: New file.
75869         * m4/log10f.m4: New file.
75870         * m4/math_h.m4 (gl_MATH_H): Test whether log10f is declared.
75871         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOG10F, HAVE_LOG10F.
75872         * modules/math (Makefile.am): Substitute GNULIB_LOG10F, HAVE_LOG10F.
75873         * modules/log10f: New file.
75874         * tests/test-math-c++.cc: Check the declaration of log10f.
75875         * doc/posix-functions/log10f.texi: Mention the new module.
75877         log10: Use a .m4 file.
75878         * m4/log10.m4: New file.
75879         * modules/log10 (Files): Add it.
75880         (configure.ac): Just invoke gl_FUNC_LOG10.
75882 2011-10-08  Bruno Haible  <bruno@clisp.org>
75884         Tests for module 'logf'.
75885         * modules/logf-tests: New file.
75886         * tests/test-logf.c: New file.
75888         New module 'logf'.
75889         * lib/math.in.h (logf): New declaration.
75890         * lib/logf.c: New file.
75891         * m4/logf.m4: New file.
75892         * m4/math_h.m4 (gl_MATH_H): Test whether logf is declared.
75893         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGF, HAVE_LOGF.
75894         * modules/math (Makefile.am): Substitute GNULIB_LOGF, HAVE_LOGF.
75895         * modules/logf: New file.
75896         * tests/test-math-c++.cc: Check the declaration of logf.
75897         * doc/posix-functions/logf.texi: Mention the new module.
75899         log: Use a .m4 file.
75900         * m4/log.m4: New file.
75901         * modules/log (Files): Add it.
75902         (configure.ac): Just invoke gl_FUNC_LOG.
75904 2011-10-08  Bruno Haible  <bruno@clisp.org>
75906         Tests for module 'expf'.
75907         * modules/expf-tests: New file.
75908         * tests/test-expf.c: New file.
75910         New module 'expf'.
75911         * lib/math.in.h (expf): New declaration.
75912         * lib/expf.c: New file.
75913         * m4/expf.m4: New file.
75914         * m4/math_h.m4 (gl_MATH_H): Test whether expf is declared.
75915         (gl_MATH_H_DEFAULTS): Initialize GNULIB_EXPF, HAVE_EXPF.
75916         * modules/math (Makefile.am): Substitute GNULIB_EXPF, HAVE_EXPF.
75917         * modules/expf: New file.
75918         * tests/test-math-c++.cc: Check the declaration of expf.
75919         * doc/posix-functions/expf.texi: Mention the new module.
75921         exp: Use a .m4 file.
75922         * m4/exp.m4: New file.
75923         * modules/exp (Files): Add it.
75924         (configure.ac): Just invoke gl_FUNC_EXP.
75926 2011-10-08  Bruno Haible  <bruno@clisp.org>
75928         Tests for module 'sqrtf'.
75929         * modules/sqrtf-tests: New file.
75930         * tests/test-sqrtf.c: New file.
75932         New module 'sqrtf'.
75933         * lib/math.in.h (sqrtf): New declaration.
75934         * lib/sqrtf.c: New file.
75935         * m4/sqrtf.m4: New file.
75936         * m4/math_h.m4 (gl_MATH_H): Test whether sqrtf is declared.
75937         (gl_MATH_H_DEFAULTS): Initialize GNULIB_SQRTF, HAVE_SQRTF.
75938         * modules/math (Makefile.am): Substitute GNULIB_SQRTF, HAVE_SQRTF.
75939         * modules/sqrtf: New file.
75940         * tests/test-math-c++.cc: Check the declaration of sqrtf.
75941         * doc/posix-functions/sqrtf.texi: Mention the new module.
75943 2011-10-08  Bruno Haible  <bruno@clisp.org>
75945         Tests: Avoid link failures w.r.t. libintl.
75946         * modules/faccessat-tests (Makefile.am): Link test-faccessat against
75947         $(LIBINTL).
75948         * modules/fchdir-tests (Makefile.am): Link test-fchdir against
75949         $(LIBINTL).
75950         * modules/getcwd-lgpl-tests (Makefile.am): Link test-getcwd-lgpl
75951         against $(LIBINTL).
75952         * modules/getcwd-tests (Makefile.am): Link test-getcwd against
75953         $(LIBINTL).
75954         * modules/openat-tests (Makefile.am): Link test-fchmodat against
75955         $(LIBINTL).
75956         * modules/stat-tests (Makefile.am): Link test-stat against $(LIBINTL).
75958 2011-10-08  Bruno Haible  <bruno@clisp.org>
75960         pow tests: Defeat compiler optimizations.
75961         * tests/test-pow.c (main): Assign arguments to x and y before use.
75963 2011-10-08  Bruno Haible  <bruno@clisp.org>
75965         gnulib-tool: Improve last commit.
75966         * gnulib-tool (func_modules_transitive_closure): Simplify code.
75967         (func_emit_autoconf_snippets): Instead of invoking func_acceptable,
75968         ignore dependencies that are not among the modules list.
75970 2011-10-07  Paul Eggert  <eggert@cs.ucla.edu>
75972         gnulib-tool: don't follow dependencies to avoided modules
75973         This fixes a bug that is related to the previous one.
75974         * gnulib-tool (func_modules_transitive_closure)
75975         (func_emit_autoconf_snippets):
75976         Check whether a dependency is acceptable before using it.
75977         (--extract-dependencies): Report an error if --avoid is also used,
75978         since this combination of options is not yet supported.
75980         gnulib-tool: fix typo that broke Emacs on powerpc-apple-darwin9.8.0.
75981         Problem reported by Peter Dyballa in
75982         <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9696>.
75983         * gnulib-tool (func_emit_autoconf_snippets): Quote with "", not '',
75984         when echoing "$condition".
75986 2011-10-07  Bruno Haible  <bruno@clisp.org>
75988         Fix documentation about math functions on MacOS X.
75989         * doc/posix-functions/exp2.texi: Don't say the function is missing on
75990         MacOS X 10.5.
75991         * doc/posix-functions/fdim.texi: Likewise.
75992         * doc/posix-functions/feclearexcept.texi: Likewise.
75993         * doc/posix-functions/fegetenv.texi: Likewise.
75994         * doc/posix-functions/fegetround.texi: Likewise.
75995         * doc/posix-functions/feholdexcept.texi: Likewise.
75996         * doc/posix-functions/feraiseexcept.texi: Likewise.
75997         * doc/posix-functions/fesetenv.texi: Likewise.
75998         * doc/posix-functions/fesetround.texi: Likewise.
75999         * doc/posix-functions/fetestexcept.texi: Likewise.
76000         * doc/posix-functions/feupdateenv.texi: Likewise.
76001         * doc/posix-functions/fmax.texi: Likewise.
76002         * doc/posix-functions/fmin.texi: Likewise.
76003         * doc/posix-functions/log2.texi: Likewise.
76004         * doc/posix-functions/modff.texi: Likewise.
76005         * doc/posix-functions/nan.texi: Likewise.
76006         * doc/posix-functions/nanf.texi: Likewise.
76007         * doc/posix-functions/nextafterf.texi: Likewise.
76008         * doc/posix-functions/remquo.texi: Likewise.
76010 2011-10-07  Bruno Haible  <bruno@clisp.org>
76012         modff: Drop assumption about library that defines modff.
76013         * m4/modff.m4 (gl_FUNC_MODFF): Use gl_MATHFUNC macro instead of
76014         AC_CHECK_FUNCS.
76015         * modules/modff (Files): Add m4/mathfunc.m4.
76017 2011-10-07  Bernhard Voelker  <mail@bernhard-voelker.de>
76019         raise tests: Avoid a GCC warning.
76020         * tests/test-raise.c (handler): Use _Noreturn.
76022 2011-10-07  Bruno Haible  <bruno@clisp.org>
76024         Tests for module 'ldexpf'.
76025         * modules/ldexpf-tests: New file.
76026         * tests/test-ldexpf.c: New file.
76028         New module 'ldexpf'.
76029         * lib/math.in.h (ldexpf): New declaration.
76030         * lib/ldexpf.c: New file.
76031         * m4/ldexpf.m4: New file.
76032         * m4/math_h.m4 (gl_MATH_H): Test whether ldexpf is declared.
76033         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LDEXPF, HAVE_LDEXPF.
76034         * modules/math (Makefile.am): Substitute GNULIB_LDEXPF, HAVE_LDEXPF.
76035         * modules/ldexpf: New file.
76036         * tests/test-math-c++.cc: Check the declaration of ldexpf.
76037         * doc/posix-functions/ldexpf.texi: Mention the new module.
76039 2011-10-06  Bruno Haible  <bruno@clisp.org>
76041         frexpf: Work around problems on IRIX and mingw.
76042         * lib/math.in.h (frexpf): Consider also REPLACE_FREXPF.
76043         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPF.
76044         * m4/frexpf.m4 (gl_FUNC_FREXPF_WORKS): New macro.
76045         (gl_FUNC_FREXPF): Invoke it. Set REPLACE_FREXPF.
76046         * modules/frexpf (Depends-on, configure.ac): Consider REPLACE_FREXPF.
76047         * modules/math (Makefile.am): Substitute REPLACE_FREXPF.
76048         * doc/posix-functions/frexpf.texi: Mention the IRIX and mingw problems.
76050 2011-10-06  Bruno Haible  <bruno@clisp.org>
76052         fabsf: Drop assumption about library that defines fabsf.
76053         * m4/fabsf.m4 (gl_FUNC_FABSF): Use gl_MATHFUNC macro instead of
76054         AC_CHECK_FUNCS.
76055         * modules/fabsf (Files): Add m4/mathfunc.m4.
76057 2011-10-06  Bruno Haible  <bruno@clisp.org>
76059         frexpf: Drop assumption about library that defines frexpf.
76060         * m4/mathfunc.m4 (gl_MATHFUNC): Support also the argument types
76061         'int *', 'float *', 'long double *', 'float', 'long double'.
76062         * m4/frexpf.m4 (gl_FUNC_FREXPF): Use gl_MATHFUNC macro instead of
76063         AC_CHECK_FUNCS.
76064         * modules/frexpf (Files): Add m4/mathfunc.m4.
76066         Tests for module 'frexpf'.
76067         * modules/frexpf-tests: New file.
76068         * tests/test-frexpf.c: New file.
76070         New module 'frexpf'.
76071         * lib/math.in.h (frexpf): New declaration.
76072         * lib/frexpf.c: New file.
76073         * m4/frexpf.m4: New file.
76074         * m4/math_h.m4 (gl_MATH_H): Test whether frexpf is declared.
76075         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPF, HAVE_FREXPF.
76076         * modules/math (Makefile.am): Substitute GNULIB_FREXPF, HAVE_FREXPF.
76077         * modules/frexpf: New file.
76078         * tests/test-math-c++.cc: Check the declaration of frexpf.
76079         * doc/posix-functions/frexpf.texi: Mention the new module.
76081 2011-10-06  Bruno Haible  <bruno@clisp.org>
76083         math: Sort function declarations of math.in.h.
76084         * lib/math.in.h (frexp, logb): Move declarations.
76086 2011-10-05  Bruno Haible  <bruno@clisp.org>
76088         Tests for module 'modff'.
76089         * modules/modff-tests: New file.
76090         * tests/test-modff.c: New file.
76092         New module 'modff'.
76093         * lib/math.in.h (modff): New declaration.
76094         * lib/modff.c: New file.
76095         * m4/modff.m4: New file.
76096         * m4/math_h.m4 (gl_MATH_H): Test whether modff is declared.
76097         (gl_MATH_H_DEFAULTS): Initialize GNULIB_MODFF, HAVE_MODFF.
76098         * modules/math (Makefile.am): Substitute GNULIB_MODFF, HAVE_MODFF.
76099         * modules/modff: New file.
76100         * tests/test-math-c++.cc: Check the declaration of modff.
76101         * doc/posix-functions/modff.texi: Mention the new module.
76103         modf tests: Make test sharper.
76104         * tests/test-modf.c (main): Strengthen upper bound.
76106         modf: Use a .m4 file.
76107         * m4/modf.m4: New file.
76108         * modules/modf (Files): Add it.
76109         (configure.ac): Just invoke gl_FUNC_MODF.
76111 2011-10-05  Bruno Haible  <bruno@clisp.org>
76113         Tests for module 'fmodf'.
76114         * modules/fmodf-tests: New file.
76115         * tests/test-fmodf.c: New file.
76117         New module 'fmodf'.
76118         * lib/math.in.h (fmodf): New declaration.
76119         * lib/fmodf.c: New file.
76120         * m4/fmodf.m4: New file.
76121         * m4/math_h.m4 (gl_MATH_H): Test whether fmodf is declared.
76122         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FMODF, HAVE_FMODF.
76123         * modules/math (Makefile.am): Substitute GNULIB_FMODF, HAVE_FMODF.
76124         * modules/fmodf: New file.
76125         * tests/test-math-c++.cc: Check the declaration of fmodf.
76126         * doc/posix-functions/fmodf.texi: Mention the new module.
76128         fmod: Use a .m4 file.
76129         * m4/fmod.m4: New file.
76130         * modules/fmod (Files): Add it.
76131         (configure.ac): Just invoke gl_FUNC_FMOD.
76133 2011-10-05  Bruno Haible  <bruno@clisp.org>
76135         Tests for module 'fabsf'.
76136         * modules/fabsf-tests: New file.
76137         * tests/test-fabsf.c: New file.
76139         New module 'fabsf'.
76140         * lib/math.in.h (fabsf): New declaration.
76141         * lib/fabsf.c: New file.
76142         * m4/fabsf.m4: New file.
76143         * m4/math_h.m4 (gl_MATH_H): Test whether fabsf is declared.
76144         (gl_MATH_H_DEFAULTS): Initialize GNULIB_FABSF, HAVE_FABSF.
76145         * modules/math (Makefile.am): Substitute GNULIB_FABSF, HAVE_FABSF.
76146         * modules/fabsf: New file.
76147         * tests/test-math-c++.cc: Check the declaration of fabsf.
76148         * doc/posix-functions/fabsf.texi: Mention the new module.
76150         fabs: Use a .m4 file.
76151         * m4/fabs.m4: New file.
76152         * modules/fabs (Files): Add it.
76153         (configure.ac): Just invoke gl_FUNC_FABS.
76155 2011-10-05  Jim Meyering  <meyering@redhat.com>
76157         file-has-acl: revert both recent changes, 80af92af and 95f7c57f
76158         * lib/file-has-acl.c: While the 2011-10-03 change does fix the
76159         ls -lL regression introduced in coreutils-8.12, it does so at the
76160         cost of an additional stat call in the common case.  Besides, now
76161         that the kernel change that prompted commit 95f7c57f has been reverted
76162         (see https://bugzilla.redhat.com/show_bug.cgi?id=720325#c24)
76163         we have no use for commit 95f7c57f, "file-has-acl: use
76164         acl_extended_file_nofollow if available".
76166 2011-10-03  Kamil Dudka  <kdudka@redhat.com>
76168         file-has-acl: revert unintended change in behavior of ls -L
76169         * lib/file-has-acl.c (acl_extended_file_wrap): New function,
76170         derived from...
76171         (file_has_acl): ...code here.  Call it.
76172         This problem was introduced with 2011-07-22 commit 95f7c57f,
76173         "file-has-acl: use acl_extended_file_nofollow if available".
76174         See http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/28538
76176 2011-10-03  Bruno Haible  <bruno@clisp.org>
76178         poll: Avoid link errors on MSVC.
76179         * m4/poll.m4 (gl_FUNC_POLL): Determine LIB_POLL.
76180         * modules/poll (Depends-on): Add sockets.
76181         (Link): New section.
76182         * NEWS: Mention the change.
76183         * modules/poll-tests (Makefile.am): Link test-poll against $(LIB_POLL).
76184         * modules/poll-h-c++-tests (Makefile.am): Link test-poll-h-c++ against
76185         $(LIB_POLL) instead of $(LIBSOCKET).
76187 2011-10-03  Bruno Haible  <bruno@clisp.org>
76189         sys_select tests: Fix link error on MSVC 9.
76190         * modules/sys_select-c++-tests (Makefile.am): Link test-sys_select-c++
76191         with $(LIB_SELECT) instead of $(LIBSOCKET).
76193 2011-10-03  Bruno Haible  <bruno@clisp.org>
76195         sys_select: Fix compilation error on mingw.
76196         * lib/sys_select.in.h: On native Windows, include <io.h>.
76198 2011-10-03  Bruno Haible  <bruno@clisp.org>
76200         wmemset: Support for MSVC.
76201         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Use a small test program to test
76202         whether wmemset() exists.
76204 2011-10-03  Bruno Haible  <bruno@clisp.org>
76206         wmemmove: Support for MSVC.
76207         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Use a small test program to test
76208         whether wmemmove() exists.
76210 2011-10-03  Bruno Haible  <bruno@clisp.org>
76212         wmemcpy: Support for MSVC.
76213         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Use a small test program to test
76214         whether wmemcpy() exists.
76216 2011-10-03  Bruno Haible  <bruno@clisp.org>
76218         wmemcmp: Support for MSVC.
76219         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Use a small test program to test
76220         whether wmemcmp() exists.
76222 2011-10-03  Bruno Haible  <bruno@clisp.org>
76224         wmemchr: Support for MSVC.
76225         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Use a small test program to test
76226         whether wmemchr() exists.
76228 2011-10-03  Bruno Haible  <bruno@clisp.org>
76230         glthread/*, strsignal: Support for MSVC.
76231         * lib/glthread/cond.h: Define WIN32_LEAN_AND_MEAN, so as to avoid
76232         including <winsock.h> on MSVC 9.
76233         * lib/glthread/lock.h: Likewise.
76234         * lib/glthread/thread.h: Likewise.
76235         * lib/glthread/tls.h: Likewise.
76236         * lib/glthread/yield.h: Likewise.
76237         * lib/strsignal.c: Include <string.h> first. Don't include <unistd.h>
76238         if HAVE_UNISTD_H is false.
76239         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Test for <unistd.h>.
76241 2011-10-03  Bruno Haible  <bruno@clisp.org>
76243         nonblocking tests: Fix test failure on OpenBSD/SPARC64.
76244         * tests/test-nonblocking-socket.h (SOCKET_DATA_BLOCK_SIZE) [OpenBSD]:
76245         Set to 100000.
76247 2011-10-03  Bruno Haible  <bruno@clisp.org>
76249         acl: Fix specification.
76250         * lib/file-has-acl.c (file_has_acl): Fix specification.
76252 2011-10-03  Bruno Haible  <bruno@clisp.org>
76254         relocatable-lib[-lgpl]: Avoid expensive /proc access on Linux, Cygwin.
76255         * lib/relocatable.c (ENABLE_COSTLY_RELOCATABLE): New macro.
76256         (compute_curr_prefix, shared_library_fullname,
76257         find_shared_library_fullname, get_shared_library_fullname, relocate):
76258         Use it together with PIC && INSTALLDIR.
76259         Reported by <jojelino@gmail.com>
76260         via Charles Wilson <cygwin@cwilson.fastmail.fm>.
76262 2011-10-01  Jim Meyering  <meyering@redhat.com>
76264         maint.mk: adjust a release-related rule not to require use of gzip
76265         * top/maint.mk (writable-files): Don't hard-code use of .tar.gz.
76266         Instead, check each file in $(DIST_ARCHIVES).  This is better for
76267         projects that build only .tar.xz files.  Also fix an erroneous test.
76269         test-linkat: don't leave behind a temporary file
76270         * tests/test-linkat.c (main): Don't forget to remove a temporary file.
76271         Otherwise, coreutils' "make distcheck" would fail with this:
76272           Only in /c/cu/tests/torture/coreutils/test/\
76273             coreutils-8.13.22-d5caf.old/gnulib-tests: test-linkat.too
76274           make[2]: *** [my-distcheck] Error 1
76276         float, math: add omitted file
76277         * lib/itold.c: Add file, required for yesterday's float change.
76279 2011-10-01  Bruno Haible  <bruno@clisp.org>
76281         isinf: Fix for OpenBSD/x86.
76282         * m4/isinf.m4 (gl_ISINFL_WORKS): Also test the behaviour of isinf on
76283         pseudo-NaNs, pseudo-Infinities, and other non-IEEE values.
76284         * doc/posix-functions/isinf.texi: Mention the problem on OpenBSD/x86.
76286 2011-10-01  Bruno Haible  <bruno@clisp.org>
76288         isfinite: Fix syntax error in configure test.
76289         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Fix syntax error.
76291         isfinite: Fix typo.
76292         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): When cross-compiling, set
76293         gl_cv_func_isfinitel_works, not gl_cv_func_isnanl_works.
76295 2011-10-01  Bruno Haible  <bruno@clisp.org>
76297         nonblocking tests: Fix test failure on Linux/IA-64.
76298         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/IA-64]:
76299         Set to 270000.
76301 2011-10-01  Bruno Haible  <bruno@clisp.org>
76303         mkfifoat tests: Fix a test failure on mingw.
76304         * tests/test-mkfifoat.c (main): Allow mkfifoat or test_mknodat to fail
76305         with error ENOSYS.
76307 2011-09-30  Bruno Haible  <bruno@clisp.org>
76309         float, math: Fix 'int' to 'long double' conversion on Linux/SPARC64.
76310         * m4/float_h.m4 (gl_FLOAT_H): Test conversion from 'int' to
76311         'long double'. Set REPLACE_ITOLD.
76312         * lib/float.in.h (_Qp_itoq, _gl_float_fix_itold): New declarations.
76313         * lib/math.in.h (_Qp_itoq, _gl_math_fix_itold): New declarations.
76314         * lib/itold.c: New file.
76315         * modules/float (Files): Add lib/itold.c.
76316         (configure.ac): When REPLACE_ITOLD is 1, arrange to compile itold.c.
76317         (Makefile.am): Substitute REPLACE_ITOLD.
76318         * modules/math (Depends-on): Add float.
76319         (Makefile.am): Substitute REPLACE_ITOLD.
76320         * doc/posix-headers/float.texi: Mention problem on Linux/SPARC64.
76321         * doc/posix-headers/math.texi: Likewise.
76322         * doc/posix-functions/logl.texi: Likewise.
76324 2011-09-30  Bruno Haible  <bruno@clisp.org>
76326         nonblocking tests: Fix test failure on Linux/SPARC (32-bit and 64-bit).
76327         * tests/test-nonblocking-pipe.h (PIPE_DATA_BLOCK_SIZE) [Linux/SPARC]:
76328         Set to 140000.
76330 2011-09-30  Bruno Haible  <bruno@clisp.org>
76332         gnulib-tool: Improve suggestion where to put gl_EARLY invocation.
76333         * gnulib-tool (func_import): If the configure.ac has an AC_PROG_CC_STDC
76334         invocation, say "right after AC_PROG_CC_STDC", not "right after
76335         AC_PROG_CC".
76336         Reported by Gary V. Vaughan <gary@gnu.org>.
76338 2011-09-30  Bruno Haible  <bruno@clisp.org>
76340         Centralize C99 requirement.
76341         * m4/gnulib-common.m4 (gl_PROG_CC_C99): New macro.
76342         * modules/stdarg (configure.ac-early): Invoke it instead of
76343         AC_PROG_CC_STDC.
76344         Reported by Gary V. Vaughan and Paul Eggert.
76346 2011-09-29  Bruno Haible  <bruno@clisp.org>
76348         float: Fix LDBL_MAX value on Linux/PowerPC.
76349         * m4/float_h.m4 (gl_FLOAT_H): Set FLOAT_H and REPLACE_FLOAT_LDBL also
76350         on Linux/PowerPC.
76351         * lib/float.in.h (LDBL_MAX): Redefine also on Linux/PowerPC.
76352         * lib/float.c (gl_LDBL_MAX): Also define on Linux/PowerPC.
76353         * doc/posix-headers/float.texi: Mention Linux/PowerPC as an affected
76354         platform.
76355         Reported by Andreas Metzler <ametzler@downhill.at.eu.org>.
76357 2011-09-29  Bruno Haible  <bruno@clisp.org>
76359         doc: Improve doc about gl_EARLY.
76360         * doc/gnulib-tool.texi (Initial import): Mention where to place an
76361         AC_PROG_CC_STDC invocation.
76362         Reported by Gary V. Vaughan <gary@gnu.org>.
76364 2011-09-28  Bruno Haible  <bruno@clisp.org>
76366         fgetc, fputc, fread, fwrite tests: Fix link error.
76367         * tests/test-fgetc.c (main): Don't invoke gl_msvc_inval_ensure_handler
76368         on non-MSVC platforms.
76369         * tests/test-fputc.c (main): Likewise.
76370         * tests/test-fread.c (main): Likewise.
76371         * tests/test-fwrite.c (main): Likewise.
76372         Reported by Jim Meyering.
76374 2011-09-27  Bruno Haible  <bruno@clisp.org>
76376         fputc, fwrite tests: Avoid test failure on MSVC.
76377         * tests/test-fgetc.c: Include msvc-inval.h.
76378         (main): Invoke gl_msvc_inval_ensure_handler.
76379         * tests/test-fputc.c: Include msvc-inval.h.
76380         (main): Invoke gl_msvc_inval_ensure_handler.
76381         * tests/test-fread.c: Include msvc-inval.h.
76382         (main): Invoke gl_msvc_inval_ensure_handler.
76383         * tests/test-fwrite.c: Include msvc-inval.h.
76384         (main): Invoke gl_msvc_inval_ensure_handler.
76385         * modules/fgetc-tests (Depends-on): Add msvc-inval.
76386         * modules/fputc-tests (Depends-on): Likewise.
76387         * modules/fread-tests (Depends-on): Likewise.
76388         * modules/fwrite-tests (Depends-on): Likewise.
76390 2011-09-27  Bruno Haible  <bruno@clisp.org>
76392         raise: Fix double declaration with modules 'sigprocmask' and 'sigpipe'.
76393         * lib/signal.in.h (GNULIB_defined_signal_blocking): New macro.
76394         (raise): Remove older, duplicated declaration.
76395         (_gl_raise_SIGPIPE): New declaration.
76396         * lib/sigprocmask.c (_gl_raise_SIGPIPE): New function.
76397         (rpl_raise): Remove function.
76398         * lib/raise.c (rpl_raise, raise): Merge into a single function. Handle
76399         a gnulib-defined SIGPIPE here.
76400         * m4/raise.m4 (gl_FUNC_RAISE): Set REPLACE_RAISE also if the module
76401         'sigprocmask' has detected missing signal-blocking and the module
76402         'sigpipe' is enabled.
76403         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>.
76405 2011-09-26  Gijs van Tulder  <gvtulder@gmail.com>
76407         base64-tests: avoid memory leak
76408         * tests/test-base64.c (main): Plug memory leak.
76410         base32: new module
76411         * modules/base32: New module.
76412         * lib/base32.c: New file.
76413         * lib/base32.h: Likewise.
76414         * m4/base32.m4: Likewise.
76415         * modules/base32-tests: New test.
76416         * tests/test-base32.c: Likewise.
76417         * MODULES.html.sh (Misc): Mention it.
76419 2011-09-26  Paul Eggert  <eggert@cs.ucla.edu>
76421         gnulib: use more-standard license notice wording
76422         * gnulib-tool (func_emit_copyright_notice): When emitting a
76423         license notice into a file, use the standard wording as suggested
76424         by the current information for GNU maintainers, except say "file"
76425         rather than "program".  The new wording gives a license version
76426         number, which addresses an issue raised by Glenn Morris in
76427         <http://lists.gnu.org/r/bug-gnulib/2011-09/msg00397.html>.
76428         * m4/onceonly.m4: Use that same wording here, too.
76430         dup2: minor simplification
76431         * m4/dup2.m4 (gl_PREREQ_DUP2): Don't require AC_C_INLINE,
76432         as lib/dup2.c no longer uses 'inline'.
76434 2011-09-25  Bruno Haible  <bruno@clisp.org>
76436         strings: Fix compilation error on MSVC.
76437         * lib/strings.in.h: Include <stddef.h> for size_t.
76439 2011-09-25  Bruno Haible  <bruno@clisp.org>
76441         fflush et al.: Document limitation on MSVC.
76442         * doc/posix-functions/fflush.texi: Document possible crash in handling
76443         mode other than DEFAULT_HANDLING.
76444         * doc/posix-functions/fgetc.texi: Likewise.
76445         * doc/posix-functions/fputc.texi: Likewise.
76446         * doc/posix-functions/fread.texi: Likewise.
76447         * doc/posix-functions/fwrite.texi: Likewise.
76449 2011-09-25  Bruno Haible  <bruno@clisp.org>
76451         msvc-inval: Allow three invalid parameter handling modes.
76452         * lib/msvc-inval.h: Don't include <stdlib.h> here.
76453         (DEFAULT_HANDLING, HAIRY_LIBRARY_HANDLING, SANE_LIBRARY_HANDLING): New
76454         macros.
76455         (gl_msvc_inval_ensure_handler, TRY_MSVC_INVAL, CATCH_MSVC_INVAL,
76456         DONE_MSVC_INVAL): Implement DEFAULT_HANDLING. Treat
76457         SANE_LIBRARY_HANDLING as a no-op.
76458         * lib/msvc-inval.c: Treat SANE_LIBRARY_HANDLING as a no-op. Include
76459         <stdlib.h>.
76460         (gl_msvc_invalid_parameter_handler): Implement DEFAULT_HANDLING.
76462 2011-09-25  Bruno Haible  <bruno@clisp.org>
76464         msvc-inval: Make handler multithread-safe.
76465         * lib/msvc-inval.h (struct gl_msvc_inval_per_thread): New type.
76466         (gl_msvc_inval_restart, gl_msvc_inval_restart_valid): Remove
76467         declarations.
76468         (gl_msvc_inval_current): New declaration.
76469         (TRY_MSVC_INVAL, CATCH_MSVC_INVAL, DONE_MSVC_INVAL) [!_MSC_VER]:
76470         Operate on the structure returned by gl_msvc_inval_current().
76471         * lib/msvc-inval.c (gl_msvc_inval_restart, gl_msvc_inval_restart_valid):
76472         Remove varaiables.
76473         (tls_index, tls_initialized): New variables.
76474         (not_per_thread): New variable.
76475         (gl_msvc_inval_current): New function.
76476         (gl_msvc_invalid_parameter_handler) [!_MSC_VER]: Use the structure
76477         returned by gl_msvc_inval_current().
76479 2011-09-25  Bruno Haible  <bruno@clisp.org>
76481         msvc-inval: Install handler globally.
76482         * lib/msvc-inval.h (STATUS_GNULIB_INVALID_PARAMETER): Define also for
76483         !_MSC_VER.
76484         (gl_msvc_invalid_parameter_handler): Remove declaration.
76485         (gl_msvc_inval_restart_valid, gl_msvc_inval_ensure_handler): New
76486         declarations.
76487         (TRY_MSVC_INVAL, CATCH_MSVC_INVAL, DONE_MSVC_INVAL) [!_MSC_VER]:
76488         Install the handler globally, don't uninstall it.
76489         * lib/msvc-inval.c (gl_msvc_inval_restart_valid): New variable.
76490         (gl_msvc_invalid_parameter_handler): Make static. If the restart is not
76491         currently valid, call RaiseException instead.
76492         (gl_msvc_inval_initialized, gl_msvc_inval_ensure_handler): Define also
76493         for !_MSC_VER.
76495 2011-09-25  Bruno Haible  <bruno@clisp.org>
76497         strerror_r-posix: Fix for MSVC 9.
76498         * lib/strerror_r.c (local_snprintf): New function.
76499         (snprintf): Define to local_snprintf, not to _snprintf.
76501 2011-09-25  Bruno Haible  <bruno@clisp.org>
76503         ftruncate: Support for MSVC 9.
76504         * lib/ftruncate.c: Include errno.h, msvc-inval.h.
76505         (chsize_nothrow): New function.
76506         (chsize): Redefine as a macro.
76507         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): Require AC_C_INLINE.
76508         * modules/ftruncate (Depends-on): Add msvc-inval.
76510 2011-09-25  Bruno Haible  <bruno@clisp.org>
76512         New module 'fstat'.
76513         * lib/sys_stat.in.h (fstat): Declare only if GNULIB_FSTAT is set.
76514         * lib/fstat.c: New file, based on a piece of lib/fchdir.c.
76515         * lib/fchdir.c (rpl_fstat): Remove function.
76516         * m4/fstat.m4: New file.
76517         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_FSTAT.
76518         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Test whether fstat is
76519         declared.
76520         (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_FSTAT.
76521         * modules/sys_stat (Makefile.am): Substitute GNULIB_FSTAT.
76522         * modules/fstat: New file.
76523         * modules/sys_stat-tests (Depends-on): Remove fstat-tests.
76524         * tests/test-sys_stat-c++.cc (fstat): Check only if GNULIB_TEST_FSTAT
76525         is set.
76526         * doc/posix-functions/fstat.texi: Mention the new module and the
76527         problem on MSVC.
76528         * NEWS: Mention the change.
76529         * modules/acl (Depends-on): Add fstat.
76530         * modules/chdir-safer (Depends-on): Likewise.
76531         * modules/chown (Depends-on): Likewise.
76532         * modules/copy-file (Depends-on): Likewise.
76533         * modules/fchdir (Depends-on): Likewise.
76534         * modules/fdopendir (Depends-on): Likewise.
76535         * modules/fopen (Depends-on): Likewise.
76536         * modules/fts (Depends-on): Likewise.
76537         * modules/getcwd (Depends-on): Likewise.
76538         * modules/isapipe (Depends-on): Likewise.
76539         * modules/linkat (Depends-on): Likewise.
76540         * modules/lseek (Depends-on): Likewise.
76541         * modules/mkdir-p (Depends-on): Likewise.
76542         * modules/open (Depends-on): Likewise.
76543         * modules/openat (Depends-on): Likewise.
76544         * modules/read-file (Depends-on): Likewise.
76545         * modules/renameat (Depends-on): Likewise.
76546         * modules/utimens (Depends-on): Likewise.
76548 2011-09-25  Bruno Haible  <bruno@clisp.org>
76550         linkat: Fix compilation on MSVC 9.
76551         * lib/linkat.c: Don't include <stdint.h>.
76553 2011-09-25  Bruno Haible  <bruno@clisp.org>
76555         fclose: Support for MSVC 9.
76556         * lib/fclose.c: Include msvc-inval.h.
76557         (fclose_nothrow): New function.
76558         (rpl_fclose): Use it.
76559         * modules/fclose (Depends-on): Add msvc-inval.
76560         * doc/posix-functions/fclose.texi: Mention the problem on MSVC.
76562 2011-09-24  Paul Eggert  <eggert@cs.ucla.edu>
76564         dup2: minor simplifications
76565         * lib/dup2.c (ms_windows_dup2): Omit 'inline' as it's not clear
76566         that it's a performance win.
76567         (rpl_dup2): Change "if !((defined _WIN32 || defined __WIN32__) &&
76568         ! defined __CYGWIN__)" to "ifdef F_GETFL".
76570 2011-09-24  Jim Meyering  <meyering@redhat.com>
76572         test-futimens: avoid a warning from gcc -Wshadow
76573         * tests/test-futimens.h (test_futimens): Rename inner local, s/fd/fd0/
76574         to avoid a shadowing warning.
76576 2011-09-24  Bruno Haible  <bruno@clisp.org>
76578         fdopen: Support for MSVC 9.
76579         * m4/fdopen.m4 (gl_FUNC_FDOPEN): Set REPLACE_FDOPEN also if
76580         HAVE_MSVC_INVALID_PARAMETER_HANDLER is 1.
76581         * lib/fdopen.c: Include msvc-inval.h.
76582         (fdopen_nothrow): New function.
76583         (rpl_fdopen): Use it.
76584         * modules/fdopen (Depends-on): Add msvc-inval.
76585         * modules/fclose-tests (Depends-on): Add fdopen.
76586         * modules/fflush-tests (Depends-on): Likewise.
76587         * modules/fgetc-tests (Depends-on): Likewise.
76588         * modules/fputc-tests (Depends-on): Likewise.
76589         * modules/fread-tests (Depends-on): Likewise.
76590         * modules/freopen-tests (Depends-on): Likewise.
76591         * modules/fseeko-tests (Depends-on): Likewise.
76592         * modules/ftello-tests (Depends-on): Likewise.
76593         * modules/fwrite-tests  (Depends-on): Likewise.
76594         * doc/posix-functions/fdopen.texi: Mention the problem on MSVC.
76596 2011-09-24  Bruno Haible  <bruno@clisp.org>
76598         fgetc, fputc, fread, fwrite tests: Avoid compilation error on MSVC.
76599         * modules/fgetc-tests (Depends-on): Add unistd.
76600         * modules/fputc-tests (Depends-on): Likewise.
76601         * modules/fread-tests (Depends-on): Likewise.
76602         * modules/fwrite-tests (Depends-on): Likewise.
76604 2011-09-24  Bruno Haible  <bruno@clisp.org>
76606         dup: Simplify autoconf test.
76607         * m4/dup.m4 (gl_FUNC_DUP): Don't run a test program. Instead, just rely
76608         on gl_MSVC_INVAL's result.
76610 2011-09-24  Bruno Haible  <bruno@clisp.org>
76612         Tests for function fwrite().
76613         * modules/fwrite-tests: New file.
76614         * tests/test-fwrite.c: New file.
76615         * modules/stdio-tests (Depends-on): Add fwrite-tests.
76617         Tests for function fread().
76618         * modules/fread-tests: New file.
76619         * tests/test-fread.c: New file.
76620         * modules/stdio-tests (Depends-on): Add fread-tests.
76622         Activate fputc tests.
76623         * modules/stdio-tests (Depends-on): Add fputc-tests.
76625         Enhance fgetc, fputc tests.
76626         * tests/test-fgetc.c (main): Also test the stream's error indicator.
76627         * tests/test-fputc.c (main): Likewise.
76629 2011-09-24  Bruno Haible  <bruno@clisp.org>
76631         write: Support for MSVC 9.
76632         * lib/unistd.in.h (write): Replace also when GNULIB_UNISTD_H_NONBLOCKING
76633         is not 1.
76634         * lib/write.c (write_nothrow): New function.
76635         (rpl_write): Define also when GNULIB_NONBLOCKING or GNULIB_SIGPIPE is
76636         not 1. Use write_nothrow.
76637         * m4/write.m4 (gl_FUNC_WRITE): Replace read if the platform has an
76638         invalid parameter handler.
76639         (gl_PREREQ_WRITE): New macro.
76640         * modules/write (Depends-on): Add msvc-inval.
76641         (configure.ac): Invoke gl_PREREQ_WRITE.
76642         * doc/posix-functions/write.texi: Mention the problem on MSVC.
76644 2011-09-24  Bruno Haible  <bruno@clisp.org>
76646         read: Fix last commit.
76647         * lib/read.c (read_nothrow): Change return type to 'ssize_t'.
76649 2011-09-24  Bruno Haible  <bruno@clisp.org>
76651         dup2: Fix last commit.
76652         * lib/dup2.c: Restore comments. Treat Cygwin like Unix.
76653         (rpl_dup2): Disable fcntl workaround on native Windows.
76655         sigprocmask: Make code safer.
76656         * lib/sigprocmask.c: Move '#include "msvc-inval.h"' before the code
76657         section that changes macro definitions for this compilation unit.
76659 2011-09-23  Paul Eggert  <eggert@cs.ucla.edu>
76661         dup2: clarify by coalescing Windows-specific material
76662         * lib/dup2.c: Move '#include "msvc-inval.h"' and '#include
76663         "msvc-nothrow.h"' to the Windows-specific section, so that the
76664         Emacs source need not contain these include files.
76665         (ms_windows_dup2): Rename from dup2_nothrow, and move all the
76666         Windows-specific fixes into this function rather than just the
76667         nothrow fix, as this shortens and clarifies the code.  Always
76668         define as a function, as that's a bit cleaner than having it be
76669         sometimes a function and sometimes a macro.
76670         (rpl_dup2): Move the Windows-specific stuff out of here and into
76671         ms_windows_dup2.  Don't protect the Haiku-related fix with
76672         "#if !defined __linux__", as the same code also works around
76673         a Linux kernel bug, and it doesn't add any system calls on any
76674         platform.  Add comment about FreeBSD 6.1.
76676         sigprocmask: move #include directive
76677         * lib/sigprocmask.c: Move '#include "msvc-inval.h"' to the
76678         Windows-specific section, so that the Emacs source need not
76679         contain msvc-inval.h.
76681 2011-09-23  Bruno Haible  <bruno@clisp.org>
76683         read: Support for MSVC 9.
76684         * lib/unistd.in.h (read): Replace also when GNULIB_UNISTD_H_NONBLOCKING
76685         is not 1.
76686         * lib/read.c (read_nothrow): New function.
76687         (rpl_read): Define also when GNULIB_NONBLOCKING is not 1. Use
76688         read_nothrow.
76689         * m4/read.m4 (gl_FUNC_READ): Replace read if the platform has an
76690         invalid parameter handler.
76691         (gl_PREREQ_READ): New macro.
76692         * modules/read (Depends-on): Add msvc-inval.
76693         (configure.ac): Invoke gl_PREREQ_READ.
76694         * doc/posix-functions/read.texi: Mention the problem on MSVC.
76696 2011-09-23  Bruno Haible  <bruno@clisp.org>
76698         close: Support for MSVC 9.
76699         * lib/close.c: Include <errno.h>, msvc-inval.h.
76700         (close_nothrow): New function.
76701         (rpl_close): Use it.
76702         * m4/close.m4 (gl_FUNC_CLOSE): Replace close if the platform has an
76703         invalid parameter handler.
76704         * modules/close (Depends-on): Add msvc-inval.
76705         * modules/dup2-tests (Depends-on): Add close.
76706         * modules/dup3-tests (Depends-on): Likewise.
76707         * modules/fcntl-tests (Depends-on): Likewise.
76708         * modules/spawn-pipe-tests (Depends-on): Likewise.
76709         * modules/unistd-safer-tests (Depends-on): Likewise.
76710         * doc/posix-functions/close.texi: Mention the problem on MSVC.
76712 2011-09-23  Bruno Haible  <bruno@clisp.org>
76714         New module 'dup'.
76715         * lib/unistd.in.h (dup): Declare only if the 'dup' module is in use.
76716         Allow replacement.
76717         * lib/dup.c: New file.
76718         * lib/fchdir.c (rpl_dup): Remove function.
76719         * m4/dup.m4: New file.
76720         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_DUP here.
76721         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether 'dup' is declared.
76722         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_DUP.
76723         * modules/unistd (Makefile.am): Substitute GNULIB_DUP.
76724         * modules/dup: New file.
76725         * tests/test-unistd-c++.cc: Check the signature of 'dup' only if the
76726         'dup' module is in use.
76727         * modules/fdopendir (Depends-on): Add dup.
76728         * modules/fdutimensat-tests (Depends-on): Likewise.
76729         * modules/fts (Depends-on): Likewise.
76730         * modules/futimens-tests (Depends-on): Likewise.
76731         * modules/posix_spawnp-tests (Depends-on): Likewise.
76732         * modules/unistd-safer-tests (Depends-on): Likewise.
76733         * modules/utimens-tests (Depends-on): Likewise.
76734         * doc/posix-functions/dup.texi: Mention the new module and the problem
76735         on MSVC.
76737 2011-09-23  Bruno Haible  <bruno@clisp.org>
76739         getdtablesize: Support for MSVC 9.
76740         * lib/getdtablesize.c: Include msvc-inval.h.
76741         (_setmaxstdio_nothrow): New function.
76742         (_setmaxstdio): Redefine it.
76743         * m4/getdtablesize.m4 (gl_PREREQ_GETDTABLESIZE): New macro.
76744         * modules/getdtablesize (Depends-on): Add msvc-inval.
76745         (configure.ac): Invoke gl_PREREQ_GETDTABLESIZE.
76747 2011-09-23  Bruno Haible  <bruno@clisp.org>
76749         signal-h: Rename from signal.
76750         * modules/signal-h: Renamed from modules/signal.
76751         * modules/pthread_sigmask (Depends-on): Update.
76752         * modules/raise (Depends-on): Likewise.
76753         * modules/sigaction (Depends-on): Likewise.
76754         * modules/sigpipe (Depends-on): Likewise.
76755         * modules/sigprocmask (Depends-on): Likewise.
76756         * modules/sys_select (Depends-on): Likewise.
76757         * modules/signal-h-tests: Renamed from modules/signal-tests.
76758         (Files, Depends-on, Makefile.am): Update.
76759         * tests/test-signal-h.c: Renamed from tests/test-signal.c.
76760         * modules/signal-h-c++-tests: Renamed from modules/signal-c++-tests.
76761         (Files, Makefile.am): Update.
76762         * tests/test-signal-h-c++.cc: Renamed from tests/test-signal-c++.cc.
76763         * tests/test-signal-h-c++2.cc: Renamed from tests/test-signal-c++2.cc.
76764         * modules/signal: New placeholder file.
76765         * MODULES.html.sh (Support for systems lacking POSIX:2008): Update.
76766         * doc/posix-headers/signal.texi: Update.
76767         * NEWS: Mention the change.
76769 2011-09-23  Bruno Haible  <bruno@clisp.org>
76771         sigprocmask: Avoid crashes through signal() on MSVC 9.
76772         * lib/sigprocmask.c: Include msvc-inval.h.
76773         (signal_nothrow): New function.
76774         (signal): Redefine it.
76775         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Require AC_C_INLINE.
76776         * modules/sigprocmask (Depends-on): Add msvc-inval.
76777         * doc/posix-functions/signal.texi: Mention the problem on MSVC.
76779 2011-09-23  Bruno Haible  <bruno@clisp.org>
76781         Tests for module 'raise'.
76782         * modules/raise-tests: New file.
76783         * tests/test-raise.c: New file.
76785         raise: Support for MSVC.
76786         * lib/signal.in.h (raise): New declaration.
76787         * lib/raise.c (raise_nothrow, rpl_raise): New alternate implementation
76788         for native Windows platforms.
76789         * m4/raise.m4: New file.
76790         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize GNULIB_RAISE,
76791         HAVE_RAISE, REPLACE_RAISE.
76792         * modules/signal (Makefile.am): Substitute GNULIB_RAISE, HAVE_RAISE,
76793         REPLACE_RAISE.
76794         * modules/raise (Status, Notice): Remove fields.
76795         (Files): Add m4/raise.m4.
76796         (Depends-on): Add signal, msvc-inval.
76797         (configure.ac): Use the common idioms.
76798         (Maintainer): Add me.
76799         * tests/test-signal-c++.cc: Check the signature of raise.
76800         * doc/posix-functions/raise.texi: Mention the problem on MSVC.
76802 2011-09-23  Bruno Haible  <bruno@clisp.org>
76804         pipe2: Fix compilation on pre-C99 compilers.
76805         * lib/pipe2.c (pipe2): Surround verify(...) declaration with braces.
76807 2011-09-23  Bruno Haible  <bruno@clisp.org>
76809         New module 'msvc-nothrow'. Makes _get_osfhandle safe on MSVC 9.
76810         * lib/msvc-nothrow.h: New file.
76811         * lib/msvc-nothrow.c: New file.
76812         * m4/msvc-nothrow.m4: New file.
76813         * modules/msvc-nothrow: New file.
76814         * lib/dup2.c: Include msvc-nothrow.h.
76815         (rpl_dup2): No need to protect _get_osfhandle call here.
76816         * lib/accept4.c: Include msvc-nothrow.h.
76817         * lib/error.c: Likewise.
76818         * lib/fcntl.c: Likewise.
76819         * lib/lseek.c: Likewise.
76820         * lib/nonblocking.c: Likewise.
76821         * lib/poll.c: Likewise.
76822         * lib/read.c: Likewise.
76823         * lib/select.c: Likewise.
76824         * lib/sockets.h: Likewise.
76825         * lib/sockets.c: Likewise.
76826         * lib/stdio-read.c: Likewise.
76827         * lib/stdio-write.c: Likewise.
76828         * lib/write.c: Likewise.
76829         * lib/w32sock.h: Likewise.
76830         * lib/w32spawn.h: Likewise.
76831         * lib/flock.c: Include msvc-nothrow.h instead of <io.h>.
76832         * lib/fsync.c: Likewise.
76833         * lib/isapipe.c: Likewise.
76834         * modules/dup2 (Depends-on): Add msvc-nothrow.
76835         * modules/accept4 (Depends-on): Likewise.
76836         * modules/error (Depends-on): Likewise.
76837         * modules/fcntl (Depends-on): Likewise.
76838         * modules/lseek (Depends-on): Likewise.
76839         * modules/nonblocking (Depends-on): Likewise.
76840         * modules/poll (Depends-on): Likewise.
76841         * modules/read (Depends-on): Likewise.
76842         * modules/select (Depends-on): Likewise.
76843         * modules/sockets (Depends-on): Likewise.
76844         * modules/sigpipe (Depends-on): Likewise.
76845         * modules/write (Depends-on): Likewise.
76846         * modules/accept (Depends-on): Likewise.
76847         * modules/bind (Depends-on): Likewise.
76848         * modules/connect (Depends-on): Likewise.
76849         * modules/gethostname (Depends-on): Likewise.
76850         * modules/getpeername (Depends-on): Likewise.
76851         * modules/getsockname (Depends-on): Likewise.
76852         * modules/getsockopt (Depends-on): Likewise.
76853         * modules/ioctl (Depends-on): Likewise.
76854         * modules/listen (Depends-on): Likewise.
76855         * modules/recv (Depends-on): Likewise.
76856         * modules/recvfrom (Depends-on): Likewise.
76857         * modules/send (Depends-on): Likewise.
76858         * modules/sendto (Depends-on): Likewise.
76859         * modules/setsockopt (Depends-on): Likewise.
76860         * modules/shutdown (Depends-on): Likewise.
76861         * modules/socket (Depends-on): Likewise.
76862         * modules/execute (Depends-on): Likewise.
76863         * modules/spawn-pipe (Depends-on): Likewise.
76864         * modules/flock (Depends-on): Likewise.
76865         * modules/fsync (Depends-on): Likewise.
76866         * modules/isapipe (Depends-on): Likewise.
76867         * tests/test-cloexec.c: Include msvc-nothrow.h.
76868         * tests/test-dup-safer.c: Likewise.
76869         * tests/test-dup2.c: Likewise.
76870         * tests/test-dup3.c: Likewise.
76871         * tests/test-fcntl.c: Likewise.
76872         * tests/test-pipe.c: Likewise.
76873         * tests/test-pipe2.c: Likewise.
76874         * modules/cloexec-tests (Depends-on): Add msvc-nothrow.
76875         * modules/unistd-safer-tests (Depends-on): Likewise.
76876         * modules/dup2-tests (Depends-on): Likewise.
76877         * modules/dup3-tests (Depends-on): Likewise.
76878         * modules/fcntl-tests (Depends-on): Likewise.
76879         * modules/pipe-posix-tests (Depends-on): Likewise.
76880         * modules/pipe2-tests (Depends-on): Likewise.
76882 2011-09-23  Bruno Haible  <bruno@clisp.org>
76884         dup2: Make code more maintainable.
76885         * lib/dup2.c (dup2_nothrow): New function, extracted from rpl_dup2.
76886         (rpl_dup2): Use it.
76887         * m4/dup2.m4 (gl_PREREQ_DUP2): New macro.
76888         * modules/dup2 (configure.ac): Invoke it.
76889         Reported by Paul Eggert.
76891 2011-09-23  Bruno Haible  <bruno@clisp.org>
76893         msvc-inval: Fix compilation error.
76894         * lib/msvc-inval.h: Include <excpt.h>.
76896 2011-09-23  Bruno Haible  <bruno@clisp.org>
76898         mkdir: Tweak for MSVC 9.
76899         * lib/sys_stat.in.h: Update comments.
76900         * doc/posix-functions/mkdir.texi: Mention problem on MSVC 9.
76902         Tests for module 'chdir'.
76903         * modules/chdir-tests: New file.
76904         * tests/test-chdir.c: New file.
76906         New module 'chdir'.
76907         * modules/chdir: New file.
76908         * lib/unistd.in.h: Include <io.h>, <direct.h> also for chdir.
76909         (chdir): New declaration.
76910         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether chdir is declared.
76911         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_CHDIR.
76912         * modules/unistd (Makefile.am): Substitute GNULIB_CHDIR.
76913         * tests/test-unistd-c++.cc: Check signature of chdir.
76914         * doc/posix-functions/chdir.texi: Mention problem on native Windows.
76915         * modules/chdir-long (Depends-on): Add chdir.
76916         * modules/fchdir (Depends-on): Likewise.
76917         * modules/rename (Depends-on): Likewise.
76918         * modules/savewd (Depends-on): Likewise.
76920         rmdir: Support for mingw, MSVC 9.
76921         * lib/unistd.in.h: Include <io.h> and <direct.h> also for rmdir.
76922         * doc/posix-functions/getcwd.texi: Mention problem on native Windows.
76924         getcwd: Tweak for MSVC 9.
76925         * lib/unistd.in.h: Update comments.
76926         * doc/posix-functions/getcwd.texi: Mention problem on MSVC 9.
76928 2011-09-22  Bruno Haible  <bruno@clisp.org>
76930         strerror_r-posix: Avoid a link error on MSVC.
76931         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R): Check for snprintf.
76932         * lib/strerror_r.c (snprintf): Define to _snprintf if it doesn't exist.
76934 2011-09-22  Bruno Haible  <bruno@clisp.org>
76936         select: Avoid link errors on MSVC.
76937         * m4/select.m4 (gl_FUNC_SELECT): Determine LIB_SELECT.
76938         * modules/select (Link): Replace $(LIBSOCKET) with $(LIB_SELECT).
76939         * modules/pselect (Link): Likewise.
76940         * NEWS: Mention the change.
76941         * modules/select-tests (Makefile.am): Link test-select, test-select-fd,
76942         test-select-stdin against $(LIB_SELECT).
76943         * modules/pselect-tests (Makefile.am): Link test-pselect against
76944         $(LIB_SELECT).
76946 2011-09-22  Bruno Haible  <bruno@clisp.org>
76948         select: Avoid compilation error on MSVC.
76949         * lib/select.c: Don't include <stdbool.h>.
76951 2011-09-21  Bruno Haible  <bruno@clisp.org>
76953         Consolidate all uses of PATH_MAX in *.m4 files.
76954         * m4/pathmax.m4 (gl_PATHMAX_SNIPPET, gl_PATHMAX_SNIPPET_PREREQ): New
76955         macros.
76956         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Use gl_PATHMAX_SNIPPET_PREREQ
76957         and gl_PATHMAX_SNIPPET.
76958         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
76959         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
76960         * modules/chdir-long (Files): Add m4/pathmax.m4.
76961         * modules/getcwd (Files): Likewise.
76963 2011-09-21  Bruno Haible  <bruno@clisp.org>
76965         ftruncate: Un-deprecate, concentrate on Win32 support.
76966         * modules/ftruncate (Status, Notice): Remove sections.
76967         (Depends-on): Add largefile.
76968         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Drop failure message on
76969         non-mingw platforms.
76970         * lib/ftruncate.c: Remove code for the older platforms. For Win32,
76971         include <io.h>.
76972         * modules/perror-tests (Depends-on): Add ftruncate.
76973         * doc/posix-functions/ftruncate.texi: Mention the MSVC problem and the
76974         'ftruncate' module.
76976 2011-09-21  Bruno Haible  <bruno@clisp.org>
76978         Add dependencies to new dirent related modules.
76979         * modules/opendir (Depends-on): Add closedir.
76980         * modules/getcwd (Depends-on): Add opendir, closedir.
76981         * modules/dirent-safer-tests (Depends-on): Likewise.
76982         * modules/fdopendir-tests (Depends-on): Likewise.
76983         * modules/rename-tests (Depends-on): Add opendir, readdir, closedir.
76984         * modules/renameat-tests (Depends-on): Likewise.
76986 2011-09-21  Bruno Haible  <bruno@clisp.org>
76988         opendir: Avoid compilation error on mingw.
76989         * lib/opendir.c: Include <stddef.h> always. Include <unistd.h> as well.
76990         * modules/opendir (Depends-on): Add unistd.
76992 2011-09-21  Bruno Haible  <bruno@clisp.org>
76994         ftruncate tests: Avoid a test failure on mingw.
76995         * tests/test-ftruncate.c (main): Allow a failure with EACCES.
76997 2011-09-21  Bruno Haible  <bruno@clisp.org>
76999         select tests: Avoid test failures on OSF/1 5.1 and mingw.
77000         * tests/test-select.h (test_bad_fd): Disable all tests on OSF/1 and
77001         native Windows.
77003 2011-09-21  Bruno Haible  <bruno@clisp.org>
77005         New module 'fdopen'.
77006         * lib/stdio.in.h (fdopen): New declaration.
77007         * lib/fdopen.c: New file.
77008         * m4/fdopen.m4: New file.
77009         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FDOPEN,
77010         REPLACE_FDOPEN.
77011         * modules/stdio (Makefile.am): Substitute GNULIB_FDOPEN,
77012         REPLACE_FDOPEN.
77013         * modules/fdopen: New file.
77014         * modules/stdio-tests (Depends-on): Remove fdopen-tests.
77015         * tests/test-stdio-c++.cc: Check signature of fdopen.
77016         * doc/posix-functions/fdopen.texi: Mention the new module.
77018 2011-09-21  Bruno Haible  <bruno@clisp.org>
77020         unlockpt tests: Avoid test failure on NetBSD 5.1.
77021         * tests/test-unlockpt.c (main): Skip the EBADF tests on NetBSD.
77022         * doc/posix-functions/unlockpt.texi: Mention the bug on NetBSD.
77024 2011-09-21  Bruno Haible  <bruno@clisp.org>
77026         getlogin, getlogin_r tests: Avoid test failure on Linux/SPARC.
77027         * tests/test-getlogin.c (main): Allow a failure with EINVAL.
77028         * tests/test-getlogin_r.c (main): Likewise.
77030 2011-09-20  Bruno Haible  <bruno@clisp.org>
77032         time tests: Don't require pid_t.
77033         * doc/posix-headers/time.texi: Revert last change.
77034         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Revert last change.
77035         * tests/test-time.c: Comment out the check for pid_t.
77037 2011-09-20  Bruno Haible  <bruno@clisp.org>
77039         fsync tests: Avoid a test failure on mingw.
77040         * tests/test-fsync.c (main): Allow a failure with EIO.
77042 2011-09-20  Bruno Haible  <bruno@clisp.org>
77044         euidaccess: Update comments.
77045         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Update comments.
77047 2011-09-20  Bruno Haible  <bruno@clisp.org>
77049         Ensure EBADF returns for socket functions on mingw.
77050         * lib/accept.c (rpl_accept): Fail with error EBADF if the file
77051         descriptor is invalid.
77052         * lib/bind.c (rpl_bind): Likewise.
77053         * lib/connect.c (rpl_connect): Likewise.
77054         * lib/getpeername.c (rpl_getpeername): Likewise.
77055         * lib/getsockname.c (rpl_getsockname): Likewise.
77056         * lib/getsockopt.c (rpl_getsockopt): Likewise.
77057         * lib/listen.c (rpl_listen): Likewise.
77058         * lib/recv.c (rpl_recv): Likewise.
77059         * lib/recvfrom.c (rpl_recvfrom): Likewise.
77060         * lib/send.c (rpl_send): Likewise.
77061         * lib/sendto.c (rpl_sendto): Likewise.
77062         * lib/setsockopt.c (rpl_setsockopt): Likewise.
77063         * lib/shutdown.c (rpl_shutdown): Likewise.
77065 2011-09-20  Bruno Haible  <bruno@clisp.org>
77067         select tests: EBADF tests.
77068         * tests/test-select.h (do_select_bad_fd, do_select_bad_fd_nowait,
77069         test_bad_fd): New functions.
77070         (test_function): Invoke also test_bad_fd.
77072 2011-09-20  Bruno Haible  <bruno@clisp.org>
77074         Tests for module 'posix_spawn_file_actions_addopen.
77075         * modules/posix_spawn_file_actions_addopen-tests: New file.
77076         * tests/test-posix_spawn_file_actions_addopen.c: New file.
77078         Tests for module 'posix_spawn_file_actions_adddup2'.
77079         * modules/posix_spawn_file_actions_adddup2-tests: New file.
77080         * tests/test-posix_spawn_file_actions_adddup2.c: New file.
77082         Tests for module 'posix_spawn_file_actions_addclose'.
77083         * modules/posix_spawn_file_actions_addclose-tests: New file.
77084         * tests/test-posix_spawn_file_actions_addclose.c: New file.
77086 2011-09-20  Bruno Haible  <bruno@clisp.org>
77088         Tests for module 'unlockpt'.
77089         * modules/unlockpt-tests: New file.
77090         * tests/test-unlockpt.c: New file.
77091         * doc/posix-functions/unlockpt.texi: Mention the Cygwin 1.7 problem.
77093         Tests for module 'grantpt'.
77094         * modules/grantpt-tests: New file.
77095         * tests/test-grantpt.c: New file.
77096         * doc/posix-functions/grantpt.texi: Mention the Cygwin 1.7 problem.
77098 2011-09-20  Bruno Haible  <bruno@clisp.org>
77100         freopen tests: EBADF tests.
77101         * tests/test-freopen.c: Include errno.h, unistd.h.
77102         (main): Add tests for EBADF, commented out for the moment.
77104         fclose tests: EBADF tests.
77105         * tests/test-fclose.c (main): Add tests for EBADF.
77107         fflush tests: EBADF tests.
77108         * tests/test-fflush.c: Include errno.h, macros.h.
77109         (main): Add tests for EBADF.
77111         ftello tests: EBADF tests.
77112         * tests/test-ftello4.sh: New file.
77113         * tests/test-ftello4.c: New file.
77114         * modules/ftello-tests (Files): Add them.
77115         (Makefile.am): Arrange to compile test-ftello4 and run test-ftello4.sh.
77117         fseeko tests: EBADF tests.
77118         * tests/test-fseeko4.sh: New file.
77119         * tests/test-fseeko4.c: New file.
77120         * modules/fseeko-tests (Files): Add them.
77121         (Makefile.am): Arrange to compile test-fseeko4 and run test-fseeko4.sh.
77123         Tests for function fputc().
77124         * modules/fputc-tests: New file.
77125         * tests/test-fputc.c: New file.
77126         * modules/stdio-tests (Depends-on): Add fputc-tests.
77128         Tests for function fgetc().
77129         * modules/fgetc-tests: New file.
77130         * tests/test-fgetc.c: New file.
77131         * modules/stdio-tests (Depends-on): Add fgetc-tests.
77133         Tests for function fdopen().
77134         * modules/fdopen-tests: New file.
77135         * tests/test-fdopen.c: New file.
77136         * modules/stdio-tests (Depends-on): Add fdopen-tests.
77138         Tests for module 'vdprintf'.
77139         * modules/vdprintf-tests: New file.
77140         * tests/test-vdprintf.c: New file.
77142         Tests for module 'dprintf'.
77143         * modules/dprintf-tests: New file.
77144         * tests/test-dprintf.c: New file.
77146 2011-09-20  Bruno Haible  <bruno@clisp.org>
77148         Tests for module 'ioctl'.
77149         * modules/ioctl-tests: New file.
77150         * tests/test-ioctl.c: New file.
77152 2011-09-20  Bruno Haible  <bruno@clisp.org>
77154         fcntl tests: EBADF tests.
77155         * tests/test-fcntl.c (main): Add more tests for EBADF.
77157 2011-09-20  Bruno Haible  <bruno@clisp.org>
77159         utimensat tests: EBADF tests.
77160         * tests/test-utimensat.c (main): Add tests for EBADF.
77162         renameat tests: EBADF tests.
77163         * tests/test-renameat.c (main): Add tests for EBADF.
77165         mkfifoat tests: EBADF tests.
77166         * tests/test-mkfifoat.c (main): Add tests for EBADF.
77168         readlinkat tests: EBADF tests.
77169         * tests/test-readlinkat.c (main): Add tests for EBADF.
77171         symlinkat tests: EBADF tests.
77172         * tests/test-symlinkat.c (main): Add tests for EBADF.
77174         linkat tests: EBADF tests.
77175         * tests/test-linkat.c (main): Add tests for EBADF.
77177         Tests for module 'faccessat'.
77178         * modules/faccessat-tests: New file.
77179         * tests/test-faccessat.c: New file.
77181         fdopendir tests: EBADF tests.
77182         * tests/test-fdopendir.c (main): Add more tests for EBADF.
77184         openat tests: EBADF tests.
77185         * tests/test-fchownat.c (main): Add tests for EBADF.
77186         * tests/test-fstatat.c (main): Likewise.
77187         * tests/test-mkdirat.c (main): Likewise.
77188         * tests/test-openat.c (main): Likewise.
77189         * tests/test-unlinkat.c (main): Likewise.
77190         * tests/test-fchmodat.c: New file.
77191         * modules/openat-tests (Files): Add tests/test-fchmodat.c.
77192         (Makefile.am): Also run 'test-fchmodat'.
77194 2011-09-20  Bruno Haible  <bruno@clisp.org>
77196         utimens, futimens, fdutimensat tests: EBADF tests.
77197         * tests/test-futimens.h (test_futimens): Add more tests for EBADF.
77199         Tests for function fstat().
77200         * modules/fstat-tests: New file.
77201         * tests/test-fstat.c: New file.
77202         * modules/sys_stat-tests (Depends-on): Add fstat-tests.
77204 2011-09-20  Bruno Haible  <bruno@clisp.org>
77206         test-ttyname_r tests: EBADF tests.
77207         * tests/test-ttyname_r.c (main): Add tests for EBADF.
77209         Tests for module 'isatty'.
77210         * modules/isatty-tests: New file.
77211         * tests/test-isatty.c: New file.
77213         Tests for module 'write'.
77214         * modules/write-tests: New file.
77215         * tests/test-write.c: New file.
77217         Tests for module 'read'.
77218         * modules/read-tests: New file.
77219         * tests/test-read.c: New file.
77221         pwrite tests: EBADF tests.
77222         * tests/test-pwrite.c (main): Add tests for EBADF.
77224         pread tests: EBADF tests.
77225         * tests/test-pread.c (main): Add tests for EBADF.
77227         lseek tests: EBADF tests.
77228         * tests/test-lseek.c (main): Add more tests for EBADF.
77230         Tests for module 'ftruncate'.
77231         * modules/ftruncate-tests: New file.
77232         * tests/test-ftruncate.sh: New file.
77233         * tests/test-ftruncate.c: New file.
77235         fsync tests: EBADF tests.
77236         * tests/test-fsync.c (main): Add more tests for EBADF.
77238         fdatasync tests: EBADF tests.
77239         * tests/test-fdatasync.c (main): Add more tests for EBADF.
77241         Tests for module 'fchown'.
77242         * modules/fchown-tests: New file.
77243         * tests/test-fchown.c: New file.
77245         Tests for module 'fchmod'.
77246         * modules/fchmod-tests: New file.
77247         * tests/test-fchmod.c: New file.
77249         fchdir tests: EBADF tests.
77250         * tests/test-fchdir.c (main): Add more tests for EBADF.
77252         dup2 tests: EBADF tests.
77253         * tests/test-dup2.c (main): Add more tests for EBADF.
77255         Tests for module 'dup'.
77256         * modules/dup-tests: New file.
77257         * tests/test-dup.c: New file.
77259         Tests for module 'close'.
77260         * modules/close-tests: New file.
77261         * tests/test-close.c: New file.
77263 2011-09-20  Bruno Haible  <bruno@clisp.org>
77265         Tests for module 'shutdown'.
77266         * modules/shutdown-tests: New file.
77267         * tests/test-shutdown.c: New file.
77269         Tests for module 'setsockopt'.
77270         * modules/setsockopt-tests: New file.
77271         * tests/test-setsockopt.c: New file.
77273         Tests for module 'sendto'.
77274         * modules/sendto-tests: New file.
77275         * tests/test-sendto.c: New file.
77277         Tests for module 'send'.
77278         * modules/send-tests: New file.
77279         * tests/test-send.c: New file.
77281         Tests for module 'recvfrom'.
77282         * modules/recvfrom-tests: New file.
77283         * tests/test-recvfrom.c: New file.
77285         Tests for module 'recv'.
77286         * modules/recv-tests: New file.
77287         * tests/test-recv.c: New file.
77289         Tests for module 'listen'.
77290         * modules/listen-tests: New file.
77291         * tests/test-listen.c: New file.
77293         Tests for module 'getsockopt'.
77294         * modules/getsockopt-tests: New file.
77295         * tests/test-getsockopt.c: New file.
77297         Tests for module 'getsockname'.
77298         * modules/getsockname-tests: New file.
77299         * tests/test-getsockname.c: New file.
77301         Tests for module 'getpeername'.
77302         * modules/getpeername-tests: New file.
77303         * tests/test-getpeername.c: New file.
77305         Tests for module 'connect'.
77306         * modules/connect-tests: New file.
77307         * tests/test-connect.c: New file.
77309         Tests for module 'bind'.
77310         * modules/bind-tests: New file.
77311         * tests/test-bind.c: New file.
77313         accept4 tests: Fix for native Windows.
77314         * tests/test-accept4.c: Include sockets.h.
77315         (main): Invoke gl_sockets_startup.
77316         * modules/accept4-tests (Depends-on): Add sockets.
77318         accept tests: Fix for native Windows.
77319         * tests/test-accept.c: Include sockets.h.
77320         (main): Invoke gl_sockets_startup.
77321         * modules/accept-tests (Depends-on): Add sockets.
77323 2011-09-19  Bruno Haible  <bruno@clisp.org>
77325         msvc-inval: Require a semicolon after DONE_MSVC_INVAL.
77326         * lib/msvc-inval.h (TRY_MSVC_INVAL, DONE_MSVC_INVAL): Wrap in a
77327         do...while(0).
77328         * lib/dup2.c (rpl_dup2): Add a semicolon after DONE_MSVC_INVAL.
77329         Suggested by Paul Eggert.
77331 2011-09-19  Bruno Haible  <bruno@clisp.org>
77333         sched: Ensure pid_t is defined.
77334         * m4/sched_h.m4 (gl_SCHED_H): Arrange to override <sched.h> if it does
77335         not define pid_t.
77336         * lib/sched.in.h: Include <sys/types.h>.
77337         * doc/posix-headers/sched.texi: Mention the pid_t problem.
77338         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
77340 2011-09-19  Bruno Haible  <bruno@clisp.org>
77342         msvc-inval: Ensure the entire expansion is a single statement.
77343         * lib/msvc-inval.h (TRY_MSVC_INVAL, DONE_MSVC_INVAL): Add an extra pair
77344         of braces.
77346 2011-09-19  Jim Meyering  <meyering@redhat.com>
77348         tests: use printf, not echo in init.sh's warn_ function
77349         * tests/init.sh (warn_): Use printf, not echo.  The latter would
77350         misbehave when given strings containing a backslash or starting
77351         with e.g., -n.  James Youngman suggested setting IFS.
77353 2011-09-19  Eric Blake  <eblake@redhat.com>
77355         futimens: enhance test
77356         * tests/test-futimens.h (test_futimens): Also check for EBADF on
77357         closed non-negative fd.
77359         date: accept 'hence' as opposite of 'ago'
77360         * lib/parse-datetime.y (relative_time_table): Add 'hence'.
77361         * tests/test-parse-datetime.c (main): Enhance test.
77362         Suggested by Jesse Wilson.
77364 2011-09-19  Jim Meyering  <meyering@redhat.com>
77366         getcwd: don't fail in a deep directory on a system without openat
77367         Before this change, getcwd would fail when called from a directory
77368         of depth PATH_MAX / 3 or greater.  That was due to the fact that
77369         the non-openat implementation used "..", "../..", "../../..", etc.
77370         to access ancestor directories.  With too many, that string would
77371         be longer than PATH_MAX.
77372         * lib/getcwd.c (HAVE_OPENAT_SUPPORT): Define also when we are
77373         using gnulib's openat replacement.
77374         * m4/openat.m4: Set GNULIB_OPENAT, so getcwd.c knows when
77375         we're using the replacement function.
77377 2011-09-14  Martin von Gagern  <Martin.vGagern@gmx.net>
77379         maint.mk: avoid warnings from perl about missing files
77380         * top/maint.mk (def_sym_regex): Ignore files listed in
77381         $(gl_other_headers_) that do not exist, say because a project
77382         does not use a corresponding module.
77384 2011-09-18  Paul Eggert  <eggert@cs.ucla.edu>
77386         stat: use pathmax.h only if needed
77387         * lib/stat.c: Include pathmax.h only if REPLACE_FUNC_STAT_DIR.
77388         This is better for Emacs, which does not have a mingw port and
77389         therefore can avoid the pathmax module.
77391         utimens: remove dependency on dup2
77392         * lib/utimens.c (fdutimens): Don't invoke dup2; it's not needed
77393         to work around the Linux kernel bug.
77394         * modules/utimens (Depends-on): Remove dup2.
77396 2011-09-18  Bruno Haible  <bruno@clisp.org>
77398         inet_ntop, inet_pton: Look for it also in libresolv.
77399         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): If the function was not found in
77400         libnsl, search for it in libresolv.
77401         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
77402         Needed on Solaris 7.
77404 2011-09-18  Bruno Haible  <bruno@clisp.org>
77406         accept, accept4 tests: Avoid link error on Solaris.
77407         * modules/accept-tests (Makefile.am): Link test-accept against
77408         $(LIBSOCKET).
77409         * modules/accept4-tests (Makefile.am): Link test-accept4 against
77410         $(LIBSOCKET).
77412         accept4: Avoid link error on Solaris.
77413         * modules/accept4 (Link): New section.
77415         socket functions: Avoid link errors on Solaris.
77416         * modules/accept (Depends-on): Add socketlib.
77417         (Link): New section.
77418         * modules/bind (Depends-on): Add socketlib.
77419         (Link): New section.
77420         * modules/connect (Depends-on): Add socketlib.
77421         (Link): New section.
77422         * modules/getpeername (Depends-on): Add socketlib.
77423         (Link): New section.
77424         * modules/getsockname (Depends-on): Add socketlib.
77425         (Link): New section.
77426         * modules/getsockopt (Depends-on): Add socketlib.
77427         (Link): New section.
77428         * modules/listen (Depends-on): Add socketlib.
77429         (Link): New section.
77430         * modules/recv (Depends-on): Add socketlib.
77431         (Link): New section.
77432         * modules/recvfrom (Depends-on): Add socketlib.
77433         (Link): New section.
77434         * modules/send (Depends-on): Add socketlib.
77435         (Link): New section.
77436         * modules/sendto (Depends-on): Add socketlib.
77437         (Link): New section.
77438         * modules/setsockopt (Depends-on): Add socketlib.
77439         (Link): New section.
77440         * modules/shutdown (Depends-on): Add socketlib.
77441         (Link): New section.
77442         * modules/socket (Depends-on): Add socketlib.
77443         (Link): New section.
77445 2011-09-18  Bruno Haible  <bruno@clisp.org>
77447         ptsname tests: Let the test fail rather than hang (e.g. on AIX 5.1).
77448         * tests/test-ptsname.c (main): Terminate the test if it takes longer
77449         than 5 seconds.
77450         * modules/ptsname-tests (configure.ac): Test for alarm.
77452 2011-09-18  Bruno Haible  <bruno@clisp.org>
77454         posix_spawn_file_actions_add*: Fix module dependencies.
77455         * modules/posix_spawn_file_actions_addclose (Dependencies): Add
77456         posix_spawn_file_actions_init.
77457         * modules/posix_spawn_file_actions_adddup2 (Dependencies): Likewise.
77458         * modules/posix_spawn_file_actions_addopen (Dependencies): Likewise.
77460 2011-09-18  Bruno Haible  <bruno@clisp.org>
77462         rename, renameat tests: Avoid test failures on FreeBSD 6.4.
77463         * tests/test-rename.h (test_rename): Allow error code EEXIST.
77464         * tests/test-renameat.c (main): Likewise.
77466 2011-09-18  Bruno Haible  <bruno@clisp.org>
77468         Tests for module 'accept4'.
77469         * modules/accept4-tests: New file.
77470         * tests/test-accept4.c: New file.
77472 2011-09-18  Bruno Haible  <bruno@clisp.org>
77474         Tests for module 'accept'.
77475         * modules/accept-tests: New file.
77476         * tests/test-accept.c: New file.
77478 2011-09-18  Bruno Haible  <bruno@clisp.org>
77480         dup2: Support for MSVC.
77481         * lib/dup2.c: Include msvc-inval.h.
77482         (rpl_dup2): Handle invalid parameter notifications during dup2 and
77483         _get_osfhandle calls.
77484         * modules/dup2 (Depends-on): Add msvc-inval.
77485         * doc/posix-functions/dup2.texi: Mention problem on MSVC.
77487         New module 'msvc-inval'.
77488         * lib/msvc-inval.h: New file.
77489         * lib/msvc-inval.c: New file.
77490         * m4/msvc-inval.m4: New file.
77491         * modules/msvc-inval: New file.
77493 2011-09-17  Bruno Haible  <bruno@clisp.org>
77495         Tests for module 'pclose'.
77496         * modules/pclose-tests: New file.
77498         New module 'pclose'.
77499         * lib/stdio.in.h (pclose): New declaration.
77500         * lib/pclose.c: New file.
77501         * m4/pclose.m4: New file.
77502         * m4/stdio_h.m4 (gl_STDIO_H): Test whether pclose is declared.
77503         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_PCLOSE, HAVE_PCLOSE.
77504         * modules/stdio (Makefile.am): Substitute GNULIB_PCLOSE, HAVE_PCLOSE.
77505         * modules/pclose: New file.
77506         * modules/popen-tests (Depends-on): Add pclose.
77507         * modules/popen-safer-tests (Depends-on): Likewise.
77508         * doc/posix-functions/pclose.texi: Mention the new module.
77510 2011-09-17  Bruno Haible  <bruno@clisp.org>
77512         popen: Support for MSVC.
77513         * lib/stdio.in.h (popen): Declare it if the system lacks this function.
77514         * lib/popen.c (popen): Provide alternate definition for native Windows.
77515         * m4/popen.m4 (gl_FUNC_POPEN): Test if popen exists. Set HAVE_POPEN.
77516         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_POPEN.
77517         * modules/popen (Depends-on, configure.ac): Update condition.
77518         * modules/stdio (Makefile.am): Substitute HAVE_POPEN.
77519         * doc/posix-functions/popen.texi: Mention that the MSVC problem is
77520         fixed.
77522 2011-09-17  Bruno Haible  <bruno@clisp.org>
77524         isnanl, isnand, isnanf: Work around MSVC bug.
77525         * lib/isnan.c (FUNC): Use alternate ways of computing NaN and Infinity.
77527 2011-09-17  Bruno Haible  <bruno@clisp.org>
77529         sys_socket tests: Fix recent mistake.
77530         * tests/test-sys_socket.c (t1): Avoid collision of identifiers.
77532 2011-09-17  Bruno Haible  <bruno@clisp.org>
77534         putenv: Support for MSVC.
77535         * modules/putenv (Depends-on): Add environ.
77536         * lib/putenv.c (environ): Disable declaration.
77537         * lib/unistd.in.h: Update comment.
77539 2011-09-17  Bruno Haible  <bruno@clisp.org>
77541         math: Avoid macro redefinition warnings on MSVC.
77542         * lib/math.in.h (ceilf, ceill, floorf, floorl, frexpl, ldexpl):
77543         Undefine before redefining.
77545 2011-09-17  Bruno Haible  <bruno@clisp.org>
77547         doc: Mention functions which are declared as macros.
77548         * doc/posix-functions/*[fl].texi: Mention that some functions are
77549         defined as macros with arguments only.
77551 2011-09-17  Bruno Haible  <bruno@clisp.org>
77553         Add dependencies to new dirent related modules.
77554         * modules/backupfile (Depends-on): Add opendir, readdir, closedir.
77555         * modules/fts (Depends-on): Likewise.
77556         * modules/glob (Depends-on): Likewise.
77557         * modules/savedir (Depends-on): Likewise.
77558         * modules/scandir (Depends-on): Likewise.
77559         * modules/dirent-safer (Depends-on): Add opendir, closedir.
77560         * modules/fdopendir (Depends-on): Add opendir.
77562 2011-09-17  Bruno Haible  <bruno@clisp.org>
77564         inet_pton: Support for MSVC on Windows Vista or newer.
77565         * lib/arpa_inet.in.h (inet_pton): Also consider REPLACE_INET_PTON.
77566         * lib/inet_pton.c (rpl_inet_pton): Use a simple wrapper if
77567         HAVE_DECL_INET_PTON is defined.
77568         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Invoke gl_PREREQ_SYS_H_WINSOCK2.
77569         On platforms with <winsock2.h>, test whether inet_pton is declared in
77570         <ws2tcpip.h>. If so, arrange to replace it.
77571         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Initialize
77572         REPLACE_INET_PTON.
77573         * modules/arpa_inet (Makefile.am): Substitute REPLACE_INET_PTON.
77574         * modules/inet_pton (Files): Add m4/sys_socket_h.m4.
77575         (Depends-on, configure.ac): Update condition.
77576         * doc/posix-functions/inet_pton.texi: Mention the MSVC problem.
77578 2011-09-17  Bruno Haible  <bruno@clisp.org>
77580         inet_ntop: Support for MSVC on Windows Vista or newer.
77581         * lib/arpa_inet.in.h (inet_ntop): Also consider REPLACE_INET_NTOP.
77582         * lib/inet_ntop.c (rpl_inet_ntop): Use a simple wrapper if
77583         HAVE_DECL_INET_NTOP is defined.
77584         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Invoke gl_PREREQ_SYS_H_WINSOCK2.
77585         On platforms with <winsock2.h>, test whether inet_ntop is declared in
77586         <ws2tcpip.h>. If so, arrange to replace it.
77587         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Initialize
77588         REPLACE_INET_NTOP.
77589         * modules/arpa_inet (Makefile.am): Substitute REPLACE_INET_NTOP.
77590         * modules/inet_ntop (Files): Add m4/sys_socket_h.m4.
77591         (Depends-on, configure.ac): Update condition.
77592         * doc/posix-functions/inet_ntop.texi: Mention the MSVC problem.
77594 2011-09-16  Eric Blake  <eblake@redhat.com>
77596         test-fsync: yet another enhancement
77597         * tests/test-fsync.c (main): Also test behavior on read-only text
77598         file.
77600 2011-09-16  Bruno Haible  <bruno@clisp.org>
77602         Enhance fsync, fdatasync tests.
77603         * tests/test-fsync.c (main): Test both STDIN_FILENO and STDOUT_FILENO.
77604         * tests/test-fdatasync.c (main): Likewise.
77606 2011-09-16  Bruno Haible  <bruno@clisp.org>
77608         Support for MSVC compiler: Ensure mode_t gets defined.
77609         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_TYPE_MODE_T.
77610         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
77611         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
77612         * m4/sys_types_h.m4 (gl_SYS_TYPES_H): Likewise.
77613         * tests/test-fcntl-h.c: Check that mode_t is defined.
77614         * tests/test-sys_stat.c: Likewise.
77615         * tests/test-sys_types.c: Likewise.
77616         * doc/posix-headers/fcntl.texi: Mention the missing mode_t problem.
77617         * doc/posix-headers/sys_stat.texi: Likewise.
77618         * doc/posix-headers/sys_types.texi: Likewise.
77620 2011-09-16  Bruno Haible  <bruno@clisp.org>
77622         sys_stat: Support for MSVC.
77623         * lib/sys_stat.in.h (S_IFIFO): Define to _S_IFIFO if that exists.
77624         * tests/test-sys_stat.c: Don't assume that S_IFBLK exists.
77625         * doc/posix-headers/sys_stat.texi: Mention missing S_IFIFO, S_IFBLK on
77626         MSVC.
77628 2011-09-16  Bruno Haible  <bruno@clisp.org>
77630         Support for MSVC compiler: Ensure off_t gets defined.
77631         * lib/unistd.in.h: Include <sys/types.h>.
77632         * tests/test-fcntl-h.c: Check that off_t is defined.
77633         * tests/test-sys_stat.c: Likewise.
77634         * tests/test-sys_types.c: Likewise.
77636 2011-09-16  Eric Blake  <eblake@redhat.com>
77638         fdatasync: port to Solaris
77639         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Set LIB_FDATASYNC.
77640         * modules/fdatasync (Link): Document it.
77641         * modules/fdatasync-tests (test_fdatasync_LDADD): Link with it.
77643         fdatasync: port to MacOS X 10.7
77644         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): Check for present but not
77645         declared.
77646         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Another default.
77647         * modules/unistd (Makefile.am): Substitute it.
77648         * lib/unistd.in.h (fdatasync): Declare on MacOS.
77649         * doc/posix-functions/fdatasync.texi (fdatasync): Document it.
77651         fdatasync: minor improvements
77652         * modules/fdatasync (Depends-on): Add condition for fsync.
77653         * lib/fdatasync.c (fdatasync): Add comment.
77654         * tests/test-unistd-c++.cc: Test fdatasync.
77656         unistd: update refs to newer POSIX
77657         * lib/unistd.in.h: Prefer POSIX 2008 over 2001.
77658         Suggested by Bruno Haible.
77660         fdatasync: new module
77661         * modules/fsync (Description): Document difference to fdatasync.
77662         * modules/fdatasync: New module.
77663         * m4/fdatasync.m4 (gl_FUNC_FDATASYNC): New file.
77664         * lib/fdatasync.c (fdatasync): Likewise.
77665         * m4/unistd_h.m4 (gl_UNISTD_H, gl_UNISTD_H_DEFAULTS): Set up
77666         defaults.
77667         * modules/unistd (Makefile.am): Set witnesses.
77668         * lib/unistd.in.h (fdatasync): Declare.
77669         * MODULES.html.sh: Document it.
77670         * doc/posix-functions/fdatasync.texi (fdatasync): Likewise.
77671         * modules/fdatasync-tests: New test.
77672         * tests/test-fdatasync.c: Likewise.
77674 2011-09-16  Eric Blake  <eblake@redhat.com>
77676         test-fsync: enhance tests
77677         * modules/fsync-tests (Depends-on): Add errno, for mingw.
77678         * tests/test-fsync.c (main): Enhance test.
77680 2011-09-15  Bruno Haible  <bruno@clisp.org>
77682         Support for MSVC compiler: Ensure ssize_t gets defined.
77683         * doc/posix-headers/sys_types.texi: Mention the missing ssize_t problem.
77684         * doc/posix-headers/stdio.texi: Likewise.
77685         * modules/stdio (Depends-on): Add ssize_t.
77686         * modules/sys_socket (Depends-on): Likewise.
77687         * modules/sys_types (Depends-on): Likewise.
77688         * modules/sys_uio (Depends-on): Likewise.
77689         * modules/unistd (Depends-on): Likewise.
77690         * tests/test-sys_socket.c: Check that size_t and ssize_t are defined.
77691         * tests/test-sys_types.c: Check that ssize_t is defined.
77693 2011-09-14  Bruno Haible  <bruno@clisp.org>
77695         Avoid using #, the m4 comment starter character, near brackets.
77696         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): Use |, not #, as
77697         delimiter character in sed expressions.
77698         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Likewise.
77699         Suggested by Eric Blake.
77701         Properly quote AC_CHECK_DECLS' 4th argument.
77702         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Double-quote AC_CHECK_DECLS' 4th
77703         argument.
77704         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
77705         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
77706         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
77707         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
77708         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
77709         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): Likewise.
77710         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Likewise.
77711         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Likewise.
77712         * m4/gethrxtime.m4 (gl_GETHRXTIME): Likewise.
77713         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
77714         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Likewise.
77715         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Likewise.
77716         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
77717         * m4/isinf.m4 (gl_ISINF): Likewise.
77718         * m4/logb.m4 (gl_FUNC_LOGB): Likewise.
77719         * m4/readutmp.m4 (gl_READUTMP): Likewise.
77720         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
77721         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
77722         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
77723         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
77724         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
77725         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
77726         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Likewise.
77727         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
77728         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
77729         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
77730         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Likewise.
77731         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
77732         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
77733         Reported by Eric Blake.
77735         Properly quote AC_CHECK_DECL's 4th argument.
77736         * m4/acosl.m4 (gl_FUNC_ACOSL): Double-quote AC_CHECK_DECL's 4th
77737         argument.
77738         * m4/argp.m4 (gl_ARGP): Likewise.
77739         * m4/asinl.m4 (gl_FUNC_ASINL): Likewise.
77740         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
77741         * m4/cosl.m4 (gl_FUNC_COSL): Likewise.
77742         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
77743         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): Likewise.
77744         * m4/getloadavg.m4 (gl_GETLOADAVG): Likewise.
77745         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Likewise.
77746         * m4/logl.m4 (gl_FUNC_LOGL): Likewise.
77747         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
77748         * m4/sinl.m4 (gl_FUNC_SINL): Likewise.
77749         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Likewise.
77750         * m4/tanl.m4 (gl_FUNC_TANL): Likewise.
77751         Reported by Eric Blake.
77753 2011-09-14  Eric Blake  <eblake@redhat.com>
77755         opendir: avoid compile warning
77756         * lib/opendir.c (includes): Always include errno.h.
77757         Reported by Tatsuro MATSUOKA.
77759 2011-09-14  Jim Meyering  <meyering@redhat.com>
77761         maint.mk: sc_tight_scope: propagate failure from sub-make
77762         * top/maint.mk (sc_tight_scope): Actually initialize and use $fail.
77763         Reported by Martin von Gagern.
77765 2011-09-13  Bruno Haible  <bruno@clisp.org>
77767         tempname: Support for MSVC.
77768         * doc/posix-headers/fcntl.texi: Document the problem with O_ACCMODE on
77769         MSVC.
77770         * modules/tempname (Depends-on): Add fcntl-h.
77772 2011-09-13  Bruno Haible  <bruno@clisp.org>
77774         sys_time: Support for MSVC.
77775         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Invoke
77776         gl_PREREQ_SYS_H_WINSOCK2. When testing for 'struct timeval', also
77777         include <winsock2.h>.
77778         * lib/sys_time.in.h: On MSVC, include <winsock2.h> and hide its
77779         function declarations that collide with POSIX.
77780         * modules/sys_time (Files): Add m4/sys_socket_h.m4.
77781         (Makefile.am): Substitute HAVE_WINSOCK2_H.
77783 2011-09-13  Bruno Haible  <bruno@clisp.org>
77785         stat: Support for MSVC.
77786         * lib/stat.c: Include pathmax.h.
77787         * modules/stat (Depends-on): Add pathmax.
77789         pathmax: Support for native Windows.
77790         * lib/pathmax.h (PATH_MAX): Define to 260 on native Windows.
77792 2011-09-12  Bruno Haible  <bruno@clisp.org>
77794         New modules 'opendir', 'readdir', 'rewinddir', 'closedir'.
77795         * lib/dirent.in.h (struct dirent): New type.
77796         (DT_UNKNOWN, DT_FIFO, DT_CHR, DT_DIR, DT_BLK, DT_REG, DT_LNK, DT_SOCK,
77797         DT_WHT): New macros.
77798         (DIR): New type.
77799         (opendir, closedir): Declare only if the module 'opendir' is enabled.
77800         (readdir, rewinddir): New declarations.
77801         * lib/dirent-private.h: New file.
77802         * lib/opendir.c: New file.
77803         * lib/readdir.c: New file.
77804         * lib/rewinddir.c: New file.
77805         * lib/closedir.c: New file.
77806         * lib/fchdir.c (rpl_closedir, rpl_opendir): Remove functions.
77807         * m4/opendir.m4: New file.
77808         * m4/readdir.m4: New file.
77809         * m4/rewinddir.m4: New file.
77810         * m4/closedir.m4: New file.
77811         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't set REPLACE_OPENDIR,
77812         REPLACE_CLOSEDIR here.
77813         * m4/dirent_h.m4 (gl_DIRENT_H): Also check whether closedir, opendir,
77814         readdir, rewinddir are declared.
77815         (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_OPENDIR, GNULIB_READDIR,
77816         GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR, HAVE_READDIR,
77817         HAVE_REWINDDIR, HAVE_CLOSEDIR.
77818         * modules/dirent (Makefile.am): Substitute GNULIB_OPENDIR,
77819         GNULIB_READDIR, GNULIB_REWINDDIR, GNULIB_CLOSEDIR, HAVE_OPENDIR,
77820         HAVE_READDIR, HAVE_REWINDDIR, HAVE_CLOSEDIR.
77821         * modules/opendir: New file.
77822         * modules/readdir: New file.
77823         * modules/rewinddir: New file.
77824         * modules/closedir: New file.
77825         * doc/posix-functions/opendir.texi: Mention the 'opendir' module.
77826         * doc/posix-functions/readdir.texi: Mention the 'readdir' module.
77827         * doc/posix-functions/rewinddir.texi: Mention the 'rewinddir' module.
77828         * doc/posix-functions/closedir.texi: Mention the 'closedir' module.
77829         * NEWS: Mention the 'fchdir' change.
77831 2011-09-11  Bruno Haible  <bruno@clisp.org>
77833         asm-underscore.m4: Support for MSVC.
77834         * m4/asm-underscore.m4 (gl_C_ASM): New macro.
77835         (gl_ASM_SYMBOL_PREFIX): Require it. Use its results.
77837 2011-09-11  Reuben Thomas  <rrt@sc3d.org>
77839         Doc about crypt functions.
77840         * doc/posix-functions/crypt.texi: Expand range of glibc versions
77841         needing for _GNU_SOURCE to get crypt.
77842         * doc/posix-functions/encrypt.texi: Likewise.
77843         * doc/posix-functions/setkey.texi: Likewise.
77845 2011-09-11  Bruno Haible  <bruno@clisp.org>
77847         doc: Update regarding MSVC 9.
77848         * doc/gnulib-intro.texi (Target Platforms): Classify MSVC as "rarely
77849         tested".
77850         * doc/posix-functions/*.texi: Update with info about MSVC 9.
77851         * doc/posix-headers/*.texi: Likewise.
77852         * doc/pastposix-functions/*.texi: Likewise.
77853         * doc/glibc-functions/*.texi: Likewise.
77854         * doc/glibc-headers/*.texi: Likewise.
77856 2011-09-11  Bruno Haible  <bruno@clisp.org>
77858         unistd et al.: Don't assume <unistd.h> exists.
77859         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Don't include <unistd.h> if it
77860         does not exist.
77861         * m4/environ.m4 (gl_ENVIRON): Don't include <unistd.h> if it does not
77862         exist. But include <stdlib.h>.
77863         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): If <unistd.h> does not exist,
77864         include <io.h> and <stdlib.h> instead. Don't test symbolink links if
77865         symlink() does not exist.
77866         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): If <unistd.h> does not exist,
77867         include <io.h> instead.
77868         * m4/free.m4 (gl_FUNC_FREE): Assume free(NULL) works on native Windows.
77869         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): If <unistd.h> does not exist,
77870         include <direct.h> instead.
77871         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): Likewise.
77872         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
77873         * m4/lseek.m4 (gl_FUNC_LSEEK): If <unistd.h> does not exist, include
77874         <io.h> instead.
77875         * m4/rename.m4 (gl_FUNC_RENAME): Assume rename() manages hard links
77876         correctly if the system does not have hard links.
77877         * m4/rmdir.m4 (gl_FUNC_RMDIR): If <unistd.h> does not exist, include
77878         <direct.h> instead.
77879         * m4/unistd_h.m4 (gl_UNISTD_H): If <unistd.h> does not exist, bypass
77880         it when looking for function declarations.
77881         * m4/unlink.m4 (gl_FUNC_UNLINK): If <unistd.h> does not exist, include
77882         <direct.h> and <io.h> instead.
77883         * doc/posix-headers/unistd.texi: More details about MSVC problem.
77885 2011-09-11  Bruno Haible  <bruno@clisp.org>
77887         strcase: Support for MSVC.
77888         * modules/strcase (Status, Notice): Remove obsoletion mark.
77889         * doc/posix-functions/strcasecmp.texi: Mention MSVC problem.
77890         * doc/posix-functions/strncasecmp.texi: Likewise.
77892         strings: Don't assume <strings.h> exists.
77893         * lib/strings.in.h: Include <strings.h> only if HAVE_STRINGS_H is 1.
77894         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Set HAVE_STRINGS_H.
77895         * modules/strings (Makefile.am): Substitute HAVE_STRINGS_H.
77896         * doc/posix-headers/strings.texi: Mention the MSVC problem.
77898 2011-09-11  Bruno Haible  <bruno@clisp.org>
77900         dirent: Don't assume <dirent.h> exists.
77901         * lib/dirent.in.h: Include <dirent.h> only if HAVE_DIRENT_H is 1.
77902         * m4/dirent_h.m4 (gl_DIRENT_H): Set HAVE_DIRENT_H.
77903         * modules/dirent (Makefile.am): Substitute HAVE_DIRENT_H.
77904         * doc/posix-headers/dirent.texi: Mention the MSVC problem.
77906 2011-09-11  Bruno Haible  <bruno@clisp.org>
77908         Fix wint_t on MSVC.
77909         * lib/wchar.in.h (wint_t): On MSVC, override it.
77910         * lib/wctype.in.h (wint_t): Likewise.
77911         * m4/stdint.m4 (gl_STDINT_TYPE_PROPERTIES): Override BITSIZEOF_WINT_T on
77912         MSVC.
77913         * doc/posix-headers/wchar.texi: Mention the problem with wint_t on MSVC.
77914         * doc/posix-headers/wctype.texi: Likewise.
77916 2011-09-11  Bruno Haible  <bruno@clisp.org>
77918         sys_types: Fix typo.
77919         * lib/sys_types.in.h: Fix typo in comment.
77920         Reported by Paul Eggert.
77922         Support for MSVC compiler: Ensure size_t gets defined.
77923         * modules/strings (Depends-on): Add 'sys_types'.
77924         * modules/sys_uio (Depends-on): Likewise.
77925         * lib/sys_uio.in.h: Update comment.
77927         C++ tests for module 'sys_types'.
77928         * modules/sys_types-c++-tests: New file.
77929         * tests/test-sys_types-c++.cc: New file.
77931         Tests for module 'sys_types'.
77932         * modules/sys_types-tests: New file.
77933         * tests/test-sys_types.c: New file.
77935         New module 'sys_types'.
77936         * lib/sys_types.in.h: New file.
77937         * m4/sys_types_h.m4: New file.
77938         * modules/sys_types: New file.
77939         * doc/posix-headers/sys_types.texi: Mention the new module and the
77940         size_t problem on MSVC 9.
77942 2011-09-11  Bruno Haible  <bruno@clisp.org>
77944         Support for MSVC compiler: Avoid division by a literal 0.
77945         * lib/math.in.h (NAN): Define through a function call also on MSVC.
77946         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Divide by 'zero' instead of 0.0.
77947         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_DIRECTIVE_A,
77948         gl_PRINTF_DIRECTIVE_F, gl_PRINTF_FLAG_ZERO): Likewise.
77949         (gl_PRINTF_INFINITE_LONG_DOUBLE): Divide by 'zeroL' instead of 0.0L.
77950         * tests/infinity.h: New file.
77951         * tests/nan.h (NaNf, NaNd, NaNl): Define through a function call also
77952         on MSVC.
77953         * tests/test-ceilf1.c: Include infinity.h.
77954         (main): Use Infinityf.
77955         * tests/test-ceil1.c: Include infinity.h.
77956         (main): Use Infinityd.
77957         * tests/test-ceill.c: Include infinity.h.
77958         (main): Use Infinityl.
77959         * tests/test-dprintf-posix.c: Include infinity.h.
77960         (test_function): Use Infinityd.
77961         * tests/test-floorf1.c: Include infinity.h.
77962         (main): Use Infinityf.
77963         * tests/test-floor1.c: Include infinity.h.
77964         (main): Use Infinityd.
77965         * tests/test-floorl.c: Include infinity.h.
77966         (main): Use Infinityl.
77967         * tests/test-fprintf-posix.c: Include infinity.h.
77968         (test_function): Use Infinityd.
77969         * tests/test-frexp.c: Include infinity.h.
77970         (main): Use Infinityd.
77971         * tests/test-frexpl.c: Include infinity.h.
77972         (main): Use Infinityl.
77973         * tests/test-isfinite.c: Include infinity.h.
77974         (test_isfinitef): Use Infinityf.
77975         (test_isfinited): Use Infinityd.
77976         (test_isfinitel): Use Infinityl.
77977         * tests/test-isinf.c: Include infinity.h.
77978         (test_isinff): Use Infinityf.
77979         (test_isinfd): Use Infinityd.
77980         (test_isinfl): Use Infinityl.
77981         * tests/test-isnan.c: Include infinity.h.
77982         (test_float): Use Infinityf.
77983         (test_double): Use Infinityd.
77984         (test_long_double): Use Infinityl.
77985         * tests/test-isnanf.h: Include infinity.h.
77986         (main): Use Infinityf.
77987         * tests/test-isnand.h: Include infinity.h.
77988         (main): Use Infinityd.
77989         * tests/test-isnanl.h: Include infinity.h.
77990         (main): Use Infinityl.
77991         * tests/test-ldexpl.c: Include infinity.h.
77992         (main): Use Infinityl.
77993         * tests/test-printf-posix.h: Include infinity.h.
77994         (test_function): Use Infinityd.
77995         * tests/test-roundf1.c: Include infinity.h.
77996         (main): Use Infinityf.
77997         * tests/test-round1.c: Include infinity.h.
77998         (main): Use Infinityd.
77999         * tests/test-roundl.c: Include infinity.h.
78000         (main): Use Infinityl.
78001         * tests/test-signbit.c: Include infinity.h.
78002         (test_signbitf): Use Infinityf.
78003         (test_signbitd): Use Infinityd.
78004         (test_signbitl): Use Infinityl.
78005         * tests/test-snprintf-posix.h: Include infinity.h.
78006         (test_function): Use Infinityd, Infinityl.
78007         * tests/test-sprintf-posix.h: Include infinity.h.
78008         (test_function): Use Infinityd, Infinityl.
78009         * tests/test-truncf1.c: Include infinity.h.
78010         (main): Use Infinityf.
78011         * tests/test-trunc1.c: Include infinity.h.
78012         (main): Use Infinityd.
78013         * tests/test-truncl.c: Include infinity.h.
78014         (main): Use Infinityl.
78015         * tests/test-vasnprintf-posix.c: Include infinity.h.
78016         (test_function): Use Infinityd, Infinityl.
78017         * tests/test-vasprintf-posix.c: Include infinity.h.
78018         (test_function): Use Infinityd, Infinityl.
78019         * modules/ceilf-tests (Files): Add tests/infinity.h.
78020         * modules/ceil-tests (Files): Likewise.
78021         * modules/ceill-tests (Files): Likewise.
78022         * modules/dprintf-posix-tests (Files): Likewise.
78023         * modules/floorf-tests (Files): Likewise.
78024         * modules/floor-tests (Files): Likewise.
78025         * modules/floorl-tests (Files): Likewise.
78026         * modules/fprintf-posix-tests (Files): Likewise.
78027         * modules/frexp-tests (Files): Likewise.
78028         * modules/frexp-nolibm-tests (Files): Likewise.
78029         * modules/frexpl-tests (Files): Likewise.
78030         * modules/frexpl-nolibm-tests (Files): Likewise.
78031         * modules/isfinite-tests (Files): Likewise.
78032         * modules/isinf-tests (Files): Likewise.
78033         * modules/isnan-tests (Files): Likewise.
78034         * modules/isnanf-tests (Files): Likewise.
78035         * modules/isnanf-nolibm-tests (Files): Likewise.
78036         * modules/isnand-tests (Files): Likewise.
78037         * modules/isnand-nolibm-tests (Files): Likewise.
78038         * modules/isnanl-tests (Files): Likewise.
78039         * modules/isnanl-nolibm-tests (Files): Likewise.
78040         * modules/ldexpl-tests (Files): Likewise.
78041         * modules/printf-posix-tests (Files): Likewise.
78042         * modules/roundf-tests (Files): Likewise.
78043         * modules/round-tests (Files): Likewise.
78044         * modules/roundl-tests (Files): Likewise.
78045         * modules/signbit-tests (Files): Likewise.
78046         * modules/snprintf-posix-tests (Files): Likewise.
78047         * modules/sprintf-posix-tests (Files): Likewise.
78048         * modules/truncf-tests (Files): Likewise.
78049         * modules/trunc-tests (Files): Likewise.
78050         * modules/truncl-tests (Files): Likewise.
78051         * modules/vasnprintf-posix-tests (Files): Likewise.
78052         * modules/vasprintf-posix-tests (Files): Likewise.
78053         * modules/vdprintf-posix-tests (Files): Likewise.
78054         * modules/vfprintf-posix-tests (Files): Likewise.
78055         * modules/vprintf-posix-tests (Files): Likewise.
78056         * modules/vsnprintf-posix-tests (Files): Likewise.
78057         * modules/vsprintf-posix-tests (Files): Likewise.
78058         * modules/xprintf-posix-tests (Files): Likewise.
78060 2011-09-11  Bruno Haible  <bruno@clisp.org>
78062         Ensure pid_t gets defined.
78063         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_TYPE_PID_T.
78064         * m4/sched_h.m4 (gl_SCHED_H): Likewise.
78065         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
78066         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
78067         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H): Likewise.
78068         * m4/termios_h.m4 (gl_TERMIOS_H): Likewise.
78069         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
78070         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
78071         * tests/test-fcntl-h.c: Check that pid_t is defined.
78072         * tests/test-sched.c: Likewise.
78073         * tests/test-termios.c: Likewise.
78074         * tests/test-time.c: Likewise.
78075         * doc/posix-headers/fcntl.texi: Mention lack of pid_t on MSVC platform.
78076         * doc/posix-headers/signal.texi: Likewise.
78077         * doc/posix-headers/sys_types.texi: Likewise.
78078         * doc/posix-headers/time.texi: Likewise.
78080 2011-09-11  Bruno Haible  <bruno@clisp.org>
78082         acl: Fix compilation on Solaris 10 (older version).
78083         * lib/file-has-acl.c (acl_ace_nontrivial): Use NEW_ACE_EVERYONE instead
78084         of ACE_EVERYONE.
78085         * lib/set-mode-acl.c (qset_acl): Likewise.
78086         Reported by Christian Jullien <eligis@orange.fr>.
78088 2011-09-10  Bruno Haible  <bruno@clisp.org>
78090         iconv, unsetenv: Add support for MSVC compiler.
78091         * m4/iconv.m4 (AM_ICONV): Use ISO C declaration syntax on MSVC.
78092         * m4/setenv.m4 (gl_FUNC_UNSETENV): Drop support for K&R C compilers.
78094 2011-09-10  Bruno Haible  <bruno@clisp.org>
78096         *printf: Add support for MSVC compiler.
78097         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): On MSVC, install a handler that
78098         handles the exception caused by the %n directive. When cross-compiling,
78099         guess no on native Windows.
78100         (gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
78101         gl_SNPRINTF_DIRECTIVE_N, gl_SNPRINTF_SIZE1): When snprintf is missing,
78102         emulate it through vsnprintf.
78103         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Update comment.
78104         * doc/posix-functions/dprintf.texi: Update documentation regarding
78105         MSVC 9.
78106         * doc/posix-functions/fprintf.texi: Likewise.
78107         * doc/posix-functions/printf.texi: Likewise.
78108         * doc/posix-functions/snprintf.texi: Likewise.
78109         * doc/posix-functions/sprintf.texi: Likewise.
78110         * doc/posix-functions/swprintf.texi: Likewise.
78111         * doc/posix-functions/vdprintf.texi: Likewise.
78112         * doc/posix-functions/vfprintf.texi: Likewise.
78113         * doc/posix-functions/vprintf.texi: Likewise.
78114         * doc/posix-functions/vsnprintf.texi: Likewise.
78115         * doc/posix-functions/vsprintf.texi: Likewise.
78116         * doc/glibc-functions/asprintf.texi: Likewise.
78117         * doc/glibc-functions/obstack_printf.texi: Likewise.
78118         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
78119         * doc/glibc-functions/vasprintf.texi: Likewise.
78121 2011-09-10  Bruno Haible  <bruno@clisp.org>
78123         nocrash: Add support for native Windows.
78124         * m4/nocrash.m4 (GL_NOCRASH): Avoid a crash also on native Windows.
78126 2011-09-10  Michael Goffioul  <michael.goffioul@gmail.com>  (tiny change)
78127             Bruno Haible  <bruno@clisp.org>
78129         absolute-header, include-next: Add support for MSVC compiler.
78130         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): Require
78131         AC_CANONICAL_HOST. On native Windows, recognize also backslash as
78132         directory separator in #line directives.
78133         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): On native Windows,
78134         recognize also backslash as directory separator in #line directives.
78136 2011-09-08  Jim Meyering  <meyering@redhat.com>
78138         maint.mk: mark the post-release commit log with "maint: " prefix
78139         * top/maint.mk (emit-commit-log): Add "maint: " prefix to the
78140         one-line commit-log summary.
78142 2011-09-08  Reuben Thomas  <rrt@sc3d.org>
78143             Bruno Haible  <bruno@clisp.org>
78145         Doc about crypt functions.
78146         * doc/posix-functions/crypt.texi: Mention need for _GNU_SOURCE on glibc
78147         systems.
78148         * doc/posix-functions/encrypt.texi: Likewise.
78149         * doc/posix-functions/setkey.texi: Likewise.
78151 2011-09-08  Simon Josefsson  <simon@josefsson.org>
78153         * lib/gc.h: Fix copyright header.
78155 2011-09-07  Bruno Haible  <bruno@clisp.org>
78157         pthread: Determine $(LIB_PTHREAD) correctly on OSF/1 5.1.
78158         * m4/pthread.m4 (gl_PTHREAD_CHECK): Use AC_CACHE_CHECK and
78159         AC_LINK_IFELSE instead of AC_SEARCH_LIBS.
78161 2011-09-07  Bruno Haible  <bruno@clisp.org>
78163         openat: Work around compilation error with OSF/1 5.1 DTK cc.
78164         * lib/fopen.c: Use different syntax for include of <stdio.h>.
78165         * lib/freopen.c: Likewise.
78166         * lib/fstatat.c: Use different syntax for include of <sys/stat.h>.
78167         * lib/lstat.c: Likewise.
78168         * lib/stat.c: Likewise.
78169         * lib/open.c: Use different syntax for include of <fcntl.h>.
78170         * lib/openat.c: Include fcntl.h again, explicitly.
78172 2011-09-04  J.T. Conklin  <jtc@acorntoolworks.com>
78174         parse-datetime: document the newly accepted format
78175         * doc/parse-datetime.texi (Combined date and time of day items):
78176         New section.
78178 2011-09-06  Bruno Haible  <bruno@clisp.org>
78180         acl: Fix a test failure on newer Solaris 10 with ZFS.
78181         * tests/test-sameacls.c (main): Interpret acl GETACLCNT failure with
78182         ENOSYS as no ACL.
78183         Reported by Jim Meyering.
78185 2011-09-06  Bruno Haible  <bruno@clisp.org>
78187         acl: Update for AIX >= 5.3 with NFS.
78188         * lib/file-has-acl.c (file_has_acl): Interpret aclx_get failure with
78189         ENOSYS as no ACL.
78191         acl: Fix a test failure on AIX >= 5.3 with NFS.
78192         * tests/test-sameacls.c (main): Interpret aclx_get failure with ENOSYS
78193         as no ACL.
78195 2011-09-06  Bruno Haible  <bruno@clisp.org>
78197         acl: Fix a test failure on IRIX 6.5 with NFS.
78198         * lib/acl-internal.h (MODE_INSIDE_ACL): Define to 0 on IRIX.
78199         * lib/set-mode-acl.c (qset_acl): Test !HAVE_ACL_TYPE_EXTENDED instead
78200         of MODE_INSIDE_ACL. If !MODE_INSIDE_ACL, do a chmod_or_fchmod always.
78201         * lib/copy-acl.c (qcopy_acl): Likewise.
78203 2011-09-05  Paul Eggert  <eggert@cs.ucla.edu>
78205         openat: port to AIX 7.1 with large files
78206         AIX 7.1 does a "#define openat open64at" if large files are in use,
78207         so we can't simply #undef openat.  Use the orig_openat trick (similar
78208         to orig_open in lib/open.c) to work around the problem.  Problem
78209         reported by Kevin Brott for GNU tar, in the thread containing
78210         <http://lists.gnu.org/r/bug-tar/2011-09/msg00032.html>.
78211         * lib/openat.c (__need_system_fcntl_h): Define first.
78212         Include <fcntl.h> and <sys/types.h> before undefining.
78213         (orig_openat) [HAVE_OPENAT]: New inline function.
78214         (openat) [HAVE_OPENAT]: Do not undef.
78215         (rpl_openat): Use orig_openat, not openat.
78217 2011-09-05  Joachim Schmitz  <schmitz@hp.com>  (tiny change)
78218             Bruno Haible  <bruno@clisp.org>
78220         acl: Avoid errors on NonStop Kernel.
78221         * lib/file-has-acl.c (file_has_acl) [NonStop Kernel]: Ignore ENOSYS and
78222         ENOTSUP errors.
78224 2011-09-05  Bruno Haible  <bruno@clisp.org>
78226         acl: Clean up Solaris code.
78227         * lib/acl-internal.h: Remove no-op #if.
78228         * lib/file-has-acl.c: Likewise.
78229         * lib/set-mode-acl.c (qset_acl): Remove unused Solaris code.
78230         * lib/copy-acl.c (qcopy_acl): Likewise.
78232 2011-09-05  Bruno Haible  <bruno@clisp.org>
78234         acl: Fix a bug with NFSv4 ACLs on Solaris 10 (newer version) in
78235         binaries built on the original Solaris 10.
78236         * lib/file-has-acl.c (file_has_acl): ACLs with 4..6 ACEs can be
78237         trivial.
78239 2011-09-05  Bruno Haible  <bruno@clisp.org>
78241         acl: Improve support of NFSv4 ACLs on Solaris 10 (newer version).
78242         * lib/acl-internal.h (acl_nontrivial): Declare also on newer Solaris
78243         10.
78244         * lib/file-has-acl.c (acl_nontrivial): Define also on newer Solaris 10.
78245         (acl_ace_nontrivial): Likewise. Recognize the trivial ACLs with 6 ACEs.
78246         * lib/copy-acl.c (qcopy_acl): On newer Solaris 10, use acl or facl
78247         instead of acl_get, facl_get, acl_set, facl_set.
78249 2011-09-05  Bruno Haible  <bruno@clisp.org>
78251         copy-file: Try unit tests on more file systems.
78252         * tests/test-copy-file-1.sh: New file.
78253         * tests/test-copy-file-2.sh: New file.
78254         * modules/copy-file-tests (Files): Add them.
78255         (Makefile.am): Add them to TESTS.
78257         acl: Try unit tests on more file systems.
78258         * tests/test-file-has-acl-1.sh: New file.
78259         * tests/test-file-has-acl-2.sh: New file.
78260         * tests/test-set-mode-acl-1.sh: New file.
78261         * tests/test-set-mode-acl-2.sh: New file.
78262         * tests/test-copy-acl-1.sh: New file.
78263         * tests/test-copy-acl-2.sh: New file.
78264         * modules/acl-tests (Files): Add them.
78265         (Makefile.am): Add them to TESTS.
78267 2011-09-04  Bruno Haible  <bruno@clisp.org>
78269         acl: Improve support of NFSv4 ACLs on Solaris 10 (newer version).
78270         * lib/acl-internal.h (ACE_*, NEW_ACE_*): Define also on newer Solaris
78271         10.
78272         (OLD_ALLOW, OLD_DENY): New macros.
78273         (NEW_ACE_ACCESS_ALLOWED_ACE_TYPE): Renamed from
78274         ACE_ACCESS_ALLOWED_ACE_TYPE.
78275         (NEW_ACE_ACCESS_DENIED_ACE_TYPE): Renamed from
78276         ACE_ACCESS_DENIED_ACE_TYPE.
78277         (OLD_ACE_OWNER, OLD_ACE_GROUP, OLD_ACE_OTHER): New macros.
78278         (NEW_ACE_EXECUTE): Fix value.
78279         (NEW_ACE_APPEND_DATA, NEW_ACE_READ_NAMED_ATTRS,
78280         NEW_ACE_WRITE_NAMED_ATTRS, NEW_ACE_DELETE_CHILD,
78281         NEW_ACE_READ_ATTRIBUTES, NEW_ACE_WRITE_ATTRIBUTES, NEW_ACE_DELETE,
78282         NEW_ACE_READ_ACL, NEW_ACE_WRITE_ACL, NEW_ACE_WRITE_OWNER,
78283         NEW_ACE_SYNCHRONIZE): New macros.
78284         * lib/set-mode-acl.c (qset_acl): On newer Solaris 10, use acl or facl
78285         instead of acl_fromtext, acl_set, facl_set.
78286         Fixes a coreutils/tests/cp/perm failure.
78288 2011-09-03  Paul Eggert  <eggert@cs.ucla.edu>
78290         openat: test for fstatat (..., 0) bug
78291         Further testing with tar suggests that fstatat (..., 0)
78292         does not work in general, on AIX 7.1; see
78293         <http://lists.gnu.org/r/bug-tar/2011-09/msg00023.html>.
78294         So, give up entirely on AIX 7.1's fstatat, and fall back on our
78295         replacement fstatat (which is what older AIX releases were using
78296         anyway).
78297         * lib/fstatat.c (fstatat) [HAVE_FSTATAT]: Do not undef.  The only
78298         use is now changed to orig_fstatat.  This was probably the right
78299         thing to do anyway.
78300         (FSTATAT_AT_FDCWD_0_BROKEN): Remove; no longer used.
78301         (rpl_fstatat) [FSTATAT_ZERO_FLAG_BROKEN]: Remove.
78302         (rpl_fstatat): Simplify, assuming !FSTATAT_ZERO_FLAG_BROKEN.
78303         (AT_FUNC_NAME) [FSTATAT_ZERO_FLAG_BROKEN]: Now rpl_fstatat.
78304         * m4/openat.m4 (gl_FUNC_FSTATAT): Test for the more-general bug
78305         and define FSTATAT_ZERO_FLAG_BROKEN, not FSTATAT_AT_FDCWD_0_BROKEN,
78306         if the bug is found.
78308         openat: test for fstatat (AT_FDCWD, ..., 0) bug
78309         This tests for another fstatat bug on AIX 7.1:
78310         fstatat (AT_FDCWD, ..., 0) does not work.  See
78311         <http://lists.gnu.org/r/bug-tar/2011-09/msg00015.html>.
78312         * lib/fstatat.c (FSTATAT_AT_FDCWD_0_BROKEN)
78313         (LSTAT_FOLLOWS_SLASHED_SYMLINK): Default to 0.
78314         (rpl_fstatat): Adjust so that it works around either (or both)
78315         bugs if present.
78316         * m4/openat.m4 (gl_FUNC_FSTATAT): Test for this fstatat bug.
78318 2011-09-03  Karl Berry  <karl@gnu.org>
78320         * doc/regex.texi (Character Class Operators): Avoid literal ":"
78321         in index entries.
78323 2011-09-02  Bruno Haible  <bruno@clisp.org>
78325         Allow the user to override the choice of AR, ARFLAGS, RANLIB.
78326         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): Don't override the given
78327         values of AR, ARFLAGS, RANLIB.
78328         Reported by John W. Eaton <jwe@gnu.org> for Octave.
78330 2011-09-02  Bruno Haible  <bruno@clisp.org>
78332         Find 'ar' program that fits with --host argument.
78333         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): Use AC_CHECK_TOOL.
78335 2011-09-02  Bruno Haible  <bruno@clisp.org>
78337         tests: init.sh: Support any non-GNU diff.
78338         * tests/init.sh (compare): If "diff -c" is supported but "diff -u" is
78339         not, use "diff -c". Useful on AIX 6.1, HP-UX 11.31, OSF/1 5.1,
78340         Solaris 8.
78342 2011-09-02  Bruno Haible  <bruno@clisp.org>
78344         tests: init.sh: work also with any non-GNU diff that supports -u
78345         * tests/init.sh: Relax check for diff -u support.
78346         Rather than checking for GNU diff via --version, simply check
78347         for support for -u itself.  Useful at least on OpenBSD 4.9,
78348         AIX 7.1, IRIX 6.5, and Solaris 10.
78350 2011-09-01  Bruno Haible  <bruno@clisp.org>
78352         strtoimax, strtoumax: Document problem on HP-UX 11.
78353         * doc/posix-functions/strtoimax.texi: Mention HP-UX 11.11 problem.
78354         * doc/posix-functions/strtoumax.texi: Likewise.
78356 2011-09-01  Bruno Haible  <bruno@clisp.org>
78358         strtoumax: Avoid link error on OSF/1 with DTK cc.
78359         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Always test whether strtoumax is
78360         defined as a function.
78361         * modules/strtoumax (Depends-on, configure.ac): Test only whether
78362         strtoumax is defined, not whether it is declared.
78364 2011-09-01  Bruno Haible  <bruno@clisp.org>
78366         strtoimax: Avoid link error on OSF/1 with DTK cc.
78367         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Always test whether strtoimax is
78368         defined as a function.
78369         * modules/strtoimax (Depends-on, configure.ac): Test only whether
78370         strtoimax is defined, not whether it is declared.
78372 2011-09-01  Bruno Haible  <bruno@clisp.org>
78374         imaxdiv: Avoid link error on OSF/1 with DTK cc.
78375         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Also test whether imaxdiv is defined
78376         as a function.
78377         * modules/imaxdiv (configure.ac): Test whether imaxdiv is defined, not
78378         whether it is declared.
78380 2011-09-01  Bruno Haible  <bruno@clisp.org>
78382         imaxabs: Avoid link error on OSF/1 with DTK cc.
78383         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Also test whether imaxabs is defined
78384         as a function.
78385         * modules/imaxabs (configure.ac): Test whether imaxabs is defined, not
78386         whether it is declared.
78388 2011-09-01  Bruno Haible  <bruno@clisp.org>
78390         Tests for module 'strtoumax'.
78391         * modules/strtoumax-tests: New file.
78392         * tests/test-strtoumax.c: New file.
78394         Tests for module 'strtoimax'.
78395         * modules/strtoimax-tests: New file.
78396         * tests/test-strtoimax.c: New file.
78398         Tests for module 'imaxdiv'.
78399         * modules/imaxdiv-tests: New file.
78400         * tests/test-imaxdiv.c: New file.
78402         Tests for module 'imaxabs'.
78403         * modules/imaxabs-tests: New file.
78404         * tests/test-imaxabs.c: New file.
78406 2011-09-01  Bruno Haible  <bruno@clisp.org>
78408         pthread: Determine $(LIB_PTHREAD) correctly on IRIX 6.5.
78409         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for pthread_join, not
78410         pthread_create.
78412 2011-09-01  Paul Eggert  <eggert@cs.ucla.edu>
78414         openat: work around AIX 7.1 fstatat issue
78415         This should fix the problem that was not properly fixed
78416         in the previous change, dated 2011-08-30.
78417         * lib/fstatat.c: Include <sys/stat.h> twice, the first with
78418         __need_system_stat_h defined.
78419         (orig_fstatat) [HAVE_FSTATAT]: New function.
78420         (rpl_fstatat): Go back to the old way of doing things,
78421         except call orig_fstatat instead of fstatat.
78422         * m4/openat.m4 (gl_FUNC_FSTATAT): Remove unnecessary check for openat.
78423         Remove unnecessary check whether fstatat fills in st_size etc.
78425 2011-09-01  Bruno Haible  <bruno@clisp.org>
78427         sys_select: Avoid a syntax error regarding timespec_t on IRIX 6.5.
78428         * lib/sys_select.in.h [__sgi]: When included from <sys/bsd_types.h>,
78429         just include the system's header.
78431 2011-08-31  Jim Meyering  <meyering@redhat.com>
78433         tests: avoid spurious assertion failure in test-float.c on ppc64
78434         * tests/test-float.c (test_long_double): Comment out an assertion,
78435         LDBL_MIN_EXP <= DBL_MIN_EXP, that is failing at least on PowerPC-64
78436         with gcc-4.4.4.
78438         maint: indent with spaces, not TABs
78439         I need to get in the habit of running gnulib's "make check".
78440         Both of these would have been caught.
78441         * m4/largefile.m4: Indent with spaces, not TABs.
78442         * lib/parse-datetime.y (iso_8601_time): Likewise.
78443         Spotted by Pádraig Brady.
78445         test-parse-datetime.c: accommodate a relatively strict gcc warning
78446         * tests/test-parse-datetime.c (gmt_offset): Declare function "static",
78447         to avoid a warning from gcc's -Werror=missing-declarations.
78448         Insert a few spaces-before-funcall-parenthesis.
78450 2011-08-17  J.T. Conklin  <jtc@acorntoolworks.com>
78452         parse-datetime: accept ISO 8601 date and time rep with "T" separator
78453         The parser now accepts ISO 8601 date-time strings with "T" as the
78454         separator.  It has long parsed dates like "2004-02-29 16:21:42"
78455         with a space between the date and time strings.  Now it also parses
78456         "2004-02-29T16:21:42" and fractional-second and time-zone-annotated
78457         variants like "2004-02-29T16:21:42.333-07:00"
78458         * lib/parse-datetime.y: Parse ISO 8601 extended date and time
78459         of day representation using the 'T' separator character.
78460         * doc/parse-datetime.texi (General date syntax): replace use of
78461         deprecated --iso-8601 option with --rfc-3339 in example of date
78462         command output formats that can be parsed.
78463         * tests/test-parse-datetime.c (tm_diff): New function, taken from
78464         lib/parse-datetime.y.
78465         (gmt_offset): New function.
78466         (main): Add additional test cases to validate ISO8601 extended
78467         date and time of day parsing.
78469 2011-08-31  Bruno Haible  <bruno@clisp.org>
78471         freopen: Documentation.
78472         * doc/posix-functions/freopen.texi: Document the bug with the NULL file
78473         name.
78474         Reported by Claudio Bley <claudio.bley@gmail.com>.
78476 2011-08-31  Claudio Bley  <claudio.bley@gmail.com>  (tiny change)
78478         freopen: Don't crash if the filename argument is NULL.
78479         * lib/freopen.c (rpl_freopen): Don't compare the filename if it is
78480         NULL.
78482 2011-08-30  Paul Eggert  <eggert@cs.ucla.edu>
78484         openat: work around AIX 7.1 fstatat bug
78485         Problem reported by Kevin Brott for GNU tar, in the thread containing
78486         <http://lists.gnu.org/r/bug-tar/2011-08/msg00015.html>.
78487         * lib/fstatat.c (rpl_fstatat): Do not invoke underlying fstatat if
78488         FSTATAT_ST_SIZE_ETC_BROKEN.
78489         (fstatat) [FSTATAT_ST_SIZE_ETC_BROKEN && HAVE_FSTATAT]: #define to
78490         rpl_fstatat.
78491         * m4/openat.m4 (gl_FUNC_FSTATAT): New macro, with the fstatat-relevant
78492         part of gl_FUNC_OPENAT.  Also, check for the AIX 7.1 bug, and use
78493         AC_CHECK_FUNCS_ONCE for fstatat.
78494         (gl_FUNC_OPENAT): Use it.  Use AC_CHECK_FUNCS_ONCE for
78495         fchmodat, mkdirat, openat and unlinkat.
78497 2011-08-30  Bruno Haible  <bruno@clisp.org>
78499         Avoid endless recursions if config.h includes some header files.
78500         * lib/fopen.c (__need_FILE): Define already before including config.h.
78501         * lib/freopen.c (__need_FILE): Likewise.
78502         * lib/open.c (__need_system_fcntl_h): Likewise.
78503         * lib/stat.c (__need_system_sys_stat_h): Likewise.
78504         * lib/lstat.c (__need_system_sys_stat_h): Likewise.
78505         Reported by Michael Goffioul <michael.goffioul@gmail.com>.
78507 2011-08-25  Karl Berry  <karl@gnu.org>
78509         * config/srclist.txt (ylwrap): new try.
78510         * build-aux/ylwrap: new file.
78512 2011-08-23  Bruno Haible  <bruno@clisp.org>
78514         tmpdir: Use a good default directory on native Windows.
78515         * lib/tmpdir.c: Include <windows.h>, pathmax.h.
78516         (P_tmpdir): Default to _P_tmpdir on native Windows.
78517         (path_search): On native Windows, try the value returned by GetTempPath
78518         before trying P_tmpdir.
78519         * modules/tmpdir (Depends-on): Add pathmax.
78520         Suggested by John Darrington <john@darrington.wattle.id.au>.
78522 2011-08-20  Reuben Thomas  <rrt@sc3d.org>
78524         doc: fix typo in README-release
78525         * top/README-release: Capitalize first word of a sentence.
78527 2011-08-19  Jim Meyering  <meyering@redhat.com>
78529         fts: do not exhaust memory when processing million-entry directories
78530         Before this change, traversing (via rm -rf, find, du, etc.) an N-entry
78531         directory would require about 256*N bytes of memory.  Thus, it was
78532         easy to construct a directory too large to be processed by any of
78533         those tools.  With this change, fts' maximum memory utilization is
78534         now limited to around 30MB.
78535         * lib/fts.c (FTS_MAX_READDIR_ENTRIES): Define.
78536         (fts_read): When we've processed the final entry (i.e., when
78537         ->fts_link is NULL) and fts_dirp is non-NULL, call fts_build
78538         using the parent entry to read any remaining entries.  Dispatch
78539         depending on what fts_build returns:
78540         - NULL+stop, aka failure: stop
78541         - NULL otherwise: move up in the dir hierarchy
78542         - non-NULL: handle this new entry
78543         (fts_build): Declare and use new local, continue_readdir.
78544         Prepare to be called from fts_read, when the entries
78545         from a partially-read directory have just been exhausted.
78546         In that case, we'll skip the opendir and instead use the parent's
78547         fts_dirp and derive dir_fd from that.
78548         Finally, in the readdir loop, if we read max_entries entries,
78549         exit the loop ensuring *not* to call closedir.  This is required
78550         so that fts_dirp can be reused on a subsequent call.
78551         Prompted by Ben England's report of memory exhaustion in find
78552         and rm -rf vs. NFS: https://bugzilla.redhat.com/719749.
78554         maint: fts: move decl of `dp' down into while loop; split a long line
78555         * lib/fts.c (fts_build): No semantic change.
78557         fts: add/use new struct member, fts_dirp
78558         We are about to use this to manage any directory with
78559         too many entries to read all of them into memory at once.
78560         To do that, we'll need to save the DIR* pointer in each
78561         affected FTSENT struct.
78562         * lib/fts_.h: Include <dirent.h>.
78563         (struct FTSENT) [fts_dirp]: New member.
78564         * lib/fts.c (closedir_and_clear): Define.
78565         Use it in place of closedir so that we are sure to
78566         clear the new fts_dirp member when done with it.
78567         (fts_alloc): Initialize the new member.
78568         (fts_lfree): Free, if needed.
78570         maint: fts: give __opendir2 a new parameter and rename
78571         * lib/fts.c (__opendir2): Give it a new parameter, Pdir_fd, rather
78572         than surreptitiously using sole caller's "dir_fd".
78573         (fts_opendir): Rename from __opendir2.
78575         maint: fts.c: remove __opendir2's now-unused parameter, oflag
78576         * lib/fts.c (__opendir2): Remove unused parameter, oflag.
78578         maint: fts.c: correct off-by-one indentation
78579         * lib/fts.c (fts_build): Correct indentation, change style
78580         of a couple of block comments, and bracing style.
78582         maint: fts.c: move __opendir2 #define "up" out of function body
78583         * lib/fts.c (__opendir2): Move "up".  No semantic change.
78585         maint: fts.c: remove #if-0'd FTS_WHITEOUT code
78586         * lib/fts.c: Remove #if-0'd FTS_WHITEOUT code.  It's been #if-0'd
78587         out for a long time and besides was useful only on BSD systems.
78589 2011-08-18  Paul Eggert  <eggert@cs.ucla.edu>
78591         regex: port to Stratus OpenVOS
78592         * lib/regex_internal.h (internal_function) [!_LIBC]: Simply
78593         define to empty, rather than attempting nonportable optimizations.
78594         Problem reported by Paul Green in:
78595         http://lists.gnu.org/r/bug-diffutils/2011-08/msg00047.html
78596         and fix suggested by Eric Blake in:
78597         http://lists.gnu.org/r/bug-gnulib/2011-08/msg00143.html
78599 2011-08-17  Eric Blake  <eblake@redhat.com>
78601         getcwd: fix test failures on mingw
78602         * lib/getcwd.c (__getcwd): Early exit for ERANGE.
78603         * tests/test-getcwd.c (test_abort_bug, test_long_name): Don't fail
78604         test if long directory cannot be created, and allow mingw errno.
78606         getcwd-lgpl: fix m4 to match relaxed test for BSD
78607         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Relax probe.
78608         (gl_FUNC_GETCWD_SIGNATURE): New macro.
78609         (gl_FUNC_GETCWD_LGPL, gl_FUNC_GETCWD): Use it.
78610         * doc/posix-functions/getcwd.texi (getcwd): Tweak mentions of
78611         signature problem.
78613         getcwd: fix compilation on mingw64
78614         * lib/unistd.in.h (includes) [mingw]: Include <direct.h> for
78615         getcwd.
78616         Reported by Marc-André Lureau.
78618         pipe2: silence compiler warning
78619         * lib/pipe2.c (pipe2): Hide label if it is not used.
78621 2011-08-15  Ben Pfaff  <blp@cs.stanford.edu>
78623         relocatable-prog: fix link error
78624         * modules/relocatable-prog (configure.ac) [RELOCATABLE]: Also
78625         invoke AC_LIBOBJ([relocatable]).  This invocation was previously
78626         in the gl_RELOCATABLE_LIBRARY macro.  That invocation was moved
78627         into modules/relocatable-lib without noticing that
78628         modules/relocatable-prog also invokes gl_RELOCATABLE_LIBRARY and
78629         also needs to build relocatable.c.
78631 2011-08-12  Paul Eggert  <eggert@cs.ucla.edu>
78633         getaddrinfo: fix sh typo in gai_strerrorA decl checking
78634         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix typo in the generated
78635         shell code: it contained a 'break' that was not in a loop.
78636         Apparently the macro assumed that AC_CHECK_DECLS is implemenented
78637         via a shell-language loop; this may have been true in old Autoconf
78638         versions, but it's not true in Autoconf 2.68.  I found this bug
78639         when testing coreutils git on Solaris 8, whose shell complains
78640         about the syntax error.
78642 2011-08-12  Simon Josefsson  <simon@josefsson.org>
78644         * lib/base64.c: Fix comment to reference RFC 4648.
78645         Suggested by Bruno Haible <bruno@clisp.org> and Gijs van Tulder
78646         <gvtulder@gmail.com>.
78648 2011-08-11  Paul Eggert  <eggert@cs.ucla.edu>
78650         * build-aux/bootstrap (slurp): Remove obsolescent gettext.m4 patch.
78652         po/Makefile.in.in: fix make -q problem
78653         * build-aux/po/Makefile.in.in (check-macro-version): Remove this
78654         rule, since there's no file named 'check-macro-version' and its
78655         use as a file breaks make -q.
78656         (all): Don't depend on check-macro-version.
78657         (CHECK_MACRO_VERSION): New macro.
78658         (stamp-po): Use it.
78660         configmake: fix make -q problem
78661         * modules/configmake (configmake.h): Update configmake.h's time stamp
78662         even if the file does not change.  Otherwise, 'make -q' fails.
78663         Problem reported by Simon Josefsson in
78664         <http://lists.gnu.org/r/bug-gnulib/2011-08/msg00088.html>.
78666 2011-08-11  Jim Meyering  <meyering@redhat.com>
78668         git-version-gen: correct the advice in a comment
78669         * build-aux/git-version-gen: Correct comment.
78670         Don't recommend to list .tarball-version in .gitignore.
78672 2011-08-10  Paul Eggert  <eggert@cs.ucla.edu>
78674         base64: fix off-by-one buffer size bug
78675         Problem and (trivial) fix reported by Gijs van Tulder in
78676         <http://lists.gnu.org/r/bug-gnulib/2011-08/msg00083.html>.
78677         * lib/base64.c (base64_decode_alloc_ctx): Allocate one more byte.
78678         * tests/test-base64.c (main): Catch the bug.
78680 2011-08-10  Eric Blake  <eblake@redhat.com>
78682         closein: correct comments
78683         * lib/closein.c (close_stdin): Improve comments.
78685 2011-08-09  Bruno Haible  <bruno@clisp.org>
78687         More tests for 'fseeko'.
78688         * tests/test-fseeko3.c: New file, from Eric Blake.
78689         * tests/test-fseeko3.sh: New file.
78690         * modules/fseeko-tests (Files): Add them.
78691         (TESTS): Add test-fseeko3.sh.
78692         (check_PROGRAMS): Add test-fseeko3.
78694 2011-08-09  Eric Blake  <eblake@redhat.com>
78696         fseeko: remove unneeded hack
78697         * lib/fseeko.c (fseeko): Don't special-case SEEK_END.
78699         fseeko: fix bug on glibc
78700         * lib/fseeko.c (fseeko): Set stream offset to match fd offset.
78701         Reported by John W. Eaton.
78703 2011-08-08  Bruno Haible  <bruno@clisp.org>
78705         unictype/base: Fix interoperability with preinstalled libunistring.
78706         * modules/unictype/base (configure.ac): Bump minimum version to 0.9.4.
78707         Reported by Simon Josefsson.
78709 2011-08-08  Bruno Haible  <bruno@clisp.org>
78711         iswblank: Detect declaration correctly.
78712         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Use correct headers in
78713         AC_CHECK_DECLS invocation.
78715 2011-08-08  Bruno Haible  <bruno@clisp.org>
78717         tcgetsid: Detect declaration correctly.
78718         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Use correct headers in
78719         AC_CHECK_DECLS invocation.
78720         Reported by Simon Josefsson.
78722 2011-08-08  Eric Blake  <eblake@redhat.com>
78724         largefile: fix typo that regressed large file support
78725         * modules/largefile (configure.ac-early): Fix section name.
78727 2011-08-06  Karl Berry  <karl@gnu.org>
78729         * MODULES.html.sh (func_all_files): _Noreturn is no longer
78730         a separate module.
78732 2011-08-05  Simon Josefsson  <simon@josefsson.org>
78734         openat: Fix warnings and commens when building unlinkat.c on Hurd.
78735         * lib/unlinkat.c: Mention Hurd in comments.  Include stdlib.h to
78736         get prototype for free.
78738 2011-08-04  Bruno Haible  <bruno@clisp.org>
78740         Tests for module 'pathmax'.
78741         * modules/pathmax-tests: New file.
78742         * tests/test-pathmax.c: New file.
78744         canonicalize-lgpl: Support larger filenames on the Hurd.
78745         * lib/canonicalize-lgpl.c (__realpath): Bump path_max fallback to 8192.
78746         Reported by Paul Eggert.
78748         pathmax: Leave PATH_MAX undefined on the Hurd, and a constant otherwise.
78749         * lib/pathmax.h (PATH_MAX): Leave it undefined on GNU/Hurd.
78750         * lib/chdir-long.h: Include pathmax.h.
78751         * lib/clean-temp.c (PATH_MAX): Remove code that is done by pathmax.h.
78752         * lib/getcwd.c: Include pathmax.h instead of <limits.h>.
78753         (PATH_MAX): Remove code that is done by pathmax.h.
78754         * lib/canonicalize.c (PATH_MAX): Provide a fallback value.
78755         * lib/tmpfile.c: Add a comment.
78756         * m4/pathmax.m4 (gl_PATHMAX): Don't test for pathconf.
78757         * modules/chdir-long (Depends-on): Add pathmax.
78758         * modules/getcwd (Depends-on): Add pathmax.
78759         * tests/test-getcwd.c (test_abort_bug): Avoid syntax error when PATH_MAX
78760         is not defined.
78761         * doc/posix-headers/limits.texi: Mention the pathmax module.
78762         * NEWS: Mention the change.
78764 2011-08-02  Bruno Haible  <bruno@clisp.org>
78766         pthread_sigmask: Actually use results of gl_THREADLIB.
78767         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test and require
78768         gl_THREADLIB, not gl_[]THREADLIB.
78769         Reported by Eric Blake.
78771 2011-08-02  Jim Meyering  <meyering@redhat.com>
78773         maint.mk: relax the default _gl_TS_function_match regexp
78774         * top/maint.mk (_gl_TS_function_match): Don't require at least one
78775         space between function name and "(" in an "extern" declaration.
78776         That would fail to match a decl with no space there: extern void foo();
78778 2011-07-31  Iain Nicol  <iain@thenicols.net>
78780         git-version-gen: document that EXTRA_DIST must include .version
78781         * build-aux/git-version-gen: In the how-to-use comment, document
78782         that EXTRA_DIST must include .version.  Otherwise, "make distcheck"
78783         will fail when run from an unpacked distribution tarball.
78785 2011-08-01  Bruno Haible  <bruno@clisp.org>
78787         wctype-h: Fix last change.
78788         * m4/wctype_h.m4 (gl_WCTYPE_H): If towlower is defined, set
78789         REPLACE_TOWLOWER to 0.
78790         Reported by Sam Steingold <sds@gnu.org>.
78792 2011-07-31  Bruno Haible  <bruno@clisp.org>
78794         frexpl: Update autoconf test.
78795         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Update overrides of <float.h>,
78796         according to changes of 2011-06-20.
78798 2011-07-31  Bruno Haible  <bruno@clisp.org>
78800         sys_utsname: Add support for Minix.
78801         * lib/sys_utsname.in.h [Minix]: Include <stddef.h> before
78802         <sys/utsname.h>.
78803         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
78804         * doc/posix-headers/sys_utsname.texi: Document the Minix problem.
78806 2011-07-31  Bruno Haible  <bruno@clisp.org>
78808         strings: Add support for Minix.
78809         * lib/strings.in.h [Minix]: Include <sys/types.h> before <strings.h>.
78810         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Likewise.
78811         * doc/posix-headers/strings.texi: Document the Minix problem.
78813 2011-07-31  Bruno Haible  <bruno@clisp.org>
78815         wctype-h: Add support for Minix.
78816         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether towlower is declared. Set
78817         REPLACE_TOWLOWER.
78818         * modules/wctype-h (Makefile.am): Substitute REPLACE_TOWLOWER.
78819         * lib/wctype.in.h (towlower, towupper): Test REPLACE_TOWLOWER, not
78820         REPLACE_ISWCNTRL.
78822 2011-07-31  Paul Eggert  <eggert@cs.ucla.edu>
78824         * lib/xalloc.h (DEFAULT_MXFAST): Track 64-bit glibc.
78825         This is a performance improvement for 64-bit hosts: it causes the
78826         value of DEFAULT_MXFAST to track what's in glibc on such hosts.
78828 2011-07-31  Bruno Haible  <bruno@clisp.org>
78830         stdioext: Add support for Minix.
78831         * lib/fbufmode.c (fbufmode) [__minix]: Add conditional code.
78832         * lib/fpurge.c (fpurge): Likewise.
78833         * lib/freadahead.c (freadahead): Likewise.
78834         * lib/freadable.c (freadable): Likewise.
78835         * lib/freading.c (freading): Likewise.
78836         * lib/freadptr.c (freadptr): Likewise.
78837         * lib/freadseek.c (freadptrinc): Likewise.
78838         * lib/fseeko.c (rpl_fseeko): Likewise.
78839         * lib/fseterr.c (fseterr): Likewise.
78840         * lib/fwritable.c (fwritable): Likewise.
78841         * lib/fwriting.c (fwriting): Likewise.
78842         * lib/fflush.c (clear_ungetc_buffer): Update comment.
78843         * m4/fpending.m4 (gl_PREREQ_FPENDING): Add a variant for Minix.
78845 2011-07-31  Bruno Haible  <bruno@clisp.org>
78847         errno: Port to Minix.
78848         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Test also whether ENETRESET and
78849         ECONNABORTED are defined.
78850         * lib/errno.in.h (ENETRESET, GNULIB_defined_ENETRESET, ECONNABORTED,
78851         GNULIB_defined_ECONNABORTED): New macros.
78852         * lib/strerror-override.h (strerror_override): Test also
78853         GNULIB_defined_ENETRESET, GNULIB_defined_ECONNABORTED.
78854         * lib/strerror-override.c (strerror_override): Handle also ENETRESET,
78855         ECONNABORTED.
78856         * doc/posix-headers/errno.texi: Mention the Minix problem.
78858 2011-07-31  Bruno Haible  <bruno@clisp.org>
78860         Work around declaration collisions on Minix.
78861         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): If mbsinit is declared but not
78862         defined, set REPLACE_MBSINIT.
78863         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): If mbrtowc is declared but not
78864         defined, set REPLACE_MBRTOWC.
78865         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): If mbrlen is declared but not defined,
78866         set REPLACE_MBRLEN.
78867         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): If mbsrtowcs is declared but not
78868         defined, set REPLACE_MBSRTOWCS.
78869         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): If wcrtomb is declared but not
78870         defined, set REPLACE_WCRTOMB.
78871         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): If wcsrtombs is declared but not
78872         defined, set REPLACE_WCSRTOMBS.
78874 2011-07-31  Bruno Haible  <bruno@clisp.org>
78876         Add support for Minix with ACK compiler.
78877         * m4/gnulib-common.m4 (gl_PROG_AR_RANLIB): New macro.
78878         * gnulib-tool (func_import, func_create_testdir): Emit invocation of
78879         gl_PROG_AR_RANLIB instead of AC_PROG_RANLIB.
78881 2011-07-31  Bruno Haible  <bruno@clisp.org>
78883         Documentation about Minix.
78884         * doc/posix-headers/*.texi: Add info about Minix 3.1.8.
78885         * doc/glibc-headers/*.texi: Likewise.
78886         * doc/posix-functions/*.texi: Likewise.
78887         * doc/glibc-functions/*.texi: Likewise.
78889 2011-07-31  Bruno Haible  <bruno@clisp.org>
78891         snippet/warn-on-use: Fix indentation.
78892         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Fix indentation.
78894 2011-07-25  Jim Meyering  <meyering@redhat.com>
78896         tests: test-update-copyright.sh: remove unnecessary "rm" commands
78897         * tests/test-update-copyright.sh: Remove unused rm -f $TMP.*.bak
78898         commands.
78900 2011-07-27  Jim Meyering  <meyering@redhat.com>
78902         maint.mk: avoid sc_prohibit_always-defined_macros failure in coreutils
78903         * top/maint.mk (gl_extract_significant_defines_): Now that
78904         SA_RESETHAND and SA_RESTART are #defined (albeit conditionally) in
78905         gnulib/lib/signal.in.h, and now that we recommend to
78906         define-if-undefined those two symbols in application code,
78907         we must filter them out of the "significant" list.
78908         This avoids a "make syntax-check" failure in coreutils.
78910 2011-07-26  Eric Blake  <eblake@redhat.com>
78912         warnings: add comments about previous patch
78913         * m4/absolute-header.m4: Document AS_VAR_PUSHDEF limitation.
78914         * m4/include_next.m4: Likewise.
78915         * m4/warn-on-use.m4: Likewise.
78916         * m4/warnings.m4: Likewise, and simplify use.
78917         Suggested by Stefano Lattarini.
78919         include-next, warnings: support older autoconf
78920         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): Use
78921         AS_VAR_PUSHDEF in a way that works with older autoconf.
78922         * m4/warnings.m4 (gl_WARN_ADD): Likewise.
78923         Reported by Daniel P. Berrange.
78925 2011-07-25  Bruno Haible  <bruno@clisp.org>
78927         fseek, ftell: Fix doc.
78928         * doc/posix-functions/fseek.texi: Reword statement about
78929         AC_SYS_LARGEFILE.
78930         * doc/posix-functions/ftell.texi: Likewise.
78932 2011-07-25  Paul Eggert  <eggert@cs.ucla.edu>
78933             Bruno Haible  <bruno@clisp.org>
78935         Add dependencies to the 'largefile' module.
78936         * modules/fopen (Depends-on): Add 'largefile'.
78937         * modules/freopen (Depends-on): Likewise.
78938         * modules/fseeko (Depends-on): Likewise.
78939         * modules/ftello (Depends-on): Likewise.
78940         * modules/glob (Depends-on): Likewise.
78941         * modules/lseek (Depends-on): Likewise.
78942         * modules/lstat (Depends-on): Likewise.
78943         * modules/mkostemp (Depends-on): Likewise.
78944         * modules/mkostemps (Depends-on): Likewise.
78945         * modules/mkstemp (Depends-on): Likewise.
78946         * modules/mkstemps (Depends-on): Likewise.
78947         * modules/open (Depends-on): Likewise.
78948         * modules/openat (Depends-on): Likewise.
78949         * modules/pread (Depends-on): Likewise.
78950         * modules/pwrite (Depends-on): Likewise.
78951         * modules/scandir (Depends-on): Likewise.
78952         * modules/stat (Depends-on): Likewise.
78953         * modules/tmpfile (Depends-on): Likewise.
78954         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Do not require AC_SYS_LARGEFILE,
78955         since the containing module now depends on the largefile module.
78956         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Likewise.
78957         * doc/posix-functions/fopen.texi: Mention that the problem of 32-bit
78958         off_t is fixed by gnulib.
78959         * doc/posix-functions/freopen.texi: Likewise.
78960         * doc/posix-functions/fseeko.texi: Likewise.
78961         * doc/posix-functions/fstatat.texi: Likewise.
78962         * doc/posix-functions/ftello.texi: Likewise.
78963         * doc/posix-functions/glob.texi: Likewise.
78964         * doc/posix-functions/lseek.texi: Likewise.
78965         * doc/posix-functions/lstat.texi: Likewise.
78966         * doc/posix-functions/mkstemp.texi: Likewise.
78967         * doc/posix-functions/open.texi: Likewise.
78968         * doc/posix-functions/openat.texi: Likewise.
78969         * doc/posix-functions/pread.texi: Likewise.
78970         * doc/posix-functions/pwrite.texi: Likewise.
78971         * doc/posix-functions/scandir.texi: Likewise.
78972         * doc/posix-functions/stat.texi: Likewise.
78973         * doc/posix-functions/tmpfile.texi: Likewise.
78974         * doc/glibc-functions/mkostemp.texi: Likewise.
78975         * doc/glibc-functions/mkostemps.texi: Likewise.
78976         * doc/glibc-functions/mkstemps.texi: Likewise.
78978 2011-07-25  Bruno Haible  <bruno@clisp.org>
78980         fcntl: Move AC_LIBOBJ invocation to module description.
78981         * m4/fcntl.m4 (gl_REPLACE_FCNTL): Don't invoke AC_LIBOBJ.
78982         * modules/fcntl (configure.ac): Invoke AC_LIBOBJ.
78984         fcntl: Remove call-in from fchdir.m4.
78985         * m4/fcntl.m4 (gl_FUNC_FCNTL): Conditionally invoke gl_TEST_FCHDIR.
78986         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_FCNTL.
78988         dup3: Remove potential call-in from fchdir.m4.
78989         * m4/dup3.m4 (gl_FUNC_DUP3): Add comment about fchdir.
78990         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Remove comment about dup3.
78992         dup2: Move AC_LIBOBJ invocation to module description.
78993         * m4/dup2.m4 (gl_REPLACE_DUP2): Remove macro.
78994         (gl_FUNC_DUP2): Instead of gl_REPLACE_DUP2, just set REPLACE_DUP2 to 1.
78995         Don't invoke AC_LIBOBJ.
78996         * modules/dup2 (configure.ac): Invoke AC_LIBOBJ.
78998         dup2: Remove call-in from fchdir.m4.
78999         * m4/dup2.m4 (gl_FUNC_DUP2): Conditionally invoke gl_TEST_FCHDIR.
79000         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_DUP2.
79002         fclose: Move AC_LIBOBJ invocation to module description.
79003         * m4/fclose.m4 (gl_REPLACE_FCLOSE): Remove macro.
79004         (gl_FUNC_FCLOSE): Instead of gl_REPLACE_FCLOSE, just set REPLACE_FCLOSE
79005         to 1.
79006         * modules/fclose (configure.ac): Invoke AC_LIBOBJ.
79008         fclose: Remove call-in from close.m4.
79009         * m4/fclose.m4 (gl_FUNC_FCLOSE): Invoke gl_FUNC_CLOSE.
79010         * m4/close.m4 (gl_FUNC_CLOSE): Don't invoke gl_REPLACE_FCLOSE.
79012         close: Move AC_LIBOBJ invocation to module description.
79013         * m4/close.m4 (gl_REPLACE_CLOSE): Remove macro.
79014         (gl_FUNC_CLOSE): Instead of gl_REPLACE_CLOSE, just set REPLACE_CLOSE to
79015         1.
79016         * modules/close (configure.ac): Invoke AC_LIBOBJ.
79018         close: Remove call-in from fchdir.m4.
79019         * m4/close.m4 (gl_FUNC_CLOSE): Conditionally invoke gl_TEST_FCHDIR.
79020         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_CLOSE.
79022         open: Move AC_LIBOBJ invocation to module description.
79023         * m4/open.m4 (gl_REPLACE_OPEN): Remove macro.
79024         (gl_FUNC_OPEN): Instead of gl_REPLACE_OPEN, just set REPLACE_OPEN to 1.
79025         * modules/open (configure.ac): Invoke AC_LIBOBJ and gl_PREREQ_OPEN.
79027         open: Remove call-in from fchdir.m4.
79028         * m4/open.m4 (gl_FUNC_OPEN): Conditionally invoke gl_TEST_FCHDIR.
79029         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Don't invoke gl_REPLACE_OPEN.
79031         fchdir: Start to remove gl_REPLACE_* idiom.
79032         * m4/fchdir.m4 (gl_TEST_FCHDIR): New macro.
79033         (gl_FUNC_FCHDIR): Invoke it.
79035 2011-07-25  Paul Eggert  <eggert@cs.ucla.edu>
79037         * lib/ftell.c (ftell): Comment out cast.
79039         close: use gl_REPLACE_FCLOSE only if defined
79040         * m4/close.m4 (gl_REPLACE_CLOSE): Use gl_REPLACE_FCLOSE only if it
79041         is defined.  The close module doesn't depend on the fclose module
79042         any more, so gl_REPLACE_CLOSE's existence cannot be assumed.  See
79043         <http://lists.gnu.org/r/bug-gnulib/2011-07/msg00392.html>.
79044         I reproduced the problem with "./gnulib-tool --test close sys_socket".
79046 2011-07-24  Jim Meyering  <meyering@redhat.com>
79048         test-select.h: avoid warning when using gcc's -Wmissing-declarations
79049         * tests/test-select.h (test_function): Declare as "static".
79051 2011-07-24  Bruno Haible  <bruno@clisp.org>
79053         doc: Mention the effects of AC_SYS_LARGEFILE.
79054         * doc/posix-functions/aio_cancel.texi: Mention the effects of AC_SYS_LARGEFILE
79055         on this function.
79056         * doc/posix-functions/aio_error.texi: Likewise.
79057         * doc/posix-functions/aio_fsync.texi: Likewise.
79058         * doc/posix-functions/aio_read.texi: Likewise.
79059         * doc/posix-functions/aio_return.texi: Likewise.
79060         * doc/posix-functions/aio_suspend.texi: Likewise.
79061         * doc/posix-functions/aio_write.texi: Likewise.
79062         * doc/posix-functions/fgetpos.texi: Likewise.
79063         * doc/posix-functions/fopen.texi: Likewise.
79064         * doc/posix-functions/freopen.texi: Likewise.
79065         * doc/posix-functions/fsetpos.texi: Likewise.
79066         * doc/posix-functions/fstatvfs.texi: Likewise.
79067         * doc/posix-functions/ftruncate.texi: Likewise.
79068         * doc/posix-functions/ftw.texi: Likewise.
79069         * doc/posix-functions/getrlimit.texi: Likewise.
79070         * doc/posix-functions/glob.texi: Likewise.
79071         * doc/posix-functions/lio_listio.texi: Likewise.
79072         * doc/posix-functions/lockf.texi: Likewise.
79073         * doc/posix-functions/mkstemp.texi: Likewise.
79074         * doc/posix-functions/mmap.texi: Likewise.
79075         * doc/posix-functions/nftw.texi: Likewise.
79076         * doc/posix-functions/openat.texi: Likewise.
79077         * doc/posix-functions/opendir.texi: Likewise.
79078         * doc/posix-functions/posix_fadvise.texi: Likewise.
79079         * doc/posix-functions/posix_fallocate.texi: Likewise.
79080         * doc/posix-functions/pread.texi: Likewise.
79081         * doc/posix-functions/pwrite.texi: Likewise.
79082         * doc/posix-functions/readdir.texi: Likewise.
79083         * doc/posix-functions/readdir_r.texi: Likewise.
79084         * doc/posix-functions/rewinddir.texi: Likewise.
79085         * doc/posix-functions/scandir.texi: Likewise.
79086         * doc/posix-functions/seekdir.texi: Likewise.
79087         * doc/posix-functions/setrlimit.texi: Likewise.
79088         * doc/posix-functions/statvfs.texi: Likewise.
79089         * doc/posix-functions/telldir.texi: Likewise.
79090         * doc/posix-functions/tmpfile.texi: Likewise.
79091         * doc/posix-functions/truncate.texi: Likewise.
79092         * doc/glibc-functions/fallocate.texi: Likewise.
79093         * doc/glibc-functions/fstatfs.texi: Likewise.
79094         * doc/glibc-functions/fts_children.texi: Likewise.
79095         * doc/glibc-functions/fts_read.texi: Likewise.
79096         * doc/glibc-functions/getdirentries.texi: Likewise.
79097         * doc/glibc-functions/mkostemp.texi: Likewise.
79098         * doc/glibc-functions/mkostemps.texi: Likewise.
79099         * doc/glibc-functions/mkstemps.texi: Likewise.
79100         * doc/glibc-functions/preadv.texi: Likewise.
79101         * doc/glibc-functions/pwritev.texi: Likewise.
79102         * doc/glibc-functions/sendfile.texi: Likewise.
79103         * doc/glibc-functions/statfs.texi: Likewise.
79105 2011-07-24  Bruno Haible  <bruno@clisp.org>
79107         doc: Fix typo.
79108         * doc/posix-functions/fstat.texi: Talk about fstat, not stat.
79110 2011-07-24  Bruno Haible  <bruno@clisp.org>
79112         doc: Mention fsusage.
79113         * doc/posix-functions/statvfs.texi: Mention the fsusage module.
79115 2011-07-24  Bruno Haible  <bruno@clisp.org>
79117         doc: Mention new glibc headers and functions.
79118         * doc/glibc-headers/gshadow.texi: New file.
79119         * doc/glibc-functions/endsgent.texi: New file.
79120         * doc/glibc-functions/fgetsgent.texi: New file.
79121         * doc/glibc-functions/fgetsgent_r.texi: New file.
79122         * doc/glibc-functions/getsgent.texi: New file.
79123         * doc/glibc-functions/getsgent_r.texi: New file.
79124         * doc/glibc-functions/getsgnam.texi: New file.
79125         * doc/glibc-functions/getsgnam_r.texi: New file.
79126         * doc/glibc-functions/putsgent.texi: New file.
79127         * doc/glibc-functions/setsgent.texi: New file.
79128         * doc/glibc-functions/sgetsgent.texi: New file.
79129         * doc/glibc-functions/sgetsgent_r.texi: New file.
79130         * doc/glibc-functions/malloc_info.texi: New file.
79131         * doc/glibc-functions/preadv.texi: New file.
79132         * doc/glibc-functions/pwritev.texi: New file.
79133         * doc/glibc-functions/register_printf_modifier.texi: New file.
79134         * doc/glibc-functions/register_printf_specifier.texi: New file.
79135         * doc/glibc-functions/register_printf_type.texi: New file.
79136         * doc/glibc-functions/pthread_attr_getaffinity_np.texi: New file.
79137         * doc/glibc-functions/pthread_attr_setaffinity_np.texi: New file.
79138         * doc/glibc-functions/pthread_getaffinity_np.texi: New file.
79139         * doc/glibc-functions/pthread_getname_np.texi: New file.
79140         * doc/glibc-functions/pthread_mutex_consistent_np.texi: New file.
79141         * doc/glibc-functions/pthread_mutexattr_getrobust_np.texi: New file.
79142         * doc/glibc-functions/pthread_mutexattr_setrobust_np.texi: New file.
79143         * doc/glibc-functions/pthread_setaffinity_np.texi: New file.
79144         * doc/glibc-functions/pthread_setname_np.texi: New file.
79145         * doc/glibc-functions/pthread_sigqueue.texi: New file.
79146         * doc/glibc-functions/pthread_timedjoin_np.texi: New file.
79147         * doc/glibc-functions/pthread_tryjoin_np.texi: New file.
79148         * doc/glibc-functions/qsort_r.texi: New file.
79149         * doc/glibc-functions/quick_exit.texi: New file.
79150         * doc/glibc-functions/syncfs.texi: New file.
79151         * doc/gnulib.texi: Include them.
79152         (Glibc gshadow.h, Glibc sys/uio.h): New sections.
79153         * doc/posix-functions/psiginfo.texi: Fix info about glibc version.
79154         * doc/posix-functions/pthread_mutex_consistent.texi: Likewise.
79155         * doc/posix-functions/pthread_mutexattr_getrobust.texi: Likewise.
79156         * doc/posix-functions/pthread_mutexattr_setrobust.texi: Likewise.
79157         * doc/glibc-functions/execvpe.texi: Likewise.
79159 2011-07-24  Paul Eggert  <eggert@cs.ucla.edu>
79161         ftell: don't include <unistd.h>
79162         * lib/ftell.c: Don't include <unistd.h>.  <stdio.h> is now
79163         guaranteed to define off_t, and the ftell module depends on the
79164         stdio module.
79166         ftell: do not assume wraparound signed arithmetic
79167         * lib/ftell.c: Include <limits.h>.
79168         (ftell): Don't assume wraparound signed arithmetic.
79170 2011-07-24  Bruno Haible  <bruno@clisp.org>
79172         close: No longer depend on module 'fclose'.
79173         * modules/close (Depends-on): Remove fclose.
79174         * NEWS: Mention the change.
79175         Suggested by Sam Steingold <sds@gnu.org>.
79177 2011-07-24  Bruno Haible  <bruno@clisp.org>
79179         fsusage: Enable large volume support on AIX >= 5.2.
79180         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): If 'struct statvfs64' has a
79181         larger f_blocks field than 'struct statvfs', define STAT_STATVFS64
79182         instead of STAT_STATVFS.
79183         * lib/fsusage.c (get_fs_usage) [STAT_STATVFS64]: Use statvfs64.
79185         fsusage: Restore previous behaviour on AIX, Cygwin, Interix.
79186         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Enforce a 64-bit struct statvfs
79187         f_blocks field only on MacOS X.
79189         fsusage: Support large volumes on glibc/Hurd, HP-UX, Solaris, MacOS X.
79190         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Require AC_SYS_LARGEFILE.
79191         * modules/fsusage (Depends-on): Add largefile.
79193 2011-07-24  Paul Eggert  <eggert@cs.ucla.edu>
79195         * README: Modernize discussion of signed integers.
79196         Assuming overflow wraparound is no longer safe.
79197         Mention ones' complement and signed magnitude.
79199 2011-07-22  Bruno Haible  <bruno@clisp.org>
79201         select tests, pselect tests: Refactor.
79202         * tests/test-select.h: New file, extracted from tests/test-select.c.
79203         (select_fn): New type.
79204         (test, do_select, do_select_nowait, do_select_wait, test_tty,
79205         test_connect_first, test_accept_first, test_pair, test_socket_pair,
79206         test_pipe): Add my_select argument.
79207         (test_function): Renamed from main. Add my_select argument.
79208         * tests/test-select.c: Move most code to tests/test-select.h. Include
79209         test-select.h.
79210         * modules/select-tests (Files): Add tests/test-select.h.
79211         * tests/test-pselect.c: Include test-select.h instead of test-select.c.
79212         (my_select, main): New functions.
79213         * modules/pselect-tests (Files): Add tests/test-select.h,
79214         tests/macros.h, tests/signature.h.
79215         (Depends-on): Remove select-tests. Add dependencies of test-select.h.
79216         (configure.ac): Check for <sys/wait.h>.
79218 2011-07-22  Bruno Haible  <bruno@clisp.org>
79220         sys_select tests: Check the signature of FD_*.
79221         * tests/test-select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): Move
79222         signature tests from here...
79223         * tests/test-sys_select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): ... to
79224         here.
79225         * modules/sys_select-tests (Files): Add tests/signature.h.
79227 2011-07-22  Paul Eggert  <eggert@cs.ucla.edu>
79229         largefile: new module, replacing large-inode
79230         Pádraig Brady suggested this in <http://debbugs.gnu.org/9140#20>.
79231         * MODULES.html.sh: Add largefile, remove large-inode.
79232         * modules/largefile, m4/largefile.m4: New files.
79233         * modules/large-inode, m4/large-inode.m4: Remove.
79235         fsusage: port to MacOS X 10.7 with 4 TiB file systems
79236         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Reject statvfs
79237         implementations that use only 32 bits to count blocks.
79238         On typical hosts with 1024-byte blocks, this fails with file
79239         systems as small as 4 TiB.  Problem reported by Herb Wartens
79240         <http://debbugs.gnu.org/9140> and this should also fix a similar
79241         problem reported by Tim Spriggs <http://debbugs.gnu.org/7355>.
79243         large-inode: New module
79244         * MODULES.html.sh: Add it.
79245         * modules/large-inode, m4/large-inode.m4: New files.
79247         extensions: Enable extensions on MacOS X 10.5 and later.
79248         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Define _DARWIN_C_SOURCE.
79250 2011-07-22  Kamil Dudka  <kdudka@redhat.com>
79252         file-has-acl: use acl_extended_file_nofollow if available
79253         * lib/acl-internal.h (HAVE_ACL_EXTENDED_FILE): New macro.
79254         (acl_extended_file): New macro.
79255         * lib/file-has-acl.c (file_has_acl): Use acl_extended_file_nofollow.
79256         * m4/acl.m4 (gl_FUNC_ACL): Check for acl_extended_file_nofollow.
79258 2011-07-21  Bruno Haible  <bruno@clisp.org>
79260         Declare system functions in a way that works with C++.
79261         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR) [C++]: In the test program,
79262         declare fdopendir as extern "C".
79263         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS) [C++]: In the test program,
79264         declare frexpl as extern "C".
79265         * m4/getaddrinfo.m4 (gl_GETADDRINFO) [C++]: In the test program,
79266         declare gai_strerror as extern "C".
79267         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME) [C++]: In the test
79268         programs, declare gai_strerror as extern "C".
79269         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R) [C++]: In the test program,
79270         declare getlogin_r as extern "C".
79271         * m4/ioctl.m4 (gl_FUNC_IOCTL) [C++]: In the test program, declare ioctl
79272         as extern "C".
79273         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS) [C++]: In the test program,
79274         declare ldexpl as extern "C".
79275         * m4/logb.m4 (gl_FUNC_LOGB) [C++]: In the test programs, declare logb
79276         as extern "C".
79277         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS) [C++]: In the test
79278         program, declare getmntinfo as extern "C".
79279         * m4/stpncpy.m4 (gl_FUNC_STPNCPY) [C++]: In the test program, declare
79280         stpncpy as extern "C".
79281         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS) [C++]: In the test
79282         program, declare __xpg_strerror_r as extern "C".
79283         * m4/strndup.m4 (gl_FUNC_STRNDUP) [C++]: In the test program, declare
79284         strndup as extern "C".
79285         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT) [C++]: In the test program,
79286         declare memset and bzero as extern "C".
79287         Reported by Sam Steingold <sds@gnu.org>.
79289 2011-07-12  Jim Meyering  <meyering@redhat.com>
79291         maint.mk: prohibit inclusion of "verify.h" without use
79292         * top/maint.mk (sc_prohibit_verify_without_use): New rule.
79294 2011-07-19  Pádraig Brady  <P@draigBrady.com>
79296         timer-time: A new module to check for timer_settime()
79297         * m4/timer_time.m4: Check for the posix function.
79298         * modules/timer-time: Add the new module.
79299         * MODULES.html.sh (Compat checks for POSIX:2008 functions):
79300         Mention it.
79302 2011-07-19  Paul Eggert  <eggert@cs.ucla.edu>
79303             Bruno Haible  <bruno@clisp.org>
79305         pthread_sigmask: assume POSIX threads if --avoid=threadlib
79306         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): If gl_THREADLIB is
79307         not defined, assume POSIX threads and look for pthread_sigmask in
79308         $LIBS, without changing $CPPFLAGS.
79310 2011-07-19  Bruno Haible  <bruno@clisp.org>
79312         strstr: Update cross-compilation guess.
79313         * m4/strstr.m4 (gl_FUNC_STRSTR): On glibc > 2.12 with x86 or x86_64
79314         CPUs, guess no, in view of glibc
79315         BZ #12100 <http://sourceware.org/bugzilla/show_bug.cgi?id=12100>.
79316         Suggested by Eric Blake. Reported by Reuben Thomas.
79318 2011-07-19  Pádraig Brady  <P@draigBrady.com>
79320         getopt-gnu: suppress core dumps from detection code
79321         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Use the nocrash module
79322         to suppress core dumps that may well occur on glibc systems.
79323         * modules/getopt-gnu: Depend on nocrash.
79325 2011-07-16  Paul Eggert  <eggert@cs.ucla.edu>
79327         pthread_sigmask: ensure usleep is declared
79328         * lib/pthread_sigmask.c [PTHREAD_SIGMASK_UNBLOCK_BUG]:
79329         Include <unistd.h>, to declare usleep.  Needed on Solaris 8,
79331 2011-07-15  Paul Eggert  <eggert@cs.ucla.edu>
79333         doc: Document NonStop portability issues.
79334         * doc/posix-functions/sigaction.texi (sigaction):
79335         * doc/posix-headers/signal.texi (signal.h):
79336         Document NonStop.  See Joachim Schmitz in
79337         http://lists.gnu.org/r/bug-coreutils/2011-07/msg00062.html
79339 2011-07-15  Bruno Haible  <bruno@clisp.org>
79341         ffsl, ffsll: Avoid unportable behaviour.
79342         * lib/ffsl.h (FUNC): Use 'unsigned int' instead of 'int'.
79344 2011-07-15  Bruno Haible  <bruno@clisp.org>
79346         ffs: More tests.
79347         * tests/test-ffs.c (NBITS): New macro.
79348         (main): Add more tests.
79349         * tests/test-ffsl.c (NBITS): New macro.
79350         (main): Add more tests.
79351         * tests/test-ffsll.c (NBITS): New macro.
79352         (main): Add more tests.
79354 2011-07-15  Eric Blake  <eblake@redhat.com>
79356         ffsl, ffsll: new modules
79357         * modules/ffsl: New file.
79358         * modules/ffsll: Likewise.
79359         * m4/ffsl.m4: Likewise.
79360         * m4/ffsll.m4: Likewise.
79361         * lib/ffsl.c: Likewise.
79362         * lib/ffsl.h: Likewise.
79363         * lib/ffsll.c: Likewise.
79364         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY)
79365         (gl_HEADER_STRING_H_DEFAULTS): Add defaults.
79366         * modules/string (Makefile.am): Substitute witnesses.
79367         * lib/strings.in.h (ffsl, ffsll): Declare.
79368         * modules/ffsl-tests: New test file.
79369         * modules/ffsll-tests: Likewise.
79370         * tests/test-ffsl.c: Likewise.
79371         * tests/test-ffsll.c: Likewise.
79372         * MODULES.html.sh (Integer arithmetic functions): Mention it.
79373         * doc/glibc-functions/ffsl.texi (ffsl): Likewise.
79374         * doc/glibc-functions/ffsll.texi (ffsll): Likewise.
79376         ffs: fix m4 prerequisite
79377         * m4/ffs.m4 (gl_FUNC_FFS): Require strings.h defaults.
79379         ffs: avoid undefined behavior
79380         * lib/ffs.c (ffs): Provide fallback for non-32-bit int.
79381         * tests/test-ffs.c (naive, main): Avoid signed shifts.
79382         Reported by Bruno Haible.
79384 2011-07-12  Bruno Haible  <bruno@clisp.org>
79386         pthread_sigmask: Rely on module 'threadlib'.
79387         * modules/pthread_sigmask (Depends-on): Add threadlib.
79388         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Assume gl_THREADLIB
79389         is defined.
79391 2011-07-12  Bruno Haible  <bruno@clisp.org>
79393         regex: Depend on module 'strcase'.
79394         * modules/regex (Depends-on): Add strcase, for strcasecmp().
79396 2011-07-12  Jim Meyering  <meyering@redhat.com>
79398         warn-on-use: fix typo in file name
79399         * modules/snippet/warn-on-use (Files): Correct file name:
79400         include /snippet/ component in "build-aux/snippet/warn-on-use.h".
79402 2011-07-12  Bruno Haible  <bruno@clisp.org>
79404         strings: Document module.
79405         * doc/posix-headers/strings.texi: Mention module 'strings'.
79407 2011-07-12  Bruno Haible  <bruno@clisp.org>
79409         Rename module '_Noreturn' to 'snippet/_Noreturn'.
79410         * modules/snippet/_Noreturn: Renamed from modules/_Noreturn.
79411         (Files, Makefile.am): Update.
79412         * build-aux/snippet/_Noreturn.h: Renamed from build-aux/_Noreturn.h.
79413         * modules/stdlib (Depends-on): Update.
79415 2011-07-12  Bruno Haible  <bruno@clisp.org>
79417         * NEWS: Mention the changes.
79419         Rename module 'warn-on-use' to 'snippet/warn-on-use'.
79420         * modules/snippet/warn-on-use: Renamed from modules/warn-on-use.
79421         (Files, Makefile.am): Update.
79422         * build-aux/snippet/warn-on-use.h: Renamed from build-aux/warn-on-use.h.
79423         * modules/arpa_inet (Depends-on): Update.
79424         * modules/ctype (Depends-on): Update.
79425         * modules/dirent (Depends-on): Update.
79426         * modules/fcntl-h (Depends-on): Update.
79427         * modules/glob (Depends-on): Update.
79428         * modules/iconv-h (Depends-on): Update.
79429         * modules/inttypes-incomplete (Depends-on): Update.
79430         * modules/langinfo (Depends-on): Update.
79431         * modules/locale (Depends-on): Update.
79432         * modules/math (Depends-on): Update.
79433         * modules/netdb (Depends-on): Update.
79434         * modules/poll-h (Depends-on): Update.
79435         * modules/pty (Depends-on): Update.
79436         * modules/search (Depends-on): Update.
79437         * modules/signal (Depends-on): Update.
79438         * modules/spawn (Depends-on): Update.
79439         * modules/stdio (Depends-on): Update.
79440         * modules/stdlib (Depends-on): Update.
79441         * modules/string (Depends-on): Update.
79442         * modules/strings (Depends-on): Update.
79443         * modules/sys_file (Depends-on): Update.
79444         * modules/sys_ioctl (Depends-on): Update.
79445         * modules/sys_select (Depends-on): Update.
79446         * modules/sys_socket (Depends-on): Update.
79447         * modules/sys_stat (Depends-on): Update.
79448         * modules/sys_time (Depends-on): Update.
79449         * modules/sys_times (Depends-on): Update.
79450         * modules/sys_utsname (Depends-on): Update.
79451         * modules/sys_wait (Depends-on): Update.
79452         * modules/termios (Depends-on): Update.
79453         * modules/time (Depends-on): Update.
79454         * modules/unistd (Depends-on): Update.
79455         * modules/wchar (Depends-on): Update.
79456         * modules/wctype-h (Depends-on): Update.
79457         * MODULES.html.sh (Support for building libraries and executables):
79458         Update.
79460         Rename module 'unused-parameter' to 'snippet/unused-parameter'.
79461         * modules/snippet/unused-parameter: Renamed from
79462         modules/unused-parameter.
79463         (Files, Makefile.am): Update.
79464         * build-aux/snippet/unused-parameter.h: Renamed from
79465         build-aux/unused-parameter.h.
79466         * modules/selinux-h (Depends-on): Update.
79467         * modules/unistr/base (Depends-on): Update.
79468         * MODULES.html.sh (Core language properties): Update.
79470         Rename module 'link-warning' to 'snippet/link-warning'.
79471         * modules/snippet/link-warning: Renamed from modules/link-warning.
79472         (Files, Makefile.am): Update.
79473         * build-aux/snippet/link-warning.h: Renamed from
79474         build-aux/link-warning.h.
79475         * MODULES.html.sh (Support for building libraries and executables):
79476         Update.
79478         Rename module 'c++defs' to 'snippet/c++defs'.
79479         * modules/snippet/c++defs: Renamed from modules/c++defs.
79480         (Files, Makefile.am): Update.
79481         * build-aux/snippet/c++defs.h: Renamed from build-aux/c++defs.h.
79482         * modules/arpa_inet (Depends-on): Update.
79483         * modules/ctype (Depends-on): Update.
79484         * modules/dirent (Depends-on): Update.
79485         * modules/fcntl-h (Depends-on): Update.
79486         * modules/glob (Depends-on): Update.
79487         * modules/iconv-h (Depends-on): Update.
79488         * modules/langinfo (Depends-on): Update.
79489         * modules/locale (Depends-on): Update.
79490         * modules/math (Depends-on): Update.
79491         * modules/netdb (Depends-on): Update.
79492         * modules/poll-h (Depends-on): Update.
79493         * modules/pty (Depends-on): Update.
79494         * modules/search (Depends-on): Update.
79495         * modules/signal (Depends-on): Update.
79496         * modules/spawn (Depends-on): Update.
79497         * modules/stdio (Depends-on): Update.
79498         * modules/stdlib (Depends-on): Update.
79499         * modules/string (Depends-on): Update.
79500         * modules/strings (Depends-on): Update.
79501         * modules/sys_ioctl (Depends-on): Update.
79502         * modules/sys_select (Depends-on): Update.
79503         * modules/sys_socket (Depends-on): Update.
79504         * modules/sys_stat (Depends-on): Update.
79505         * modules/sys_time (Depends-on): Update.
79506         * modules/sys_wait (Depends-on): Update.
79507         * modules/termios (Depends-on): Update.
79508         * modules/time (Depends-on): Update.
79509         * modules/unistd (Depends-on): Update.
79510         * modules/wchar (Depends-on): Update.
79511         * modules/wctype-h (Depends-on): Update.
79513         Rename module 'arg-nonnull' to 'snippet/arg-nonnull'.
79514         * modules/snippet/arg-nonnull: Renamed from modules/arg-nonnull.
79515         (Files, Makefile.am): Update.
79516         * build-aux/snippet/arg-nonnull.h: Renamed from build-aux/arg-nonnull.h.
79517         * modules/argv-iter (Depends-on): Update.
79518         * modules/arpa_inet (Depends-on): Update.
79519         * modules/dirent (Depends-on): Update.
79520         * modules/fcntl-h (Depends-on): Update.
79521         * modules/fnmatch (Depends-on): Update.
79522         * modules/getopt-posix (Depends-on): Update.
79523         * modules/glob (Depends-on): Update.
79524         * modules/iconv-h (Depends-on): Update.
79525         * modules/inttypes-incomplete (Depends-on): Update.
79526         * modules/locale (Depends-on): Update.
79527         * modules/math (Depends-on): Update.
79528         * modules/netdb (Depends-on): Update.
79529         * modules/search (Depends-on): Update.
79530         * modules/signal (Depends-on): Update.
79531         * modules/spawn (Depends-on): Update.
79532         * modules/stdio (Depends-on): Update.
79533         * modules/stdlib (Depends-on): Update.
79534         * modules/string (Depends-on): Update.
79535         * modules/strings (Depends-on): Update.
79536         * modules/sys_socket (Depends-on): Update.
79537         * modules/sys_stat (Depends-on): Update.
79538         * modules/sys_time (Depends-on): Update.
79539         * modules/sys_times (Depends-on): Update.
79540         * modules/sys_utsname (Depends-on): Update.
79541         * modules/time (Depends-on): Update.
79542         * modules/unistd (Depends-on): Update.
79543         * modules/wchar (Depends-on): Update.
79544         * MODULES.html.sh (Support for building libraries and executables):
79545         Update.
79547 2011-07-12  Paul Eggert  <eggert@cs.ucla.edu>
79549         Improvements on _Noreturn and related modules.
79551         modules/_Exit-tests: test _Noreturn too
79552         * tests/test-_Exit.c (MTA, Charlie): New functions, taken from the
79553         old tests/test-stdnoreturn.c.  This tests the _Noreturn keyword a bit.
79554         (main): Use them.
79556         stdnoreturn, stdnoreturn-tests: remove modules
79557         They're not needed here and a bit premature for use elsewhere.  See
79558         <http://lists.gnu.org/r/bug-gnulib/2011-07/msg00209.html>.
79559         * m4/stdnoreturn.m4, modules/stdnoreturn, modules/stdnoreturn-tests:
79560         * tests/test-stdnoreturn.c: Remove files.
79561         * MODULES.html.sh (_Noreturn <stdnoreturn.h>): Remove section.
79562         * lib/openat.h, lib/sigpipe-die.h, lib/xalloc.h, lib/xmemdup0.h:
79563         * lib/xstrtol.h: Use _Noreturn rather than including <stdnoreturn.h>
79564         and using noreturn.
79565         * modules/openat, modules/sigpipe-die, modules/xalloc:
79566         * modules/xmemdup0, modules/xstrtol:
79567         Remove dependency on stdnoreturn.
79569         _Noreturn: Ignore __STDC_VERSION__; observe _MSC_VER.
79570         * build-aux/_Noreturn.h (_Noreturn): Ignore __STDC_VERSION__.
79571         Reparenthesize to avoid GCC warning.
79572         Support Microsoft's syntax.
79573         * m4/gnulib-common.m4 (gl_COMMON_BODY): Likewise.
79575         _Noreturn-tests: remove module
79576         * modules/_Noreturn-tests: Remove.
79577         * modules/stdnoreturn-tests (Files): Remove tests/test-_Noreturn.c.
79578         * tests/test-_Noreturn.c: Remove.
79579         * tests/test-stdnoreturn.c: Merge from the old
79580         tests/test-_Noreturn.c, testing both noreturn and _Noreturn.
79582 2011-07-12  Paul Eggert  <eggert@cs.ucla.edu>
79584         _Noreturn, stdnoreturn, and related modules.
79586         * top/maint.mk: Adjust to new noreturn support.
79587         (gl_extract_significant_defines_): Omit pattern ATTRIBUTE_NORETURN.
79588         (def_sym_regex): Do not remove ATTRIBUTE_NORETURN.
79590         xalloc: use stdnoreturn.h
79591         * lib/xalloc.h: Include <stdnoreturn.h>.
79592         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
79593         * modules/xalloc (Depends-on): Add stdnoreturn.
79595         xstrtol: use stdnoreturn.h
79596         * lib/xstrtol.h: Include <stdnoreturn.h>.
79597         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
79598         * modules/xstrtol (Depends-on): Add stdnoreturn.
79600         xmemdup0: use stdnoreturn.h
79601         * lib/xmemdup0.h: Include <stdnoreturn.h>.
79602         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
79603         * modules/xmemdup0 (Depends-on): Add stdnoreturn.
79605         sigpipe-die: use stdnoreturn.h
79606         * lib/sigpipe-die.h: Include <stdnoreturn.h>.
79607         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
79608         * modules/sigpipe-die (Depends-on): Add stdnoreturn.
79610         openat: use stdnoreturn.h
79611         * lib/openat.h: Include <stdnoreturn.h>.
79612         (_GL_ATTRIBUTE_NORETURN): Remove; all uses replaced with noreturn.
79613         * modules/openat (Depends-on): Add stdnoreturn.
79615         * lib/openat-die.c (openat_save_fail): Modernize comment.
79617         * lib/xalloc-die.c (xalloc_die): Modernize comment.
79619         * lib/glthread/thread.h: Modernize comment.
79621         obstack: use _Noreturn
79622         * lib/obstack.c (__attribute__): Remove macro.
79623         (print_and_abort): Use _Noreturn.
79625         c-stack: use _Noreturn
79626         * lib/c-stack.c (die, overflow_handler, segv_handler):
79627         Use _Noreturn rather than __attribute__((noreturn)).
79629         argmatch-tests, exclude_tests: use _Noreturn
79630         * tests/test-argmatch.c, tests/test-exclude.c (_GL_ATTRIBUTE_NORETURN):
79631         Remove.
79632         (ARGMATCH_DIE_DECL): Use _Noreturn instead.
79634         stdlib: use _Noreturn
79635         * lib/stdlib.in.h (_GL_ATTRIBUTE_NORETURN): Remove.
79636         (_Exit): Use _Noreturn rather than _GL_ATTRIBUTE_NORETURN.
79637         * modules/stdlib (Depends-on): Add _Noreturn.
79638         (stdlib.h): Depend on $(_NORETURN_H), and copy it in.
79640         stdnoreturn-tests: new module
79641         * modules/stdnoreturn-tests, tests/test-stdnoreturn.c: New files.
79643         stdnoreturn: new module
79644         * MODULES.html.sh (Noreturn <stdnoreturn.h>): New section.
79645         * m4/stdnoreturn.m4, modules/stdnoreturn: New files.
79647         _Noreturn-tests: new module
79648         * modules/_Noreturn-tests, tests/test-_Noreturn.c: New files.
79650         _Noreturn: new module
79651         * MODULES.html.sh (Support for systems lacking draft ISO C 1X):
79652         New section, mentioning it.
79653         * build-aux/_Noreturn.h, modules/_Noreturn: New files.
79655         * m4/gnulib-common.m4 (gl_COMMON_BODY): Add _Noreturn.
79657 2011-07-11  Eric Blake  <eblake@redhat.com>
79659         ffs: new module
79660         * modules/ffs: New file.
79661         * m4/ffs.m4: Likewise.
79662         * lib/ffs.c: Likewise.
79663         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_DEFAULTS): Add default.
79664         * modules/strings (Makefile.am): Substitute witness.
79665         (Depends-on): Add c++defs.
79666         * lib/strings.in.h (ffs): Declare.
79667         * modules/ffs-tests: New test file.
79668         * tests/test-ffs.c: Test new module.
79669         * MODULES.html.sh (Integer arithmetic functions): Mention it.
79670         * doc/posix-functions/ffs.texi (ffs): Likewise.
79672         regex: avoid compiler warning
79673         * lib/regex.c (includes): Include <strings.h>, for use of
79674         strcasecmp in regcomp.c.
79675         Reported by Joachim Schmitz.
79677 2011-07-09  Paul Eggert  <eggert@cs.ucla.edu>
79679         stdint: respect system's intmax_t if INTMAX_MAX
79680         * lib/stdint.in.h (intmax_t, uintmax_t): If the system defines
79681         INTMAX_MAX, assume its intmax_t is OK.  Similarly for and
79682         uintmax_t.  This is for some Mac OS X builds, where intmax_t is
79683         long but int64_t is long long, and where we will clash with the
79684         system intmax_t if we override it.  See
79685         <http://lists.gnu.org/r/bug-gnulib/2011-07/msg00160.html>.
79686         (INTMAX_C, UINTMAX_C): For consistency, respect the system's
79687         INTMAX_C if INTMAX_MAX and INTMAX_C are both defined, and
79688         similarly for UINTMAX_C.
79690 2011-07-08  Bruno Haible  <bruno@clisp.org>
79692         pthread_sigmask tests: Avoid a compiler warning.
79693         * tests/test-pthread_sigmask1.c (main): Complain if system() returns
79694         non-zero.
79696         sigprocmask tests: A better way to avoid a compiler warning.
79697         * tests/test-sigprocmask.c: Don't include "ignore-value.h".
79698         (main): Complain if system() returns non-zero.
79699         * modules/sigprocmask-tests (Depends-on): Remove ignore-value.
79701 2011-07-08  Bruno Haible  <bruno@clisp.org>
79703         pthread_sigmask: Work around IRIX bug.
79704         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test for the IRIX
79705         bug.
79706         * lib/pthread_sigmask.c (pthread_sigmask): usleep for some time when
79707         there may be unblocked pending signals.
79708         * doc/posix-functions/pthread_sigmask.texi: Mention the IRIX bug.
79710 2011-07-08  Bruno Haible  <bruno@clisp.org>
79712         pthread_sigmask: Work around Cygwin bug.
79713         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test for the Cygwin
79714         bug.
79715         * lib/pthread_sigmask.c (pthread_sigmask): Fix the return value from
79716         the system's pthread_sigmask function.
79717         * doc/posix-functions/pthread_sigmask.texi: Mention the Cygwin bug.
79719 2011-07-08  Bruno Haible  <bruno@clisp.org>
79721         pthread_sigmask: Work around bug in single-threaded implementation.
79722         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Test for the
79723         FreeBSD, HP-UX, Solaris bug.
79724         (gl_PREREQ_PTHREAD_SIGMASK): New macro.
79725         * lib/pthread_sigmask.c: Include <stddef.h>.
79726         (pthread_sigmask): If HAVE_PTHREAD_SIGMASK, define as a wrapper around
79727         the system's pthread_sigmask function.
79728         * modules/pthread_sigmask (configure.ac): Invoke
79729         gl_PREREQ_PTHREAD_SIGMASK.
79730         * doc/posix-functions/pthread_sigmask.texi: Mention bug on FreeBSD,
79731         HP-UX, Solaris.
79733 2011-07-08  Eric Blake  <eblake@redhat.com>
79735         test-sigprocmask: avoid compiler warning
79736         * modules/sigprocmask-tests (Depends-on): Add ignore-value.
79737         * tests/test-sigprocmask.c (main): Use it to silence warning.
79738         Reported by Jim Meyering.
79740         test-snprintf: avoid compiler warning
79741         * tests/test-snprintf.c (main): Avoid shadowed declaration.
79742         * tests/test-vsnprintf.c (main): Likewise.
79743         Reported by Jim Meyering.
79745 2011-07-08  Bruno Haible  <bruno@clisp.org>
79747         Tests for module 'pthread_sigmask'.
79748         * modules/pthread_sigmask-tests: New file.
79749         * tests/test-pthread_sigmask1.c: New file, based on
79750         tests/test-sigprocmask.c.
79751         * tests/test-pthread_sigmask2.c: New file.
79753 2011-07-08  Jim Meyering  <meyering@redhat.com>
79755         test-getopt.h: avoid warning about an unused variable
79756         * tests/test-getopt.h (test_getopt): Remove unused variable, "c".
79758 2011-07-07  Jim Meyering  <meyering@redhat.com>
79760         maint: reduce list of files exempt from sc_prohibit_leading_TABs
79761         * Makefile (sc_prohibit_leading_TABs): Don't exempt m4/po.m4,
79762         now that it no longer contains leading TABs.
79763         Remove unused "url=FIXME" statement.
79765 2011-07-08  Paul Eggert  <eggert@cs.ucla.edu>
79767         pthread_sigmask: Assume POSIX when not gl_THREADLIB.
79768         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
79769         When gl_THREADLIB is not in use, assume that the POSIX sematics
79770         are desired.  This is better for Emacs, which uses POSIX semantics
79771         on GNUish and/or POSIXish platforms, and does not use threads at
79772         all otherwise.
79774         pthread_sigmask: fix typo when testing for libraries
79775         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK):
79776         AC_LINK_IFELSE, not AC_COMPILE_IFELSE.
79778 2011-07-08  Eric Blake  <eblake@redhat.com>
79780         fts: introduce FTS_NOATIME
79781         * lib/fts_.h (FTS_NOATIME): New bit flag.
79782         (FTS_OPTIONMASK): Adjust.
79783         * lib/fts.c (diropen, fts_open, fts_build): Honor it.
79784         (fd_ring_check): Debug code unconditionally uses O_NOATIME.
79786 2011-07-08  Bruno Haible  <bruno@clisp.org>
79788         Tests for module 'thread'.
79789         * modules/thread-tests: New file.
79790         * tests/test-thread_self.c: New file.
79791         * tests/test-thread_create.cc: New file.
79793 2011-07-08  Bruno Haible  <bruno@clisp.org>
79795         thread: Avoid gcc warnings when using gl_thread_self().
79796         * lib/glthread/thread.h (gl_thread_self): Return a pthread_t, not a
79797         'void *'.
79798         (gl_thread_self_pointer): Update.
79800 2011-07-07  Bruno Haible  <bruno@clisp.org>
79802         signal-c++-tests: Check declaration of pthread_sigmask.
79803         * tests/test-signal-c++.cc: Check declaration of pthread_sigmask.
79804         * modules/signal-c++-tests (Makefile.am): Link test-signal-c++ against
79805         $(LIB_PTHREAD_SIGMASK).
79807 2011-07-07  Bruno Haible  <bruno@clisp.org>
79809         pthread_sigmask: Fix link requirements on OSF/1 5.1 and with pth.
79810         * lib/signal.in.h (pthread_sigmask): Override if
79811         REPLACE_PTHREAD_SIGMASK is 1.
79812         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
79813         REPLACE_PTHREAD_SIGMASK.
79814         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Set also
79815         REPLACE_PTHREAD_SIGMASK. Set and substitute LIB_PTHREAD_SIGMASK.
79816         * modules/signal (Makefile.am): Substitute REPLACE_PTHREAD_SIGMASK.
79817         * modules/pthread_sigmask (Depends-on, configure.ac): Update condition.
79818         (Link): Set to $(LIB_PTHREAD_SIGMASK), not $(LIBMULTITHREAD).
79820 2011-07-07  Bruno Haible  <bruno@clisp.org>
79822         pthread_sigmask: Ensure declaration in <signal.h>.
79823         * lib/signal.in.h: On MacOS X, FreeBSD, OpenBSD, OSF/1, Solaris 2.6,
79824         include <pthread.h>.
79825         * doc/posix-functions/pthread_sigmask.texi: Mention the header file
79826         problem.
79828 2011-07-07  Bruno Haible  <bruno@clisp.org>
79830         pthread_sigmask: Document the module.
79831         * doc/posix-functions/pthread_sigmask.texi: Mention the new module.
79833 2011-07-07  Bruno Haible  <bruno@clisp.org>
79835         pthread_sigmask: Follow gnulib conventions.
79836         * m4/pthread_sigmask.m4 (gl_FUNC_PTHREAD_SIGMASK): Renamed from
79837         gl_PTHREAD_SIGMASK.
79838         * modules/pthread_sigmask (configure.ac): Update.
79840 2011-07-07  Bruno Haible  <bruno@clisp.org>
79842         pthread_sigmask: Make declaration C++ safe.
79843         * lib/signal.in.h: In two special conditions, just do an #include_next.
79844         (pthread_sigmask): Test HAVE_PTHREAD_SIGMASK, not REPLACE_PTHREAD_MASK.
79845         Invoke _GL_CXXALIAS_SYS and _GL_CXXALIASWARN.
79846         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
79847         HAVE_PTHREAD_SIGMASK, not REPLACE_PTHREAD_MASK.
79848         * m4/pthread_sigmask.m4 (gl_PTHREAD_SIGMASK): Set HAVE_PTHREAD_SIGMASK,
79849         not REPLACE_PTHREAD_MASK.
79850         * modules/signal (Makefile.am): Substitute HAVE_PTHREAD_SIGMASK,
79851         not REPLACE_PTHREAD_MASK.
79852         * modules/pthread_sigmask (Depends-on, configure.ac): Update condition.
79854 2011-07-07  Bruno Haible  <bruno@clisp.org>
79856         pthread_sigmask: Fix return value.
79857         * lib/signal.in.h (pthread_sigmask): Declare. Don't define as a macro.
79858         * lib/pthread_sigmask.c: New file.
79859         * modules/pthread_sigmask (Files): Add it.
79860         (configure.ac): Invoke AC_LIBOBJ.
79862 2011-07-07  Eric Blake  <eblake@redhat.com>
79864         getopt: more portable argv creation
79865         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADRS): Rather than casting away
79866         const, use char arrays rather than strings.
79867         Suggested by Paul Eggert.
79869 2011-07-07  Bruno Haible  <bruno@clisp.org>
79871         Tests for module 'sigprocmask'.
79872         * modules/sigprocmask-tests: New file.
79873         * tests/test-sigprocmask.c: New file.
79875 2011-07-07  Bruno Haible  <bruno@clisp.org>
79877         float tests: Tweak.
79878         * tests/test-float.c (main): Tweak skip message.
79880 2011-07-07  Eric Blake  <eblake@redhat.com>
79882         getopt: avoid compiler warning during configure
79883         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADRS): Avoid problems with
79884         assigning string literals to non-const pointer.
79886         getopt-gnu: avoid crash in glibc getopt
79887         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADRS): Detect the problem.
79888         * tests/test-getopt.h (test_getopt): Enhance test.
79889         * tests/test-getopt_long.h (test_getopt_long): Likewise.
79890         * doc/posix-functions/getopt.texi (getopt): Document it.
79891         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
79892         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
79893         Likewise.
79895 2011-07-07  Ulrich Drepper  <drepper@gmail.com>
79897         getopt: handle W; without long options in getopt [BZ #12922]
79898         * lib/getopt.c (_getopt_internal_r): When "W;" is in short options
79899         but no long options are defined, just return 'W'.
79901 2011-07-07  Bruno Haible  <bruno@clisp.org>
79903         Avoid literal tabs.
79904         * m4/po,m4 (AM_PO_SUBDIRS, AM_POSTPROCESS_PO_MAKEFILE): Use a shell
79905         variable containing a tab instead of a literal tab.
79906         Reported by Jim Meyering.
79908 2011-07-07  Bruno Haible  <bruno@clisp.org>
79910         Comments.
79911         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Update comments about mingw.
79913 2011-07-06  Bruno Haible  <bruno@clisp.org>
79915         sys_select: Fix compilation error on mingw, introduced on 2011-06-30.
79916         * lib/sys_select.in.h: Don't include <sys/socket.h>. Instead, include
79917         <winsock2.h>.
79918         (rpl_fd_isset, FD_ISSET): New definitions, copied from
79919         lib/sys_socket.in.h.
79920         (close, gethostname): Hide declarations from <winsock2.h>.
79921         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
79922         listen, recv, send, recvfrom, sendto, setsockopt, shutdown): Likewise.
79923         * lib/sys_socket.in.h (close, gethostname): Tweak indentation.
79924         (select): Don't override if gnulib's <sys/select.h> was already
79925         included.
79926         * lib/unistd.in.h (socket, connect, accept, bind, getpeername,
79927         getsockname, getsockopt, listen, recv, send, recvfrom, sendto,
79928         setsockopt, shutdown, select): Tweak indentation.
79930 2011-07-06  Paul Eggert  <eggert@cs.ucla.edu>
79932         * modules/pthread_sigmask (configure.ac): gl_SIGNAL_MODULE_INDICATOR
79933         and not gl_SYS_SELECT_MODULE_INDICATOR, fixing a typo exposed
79934         in an application that does not use the sys_select module.
79936 2011-07-06  Erik Faye-Lund  <kusmabite@gmail.com>
79938         poll: do not return 0 on timeout=-1
79939         * lib/poll.c: Loop with yield if no events occurred.
79941 2011-07-06  Eric Blake  <eblake@redhat.com>
79943         pthread_sigmask: always replace when not using pthread
79944         * m4/pthread_sigmask.m4 (gl_PTHREAD_SIGMASK): Force sigprocmask
79945         replacement when using some threading other than pthread.  Fix
79946         logic bug.
79948 2011-07-06  Bruno Haible  <bruno@clisp.org>
79950         Comments.
79951         * m4/printf.m4: Update comments about mingw.
79953 2011-07-06  Paul Eggert  <eggert@cs.ucla.edu>
79955         sys_select: define sigset_t more portably
79956         * lib/sys_select.in.h: Always include <sys/types.h>, since
79957         we now need sigset_t and mingw defines it there.
79958         Include <signal.h> before split inclusion guard, to avoid
79959         mishaps on Solaris, whose <signal.h> eventually includes us.
79960         * m4/signal_h.m4 (gl_SIGNAL_H): Require gl_CHECK_TYPE_SIGSET_T.
79961         (gl_CHECK_TYPE_SIGSET_T): New macro, most of the contents of
79962         which come from ...
79963         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
79964         gl_CHECK_TYPE_SIGSET_T.
79965         (gl_PREREQ_SIGPROCMASK): Now a no-op, since gl_CHECK_TYPE_SIGSET_T
79966         does the real work.
79967         * modules/sys_select (Depends-on): Add 'signal'.
79969         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Poison pselect.
79970         Suggested by Bruno Haible.
79972         pselect: Use pthread_sigmask, not sigprocmask.
79973         * lib/pselect.c (pselect): Use pthread_sigmask, as it supports
79974         multithreaded apps better than sigprocmask does.
79975         * modules/pselect (Depends-on): Depend on pthread_sigmask, not
79976         sigprocmask directly.
79978 2011-07-05  Paul Eggert  <eggert@cs.ucla.edu>
79980         * lib/pselect.c (pselect): Use plain name, without "rpl_".
79981         Don't #undef,  since we don't need any underlying pselect.
79982         * modules/pselect (configure.ac): Use our pselect.o if !HAVE_PSELECT.
79983         (Depends-on): Add select.
79984         (Link): Add $(LIBSOCKET).
79985         These changes suggested by Bruno Haible.
79987         pselect: document better
79988         * MODULES.html.sh (Support for systems lacking POSIX:2008): Add it.
79989         * doc/posix-functions/pselect.texi (pselect): Document new module.
79991         pthread_sigmask: new module
79992         * MODULES.html.sh (Support for systems lacking POSIX:2008): Add it.
79993         * doc/posix-functions/pthread_sigmask.texi: Document new module.
79994         * lib/signal.in.h (pthread_sigmask): Arrange for replacement.
79995         This is done only as a macro; I don't know how well that'll
79996         work for C++.  Move <sys/types.h> include before the include_next,
79997         to avoid mishap on Solaris.
79998         * m4/signal_h.m4 (gl_SIGNAL_H, gl_SIGNAL_H_DEFAULTS): Check for it.
79999         * modules/signal (Makefile.am): Substitute the check's results.
80000         * modules/pthread_sigmask, m4/pthread_sigmask.m4: New files.
80002         test-pselect: new module
80003         * modules/pselect-tests, tests/test-pselect.c: New files.
80004         * tests/test-select.c, tests/test-sys_select-c++.cc:
80005         If TEST_PSELECT is defined, test pselect instead of testing select.
80007         * tests/test-sys_select.c (sigset_t): Test for it, too.
80008         Suggested by Bruno Haible.
80010 2011-07-05  Eric Blake  <eblake@redhat.com>
80012         snprintf: guarantee %1$d, for libintl
80013         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require %1$d support.
80014         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Likewise.
80015         * doc/posix-functions/snprintf.texi (snprintf): Update.
80016         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
80017         * tests/test-snprintf.c (main): Enhance test.
80018         * tests/test-vsnprintf.c (main): Likewise.
80020 2011-07-05  Jim Meyering  <meyering@redhat.com>
80022         maint: exempt stdio-read.c and stdio-write.c from the cppi check
80023         * Makefile (sc_cpp_indent_check): Exempt stdio-read.c and stdio-write.c
80024         per Bruno's request, to accommodate this idiom (no space after "#")
80025         even when the function is inside an #if block:
80026         char *
80027         gets (char *s)
80028         #undef gets
80029         {
80030           ...
80031         }
80033 2011-07-04  Jim Meyering  <meyering@redhat.com>
80035         maint: indent with spaces, not TABs, and add a rule to check this
80036         * tests/test-userspec.c: Indent with spaces, not TABs.
80037         * tests/test-argp.c: Likewise.
80038         * tests/test-c-stack2.sh: Likewise.
80039         * tests/test-parse-duration.sh: Likewise
80040         * m4/strtod.m4: Likewise.
80041         * m4/alloca.m4: Likewise.
80042         * m4/pselect.m4: Likewise.
80043         * Makefile (sc_prohibit_leading_TABs): Prohibit leading TABs.
80045 2011-07-03  Jim Meyering  <meyering@redhat.com>
80047         maint.mk: correct omissions in prohibit_argmatch_without_use check
80048         This rule would mistakenly report that argmatch.h is included without
80049         use even when both the argmatch and invalid_arg macro were used.
80050         * top/maint.mk (sc_prohibit_argmatch_without_use): Also detect uses
80051         of argmatch and invalid_arg.
80053 2011-07-03  Bruno Haible  <bruno@clisp.org>
80055         Comments about EINTR.
80056         * lib/safe-read.h: Explain the purpose of this module.
80057         * lib/safe-write.h: Likewise.
80058         * doc/posix-functions/read.texi: Mention EINTR and the 'safe-read'
80059         module.
80060         * doc/posix-functions/write.texi: Mention EINTR and the 'safe-write'
80061         module.
80062         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
80064 2011-06-30  Paul Eggert  <eggert@cs.ucla.edu>
80066         xnanosleep: Rewrite to use new dtotimespec module.
80067         It has the conversion code that used to be in xnanosleep.
80068         * lib/xnanosleep.c: Do not include limits.h, stdbool.h, stdio.h,
80069         assert.h, sys/types.h, or intprops.h.  Include timespec.h instead.
80070         (TIME_T_MAX): Remove.
80071         (xnanosleep): Rewrite in terms of dtotimespec.
80072         * modules/xnanosleep (Depends-on): Add dtotimespec.
80073         Remove intprops, stdbool.
80075         timespec-add, timespec-sub: new modules
80076         * lib/timespec.h (timespec_add, timespec_sub): New decls.
80077         * lib/timespec-add.c, lib/timespec-sub.c:
80078         * modules/timespec-add, modules/timespec-sub: New files.
80080         dtotimespec: new module
80081         * lib/timespec.h (dtotimespec): New decl.
80082         * lib/dtotimespec.c, modules/dtotimespec: New files.
80084         * lib/timespec.h (timespec_sign, timespectod): New inline functions.
80086         pselect: new module
80087         * lib/sys_select.in.h: Include <signal.h>, for 'sigset_t'.
80088         (pselect): New decls.
80089         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Require AC_C_RESTRICT,
80090         since the standard pselect decl uses 'restrict'.
80091         (gl_SYS_SELECT_H_DEFAULTS): Add defaults for GNULIB_PSELECT,
80092         HAVE_PSELECT, REPLACE_PSELECT.
80093         * modules/sys_select (sys/select.h): Substitute GNULIB_PSELECT,
80094         HAVE_PSELECT, REPLACE_PSELECT.
80095         * lib/pselect.c, m4/pselect.m4, modules/pselect: New files.
80097         sys_select: don't depend on sys_socket
80098         This is so that Emacs doesn't have to drag in m4/sockpfaf.m4 etc; see
80099         <http://lists.gnu.org/r/bug-gnulib/2011-06/msg00358.html>.
80100         This fix works on GNU and GNU-like platforms, but has not been tested
80101         on native Windows.
80102         * lib/sys_select.in.h: Include <sys/socket.h> only if native Windows.
80103         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Do not require
80104         gl_HEADER_SYS_SOCKET.
80105         * modules/sys_select (Files): Add m4/sys_socket_h.m4, for
80106         gl_PREREQ_SYS_H_WINSOCK2.
80108 2011-06-29  Eric Blake  <eblake@redhat.com>
80110         pipe2: fix C89 compile problem
80111         * lib/pipe2.c (pipe2): Avoid C99 array initialization.
80112         Reported by Bruno Haible.
80114         pipe, pipe2: don't corrupt fd on error
80115         * lib/pipe.c (pipe): Leave fd unchanged on error.
80116         * lib/pipe2.c (pipe2): Likewise.
80117         * doc/posix-functions/pipe.texi (pipe): Document cygwin issue.
80118         * doc/glibc-functions/pipe2.texi (pipe2): Likewise.
80120 2011-06-27  Paolo Bonzini  <bonzini@gnu.org>
80122         mmap-anon: do not use regular expressions inadvertently
80123         * m4/mmap-anon.m4: Remove trailing period from strings sought
80124         in the output.
80126 2011-06-25  Paul Eggert  <eggert@cs.ucla.edu>
80128         nanosleep: fix integer overflow problem
80129         * lib/nanosleep.c (my_usleep): Don't assume signed integer
80130         arithmetic wraps around on overflow.
80132         nanosleep: simplify carrying
80133         * lib/nanosleep.c (nanosleep): Use the requested tv_nsec for the
80134         first call to the underyling nanosleep, not for the last one.
80135         This doesn't fix any bugs, but it simplifies the computation of
80136         the remaining delay.  Found while auditing integer overflow issues.
80138         dup2: remove test for existence of fcntl
80139         * m4/dup2.m4 (gl_FUNC_DUP2): Use "#ifdef FD_CLOEXEC", not
80140         "#if HAVE_FCNTL", in the configure-time test program.
80141         This removes the need for the AC_CHECK_FUNCS_ONCE([fcntl]),
80142         and therefore speeds up "configure" a bit.  Found while
80143         adding the dup2 module to Emacs.
80145 2011-06-24  Eric Blake  <eblake@redhat.com>
80147         maint.mk: enhance useless header checks
80148         * top/maint.mk (_sc_header_without_use): Check both include
80149         styles.
80150         (sc_prohibit_assert_without_use)
80151         (sc_prohibit_close_stream_without_use)
80152         (sc_prohibit_getopt_without_use)
80153         (sc_prohibit_quotearg_without_use)
80154         (sc_prohibit_quote_without_use)
80155         (sc_prohibit_long_options_without_use)
80156         (sc_prohibit_inttostr_without_use)
80157         (sc_prohibit_ignore_value_without_use)
80158         (sc_prohibit_error_without_use, sc_prohibit_xalloc_without_use)
80159         (sc_prohibit_hash_without_use, sc_prohibit_cloexec_without_use)
80160         (sc_prohibit_posixver_without_use, sc_prohibit_same_without_use)
80161         (sc_prohibit_hash_pjw_without_use)
80162         (sc_prohibit_safe_read_without_use)
80163         (sc_prohibit_argmatch_without_use)
80164         (sc_prohibit_canonicalize_without_use)
80165         (sc_prohibit_root_dev_ino_without_use)
80166         (sc_prohibit_openat_without_use)
80167         (sc_prohibit_c_ctype_without_use)
80168         (sc_prohibit_signal_without_use)
80169         (sc_prohibit_stdio--_without_use)
80170         (sc_prohibit_stdio-safer_without_use)
80171         (sc_prohibit_strings_without_use)
80172         (sc_prohibit_intprops_without_use)
80173         (sc_prohibit_stddef_without_use)
80174         (sc_prohibit_xfreopen_without_use): Update clients.
80176 2011-06-24  Jim Meyering  <meyering@redhat.com>
80178         syntax-check: keep one maint.mk rule in sync with its header
80179         * Makefile (sc_check_sym_list): Add a rule to prevent a repeat
80180         of the bug Eric has just fixed, with today's commit 25e4c2ec.
80181         I prefer to avoid temporary files here, so use <(...), but that
80182         is not supported by /bin/sh, so...
80183         (SHELL): Define to /bin/bash.
80185 2011-06-24  Eric Blake  <eblake@redhat.com>
80187         maint.mk: update sc_prohibit_intprops_without_use
80188         * top/maint.mk (_intprops_names): Match recent changes.
80190 2011-06-24  Bruno Haible  <bruno@clisp.org>
80192         strerror-override: No-op tweak.
80193         * lib/strerror-override.h (strerror_override): Reorder conditions,
80194         for consistency with lib/strerror-override.c.
80196 2011-06-23  Eric Blake  <eblake@redhat.com>
80198         maint.mk: test further PATH_MAX issues
80199         * top/maint.mk (sc_prohibit_path_max_array): Rename...
80200         (sc_prohibit_path_max_allocation): ...and also test alloca.
80201         Suggested by Jim Meyering.
80203 2011-06-22  Eric Blake  <eblake@redhat.com>
80205         maint.mk: add syntax-check to avoid char[PATH_MAX]
80206         * top/maint.mk (sc_prohibit_path_max_array): New rule.
80208         stat: be robust to PATH_MAX definition
80209         * lib/stat.c (rpl_stat): Require reasonable PATH_MAX.
80210         * modules/stat (Depends-on): Add verify.
80212         link: work around IRIX bug
80213         * m4/link.m4 (gl_FUNC_LINK): Expose the bug.
80214         * lib/link.c (rpl_link): Work around it.
80215         * tests/test-link.h (test_link): Enhance test.
80216         * doc/posix-functions/link.texi (link): Document the bug.
80218         getopt: silence clang warning
80219         * lib/getopt.c (_getopt_internal_r): Avoid unlikely NULL
80220         dereference.
80221         Reported by Gustavo Martin Domato.
80223 2011-06-22  Jim Meyering  <meyering@redhat.com>
80225         bootstrap: do not insert a blank line into each .gitignore file
80226         * build-aux/bootstrap (sort_patterns): Filter out blank lines.
80228 2011-06-21  Eric Blake  <eblake@redhat.com>
80230         perror: test for output mismatch
80231         * m4/perror.m4 (gl_FUNC_PERROR): Add test, in order to replace
80232         perror on IRIX.
80234         strerror_r: fix OpenBSD behavior on out-of-range
80235         * lib/strerror_r.c (strerror_r): Always use maximal string.
80236         * doc/posix-functions/strerror_r.texi (strerror_r): Document it.
80238         strerror_r: fix OpenBSD behavior on 0
80239         * lib/strerror-override.c (strerror_override): Also override 0
80240         when needed.
80241         * lib/strerror-override.h (strerror_override): Likewise.
80242         * lib/strerror.c (strerror): Simplify, now that 0 override is done
80243         earlier.
80244         * lib/strerror_r.c (strerror_r): Likewise.
80245         * m4/strerror.m4 (gl_FUNC_STRERROR): Split detection of 0
80246         behavior...
80247         (gl_FUNC_STRERROR_0): ...into new macro.
80248         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Replace strerror_r if 0
80249         is overridden.
80250         (gl_FUNC_STRERROR_R_WORKS): Avoid extra tests if 0 is broken.
80251         * modules/strerror-override (Files): Add strerror.m4.
80252         (configure.ac): Also provide override for 0 when needed.
80253         * doc/posix-functions/strerror.texi (strerror): Document this.
80254         * doc/posix-functions/perror.texi (perror): Likewise.
80256         perror: adjust array size
80257         * modules/perror (Depends-on): Add strerror-override.
80258         * lib/perror.c (perror): Use it to avoid magic number.
80260         strerror-override: reduce size
80261         * lib/strerror-override.c (strerror_override): Use fewer lines.
80263 2011-06-20  Bruno Haible  <bruno@clisp.org>
80265         pathmax: Ensure correct value for PATH_MAX on HP-UX.
80266         * lib/pathmax.h (PATH_MAX) [HP-UX]: Define to 1024.
80268 2011-06-20  Paul Eggert  <eggert@cs.ucla.edu>
80270         alloca: port to compilers that can optimize like GCC 4.6.0
80271         * lib/alloca.c (find_stack_direction): New signature, taken from
80272         Autoconf git.  This works with GCC 4.6.0.  This code should never
80273         be used with GCC 4.6.0 itself, as GCC has alloca, but it might
80274         be used with other compilers that optimize as well as GCC 4.6.0 does.
80275         (alloca): Adjust to new signature.
80276         * m4/alloca.m4 (__AC_LIBOBJ_ALLOCA) [Autoconf version < 2.69]:
80277         New macro, which patches Autoconf in a similar way.
80279         c-stack: stop worrying about stack direction
80280         * lib/c-stack.c (find_stack_direction): Remove.
80281         (segv_handler): Don't worry about stack direction growth, as it's
80282         too much of a pain to configure this correctly, given how compilers
80283         are optimizing-away our stack-growth detection code.  Instead, assume
80284         that any access to just before or just after the stack is OK.
80285         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
80286         Don't require AC_FUNC_ALLOCA; no longer needed.
80288 2011-06-20  Eric Blake  <eblake@redhat.com>
80290         test-stat: don't allocate PATH_MAX bytes
80291         * tests/test-stat.h (test_stat_func): Don't stack-allocate a
80292         PATH_MAX-sized buffer.
80293         * modules/openat-tests (Depends-on): Add getcwd-lgpl, drop pathmax.
80294         * modules/stat-tests (Depends-on): Likewise.
80295         * tests/test-fstatat.c (includes): Drop pathmax.h.
80296         * tests/test-stat.c (includes): Likewise.
80297         Reported by Bruno Haible.
80299 2011-06-20  Bruno Haible  <bruno@clisp.org>
80301         float: Work around <float.h> bugs on FreeBSD/x86, AIX with GCC, IRIX.
80302         * lib/float.in.h: Add workarounds for FreeBSD/x86, AIX with GCC, IRIX.
80303         * lib/float.c: New file.
80304         * m4/float_h.m4 (gl_FLOAT_H): Also handle FreeBSD, AIX, IRIX. Set
80305         REPLACE_FLOAT_LDBL.
80306         * modules/float (Files): Add lib/float.c.
80307         (configure.ac): Invoke AC_LIBOBJ.
80308         * doc/posix-headers/float.texi: Mention problems on FreeBSD, AIX, IRIX.
80310 2011-06-20  Bruno Haible  <bruno@clisp.org>
80312         Tests for module 'float'.
80313         * modules/float-tests: New file.
80314         * tests/test-float.c: New file.
80316 2011-06-19  Bruno Haible  <bruno@clisp.org>
80318         isinf: Coding style.
80319         * lib/isinf.c: Use GNU coding style.
80321 2011-06-19  Bruno Haible  <bruno@clisp.org>
80323         linkat test: Avoid test failure on AIX 7.1.
80324         * tests/test-linkat.c (main): Allow EINVAL as alternate error value.
80325         * tests/test-link.h (test_link): Likewise.
80327 2011-06-19  Bruno Haible  <bruno@clisp.org>
80329         pread test: Avoid test failure on OpenBSD 4.9.
80330         * tests/test-pread.c (main): Allow EFBIG instead of EINBAL.
80332 2011-06-19  Bruno Haible  <bruno@clisp.org>
80334         sprintf-posix: Fix test failure on AIX 7.1.
80335         * m4/printf.m4 (gl_PRINTF_PRECISION): Test against AIX bug.
80336         * doc/posix-functions/dprintf.texi: Mention limited precision problem
80337         on AIX.
80338         * doc/posix-functions/fprintf.texi: Likewise.
80339         * doc/posix-functions/printf.texi: Likewise.
80340         * doc/posix-functions/snprintf.texi: Likewise.
80341         * doc/posix-functions/sprintf.texi: Likewise.
80342         * doc/posix-functions/vdprintf.texi: Likewise.
80343         * doc/posix-functions/vfprintf.texi: Likewise.
80344         * doc/posix-functions/vprintf.texi: Likewise.
80345         * doc/posix-functions/vsnprintf.texi: Likewise.
80346         * doc/posix-functions/vsprintf.texi: Likewise.
80348 2011-06-19  Bruno Haible  <bruno@clisp.org>
80350         roundl-ieee: Fix test failure on AIX 7.1.
80351         * m4/roundl.m4 (gl_FUNC_ROUNDL): Test also the sign of roundl (-0.3L).
80352         * doc/posix-functions/roundl.texi: Mention problem with negative
80353         arguments.
80355 2011-06-19  Bruno Haible  <bruno@clisp.org>
80357         round-ieee: Fix test failures on AIX 7.1 and OSF/1 5.1.
80358         * modules/round-ieee (Depends-on): Add floor-ieee, ceil-ieee.
80359         * doc/posix-functions/round.texi: Mention problem with negative
80360         arguments.
80361         * doc/posix-functions/ceil.texi: Mention problem on OSF/1 5.1.
80363 2011-06-19  Bruno Haible  <bruno@clisp.org>
80365         roundf-ieee: Fix test failures on AIX 7.1 and OSF/1 5.1.
80366         * m4/roundf.m4 (gl_FUNC_ROUNDF): Test also the sign of roundf (-0.3f).
80367         * modules/roundf-ieee (Depends-on): Add floorf-ieee, ceilf-ieee.
80368         * doc/posix-functions/roundf.texi: Mention problem with negative
80369         arguments.
80370         * doc/posix-functions/ceilf.texi: Mention problem on OSF/1 5.1.
80372 2011-06-19  Bruno Haible  <bruno@clisp.org>
80374         ceilf-ieee: Work around bug on MacOS X 10.5.
80375         * doc/posix-functions/ceilf.texi: Mention the MacOS X 10.5 problem.
80377         floor*-ieee, ceil*-ieee, trunc*-ieee, round*-ieee: More robust checks.
80378         * m4/floorf.m4 (gl_FUNC_FLOORF): In the test whether the function is
80379         IEEE compliant, avoid compiler optimizations.
80380         * m4/floor.m4 (gl_FUNC_FLOOR): Likewise.
80381         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
80382         * m4/ceil.m4 (gl_FUNC_CEIL): Likewise.
80383         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
80384         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
80385         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
80386         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
80387         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
80388         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
80389         * m4/roundl.m4 (gl_FUNC_ROUNDL): Likewise.
80391 2011-06-19  Bruno Haible  <bruno@clisp.org>
80393         ceilf-ieee: Work around bug on AIX 7.1.
80394         * m4/ceilf.m4 (gl_FUNC_CEILF): Test also the sign of ceilf (-0.3f).
80395         * doc/posix-functions/ceilf.texi: Mention the AIX 7.1 problem.
80397 2011-06-19  Bruno Haible  <bruno@clisp.org>
80399         ceil-ieee: Work around bug on AIX 7.1.
80400         * m4/ceil.m4 (gl_FUNC_CEIL): Test also the sign of ceil (-0.3).
80401         * doc/posix-functions/ceil.texi: Mention the AIX 7.1 problem.
80403 2011-06-18  Bruno Haible  <bruno@clisp.org>
80405         fsync test: Avoid test failure on MacOS X and AIX.
80406         * tests/test-fsync.c (fsync): Allow ENOTSUP and EBADF instead of
80407         EINVAL.
80409 2011-06-18  Bruno Haible  <bruno@clisp.org>
80411         openat, fdopendir tests: Fix link errors.
80412         * modules/openat-tests (Depends-on): Add progname.
80413         * modules/fdopendir-tests (Depends-on): Likewise.
80414         * tests/test-fchownat.c: Include progname.h.
80415         (main): Call set_program_name.
80416         * tests/test-fstatat.c: Include progname.h.
80417         (main): Call set_program_name.
80418         * tests/test-mkdirat.c: Include progname.h.
80419         (main): Call set_program_name.
80420         * tests/test-openat.c: Include progname.h.
80421         (main): Call set_program_name.
80422         * tests/test-unlinkat.c: Include progname.h.
80423         (main): Call set_program_name.
80424         * tests/test-fdopendir.c: Include progname.h.
80425         (main): Call set_program_name.
80427 2011-06-18  Bruno Haible  <bruno@clisp.org>
80429         Doc update.
80430         * doc/posix-functions/pthread_attr_getstack.texi: Update info regarding
80431         HP-UX.
80432         * doc/posix-functions/pthread_attr_setstack.texi: Likewise.
80434 2011-06-18  Bruno Haible  <bruno@clisp.org>
80436         getcwd tests: Avoid compilation error on HP-UX 11.31.
80437         * modules/getcwd-tests (Depends-on): Add pathmax.
80438         * tests/test-getcwd.c: Include pathmax.h.
80440 2011-06-18  Bruno Haible  <bruno@clisp.org>
80442         isfinite, isinf: Fix link error on AIX 6 and 7.
80443         * m4/isfinite.m4 (gl_ISFINITE): When determining whether libm is
80444         needed, also test the macro with a 'float' argument.
80445         * m4/isinf.m4 (gl_ISINF): Likewise.
80447 2011-06-18  Bruno Haible  <bruno@clisp.org>
80449         getloadavg: Don't clobber LIBS. Regression from previous commit.
80450         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Move tests that use
80451         AC_CHECK_LIB from here...
80452         (gl_GETLOADAVG): ... to here, inside the experiment with LIBS.
80453         (gl_GETLOADAVG, gl_PREREQ_GETLOADAVG): Rename gl_have_func to
80454         gl_func_getloadavg_done.
80455         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
80457 2011-06-18  Bruno Haible  <bruno@clisp.org>
80459         clean-temp: Improve documentation.
80460         * lib/clean-temp.h: Explain better how to use this module.
80461         Reported by John Darrington <john@darrington.wattle.id.au>.
80463 2011-06-17  Bruno Haible  <bruno@clisp.org>
80465         pread, pwrite: Avoid cc warning on AIX.
80466         * lib/unistd.in.h (pread): Undefine before defining as a macro.
80467         (pwrite): Likewise.
80469 2011-06-17  Bruno Haible  <bruno@clisp.org>
80471         spawn-pipe tests: Fix link error.
80472         * tests/test-spawn-pipe-child.c: Undefine fprintf.
80473         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
80475 2011-06-17  Bruno Haible  <bruno@clisp.org>
80477         Tests: Remove unnecessary dependency.
80478         * modules/canonicalize-tests (Depends-on): Remove progname.
80479         * modules/chown-tests (Depends-on): Likewise.
80480         * modules/dirname-tests (Depends-on): Likewise.
80481         * modules/fdopendir-tests (Depends-on): Likewise.
80482         * modules/fdutimensat-tests (Depends-on): Likewise.
80483         * modules/hash-tests (Depends-on): Likewise.
80484         * modules/lchown-tests (Depends-on): Likewise.
80485         * modules/linkat-tests (Depends-on): Likewise.
80486         * modules/renameat-tests (Depends-on): Likewise.
80487         * modules/spawn-pipe-tests (Depends-on): Likewise.
80488         * modules/utimensat-tests (Depends-on): Likewise.
80490 2011-06-17  Bruno Haible  <bruno@clisp.org>
80492         spawn-pipe tests: Fix link error.
80493         * tests/test-spawn-pipe-child.c: Undefine fflush.
80495 2011-06-17  Bruno Haible  <bruno@clisp.org>
80497         Fix tests link errors.
80498         * modules/ceil-ieee-tests (Makefile.am): Use CEIL_LIBM, not FLOOR_LIBM.
80499         * modules/chown-tests (Makefile.am): Don't link test-chown with
80500         LIBINTL.
80501         * modules/lchown-tests (Makefile.am): Don't link test-lchown with
80502         LIBINTL.
80503         * modules/utimens-tests (Makefile.am): Don't link test-utimens with
80504         LIBINTL.
80505         * modules/futimens-tests (Makefile.am): Don't link test-futimens with
80506         LIBINTL.
80508 2011-06-16  Bruno Haible  <bruno@clisp.org>
80510         crypto/gc-sha1: Fix recent regression.
80511         * modules/crypto/gc-sha1 (configure.ac): Invoke AC_LIBOBJ here.
80512         * m4/gc-sha1.m4 (gl_GC_SHA1): Don't invoke gl_SHA1.
80514         crypto/gc-md5: Fix recent regression.
80515         * modules/crypto/gc-md5 (configure.ac): Invoke AC_LIBOBJ here.
80517         crypto/gc-md4: Fix recent regression.
80518         * modules/crypto/gc-md4 (configure.ac): Invoke AC_LIBOBJ here.
80519         * m4/md4.m4 (gl_MD4): Ensure the expansion is non-empty.
80521         crypto/gc-arctwo: Fix recent regression.
80522         * modules/crypto/gc-arctwo (configure.ac): Invoke AC_LIBOBJ here.
80523         * m4/arctwo.m4 (gl_ARCTWO): Ensure the expansion is non-empty.
80525         crypto/gc-rijndael: Fix recent regression.
80526         * modules/crypto/gc-rijndael (Files): Remove m4/rijndael.m4.
80527         (configure.ac): Invoke AC_LIBOBJ here.
80528         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Don't invoke gl_RIJNDAEL.
80529         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
80531         crypto/gc-hmac-sha1: Fix recent regression.
80532         * modules/crypto/gc-hmac-sha1 (Files): Remove m4/hmac-sha1.m4.
80533         (configure.ac): Invoke AC_LIBOBJ here.
80534         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Don't invoke gl_HMAC_SHA1.
80535         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
80537         crypto/gc-hmac-md5: Fix recent regression.
80538         * modules/crypto/gc-hmac-md5 (Files): Remove m4/hmac-md5.m4.
80539         (configure.ac): Invoke AC_LIBOBJ here.
80540         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Don't invoke gl_HMAC_MD5.
80541         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
80543         crypto/gc-des: Fix recent regression.
80544         * modules/crypto/gc-des (Files): Remove m4/des.m4.
80545         (configure.ac): Invoke AC_LIBOBJ here.
80546         * m4/gc-des.m4 (gl_GC_DES): Don't invoke gl_DES.
80547         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
80549         crypto/gc-arcfour: Fix recent regression.
80550         * modules/crypto/gc-arcfour (Files): Remove m4/arcfour.m4.
80551         (configure.ac): Invoke AC_LIBOBJ here.
80552         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Don't invoke gl_ARCFOUR.
80553         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
80555 2011-06-16  Paul Eggert  <eggert@cs.ucla.edu>
80557         * m4/lstat.m4 (gl_FUNC_LSTAT): Fix typo in prerequisite.
80558         After the 2011-05-21 change, this macro requires
80559         gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, not
80560         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
80562 2011-06-16  Bruno Haible  <bruno@clisp.org>
80564         fprintftime: Move AC_LIBOBJ invocations to module description.
80565         * m4/fprintftime.m4: Remove file.
80566         * modules/fprintftime (Files): Remove m4/fprintftime.m4.
80567         (configure.ac): Remove gl_FPRINTFTIME call.
80568         (Makefile.am): Augment lib_SOURCES.
80569         Reported by Jim Meyering.
80571 2011-06-16  Bruno Haible  <bruno@clisp.org>
80573         tmpfile-safer: Finish 2011-05-23 commit.
80574         * m4/stdio-safer.m4: Really remove file.
80575         Reported by Jim Meyering.
80577 2011-06-16  Bruno Haible  <bruno@clisp.org>
80579         syntax-check: Fix typo.
80580         * Makefile (allow_AC_LIBOBJ): Mention printf-posix-rpl.m4, not
80581         printf-posix.m4.
80582         Reported by Jim Meyering.
80584 2011-06-13  Jim Meyering  <meyering@redhat.com>
80586         syntax-check: add a rule to help enforce the no-AC_LIBOBJ-in-m4/ policy
80587         * Makefile (sc_prohibit_AC_LIBOBJ_in_m4): New rule.
80589 2011-05-23  Bruno Haible  <bruno@clisp.org>
80591         yesno: Move AC_LIBOBJ invocations to module description.
80592         * m4/yesno.m4 (gl_YESNO): Remove AC_LIBOBJ invocation.
80593         * modules/yesno (Makefile.am): Augment lib_SOURCES.
80595 2011-05-23  Bruno Haible  <bruno@clisp.org>
80597         xstrtol: Move AC_LIBOBJ invocations to module description.
80598         * m4/xstrtol.m4 (gl_XSTRTOL): Remove AC_LIBOBJ invocations.
80599         * modules/xstrtol (Makefile.am): Augment lib_SOURCES.
80601 2011-05-23  Bruno Haible  <bruno@clisp.org>
80603         xstrtold: Move AC_LIBOBJ invocations to module description.
80604         * m4/xstrtod.m4 (gl_XSTRTOLD): Remove AC_LIBOBJ invocation.
80605         * modules/xstrtold (Makefile.am): Augment lib_SOURCES.
80607 2011-05-23  Bruno Haible  <bruno@clisp.org>
80609         xstrtod: Move AC_LIBOBJ invocations to module description.
80610         * m4/xstrtod.m4 (gl_XSTRTOD): Remove AC_LIBOBJ invocation.
80611         * modules/xstrtod (Makefile.am): Augment lib_SOURCES.
80613 2011-05-23  Bruno Haible  <bruno@clisp.org>
80615         xnanosleep: Move AC_LIBOBJ invocations to module description.
80616         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove AC_LIBOBJ invocation.
80617         * modules/xnanosleep (Makefile.am): Augment lib_SOURCES.
80619 2011-05-23  Bruno Haible  <bruno@clisp.org>
80621         xgetcwd: Move AC_LIBOBJ invocations to module description.
80622         * m4/xgetcwd.m4 (gl_XGETCWD): Remove AC_LIBOBJ invocation.
80623         * modules/xgetcwd (Makefile.am): Augment lib_SOURCES.
80625 2011-05-23  Bruno Haible  <bruno@clisp.org>
80627         xalloc: Move AC_LIBOBJ invocations to module description.
80628         * m4/xalloc.m4 (gl_XALLOC): Remove AC_LIBOBJ invocation.
80629         * modules/xalloc (Makefile.am): Augment lib_SOURCES.
80631 2011-05-23  Bruno Haible  <bruno@clisp.org>
80633         write-any-file: Move AC_LIBOBJ invocations to module description.
80634         * m4/write-any-file.m4 (gl_WRITE_ANY_FILE): Remove AC_LIBOBJ
80635         invocation.
80636         * modules/write-any-file (Makefile.am): Augment lib_SOURCES.
80638 2011-05-23  Bruno Haible  <bruno@clisp.org>
80640         utimens: Move AC_LIBOBJ invocations to module description.
80641         * m4/utimens.m4 (gl_UTIMENS): Remove AC_LIBOBJ invocation.
80642         * modules/utimens (Makefile.am): Augment lib_SOURCES.
80644 2011-05-23  Bruno Haible  <bruno@clisp.org>
80646         utimecmp: Move AC_LIBOBJ invocations to module description.
80647         * m4/utimecmp.m4 (gl_UTIMECMP): Remove AC_LIBOBJ invocation.
80648         * modules/utimecmp (Makefile.am): Augment lib_SOURCES.
80650 2011-05-23  Bruno Haible  <bruno@clisp.org>
80652         userspec: Move AC_LIBOBJ invocations to module description.
80653         * m4/userspec.m4 (gl_USERSPEC): Remove AC_LIBOBJ invocation.
80654         * modules/userspec (Makefile.am): Augment lib_SOURCES.
80656 2011-05-23  Bruno Haible  <bruno@clisp.org>
80658         unlinkdir: Move AC_LIBOBJ invocations to module description.
80659         * m4/unlinkdir.m4 (gl_UNLINKDIR): Remove AC_LIBOBJ invocation.
80660         * modules/unlinkdir (Makefile.am): Augment lib_SOURCES.
80662 2011-05-23  Bruno Haible  <bruno@clisp.org>
80664         unistd-safer: Move AC_LIBOBJ invocations to module description.
80665         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Remove AC_LIBOBJ invocations.
80666         * modules/unistd-safer (Makefile.am): Augment lib_SOURCES.
80668 2011-05-23  Bruno Haible  <bruno@clisp.org>
80670         tempname: Move AC_LIBOBJ invocations to module description.
80671         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Remove AC_LIBOBJ invocation.
80672         * modules/tempname (Makefile.am): Augment lib_SOURCES.
80674 2011-05-23  Bruno Haible  <bruno@clisp.org>
80676         strftime: Move AC_LIBOBJ invocations to module description.
80677         * m4/strftime.m4 (gl_FUNC_STRFTIME): Remove AC_LIBOBJ invocation.
80678         * modules/strftime (Makefile.am): Augment lib_SOURCES.
80680 2011-05-23  Bruno Haible  <bruno@clisp.org>
80682         stdlib-safer: Move AC_LIBOBJ invocations to module description.
80683         * m4/stdlib-safer.m4: Remove file.
80684         * modules/stdlib-safer (Files): Remove m4/stdlib-safer.m4.
80685         (configure.ac): Remove gl_STDLIB_SAFER call.
80686         (Makefile.am): Augment lib_SOURCES.
80688 2011-05-23  Bruno Haible  <bruno@clisp.org>
80690         tmpfile-safer: Move AC_LIBOBJ invocations to module description.
80691         * m4/stdio-safer.m4: Remove file.
80692         * modules/tmpfile-safer (Files): Remove m4/stdio-safer.m4.
80693         (configure.ac): Remove gl_TMPFILE_SAFER call.
80694         (Makefile.am): Augment lib_SOURCES.
80696 2011-05-23  Bruno Haible  <bruno@clisp.org>
80698         popen-safer: Move AC_LIBOBJ invocations to module description.
80699         * m4/stdio-safer.m4 (gl_POPEN_SAFER): Remove macro.
80700         * modules/popen-safer (Files): Remove m4/stdio-safer.m4.
80701         (configure.ac): Remove gl_POPEN_SAFER call.
80702         (Makefile.am): Augment lib_SOURCES.
80704 2011-05-23  Bruno Haible  <bruno@clisp.org>
80706         freopen-safer: Move AC_LIBOBJ invocations to module description.
80707         * m4/stdio-safer.m4 (gl_FREOPEN_SAFER): Remove macro.
80708         * modules/freopen-safer (Files): Remove m4/stdio-safer.m4.
80709         (configure.ac): Remove gl_FREOPEN_SAFER call.
80710         (Makefile.am): Augment lib_SOURCES.
80712 2011-05-23  Bruno Haible  <bruno@clisp.org>
80714         fopen-safer: Move AC_LIBOBJ invocations to module description.
80715         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove macro.
80716         * modules/fopen-safer (Files): Remove m4/stdio-safer.m4.
80717         (configure.ac): Remove gl_FOPEN_SAFER call.
80718         (Makefile.am): Augment lib_SOURCES.
80720 2011-05-23  Bruno Haible  <bruno@clisp.org>
80722         crypto/sha512: Move AC_LIBOBJ invocations to module description.
80723         * m4/sha512.m4 (gl_SHA512): Remove AC_LIBOBJ invocation.
80724         * modules/crypto/sha512 (Makefile.am): Augment lib_SOURCES.
80726 2011-05-23  Bruno Haible  <bruno@clisp.org>
80728         crypto/sha256: Move AC_LIBOBJ invocations to module description.
80729         * m4/sha256.m4 (gl_SHA256): Remove AC_LIBOBJ invocation.
80730         * modules/crypto/sha256 (Makefile.am): Augment lib_SOURCES.
80732 2011-05-23  Bruno Haible  <bruno@clisp.org>
80734         crypto/sha1: Move AC_LIBOBJ invocations to module description.
80735         * m4/sha1.m4 (gl_SHA1): Remove AC_LIBOBJ invocation.
80736         * modules/crypto/sha1 (Makefile.am): Augment lib_SOURCES.
80738 2011-05-23  Bruno Haible  <bruno@clisp.org>
80740         settime: Move AC_LIBOBJ invocations to module description.
80741         * m4/settime.m4 (gl_SETTIME): Remove AC_LIBOBJ invocation.
80742         * modules/settime (Makefile.am): Augment lib_SOURCES.
80744 2011-05-23  Bruno Haible  <bruno@clisp.org>
80746         savedir: Move AC_LIBOBJ invocations to module description.
80747         * m4/savedir.m4 (gl_SAVEDIR): Remove AC_LIBOBJ invocation.
80748         * modules/savedir (Makefile.am): Augment lib_SOURCES.
80750 2011-05-23  Bruno Haible  <bruno@clisp.org>
80752         save-cwd: Move AC_LIBOBJ invocations to module description.
80753         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove AC_LIBOBJ invocation.
80754         * modules/save-cwd (Makefile.am): Augment lib_SOURCES.
80756 2011-05-23  Bruno Haible  <bruno@clisp.org>
80758         same: Move AC_LIBOBJ invocations to module description.
80759         * m4/same.m4 (gl_SAME): Remove AC_LIBOBJ invocation.
80760         * modules/same (Makefile.am): Augment lib_SOURCES.
80762 2011-05-23  Bruno Haible  <bruno@clisp.org>
80764         safe-write: Move AC_LIBOBJ invocations to module description.
80765         * m4/safe-write.m4 (gl_SAFE_WRITE): Remove macro.
80766         * modules/safe-write (configure.ac): Invoke gl_PREREQ_SAFE_WRITE
80767         instead of gl_SAFE_WRITE.
80768         (Makefile.am): Augment lib_SOURCES.
80770 2011-05-23  Bruno Haible  <bruno@clisp.org>
80772         safe-read: Move AC_LIBOBJ invocations to module description.
80773         * m4/safe-read.m4 (gl_SAFE_READ): Remove macro.
80774         * modules/safe-read (configure.ac): Invoke gl_PREREQ_SAFE_READ instead
80775         of gl_SAFE_READ.
80776         (Makefile.am): Augment lib_SOURCES.
80778 2011-05-23  Bruno Haible  <bruno@clisp.org>
80780         safe-alloc: Move AC_LIBOBJ invocations to module description.
80781         * m4/safe-alloc.m4 (gl_SAFE_ALLOC): Remove AC_LIBOBJ invocation.
80782         * modules/safe-alloc (Makefile.am): Augment lib_SOURCES.
80784 2011-05-23  Bruno Haible  <bruno@clisp.org>
80786         crypto/rijndael: Move AC_LIBOBJ invocations to module description.
80787         * m4/rijndael.m4: Remove file.
80788         * modules/crypto/rijndael (Files): Remove it.
80789         (configure.ac): Remove gl_RIJNDAEL call.
80790         (Makefile.am): Augment lib_SOURCES.
80792 2011-05-23  Bruno Haible  <bruno@clisp.org>
80794         readtokens: Move AC_LIBOBJ invocations to module description.
80795         * m4/readtokens.m4 (gl_READTOKENS): Remove AC_LIBOBJ invocation.
80796         * modules/readtokens (Makefile.am): Augment lib_SOURCES.
80798 2011-05-23  Bruno Haible  <bruno@clisp.org>
80800         read-file: Move AC_LIBOBJ invocations to module description.
80801         * m4/read-file.m4 (gl_FUNC_READ_FILE): Remove macro.
80802         * modules/read-file (configure.ac): Invoke gl_PREREQ_READ_FILE instead
80803         of gl_FUNC_READ_FILE.
80804         (Makefile.am): Augment lib_SOURCES.
80806 2011-05-23  Bruno Haible  <bruno@clisp.org>
80808         quotearg: Move AC_LIBOBJ invocations to module description.
80809         * m4/quotearg.m4 (gl_QUOTEARG): Remove AC_LIBOBJ invocation.
80810         * modules/quotearg (Makefile.am): Augment lib_SOURCES.
80812 2011-05-23  Bruno Haible  <bruno@clisp.org>
80814         quote: Move AC_LIBOBJ invocations to module description.
80815         * m4/quote.m4 (gl_QUOTE): Remove AC_LIBOBJ invocation.
80816         * modules/quote (Makefile.am): Augment lib_SOURCES.
80818 2011-05-23  Bruno Haible  <bruno@clisp.org>
80820         posixver: Move AC_LIBOBJ invocations to module description.
80821         * m4/posixver.m4 (gl_POSIXVER): Remove AC_LIBOBJ invocation.
80822         * modules/posixver (Makefile.am): Augment lib_SOURCES.
80824 2011-05-23  Bruno Haible  <bruno@clisp.org>
80826         posixtm: Move AC_LIBOBJ invocations to module description.
80827         * m4/posixtm.m4 (gl_POSIXTM): Remove AC_LIBOBJ invocation.
80828         * modules/posixtm (Makefile.am): Augment lib_SOURCES.
80830 2011-05-23  Bruno Haible  <bruno@clisp.org>
80832         physmem: Move AC_LIBOBJ invocations to module description.
80833         * m4/physmem.m4 (gl_PHYSMEM): Remove AC_LIBOBJ invocation.
80834         * modules/physmem (Makefile.am): Augment lib_SOURCES.
80836 2011-05-23  Bruno Haible  <bruno@clisp.org>
80838         pagealign_alloc: Move AC_LIBOBJ invocations to module description.
80839         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC): Remove AC_LIBOBJ
80840         invocation.
80841         * modules/pagealign_alloc (Makefile.am): Augment lib_SOURCES.
80843 2011-05-23  Bruno Haible  <bruno@clisp.org>
80845         mpsort: Move AC_LIBOBJ invocations to module description.
80846         * m4/mpsort.m4 (gl_MPSORT): Remove AC_LIBOBJ invocation.
80847         * modules/mpsort (Makefile.am): Augment lib_SOURCES.
80849 2011-05-23  Bruno Haible  <bruno@clisp.org>
80851         modechange: Move AC_LIBOBJ invocations to module description.
80852         * m4/modechange.m4 (gl_MODECHANGE): Remove AC_LIBOBJ invocation.
80853         * modules/modechange (Makefile.am): Augment lib_SOURCES.
80855 2011-05-23  Bruno Haible  <bruno@clisp.org>
80857         mkdir-p: Move AC_LIBOBJ invocations to module description.
80858         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Remove AC_LIBOBJ invocations.
80859         * modules/mkdir-p (Makefile.am): Augment lib_SOURCES.
80861 2011-05-23  Bruno Haible  <bruno@clisp.org>
80863         mkancesdirs: Move AC_LIBOBJ invocations to module description.
80864         * m4/mkancesdirs.m4 (gl_MKANCESDIRS): Remove AC_LIBOBJ invocation.
80865         * modules/mkancesdirs (Makefile.am): Augment lib_SOURCES.
80867 2011-05-23  Bruno Haible  <bruno@clisp.org>
80869         mgetgroups: Move AC_LIBOBJ invocations to module description.
80870         * m4/mgetgroups.m4 (gl_MGETGROUPS): Remove AC_LIBOBJ invocation.
80871         * modules/mgetgroups (Makefile.am): Augment lib_SOURCES.
80873 2011-05-23  Bruno Haible  <bruno@clisp.org>
80875         memxor: Move AC_LIBOBJ invocations to module description.
80876         * m4/memxor.m4 (gl_MEMXOR): Remove AC_LIBOBJ invocation.
80877         * modules/memxor (Makefile.am): Augment lib_SOURCES.
80879 2011-05-23  Bruno Haible  <bruno@clisp.org>
80881         memcoll: Move AC_LIBOBJ invocations to module description.
80882         * m4/memcoll.m4 (gl_MEMCOLL): Remove AC_LIBOBJ invocation.
80883         * modules/memcoll (Makefile.am): Augment lib_SOURCES.
80885 2011-05-23  Bruno Haible  <bruno@clisp.org>
80887         memcasecmp: Move AC_LIBOBJ invocations to module description.
80888         * m4/memcasecmp.m4 (gl_MEMCASECMP): Remove AC_LIBOBJ invocation.
80889         * modules/memcasecmp (Makefile.am): Augment lib_SOURCES.
80891 2011-05-23  Bruno Haible  <bruno@clisp.org>
80893         crypto/md5: Move AC_LIBOBJ invocations to module description.
80894         * m4/md5.m4 (gl_MD5): Remove AC_LIBOBJ invocation.
80895         * modules/crypto/md5 (Makefile.am): Augment lib_SOURCES.
80897 2011-05-23  Bruno Haible  <bruno@clisp.org>
80899         crypto/md4: Move AC_LIBOBJ invocations to module description.
80900         * m4/md4.m4 (gl_MD4): Remove AC_LIBOBJ invocation.
80901         * modules/crypto/md4 (Makefile.am): Augment lib_SOURCES.
80903 2011-05-23  Bruno Haible  <bruno@clisp.org>
80905         crypto/md2: Move AC_LIBOBJ invocations to module description.
80906         * m4/md2.m4: Remove file.
80907         * modules/crypto/md2 (Files): Remove it.
80908         (configure.ac): Remove gl_MD2 call.
80909         (Makefile.am): Augment lib_SOURCES.
80911 2011-05-23  Bruno Haible  <bruno@clisp.org>
80913         long-options: Move AC_LIBOBJ invocations to module description.
80914         * m4/long-options.m4: Remove file.
80915         * modules/long-options (Files): Remove it.
80916         (configure.ac): Remove gl_LONG_OPTIONS call.
80917         (Makefile.am): Augment lib_SOURCES.
80919 2011-05-23  Bruno Haible  <bruno@clisp.org>
80921         i-ring: Move AC_LIBOBJ invocations to module description.
80922         * m4/i-ring.m4 (gl_I_RING): Remove AC_LIBOBJ invocation.
80923         * modules/i-ring (Makefile.am): Augment lib_SOURCES.
80925 2011-05-23  Bruno Haible  <bruno@clisp.org>
80927         idcache: Move AC_LIBOBJ invocations to module description.
80928         * m4/idcache.m4 (gl_IDCACHE): Remove AC_LIBOBJ invocation.
80929         * modules/idcache (Makefile.am): Augment lib_SOURCES.
80931 2011-05-23  Bruno Haible  <bruno@clisp.org>
80933         human: Move AC_LIBOBJ invocations to module description.
80934         * m4/human.m4 (gl_HUMAN): Remove AC_LIBOBJ invocation.
80935         * modules/human (Makefile.am): Augment lib_SOURCES.
80937 2011-05-23  Bruno Haible  <bruno@clisp.org>
80939         crypto/hmac-sha1: Move AC_LIBOBJ invocations to module description.
80940         * m4/hmac-sha1.m4: Remove file.
80941         * modules/crypto/hmac-sha1 (Files): Remove it.
80942         (configure.ac): Remove gl_HMAC_SHA1 call.
80943         (Makefile.am): Augment lib_SOURCES.
80945 2011-05-23  Bruno Haible  <bruno@clisp.org>
80947         crypto/hmac-md5: Move AC_LIBOBJ invocations to module description.
80948         * m4/hmac-md5.m4: Remove file.
80949         * modules/crypto/hmac-md5 (Files): Remove it.
80950         (configure.ac): Remove gl_HMAC_MD5 call.
80951         (Makefile.am): Augment lib_SOURCES.
80953 2011-05-23  Bruno Haible  <bruno@clisp.org>
80955         hash: Move AC_LIBOBJ invocations to module description.
80956         * m4/hash.m4: Remove file.
80957         * modules/hash (Files): Remove it.
80958         (configure.ac): Remove gl_HASH call.
80959         (Makefile.am): Augment lib_SOURCES.
80961 2011-05-23  Bruno Haible  <bruno@clisp.org>
80963         hard-locale: Move AC_LIBOBJ invocations to module description.
80964         * m4/hard-locale.m4 (gl_HARD_LOCALE): Remove AC_LIBOBJ invocation.
80965         * modules/hard-locale (Makefile.am): Augment lib_SOURCES.
80967 2011-05-23  Bruno Haible  <bruno@clisp.org>
80969         getugroups: Move AC_LIBOBJ invocations to module description.
80970         * m4/getugroups.m4 (gl_GETUGROUPS): Remove AC_LIBOBJ invocation.
80971         * modules/getugroups (Makefile.am): Augment lib_SOURCES.
80973 2011-05-23  Bruno Haible  <bruno@clisp.org>
80975         gettime: Move AC_LIBOBJ invocations to module description.
80976         * m4/gettime.m4 (gl_GETTIME): Remove AC_LIBOBJ invocation.
80977         * modules/gettime (Makefile.am): Augment lib_SOURCES.
80979 2011-05-23  Bruno Haible  <bruno@clisp.org>
80981         getndelim2: Move AC_LIBOBJ invocations to module description.
80982         * m4/getndelim2.m4 (gl_GETNDELIM2): Remove AC_LIBOBJ invocation.
80983         * modules/getndelim2 (Makefile.am): Augment lib_SOURCES.
80985 2011-05-23  Bruno Haible  <bruno@clisp.org>
80987         crypto/gc-pbkdf2-sha1: Move AC_LIBOBJ invocations to module description.
80988         * m4/gc-pbkdf2-sha1.m4: Remove file.
80989         * modules/crypto/gc-pbkdf2-sha1 (Files): Remove it.
80990         (configure.ac): Remove gl_GC_PBKDF2_SHA1 call.
80991         (Makefile.am): Augment lib_SOURCES.
80993 2011-05-23  Bruno Haible  <bruno@clisp.org>
80995         fts: Move AC_LIBOBJ invocations to module description.
80996         * m4/fts.m4 (gl_FUNC_FTS_CORE): Move AC_LIBOBJ invocation from here...
80997         * modules/fts (configure.ac): ... to here.
80999 2011-05-23  Bruno Haible  <bruno@clisp.org>
81001         file-type: Move AC_LIBOBJ invocations to module description.
81002         * m4/file-type.m4: Remove file.
81003         * modules/file-type (Files): Remove it.
81004         (configure.ac): Remove gl_FILE_TYPE call.
81005         (Makefile.am): Augment lib_SOURCES.
81007 2011-05-23  Bruno Haible  <bruno@clisp.org>
81009         filenamecat*: Respect rules for use of AC_LIBOBJ.
81010         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT, gl_FILE_NAME_CONCAT_LGPL):
81011         Remove AC_LIBOBJ invocation.
81012         * modules/filenamecat (Makefile.am): Augment lib_SOURCES.
81013         * modules/filenamecat-lgpl (Makefile.am): Augment lib_SOURCES.
81015 2011-05-23  Bruno Haible  <bruno@clisp.org>
81017         filemode: Move AC_LIBOBJ invocations to module description.
81018         * m4/filemode.m4 (gl_FILEMODE): Remove AC_LIBOBJ invocation.
81019         * modules/filemode (Makefile.am): Augment lib_SOURCES.
81021 2011-05-23  Bruno Haible  <bruno@clisp.org>
81023         openat-safer: Move AC_LIBOBJ invocations to module description.
81024         * m4/fcntl-safer.m4 (gl_OPENAT_SAFER): Remove AC_LIBOBJ invocation.
81025         * modules/openat-safer (Makefile.am): Augment lib_SOURCES.
81027 2011-05-23  Bruno Haible  <bruno@clisp.org>
81029         fcntl-safer: Move AC_LIBOBJ invocations to module description.
81030         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove AC_LIBOBJ invocations.
81031         * modules/fcntl-safer (Makefile.am): Augment lib_SOURCES.
81033 2011-05-23  Bruno Haible  <bruno@clisp.org>
81035         exclude: Move AC_LIBOBJ invocations to module description.
81036         * m4/exclude.m4: Remove file.
81037         * modules/exclude (Files): Remove it.
81038         (configure.ac): Remove gl_EXCLUDE call.
81039         (Makefile.am): Augment lib_SOURCES.
81041 2011-05-23  Bruno Haible  <bruno@clisp.org>
81043         dirname*: Respect rules for use of AC_LIBOBJ.
81044         * m4/dirname.m4 (gl_DIRNAME, gl_DIRNAME_LGPL): Remove AC_LIBOBJ
81045         invocations.
81046         * modules/dirname (Makefile.am): Augment lib_SOURCES.
81047         * modules/dirname-lgpl (Makefile.am): Augment lib_SOURCES.
81049 2011-05-23  Bruno Haible  <bruno@clisp.org>
81051         dirent-safer: Move AC_LIBOBJ invocations to module description.
81052         * m4/dirent-safer.m4 (gl_DIRENT_SAFER): Remove AC_LIBOBJ invocation.
81053         * modules/dirent-safer (Makefile.am): Augment lib_SOURCES.
81055 2011-05-23  Bruno Haible  <bruno@clisp.org>
81057         crypto/des: Move AC_LIBOBJ invocations to module description.
81058         * m4/des.m4: Remove file.
81059         * modules/crypto/des (Files): Remove it.
81060         (configure.ac): Remove gl_DES call.
81061         (Makefile.am): Augment lib_SOURCES.
81063 2011-05-23  Bruno Haible  <bruno@clisp.org>
81065         cycle-check: Move AC_LIBOBJ invocations to module description.
81066         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Remove AC_LIBOBJ invocation.
81067         * modules/cycle-check (Makefile.am): Augment lib_SOURCES.
81069 2011-05-23  Bruno Haible  <bruno@clisp.org>
81071         c-strtold: Move AC_LIBOBJ invocations to module description.
81072         * m4/c-strtod.m4 (gl_C_STRTOLD): Remove AC_LIBOBJ invocation.
81073         * modules/c-strtold (Makefile.am): Augment lib_SOURCES.
81075 2011-05-23  Bruno Haible  <bruno@clisp.org>
81077         c-strtod: Move AC_LIBOBJ invocations to module description.
81078         * m4/c-strtod.m4 (gl_C_STRTOD): Remove AC_LIBOBJ invocation.
81079         * modules/c-strtod (Makefile.am): Augment lib_SOURCES.
81081 2011-05-23  Bruno Haible  <bruno@clisp.org>
81083         crc: Move AC_LIBOBJ invocations to module description.
81084         * m4/crc.m4: Remove file.
81085         * modules/crc (Files): Remove it.
81086         (configure.ac): Remove gl_CRC call.
81087         (Makefile.am): Augment lib_SOURCES.
81089 2011-05-23  Bruno Haible  <bruno@clisp.org>
81091         close-stream: Move AC_LIBOBJ invocations to module description.
81092         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove AC_LIBOBJ invocation.
81093         * modules/close-stream (Makefile.am): Augment lib_SOURCES.
81095 2011-05-23  Bruno Haible  <bruno@clisp.org>
81097         closeout: Move AC_LIBOBJ invocations to module description.
81098         * m4/closeout.m4 (gl_CLOSEOUT): Remove AC_LIBOBJ invocation.
81099         * modules/closeout (Makefile.am): Augment lib_SOURCES.
81101 2011-05-23  Bruno Haible  <bruno@clisp.org>
81103         closein: Move AC_LIBOBJ invocations to module description.
81104         * m4/closein.m4 (gl_CLOSEIN): Remove AC_LIBOBJ invocation.
81105         * modules/closein (Makefile.am): Augment lib_SOURCES.
81107 2011-05-23  Bruno Haible  <bruno@clisp.org>
81109         cloexec: Move AC_LIBOBJ invocations to module description.
81110         * m4/cloexec.m4: Remove file.
81111         * modules/cloexec (Files): Remove it.
81112         (configure.ac): Remove gl_CLOEXEC call.
81113         (Makefile.am): Augment lib_SOURCES.
81115 2011-05-23  Bruno Haible  <bruno@clisp.org>
81117         check-version: Move AC_LIBOBJ invocations to module description.
81118         * m4/check-version.m4: Remove file.
81119         * modules/check-version (Files): Remove it.
81120         (configure.ac): Remove gl_CHECK_VERSION call.
81121         (Makefile.am): Augment lib_SOURCES.
81123 2011-05-23  Bruno Haible  <bruno@clisp.org>
81125         chdir-safer: Move AC_LIBOBJ invocations to module description.
81126         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Remove AC_LIBOBJ invocation.
81127         * modules/chdir-safer (Makefile.am): Augment lib_SOURCES.
81129 2011-05-23  Bruno Haible  <bruno@clisp.org>
81131         canonicalize: Move AC_LIBOBJ invocations to module description.
81132         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Remove
81133         AC_LIBOBJ invocation.
81134         * modules/canonicalize (Makefile.am): Augment lib_SOURCES.
81136 2011-05-23  Bruno Haible  <bruno@clisp.org>
81138         canon-host: Move AC_LIBOBJ invocations to module description.
81139         * m4/canon-host.m4 (gl_CANON_HOST): Remove macro.
81140         * modules/canon-host (configure.ac): Invoke gl_PREREQ_CANON_HOST
81141         instead of gl_CANON_HOST.
81142         (Makefile.am): Augment lib_SOURCES.
81144 2011-05-23  Bruno Haible  <bruno@clisp.org>
81146         backupfile: Move AC_LIBOBJ invocations to module description.
81147         * m4/backupfile.m4 (gl_BACKUPFILE): Remove AC_LIBOBJ invocation.
81148         * modules/backupfile (Makefile.am): Augment lib_SOURCES.
81150 2011-05-23  Bruno Haible  <bruno@clisp.org>
81152         argmatch: Move AC_LIBOBJ invocations to module description.
81153         * m4/argmatch.m4: Remove file.
81154         * modules/argmatch (Files): Remove it.
81155         (configure.ac): Remove gl_ARGMATCH call.
81156         (Makefile.am): Augment lib_SOURCES.
81158 2011-05-23  Bruno Haible  <bruno@clisp.org>
81160         crypto/arctwo: Move AC_LIBOBJ invocations to module description.
81161         * m4/arctwo.m4 (gl_ARCTWO): Remove AC_LIBOBJ invocation.
81162         * modules/crypto/arctwo (Makefile.am): Augment lib_SOURCES.
81164 2011-05-23  Bruno Haible  <bruno@clisp.org>
81166         crypto/arcfour: Move AC_LIBOBJ invocations to module description.
81167         * m4/arcfour.m4: Remove file.
81168         * modules/crypto/arcfour (Files): Remove it.
81169         (configure.ac): Remove gl_ARCFOUR call.
81170         (Makefile.am): Augment lib_SOURCES.
81172 2011-05-22  Bruno Haible  <bruno@clisp.org>
81174         write: Move AC_LIBOBJ invocations to module description.
81175         * m4/write.m4 (gl_FUNC_WRITE): Move AC_LIBOBJ invocation from here...
81176         * modules/write (configure.ac): ... to here.
81178 2011-05-22  Bruno Haible  <bruno@clisp.org>
81180         wmemset: Move AC_LIBOBJ invocations to module description.
81181         * m4/wmemset.m4 (gl_FUNC_WMEMSET): Move AC_LIBOBJ invocation from
81182         here...
81183         * modules/wmemset (configure.ac): ... to here.
81185 2011-05-22  Bruno Haible  <bruno@clisp.org>
81187         wmemmove: Move AC_LIBOBJ invocations to module description.
81188         * m4/wmemmove.m4 (gl_FUNC_WMEMMOVE): Move AC_LIBOBJ invocation from
81189         here...
81190         * modules/wmemmove (configure.ac): ... to here.
81192 2011-05-22  Bruno Haible  <bruno@clisp.org>
81194         wmemcpy: Move AC_LIBOBJ invocations to module description.
81195         * m4/wmemcpy.m4 (gl_FUNC_WMEMCPY): Move AC_LIBOBJ invocation from
81196         here...
81197         * modules/wmemcpy (configure.ac): ... to here.
81199 2011-05-22  Bruno Haible  <bruno@clisp.org>
81201         wmemcmp: Move AC_LIBOBJ invocations to module description.
81202         * m4/wmemcmp.m4 (gl_FUNC_WMEMCMP): Move AC_LIBOBJ invocation from
81203         here...
81204         * modules/wmemcmp (configure.ac): ... to here.
81206 2011-05-22  Bruno Haible  <bruno@clisp.org>
81208         wmemchr: Move AC_LIBOBJ invocations to module description.
81209         * m4/wmemchr.m4 (gl_FUNC_WMEMCHR): Move AC_LIBOBJ invocation from
81210         here...
81211         * modules/wmemchr (configure.ac): ... to here.
81213 2011-05-22  Bruno Haible  <bruno@clisp.org>
81215         wcswidth: Move AC_LIBOBJ invocations to module description.
81216         * m4/wcswidth.m4 (gl_FUNC_WCSWIDTH): Move AC_LIBOBJ invocation from
81217         here...
81218         * modules/wcswidth (configure.ac): ... to here.
81220 2011-05-22  Bruno Haible  <bruno@clisp.org>
81222         wcwidth: Respect rules for use of AC_LIBOBJ.
81223         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Set HAVE_WCWIDTH. Move AC_LIBOBJ
81224         invocation from here...
81225         * modules/wcwidth (configure.ac): ... to here.
81226         (Depends-on): Update conditions.
81228 2011-05-22  Bruno Haible  <bruno@clisp.org>
81230         wctype: Move AC_LIBOBJ invocations to module description.
81231         * m4/wctype.m4 (gl_FUNC_WCTYPE): Set HAVE_WCTYPE. Move AC_LIBOBJ
81232         invocation from here...
81233         * modules/wctype (configure.ac): ... to here.
81234         (Depends-on): Update conditions.
81236 2011-05-22  Bruno Haible  <bruno@clisp.org>
81238         wctrans: Move AC_LIBOBJ invocations to module description.
81239         * m4/wctrans.m4 (gl_FUNC_WCTRANS): Set HAVE_WCTRANS. Move AC_LIBOBJ
81240         invocation from here...
81241         * modules/wctrans (configure.ac): ... to here.
81243 2011-05-22  Bruno Haible  <bruno@clisp.org>
81245         wctomb: Move AC_LIBOBJ invocations to module description.
81246         * m4/wctomb.m4 (gl_FUNC_WCTOMB): Move AC_LIBOBJ and gl_PREREQ_WCTOMB
81247         invocations from here...
81248         * modules/wctomb (configure.ac): ... to here.
81250 2011-05-22  Bruno Haible  <bruno@clisp.org>
81252         wctob: Move AC_LIBOBJ invocations to module description.
81253         * m4/wctob.m4 (gl_FUNC_WCTOB): Set HAVE_WCTOB. Move AC_LIBOBJ and
81254         gl_PREREQ_WCTOB invocations from here...
81255         * modules/wctob (configure.ac): ... to here.
81256         (Depends-on): Update conditions.
81258 2011-05-22  Bruno Haible  <bruno@clisp.org>
81260         wcsxfrm: Move AC_LIBOBJ invocations to module description.
81261         * m4/wcsxfrm.m4 (gl_FUNC_WCSXFRM): Move AC_LIBOBJ invocation from
81262         here...
81263         * modules/wcsxfrm (configure.ac): ... to here.
81265 2011-05-22  Bruno Haible  <bruno@clisp.org>
81267         wcstok: Move AC_LIBOBJ invocations to module description.
81268         * m4/wcstok.m4 (gl_FUNC_WCSTOK): Move AC_LIBOBJ invocation from here...
81269         * modules/wcstok (configure.ac): ... to here.
81271 2011-05-22  Bruno Haible  <bruno@clisp.org>
81273         wcsstr: Move AC_LIBOBJ invocations to module description.
81274         * m4/wcsstr.m4 (gl_FUNC_WCSSTR): Move AC_LIBOBJ invocation from here...
81275         * modules/wcsstr (configure.ac): ... to here.
81277 2011-05-22  Bruno Haible  <bruno@clisp.org>
81279         wcsspn: Move AC_LIBOBJ invocations to module description.
81280         * m4/wcsspn.m4 (gl_FUNC_WCSSPN): Move AC_LIBOBJ invocation from here...
81281         * modules/wcsspn (configure.ac): ... to here.
81283 2011-05-22  Bruno Haible  <bruno@clisp.org>
81285         wcsrtombs: Move AC_LIBOBJ invocations to module description.
81286         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): Move AC_LIBOBJ and
81287         gl_PREREQ_WCSRTOMBS invocations from here...
81288         * modules/wcsrtombs (configure.ac): ... to here.
81290 2011-05-22  Bruno Haible  <bruno@clisp.org>
81292         wcsrchr: Move AC_LIBOBJ invocations to module description.
81293         * m4/wcsrchr.m4 (gl_FUNC_WCSRCHR): Move AC_LIBOBJ invocation from
81294         here...
81295         * modules/wcsrchr (configure.ac): ... to here.
81297 2011-05-22  Bruno Haible  <bruno@clisp.org>
81299         wcspbrk: Move AC_LIBOBJ invocations to module description.
81300         * m4/wcspbrk.m4 (gl_FUNC_WCSPBRK): Move AC_LIBOBJ invocation from
81301         here...
81302         * modules/wcspbrk (configure.ac): ... to here.
81304 2011-05-22  Bruno Haible  <bruno@clisp.org>
81306         wcsnrtombs: Move AC_LIBOBJ invocations to module description.
81307         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): Move AC_LIBOBJ and
81308         gl_PREREQ_WCSNRTOMBS invocations from here...
81309         * modules/wcsnrtombs (configure.ac): ... to here.
81311 2011-05-22  Bruno Haible  <bruno@clisp.org>
81313         wcsnlen: Move AC_LIBOBJ invocations to module description.
81314         * m4/wcsnlen.m4 (gl_FUNC_WCSNLEN): Move AC_LIBOBJ invocation from
81315         here...
81316         * modules/wcsnlen (configure.ac): ... to here.
81318 2011-05-22  Bruno Haible  <bruno@clisp.org>
81320         wcsncpy: Move AC_LIBOBJ invocations to module description.
81321         * m4/wcsncpy.m4 (gl_FUNC_WCSNCPY): Move AC_LIBOBJ invocation from
81322         here...
81323         * modules/wcsncpy (configure.ac): ... to here.
81325 2011-05-22  Bruno Haible  <bruno@clisp.org>
81327         wcsncmp: Move AC_LIBOBJ invocations to module description.
81328         * m4/wcsncmp.m4 (gl_FUNC_WCSNCMP): Move AC_LIBOBJ invocation from
81329         here...
81330         * modules/wcsncmp (configure.ac): ... to here.
81332 2011-05-22  Bruno Haible  <bruno@clisp.org>
81334         wcsncat: Move AC_LIBOBJ invocations to module description.
81335         * m4/wcsncat.m4 (gl_FUNC_WCSNCAT): Move AC_LIBOBJ invocation from
81336         here...
81337         * modules/wcsncat (configure.ac): ... to here.
81339 2011-05-22  Bruno Haible  <bruno@clisp.org>
81341         wcsncasecmp: Move AC_LIBOBJ invocations to module description.
81342         * m4/wcsncasecmp.m4 (gl_FUNC_WCSNCASECMP): Move AC_LIBOBJ invocation
81343         from here...
81344         * modules/wcsncasecmp (configure.ac): ... to here.
81346 2011-05-22  Bruno Haible  <bruno@clisp.org>
81348         wcslen: Move AC_LIBOBJ invocations to module description.
81349         * m4/wcslen.m4 (gl_FUNC_WCSLEN): Move AC_LIBOBJ invocation from here...
81350         * modules/wcslen (configure.ac): ... to here.
81352 2011-05-22  Bruno Haible  <bruno@clisp.org>
81354         wcsdup: Move AC_LIBOBJ invocations to module description.
81355         * m4/wcsdup.m4 (gl_FUNC_WCSDUP): Move AC_LIBOBJ invocation from here...
81356         * modules/wcsdup (configure.ac): ... to here.
81358 2011-05-22  Bruno Haible  <bruno@clisp.org>
81360         wcscspn: Move AC_LIBOBJ invocations to module description.
81361         * m4/wcscspn.m4 (gl_FUNC_WCSCSPN): Move AC_LIBOBJ invocation from
81362         here...
81363         * modules/wcscspn (configure.ac): ... to here.
81365 2011-05-22  Bruno Haible  <bruno@clisp.org>
81367         wcscpy: Move AC_LIBOBJ invocations to module description.
81368         * m4/wcscpy.m4 (gl_FUNC_WCSCPY): Move AC_LIBOBJ invocation from here...
81369         * modules/wcscpy (configure.ac): ... to here.
81371 2011-05-22  Bruno Haible  <bruno@clisp.org>
81373         wcscoll: Move AC_LIBOBJ invocations to module description.
81374         * m4/wcscoll.m4 (gl_FUNC_WCSCOLL): Move AC_LIBOBJ invocation from
81375         here...
81376         * modules/wcscoll (configure.ac): ... to here.
81378 2011-05-22  Bruno Haible  <bruno@clisp.org>
81380         wcscmp: Move AC_LIBOBJ invocations to module description.
81381         * m4/wcscmp.m4 (gl_FUNC_WCSCMP): Move AC_LIBOBJ invocation from here...
81382         * modules/wcscmp (configure.ac): ... to here.
81384 2011-05-22  Bruno Haible  <bruno@clisp.org>
81386         wcschr: Move AC_LIBOBJ invocations to module description.
81387         * m4/wcschr.m4 (gl_FUNC_WCSCHR): Move AC_LIBOBJ invocation from here...
81388         * modules/wcschr (configure.ac): ... to here.
81390 2011-05-22  Bruno Haible  <bruno@clisp.org>
81392         wcscat: Move AC_LIBOBJ invocations to module description.
81393         * m4/wcscat.m4 (gl_FUNC_WCSCAT): Move AC_LIBOBJ invocation from here...
81394         * modules/wcscat (configure.ac): ... to here.
81396 2011-05-22  Bruno Haible  <bruno@clisp.org>
81398         wcscasecmp: Move AC_LIBOBJ invocations to module description.
81399         * m4/wcscasecmp.m4 (gl_FUNC_WCSCASECMP): Move AC_LIBOBJ invocation from
81400         here...
81401         * modules/wcscasecmp (configure.ac): ... to here.
81403 2011-05-22  Bruno Haible  <bruno@clisp.org>
81405         wcrtomb: Move AC_LIBOBJ invocations to module description.
81406         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Move AC_LIBOBJ and gl_PREREQ_WCRTOMB
81407         invocations from here...
81408         * modules/wcrtomb (configure.ac): ... to here.
81410 2011-05-22  Bruno Haible  <bruno@clisp.org>
81412         wcpncpy: Move AC_LIBOBJ invocations to module description.
81413         * m4/wcpncpy.m4 (gl_FUNC_WCPNCPY): Move AC_LIBOBJ invocation from
81414         here...
81415         * modules/wcpncpy (configure.ac): ... to here.
81417 2011-05-22  Bruno Haible  <bruno@clisp.org>
81419         wcpcpy: Move AC_LIBOBJ invocations to module description.
81420         * m4/wcpcpy.m4 (gl_FUNC_WCPCPY): Move AC_LIBOBJ invocation from here...
81421         * modules/wcpcpy (configure.ac): ... to here.
81423 2011-05-22  Bruno Haible  <bruno@clisp.org>
81425         waitpid: Move AC_LIBOBJ invocations to module description.
81426         * m4/waitpid.m4 (gl_FUNC_WAITPID): Set HAVE_WAITPID. Move AC_LIBOBJ
81427         invocation from here...
81428         * modules/waitpid (configure.ac): ... to here.
81430 2011-05-22  Bruno Haible  <bruno@clisp.org>
81432         utimensat: Move AC_LIBOBJ invocations to module description.
81433         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Move AC_LIBOBJ invocations from
81434         here...
81435         * modules/utimensat (configure.ac): ... to here.
81437 2011-05-22  Bruno Haible  <bruno@clisp.org>
81439         usleep: Move AC_LIBOBJ invocations to module description.
81440         * m4/usleep.m4 (gl_FUNC_USLEEP): Move AC_LIBOBJ invocations from
81441         here...
81442         * modules/usleep (configure.ac): ... to here.
81444 2011-05-22  Bruno Haible  <bruno@clisp.org>
81446         unlockpt: Move AC_LIBOBJ invocations to module description.
81447         * m4/unlockpt.m4 (gl_FUNC_UNLOCKPT): Move AC_LIBOBJ and
81448         gl_PREREQ_UNLOCKPT invocations from here...
81449         * modules/unlockpt (configure.ac): ... to here.
81451 2011-05-22  Bruno Haible  <bruno@clisp.org>
81453         unlink: Respect rules for use of AC_LIBOBJ.
81454         * m4/unlink.m4 (gl_FUNC_UNLINK): Move AC_LIBOBJ invocation from here...
81455         * modules/unlink (configure.ac): ... to here.
81457 2011-05-22  Bruno Haible  <bruno@clisp.org>
81459         uname: Move AC_LIBOBJ invocations to module description.
81460         * m4/uname.m4 (gl_FUNC_UNAME): Call AC_CHECK_FUNCS instead of
81461         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_UNAME invocations from
81462         here...
81463         * modules/uname (configure.ac): ... to here.
81465 2011-05-22  Bruno Haible  <bruno@clisp.org>
81467         ttyname_r: Move AC_LIBOBJ invocations to module description.
81468         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Move AC_LIBOBJ and
81469         gl_PREREQ_TTYNAME_R invocations from here...
81470         * modules/ttyname_r (configure.ac): ... to here.
81472 2011-05-22  Bruno Haible  <bruno@clisp.org>
81474         tsearch: Move AC_LIBOBJ invocations to module description.
81475         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Move AC_LIBOBJ and gl_PREREQ_TSEARCH
81476         invocations from here...
81477         * modules/tsearch (configure.ac): ... to here.
81479 2011-05-22  Bruno Haible  <bruno@clisp.org>
81481         towctrans: Move AC_LIBOBJ invocations to module description.
81482         * m4/towctrans.m4 (gl_FUNC_TOWCTRANS): Set HAVE_TOWCTRANS. Move
81483         AC_LIBOBJ invocation from here...
81484         * modules/towctrans (configure.ac): ... to here.
81486 2011-05-22  Bruno Haible  <bruno@clisp.org>
81488         tmpfile: Move AC_LIBOBJ invocations to module description.
81489         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Move AC_LIBOBJ and gl_PREREQ_TMPFILE
81490         invocations from here...
81491         * modules/tmpfile (configure.ac): ... to here.
81493 2011-05-22  Bruno Haible  <bruno@clisp.org>
81495         times: Move AC_LIBOBJ invocations to module description.
81496         * m4/times.m4 (gl_FUNC_TIMES): Move AC_LIBOBJ invocation from here...
81497         * modules/times (configure.ac): ... to here.
81499 2011-05-22  Bruno Haible  <bruno@clisp.org>
81501         time_r: Move AC_LIBOBJ invocations to module description.
81502         * m4/time_r.m4 (gl_TIME_R): Move AC_LIBOBJ and gl_PREREQ_TIME_R
81503         invocations from here...
81504         * modules/time_r (configure.ac): ... to here.
81506 2011-05-22  Bruno Haible  <bruno@clisp.org>
81508         timegm: Move AC_LIBOBJ invocations to module description.
81509         * m4/timegm.m4 (gl_FUNC_TIMEGM): Move AC_LIBOBJ and gl_PREREQ_TIMEGM
81510         invocations from here...
81511         * modules/timegm (configure.ac): ... to here.
81513 2011-05-22  Bruno Haible  <bruno@clisp.org>
81515         tcgetsid: Move AC_LIBOBJ invocations to module description.
81516         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Set HAVE_TCGETSID. Move AC_LIBOBJ
81517         and gl_PREREQ_TCGETSID invocations from here...
81518         * modules/tcgetsid (configure.ac): ... to here.
81519         (Depends-on): Update conditions.
81521 2011-05-22  Bruno Haible  <bruno@clisp.org>
81523         symlinkat: Move AC_LIBOBJ invocations to module description.
81524         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Move AC_LIBOBJ invocation from
81525         here...
81526         * modules/symlinkat (configure.ac): ... to here.
81528 2011-05-22  Bruno Haible  <bruno@clisp.org>
81530         symlink: Move AC_LIBOBJ invocations to module description.
81531         * m4/symlink.m4 (gl_FUNC_SYMLINK): Move AC_LIBOBJ invocations from
81532         here...
81533         * modules/symlink (configure.ac): ... to here.
81535 2011-05-22  Bruno Haible  <bruno@clisp.org>
81537         strverscmp: Move AC_LIBOBJ invocations to module description.
81538         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Call AC_CHECK_FUNCS instead of
81539         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRVERSCMP invocations
81540         from here...
81541         * modules/strverscmp (configure.ac): ... to here.
81543 2011-05-22  Bruno Haible  <bruno@clisp.org>
81545         strtok_r: Move AC_LIBOBJ invocations to module description.
81546         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_STRTOK_R. Move AC_LIBOBJ
81547         and gl_PREREQ_STRTOK_R invocations from here...
81548         * modules/strtok_r (configure.ac): ... to here.
81549         (Depends-on): Update conditions.
81551 2011-05-22  Bruno Haible  <bruno@clisp.org>
81553         strtoumax: Move AC_LIBOBJ invocations to module description.
81554         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Call AC_CHECK_FUNCS instead of
81555         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOUMAX invocations
81556         from here...
81557         * modules/strtoumax (configure.ac): ... to here.
81559 2011-05-22  Bruno Haible  <bruno@clisp.org>
81561         strtoimax: Move AC_LIBOBJ invocations to module description.
81562         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Call AC_CHECK_FUNCS instead of
81563         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOIMAX invocations
81564         from here...
81565         * modules/strtoimax (configure.ac): ... to here.
81567 2011-05-22  Bruno Haible  <bruno@clisp.org>
81569         strtoull: Move AC_LIBOBJ invocations to module description.
81570         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Call AC_CHECK_FUNCS instead of
81571         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOULL invocations
81572         from here...
81573         * modules/strtoull (configure.ac): ... to here.
81575 2011-05-22  Bruno Haible  <bruno@clisp.org>
81577         strtoll: Move AC_LIBOBJ invocations to module description.
81578         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Call AC_CHECK_FUNCS instead of
81579         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRTOLL invocations from
81580         here...
81581         * modules/strtoll (configure.ac): ... to here.
81583 2011-05-22  Bruno Haible  <bruno@clisp.org>
81585         strtoul: Move AC_LIBOBJ invocations to module description.
81586         * m4/strtoul.m4 (gl_FUNC_STRTOUL): Call AC_CHECK_FUNCS instead of
81587         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocation from here...
81588         * modules/strtoul (configure.ac): ... to here.
81590 2011-05-22  Bruno Haible  <bruno@clisp.org>
81592         strtol: Move AC_LIBOBJ invocations to module description.
81593         * m4/strtol.m4 (gl_FUNC_STRTOL): Call AC_CHECK_FUNCS instead of
81594         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocation from here...
81595         * modules/strtol (configure.ac): ... to here.
81597 2011-05-22  Bruno Haible  <bruno@clisp.org>
81599         strtod: Move AC_LIBOBJ invocations to module description.
81600         * m4/strtod.m4 (gl_FUNC_STRTOD): Move AC_LIBOBJ and gl_PREREQ_STRTOD
81601         invocations from here...
81602         * modules/strtod (configure.ac): ... to here.
81604 2011-05-22  Bruno Haible  <bruno@clisp.org>
81606         strstr*: Move AC_LIBOBJ invocations to module description.
81607         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Move AC_LIBOBJ
81608         invocations from here...
81609         * modules/strstr-simple (configure.ac): ... to here.
81610         * modules/strstr (configure.ac): ... and here.
81612 2011-05-22  Bruno Haible  <bruno@clisp.org>
81614         strsignal: Move AC_LIBOBJ invocations to module description.
81615         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Set HAVE_STRSIGNAL. Move
81616         AC_LIBOBJ and gl_PREREQ_STRSIGNAL invocations from here...
81617         * modules/strsignal (configure.ac): ... to here.
81618         (Depends-on): Update conditions.
81620 2011-05-22  Bruno Haible  <bruno@clisp.org>
81622         strsep: Move AC_LIBOBJ invocations to module description.
81623         * m4/strsep.m4 (gl_FUNC_STRSEP): Call AC_CHECK_FUNCS instead of
81624         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRSEP invocations from
81625         here...
81626         * modules/strsep (configure.ac): ... to here.
81628 2011-05-22  Bruno Haible  <bruno@clisp.org>
81630         strptime: Move AC_LIBOBJ invocations to module description.
81631         * m4/strptime.m4 (gl_FUNC_STRPTIME): Move AC_LIBOBJ and
81632         gl_PREREQ_STRPTIME invocations from here...
81633         * modules/strptime (configure.ac): ... to here.
81635 2011-05-22  Bruno Haible  <bruno@clisp.org>
81637         strpbrk: Move AC_LIBOBJ invocations to module description.
81638         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Call AC_CHECK_FUNCS instead of
81639         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRPBRK invocations from
81640         here...
81641         * modules/strpbrk (configure.ac): ... to here.
81643 2011-05-22  Bruno Haible  <bruno@clisp.org>
81645         strnlen: Move AC_LIBOBJ invocations to module description.
81646         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Move AC_LIBOBJ and gl_PREREQ_STRNLEN
81647         invocations from here...
81648         * modules/strnlen (configure.ac): ... to here.
81650 2011-05-22  Bruno Haible  <bruno@clisp.org>
81652         strndup: Move AC_LIBOBJ invocations to module description.
81653         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_STRNDUP. Move AC_LIBOBJ
81654         invocations from here...
81655         * modules/strndup (configure.ac): ... to here.
81656         (Depends-on): Update conditions.
81658 2011-05-22  Bruno Haible  <bruno@clisp.org>
81660         strncat: Move AC_LIBOBJ invocations to module description.
81661         * m4/strncat.m4 (gl_FUNC_STRNCAT): Move AC_LIBOBJ and gl_PREREQ_STRNCAT
81662         invocations from here...
81663         * modules/strncat (configure.ac): ... to here.
81665 2011-05-22  Bruno Haible  <bruno@clisp.org>
81667         strdup, strdup-posix: Move AC_LIBOBJ invocations to module description.
81668         * m4/strdup.m4 (gl_FUNC_STRDUP): Move AC_LIBOBJ and gl_PREREQ_STRDUP
81669         invocations from here...
81670         * modules/strdup (configure.ac): ... to here.
81671         * modules/strdup-posix (configure.ac): ... and here.
81673 2011-05-22  Bruno Haible  <bruno@clisp.org>
81675         strcspn: Move AC_LIBOBJ invocations to module description.
81676         * m4/strcspn.m4 (gl_FUNC_STRCSPN): Call AC_CHECK_FUNCS instead of
81677         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STRCSPN invocations from
81678         here...
81679         * modules/strcspn (configure.ac): ... to here.
81681 2011-05-22  Bruno Haible  <bruno@clisp.org>
81683         strchrnul: Move AC_LIBOBJ invocations to module description.
81684         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Move AC_LIBOBJ and
81685         gl_PREREQ_STRCHRNUL invocations from here...
81686         * modules/strchrnul (configure.ac): ... to here.
81688 2011-05-22  Bruno Haible  <bruno@clisp.org>
81690         strcasestr*: Move AC_LIBOBJ invocations to module description.
81691         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE, gl_FUNC_STRCASESTR):
81692         Move AC_LIBOBJ and gl_PREREQ_STRCASESTR invocations from here...
81693         * modules/strcasestr-simple (configure.ac): ... to here.
81694         * modules/strcasestr (configure.ac): ... and here.
81696 2011-05-22  Bruno Haible  <bruno@clisp.org>
81698         strcase: Move AC_LIBOBJ invocations to module description.
81699         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Set HAVE_STRNCASECMP.
81700         (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Call AC_CHECK_FUNCS instead
81701         of AC_REPLACE_FUNCS. Move AC_LIBOBJ, gl_PREREQ_STRCASECMP,
81702         gl_PREREQ_STRNCASECMP invocations from here...
81703         * modules/strcase (configure.ac): ... to here.
81705 2011-05-22  Bruno Haible  <bruno@clisp.org>
81707         stpncpy: Move AC_LIBOBJ invocations to module description.
81708         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Move AC_LIBOBJ invocations from
81709         here...
81710         * modules/stpncpy (configure.ac): ... to here.
81712 2011-05-22  Bruno Haible  <bruno@clisp.org>
81714         stpcpy: Move AC_LIBOBJ invocations to module description.
81715         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Call AC_CHECK_FUNCS instead of
81716         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_STPCPY invocations from
81717         here...
81718         * modules/stpcpy (configure.ac): ... to here.
81720 2011-05-21  Bruno Haible  <bruno@clisp.org>
81722         stat: Move AC_LIBOBJ invocations to module description.
81723         * m4/stat.m4 (gl_PREREQ_STAT): New macro, extracted from gl_FUNC_STAT.
81724         (gl_FUNC_STAT): Move AC_LIBOBJ and gl_PREREQ_STAT invocations from
81725         here...
81726         * modules/stat (configure.ac): ... to here.
81728 2011-05-21  Bruno Haible  <bruno@clisp.org>
81730         sleep: Move AC_LIBOBJ invocations to module description.
81731         * m4/sleep.m4 (gl_FUNC_SLEEP): Move AC_LIBOBJ invocations from here...
81732         * modules/sleep (configure.ac): ... to here.
81734 2011-05-21  Bruno Haible  <bruno@clisp.org>
81736         signbit: Move AC_LIBOBJ invocations to module description.
81737         * m4/signbit.m4 (gl_SIGNBIT): Move AC_LIBOBJ invocations from here...
81738         * modules/signbit (configure.ac): ... to here.
81740 2011-05-21  Bruno Haible  <bruno@clisp.org>
81742         sigprocmask: Move AC_LIBOBJ invocations to module description.
81743         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Move AC_LIBOBJ and
81744         gl_PREREQ_SIGPROMASK invocations from here...
81745         * modules/sigprocmask (configure.ac): ... to here.
81747 2011-05-21  Bruno Haible  <bruno@clisp.org>
81749         sigaction: Move AC_LIBOBJ invocations to module description.
81750         * m4/sigaction.m4 (gl_SIGACTION): Move AC_LIBOBJ and
81751         gl_PREREQ_SIGACTION invocations from here...
81752         * modules/sigaction (configure.ac): ... to here.
81754 2011-05-21  Bruno Haible  <bruno@clisp.org>
81756         sig2str: Move AC_LIBOBJ invocations to module description.
81757         * m4/sig2str.m4 (gl_FUNC_SIG2STR): Call AC_CHECK_FUNCS instead of
81758         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_SIG2STR invocations from
81759         here...
81760         * modules/sig2str (configure.ac): ... to here.
81762 2011-05-21  Bruno Haible  <bruno@clisp.org>
81764         setlocale: Move AC_LIBOBJ invocations to module description.
81765         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Move AC_LIBOBJ and
81766         gl_PREREQ_SETLOCALE invocations from here...
81767         * modules/setlocale (configure.ac): ... to here.
81769 2011-05-21  Bruno Haible  <bruno@clisp.org>
81771         unsetenv: Move AC_LIBOBJ invocations to module description.
81772         * m4/setenv.m4 (gl_FUNC_UNSETENV): Set HAVE_UNSETENV. Move AC_LIBOBJ
81773         and gl_PREREQ_UNSETENV invocations from here...
81774         * modules/unsetenv (configure.ac): ... to here.
81775         (Depends-on): Update.
81777 2011-05-21  Bruno Haible  <bruno@clisp.org>
81779         setenv: Move AC_LIBOBJ invocations to module description.
81780         * m4/setenv.m4 (gl_FUNC_SETENV): Move AC_LIBOBJ invocations from
81781         here...
81782         * modules/setenv (configure.ac): ... to here.
81784 2011-05-21  Bruno Haible  <bruno@clisp.org>
81786         selinux-h: Move AC_LIBOBJ invocations to module description.
81787         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Move
81788         AC_LIBOBJ invocation from here...
81789         * modules/selinux-h (configure.ac): ... to here.
81791 2011-05-21  Bruno Haible  <bruno@clisp.org>
81793         select: Respect rules for use of AC_LIBOBJ.
81794         * m4/select.m4 (gl_FUNC_SELECT): Move AC_LIBOBJ invocations from
81795         here...
81796         * modules/select (configure.ac): ... to here.
81798 2011-05-21  Bruno Haible  <bruno@clisp.org>
81800         scandir: Move AC_LIBOBJ invocations to module description.
81801         * m4/scandir.m4 (gl_FUNC_SCANDIR): Move AC_LIBOBJ and gl_PREREQ_SCANDIR
81802         invocations from here...
81803         * modules/scandir (configure.ac): ... to here.
81805 2011-05-21  Bruno Haible  <bruno@clisp.org>
81807         rpmatch: Move AC_LIBOBJ invocations to module description.
81808         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Call AC_CHECK_FUNCS instead of
81809         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_RPMATCH invocations from
81810         here...
81811         * modules/rpmatch (configure.ac): ... to here.
81813 2011-05-21  Bruno Haible  <bruno@clisp.org>
81815         rmdir: Respect rules for use of AC_LIBOBJ.
81816         * m4/rmdir.m4 (gl_FUNC_RMDIR): Move AC_LIBOBJ invocation from here...
81817         * modules/rmdir (configure.ac): ... to here.
81819 2011-05-21  Bruno Haible  <bruno@clisp.org>
81821         renameat: Move AC_LIBOBJ invocations to module description.
81822         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Move AC_LIBOBJ invocations from
81823         here...
81824         * modules/renameat (configure.ac): ... to here.
81826 2011-05-21  Bruno Haible  <bruno@clisp.org>
81828         rename: Respect rules for use of AC_LIBOBJ.
81829         * m4/rename.m4 (gl_FUNC_RENAME): Move AC_LIBOBJ invocations from
81830         here...
81831         * modules/rename (configure.ac): ... to here.
81833 2011-05-21  Bruno Haible  <bruno@clisp.org>
81835         remove: Move AC_LIBOBJ invocations to module description.
81836         * m4/remove.m4 (gl_FUNC_REMOVE): Move AC_LIBOBJ invocations from
81837         here...
81838         * modules/remove (configure.ac): ... to here.
81840 2011-05-21  Bruno Haible  <bruno@clisp.org>
81842         relocatable-lib: Move AC_LIBOBJ invocations to module description.
81843         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_SEPARATE): Remove
81844         macro.
81845         (gl_RELOCATABLE_LIBRARY): Move AC_LIBOBJ invocation from here...
81846         * modules/relocatable-lib (configure.ac): ... to here.
81847         * modules/relocatable-prog-wrapper (configure.ac): Invoke
81848         gl_RELOCATABLE_LIBRARY instead of gl_RELOCATABLE_LIBRARY_SEPARATE.
81850 2011-05-21  Bruno Haible  <bruno@clisp.org>
81852         relocatable-prog: Move AC_LIBOBJ invocations to module description.
81853         * m4/relocatable.m4 (gl_RELOCATABLE): Move AC_LIBOBJ invocation from
81854         here...
81855         * modules/relocatable-prog (configure.ac): ... to here.
81857 2011-05-21  Bruno Haible  <bruno@clisp.org>
81859         regex: Move AC_LIBOBJ invocations to module description.
81860         * m4/regex.m4 (gl_REGEX): Move AC_LIBOBJ and gl_PREREQ_REGEX
81861         invocations from here...
81862         * modules/regex (configure.ac): ... to here.
81864 2011-05-21  Bruno Haible  <bruno@clisp.org>
81866         realloc-*: Move AC_LIBOBJ invocations to module description.
81867         * m4/realloc.m4 (gl_REPLACE_REALLOC): Remove macro.
81868         (gl_FUNC_REALLOC_GNU, gl_FUNC_REALLOC_POSIX): Inline it here. Move
81869         AC_LIBOBJ invocations from here...
81870         * modules/realloc-gnu (configure.ac): ... to here.
81871         * modules/realloc-posix (configure.ac): ... and here.
81873 2011-05-21  Bruno Haible  <bruno@clisp.org>
81875         readutmp: Move AC_LIBOBJ invocations to module description.
81876         * m4/readutmp.m4 (gl_READUTMP): Move AC_LIBOBJ invocation from here...
81877         * modules/readutmp (configure.ac): ... to here.
81879 2011-05-21  Bruno Haible  <bruno@clisp.org>
81881         readlinkat: Move AC_LIBOBJ invocations to module description.
81882         * m4/readlinkat.m4 (gl_FUNC_READLINKAT): Move AC_LIBOBJ invocation from
81883         here...
81884         * modules/readlinkat (configure.ac): ... to here.
81886 2011-05-21  Bruno Haible  <bruno@clisp.org>
81888         readlink: Move AC_LIBOBJ invocations to module description.
81889         * m4/readlink.m4 (gl_FUNC_READLINK): Move AC_LIBOBJ and
81890         gl_PREREQ_READLINK invocations from here...
81891         * modules/readlink (configure.ac): ... to here.
81893 2011-05-21  Bruno Haible  <bruno@clisp.org>
81895         readline: Move AC_LIBOBJ invocations to module description.
81896         * m4/readline.m4 (gl_FUNC_READLINE): Move AC_LIBOBJ and
81897         gl_PREREQ_READLINE invocations from here...
81898         * modules/readline (configure.ac): ... to here.
81900 2011-05-21  Bruno Haible  <bruno@clisp.org>
81902         read: Move AC_LIBOBJ invocations to module description.
81903         * m4/read.m4 (gl_FUNC_READ): Move AC_LIBOBJ invocation from here...
81904         * modules/read (configure.ac): ... to here.
81906 2011-05-21  Bruno Haible  <bruno@clisp.org>
81908         rawmemchr: Move AC_LIBOBJ invocations to module description.
81909         * m4/rawmemchr.m4 (gl_FUNC_RAWMEMCHR): Call AC_CHECK_FUNCS instead of
81910         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_RAWMEMCHR invocations
81911         from here...
81912         * modules/rawmemchr (configure.ac): ... to here.
81914 2011-05-21  Bruno Haible  <bruno@clisp.org>
81916         random_r: Move AC_LIBOBJ invocations to module description.
81917         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Move AC_LIBOBJ and
81918         gl_PREREQ_RANDOM_R invocations from here...
81919         * modules/random_r (configure.ac): ... to here.
81921 2011-05-21  Bruno Haible  <bruno@clisp.org>
81923         pwrite: Move AC_LIBOBJ invocations to module description.
81924         * m4/pwrite.m4 (gl_FUNC_PWRITE): Move AC_LIBOBJ invocation from here...
81925         * modules/pwrite (configure.ac): ... to here.
81927 2011-05-21  Bruno Haible  <bruno@clisp.org>
81929         putenv: Move AC_LIBOBJ invocations to module description.
81930         * m4/putenv.m4 (gl_FUNC_PUTENV): Move AC_LIBOBJ invocation from here...
81931         * modules/putenv (configure.ac): ... to here.
81933 2011-05-21  Bruno Haible  <bruno@clisp.org>
81935         login_tty: Move AC_LIBOBJ invocations to module description.
81936         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Move AC_LIBOBJ invocation from here...
81937         * modules/login_tty (configure.ac): ... to here.
81939 2011-05-21  Bruno Haible  <bruno@clisp.org>
81941         openpty: Move AC_LIBOBJ invocations to module description.
81942         * m4/pty.m4 (gl_FUNC_OPENPTY): Move AC_LIBOBJ invocations from here...
81943         * modules/openpty (configure.ac): ... to here.
81945 2011-05-21  Bruno Haible  <bruno@clisp.org>
81947         forkpty: Move AC_LIBOBJ invocations to module description.
81948         * m4/pty.m4 (gl_FUNC_FORKPTY): Move AC_LIBOBJ invocations from here...
81949         * modules/forkpty (configure.ac): ... to here.
81951 2011-05-21  Bruno Haible  <bruno@clisp.org>
81953         ptsname: Move AC_LIBOBJ invocations to module description.
81954         * m4/ptsname.m4 (gl_FUNC_PTSNAME): Move AC_LIBOBJ and gl_PREREQ_PTSNAME
81955         invocations from here...
81956         * modules/ptsname (configure.ac): ... to here.
81958 2011-05-21  Bruno Haible  <bruno@clisp.org>
81960         pread: Move AC_LIBOBJ invocations to module description.
81961         * m4/pread.m4 (gl_FUNC_PREAD): Move AC_LIBOBJ invocation from here...
81962         * modules/pread (configure.ac): ... to here.
81964 2011-05-21  Bruno Haible  <bruno@clisp.org>
81966         posix_spawn*: Move AC_LIBOBJ invocations to module description.
81967         * m4/posix_spawn.m4 (gl_PREREQ_POSIX_SPAWN_INTERNAL): Renamed from
81968         gl_POSIX_SPAWN_INTERNAL. Move AC_LIBOBJ invocation from here...
81969         * modules/posix_spawn (configure.ac): ... to here.
81970         * modules/posix_spawnp (configure.ac): ... and here.
81972 2011-05-21  Bruno Haible  <bruno@clisp.org>
81974         popen: Move AC_LIBOBJ invocations to module description.
81975         * m4/popen.m4 (gl_FUNC_POPEN): Move AC_LIBOBJ and gl_PREREQ_POPEN
81976         invocations from here...
81977         * modules/popen (configure.ac): ... to here.
81979 2011-05-21  Bruno Haible  <bruno@clisp.org>
81981         poll: Move AC_LIBOBJ invocations to module description.
81982         * m4/poll.m4 (gl_FUNC_POLL): Move AC_LIBOBJ and gl_PREREQ_POLL
81983         invocations from here...
81984         * modules/poll (configure.ac): ... to here.
81986 2011-05-21  Bruno Haible  <bruno@clisp.org>
81988         pipe-posix: Move AC_LIBOBJ invocations to module description.
81989         * m4/pipe.m4 (gl_FUNC_PIPE): Move AC_LIBOBJ invocation from here...
81990         * modules/pipe-posix (configure.ac): ... to here.
81992 2011-05-21  Bruno Haible  <bruno@clisp.org>
81994         openat: Respect rules for use of AC_LIBOBJ.
81995         * m4/openat.m4 (gl_FUNC_OPENAT): Call AC_CHECK_FUNCS instead of
81996         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocations from here...
81997         * modules/openat (configure.ac): ... to here.
81999 2011-05-21  Bruno Haible  <bruno@clisp.org>
82001         obstack-printf*: Move AC_LIBOBJ invocations to module description.
82002         * m4/obstack-printf.m4 (gl_REPLACE_OBSTACK_PRINTF): Move AC_LIBOBJ
82003         invocation from here...
82004         * modules/obstack-printf (configure.ac): ... to here.
82005         * modules/obstack-printf-posix (configure.ac): ... and here.
82007 2011-05-21  Bruno Haible  <bruno@clisp.org>
82009         nl_langinfo: Move AC_LIBOBJ invocations to module description.
82010         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Move AC_LIBOBJ invocations
82011         from here...
82012         * modules/nl_langinfo (configure.ac): ... to here.
82014 2011-05-21  Bruno Haible  <bruno@clisp.org>
82016         nanosleep: Move AC_LIBOBJ invocations to module description.
82017         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Move AC_LIBOBJ and
82018         gl_PREREQ_NANOSLEEP invocations from here...
82019         * modules/nanosleep (configure.ac): ... to here.
82021 2011-05-21  Bruno Haible  <bruno@clisp.org>
82023         mountlist: Move AC_LIBOBJ invocations to module description.
82024         * m4/mountlist.m4 (gl_MOUNTLIST): Move AC_LIBOBJ and
82025         gl_PREREQ_MOUNTLIST_EXTRA invocations from here...
82026         * modules/mountlist (configure.ac): ... to here.
82028 2011-05-21  Bruno Haible  <bruno@clisp.org>
82030         mktime: Respect rules for use of AC_LIBOBJ.
82031         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove macro.
82032         (gl_FUNC_MKTIME): Inline it here. Set gl_cv_func_working_mktime. Move
82033         AC_LIBOBJ and gl_PREREQ_MKTIME invocations from here...
82034         (gl_FUNC_MKTIME_INTERNAL): ... and here...
82035         * modules/mktime (configure.ac): ... to here.
82036         * modules/mktime-internal (configure.ac): ... and here.
82037         * m4/timegm.m4 (gl_FUNC_TIMEGM): Update.
82039 2011-05-21  Bruno Haible  <bruno@clisp.org>
82041         mkstemps: Move AC_LIBOBJ invocations to module description.
82042         * m4/mkstemps.m4 (gl_FUNC_MKSTEMPS): Move AC_LIBOBJ invocation from
82043         here...
82044         * modules/mkstemps (configure.ac): ... to here.
82046 2011-05-21  Bruno Haible  <bruno@clisp.org>
82048         mkstemp: Move AC_LIBOBJ invocations to module description.
82049         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Move AC_LIBOBJ and
82050         gl_PREREQ_MKSTEMP invocations from here...
82051         * modules/mkstemp (configure.ac): ... to here.
82053 2011-05-21  Bruno Haible  <bruno@clisp.org>
82055         mkostemps: Move AC_LIBOBJ invocations to module description.
82056         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Move AC_LIBOBJ invocation from
82057         here...
82058         * modules/mkostemps (configure.ac): ... to here.
82060 2011-05-21  Bruno Haible  <bruno@clisp.org>
82062         mkostemp: Move AC_LIBOBJ invocations to module description.
82063         * m4/mkostemp.m4 (gl_FUNC_MKOSTEMP): Move AC_LIBOBJ and
82064         gl_PREREQ_MKOSTEMP invocations from here...
82065         * modules/mkostemp (configure.ac): ... to here.
82067 2011-05-21  Bruno Haible  <bruno@clisp.org>
82069         mknod: Move AC_LIBOBJ invocations to module description.
82070         * m4/mknod.m4 (gl_FUNC_MKNOD): Move AC_LIBOBJ invocations from here...
82071         * modules/mknod (configure.ac): ... to here.
82073 2011-05-21  Bruno Haible  <bruno@clisp.org>
82075         mkfifoat: Move AC_LIBOBJ invocations to module description.
82076         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Move AC_LIBOBJ invocations from
82077         here...
82078         * modules/mkfifoat (configure.ac): ... to here.
82080 2011-05-21  Bruno Haible  <bruno@clisp.org>
82082         mkfifo: Respect rules for use of AC_LIBOBJ.
82083         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Move AC_LIBOBJ invocations from
82084         here...
82085         * modules/mkfifo (configure.ac): ... to here.
82087 2011-05-21  Bruno Haible  <bruno@clisp.org>
82089         mkdtemp: Move AC_LIBOBJ invocations to module description.
82090         * m4/mkdtemp.m4 (gl_FUNC_MKDTEMP): Move AC_LIBOBJ and gl_PREREQ_MKDTEMP
82091         invocations from here...
82092         * modules/mkdtemp (configure.ac): ... to here.
82094 2011-05-21  Bruno Haible  <bruno@clisp.org>
82096         mkdir: Move AC_LIBOBJ invocations to module description.
82097         * m4/mkdir.m4 (gl_FUNC_MKDIR): Move AC_LIBOBJ invocations from here...
82098         * modules/mkdir (configure.ac): ... to here.
82100 2011-05-21  Bruno Haible  <bruno@clisp.org>
82102         memset: Move AC_LIBOBJ invocations to module description.
82103         * m4/memset.m4 (gl_FUNC_MEMSET): Call AC_CHECK_FUNCS instead of
82104         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMSET invocations from
82105         here...
82106         * modules/memset (configure.ac): ... to here.
82108 2011-05-21  Bruno Haible  <bruno@clisp.org>
82110         memrchr: Move AC_LIBOBJ invocations to module description.
82111         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Call AC_CHECK_FUNCS instead of
82112         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMRCHR invocations from
82113         here...
82114         * modules/memrchr (configure.ac): ... to here.
82116 2011-05-21  Bruno Haible  <bruno@clisp.org>
82118         mempcpy: Move AC_LIBOBJ invocations to module description.
82119         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Call AC_CHECK_FUNCS instead of
82120         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMPCPY invocations from
82121         here...
82122         * modules/mempcpy (configure.ac): ... to here.
82124 2011-05-21  Bruno Haible  <bruno@clisp.org>
82126         memmove: Move AC_LIBOBJ invocations to module description.
82127         * m4/memmove.m4 (gl_FUNC_MEMMOVE): Call AC_CHECK_FUNCS instead of
82128         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMMOVE invocations from
82129         here...
82130         * modules/memmove (configure.ac): ... to here.
82132 2011-05-21  Bruno Haible  <bruno@clisp.org>
82134         memmem*: Move AC_LIBOBJ invocations to module description.
82135         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Call AC_CHECK_FUNCS instead of
82136         AC_REPLACE_FUNCS. Set HAVE_MEMMEM. Move AC_LIBOBJ invocations from
82137         here...
82138         (gl_FUNC_MEMMEM): ... and here...
82139         * modules/memmem-simple (configure.ac): ... to here.
82140         * modules/memmem (configure.ac): ... and here.
82142 2011-05-21  Bruno Haible  <bruno@clisp.org>
82144         memcpy: Move AC_LIBOBJ invocations to module description.
82145         * m4/memcpy.m4 (gl_FUNC_MEMCPY): Call AC_CHECK_FUNCS instead of
82146         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_MEMCPY invocations from
82147         here...
82148         * modules/memcpy (configure.ac): ... to here.
82150 2011-05-21  Bruno Haible  <bruno@clisp.org>
82152         memcmp: Simplify autoconf macro.
82153         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Merge the cross-compilation code into
82154         the AC_RUN_IFELSE invocation. Set gl_func_memcmp.
82155         * modules/memcmp (Depends-on, configure.ac): Test gl_func_memcmp.
82157 2011-05-21  Bruno Haible  <bruno@clisp.org>
82159         memcmp: Move AC_LIBOBJ invocations to module description.
82160         * m4/memcmp.m4 (AC_FUNC_MEMCMP): Remove macro.
82161         (gl_FUNC_MEMCMP): Inline it here. Set gl_cv_func_memcmp_working. Move
82162         AC_LIBOBJ and gl_PREREQ_MEMCMP invocations from here...
82163         * modules/memcmp (configure.ac): ... to here.
82164         (Depends-on): Update conditions.
82166 2011-05-21  Bruno Haible  <bruno@clisp.org>
82168         memchr: Respect rules for use of AC_LIBOBJ.
82169         * m4/memchr.m4 (gl_FUNC_MEMCHR): Move AC_LIBOBJ and gl_PREREQ_MEMCHR
82170         invocations from here...
82171         * modules/memchr (configure.ac): ... to here.
82173 2011-05-21  Bruno Haible  <bruno@clisp.org>
82175         mbtowc: Move AC_LIBOBJ invocations to module description.
82176         * m4/mbtowc.m4 (gl_FUNC_MBTOWC): Move AC_LIBOBJ and gl_PREREQ_MBTOWC
82177         invocations from here...
82178         * modules/mbtowc (configure.ac): ... to here.
82180 2011-05-21  Bruno Haible  <bruno@clisp.org>
82182         mbsrtowcs: Move AC_LIBOBJ invocations to module description.
82183         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Move AC_LIBOBJ and
82184         gl_PREREQ_MBSRTOWCS invocations from here...
82185         * modules/mbsrtowcs (configure.ac): ... to here.
82187 2011-05-21  Bruno Haible  <bruno@clisp.org>
82189         mbsnrtowcs: Move AC_LIBOBJ invocations to module description.
82190         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): Move AC_LIBOBJ and
82191         gl_PREREQ_MBSNRTOWCS invocations from here...
82192         * modules/mbsnrtowcs (configure.ac): ... to here.
82194 2011-05-21  Bruno Haible  <bruno@clisp.org>
82196         mbsinit: Move AC_LIBOBJ invocations to module description.
82197         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Move AC_LIBOBJ and gl_PREREQ_MBSINIT
82198         invocations from here...
82199         * modules/mbsinit (configure.ac): ... to here.
82201 2011-05-21  Bruno Haible  <bruno@clisp.org>
82203         mbrlen: Move AC_LIBOBJ invocations to module description.
82204         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): Move AC_LIBOBJ and gl_PREREQ_MBRLEN
82205         invocations from here...
82206         * modules/mbrlen (configure.ac): ... to here.
82208 2011-05-21  Bruno Haible  <bruno@clisp.org>
82210         mbrtowc: Respect rules for use of AC_LIBOBJ.
82211         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Move AC_LIBOBJ and gl_PREREQ_MBRTOWC
82212         invocations from here...
82213         * modules/mbrtowc (configure.ac): ... to here.
82215 2011-05-21  Bruno Haible  <bruno@clisp.org>
82217         malloc-*: Move AC_LIBOBJ invocations to module description.
82218         * m4/malloc.m4 (gl_REPLACE_MALLOC): Remove macro.
82219         (gl_FUNC_MALLOC_GNU, gl_FUNC_MALLOC_POSIX): Inline it here. Move
82220         AC_LIBOBJ invocations from here...
82221         * modules/malloc-gnu (configure.ac): ... to here.
82222         * modules/malloc-posix (configure.ac): ... and here.
82224 2011-05-21  Bruno Haible  <bruno@clisp.org>
82226         lstat, openat: Respect rules for use of AC_LIBOBJ.
82227         * m4/lstat.m4 (gl_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Renamed from
82228         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK. Set variable
82229         gl_cv_func_lstat_dereferences_slashed_symlink. Don't invoke AC_LIBOBJ.
82230         (gl_PREREQ_LSTAT): New macro, extracted from gl_FUNC_LSTAT.
82231         (gl_FUNC_LSTAT): Update. Remove gl_PREREQ_LSTAT code.
82232         * modules/lstat (configure.ac): Invoke AC_LIBOBJ and gl_PREREQ_LSTAT
82233         here.
82234         * m4/openat.m4 (gl_FUNC_OPENAT): Update.
82236 2011-05-21  Bruno Haible  <bruno@clisp.org>
82238         lseek: Move AC_LIBOBJ invocations to module description.
82239         * m4/lseek.m4 (gl_REPLACE_LSEEK): Remove macro.
82240         (gl_FUNC_LSEEK): Inline it here. Move AC_LIBOBJ invocation from here...
82241         * modules/lseek (configure.ac): ... to here.
82243 2011-05-21  Bruno Haible  <bruno@clisp.org>
82245         linkat: Move AC_LIBOBJ invocations to module description.
82246         * m4/linkat.m4 (gl_FUNC_LINKAT): Move AC_LIBOBJ invocations from
82247         here...
82248         * modules/linkat (configure.ac): ... to here.
82250 2011-05-21  Bruno Haible  <bruno@clisp.org>
82252         link: Respect rules for use of AC_LIBOBJ.
82253         * m4/link.m4 (gl_FUNC_LINK): Move AC_LIBOBJ invocations from here...
82254         * modules/link (configure.ac): ... to here.
82256 2011-05-21  Bruno Haible  <bruno@clisp.org>
82258         lchown: Move AC_LIBOBJ invocations to module description.
82259         * m4/lchown.m4 (gl_FUNC_EUIDACCESS): Call AC_CHECK_FUNCS instead of
82260         AC_REPLACE_FUNCS. Move AC_LIBOBJ invocations from here...
82261         * modules/lchown (configure.ac): ... to here.
82263 2011-05-21  Bruno Haible  <bruno@clisp.org>
82265         iswctype: Move AC_LIBOBJ invocations to module description.
82266         * m4/iswctype.m4 (gl_FUNC_ISWCTYPE): Move AC_LIBOBJ invocation from
82267         here...
82268         * modules/iswctype (configure.ac): ... to here.
82270 2011-05-21  Bruno Haible  <bruno@clisp.org>
82272         iswblank: Move AC_LIBOBJ invocations to module description.
82273         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Move AC_LIBOBJ invocation from
82274         here...
82275         * modules/iswblank (configure.ac): ... to here.
82277 2011-05-21  Bruno Haible  <bruno@clisp.org>
82279         atanl: Move AC_LIBOBJ invocations to module description.
82280         * m4/atanl.m4 (gl_FUNC_ATANL): Move AC_LIBOBJ invocation from here...
82281         * modules/atanl (configure.ac): ... to here.
82283 2011-05-21  Bruno Haible  <bruno@clisp.org>
82285         acosl: Move AC_LIBOBJ invocations to module description.
82286         * m4/acosl.m4 (gl_FUNC_ACOSL): Move AC_LIBOBJ invocation from here...
82287         * modules/acosl (configure.ac): ... to here.
82289 2011-05-21  Bruno Haible  <bruno@clisp.org>
82291         asinl: Respect rules for use of AC_LIBOBJ.
82292         * m4/asinl.m4 (gl_FUNC_ASINL): Move AC_LIBOBJ invocation from here...
82293         * modules/asinl (configure.ac): ... to here.
82295 2011-05-21  Bruno Haible  <bruno@clisp.org>
82297         tanl: Move AC_LIBOBJ invocations to module description.
82298         * m4/tanl.m4 (gl_FUNC_TANL): Move AC_LIBOBJ invocations from here...
82299         * modules/tanl (configure.ac): ... to here.
82301 2011-05-21  Bruno Haible  <bruno@clisp.org>
82303         cosl: Move AC_LIBOBJ invocations to module description.
82304         * m4/cosl.m4 (gl_FUNC_COSL): Move AC_LIBOBJ invocations from here...
82305         * modules/cosl (configure.ac): ... to here.
82307 2011-05-21  Bruno Haible  <bruno@clisp.org>
82309         sinl: Move AC_LIBOBJ invocations to module description.
82310         * m4/sinl.m4 (gl_FUNC_SINL): Move AC_LIBOBJ invocations from here...
82311         * modules/sinl (configure.ac): ... to here.
82313 2011-05-21  Bruno Haible  <bruno@clisp.org>
82315         logl: Move AC_LIBOBJ invocations to module description.
82316         * m4/logl.m4 (gl_FUNC_LOGL): Move AC_LIBOBJ invocation from here...
82317         * modules/logl (configure.ac): ... to here.
82319 2011-05-21  Bruno Haible  <bruno@clisp.org>
82321         expl: Move AC_LIBOBJ invocations to module description.
82322         * m4/expl.m4 (gl_FUNC_EXPL): Move AC_LIBOBJ invocation from here...
82323         * modules/expl (configure.ac): ... to here.
82325 2011-05-21  Bruno Haible  <bruno@clisp.org>
82327         roundl: Move AC_LIBOBJ invocations to module description.
82328         * m4/roundl.m4 (gl_FUNC_ROUNDL): Move AC_LIBOBJ invocation from here...
82329         * modules/roundl (configure.ac): ... to here.
82331 2011-05-21  Bruno Haible  <bruno@clisp.org>
82333         round: Move AC_LIBOBJ invocations to module description.
82334         * m4/round.m4 (gl_FUNC_ROUND): Move AC_LIBOBJ invocation from here...
82335         * modules/round (configure.ac): ... to here.
82337 2011-05-21  Bruno Haible  <bruno@clisp.org>
82339         roundf: Move AC_LIBOBJ invocations to module description.
82340         * m4/roundf.m4 (gl_FUNC_ROUNDF): Move AC_LIBOBJ invocation from here...
82341         * modules/roundf (configure.ac): ... to here.
82343 2011-05-21  Bruno Haible  <bruno@clisp.org>
82345         truncl: Move AC_LIBOBJ invocations to module description.
82346         * m4/truncl.m4 (gl_FUNC_TRUNCL): Move AC_LIBOBJ invocation from here...
82347         * modules/truncl (configure.ac): ... to here.
82349 2011-05-21  Bruno Haible  <bruno@clisp.org>
82351         trunc: Move AC_LIBOBJ invocations to module description.
82352         * m4/trunc.m4 (gl_FUNC_TRUNC): Move AC_LIBOBJ invocation from here...
82353         * modules/trunc (configure.ac): ... to here.
82355 2011-05-21  Bruno Haible  <bruno@clisp.org>
82357         truncf: Move AC_LIBOBJ invocations to module description.
82358         * m4/truncf.m4 (gl_FUNC_TRUNCF): Move AC_LIBOBJ invocation from here...
82359         * modules/truncf (configure.ac): ... to here.
82361 2011-05-21  Bruno Haible  <bruno@clisp.org>
82363         ceill: Move AC_LIBOBJ invocations to module description.
82364         * m4/ceill.m4 (gl_FUNC_CEILL): Move AC_LIBOBJ invocation from here...
82365         * modules/ceill (configure.ac): ... to here.
82367 2011-05-21  Bruno Haible  <bruno@clisp.org>
82369         ceil: Move AC_LIBOBJ invocations to module description.
82370         * m4/ceil.m4 (gl_FUNC_CEIL): Move AC_LIBOBJ invocation from here...
82371         * modules/ceil (configure.ac): ... to here.
82373 2011-05-21  Bruno Haible  <bruno@clisp.org>
82375         ceilf: Move AC_LIBOBJ invocations to module description.
82376         * m4/ceilf.m4 (gl_FUNC_CEILF): Move AC_LIBOBJ invocation from here...
82377         * modules/ceilf (configure.ac): ... to here.
82379 2011-05-21  Bruno Haible  <bruno@clisp.org>
82381         floorl: Respect rules for use of AC_LIBOBJ.
82382         * m4/floorl.m4 (gl_FUNC_FLOORL): Move AC_LIBOBJ invocation from here...
82383         * modules/floorl (configure.ac): ... to here.
82385 2011-05-21  Bruno Haible  <bruno@clisp.org>
82387         floor: Respect rules for use of AC_LIBOBJ.
82388         * m4/floor.m4 (gl_FUNC_FLOOR): Move AC_LIBOBJ invocation from here...
82389         * modules/floor (configure.ac): ... to here.
82391 2011-05-21  Bruno Haible  <bruno@clisp.org>
82393         floorf: Move AC_LIBOBJ invocations to module description.
82394         * m4/floorf.m4 (gl_FUNC_FLOORF): Move AC_LIBOBJ invocation from here...
82395         * modules/floorf (configure.ac): ... to here.
82397 2011-05-20  Bruno Haible  <bruno@clisp.org>
82399         sqrtl: Respect rules for use of AC_LIBOBJ.
82400         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Move AC_LIBOBJ invocation from here...
82401         * modules/sqrtl (configure.ac): ... to here.
82403 2011-05-20  Bruno Haible  <bruno@clisp.org>
82405         ldexpl: Respect rules for use of AC_LIBOBJ.
82406         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Move AC_LIBOBJ invocation from here...
82407         * modules/ldexpl (configure.ac): ... to here.
82409 2011-05-20  Bruno Haible  <bruno@clisp.org>
82411         frexpl*: Respect rules for use of AC_LIBOBJ.
82412         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): Move AC_LIBOBJ
82413         invocation from here...
82414         * modules/frexpl (configure.ac): ... to here.
82415         * modules/frexpl-nolibm (configure.ac): ... and here.
82417 2011-05-20  Bruno Haible  <bruno@clisp.org>
82419         frexp, frexp-nolibm: Move AC_LIBOBJ invocations to module description.
82420         * m4/frexp.m4 (gl_FUNC_FREXP, gl_FUNC_FREXP_NO_LIBM): Move AC_LIBOBJ
82421         invocation from here...
82422         * modules/frexp (configure.ac): ... to here.
82423         * modules/frexp-nolibm (configure.ac): ... and here.
82425 2011-05-20  Bruno Haible  <bruno@clisp.org>
82427         isnan: Respect rules for use of AC_LIBOBJ.
82428         * m4/isnan.m4 (gl_ISNAN): Don't do the AC_LIBOBJ and gl_PREREQ_ISNAN*
82429         invocations here.
82430         * modules/isnanf (configure.ac): Require gl_ISNAN if it exists. Test
82431         REPLACE_ISNAN.
82432         * modules/isnand (configure.ac): Likewise.
82433         * modules/isnanl (configure.ac): Likewise.
82435 2011-05-20  Bruno Haible  <bruno@clisp.org>
82437         isnanl*: Respect rules for use of AC_LIBOBJ.
82438         * m4/isnanl.m4 (gl_FUNC_ISNANL, gl_FUNC_ISNANL_NO_LIBM): Move AC_LIBOBJ
82439         invocation from here...
82440         * modules/isnanl (configure.ac): ... to here.
82441         * modules/isnanl-nolibm (configure.ac): ... and here.
82443 2011-05-20  Bruno Haible  <bruno@clisp.org>
82445         isnand*: Move AC_LIBOBJ invocations to module description.
82446         * m4/isnand.m4 (gl_FUNC_ISNAND, gl_FUNC_ISNAND_NO_LIBM): Move AC_LIBOBJ
82447         invocation from here...
82448         * modules/isnand (configure.ac): ... to here.
82449         * modules/isnand-nolibm (configure.ac): ... and here.
82451 2011-05-20  Bruno Haible  <bruno@clisp.org>
82453         isnanf*: Move AC_LIBOBJ invocations to module description.
82454         * m4/isnanf.m4 (gl_FUNC_ISNANF, gl_FUNC_ISNANF_NO_LIBM): Move AC_LIBOBJ
82455         invocation from here...
82456         * modules/isnanf (configure.ac): ... to here.
82457         * modules/isnanf-nolibm (configure.ac): ... and here.
82459 2011-05-20  Bruno Haible  <bruno@clisp.org>
82461         isnan*: Separate the AC_LIBOBJ invocations.
82462         * m4/isnanf.m4 (gl_PREREQ_ISNANF): Renamed from gl_BUILD_ISNANF. Remove
82463         AC_LIBOBJ invocation.
82464         (gl_FUNC_ISNANF, gl_FUNC_ISNANF_NO_LIBM): Update. Invoke AC_LIBOBJ
82465         here.
82466         * m4/isnand.m4 (gl_PREREQ_ISNAND): Renamed from gl_BUILD_ISNAND. Remove
82467         AC_LIBOBJ invocation.
82468         (gl_FUNC_ISNAND, gl_FUNC_ISNAND_NO_LIBM): Update. Invoke AC_LIBOBJ
82469         here.
82470         * m4/isnanl.m4 (gl_PREREQ_ISNANL): Renamed from gl_BUILD_ISNANL. Remove
82471         AC_LIBOBJ invocation.
82472         (gl_FUNC_ISNANL, gl_FUNC_ISNANL_NO_LIBM): Update. Invoke AC_LIBOBJ
82473         here.
82474         * m4/isnan.m4 (gl_ISNAN): Update. Invoke AC_LIBOBJ here.
82476 2011-05-08  Bruno Haible  <bruno@clisp.org>
82478         isinf: Move AC_LIBOBJ invocations to module description.
82479         * m4/isinf.m4 (gl_ISINF): Move AC_LIBOBJ invocation from here...
82480         * modules/isinf (configure.ac): ... to here.
82482 2011-05-08  Bruno Haible  <bruno@clisp.org>
82484         isfinite: Move AC_LIBOBJ invocations to module description.
82485         * m4/isfinite.m4 (gl_ISFINITE): Move AC_LIBOBJ invocation from here...
82486         * modules/isfinite (configure.ac): ... to here.
82488 2011-05-08  Bruno Haible  <bruno@clisp.org>
82490         isblank: Move AC_LIBOBJ invocations to module description.
82491         * m4/isblank.m4 (gl_FUNC_ISBLANK): Move AC_LIBOBJ invocation from
82492         here...
82493         * modules/isblank (configure.ac): ... to here.
82495 2011-05-08  Bruno Haible  <bruno@clisp.org>
82497         isapipe: Move AC_LIBOBJ invocations to module description.
82498         * m4/isapipe.m4 (gl_ISAPIPE): Set HAVE_ISAPIPE. Move AC_LIBOBJ and
82499         gl_PREREQ_ISAPIPE invocations from here...
82500         * modules/isapipe (configure.ac): ... to here.
82501         (Depends-on): Update condition.
82503 2011-05-08  Bruno Haible  <bruno@clisp.org>
82505         ioctl: Move AC_LIBOBJ invocations to module description.
82506         * m4/ioctl.m4 (gl_FUNC_IOCTL): Set HAVE_IOCTL. Move AC_LIBOBJ
82507         invocations from here...
82508         * modules/ioctl (configure.ac): ... to here.
82509         (Depends-on): Update condition.
82511 2011-05-08  Bruno Haible  <bruno@clisp.org>
82513         imaxdiv: Move AC_LIBOBJ invocations to module description.
82514         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Move AC_LIBOBJ and gl_PREREQ_IMAXDIV
82515         invocations from here...
82516         * modules/imaxdiv (configure.ac): ... to here.
82518 2011-05-08  Bruno Haible  <bruno@clisp.org>
82520         imaxabs: Move AC_LIBOBJ invocations to module description.
82521         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Move AC_LIBOBJ and gl_PREREQ_IMAXABS
82522         invocations from here...
82523         * modules/imaxabs (configure.ac): ... to here.
82525 2011-05-08  Bruno Haible  <bruno@clisp.org>
82527         getaddrinfo: Move AC_LIBOBJ invocations to module description.
82528         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Set HAVE_GETADDRINFO, Move
82529         AC_LIBOBJ invocations from here...
82530         * modules/getaddrinfo (configure.ac): ... to here.
82531         (Depends-on): Add conditions.
82533 2011-05-08  Bruno Haible  <bruno@clisp.org>
82535         inet_pton. getaddrinfo: Respect rules for use of AC_LIBOBJ.
82536         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Set HAVE_INET_PTON. Call
82537         AC_CHECK_FUNCS instead of AC_REPLACE_FUNCS. Don't invoke
82538         gl_PREREQ_INET_PTON. Move tests for declaration of inet_pton here...
82539         (gl_PREREQ_INET_PTON): ... from here.
82540         * modules/inet_pton (configure.ac): Invoke AC_LIBOBJ and
82541         gl_PREREQ_INET_PTON here.
82542         (Depends-on): Update condition.
82544 2011-05-08  Bruno Haible  <bruno@clisp.org>
82546         inet_ntop. getaddrinfo: Respect rules for use of AC_LIBOBJ.
82547         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Set HAVE_INET_NTOP. Call
82548         AC_CHECK_FUNCS instead of AC_REPLACE_FUNCS. Don't invoke
82549         gl_PREREQ_INET_NTOP. Move tests for declaration of inet_ntop here...
82550         (gl_PREREQ_INET_NTOP): ... from here.
82551         * modules/inet_ntop (configure.ac): Invoke AC_LIBOBJ and
82552         gl_PREREQ_INET_NTOP here.
82553         (Depends-on): Update condition.
82555 2011-05-08  Bruno Haible  <bruno@clisp.org>
82557         iconv_open: Move AC_LIBOBJ invocations to module description.
82558         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN, gl_REPLACE_ICONV_OPEN): Move
82559         AC_LIBOBJ invocations from here...
82560         * modules/iconv_open (configure.ac): ... to here.
82562 2011-05-08  Bruno Haible  <bruno@clisp.org>
82564         iconv_open, iconv_open-utf: Respect rules for use of AC_LIBOBJ.
82565         If module 'iconv_open' is among the main modules and module
82566         'iconv_open-utf' is among the tests dependencies, then
82567         REPLACE_ICONV_UTF will be defined to 1, hence iconv_open() in lib may
82568         return the special iconv_t values. Therefore iconv() and iconv_close()
82569         must support these special iconv_t values, already in lib, not only in
82570         tests.
82571         * m4/iconv_open-utf.m4: New file, extracted from m4/iconv_open.m4.
82572         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Invoke
82573         gl_FUNC_ICONV_OPEN_UTF_SUPPORT if present.
82574         (gl_FUNC_ICONV_OPEN_UTF): Remove macro.
82575         * modules/iconv_open (Files): Add lib/iconv.c, lib/iconv_close.c.
82576         (Depends-on): Add the dependencies of iconv_open-utf.
82577         * modules/iconv_open-utf (Files): Add m4/iconv_open-utf.m4. Remove
82578         m4/iconv_open.m4, lib/iconv.c, lib/iconv_close.c.
82579         (Depends-on): Remove modules needed by lib/iconv.c, lib/iconv_close.c.
82581 2011-05-08  Bruno Haible  <bruno@clisp.org>
82583         group-member: Move AC_LIBOBJ invocations to module description.
82584         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Move AC_LIBOBJ and
82585         gl_PREREQ_GROUP_MEMBER invocations from here...
82586         * modules/group-member (configure.ac): ... to here.
82588 2011-05-08  Bruno Haible  <bruno@clisp.org>
82590         grantpt: Move AC_LIBOBJ invocations to module description.
82591         * m4/grantpt.m4 (gl_FUNC_GRANTPT): Move AC_LIBOBJ and gl_PREREQ_GRANTPT
82592         invocations from here...
82593         * modules/grantpt (configure.ac): ... to here.
82595 2011-05-08  Bruno Haible  <bruno@clisp.org>
82597         glob: Move AC_LIBOBJ invocations to module description.
82598         * m4/glob.m4 (gl_GLOB): Move AC_LIBOBJ and gl_PREREQ_GLOB invocations
82599         from here...
82600         * modules/glob (configure.ac): ... to here.
82602 2011-05-08  Bruno Haible  <bruno@clisp.org>
82604         getusershell: Move AC_LIBOBJ invocations to module description.
82605         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): Set HAVE_GETUSERSHELL.
82606         Move AC_LIBOBJ invocation from here...
82607         * modules/getusershell (configure.ac): ... to here.
82608         (Depends-on): Update condition.
82610 2011-05-08  Bruno Haible  <bruno@clisp.org>
82612         gettimeofday: Move AC_LIBOBJ invocations to module description.
82613         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
82614         gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Move AC_LIBOBJ and
82615         gl_PREREQ_GETTIMEOFDAY invocations from here...
82616         * modules/gettimeofday (configure.ac): ... to here.
82618 2011-05-08  Bruno Haible  <bruno@clisp.org>
82620         gettimeofday, tzset: Respect rules for use of AC_LIBOBJ.
82621         * modules/tzset (configure.ac): Don't invoke gl_FUNC_TZSET_CLOBBER,
82622         just gl_FUNC_TZSET.
82623         * m4/tzset.m4 (gl_FUNC_TZSET): New macro.
82624         (gl_FUNC_TZSET_CLOBBER): Remove actions.
82625         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Invoke
82626         gl_FUNC_TZSET_CLOBBER and its actions here, if present.
82628 2011-05-08  Bruno Haible  <bruno@clisp.org>
82630         getsubopt: Move AC_LIBOBJ invocations to module description.
82631         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Move AC_LIBOBJ and
82632         gl_PREREQ_GETSUBOPT invocations from here...
82633         * modules/getsubopt (configure.ac): ... to here.
82635 2011-05-08  Bruno Haible  <bruno@clisp.org>
82637         getpass-gnu: Move AC_LIBOBJ invocations to module description.
82638         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): Set REPLACE_GETPASS. Move
82639         AC_LIBOBJ and gl_PREREQ_GETPASS invocations from here...
82640         * modules/getpass-gnu (configure.ac): ... to here.
82642 2011-05-08  Bruno Haible  <bruno@clisp.org>
82644         getpass: Move AC_LIBOBJ invocations to module description.
82645         * m4/getpass.m4 (gl_FUNC_GETPASS): Set HAVE_GETPASS. Move AC_LIBOBJ and
82646         gl_PREREQ_GETPASS invocations from here...
82647         * modules/getpass (configure.ac): ... to here.
82649 2011-05-08  Bruno Haible  <bruno@clisp.org>
82651         getpagesize: Move AC_LIBOBJ invocations to module description.
82652         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Move AC_LIBOBJ invocation
82653         from here...
82654         * modules/getpagesize (configure.ac): ... to here.
82656 2011-05-08  Bruno Haible  <bruno@clisp.org>
82658         getopt: Move AC_LIBOBJ invocations to module description.
82659         * m4/getopt.m4 (gl_REPLACE_GETOPT): Remove macro.
82660         (gl_FUNC_GETOPT): Inline it here. Move AC_LIBOBJ and gl_PREREQ_GETOPT
82661         invocations from here...
82662         * modules/getopt-gnu (configure.ac): ... to here.
82663         * modules/getopt-posix (configure.ac): ... and here.
82664         (Depends-on): Update condition.
82666 2011-05-08  Bruno Haible  <bruno@clisp.org>
82668         getopt, argp: Respect rules for use of AC_LIBOBJ.
82669         * m4/argp.m4 (gl_ARGP): Don't invoke gl_REPLACE_GETOPT.
82670         (gl_REPLACE_GETOPT_ALWAYS): New macro.
82671         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX): Test whether
82672         gl_REPLACE_GETOPT_ALWAYS is defined. Set REPLACE_GETOPT.
82674 2011-05-08  Bruno Haible  <bruno@clisp.org>
82676         getlogin_r: Move AC_LIBOBJ invocations to module description.
82677         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Move AC_LIBOBJ and
82678         gl_PREREQ_GETLOGIN_R invocations from here...
82679         * modules/getlogin_r (configure.ac): ... to here.
82681 2011-05-08  Bruno Haible  <bruno@clisp.org>
82683         getlogin: Move AC_LIBOBJ invocations to module description.
82684         * m4/getlogin.m4 (gl_FUNC_GETLOGIN): Move AC_LIBOBJ invocation from
82685         here...
82686         * modules/getlogin (configure.ac): ... to here.
82688 2011-05-08  Bruno Haible  <bruno@clisp.org>
82690         getloadavg: Move AC_LIBOBJ invocations to module description.
82691         * m4/getloadavg.m4 (gl_FUNC_GETDELIM): Set HAVE_GETLOADAVG. Move
82692         AC_LIBOBJ and gl_PREREQ_GETLOADAVG invocations from here...
82693         * modules/getloadavg (configure.ac): ... to here.
82695 2011-05-08  Bruno Haible  <bruno@clisp.org>
82697         gethrxtime: Move AC_LIBOBJ invocations to module description.
82698         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Move code that determines
82699         LIB_GETHRXTIME from here...
82700         (gl_GETHRXTIME): ... to here. Move AC_LIBOBJ and gl_PREREQ_GETHRXTIME
82701         invocations from here...
82702         * modules/gethrxtime (configure.ac): ... to here.
82704 2011-05-08  Bruno Haible  <bruno@clisp.org>
82706         gethostname: Move AC_LIBOBJ invocations to module description.
82707         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Move AC_LIBOBJ and
82708         gl_PREREQ_GETHOSTNAME invocations from here...
82709         * modules/gethostname (configure.ac): ... to here.
82711 2011-05-08  Bruno Haible  <bruno@clisp.org>
82713         getgroups: Move AC_LIBOBJ invocations to module description.
82714         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Move AC_LIBOBJ invocations from
82715         here...
82716         * modules/getgroups (configure.ac): ... to here.
82718 2011-05-08  Bruno Haible  <bruno@clisp.org>
82720         getdtablesize: Move AC_LIBOBJ invocations to module description.
82721         * m4/getdtablesize.m4 (gl_FUNC_GETDTABLESIZE): Move AC_LIBOBJ
82722         invocation from here...
82723         * modules/getdtablesize (configure.ac): ... to here.
82725 2011-05-08  Bruno Haible  <bruno@clisp.org>
82727         getdomainname: Move AC_LIBOBJ invocations to module description.
82728         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Move AC_LIBOBJ and
82729         gl_PREREQ_GETDOMAINNAME invocations from here...
82730         * modules/getdomainname (configure.ac): ... to here.
82732 2011-05-08  Bruno Haible  <bruno@clisp.org>
82734         getline: Move AC_LIBOBJ invocations to module description.
82735         * m4/getline.m4 (gl_FUNC_GETLINE): Move AC_LIBOBJ and gl_PREREQ_GETLINE
82736         invocations from here...
82737         * modules/getline (configure.ac): ... to here.
82739 2011-05-08  Bruno Haible  <bruno@clisp.org>
82741         getline: Simplify.
82742         * m4/getline.m4 (gl_PREREQ_GETLINE): Don't invoke gl_FUNC_GETDELIM.
82743         It's already handled through the module dependency.
82745 2011-05-08  Bruno Haible  <bruno@clisp.org>
82747         getdelim: Move AC_LIBOBJ invocations to module description.
82748         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Set HAVE_GETDELIM. Move AC_LIBOBJ
82749         and gl_PREREQ_GETDELIM invocations from here...
82750         * modules/getdelim (configure.ac): ... to here.
82751         (Depends-on): Fix condition.
82753 2011-05-08  Bruno Haible  <bruno@clisp.org>
82755         getcwd: Move AC_LIBOBJ invocations to module description.
82756         * m4/getcwd.m4 (gl_FUNC_GETCWD): Move AC_LIBOBJ and gl_PREREQ_GETCWD
82757         invocations from here...
82758         * modules/getcwd (configure.ac): ... to here.
82760 2011-05-08  Bruno Haible  <bruno@clisp.org>
82762         getcwd-lgpl: Move AC_LIBOBJ invocations to module description.
82763         * m4/getcwd.m4 (gl_FUNC_GETCWD_LGPL): Move AC_LIBOBJ invocation from
82764         here...
82765         * modules/getcwd-lgpl (configure.ac): ... to here.
82767 2011-05-07  Bruno Haible  <bruno@clisp.org>
82769         crypto/gc: Move AC_LIBOBJ invocations to module description.
82770         * m4/gc.m4 (gl_GC): Move AC_LIBOBJ invocations from here...
82771         * modules/crypto/gc (configure.ac): ... to here.
82773 2011-05-07  Bruno Haible  <bruno@clisp.org>
82775         fwriting: Move AC_LIBOBJ invocations to module description.
82776         * m4/fwriting.m4 (gl_FUNC_FWRITINT): Move AC_LIBOBJ invocation from
82777         here...
82778         * modules/fwriting (configure.ac): ... to here.
82780 2011-05-07  Bruno Haible  <bruno@clisp.org>
82782         fwritable: Move AC_LIBOBJ invocations to module description.
82783         * m4/fwritable.m4 (gl_FUNC_FWRITABLE): Move AC_LIBOBJ invocation from
82784         here...
82785         * modules/fwritable (configure.ac): ... to here.
82787 2011-05-07  Bruno Haible  <bruno@clisp.org>
82789         futimens: Move AC_LIBOBJ invocations to module description.
82790         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Move AC_LIBOBJ invocations from
82791         here...
82792         * modules/futimens (configure.ac): ... to here.
82794 2011-05-07  Bruno Haible  <bruno@clisp.org>
82796         ftruncate: Move AC_LIBOBJ invocations to module description.
82797         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Move AC_LIBOBJ and
82798         gl_PREREQ_FTRUNCATE invocations from here...
82799         * modules/ftruncate (configure.ac): ... to here.
82801 2011-05-07  Bruno Haible  <bruno@clisp.org>
82803         fsync: Move AC_LIBOBJ invocations to module description.
82804         * m4/fsync.m4 (gl_FUNC_FSYNC): Move AC_LIBOBJ and gl_PREREQ_FSYNC
82805         invocations from here...
82806         * modules/fsync (configure.ac): ... to here.
82808 2011-05-07  Bruno Haible  <bruno@clisp.org>
82810         fsusage: Move AC_LIBOBJ invocations to module description.
82811         * m4/fsusage.m4 (gl_FUNC_FREOPEN): Move AC_LIBOBJ and
82812         gl_PREREQ_FSUSAGE_EXTRA invocations from here...
82813         * modules/fsusage (configure.ac): ... to here.
82815 2011-05-07  Bruno Haible  <bruno@clisp.org>
82817         freopen: Move AC_LIBOBJ invocations to module description.
82818         * m4/freopen.m4 (gl_FUNC_FREOPEN): Move AC_LIBOBJ and gl_PREREQ_FREOPEN
82819         invocations from here...
82820         * modules/freopen (configure.ac): ... to here.
82822 2011-05-07  Bruno Haible  <bruno@clisp.org>
82824         free: Move AC_LIBOBJ invocations to module description.
82825         * m4/free.m4 (gl_FUNC_FREE): Move AC_LIBOBJ and missing gl_PREREQ_FREE
82826         invocations from here...
82827         * modules/free (configure.ac): ... to here.
82829 2011-05-07  Bruno Haible  <bruno@clisp.org>
82831         freadable: Move AC_LIBOBJ invocations to module description.
82832         * m4/freadable.m4 (gl_FUNC_FREADABLE): Move AC_LIBOBJ invocation from
82833         here...
82834         * modules/freadable (configure.ac): ... to here.
82836 2011-05-07  Bruno Haible  <bruno@clisp.org>
82838         fpurge: Move AC_LIBOBJ invocations to module description.
82839         * m4/fpurge.m4 (gl_FUNC_FPURGE): Set HAVE_FPURGE. Move AC_LIBOBJ
82840         invocations from here...
82841         * modules/fpurge (configure.ac): ... to here.
82843 2011-05-07  Bruno Haible  <bruno@clisp.org>
82845         fpending: Move AC_LIBOBJ invocations to module description.
82846         * m4/fpending.m4 (gl_PREREQ_FPENDING): New macro, extracted from
82847         gl_FUNC_FPENDING.
82848         (gl_FUNC_FPENDING): Move AC_LIBOBJ and gl_PREREQ_FPENDING
82849         invocations from here...
82850         * modules/fpending (configure.ac): ... to here.
82852 2011-05-07  Bruno Haible  <bruno@clisp.org>
82854         fopen: Move AC_LIBOBJ invocations to module description.
82855         * m4/fopen.m4 (gl_FUNC_FOPEN): Move AC_LIBOBJ and gl_PREREQ_FOPEN
82856         invocations from here...
82857         * modules/fopen (configure.ac): ... to here.
82859 2011-05-07  Bruno Haible  <bruno@clisp.org>
82861         fnmatch, fnmatch-gnu: Move AC_LIBOBJ invocations to module description.
82862         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH): New macro, extracted from
82863         gl_FUNC_FNMATCH_POSIX.
82864         (gl_FUNC_FNMATCH_POSIX): Move AC_LIBOBJ and gl_PREREQ_FNMATCH
82865         invocations from here...
82866         * modules/fnmatch (configure.ac): ... to here.
82867         * modules/fnmatch-gnu (configure.ac): ... and here.
82869 2011-05-07  Bruno Haible  <bruno@clisp.org>
82871         flock: Move AC_LIBOBJ invocations to module description.
82872         * m4/flock.m4 (gl_FUNC_FLOCK): Move AC_LIBOBJ and gl_PREREQ_FLOCK
82873         invocations from here...
82874         * modules/flock (configure.ac): ... to here.
82876 2011-05-07  Bruno Haible  <bruno@clisp.org>
82878         fileblocks: Move AC_LIBOBJ invocations to module description.
82879         * m4/fileblocks.m4 (gl_FILEBLOCKS): Move AC_LIBOBJ and
82880         gl_PREREQ_FILEBLOCKS invocations from here...
82881         * modules/fileblocks (configure.ac): ... to here.
82883 2011-05-06  Bruno Haible  <bruno@clisp.org>
82885         fflush: Move AC_LIBOBJ invocations to module description.
82886         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Remove macro.
82887         (gl_FUNC_FFLUSH): Inline it here. Move AC_LIBOBJ and gl_PREREQ_FFLUSH
82888         invocations from here...
82889         * modules/fflush (configure.ac): ... to here.
82891 2011-05-06  Bruno Haible  <bruno@clisp.org>
82893         fdopendir: Move AC_LIBOBJ invocations to module description.
82894         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Move AC_LIBOBJ invocations from
82895         here...
82896         * modules/fdopendir (configure.ac): ... to here.
82897         (Depends-on): Improve conditions.
82899 2011-05-06  Bruno Haible  <bruno@clisp.org>
82901         _Exit: Move AC_LIBOBJ invocations to module description.
82902         * m4/_Exit.m4 (gl_FUNC__EXIT): Move AC_LIBOBJ and gl_PREREQ__EXIT
82903         invocations from here...
82904         * modules/_Exit (configure.ac): ... to here.
82906 2011-05-21  Bruno Haible  <bruno@clisp.org>
82908         euidaccess: Respect rules for use of AC_LIBOBJ.
82909         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Call AC_CHECK_FUNCS instead of
82910         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_EUIDACCESS invocations
82911         from here...
82912         * modules/euidaccess (configure.ac): ... to here.
82914 2011-05-06  Bruno Haible  <bruno@clisp.org>
82916         error: Move AC_LIBOBJ invocations to module description.
82917         * m4/error.m4 (gl_ERROR): Inline AC_FUNC_ERROR_AT_LINE. Remove
82918         AC_LIBSOURCES invocation. Move AC_LIBOBJ and gl_PREREQ_ERROR
82919         invocations from here...
82920         * modules/error (configure.ac): ... to here.
82922 2011-05-06  Bruno Haible  <bruno@clisp.org>
82924         duplocale: Move AC_LIBOBJ invocations to module description.
82925         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Move AC_LIBOBJ and
82926         gl_PREREQ_DUPLOCALE invocations from here...
82927         * modules/duplocale (configure.ac): ... to here.
82929 2011-05-05  Bruno Haible  <bruno@clisp.org>
82931         dirfd: Move AC_LIBOBJ invocations to module description.
82932         * m4/dirfd.m4 (gl_PREREQ_DIRFD): New macro, extracted from
82933         gl_FUNC_DIRFD.
82934         (gl_FUNC_DIRFD): Move AC_LIBOBJ and gl_PREREQ_DIRFD invocations from
82935         here...
82936         * modules/dirfd (configure.ac): ... to here.
82937         (Depends-on): Fix condition.
82939 2011-05-05  Bruno Haible  <bruno@clisp.org>
82941         chown: Respect rules for use of AC_LIBOBJ.
82942         * m4/chown.m4 (gl_FUNC_CHOWN): Move AC_LIBOBJ invocations from here...
82943         * modules/chown (configure.ac): ... to here.
82945 2011-05-05  Bruno Haible  <bruno@clisp.org>
82947         chdir-long: Move AC_LIBOBJ invocations to module description.
82948         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Move AC_LIBOBJ and
82949         gl_PREREQ_CHDIR_LONG invocations from here...
82950         * modules/chdir-long (configure.ac): ... to here.
82952 2011-05-05  Bruno Haible  <bruno@clisp.org>
82954         canonicalize-lgpl: Move AC_LIBOBJ invocations to module description.
82955         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL): Move AC_LIBOBJ invocation
82956         from here...
82957         * modules/canonicalize-lgpl (configure.ac): ... to here.
82959 2011-05-05  Bruno Haible  <bruno@clisp.org>
82961         calloc-posix, calloc-gnu: Move AC_LIBOBJs to module description.
82962         * m4/calloc.m4 (gl_REPLACE_CALLOC): Remove macro.
82963         (gl_FUNC_CALLOC_GNU, gl_FUNC_CALLOC_POSIX): Instead, just set
82964         REPLACE_CALLOC.
82965         * modules/calloc-posix (configure.ac): Invoke AC_LIBOBJ here.
82966         * modules/calloc-gnu (configure.ac): Likewise.
82968 2011-05-05  Bruno Haible  <bruno@clisp.org>
82970         btowc: Move AC_LIBOBJ invocations to module description.
82971         * m4/btowc.m4 (gl_FUNC_BTOWC): Move AC_LIBOBJ and gl_PREREQ_BTOWC
82972         invocations from here...
82973         * modules/btowc (configure.ac): ... to here.
82975 2011-05-21  Bruno Haible  <bruno@clisp.org>
82977         atexit: Move AC_LIBOBJ invocations to module description.
82978         * m4/atexit.m4 (gl_FUNC_ATEXIT): Call AC_CHECK_FUNCS instead of
82979         AC_REPLACE_FUNCS. Move AC_LIBOBJ and gl_PREREQ_ATEXIT invocations from
82980         here...
82981         * modules/atexit (configure.ac): ... to here.
82983 2011-05-05  Bruno Haible  <bruno@clisp.org>
82985         atoll: Move AC_LIBOBJ invocations to module description.
82986         * m4/atoll.m4 (gl_FUNC_ATOLL): Move AC_LIBOBJ and gl_PREREQ_ATOLL
82987         invocations from here...
82988         * modules/atoll (configure.ac): ... to here.
82990 2011-05-05  Bruno Haible  <bruno@clisp.org>
82992         argz: Move AC_LIBOBJ invocations to module description.
82993         * m4/argz.m4 (gl_FUNC_ARGZ): Move AC_LIBOBJ invocation from here...
82994         * modules/argz (configure.ac): ... to here.
82996 2011-05-05  Bruno Haible  <bruno@clisp.org>
82998         alphasort: Move AC_LIBOBJ invocations to module description.
82999         * m4/alphasort.m4 (gl_FUNC_ALPHASORT): Move AC_LIBOBJ and
83000         gl_PREREQ_ALPHASORT invocations from here...
83001         * modules/alphasort (configure.ac): ... to here.
83003 2011-06-15  Paul Eggert  <eggert@cs.ucla.edu>
83005         verify: new macro verify_expr; verify_true deprecated
83006         * NEWS: Mention this.
83007         * doc/verify.texi (Compile-time Assertions): Document this.
83008         * lib/verify.h (verify_true): Deprecate.
83009         (verify_expr): New macro.
83010         * tests/test-verify.c (function): Test verify_expr.
83012 2011-06-14  Jim Meyering  <meyering@redhat.com>
83014         init.sh: give more portable redirection-related advice in a comment
83015         * tests/init.sh (stderr_fileno_): Update the advice in comments.
83016         See http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/22488
83017         for lots of discussion.  Stefano Lattarini suggested the solution
83018         of putting "9>&2" after the command.  Reported by Bruno Haible.
83020 2011-06-13  Bruno Haible  <bruno@clisp.org>
83022         locale-zh: Reject zh_CN.GB18030 locale on Solaris 8.
83023         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): On Solaris 8, set LOCALE_ZH_CN to
83024         'none'.
83026 2011-06-13  Paul Eggert  <eggert@cs.ucla.edu>
83028         ftoastr: use strtof only if HAVE_STRTOF
83029         This is needed on HP-UX 11.11 with GCC 4.2.4; see Bruno Haible's report
83030         <http://lists.gnu.org/r/bug-gnulib/2011-06/msg00154.html>.
83031         * lib/ftoastr.c (STRTOF) [LENGTH == 1]: Use strtof only if HAVE_STRTOF.
83032         * modules/ftoastr (configure.ac): Check for strtof.
83034 2011-06-13  Bruno Haible  <bruno@clisp.org>
83036         gnulib-tool: Addendum to 2011-06-08 commit.
83037         * gnulib-tool (func_emit_lib_Makefile_am): If options --makefile-name
83038         and --witness-c-macro have been given, augment AM_CPPFLAGS.
83040 2011-06-13  Bruno Haible  <bruno@clisp.org>
83042         fseeko: Provide a non-inline replacement of fseek().
83043         * lib/stdio.in.h (fseek): Don't provide if module 'fseek' is not used.
83044         * modules/fseeko (Depends-on): Add fseek.
83045         * modules/fseek (License): Change to LGPLv2+.
83047 2011-06-13  Bruno Haible  <bruno@clisp.org>
83049         ftello: Provide a non-inline replacement of ftell().
83050         * lib/stdio.in.h (ftell): Don't provide if module 'ftell' is not used.
83051         * m4/ftell.m4 (gl_FUNC_FTELL): Replace ftell also if the system does
83052         not have ftello() (such as on mingw).
83053         * modules/ftello (Depends-on): Add ftell.
83054         * modules/ftell (License): Change to LGPLv2+.
83056 2011-05-07  Bruno Haible  <bruno@clisp.org>
83058         ftell: Move AC_LIBOBJ invocations to module description.
83059         * m4/ftell.m4 (gl_FUNC_FTELL): Move AC_LIBOBJ invocation from here...
83060         * modules/ftell (configure.ac): ... to here.
83062 2011-05-07  Bruno Haible  <bruno@clisp.org>
83064         ftello: Respect rules for use of AC_LIBOBJ.
83065         * m4/ftello.m4 (gl_REPLACE_FTELLO): Remove macro.
83066         (gl_FUNC_FTELLO): Inline it here. Move AC_LIBOBJ invocation from
83067         here...
83068         * modules/ftello (configure.ac): ... to here.
83070 2011-05-07  Bruno Haible  <bruno@clisp.org>
83072         fseeko: Simplify.
83073         * m4/fseeko.m4 (gl_HAVE_FSEEKO): Remove macro.
83074         (gl_FUNC_FSEEKO): Inline it here.
83076 2011-05-07  Bruno Haible  <bruno@clisp.org>
83078         fseek: Move AC_LIBOBJ invocations to module description.
83079         * m4/fseek.m4 (gl_REPLACE_FSEEK): Remove macro.
83080         (gl_FUNC_FSEEK): Inline it here. Move AC_LIBOBJ invocation from here...
83081         * modules/fseek (configure.ac): ... to here.
83083 2011-05-07  Bruno Haible  <bruno@clisp.org>
83085         fseek: Respect rules for use of AC_LIBOBJ.
83086         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Move gl_REPLACE_FSEEK invocation from
83087         here...
83088         * m4/fseek.m4 (gl_FUNC_FSEEK): ... to here.
83090 2011-05-07  Bruno Haible  <bruno@clisp.org>
83092         fseeko: Respect rules for use of AC_LIBOBJ.
83093         * m4/fseeko.m4 (gl_REPLACE_FSEEKO): Remove macro.
83094         (gl_FUNC_FSEEKO): Inline it here. Move AC_LIBOBJ invocation from
83095         here...
83096         * modules/fseeko (configure.ac): ... to here.
83098 2011-06-13  Bruno Haible  <bruno@clisp.org>
83100         gnulib-tool: Allow comments in the 'Depends-on' section.
83101         * doc/gnulib.texi (Module description): Mention comment syntax in the
83102         Depends-on section.
83103         * gnulib-tool (func_get_dependencies): Filter out comment lines.
83105 2011-06-13  Bruno Haible  <bruno@clisp.org>
83107         file-set.h: guard __attibute__ use, now that it's not always defined
83108         * lib/file-set.h (record_file): Use __attribute__ only with compiler
83109         versions that support it.  This fixes a coreutils build failure with
83110         the vendor cc on HP-UX 11.31.
83112 2011-06-12  Bruno Haible  <bruno@clisp.org>
83114         acl: Add support for HP-UX >= 11.11 JFS ACLs.
83115         * doc/acl-resources.txt: Add info about the ACL APIs on HP-UX.
83116         * m4/acl.m4 (gl_FUNC_ACL): Also test for HP-UX 11.11 API.
83117         * lib/acl-internal.h [HP-UX 11.11]: Include <aclv.h>.
83118         (acl, aclsort): New declarations.
83119         (aclv_nontrivial): New declaration.
83120         * lib/file-has-acl.c (aclv_nontrivial) [HP-UX 11.11]: New function.
83121         (file_has_acl): Read also the second kind of HP-UX ACLs.
83122         * lib/set-mode-acl.c (qset_acl) [HP-UX 11.11]: Try to set the second
83123         kind of HP-UX ACLs if the first kind fails.
83124         * lib/copy-acl.c (qcopy_acl) [HP-UX 11.11]: Read and set also the
83125         second kind of HP-UX ACLs.
83126         * tests/test-sameacls.c [HP-UX 11.11]: Include <aclv.h>.
83127         (main) [HP-UX 11.11]: Test also whether the second kind of HP-UX ACLs
83128         agree.
83129         * tests/test-file-has-acl.sh (acl_flavor) [HP-UX 11.11]: Set to
83130         hpuxjfs.
83131         Handle hpuxjfs.
83132         * tests/test-set-mode-acl.sh (acl_flavor) [HP-UX 11.11]: Set to
83133         hpuxjfs.
83134         Handle hpuxjfs.
83135         * tests/test-copy-acl.sh (acl_flavor) [HP-UX 11.11]: Set to hpuxjfs.
83136         (func_test_same_acls): Use both lsacl and getacl.
83137         Handle hpuxjfs.
83138         * tests/test-copy-file.sh (acl_flavor) [HP-UX 11.11]: Set to hpuxjfs.
83139         (func_test_same_acls): Use both lsacl and getacl.
83140         Handle hpuxjfs.
83142 2011-06-12  Bruno Haible  <bruno@clisp.org>
83144         acl: Complete the 2010-08-10 fix.
83145         * lib/file-has-acl.c (file_has_acl) [HP-UX]: Also test against ENOTSUP.
83146         * lib/set-mode-acl.c (qset_acl) [HP-UX]: Likewise.
83147         * lib/copy-acl.c (qcopy_acl) [HP-UX]: Test for the errno values
83148         explicitly.
83149         * tests/test-sameacls.c (main) [HP-UX]: Also test against ENOTSUP.
83150         Reported in <http://debbugs.gnu.org/db/60/6053.html>.
83152 2011-06-12  Bruno Haible  <bruno@clisp.org>
83154         spawn-pipe tests: Comments.
83155         * tests/test-spawn-pipe-child.c (main): Update comment.
83156         Reported by James Youngman <jay@gnu.org>.
83158 2011-06-11  James Youngman  <jay@gnu.org>
83160         New module 'stat-size'.
83161         * modules/stat-size: New module.  Provides macros for accessing
83162         file size information in instances of struct stat.  Depends on the
83163         fileblocks module because it calls st_blocks.
83164         * lib/stat-size.h: New file, adapted from coreutils' system.h.
83165         * doc/gnulib.texi: Include stat-size.texi.
83166         * doc/stat-size.texi: Documentation for this module.
83167         * m4/stat-size.m4: New file; defines gl_STAT_SIZE.
83168         * m4/fileblocks.m4: Mention that stat-size depends on the call to
83169         AC_STRUCT_ST_BLOCKS.
83171 2011-06-09  Bruno Haible  <bruno@clisp.org>
83173         thread: Support pthreads-win32.
83174         * lib/glthread/thread.h (gl_thread_self): Define differently on
83175         pthreads-win32.
83176         (gl_null_thread): New declaration.
83177         (gl_thread_self_pointer): New macro.
83178         * lib/glthread/thread.c (gl_null_thread): New constant.
83179         * tests/test-lock.c: Use gl_thread_self_pointer instead of
83180         gl_thread_self.
83181         * tests/test-tls.c: Likewise.
83182         Suggested by Paul Eggert. Reported by Eric Blake.
83184 2011-06-09  Bruno Haible  <bruno@clisp.org>
83186         thread: Fix confusion between NULL and 0.
83187         * lib/glthread/thread.h (gl_thread_self): Use NULL and 0 appropriately.
83188         Reported by Paul Eggert.
83190 2011-06-09  Bruno Haible  <bruno@clisp.org>
83192         spawn-pipe tests: Avoid test failure on HP-UX 11.
83193         * tests/test-spawn-pipe-child.c (main) [HP-UX]: Don't assert that fd 2
83194         is closed.
83196 2011-06-09  Bruno Haible  <bruno@clisp.org>
83198         acl tests: Fix compilation error on HP-UX 11.
83199         * tests/test-sameacls.c: Include <sys/acl.h> also on HP-UX.
83201 2011-06-09  Bruno Haible  <bruno@clisp.org>
83203         rmdir: Avoid test failure on HP-UX 10.20.
83204         * tests/test-rmdir.h (test_rmdir_func): Accept ENOTEMPTY error, like
83205         EEXIST.
83207 2011-06-08  Eric Blake  <eblake@redhat.com>
83209         perror: fix test on mingw
83210         * modules/perror-tests (Depends-on): Add dup2.
83212         strerror_r-posix: fix on MacOS
83213         * m4/strerror.m4 (gl_FUNC_STRERROR): Flush out MacOS bug.
83214         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Likewise, and fix
83215         logic bug.
83216         * lib/strerror_r.c (strerror_r): Fix the bug.
83217         * lib/strerror.c (strerror): Likewise.
83218         * doc/posix-functions/strerror_r.texi (strerror_r): Document the
83219         problem.
83220         * doc/posix-functions/strerror.texi (strerror): Likewise.
83221         * doc/posix-functions/perror.texi (perror): Likewise.
83222         * tests/test-strerror.c (main): Enhance test.
83223         * tests/test-strerror_r.c (main): Likewise.
83225 2011-06-08  Bruno Haible  <bruno@clisp.org>
83227         gnulib-tool: Better isolation between different gnulib-tool invocations.
83228         * gnulib-tool: New option --witness-c-macro.
83229         (witness_c_macro): New variable.
83230         (func_emit_lib_Makefile_am): If --witness-c-macro was specified, let
83231         AM_CPPFLAGS define it as a C macro.
83232         (func_emit_tests_Makefile_am): Likewise.
83233         (func_import): Store witness_c_macro setting in gnulib-cache.m4 and
83234         read it from there.
83235         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_CONDITION): Define through
83236         m4_define, not AC_DEFUN.
83237         (gl_MODULE_INDICATOR_SET_VARIABLE_AUX,
83238         gl_MODULE_INDICATOR_SET_VARIABLE_AUX_OR): New macros.
83239         (gl_MODULE_INDICATOR_SET_VARIABLE): Use them.
83240         * modules/arpa_inet (Makefile.am): Use sed expression s/.../.../, not
83241         s|...|...|, to substitute the values of the GNULIB_* module indicator
83242         variables.
83243         * modules/dirent (Makefile.am): Likewise.
83244         * modules/fcntl-h (Makefile.am): Likewise.
83245         * modules/iconv-h (Makefile.am): Likewise.
83246         * modules/langinfo (Makefile.am): Likewise.
83247         * modules/locale (Makefile.am): Likewise.
83248         * modules/math (Makefile.am): Likewise.
83249         * modules/netdb (Makefile.am): Likewise.
83250         * modules/poll-h (Makefile.am): Likewise.
83251         * modules/pty (Makefile.am): Likewise.
83252         * modules/search (Makefile.am): Likewise.
83253         * modules/signal (Makefile.am): Likewise.
83254         * modules/spawn (Makefile.am): Likewise.
83255         * modules/stdio (Makefile.am): Likewise.
83256         * modules/stdlib (Makefile.am): Likewise.
83257         * modules/string (Makefile.am): Likewise.
83258         * modules/sys_ioctl (Makefile.am): Likewise.
83259         * modules/sys_select (Makefile.am): Likewise.
83260         * modules/sys_socket (Makefile.am): Likewise.
83261         * modules/sys_stat (Makefile.am): Likewise.
83262         * modules/sys_times (Makefile.am): Likewise.
83263         * modules/sys_utsname (Makefile.am): Likewise.
83264         * modules/sys_wait (Makefile.am): Likewise.
83265         * modules/termios (Makefile.am): Likewise.
83266         * modules/time (Makefile.am): Likewise.
83267         * modules/unistd (Makefile.am): Likewise.
83268         * modules/wchar (Makefile.am): Likewise.
83270 2011-06-08  Eric Blake  <eblake@redhat.com>
83272         strerror: simplify replacement
83273         * m4/strerror.m4 (gl_PREREQ_STRERROR): Delete.
83274         * modules/strerror (configure.ac): No prereqs needed here...
83275         * modules/strerror-override (configure.ac): ...but this needs it.
83276         (Files): Add file for needed prereq macro.
83278 2011-06-08  Bruno Haible  <bruno@clisp.org>
83280         strerror_r-posix: Tweaks.
83281         * m4/strerror.m4 (gl_FUNC_STRERROR): Omit the code that tests
83282         gl_cv_func_strerror_r_works if gl_FUNC_STRERROR_R_WORKS is not present.
83283         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R_WORKS): Fix AC_CACHE_CHECK
83284         message. Move gl_HEADER_STRING_H_DEFAULTS invocation from here...
83285         (gl_FUNC_STRERROR_R): ... to here.
83286         (gl_PREREQ_STRERROR_R): Test for __xpg_strerror_r.
83288 2011-06-07  Eric Blake  <eblake@redhat.com>
83290         perror: document fixed bugs
83291         * doc/posix-functions/perror.texi (perror): Document recent
83292         patches.
83294 2011-06-07  Paul Eggert  <eggert@cs.ucla.edu>
83296         stat-time: get_stat_birthtime failure is better-defined
83297         * lib/stat-time.h (get_stat_birthtime): If the time is not available,
83298         return a timestamp whose tv_sec and tv_nsec values are both -1.
83299         Previously, the spec said only that the tv_nsec value was negative.
83300         This upward-compatible change simplifies GNU tar a bit.
83302 2011-06-07  Eric Blake  <eblake@redhat.com>
83304         strerror_r-posix: work around cygwin 1.7.9
83305         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Split...
83306         (gl_FUNC_STRERROR_R_WORKS): ...into new macro, to detect Cygwin
83307         bug without replacing strerror_r.
83308         * m4/strerror.m4 (gl_FUNC_STRERROR): Replace strerror if
83309         strerror_r is buggy, but without requiring strerror_r compilation.
83310         * doc/posix-functions/strerror_r.texi (strerror_r): Fix docs.
83312         test-perror: relax test to ignore cygwin bug
83313         * tests/test-perror2.c (main): Relax test on requiring detection
83314         of stream errors, and use unbuffered stream.
83315         * doc/posix-functions/dprintf.texi (dprintf): Document bug.
83316         * doc/posix-functions/fprintf.texi (fprintf): Likewise.
83317         * doc/posix-functions/fputc.texi (fputc): Likewise.
83318         * doc/posix-functions/fputs.texi (fputs): Likewise.
83319         * doc/posix-functions/fputws.texi (fputws): Likewise.
83320         * doc/posix-functions/fwprintf.texi (fwprintf): Likewise.
83321         * doc/posix-functions/fwrite.texi (fwrite): Likewise.
83322         * doc/posix-functions/getopt.texi (getopt): Likewise.
83323         * doc/posix-functions/perror.texi (perror): Likewise.
83324         * doc/posix-functions/printf.texi (printf): Likewise.
83325         * doc/posix-functions/psiginfo.texi (psiginfo): Likewise.
83326         * doc/posix-functions/psignal.texi (psignal): Likewise.
83327         * doc/posix-functions/putc.texi (putc): Likewise.
83328         * doc/posix-functions/putc_unlocked.texi (putc_unlocked):
83329         Likewise.
83330         * doc/posix-functions/putchar.texi (putchar): Likewise.
83331         * doc/posix-functions/putchar_unlocked.texi (putchar_unlocked):
83332         Likewise.
83333         * doc/posix-functions/puts.texi (puts): Likewise.
83334         * doc/posix-functions/putwc.texi (putwc): Likewise.
83335         * doc/posix-functions/putwchar.texi (putwchar): Likewise.
83336         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
83337         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
83338         * doc/posix-functions/vfwprintf.texi (vfwprintf): Likewise.
83339         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
83340         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
83341         * doc/posix-functions/wordexp.texi (wordexp): Likewise.
83342         * doc/posix-functions/wprintf.texi (wprintf): Likewise.
83344 2011-05-22  Bruno Haible  <bruno@clisp.org>
83346         strerror: Move AC_LIBOBJ invocations to module description.
83347         * m4/strerror.m4 (gl_FUNC_STRERROR): Move AC_LIBOBJ and
83348         gl_PREREQ_STRERROR invocations from here...
83349         * modules/strerror (configure.ac): ... to here.
83351 2011-05-21  Bruno Haible  <bruno@clisp.org>
83353         perror: Use common idiom.
83354         * modules/perror (configure.ac): Reorder statements.
83356 2011-06-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
83358         tests: fix usage message in 'mktempd_'
83359         * tests/init.sh (mktempd_): In the usage message, use literal
83360         'mktempd_', not '$ME' (which is even undefined), as the name of
83361         the subroutine.
83363 2011-06-07  Stefano Lattarini  <stefano.lattarini@gmail.com>
83365         tests init: new function 'fatal_', for hard errors
83366         Before this patch, the only way offered by tests/init.sh to
83367         properly signal a hard error was the `framework_failure_'
83368         function.  But the error message issued by that function,
83369         as its name would suggest, refers to a set-up failure in the
83370         testsuite, while hard errors can obviously also be due to
83371         other reasons.  The best way to fix this inconsistency is to
83372         introduce a new function with a more general error message.
83373         * tests/init.sh (fatal_): New function.
83375 2011-06-06  Eric Blake  <eblake@redhat.com>
83377         canonicalize-lgpl: use common idiom
83378         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Prefer older rm -rf
83379         over newer POSIX -Rf.
83380         Reported by Bruno Haible.
83382         canonicalize-lgpl: work around AIX realpath bug
83383         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Expose AIX bug.
83384         * doc/posix-functions/realpath.texi (realpath): Document it.
83385         Reported by Bruno Haible.
83387         strerror: work around FreeBSD bug
83388         * lib/strerror.c (strerror): Special case 0.
83389         Reported by Bruno Haible.
83391         strerror-override: avoid bloating errno module
83392         * modules/errno (Files, configure.ac): Move replacement strings...
83393         * modules/strerror-override: ...to new module.
83394         * modules/strerror (Depends-on): Add strerror-override.
83395         * modules/strerror_r-posix (Depends-on): Likewise.
83396         * MODULES.html.sh: Document new module.
83397         Reported by Bruno Haible.
83399 2011-06-06  Bruno Haible  <bruno@clisp.org>
83401         spawn-pipe tests: Rename program.
83402         * tests/test-spawn-pipe-main.c: Renamed from tests/test-spawn-pipe.c.
83403         * tests/test-spawn-pipe-child.c: Update comment.
83404         * tests/test-spawn-pipe.sh: Update.
83405         * modules/spawn-pipe-tests (Files, Makefile.am): Update.
83407         spawn-pipe tests: Link the child program only against libc.
83408         * tests/test-spawn-pipe-child.c: New file, extracted from
83409         tests/test-spawn-pipe.c.
83410         (main): Expect only one argument.
83411         (is_open): New function, copied from tests/test-pipe.c.
83412         * tests/test-spawn-pipe.c: Don't include <errno.h>.
83413         (child_main): Remove function.
83414         (test_pipe): Pass only one argument to the child program.
83415         (main): Remove child process code. Expect the child program's name as
83416         first argument.
83417         * tests/test-spawn-pipe.sh: Pass the child program's name as first
83418         argument.
83419         * modules/spawn-pipe-tests (Files): Add tests/test-spawn-pipe-child.c.
83420         (Makefile.am): Add test-spawn-pipe-child to check_PROGRAMS. Link
83421         test-spawn-pipe-child against no libraries.
83423 2011-06-06  Bruno Haible  <bruno@clisp.org>
83425         careadlinkat: Avoid mismatch between ssize_t and int.
83426         * lib/careadlinkat.h (careadlinkatcwd): Declare as a function always.
83427         * lib/careadlinkat.c (careadlinkatcwd): Define always.
83429 2011-06-06  Jim Meyering  <meyering@redhat.com>
83431         gnulib-common.m4: add _GL_ATTRIBUTE_CONST and _GL_ATTRIBUTE_PURE
83432         * m4/gnulib-common.m4 (gl_COMMON): Emit definitions of
83433         _GL_ATTRIBUTE_CONST and _GL_ATTRIBUTE_PURE.
83435 2011-06-05  Bruno Haible  <bruno@clisp.org>
83437         ansi-c++-opt: Interoperability with libtool.
83438         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): When a C++ compiler is not found,
83439         set the variable to "no", not to ":".
83440         * NEWS: Mention the change.
83442 2011-06-05  Bruno Haible  <bruno@clisp.org>
83444         acl: Fix test failure on AIX 7.
83445         * tests/test-sameacls.c (main) [AIX]: Fix aclx_printStr invocation.
83446         Based on a patch by Jørn Amundsen <Jorn.Amundsen@ntnu.no>.
83448 2011-06-05  Bruno Haible  <bruno@clisp.org>
83450         pipe-filter-ii: Fix test failure on AIX and IRIX.
83451         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): When write() fails
83452         with EAGAIN, retry with a smaller buffer size.
83454 2011-06-05  Bruno Haible  <bruno@clisp.org>
83456         localename: Fix link dependencies.
83457         * modules/localename (Link): Mention $(LIBTHREAD) or $(LTLIBTHREAD).
83458         * modules/localename-tests (Makefile.am): Link test-localename with
83459         $(LIBTHREAD).
83461 2011-06-05  Bruno Haible  <bruno@clisp.org>
83463         error: Avoid gcc warning.
83464         * lib/error.c (strerror_r): Declare also when its return type is 'int'.
83466 2011-06-05  Bruno Haible  <bruno@clisp.org>
83468         unsetenv: Avoid gcc warning.
83469         * lib/unsetenv.c (unsetenv): Provide declaration if system lacks it.
83471 2011-06-05  Bruno Haible  <bruno@clisp.org>
83473         setenv: Avoid gcc warning.
83474         * lib/setenv.c (setenv): Provide declaration if system lacks it.
83476 2011-06-05  Bruno Haible  <bruno@clisp.org>
83478         sys_select: Ensure memset is declared also on AIX 7.
83479         * lib/sys_select.in.h: Include <string.h> also on AIX.
83480         * doc/posix-headers/sys_select.texi: Mention that <sys/select.h> is not
83481         self-contained also on AIX 7.1.
83483 2011-06-04  Jim Meyering  <meyering@redhat.com>
83485         maint.mk: sc_unmarked_diagnostics: don't hard-code "error"
83486         * top/maint.mk (sc_unmarked_diagnostics): Don't hard-code the
83487         function name, "error".
83488         (_gl_translatable_diag_func_re): New configurable variable.
83490 2011-06-04  Bruno Haible  <bruno@clisp.org>
83492         getopt: Avoid gcc warning.
83493         * lib/getopt.c (_getopt_internal_r): Remove unused variable 'ambig'.
83495 2011-06-04  Bruno Haible  <bruno@clisp.org>
83497         strerror_r: Fix comments.
83498         * lib/strerror_r.c (strerror_r): Update comments after 2011-06-01
83499         commit.
83501 2011-06-04  Bruno Haible  <bruno@clisp.org>
83503         perror: Fix compilation error.
83504         * lib/perror.c: Don't include intprops.h, verify.h, strerror-impl.h.
83505         Undefine fprintf, not sprintf.
83506         * modules/perror (Depends-on): Remove intprops, verify.
83508 2011-06-04  Bruno Haible  <bruno@clisp.org>
83510         setlocale: Enable replacement on Cygwin 1.5.
83511         * m4/setlocale.m4 (gl_FUNC_SETLOCALE): Set REPLACE_SETLOCALE also on
83512         Cygwin 1.5.x.
83513         * doc/posix-functions/setlocale.texi: Mention that the problem with the
83514         LC_CTYPE category also exists on Cygwin 1.5.x.
83516 2011-06-04  Bruno Haible  <bruno@clisp.org>
83518         strerror-override: Don't disable symbol renamings.
83519         * lib/strerror-override.h: Include errno.h and stddef.h, not string.h.
83520         * lib/strerror-override.c: Include config.h.
83521         (strerror_override): Don't undefine.
83523 2011-06-03  Bruno Haible  <bruno@clisp.org>
83525         Copyright: Use LGPL 2.1 instead of LGPL 2.0.
83526         * lib/localename.h: Update copyright header.
83527         * lib/localename.c: Likewise.
83528         * lib/relocatable.h: Likewise.
83529         * lib/relocatable.c: Likewise.
83531 2011-06-02  Bruno Haible  <bruno@clisp.org>
83533         doc: Fix a module name.
83534         * doc/posix-functions/open.texi: Fix module name 'nonblocking'.
83536 2011-06-02  Bruno Haible  <bruno@clisp.org>
83538         pipe2: Remove dependency on 'nonblocking' module.
83539         * lib/pipe2.c: Include verify.h. Include nonblocking.h only if
83540         O_NONBLOCK is defined by gnulib.
83541         (pipe2) [WIN32]: If O_NONBLOCK is not defined by gnulib, verify that it
83542         is zero.
83543         * modules/pipe2 (Depends-on): Add verify. Remove nonblocking.
83544         * tests/test-pipe2.c: Include nonblocking.h only if O_NONBLOCK is
83545         defined by gnulib.
83546         (get_nonblocking_flag): New function.
83547         (main): Test O_NONBLOCK flag only if it is nonzero.
83548         * doc/glibc-functions/pipe2.texi: Mention the 'nonblocking' module.
83550 2011-06-03  Jim Meyering  <meyering@redhat.com>
83552         maint: three new prohibit-header-without-use rules
83553         Prohibit use of cloexec.h, posixver.h, same.h without use.
83554         * top/maint.mk (sc_prohibit_cloexec_without_use): New rule.
83555         (sc_prohibit_posixver_without_use): Likewise.
83556         (sc_prohibit_same_without_use): Likewise.
83558 2011-06-02  Paul Eggert  <eggert@cs.ucla.edu>
83560         allocator: 'die' routine is now given requested size
83561         * lib/allocator.h (struct allocator.die): New size arg.
83562         * lib/careadlinkat.c (careadlinkat): Pass size to 'die' function.
83563         If the actual problem is an ssize_t limitation, not a size_t or
83564         malloc failure, fail with errno==ENAMETOOLONG instead of calling 'die'.
83566 2011-06-01  Eric Blake  <eblake@redhat.com>
83568         strerror: drop strerror_r dependency
83569         * lib/strerror_r.c (strerror_r): Move gnulib replacement strings...
83570         * lib/strerror-override.c (strerror_override): ...to new file.
83571         * lib/strerror-override.h: Add prototype.
83572         * lib/strerror-impl.h: Delete.
83573         * lib/strerror.c (strerror): New implementation.
83574         * modules/errno (Files): Add new files.
83575         (configure.ac): Compile new file as appropriate.
83576         * modules/strerror (Files): Drop unused file.
83577         (Depends-on): Drop strerror_r-posix.
83578         * MODULES.html.sh: Document strerror_r-posix.
83579         Requested by Sam Steingold.
83581         perror: call strerror_r directly
83582         * modules/perror (Files): Drop strerror-impl.h.
83583         * lib/perror.c (perror): Use our own stack buffer, rather than
83584         calling a wrapper that uses static storage.
83585         * doc/posix-functions/perror.texi (perror): Document a limitation
83586         of our replacement.
83588         strerror_r: fix includes for FreeBSD
83589         * lib/strerror_r.c (includes): Use <stdlib.h> unconditionally,
83590         since we use abort on some platforms.
83591         Reported by Matthias Bolte.
83593 2011-05-31  Bruno Haible  <bruno@clisp.org>
83595         Fix link errors in tests: openat-die uses gettext-h.
83596         * modules/areadlinkat-tests (Makefile.am): Link test-areadlinkat
83597         against $(LIBINTL).
83598         * modules/dirent-safer-tests (Makefile.am): Link test-dirent-safer
83599         against $(LIBINTL).
83600         * modules/fdopendir-tests (Makefile.am): Link test-fdopendir against
83601         $(LIBINTL).
83602         * modules/fdutimensat-tests (Makefile.am): Link test-fdutimensat
83603         against $(LIBINTL).
83604         * modules/linkat-tests (Makefile.am): Link test-linkat against
83605         $(LIBINTL).
83606         * modules/mkfifoat-tests (Makefile.am): Link test-mkfifoat against
83607         $(LIBINTL).
83608         * modules/openat-safer-tests (Makefile.am): Link test-openat-safer
83609         against $(LIBINTL).
83610         * modules/openat-tests (Makefile.am): Link test-fchownat, test-fstatat,
83611         test-mkdirat, test-openat, test-unlinkat against $(LIBINTL).
83612         * modules/readlinkat-tests (Makefile.am): Link test-readlinkat against
83613         $(LIBINTL).
83614         * modules/symlinkat-tests (Makefile.am): Link test-symlinkat against
83615         $(LIBINTL).
83616         * modules/utimensat-tests (Makefile.am): Link test-utimensat against
83617         $(LIBINTL).
83618         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
83620 2011-05-31  Bruno Haible  <bruno@clisp.org>
83622         Fix link errors in tests: wait-process uses gettext-h.
83623         * modules/nonblocking-pipe-tests (Makefile.am): Set
83624         test_nonblocking_pipe_main_LDADD.
83625         * modules/nonblocking-socket-tests (Makefile.am): Link
83626         test-nonblocking-socket-main against $(LIBINTL).
83627         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
83629 2011-05-29  Paul Eggert  <eggert@cs.ucla.edu>
83631         assert-h: work around 'verify' incompatibility
83632         * lib/verify.h: Use @...@ directives, not ifdef.
83633         * modules/assert-h (assert.h): Implement the directives.
83634         (assert.h): Substitute the symbol-prefix more consistently.
83636 2011-05-29  Jim Meyering  <meyering@redhat.com>
83638         trim: remove three superfluous assignments
83639         * lib/trim.c (trim2): Remove three superfluous assignments
83640         and correct brace positioning.
83642 2011-05-29  Bruno Haible  <bruno@clisp.org>
83644         wctype-h: Avoid namespace pollution on Solaris 2.6.
83645         * lib/wctype.in.h: On Solaris, undefine 'multibyte' and a few other
83646         identifiers.
83647         * doc/posix-headers/wctype.texi: Mention the problem.
83648         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
83650 2011-05-28  Jim Meyering  <meyering@redhat.com>
83652         parse-datetime.y: accommodate -Wstrict-overflow
83653         * lib/parse-datetime.y (yylex): Rearrange pointer arithmetic to
83654         placate -Wstrict-overflow.
83656         trim: avoid a warning from -O2 -Wstrict-overflow
83657         * lib/trim.c (trim2): Declare local to be "unsigned int", not "int".
83659 2011-05-29  Bruno Haible  <bruno@clisp.org>
83661         gnulib-tool: Fix bug in yesterday's commit.
83662         * gnulib-tool (func_create_testdir): Don't add gltests to $subdirs
83663         twice.
83665 2011-05-29  Bruno Haible  <bruno@clisp.org>
83667         Allow multiple gnulib generated include files to be combined.
83668         * gnulib-tool (func_compute_include_guard_prefix): New function.
83669         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Resolve also
83670         ${gl_include_guard_prefix} references.
83671         (func_import, func_create_testdir): Invoke
83672         func_compute_include_guard_prefix.
83673         * lib/arpa_inet.in.h: Use the @GUARD_PREFIX@ placeholder.
83674         * lib/ctype.in.h: Likewise.
83675         * lib/dirent.in.h: Likewise.
83676         * lib/errno.in.h: Likewise.
83677         * lib/fcntl.in.h: Likewise.
83678         * lib/float.in.h: Likewise.
83679         * lib/getopt.in.h: Likewise.
83680         * lib/iconv.in.h: Likewise.
83681         * lib/langinfo.in.h: Likewise.
83682         * lib/locale.in.h: Likewise.
83683         * lib/math.in.h: Likewise.
83684         * lib/netdb.in.h: Likewise.
83685         * lib/netinet_in.in.h: Likewise.
83686         * lib/poll.in.h: Likewise.
83687         * lib/pthread.in.h: Likewise.
83688         * lib/pty.in.h: Likewise.
83689         * lib/sched.in.h: Likewise.
83690         * lib/se-selinux.in.h: Likewise.
83691         * lib/search.in.h: Likewise.
83692         * lib/signal.in.h: Likewise.
83693         * lib/spawn.in.h: Likewise.
83694         * lib/stdarg.in.h: Likewise.
83695         * lib/stddef.in.h: Likewise.
83696         * lib/stdint.in.h: Likewise.
83697         * lib/stdio.in.h: Likewise.
83698         * lib/stdlib.in.h: Likewise.
83699         * lib/string.in.h: Likewise.
83700         * lib/strings.in.h: Likewise.
83701         * lib/sys_file.in.h: Likewise.
83702         * lib/sys_ioctl.in.h: Likewise.
83703         * lib/sys_select.in.h: Likewise.
83704         * lib/sys_socket.in.h: Likewise.
83705         * lib/sys_stat.in.h: Likewise.
83706         * lib/sys_time.in.h: Likewise.
83707         * lib/sys_times.in.h: Likewise.
83708         * lib/sys_uio.in.h: Likewise.
83709         * lib/sys_utsname.in.h: Likewise.
83710         * lib/sys_wait.in.h: Likewise.
83711         * lib/sysexits.in.h: Likewise.
83712         * lib/termios.in.h: Likewise.
83713         * lib/time.in.h: Likewise.
83714         * lib/unistd.in.h: Likewise.
83715         * lib/wchar.in.h: Likewise.
83716         * lib/wctype.in.h: Likewise.
83717         * modules/arpa_inet (Makefile.am): Substitute @GUARD_PREFIX@.
83718         * modules/ctype (Makefile.am): Likewise.
83719         * modules/dirent (Makefile.am): Likewise.
83720         * modules/errno (Makefile.am): Likewise.
83721         * modules/fcntl-h (Makefile.am): Likewise.
83722         * modules/float (Makefile.am): Likewise.
83723         * modules/getopt-posix (Makefile.am): Likewise.
83724         * modules/iconv-h (Makefile.am): Likewise.
83725         * modules/langinfo (Makefile.am): Likewise.
83726         * modules/locale (Makefile.am): Likewise.
83727         * modules/math (Makefile.am): Likewise.
83728         * modules/netdb (Makefile.am): Likewise.
83729         * modules/netinet_in (Makefile.am): Likewise.
83730         * modules/poll-h (Makefile.am): Likewise.
83731         * modules/pthread (Makefile.am): Likewise.
83732         * modules/pty (Makefile.am): Likewise.
83733         * modules/sched (Makefile.am): Likewise.
83734         * modules/search (Makefile.am): Likewise.
83735         * modules/selinux-h (Makefile.am): Likewise.
83736         * modules/signal (Makefile.am): Likewise.
83737         * modules/spawn (Makefile.am): Likewise.
83738         * modules/stdarg (Makefile.am): Likewise.
83739         * modules/stddef (Makefile.am): Likewise.
83740         * modules/stdint (Makefile.am): Likewise.
83741         * modules/stdio (Makefile.am): Likewise.
83742         * modules/stdlib (Makefile.am): Likewise.
83743         * modules/string (Makefile.am): Likewise.
83744         * modules/strings (Makefile.am): Likewise.
83745         * modules/sys_file (Makefile.am): Likewise.
83746         * modules/sys_ioctl (Makefile.am): Likewise.
83747         * modules/sys_select (Makefile.am): Likewise.
83748         * modules/sys_socket (Makefile.am): Likewise.
83749         * modules/sys_stat (Makefile.am): Likewise.
83750         * modules/sys_time (Makefile.am): Likewise.
83751         * modules/sys_times (Makefile.am): Likewise.
83752         * modules/sys_uio (Makefile.am): Likewise.
83753         * modules/sys_utsname (Makefile.am): Likewise.
83754         * modules/sys_wait (Makefile.am): Likewise.
83755         * modules/sysexits (Makefile.am): Likewise.
83756         * modules/termios (Makefile.am): Likewise.
83757         * modules/time (Makefile.am): Likewise.
83758         * modules/unistd (Makefile.am): Likewise.
83759         * modules/wchar (Makefile.am): Likewise.
83760         * modules/wctype-h (Makefile.am): Likewise.
83761         * modules/assert-h (Makefile.am): Replace _GL_VERIFY_H specially.
83763 2011-05-29  Bruno Haible  <bruno@clisp.org>
83765         assert-h: Allow multiple gnulib generated replacements to coexist.
83766         * lib/verify.h (struct _gl_verify_type): Avoid identical redefinition.
83768 2011-05-29  Bruno Haible  <bruno@clisp.org>
83770         argp: Allow coexistence with strerror_r-posix module.
83771         * lib/argp-help.c (__argp_failure): If strerror_r is defined as a macro
83772         (either to __xpg_strerror_r by glibc's <string.h> or to rpl_strerror_r
83773         by gnulib's <string.h> replacement), assume it has the POSIX signature,
83774         not the glibc signature.
83776 2011-05-28  Bruno Haible  <bruno@clisp.org>
83778         gnulib-tool: Alternative structure of testdirs, similar to --import.
83779         * gnulib-tool: New option --single-configure.
83780         (func_usage): Document it.
83781         (single_configure): New variable.
83782         (func_modules_transitive_closure_separately,
83783         func_modules_transitive_closure_separately,
83784         func_determine_use_libtests, func_modules_add_dummy_separately,
83785         func_modules_to_filelist_separately): New functions, extracted from
83786         func_import.
83787         (func_emit_tests_Makefile_am): Handle $single_configure = true case.
83788         (func_import): Use the new functions.
83789         (func_create_testdir): Set final_modules. Handle $single_configure =
83790         true case.
83792 2011-05-28  Bruno Haible  <bruno@clisp.org>
83794         getloadavg: Remove an unreliable safety check.
83795         * m4/getloadavg.m4 (gl_GETLOADAVG): Drop argument. Remove test whether
83796         getloadavg.c is in place.
83797         * modules/getloadavg (configure.ac): Drop argument of gl_GETLOADAVG.
83798         Reported by Sam Steingold <sds@gnu.org>.
83800 2011-05-28  Bruno Haible  <bruno@clisp.org>
83802         doc: Cleanup yet another file produced by texinfo.tex.
83803         * doc/Makefile (mostlyclean): Remove also gnulib.cn.
83805 2011-05-28  Bruno Haible  <bruno@clisp.org>
83807         Finish the conditional dependencies mechanism.
83808         * gnulib-tool: New option --no-conditional-dependencies.
83809         (func_usage): Document it. Don't mark --conditional-dependencies as
83810         experimental.
83811         (cond_dependencies): The possible values can now be true, false, empty.
83812         (func_modules_transitive_closure, func_emit_autoconf_snippets): Update.
83813         (func_import): Store setting in gnulib-cache.m4 and read it from there.
83814         * doc/gnulib-tool.texi (Conditional dependencies): New section.
83816 2011-05-28  Bruno Haible  <bruno@clisp.org>
83818         doc: Use a recent texinfo.tex.
83819         * doc/Makefile (tex_opts): New variable.
83820         (%.dvi, %.pdf): Pass it to texi2dvi and texi2pdf.
83822 2011-05-28  Jim Meyering  <meyering@redhat.com>
83824         intprops.h: adjust comment to match code change
83825         * lib/intprops.h (_GL_INT_CONVERT): Adjust comment: now that E is used
83826         only once, it *may* have side effects.  Also fix an unrelated typo.
83827         (_GL_INT_SIGNED): Likewise.
83829 2011-05-26  Simon Josefsson  <simon@josefsson.org>
83831         * lib/gen-uni-tables.c: Say "gen-uni-tables.c" consistently.
83833 2011-05-26  Bruno Haible  <bruno@clisp.org>
83835         mbsrchr: Avoid collision with system function on Interix.
83836         * lib/string.in.h (mbsrchr): Define as rpl_mbsrchr also on Interix.
83837         Reported by Markus Duft <mduft@gentoo.org>.
83839 2011-05-15  James Youngman  <jay@gnu.org>
83841         getopt: for ambiguous options, enumerate the possibilities.
83842         * lib/getopt.c (_getopt_internal_r): Merge glibc change printing
83843         the ambiguous options when an ambiguous prefix is given. This was
83844         http://sourceware.org/bugzilla/show_bug.cgi?id=7101.  The merged
83845         glibc change was
83846         http://sourceware.org/git/?p=glibc.git;a=commit;h=bd25564e1e98910ed69043ed6a6f884ce60e5780.
83848 2011-05-25  Eric Blake  <eblake@redhat.com>
83850         getcwd: work around mingw bug
83851         * lib/getcwd-lgpl.c (rpl_getcwd): Guarantee correct error.
83852         * doc/posix-functions/getcwd.texi (getcwd): Document it.
83853         Reported by Matthias Bolte.
83855 2011-05-24  Paul Eggert  <eggert@cs.ucla.edu>
83857         test-intprops: disable -Wtype-limits diagnostics
83858         * tests/test-intprops.c: Use a pragma to ignore -Wtype-limits
83859         diagnostics.  Otherwise, the integer overflow macros generate many
83860         diagnostics.  Reported by Jim Meyering in
83861         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00528.html>.
83863         intprops: shorten, to pacify gcc -Woverlength-strings
83864         * lib/intprops.h (_GL_INT_CONVERT, _GL_INT_NEGATE_CONVERT):
83865         (_GL_BINARY_OP_OVERFLOW): Say "0 * (x)" rather than "(x) - (x)",
83866         so that, for example, verify (INT_MULTIPLY_OVERFLOW (...)) is less
83867         likely to run afoul of C compiler limits for string constant lengths.
83868         See <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00528.html>.
83870 2011-05-24  Eric Blake  <eblake@redhat.com>
83872         docs: document recently fixed glibc printf bug
83873         * doc/posix-functions/fprintf.texi (fprintf): Document it.
83874         * doc/posix-functions/printf.texi (printf): Likewise.
83875         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
83876         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
83878         closein-tests: convert to init.sh
83879         * modules/closein-tests (Files): Add init.sh
83880         * tests/test-closein.sh Use it.
83882         yesno-tests: convert to init.sh
83883         * modules/yesno-tests (Files): Add init.sh.
83884         * tests/test-yesno.sh: Use it.
83886         atexit-tests: ensure reliable exit status
83887         * tests/test-atexit.sh: Prefer 'Exit' over 'exit'.
83888         Reported by Bruno Haible.
83890 2011-05-24  Bruno Haible  <bruno@clisp.org>
83892         strerror_r-posix: Respect rules for use of AC_LIBOBJ.
83893         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Move AC_LIBOBJ and
83894         gl_PREREQ_STRERROR_R invocations from here...
83895         * modules/strerror_r-posix (configure.ac): ... to here.
83897 2011-05-24  Eric Blake  <eblake@redhat.com>
83899         strerror_r: fix missing header
83900         * lib/strerror_r.c: Avoid compiler warning about snprintf.
83902         strerror_r: fix AIX test failures
83903         * lib/strerror_r.c (strerror_r): Convert silent truncation to
83904         ERANGE failure.
83906         strerror_r: fix Solaris test failures
83907         * lib/strerror_r.c (strerror_r): Partially populate buf on ERANGE
83908         failures.
83909         * doc/posix-functions/strerror_r.texi (strerror_r): Document this.
83911         strerror_r: enforce POSIX recommendations
83912         * lib/strerror_r.c (safe_copy): New helper method.
83913         (strerror_r): Guarantee a non-empty string.
83914         * tests/test-strerror_r.c (main): Enhance tests to incorporate
83915         recent POSIX rulings and to match our strerror guarantees.
83916         * doc/posix-functions/strerror_r.texi (strerror_r): Document this.
83918 2011-05-24  Jim Meyering  <meyering@redhat.com>
83920         test-perror2.c: avoid warning about unused variable
83921         * tests/test-perror2.c (main): Remove declaration of unused "fp".
83923 2011-05-24  Eric Blake  <eblake@redhat.com>
83925         perror: avoid spurious test failure on HP-UX
83926         * tests/test-perror.sh: Use Exit to avoid wrong exit status.
83928         tests: fix logic bug in init.sh
83929         * tests/init.sh: (gl_set_x_corrupts_stderr_): Clear for successful
83930         shell.
83932 2011-05-24  Jim Meyering  <meyering@redhat.com>
83934         utimensat: do not reference an out-of-scope buffer
83935         Otherwise, with __linux__ defined, "times" would point to a buffer, "ts"
83936         declared in an inner scope, yet "times" would be dereferenced outside
83937         the scope in which "ts" was valid.
83938         * lib/utimensat.c (rpl_utimensat) [__linux__]: Move the declaration
83939         of ts[2] "out/up", so that the use of aliased "times" (via
83940         "times = ts;") does not end up referencing an out-of-scope "ts"
83942         opendir-safer.c: don't clobber errno; don't close negative FD
83943         * lib/opendir-safer.c (opendir_safer):
83944         [HAVE_FDOPENDIR || GNULIB_FDOPENDIR]: Don't close a negative
83945         file descriptor, and more importantly, don't clobber the
83946         offending errno value with EINVAL.  Before, upon failure
83947         of dup_safer, we would pass the negative file descriptor to
83948         fdopendir, which would clobber errno.
83950 2011-05-23  Bruno Haible  <bruno@clisp.org>
83952         idcache: Fix module description.
83953         * modules/idcache (Include): Set to "idcache.h".
83955 2011-05-23  Paul Eggert  <eggert@cs.ucla.edu>
83957         gnulib-tool: fix portability problem with MacOS sed
83958         A sed command like "/x/{s/a/b/}" is not portable; a newline is needed
83959         before the "}".  Problem reported by Leo in
83960         <http://lists.gnu.org/r/emacs-devel/2011-05/msg00717.html>.
83961         * gnulib-tool (func_modules_transitive_closure): Insert newlines in
83962         sed_extract_condition1, sed_extract_condition2.
83964 2011-05-23  Bruno Haible  <bruno@clisp.org>
83966         hash: Simplify autoconf macro.
83967         * m4/hash.m4 (gl_HASH): Don't require AM_STDBOOL_H.
83969 2011-05-23  Bruno Haible  <bruno@clisp.org>
83971         getugroups: Fix module description.
83972         * modules/getugroups (Include): Set to "getugroups.h".
83974 2011-05-23  Bruno Haible  <bruno@clisp.org>
83976         linkat: Simplify autoconf macro.
83977         * m4/linkat.m4 (gl_FUNC_LINKAT): Don't require gl_FUNC_LINK.
83979 2011-05-23  Bruno Haible  <bruno@clisp.org>
83980             Eric Blake  <eblake@redhat.com>
83982         linkat, renameat: Update dependencies.
83983         * modules/renameat (Depends-on): Add dosname, save-cwd. Remove stpcpy.
83984         * modules/linkat (Depends-on): Likewise. Remove also readlink,
83985         symlinkat.
83987 2011-05-23  Jim Meyering  <meyering@redhat.com>
83989         maint.mk: more tight_scope improvements
83990         * top/maint.mk: (_gl_TS_var_match): Use $(_gl_TS_extern) here, too.
83991         (_gl_TS_headers): Define only in if-0'd block.
83992         (_gl_TS_dir): Omit the $(srcdir)/ prefix.  Sometimes we need it,
83993         sometimes we must *not* use it.  Adjust uses accordingly.
83994         (sc_tight_scope): Use much simpler grep-based test to determine
83995         whether we skip this rule.
83997         maint.mk: generalize/improve the tight-scope rule
83998         * top/maint.mk: Emit a warning when the test is skipped.
83999         (_gl_TS_dir): Add $(srcdir)/ prefix.
84000         (_gl_TS_function_match): Simplify, rather than trying
84001         to enumerate common types.  Otherwise, it would fail to match an
84002         "extern unsigned char const *" declaration in idutils.
84003         (_gl_TS_extern): Do not endorse use of "XTERN", but do provide
84004         a way to support use of that type of macro.
84005         (_gl_TS_var_match): Simplify regexp.
84006         (_gl_TS_obj_files): New configurable variable.
84007         (_gl_TS_headers): Likewise.
84009 2011-05-22  Paul Eggert  <eggert@cs.ucla.edu>
84011         verify: fix bug when gnulib <assert.h> is also included
84012         * lib/verify.h (verify, verify_true): Define if _GL_VERIFY_H
84013         is defined, not if _GL_STATIC_ASSERT_H is not defined.
84014         Perhaps there's a better way, but this fixes the immediate problem.
84015         Problem reported by Bruno Haible in
84016         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00478.html>.
84018 2011-05-22  Bruno Haible  <bruno@clisp.org>
84020         xgetcwd: Simplify autoconf macro.
84021         * m4/xgetcwd.m4 (gl_XGETCWD): Don't require gl_FUNC_GETCWD.
84023 2011-05-22  Bruno Haible  <bruno@clisp.org>
84025         New module 'mktime-internal'.
84026         * modules/mktime-internal: New file.
84027         * m4/timegm.m4 (gl_PREREQ_TIMEGM): Move contents to ...
84028         * m4/mktime.m4 (gl_FUNC_MKTIME_INTERNAL): New macro. Define
84029         mktime_internal as a C macro if libc has __mktime_internal.
84030         * modules/timegm (Depends-on): Add mktime-internal. Remove mktime. Add
84031         conditions.
84032         * MODULES.html.sh (Date and time <time.h>): Add mktime-internal.
84034 2011-05-22  Bruno Haible  <bruno@clisp.org>
84036         timegm: Correct mktime replacement statements.
84037         * m4/timegm.m4 (gl_PREREQ_TIMEGM): Set REPLACE_MKTIME, instead of
84038         defining mktime as a C macro. This completes a 2009-07-28 commit.
84040 2011-05-22  Bruno Haible  <bruno@clisp.org>
84042         timegm: Simplify autoconf macro.
84043         * m4/timegm.m4 (gl_PREREQ_TIMEGM): Don't require gl_TIME_R.
84045 2011-05-21  Paul Eggert  <eggert@cs.ucla.edu>
84047         clock-time: change to LGPLv2+.
84048         * modules/clock-time: Change from GPL to LGPLv2+.  Actually, it's
84049         BSD-like but we have no mark for that; this is good enough for now.
84051 2011-05-21  Bruno Haible  <bruno@clisp.org>
84053         strerror_r: Fix comments.
84054         * lib/strerror_r.c (strerror_r): Fix comment about Cygwin and sys_nerr.
84056 2011-05-21  Bruno Haible  <bruno@clisp.org>
84058         relocatable-prog-wrapper: Fix possible link error.
84059         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Move determination of
84060         HAVE_SETENV and REPLACE_SETENV and AC_LIBOBJ invocation from here...
84061         (gl_FUNC_SETENV): ... to here.
84062         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL_SEPARATE): Update comment.
84063         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): Likewise.
84065 2011-05-21  Bruno Haible  <bruno@clisp.org>
84067         relocatable-prog-wrapper: Assume strerror() exists.
84068         * modules/relocatable-prog-wrapper (Files): Remove lib/strerror.c,
84069         m4/strerror.m4.
84070         (configure.ac): Don't invoke gl_FUNC_STRERROR_SEPARATE.
84071         * lib/relocwrapper.c: Remove mention of strerror module.
84072         * lib/strerror.c: Assume REPLACE_STRERROR is 1.
84073         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Remove macro.
84074         (gl_FUNC_STRERROR): Inline it here. Don't define REPLACE_STRERROR as a
84075         C macro.
84077 2011-05-21  Bruno Haible  <bruno@clisp.org>
84079         select: Simplify replacement idiom.
84080         * m4/select.m4 (gl_FUNC_SELECT): Set REPLACE_SELECT also on native
84081         Win32 platforms.
84082         * lib/sys_select.in.h (select): Simplify accordingly.
84083         * modules/select (Depends-on): Likewise.
84085 2011-05-21  Bruno Haible  <bruno@clisp.org>
84087         mkdir-p: Simplify autoconf macro.
84088         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't require gl_FUNC_LCHMOD,
84089         gl_FUNC_LCHOWN.
84091 2011-05-21  Eric Blake  <eblake@redhat.com>
84093         strerror_r: avoid clobbering strerror on cygwin
84094         * lib/strerror_r.c (strerror_r): Don't use cygwin's strerror_r;
84095         fall back instead to sys_errlist.
84096         * modules/strerror (configure.ac): Add witness.
84097         * tests/test-strerror_r.c (main): Enhance test.
84098         * doc/posix-functions/strerror_r.texi (strerror_r): Document it.
84099         * tests/test-perror2.c (main): Free memory before exit.
84101 2011-05-21  Bruno Haible  <bruno@clisp.org>
84103         mkdtemp: Use gnulib naming conventions.
84104         * m4/mkdtemp.m4 (gl_FUNC_MKDTEMP): Renamed from gt_FUNC_MKDTEMP.
84105         * modules/mkdtemp (configure.ac): Update.
84107 2011-05-20  Eric Blake  <eblake@redhat.com>
84109         strerror_r: avoid corrupting errno on Solaris
84110         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Check for Solaris behavior.
84111         * doc/posix-functions/strerror_r.texi (strerror_r): Document it.
84113         strerror_r: avoid compiler warning
84114         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Don't return a char*.
84116         strerror_r: simplify AIX code
84117         * lib/strerror_r.c (strerror_r): Filter out buflen of 1 up front.
84119         test-perror: avoid spurious failure on FreeBSD
84120         * modules/perror-tests (Depends-on): Add strerror, now that
84121         strerror_r no longer pulls it in.
84123 2011-05-20  Bruno Haible  <bruno@clisp.org>
84125         strerror_r-posix: Remove unused dependencies.
84126         * modules/strerror_r-posix (Depends-on): Remove strerror.
84127         Reported by Eric Blake.
84129 2011-05-20  Paul Eggert  <eggert@cs.ucla.edu>
84131         intprops: remove assumption about A|B representation
84132         * lib/intprops.h (_GL_BINARY_OP_OVERFLOW): Do not assume that A|B
84133         is a valid integer if both A and B are.  Although this is true for
84134         all known practical hosts, the C standard doesn't guarantee it,
84135         and the code need not assume it.  Also, this change may work around
84136         HP-UX 11.23 and IRIX 6.5 cc bugs reported by Bruno Haible in
84137         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00426.html>.
84139 2011-05-20  Eric Blake  <eblake@redhat.com>
84141         perror: work around FreeBSD bug
84142         * m4/perror.m4 (gl_FUNC_PERROR): Also replace perror if strerror_r
84143         is broken.  Move AC_LIBOBJ...
84144         * modules/perror (configure.ac): Here.
84145         * doc/posix-functions/perror.texi (perror): Document this.
84146         * tests/test-perror2.c (main): Enhance test.
84148         test-perror: check for strerror interactions
84149         * tests/macros.h (STREQ): Add macro.
84150         * modules/perror-tests (Files): Add second test.
84151         * tests/test-perror2.c (main): New file.
84152         * doc/posix-functions/perror.texi (perror): Document glibc bug.
84154         test-perror: rewrite to use init script
84155         * modules/perror-tests (Files): Add init.sh.
84156         * tests/test-perror.sh: Use temporary directory.
84158 2011-05-20  Jim Meyering  <meyering@redhat.com>
84160         maint: replace misused "a" with "an"
84161         * doc/intprops.texi: "a integer"
84162         * doc/regex.texi: "a explanation"
84163         * lib/alignof.h: "a object"
84164         * lib/argmatch.h: "a explanation"
84165         * lib/argp-help.c: "a option" and "a OPTION_DOC"
84166         * lib/stdint.in.h: "a integer"
84167         * lib/userspec.c: "a owner"
84168         * doc/gnulib.texi: Fix "a idea", and reword.
84170 2011-05-19  Jim Meyering  <meyering@redhat.com>
84172         maint: correct misuse of "a" and "an"
84173         * doc/regex.texi (Collating Symbol Operators): s/an close.../a close/
84174         * lib/argp-help.c: "an docum...": s/an/a/
84175         * lib/argp-parse.c: "An vector": s/An/A/
84176         * lib/execute.c: "an native": s/an/a/
84177         * lib/spawn-pipe.c: Likewise.
84178         * lib/gc.h: "an Gc_rc": s/an/a/
84179         * lib/unigbrk.in.h: "an grapheme": s/an/a/
84180         * lib/fts.c: "an stat.st_dev": s/an/a/
84182 2011-05-19  Paul Eggert  <eggert@cs.ucla.edu>
84184         intprops-tests: work around HP-UX 11.23 cc bug with constants
84185         * tests/test-intprops.c (VERIFY): New macro.
84186         (main): Use it, instead of verify, to work around the compiler bug; see
84187         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00401.html>.
84189         intprops: work around IRIX 6.5 cc bug with 0u - 0u + -1
84190         See http://lists.gnu.org/r/bug-gnulib/2011-05/msg00406.html
84191         * lib/intprops.h (_GL_INT_NEGATE_CONVERT): New macro.
84192         (_GL_INT_SIGNED, _GL_INT_MAXIMUM, _GL_DIVIDE_OVERFLOW):
84193         (_GL_REMAINDER_OVERFLOW): Use it.
84195         intprops-tests: revert unsigned part of previous change
84196         * tests/test-intprops.c (UINT_MAX, ULONG_MAX, UINTMAX_MAX, U0, U1):
84197         Remove; they weren't actually needed.  All uses of U0 and U1 removed,
84198         and other casts to 'unsigned int' reverted to 'u' suffixes.  See
84199         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00406.html>.
84201 2011-05-19  Bruno Haible  <bruno@clisp.org>
84203         strerror_r: Work around strerror_r() change in Cygwin 1.7.8.
84204         * lib/strerror_r.c (strerror_r) [CYGWIN]: Recognize when the system's
84205         strerror_r() returned without filling the buffer.
84206         Reported by Eric Blake.
84208 2011-05-19  Eric Blake  <eblake@redhat.com>
84210         strerror_r: guarantee unchanged errno
84211         * lib/strerror_r.c (strerror_r): Guarantee unchanged errno.
84212         * lib/strerror-impl.h (strerror): Set errno to match strerror_r
84213         failure.
84214         * tests/test-strerror_r.c (main): Enhance test.
84216 2011-05-19  Bruno Haible  <bruno@clisp.org>
84218         strerror_r: Reorder #if blocks.
84219         * lib/strerror_r.c (strerror_r): Reorder conditionals in the function
84220         for consistency with the previous commit.
84222 2011-05-19  Bruno Haible  <bruno@clisp.org>
84224         perror: Avoid clobbering the strerror buffer when possible.
84225         * lib/strerror-impl.h: New file, extracted from lib/strerror.c.
84226         * lib/strerror.c: Include it.
84227         * modules/strerror (Files): Add lib/strerror-impl.h.
84228         * lib/perror.c: Include <stdlib.h>, intprops.h, verify.h.
84229         (my_strerror): New function, defined through lib/strerror-impl.h.
84230         (perror): Use it instead of strerror.
84231         * modules/perror (Files): Add lib/strerror-impl.h.
84232         (Depends-on): Remove strerror. Add intprops, verify, strerror_r-posix.
84234 2011-05-19  Eric Blake  <eblake@redhat.com>
84236         strerror_r: fix on newer cygwin
84237         * lib/strerror_r.c (strerror_r): Cygwin now has
84238         __xpg_strerror_r, use it.
84240 2011-05-19  Bruno Haible  <bruno@clisp.org>
84242         strerror_r: Avoid clobbering the strerror buffer when possible.
84243         * lib/strerror.c: Define _NETBSD_SOURCE. Include <nl_types.h>.
84244         (sys_nerr, sys_errlist): New declarations.
84245         (strerror_r): Be careful not to clobber the strerror buffer on NetBSD,
84246         HP-UX, native Win32, IRIX, and 32-bit Solaris.
84247         * m4/strerror_r.m4 (gl_PREREQ_STRERROR_R): Test whether catgets exists.
84249 2011-05-19  Bruno Haible  <bruno@clisp.org>
84251         strerror_r: Fix test failure on mingw.
84252         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Don't define
84253         EXTEND_STRERROR_R.
84254         * lib/strerror_r.c (strerror_r): Test the various GNULIB_defined_*
84255         macros from errno.in.h instead.
84257 2011-05-19  Eric Blake  <eblake@redhat.com>
84259         strerror: relax test for Solaris
84260         * tests/test-strerror.c (main): Permit Solaris behavior.
84261         * tests/test-strerror_r.c (main): Likewise.
84263         strerror: enforce POSIX ruling on strerror(0)
84264         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Expose BSD bug.
84265         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Likewise.
84266         * lib/strerror_r.c (rpl_strerror_r): Work around it.
84267         * doc/posix-functions/strerror.texi (strerror): Document it.
84268         * doc/posix-functions/strerror_r.texi (strerror_r): Likewise.
84269         * tests/test-strerror.c (main): Strengthen test.
84270         * tests/test-strerror_r.c (main): Likewise.
84272 2011-05-19  Paul Eggert  <eggert@cs.ucla.edu>
84274         intprop-tests: port to older and more-pedantic compilers
84275         * modules/intprops-tests (Files): Add tests/macros.h.
84276         * tests/test-intprops.c: Include macros.h.
84277         (TYPE_IS_INTEGER): Use ASSERT, not verify, to test this macro, as
84278         it's no longer documented to expand to an integer constant expression.
84279         (TYPE_SIGNED): Use ASSERT, not verify, to test this macro when the
84280         argument is floating point, as it's no longer documented to expand
84281         to an integer constant expression in that case.
84282         (UINT_MAX, ULONG_MAX, UINTMAX_MAX): Redefine to work around
84283         compiler bugs reported by Bruno Haible.  See
84284         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00401.html>.
84285         (U0, U1): New constants, to work around the same bugs.  Also,
84286         in tests, use e.g., "(unsigned int) 39" rather than "39u".
84288         intprops: work around C compiler bugs
84289         * lib/intprops.h (INT_MULTIPLY_RANGE_OVERFLOW): Work around compiler
84290         bug in Sun C 5.11 2010/08/13 and other compilers; see
84291         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00401.html>.
84293         intprops: TYPE_IS_INTEGER, TYPE_SIGNED not integer constant exprs
84294         * doc/intprops.texi (Integer Type Determination): Fix
84295         documentation for TYPE_IS_INTEGER: it returns an constant
84296         expression, not an integer constant expression.  Fix doc for
84297         TYPE_SIGNED: it returns an integer constant expression only if its
84298         argument is an integer type.  (TYPE_IS_INTEGER is the same, but is
84299         hardly worth documented that way....)
84301 2011-05-18  Bruno Haible  <bruno@clisp.org>
84303         strerror_r: Avoid clobbering the strerror buffer when possible.
84304         * lib/strerror_r.c (strerror_r): Merge the three implementations.
84305         Handle gnulib defined errno values here. When strerror() returns NULL
84306         or an empty string, return EINVAL.
84307         * lib/strerror.c (strerror): Always call strerror_r. Don't handle
84308         gnulib defined errno values here.
84309         * modules/strerror (Depends-on): Add verify, strerror_r-posix.
84311 2011-05-18  Eric Blake  <eblake@redhat.com>
84313         fnmatch: avoid compiler warning
84314         * lib/fnmatch_loop.c (FCT): Use correct type.
84315         Reported by Matthias Bolte.
84317 2011-05-13  Jim Meyering  <meyering@redhat.com>
84319         maint.mk: three new prohibit_<HDR>_without_use rules
84320         * top/maint.mk (sc_prohibit_stdio--_without_use): New rule.
84321         (sc_prohibit_stdio-safer_without_use): Likewise.
84322         (sc_prohibit_xfreopen_without_use): Likewise.
84324 2011-05-17  Jim Meyering  <meyering@redhat.com>
84326         announce-gen: fail if the NEWS delta is empty
84327         If there's nothing noteworthy in NEWS, then either you forgot
84328         or you shouldn't be releasing.
84329         * build-aux/announce-gen: Die if the NEWS delta is effectively empty.
84331 2011-05-17  Pádraig Brady  <P@draigBrady.com>
84333         * top/maint.mk (_gl_tight_scope:): Automatically exclude compiler
84334         reserved symbols starting with double underscore from the check.
84336 2011-05-17  Paul Eggert  <eggert@cs.ucla.edu>
84338         intprops: add doc
84339         * doc/intprops.texi: New file, documenting intprops.
84340         * doc/gnulib.texi (Particular Modules): Include it.
84342         verify: add doc to gnulib manual and fix example
84343         * doc/gnulib.texi (Compile-time Assertions): New node, for 'verify'.
84344         * doc/verify.texi (Compile-time Assertions): Update 'assert' doc.
84345         (Compile-time Assertions): Fix example so it can't overflow.
84347 2011-05-17  Jim Meyering  <meyering@redhat.com>
84349         warnings.m4: don't usurp save_CPPFLAGS variable name
84350         * m4/warnings.m4: Prefix local temporary variable name with gl_.
84352         doc: fix typo
84353         * doc/gnulib-intro.texi (Target Platforms): s/is/are/
84355 2011-05-16  Paul Eggert  <eggert@cs.ucla.edu>
84356             Bruno Haible  <bruno@clisp.org>
84358         doc: Tweak recent change.
84359         * README (Portability guidelines): Tweak new text.
84360         * doc/gnulib-intro.texi (Target Platforms): Likewise. Mention
84361         Interix 6.1.
84363 2011-05-16  Eric Blake  <eblake@redhat.com>
84365         inttypes: avoid autoconf warning
84366         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): Only expand once.
84367         * m4/stdint.m4 (gl_STDINT_H): Likewise.
84369 2011-05-16  Sam Steingold  <sds@gnu.org>
84370         and Eric Blake  <eblake@redhat.com>
84372         vc-list-files: accept multiple directory operands
84373         * build-aux/vc-list-files: Iterate over all remaining operands.
84375 2011-05-16  Bruno Haible  <bruno@clisp.org>
84377         Fix confusion regarding deprecated modules.
84378         * modules/calloc (Status, Notice): Mark module as deprecated, not
84379         obsolete.
84380         * modules/fnmatch-posix (Status, Notice): Likewise.
84381         * modules/getdate (Status, Notice): Likewise.
84382         * modules/getopt (Status, Notice): Likewise.
84383         * modules/malloc (Status, Notice): Likewise.
84384         * modules/pipe (Status, Notice): Likewise.
84385         * modules/realloc (Status, Notice): Likewise.
84386         * modules/rename-dest-slash (Status, Notice): Likewise.
84387         * modules/unictype/bidicategory-all (Status, Notice): Likewise.
84388         * modules/unictype/bidicategory-byname (Status, Notice): Likewise.
84389         * modules/unictype/bidicategory-name (Status, Notice): Likewise.
84390         * modules/unictype/bidicategory-of (Status, Notice): Likewise.
84391         * modules/unictype/bidicategory-test (Status, Notice): Likewise.
84393 2011-05-16  Bruno Haible  <bruno@clisp.org>
84395         doc: List the target platforms.
84396         * doc/gnulib-intro.texi (Target Platforms): New section.
84397         * doc/gnulib.texi (Introduction): Update menu.
84398         * README (Portability guidelines): Refer to the new section. Update
84399         statement about oldest supported environment. Remove rationale why
84400         <errno.h>, <string.h>, <stdlib.h> are assumed. Update example of an
84401         unportable C89 function.
84402         Reported by Bastien Roucariès <roucaries.bastien@gmail.com> and
84403         Charles Wilson <cygwin@cwilson.fastmail.fm>. Feedback from Paul Eggert.
84405 2011-05-16  Paul Eggert  <eggert@cs.ucla.edu>
84407         * build-aux/bootstrap (gnulib_tool): Handle symlink timestamps better.
84409 2011-05-13  Paul Eggert  <eggert@cs.ucla.edu>
84411         intprops-tests: new module
84412         * modules/intprops-tests, tests/test-intprops.c: New files.
84414         intprops: add safe, portable integer overflow checking
84415         * lib/intprops.h (_GL_INT_CONVERT, _GL_INT_TWOS_COMPLEMENT):
84416         (_GL_INT_SIGNED, _GL_INT_MINIMUM, _GL_INT_MAXIMUM):
84417         (_GL_SIGNED_INT_MINIMUM, INT_ADD_RANGE_OVERFLOW):
84418         (INT__SUBTRACT__RANGE_OVERFLOW, INT_NEGATE_RANGE_OVERFLOW):
84419         (INT_MULTIPLY_RANGE_OVERFLOW, INT_REMAINDER_RANGE_OVERFLOW):
84420         (INT_LEFT_SHIFT_RANGE_OVERFLOW, _GL_ADD_OVERFLOW):
84421         (_GL__SUBTRACT__OVERFLOW, _GL_MULTIPLY_OVERFLOW, _GL_DIVIDE_OVERFLOW):
84422         (_GL_REMAINDER_OVERFLOW, _GL_UNSIGNED_NEG_MULTIPLE, INT_ADD_OVERFLOW):
84423         (INT__SUBTRACT__OVERFLOW, INT_NEGATE_OVERFLOW, INT_MULTIPLY_OVERFLOW):
84424         (INT_DIVIDE_OVERFLOW, INT_REMAINDER_OVERFLOW):
84425         (INT_LEFT_SHIFT_OVERFLOW, _GL_BINARY_OP_OVERFLOW): New macros.
84427 2011-05-12  James Youngman  <jay@gnu.org>
84429         Add a test for glibc's Bugzilla bug #12378.
84430         * m4/fnmatch.m4: Use gnulib's fnmatch if the system fnmatch
84431         doesn't allow the literal matching of a lone "[" (which is
84432         required by POSIX).
84433         * tests/test-fnmatch.c (main): Check that "[/b" matches itself.
84435 2011-05-11  Ulrich Drepper  <drepper@gmail.com>
84437         Sync glibc change fixing Bugzilla bug #12378.
84438         * lib/fnmatch_loop.c (FCT): When matching '[' keep track of
84439         beginning and fall back to matching as normal character if the
84440         string ends before the matching ']' is found.  This is what POSIX
84441         requires.
84443 2011-05-13  Eric Blake  <eblake@redhat.com>
84445         getcwd-lgpl: relax test for FreeBSD
84446         * doc/posix-functions/getcwd.texi (getcwd): Document portability
84447         issue.
84448         * tests/test-getcwd-lgpl.c (main): Relax test.
84449         Reported by Matthias Bolte.
84451 2011-05-11  Eric Blake  <eblake@redhat.com>
84453         test-fflush: silence compiler warning
84454         * tests/test-fflush.c (main): Don't fclose a NULL pointer.
84456 2011-05-11  Bruno Haible  <bruno@clisp.org>
84458         canonicalize, canonicalize-lgpl: Avoid crash dialog on MacOS X.
84459         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Add GL_NOCRASH code.
84460         * modules/canonicalize (Depends-on): Add 'nocrash'.
84461         * modules/canonicalize-lgpl (Depends-on): Likewise.
84462         * doc/posix-functions/realpath.texi: Update platforms list.
84463         Reported by Ryan Schmidt <ryandesign@macports.org>.
84465 2011-05-11  Bruno Haible  <bruno@clisp.org>
84467         group-member: Declare function in <unistd.h>.
84468         * lib/unistd.in.h (group_member): New declaration.
84469         * lib/group-member.h: Remove file.
84470         * lib/group-member.c: Include <unistd.h> instead of group-member.h.
84471         * tests/test-unistd-c++.cc: Check signature of group_member.
84472         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Require
84473         gl_UNISTD_H_DEFAULTS. Set HAVE_GROUP_MEMBER.
84474         * m4/unistd_h.m4 (gl_UNISTD_H): Check whether group_member is declared.
84475         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GROUP_MEMBER,
84476         HAVE_GROUP_MEMBER.
84477         * modules/group-member (Files): Remove lib/group-member.h.
84478         (Depends-on): Add unistd. Specify conditions.
84479         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
84480         (Include): Change to <unistd.h>.
84481         * modules/unistd (Makefile.am): Substitute GNULIB_GROUP_MEMBER,
84482         HAVE_GROUP_MEMBER.
84483         * NEWS: Mention the change.
84484         * lib/euidaccess.c: Don't include group-member.h.
84486 2011-05-11  Bruno Haible  <bruno@clisp.org>
84488         group-member: Document module.
84489         * doc/glibc-functions/group_member.texi: Mention the 'group-member'
84490         module.
84492 2011-05-11  Bruno Haible  <bruno@clisp.org>
84494         fclose: Fix mistake earlier today.
84495         * lib/fclose.c (rpl_fclose): Don't assume that EOF < 0.
84497 2011-05-11  Eric Blake  <eblake@redhat.com>
84499         fclose: preserve fflush errors
84500         * lib/fclose.c (rpl_fclose): Don't lose fflush errors.
84501         Reported by Jim Meyering.
84503         bootstrap: support a prereq of 'rpcgen -' on RHEL5
84504         * build-aux/bootstrap (check_versions): When no specific version
84505         is required, merely check that the app produces an exit status
84506         that indicates its existence.
84508         maint.mk: drop redundant check
84509         * top/maint.mk (sc_the_the): Delete; sc_prohibit_doubled_word does
84510         the same but better.
84512 2011-05-11  Bruno Haible  <bruno@clisp.org>
84514         fclose: Fix possible link error.
84515         * lib/fclose.c (rpl_fclose): Invoke _gl_unregister_fd, not
84516         unregister_shadow_fd. Improve comments.
84517         * lib/sockets.c (close_fd_maybe_socket): Add comments. Reported by
84518         Eric Blake.
84520 2011-05-11  Jim Meyering  <meyering@redhat.com>
84522         maint.mk: improve "can not" detection and generalize rule name
84523         * top/maint.mk (sc_prohibit_undesirable_word_seq): Renamed from
84524         sc_prohibit_can_not, since we'll probably add a few more word pairs here.
84525         Use the same technique as in sc_prohibit_doubled_word, so that
84526         we recognize "can not" also when the words are separated by a newline.
84527         Suggested by Eric Blake.
84528         (perl_filename_lineno_text_): Define.  Factored out of...
84529         (prohibit_doubled_word_): ...here.  Use the new definition.
84530         (prohibit_undesirable_word_seq_): New var.  Use it here, too.
84531         (prohibit_undesirable_word_seq_RE_): New overridable variable.
84532         (ignore_undesirable_word_sequence_RE_): New overridable variable.
84534 2011-05-10  Eric Blake  <eblake@redhat.com>
84536         fclose: avoid double close race when possible
84537         * lib/fclose.c (rpl_fclose): Rewrite to avoid double-close race on
84538         all but WINDOWS_SOCKETS.
84540 2011-05-10  Bastien Roucariès  <roucaries.bastien@gmail.com>
84542         openat: correct new comment
84543         * lib/openat-proc.c (openat_proc_name): Correct the comment.
84545 2011-05-10  Jim Meyering  <meyering@redhat.com>
84547         openat: add comments
84548         * lib/openat-proc.c (openat_proc_name): Add comments,
84549         mostly from Eric Blake.
84551 2011-05-09  Eric Blake  <eblake@redhat.com>
84553         openat: reduce syscalls in first probe of /proc
84554         * lib/openat-proc.c (openat_proc_name): Require that /proc/self/fd
84555         be a directory.  Simplify the probe for .. bugs.
84556         * modules/openat (Depends-on): Drop same-inode.
84557         Reported by Bastien ROUCARIES.
84559 2011-05-09  Jim Meyering  <meyering@redhat.com>
84561         maint.mk: change semantics/name of tight_scope variables
84562         * top/maint.mk (_gl_TS_var_match, _gl_TS_function_match):
84563         Rename variables to align with semantics that make them more useful.
84565         maint.mk: tweak new rule's name not to impinge
84566         * top/maint.mk (_gl_tight_scope): Rename from sc_tight_scope-0.
84567         (sc_tight_scope): Use new rule name rather than $@-0.
84569         maint.mk: add a syntax-check rule to ensure tightly-scoped symbols
84570         * top/maint.mk (sc_tight_scope): New rule.
84571         (sc_tight_scope-0): New rule, ifdef'd out.
84572         (_gl_TS_dir): Default.
84573         (_gl_TS_unmarked_extern_functions, _gl_TS_function_regex): Define.
84574         (_gl_TS_unmarked_extern_vars, _gl_TS_var_regex): Define.
84576 2011-05-09  Simon Josefsson  <simon@josefsson.org>
84578         * m4/gc.m4: Remove gl_PREREQ_GC (not used).  Reported by Bruno
84579         Haible <bruno@clisp.org>.
84581 2011-05-08  Bruno Haible  <bruno@clisp.org>
84583         Comments.
84584         * m4/isnanf.m4: Add comment.
84585         * m4/isnanl.m4: Likewise.
84587 2011-05-08  Bruno Haible  <bruno@clisp.org>
84589         glob: Remove obsolete macro.
84590         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): Remove macro.
84592 2011-05-08  Paul Eggert  <eggert@cs.ucla.edu>
84594         intprops: Sun C 5.11 supports __typeof__
84595         * lib/intprops.h (_GL_HAVE___TYPEOF__): New macro, which is set
84596         for either GCC 2 or later, as before, or for Sun C 5.11 or later,
84597         which is new.
84598         (_GL_SIGNED_TYPE_OR_EXPR): Use it.
84600         intprops: switch to usual gnulib indenting and naming
84601         * lib/intprops.h (_GL_INTPROPS_H): Rename from GL_INTPROPS_H.
84602         (_GL_SIGNED_TYPE_OR_EXPR): Rename from signed_type_or_expr__.
84604         * tests/test-inttostr.c (IS_TIGHT): Adjust to above renaming.
84606 2011-05-08  Jim Meyering  <meyering@redhat.com>
84608         maint.mk: suppress "Entering/Leaving directory" diag in announcement
84609         * top/maint.mk (release-prep): Use make's --no-print-directory
84610         option when generating the announcement.  This eliminates the
84611         pesky "make[2]: Entering/Leaving directory" diagnostics in the
84612         generated announcement template.
84614 2011-05-08  Bruno Haible  <bruno@clisp.org>
84616         tzset: Fix gettimeofday wrapper on Solaris 2.6.
84617         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): When invoking
84618         gl_GETTIMEOFDAY_REPLACE_LOCALTIME, also set REPLACE_GETTIMEOFDAY.
84620 2011-05-07  Paul Eggert  <eggert@cs.ucla.edu>
84622         ignore-value, verify: Omit include files from lib_SOURCES.
84623         * modules/ignore-value, modules/verify (Makefile.am):
84624         Don't put ignore-value.h, or verify.h, into lib_SOURCES, as
84625         that leads Automake to duplicate use of am__objects_... variables
84626         in Makefile.in.  See
84627         <http://lists.gnu.org/r/emacs-devel/2011-05/msg00257.html>.
84629 2011-05-07  Bruno Haible  <bruno@clisp.org>
84631         fclose: Simplify autoconf macro.
84632         * m4/fclose.m4 (gl_FUNC_FCLOSE): Assume gl_FUNC_FFLUSH_STDIN is
84633         defined.
84635 2011-05-07  Bruno Haible  <bruno@clisp.org>
84637         canonicalize-lgpl: Fix autoconf macro ordering bug.
84638         * m4/canonicalize.m4 (gl_CANONICALIZE_LGPL): Require
84639         gl_STDLIB_H_DEFAULTS.
84641 2011-05-06  Eric Blake  <eblake@redhat.com>
84643         maintainer-makefile: make sc_po_check easier to tune
84644         * top/maint.mk (sc_po_check): Allow overriding which non-VC files
84645         to probe for strings, such as an alternate location for gnulib.
84647         fclose: guarantee behavior on seekable stdin
84648         * modules/fclose (Depends-on): Add fflush.
84649         * doc/posix-functions/fclose.texi (fclose): Document this.
84650         * tests/test-fclose.c (main): Make test for this unconditional.
84652 2011-05-06  Bruno Haible  <bruno@clisp.org>
84654         fflush, fpurge: Relicense under LGPLv2+.
84655         * modules/fflush (License): Change from LGPLv3+ to LGPLv2+.
84656         * modules/fpurge (License): Likewise.
84657         With permission from Eric Blake and Jim Meyering.
84658         Suggested by Eric Blake.
84660 2011-05-06  Karl Berry  <karl@gnu.org>
84662         * MODULES.html.sh (func_all_modules): remove exit.
84664 2011-05-06  Jim Meyering  <meyering@redhat.com>
84666         maint.mk: use info-gnu@ as the default only for a stable release
84667         * top/maint.mk: Don't default to info-gnu for alpha or beta releases.
84668         For those, just use $(PACKAGE_BUGREPORT), in which case we don't have
84669         to set the Mail-Followup-To header.  Prompted by Reuben Thomas in
84670         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/26488
84672 2011-05-05  Paul Eggert  <eggert@cs.ucla.edu>
84674         assert-h: new module, which supports C1X-style static_assert
84675         * lib/assert.in.h, m4/assert_h.m4, modules/assert-h: New files.
84676         * lib/verify.h: Revamp so that this can be copied into assert.h,
84677         while retaining the ability to use it standalone as before.
84678         Rename private identifiers so as not to encroach on the
84679         standard C namespace, since this is now used by assert.h.
84680         (_GL_VERIFY_TYPE): New macro, factoring out differing parts of
84681         the old verify_true.
84682         (_GL_VERIFY_TRUE): New macro, with much of the contents of
84683         the old verify_true.  Use _GL_VERIFY_TYPE.
84684         (_GL_VERIFY): New macro, with much of the contents of the old verify.
84685         (static_assert): New macro, if _GL_STATIC_ASSERT_H
84686         is defined and static_assert is not; _GL_STATIC_ASSERT_H is
84687         defined when this file is copied into the replacement assert.h.
84688         (_Static_assert): New macro, if _GL_STATIC_ASSERT_H is defined
84689         and _Static_assert is not built in.
84690         (verify_true, verify): Define only if _GL_STATIC_ASSERT_H is not
84691         defined, and use the new macros mentioned above.
84692         * doc/posix-headers/assert.texi: Document this.
84694 2011-05-05  Bruno Haible  <bruno@clisp.org>
84696         fclose, fflush: Respect rules for use of AC_LIBOBJ.
84697         * m4/fflush.m4 (gl_FUNC_FFLUSH): Don't invoke gl_REPLACE_FCLOSE.
84698         * m4/fclose.m4 (gl_FUNC_FCLOSE): Invoke gl_FUNC_FFLUSH_STDIN and
84699         gl_REPLACE_FCLOSE here.
84700         * modules/fflush (Depends-on): Remove fclose.
84701         * doc/posix-functions/fclose.texi: Mention module 'fflush' only in
84702         combination with module 'fclose'.
84704 2011-05-05  Bruno Haible  <bruno@clisp.org>
84706         fflush, fseeko: Respect rules for use of AC_LIBOBJ.
84707         * m4/fflush.m4 (gl_FUNC_FFLUSH_STDIN): New macro, extracted from
84708         gl_FUNC_FFLUSH.
84709         (gl_FUNC_FFLUSH): Use it.
84710         (gl_REPLACE_FFLUSH): Don't invoke gl_REPLACE_FSEEKO.
84711         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Invoke gl_FUNC_FFLUSH_STDIN and
84712         gl_REPLACE_FSEEKO here.
84714 2011-05-05  Bruno Haible  <bruno@clisp.org>
84716         tzset: Relicense under LGPL.
84717         * modules/tzset (License): Change to LGPL.
84718         No agreement needed; it's a no-op.
84720         strtoimax, strtoumax: Relicense under LGPL.
84721         * modules/strtoimax (License): Change to LGPL.
84722         * modules/strtoumax (License): Likewise.
84723         With permission from Jim Meyering, Paul Eggert:
84724         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00124.html>
84725         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00109.html>
84727         getgroups: Relicense under LGPL.
84728         * modules/getgroups (License): Change to LGPL.
84729         With permission from Jim Meyering, Paul Eggert, Eric Blake:
84730         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00111.html>
84731         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00148.html>
84732         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
84734         nanosleep: Relicense under LGPL.
84735         * modules/nanosleep (License): Change to LGPL.
84736         With permission from Jim Meyering, Paul Eggert, Eric Blake, Bruno
84737         Haible:
84738         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00111.html>
84739         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00148.html>
84740         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
84741         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00131.html>
84743         futimens: Relicense under LGPL.
84744         * modules/futimens (License): Change to LGPL.
84745         With permission from Eric Blake:
84746         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
84748         fflush: Relicense under LGPL.
84749         * modules/fflush (License): Change to LGPL.
84750         With permission from Eric Blake, Bruno Haible, Jim Meyering:
84751         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00138.html>
84752         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00131.html>
84753         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00133.html>
84755         tmpfile: Relicense under LGPL.
84756         * modules/tmpfile (License): Change to LGPL.
84757         With permission from Ben Pfaff:
84758         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00185.html>
84760         isfinite: Relicense under LGPL.
84761         * modules/isfinite (License): Change to LGPL.
84762         With permission from Ben Pfaff, Bruno Haible:
84763         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00185.html>
84764         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00130.html>
84766         acosl..tanl: Relicense under LGPL.
84767         * modules/acosl (License): Change to LGPL.
84768         * modules/asinl (License): Likewise.
84769         * modules/atanl (License): Likewise.
84770         * modules/cosl (License): Likewise.
84771         * modules/expl (License): Likewise.
84772         * modules/logl (License): Likewise.
84773         * modules/sinl (License): Likewise.
84774         * modules/sqrtl (License): Likewise.
84775         * modules/tanl (License): Likewise.
84776         Source code originally from glibc and Paolo Bonzini. Agreements:
84777         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00137.html>
84778         <http://lists.gnu.org/r/bug-gnulib/2011-05/msg00128.html>
84780 2011-05-05  Bruno Haible  <bruno@clisp.org>
84782         signal: Define sighandler_t.
84783         * lib/signal.in.h (sighandler_t): New type.
84784         * m4/signal_h.m4 (gl_SIGNAL_H): Require AC_USE_SYSTEM_EXTENSIONS. Test
84785         whether sighandler_t is defined.
84786         (gl_SIGNAL_H_DEFAULTS): Initialize HAVE_SIGHANDLER_T.
84787         * modules/signal (Depends-on): Add extensions.
84788         (Makefile.am): Substitute HAVE_SIGHANDLER_T.
84789         * doc/posix-headers/signal.texi: Mention the problem with sighandler_t.
84790         Suggested by Markus Steinborn <gnugv_maintainer@yahoo.de>.
84792 2011-05-05  Eric Blake  <eblake@redhat.com>
84794         maint: remove useless REPLACE_*_H macros
84795         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Delete.
84796         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H): Likewise.
84797         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H): Likewise.
84798         * m4/poll_h.m4 (gl_REPLACE_POLL_H): Likewise.
84799         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H): Likewise.
84800         * m4/sys_ioctl_h.m4 (gl_REPLACE_SYS_IOCTL_H): Likewise.
84801         * m4/wchar_h.m4 (gl_REPLACE_WCHAR_H): Likewise.
84802         * m4/btowc.m4: Update callers.
84803         * m4/dirfd.m4: Likewise.
84804         * m4/duplocale.m4: Likewise.
84805         * m4/fchdir.m4: Likewise.
84806         * m4/fdopendir.m4: Likewise.
84807         * m4/inet_ntop.m4: Likewise.
84808         * m4/inet_pton.m4: Likewise.
84809         * m4/ioctl.m4: Likewise.
84810         * m4/mbrlen.m4: Likewise.
84811         * m4/mbrtowc.m4: Likewise.
84812         * m4/mbsinit.m4: Likewise.
84813         * m4/mbsnrtowcs.m4: Likewise.
84814         * m4/mbsrtowcs.m4: Likewise.
84815         * m4/poll.m4: Likewise.
84816         * m4/setlocale.m4: Likewise.
84817         * m4/wcrtomb.m4: Likewise.
84818         * m4/wcsnrtombs.m4: Likewise.
84819         * m4/wcsrtombs.m4: Likewise.
84820         * m4/wctob.m4: Likewise.
84821         * m4/wcwidth.m4: Likewise.
84822         * modules/posix_spawn: Likewise.
84823         * modules/posix_spawn_file_actions_addclose: Likewise.
84824         * modules/posix_spawn_file_actions_adddup2: Likewise.
84825         * modules/posix_spawn_file_actions_addopen: Likewise.
84826         * modules/posix_spawn_file_actions_destroy: Likewise.
84827         * modules/posix_spawn_file_actions_init: Likewise.
84828         * modules/posix_spawnattr_destroy: Likewise.
84829         * modules/posix_spawnattr_getflags: Likewise.
84830         * modules/posix_spawnattr_getpgroup: Likewise.
84831         * modules/posix_spawnattr_getschedparam: Likewise.
84832         * modules/posix_spawnattr_getschedpolicy: Likewise.
84833         * modules/posix_spawnattr_getsigdefault: Likewise.
84834         * modules/posix_spawnattr_getsigmask: Likewise.
84835         * modules/posix_spawnattr_init: Likewise.
84836         * modules/posix_spawnattr_setflags: Likewise.
84837         * modules/posix_spawnattr_setpgroup: Likewise.
84838         * modules/posix_spawnattr_setschedparam: Likewise.
84839         * modules/posix_spawnattr_setschedpolicy: Likewise.
84840         * modules/posix_spawnattr_setsigdefault: Likewise.
84841         * modules/posix_spawnattr_setsigmask: Likewise.
84842         * modules/posix_spawnp: Likewise.
84844 2011-05-04  Reuben Thomas  <rrt@sc3d.org>
84846         Add option to do-release-commit-and-tag to specify branch.
84847         * build-aux/do-release-commit-and-tag: Add --branch.
84849 2011-05-03  Bruno Haible  <bruno@clisp.org>
84851         Avoid unnecessary compilation units, through conditional dependencies.
84852         * modules/accept (Depends-on): Add conditions to the dependencies.
84853         * modules/acosl (Depends-on): Likewise.
84854         * modules/argz (Depends-on): Likewise.
84855         * modules/asinl (Depends-on): Likewise.
84856         * modules/atanl (Depends-on): Likewise.
84857         * modules/atoll (Depends-on): Likewise.
84858         * modules/bind (Depends-on): Likewise.
84859         * modules/btowc (Depends-on): Likewise.
84860         * modules/canonicalize-lgpl (Depends-on): Likewise.
84861         * modules/ceil (Depends-on): Likewise.
84862         * modules/ceilf (Depends-on): Likewise.
84863         * modules/ceill (Depends-on): Likewise.
84864         * modules/chdir-long (Depends-on): Likewise.
84865         * modules/chown (Depends-on): Likewise.
84866         * modules/close (Depends-on): Likewise.
84867         * modules/connect (Depends-on): Likewise.
84868         * modules/cosl (Depends-on): Likewise.
84869         * modules/dirfd (Depends-on): Likewise.
84870         * modules/dprintf (Depends-on): Likewise.
84871         * modules/dprintf-posix (Depends-on): Likewise.
84872         * modules/error (Depends-on): Likewise.
84873         * modules/euidaccess (Depends-on): Likewise.
84874         * modules/expl (Depends-on): Likewise.
84875         * modules/faccessat (Depends-on): Likewise.
84876         * modules/fchdir (Depends-on): Likewise.
84877         * modules/fclose (Depends-on): Likewise.
84878         * modules/fcntl (Depends-on): Likewise.
84879         * modules/fdopendir (Depends-on): Likewise.
84880         * modules/fflush (Depends-on): Likewise.
84881         * modules/floor (Depends-on): Likewise.
84882         * modules/floorf (Depends-on): Likewise.
84883         * modules/floorl (Depends-on): Likewise.
84884         * modules/fnmatch (Depends-on): Likewise.
84885         * modules/fopen (Depends-on): Likewise.
84886         * modules/fprintf-posix (Depends-on): Likewise.
84887         * modules/frexp (Depends-on): Likewise.
84888         * modules/frexp-nolibm (Depends-on): Likewise.
84889         * modules/frexpl (Depends-on): Likewise.
84890         * modules/frexpl-nolibm (Depends-on): Likewise.
84891         * modules/fseek (Depends-on): Likewise.
84892         * modules/fsusage (Depends-on): Likewise.
84893         * modules/ftell (Depends-on): Likewise.
84894         * modules/ftello (Depends-on): Likewise.
84895         * modules/futimens (Depends-on): Likewise.
84896         * modules/getcwd (Depends-on): Likewise.
84897         * modules/getcwd-lgpl (Depends-on): Likewise.
84898         * modules/getdelim (Depends-on): Likewise.
84899         * modules/getdomainname (Depends-on): Likewise.
84900         * modules/getgroups (Depends-on): Likewise.
84901         * modules/gethostname (Depends-on): Likewise.
84902         * modules/getline (Depends-on): Likewise.
84903         * modules/getlogin_r (Depends-on): Likewise.
84904         * modules/getopt-posix (Depends-on): Likewise.
84905         * modules/getpeername (Depends-on): Likewise.
84906         * modules/getsockname (Depends-on): Likewise.
84907         * modules/getsockopt (Depends-on): Likewise.
84908         * modules/getsubopt (Depends-on): Likewise.
84909         * modules/getusershell (Depends-on): Likewise.
84910         * modules/glob (Depends-on): Likewise.
84911         * modules/grantpt (Depends-on): Likewise.
84912         * modules/iconv_open (Depends-on): Likewise.
84913         * modules/iconv_open-utf (Depends-on): Likewise.
84914         * modules/inet_ntop (Depends-on): Likewise.
84915         * modules/inet_pton (Depends-on): Likewise.
84916         * modules/ioctl (Depends-on): Likewise.
84917         * modules/isapipe (Depends-on): Likewise.
84918         * modules/isfinite (Depends-on): Likewise.
84919         * modules/isinf (Depends-on): Likewise.
84920         * modules/lchown (Depends-on): Likewise.
84921         * modules/ldexpl (Depends-on): Likewise.
84922         * modules/link (Depends-on): Likewise.
84923         * modules/linkat (Depends-on): Likewise.
84924         * modules/listen (Depends-on): Likewise.
84925         * modules/logl (Depends-on): Likewise.
84926         * modules/lstat (Depends-on): Likewise.
84927         * modules/mbrlen (Depends-on): Likewise.
84928         * modules/mbrtowc (Depends-on): Likewise.
84929         * modules/mbsinit (Depends-on): Likewise.
84930         * modules/mbsnrtowcs (Depends-on): Likewise.
84931         * modules/mbsrtowcs (Depends-on): Likewise.
84932         * modules/mbtowc (Depends-on): Likewise.
84933         * modules/memcmp (Depends-on): Likewise.
84934         * modules/mkdir (Depends-on): Likewise.
84935         * modules/mkdtemp (Depends-on): Likewise.
84936         * modules/mkfifo (Depends-on): Likewise.
84937         * modules/mkfifoat (Depends-on): Likewise.
84938         * modules/mknod (Depends-on): Likewise.
84939         * modules/mkostemp (Depends-on): Likewise.
84940         * modules/mkostemps (Depends-on): Likewise.
84941         * modules/mkstemp (Depends-on): Likewise.
84942         * modules/mkstemps (Depends-on): Likewise.
84943         * modules/mktime (Depends-on): Likewise.
84944         * modules/nanosleep (Depends-on): Likewise.
84945         * modules/open (Depends-on): Likewise.
84946         * modules/openat (Depends-on): Likewise.
84947         * modules/perror (Depends-on): Likewise.
84948         * modules/poll (Depends-on): Likewise.
84949         * modules/popen (Depends-on): Likewise.
84950         * modules/posix_spawn (Depends-on): Likewise.
84951         * modules/posix_spawn_file_actions_addclose (Depends-on): Likewise.
84952         * modules/posix_spawn_file_actions_adddup2 (Depends-on): Likewise.
84953         * modules/posix_spawn_file_actions_addopen (Depends-on): Likewise.
84954         * modules/posix_spawnp (Depends-on): Likewise.
84955         * modules/pread (Depends-on): Likewise.
84956         * modules/printf-posix (Depends-on): Likewise.
84957         * modules/ptsname (Depends-on): Likewise.
84958         * modules/putenv (Depends-on): Likewise.
84959         * modules/pwrite (Depends-on): Likewise.
84960         * modules/readline (Depends-on): Likewise.
84961         * modules/readlink (Depends-on): Likewise.
84962         * modules/readlinkat (Depends-on): Likewise.
84963         * modules/recv (Depends-on): Likewise.
84964         * modules/recvfrom (Depends-on): Likewise.
84965         * modules/regex (Depends-on): Likewise.
84966         * modules/remove (Depends-on): Likewise.
84967         * modules/rename (Depends-on): Likewise.
84968         * modules/renameat (Depends-on): Likewise.
84969         * modules/rmdir (Depends-on): Likewise.
84970         * modules/round (Depends-on): Likewise.
84971         * modules/roundf (Depends-on): Likewise.
84972         * modules/roundl (Depends-on): Likewise.
84973         * modules/rpmatch (Depends-on): Likewise.
84974         * modules/select (Depends-on): Likewise.
84975         * modules/send (Depends-on): Likewise.
84976         * modules/sendto (Depends-on): Likewise.
84977         * modules/setenv (Depends-on): Likewise.
84978         * modules/setlocale (Depends-on): Likewise.
84979         * modules/setsockopt (Depends-on): Likewise.
84980         * modules/shutdown (Depends-on): Likewise.
84981         * modules/sigaction (Depends-on): Likewise.
84982         * modules/signbit (Depends-on): Likewise.
84983         * modules/sigprocmask (Depends-on): Likewise.
84984         * modules/sinl (Depends-on): Likewise.
84985         * modules/sleep (Depends-on): Likewise.
84986         * modules/snprintf (Depends-on): Likewise.
84987         * modules/snprintf-posix (Depends-on): Likewise.
84988         * modules/socket (Depends-on): Likewise.
84989         * modules/sprintf-posix (Depends-on): Likewise.
84990         * modules/sqrtl (Depends-on): Likewise.
84991         * modules/stat (Depends-on): Likewise.
84992         * modules/strchrnul (Depends-on): Likewise.
84993         * modules/strdup-posix (Depends-on): Likewise.
84994         * modules/strerror (Depends-on): Likewise.
84995         * modules/strerror_r-posix (Depends-on): Likewise.
84996         * modules/strndup (Depends-on): Likewise.
84997         * modules/strnlen (Depends-on): Likewise.
84998         * modules/strptime (Depends-on): Likewise.
84999         * modules/strsep (Depends-on): Likewise.
85000         * modules/strsignal (Depends-on): Likewise.
85001         * modules/strstr-simple (Depends-on): Likewise.
85002         * modules/strtod (Depends-on): Likewise.
85003         * modules/strtoimax (Depends-on): Likewise.
85004         * modules/strtok_r (Depends-on): Likewise.
85005         * modules/strtoumax (Depends-on): Likewise.
85006         * modules/symlink (Depends-on): Likewise.
85007         * modules/symlinkat (Depends-on): Likewise.
85008         * modules/tanl (Depends-on): Likewise.
85009         * modules/tcgetsid (Depends-on): Likewise.
85010         * modules/tmpfile (Depends-on): Likewise.
85011         * modules/trunc (Depends-on): Likewise.
85012         * modules/truncf (Depends-on): Likewise.
85013         * modules/truncl (Depends-on): Likewise.
85014         * modules/uname (Depends-on): Likewise.
85015         * modules/unlink (Depends-on): Likewise.
85016         * modules/unlockpt (Depends-on): Likewise.
85017         * modules/unsetenv (Depends-on): Likewise.
85018         * modules/usleep (Depends-on): Likewise.
85019         * modules/utimensat (Depends-on): Likewise.
85020         * modules/vasprintf (Depends-on): Likewise.
85021         * modules/vdprintf (Depends-on): Likewise.
85022         * modules/vdprintf-posix (Depends-on): Likewise.
85023         * modules/vfprintf-posix (Depends-on): Likewise.
85024         * modules/vprintf-posix (Depends-on): Likewise.
85025         * modules/vsnprintf (Depends-on): Likewise.
85026         * modules/vsnprintf-posix (Depends-on): Likewise.
85027         * modules/vsprintf-posix (Depends-on): Likewise.
85028         * modules/wcrtomb (Depends-on): Likewise.
85029         * modules/wcscasecmp (Depends-on): Likewise.
85030         * modules/wcscspn (Depends-on): Likewise.
85031         * modules/wcsdup (Depends-on): Likewise.
85032         * modules/wcsncasecmp (Depends-on): Likewise.
85033         * modules/wcsnrtombs (Depends-on): Likewise.
85034         * modules/wcspbrk (Depends-on): Likewise.
85035         * modules/wcsrtombs (Depends-on): Likewise.
85036         * modules/wcsspn (Depends-on): Likewise.
85037         * modules/wcsstr (Depends-on): Likewise.
85038         * modules/wcstok (Depends-on): Likewise.
85039         * modules/wcswidth (Depends-on): Likewise.
85040         * modules/wctob (Depends-on): Likewise.
85041         * modules/wctomb (Depends-on): Likewise.
85042         * modules/wctype (Depends-on): Likewise.
85043         * modules/wcwidth (Depends-on): Likewise.
85044         * modules/write (Depends-on): Likewise.
85046 2011-05-03  Bruno Haible  <bruno@clisp.org>
85048         Support for conditional dependencies.
85049         * doc/gnulib.texi (Module description): Document the syntax of
85050         conditional dependencies.
85051         * gnulib-tool: New option --conditional-dependencies.
85052         (func_usage): Document it.
85053         (cond_dependencies): New variable.
85054         (func_get_automake_snippet_conditional,
85055         func_get_automake_snippet_unconditional): New functions, extracted from
85056         func_get_automake_snippet.
85057         (func_get_automake_snippet): Use them.
85058         (sed_first_32_chars): New variable.
85059         (func_module_shellfunc_name): New function.
85060         (func_module_shellvar_name): New function.
85061         (func_module_conditional_name): New function.
85062         (func_uncond_add_module, func_conddep_add_module, func_cond_module_p,
85063         func_cond_module_condition): New functions.
85064         (func_modules_transitive_closure): Add support for conditional
85065         dependencies.
85066         (func_emit_lib_Makefile_am): For a conditional module, enclose the
85067         conditional automake snippet in an automake conditional.
85068         (func_emit_autoconf_snippets): Emit shell functions that contain the
85069         code for conditional modules.
85070         (func_import, func_create_testdir): Update specification.
85072 2011-05-03  Eric Blake  <eblake@redhat.com>
85074         test-getaddrinfo: report error information
85075         * tests/test-getaddrinfo.c (simple): Use err outside of dbprintf.
85077 2011-05-03  Jim Meyering  <meyering@redhat.com>
85079         bootstrap: avoid build failure when $GZIP is set
85080         * build-aux/bootstrap (check_versions): Do not treat $GZIP as a
85081         program name.  If defined at all, it is supposed to list gzip options.
85082         Reported by Alan Curry in http://debbugs.gnu.org/8609
85084 2011-05-03  Reuben Thomas  <rrt@sc3d.org>
85086         readme-release: new module with release instructions
85087         * modules/readme-release: New module.
85088         * top/README-release: New file, from coreutils, grep, diffutils.
85089         * MODULES.html.sh (Support for maintaining and releasing): Add it.
85091 2011-05-02  Eric Blake  <eblake@redhat.com>
85093         fflush: also replace fclose when fixing fflush
85094         * modules/fflush (Depends-on): Add fclose.
85095         * m4/fflush.m4 (gl_FUNC_FFLUSH): Also replace fclose.
85096         * lib/fclose.c (rpl_fclose): Don't cause spurious failures on
85097         memstreams with no backing fd.
85098         * doc/posix-functions/fclose.texi (fclose): Document the use of
85099         fflush module to fix the bug.
85100         * tests/test-fclose.c (main): Relax test when fclose is used in
85101         isolation.
85103         fclose: add some tests
85104         * modules/fclose-tests: New test module.
85105         * tests/test-fclose.c: New file.
85106         * doc/posix-functions/fclose.texi (fclose): Document the bug.
85108         fclose: reduced dependencies
85109         * modules/fclose (Depends-on): Switch from fflush/fseeko to
85110         simpler lseek.
85111         * lib/fclose.c (rpl_fclose): Likewise.
85112         Reported by Simon Josefsson.
85114         exit: drop remaining clients
85115         * modules/argmatch (Depends-on): Replace exit with stdlib.
85116         * modules/copy-file (Depends-on): Likewise.
85117         * modules/execute (Depends-on): Likewise.
85118         * modules/exitfail (Depends-on): Likewise.
85119         * modules/obstack (Depends-on): Likewise.
85120         * modules/pagealign_alloc (Depends-on): Likewise.
85121         * modules/pipe-filter-gi (Depends-on): Likewise.
85122         * modules/pipe-filter-ii (Depends-on): Likewise.
85123         * modules/savewd (Depends-on): Likewise.
85124         * modules/spawn-pipe (Depends-on): Likewise.
85125         * modules/wait-process (Depends-on): Likewise.
85126         * modules/xsetenv (Depends-on): Likewise.
85127         * modules/chdir-long (Depends-on): Add stdlib, for EXIT_FAILURE.
85128         * modules/git-merge-changelog (Depends-on): Likewise.
85129         * modules/long-options (Depends-on): Likewise.
85130         * modules/pt_chown (Depends-on): Likewise.
85131         * modules/sysexits (Depends-on): Likewise.
85133         freading: relax license from LGPLv3+ to LGPLv2+
85134         * modules/freading (License): Relax LGPL version.
85136 2011-05-02  Bruno Haible  <bruno@clisp.org>
85138         fchdir: Remove unused dependencies.
85139         * modules/fchdir (Depends-on): Remove include_next.
85141 2011-05-02  Bruno Haible  <bruno@clisp.org>
85143         gnulib-tool: Refactor.
85144         * gnulib-tool (func_emit_autoconf_snippet): New function, extracted
85145         from func_emit_autoconf_snippets.
85146         (func_emit_autoconf_snippets): Use it.
85148 2011-05-02  Simon Josefsson  <simon@josefsson.org>
85150         * NEWS: Document removal of 'exit'.
85151         * modules/exit: Remove file.
85153 2011-05-01  Bruno Haible  <bruno@clisp.org>
85155         Update DEPENDENCIES.
85156         * DEPENDENCIES (gettext): Recommend the newest release.
85157         Reported by Simon Josefsson.
85159 2011-05-01  Bruno Haible  <bruno@clisp.org>
85161         gnulib-tool: Reduce code duplication.
85162         * gnulib-tool (func_emit_autoconf_snippets): New function.
85163         (func_import, func_create_testdir): Use it.
85165 2011-04-30  Eric Blake  <eblake@redhat.com>
85167         fclose: don't fail on non-seekable input stream
85168         * modules/fclose (Depends-on): Add freading, fflush, fseeko.
85169         * lib/fclose.c (rpl_fclose): Skip fflush for non-seekable input,
85170         since fflush is allowed to fail in that case.
85172 2011-04-30  Bruno Haible  <bruno@clisp.org>
85174         dup3: cleanup
85175         * lib/dup3.c: Remove old code, leftover from 2009-12-16.
85177 2011-04-30  Bruno Haible  <bruno@clisp.org>
85179         netdb: Make it work in C++ mode.
85180         * lib/netdb.in.h (struct addrinfo): In C++, define as a C struct.
85181         (getaddrinfo, freeaddrinfo, getnameinfo): Use macros from c++defs
85182         module.
85183         * m4/netdb_h.m4 (gl_NETDB_MODULE_INDICATOR): Invoke
85184         gl_MODULE_INDICATOR_FOR_TESTS.
85185         * modules/netdb-tests (Depends-on): Add netdb-c++-tests.
85186         * modules/netdb-c++-tests: New file.
85187         * tests/test-netdb-c++.cc: New file.
85189 2011-04-30  Bruno Haible  <bruno@clisp.org>
85191         New modules 'vfscanf', 'vscanf'.
85192         * modules/vfscanf: New file.
85193         * modules/vscanf: New file.
85194         * m4/stdio_h.m4 (gl_STDIO_H): Don't set GNULIB_VFSCANF, GNULIB_VSCANF
85195         here.
85196         * doc/posix-functions/vfscanf.texi: Mention module 'vfscanf'.
85197         * doc/posix-functions/vscanf.texi: Mention module 'vscanf'.
85199 2011-04-30  Bruno Haible  <bruno@clisp.org>
85201         passfd: Add comments.
85202         * lib/passfd.c: Add comments about platforms.
85204 2011-04-30  Bruno Haible  <bruno@clisp.org>
85206         sys_uio: Make <sys/uio.h> self-contained.
85207         * lib/sys_uio.in.h: Include <sys/types.h> before <sys/uio.h>.
85208         * doc/posix-headers/sys_uio.texi: Mention the OpenBSD problem.
85210 2011-04-30  Bruno Haible  <bruno@clisp.org>
85212         sys_socket: Ensure 'struct iovec' definition.
85213         * lib/sys_socket.in.h: Include <sys/uio.h> also on platforms that have
85214         <sys/socket.h>.
85215         * doc/posix-headers/sys_socket.texi: Mention the OpenBSD problem.
85217 2011-04-30  Bruno Haible  <bruno@clisp.org>
85219         sys_uio: Protect definition of 'struct iovec'.
85220         * lib/sys_uio.in.h (struct iovec): Avoid redefinition. In C++, define
85221         it as a C struct.
85223 2011-04-30  Bruno Haible  <bruno@clisp.org>
85225         manywarnings: fix indentation
85226         * m4/manywarnings.m4: Indent by 2 spaces consistently.
85228 2011-04-30  Pádraig Brady  <P@draigBrady.com>
85230         manywarnings: add -Wno-missing-field-initializers if needed.
85231         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add the above
85232         option if it's needed to allow initialization with { 0, }
85234 2011-04-29  Reuben Thomas  <rrt@sc3d.org>
85236         announce-gen: cosmetic improvement
85237         * build-aux/announce-gen: Strip any leading ./ from the NEWS file name.
85239 2011-04-29  Jim Meyering  <meyering@redhat.com>
85241         vc-list-files: indent with spaces, not TABs
85242         * build-aux/vc-list-files: Convert leading TABs to spaces,
85243         to match the style of most other files in gnulib.
85245         announce-gen: indent with spaces, not TABs
85246         * build-aux/announce-gen: Convert all TABs to spaces, to match
85247         the style of most other files in gnulib.
85249 2011-04-29  Eric Blake  <eblake@redhat.com>
85251         quotearg: avoid uninitialized variable use
85252         * lib/quotearg.c (quoting_options_from_style): Initialize
85253         remaining fields, and ensure that custom styles are only used via
85254         quoting_options rather than quoting_style.
85256 2011-04-29  Jim Meyering  <meyering@redhat.com>
85258         maint.mk: remove unused VC-tag variable
85259         * top/maint.mk (VC-tag): Remove unused variable.
85261 2011-04-29  Bruno Haible  <bruno@clisp.org>
85263         netdb: fix gai_strerror replacements
85264         * lib/netdb.in.h: Add _GL_FUNCDECL_RPL definitions.
85265         * modules/netdb: Substitute it.
85267 2011-04-29  Jim Meyering  <meyering@redhat.com>
85269         test-getcwd.c: avoid new set-but-not-used warning
85270         * tests/test-getcwd.c (test_abort_bug): Exit nonzero for any problem,
85271         not just the glibc/abort one that getcwd-abort-bug.m4 detects.
85272         * m4/getcwd-abort-bug.m4: Update this now-duplicated code to match,
85273         and adjust the code that sets gl_cv_func_getcwd_abort_bug accordingly.
85275         test-hash.c: avoid a new shadowing warning
85276         * tests/test-hash.c (main): Don't shadow "dup".
85278 2011-04-28  Eric Blake  <eblake@redhat.com>
85280         getaddrinfo: fix gai_strerror signature
85281         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Detect broken signatures,
85282         and work around mingw with UNICODE defined.
85283         (gl_PREREQ_GETADDRINFO): Drop redundant decl check.
85284         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Add witness.
85285         * modules/netdb (Makefile.am): Substitute it.
85286         * lib/netdb.in.h (gai_strerror): Declare replacement.
85287         * lib/gai_strerror.c (rpl_gai_strerror): Fix signature.
85288         * doc/posix-functions/gai_strerror.texi (gai_strerror): Document
85289         the fix.
85291         getsockopt: avoid compiler warning
85292         * lib/getsockopt.c (rpl_getsockopt): Add a cast for mingw.
85293         Reported by Matthias Bolte.
85295         tests: drop unused link dependency
85296         * modules/areadlinkat-tests (Makefile.am): Drop stale LDADD.
85297         * modules/dirent-safer-tests (Makefile.am): Likewise.
85298         * modules/fdopendir-tests (Makefile.am): Likewise.
85299         * modules/mkfifoat-tests (Makefile.am): Likewise.
85300         * modules/openat-safer-tests (Makefile.am): Likewise.
85301         * modules/openat-tests (Makefile.am): Likewise.
85302         * modules/readlinkat-tests (Makefile.am): Likewise.
85303         * modules/symlinkat-tests (Makefile.am): Likewise.
85304         * modules/linkat-tests (Makefile.am): Likewise.
85305         (Depends-on): Switch to filenamecat-lgpl.
85306         * modules/fdutimensat-tests (test_fdutimensat_LDADD): Drop unused
85307         LIBINTL.
85308         * modules/utimensat-tests (test_utimensat_LDADD): Likewise.
85309         * tests/test-linkat.c (main): Don't require xalloc.
85311         hash, mgetgroups: drop xalloc dependency
85312         * lib/hash.c (includes): Adjust includes.
85313         * lib/mgetgroups.c (includes): Likewise.
85314         (xgetgroups): Move...
85315         * lib/xgetgroups.c: ...to new file.
85316         * lib/mgetgroups.h (xgetgroups): Make declaration conditional.
85317         * modules/xgetgroups: New file, split from...
85318         * modules/mgetgroups: ...here.
85319         (Depends-on): Add xalloc-oversized.
85320         * modules/hash (Depends-on): Likewise.
85321         * modules/hash-tests (Depends-on): Drop xalloc.
85322         (test_hash_LDADD): Drop unused library.
85323         * tests/test-hash.c (main): Break xalloc dependency.
85324         (includes): Drop unused include.
85326         xalloc-oversized: new module
85327         * modules/xalloc-oversized: New module.
85328         * modules/xalloc (Depends-on): Add it.
85329         * lib/xalloc.h (xalloc_oversized): Move...
85330         * lib/xalloc-oversized.h: ...into new file.
85332         utimecmp: drop dependency on xmalloc
85333         * lib/utimecmp.c (utimecmp): Work even if hash table cache fails
85334         due to memory pressure.
85335         * modules/utimecmp (Depends-on): Drop xalloc.
85337 2011-04-27  Eric Blake  <eblake@redhat.com>
85339         getcwd: fix mingw bugs
85340         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Detect one mingw bug.
85341         * doc/posix-functions/getcwd.texi (getcwd): Document the problems.
85342         * lib/getcwd-lgpl.c (rpl_getcwd): Fix return type.
85344 2011-04-27  Bruno Haible  <bruno@clisp.org>
85346         mkstemps: Ensure declaration on MacOS X 10.5.
85347         * lib/stdlib.in.h: Include <unistd.h> when mkstemps is requested.
85348         * doc/glibc-functions/mkstemps.texi: Document header file problem on
85349         MacOS X.
85351 2011-04-27  Bruno Haible  <bruno@clisp.org>
85353         mkstemp: More documentation.
85354         * doc/posix-functions/mkstemp.texi: Document header file problem on
85355         MacOS X.
85357 2011-04-27  Bruno Haible  <bruno@clisp.org>
85359         mkstemp: Tweak configure message when cross-compiling.
85360         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): When cross-compiling, qualify the
85361         result as a guess.
85363 2011-04-27  Bruno Haible  <bruno@clisp.org>
85365         clean-temp: Clarify what it does.
85366         * lib/clean-temp.h: Add more comments.
85367         * doc/posix-functions/mkstemp.texi: Tweak reference to 'clean-temp'
85368         module.
85369         * doc/glibc-functions/mkostemp.texi: Mention 'clean-temp' here too.
85370         * doc/glibc-functions/mkstemps.texi: Likewise.
85371         * doc/glibc-functions/mkostemps.texi: Likewise.
85373 2011-04-27  Eric Blake  <eblake@redhat.com>
85375         fchdir: avoid extra chdir and fix test
85376         * modules/fchdir (Depends-on): Add dosname, filenamecat-lgpl,
85377         getcwd-lgpl.
85378         * lib/fchdir.c (get_name): Any absolute name will do; it does not
85379         have to be canonical.
85380         (canonicalize_file_name): Drop unused macro.
85381         * m4/dup2.m4 (gl_REPLACE_DUP2): Ensure dup2 is replaced.
85383         filenamecat-lgpl: fix licence
85384         * modules/filenamecat-lgpl (License): Mark as LGPLv2+, as intended
85385         when it was first created.
85387         linkat, renameat: add missing dependency
85388         * modules/linkat (Depends-on): Require getcwd-lgpl.
85389         * modules/renameat (Depends-on): Likewise.
85391         tests: reduce dependencies
85392         * tests/test-linkat.c (main): Use lighter-weight getcwd.
85393         * tests/test-renameat.c (main): Likewise.
85394         * modules/linkat-tests (Depends-on): Relax dependency.
85395         * modules/renameat-tests (Depends-on): Likewise.
85396         * modules/fchdir-tests (Depends-on): Likewise.  Also make cloexec
85397         dependency explicit.
85399         save-cwd: reduce default dependency
85400         * modules/save-cwd (Depends-on): Use getcwd-lgpl.
85401         * lib/save-cwd.c: Update comments.
85402         * NEWS: Document the semantic change.
85404         getcwd: enhance tests
85405         * tests/test-getcwd-lgpl.c: New file, taken from...
85406         * tests/test-getcwd.c: ...old contents.  Rewrite this file to
85407         repeat long path stress tests from m4 probe.
85408         * modules/getcwd-lgpl-tests: New module.
85409         * modules/getcwd-tests (Depends-on): Depend on lgpl tests.
85410         * m4/getcwd-abort-bug.m4: Update comment.
85411         * m4/getcwd-path-max.m4: Likewise.
85413         getcwd-lgpl: new module
85414         * modules/getcwd-lgpl: New module.
85415         * lib/getcwd-lgpl.c: New file.
85416         * doc/posix-functions/getcwd.texi (getcwd): Document it.
85417         * MODULES.html.sh (lacking POSIX:2008): Likewise.
85418         * modules/getcwd (configure.ac): Set C witness.
85419         * m4/getcwd.m4 (gl_FUNC_GETCWD_LGPL): New macro.
85421         getcwd: tweak comments
85422         * m4/getcwd-abort-bug.m4: Fix comments.
85423         * m4/getcwd-path-max.m4: Likewise.
85424         * m4/getcwd.m4: Likewise.
85426 2011-04-27  Reuben Thomas  <rrt@sc3d.org>
85427         and Eric Blake  <eblake@redhat.com>
85429         mkstemp: replace if system version uses wrong permissions
85430         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Add test for non-owner
85431         read/write mode bits set in file created by mkstemp.
85432         * doc/posix-functions/mkstemp.texi (mkstemp): Document the fix.
85434 2011-04-27  Eric Blake  <eblake@redhat.com>
85436         passfd: avoid compiler warning
85437         * lib/passfd.c (sendfd, recvfd): Avoid shadowing names.
85438         Reported by Laine Stump.
85440 2011-04-27  J.T. Conklin  <jtc@acorntoolworks.com>  (tiny change)
85442         * gnulib-tool: change "join -a 2" to "join -a2", the latter is
85443         required by the NetBSD (and perhaps other 4.4BSD derived) join.
85445 2011-04-27  Reuben Thomas  <rrt@sc3d.org>
85446         and Eric Blake  <eblake@redhat.com>
85448         mkstemp: mention clean-temp module
85449         * lib/mkstemp.c: Add comment.
85450         * doc/posix-functions/mkstemp.texi (mkstemp): Likewise.
85452 2011-04-26  Paul Eggert  <eggert@cs.ucla.edu>
85454         inttypes: also provide default values for 32-bit tests
85455         * m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Also provide default values
85456         for INT32_MAX_LT_INTMAX_MAX and for UINT32_MAX_LT_UINTMAX_MAX.
85458 2011-04-25  Paul Eggert  <eggert@cs.ucla.edu>
85460         strtoumax: remove dependency on strtoimax
85461         This is like the strtoull change of yesterday.
85462         * modules/strtoumax (Files): Add lib/strtoimax.c.
85463         (Depends-on): Remove strtoimax and add verify.
85465         inttypes-incomplete: new module
85466         * m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): New macro, containing
85467         all but the PRI* and SCN* parts of gl_INTTYPES_H.
85468         (gl_INTTYPES_PRI_SCN): New macro, containing the PRI* and SCN* parts
85469         of gl_INTTYPES_H.
85470         (gl_INTTYPES_H): Rewrite in terms of these new macros.
85471         (gl_INTTYPES_H_DEFAULTS): Provide defaults for the PRI* and SCN*
85472         parts, in case gl_INTTYPE_PRI_SCN is not invoked.
85473         * modules/imaxabs, modules/imaxdiv, modules/strtoimax (Depends-on):
85474         * modules/strtoumax, modules/xstrtol (Depends-on):
85475         Depend on inttypes-incomplete, not inttypes.
85476         * modules/inttypes-incomplete: New module, containing the contents
85477         of the old modules/inttypes module, except that the Files: section
85478         omits m4/inttypes-pri.m4, and the configure.ac section invokes
85479         gl_INTTYPES_INCOMPLETE rather than gl_INTTYPES_H.
85480         * modules/inttypes (Files): Remove lib/inttypes.in.h, m4/inttypes.m4.
85481         (Depends-on): Depend only on inttypes-incomplete.
85482         (Makefile.am): Remove everything; this is now in inttypes-incomplete.
85484         inttypes: omit now-redundant strtoimax and strtoumax work
85485         * m4/inttypes.m4 (gl_INTTYPES_H): Do not check for strtoimax and
85486         strtoumax decls; gl_FUNC_STRTOIMAX and gl_FUNC_STRTOUMAX now do this.
85488         strtoimax, strtoumax: simplify, port to HP-UX 11.00 64-bit
85489         This supports apps that need pointers to strtoimax and strtoumax,
85490         and ports to HP-UX 11.00 64.bit, which has macros that expand to
85491         nonexistent functions.  See
85492         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00241.html>
85493         et seq.
85494         * lib/inttypes.in.h (strtoimax, strtoumax): #undef before declaring.
85495         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Don't check whether it's
85496         a macro.
85497         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
85499 2011-04-25  Simon Josefsson  <simon@josefsson.org>
85501         * modules/gnumakefile (configure.ac): Replace TAB with SPCs.
85503 2011-04-25  Bruno Haible  <bruno@clisp.org>
85505         strtol, strtoul: Mark modules as obsolete.
85506         * modules/strtol (Status, Notice): New sections.
85507         * modules/strtoul (Status, Notice): New sections.
85509 2011-04-25  Bruno Haible  <bruno@clisp.org>
85511         strtod: Remove check for strtod, unless supporting old platforms.
85512         * modules/strtod-obsolete: New file.
85513         * m4/strtod-obsolete.m4: New file.
85514         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't check whether strtod is declared
85515         if gl_FUNC_STRTOD_OBSOLETE is not also defined.
85516         * modules/strtod (Depends-on): Add strtod-obsolete.
85517         * doc/posix-functions/strtod.texi: Mention module strtod-obsolete.
85519 2011-04-25  Bruno Haible  <bruno@clisp.org>
85521         strcase: Make module obsolete.
85522         * modules/strcase (Status, Notice): New sections.
85524 2011-04-25  Bruno Haible  <bruno@clisp.org>
85526         dup2: Remove check for dup2, unless supporting old obsolete platforms.
85527         * modules/dup2-obsolete: New file.
85528         * m4/dup2-obsolete.m4: New file.
85529         * m4/dup2.m4 (gl_FUNC_DUP2): Don't check whether dup2 exists if
85530         gl_FUNC_DUP2_OBSOLETE is not also defined.
85531         * modules/dup2 (Depends-on): Add dup2-obsolete.
85532         * doc/posix-functions/dup2.texi: Mention module dup2-obsolete.
85534 2011-04-25  Bruno Haible  <bruno@clisp.org>
85536         strnlen: Avoid memchr related link error on old obsolete platforms.
85537         * modules/memchr-obsolete: New file.
85538         * m4/memchr-obsolete.m4: New file.
85539         * m4/memchr.m4 (gl_FUNC_MEMCHR): Don't check whether memchr exists if
85540         gl_FUNC_MEMCHR_OBSOLETE is not also defined.
85541         * modules/memchr (Depends-on): Add memchr-obsolete.
85542         * modules/strnlen (Depends-on): Likewise.
85543         * doc/posix-functions/memchr.texi: Mention module memchr-obsolete.
85545 2011-04-25  Jim Meyering  <meyering@redhat.com>
85547         maint.mk: makefile_at_at_check extend and clean up
85548         * top/maint.mk (sc_makefile_at_at_check): Check *.mk files
85549         in addition to */Makefile.am.
85550         Exempt legitimate uses of @VAR@ notation, e.g.,
85551         MAKEINFO = env LANG= LC_MESSAGES= LC_ALL= LANGUAGE= @MAKEINFO@
85552         Remove obsolete coreutils-specific comment.
85553         Prompted by discussion here:
85554         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/26074
85556 2011-04-24  Paul Eggert  <eggert@cs.ucla.edu>
85558         strtoul: remove dependency on strtol
85559         This is so that 'configure' need not check for strtol merely because
85560         the application needs strtoul.
85561         * modules/strtoul (Files): Add lib/strtol.c.
85562         (Depends-on): Remove strtol.
85564         strtoull: remove dependency on strtoul
85565         This is like the strtoll change.
85566         * modules/strtoull (Files): Add lib/strtol.c, lib/strtoul.c.
85567         (Depends-on): Remove strtoul.
85569         strtoll: remove dependency on strtol
85570         This is so that 'configure' need not check for strtol merely because
85571         the application needs strtoll.
85572         * modules/strtoll (Files): Add lib/strtol.c.
85573         (Depends-on): Remove strtol.
85575 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
85577         inttypes: Move some configure check to module 'imaxdiv'.
85578         * m4/imaxdiv.m4 (gl_FUNC_IMAXDIV): Require gl_INTTYPES_H_DEFAULTS
85579         instead of gl_INTTYPES_H.  Check for imaxdiv decl here.
85580         * m4/inttypes.m4 (gl_INTTYPES_H): Don't check for imaxdiv decl here.
85582 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
85584         inttypes: Move some configure check to module 'imaxabs'.
85585         * m4/imaxabs.m4 (gl_FUNC_IMAXABS): Require gl_INTTYPES_H_DEFAULTS
85586         instead of gl_INTTYPES_H.  Check for imaxabs decl here.
85587         * m4/inttypes.m4 (gl_INTTYPES_H): Don't check for imaxabs decl here.
85589 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
85591         inttypes: Remove configure tests that are not needed since 2009-12-31.
85592         * m4/inttypes.m4 (gl_INTTYPES_H): Remove determination of
85593         gl_cv_header_working_inttypes_h.
85595 2011-04-22  Paul Eggert  <eggert@cs.ucla.edu>
85597         * modules/strnlen (Depends-on): Remove memchr.
85598         The strnlen implementation doesn't need the memchr module's fixes; see
85599         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00237.html>.
85601         strtol: remove dependency on wchar
85602         * lib/strtol.c: Include <wchar.h> only if USE_WIDE_CHAR is defined.
85603         * modules/strtol (Depends-on): Remove wchar.
85605 2011-04-21  Eric Blake  <eblake@redhat.com>
85607         passfd: fix test regression on Linux
85608         * modules/passfd-tests (configure.ac): Correct socketpair check.
85610         passfd: speed up configure and drop unused code
85611         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Rename...
85612         * m4/passfd.m4 (gl_PASSFD): ...to something more fitting of
85613         its use.  Drop test for setting unused HAVE_UNIXSOCKET_SCM_RIGHTS.
85614         Instead of probing at configure for unix_scm_rights_bsd44_way,
85615         instead probe for CMSG_FIRSTHDR at compile time.  Simplify BSD 4.3
85616         check to a struct member probe.
85617         * lib/passfd.c (includes): Nothing here requires <sys/un.h>.
85618         (sendfd, recvfd): Update preprocessor checks.
85619         * modules/passfd (Files): Reflect rename, and drop unused file.
85620         (Depends-on): Drop unused dependency.
85622         passfd: allow compilation on mingw
85623         * modules/sys_socket (Depends-on): Add sys_uio.
85624         * lib/sys_socket.in.h [!@HAVE_SYS_SOCKET_H@]: Use it for struct
85625         iovec and a minimal struct msghdr.
85626         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Detect recvmsg/sendmsg.
85627         * tests/test-sys_socket.c (main): Enhance test.
85628         * lib/passfd.c (include): Drop <sys/uio.h>; <sys/sockets.h> is
85629         guaranteed to provide what we need.
85630         (sendmsg, recvmsg): Declare fallbacks if we lack sendmsg.
85631         * modules/passfd-tests (Depends-on): Add sys_wait.
85632         * tests/test-passfd.c (main): Skip test on mingw, for now.
85633         * doc/posix-headers/sys_socket.texi (sys/socket.h): Document the
85634         partial 'struct msghdr' implementation.
85636         sys_uio: new module
85637         * modules/sys_uio: New module.
85638         * modules/sys_uio-tests: Likewise.
85639         * lib/sys_uio.in.h: New file.
85640         * m4/sys_uio_h.m4: Likewise.
85641         * tests/test-sys_uio.c: Likewise.
85642         * doc/posix-headers/sys_uio.texi (sys/uio.h): Document it.
85643         * MODULES.html.sh (systems lacking POSIX:2008): Likewise.
85645 2011-04-20  Jim Meyering  <meyering@redhat.com>
85647         useless-if-before-free: avoid false-positive
85648         * build-aux/useless-if-before-free: Adjust regexp for the non-brace
85649         disjunct so that it too requires a terminating ";".  Without that,
85650         this script would identify as useless one statement from gcc that
85651         was not:
85652           if (aligned_ptr)
85653             free (((void **) aligned_ptr) [-1]);
85655 2011-04-20  Giuseppe Scrivano  <gscrivano@gnu.org>
85657         doc: update users.txt.
85658         * users.txt: Add barcode.
85660 2011-04-19  Bruno Haible  <bruno@clisp.org>
85662         ioctl: Remove link dependency on native Windows.
85663         * lib/fd-hook.h: Renamed from lib/close-hook.h.
85664         (gl_close_fn, gl_ioctl_fn): New types.
85665         (struct fd_hook): Renamed from struct close_hook. Change type of
85666         private_close_fn field. Add private_ioctl_fn field.
85667         (close_hook_fn): Add parameter for primary close method.
85668         (execute_close_hooks, execute_all_close_hooks): Likewise.
85669         (ioctl_hook_fn): New type.
85670         (execute_ioctl_hooks, execute_all_ioctl_hooks): New declarations.
85671         (register_fd_hook): Renamed from register_close_hook. Add ioctl_hook
85672         argument.
85673         (unregister_fd_hook): Renamed from unregister_close_hook.
85674         * lib/fd-hook.c: Renamed from lib/close-hook.c.
85675         Don't include <unistd.h>.
85676         (close): Remove undef.
85677         (anchor): Update.
85678         (execute_close_hooks): Add argument for primary close method.
85679         (execute_all_close_hooks): Likewise.
85680         (execute_ioctl_hooks, execute_all_ioctl_hooks): New functions.
85681         (register_fd_hook): Renamed from register_close_hook. Add ioctl_hook
85682         argument. Allow each argument to be NULL.
85683         (unregister_fd_hook): Renamed from unregister_close_hook.
85684         * lib/close.c (rpl_close): Pass 'close' function pointer to
85685         execute_all_close_hooks.
85686         * lib/ioctl.c: Include <errno.h>, fd-hook.h.
85687         (primary_ioctl): New function.
85688         (ioctl): Don't call ioctlsocket here. Instead, call
85689         execute_all_ioctl_hooks.
85690         * lib/sockets.c (close_fd_maybe_socket): Add argument for primary
85691         close method.
85692         (ioctl_fd_maybe_socket): New function, with code from lib/ioctl.c.
85693         (fd_sockets_hook): Renamed from close_sockets_hook.
85694         (gl_sockets_startup, gl_sockets_cleanup): Update.
85695         * modules/fd-hook: Renamed from modules/close-hook. Update.
85696         * modules/close (Depends-on): Add fd-hook, remove close-hook.
85697         * modules/sockets (Depends-on): Likewise.
85698         * modules/ioctl (Depends-on): Add fd-hook.
85699         * tests/test-nonblocking.c (main): Use GNULIB_TEST_SOCKET, not
85700         GNULIB_SOCKET.
85702 2011-04-19  Bruno Haible  <bruno@clisp.org>
85704         Move the support of O_NONBLOCK in open() to the 'open' module.
85705         * modules/nonblocking (Depends-on): Remove 'open'.
85706         * m4/nonblocking.m4 (gl_NONBLOCKING_IO_BODY): Set
85707         gl_cv_have_open_O_NONBLOCK.
85708         * m4/open.m4 (gl_FUNC_OPEN): Replace open() also when required for
85709         O_NONBLOCK support.
85710         * doc/posix-functions/open.texi: Document support for O_NONBLOCK.
85712 2011-04-17  Bruno Haible  <bruno@clisp.org>
85714         pipe2: Simplify code.
85715         * lib/pipe2.c (pipe2): Reduce code duplication.
85717 2011-04-17  Bruno Haible  <bruno@clisp.org>
85719         nonblocking: Add comment.
85720         * lib/fcntl.in.h (O_NONBLOCK): Add comment.
85722 2011-04-17  Bruno Haible  <bruno@clisp.org>
85724         nonblocking: Add tests for sockets.
85725         * tests/test-nonblocking-socket.sh: New file.
85726         * tests/test-nonblocking-socket-main.c: New file.
85727         * tests/test-nonblocking-socket-child.c: New file.
85728         * tests/test-nonblocking-socket.h: New file.
85729         * tests/socket-server.h: New file.
85730         * tests/socket-client.h: New file.
85731         * modules/nonblocking-socket-tests: New file.
85732         * modules/nonblocking-tests (Depends-on): Add nonblocking-socket-tests.
85734 2011-04-17  Bruno Haible  <bruno@clisp.org>
85736         nonblocking: Add tests for pipes.
85737         * tests/test-nonblocking-pipe.sh: New file.
85738         * tests/test-nonblocking-pipe-main.c: New file.
85739         * tests/test-nonblocking-pipe-child.c: New file.
85740         * tests/test-nonblocking-pipe.h: New file.
85741         * tests/test-nonblocking-writer.h: New file.
85742         * tests/test-nonblocking-reader.h: New file.
85743         * tests/test-nonblocking-misc.h: New file.
85744         * modules/nonblocking-pipe-tests: New file.
85745         * modules/nonblocking-tests (Depends-on): Add nonblocking-pipe-tests.
85747 2011-04-16  Bruno Haible  <bruno@clisp.org>
85749         gettext: Clarify the needed programmer actions.
85750         * modules/gettext (Notice): New field.
85751         Suggested by Ben Pfaff <blp@cs.stanford.edu>.
85753 2011-04-16  Bruno Haible  <bruno@clisp.org>
85755         strchrnul: Tweak last commit.
85756         * doc/glibc-functions/strchrnul.texi: Add more details about Cygwin
85757         bug.
85758         * lib/string.in.h (strchrnul): Use same arguments in _GL_FUNCDECL_RPL
85759         as in _GL_FUNCDECL_SYS.
85760         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Invoke gl_PREREQ_STRCHRNUL after
85761         AC_LIBOBJ. When cross-compiling, say "guessing yes" not "yes".
85763 2011-04-15  Eric Blake  <eblake@redhat.com>
85765         strchrnul: work around cygwin bug
85766         * doc/glibc-functions/strchrnul.texi (strchrnul): Document bug.
85767         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Detect it.
85768         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New witness.
85769         * modules/string (Makefile.am): Substitute it.
85770         * lib/string.in.h (strchrnul): Use it.
85772 2011-04-15  Bruno Haible  <bruno@clisp.org>
85774         Don't require lib/stdio-write.c when only module 'stdio' is used.
85775         * m4/stdio_h.m4 (gl_STDIO_H): Move the AC_LIBOBJ back into the m4_ifdef
85776         invocation.
85777         Reported by Rob Vermaas <rob.vermaas@gmail.com>.
85779 2011-04-14  Bruno Haible  <bruno@clisp.org>
85781         Support non-blocking pipe I/O in read() on native Windows.
85782         * lib/unistd.in.h: Include <sys/types.h> also for 'read'.
85783         (read): New declaration.
85784         * lib/read.c: New file.
85785         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT_SCANF,
85786         _GL_ATTRIBUTE_FORMAT_SCANF_SYSTEM): New macros.
85787         (fgetc, fgets, fread, fscanf, getc, getchar, gets, scanf, vfscanf,
85788         vscanf): New declarations.
85789         * lib/stdio-read.c: New file.
85790         * m4/read.m4: New file.
85791         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_READ,
85792         REPLACE_READ.
85793         * m4/stdio_h.m4 (gl_STDIO_H): Set GNULIB_FGETC, GNULIB_FGETS,
85794         GNULIB_FREAD, GNULIB_FSCANF, GNULIB_GETC, GNULIB_GETCHAR, GNULIB_GETS,
85795         GNULIB_SCANF, GNULIB_VFSCANF, GNULIB_VSCANF. In non-blocking I/O is
85796         desired and needs workarounds, set REPLACE_STDIO_READ_FUNCS.
85797         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FGETC, GNULIB_FGETS,
85798         GNULIB_FREAD, GNULIB_FSCANF, GNULIB_GETC, GNULIB_GETCHAR, GNULIB_GETS,
85799         GNULIB_SCANF, GNULIB_VFSCANF, GNULIB_VSCANF, REPLACE_STDIO_READ_FUNCS.
85800         * modules/read: New file.
85801         * modules/nonblocking (Files): Add lib/stdio-read.c.
85802         * modules/unistd (Makefile.am): Substitute GNULIB_READ, REPLACE_READ.
85803         * modules/stdio (Makefile.am): Substitute GNULIB_FGETC, GNULIB_FGETS,
85804         GNULIB_FREAD, GNULIB_FSCANF, GNULIB_GETC, GNULIB_GETCHAR, GNULIB_GETS,
85805         GNULIB_SCANF, GNULIB_VFSCANF, GNULIB_VSCANF, REPLACE_STDIO_READ_FUNCS.
85806         * modules/pread (Depends-on): Add read.
85807         * modules/safe-read (Depends-on): Likewise.
85808         * tests/test-stdio-c++.cc (fgetc, fgets, fread, fscanf, getc, getchar,
85809         gets, scanf, vfscanf, vscanf): Verify signatures.
85810         * doc/posix-functions/read.texi: Mention 'nonblocking' module and
85811         problem with non-blocking pipes.
85812         * doc/posix-functions/fgetc.texi: Likewise.
85813         * doc/posix-functions/fgets.texi: Likewise.
85814         * doc/posix-functions/fread.texi: Likewise.
85815         * doc/posix-functions/fscanf.texi: Likewise.
85816         * doc/posix-functions/getc.texi: Likewise.
85817         * doc/posix-functions/getchar.texi: Likewise.
85818         * doc/posix-functions/gets.texi: Likewise.
85819         * doc/posix-functions/scanf.texi: Likewise.
85820         * doc/posix-functions/vfscanf.texi: Likewise.
85821         * doc/posix-functions/vscanf.texi: Likewise.
85823 2011-04-14  Bruno Haible  <bruno@clisp.org>
85825         Support non-blocking pipe I/O in write() on native Windows.
85826         * lib/write.c (rpl_write): Split a write request that failed merely
85827         because the byte count was larger than the pipe buffer's size.
85828         * doc/posix-functions/write.texi: Mention the problem with large byte
85829         counts.
85831 2011-04-14  Bruno Haible  <bruno@clisp.org>
85833         wchar: Ensure that wchar_t gets defined on uClibc.
85834         * lib/wchar.in.h: On uClibc, include <stddef.h>.
85835         Reported by Giuseppe Scrivano <gscrivano@gnu.org>.
85837 2011-04-13  Bruno Haible  <bruno@clisp.org>
85839         safe-write, full-read: Avoid unnecessary compilation units.
85840         * modules/safe-write (Files): Add lib/safe-read.c, m4/safe-read.m4.
85841         (Depends-on): Remove safe-read. Add ssize_t.
85842         * modules/full-read (Files): Add lib/full-write.c.
85843         (Depends-on): Add full-write.
85845 2011-04-13  Bruno Haible  <bruno@clisp.org>
85847         Support non-blocking pipe I/O and SIGPIPE in pwrite().
85848         * modules/pwrite (Depends-on): Add 'write'.
85850 2011-04-13  Bruno Haible  <bruno@clisp.org>
85852         Support non-blocking pipe I/O in write() on native Windows.
85853         * lib/unistd.in.h (write): Enable replacement also if
85854         GNULIB_UNISTD_H_NONBLOCKING is 1.
85855         * lib/write.c: Enable replacement also if GNULIB_NONBLOCKING.
85856         (rpl_write): When failing to write on a non-blocking pipe, change
85857         errno from ENOSPC to EAGAIN.
85858         * lib/stdio.in.h (fprintf, fputc, fputs, fwrite, printf, putc,
85859         putchar, puts, vfprintf, vprintf): Enable replacement also if
85860         GNULIB_STDIO_H_NONBLOCKING is 1.
85861         * lib/stdio-write.c: Enable replacements also if GNULIB_NONBLOCKING.
85862         (CLEAR_ERRNO, HANDLE_ENOSPC): New macros.
85863         (CLEAR_LastError, HANDLE_ERROR_NO_DATA): New macros, extracted from
85864         CALL_WITH_SIGPIPE_EMULATION.
85865         (CALL_WITH_SIGPIPE_EMULATION): Use them.
85866         * m4/nonblocking.m4: New file.
85867         * m4/write.m4 (gl_FUNC_WRITE): Enable REPLACE_WRITE also if required
85868         for non-blocking I/O support.
85869         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
85870         GNULIB_UNISTD_H_NONBLOCKING.
85871         * m4/stdio_h.m4 (gl_STDIO_H): Enable REPLACE_STDIO_WRITE_FUNCS also if
85872         required for non-blocking I/O support.
85873         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_STDIO_H_NONBLOCKING.
85874         * modules/nonblocking (Files): Add m4/nonblocking.m4,
85875         lib/stdio-write.c, m4/asm-underscore.m4.
85876         (Depends-on): Add stdio, unistd.
85877         (configure.ac): Invoke gl_NONBLOCKING_IO. Define GNULIB_NONBLOCKING.
85878         Set GNULIB_STDIO_H_NONBLOCKING, GNULIB_UNISTD_H_NONBLOCKING.
85879         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_NONBLOCKING.
85880         * modules/stdio (Makefile.am): Substitute GNULIB_STDIO_H_NONBLOCKING.
85881         * doc/posix-functions/fprintf.texi: Mention 'nonblocking' module and
85882         problem with non-blocking pipes.
85883         * doc/posix-functions/fputc.texi: Likewise.
85884         * doc/posix-functions/fputs.texi: Likewise.
85885         * doc/posix-functions/fwrite.texi: Likewise.
85886         * doc/posix-functions/printf.texi: Likewise.
85887         * doc/posix-functions/putc.texi: Likewise.
85888         * doc/posix-functions/putchar.texi: Likewise.
85889         * doc/posix-functions/puts.texi: Likewise.
85890         * doc/posix-functions/vfprintf.texi: Likewise.
85891         * doc/posix-functions/vprintf.texi: Likewise.
85892         * doc/posix-functions/write.texi: Likewise.
85894 2011-04-10  Jim Meyering  <meyering@redhat.com>
85896         maint.mk: prohibit doubled words
85897         Detect them also when they're separated by a newline.
85898         There are 3 ways to customize it:
85899           - disable the test on a per file basis, as usual with rules using
85900             $(VC_LIST_EXCEPT)
85901           - replace the default doubled-word-selecting regexp (affects all files)
85902           - ignore a particular file-vs-doubled-word match
85903         I nearly used that last one to ignore the "is is" match in
85904         coreutils' NEWS file, since the text was "ls -is is ..."
85905         To do that, I would have added this line to cfg.mk:
85906           ignore_doubled_word_match_RE_ = ^NEWS:[0-9]+:is[ ]is$
85907         but it would have ignored any "is is" match in NEWS.
85908         Low probability, but still...
85909         Instead, I changed the text, slightly:
85910           -  ls -is is now consistent with ls -lis in ignoring values returned
85911           +  "ls -is" is now consistent with ls -lis in ignoring values returned
85912         * top/maint.mk (prohibit_double_word_RE_): Provide default.
85913         (prohibit_doubled_word_): Define.
85914         (sc_prohibit_doubled_word): New rule.
85915         (sc_prohibit_the_the): Remove.  Subsumed by the above.
85917 2011-04-10  Jim Meyering  <meyering@redhat.com>
85919         maint: fix doubled-word typo in comment
85920         * m4/gethostname.m4: s/is is/it is/
85921         * m4/getdomainname.m4: Likewise.
85923 2011-04-10  Jim Meyering  <meyering@redhat.com>
85925         maint: remove doubled word: s/it it/it/
85926         * lib/stat-time.h (get_stat_birthtime): s/it it/it/
85928 2011-04-10  Jim Meyering  <meyering@redhat.com>
85930         maint.mk: remove useless semicolon and backslash
85931         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Remove stray
85932         semicolon and backslash.
85934 2011-04-10  Bruno Haible  <bruno@clisp.org>
85936         stdint test: Fix compilation failure on OSF/1 with DTK compiler.
85937         * modules/stdint-tests (Depends-on): Add wchar.
85939 2011-04-10  Jim Meyering  <meyering@redhat.com>
85941         maint: remove doubled words in comments, e.g., s/a a/a/
85942         * lib/strptime.c (day_of_the_week): s/the the/the/
85943         * tests/test-chown.h (test_chown): s/a a/a/
85945         test-chown.h: correct a cast
85946         * tests/test-chown.h (test_chown): Cast -1 to gid_t (not uid_t)
85947         when the destination is a stat.st_gid.
85949 2011-04-09  Mats Erik Andersson  <mats.andersson@gisladisker.se>  (tiny change)
85951         getaddrinfo: Fix test for sa_len member.
85952         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): When testing for sa_len,
85953         include <sys/types.h> before <sys/socket.h>.
85955 2011-04-09  Paul Eggert  <eggert@cs.ucla.edu>
85957         maint: change "can not" to "cannot"
85958         * doc/posix-functions/iconv.texi (iconv): This one crossed line
85959         boundaries.
85961 2011-04-09  Jim Meyering  <meyering@redhat.com>
85963         maint: change "a a" to "a"
85964         * tests/test-lchown.h (test_lchown): s/a a/a/
85966         maint.mk: prohibit \<the the\>
85967         * top/maint.mk (sc_prohibit_the_the): New rule.
85969         maint: fix "the the" in comment
85970         * lib/count-one-bits.h: s/the the/the/
85972         maint: change "can not" to "cannot"
85973         But do not change the occurrences in maintain.texi or in
85974         build-aux/po/Makefile.in.in, which I presume comes from gettext.
85975         * doc/gnulib-tool.texi: s/can not/cannot/
85976         * doc/posix-functions/accept.texi (accept): Likewise.
85977         * doc/posix-functions/socket.texi (socket): Likewise.
85978         * lib/mbrtowc.c: Likewise.
85980         maint.mk: prohibit use of "can not"
85981         * top/maint.mk (sc_prohibit_can_not): New rule.
85982         Writing "can not" (rather than "cannot") is too common.  Prohibit it.
85984 2011-04-09  Bruno Haible  <bruno@clisp.org>
85986         careadlinkat: Guard against misuse of careadlinkatcwd.
85987         * lib/careadlinkat.c: Include <stdlib.h>.
85988         (careadlinkatcwd): Check that the fd argument is as expected.
85990 2011-04-09  Bruno Haible  <bruno@clisp.org>
85992         careadlinkat: Use common coding style.
85993         * lib/careadlinkat.c: Move gnulib includes after system includes.
85995 2011-04-09  Bruno Haible  <bruno@clisp.org>
85997         careadlinkat: Clarify specification.
85998         * lib/careadlinkat.h (careadlinkat): Clarify preadlinkat argument.
85999         (careadlinkatcwd): Add comment.
86000         * lib/careadlinkat.c (careadlinkat): Clarify preadlinkat argument.
86002 2011-04-09  Bruno Haible  <bruno@clisp.org>
86004         areadlinkat: Avoid link error on many platforms.
86005         * modules/areadlinkat (Depends-on): Add areadlink.
86007 2011-04-09  Bruno Haible  <bruno@clisp.org>
86009         allocator, careadlinkat: Fix double-inclusion guard.
86010         * lib/allocator.h: Fix double-inclusion guard.
86011         * lib/careadlinkat.h: Likewise.
86013 2011-04-09  Bruno Haible  <bruno@clisp.org>
86015         relocatable-prog-wrapper: Update after module 'areadlink' changed.
86016         * lib/relocwrapper.c: Update dependencies hierarchy.
86017         * build-aux/install-reloc: Update list of files to be compiled.
86018         * modules/relocatable-prog-wrapper (Files): Add lib/careadlinkat.[hc],
86019         lib/allocator.[hc].
86021 2011-04-08  Eric Blake  <eblake@redhat.com>
86023         strftime: silence gnulib-tool warning
86024         * modules/strftime-tests (Depends-on): Drop automatic dependency.
86026 2011-04-08  Bruno Haible  <bruno@clisp.org>
86028         verify: Fix syntax error with GCC 4.6 in C++ mode.
86029         * lib/verify.h (HAVE__STATIC_ASSERT): Don't define in C++ mode.
86030         (HAVE_STATIC_ASSERT): New macro.
86031         (verify_true, verify): Use 'static_assert' if it is supported and
86032         '_Static_assert' is not supported.
86034 2011-04-08  Paul Eggert  <eggert@cs.ucla.edu>
86036         allocator: New module.
86037         * modules/allocator, lib/allocator.c: New files.
86038         * lib/allocator.h (stdlib_allocator): New decl.
86039         * lib/careadlinkat.c (_GL_USE_STDLIB_ALLOC, standard_allocator):
86040         Remove.  Do not include <stdlib.h>.
86041         (careadlinkat): Use stdlib_allocator instead of rolling our own.
86042         * modules/careadlinkat (Files): Remove lib/allocator.h.
86043         (Depends-on): Add allocator.
86045         stdlib: let modules use system malloc, realloc
86046         * lib/stdlib.in.h (malloc, realloc): Don't #define or add warnings
86047         if !_GL_USE_STDLIB_ALLOC.
86048         (malloc, realloc): Limit this change to a smaller scope.
86050         * lib/careadlinkat.c (_GL_USE_STDLIB_ALLOC): Define.
86051         (malloc, realloc): Don't #undef; no longer needed.
86052         * lib/malloca.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
86053         * lib/progreloc.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
86054         * lib/setenv.c (_GL_USE_STDLIB_ALLOC, malloc, realloc): Likewise.
86055         * lib/canonicalize-lgpl.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
86056         * lib/relocatable.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
86057         * lib/relocwrapper.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
86058         * lib/malloc.c (_GL_USE_STDLIB_ALLOC, malloc): Likewise.
86059         * lib/realloc.c (_GL_USE_STDLIB_ALLOC, malloc, realloc): Likewise.
86061         careadlinkat: rename members to avoid problem
86062         * lib/allocator.h (struct allocator): Rename members from
86063         malloc/realloc to allocate/reallocate, to avoid problems if malloc
86064         and realloc are #define'd.  Reported by Eric Blake in
86065         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00091.html>.
86066         * lib/careadlinkat.c (careadlinkat): Adjust to renaming.
86068 2011-04-08  Eric Blake  <eblake@redhat.com>
86070         nonblocking: reduce dependency
86071         * tests/test-nonblocking.c: Only test sockets when in use.
86072         * modules/nonblocking-tests (Depends-on): Drop socket.
86073         (Makefile.am): Link even if sockets are not present.
86074         * modules/pipe2-tests (Makefile.am): Likewise.
86075         * lib/ioctl.c (ioctl) [WIN32]: Fail if sockets are not also in use.
86077         pipe2: fix O_NONBLOCK support on mingw
86078         * modules/pipe2 (Depends-on): Add nonblocking.
86079         * lib/pipe2.c (pipe2) [WIN32]: Add O_NONBLOCK support.
86080         * tests/test-pipe2.c (is_nonblocking): Adjust test accordingly.
86081         * tests/test-nonblocking.c (main): Likewise.
86082         * modules/pipe2-tests (Makefile.am): Avoid link failure.
86084         fcntl-h: fix O_ACCMODE on cygwin
86085         * doc/posix-headers/fcntl.texi (fcntl.h): Document the bug.
86086         * lib/fcntl.in.h (O_ACCMODE): Fix it.
86088         pipe-filter: drop O_NONBLOCK workarounds
86089         * modules/pipe-filter-gi (Depends-on): Add fcntl-h.
86090         * modules/pipe-filter-ii (Depends-on): Likewise.
86091         * lib/pipe-filter-aux.h (O_NONBLOCK): Delete workaround.
86093         nonblocking: provide O_NONBLOCK for mingw
86094         * modules/nonblocking (Depends-on): Add open.
86095         (configure.ac): Set new witness macro.
86096         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Provide default for it.
86097         * modules/fcntl-h (Makefile.am): Substitute it.
86098         * lib/fcntl.in.h (O_NONBLOCK): Guarantee non-zero definition when
86099         nonblocking module is in use.
86100         * lib/nonblocking.c: Adjust portability test.
86101         * lib/open.c (open): Don't let native open see gnulib flag.
86102         * tests/test-fcntl-h.c (main): Enhance test.
86103         * tests/test-open.h (test_open): Likewise.
86104         * doc/posix-headers/fcntl.texi (fcntl.h): Document the replacement.
86106         careadlinkat: fix compilation error on mingw
86107         * lib/careadlinkat.c (standard_allocator): Avoid renaming fields
86108         within struct allocator.
86110 2011-04-06  Eric Blake  <eblake@redhat.com>
86112         binary-io: relicense under LGPLv2+
86113         * modules/binary-io (License): Relax to LGPLv2+.
86114         Requested for libvirt, and required by pipe2.
86116 2011-04-06  Paul Eggert  <eggert@cs.ucla.edu>
86118         verify: use _Static_assert if available
86119         * lib/verify.h (HAVE__STATIC_ASSERT): New macro.
86120         (verify_true, verify): Use it if available.  This generates better
86121         diagnostics with GCC 4.6.0 and later.
86123 2011-04-05  Bruno Haible  <bruno@clisp.org>
86125         Remove leftover generated .h files after config.status changed.
86127         * m4/alloca.m4 (gl_FUNC_ALLOCA): New automake conditional
86128         GL_GENERATE_ALLOCA_H.
86129         * modules/alloca-opt (Makefile.am): Remove alloca.h if
86130         GL_GENERATE_ALLOCA_H evaluates to false.
86132         * m4/argz.m4 (gl_FUNC_ARGZ): New automake conditional
86133         GL_GENERATE_ARGZ_H.
86134         * modules/argz (Makefile.am): Remove argz.h if GL_GENERATE_ARGZ_H
86135         evaluates to false.
86137         * m4/byteswap.m4 (gl_BYTESWAP): New automake conditional
86138         GL_GENERATE_BYTESWAP_H.
86139         * modules/byteswap (Makefile.am): Remove byteswap.h if
86140         GL_GENERATE_BYTESWAP_H evaluates to false.
86142         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): New automake conditional
86143         GL_GENERATE_ERRNO_H.
86144         * modules/errno (Makefile.am): Remove errno.h if GL_GENERATE_ERRNO_H
86145         evaluates to false.
86147         * m4/float_h.m4 (gl_FLOAT_H): New automake conditional
86148         GL_GENERATE_FLOAT_H.
86149         * modules/float (Makefile.am): Remove float.h if GL_GENERATE_FLOAT_H
86150         evaluates to false.
86152         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): New automake conditional
86153         GL_GENERATE_FNMATCH_H.
86154         * modules/fnmatch (Makefile.am): Remove fnmatch.h if
86155         GL_GENERATE_FNMATCH_H evaluates to false.
86157         * m4/glob.m4 (gl_GLOB_SUBSTITUTE, gl_GLOB): New automake conditional
86158         GL_GENERATE_GLOB_H.
86159         * modules/glob (Makefile.am): Remove glob.h if GL_GENERATE_GLOB_H
86160         evaluates to false.
86162         * m4/iconv_h.m4 (gl_REPLACE_ICONV_H, gl_ICONV_H_DEFAULTS): New
86163         automake conditional GL_GENERATE_ICONV_H.
86164         * modules/iconv-h (Makefile.am): Remove iconv.h if GL_GENERATE_ICONV_H
86165         evaluates to false.
86167         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): New automake conditional
86168         GL_GENERATE_NETINET_IN_H.
86169         * modules/netinet_in (Makefile.am): Remove netinet/in.h if
86170         GL_GENERATE_NETINET_IN_H evaluates to false.
86172         * m4/pthread.m4 (gl_PTHREAD_CHECK): Set PTHREAD_H here. New automake
86173         conditional GL_GENERATE_PTHREAD_H.
86174         (gl_PTHREAD_DEFAULTS): Don't set PTHREAD_H here.
86175         * modules/pthread (Makefile.am): Remove pthread.h if
86176         GL_GENERATE_PTHREAD_H evaluates to false.
86178         * m4/sched_h.m4 (gl_SCHED_H): New automake conditional
86179         GL_GENERATE_SCHED_H.
86180         * modules/sched (Makefile.am): Remove sched.h if GL_GENERATE_SCHED_H
86181         evaluates to false.
86183         * m4/selinux-context-h.m4 (gl_HEADERS_SELINUX_CONTEXT_H): New automake
86184         conditional GL_GENERATE_SELINUX_CONTEXT_H.
86185         * modules/selinux-h (Makefile.am): Remove selinux/context.h if
86186         GL_GENERATE_SELINUX_CONTEXT_H evaluates to false.
86188         * m4/stdarg.m4 (gl_STDARG_H): New automake conditional
86189         GL_GENERATE_STDARG_H.
86190         * modules/stdarg (Makefile.am): Remove stdarg.h if
86191         GL_GENERATE_STDARG_H evaluates to false.
86193         * m4/stdbool.m4 (AM_STDBOOL_H): New automake conditional
86194         GL_GENERATE_STDBOOL_H.
86195         * modules/stdbool (Makefile.am): Remove stdbool.h if
86196         GL_GENERATE_STDBOOL_H evaluates to false.
86198         * m4/stddef_h.m4 (gl_STDDEF_H): Set STDDEF_H here. New automake
86199         conditional GL_GENERATE_STDDEF_H.
86200         (gl_STDDEF_H_DEFAULTS): Don't set STDDEF_H here.
86201         * modules/stddef (Makefile.am): Remove stddef.h if
86202         GL_GENERATE_STDDEF_H evaluates to false.
86204         * m4/stdint.m4 (gl_STDINT_H): New automake conditional
86205         GL_GENERATE_STDINT_H.
86206         * modules/stdint (Makefile.am): Remove stdint.h if
86207         GL_GENERATE_STDINT_H evaluates to false.
86209         * m4/sysexits.m4 (gl_SYSEXITS): New automake conditional
86210         GL_GENERATE_SYSEXITS_H.
86211         * modules/sysexits (Makefile.am): Remove sysexits.h if
86212         GL_GENERATE_SYSEXITS_H evaluates to false.
86214         Reported by Karl Berry and Ralf Wildenhues.
86216 2011-04-05  Bruno Haible  <bruno@clisp.org>
86218         Ensure to rebuild generated .h files when config.status has changed.
86219         * modules/arpa_inet (Makefile.am): Add dependency from .h file to
86220         config.status.
86221         * modules/ctype (Makefile.am): Likewise.
86222         * modules/dirent (Makefile.am): Likewise.
86223         * modules/errno (Makefile.am): Likewise.
86224         * modules/fcntl-h (Makefile.am): Likewise.
86225         * modules/float (Makefile.am): Likewise.
86226         * modules/getopt-posix (Makefile.am): Likewise.
86227         * modules/glob (Makefile.am): Likewise.
86228         * modules/iconv-h (Makefile.am): Likewise.
86229         * modules/inttypes (Makefile.am): Likewise.
86230         * modules/langinfo (Makefile.am): Likewise.
86231         * modules/locale (Makefile.am): Likewise.
86232         * modules/math (Makefile.am): Likewise.
86233         * modules/netdb (Makefile.am): Likewise.
86234         * modules/netinet_in (Makefile.am): Likewise.
86235         * modules/poll-h (Makefile.am): Likewise.
86236         * modules/pthread (Makefile.am): Likewise.
86237         * modules/pty (Makefile.am): Likewise.
86238         * modules/sched (Makefile.am): Likewise.
86239         * modules/search (Makefile.am): Likewise.
86240         * modules/selinux-h (Makefile.am): Likewise.
86241         * modules/signal (Makefile.am): Likewise.
86242         * modules/spawn (Makefile.am): Likewise.
86243         * modules/stdarg (Makefile.am): Likewise.
86244         * modules/stdbool (Makefile.am): Likewise.
86245         * modules/stddef (Makefile.am): Likewise.
86246         * modules/stdint (Makefile.am): Likewise.
86247         * modules/stdio (Makefile.am): Likewise.
86248         * modules/stdlib (Makefile.am): Likewise.
86249         * modules/string (Makefile.am): Likewise.
86250         * modules/strings (Makefile.am): Likewise.
86251         * modules/sys_file (Makefile.am): Likewise.
86252         * modules/sys_ioctl (Makefile.am): Likewise.
86253         * modules/sys_select (Makefile.am): Likewise.
86254         * modules/sys_socket (Makefile.am): Likewise.
86255         * modules/sys_stat (Makefile.am): Likewise.
86256         * modules/sys_time (Makefile.am): Likewise.
86257         * modules/sys_times (Makefile.am): Likewise.
86258         * modules/sys_utsname (Makefile.am): Likewise.
86259         * modules/sys_wait (Makefile.am): Likewise.
86260         * modules/sysexits (Makefile.am): Likewise.
86261         * modules/termios (Makefile.am): Likewise.
86262         * modules/time (Makefile.am): Likewise.
86263         * modules/unistd (Makefile.am): Likewise.
86264         * modules/wchar (Makefile.am): Likewise.
86265         * modules/wctype-h (Makefile.am): Likewise.
86266         Reported by Karl Berry, Eric Blake, and Ralf Wildenhues.
86268 2011-04-05  Bruno Haible  <bruno@clisp.org>
86270         pipe2: Relicense under LGPLv2+.
86271         * modules/pipe2 (License): Change to LGPLv2+.
86272         Requested by Eric Blake, for libvirt.
86274 2011-04-05  Bruce Korb  <bkorb@gnu.org>
86276         bootstrap: compute gnulib_extra_files after updating build_aux
86277         * build-aux/bootstrap (gnulib_extra_files): bootstrap.conf may
86278         change build_aux or also supply gnulib_extra_files.  Handle correctly.
86280 2011-04-05  Eric Blake  <eblake@redhat.com>
86282         bootstrap: preserve git whitelist item sorting
86283         * build-aux/bootstrap (sort_patterns): New function.
86284         (insert_sorted_if_absent): Use it to sink ! lines to the bottom.
86286 2011-04-05  Simon Josefsson  <simon@josefsson.org>
86288         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Don't trigger
86289         sc_space_tab check.
86291 2011-04-05  Paul Eggert  <eggert@cs.ucla.edu>
86293         areadlink, areadlinkat: rewrite in terms of careadlinkat
86294         * lib/areadlink.c, lib/areadlinkat.c: Include careadlinkat.h
86295         instead of errno.h, limits.h, stdint.h, stdlib.h, string.h, unistd.h.
86296         (SSIZE_MAX, INITIAL_BUF_SIZE): Remove.
86297         (malloc, realloc): Remove #undefs.
86298         (areadlink, areadlinkat): Rewrite in terms of careadlinkat.
86299         * modules/areadlink (Depends-on): Add careadlinkat.  Remove
86300         readlink, ssize_t, stdint, unistd.
86301         * modules/areadlinkat (Depends-on): Add careadlinkat.  Remove
86302         areadlink, stdint.
86304         careadlinkat: new module
86305         * lib/allocator.h, lib/careadlinkat.h, lib/careadlinkat.c:
86306         * modules/careadlinkat: New files, written by me with
86307         a review and feedback from Ben Pfaff in
86308         <http://lists.gnu.org/r/bug-gnulib/2011-04/msg00008.html>.
86310 2011-04-01  Bruno Haible  <bruno@clisp.org>
86312         wmemchr, wcschr, wcsrchr, wcspbrk, wcsstr: Avoid errors in C++ mode.
86313         * lib/wchar.in.h (wmemchr, wcschr, wcsrchr, wcspbrk, wcsstr): Use
86314         _GL_CXXALIAS_SYS_CAST2 instead of _GL_CXXALIAS_SYS. On glibc >= 2.10
86315         systems, use _GL_CXXALIASWARN1 instead of _GL_CXXALIASWARN.
86316         Reported by Bruce Korb <bruce.korb@gmail.com>.
86318 2011-04-01  Bruno Haible  <bruno@clisp.org>
86320         wcpcpy, wcpncpy: Ensure declaration on glibc >= 2.13 systems.
86321         * m4/wcpcpy.m4 (gl_FUNC_WCPCPY): Require AC_USE_SYSTEM_EXTENSIONS.
86322         * m4/wcpncpy.m4 (gl_FUNC_WCPNCPY): Likewise.
86323         * modules/wcpcpy (Depends-on): Add extensions.
86324         * modules/wcpncpy (Depends-on): Likewise.
86325         * doc/posix-functions/wcpcpy.texi: Mention missing declaration on glibc
86326         systems.
86327         * doc/posix-functions/wcpncpy.texi: Likewise.
86328         * doc/posix-functions/wcwidth.texi: Likewise.
86330 2011-03-31  Eric Blake  <eblake@redhat.com>
86332         nonblocking: fix mingw test failures
86333         * lib/nonblocking.c (set_nonblocking_flag): Succeed when clearing
86334         non-blocking flag on regular file.
86335         (get_nonblocking_flag): Set errno on invalid fd.
86336         * tests/test-nonblocking.c (main): Avoid test failure on
86337         directories if fchdir is not active.
86338         * modules/nonblocking-tests (Depends-on): Drop unused dependency.
86340 2011-03-31  Bruno Haible  <bruno@clisp.org>
86342         Fix bug with gl_WARN_ON_USE_PREPARE, introduced on 2011-01-23.
86343         * m4/gnulib-common.m4 (gl_ASSERT_NO_GNULIB_POSIXCHECK): Hide the
86344         gl_WARN_ON_USE_PREPARE definition from 'aclocal'.
86345         Reported by Simon Josefsson <simon@josefsson.org>.
86347 2011-03-31  Bruno Haible  <bruno@clisp.org>
86348         and Eric Blake  <eblake@redhat.com>
86350         nonblocking: new module
86351         * modules/nonblocking: New module.
86352         * modules/nonblocking-tests: Likewise.
86353         * lib/nonblocking.h: New file.
86354         * lib/nonblocking.c: Likewise.
86355         * tests/test-nonblocking.c: New test.
86356         * lib/ioctl.c (ioctl) [mingw]: Update comment.
86358 2011-03-30  Bruno Haible  <bruno@clisp.org>
86360         stdio: Avoid GCC >= 4.4 warnings when using %lld and similar on mingw.
86361         * lib/stdio.in.h (_GL_ATTRIBUTE_FORMAT_PRINTF): Use 'gnu_printf' format
86362         instead of 'printf' format for GCC >= 4.4.
86363         (_GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM): New macro.
86364         (fprintf, printf, vfprintf, vprintf): Declare with
86365         _GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM when the function ends up calling
86366         the system's vfprintf() function.
86367         Reported by Daniel P. Berrange <berrange@redhat.com> via Eric Blake.
86369 2011-03-30  Eric Blake  <eblake@redhat.com>
86371         passfd: fix scoping bug
86372         * lib/passfd.c (sendfd, recvfd): Don't let buf go out of scope
86373         before sendmsg/recvmsg.
86375         passfd: standardize coding conventions
86376         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Drop check for something that
86377         can be learned at compile time.
86378         * lib/passfd.c (MSG_CMSG_CLOEXEC): Reduce number of in-function
86379         ifdefs.
86380         (sendfd, recvfd): Follow gnulib code conventions.
86382         passfd: fix incorrect sendmsg arguments
86383         * lib/passfd.c (sendfd): Avoid uninitialized msg_flags field, and
86384         incorrect msg_controllen value.
86385         * modules/passfd-tests (Depends-on): Check for alarm.
86386         * tests/test-passfd.c (main) [HAVE_DECL_ALARM]: Avoid hanging test.
86387         Reported by Bastien ROUCARIES.
86389 2011-03-30  Bruno Haible  <bruno@clisp.org>
86391         c-strcasestr: Relicense under LGPLv2+.
86392         * modules/c-strcasestr (License): Change to LGPLv2+.
86393         Requested by Eric Blake, for libvirt.
86395 2011-03-30  Simon Josefsson  <simon@josefsson.org>
86397         * users.txt: Add libidn2.  Fix libtasn1 link.
86399 2011-03-30  Jim Meyering  <meyering@redhat.com>
86401         tests: readlink* ("",... fails with EINVAL on newer kernels
86402         readlink and readlinkat have typically failed with ENOENT for
86403         the invalid, empty file name,  "".  However, with the advent
86404         of linux-2.6.39, they fail with EINVAL.
86405         * tests/test-areadlink.h (test_areadlink): Also accept EINVAL
86406         when operating on the empty file name.
86407         * tests/test-readlink.h (test_readlink): Likewise.
86409 2011-03-29  Bruno Haible  <bruno@clisp.org>
86411         Relicense some modules under LGPLv2+, for libidn2.
86412         * modules/array-mergesort (License): Change to LGPLv2+.
86413         * modules/c-strcaseeq (License): Likewise.
86414         * modules/striconveh (License): Likewise.
86415         * modules/striconveha (License): Likewise.
86416         * modules/uniconv/base (License): Likewise.
86417         * modules/uniconv/u8-conv-from-enc (License): Likewise.
86418         * modules/uniconv/u8-strconv-from-enc (License): Likewise.
86419         * modules/uniconv/u8-strconv-from-locale (License): Likewise.
86420         * modules/unictype/base (License): Likewise.
86421         * modules/unictype/bidiclass-of (License): Likewise.
86422         * modules/unictype/category-M (License): Likewise.
86423         * modules/unictype/category-none (License): Likewise.
86424         * modules/unictype/category-of (License): Likewise.
86425         * modules/unictype/category-test (License): Likewise.
86426         * modules/unictype/category-test-withtable (License): Likewise.
86427         * modules/unictype/combining-class (License): Likewise.
86428         * modules/unictype/joiningtype-of (License): Likewise.
86429         * modules/unictype/scripts (License): Likewise.
86430         * modules/uninorm/base (License): Likewise.
86431         * modules/uninorm/canonical-decomposition (License): Likewise.
86432         * modules/uninorm/composition (License): Likewise.
86433         * modules/uninorm/decompose-internal (License): Likewise.
86434         * modules/uninorm/decomposition-table (License): Likewise.
86435         * modules/uninorm/nfc (License): Likewise.
86436         * modules/uninorm/nfd (License): Likewise.
86437         * modules/uninorm/u32-normalize (License): Likewise.
86438         * modules/unistr/base (License): Likewise.
86439         * modules/unistr/u32-cpy (License): Likewise.
86440         * modules/unistr/u32-mbtouc-unsafe (License): Likewise.
86441         * modules/unistr/u32-to-u8 (License): Likewise.
86442         * modules/unistr/u32-uctomb (License): Likewise.
86443         * modules/unistr/u8-check (License): Likewise.
86444         * modules/unistr/u8-mblen (License): Likewise.
86445         * modules/unistr/u8-mbtouc (License): Likewise.
86446         * modules/unistr/u8-mbtouc-unsafe (License): Likewise.
86447         * modules/unistr/u8-mbtoucr (License): Likewise.
86448         * modules/unistr/u8-prev (License): Likewise.
86449         * modules/unistr/u8-strlen (License): Likewise.
86450         * modules/unistr/u8-to-u32 (License): Likewise.
86451         * modules/unistr/u8-uctomb (License): Likewise.
86452         * modules/unitypes (License): Likewise.
86453         Requested by Simon Josefsson.
86455 2011-03-29  Simon Josefsson  <simon@josefsson.org>
86457         lib-symbol-visibility: Add a notice.
86458         * modules/lib-symbol-visibility (Notice): New field.
86460 2011-03-29  Bruno Haible  <bruno@clisp.org>
86462         getaddrinfo: Doc fix.
86463         * doc/posix-functions/getaddrinfo.texi: Mention Windows problem in the
86464         section "fixed in Gnulib".
86466 2011-03-28  Simon Josefsson  <simon@josefsson.org>
86468         * doc/posix-functions/getaddrinfo.texi: Drop netdb.h discussion.
86469         Reported by Bastien ROUCARIES <roucaries.bastien@gmail.com>.
86471 2011-03-26  Bruno Haible  <bruno@clisp.org>
86473         unictype/property-byname: Reduce the number of load-time relocations.
86474         * lib/unictype/pr_byname.c: Include <stdlib.h>.
86475         (UC_PROPERTY_INDEX_*): New enumeration values.
86476         (uc_property_byname): Convert an index from the lookup table to an
86477         uc_property_t.
86478         * lib/unictype/pr_byname.gperf: Store indices instead of uc_property_t
86479         values.
86481 2011-03-26  Bruno Haible  <bruno@clisp.org>
86483         unictype/property-byname: Allow omitted word separators and aliases.
86484         * lib/unictype/pr_byname.gperf: Add property names without word
86485         separators. Add aliases from Unicode 6.0 PropertyAliases.txt, except
86486         for 'space'.
86488 2011-03-26  Bruno Haible  <bruno@clisp.org>
86490         unictype/joininggroup-byname: Allow hyphens, omitted word separators.
86491         * lib/unictype/joininggroup_byname.c (uc_joining_group_byname): Convert
86492         also hyphens to space.
86493         * lib/unictype/joininggroup_byname.gperf: Recognize the names also
86494         without spaces.
86495         * tests/unictype/test-joininggroup_byname.c (main): Add more tests.
86497 2011-03-26  Bruno Haible  <bruno@clisp.org>
86499         unictype/joiningtype-byname: Recognize long names as well.
86500         * lib/unictype.in.h (uc_joiningtype_class_byname): Allow argument to be
86501         a long name.
86502         * lib/unictype/joiningtype_byname.c: Include <string.h>,
86503         unictype/joiningtype_byname.h.
86504         (uc_joiningtype_class_byname): Use uc_joining_type_lookup.
86505         * lib/unictype/joiningtype_byname.gperf: New file.
86506         * modules/unictype/joiningtype-byname (Files): Add
86507         lib/unictype/joiningtype_byname.gperf.
86508         (Depends-on): Add gperf.
86509         (Makefile.am): Add rule for generating unictype/joiningtype_byname.h.
86510         * tests/unictype/test-joiningtype_byname.c (main): Test the recognition of
86511         long names.
86513         Tests for module 'unictype/joiningtype-longname'.
86514         * modules/unictype/joiningtype-longname-tests: New file.
86515         * tests/unictype/test-joiningtype_longname.c: New file.
86517         New module 'unictype/joiningtype-longname'.
86518         * lib/unictype.in.h (uc_joiningtype_class_long_name): New declaration.
86519         * lib/unictype/joiningtype_longname.c: New file.
86520         * modules/unictype/joiningtype-longname: New file.
86521         * modules/unictype/joiningtype-all (Depends-on): Add
86522         unictype/joiningtype-longname.
86524 2011-03-26  Bruno Haible  <bruno@clisp.org>
86526         unictype/bidiclass-byname: Recognize long names as well.
86527         * lib/unictype.in.h (uc_bidi_class_byname): Allow argument to be a long
86528         name.
86529         * lib/unictype/bidi_byname.c: Include <string.h>,
86530         unictype/bidi_byname.h.
86531         (uc_bidi_class_byname): Use uc_bidi_class_lookup.
86532         * lib/unictype/bidi_byname.gperf: New file.
86533         * modules/unictype/bidiclass-byname (Files): Add
86534         lib/unictype/bidi_byname.gperf.
86535         (Depends-on): Add gperf.
86536         (Makefile.am): Add rule for generating unictype/bidi_byname.h.
86537         * tests/unictype/test-bidi_byname.c (main): Test the recognition of
86538         long names.
86540         Tests for module 'unictype/bidiclass-longname'.
86541         * modules/unictype/bidiclass-longname-tests: New file.
86542         * tests/unictype/test-bidi_longname.c: New file.
86544         New module 'unictype/bidiclass-longname'.
86545         * lib/unictype.in.h (uc_bidi_class_long_name): New declaration.
86546         * lib/unictype/bidi_longname.c: New file.
86547         * modules/unictype/bidiclass-longname: New file.
86548         * modules/unictype/bidiclass-all (Depends-on): Add
86549         unictype/bidiclass-longname.
86551 2011-03-26  Bruno Haible  <bruno@clisp.org>
86553         unictype/bidi*: Rename modules.
86554         * modules/unictype/bidiclass-all: Renamed from
86555         modules/unictype/bidicategory-all.
86556         * modules/unictype/bidiclass-name: Renamed from
86557         modules/unictype/bidiclass-name.
86558         (Description): Update.
86559         * modules/unictype/bidiclass-name-tests: Renamed from
86560         modules/unictype/bidicategory-name-tests.
86561         * modules/unictype/bidiclass-byname: Renamed from
86562         modules/unictype/bidicategory-byname.
86563         (Description): Update.
86564         * modules/unictype/bidiclass-byname-tests: Renamed from
86565         modules/unictype/bidicategory-byname-tests.
86566         * modules/unictype/bidiclass-of: Renamed from
86567         modules/unictype/bidicategory-of.
86568         (Description): Update.
86569         * modules/unictype/bidiclass-of-tests: Renamed from
86570         modules/unictype/bidicategory-of-tests.
86571         * modules/unictype/bidiclass-test: Renamed from
86572         modules/unictype/bidicategory-test.
86573         (Description): Update.
86574         * modules/unictype/bidiclass-test-tests: Renamed from
86575         modules/unictype/bidicategory-test-tests.
86576         * modules/unictype/bidicategory-all: New file, a simple redirection.
86577         * modules/unictype/bidicategory-name: Likewise.
86578         * modules/unictype/bidicategory-byname: Likewise.
86579         * modules/unictype/bidicategory-of: Likewise.
86580         * modules/unictype/bidicategory-test: Likewise.
86581         * modules/unictype/property-bidi-* (Dependencies): Update.
86582         * lib/unictype/bidi_*.c: Update comment.
86584 2011-03-26  Bruno Haible  <bruno@clisp.org>
86586         unictype/bidi*: Rename functions, part 2.
86587         * modules/unictype/bidicategory-name (configure.ac): Update required
86588         libunistring version.
86589         * modules/unictype/bidicategory-byname (configure.ac): Likewise.
86591 2011-03-25  Bruno Haible  <bruno@clisp.org>
86593         New module 'unictype/combining-class-all'.
86594         * modules/unictype/combining-class-all: New file.
86596         Tests for module 'unictype/combining-class-byname'.
86597         * modules/unictype/combining-class-byname-tests: New file.
86598         * tests/unictype/test-combiningclass_byname.c: New file.
86600         New module 'unictype/combining-class-byname'.
86601         * lib/unictype.in.h (uc_combining_class_byname): New declaration.
86602         * lib/unictype/combiningclass_byname.c: New file.
86603         * lib/unictype/combiningclass_byname.gperf: New file.
86604         * modules/unictype/combining-class-byname: New file.
86606         Tests for module 'unictype/combining-class-longname'.
86607         * modules/unictype/combining-class-longname-tests: New file.
86608         * tests/unictype/test-combiningclass_longname.c: New file.
86610         New module 'unictype/combining-class-longname'.
86611         * lib/unictype.in.h (uc_combining_class_long_name): New declaration.
86612         * lib/unictype/combiningclass_longname.c: New file.
86613         * modules/unictype/combining-class-longname: New file.
86615         Tests for module 'unictype/combining-class-name'.
86616         * modules/unictype/combining-class-name-tests: New file.
86617         * tests/unictype/test-combiningclass_name.c: New file.
86619         New module 'unictype/combining-class-name'.
86620         * lib/unictype.in.h (uc_combining_class_name): New declaration.
86621         * lib/unictype/combiningclass_name.c: New file.
86622         * modules/unictype/combining-class-name: New file.
86624 2011-03-25  Bruno Haible  <bruno@clisp.org>
86626         unictype/combining-class: Rename source files.
86627         * lib/gen-uni-tables.c (main): Emit unictype/combiningclass.h instead
86628         of unictype/combining.h.
86629         * lib/unictype/combiningclass.c: Renamed from lib/unictype/combining.c.
86630         Update.
86631         * lib/unictype/combiningclass.h: Renamed from lib/unictype/combining.h.
86632         * modules/unictype/combining-class (Description): Fix.
86633         (Files, Makefile.am): Update.
86634         * tests/unictype/test-combiningclass.c: Renamed from
86635         tests/unictype/test-combining.c.
86636         * modules/unictype/combining-class-tests (Files, Makefile.am): Update.
86638 2011-03-25  Bruno Haible  <bruno@clisp.org>
86640         unictype: Update list of canonical combining classes.
86641         * lib/unictype.in.h (UC_CCC_ATA): New enumeration value.
86643 2011-03-25  Bruno Haible  <bruno@clisp.org>
86645         unictype/category-byname: Recognize long names as well.
86646         * lib/unictype.in.h (uc_general_category_byname): Allow argument to be
86647         a long name.
86648         * lib/unictype/categ_byname.c: Include <stdlib.h>, <string.h>,
86649         unictype/categ_byname.h.
86650         (UC_CATEGORY_INDEX_*): New enumeration values.
86651         (uc_general_category_byname): Use uc_general_category_lookup and
86652         convert from index to value.
86653         * lib/unictype/categ_byname.gperf: New file.
86654         * modules/unictype/category-byname (Files): Add
86655         lib/unictype/categ_byname.gperf.
86656         (Depends-on): Add gperf.
86657         (Makefile.am): Add rule for generating unictype/categ_byname.h.
86658         * tests/unictype/test-categ_byname.c (main): Test the recognition of
86659         long names.
86661         Tests for module 'unictype/category-longname'.
86662         * modules/unictype/category-longname-tests: New file.
86663         * tests/unictype/test-categ_longname.c: New file.
86665         New module 'unictype/category-longname'.
86666         * lib/unictype.in.h (uc_general_category_long_name): New declaration.
86667         * lib/unictype/categ_longname.c: New file.
86668         * modules/unictype/category-longname: New file.
86669         * modules/unictype/category-all (Depends-on): Add it.
86671 2011-03-25  Bruno Haible  <bruno@clisp.org>
86673         Tests for module 'unictype/category-LC'.
86674         * modules/unictype/category-LC-tests: New file.
86675         * tests/unictype/test-categ_LC.c: New file, automatically generated.
86677         New module 'unictype/category-LC'.
86678         * lib/unictype.in.h (UC_CATEGORY_MASK_LC): New enumeration value.
86679         (UC_CATEGORY_LC): New declaration.
86680         (UC_CASED_LETTER): New macro.
86681         * lib/gen-uni-tables.c (is_category_LC): New function.
86682         (output_categories): Also handle category LC.
86683         (UC_CATEGORY_MASK_LC): New enumeration value.
86684         (general_category_byname): Also handle category LC.
86685         * lib/unictype/categ_LC.c: New file.
86686         * lib/unictype/categ_LC.h: New file, automatically generated.
86687         * lib/unictype/categ_name.c (uc_general_category_name): Also handle
86688         category LC.
86689         * lib/unictype/categ_byname.c (uc_general_category_byname): Likewise.
86690         * modules/unictype/category-LC: New file.
86691         * modules/unictype/category-byname (Depends-on): Add
86692         unictype/category-LC.
86693         * modules/unictype/category-all (Depends-on): Likewise.
86695 2011-03-25  Eric Blake  <eblake@redhat.com>
86697         xmalloc: revert yesterday's regression
86698         * lib/xmalloc.c (xrealloc): Once again forward xrealloc(NULL,0) to
86699         realloc's underlying behavior (allowing allocation of zero-size
86700         objects, especially if malloc-gnu is also in use).
86702 2011-03-25  Reuben Thomas  <rrt@sc3d.org>
86704         maint.mk: add missing version to VC-tag
86705         * top/maint.mk: git tag was missing actual tag name; add it.
86707         valgrind: do leak checking, and exit with code 1 on error (not 0)
86708         * m4/valgrind-tests.m4: Add `--error-exitcode=1 --leak-check=full'
86709         to VALGRIND.
86711 2010-11-30  Reuben Thomas  <rrt@sc3d.org>
86713         posix-modules: say what it does.
86714         * posix-modules: Add a line to the --help output saying what it does.
86716 2011-03-24  Paul Eggert  <eggert@cs.ucla.edu>
86718         xmalloc: Do not leak if underlying realloc is C99 compatible.
86719         * lib/xmalloc.c (xrealloc): If N is zero, call 'free' directly.
86720         This avoids a leak on C99-based systems.  See
86721         <http://lists.gnu.org/r/bug-gnulib/2011-03/msg00243.html>.
86723 2011-03-24  Eric Blake  <eblake@redhat.com>
86725         realloc: document portability problem
86726         * doc/posix-functions/realloc.texi (realloc): Mention pitfalls of
86727         passing 0 size to realloc.
86729 2011-03-23  Ben Walton  <bwalton@artsci.utoronto.ca>
86731         doc: update users.txt
86732         * users.txt: Add cvsps, tmpwatch
86734 2011-03-23  Matt Rice  <ratmice@gmail.com>
86736         doc: update users.txt
86737         * users.txt: Add gdb.
86739 2011-03-23  Jim Meyering  <meyering@redhat.com>
86741         doc: update users.txt
86742         Looking through matches up to the following URL (there are still
86743         several more pages), I found several projects that use gnulib:
86744         http://codesearch.google.com/codesearch?start=50&q=gnulib-cache\.m4
86745         * users.txt: Add nagios plugins (nagiosplug), acct, gengetopt,
86746         gmediaserver, gtkreindeer, jugtail, libunistring, mini-httpd, reindeer.
86748 2011-03-22  Bruno Haible  <bruno@clisp.org>
86750         unictype/bidi*: Rename functions.
86751         * lib/unictype.in.h (uc_bidi_class_name, uc_bidi_class_byname,
86752         uc_bidi_class, uc_is_bidi_class): New declarations.
86753         * lib/unictype/bidi_byname.c (uc_bidi_class_byname): Renamed from
86754         uc_bidi_category_byname.
86755         (uc_bidi_category_byname): New function.
86756         * lib/unictype/bidi_name.c (u_bidi_class_name): Renamed from
86757         u_bidi_category_name.
86758         (uc_bidi_class_name): Renamed from uc_bidi_category_name.
86759         (uc_bidi_category_name): New function.
86760         * lib/unictype/bidi_of.c (uc_bidi_class): Renamed from
86761         uc_bidi_category.
86762         (uc_bidi_category): New function.
86763         * lib/unictype/bidi_test.c (uc_is_bidi_class): Renamed from
86764         uc_is_bidi_category. Invoke uc_bidi_class.
86765         (uc_is_bidi_category): New function.
86766         * tests/unictype/test-bidi_byname.c (main): Test uc_bidi_class_byname
86767         instead of uc_bidi_category_byname.
86768         * tests/unictype/test-bidi_name.c (main): Test uc_bidi_class_name
86769         instead of uc_bidi_category_name.
86770         * tests/unictype/test-bidi_of.c (main): Test uc_bidi_class instead of
86771         uc_bidi_category.
86772         * tests/unictype/test-bidi_test.c (main): Test uc_is_bidi_class
86773         instead of uc_is_bidi_category.
86775 2011-03-21  Bruno Haible  <bruno@clisp.org>
86777         New module 'unictype/joininggroup-all'.
86778         * modules/unictype/joininggroup-all: New file.
86780         Tests for module 'unictype/joininggroup-of'.
86781         * modules/unictype/joininggroup-of-tests: New file.
86782         * tests/unictype/test-joininggroup_of.c: New file.
86783         * tests/unictype/test-joininggroup_of.h: New file, automatically
86784         generated by gen-uni-tables.
86786         New module 'unictype/joininggroup-of'.
86787         * modules/unictype/joininggroup-of: New file.
86788         * lib/unictype/joininggroup_of.c: New file.
86789         * lib/unictype/joininggroup_of.h: New file, automatically generated by
86790         gen-uni-tables.
86792         Tests for module 'unictype/joininggroup-byname'.
86793         * modules/unictype/joininggroup-byname-tests: New file.
86794         * tests/unictype/test-joininggroup_byname.c: New file.
86796         New module 'unictype/joininggroup-byname'.
86797         * modules/unictype/joininggroup-byname: New file.
86798         * lib/unictype/joininggroup_byname.c: New file.
86799         * lib/unictype/joininggroup_byname.gperf: New file.
86801         Tests for module 'unictype/joininggroup-name'.
86802         * modules/unictype/joininggroup-name-tests: New file.
86803         * tests/unictype/test-joininggroup_name.c: New file.
86805         New module 'unictype/joininggroup-name'.
86806         * modules/unictype/joininggroup-name: New file.
86807         * lib/unictype/joininggroup_name.c: New file.
86808         * lib/unictype/joininggroup_name.h: New file.
86810         New module 'unictype/joiningtype-all'.
86811         * modules/unictype/joiningtype-all: New file.
86813         Tests for module 'unictype/joiningtype-of'.
86814         * modules/unictype/joiningtype-of-tests: New file.
86815         * tests/unictype/test-joiningtype_of.c: New file.
86816         * tests/unictype/test-joiningtype_of.h: New file, automatically
86817         generated by gen-uni-tables.
86819         New module 'unictype/joiningtype-of'.
86820         * modules/unictype/joiningtype-of: New file.
86821         * lib/unictype/joiningtype_of.c: New file.
86822         * lib/unictype/joiningtype_of.h: New file, automatically generated by
86823         gen-uni-tables.
86825         Tests for module 'unictype/joiningtype-byname'.
86826         * modules/unictype/joiningtype-byname-tests: New file.
86827         * tests/unictype/test-joiningtype_byname.c: New file.
86829         New module 'unictype/joiningtype-byname'.
86830         * modules/unictype/joiningtype-byname: New file.
86831         * lib/unictype/joiningtype_byname.c: New file.
86833         Tests for module 'unictype/joiningtype-name'.
86834         * modules/unictype/joiningtype-name-tests: New file.
86835         * tests/unictype/test-joiningtype_name.c: New file.
86837         New module 'unictype/joiningtype-name'.
86838         * modules/unictype/joiningtype-name: New file.
86839         * lib/unictype/joiningtype_name.c: New file.
86841         unictype: Add support for Arabic shaping properties.
86842         * lib/unictype.in.h (UC_JOINING_TYPE_*): New enumeration values.
86843         (uc_joining_type_name, uc_joining_type_byname, uc_joining_type): New
86844         declarations.
86845         (UC_JOINING_GROUP_*): New enumeration values.
86846         (uc_joining_group_name, uc_joining_group_byname, uc_joining_group): New
86847         declarations.
86848         * lib/gen-uni-tables.c (UC_JOINING_TYPE_*): New enumeration values.
86849         (unicode_joining_type): New variable.
86850         (UC_JOINING_GROUP_*): New enumeration values.
86851         (unicode_joining_group): New variable.
86852         (fill_arabicshaping, joining_type_as_c_identifier,
86853         output_joining_type_test, output_joining_type,
86854         joining_group_as_c_identifier, output_joining_group_test,
86855         output_joining_group): New functions.
86856         (main); Add an argument denoting the ArabicShaping.txt file. Invoke
86857         fill_arabicshaping and output_joining_type_test, output_joining_type,
86858         output_joining_group_test, output_joining_group.
86859         Reported by Simon Josefsson.
86861 2011-03-21  Jim Meyering  <meyering@redhat.com>
86863         strftime: fix a bug in yesterday's change
86864         * lib/strftime.c (add): Accommodate width's initial value of -1.
86865         Otherwise, nstrftime would copy uninitialized data into
86866         the result buffer.
86868 2011-03-21  Jim Meyering  <meyering@redhat.com>
86870         tests: add strftime-tests module
86871         * tests/test-strftime.c: New file.
86872         * modules/strftime-tests: New module.
86874 2011-03-20  Paul Eggert  <eggert@cs.ucla.edu>
86876         strftime: don't assume a byte count fits in 'int'
86877         * lib/strftime.c (add): Don't assume first arg fits in 'int'.  I
86878         found this problem by static analysis, using gcc -Wstrict-overflow
86879         (GCC 4.5.2, x86-64).  This reported an optimization that depended
86880         on an integer overflow having undefined behavior, but it turns out
86881         that the argument is a size, which might not fit in 'int' anyway,
86883 2011-03-20  Paul Eggert  <eggert@cs.ucla.edu>
86885         stdio: don't require ignore_value around fwrite
86887         This patch works around libc bug 11959
86888         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=11959>.
86889         Without this patch, applications must often write
86890         ignore_value (fwrite (...)) even though the ignore_value is
86891         not helpful here.  It's common to write many objects, using
86892         fwrite/printf/etc., and then use ferror to detect output error.
86894         I considered making this patch optional, but decided against it,
86895         because libc is obviously being inconsistent here: there is no
86896         reason libc should insist that user code must inspect fwrite
86897         return's value without also insisting that it inspect printf's,
86898         putchar's, etc.  If user code wants to have a strict style where
86899         all these functions' values are checked (so that ferror need not
86900         be checked), we could add support for that style in a new gnulib
86901         module, but in the meantime it's better to be consistent and to
86902         support common usage.
86904         * lib/stdio.in.h (rpl_fwrite): Define this wrapper around fwrite,
86905         to work around libc bug 11959, if __USE_FORTIFY_LEVEL indicates
86906         that we are compiling in checking mode, and if not C++, and
86907         if not already wrapping fwrite for some other reason.
86908         (fwrite): #define to rpl_fwrite if the latter is defined.
86910 2011-03-20  Bruno Haible  <bruno@clisp.org>
86912         verror: Fix compilation error introduced on 2011-02-13.
86913         * lib/verror.h (verror, verror_at_line): Use _GL_ATTRIBUTE_FORMAT macro
86914         instead of __attribute__.
86915         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
86917 2011-03-20  Paul Eggert  <eggert@cs.ucla.edu>
86918             Bruno Haible  <bruno@clisp.org>
86920         socklen: do not depend on sys_socket
86921         While trying to modify Emacs to use gnulib's socklen module,
86922         I discovered a circular dependency: socklen depends on sys_socket
86923         and vice versa.  Emacs can use socklen, but it does not need
86924         sys_socket because it has its own substitute for sys/socket.h.
86925         * m4/socklen.m4 (gl_SOCKET_HEADERS): New macro, extracted from
86926         gl_TYPE_SOCKLEN_T.
86927         (gl_CHECK_SOCKET_HEADERS): New macro, taken from parts of
86928         gl_PREREQ_SYS_H_SOCKET.
86929         (gl_TYPE_SOCKLEN_T): Require it instead of requiring
86930         gl_PREREQ_SYS_H_SOCKET.
86931         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_SOCKET): Require
86932         gl_CHECK_SOCKET_HEADERS instead of doing its work ourselves.
86933         * modules/socklen (Depends-on): Do not depend on sys_socket.
86934         (Include): Adjust to match the code used in gl_SOCKET_HEADERS.
86936 2011-03-20  Jim Meyering  <meyering@redhat.com>
86938         maint.mk: sort file names *after* new transformation
86939         * top/maint.mk (sc_po_check): Sorting before removing the $(srcdir)/
86940         prefix would have led to an unwarranted failure in GNU parted.
86941         Sort after that transformation.
86943 2011-03-19  Jim Meyering  <meyering@redhat.com>
86945         maint.mk: fix po-file syntax-check rule
86946         * top/maint.mk (sc_po_check): Fix fatal typo in yesterday's change.
86947         Patch by Bruno Haible.
86949 2011-03-19  Bruno Haible  <bruno@clisp.org>
86951         socklen: Update comment.
86952         * m4/socklen.m4: Update comment about platforms.
86954 2011-03-19  Paul Eggert  <eggert@cs.ucla.edu>
86955             Bruno Haible  <bruno@clisp.org>
86957         inet_ntop, inet_pton: Simplify.
86958         * modules/inet_ntop (Depends-on): Remove socklen, since sys_socket is
86959         documented to provide socklen_t and we already depend on sys_socket.
86960         * modules/inet_pton (Depends-on): Likewise.
86961         * lib/arpa_inet.in.h: Adjust comment.
86963 2011-03-19  Paul Eggert  <eggert@cs.ucla.edu>
86964             Bruno Haible  <bruno@clisp.org>
86966         netdb: Simplify.
86967         * modules/netdb (Depends-on): Remove socklen, since sys_socket is
86968         documented to provide socklen_t and we already depend on sys_socket.
86969         * lib/netdb.in.h: Adjust comment.
86971 2011-03-19  Bruno Haible  <bruno@clisp.org>
86973         sys_socket, netdb: Document problem with socklen_t.
86974         * doc/posix-headers/sys_socket.texi: Mention lack of socklen_t on some
86975         platforms.
86976         * doc/posix-headers/netdb.texi: Likewise.
86978 2011-03-18  Eric Blake  <eblake@redhat.com>
86980         maint.mk: let po check work in VPATH build
86981         * top/maint.mk (po_file): Allow cfg.mk override.
86982         (sc_po_check): Allow VPATH use.
86983         Reported by Jiri Denemark.
86985 2011-03-16  Jim Meyering  <meyering@redhat.com>
86987         maint.mk: allow fine-grained syntax-check exclusion via Make variables
86988         Before, you would have had to create one .x-sc_ file per rule in order
86989         to exempt offending files.  Now, you may instead use a Make variable --
86990         usually defined in cfg.mk -- whose name identifies the affected rule.
86991         * top/maint.mk (_sc_excl): Define.
86992         (VC_LIST_EXCEPT): Use it to exclude names on a per-rule basis.
86993         (_sc_search_regexp): When not using VC_LIST_EXCEPT, exclude here, too.
86995 2011-03-13  Bruno Haible  <bruno@clisp.org>
86997         ignore-value tests: Avoid warnings.
86998         * tests/test-ignore-value.c (_GL_ATTRIBUTE_RETURN_CHECK): Define to
86999         empty for gcc < 3.4.
87001 2011-03-13  Bruno Haible  <bruno@clisp.org>
87003         passfd: Fix link error on Solaris.
87004         * modules/passfd (Description): Correct.
87005         (Depends-on): Add socketlib.
87006         (Link): New section.
87007         * modules/passfd-tests (Makefile.am): Link test-passfd with LIBSOCKET.
87009 2011-03-13  Bruno Haible  <bruno@clisp.org>
87011         passfd: Fix link error on AIX 5.2.
87012         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Define _LINUX_SOURCE_COMPAT.
87014 2011-03-13  Bruno Haible  <bruno@clisp.org>
87016         passfd: Work around bug with CMSG_FIRSTHDR on FreeBSD 6.4.
87017         * lib/sys_socket.in.h: Include <stddef.h>.
87018         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Include <stddef.h> before using
87019         CMSG_FIRSTHDR. Remove unused variable.
87021 2011-03-13  Bruno Haible  <bruno@clisp.org>
87023         passfd: Fix compilation error on OpenBSD.
87024         * lib/passfd.c: Include <sys/uio.h>.
87026 2011-03-13  Bruno Haible  <bruno@clisp.org>
87028         passfd test: Fix warnings.
87029         * tests/test-passfd.c: Include <sys/wait.h>.
87030         (main): Fix typo.
87032 2011-03-13  Bruno Haible  <bruno@clisp.org>
87034         passfd module, part 4, tweaks.
87035         * tests/test-passfd.c: Reorder includes.
87036         (main): Fix perror and printf calls.
87038 2011-03-07  Bastien Roucariès  <roucaries.bastien@gmail.com>
87040         passfd module, part 4.
87041         * modules/passfd-tests: New file.
87042         * tests/test-passfd.c: New file.
87044 2011-03-13  Jim Meyering  <meyering@redhat.com>
87046         Makefile: rely on GNU make; derive syntax-check rule names
87047         Rather than requiring that each sc_ rule be listed as a dependent
87048         of "check", use features of GNU make to derive the list.
87049         * Makefile (syntax-check-rules): Define.
87050         (check): Depend on the new variable, not the hard-coded list.
87052 2011-03-13  Bastien Roucariès  <roucaries.bastien@gmail.com>
87053             Bruno Haible  <bruno@clisp.org>
87055         passfd module, part 3.
87056         * lib/passfd.h (recvfd): Add a flags argument.
87057         * lib/passfd.c: Include <fcntl.h>, cloexec.h.
87058         (recvfd): Add a flags argument.
87059         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Test whether MSG_CMSG_CLOEXEC
87060         exists.
87061         * modules/passfd (Depends-on): Add cloexec.
87062         Suggested by Eric Blake.
87064 2011-03-13  Bruno Haible  <bruno@clisp.org>
87066         passfd module, part 2, tweaks.
87067         * modules/passfd (Files): Reorder.
87068         (Depends-on): Remove errno.
87069         (Include): Remove <sys/socket.h>, <sys/un.h>.
87070         * lib/passfd.h: Use a GPLv3+ header. Make C++ safe.
87071         * lib/passfd.c: Untabify. Use a GPLv3+ header. Really include the
87072         specification header. Include <sys/socket.h> always. Don't include
87073         <winsock2.h>. Use "#if HAVE_..." instead of "#ifdef HAVE_...".
87074         (sendfd): Clarify that it sets errno when it fails.
87075         (recvfd): Fix specification.
87077 2011-03-07  Bastien Roucariès  <roucaries.bastien@gmail.com>
87079         passfd module, part 2.
87080         * modules/passfd: New file.
87081         * lib/passfd.h: New file.
87082         * lib/passfd.c: New file.
87084 2011-03-12  Bruno Haible  <bruno@clisp.org>
87086         wcswidth, mbswidth: Avoid integer overflow.
87087         * lib/wcswidth.c: Include <limits.h>.
87088         * lib/wcswidth-impl.h (wcswidth): Avoid 'int' overflow.
87089         * lib/mbswidth.c: Include <limits.h>.
87090         (mbsnwidth): Avoid 'int' overflow.
87091         Reported by Jim Meyering.
87093 2011-03-12  Bruno Haible  <bruno@clisp.org>
87095         futimens, utimensat: Avoid endless recursion on Solaris 10.
87096         * lib/sys_stat.in.h (futimens, utimensat): Define with rpl_ prefix on
87097         Solaris.
87098         Reported by Ben Walton <bwalton@artsci.utoronto.ca> via Eric Blake
87099         in <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=8230>.
87101 2011-03-11  Jim Meyering  <meyering@redhat.com>
87103         maint.mk: relax a regexp to accommodate other formatting styles
87104         * top/maint.mk (sc_unmarked_diagnostics): Allow 0 or 1 space
87105         between "ngettext" and the following "(".
87107 2011-03-11  Pádraig Brady  <P@draigBrady.com>
87109         maint.mk: suppress a false positive warning
87110         * top/maint.mk ((sc_unmarked_diagnostics): Don't warn when
87111         diagnostics are marked with ngettext.
87113 2011-03-10  Eric Blake  <eblake@redhat.com>
87115         wchar: add explicit dependencies, for Tru64
87116         * modules/mbmemcasecoll (Depends-on): Add wchar.
87117         * modules/mbtowc (Depends-on): Likewise.
87118         * modules/vasnprintf (Depends-on): Likewise.
87119         * modules/unistdio/u-printf-args (Depends-on): Likewise.
87120         * modules/wctomb (Depends-on): Likewise.
87121         Reported by Peter O'Gorman.
87123 2011-03-08  Bruno Haible  <bruno@clisp.org>
87125         passfd module, part 1, tweaks.
87126         * m4/afunix.m4 (gl_SOCKET_AFUNIX): Update AC_REQUIRE invocation.
87127         Improve indentation. Improve AC_MSG_CHECKING messages.
87128         * m4/sockpfaf.m4 (gl_SOCKET_FAMILY_UNIX): New macro, extracted from
87129         gl_SOCKET_FAMILIES.
87131 2011-03-07  Bastien Roucariès  <roucaries.bastien@gmail.com>
87133         passfd module, part 1.
87134         * m4/afunix.m4: New file.
87135         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Also test for UNIX domain
87136         sockets.
87138 2011-03-08  Bruno Haible  <bruno@clisp.org>
87140         regex-quote: New API.
87141         * lib/regex-quote.h: Include <stdbool.h>.
87142         (struct regex_quote_spec): New type.
87143         (regex_quote_spec_posix, regex_quote_spec_gnu, regex_quote_spec_pcre):
87144         New declarations.
87145         (regex_quote_length, regex_quote_copy, regex_quote): Take a
87146         'const struct regex_quote_spec *' argument.
87147         * lib/regex-quote.c (RE_*, PCRE_*): New macros.
87148         (pcre_special): New constant.
87149         (regex_quote_spec_posix, regex_quote_spec_gnu, regex_quote_spec_pcre):
87150         New functions.
87151         (regex_quote_length, regex_quote_copy, regex_quote): Take a
87152         'const struct regex_quote_spec *' argument.
87153         * modules/regex-quote (Depends-on): Add stdbool.
87154         * tests/test-regex-quote.c (check): Update for new API. Add test for
87155         anchored results.
87156         * NEWS: Mention the API change.
87157         Reported by Reuben Thomas and Eric Blake.
87159 2011-03-06  Bruno Haible  <bruno@clisp.org>
87161         regex-quote: Fix creation of POSIX extended regular expressions.
87162         * lib/regex-quote.c (ere_special): Add grouping and alternation
87163         operators.
87165 2011-03-05  Bruno Haible  <bruno@clisp.org>
87167         doc: Improve doc regarding autopoint vs. gnulib.
87168         * doc/gnulib-tool.texi (gettextize and autopoint): Recommend to
87169         disable autopoint while running autoreconf.
87170         Suggested by Ralf Wildenhues.
87172 2011-03-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
87174         Update AC_OPENMP macro for Lahey compiler on GNU/Linux.
87175         * m4/openmp.m4 (AC_OPENMP): Sync from Autoconf.
87177 2011-03-03  Bruce Korb  <bkorb@gnu.org>
87179         parse-duration: remove xalloc.h dependency
87180         * lib/parse-duration.c (parse_period): handle NULL return from
87181         strdup instead of calling xstrdup().
87182         * modules/parse-duration: remove "xalloc" dependency
87184 2011-03-03  Matthew Booth  <mbooth@redhat.com>
87186         bootstrap: honor m4_base when running aclocal
87187         * build-aux/bootstrap: Fix hard-coded use of m4 directory name.
87189 2011-03-02  Jim Meyering  <meyering@redhat.com>
87191         getopt-gnu: relax license from LGPLv3+ to LGPLv2+
87192         * modules/getopt-gnu (License): Relax to LGPLv2+, for augeas,
87193         on request from Matt Booth.
87195 2011-03-01  Eric Blake  <eblake@redhat.com>
87197         test-link: work on Hurd
87198         * tests/test-link.h (test_link): Hurd rejects linking directories
87199         with EISDIR instead of the POSIX-mandated EPERM.
87201 2011-02-28  Paul Eggert  <eggert@cs.ucla.edu>
87203         stdio: simplify by moving files to printf-posix, sigpipe
87204         * m4/stdio_h.m4 (gl_STDIO_H): Do not require gl_ASM_SYMBOL_PREFIX,
87205         since this symbol is needed only if printf is replaced.
87206         * m4/printf-posix-rpl.m4 (gl_REPLACE_PRINTF):
87207         Require gl_ASM_SYMBOL_PREFIX.
87208         * modules/printf-posix (Files): Add m4/asm-underscore.m4.
87209         * modules/sigpipe (Files): Likewise.  Also, add m4/stdio-write.c.
87210         (Depends-on): Add 'raise'.
87211         (configure.ac): Require gl_ASM_SYMBOL_PREFIX.
87212         * modules/stdio (Files): Remove lib/stdio-write.c,
87213         m4/asm-underscore.m4.
87214         (Depends-on): Remove 'raise'.
87216         stdio: simplify by moving gl_STDIN_LARGE_OFFSET to fseeko, ftello
87217         * m4/fseeko.m4 (gl_STDIN_LARGE_OFFSET): Moved here, from ...
87218         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET): ... here, because
87219         * modules/ftello (Files): Add m4/fseeko.m4, for gl_STDIN_LARGE_OFFSET.
87221 2011-02-28  Bruno Haible  <bruno@clisp.org>
87223         localcharset: Assume ANSI C behaviour of free().
87224         * lib/localcharset.c (get_charset_aliases): Remove NULL test before
87225         calling free().
87226         Suggested by Simon Josefsson <simon@josefsson.org>.
87228 2011-02-28  Corinna Vinschen  <vinschen@redhat.com>  (tiny change)
87229             Charles Wilson  <cygwin@cwilson.fastmail.fm>  (tiny change)
87230             Bruno Haible  <bruno@clisp.org>  (tiny change)
87232         On Cygwin, use /proc file system instead of win32 API.
87233         * lib/relocatable.c: On Cygwin, use file names from /proc, rather than
87234         Win32 file names.
87235         (DllMain): Simplify by removing Cygwin specific code.
87236         (find_shared_library_fullname): Use Linux specific implementation also
87237         for Cygwin.
87238         (get_shared_library_fullname): Update accordingly.
87239         * lib/progreloc.c: On Cygwin, use file names from /proc, rather than
87240         Win32 file names.
87241         (find_executable): On Cygwin, use /proc, like on Linux. Remove previous
87242         Cygwin specific code.
87244 2011-02-28  Christian Rössel  <christian.roessel@gmx.de>  (tiny change)
87245             Markus Geimer  <m.geimer@fz-juelich.de>  (tiny change)
87247         Fix OpenMP flag detection for various Fortran compilers.
87248         * m4/openmp.m4 (_AC_LANG_OPENMP(Fortran 77)): Use '!$'
87249         OpenMP-conditional compilation construct, to force compile
87250         failure with missing OpenMP flag.
87251         (AC_OPENMP): Add flags for Cray CCE and NEC SX compilers.
87253 2011-02-25  Eric Blake  <eblake@redhat.com>
87255         strstr: expand test coverage
87256         * tests/test-strstr.c (main): Add much shorter trigger.  Fix C89
87257         compilation.
87258         * tests/test-memmem.c (main): Duplicate tests.
87259         * tests/test-strcasestr.c (main): Likewise.
87260         * tests/test-c-strcasestr.c (main): Likewise.
87262 2011-02-25  Jim Meyering  <meyering@redhat.com>
87264         maint.mk: detect missing-NL-at-EOF, too
87265         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Adjust so that
87266         it also detects when a file lacks a newline at EOF.
87267         (require_exactly_one_NL_at_EOF_): Renamed from
87268         detect_empty_lines_at_EOF_.  I opted not to rename the rule,
87269         since people may well have .x-sc_... file names tied to the
87270         existing name.  Suggested by Eric Blake.
87272 2011-02-25  Paul Eggert  <eggert@cs.ucla.edu>
87274         dirname: move m4/dos.m4 functionality into lib/dosname.h
87276         m4/dos.m4 needs to go.  It laboriously invokes the C compiler, and
87277         extracts symbols from it, puts them into config.h; but it's much
87278         easier to use the symbols directly.  filename.h already does this,
87279         but it disagrees with dos.m4 in some respects.  This patch
87280         introduces a different include file dosname.h that packages up
87281         dos.m4, and then later we can work on merging filename.h and
87282         dosname.h.  Applications that need only the easy-to-configure
87283         symbols should consider including dosname.h rather than dirname.h.
87284         * NEWS: Mention incompatible changes.
87285         * m4/dos.m4: Remove.
87286         * lib/dosname.h, modules/dosname: New files.
87287         * lib/dirname.h (ISSLASH, FILE_SYSTEM_PREFIX_LEN):
87288         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE):
87289         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): Move to lib/dosname.h.
87290         * lib/at-func.c, lib/at-func2.c, lib/openat.c, lib/savewd.c:
87291         Include dosname.h, not dirname.h.
87292         * lib/rmdir.c, lib/stat.c, lib/unlink.c, lib/unlinkat.c:
87293         Include dosname.h, for definitions of symbols like ISSLASH
87294         that used to be in config.h.
87295         * m4/dirname.m4 (gl_DIRNAME_LGPL): Do not require gl_AC_DOS.
87296         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
87297         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
87298         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
87299         * modules/dirname-lgpl (Files): Omit m4/dos.m4.
87300         * modules/rmdir (Files): Likewise.
87301         * modules/stat (Files): Likewise.
87302         * modules/unlink (Files): Likewise.
87303         * modules/dirname-lgpl (Depends-on): Add dosname.
87304         * modules/lstat (Depends-on): Likewise.
87305         * modules/openat (Depends-on): Likewise.
87306         * modules/rmdir (Depends-on): Likewise.
87307         * modules/savewd (Depends-on): Likewise.
87308         * modules/stat (Depends-on): Likewise.
87309         * modules/unlink (Depends-on): Likewise.
87310         * modules/openat (Depends-on): Remove dirname-lgpl.
87311         * modules/savewd (Depends-on): Likewise.
87312         * tests/test-dirname.c: Do not use removed symbols like
87313         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.  Instead, use
87314         the remaining symbols, e.g., ISSLASH ('\\').
87316 2011-02-25  Eric Blake  <eblake@redhat.com>
87318         strstr: revert patches that introduced bug and pessimization
87319         * lib/str-two-way.h: Add another reference.
87320         (two_way_short_needle, two_way_long_needle): Revert changes from
87321         2011-02-24; they pessimize search speed.
87322         (critical_factorization): Partially revert changes from
87323         2010-06-22; they violate the requirement that the left half of the
87324         needle be smaller than the period of the needle.
87326 2011-02-24  Paul Eggert  <eggert@cs.ucla.edu>
87328         filenamecat: remove unnecessary dependency on dirname-lgpl
87329         * modules/filenamecat (Depends-on): Remove dirname-lgpl, as there
87330         is no direct dependency, just an indirect one via filenamecat-lgpl.
87332         remove: remove unnecessary use of m4/dos.m4
87333         * m4/remove.m4 (gl_FUNC_REMOVE): Don't require gl_AC_DOS; not needed.
87334         * modules/remove (FILES): Remove m4/dos.m4.
87336         * lib/openat-proc.c: Don't include dirname.h; not needed.
87338         backupfile: remove unnecessary use of m4/dos.m4
87339         * m4/backupfile.m4 (gl_BACKUPFILE): Don't require gl_AC_DOS; none
87340         of its symbols are used by the backupfile code.  backupfile.c does
87341         use a symbol HAVE_DOS_FILE_NAMES, but that symbol is meant only
87342         for the rare case of programs that want all their backup file
87343         names to live within 8+3 limits, and dos.m4 doesn't address that.
87344         * modules/backupfile (Files): Remove m4/dos.m4.
87346 2011-02-24  Jim Meyering  <meyering@redhat.com>
87348         strstr: fix a bug whereby strstr would mistakenly return NULL
87349         * lib/str-two-way.h (two_way_short_needle): Correct off-by-one error
87350         in period calculation.
87351         (two_way_long_needle): Likewise.
87352         The original problem was reported by Mike Stump in
87353         http://thread.gmane.org/gmane.comp.sysutils.autoconf.bugs/7834
87354         Ralf Wildenhues provided the short needle and haystack.
87355         * tests/test-strstr.c: Add Ralf's test case to trigger the bug.
87356         Add a more involved test to trigger the bug in two_way_long_needle.
87358 2011-02-24  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
87360         gnulib-tool: remove use of bold display in help screen
87361         * gnulib-tool (func_usage): Do not use bold display anymore in the
87362         help screen.  That was just meant to be a temporary emphasis for a
87363         backward-incompatible change.
87365 2011-02-23  Bruno Haible  <bruno@clisp.org>
87367         Fix misindentation of preprocessor directives.
87368         * lib/argp-namefrob.h: Reindent preprocessor directives.
87369         * lib/getopt_int.h (struct _getopt_data): Likewise.
87370         * lib/progreloc.c (maybe_executable, find_executable): Likewise.
87371         * lib/vasnprintf.c (decode_long_double): Likewise.
87372         * tests/test-argmatch.c: Insert blank lines, for clarity.
87373         * tests/test-exclude.c: Likewise.
87375 2011-02-22  Bruno Haible  <bruno@clisp.org>
87377         ioctl: Fix for MacOS X in 64-bit mode.
87378         * lib/ioctl.c (rpl_ioctl): Zero-extend, not sign-extend, the request
87379         value.
87380         Suggested by Eric Blake.
87381         Reported by Markus Gothe <nietzsche@lysator.liu.se>.
87383 2011-02-22  Jim Meyering  <meyering@redhat.com>
87385         maint: sc_cpp_indent_check: remove the "only in lib/" restriction
87386         * Makefile (sc_cpp_indent_check): Don't limit the check to files
87387         in lib/.
87389 2011-02-22  Eric Blake  <eblake@redhat.com>
87391         maint: avoid any CDPATH issue
87392         * Makefile (sc_cpp_indent_check): Anchor cd argument.
87394         maint: adjust cpp indentation for my modules, as well
87395         * Makefile (sc_cpp_indent_check): Add my name.
87396         * lib/fbufmode.c: Filter through cppi.
87397         * lib/fpurge.c: Likewise.
87398         * lib/freadable.c: Likewise.
87399         * lib/freading.c: Likewise.
87400         * lib/fwritable.c: Likewise.
87401         * lib/fwriting.c: Likewise.
87402         * lib/sigaction.c: Likewise.
87404 2011-02-22  Jim Meyering  <meyering@redhat.com>
87406         maint: adjust cpp indentation to reflect nesting depth
87407         I.e., in a block of code that begins with an unnested "#if",
87408         put one space between the "#" in column 1 and following token.
87409         For example,
87410         -#include <sys/vfs.h>
87411         +# include <sys/vfs.h>
87412         Do this only in .c files that are part of a module I maintain.
87413         * lib/linkat.c: Filter through cppi.
87414         * lib/nanosleep.c: Likewise.
87415         * lib/openat.c: Likewise.
87416         * lib/openat-die.c: Likewise.
87417         * lib/dup3.c: Likewise.
87418         * lib/fchownat.c: Likewise.
87419         * lib/flock.c: Likewise.
87420         * lib/fsync.c: Likewise.
87421         * lib/fts.c: Likewise.
87422         * lib/getpass.c: Likewise.
87423         * lib/gettimeofday.c: Likewise.
87424         * lib/userspec.c: Likewise.
87425         * Makefile (sc_cpp_indent_check): New rule, to check this.
87427 2011-02-22  Bruno Haible  <bruno@clisp.org>
87429         New module 'wctomb'.
87430         * lib/stdlib.in.h (wctomb): New declaration.
87431         * lib/wctomb.c: New file.
87432         * lib/wctomb-impl.h: New file.
87433         * m4/wctomb.m4: New file.
87434         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_WCTOMB,
87435         REPLACE_WCTOMB.
87436         * modules/stdlib (Makefile.am): Substitute GNULIB_WCTOMB,
87437         REPLACE_WCTOMB.
87438         * modules/wctomb: New file.
87439         * tests/test-stdlib-c++.cc: Test signature of wctomb.
87440         * doc/posix-functions/wctomb.texi: Mention the new module.
87441         * modules/wctob (Depends-on): Add wctomb.
87443 2011-02-22  Bruno Haible  <bruno@clisp.org>
87445         New module 'mbtowc'.
87446         * lib/stdlib.in.h (mbtowc): New declaration.
87447         * lib/mbtowc.c: New file.
87448         * lib/mbtowc-impl.h: New file, from libutf8 with modifications.
87449         * m4/mbtowc.m4: New file.
87450         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_MBTOWC,
87451         REPLACE_MBTOWC.
87452         * modules/stdlib (Makefile.am): Substitute GNULIB_MBTOWC,
87453         REPLACE_MBTOWC.
87454         * modules/mbtowc: New file.
87455         * tests/test-stdlib-c++.cc: Test signature of mbtowc.
87456         * doc/posix-functions/mbtowc.texi: Mention the new module.
87457         * modules/btowc (Depends-on): Add mbtowc.
87459 2011-02-22  Bruno Haible  <bruno@clisp.org>
87461         wcrtomb: Add more tests for native Windows platforms.
87462         * tests/test-wcrtomb-w32-1.sh: New file.
87463         * tests/test-wcrtomb-w32-2.sh: New file.
87464         * tests/test-wcrtomb-w32-3.sh: New file.
87465         * tests/test-wcrtomb-w32-4.sh: New file.
87466         * tests/test-wcrtomb-w32-5.sh: New file.
87467         * tests/test-wcrtomb-w32.c: New file.
87468         * modules/wcrtomb-tests (Files): Add them.
87469         (Makefile.am): Arrange to run these tests.
87470         * tests/test-wcrtomb-w32-6.sh: New file, currently unused.
87471         * tests/test-wcrtomb-w32-7.sh: New file, currently unused.
87473 2011-02-20  Bruno Haible  <bruno@clisp.org>
87475         wcrtomb: Enhance test.
87476         * tests/test-wcrtomb.c (main): Add test against bug with NULL argument.
87478 2011-02-20  Bruno Haible  <bruno@clisp.org>
87480         mbrtowc: Tiny optimization.
87481         * lib/mbrtowc.c (mbrtowc): Delay pstate assignment until it is needed.
87483 2011-02-20  Jim Meyering  <meyering@redhat.com>
87485         test-exclude.c: remove unmatched #endif
87486         * tests/test-exclude.c: Remove stray #endif, left over from
87487         the change of a week ago.
87489 2011-02-19  Jim Meyering  <meyering@redhat.com>
87491         git-version-gen: skip "-dirty" check when appropriate
87492         * build-aux/git-version-gen: Don't run any git commands when the
87493         version string comes from .tarball-version.  Prior to this, we
87494         would run git update-index --refresh even from a just-unpacked
87495         tarball directory, and that could affect a .git/ directory in a
87496         parent of the build directory.  Reported by Mike Frysinger.
87498 2011-02-19  Bruno Haible  <bruno@clisp.org>
87500         unictype/property-byname: Reduce the size of the 'data' segment.
87501         * lib/unictype/pr_byname.gperf: Add gperf option '%pic'.
87503 2011-02-19  Bruno Haible  <bruno@clisp.org>
87505         unictype/scripts: Reduce the size of the 'data' segment.
87506         * lib/gen-uni-tables.c (output_scripts_byname): Emit gperf option
87507         '%pic'.
87508         * lib/unictype/scripts_byname.gperf: Regenerated.
87510 2011-02-19  Bruno Haible  <bruno@clisp.org>
87512         stdint: Update documentation.
87513         * doc/posix-headers/stdint.texi: Mention WCHAR_MIN, WCHAR_MAX problem.
87515 2011-02-18  Paul Eggert  <eggert@cs.ucla.edu>
87517         stdint: omit redundant check for wchar.h
87518         * m4/stdint.m4 (gl_STDINT_H): The earlier part of this macro now
87519         always tests whether wchar.h exists, so remove the now-redundant test.
87521 2011-02-18  Bruno Haible  <bruno@clisp.org>
87523         stdint: Cut dependency to module 'wchar'.
87524         * lib/stdint.in.h: Include wchar.h only when HAVE_WCHAR_H is 1. Also
87525         include the necessary prerequisites.
87526         * m4/stdint.m4 (gl_STDINT_H): Test whether wchar.h exists.
87527         * modules/stdint (Depends-on): Remove wchar.
87528         (Makefile.am): Substitute HAVE_WCHAR_H.
87529         This reverts part of a 2007-01-06 commit. Reported by Paul Eggert.
87531 2011-02-18  Eric Blake  <eblake@redhat.com>
87533         longlong: skip, rather than fail, on cross-compilation
87534         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Avoid aborting configure
87535         when cross-compiling; regression from 2011-02-16.
87537 2011-02-17  Paul Eggert  <eggert@cs.ucla.edu>
87539         * NEWS: Mention 2011-02-08 change to stdlib.
87541 2011-02-17  Bruno Haible  <bruno@clisp.org>
87543         getloadavg: Add comments about platforms.
87544         * m4/getloadavg.m4: Add comment.
87545         * lib/getloadavg.c: Likewise.
87547 2011-02-17  Bruno Haible  <bruno@clisp.org>
87549         getloadavg: Fix link error on Solaris 2.6.
87550         * modules/getloadavg (Link): New section.
87551         * modules/getloadavg-tests (Makefile.am): Use GETLOADAVG_LIBS for
87552         linking test-getloadavg.
87553         * doc/glibc-functions/getloadavg.texi: Mention that Solaris 2.6 lacks
87554         getloadavg.
87556 2011-02-17  Paul Eggert  <eggert@cs.ucla.edu>
87558         * lib/getloadavg.c (getloadavg) [sgi]: Make ldav_off of type ptrdiff_t.
87559         It was 'int', but this doesn't match the IRIX 6.5 manual.
87560         Suggested by Bruno Haible in
87561         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00207.html>.
87563 2011-02-17  Bruno Haible  <bruno@clisp.org>
87565         havelib: Fix comments.
87566         * m4/lib-link.m4 (AC_LIB_RPATH): Update comments after 2007-01-02
87567         change.
87569 2011-02-17  Bruno Haible  <bruno@clisp.org>
87571         havelib: Update config.rpath.
87572         * build-aux/config.rpath: Update to match libtool.m4 from libtool-2.4.
87574 2011-02-17  Bruno Haible  <bruno@clisp.org>
87576         getloadavg test: Add some plausibility checks.
87577         * tests/test-getloadavg.c (check_avg): Print a warning when the value
87578         is improbable.
87580 2011-02-16  Eric Blake  <eblake@redhat.com>
87582         maintainer-makefile: make syntax-check a no-op from tarballs
87583         * top/maint.mk (no-vc-detected): New rule.
87584         (local-checks-available): Use it to avoid hanging if someone tries
87585         'make syntax-check' from a tarball.  Also append to any non-syntax
87586         checks already defined in cfg.mk.
87588 2011-02-16  Paul Eggert  <eggert@cs.ucla.edu>
87590         longlong: tune, particularly for common case of c99
87592         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Don't bother compiling
87593         or running anything if c99, or if unsigned long long int does not
87594         work.  In either case, we know the answer without further tests.
87595         Do not compile _AC_TYPE_LONG_LONG_SNIPPET twice.  Instead, compile
87596         it at most once, and use its results for both long long int and
87597         unsigned long long int.  This is more likely to be efficient in
87598         the common case where the program wants to check for both long
87599         long int and unsigned long long int.
87600         (AC_TYPE_UNSIGNED_LONG_LONG_INT): Don't bother compiling if c99,
87601         since the answer is already known.
87603 2011-02-15  Paul Eggert  <eggert@cs.ucla.edu>
87605         getloadavg: set errno
87606         * lib/getloadavg.c: Set errno when returning -1.  If no other
87607         error number looks appropriate, set it to ENOSYS if the getloadavg
87608         looks like it can't possibly ever work, ENOTSUP otherwise.
87609         Suggested by Bruno Haible in
87610         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00187.html>.
87612         getloadavg: trim unused parts and speed up 'configure'
87613         * NEWS: Document this.
87614         * lib/getloadavg.c: Ignore HAVE_GETLOADAVG; this file is now
87615         always compiled if getloadavg is absent.
87616         Move test code to ...
87617         * tests/test-getloadavg.c: New file, containing previous
87618         contents of test from lib/getloadavg.c.  It also contains
87619         suggestions by Bruno Haible in
87620         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00186.html>.
87621         * modules/getloadavg-tests: New file.
87622         * m4/getloadavg.m4 (gl_GETLOADAVG): Do not check for getloadavg twice.
87623         Do tests in the same order as they're needed for getloadavg.c.
87624         Omit setgid-related tests that generate symbols KMEM_GROUP,
87625         NEET_SETGID, GETLOADAVG_PRIVILEGED; nobody seems to use those any more.
87626         Do only the tests that are needed to see whether the system has
87627         getloadavg, moving the other tests into ...
87628         (gl_PREREQ_GETLOADAVG): ... here.  Do not define obsolete symbol
87629         NLIST_NAME_UNION; nobody should be using it.  Do not define
87630         symbols C_GETLOADAVG and HAVE_GETLOADAVG; they're no longer
87631         relevant, as the user of this module shouldn't care how getloadavg
87632         is implemented.
87634         getloadavg: omit unused var
87635         * lib/getloadavg.c (getloadavg): Omit unused local variable.
87637 2011-02-15  Jim Meyering  <meyering@redhat.com>
87639         doc: update users.txt
87640         * users.txt: Update iwhd's URL.
87642 2011-02-13  Bruno Haible  <bruno@clisp.org>
87644         Consistent macro naming for macros that use GCC __attribute__.
87645         * lib/di-set.h (_GL_ATTRIBUTE_NONNULL): Renamed from
87646         _ATTRIBUTE_NONNULL_.
87647         * lib/ino-map.h (_GL_ATTRIBUTE_NONNULL): Likewise.
87648         * lib/hash.h (_GL_ATTRIBUTE_WUR): Renamed from ATTRIBUTE_WUR.
87649         * lib/ignore-value.h (_GL_ATTRIBUTE_DEPRECATED): Renamed from
87650         ATTRIBUTE_DEPRECATED.
87651         * lib/openat.h (_GL_ATTRIBUTE_NORETURN): Renamed from
87652         ATTRIBUTE_NORETURN.
87653         * lib/sigpipe-die.h (_GL_ATTRIBUTE_NORETURN): Likewise.
87654         * lib/xmemdup0.h (_GL_ATTRIBUTE_NORETURN): Likewise.
87655         * lib/xstrtol.h (_GL_ATTRIBUTE_NORETURN): Likewise.
87656         * lib/xalloc.h (_GL_ATTRIBUTE_NORETURN): Likewise.
87657         (_GL_ATTRIBUTE_MALLOC): Renamed from ATTRIBUTE_MALLOC.
87658         (_GL_ATTRIBUTE_ALLOC_SIZE): Renamed from ATTRIBUTE_ALLOC_SIZE.
87659         * lib/version-etc.h (_GL_ATTRIBUTE_SENTINEL): Renamed from
87660         ATTRIBUTE_SENTINEL.
87661         * lib/safe-alloc.h (_GL_ATTRIBUTE_RETURN_CHECK): Renamed from
87662         ATTRIBUTE_RETURN_CHECK.
87663         * tests/test-ignore-value.c (_GL_ATTRIBUTE_RETURN_CHECK): Likewise.
87664         * tests/test-argmatch.c (_GL_ATTRIBUTE_NORETURN): Renamed from
87665         ATTRIBUTE_NORETURN.
87666         * tests/test-exclude.c (_GL_ATTRIBUTE_NORETURN): Likewise.
87667         Reported by Paul Eggert.
87669 2011-02-13  Bruno Haible  <bruno@clisp.org>
87671         Don't interfere with a program's definition of __attribute__.
87672         * lib/argp.h (__attribute__): Remove definition.
87673         (_GL_ATTRIBUTE_FORMAT): New macro.
87674         (argp_error, __argp_error, argp_failure, __argp_failure): Use it.
87675         * lib/argp-fmtstream.h (__attribute__): Remove definition.
87676         (_GL_ATTRIBUTE_FORMAT): New macro.
87677         (__argp_fmtstream_printf, argp_fmtstream_printf): Use it.
87678         * lib/argp-help.c (hol_entry_long_iterate): Use __attribute__ only for
87679         GCC 3 or newer.
87680         * lib/error.h (__attribute__): Remove definition.
87681         (_GL_ATTRIBUTE_FORMAT): New macro.
87682         (error, error_at_line): Use it.
87683         * lib/hash.h (__attribute__): Remove definition.
87684         (ATTRIBUTE_WUR): Update definition. Define always.
87685         * lib/openat.h (__attribute__): Remove definition.
87686         (ATTRIBUTE_NORETURN): Update definition. Define always.
87687         * lib/sigpipe-die.h (__attribute__): Remove definition.
87688         (ATTRIBUTE_NORETURN): Update definition. Define always.
87689         * lib/vasnprintf.h (__attribute__): Remove definition.
87690         (_GL_ATTRIBUTE_FORMAT): New macro.
87691         (asnprintf, vasnprintf): Use it.
87692         * lib/xalloc.h (__attribute__): Remove definition.
87693         (ATTRIBUTE_NORETURN): Update definition. Define always.
87694         (ATTRIBUTE_MALLOC, ATTRIBUTE_ALLOC_SIZE): Define always.
87695         * lib/xmemdup0.h (__attribute__): Remove definition.
87696         (ATTRIBUTE_NORETURN): Update definition. Define always.
87697         * lib/xprintf.h (__attribute__): Remove definition.
87698         (_GL_ATTRIBUTE_FORMAT): New macro.
87699         (xprintf, xvprintf, xfprintf, xvfprintf): Use it.
87700         * lib/xstrtol.h (__attribute__): Remove definition.
87701         (ATTRIBUTE_NORETURN): Update definition. Define always.
87702         * lib/xvasprintf.h (__attribute__): Remove definition.
87703         (_GL_ATTRIBUTE_FORMAT): New macro.
87704         (xasprintf, xvasprintf): Use it.
87705         * tests/test-argmatch.c (__attribute__): Remove definition.
87706         (ATTRIBUTE_NORETURN): Update definition. Define always.
87707         * tests/test-exclude.c (__attribute__): Remove definition.
87708         (ATTRIBUTE_NORETURN): Update definition. Define always.
87709         Reported by Paul Eggert.
87711 2011-02-13  Bruno Haible  <bruno@clisp.org>
87713         mbrtowc: Add more tests for native Windows platforms.
87714         * tests/test-mbrtowc-w32-1.sh: New file.
87715         * tests/test-mbrtowc-w32-2.sh: New file.
87716         * tests/test-mbrtowc-w32-3.sh: New file.
87717         * tests/test-mbrtowc-w32-4.sh: New file.
87718         * tests/test-mbrtowc-w32-5.sh: New file.
87719         * tests/test-mbrtowc-w32.c: New file.
87720         * modules/mbrtowc-tests (Files): Add them.
87721         (Makefile.am): Arrange to run these tests.
87722         * tests/test-mbrtowc-w32-6.sh: New file, currently unused.
87723         * tests/test-mbrtowc-w32-7.sh: New file, currently unused.
87725 2011-02-13  Bruno Haible  <bruno@clisp.org>
87727         mbrtowc: Work around native Windows bug.
87728         * m4/mbrtowc.m4 (gl_MBRTOWC_RETVAL): Detect native Windows bug. Use the
87729         guess when no suitable locale for testing was found.
87730         * doc/posix-functions/mbrtowc.texi: Mention the native Windows bug.
87732 2011-02-13  Bruno Haible  <bruno@clisp.org>
87734         mbsinit: Work around mingw bug.
87735         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Replace mbsinit also on mingw.
87736         * lib/mbsinit.c (mbsinit): Provide an alternate definition for native
87737         Windows.
87738         * doc/posix-functions/mbsinit.texi: Mention the mingw bug.
87740 2011-02-13  Bruno Haible  <bruno@clisp.org>
87742         mbsinit: Don't crash for a NULL argument.
87743         * lib/mbsinit.c (mbsinit): When the argument is NULL, return 1.
87744         * tests/test-mbsinit.c (mbsinit): Check this behaviour.
87746 2011-02-13  Bruno Haible  <bruno@clisp.org>
87748         Don't interfere with a program's definition of __attribute__.
87749         * lib/stdio.in.h (__attribute__): Remove definition.
87750         (_GL_ATTRIBUTE_FORMAT, _GL_ATTRIBUTE_FORMAT_PRINTF): New macros.
87751         (dprintf, fprintf, obstack_printf, obstack_printf, obstack_vprintf,
87752         printf, snprintf, sprintf, asprintf, vasprintf, vdprintf, vfprintf,
87753         vsnprintf, vsprintf): Use _GL_ATTRIBUTE_FORMAT_PRINTF.
87754         * lib/string.in.h (__attribute__): Remove definition.
87755         Reported by Paul Eggert.
87757 2011-02-12  Paul Eggert  <eggert@cs.ucla.edu>
87759         stdlib: don't get in the way of non-GCC __attribute__
87760         See thread starting at
87761         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00161.html>.
87762         Revert previous stdlib change, installing the following instead:
87763         * lib/stdlib.in.h (__attribute__): Remove.  We do not want
87764         to get in the way of a non-GCC compiler that supports __attribute__.
87765         (_GL_ATTRIBUTE_RETURN): New macro.
87766         (_Exit): Use it instead of __attribute__.
87768 2011-02-12  Bruno Haible  <bruno@clisp.org>
87770         quotearg test: Avoid test failure on mingw.
87771         * tests/test-quotearg.sh: Convert the locale identifier from native
87772         Windows syntax to Unix syntax.
87774 2011-02-12  Bruno Haible  <bruno@clisp.org>
87776         setlocale: Prefer gnulib's override over libintl's override.
87777         * lib/locale.in.h (GNULIB_defined_setlocale): New macro.
87778         * lib/gettext.h (setlocale): Redefine to rpl_setlocale if
87779         GNULIB_defined_setlocale is set.
87781 2011-02-12  Paul Eggert  <eggert@cs.ucla.edu>
87783         stdlib: support non-GCC __attribute__
87785         Fix a serious and tricky problem encountered when attempting to
87786         add the getloadavg module to Emacs.  Emacs worked fine on RHEL
87787         5.5, but it crashed due to memory corruption on Solaris 10 with
87788         Sun C 5.11.  Emacs normally ORs 3-bit tags into their low-order
87789         bits that are otherwise zero.  This tagging is optional inside
87790         Emacs but is preferred and is used when __attribute__ ((__aligned
87791         (8))) works, as it does with both recent-enough GCC and with Sun C
87792         5.11.  However, Sun C 5.11 is not GCC and does not #define
87793         __GNUC__ and __GNUC_MINOR__.
87795         When I added the getloadavg module to Emacs, it brought in
87796         stdlib.in.h, which contained this fragment:
87798            #ifndef __attribute__
87799            # if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 8)
87800            #  define __attribute__(Spec)   /* empty */
87801            # endif
87802            #endif
87804         When files that include <stdlib.h> were compiled with Sun C 5.11,
87805         the above code disabled __attribute__ ((__aligned (8))), which
87806         caused variables to not be properly aligned, which eventually led
87807         to the pointer corruption mentioned above.  (This was a bit hard
87808         to diagnose, unfortunately.)
87810         Several "#define __attribute__(X) /* empty */" code snippets need
87811         to be eradicated from Gnulib to work with non-GCC compilers that
87812         support __attribute__.  The Autoconf way to do this is to test for
87813         each kind of attribute that we want support for, and selectively
87814         enable that in source code.
87816         Fix this problem just for stdlib.h, by adding a test for the
87817         __noreturn__ attribute, and change stdlib.in.h to use that test
87818         when needed.  This technique can be easily generalized to the
87819         other *.in.h files and attributes, and a similar technique can be
87820         used for *.h and *.c files.  This patch is enough to solve the
87821         problem for Emacs + getloadavg, and I thought I'd publish it for
87822         feedback before undertaking further, similar fixes in other
87823         modules.
87825         This patch does not arrange to #define HAVE_ATTRIBUTE_NORETURN
87826         because it's not needed for stdlib.h.  It merely substitutes the
87827         value directly into stdlib.h.  We may well need to #define it, or
87828         similar symbols, for other modules, but it's nice to also have an
87829         option to not #define it for applications like Emacs that do not
87830         need it.
87832         * lib/stdlib.in.h (__attribute__): Do not #define.
87833         (_GL_ATTRIBUTE_NORETURN): New macro, which in stdlib.h needs to
87834         be defined only if the _Exit module is also used.
87835         * m4/_Exit.m4 (gl_FUNC__EXIT): Require gl_ATTRIBUTE_NORETURN.
87836         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Subst
87837         HAVE_ATTRIBUTE_NORETURN and default it to 1, its value on GNU
87838         platforms.
87839         * modules/_Exit (Files): Add m4/attribute.m4.
87840         * modules/stdlib (Makefile.am): Substitute HAVE_ATTRIBUTE_NORETURN.
87841         * m4/attribute.m4: New file.
87843 2011-02-12  Bruno Haible  <bruno@clisp.org>
87845         wcsrtombs: Work around bug on native Windows.
87846         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_NULL): Test against mingw bug.
87847         * lib/wcsrtombs.c (rpl_wcsrtombs): When dest is NULL, pass SIZE_MAX
87848         instead of len.
87849         * doc/posix-functions/wcsrtombs.texi: Document mingw bug.
87851 2011-02-12  Bruno Haible  <bruno@clisp.org>
87853         mbsrtowcs: Work around bug on native Windows.
87854         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Require gt_LOCALE_FR. Test
87855         against mingw bug.
87856         * doc/posix-functions/mbsrtowcs.texi: Document mingw bug.
87858 2011-02-12  Bruno Haible  <bruno@clisp.org>
87860         Avoid setlocale bugs in tests.
87861         * modules/btowc (Dependencies): Add setlocale.
87862         * modules/c-strcase (Dependencies): Likewise.
87863         * modules/mbmemcasecmp (Dependencies): Likewise.
87864         * modules/mbmemcasecoll (Dependencies): Likewise.
87865         * modules/mbrtowc (Dependencies): Likewise.
87866         * modules/mbscasecmp (Dependencies): Likewise.
87867         * modules/mbscasestr (Dependencies): Likewise.
87868         * modules/mbschr (Dependencies): Likewise.
87869         * modules/mbscspn (Dependencies): Likewise.
87870         * modules/mbsinit (Dependencies): Likewise.
87871         * modules/mbsncasecmp (Dependencies): Likewise.
87872         * modules/mbsnrtowcs (Dependencies): Likewise.
87873         * modules/mbspbrk (Dependencies): Likewise.
87874         * modules/mbspcasecmp (Dependencies): Likewise.
87875         * modules/mbsrchr (Dependencies): Likewise.
87876         * modules/mbsrtowcs (Dependencies): Likewise.
87877         * modules/mbsspn (Dependencies): Likewise.
87878         * modules/mbsstr (Dependencies): Likewise.
87879         * modules/nl_langinfo (Dependencies): Likewise.
87880         * modules/quotearg (Dependencies): Likewise.
87881         * modules/unicase/locale-language (Dependencies): Likewise.
87882         * modules/unicase/ulc-casecmp (Dependencies): Likewise.
87883         * modules/unicase/ulc-casecoll (Dependencies): Likewise.
87884         * modules/unigbrk/ulc-grapheme-breaks (Dependencies): Likewise.
87885         * modules/unistdio/u8-vasnprintf (Dependencies): Likewise.
87886         * modules/unistdio/u16-vasnprintf (Dependencies): Likewise.
87887         * modules/unistdio/u32-vasnprintf (Dependencies): Likewise.
87888         * modules/unistdio/ulc-vasnprintf (Dependencies): Likewise.
87889         * modules/uniwbrk/ulc-wordbreaks (Dependencies): Likewise.
87890         * modules/vasnprintf-posix (Dependencies): Likewise.
87891         * modules/wcrtomb (Dependencies): Likewise.
87892         * modules/wcsnrtombs (Dependencies): Likewise.
87893         * modules/wcsrtombs (Dependencies): Likewise.
87895 2011-02-12  Bruno Haible  <bruno@clisp.org>
87897         setlocale: Workaround native Windows bug.
87898         * lib/setlocale.c (rpl_setlocale): On native Windows, when setlocale
87899         succeeds but sets LC_CTYPE to "C", report a failure.
87900         * tests/test-setlocale2.sh: New file.
87901         * tests/test-setlocale2.c: New file.
87902         * modules/setlocale-tests (Files): Add the new files.
87903         (Makefile.am): Enable test-setlocale2.sh test.
87904         * doc/posix-functions/setlocale.texi: Mention workaround.
87906 2011-02-11  Bruno Haible  <bruno@clisp.org>
87908         Tests for module 'setlocale'.
87909         * modules/setlocale-tests: New file.
87910         * tests/test-setlocale1.sh: New file.
87911         * tests/test-setlocale1.c: New file.
87913         New module 'setlocale'.
87914         * lib/locale.in.h (setlocale): New declaration.
87915         * lib/setlocale.c: New file, based on
87916         gettext/gettext-runtime/intl/setlocale.c.
87917         * m4/setlocale.m4: New file.
87918         * m4/locale_h.m4 (gl_LOCALE_H): Test whether setlocale is declared.
87919         (gl_LOCALE_H_DEFAULTS): Initialize GNULIB_SETLOCALE, REPLACE_SETLOCALE.
87920         * modules/locale (Makefile.am): Substitute GNULIB_SETLOCALE,
87921         REPLACE_SETLOCALE.
87922         * modules/setlocale: New file.
87923         * tests/test-locale-c++.cc: Test the declaration of setlocale.
87924         * doc/posix-functions/setlocale.texi: Mention the new module.
87926 2011-02-11  Bruno Haible  <bruno@clisp.org>
87928         Prepare for locale dependent tests on mingw.
87929         * m4/locale-ar.m4 (gt_LOCALE_AR): On native Windows, don't try "ar"
87930         because it has the wrong locale encoding.
87931         * m4/locale-fr.m4 (gt_LOCALE_FR): On native Windows, try
87932         French_France.1252 instead of "fr".
87933         (gt_LOCALE_FR_UTF8): On native Windows, try French_France.65001.
87934         * m4/locale-ja.m4 (gt_LOCALE_JA): On native Windows, don't try "ja"
87935         because it has the wrong locale encoding.
87936         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Require AC_CANONICAL_HOST. On
87937         native Windows, try Turkish_Turkey.65001.
87938         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): On native Windows, try
87939         Chinese_China.54936.
87941         Prepare for locale dependent tests on mingw.
87942         * m4/locale-ar.m4 (gt_LOCALE_AR): On native Windows, call setlocale
87943         differently.
87944         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Likewise.
87945         * m4/locale-ja.m4 (gt_LOCALE_JA): Likewise.
87946         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
87947         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
87949 2011-02-11  Eric Blake  <eblake@redhat.com>
87951         strptime: avoid compiler warnings
87952         * lib/strptime.c (__strptime_internal) [!_NL_CURRENT]: Avoid
87953         compiler warnings about dead code.
87954         Reported by Daniel P. Berrange.
87956 2011-02-11  Thien-Thi Nguyen  <ttn@gnuvola.org>
87958         doc: update users.txt
87959         * users.txt: Add rcs.
87961 2011-02-10  John W. Eaton  <jwe@gnu.org>
87963         doc: update users.txt
87964         * users.txt: Add octave.
87966 2011-02-10  Jim Meyering  <meyering@redhat.com>
87968         doc: update users.txt
87969         * users.txt: Add iwhd.
87971 2011-02-09  Bruno Haible  <bruno@clisp.org>
87973         gnulib-tool: Make copyright notice adjustment more robust.
87974         * gnulib-tool (func_import): In sed_transform_main_lib_file,
87975         sed_transform_build_aux_file, sed_transform_testsrelated_lib_file,
87976         allow a line break to occur after "GNU" in "GNU [Lesser] General Public
87977         License".
87978         Reported by Glenn Morris <rgm@gnu.org> via Paul Eggert.
87980 2011-02-06  Bruno Haible  <bruno@clisp.org>
87982         New module 'towctrans'.
87983         * modules/towctrans: New file.
87984         * lib/wctype.in.h (towctrans): New declaration.
87985         * lib/towctrans.c: New file.
87986         * lib/towctrans-impl.h: New file.
87987         * m4/towctrans.m4: New file.
87988         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether towctrans is declared.
87989         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_TOWCTRANS.
87990         * modules/wctype-h (Makefile.am): Substitute GNULIB_TOWCTRANS.
87991         * tests/test-wctype-h-c++.cc: Test the declaration of towctrans.
87992         * doc/posix-functions/towctrans.texi: Mention the new module.
87994 2011-02-06  Bruno Haible  <bruno@clisp.org>
87996         New module 'wctrans'.
87997         * modules/wctrans: New file.
87998         * lib/wctype.in.h (wctrans): New declaration.
87999         * lib/wctrans.c: New file.
88000         * lib/wctrans-impl.h: New file.
88001         * m4/wctrans.m4: New file.
88002         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether wctrans is declared.
88003         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_WCTRANS.
88004         * modules/wctype-h (Makefile.am): Substitute GNULIB_WCTRANS.
88005         * tests/test-wctype-h-c++.cc: Test the declaration of wctrans.
88006         * doc/posix-functions/wctrans.texi: Mention the new module.
88008 2011-02-06  Bruno Haible  <bruno@clisp.org>
88010         New module 'iswctype'.
88011         * modules/iswctype: New file.
88012         * lib/wctype.in.h (iswctype): New declaration.
88013         * lib/iswctype.c: New file.
88014         * lib/iswctype-impl.h: New file.
88015         * m4/iswctype.m4: New file.
88016         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether iswctype is declared.
88017         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_ISWCTYPE.
88018         * modules/wctype-h (Makefile.am): Substitute GNULIB_ISWCTYPE.
88019         * tests/test-wctype-h-c++.cc: Test the declaration of iswctype.
88020         * doc/posix-functions/iswctype.texi: Mention the new module and the
88021         HP-UX 11.00 problem.
88023 2011-02-06  Bruno Haible  <bruno@clisp.org>
88025         New module 'wctype'.
88026         * modules/wctype: Change to represent the wctype() substitute.
88027         * lib/wctype.in.h (wctype): New declaration.
88028         * lib/wctype.c: New file.
88029         * lib/wctype-impl.h: New file.
88030         * m4/wctype.m4: New file.
88031         * m4/wctype_h.m4 (gl_WCTYPE_H): Test whether wctype is declared.
88032         (gl_WCTYPE_H_DEFAULTS): Initialize GNULIB_WCTYPE.
88033         * modules/wctype-h (Makefile.am): Substitute GNULIB_WCTYPE.
88034         * tests/test-wctype-h-c++.cc: Test the declaration of wctype.
88035         * doc/posix-functions/wctype.texi: Mention the new module and the
88036         HP-UX 11.00 problem.
88038 2011-02-06  Bruno Haible  <bruno@clisp.org>
88040         wctype-h: Ensure wctype_t and wctrans_t are defined.
88041         * lib/wctype.in.h (wctype_t, wctrans_t): New type declarations.
88042         * m4/wctype_h.m4 (gl_WCTYPE_H): Determine HAVE_WCTYPE_T, HAVE_WCTRANS_T.
88043         (gl_WCTYPE_H_DEFAULTS): Initialize HAVE_WCTYPE_T, HAVE_WCTRANS_T.
88044         * modules/wctype-h (Makefile.am): Substitute HAVE_WCTYPE_T,
88045         HAVE_WCTRANS_T.
88046         * tests/test-wctype-h.c: Check that wctype_t and wctrans_t are defined.
88048 2011-02-09  Paul Eggert  <eggert@cs.ucla.edu>
88050         flock: fix license typo
88052         * lib/flock.c: Fix typo in license.  One of the "Lesser"s was
88053         omitted.
88055 2011-02-08  Bruno Haible  <bruno@clisp.org>
88057         Split large sed scripts, for HP-UX sed.
88058         * modules/math (Makefile.am): Split sed scripts around 50 sed commands,
88059         to avoid HP-UX limit of 99 commands, in the near future.
88060         * modules/stdlib (Makefile.am): Likewise.
88061         * modules/unistd (Makefile.am): Likewise.
88062         * modules/wchar (Makefile.am): Likewise.
88063         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
88064         Suggestion by Ralf Wildenhues <Ralf.Wildenhues@gmx.de> in
88065         <http://lists.gnu.org/r/bug-gnulib/2010-01/msg00216.html>.
88067 2011-02-08  Paul Eggert  <eggert@cs.ucla.edu>
88068             Bruno Haible  <bruno@clisp.org>
88070         stdlib: improve random_r modularization
88071         * lib/stdlib.in.h: Encapsulate all the stuff having to do with
88072         random_r inside "#if @GNULIB_RANDOM_R@", so that it's clearer that
88073         you also need the random_r module to get this material right.
88074         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Move check for random.h here ...
88075         * m4/stdlib_h.m4 (gl_STDLIB_H): ... from here.
88076         (gl_STDLIB_H_DEFAULTS): Default HAVE_RANDOM_H to 1, and AC_SUBST it.
88078 2011-02-08  Paul Eggert  <eggert@cs.ucla.edu>
88080         stdlib: don't depend on stdint
88081         * lib/stdlib.in.h: Don't include <stdint.h> merely because
88082         GNULIB_POSIXCHECK is defined.  GNULIB_POSIXCHECK seems to
88083         be independent of whether stdint.h is needed.
88084         * m4/random_r.m4 (gl_FUNC_RANDOM_R): Check for struct random_data
88085         here, instead of ...
88086         * m4/stdlib_h.m4 (gl_STDLIB_H): ... here.  Applications that need
88087         struct random_data should be using the random_r module, not just
88088         the stdlib module (which wouldn't make sense: what package needs
88089         just struct random_data without also needing random_r?).
88090         * modules/stdlib (Depends-on): Remove stdint.
88092         getloadavg: don't depend on c-strtod, cloexec, fcntl-safer
88093         See the thread rooted at
88094         <http://lists.gnu.org/r/bug-gnulib/2011-02/msg00090.html>.
88095         * lib/getloadavg.c: Do not include c-strtod.h, cloexec.h, or fcntl--.h.
88096         Include <fcntl.h> only if (defined __linux__ || defined __CYGWIN__
88097         || defined SUNOS_5 || (defined LOAD_AVE_TYPE && !  defined
88098         __VMS)); previously it was always included (via fcntl--.h).
88099         (getloadavg): Do not use c_strtod.  Instead, approximate it by
88100         hand; this is good enough for load averages.  Also, do not use
88101         set_cloexec_flag; instead, use the O_CLOEXEC and F_DUPFD_CLOEXEC
88102         flags directly if available and don't bother otherwise.  (Packages
88103         that need the extra reliability should use the modules that define
88104         these flags on older platforms that lack them.)
88105         * modules/getloadavg (Depends-on): Remove c-strtod, cloexec,
88106         fcntl-safer.
88108 2011-02-08  Jim Meyering  <meyering@redhat.com>
88110         di-set.h, ino-map.h: add multiple-inclusion guard
88111         Technically, the guard is required only for ino-map.h, due to its
88112         INO_MAP_INSERT_FAILURE definition, but do both for consistency.
88113         * lib/di-set.h: Add file-spanning #ifndef _GL_DI_SET_H.
88114         * lib/ino-map.h: Likewise.
88116 2011-02-06  Bruno Haible  <bruno@clisp.org>
88118         iswblank: Ensure declaration on glibc systems.
88119         * m4/iswblank.m4 (gl_FUNC_ISWBLANK): Require gl_USE_SYSTEM_EXTENSIONS.
88120         * modules/iswblank (Dependencies): Add 'extensions'.
88121         * doc/posix-functions/iswblank.texi: Document the glibc problem.
88123 2011-02-06  Bruno Haible  <bruno@clisp.org>
88125         New module 'iswblank'.
88126         * lib/wctype.in.h (iswblank): Don't declare if GNULIB_ISWBLANK is 0.
88127         * modules/iswblank: New file.
88128         * modules/wctype-h (Files): Remove lib/iswblank.c.
88129         (Makefile.am): Substitute GNULIB_ISWBLANK.
88130         * m4/iswblank.m4: New file, partially extracted from m4/wctype_h.m4.
88131         * m4/wctype_h.m4 (gl_WCTYPE_MODULE_INDICATOR): New macro.
88132         (gl_WCTYPE_H_DEFAULTS): New macro.
88133         (gl_WCTYPE_H): Require it. Remove iswblank related code.
88134         * modules/iswblank-tests: New file.
88135         * tests/test-iswblank.c: New file, extraced from tests/test-wctype-h.c.
88136         * tests/test-wctype-h.c (main): Remove iswblank tests.
88137         * tests/test-wctype-h-c++.cc: Guard the signature test of iswblank.
88138         * doc/posix-functions/iswblank.texi: Mention module 'iswblank' instead
88139         of 'wctype-h'.
88140         * NEWS: Mention the change.
88141         * modules/mbchar (Depends-on): Add iswblank.
88143 2011-02-08  Bruno Haible  <bruno@clisp.org>
88145         di-set tests: Refactor.
88146         * tests/test-di-set.c: Include di-set.h early. Include macros.h. Drop
88147         unnecessary includes.
88148         (ASSERT): Remove macro.
88149         (main): Make C90 compliant by avoiding variable declaration after
88150         statement.
88151         * modules/di-set-tests (Files): Add tests/macros.h.
88153 2011-02-08  Bruno Haible  <bruno@clisp.org>
88155         ino-map tests: Refactor.
88156         * tests/test-ino-map.c: Include ino-map.h early. Include macros.h. Drop
88157         unnecessary includes.
88158         (ASSERT): Remove macro.
88159         (main): Make C90 compliant by avoiding variable declaration after
88160         statement.
88161         * modules/ino-map-tests (Files): Add tests/macros.h.
88163 2011-02-08  Jim Meyering  <meyering@redhat.com>
88165         di-set: add "const" to a cast
88166         * lib/di-set.c (di_set_insert): Cast hash_insert0 argument to
88167         "(void const *)", not "(void *)".  Spotted by Bruno Haible.
88169 2011-02-06  Bruno Haible  <bruno@clisp.org>
88171         Rename module 'wctype' to 'wctype-h'.
88172         * modules/wctype-h: Renamed from modules/wctype.
88173         * modules/wctype: Simplyfy to a redirection to 'wctype-h'.
88174         * modules/wctype-h-tests: Renamed from modules/wctype-tests.
88175         (Files, Depends-on, Makefile.am): Update.
88176         * modules/wctype-h-c++-tests: Renamed from modules/wctype-c++-tests.
88177         (Files, Makefile.am): Update.
88178         * tests/test-wctype-h.c: Renamed from tests/test-wctype.c.
88179         * tests/test-wctype-h-c++.cc: Renamed from tests/test-wctype-c++.cc.
88180         * doc/posix-headers/wctype.texi: Update.
88181         * doc/posix-functions/iswalnum.texi: Update.
88182         * doc/posix-functions/iswalpha.texi: Update.
88183         * doc/posix-functions/iswblank.texi: Update.
88184         * doc/posix-functions/iswcntrl.texi: Update.
88185         * doc/posix-functions/iswdigit.texi: Update.
88186         * doc/posix-functions/iswgraph.texi: Update.
88187         * doc/posix-functions/iswlower.texi: Update.
88188         * doc/posix-functions/iswprint.texi: Update.
88189         * doc/posix-functions/iswpunct.texi: Update.
88190         * doc/posix-functions/iswspace.texi: Update.
88191         * doc/posix-functions/iswupper.texi: Update.
88192         * doc/posix-functions/iswxdigit.texi: Update.
88193         * doc/posix-functions/towlower.texi: Update.
88194         * doc/posix-functions/towupper.texi: Update.
88195         * NEWS: Mention the change.
88196         * modules/fnmatch (Dependencies): Add wctype-h, remove wctype.
88197         * modules/mbchar (Dependencies): Likewise.
88198         * modules/mbswidth (Dependencies): Likewise.
88199         * modules/quotearg (Dependencies): Likewise.
88200         * modules/regex (Dependencies): Likewise.
88201         * modules/wcscasecmp (Dependencies): Likewise.
88202         * modules/wcsncasecmp (Dependencies): Likewise.
88203         * modules/wcwidth (Dependencies): Likewise.
88205 2011-02-06  Bruno Haible  <bruno@clisp.org>
88207         New module 'wcswidth'.
88208         * modules/wcswidth: New file.
88209         * lib/wchar.in.h (wcswidth): New declaration.
88210         * lib/wcswidth.c: New file.
88211         * lib/wcswidth-impl.h: New file, from libutf8 with modifications.
88212         * m4/wcswidth.m4: New file.
88213         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcswidth is declared.
88214         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSWIDTH, HAVE_WCSWIDTH,
88215         REPLACE_WCSWIDTH.
88216         * modules/wchar (Makefile.am): Substitute GNULIB_WCSWIDTH,
88217         HAVE_WCSWIDTH, REPLACE_WCSWIDTH.
88218         * tests/test-wchar-c++.cc: Test the declaration of wcswidth.
88219         * doc/posix-functions/wcswidth.texi: Mention the new module.
88221 2011-02-06  Bruno Haible  <bruno@clisp.org>
88223         New module 'wcstok'.
88224         * modules/wcstok: New file.
88225         * lib/wchar.in.h (wcstok): New declaration.
88226         * lib/wcstok.c: New file.
88227         * lib/wcstok-impl.h: New file, from libutf8 with modifications.
88228         * m4/wcstok.m4: New file.
88229         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcstok is declared.
88230         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSTOK, HAVE_WCSTOK.
88231         * modules/wchar (Makefile.am): Substitute GNULIB_WCSTOK, HAVE_WCSTOK.
88232         * tests/test-wchar-c++.cc: Test the declaration of wcstok.
88233         * doc/posix-functions/wcstok.texi: Mention the new module.
88235 2011-02-06  Bruno Haible  <bruno@clisp.org>
88237         New module 'wcsstr'.
88238         * modules/wcsstr: New file.
88239         * lib/wchar.in.h (wcsstr): New declaration.
88240         * lib/wcsstr.c: New file.
88241         * lib/wcsstr-impl.h: New file, from libutf8 with modifications.
88242         * m4/wcsstr.m4: New file.
88243         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsstr is declared.
88244         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSSTR, HAVE_WCSSTR.
88245         * modules/wchar (Makefile.am): Substitute GNULIB_WCSSTR, HAVE_WCSSTR.
88246         * tests/test-wchar-c++.cc: Test the declaration of wcsstr.
88247         * doc/posix-functions/wcsstr.texi: Mention the new module.
88249 2011-02-06  Bruno Haible  <bruno@clisp.org>
88251         New module 'wcspbrk'.
88252         * modules/wcspbrk: New file.
88253         * lib/wchar.in.h (wcspbrk): New declaration.
88254         * lib/wcspbrk.c: New file.
88255         * lib/wcspbrk-impl.h: New file, from libutf8 with modifications.
88256         * m4/wcspbrk.m4: New file.
88257         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcspbrk is declared.
88258         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSPBRK, HAVE_WCSPBRK.
88259         * modules/wchar (Makefile.am): Substitute GNULIB_WCSPBRK, HAVE_WCSPBRK.
88260         * tests/test-wchar-c++.cc: Test the declaration of wcspbrk.
88261         * doc/posix-functions/wcspbrk.texi: Mention the new module.
88263 2011-02-06  Bruno Haible  <bruno@clisp.org>
88265         New module 'wcsspn'.
88266         * modules/wcsspn: New file.
88267         * lib/wchar.in.h (wcsspn): New declaration.
88268         * lib/wcsspn.c: New file.
88269         * lib/wcsspn-impl.h: New file, from libutf8 with modifications.
88270         * m4/wcsspn.m4: New file.
88271         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsspn is declared.
88272         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSSPN, HAVE_WCSSPN.
88273         * modules/wchar (Makefile.am): Substitute GNULIB_WCSSPN, HAVE_WCSSPN.
88274         * tests/test-wchar-c++.cc: Test the declaration of wcsspn.
88275         * doc/posix-functions/wcsspn.texi: Mention the new module.
88277 2011-02-06  Bruno Haible  <bruno@clisp.org>
88279         New module 'wcscspn'.
88280         * modules/wcscspn: New file.
88281         * lib/wchar.in.h (wcscspn): New declaration.
88282         * lib/wcscspn.c: New file.
88283         * lib/wcscspn-impl.h: New file, from libutf8 with modifications.
88284         * m4/wcscspn.m4: New file.
88285         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscspn is declared.
88286         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCSPN, HAVE_WCSCSPN.
88287         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCSPN, HAVE_WCSCSPN.
88288         * tests/test-wchar-c++.cc: Test the declaration of wcscspn.
88289         * doc/posix-functions/wcscspn.texi: Mention the new module.
88291 2011-02-06  Bruno Haible  <bruno@clisp.org>
88293         New module 'wcsrchr'.
88294         * modules/wcsrchr: New file.
88295         * lib/wchar.in.h (wcsrchr): New declaration.
88296         * lib/wcsrchr.c: New file.
88297         * lib/wcsrchr-impl.h: New file, from libutf8 with modifications.
88298         * m4/wcsrchr.m4: New file.
88299         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsrchr is declared.
88300         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSRCHR, HAVE_WCSRCHR.
88301         * modules/wchar (Makefile.am): Substitute GNULIB_WCSRCHR, HAVE_WCSRCHR.
88302         * tests/test-wchar-c++.cc: Test the declaration of wcsrchr.
88303         * doc/posix-functions/wcsrchr.texi: Mention the new module.
88305 2011-02-06  Bruno Haible  <bruno@clisp.org>
88307         New module 'wcschr'.
88308         * modules/wcschr: New file.
88309         * lib/wchar.in.h (wcschr): New declaration.
88310         * lib/wcschr.c: New file.
88311         * lib/wcschr-impl.h: New file, from libutf8 with modifications.
88312         * m4/wcschr.m4: New file.
88313         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcschr is declared.
88314         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCHR, HAVE_WCSCHR.
88315         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCHR, HAVE_WCSCHR.
88316         * tests/test-wchar-c++.cc: Test the declaration of wcschr.
88317         * doc/posix-functions/wcschr.texi: Mention the new module.
88319 2011-02-06  Bruno Haible  <bruno@clisp.org>
88321         New module 'wcsdup'.
88322         * modules/wcsdup: New file.
88323         * lib/wchar.in.h (wcsdup): New declaration.
88324         * lib/wcsdup.c: New file.
88325         * lib/wcsdup-impl.h: New file, from libutf8 with modifications.
88326         * m4/wcsdup.m4: New file.
88327         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsdup is declared.
88328         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSDUP, HAVE_WCSDUP.
88329         * modules/wchar (Makefile.am): Substitute GNULIB_WCSDUP, HAVE_WCSDUP.
88330         * tests/test-wchar-c++.cc: Test the declaration of wcsdup.
88331         * doc/posix-functions/wcsdup.texi: Mention the new module.
88333 2011-02-06  Bruno Haible  <bruno@clisp.org>
88335         New module 'wcsxfrm'.
88336         * modules/wcsxfrm: New file.
88337         * lib/wchar.in.h (wcsxfrm): New declaration.
88338         * lib/wcsxfrm.c: New file.
88339         * lib/wcsxfrm-impl.h: New file.
88340         * m4/wcsxfrm.m4: New file.
88341         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsxfrm is declared.
88342         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSXFRM, HAVE_WCSXFRM.
88343         * modules/wchar (Makefile.am): Substitute GNULIB_WCSXFRM, HAVE_WCSXFRM.
88344         * tests/test-wchar-c++.cc: Test the declaration of wcsxfrm.
88345         * doc/posix-functions/wcsxfrm.texi: Mention the new module.
88347 2011-02-06  Bruno Haible  <bruno@clisp.org>
88349         New module 'wcscoll'.
88350         * modules/wcscoll: New file.
88351         * lib/wchar.in.h (wcscoll): New declaration.
88352         * lib/wcscoll.c: New file.
88353         * lib/wcscoll-impl.h: New file.
88354         * m4/wcscoll.m4: New file.
88355         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscoll is declared.
88356         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCOLL, HAVE_WCSCOLL.
88357         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCOLL, HAVE_WCSCOLL.
88358         * tests/test-wchar-c++.cc: Test the declaration of wcscoll.
88359         * doc/posix-functions/wcscoll.texi: Mention the new module.
88361 2011-02-06  Bruno Haible  <bruno@clisp.org>
88363         New module 'wcsncasecmp'.
88364         * modules/wcsncasecmp: New file.
88365         * lib/wchar.in.h (wcsncasecmp): New declaration.
88366         * lib/wcsncasecmp.c: New file.
88367         * lib/wcsncasecmp-impl.h: New file, from libutf8 with modifications.
88368         * m4/wcsncasecmp.m4: New file.
88369         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncasecmp is declared.
88370         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCASECMP, HAVE_WCSNCASECMP.
88371         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCASECMP,
88372         HAVE_WCSNCASECMP.
88373         * tests/test-wchar-c++.cc: Test the declaration of wcsncasecmp.
88374         * doc/posix-functions/wcsncasecmp.texi: Mention the new module.
88376 2011-02-06  Bruno Haible  <bruno@clisp.org>
88378         New module 'wcscasecmp'.
88379         * modules/wcscasecmp: New file.
88380         * lib/wchar.in.h (wcscasecmp): New declaration.
88381         * lib/wcscasecmp.c: New file.
88382         * lib/wcscasecmp-impl.h: New file, from libutf8 with modifications.
88383         * m4/wcscasecmp.m4: New file.
88384         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscasecmp is declared.
88385         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCASECMP, HAVE_WCSCASECMP.
88386         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCASECMP,
88387         HAVE_WCSCASECMP.
88388         * tests/test-wchar-c++.cc: Test the declaration of wcscasecmp.
88389         * doc/posix-functions/wcscasecmp.texi: Mention the new module.
88391 2011-02-05  Bruno Haible  <bruno@clisp.org>
88393         New module 'wcsncmp'.
88394         * modules/wcsncmp: New file.
88395         * lib/wchar.in.h (wcsncmp): New declaration.
88396         * lib/wcsncmp.c: New file.
88397         * lib/wcsncmp-impl.h: New file, from libutf8 with modifications.
88398         * m4/wcsncmp.m4: New file.
88399         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncmp is declared.
88400         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCMP, HAVE_WCSNCMP.
88401         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCMP, HAVE_WCSNCMP.
88402         * tests/test-wchar-c++.cc: Test the declaration of wcsncmp.
88403         * doc/posix-functions/wcsncmp.texi: Mention the new module.
88405 2011-02-05  Bruno Haible  <bruno@clisp.org>
88407         New module 'wcscmp'.
88408         * modules/wcscmp: New file.
88409         * lib/wchar.in.h (wcscmp): New declaration.
88410         * lib/wcscmp.c: New file.
88411         * lib/wcscmp-impl.h: New file, from libutf8 with modifications.
88412         * m4/wcscmp.m4: New file.
88413         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscmp is declared.
88414         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCMP, HAVE_WCSCMP.
88415         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCMP, HAVE_WCSCMP.
88416         * tests/test-wchar-c++.cc: Test the declaration of wcscmp.
88417         * doc/posix-functions/wcscmp.texi: Mention the new module.
88419 2011-02-05  Bruno Haible  <bruno@clisp.org>
88421         New module 'wcsncat'.
88422         * modules/wcsncat: New file.
88423         * lib/wchar.in.h (wcsncat): New declaration.
88424         * lib/wcsncat.c: New file.
88425         * lib/wcsncat-impl.h: New file, from libutf8 with modifications.
88426         * m4/wcsncat.m4: New file.
88427         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncat is declared.
88428         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCAT, HAVE_WCSNCAT.
88429         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCAT, HAVE_WCSNCAT.
88430         * tests/test-wchar-c++.cc: Test the declaration of wcsncat.
88431         * doc/posix-functions/wcsncat.texi: Mention the new module.
88433 2011-02-05  Bruno Haible  <bruno@clisp.org>
88435         New module 'wcscat'.
88436         * modules/wcscat: New file.
88437         * lib/wchar.in.h (wcscat): New declaration.
88438         * lib/wcscat.c: New file.
88439         * lib/wcscat-impl.h: New file, from libutf8 with modifications.
88440         * m4/wcscat.m4: New file.
88441         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscat is declared.
88442         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCAT, HAVE_WCSCAT.
88443         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCAT, HAVE_WCSCAT.
88444         * tests/test-wchar-c++.cc: Test the declaration of wcscat.
88445         * doc/posix-functions/wcscat.texi: Mention the new module.
88447 2011-02-05  Bruno Haible  <bruno@clisp.org>
88449         New module 'wcpncpy'.
88450         * modules/wcpncpy: New file.
88451         * lib/wchar.in.h (wcpncpy): New declaration.
88452         * lib/wcpncpy.c: New file.
88453         * lib/wcpncpy-impl.h: New file, from libutf8 with modifications.
88454         * m4/wcpncpy.m4: New file.
88455         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcpncpy is declared.
88456         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCPNCPY, HAVE_WCPNCPY.
88457         * modules/wchar (Makefile.am): Substitute GNULIB_WCPNCPY, HAVE_WCPNCPY.
88458         * tests/test-wchar-c++.cc: Test the declaration of wcpncpy.
88459         * doc/posix-functions/wcpncpy.texi: Mention the new module.
88461 2011-02-05  Bruno Haible  <bruno@clisp.org>
88463         New module 'wcsncpy'.
88464         * modules/wcsncpy: New file.
88465         * lib/wchar.in.h (wcsncpy): New declaration.
88466         * lib/wcsncpy.c: New file.
88467         * lib/wcsncpy-impl.h: New file, from libutf8 with modifications.
88468         * m4/wcsncpy.m4: New file.
88469         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsncpy is declared.
88470         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNCPY, HAVE_WCSNCPY.
88471         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNCPY, HAVE_WCSNCPY.
88472         * tests/test-wchar-c++.cc: Test the declaration of wcsncpy.
88473         * doc/posix-functions/wcsncpy.texi: Mention the new module.
88475 2011-02-05  Bruno Haible  <bruno@clisp.org>
88477         New module 'wcpcpy'.
88478         * modules/wcpcpy: New file.
88479         * lib/wchar.in.h (wcpcpy): New declaration.
88480         * lib/wcpcpy.c: New file.
88481         * lib/wcpcpy-impl.h: New file, from libutf8 with modifications.
88482         * m4/wcpcpy.m4: New file.
88483         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcpcpy is declared.
88484         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCPCPY, HAVE_WCPCPY.
88485         * modules/wchar (Makefile.am): Substitute GNULIB_WCPCPY, HAVE_WCPCPY.
88486         * tests/test-wchar-c++.cc: Test the declaration of wcpcpy.
88487         * doc/posix-functions/wcpcpy.texi: Mention the new module.
88489 2011-02-05  Bruno Haible  <bruno@clisp.org>
88491         New module 'wcscpy'.
88492         * modules/wcscpy: New file.
88493         * lib/wchar.in.h (wcscpy): New declaration.
88494         * lib/wcscpy.c: New file.
88495         * lib/wcscpy-impl.h: New file, from libutf8 with modifications.
88496         * m4/wcscpy.m4: New file.
88497         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcscpy is declared.
88498         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSCPY, HAVE_WCSCPY.
88499         * modules/wchar (Makefile.am): Substitute GNULIB_WCSCPY, HAVE_WCSCPY.
88500         * tests/test-wchar-c++.cc: Test the declaration of wcscpy.
88501         * doc/posix-functions/wcscpy.texi: Mention the new module.
88503 2011-02-05  Bruno Haible  <bruno@clisp.org>
88505         New module 'wcsnlen'.
88506         * modules/wcsnlen: New file.
88507         * lib/wchar.in.h (wcsnlen): New declaration.
88508         * lib/wcsnlen.c: New file.
88509         * lib/wcsnlen-impl.h: New file, from libutf8 with modifications.
88510         * m4/wcsnlen.m4: New file.
88511         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcsnlen is declared.
88512         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNLEN, HAVE_WCSNLEN.
88513         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNLEN, HAVE_WCSNLEN.
88514         * tests/test-wchar-c++.cc: Test the declaration of wcsnlen.
88515         * doc/posix-functions/wcsnlen.texi: Mention the new module.
88517 2011-02-05  Bruno Haible  <bruno@clisp.org>
88519         New module 'wcslen'.
88520         * modules/wcslen: New file.
88521         * lib/wchar.in.h (wcslen): New declaration.
88522         * lib/wcslen.c: New file.
88523         * lib/wcslen-impl.h: New file, from libutf8 with modifications.
88524         * m4/wcslen.m4: New file.
88525         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wcslen is declared.
88526         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSLEN, HAVE_WCSLEN.
88527         * modules/wchar (Makefile.am): Substitute GNULIB_WCSLEN, HAVE_WCSLEN.
88528         * tests/test-wchar-c++.cc: Test the declaration of wcslen.
88529         * doc/posix-functions/wcslen.texi: Mention the new module.
88531 2011-02-05  Bruno Haible  <bruno@clisp.org>
88533         New module 'wmemset'.
88534         * modules/wmemset: New file.
88535         * lib/wchar.in.h (wmemset): New declaration.
88536         * lib/wmemset.c: New file.
88537         * lib/wmemset-impl.h: New file, from libutf8 with modifications.
88538         * m4/wmemset.m4: New file.
88539         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemset is declared.
88540         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMSET, HAVE_WMEMSET.
88541         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMSET, HAVE_WMEMSET.
88542         * tests/test-wchar-c++.cc: Test the declaration of wmemset.
88543         * doc/posix-functions/wmemset.texi: Mention the new module.
88545 2011-02-05  Bruno Haible  <bruno@clisp.org>
88547         New module 'wmemmove'.
88548         * modules/wmemmove: New file.
88549         * lib/wchar.in.h (wmemmove): New declaration.
88550         * lib/wmemmove.c: New file.
88551         * lib/wmemmove-impl.h: New file, from libutf8 with modifications.
88552         * m4/wmemmove.m4: New file.
88553         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemmove is declared.
88554         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMMOVE, HAVE_WMEMMOVE.
88555         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMMOVE,
88556         HAVE_WMEMMOVE.
88557         * tests/test-wchar-c++.cc: Test the declaration of wmemmove.
88558         * doc/posix-functions/wmemmove.texi: Mention the new module.
88560 2011-02-05  Bruno Haible  <bruno@clisp.org>
88562         New module 'wmemcpy'.
88563         * modules/wmemcpy: New file.
88564         * lib/wchar.in.h (wmemcpy): New declaration.
88565         * lib/wmemcpy.c: New file.
88566         * lib/wmemcpy-impl.h: New file, from libutf8 with modifications.
88567         * m4/wmemcpy.m4: New file.
88568         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemcpy is declared.
88569         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMCPY, HAVE_WMEMCPY.
88570         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMCPY, HAVE_WMEMCPY.
88571         * tests/test-wchar-c++.cc: Test the declaration of wmemcpy.
88572         * doc/posix-functions/wmemcpy.texi: Mention the new module.
88574 2011-02-05  Bruno Haible  <bruno@clisp.org>
88576         New module 'wmemcmp'.
88577         * modules/wmemcmp: New file.
88578         * lib/wchar.in.h (wmemcmp): New declaration.
88579         * lib/wmemcmp.c: New file.
88580         * lib/wmemcmp-impl.h: New file, from libutf8 with modifications.
88581         * m4/wmemcmp.m4: New file.
88582         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemcmp is declared.
88583         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMCMP, HAVE_WMEMCMP.
88584         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMCMP, HAVE_WMEMCMP.
88585         * tests/test-wchar-c++.cc: Test the declaration of wmemcmp.
88586         * doc/posix-functions/wmemcmp.texi: Mention the new module.
88588 2011-02-07  Jim Meyering  <meyering@redhat.com>
88590         di-set, ino-map: new modules, from coreutils
88591         * lib/di-set.c: New file.
88592         * lib/di-set.h: Likewise.
88593         * lib/ino-map.c: Likewise.
88594         * lib/ino-map.h: Likewise.
88595         * modules/di-set: Likewise.
88596         * modules/di-set-tests: Likewise.
88597         * modules/ino-map: Likewise.
88598         * modules/ino-map-tests: Likewise.
88599         * tests/test-di-set.c: Likewise.
88600         * tests/test-ino-map.c: Likewise.
88602 2011-02-06  Paul Eggert  <eggert@cs.ucla.edu>
88604         getloadavg: merge minor changes from Emacs
88606         * lib/getloadavg.c (getloadavg_initialized): More-accurate comment.
88607         (getloadavg): Use memset, not bzero.
88609         2008-07-25  Chong Yidong  <cyd@stupidchicken.com>
88610         * lib/getloadavg.c (nl): Rename to name_list to avoid ncurses.h
88611         clash (bug#86).
88613 2010-11-14  Bruno Haible  <bruno@clisp.org>
88615         Allow multiple gnulib generated replacements to coexist.
88616         * lib/getopt.in.h (struct option): Avoid identical redefinition.
88617         * lib/inttypes.in.h (imaxdiv_t): Likewise.
88618         * lib/langinfo.in.h (nl_item): Likewise.
88619         * lib/math.in.h (_NaN, NAN): Likewise.
88620         * lib/netdb.in.h (struct addrinfo): Likewise.
88621         * lib/poll.in.h (struct pollfd, nfds_t): Likewise.
88622         * lib/pthread.in.h (pthread_t, pthread_attr_t, pthread_barrier_t,
88623         pthread_barrierattr_t, pthread_cond_t, pthread_condattr_t,
88624         pthread_key_t, pthread_mutex_t, pthread_mutexattr_t, pthread_once_t,
88625         pthread_rwlock_t, pthread_rwlockattr_t, pthread_cond_destroy,
88626         pthread_cond_init, pthread_cond_signal, pthread_cond_wait,
88627         pthread_create, pthread_exit, pthread_join, pthread_mutexattr_destroy,
88628         pthread_mutexattr_init, pthread_mutexattr_settype,
88629         pthread_mutex_destroy, pthread_mutex_init, pthread_mutex_lock,
88630         pthread_mutex_trylock, pthread_mutex_unlock, pthread_spinlock_t,
88631         pthread_spin_init, pthread_spin_destroy, pthread_spin_lock,
88632         pthread_spin_trylock, pthread_spin_unlock): Likewise.
88633         * lib/sched.in.h (struct sched_param): Likewise.
88634         * lib/se-selinux.in.h (security_class_t, security_context_t,
88635         is_selinux_enabled, getcon, freecon, getfscreatecon, setfscreatecon,
88636         matchpathcon, getfilecon, lgetfilecon, fgetfilecon, setfilecon,
88637         lsetfilecon, fsetfilecon, security_check_context,
88638         security_check_context_raw, setexeccon, matchpathcon_init_prefix):
88639         Likewise.
88640         * lib/search.in.h (VISIT, _gl_search_compar_fn, _gl_search_action_fn):
88641         Likewise.
88642         * lib/signal.in.h (sig_atomic_t, sigset_t, verify_NSIG_constraint,
88643         _gl_function_taking_int_returning_void_t, union sigval,
88644         struct siginfo_t, siginfo_t, struct sigaction): Likewise.
88645         * lib/spawn.in.h (posix_spawnattr_t, posix_spawn_file_actions_t,
88646         verify_POSIX_SPAWN_USEVFORK_no_overlap): Likewise.
88647         * lib/stdint.in.h (gl_int8_t, gl_uint8_t, gl_int16_t, gl_uint16_t,
88648         gl_int32_t, gl_uint32_t, gl_int64_t, gl_uint64_t, int_least8_t,
88649         uint_least8_t, int_least16_t, uint_least16_t, int_least32_t,
88650         uint_least32_t, int_least64_t, uint_least64_t, gl_int_fast8_t,
88651         gl_uint_fast8_t, gl_int_fast16_t, gl_uint_fast16_t, gl_int_fast32_t,
88652         gl_uint_fast32_t, int_fast64_t, uint_fast64_t, gl_intptr_t,
88653         gl_uintptr_t, intmax_t, uintmax_t, _verify_intmax_size): Likewise.
88654         * lib/stdio.in.h (rpl_fseek, rpl_ftell): Likewise.
88655         * lib/sys_socket.in.h (sa_family_t, struct sockaddr_storage,
88656         socklen_t, rpl_fd_isset): Likewise.
88657         * lib/sys_stat.in.h (rpl_mkdir): Likewise.
88658         * lib/sys_time.in.h (struct timeval): Likewise.
88659         * lib/sys_times.in.h (struct tms): Likewise.
88660         * lib/sys_utsname.in.h (struct utsname):
88661         * lib/time.in.h (struct timespec, __time_t_must_be_integral): Likewise.
88662         * lib/unistd.in.h (getpagesize): Likewise.
88663         * lib/wchar.in.h (mbstate_t): Likewise.
88664         * lib/wctype.in.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
88665         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit,
88666         towlower, towupper): Likewise.
88667         Reported by Sam Steingold <sds@gnu.org>.
88669 2011-02-05  Eric Blake  <eblake@redhat.com>
88671         unsetenv: work around Haiku issues
88672         * m4/setenv.m4 (gl_FUNC_UNSETENV): Also detect Haiku issue.
88673         * doc/posix-functions/unsetenv.texi (unsetenv): Document it.
88675 2010-12-30  Bruce Korb  <bkorb@gnu.org>
88677         libposix: avoid calling error() within libposix
88678         * lib/openat-die.c: remove error module stuff when GNULIB_LIBPOSIX
88679         is defined.
88681 2011-02-05  Eric Blake  <eblake@redhat.com>
88683         strerror_r-posix: port to cygwin
88684         * lib/strerror_r.c (strerror_r) [__CYGWIN__]: Add cygwin
88685         implementation.
88686         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Adjust comment.
88687         * tests/test-strerror_r.c (main): Fix test.
88688         * doc/posix-functions/strerror_r.texi (strerror_r): Document the
88689         issue.
88691 2011-02-05  Bruno Haible  <bruno@clisp.org>
88693         New module 'wmemchr'.
88694         * modules/wmemchr: New file.
88695         * lib/wchar.in.h (wmemchr): New declaration.
88696         * lib/wmemchr.c: New file.
88697         * lib/wmemchr-impl.h: New file, from libutf8 with modifications.
88698         * m4/wmemchr.m4: New file.
88699         * m4/wchar_h.m4 (gl_WCHAR_H): Test whether wmemchr is declared.
88700         (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WMEMCHR, HAVE_WMEMCHR.
88701         * modules/wchar (Makefile.am): Substitute GNULIB_WMEMCHR, HAVE_WMEMCHR.
88702         * tests/test-wchar-c++.cc: Test the declaration of wmemchr.
88703         * doc/posix-functions/wmemchr.texi: Mention the new module.
88705 2011-02-04  Eric Blake  <eblake@redhat.com>
88707         fdopendir: detect FreeBSD bug
88708         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Detect bug.
88709         * doc/posix-functions/fdopendir.texi (fdopendir): Document it.
88711 2011-02-04  Paul Eggert  <eggert@cs.ucla.edu>
88713         stdbool: do not define HAVE_STDBOOL_H
88714         * m4/stdbool.m4 (AC_CHECK_HEADER_STDBOOL): Renamed from
88715         AC_HEADER_STDBOOL.  All uses changed.  Do not define
88716         HAVE_STDBOOL_H, as gnulib does not need this.  This change is
88717         imported from the latest Autoconf git.  It was motivated by Emacs,
88718         which uses gnulib but does not need HAVE_STDBOOL_H.
88720 2011-02-04  Bruno Haible  <bruno@clisp.org>
88722         wcsnrtombs: Prepare for new module wwcsnrtombs.
88723         * lib/wcsnrtombs-impl.h: New file, extracted from lib/wcsnrtombs.c.
88724         * lib/wcsnrtombs.c: Include it.
88725         * modules/wcsnrtombs (Files): Add lib/wcsnrtombs-impl.h.
88727         wcsrtombs: Prepare for new module wwcsrtombs.
88728         * lib/wcsrtombs-impl.h: New file, extracted from lib/wcsrtombs.c.
88729         * lib/wcsrtombs.c: Include it.
88730         * modules/wcsrtombs (Files): Add lib/wcsrtombs-impl.h.
88732         mbsnrtowcs: Prepare for new module mbsnrtowwcs.
88733         * lib/mbsnrtowcs-impl.h: New file, extracted from lib/mbsnrtowcs.c.
88734         * lib/mbsnrtowcs.c: Include it.
88735         * modules/mbsnrtowcs (Files): Add lib/mbsnrtowcs-impl.h.
88737         mbsrtowcs: Prepare for new module mbsrtowwcs.
88738         * lib/mbsrtowcs-impl.h: New file, extracted from lib/mbsrtowcs.c.
88739         * lib/mbsrtowcs.c: Include it.
88740         * modules/mbsrtowcs (Files): Add lib/mbsrtowcs-impl.h.
88742 2011-02-04  Bruno Haible  <bruno@clisp.org>
88744         vasnprintf: Reduce use of malloc for small format strings.
88745         * lib/printf-args.h (N_DIRECT_ALLOC_ARGUMENTS): New macro.
88746         (arguments): Add room for the first 7 arguments.
88747         * lib/printf-parse.h (N_DIRECT_ALLOC_DIRECTIVES): New macro.
88748         (char_directives, u8_directives, u16_directives, u32_directives): Add
88749         room for the first 7 directives.
88750         * lib/printf-parse.c: Include <string.h>.
88751         (PRINTF_PARSE): Change memory handling code so that it uses the first
88752         7 preallocated elements in an 'arguments' or 'DIRECTIVES' struct.
88753         * lib/vasnprintf.c (VASNPRINTF): Update memory handling code.
88754         Reported by Pádraig Brady <P@draigbrady.com>.
88756 2011-01-31  Eric Blake  <eblake@redhat.com>
88758         dup2: work around Haiku bug
88759         * m4/dup2.m4 (gl_FUNC_DUP2): Test for bug.
88760         * lib/dup2.c (rpl_dup2) [!WIN32]: Add workaround.
88761         * doc/posix-functions/dup2.texi (dup2): Document the bug.
88762         * tests/test-dup2.c (main): Enhance test.
88764 2011-01-31  Simon Josefsson  <simon@josefsson.org>
88766         doc: off_t is not available in eglibc 2.11.2 stdio.h.
88767         * doc/posix-headers/stdio.texi (stdio.h): Mention that off_t isn't
88768         declared by eglibc 2.11.2.
88769         * lib/stdio.in.h: Likewise.
88771 2011-01-31  Eric Blake  <eblake@redhat.com>
88773         ignore-value: add missing test dependency
88774         * tests/test-ignore-value.c: Revert previous change; stdio.h
88775         provides off_t.
88776         * modules/ignore-value-tests (Depends-on): Add missing dependency.
88778 2011-01-30  Paul Eggert  <eggert@cs.ucla.edu>
88780         mktime: clarify long_int width checking
88781         * lib/mktime.c (long_int_is_wide_enough): Move this assertion to
88782         the top level, to make it clearer that the assumption about
88783         long_int width is being checked.  See
88784         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00554.html>.
88786 2011-01-30  Simon Josefsson  <simon@josefsson.org>
88788         ignore-value: Fix self-test.
88789         * tests/test-ignore-value.c: Include sys/types.h for off_t.
88791 2011-01-29  Paul Eggert  <eggert@cs.ucla.edu>
88793         TYPE_MAXIMUM: avoid theoretically undefined behavior
88794         * lib/intprops.h (TYPE_MINIMUM, TYPE_MAXIMUM): Do not shift a
88795         negative number, which the C Standard says has undefined behavior.
88796         In practice this is not a problem, but might as well do it by the book.
88797         Reported by Rich Felker and Eric Blake; see
88798         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00493.html>.
88799         * lib/strtol.c (TYPE_MINIMUM, TYPE_MAXIMUM): Likewise.
88800         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
88801         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
88802         * m4/parse-datetime.m4 (gl_PARSE_DATETIME): Likewise.
88803         * m4/stdint.m4 (gl_STDINT_H): Likewise.
88804         * lib/mktime.c (TYPE_MAXIMUM): Redo slightly to match the others.
88806         mktime: #undef mktime before #defining it
88807         * lib/mktime.c (mktime) [DEBUG]: #undef mktime before #defining it.
88809         mktime: systematically normalize tm_isdst comparisons
88810         * lib/mktime.c (isdst_differ): New function.
88811         (__mktime_internal): Use it systematically for all isdst comparisons.
88812         This completes the fix for libc BZ #6723, and removes the need for
88813         normalizing tm_isdst.  See
88814         <http://sourceware.org/bugzilla/show_bug.cgi?id=6723>
88815         (not_equal_tm) [DEBUG]: Use isdst_differ here, too.
88817         mktime: fix some integer overflow issues and sidestep the rest
88819         This was prompted by a bug report by Benjamin Lindner for MinGW
88820         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00472.html>.
88821         His bug is due to signed integer overflow (0 - INT_MIN), and I
88822         I scanned through mktime.c looking for other integer overflow
88823         problems, fixing all the bugs I found.
88825         Although the C Standard says the resulting code is still not safe
88826         in the presence of integer overflow, in practice it should be good
88827         enough for all real-world two's-complement implementations, except
88828         for debugging environments that deliberately trap on integer
88829         overflow (e.g., gcc -ftrapv).
88831         * lib/mktime.c (WRAPV): New macro.
88832         (SHR): Also check that long_int and time_t shift right in the
88833         usual way, before using the fast-but-unportable method.
88834         (TYPE_ONES_COMPLEMENT, TYPE_SIGNED_MAGNITUDE): Remove, no longer
88835         used.  The code already assumed two's complement, so there's
88836         no need to test for alternatives.  All uses removed.
88837         (TYPE_MAXIMUM): Don't rely here on overflow behavior not defined by
88838         the C standard.  Problem reported by Rich Felker in
88839         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00488.html>.
88840         (twos_complement_arithmetic): Also check long_int and time_t.
88841         (time_t_avg, time_t_add_ok, time_t_int_add_ok): New functions.
88842         (guess_time_tm, ranged_convert, __mktime_internal): Use them.
88843         (__mktime_internal): Avoid integer overflow with unary subtraction
88844         in two instances where -1 - X is an adequate replacement for -X,
88845         since the calculations are approximate.
88847 2011-01-29  Eric Blake  <eblake@redhat.com>
88849         mktime: avoid infinite loop
88850         * m4/mktime.m4 (AC_FUNC_MKTIME): Avoid overflow on possibly-signed
88851         type; behavior is still undefined but portable to all known targets.
88852         Reported by Rich Felker.
88854 2011-01-29  Simon Josefsson  <simon@josefsson.org>
88856         rename, unlink, same-inode: Relicense.
88857         * modules/rename (License): Relax from LGPLv3+ to LGPLv2+.
88858         * modules/unlink (License): Likewise.
88859         * modules/same-inode (License): Likewise.
88861 2011-01-28  Paul Eggert  <eggert@cs.ucla.edu>
88863         mktime: avoid problems on NetBSD 5 / i386
88864         * lib/mktime.c (long_int): New type.  This works around a problem
88865         on NetBSD 5 / i386, where 'long int' and 'int' are both 32 bits
88866         but time_t is 64 bits, and where I expect the existing code is
88867         wrong in some cases.
88868         (leapyear, ydhms_diff, guess_time_tm, __mktime_internal): Use it.
88869         (ydhms_diff): Bring back the compile-time check for wide-enough
88870         year and yday.
88872         mktime: fix misspelling in comment
88873         * lib/mktime.c (__mktime_internal): Fix misspelling in comment.
88874         This merges all recent glibc changes of importance.
88876 2011-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
88878         move-if-change: cope with concurrent mv of identical file.
88879         * build-aux/move-if-change (CMPPROG): Accept environment
88880         variable as an override for `cmp'.
88881         (usage): Document CMPPROG.
88882         Adjust comparison to drop stdout.  Cope with failure of mv if
88883         the target file exists and is identical to the source, for
88884         parallel builds.
88885         Report from H.J. Lu against binutils in PR binutils/12283.
88887 2011-01-28  Bruce Korb  <bkorb@gnu.org>
88889         * users.txt: Mention sharutils.
88891 2011-01-28  Simon Josefsson  <simon@josefsson.org>
88893         * users.txt: Mention OATH Toolkit.
88895 2011-01-27  Bruno Haible  <bruno@clisp.org>
88897         Prepare for supporting FreeBSD 10.
88898         * build-aux/config.libpath: Remove handling of freebsd1*.
88900 2011-01-27  Gerald Pfeifer  <gerald@pfeifer.com>  (tiny change)
88902         Prepare for supporting FreeBSD 10.
88903         * build-aux/config.rpath: Remove handling of freebsd1* which soon would
88904         match FreeBSD 10.0.
88906 2011-01-27  Bruno Haible  <bruno@clisp.org>
88908         vma-iter, get-rusage-as: Add OpenBSD support.
88909         * modules/vma-iter (configure.ac): Test for mquery.
88910         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define also on OpenBSD.
88911         * lib/vma-iter.c: Include <sys/mman.h>.
88912         (vma_iterate): Add an implementation based on mquery().
88913         * lib/resource-ext.h (get_rusage_as): Update comments.
88914         * lib/get-rusage-as.c: Likewise.
88915         * lib/get-rusage-data.c: Likewise.
88917 2011-01-26  Karl Berry  <karl@gnu.org>
88919         * doc/Makefile (lang_env, makeinfo_prog, manual_opts): new
88920         variables to make it easier to override the makeinfo program used.
88922 2011-01-26  Eric Blake  <eblake@redhat.com>
88924         fcntl: work around Haiku F_DUPFD bugs
88925         * m4/fcntl.m4 (gl_FUNC_FCNTL): Also catch Haiku errno bug.
88926         * lib/fcntl.c (rpl_fcntl) [F_DUPFD]: Work around Haiku losing
88927         cloexec bit on duplication.
88928         * doc/posix-functions/fcntl.texi (fcntl): Document the bug.
88930 2011-01-26  Bruno Haible  <bruno@clisp.org>
88932         Enable memory leak tests on AIX.
88933         * tests/test-dprintf-posix2.c (main): Don't skip the test on AIX.
88934         * tests/test-fprintf-posix3.c (main): Likewise.
88936 2011-01-26  Bruno Haible  <bruno@clisp.org>
88938         Tests for module 'get-rusage-data'.
88939         * modules/get-rusage-data-tests: New file.
88940         * tests/test-get-rusage-data.c: New file.
88942         New module 'get-rusage-data'.
88943         * lib/resource-ext.h (get_rusage_data): New declaration.
88944         * lib/get-rusage-data.c: New file.
88945         * modules/get-rusage-data: New file.
88947 2011-01-25  Bruno Haible  <bruno@clisp.org>
88949         get-rusage-as: Allow for easier testing.
88950         * lib/resource-ext.h (get_rusage_as): Add comment.
88951         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit): Define always.
88952         (main): New function for interactive testing.
88954 2011-01-25  Bruno Haible  <bruno@clisp.org>
88956         vma-iter: Treat Haiku like BeOS.
88957         * lib/vma-iter.h (VMA_ITERATE_SUPPORTED): Define on Haiku as well.
88958         * lib/vma-iter.c (vma_iterate) [Haiku]: Use the BeOS API.
88960 2011-01-25  Eric Blake  <eblake@redhat.com>
88962         c-stack: fix regression on cygwin when libsigsegv is present
88963         * lib/c-stack.c (die): Don't flatten error if sigsegv is present.
88965 2011-01-24  Bruno Haible  <bruno@clisp.org>
88967         vma-iter: Avoid empty intervals.
88968         * lib/vma-iter.c (vma_iterate) [IRIX, OSF/1]: Don't call the callback
88969         on an empty interval.
88971 2011-01-24  Jim Meyering  <meyering@redhat.com>
88973         u64: remove unnecessary #include
88974         * lib/u64.h: Don't include <stddef.h>.  It was not used.
88976 2011-01-23  Paul Eggert  <eggert@cs.ucla.edu>
88978         Allow the user to avoid the HAVE_RAW_DECL_* macros.
88979         * m4/gnulib-common.m4 (gl_ASSERT_NO_GNULIB_POSIXCHECK): New macro.
88981 2011-01-23  Bruno Haible  <bruno@clisp.org>
88983         New module 'vma-iter'.
88984         * lib/vma-iter.h: New file.
88985         * lib/vma-iter.c: New file, based on lib/get-rusage-as.c.
88986         * modules/vma-iter: New file.
88987         * lib/get-rusage-as.c: Include vma-iter.h. Don't include system headers
88988         for get_rusage_as_via_iterator.
88989         (vma_iterate_callback): New function.
88990         (get_rusage_as_via_iterator): Rewritten to use vma_iterate.
88991         * modules/get-rusage-as (Depends-on): Add vma-iter.
88993 2011-01-23  Bruno Haible  <bruno@clisp.org>
88995         uninorm: Tweak includes.
88996         * lib/uninorm/normalize-internal.h: Don't include <stddef.h>.
88997         Reported by Jim Meyering.
88999 2011-01-23  Bruno Haible  <bruno@clisp.org>
89001         get-rusage-as: Improve on NetBSD.
89002         * lib/get-rusage-as.c (get_rusage_as_via_iterator): On NetBSD, use
89003         /proc, like on FreeBSD.
89005 2011-01-23  Jim Meyering  <meyering@redhat.com>
89007         xreadlink.h: remove unnecessary #include
89008         * lib/xreadlink.h: Don't include <stddef.h>.  It was not used.
89010         maint.mk: add syntax-check rule: detect unnecessary #include <stddef.h>
89011         * top/maint.mk (sc_prohibit_stddef_without_use): New rule.
89013 2011-01-23  Bruno Haible  <bruno@clisp.org>
89015         get-rusage-as: Fix bug.
89016         * lib/get-rusage-as.c (get_rusage_as_via_setrlimit): Restore the
89017         original limit when aborting the first loop.
89019 2011-01-23  Bruno Haible  <bruno@clisp.org>
89021         wctype: Ensure valid C syntax.
89022         * m4/wctype_h.m4 (gl_WCTYPE_H): Invoke gl_CHECK_NEXT_HEADERS
89023         unconditionally, instead of gl_NEXT_HEADERS conditionally.
89025 2011-01-21  Paul Eggert  <eggert@cs.ucla.edu>
89027         getopt: omit HAVE_OPTRESET, HAVE_GETOPT_CLIP from config.h
89028         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not put the
89029         symbols HAVE_OPTRESET and HAVE_GETOPT_CLIP into config.h,
89030         as they are needed only for configure's test case.
89031         This removes two unnecessary symbols from config.h.
89033         gl_CHECK_NEXT_HEADERS implies AC_CHECK_HEADERS_ONCE
89034         * m4/include_next.m4 (gl_CHECK_HEXT_HEADERS): Document this.
89035         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Don't bother to invoke
89036         AC_CHECK_HEADERS_ONCE on a header that we also invoke
89037         gl_CHECK_NEXT_HEADERS on, since the latter invokes the former.
89038         * m4/netdb_h.m4 (gl_HEADER_NETDB): Likewise.
89039         * m4/pthread.m4 (gl_PTHREAD_CHECK): Likewise.
89040         * m4/sched_h.m4 (gl_SCHED_H): Likewise.
89041         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
89042         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
89043         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Likewise.
89044         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
89045         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
89046         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
89047         * m4/termios_h.m4 (gl_TERMIOS_H): Likewise.
89048         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
89049         * m4/wchar_h.m4 (gl_WCHAR_H): Likewise.
89050         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
89052 2011-01-21  Eric Blake  <eblake@redhat.com>
89054         maintainer-makefile: work with older git for submodule check
89055         * top/maint.mk (public-submodule-commit): Rewrite to avoid
89056         merge-base --independent, which Ubuntu 10.04 git 1.7.0.4 lacks.
89057         Reported by Matthias Bolte.
89059         bootstrap: minor portability fixes
89060         * build-aux/bootstrap (me): Use $me instead of $0 in functions.
89061         (usage): Omit leading capital and trailing . on help phrases, per
89062         GNU Coding Standards.
89063         (check_versions, top level): Prefix messages with script name.
89065 2011-01-21  Benjamin Lindner  <bjmldn@gmail.com>  (tiny change)
89067         bootstrap: support --no-git option
89068         * build-aux/bootstrap: Add --no-git option, to be used when
89069         --gnulib-srcdir points to the exact desired checkout.
89071 2011-01-21  Eric Blake  <eblake@redhat.com>
89073         strerror_r-posix: work with glibc 2.13
89074         * lib/strerror_r.c (strerror_r): Fix return type.
89076 2011-01-21  Pádraig Brady  <P@draigBrady.com>
89077             Bruno Haible  <bruno@clisp.org>
89079         uN_strstr: New unit tests.
89080         * modules/unistr/u8-strstr-tests: New file.
89081         * modules/unistr/u16-strstr-tests: New file.
89082         * modules/unistr/u32-strstr-tests: New file.
89083         * tests/unistr/test-u-strstr.h: New file, based on tests/test-strstr.c.
89084         * tests/unistr/test-u8-strstr.c: New file.
89085         * tests/unistr/test-u16-strstr.c: New file.
89086         * tests/unistr/test-u32-strstr.c: New file.
89088 2011-01-21  Pádraig Brady  <P@draigBrady.com>
89089             Bruno Haible  <bruno@clisp.org>
89091         Make uN_strstr functions O(n) worst-case.
89092         * lib/unistr/u-strstr.h (FUNC): In the 8-bit case, use strstr. In the
89093         16-bit and 32-bit unit cases, use the unibyte algorithm from
89094         lib/mbsstr.c.
89095         * lib/unistr/u8-strstr.c: Include <string.h>.
89096         (UNIT_IS_UINT8_T): New macro.
89097         * lib/unistr/u16-strstr.c: Include malloca.h and str-kmp.h.
89098         (U_STRLEN, U_STRNLEN): New macros.
89099         * lib/unistr/u32-strstr.c: Include malloca.h and str-kmp.h.
89100         (U_STRLEN, U_STRNLEN): New macros.
89101         * modules/unistr/u8-strstr (Depends-on): Add strstr.
89102         (configure.ac): Update required libunistring version.
89103         * modules/unistr/u16-strstr (Files): Add lib/str-kmp.h.
89104         (Depends-on): Add unistr/u16-strlen, unistr/u16-strnlen, stdbool,
89105         malloca.
89106         (configure.ac): Update required libunistring version.
89107         * modules/unistr/u32-strstr (Files): Add lib/str-kmp.h.
89108         (Depends-on): Add unistr/u32-strlen, unistr/u32-strnlen, stdbool,
89109         malloca.
89110         (configure.ac): Update required libunistring version.
89112 2011-01-21  Pádraig Brady  <P@draigBrady.com>
89113             Bruno Haible  <bruno@clisp.org>
89115         Prepare for faster uN_strstr functions.
89116         * lib/str-kmp.h: Support definable UNITs.
89117         (knuth_morris_pratt): Renamed from knuth_morris_pratt_unibyte. Add
89118         needle_len argument.
89119         * lib/mbsstr.c (mbsstr): Adjust for the changed str-kmp.h.
89120         * lib/mbscasestr.c (mbscasestr): Likewise.
89122 2011-01-21  Pádraig Brady  <P@draigBrady.com>
89124         malloca-tests: make faster by unsetting MALLOC_PERTURB_
89125         * tests/test-malloca.c (main): Unset the environment variable
89126         to greatly speed up the test.
89127         * tests/init.sh: Don't say that MALLOC_PERTURB_ is cheap.
89128         * modules/malloca-tests: Depend on unsetenv.
89130 2011-01-21  Pádraig Brady  <P@draigBrady.com>
89132         ignore-value: remove stdint dependency
89133         * lib/ignore-value.h: Remove <stdint.h>
89134         * modules/ignore-value: Remove stdint dependency.
89136 2011-01-21  Jim Meyering  <meyering@redhat.com>
89138         maint.mk: adjust variable name to be consistent with other gl_ vars
89139         * top/maint.mk (gl_public_submodule_commit): Rename the variable
89140         to be lower case.
89142 2011-01-20  Jim Meyering  <meyering@redhat.com>
89144         maint.mk: make "check" depend on public-submodule-commit by default
89145         * top/maint.mk (GL_PUBLIC_SUBMODULE_COMMIT): New overridable variable.
89147 2011-01-20  Bruno Haible  <bruno@clisp.org>
89149         mbfile, mbiter: Complete change from 2008-12-21.
89150         * m4/mbfile.m4 (gl_MBFILE): Don't require AC_FUNC_MBRTOWC.
89151         * m4/mbiter.m4 (gl_MBITER): Likewise.
89153 2011-01-20  Jim Meyering  <meyering@redhat.com>
89155         init.sh: insert space between each function name and "()"
89156         * tests/init.sh: Make it a little easier to see that a function's
89157         name is "warn_", and not "warn" when looking at the first part of
89158         its definition: "warn_ ()".  Suggested by Ralf Wildenhues.
89160 2011-01-20  Jim Meyering  <meyering@redhat.com>
89162         mountlist: clean up code formatting
89163         * lib/mountlist.c (read_file_system_list): Split a long line,
89164         correct bracing style, use NULL in place of "(struct statfs *)0",
89165         don't parenthesize return value, add spaces around "=" and after
89166         ";-in-for-stmt".
89168 2011-01-14  Markus Duft  <mduft@gentoo.org>
89170         mountlist: add support for Interix
89171         * lib/mountlist.c (read_file_system_list) [MOUNTED_INTERIX_STATVFS]:
89172         Apply statvfs to all entries of /dev/fs.
89173         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for statvfs,
89174         and if found, AC_DEFINE MOUNTED_INTERIX_STATVFS.
89176 2011-01-20  Jim Meyering  <meyering@redhat.com>
89178         maint.mk: improve the public-submodule-commit rule
89179         * top/maint.mk (public-submodule-commit): Prefix with $(AM_V_GEN),
89180         to suppress printing of its commands... unless V=1.
89181         Add git submodule's --quiet option to suppress printing of e.g.,
89182         "Entering gnulib" output.
89183         "cd" into $(srcdir) before running git submodule.
89185 2011-01-20  Bruno Haible  <bruno@clisp.org>
89187         include_next: Fix bug introduced on 2011-01-18.
89188         * m4/include_next.m4 (gl_NEXT_HEADERS_INTERNAL): New macro, extracted
89189         from gl_CHECK_NEXT_HEADERS and gl_NEXT_HEADERS. Omit test of
89190         ac_cv_header_... variable if the second argument is not 'check'.
89191         (gl_CHECK_NEXT_HEADERS, gl_NEXT_HEADERS): Invoke
89192         gl_NEXT_HEADERS_INTERNAL.
89194 2011-01-20  Bruno Haible  <bruno@clisp.org>
89196         Allow the user to avoid the GNULIB_TEST_* macros.
89197         * m4/gnulib-common.m4 (gl_ASSERT_NO_GNULIB_TESTS): New macro.
89198         Suggested by Paul Eggert.
89200 2011-01-14  Jim Meyering  <meyering@redhat.com>
89202         bootstrap: avoid failure when there is no .gitmodules file
89203         ": ${gnulib_path=gnulib}" fails to set $gnulib_path when that variable
89204         has been assigned to, even when its value is the empty string.
89205         * build-aux/bootstrap (gnulib_path): Test explicitly for an empty
89206         "$gnulib_path", rather than using ${gnulib_path=gnulib}.
89207         Reported by John W. Eaton <jwe@gnu.org>.
89209 2011-01-19  Paul Eggert  <eggert@cs.ucla.edu>
89211         assume <ctype.h>, ..., <time.h> exist
89212         For years gnulib has been assuming the existence of the headers
89213         <ctype.h>, <errno.h>, <fcntl.h>, <locale.h>, <signal.h>,
89214         <stdio.h>, <stdlib.h>, <string.h>, and <time.h>.  Omit checks for
89215         them, since they don't appear to be needed.
89216         * README (Portability guidelines): Document this.
89217         * lib/flock.c: Assume <fcntl.h> exists.
89218         * lib/regex_internal.h: Assume <locale.h> exists.
89219         * m4/ctype.m4 (gl_CTYPE_H): Assume <ctype.h> exists.
89220         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Assume <errno.h> exists.
89221         * m4/fcntl_h.m4 (gl_FCNTL_H): Assume <fcntl.h> exists.
89222         * m4/flock.m4 (gl_PREREQ_FLOCK): Likewise.
89223         * m4/locale_h.m4 (gl_LOCALE_H): Assume <locale.h> exists.
89224         * m4/regex.m4 (gl_REGEX): Likewise.
89225         * m4/signal_h.m4 (gl_SIGNAL_H): Assume <signal.h> exists.
89226         * m4/stdio_h.m4 (gl_STDIO_H): Assume <stdio.h> exists.
89227         * m4/stdlib_h.m4 (gl_STDLIB_H): Assume <stdlib.h> exists.
89228         * m4/string_h.m4 (gl_STRING_H): Assume <string.h> exists.
89229         * tests/test-argp.c: Likewise.
89230         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Assume <time.h> exists.
89232         multiarch: remove AA_APPLE_UNIVERSAL_BUILD
89233         * m4/multiarch.m4 (gl_MULTIARCH): Don't AC_DEFINE
89234         AA_APPLE_UNIVERSAL_BUILD.  See
89235         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00247.html>.
89236         * NEWS: Document this.
89238 2011-01-19  Eric Blake  <eblake@redhat.com>
89240         c-stack: assume stack overflow if SA_SIGINFO unsupported
89241         * lib/c-stack.c (SIGACTION_WORKS): Rename...
89242         (SIGINFO_WORKS): ...since gnulib module guarantees that (most) of
89243         sigaction will work.
89244         (die): Assume stack overflow if siginfo doesn't work, to let Haiku
89245         behavior match Linux.
89246         * tests/test-c-stack.c (main): Prefer NULL for pointers.
89248         stdbool-tests: accommodate Haiku
89249         * tests/test-stdbool.c: Haiku's gcc 2.95 lacks native _Bool.
89251         binary-io: fix O_TEXT on Haiku
89252         * modules/binary-io (Depends-on): Add fcntl-h.
89253         * lib/binary-io.h (O_TEXT): Rely on replacement <fcntl.h> rather
89254         than blindly undefining O_TEXT.
89255         Reported by Scott McCreary.
89257 2011-01-18  Paul Eggert  <eggert@cs.ucla.edu>
89259         include_next: do not check for standard headers like stddef.h
89261         I found this problem when modifying Emacs to use gnulib.
89262         I noticed that it added HAVE_STDDEF_H to config.h, even though
89263         gnulib always assumes <stddef.h> exists as per README and this
89264         symbol is unnecessary.
89265         * m4/include_next.m4 (gl_NEXT_HEADERS): New macro, which does not
89266         use AC_CHECK_HEADERS_ONCE, but which otherwise contains what
89267         gl_CHECK_NEXT_HEADERS used to contain.  This makes 'configure' run
89268         faster for headers like stddef.h that are known to exist.
89269         (gl_CHECK_NEXT_HEADERS): Use it.
89270         * m4/float_h.m4 (gl_FLOAT_H): For float.h, use gl_NEXT_HEADERS
89271         rather than gl_CHECK_NEXT_HEADERS.
89272         * m4/stdarg.m4 (gl_STDARG_H): Likewise, for stdarg.h.
89273         * m4/stddef_h.m4 (gl_STDDEF_H): Likewise, for stddef.h.
89275 2011-01-18  Eric Blake  <eblake@redhat.com>
89277         ansi-c++-opt: skip C++ dependency style if C++ is unused
89278         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): Avoid full-blown dependency
89279         tests when we know C++ compilation is not desired.
89280         Reported by Scott McCreary.
89282 2011-01-18  Bruno Haible  <bruno@clisp.org>
89284         *printf-posix: Avoid test failures. Make tests work on MacOS X, Cygwin.
89285         * tests/test-fprintf-posix3.c: Include "resource-ext.h".
89286         (main): Perform test also when getrlimit and setrlimit don't exist or
89287         when setrlimit of RLIMIT_DATA fails (like on Cygwin). Instead of
89288         limiting the address space size using setrlimit, compare the address
89289         space size before and after the test.
89290         * tests/test-dprintf-posix2.c: Likewise.
89291         * tests/test-fprintf-posix3.sh: Update skip messages.
89292         * tests/test-dprintf-posix2.sh: Likewise.
89293         * modules/fprintf-posix-tests (Depends-on): Add get-rusage-as.
89294         * modules/dprintf-posix-tests (Depends-on): Likewise.
89295         Reported by Bruce Korb <bkorb@gnu.org> and
89296         Gary V. Vaughan <gary@gnu.org>.
89298 2011-01-18  Bruno Haible  <bruno@clisp.org>
89300         get-rusage-as: Improvement for Cygwin.
89301         * lib/get-rusage-as.c (get_rusage_as_via_iterator): On Windows, ignore
89302         areas that are merely reserved.
89304 2011-01-18  Paul Eggert  <eggert@cs.ucla.edu>
89306         strftime: remove dependencies on multibyte modules
89308         strftime depended on mbrlen, mbsinit, and wchar, but these modules
89309         are needed only if ! MULTIBYTE_IS_FORMAT_SAFE, and that is true
89310         only if __osf__ is defined, and I suspect OSF doesn't need these
89311         other modules.  If my guess is wrong, we'll need to come up with a
89312         variant of strftime that doesn't need the multibyte modules.
89314         I discovered this problem when attempting modify Emacs to use the
89315         strftime module.  With the previous gnulib, this caused Emacs to
89316         need 31 new files, ranging from lib/config.charset to
89317         m4/wint_t.m4.  This was overkill and I expect would be offputting
89318         to the Emacs maintainers.  After this change, only 6 new files are
89319         needed, namely strftime.[ch], srtftime.m4, stdbool.in.h,
89320         stdbool.m4, and tm_gmtoff.m4.
89322         * lib/strftime.c (MULTIBYTE_IS_FORMAT_SAFE): Define to 1 always.
89323         Suggested by Bruno Haible in
89324         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00238.html>.
89325         * m4/strftime.m4 (gl_FUNC_STRFTIME): Do not require AC_TYPE_MBSTATE_T,
89326         and do not check for wchar.h.
89327         * modules/strftime (Files): Remove m4/mbstate_t.m4.
89328         (Depends-on): Remove mbrlen, mbsinit, wchar.
89330 2011-01-18  Bruno Haible  <bruno@clisp.org>
89332         Tests for module 'get-rusage-as'.
89333         * modules/get-rusage-as-tests: New file.
89334         * tests/test-get-rusage-as.c: New file.
89336         New module 'get-rusage-as'.
89337         * modules/get-rusage-as: New file.
89338         * lib/resource-ext.h: New file.
89339         * lib/get-rusage-as.c: New file.
89341 2011-01-17  Eric Blake  <eblake@redhat.com>
89343         sigaction: relax license from LGPLv3+ to LGPLv2+
89344         * modules/sigaction (License): Relax to LGPLv2+.
89346 2011-01-14  Bruno Haible  <bruno@clisp.org>
89348         filemode: Make function declarations usable in C++ mode.
89349         * lib/filemode.h: Enclose function declarations in extern "C" block.
89350         Reported by John W. Eaton <jwe@gnu.org>.
89352 2011-01-12  Rob Vermaas  <rob.vermaas@gmail.com>
89354         save-cwd: no longer include "xgetcwd.h"
89355         * lib/save-cwd.c: Don't include "xgetcwd.h"; it's no longer used.
89356         This avoids a compilation failure in projects that use save-cwd
89357         without also using the xgetcwd module.
89359 2011-01-11  Paul Eggert  <eggert@cs.ucla.edu>
89361         ftoastr: split into 3 modules ftoastr, dtoastr, ldtoastr
89362         This is so that a program like Emacs, which needs only dtoastr,
89363         does not have to bother with distributing and compiling ftoastr
89364         and ldtoastr.
89365         * MODULES.html.sh: Document these modules (ftoastr wasn't documented).
89366         * modules/dtoastr, modules/ldtoastr: New files.
89367         * modules/ftoastr: Now works just for 'float'.
89368         (Files): Remove lib/dtoastr.c, lib/ldtoastr.c.
89369         (Makefile.am): Remove ftoastr.h (not needed and no effect),
89370         dtoastr.c, ldtoastr.c.
89372 2011-01-11  Jim Meyering  <meyering@redhat.com>
89374         save-cwd: remove #if-!HAVE_FCHDIR'd code; use the fchdir module
89375         There is no need to work around the lack of the fchdir function,
89376         since gnulib can now provide a replacement when required.
89377         * lib/save-cwd.c: Remove #if !HAVE_FCHDIR...#endif code.
89378         * modules/save-cwd (Depends-on): Add fchdir.
89380 2011-01-11  Paul Eggert  <eggert@cs.ucla.edu>
89382         openat, save-cwd: avoid xmalloc
89384         This removes a direct (but undocumented) dependency of openat on
89385         xalloc, along with an indirect dependency via save-cwd.  It also
89386         removes a dependency of save-cwd on xgetcwd, and thereby
89387         indirectly on xalloc.  This change causes the openat substitute
89388         to fall back on save_cwd when memory is tight, and for save_cwd to
89389         fail instead of dying when memory is tight, but that's good enough.
89390         Problem and initial idea for fix reported by Bastien Roucaries in
89391         <http://lists.gnu.org/r/bug-gnulib/2011-01/msg00170.html>.
89393         * lib/openat-proc.c: Include stdlib.h (for malloc), not
89394         xalloc.h (for xmalloc).
89395         (openat_proc_name): Use malloc, not xmalloc.
89396         * lib/save-cwd.c (save_cwd): Use getcwd, not xgetcwd.
89397         * modules/save-cwd (Files): Depend on getcwd, not xgetcwd.
89399         openat: Increase OPENAT_BUFFER_SIZE from 512 to at least 1024
89400         This avoids heap allocation for file names whose lengths are in
89401         the range 512..1023, with the upper bound increasing to at most
89402         4031 depending on the platform's PATH_MAX.  (We do not want
89403         pathmax.h here as it might supply a non-constant PATH_MAX.)
89404         * lib/openat-priv.h (SAFER_ALLOCA_MAX, SAFER_ALLOCA): New macros.
89405         Perhaps they should be moved to malloca.h?
89406         (OPENAT_BUFFER_SIZE): Use them.
89408 2011-01-10  Bruno Haible  <bruno@clisp.org>
89410         doc: Update users.txt.
89411         * users.txt: Add recutils.
89413 2011-01-09  Karl Berry  <karl@gnu.org>
89415         * doc/posix-functions/gai_strerror.texi: Insert missing @item.
89417         * doc/configmake.texi: New file.
89418         * doc/gnulib.texi: Include it.
89419         * modules/configmake: Move documentation from here.
89421 2011-01-09  Bruno Haible  <bruno@clisp.org>
89423         Update to Unicode 6.0.0.
89424         * lib/gen-uni-tables.c (symbolic_width): Fix bounds of planes.
89425         (get_lbp): Update for Unicode 6.0.0.
89426         * lib/uniwidth/width.c (nonspacing_table_data): Add U+065F,
89427         U+0859..U+085B, U+093A, U+0956..U+0957, U+0F8D..U+0F8F, U+135D..U+135E,
89428         U+1BE6, U+1BE8..U+1BE9, U+1BED, U+1BEF..U+1BF1, U+1DFC, U+2D7F,
89429         U+11001, U+11038..U+11046. Remove U+06DE.
89430         (uc_width): Fix bounds of planes.
89431         * tests/uniwidth/test-uc_width2.sh: Same updates as in
89432         lib/uniwidth/width.c.
89433         * tests/unigbrk/GraphemeBreakTest.txt: Copied from Unicode 6.0.0, with
89434         trailing whitespace removed.
89435         * tests/uninorm/NormalizationTest.txt: Update from Unicode 6.0.0,
89436         without comments, but with the original copyright notice.
89437         * lib/unicase/cased.h: Regenerated for Unicode 6.0.0.
89438         * lib/unicase/ignorable.h: Likewise.
89439         * lib/unicase/tocasefold.h: Likewise.
89440         * lib/unicase/tolower.h: Likewise.
89441         * lib/unicase/totitle.h: Likewise.
89442         * lib/unicase/toupper.h: Likewise.
89443         * lib/unictype/bidi_of.h: Likewise.
89444         * lib/unictype/blocks.h: Likewise.
89445         * lib/unictype/categ_C.h: Likewise.
89446         * lib/unictype/categ_Cn.h: Likewise.
89447         * lib/unictype/categ_L.h: Likewise.
89448         * lib/unictype/categ_Ll.h: Likewise.
89449         * lib/unictype/categ_Lm.h: Likewise.
89450         * lib/unictype/categ_Lo.h: Likewise.
89451         * lib/unictype/categ_Lu.h: Likewise.
89452         * lib/unictype/categ_M.h: Likewise.
89453         * lib/unictype/categ_Mc.h: Likewise.
89454         * lib/unictype/categ_Me.h: Likewise.
89455         * lib/unictype/categ_Mn.h: Likewise.
89456         * lib/unictype/categ_N.h: Likewise.
89457         * lib/unictype/categ_Nd.h: Likewise.
89458         * lib/unictype/categ_No.h: Likewise.
89459         * lib/unictype/categ_P.h: Likewise.
89460         * lib/unictype/categ_Po.h: Likewise.
89461         * lib/unictype/categ_S.h: Likewise.
89462         * lib/unictype/categ_Sc.h: Likewise.
89463         * lib/unictype/categ_Sk.h: Likewise.
89464         * lib/unictype/categ_Sm.h: Likewise.
89465         * lib/unictype/categ_So.h: Likewise.
89466         * lib/unictype/categ_of.h: Likewise.
89467         * lib/unictype/combining.h: Likewise.
89468         * lib/unictype/ctype_alnum.h: Likewise.
89469         * lib/unictype/ctype_alpha.h: Likewise.
89470         * lib/unictype/ctype_graph.h: Likewise.
89471         * lib/unictype/ctype_lower.h: Likewise.
89472         * lib/unictype/ctype_print.h: Likewise.
89473         * lib/unictype/ctype_punct.h: Likewise.
89474         * lib/unictype/ctype_upper.h: Likewise.
89475         * lib/unictype/decdigit.h: Likewise.
89476         * lib/unictype/digit.h: Likewise.
89477         * lib/unictype/numeric.h: Likewise.
89478         * lib/unictype/pr_alphabetic.h: Likewise.
89479         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
89480         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
89481         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
89482         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
89483         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
89484         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
89485         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
89486         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
89487         * lib/unictype/pr_case_ignorable.h: Likewise.
89488         * lib/unictype/pr_cased.h: Likewise.
89489         * lib/unictype/pr_changes_when_casefolded.h: Likewise.
89490         * lib/unictype/pr_changes_when_casemapped.h: Likewise.
89491         * lib/unictype/pr_changes_when_lowercased.h: Likewise.
89492         * lib/unictype/pr_changes_when_titlecased.h: Likewise.
89493         * lib/unictype/pr_changes_when_uppercased.h: Likewise.
89494         * lib/unictype/pr_combining.h: Likewise.
89495         * lib/unictype/pr_composite.h: Likewise.
89496         * lib/unictype/pr_currency_symbol.h: Likewise.
89497         * lib/unictype/pr_decimal_digit.h: Likewise.
89498         * lib/unictype/pr_deprecated.h: Likewise.
89499         * lib/unictype/pr_format_control.h: Likewise.
89500         * lib/unictype/pr_grapheme_base.h: Likewise.
89501         * lib/unictype/pr_grapheme_extend.h: Likewise.
89502         * lib/unictype/pr_grapheme_link.h: Likewise.
89503         * lib/unictype/pr_id_continue.h: Likewise.
89504         * lib/unictype/pr_id_start.h: Likewise.
89505         * lib/unictype/pr_ideographic.h: Likewise.
89506         * lib/unictype/pr_lowercase.h: Likewise.
89507         * lib/unictype/pr_math.h: Likewise.
89508         * lib/unictype/pr_numeric.h: Likewise.
89509         * lib/unictype/pr_other_alphabetic.h: Likewise.
89510         * lib/unictype/pr_other_id_continue.h: Likewise.
89511         * lib/unictype/pr_other_math.h: Likewise.
89512         * lib/unictype/pr_punctuation.h: Likewise.
89513         * lib/unictype/pr_sentence_terminal.h: Likewise.
89514         * lib/unictype/pr_terminal_punctuation.h: Likewise.
89515         * lib/unictype/pr_unassigned_code_value.h: Likewise.
89516         * lib/unictype/pr_unified_ideograph.h: Likewise.
89517         * lib/unictype/pr_uppercase.h: Likewise.
89518         * lib/unictype/pr_xid_continue.h: Likewise.
89519         * lib/unictype/pr_xid_start.h: Likewise.
89520         * lib/unictype/scripts.h: Likewise.
89521         * lib/unictype/scripts_byname.gperf: Likewise.
89522         * lib/unictype/sy_java_ident.h: Likewise.
89523         * lib/unigbrk/gbrkprop.h: Likewise.
89524         * lib/unilbrk/lbrkprop1.h: Likewise.
89525         * lib/unilbrk/lbrkprop2.h: Likewise.
89526         * lib/uninorm/decomposition-table2.h: Likewise.
89527         * lib/uniwbrk/wbrkprop.h: Likewise.
89528         * tests/unicase/test-cased.c: Likewise.
89529         * tests/unicase/test-ignorable.c: Likewise.
89530         * tests/unicase/test-uc_tolower.c: Likewise.
89531         * tests/unicase/test-uc_totitle.c: Likewise.
89532         * tests/unicase/test-uc_toupper.c: Likewise.
89533         * tests/unictype/test-categ_C.c: Likewise.
89534         * tests/unictype/test-categ_Cn.c: Likewise.
89535         * tests/unictype/test-categ_L.c: Likewise.
89536         * tests/unictype/test-categ_Ll.c: Likewise.
89537         * tests/unictype/test-categ_Lm.c: Likewise.
89538         * tests/unictype/test-categ_Lo.c: Likewise.
89539         * tests/unictype/test-categ_Lu.c: Likewise.
89540         * tests/unictype/test-categ_M.c: Likewise.
89541         * tests/unictype/test-categ_Mc.c: Likewise.
89542         * tests/unictype/test-categ_Me.c: Likewise.
89543         * tests/unictype/test-categ_Mn.c: Likewise.
89544         * tests/unictype/test-categ_N.c: Likewise.
89545         * tests/unictype/test-categ_Nd.c: Likewise.
89546         * tests/unictype/test-categ_No.c: Likewise.
89547         * tests/unictype/test-categ_P.c: Likewise.
89548         * tests/unictype/test-categ_Po.c: Likewise.
89549         * tests/unictype/test-categ_S.c: Likewise.
89550         * tests/unictype/test-categ_Sc.c: Likewise.
89551         * tests/unictype/test-categ_Sk.c: Likewise.
89552         * tests/unictype/test-categ_Sm.c: Likewise.
89553         * tests/unictype/test-categ_So.c: Likewise.
89554         * tests/unictype/test-ctype_alnum.c: Likewise.
89555         * tests/unictype/test-ctype_alpha.c: Likewise.
89556         * tests/unictype/test-ctype_graph.c: Likewise.
89557         * tests/unictype/test-ctype_lower.c: Likewise.
89558         * tests/unictype/test-ctype_print.c: Likewise.
89559         * tests/unictype/test-ctype_punct.c: Likewise.
89560         * tests/unictype/test-ctype_upper.c: Likewise.
89561         * tests/unictype/test-decdigit.h: Likewise.
89562         * tests/unictype/test-digit.h: Likewise.
89563         * tests/unictype/test-numeric.h: Likewise.
89564         * tests/unictype/test-pr_alphabetic.c: Likewise.
89565         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
89566         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Likewise.
89567         * tests/unictype/test-pr_bidi_boundary_neutral.c: Likewise.
89568         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
89569         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
89570         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
89571         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
89572         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
89573         * tests/unictype/test-pr_case_ignorable.c: Likewise.
89574         * tests/unictype/test-pr_cased.c: Likewise.
89575         * tests/unictype/test-pr_changes_when_casefolded.c: Likewise.
89576         * tests/unictype/test-pr_changes_when_casemapped.c: Likewise.
89577         * tests/unictype/test-pr_changes_when_lowercased.c: Likewise.
89578         * tests/unictype/test-pr_changes_when_titlecased.c: Likewise.
89579         * tests/unictype/test-pr_changes_when_uppercased.c: Likewise.
89580         * tests/unictype/test-pr_combining.c: Likewise.
89581         * tests/unictype/test-pr_composite.c: Likewise.
89582         * tests/unictype/test-pr_currency_symbol.c: Likewise.
89583         * tests/unictype/test-pr_decimal_digit.c: Likewise.
89584         * tests/unictype/test-pr_deprecated.c: Likewise.
89585         * tests/unictype/test-pr_format_control.c: Likewise.
89586         * tests/unictype/test-pr_grapheme_base.c: Likewise.
89587         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
89588         * tests/unictype/test-pr_grapheme_link.c: Likewise.
89589         * tests/unictype/test-pr_id_continue.c: Likewise.
89590         * tests/unictype/test-pr_id_start.c: Likewise.
89591         * tests/unictype/test-pr_ideographic.c: Likewise.
89592         * tests/unictype/test-pr_lowercase.c: Likewise.
89593         * tests/unictype/test-pr_math.c: Likewise.
89594         * tests/unictype/test-pr_numeric.c: Likewise.
89595         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
89596         * tests/unictype/test-pr_other_id_continue.c: Likewise.
89597         * tests/unictype/test-pr_other_math.c: Likewise.
89598         * tests/unictype/test-pr_punctuation.c: Likewise.
89599         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
89600         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
89601         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
89602         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
89603         * tests/unictype/test-pr_uppercase.c: Likewise.
89604         * tests/unictype/test-pr_xid_continue.c: Likewise.
89605         * tests/unictype/test-pr_xid_start.c: Likewise.
89606         * tests/unigbrk/test-uc-gbrk-prop.h: Likewise.
89607         * lib/unicase/special-casing-table.gperf: Regenerated; only comment
89608         changes.
89609         * lib/unictype/categ_Cc.h: Likewise.
89610         * lib/unictype/categ_Cf.h: Likewise.
89611         * lib/unictype/categ_Co.h: Likewise.
89612         * lib/unictype/categ_Cs.h: Likewise.
89613         * lib/unictype/categ_Lt.h: Likewise.
89614         * lib/unictype/categ_Nl.h: Likewise.
89615         * lib/unictype/categ_Pc.h: Likewise.
89616         * lib/unictype/categ_Pd.h: Likewise.
89617         * lib/unictype/categ_Pe.h: Likewise.
89618         * lib/unictype/categ_Pf.h: Likewise.
89619         * lib/unictype/categ_Pi.h: Likewise.
89620         * lib/unictype/categ_Ps.h: Likewise.
89621         * lib/unictype/categ_Z.h: Likewise.
89622         * lib/unictype/categ_Zl.h: Likewise.
89623         * lib/unictype/categ_Zp.h: Likewise.
89624         * lib/unictype/categ_Zs.h: Likewise.
89625         * lib/unictype/ctype_blank.h: Likewise.
89626         * lib/unictype/ctype_cntrl.h: Likewise.
89627         * lib/unictype/ctype_digit.h: Likewise.
89628         * lib/unictype/ctype_space.h: Likewise.
89629         * lib/unictype/ctype_xdigit.h: Likewise.
89630         * lib/unictype/mirror.h: Likewise.
89631         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
89632         * lib/unictype/pr_bidi_block_separator.h: Likewise.
89633         * lib/unictype/pr_bidi_common_separator.h: Likewise.
89634         * lib/unictype/pr_bidi_control.h: Likewise.
89635         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
89636         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
89637         * lib/unictype/pr_bidi_european_digit.h: Likewise.
89638         * lib/unictype/pr_bidi_pdf.h: Likewise.
89639         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
89640         * lib/unictype/pr_bidi_whitespace.h: Likewise.
89641         * lib/unictype/pr_dash.h: Likewise.
89642         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
89643         * lib/unictype/pr_diacritic.h: Likewise.
89644         * lib/unictype/pr_extender.h: Likewise.
89645         * lib/unictype/pr_hex_digit.h: Likewise.
89646         * lib/unictype/pr_hyphen.h: Likewise.
89647         * lib/unictype/pr_ids_binary_operator.h: Likewise.
89648         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
89649         * lib/unictype/pr_ignorable_control.h: Likewise.
89650         * lib/unictype/pr_iso_control.h: Likewise.
89651         * lib/unictype/pr_join_control.h: Likewise.
89652         * lib/unictype/pr_left_of_pair.h: Likewise.
89653         * lib/unictype/pr_line_separator.h: Likewise.
89654         * lib/unictype/pr_logical_order_exception.h: Likewise.
89655         * lib/unictype/pr_non_break.h: Likewise.
89656         * lib/unictype/pr_not_a_character.h: Likewise.
89657         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
89658         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
89659         * lib/unictype/pr_other_id_start.h: Likewise.
89660         * lib/unictype/pr_other_lowercase.h: Likewise.
89661         * lib/unictype/pr_other_uppercase.h: Likewise.
89662         * lib/unictype/pr_paired_punctuation.h: Likewise.
89663         * lib/unictype/pr_paragraph_separator.h: Likewise.
89664         * lib/unictype/pr_pattern_syntax.h: Likewise.
89665         * lib/unictype/pr_pattern_white_space.h: Likewise.
89666         * lib/unictype/pr_private_use.h: Likewise.
89667         * lib/unictype/pr_quotation_mark.h: Likewise.
89668         * lib/unictype/pr_radical.h: Likewise.
89669         * lib/unictype/pr_soft_dotted.h: Likewise.
89670         * lib/unictype/pr_space.h: Likewise.
89671         * lib/unictype/pr_titlecase.h: Likewise.
89672         * lib/unictype/pr_variation_selector.h: Likewise.
89673         * lib/unictype/pr_white_space.h: Likewise.
89674         * lib/unictype/pr_zero_width.h: Likewise.
89675         * lib/unictype/sy_c_ident.h: Likewise.
89676         * lib/unictype/sy_c_whitespace.h: Likewise.
89677         * lib/unictype/sy_java_whitespace.h: Likewise.
89678         * lib/uninorm/composition-table.gperf: Likewise.
89679         * lib/uninorm/decomposition-table1.h: Likewise.
89680         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Add test for rule
89681         LB8.
89682         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
89683         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
89684         * modules/unictype/*: Bump version number of expected libunistring
89685         version.
89687 2011-01-09  Bruno Haible  <bruno@clisp.org>
89689         Update to Unicode 5.2.0.
89690         * tests/unigbrk/GraphemeBreakTest.txt: Copied from Unicode 5.2.0, with
89691         trailing whitespace removed.
89693 2011-01-09  Bruno Haible  <bruno@clisp.org>
89695         New Unicode character properties, from Unicode 5.2.0.
89696         * lib/unictype.in.h (UC_PROPERTY_CASED, UC_PROPERTY_CASE_IGNORABLE,
89697         UC_PROPERTY_CHANGES_WHEN_LOWERCASED,
89698         UC_PROPERTY_CHANGES_WHEN_UPPERCASED,
89699         UC_PROPERTY_CHANGES_WHEN_TITLECASED,
89700         UC_PROPERTY_CHANGES_WHEN_CASEFOLDED,
89701         UC_PROPERTY_CHANGES_WHEN_CASEMAPPED,
89702         uc_is_property_cased, uc_is_property_case_ignorable,
89703         uc_is_property_changes_when_lowercased,
89704         uc_is_property_changes_when_uppercased,
89705         uc_is_property_changes_when_titlecased,
89706         uc_is_property_changes_when_casefolded,
89707         uc_is_property_changes_when_casemapped): New declarations.
89708         * lib/unictype/pr_byname.gperf: Add the new properties.
89709         * modules/unictype/property-byname (Depends-on): Depend on the new
89710         properties modules.
89711         * modules/unictype/property-all (Depends-on): Likewise.
89712         * MODULES.html.sh (Unicode string functions): Add
89713         unictype/property-case-ignorable, unictype/property-cased,
89714         unictype/property-changes-when-casefolded,
89715         unictype/property-changes-when-casemapped,
89716         unictype/property-changes-when-lowercased,
89717         unictype/property-changes-when-titlecased,
89718         unictype/property-changes-when-uppercased.
89720         New module 'unictype/property-changes-when-casemapped'.
89721         * modules/unictype/property-changes-when-casemapped: New file.
89722         * lib/unictype/pr_changes_when_casemapped.c: New file.
89723         * lib/unictype/pr_changes_when_casemapped.h: New file, automatically
89724         generated by gen-uni-tables.
89725         * modules/unictype/property-changes-when-casemapped-tests: New file.
89726         * tests/unictype/test-pr_changes_when_casemapped.c: New file,
89727         automatically generated by gen-uni-tables.
89729         New module 'unictype/property-changes-when-casefolded'.
89730         * modules/unictype/property-changes-when-casefolded: New file.
89731         * lib/unictype/pr_changes_when_casefolded.c: New file.
89732         * lib/unictype/pr_changes_when_casefolded.h: New file, automatically
89733         generated by gen-uni-tables.
89734         * modules/unictype/property-changes-when-casefolded-tests: New file.
89735         * tests/unictype/test-pr_changes_when_casefolded.c: New file,
89736         automatically generated by gen-uni-tables.
89738         New module 'unictype/property-changes-when-titlecased'.
89739         * modules/unictype/property-changes-when-titlecased: New file.
89740         * lib/unictype/pr_changes_when_titlecased.c: New file.
89741         * lib/unictype/pr_changes_when_titlecased.h: New file, automatically
89742         generated by gen-uni-tables.
89743         * modules/unictype/property-changes-when-titlecased-tests: New file.
89744         * tests/unictype/test-pr_changes_when_titlecased.c: New file,
89745         automatically generated by gen-uni-tables.
89747         New module 'unictype/property-changes-when-uppercased'.
89748         * modules/unictype/property-changes-when-uppercased: New file.
89749         * lib/unictype/pr_changes_when_uppercased.c: New file.
89750         * lib/unictype/pr_changes_when_uppercased.h: New file, automatically
89751         generated by gen-uni-tables.
89752         * modules/unictype/property-changes-when-uppercased-tests: New file.
89753         * tests/unictype/test-pr_changes_when_uppercased.c: New file,
89754         automatically generated by gen-uni-tables.
89756         New module 'unictype/property-changes-when-lowercased'.
89757         * modules/unictype/property-changes-when-lowercased: New file.
89758         * lib/unictype/pr_changes_when_lowercased.c: New file.
89759         * lib/unictype/pr_changes_when_lowercased.h: New file, automatically
89760         generated by gen-uni-tables.
89761         * modules/unictype/property-changes-when-lowercased-tests: New file.
89762         * tests/unictype/test-pr_changes_when_lowercased.c: New file,
89763         automatically generated by gen-uni-tables.
89765         New module 'unictype/property-case-ignorable'.
89766         * modules/unictype/property-case-ignorable: New file.
89767         * lib/unictype/pr_case_ignorable.c: New file.
89768         * lib/unictype/pr_case_ignorable.h: New file, automatically generated
89769         by gen-uni-tables.
89770         * modules/unictype/property-case-ignorable-tests: New file.
89771         * tests/unictype/test-pr_case_ignorable.c: New file, automatically
89772         generated by gen-uni-tables.
89774         New module 'unictype/property-cased'.
89775         * modules/unictype/property-cased: New file.
89776         * lib/unictype/pr_cased.c: New file.
89777         * lib/unictype/pr_cased.h: New file, automatically generated by
89778         gen-uni-tables.
89779         * modules/unictype/property-cased-tests: New file.
89780         * tests/unictype/test-pr_cased.c: New file, automatically generated by
89781         gen-uni-tables.
89783 2011-01-09  Bruno Haible  <bruno@clisp.org>
89785         Update to Unicode 5.2.0.
89786         * lib/gen-uni-tables.c (output_predicate, output_category,
89787         output_combclass, output_bidi_category, output_decimal_digit_test,
89788         output_decimal_digit, output_digit_test, output_digit,
89789         output_numeric_test, output_numeric, output_mirror, output_scripts,
89790         output_scripts_byname, output_blocks, output_ident_category): Fix
89791         comment header.
89792         (is_WBP_MIDNUMLET, is_WBP_MIDLETTER): New functions, extracted from
89793         get_wbp.
89794         (PROP_CASED, PROP_CASE_IGNORABLE, PROP_CHANGES_WHEN_*): New enumeration
89795         items.
89796         (fill_properties): Also fill the peoperties Cased, Case_Ignorable,
89797         Changes_When_Lowercased, Changes_When_Uppercased,
89798         Changes_When_Titlecased, Changes_When_Casefolded,
89799         Changes_When_Casemapped.
89800         (is_property_alphabetic, is_property_default_ignorable_code_point):
89801         Update for Unicode 5.2.0.
89802         (is_property_cased, is_property_case_ignorable,
89803         is_property_changes_when_lowercased,
89804         is_property_changes_when_uppercased,
89805         is_property_changes_when_titlecased,
89806         is_property_changes_when_casefolded,
89807         is_property_changes_when_casemapped): New functions.
89808         (output_properties): Output also the properties cased, case_ignorable,
89809         changes_when_lowercased, changes_when_uppercased,
89810         changes_when_titlecased, changes_when_casefolded,
89811         changes_when_casemapped.
89812         (symbolic_width): Update for Unicode 5.2.0, incorporating changes from
89813         Unicode TR#11 revision 17 -> 19.
89814         (LBP_CP): New enumeration value.
89815         (LBP_*): Adjust values accordingly.
89816         (get_lbp): Update for Unicode 5.2.0, incorporating changes from Unicode
89817         TR#14 revision 22 -> 24.
89818         (debug_output_lbp): Allow for LBP_* bits >= 32. Support LBP_CP.
89819         (fill_org_lbp, debug_output_org_lbp, output_lbp): Support LBP_CP.
89820         (get_wbp): Update for Unicode 5.2.0, incorporating changes from Unicode
89821         TR#29 revision 13 -> 15. Use functions is_WBP_MIDNUMLET,
89822         is_WBP_MIDLETTER.
89823         (output_composition_tables): Allow for 24 bits instead of 16 bits in
89824         the code1 and code2 of each composition rule.
89825         * lib/unicase/cased.h: Regenerated for Unicode 5.2.0.
89826         * lib/unicase/ignorable.h: Likewise.
89827         * lib/unicase/tocasefold.h: Likewise.
89828         * lib/unicase/tolower.h: Likewise.
89829         * lib/unicase/totitle.h: Likewise.
89830         * lib/unicase/toupper.h: Likewise.
89831         * lib/unictype/bidi_of.h: Likewise.
89832         * lib/unictype/blocks.h: Likewise.
89833         * lib/unictype/categ_C.h: Likewise.
89834         * lib/unictype/categ_Cf.h: Likewise.
89835         * lib/unictype/categ_Cn.h: Likewise.
89836         * lib/unictype/categ_L.h: Likewise.
89837         * lib/unictype/categ_Ll.h: Likewise.
89838         * lib/unictype/categ_Lm.h: Likewise.
89839         * lib/unictype/categ_Lo.h: Likewise.
89840         * lib/unictype/categ_Lu.h: Likewise.
89841         * lib/unictype/categ_M.h: Likewise.
89842         * lib/unictype/categ_Mc.h: Likewise.
89843         * lib/unictype/categ_Mn.h: Likewise.
89844         * lib/unictype/categ_N.h: Likewise.
89845         * lib/unictype/categ_Nd.h: Likewise.
89846         * lib/unictype/categ_Nl.h: Likewise.
89847         * lib/unictype/categ_No.h: Likewise.
89848         * lib/unictype/categ_P.h: Likewise.
89849         * lib/unictype/categ_Pd.h: Likewise.
89850         * lib/unictype/categ_Po.h: Likewise.
89851         * lib/unictype/categ_S.h: Likewise.
89852         * lib/unictype/categ_Sc.h: Likewise.
89853         * lib/unictype/categ_So.h: Likewise.
89854         * lib/unictype/categ_of.h: Likewise.
89855         * lib/unictype/combining.h: Likewise.
89856         * lib/unictype/ctype_alnum.h: Likewise.
89857         * lib/unictype/ctype_alpha.h: Likewise.
89858         * lib/unictype/ctype_graph.h: Likewise.
89859         * lib/unictype/ctype_lower.h: Likewise.
89860         * lib/unictype/ctype_print.h: Likewise.
89861         * lib/unictype/ctype_punct.h: Likewise.
89862         * lib/unictype/ctype_upper.h: Likewise.
89863         * lib/unictype/decdigit.h: Likewise.
89864         * lib/unictype/digit.h: Likewise.
89865         * lib/unictype/numeric.h: Likewise.
89866         * lib/unictype/pr_alphabetic.h: Likewise.
89867         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
89868         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
89869         * lib/unictype/pr_bidi_european_digit.h: Likewise.
89870         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
89871         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
89872         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
89873         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
89874         * lib/unictype/pr_combining.h: Likewise.
89875         * lib/unictype/pr_composite.h: Likewise.
89876         * lib/unictype/pr_currency_symbol.h: Likewise.
89877         * lib/unictype/pr_dash.h: Likewise.
89878         * lib/unictype/pr_decimal_digit.h: Likewise.
89879         * lib/unictype/pr_deprecated.h: Likewise.
89880         * lib/unictype/pr_diacritic.h: Likewise.
89881         * lib/unictype/pr_extender.h: Likewise.
89882         * lib/unictype/pr_grapheme_base.h: Likewise.
89883         * lib/unictype/pr_grapheme_extend.h: Likewise.
89884         * lib/unictype/pr_grapheme_link.h: Likewise.
89885         * lib/unictype/pr_id_continue.h: Likewise.
89886         * lib/unictype/pr_id_start.h: Likewise.
89887         * lib/unictype/pr_ideographic.h: Likewise.
89888         * lib/unictype/pr_ignorable_control.h: Likewise.
89889         * lib/unictype/pr_logical_order_exception.h: Likewise.
89890         * lib/unictype/pr_lowercase.h: Likewise.
89891         * lib/unictype/pr_numeric.h: Likewise.
89892         * lib/unictype/pr_other_alphabetic.h: Likewise.
89893         * lib/unictype/pr_punctuation.h: Likewise.
89894         * lib/unictype/pr_sentence_terminal.h: Likewise.
89895         * lib/unictype/pr_terminal_punctuation.h: Likewise.
89896         * lib/unictype/pr_unassigned_code_value.h: Likewise.
89897         * lib/unictype/pr_unified_ideograph.h: Likewise.
89898         * lib/unictype/pr_uppercase.h: Likewise.
89899         * lib/unictype/pr_xid_continue.h: Likewise.
89900         * lib/unictype/pr_xid_start.h: Likewise.
89901         * lib/unictype/pr_zero_width.h: Likewise.
89902         * lib/unictype/scripts.h: Likewise.
89903         * lib/unictype/scripts_byname.gperf: Likewise.
89904         * lib/unictype/sy_java_ident.h: Likewise.
89905         * lib/unigbrk/gbrkprop.h: Likewise.
89906         * lib/unilbrk/lbrkprop1.h: Likewise.
89907         * lib/unilbrk/lbrkprop2.h: Likewise.
89908         * lib/unilbrk/lbrktables.h: Likewise.
89909         * lib/unilbrk/lbrktables.c (unilbrk_table): Add a row and column for
89910         LBP_CP. Implement rule LB30.
89911         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0816..U+0819,
89912         U+081B..U+0823, U+0825..U+0827, U+0829..U+082D, U+0900, U+0955, U+109D,
89913         U+1A56, U+1A58..U+1A5E, U+1A60, U+1A62, U+1A65..U+1A6C, U+1A73..U+1A7C,
89914         U+1A7F, U+1CD0..U+1CD2, U+1CD4..U+1CE0, U+1CE2..U+1CE8, U+1CED, U+1DFD,
89915         U+2CEF..U+2CF1, U+A6F0..U+A6F1, U+A8E0..U+A8F1, U+A980..U+A982, U+A9B3,
89916         U+A9B6..U+A9B9, U+A9BC, U+AAB0, U+AAB2..U+AAB4, U+AAB7..U+AAB8,
89917         U+AABE..U+AABF, U+AAC1, U+ABE5, U+ABE8, U+ABED, U+11080..U+11081,
89918         U+110B3..U+110B6, U+110B9..U+110BA, U+110BD.
89919         (uc_width): Return 2 also for unassigned code points of planes 2 and 3.
89920         * lib/uninorm/composition-table.gperf: Regenerated for Unicode 5.2.0.
89921         * lib/uninorm/composition.c (struct composition_rule): Allow for 24
89922         bits instead of 16 bits in the code1 and code2 of each composition
89923         rule.
89924         (uc_composition): Update for Unicode 5.2.0.
89925         * lib/uninorm/decomposition-table1.h: Regenerated for Unicode 5.2.0.
89926         * lib/uninorm/decomposition-table2.h: Likewise.
89927         * lib/uniwbrk/wbrkprop.h: Likewise.
89928         * tests/unicase/test-cased.c: Likewise.
89929         * tests/unicase/test-ignorable.c: Likewise.
89930         * tests/unicase/test-uc_tolower.c: Likewise.
89931         * tests/unicase/test-uc_totitle.c: Likewise.
89932         * tests/unicase/test-uc_toupper.c: Likewise.
89933         * tests/unictype/test-categ_C.c: Likewise.
89934         * tests/unictype/test-categ_Cf.c: Likewise.
89935         * tests/unictype/test-categ_Cn.c: Likewise.
89936         * tests/unictype/test-categ_L.c: Likewise.
89937         * tests/unictype/test-categ_Ll.c: Likewise.
89938         * tests/unictype/test-categ_Lm.c: Likewise.
89939         * tests/unictype/test-categ_Lo.c: Likewise.
89940         * tests/unictype/test-categ_Lu.c: Likewise.
89941         * tests/unictype/test-categ_M.c: Likewise.
89942         * tests/unictype/test-categ_Mc.c: Likewise.
89943         * tests/unictype/test-categ_Mn.c: Likewise.
89944         * tests/unictype/test-categ_N.c: Likewise.
89945         * tests/unictype/test-categ_Nd.c: Likewise.
89946         * tests/unictype/test-categ_Nl.c: Likewise.
89947         * tests/unictype/test-categ_No.c: Likewise.
89948         * tests/unictype/test-categ_P.c: Likewise.
89949         * tests/unictype/test-categ_Pd.c: Likewise.
89950         * tests/unictype/test-categ_Po.c: Likewise.
89951         * tests/unictype/test-categ_S.c: Likewise.
89952         * tests/unictype/test-categ_Sc.c: Likewise.
89953         * tests/unictype/test-categ_So.c: Likewise.
89954         * tests/unictype/test-ctype_alnum.c: Likewise.
89955         * tests/unictype/test-ctype_alpha.c: Likewise.
89956         * tests/unictype/test-ctype_graph.c: Likewise.
89957         * tests/unictype/test-ctype_lower.c: Likewise.
89958         * tests/unictype/test-ctype_print.c: Likewise.
89959         * tests/unictype/test-ctype_punct.c: Likewise.
89960         * tests/unictype/test-ctype_upper.c: Likewise.
89961         * tests/unictype/test-decdigit.h: Likewise.
89962         * tests/unictype/test-digit.h: Likewise.
89963         * tests/unictype/test-numeric.h: Likewise.
89964         * tests/unictype/test-pr_alphabetic.c: Likewise.
89965         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
89966         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
89967         * tests/unictype/test-pr_bidi_european_digit.c: Likewise.
89968         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
89969         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
89970         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
89971         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
89972         * tests/unictype/test-pr_combining.c: Likewise.
89973         * tests/unictype/test-pr_composite.c: Likewise.
89974         * tests/unictype/test-pr_currency_symbol.c: Likewise.
89975         * tests/unictype/test-pr_dash.c: Likewise.
89976         * tests/unictype/test-pr_decimal_digit.c: Likewise.
89977         * tests/unictype/test-pr_deprecated.c: Likewise.
89978         * tests/unictype/test-pr_diacritic.c: Likewise.
89979         * tests/unictype/test-pr_extender.c: Likewise.
89980         * tests/unictype/test-pr_grapheme_base.c: Likewise.
89981         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
89982         * tests/unictype/test-pr_grapheme_link.c: Likewise.
89983         * tests/unictype/test-pr_id_continue.c: Likewise.
89984         * tests/unictype/test-pr_id_start.c: Likewise.
89985         * tests/unictype/test-pr_ideographic.c: Likewise.
89986         * tests/unictype/test-pr_ignorable_control.c: Likewise.
89987         * tests/unictype/test-pr_logical_order_exception.c: Likewise.
89988         * tests/unictype/test-pr_lowercase.c: Likewise.
89989         * tests/unictype/test-pr_numeric.c: Likewise.
89990         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
89991         * tests/unictype/test-pr_punctuation.c: Likewise.
89992         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
89993         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
89994         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
89995         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
89996         * tests/unictype/test-pr_uppercase.c: Likewise.
89997         * tests/unictype/test-pr_xid_continue.c: Likewise.
89998         * tests/unictype/test-pr_xid_start.c: Likewise.
89999         * tests/unictype/test-pr_zero_width.c: Likewise.
90000         * tests/unigbrk/test-uc-gbrk-prop.h: Likewise.
90001         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update for
90002         changed behaviour: line breaking is now disallowed between a letter
90003         or '=' and '('.
90004         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
90005         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
90006         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
90007         * tests/unilbrk/test-ulc-width-linebreaks.c (main): Likewise.
90008         * tests/uniwidth/test-uc_width2.sh: Same updates as in
90009         lib/uniwidth/width.c.
90010         * tests/uninorm/NormalizationTest.txt: Update from Unicode 5.2.0,
90011         without comments, but with the original copyright notice.
90012         * lib/unicase/special-casing-table.gperf: Regenerated; only comment
90013         changes.
90014         * lib/unictype/categ_Cc.h: Likewise.
90015         * lib/unictype/categ_Co.h: Likewise.
90016         * lib/unictype/categ_Cs.h: Likewise.
90017         * lib/unictype/categ_Lt.h: Likewise.
90018         * lib/unictype/categ_Me.h: Likewise.
90019         * lib/unictype/categ_Pc.h: Likewise.
90020         * lib/unictype/categ_Pe.h: Likewise.
90021         * lib/unictype/categ_Pf.h: Likewise.
90022         * lib/unictype/categ_Pi.h: Likewise.
90023         * lib/unictype/categ_Ps.h: Likewise.
90024         * lib/unictype/categ_Sk.h: Likewise.
90025         * lib/unictype/categ_Sm.h: Likewise.
90026         * lib/unictype/categ_Z.h: Likewise.
90027         * lib/unictype/categ_Zl.h: Likewise.
90028         * lib/unictype/categ_Zp.h: Likewise.
90029         * lib/unictype/categ_Zs.h: Likewise.
90030         * lib/unictype/ctype_blank.h: Likewise.
90031         * lib/unictype/ctype_cntrl.h: Likewise.
90032         * lib/unictype/ctype_digit.h: Likewise.
90033         * lib/unictype/ctype_space.h: Likewise.
90034         * lib/unictype/ctype_xdigit.h: Likewise.
90035         * lib/unictype/mirror.h: Likewise.
90036         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
90037         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
90038         * lib/unictype/pr_bidi_block_separator.h: Likewise.
90039         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
90040         * lib/unictype/pr_bidi_common_separator.h: Likewise.
90041         * lib/unictype/pr_bidi_control.h: Likewise.
90042         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
90043         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
90044         * lib/unictype/pr_bidi_pdf.h: Likewise.
90045         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
90046         * lib/unictype/pr_bidi_whitespace.h: Likewise.
90047         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
90048         * lib/unictype/pr_format_control.h: Likewise.
90049         * lib/unictype/pr_hex_digit.h: Likewise.
90050         * lib/unictype/pr_hyphen.h: Likewise.
90051         * lib/unictype/pr_ids_binary_operator.h: Likewise.
90052         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
90053         * lib/unictype/pr_iso_control.h: Likewise.
90054         * lib/unictype/pr_join_control.h: Likewise.
90055         * lib/unictype/pr_left_of_pair.h: Likewise.
90056         * lib/unictype/pr_line_separator.h: Likewise.
90057         * lib/unictype/pr_math.h: Likewise.
90058         * lib/unictype/pr_non_break.h: Likewise.
90059         * lib/unictype/pr_not_a_character.h: Likewise.
90060         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
90061         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
90062         * lib/unictype/pr_other_id_continue.h: Likewise.
90063         * lib/unictype/pr_other_id_start.h: Likewise.
90064         * lib/unictype/pr_other_lowercase.h: Likewise.
90065         * lib/unictype/pr_other_math.h: Likewise.
90066         * lib/unictype/pr_other_uppercase.h: Likewise.
90067         * lib/unictype/pr_paired_punctuation.h: Likewise.
90068         * lib/unictype/pr_paragraph_separator.h: Likewise.
90069         * lib/unictype/pr_pattern_syntax.h: Likewise.
90070         * lib/unictype/pr_pattern_white_space.h: Likewise.
90071         * lib/unictype/pr_private_use.h: Likewise.
90072         * lib/unictype/pr_quotation_mark.h: Likewise.
90073         * lib/unictype/pr_radical.h: Likewise.
90074         * lib/unictype/pr_soft_dotted.h: Likewise.
90075         * lib/unictype/pr_space.h: Likewise.
90076         * lib/unictype/pr_titlecase.h: Likewise.
90077         * lib/unictype/pr_variation_selector.h: Likewise.
90078         * lib/unictype/pr_white_space.h: Likewise.
90079         * lib/unictype/sy_c_ident.h: Likewise.
90080         * lib/unictype/sy_c_whitespace.h: Likewise.
90081         * lib/unictype/sy_java_whitespace.h: Likewise.
90082         * modules/uni*/*: Bump version number of expected libunistring version.
90083         Reported by Simon Josefsson.
90085 2011-01-09  Karl Heuer  <kwzh@gnu.org>
90087         useless-if-before-free: fix typo in --help and make the internal,
90088         automatic version date update process work once again.
90089         --help output contained a NUL character instead of the
90090         backslash-zero that was intended.  Also, the "must lie within
90091         the first 8 lines" line is on line 9, and hence not getting
90092         automatically updated.
90093         * build-aux/useless-if-before-free: Fix the former by adding a
90094         backslash, and the latter by condensing the three lines of what-it-does
90095         to a single line, leaving one line of slack for the future.
90097 2011-01-09  Bruno Haible  <bruno@clisp.org>
90099         uniwidth/width: Fix width of U+1D173..U+1D17A.
90100         * lib/gen-uni-tables.c (is_nonspacing, output_nonspacing_property,
90101         symbolic_width, output_width_property_test): New functions.
90102         (main): Invoke output_nonspacing_property, output_width_property_test.
90103         * lib/uniwidth/width.c (nonspacing_table_data): Set bits for
90104         U+1D173..U+1D17A.
90105         * tests/uniwidth/test-uc_width2.sh: For U+1D173..U+1D17A, expect 0, not
90106         1.
90107         * modules/uniwidth/*: Bump version number of expected libunistring
90108         version.
90109         * modules/unilbrk/*: Likewise.
90111 2011-01-08  Bruno Haible  <bruno@clisp.org>
90113         uninorm tests: Preserve copyright of Unicode data file.
90114         * tests/uninorm/NormalizationTest.txt: Re-add original copyright.
90115         Mention modifications.
90117 2011-01-08  Bruno Haible  <bruno@clisp.org>
90119         gen-uni-tables: Prepare for Unicode 5.2.0.
90120         * lib/gen-uni-tables.c (get_lbp): Allow for more than 32 LBP_* values.
90121         (debug_output_lbp, output_lbp): Update.
90123 2011-01-08  Bruno Haible  <bruno@clisp.org>
90125         unilbrk: Clarify gen-uni-tables.c code.
90126         * lib/gen-uni-tables.c (get_lbp): Assume REVISION_22 to be false. These
90127         were mistakes in UAX #14 revision 22 that are corrected in revision 24.
90128         Clarify what to do with unilbrk/lbrkprop.txt and uniwbrk/wbrkprop.txt.
90130 2011-01-07  Bruno Haible  <bruno@clisp.org>
90132         strtod: Restore errno when successfully parsing Infinity or NaN.
90133         * lib/strtod.c (strtod): After successfully parsing an Infinity or NaN,
90134         restore the original errno.
90136 2011-01-07  Bruno Haible  <bruno@clisp.org>
90138         remove test: Avoid failure on HP-UX 11.
90139         * tests/test-remove.c (main): Allow EEXIST as alternative error code.
90141 2011-01-07  Bruno Haible  <bruno@clisp.org>
90143         mkdir, mkdirat tests: Avoid failure on HP-UX 11.11.
90144         * tests/test-mkdir.h (test_mkdir): Allow EOPNOTSUPP as alternative
90145         error code.
90147 2011-01-07  Pádraig Brady  <P@draigBrady.com>
90149         ignore-value: fixup comments, and add Eric Blake
90150         as an author since he rewrote the macros.
90151         * lib/ignore-value.h (ignore_value):  State that
90152         we now support aggregates.  Also specify exactly
90153         when the GCC warn_unused_result feature was added.
90155 2011-01-06  Eric Blake  <eblake@redhat.com>
90157         ignore-value: support aggregate types
90158         * lib/ignore-value.h (ignore_value): Provide separate gcc
90159         definition.
90160         * modules/ignore-value-tests: New test module.
90161         * tests/test-ignore-value.c: New test.
90163         maint.mk: improve sc_prohibit_strcmp regex
90164         * top/maint.mk (sc_prohibit_strcmp): Detect strcmp()!=0, as
90165         documented.  Also, detect strcmp((expr),expr) == 0.  Exempt the
90166         definition of STRNEQ.
90168         signal: work around Haiku issue with SIGBUS
90169         * lib/siglist.h: Add comment.
90170         * lib/sig2str.c (numname_table): Swap SIGBUS order, to match
90171         strsignal's favoring of SIGSEGV.
90172         * tests/test-signal.c (main): Avoid test failure.
90173         * doc/posix-headers/signal.texi (signal.h): Document the issue.
90174         Reported by Scott McCreary.
90176         maint.mk: add pre-release check to ensure submodule commits are public
90177         * top/maint.mk (public-submodule-commit): New rule.
90178         (submodule-checks): New variable.
90179         (alpha beta stable): Depend on the variable.
90181 2011-01-05  Pádraig Brady  <P@draigBrady.com>
90182         and Jim Meyering  <meyering@redhat.com>
90184         ignore-value: make ignore_value more generic; deprecate ignore_ptr
90185         * lib/ignore-value.h: Include <stdint.h>, for decl of intptr_t.
90186         (ATTRIBUTE_DEPRECATED): Define.
90187         (_ignore_case): New function.
90188         (ignore_value): New macro, to replace the old function.
90189         (ignore_ptr): Arrange for any use to evoke a deprecation warning.
90190         * modules/ignore-value (Depends-on): Add stdint.
90192 2011-01-04  Eric Blake  <eblake@redhat.com>
90194         doc: regenerate INSTALL
90195         * doc/Makefile (INSTALL, INSTALL.ISO, INSTALL.UTF-8): Re-add
90196         @firstparagraphindent support, now that autoconf dropped it.
90197         (INSTALL_PRELUDE): Reinstate old macro.
90198         * doc/install.texi: Resync from autoconf.
90199         * doc/INSTALL: Reflect recent autoconf update.
90200         * doc/INSTALL.ISO: Likewise.
90201         * doc/INSTALL.UTF-8: Likewise.
90202         Reported by Karl Berry.
90204 2011-01-04  Bruce Korb  <address@hidden>
90206         git-version-gen: avoid a sub-shell
90207         * build-aux/git-version-gen: Redirect stderr in `...` via
90208         "exec 2>...", rather than via an added sub-shell.
90210 2011-01-03  Ben Pfaff  <blp@cs.stanford.edu>
90212         git-version-gen: use (...) rather than sh -c '...'
90213         * build-aux/git-version-gen: Rather than hard-coding a shell's name
90214         with "sh -c '...'", just use "(...)".  Less syntax is better, too.
90216 2011-01-03  Jim Meyering  <meyering@redhat.com>
90218         git-version-gen: convert leading TABs to spaces
90219         * build-aux/git-version-gen: Expand leading TABs.
90221         git-version-gen: handle failed "git rev-list"
90222         * build-aux/git-version-gen: Rather than leaking a "fatal" error
90223         from git and proceeding as if it had succeeded but printed no SHA1
90224         checksums, suppress the diagnostic and handle the failure.
90225         Reported by Bruce Korb in http://marc.info/?l=git&m=129399145930450&w=2
90227         git-version-gen: include command name in one more diagnostic
90228         * build-aux/git-version-gen: When the required .tarball-version file
90229         was missing or unreadable, you might see the diagnostic from "cat",
90230         but no trace of the name of the invoking script.  Now, you still see
90231         the diagnostic from cat, but also get one from "git-version-gen: ".
90232         Inspired by a patch from Bruce Korb.
90234         update-copyright: adjust test to match changed code
90235         * tests/test-update-copyright.sh: Change test's expected output
90236         to match new actual output.
90238 2011-01-02  Bruno Haible  <bruno@clisp.org>
90240         getlogin_r: Avoid test failure on HP-UX 11.
90241         * tests/test-getlogin_r.c (main): Allow an error code EINVAL instead of
90242         ERANGE when the second argument is zero.
90243         * doc/posix-functions/getlogin_r.texi: Document the HP-UX 11
90244         portability problem.
90246 2011-01-02  Bruce Korb  <bkorb@gnu.org>
90248         * build-aux/update-copyright: doc Simon's changes
90250 2011-01-02  Simon Josefsson  <simon@josefsson.org>
90252         * build-aux/update-copyright: Support UPDATE_COPYRIGHT_HOLDER
90253         environment variable.
90255 2011-01-02  Bruno Haible  <bruno@clisp.org>
90257         unigbrk: Avoid gcc warnings.
90258         * lib/unigbrk/u16-grapheme-breaks.c (u16_grapheme_breaks): Remove
90259         unused variable.
90260         * lib/unigbrk/u16-grapheme-prev.c (u16_grapheme_prev): Likewise.
90261         * lib/unigbrk/u8-grapheme-prev.c (u8_grapheme_prev): Likewise.
90262         * tests/unigbrk/test-u16-grapheme-breaks.c (main): Likewise.
90263         * tests/unigbrk/test-u32-grapheme-breaks.c (main): Likewise.
90264         * tests/unigbrk/test-u8-grapheme-breaks.c (test_u8_grapheme_breaks):
90265         Change type of first argument to 'const char *'.
90266         (main): Remove unused variable.
90267         * tests/unigbrk/test-u8-grapheme-next.c (test_u8_grapheme_next): Change
90268         type of first argument to 'const char *'.
90269         * tests/unigbrk/test-u8-grapheme-prev.c (test_u8_grapheme_prev):
90270         Likewise.
90271         (main): Change type of variable 's'.
90272         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Cast column number
90273         to 'int'.
90275 2011-01-02  Bruno Haible  <bruno@clisp.org>
90277         pwrite: Fix test whether it works and make it work on HP-UX 11.11.
90278         * m4/pwrite.m4 (gl_FUNC_PWRITE): Use AC_LANG_PROGRAM, not
90279         AC_LANG_SOURCE. Extend the test program to catch another HP-UX 11.11
90280         bug.
90281         * lib/pwrite.c: Undo 2010-12-31 patch.
90282         * doc/posix-functions/pwrite.texi: Document another HP-UX 11.11 bug.
90284 2011-01-02  Bruno Haible  <bruno@clisp.org>
90286         pread: Fix test whether it works.
90287         * m4/pread.m4 (gl_FUNC_PREAD): Use AC_LANG_PROGRAM, not AC_LANG_SOURCE.
90289 2011-01-02  Bruno Haible  <bruno@clisp.org>
90291         Fix detection of traditional Arabic locale on HP-UX, Solaris, Cygwin.
90292         * m4/locale-ar.m4 (gt_LOCALE_AR): Require that the locale encoding name
90293         ends in "6". Don't require a specific month name. Try also the locale
90294         names found on HP-UX 11 and Solaris 7.
90296 2011-01-02  Bruno Haible  <bruno@clisp.org>
90298         tcgetsid: Correct linkage in C++ mode on HP-UX 11.00.
90299         * lib/termios.in.h: In C++ mode, on HP-UX, include <sys/termios.h> with
90300         C linkage.
90301         * doc/posix-functions/tcgetsid.texi: Mention the HP-UX 11.00 bug.
90303 2011-01-01  Ben Pfaff  <blp@cs.stanford.edu>
90305         Rename uc_is_grapheme_cluster_break() to uc_is_grapheme_break()
90306         for consistency, since the "cluster" term is not used elsewhere.
90307         * lib/unigbrk.in.h: Update name.
90308         * lib/unigbrk/u16-grapheme-breaks.c: Update name.
90309         * lib/unigbrk/u16-grapheme-next.c: Update name.
90310         * lib/unigbrk/u16-grapheme-prev.c: Update name.
90311         * lib/unigbrk/u32-grapheme-breaks.c: Update name.
90312         * lib/unigbrk/u32-grapheme-next.c: Update name.
90313         * lib/unigbrk/u32-grapheme-prev.c: Update name.
90314         * lib/unigbrk/u8-grapheme-breaks.c: Update name.
90315         * lib/unigbrk/u8-grapheme-next.c: Update name.
90316         * lib/unigbrk/u8-grapheme-prev.c: Update name.
90317         * lib/unigbrk/uc-is-grapheme-break.c: Update name.
90318         * tests/unigbrk/test-uc-is-grapheme-break.c: Update name.
90319         Suggested by Bruno Haible.
90321 2011-01-01  Ben Pfaff  <blp@cs.stanford.edu>
90323         Remove module 'u8-grapheme-len' as too redundant with
90324         'u8-grapheme-next'.
90325         * modules/unigbrk/u8-grapheme-len: Delete file.
90326         * modules/unigbrk/u8-grapheme-len-tests: Delete file.
90327         * lib/unigbrk.in.h: Remove prototype for deleted function.
90328         * lib/unigbrk/u8-grapheme-len.c: Delete file.
90329         * tests/unigbrk/test-u8-grapheme-len.c: Delete file.
90331         Remove module 'u16-grapheme-len' as too redundant with
90332         'u16-grapheme-next'.
90333         * modules/unigbrk/u16-grapheme-len: Delete file.
90334         * modules/unigbrk/u16-grapheme-len-tests: Delete file.
90335         * lib/unigbrk.in.h: Remove prototype for deleted function.
90336         * lib/unigbrk/u16-grapheme-len.c: Delete file.
90337         * tests/unigbrk/test-u16-grapheme-len.c: Delete file.
90339         Remove module 'u32-grapheme-len' as too redundant with
90340         'u32-grapheme-next'.
90341         * modules/unigbrk/u32-grapheme-len: Delete file.
90342         * modules/unigbrk/u32-grapheme-len-tests: Delete file.
90343         * lib/unigbrk.in.h: Remove prototype for deleted function.
90344         * lib/unigbrk/u32-grapheme-len.c: Delete file.
90345         * tests/unigbrk/test-u32-grapheme-len.c: Delete file.
90347         Suggested by Bruno Haible.
90349 2011-01-01  Ben Pfaff  <blp@cs.stanford.edu>
90351         * unigbrk.in.h: Fix typo: "ben" => "been".
90352         Reported by Bruno Haible.
90354 2011-01-01  Jim Meyering  <meyering@redhat.com>
90356         maint: update almost all copyright ranges to include 2011
90357         Run the new "make update-copyright" rule.
90359 2011-01-01  Jim Meyering  <meyering@redhat.com>
90361         maint: update-copyright: exempt doc/INSTALL*
90362         * Makefile (update-copyright): Also exclude doc/INSTALL*,
90363         since they are generated.  Suggested by Bruno Haible.
90365 2011-01-01  Jim Meyering  <meyering@redhat.com>
90367         maint: refine the update-copyright rule
90368         * Makefile (update-copyright): Also exclude any file that includes
90369         the "GENERATED AUTOMATICALLY" comment, being careful not to exclude
90370         code that merely generates the comment.
90372 2010-12-31  Ben Pfaff  <blp@cs.stanford.edu>
90374         New module 'u8-grapheme-len'.
90375         * modules/unigbrk/u8-grapheme-len: New file.
90376         * modules/unigbrk/u8-grapheme-len-tests: New file.
90377         * lib/unigbrk.in.h: Add prototype for new function.
90378         * lib/unigbrk/u8-grapheme-len.c: New file.
90379         * tests/unigbrk/test-u8-grapheme-len.c: New file.
90381         New module 'u16-grapheme-len'.
90382         * modules/unigbrk/u16-grapheme-len: New file.
90383         * modules/unigbrk/u16-grapheme-len-tests: New file.
90384         * lib/unigbrk.in.h: Add prototype for new function.
90385         * lib/unigbrk/u16-grapheme-len.c: New file.
90386         * tests/unigbrk/test-u16-grapheme-len.c: New file.
90388         New module 'u32-grapheme-len'.
90389         * modules/unigbrk/u32-grapheme-len: New file.
90390         * modules/unigbrk/u32-grapheme-len-tests: New file.
90391         * lib/unigbrk.in.h: Add prototype for new function.
90392         * lib/unigbrk/u32-grapheme-len.c: New file.
90393         * tests/unigbrk/test-u32-grapheme-len.c: New file.
90395         New module 'u8-grapheme-next'.
90396         * modules/unigbrk/u8-grapheme-next: New file.
90397         * modules/unigbrk/u8-grapheme-next-tests: New file.
90398         * lib/unigbrk.in.h: Add prototype for new function.
90399         * lib/unigbrk/u8-grapheme-next.c: New file.
90400         * tests/unigbrk/test-u8-grapheme-next.c: New file.
90402         New module 'u16-grapheme-next'.
90403         * modules/unigbrk/u16-grapheme-next: New file.
90404         * modules/unigbrk/u16-grapheme-next-tests: New file.
90405         * lib/unigbrk.in.h: Add prototype for new function.
90406         * lib/unigbrk/u16-grapheme-next.c: New file.
90407         * tests/unigbrk/test-u16-grapheme-next.c: New file.
90409         New module 'u32-grapheme-next'.
90410         * modules/unigbrk/u32-grapheme-next: New file.
90411         * modules/unigbrk/u32-grapheme-next-tests: New file.
90412         * lib/unigbrk.in.h: Add prototype for new function.
90413         * lib/unigbrk/u32-grapheme-next.c: New file.
90414         * tests/unigbrk/test-u32-grapheme-next.c: New file.
90416         New module 'u8-grapheme-prev'.
90417         * modules/unigbrk/u8-grapheme-prev: New file.
90418         * modules/unigbrk/u8-grapheme-prev-tests: New file.
90419         * lib/unigbrk.in.h: Add prototype for new function.
90420         * lib/unigbrk/u8-grapheme-prev.c: New file.
90421         * tests/unigbrk/test-u8-grapheme-prev.c: New file.
90423         New module 'u16-grapheme-prev'.
90424         * modules/unigbrk/u16-grapheme-prev: New file.
90425         * modules/unigbrk/u16-grapheme-prev-tests: New file.
90426         * lib/unigbrk.in.h: Add prototype for new function.
90427         * lib/unigbrk/u16-grapheme-prev.c: New file.
90428         * tests/unigbrk/test-u16-grapheme-prev.c: New file.
90430         New module 'u32-grapheme-prev'.
90431         * modules/unigbrk/u32-grapheme-prev: New file.
90432         * modules/unigbrk/u32-grapheme-prev-tests: New file.
90433         * lib/unigbrk.in.h: Add prototype for new function.
90434         * lib/unigbrk/u32-grapheme-prev.c: New file.
90435         * tests/unigbrk/test-u32-grapheme-prev.c: New file.
90437         New module 'u8-grapheme-breaks'.
90438         * modules/unigbrk/u8-grapheme-breaks: New file.
90439         * modules/unigbrk/u8-grapheme-breaks-tests: New file.
90440         * lib/unigbrk.in.h: Add prototype for new function.
90441         * lib/unigbrk/u8-grapheme-breaks.c: New file.
90442         * tests/unigbrk/test-u8-grapheme-breaks.c: New file.
90444         New module 'u16-grapheme-breaks'.
90445         * modules/unigbrk/u16-grapheme-breaks: New file.
90446         * modules/unigbrk/u16-grapheme-breaks-tests: New file.
90447         * lib/unigbrk.in.h: Add prototype for new function.
90448         * lib/unigbrk/u16-grapheme-breaks.c: New file.
90449         * tests/unigbrk/test-u16-grapheme-breaks.c: New file.
90451         New module 'u32-grapheme-breaks'.
90452         * modules/unigbrk/u32-grapheme-breaks: New file.
90453         * modules/unigbrk/u32-grapheme-breaks-tests: New file.
90454         * lib/unigbrk.in.h: Add prototype for new function.
90455         * lib/unigbrk/u32-grapheme-breaks.c: New file.
90456         * tests/unigbrk/test-u32-grapheme-breaks.c: New file.
90458         New module 'ulc-grapheme-breaks'.
90459         * modules/unigbrk/ulc-grapheme-breaks: New file.
90460         * modules/unigbrk/ulc-grapheme-breaks-tests: New file.
90461         * m4/locale-ar.m4: New file.
90462         * lib/unigbrk/ulc-grapheme-breaks.c: New file.
90463         * tests/unigbrk/test-ulc-grapheme-breaks.c: New file.
90464         * tests/unigbrk/test-ulc-grapheme-breaks.sh: New file.
90466 2010-12-31  Ben Pfaff  <blp@cs.stanford.edu>
90468         gbrkprop: Fix implementation of uc_graphemeclusterbreak_property.
90469         * lib/unigbrk/gbrkprop.h: Regenerate with gen-uni-tables.c.  I had
90470         modified how this file was generated before I initially submitted
90471         the module, but failed to regenerate it.  This meant that several
90472         of the level2 entries were wrong.
90473         * lib/unigbrk/uc-gbrk-prop.h (uc_graphemeclusterbreak_property):
90474         Remove the division-by-2 that is folded into the table now that
90475         gbrkprop.h has been regenerated properly.  Now -1 entries are
90476         handled correctly.
90478         New module 'unigbrk/uc-gbrk-prop-tests'.
90479         * modules/unigbrk/uc-gbrk-prop-tests: New file.
90480         * lib/gen-uni-tables.c: Generate tests/test-uc-gbrk-prop.h.
90481         * tests/unigbrk/test-uc-gbrk-prop.c: New file.
90482         * tests/unigbrk/test-uc-gbrk-prop.h: New file.
90484 2011-01-01  Bruno Haible  <bruno@clisp.org>
90486         Avoid use of hexadecimal escapes.
90487         * tests/unigbrk/test-uc-is-grapheme-break.c (main): Use octal escapes
90488         instead of hexadecimal escapes.
90490 2011-01-01  Jim Meyering  <meyering@redhat.com>
90492         maint: new rule to update copyright year ranges
90493         * Makefile (update-copyright): New rule.
90495         maint: indent with TABs in Makefile
90496         * Makefile: Expand leading sequences of spaces to TABs
90498         version-etc: update the copyright year it reports
90499         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2011.
90501 2010-12-31  Bruno Haible  <bruno@clisp.org>
90503         isfinite: Avoid compiler bug of "cc -O" on HP-UX 11.11.
90504         * lib/isfinite.c (zerof, zerod, zerol): New variables.
90505         (gl_isfinitef, gl_isfinited, gl_isfinitel): Use them instead of literal
90506         zero.
90508 2010-12-31  Bruno Haible  <bruno@clisp.org>
90510         pwrite: Work around HP-UX 11.11 bug.
90511         * m4/pwrite.m4 (gl_FUNC_PWRITE): When pwrite exists, test whether it
90512         works and set REPLACE_PWRITE if not.
90513         * lib/pwrite.c (pwrite): Add an implementation that uses the system
90514         function.
90515         * doc/posix-functions/pwrite.texi: Document the HP-UX 11 bug.
90517 2010-12-31  Bruno Haible  <bruno@clisp.org>
90519         pread: Work around HP-UX 11 bugs.
90520         * m4/pread.m4 (gl_FUNC_PREAD): When pread exists, test whether it works
90521         and set REPLACE_PREAD if not.
90522         * doc/posix-functions/pread.texi: Document the HP-UX 11 bugs.
90524 2010-12-31  Eric Blake  <eblake@redhat.com>
90526         nl_langinfo: fix YESEXPR on Irix 6.5
90527         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Test for Irix bug.
90528         * lib/nl_langinfo.c (rpl_nl_langinfo): Work around it.
90529         * doc/posix-functions/nl_langinfo.texi (nl_langinfo): Document
90530         it.
90532 2010-12-31  Bruno Haible  <bruno@clisp.org>
90534         iconv: Document HP-UX 11 bug.
90535         * doc/posix-functions/iconv.texi: Document HP-UX 11 return value bug.
90537 2010-12-31  Bruno Haible  <bruno@clisp.org>
90539         ldexpl: Fix link error on HP-UX 11.
90540         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): When replacing ldexpl, set
90541         LDEXPL_LIBM, using $ISNANL_LIBM.
90543 2010-12-31  Eric Blake  <eblake@redhat.com>
90545         ftello: avoid compilation failure with SunStudio c89
90546         * lib/ftello.c (ftello): Use lseek, not llseek.
90548         tests: avoid failing coreutils tests on cygwin
90549         * tests/init.sh (find_exe_basenames_): Exempt [.exe.
90550         (create_exe_shims_): Return 0 when skipping.
90552 2010-12-31  Bruno Haible  <bruno@clisp.org>
90554         sys_select: Avoid warning about missing memset declaration on HP-UX 11.
90555         * lib/sys_select.in.h: On HP-UX, include also <string.h>.
90557 2010-12-31  Bruno Haible  <bruno@clisp.org>
90559         waitpid: Fix link error in C++ mode.
90560         * lib/sys_wait.in.h: Remove extern "C" { ... } group.
90562 2010-12-31  Bruno Haible  <bruno@clisp.org>
90564         isnan: Use GCC built-ins when possible.
90565         * lib/math.in.h (gl_isnan_f): Use __builtin_isnanf instead of
90566         __builtin_isnan.
90567         (gl_isnan_l): Use __builtin_isnanl instead of __builtin_isnan.
90568         (isnan): Define using GCC built-ins for GCC >= 4.0.
90570 2010-12-31  Bruno Haible  <bruno@clisp.org>
90572         isnand: Fix mistake.
90573         * m4/isnand.m4 (gl_HAVE_ISNAND_IN_LIBM): Use __builtin_isnan, not
90574         __builtin_isnand.
90576 2010-12-31  Bruno Haible  <bruno@clisp.org>
90578         open: Avoid C++ error on HP-UX 11.
90579         * lib/fcntl.in.h (open): Disable _GL_CXXALIASWARN invocation on HP-UX.
90581 2010-12-31  Bruno Haible  <bruno@clisp.org>
90583         time_r: Add missing declarations on HP-UX 11.
90584         * lib/time.in.h (localtime_r, gmtime_r): Test HAVE_DECL_LOCALTIME_R
90585         instead of HAVE_LOCALTIME_R.
90586         * m4/time_r.m4 (gl_TIME_R): Test whether localtime_r is declared. Set
90587         HAVE_LOCALTIME_R always.
90588         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize
90589         HAVE_DECL_LOCALTIME_R, not HAVE_LOCALTIME_R.
90590         * modules/time (Makefile.am): Substitute HAVE_DECL_LOCALTIME_R, not
90591         HAVE_LOCALTIME_R.
90592         * doc/posix-functions/gmtime_r.texi: Document the HP-UX 11 problem.
90593         * doc/posix-functions/localtime_r.texi: Likewise.
90595 2010-12-29  Eric Blake  <eblake@redhat.com>
90597         mountlist: tweak previous commit
90598         * lib/mountlist.c (me_remote): Guarantee trailing backslash.
90599         Reported by Paul Eggert.
90601         mountlist: fix local drive detection on cygwin
90602         * lib/mountlist.c (ME_REMOTE) [__CYGWIN__]: Provide implementation
90603         that works for cygwin.
90605 2010-12-29  Paul Eggert  <eggert@cs.ucla.edu>
90607         ftoastr, snprintf: ftoastr + snprintf module
90608         * lib/ftoastr.c: Use GNULIB_SNPRINTF, not GNULIB_SNPRINTF_POSIX,
90609         since the snprintf module now should be good enough here.
90610         * modules/snprintf (configure.ac): Add gl_MODULE_INDICATOR([snprintf]).
90611         It seems odd to have both gl_STDIO_MODULE_INDICATOR([snprintf])
90612         and gl_MODULE_INDICATOR([snprintf]), but the former enables
90613         GNULIB_SNPRINTF only for the test directory, and the latter
90614         doesn't arrange for gl_STDIO_H_DEFAULTS to be called, so neither
90615         seems to suffice by itself.
90617 2010-12-28  Paul Eggert  <eggert@cs.ucla.edu>
90619         alloca: one step towards thread-safety
90620         * lib/alloca.c (find_stack_direction): New arg PTR, to avoid the
90621         need for a static variable.  All callers changed.  This does not
90622         make the alloca replacement thread-safe, but it's one step.
90624         tests: minor indenting change
90625         * tests/init.sh: Sync from coreutils housekeeping patch
90626         <http://lists.gnu.org/r/coreutils/2010-12/msg00116.html>
90627         to keep lines within 80 columns.
90629 2010-12-28  Jim Meyering  <meyering@redhat.com>
90631         regex: don't infloop on persistent failing calloc
90632         * lib/regexec.c (build_trtable): Return failure indication upon
90633         calloc failure.  Otherwise, re_search_internal could infloop on OOM.
90634         In glibc, this was fixed for version 2.13:
90635         http://sourceware.org/bugzilla/show_bug.cgi?id=12348
90637 2010-12-28  Bruno Haible  <bruno@clisp.org>
90638             Paul Eggert <eggert@cs.ucla.edu>
90640         linkat: Make implementation robust against system behaviour variations.
90641         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Define
90642         LINK_FOLLOWS_SYMLINKS to -1 if it needs a runtime test in the Solaris
90643         way, and to -2 if it needs a generic runtime test.
90644         * lib/linkat.c (solaris_optimized_link_immediate,
90645         solaris_optimized_link_follow): New functions.
90646         * tests/test-linkat.c (EXPECT_LINK_HARDLINKS_SYMLINKS): New macro.
90647         (check_same_link): Use it.
90649 2010-12-26  Ben Pfaff  <blp@cs.stanford.edu>
90651         New module 'unigbrk/base'.
90652         * modules/unigbrk/base: New file.
90653         * lib/unigbrk.in.h: New file.
90655         New module 'unigbrk/uc-gbrk-prop'.
90656         * lib/gen-uni-tables.c: Generate lib/unigbrk/gbrkprop.h.
90657         * modules/unigbrk/uc-gbrk-prop: New file.
90658         * lib/unigbrk/gbrkprop.h: New file.
90659         * lib/unigbrk/uc-gbrk-prop.c: New file.
90661         New module 'unigbrk/uc-is-grapheme-break'.
90662         * modules/unigbrk/uc-is-grapheme-break: New file.
90663         * modules/unigbrk/uc-is-grapheme-break-tests: New file.
90664         * lib/unigbrk/uc-is-grapheme-break.c: New file.
90665         * tests/unigbrk/test-uc-is-grapheme-break.c: New file.
90666         * tests/unigbrk/test-uc-is-grapheme-break.sh: New file.
90667         * tests/unigbrk/GraphemeBreakTest.txt: New file.
90669         With corrections and tweaks by Bruno Haible <bruno@clisp.org>.
90671 2010-12-27  Bruno Haible  <bruno@clisp.org>
90673         linkat test: Avoid failure on Solaris 11 2010-11.
90674         * tests/test-linkat.c (main): Allow ENOTDIR as alternative error code.
90676 2010-12-27  Paul Eggert  <eggert@cs.ucla.edu>
90678         utimens: work around glibc rounding bug on more platforms
90679         * lib/utimens.c (fdutimens): Work around rounding bug even if
90680         HAVE_WORKING_UTIMES.  Reported for Linux 2.4.21 by Bruno Haible in
90681         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00298.html>.
90683 2010-12-27  Bruno Haible  <bruno@clisp.org>
90685         select tests: Improve comments.
90686         * tests/test-select.c (do_select): Add comments.
90688 2010-12-27  Bruno Haible  <bruno@clisp.org>
90690         select tests: Safer way of handling timeout.
90691         * tests/test-select.c (do_select_nowait): Zero-initialize the timeout
90692         at every invocation.
90694 2010-12-27  Bruno Haible  <bruno@clisp.org>
90696         select tests: Use 'bool' where appropriate.
90697         * tests/test-select.c (connect_to_socket): Change argument type to
90698         'bool'.
90700 2010-12-27  Bruno Haible  <bruno@clisp.org>
90702         select tests: Use existing modules.
90703         * modules/select-tests (Depends-on): Add pipe-posix, unistd.
90704         (configure.ac): Don't test for unistd.h.
90705         * tests/test-select.c: Include <unistd.h> always. Use pipe() as
90706         declared in <unistd.h>.
90708 2010-12-27  Bruno Haible  <bruno@clisp.org>
90710         mbrtowc: Work around a Solaris 7 bug.
90711         * m4/mbrtowc.m4 (gl_MBRTOWC_NULL_ARG1): New macro.
90712         (gl_MBRTOWC_NULL_ARG2): Renamed from gl_MBRTOWC_NULL_ARG.
90713         (gl_FUNC_MBRTOWC): Update. Define MBRTOWC_NULL_ARG2_BUG instead of
90714         MBRTOWC_NULL_ARG_BUG. Invoke gl_MBRTOWC_NULL_ARG1 and define
90715         MBRTOWC_NULL_ARG1_BUG.
90716         * lib/mbrtowc.c (rpl_mbrtowc): Use MBRTOWC_NULL_ARG2_BUG instead of
90717         MBRTOWC_NULL_ARG_BUG. Handle MBRTOWC_NULL_ARG1_BUG.
90718         * tests/test-mbrtowc.c (main): Test support of a NULL first argument.
90719         * doc/posix-functions/mbrtowc.texi: Mention the Solaris 7 bug.
90721 2010-12-27  Jim Meyering  <meyering@redhat.com>
90723         read-file.c: tweak syntax
90724         * lib/read-file.c (fread_file): Remove space after "*" in function
90725         definitions.
90727 2010-12-27  Bruno Haible  <bruno@clisp.org>
90729         times test: Avoid gcc warnings on OSF/1.
90730         * tests/test-times.c (main): Cast printf arguments from clock_t to
90731         'long int'.
90733 2010-12-27  Paul Eggert  <eggert@cs.ucla.edu>
90735         utimens: work around glibc rounding bug on older Linux kernels
90736         * lib/utimens.c (fdutimens): If invoking futimesat or futimes
90737         on Linux with a glibc whose utimes might not work, then work
90738         around a longstanding glibc bug involving rounding rather than
90739         truncated time stamps.  Reported for Linux 2.4.21 by Bruno Haible in
90740         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00113.html>.
90742 2010-12-26  Bruno Haible  <bruno@clisp.org>
90744         inet_ntop: Hide mismatch of declaration on NonStop Kernel.
90745         * lib/arpa_inet.in.h (inet_ntop): Use _GL_CXXALIAS_SYS_CAST instead of
90746         _GL_CXXALIAS_SYS.
90747         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90749 2010-12-26  Bruno Haible  <bruno@clisp.org>
90751         inet_ntop, inet_pton: Ensure declaration on NonStop Kernel.
90752         * lib/arpa_inet.in.h: On NonStop Kernel, include also <netdb.h>.
90753         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Likewise.
90754         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Include also <netdb.h> when
90755         looking for the declaration.
90756         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
90757         * doc/posix-functions/inet_ntop.texi: Document the NonStop Kernel
90758         problem.
90759         * doc/posix-functions/inet_pton.texi: Likewise.
90761 2010-12-26  Bruno Haible  <bruno@clisp.org>
90763         arpa_inet: Use the common idioms with C++ support.
90764         * lib/arpa_inet.in.h: Include c++defs.h.
90765         (inet_ntop, inet_pton): Declare using the macros with C++ namespace
90766         support.
90767         * modules/arpa_inet (Depends-on): Add c++defs.
90768         (Makefile.am): Substitute the contents of c++defs.h.
90769         * modules/arpa_inet-tests (Depends-on): Add arpa_inet-c++-tests.
90770         * modules/arpa_inet-c++-tests: New file.
90771         * tests/test-arpa_inet-c++.cc: New file.
90773 2010-12-25  Bruno Haible  <bruno@clisp.org>
90775         Fix more C++ link errors on Solaris 8.
90776         * modules/fcntl-h-c++-tests (test_fcntl_h_c___LDADD): Add
90777         $(LIB_EACCESS).
90778         * modules/stdio-c++-tests (test_stdio_c___LDADD): Likewise.
90779         * modules/stdlib-c++-tests (test_stdlib_c___LDADD): Likewise.
90780         * modules/sys_ioctl-c++-tests (test_sys_ioctl_c___LDADD): Likewise.
90781         * modules/wchar-c++-tests (test_wchar_c___LDADD): Likewise.
90782         * modules/wctype-c++-tests (test_wctype_c___LDADD): Likewise.
90784 2010-12-25  Bruno Haible  <bruno@clisp.org>
90786         printf-posix: Fix link error when a non-GCC compiler is used.
90787         * lib/stdio.in.h (printf): When not using GCC, override printf
90788         correctly.
90789         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90791 2010-12-25  Bruno Haible  <bruno@clisp.org>
90793         strerror_r-posix: Update doc.
90794         * doc/posix-functions/strerror_r.texi: Update doc about the return
90795         value. See <http://sources.redhat.com/bugzilla/show_bug.cgi?id=12204>.
90797 2010-12-25  Paul Eggert  <eggert@cs.ucla.edu>
90799         utimens: simplify the logic of the previous change
90800         * m4/utimes.m4 (gl_FUNC_UTIMES): Simplify the logic a bit.
90801         This should not affect whether the test succeeds or fails.
90803         utimens: configure better on hosts with NFS clock skew
90804         * m4/utimes.m4 (gl_FUNC_UTIMES): Don't assume that utimes (f, NULL)
90805         uses the clock of the local host.  It might use the clock of the
90806         NFS server.  Reported for Linux 2.4.21 client by Bruno Haible in
90807         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00113.html>.
90809 2010-12-25  Bruno Haible  <bruno@clisp.org>
90811         ptsname test: Avoid failure on Solaris.
90812         * tests/test-ptsname.c (main): For Solaris, use the recommended way to
90813         open a pseudo-terminal; don't use BSD-style ptys.
90814         * doc/posix-functions/ptsname.texi: Document the limitation on Solaris.
90816 2010-12-25  Bruno Haible  <bruno@clisp.org>
90818         ptsname: Avoid ERANGE failure on some systems.
90819         * lib/ptsname.c (buffer): Increase size.
90821 2010-12-25  Bruno Haible  <bruno@clisp.org>
90823         rename, renameat: Avoid test failures at NFS mounted locations.
90824         * tests/test-rename.h (assert_nonexistent): Remove the old directory,
90825         so that subsequent mkdir calls succeed.
90827 2010-12-25  Bruno Haible  <bruno@clisp.org>
90829         iswblank: Fix C++ link error on Solaris 8.
90830         * lib/wctype.in.h (iswblank): Declare using _GL_FUNCDECL_RPL or
90831         _GL_FUNCDECL_SYS.
90833 2010-12-25  Bruno Haible  <bruno@clisp.org>
90835         unistd: Fix C++ link error on Solaris 8.
90836         * modules/unistd-c++-tests (test_unistd_c___LDADD): Add $(LIB_EACCESS).
90838 2010-12-25  Bruno Haible  <bruno@clisp.org>
90840         readlink doc: Mention an old glibc bug.
90841         * doc/posix-functions/readlink.texi: Mention glibc 2.4 bug (BZ #2450).
90843 2010-12-25  Bruno Haible  <bruno@clisp.org>
90845         fcntl-h: Fix for use of C++ on glibc systems.
90846         * lib/fcntl.in.h: Include <sys/stat.h> before include_next <fcntl.h>
90847         also on glibc systems in C++ mode.
90848         Reported by Gary V. Vaughan <gary@gnu.org>.
90850 2010-12-25  Bruno Haible  <bruno@clisp.org>
90852         roundl-ieee: Make it work on OSF/1 5.1 with cc.
90853         * modules/roundl-ieee (Depends-on): Add floorl-ieee, ceill-ieee.
90855 2010-12-25  Bruno Haible  <bruno@clisp.org>
90857         truncl-ieee: Make it work on OSF/1 5.1 with cc.
90858         * doc/posix-functions/truncl.texi: Mention the OSF/1 5.1 bug.
90859         * m4/truncl.m4 (gl_FUNC_TRUNCL): If gl_FUNC_TRUNCL_IEEE is also used,
90860         test whether truncl works according to ISO C 99 with IEC 60559.
90861         * m4/truncl-ieee.m4: New file.
90862         * modules/truncl-ieee (Files): Add it and m4/minus-zero.m4,
90863         m4/signbit.m4.
90864         (configure.ac): Invoke gl_FUNC_TRUNCL_IEEE.
90866 2010-12-25  Bruno Haible  <bruno@clisp.org>
90868         ceill-ieee: Make it work on OSF/1 5.1 with cc.
90869         * doc/posix-functions/ceill.texi: Mention the OSF/1 5.1 bug.
90870         * m4/ceill.m4 (gl_FUNC_CEILL): If gl_FUNC_CEILL_IEEE is also used,
90871         test whether ceill works according to ISO C 99 with IEC 60559.
90872         * m4/ceill-ieee.m4: New file.
90873         * modules/ceill-ieee (Files): Add it and m4/minus-zero.m4,
90874         m4/signbit.m4.
90875         (configure.ac): Invoke gl_FUNC_CEILL_IEEE.
90877 2010-12-25  Bruno Haible  <bruno@clisp.org>
90879         Ensure all prerequisites of <wchar.h> are included.
90880         * m4/btowc.m4 (gl_FUNC_BTOWC): Include <stddef.h>, <stdio.h>, <time.h>
90881         before <wchar.h>.
90882         * m4/mbrlen.m4 (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL,
90883         gl_MBRLEN_NUL_RETVAL): Likewise.
90884         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
90885         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL,
90886         AC_FUNC_MBRTOWC): Likewise.
90887         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
90888         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
90889         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
90890         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
90891         Likewise.
90892         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
90893         * m4/wchar_h.m4 (gl_WCHAR_H_INLINE_OK): Likewise.
90894         (gl_WCHAR_H): Improve comments.
90895         * m4/wctype_h.m4 (gl_WCTYPE_H): Likewise.
90897 2010-12-25  Bruno Haible  <bruno@clisp.org>
90899         strtok_r: Fix C syntax error in autoconf macro.
90900         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Don't use UTF-8 encoded U+00A0
90901         characters in test program.
90903 2010-12-24  Bruno Haible  <bruno@clisp.org>
90905         ceil, trunc, round: Fix gcc warnings.
90906         * lib/ceil.c (MIN): Undefine before redefining.
90907         * lib/trunc.c (MIN): Likewise.
90908         * lib/round.c (MIN): Likewise.
90909         Include <math.h> first.
90911 2010-12-24  Bruno Haible  <bruno@clisp.org>
90913         select tests: Avoid failures on OSF/1 5.1.
90914         * tests/test-select.c (test_accept_first, test_socket_pair): Ignore
90915         failure of closing the last socket; it may fail with ECONNRESET.
90917 2010-12-24  Eric Blake  <eblake@redhat.com>
90919         stdint: avoid HP-UX 10.20 preprocessor bug
90920         * lib/stdint.in.h (INT64_MAX, UINT64_MAX): Check via #ifdef rather
90921         than #if.
90922         * tests/test-floor2.c (main): Likewise.
90923         Reported by Peter O'Gorman.
90925         pipe: make obsoletion transition easier
90926         * lib/pipe.h: Restore file as thin shim around "spawn-pipe.h".
90927         * modules/pipe (Files): Include revived file.
90928         (Include): Drop reference, to mirror getdate's behavior.
90930 2010-12-24  Bruno Haible  <bruno@clisp.org>
90932         sys_socket: Hide mismatch of declarations on NonStop Kernel.
90933         * lib/sys_socket.in.h (connect, bind, sendto, setsockopt): Use
90934         _GL_CXXALIAS_SYS_CAST instead of _GL_CXXALIAS_SYS.
90935         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90937 2010-12-24  Bruno Haible  <bruno@clisp.org>
90939         gethostname: Ensure declaration on NonStop Kernel.
90940         * lib/unistd.in.h: Include <netdb.h> also on NonStop Kernel systems.
90941         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90943 2010-12-24  Bruno Haible  <bruno@clisp.org>
90945         sys_select: Ensure all necessary types on NonStop Kernel.
90946         * lib/sys_select.in.h: If the system does not have <sys/select.h>,
90947         include <sys/time.h>.
90948         * doc/posix-headers/sys_select.texi: Mention that it's missing on
90949         NonStop Kernel.
90950         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90952 2010-12-24  Bruno Haible  <bruno@clisp.org>
90954         sys_select: Remove unneeded include.
90955         * lib/sys_select.in.h: Don't include <sys/socket.h> on platforms that
90956         have <sys/select.h>.
90958 2010-12-24  Bruno Haible  <bruno@clisp.org>
90960         gethostname: Provide a fallback for HOST_NAME_MAX.
90961         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): When neither HOST_NAME_MAX
90962         nor MAXHOSTNAMELEN is found in the usual system headers, use 256
90963         instead.
90964         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90966 2010-12-24  Bruno Haible  <bruno@clisp.org>
90968         sigaction tests: Allow missing SA_RESETHAND and SA_RESTART.
90969         * tests/test-sigaction.c (SA_RESETHAND): Fall back to 0.
90970         (SA_RESTART): Likewise.
90971         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90973 2010-12-24  Bruno Haible  <bruno@clisp.org>
90975         signal: Define NSIG.
90976         * lib/signal.in.h (NSIG): Define to 32 on NonStop Kernel.
90977         * tests/test-signal.c (nsig): New variable.
90978         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
90980 2010-12-24  Bruno Haible  <bruno@clisp.org>
90982         rename, renameat: Avoid test failures on OSF/1 5.1.
90983         * tests/test-rename.h (test_rename): Allow EEXIST and ENOTDIR as
90984         alternative error codes.
90985         * tests/test-renameat.c (main): Likewise.
90987 2010-12-24  Bruno Haible  <bruno@clisp.org>
90989         *printf: Detect large precisions bug on Solaris 10/SPARC.
90990         * m4/printf.m4 (gl_PRINTF_PRECISION): Add one more test code, provided
90991         by Paul Eggert.
90992         * tests/test-snprintf-posix.h (test_function): Add this test code here
90993         too.
90994         * tests/test-sprintf-posix.h (test_function): Likewise.
90995         * tests/test-vasnprintf-posix.c (test_function): Likewise.
90996         * tests/test-vasprintf-posix.c (test_function): Likewise.
90997         * doc/posix-functions/fprintf.texi: Mention Solaris 10 bug as worked
90998         around by gnulib.
90999         * doc/posix-functions/printf.texi: Likewise.
91000         * doc/posix-functions/snprintf.texi: Likewise.
91001         * doc/posix-functions/sprintf.texi: Likewise.
91002         * doc/posix-functions/vfprintf.texi: Likewise.
91003         * doc/posix-functions/vprintf.texi: Likewise.
91004         * doc/posix-functions/vsnprintf.texi: Likewise.
91005         * doc/posix-functions/vsprintf.texi: Likewise.
91006         * doc/posix-functions/dprintf.texi: Undo last commit.
91007         * doc/posix-functions/vdprintf.texi: Likewise.
91009 2010-12-23  Paul Eggert  <eggert@cs.ucla.edu>
91011         tests: port test-fdutimensat.c to Solaris 8
91012         * tests/test-fdutimensat.c (do_fdutimens): Don't assume
91013         fdutimensat works with a nonnegative fd and AT_SYMLINK_NOFOLLOW.
91014         On Solaris 8, it fails with errno == ENOSYS, because there is no
91015         futimens (so it can't use the fd), and there is no lutimens (so it
91016         can't implement AT_SYMLINK_NOFOLLOW on symlinks).
91018         vsnprintf: make more consistent with snprintf; doc fixes
91020         * doc/posix-functions/snprintf.texi (snprintf): The workaround for
91021         the byte count return problem was promoted from the snprintf-posix
91022         to the snprintf module.
91023         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
91024         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Also check
91025         gl_SNPRINTF_RETVAL_C99, for consistency with gl_FUNC_SNPRINTF.
91026         * tests/test-snprintf.c (main): Check the byte count returned.
91027         * tests/test-vsnprintf.c (main): Likewise.
91029 2010-12-23  Eric Blake  <eblake@redhat.com>
91031         sigpipe: relax to LGPLv2+, since it did not have any LGPLv3+ parts
91032         * modules/sigpipe (License): Relax license.
91034 2010-12-22  Paul Eggert  <eggert@cs.ucla.edu>
91036         doc: document Solaris printf bug with large float precisions
91037         * doc/posix-functions/dprintf.texi (dprintf):
91038         * doc/posix-functions/fprintf.texi (fprintf):
91039         * doc/posix-functions/printf.texi (printf):
91040         * doc/posix-functions/snprintf.texi (snprintf):
91041         * doc/posix-functions/sprintf.texi (sprintf):
91042         * doc/posix-functions/vdprintf.texi (vdprintf):
91043         * doc/posix-functions/vfprintf.texi (vfprintf):
91044         * doc/posix-functions/vprintf.texi (vprintf):
91045         * doc/posix-functions/vsnprintf.texi (vsnprintf):
91046         * doc/posix-functions/vsprintf.texi (vsprintf):
91047         Mention that these functions mishandle large floating point
91048         precisions on Solaris 10.  The same bug is also present in Solaris
91049         8, and I assume earlier.  This causes "cd gnulib-tests; make
91050         check" to fail on Solaris 8 (and I assume, later) when building
91051         the latest coreutils, in test-vasprintf-posix's call to
91052         my_asprintf (&result, "%.4000f %d", 1.0, 99).  I have not checked
91053         the wide flavors (e.g., wprintf) so this patch just updates the
91054         documentation for the narrow ones.
91056         test-posixtm.c: add two tests
91057         * tests/test-posixtm.c: Add two tests, to highlight the
91058         bug in Solaris 10 (and earlier) localtime.  Gnulib doesn't work
91059         around this bug; this is merely to document it.
91061 2010-12-22  Bruno Haible  <bruno@clisp.org>
91063         getlogin_r: Work around portability problem on OSF/1.
91064         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Detect the OSF/1 problem.
91065         * lib/unistd.in.h (getlogin_r): Replace if REPLACE_GETLOGIN_R is set.
91066         * lib/getlogin_r.c (getlogin_r): When getlogin_r exists, invoke it and
91067         test for a truncated result.
91068         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_GETLOGIN_R.
91069         * modules/unistd (Makefile.am): Substitute REPLACE_GETLOGIN_R.
91070         * modules/getlogin_r (Depends-on): Add memchr.
91071         * doc/posix-functions/getlogin_r.texi: Mention the OSF/1 problem.
91073 2010-12-22  Bruno Haible  <bruno@clisp.org>
91075         ptsname: Avoid test failure on OSF/1 5.1.
91076         * modules/ptsname-tests (Depends-on): Add 'same-inode'.
91077         * tests/test-ptsname.c: Include <sys/stat.h>, same-inode.h.
91078         (same_slave): New function.
91079         (main): Use it to compare ptsname's result with the expected file name.
91081 2010-12-22  Bruno Haible  <bruno@clisp.org>
91083         Port extended stdio modules to HP NonStop Kernel.
91084         * lib/stdio-impl.h (_IOERR, _IOREAD, _IOWRT, _IORW) [__TANDEM]: New
91085         macros.
91086         * lib/fbufmode.c: Update comments.
91087         * lib/fflush.c: Likewise.
91088         * lib/fpurge.c: Likewise.
91089         * lib/freadable.c: Likewise.
91090         * lib/freadahead.c: Likewise.
91091         * lib/freading.c: Likewise.
91092         * lib/freadptr.c: Likewise.
91093         * lib/freadseek.c: Likewise.
91094         * lib/fseeko.c: Likewise.
91095         * lib/fseterr.c: Likewise.
91096         * lib/fwritable.c: Likewise.
91097         * lib/fwriting.c: Likewise.
91098         Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
91100 2010-12-22  Bruno Haible  <bruno@clisp.org>
91102         ttyname_r: Work around bug on OSF/1 5.1.
91103         * doc/posix-functions/ttyname_r.texi: Mention the OSF/1 bug.
91104         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Detect the OSF/1 bug. Say "no"
91105         instead of "guessing no" when the OSF/1 bug or the Solaris bug is
91106         present.
91107         * lib/ttyname_r.c (ttyname_r): Update comments.
91109 2010-12-22  Bruno Haible  <bruno@clisp.org>
91111         round: Implement result sign according to IEEE 754.
91112         * lib/round.c (MIN, MINUS_ZERO): New macros.
91113         (FLOOR_FREE_ROUND): Return -0.0 for -0.5 < x < 0.
91114         * tests/test-roundf-ieee.c (main): Test also values between -1 and 1.
91115         * tests/test-round-ieee.c (main): Likewise.
91116         * tests/test-roundl-ieee.c (main): Likewise.
91118         trunc: Implement result sign according to IEEE 754.
91119         * lib/trunc.c (MIN, MINUS_ZERO): New macros.
91120         (FUNC): Return +0.0 for 0 < x < 1 and -0.0 for -1 < x < 0.
91121         * tests/test-trunc2.c: Include minus-zero.h.
91122         (MINUS_ZERO): New macro.
91123         (trunc_reference): Keep in sync with lib/trunc.c.
91124         * tests/test-truncf2.c: Include minus-zero.h.
91125         (MINUS_ZERO): New macro.
91126         (truncf_reference): Keep in sync with lib/trunc.c.
91127         * tests/test-truncf-ieee.c (main): Test also values between -1 and 1.
91128         * tests/test-trunc-ieee.c (main): Likewise.
91129         * tests/test-truncl-ieee.c (main): Likewise.
91131         ceil: Implement result sign according to IEEE 754.
91132         * lib/ceil.c (MIN, MINUS_ZERO): New macros.
91133         (FUNC): Return -0.0 for -1 < x < 0.
91134         * tests/test-ceil2.c: Include minus-zero.h.
91135         (MINUS_ZERO): New macro.
91136         (ceil_reference): Keep in sync with lib/ceil.c.
91137         * tests/test-ceilf2.c: Include minus-zero.h.
91138         (MINUS_ZERO): New macro.
91139         (ceilf_reference): Keep in sync with lib/ceil.c.
91140         * tests/test-ceilf-ieee.c (main): Test also values between -1 and 1.
91141         * tests/test-ceil-ieee.c (main): Likewise.
91142         * tests/test-ceill-ieee.c (main): Likewise.
91144         floor: Implement result sign according to IEEE 754.
91145         * lib/floor.c (FUNC): Return +0.0 for 0 < x < 1.
91146         * tests/test-floor2.c (floor_reference): Keep in sync with lib/floor.c.
91147         * tests/test-floorf2.c (floorf_reference): Likewise.
91148         * tests/test-floorf-ieee.c (main): Test also values between -1 and 1.
91149         * tests/test-floor-ieee.c (main): Likewise.
91150         * tests/test-floorl-ieee.c (main): Likewise.
91152 2010-12-22  Bruno Haible  <bruno@clisp.org>
91154         getaddrinfo: Update doc.
91155         * doc/posix-functions/gai_strerror.texi: Return type is also different
91156         on AIX and HP-UX.
91158 2010-12-22  Paul Eggert  <eggert@cs.ucla.edu>
91160         getaddrinfo, inet_ntop: Update doc for Solaris.
91161         * doc/posix-functions/gai_strerror.texi: Return type is also an
91162         issue on Solaris 9 and earlier.
91163         * doc/posix-functions/inet_ntop.texi: 4th arg type is also an issue
91164         on Solaris 10 and earlier.
91166 2010-12-21  Bruno Haible  <bruno@clisp.org>
91168         New module 'roundl-ieee'.
91169         * modules/roundl-ieee: New file.
91170         * m4/roundl.m4 (gl_FUNC_ROUNDL): If gl_FUNC_ROUNDL_IEEE is also used,
91171         test whether roundl works according to ISO C 99 with IEC 60559.
91172         * m4/roundl-ieee.m4: New file.
91173         * modules/roundl-ieee-tests: New file.
91174         * tests/test-roundl-ieee.c: New file, based on tests/test-roundl.c.
91175         * tests/test-roundl.c (main): Remove signbit tests.
91176         * modules/roundl-tests (Depends-on): Remove signbit.
91177         * doc/posix-functions/roundl.texi: Mention the new module.
91179 2010-12-21  Bruno Haible  <bruno@clisp.org>
91181         New module 'truncl-ieee'.
91182         * modules/truncl-ieee: New file.
91183         * modules/truncl-ieee-tests: New file.
91184         * tests/test-truncl-ieee.c: New file, based on tests/test-truncl.c.
91185         * tests/test-truncl.c (main): Remove signbit tests.
91186         * modules/truncl-tests (Depends-on): Remove signbit.
91187         * doc/posix-functions/truncl.texi: Mention the new module.
91189 2010-12-21  Bruno Haible  <bruno@clisp.org>
91191         New module 'ceill-ieee'.
91192         * modules/ceill-ieee: New file.
91193         * modules/ceill-ieee-tests: New file.
91194         * tests/test-ceill-ieee.c: New file, based on tests/test-ceill.c.
91195         * tests/test-ceill.c (main): Remove signbit tests.
91196         * modules/ceill-tests (Depends-on): Remove signbit.
91197         * doc/posix-functions/ceill.texi: Mention the new module.
91199 2010-12-21  Bruno Haible  <bruno@clisp.org>
91201         New module 'floorl-ieee'.
91202         * modules/floorl-ieee: New file.
91203         * modules/floorl-ieee-tests: New file.
91204         * tests/test-floorl-ieee.c: New file, based on tests/test-floorl.c.
91205         * tests/test-floorl.c (main): Remove signbit tests.
91206         * modules/floorl-tests (Depends-on): Remove signbit.
91207         * doc/posix-functions/floorl.texi: Mention the new module.
91209 2010-12-21  Bruno Haible  <bruno@clisp.org>
91211         New module 'round-ieee'.
91212         * modules/round-ieee: New file.
91213         * m4/round.m4 (gl_FUNC_ROUND): If gl_FUNC_ROUND_IEEE is also used, test
91214         whether round works according to ISO C 99 with IEC 60559.
91215         * m4/round-ieee.m4: New file.
91216         * modules/round-ieee-tests: New file.
91217         * tests/test-round-ieee.c: New file, based on tests/test-roundf-ieee.c.
91218         * tests/test-round1.c (main): Remove signbit tests.
91219         * modules/round-tests (Depends-on): Remove 'signbit'.
91220         * doc/posix-functions/round.texi: Mention the new module.
91222 2010-12-21  Bruno Haible  <bruno@clisp.org>
91224         New module 'trunc-ieee'.
91225         * modules/trunc-ieee: New file.
91226         * m4/trunc.m4 (gl_FUNC_TRUNC): If gl_FUNC_TRUNC_IEEE is also used, test
91227         whether trunc works according to ISO C 99 with IEC 60559.
91228         * m4/trunc-ieee.m4: New file.
91229         * lib/math.in.h (trunc): Replace if REPLACE_TRUNC is set.
91230         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNC.
91231         * modules/math (Makefile.am): Substitute REPLACE_TRUNC.
91232         * modules/trunc-ieee-tests: New file.
91233         * tests/test-trunc-ieee.c: New file, based on tests/test-truncf-ieee.c.
91234         * tests/test-trunc1.c (main): Remove signbit tests.
91235         * modules/trunc-tests (Depends-on): Remove 'signbit'.
91236         * doc/posix-functions/trunc.texi: Mention the new module.
91238 2010-12-21  Bruno Haible  <bruno@clisp.org>
91240         New module 'ceil-ieee'.
91241         * modules/ceil-ieee: New file.
91242         * m4/ceil.m4 (gl_FUNC_CEIL): Require gl_MATH_H_DEFAULTS. If
91243         gl_FUNC_CEIL_IEEE is also used, test whether ceil works according to
91244         ISO C 99 with IEC 60559.
91245         * m4/ceil-ieee.m4: New file.
91246         * modules/ceil (Files): Add lib/ceil.c.
91247         (Depends-on): Add 'float'.
91248         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
91249         * lib/math.in.h (ceil): New declaration.
91250         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEIL,
91251         REPLACE_CEIL.
91252         * modules/math (Makefile.am): Substitute GNULIB_CEIL, REPLACE_CEIL.
91253         * modules/ceil-ieee-tests: New file.
91254         * tests/test-ceil-ieee.c: New file, based on tests/test-ceilf-ieee.c.
91255         * tests/test-math-c++.cc: Check the signature of 'ceil'.
91256         * doc/posix-functions/ceil.texi: Mention the new module.
91258 2010-12-21  Bruno Haible  <bruno@clisp.org>
91260         New module 'floor-ieee'.
91261         * modules/floor-ieee: New file.
91262         * m4/floor.m4 (gl_FUNC_FLOOR): Require gl_MATH_H_DEFAULTS. If
91263         gl_FUNC_FLOOR_IEEE is also used, test whether floor works according to
91264         ISO C 99 with IEC 60559.
91265         * m4/floor-ieee.m4: New file.
91266         * modules/floor (Files): Add lib/floor.c.
91267         (Depends-on): Add 'float'.
91268         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
91269         * lib/math.in.h (floor): New declaration.
91270         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOOR,
91271         REPLACE_FLOOR.
91272         * modules/math (Makefile.am): Substitute GNULIB_FLOOR, REPLACE_FLOOR.
91273         * modules/floor-ieee-tests: New file.
91274         * tests/test-floor-ieee.c: New file, based on tests/test-floorf-ieee.c.
91275         * tests/test-math-c++.cc: Check the signature of 'floor'.
91276         * doc/posix-functions/floor.texi: Mention the new module.
91278 2010-12-21  Bruno Haible  <bruno@clisp.org>
91280         New module 'roundf-ieee'.
91281         * modules/roundf-ieee: New file.
91282         * m4/roundf.m4 (gl_FUNC_ROUNDF): If gl_FUNC_ROUNDF_IEEE is also used,
91283         test whether roundf works according to ISO C 99 with IEC 60559.
91284         * m4/roundf-ieee.m4: New file.
91285         * modules/roundf-ieee-tests: New file.
91286         * tests/test-roundf-ieee.c: New file, based on tests/test-roundf1.c.
91287         * tests/test-roundf1.c (main): Remove signbit tests.
91288         * modules/roundf-tests (Depends-on): Remove 'signbit'.
91289         * doc/posix-functions/roundf.texi: Mention the new module.
91291 2010-12-21  Bruno Haible  <bruno@clisp.org>
91293         New module 'truncf-ieee'.
91294         * modules/truncf-ieee: New file.
91295         * m4/truncf.m4 (gl_FUNC_TRUNCF): If gl_FUNC_TRUNCF_IEEE is also used,
91296         test whether truncf works according to ISO C 99 with IEC 60559.
91297         * m4/truncf-ieee.m4: New file.
91298         * lib/math.in.h (truncf): Replace if REPLACE_TRUNCF is set.
91299         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNCF.
91300         * modules/math (Makefile.am): Substitute REPLACE_TRUNCF.
91301         * modules/truncf-ieee-tests: New file.
91302         * tests/test-truncf-ieee.c: New file, based on tests/test-truncf1.c.
91303         * tests/test-truncf1.c (main): Remove signbit tests.
91304         * modules/truncf-tests (Depends-on): Remove 'signbit'.
91305         * doc/posix-functions/truncf.texi: Mention the new module.
91307 2010-12-21  Bruno Haible  <bruno@clisp.org>
91309         New module 'ceilf-ieee'.
91310         * modules/ceilf-ieee: New file.
91311         * m4/ceilf.m4 (gl_FUNC_FLOORF): If gl_FUNC_CEILF_IEEE is also used,
91312         test whether ceilf works according to ISO C 99 with IEC 60559.
91313         * m4/ceilf-ieee.m4: New file.
91314         * modules/ceilf-ieee-tests: New file.
91315         * tests/test-ceilf-ieee.c: New file, based on tests/test-ceilf1.c.
91316         * tests/test-ceilf1.c (main): Remove signbit tests.
91317         * modules/ceilf-tests (Depends-on): Remove 'signbit'.
91318         * doc/posix-functions/ceilf.texi: Mention the new module.
91320 2010-12-21  Bruno Haible  <bruno@clisp.org>
91322         New module 'floorf-ieee'.
91323         * modules/floorf-ieee: New file.
91324         * m4/floorf.m4 (gl_FUNC_FLOORF): If gl_FUNC_FLOORF_IEEE is also used,
91325         test whether floorf works according to ISO C 99 with IEC 60559.
91326         * m4/floorf-ieee.m4: New file.
91327         * modules/floorf-ieee-tests: New file.
91328         * tests/test-floorf-ieee.c: New file, based on tests/test-floorf1.c.
91329         * tests/test-floorf1.c (main): Remove signbit tests.
91330         * modules/floorf-tests (Depends-on): Remove 'signbit'.
91331         * doc/posix-functions/floorf.texi: Mention the new module.
91333 2010-12-21  Bruno Haible  <bruno@clisp.org>
91335         Support for minus zero in autoconf macros.
91336         * m4/minus-zero.m4: New file, based on tests/minus-zero.h.
91337         * m4/signbit.m4 (gl_FLOAT_SIGNBIT_CODE, gl_DOUBLE_SIGNBIT_CODE,
91338         gl_LONG_DOUBLE_SIGNBIT_CODE, gl_FLOATTYPE_SIGNBIT_CODE): New macros.
91339         * tests/minus-zero.h: Update comments.
91341 2010-12-21  Bruno Haible  <bruno@clisp.org>
91343         Tests for module 'ceil'.
91344         * modules/ceil-tests: New file.
91345         * tests/test-ceil1.c: New file, based on tests/test-ceill.c.
91346         * tests/test-ceil2.c: New file, based on tests/test-ceilf2.c.
91348 2010-12-21  Bruno Haible  <bruno@clisp.org>
91350         Tests for module 'floor'.
91351         * modules/floor-tests: New file.
91352         * tests/test-floor1.c: New file, based on tests/test-floorl.c.
91353         * tests/test-floor2.c: New file, based on tests/test-floorf2.c.
91355 2010-12-21  Bruno Haible  <bruno@clisp.org>
91357         math: Fix indentation.
91358         * lib/math.in.h (floorf): Fix indentation.
91360 2010-12-21  Bruno Haible  <bruno@clisp.org>
91362         Fix cross-compilation guesses on Solaris.
91363         * m4/fopen.m4 (gl_FUNC_FOPEN): Correct shell pattern so that it does
91364         not match "solaris2.10".
91365         * m4/open.m4 (gl_FUNC_OPEN): Likewise.
91366         * m4/printf.m4 (gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_DIRECTIVE_N,
91367         gl_VSNPRINTF_ZEROSIZE_C99): Likewise.
91369 2010-12-21  Paul Eggert  <eggert@cs.ucla.edu>
91371         snprintf: port snprintf (NULL, 0, ...) to Solaris 8 and 9
91372         This fixes a problem observed with the latest coreutils snapshot
91373         that caused a test to fail on Solaris 8.  src/csplit.c's call
91374         snprintf (NULL, 0, format, UINT_MAX) returns -1 on Solaris 9 and
91375         earlier, instead of returning the number of bytes that would have
91376         been generated; this causes csplit to incorrectly report memory
91377         exhaustion.
91378         * m4/printf.m4 (gl_SNPRINTF_RETVAL_C99): Also check for
91379         snprintf (NULL, 0, ...) and (for good measure) snprintf (buf, 0, ...).
91380         Guess that it doesn't work on Solaris 2.6 through 9.  Adjust
91381         comments to match.
91382         (gl_PRINTF_SIZES_C99, gl_PRINTF_DIRECTIVE_F, gl_SNPRINTF_RETVAL_C99):
91383         Fix typo in matching older versions of Solaris: "solaris2.10"
91384         is matched by the shell pattern "solaris2.[0-9]*".  This matters
91385         only for guessing while cross-compiling.
91386         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Also check gl_SNPRINTF_RETVAL_C99.
91388 2010-12-20  Paul Eggert  <eggert@cs.ucla.edu>
91390         ftoastr: fix comment again
91391         * lib/ftoastr.h: Fix typo in comment.  Noted by Ben Pfaff in
91392         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00149.html>.
91393         Also, simplify example a bit by using flags = 0.
91395 2010-12-20  Bruno Haible  <bruno@clisp.org>
91397         round*, trunc*: Update documentation regarding glibc.
91398         * doc/posix-functions/roundf.texi: Mention missing declaration problem.
91399         * doc/posix-functions/round.texi: Likewise.
91400         * doc/posix-functions/roundl.texi: Likewise.
91401         * doc/posix-functions/truncf.texi: Likewise.
91402         * doc/posix-functions/trunc.texi: Likewise.
91403         * doc/posix-functions/truncl.texi: Likewise.
91405 2010-12-20  Bruno Haible  <bruno@clisp.org>
91407         roundf, round, roundl: Update documentation regarding OSF/1 5.1.
91408         * doc/posix-functions/roundf.texi: Mention OSF/1 5.1 problem.
91409         * doc/posix-functions/round.texi: Likewise.
91410         * doc/posix-functions/roundl.texi: Likewise.
91412 2010-12-20  Bruno Haible  <bruno@clisp.org>
91414         ttyname_r: Add missing declaration on HP-UX 11.
91415         * lib/unistd.in.h (ttyname_r): Test HAVE_DECL_TTYNAME_R instead of
91416         HAVE_TTYNAME_R.
91417         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test whether ttyname_r is
91418         declared. Set HAVE_TTYNAME_R always.
91419         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
91420         HAVE_DECL_TTYNAME_R, not HAVE_TTYNAME_R.
91421         * modules/unistd (Makefile.am): Substitute HAVE_DECL_TTYNAME_R, not
91422         HAVE_TTYNAME_R.
91423         * doc/posix-functions/ttyname_r.texi: Document the HP-UX 11 problem.
91425 2010-12-20  Bruno Haible  <bruno@clisp.org>
91427         getlogin, getlogin_r: Document HP-UX 11.11 bugs.
91428         * doc/posix-functions/getlogin.texi: Document HP-UX 11.11 bug.
91429         * doc/posix-functions/getlogin_r.texi: Likewise.
91430         * tests/test-getlogin.c: Include <errno.h>.
91431         (main): Avoid test failure on HP-UX 11.11.
91432         * tests/test-getlogin_r.c (main): Likewise.
91434 2010-12-20  Bruno Haible  <bruno@clisp.org>
91436         getlogin_r: Add missing declaration on HP-UX 11.
91437         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Test whether getlogin_r is
91438         declared also when it exists as a function.
91439         * doc/posix-functions/getlogin_r.texi: Document this workaround.
91441 2010-12-20  Bruno Haible  <bruno@clisp.org>
91443         wcsrtombs: Don't confuse mbstate_t with rpl_mbstate_t.
91444         * lib/wcsrtombs.c: If gnulib overrides mbstate_t, define wcsrtombs
91445         through wcrtomb.
91447 2010-12-19  Paul Eggert  <eggert@cs.ucla.edu>
91449         ftoastr: fix comment
91450         * lib/ftoastr.h: Fix typo in comment.  Noted by Ben Pfaff in
91451         <http://lists.gnu.org/r/bug-gnulib/2010-12/msg00130.html>.
91453 2010-12-19  Bruno Haible  <bruno@clisp.org>
91455         isnan: Ensure it is a macro.
91456         * lib/math.in.h (isnan): Define as a macro if not already a macro.
91457         * doc/posix-functions/isnan.texi: Mention problem on IRIX, OSF/1,
91458         Solaris.
91460 2010-12-19  Bruno Haible  <bruno@clisp.org>
91462         ldexpl test: Fix link error on OSF/1 5.1.
91463         * modules/ldexpl-tests (Makefile.am): Define test_ldexpl_LDADD.
91465 2010-12-19  Bruno Haible  <bruno@clisp.org>
91467         wctype: Make it work in C++ mode on OSF/1 5.1.
91468         * lib/wctype.in.h (iswblank): Declare but not define here.
91469         * lib/iswblank.c: New file, extracted from lib/wctype.in.h.
91470         * m4/wctype_h.m4 (gl_WCTYPE_H): Arrange to compile it if needed.
91471         * modules/wctype (Files): Add lib/iswblank.c.
91473 2010-12-19  Bruno Haible  <bruno@clisp.org>
91475         signal: Document problem with type of SIGRTMIN, SIGRTMAX on OSF/1 5.1.
91476         * doc/posix-headers/signal.texi: Document OSF/1 5.1 problem.
91477         * lib/strsignal.c (strsignal): Cast SIGRTMIN to 'int'.
91479 2010-12-19  Bruno Haible  <bruno@clisp.org>
91481         sys_socket: Use POSIX compatible declarations on OSF/1 5.1.
91482         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): On OSF/1, define
91483         _POSIX_PII_SOCKET.
91484         * doc/posix-functions/recv.texi: Document the OSF/1 problem.
91485         * doc/posix-functions/recvfrom.texi: Likewise.
91486         * doc/posix-functions/send.texi: Likewise.
91487         * doc/posix-functions/sendto.texi: Likewise.
91489 2010-12-19  Bruno Haible  <bruno@clisp.org>
91491         tcgetsid: Add missing declaration on OSF/1 5.1.
91492         * lib/termios.in.h (tcgetsid): Test HAVE_DECL_TCGETSID instead of
91493         HAVE_TCGETSID.
91494         * m4/tcgetsid.m4 (gl_FUNC_TCGETSID): Test whether tcgetsid is declared.
91495         Don't set HAVE_TCGETSID.
91496         * m4/termios_h.m4 (gl_TERMIOS_H_DEFAULTS): Initialize
91497         HAVE_DECL_TCGETSID, not HAVE_TCGETSID.
91498         * modules/termios (Makefile.am): Substitute HAVE_DECL_TCGETSID, not
91499         HAVE_TCGETSID.
91500         * doc/posix-functions/tcgetsid.texi: Mention the OSF/1 5.1 problem.
91502 2010-12-19  Bruno Haible  <bruno@clisp.org>
91504         stdio: Fix problem with popen() declaration on OSF/1 5.1.
91505         * lib/stdio.in.h: During the include_next statement, let recursive
91506         includes of this file include only the system header file.
91508 2010-12-19  Bruno Haible  <bruno@clisp.org>
91510         iconv_open: Fix regression from 2010-12-04.
91511         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Fix typo.
91512         Reported by Noah Lavine <noah.b.lavine@gmail.com>.
91514 2010-12-19  Bruno Haible  <bruno@clisp.org>
91516         stdbool test: Avoid a gcc warning.
91517         * tests/test-stdbool.c (main): Fail if e1 is false.
91518         Reported by Jim Meyering.
91520 2010-12-19  Jim Meyering  <meyering@redhat.com>
91522         setenv: restore to working order
91523         $HAVE_SETENV is used in gl_FUNC_SETENV, yet its definitions were
91524         mistakenly removed.
91525         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Restore code to set
91526         HAVE_SETENV.
91527         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Restore code to initialize
91528         HAVE_SETENV.
91530 2010-12-19  Bruno Haible  <bruno@clisp.org>
91532         Document some different function declarations on OSF/1 5.1.
91533         * doc/posix-functions/gai_strerror.texi: Mention different declaration.
91534         * doc/posix-functions/inet_ntop.texi: Likewise.
91535         * doc/posix-functions/gethostname.texi: Likewise.
91536         * lib/unistd.in.h (gethostname): Update comment.
91538 2010-12-19  Bruno Haible  <bruno@clisp.org>
91540         doc: Mention vasprintf-posix module.
91541         * doc/glibc-functions/asprintf.texi: Mention the workarounds present in
91542         the 'vasprintf-posix' module.
91543         * doc/glibc-functions/vasprintf.texi: Likewise.
91545 2010-12-19  Bruno Haible  <bruno@clisp.org>
91547         unsetenv: Add missing declaration on OSF/1 5.1.
91548         * lib/stdlib.in.h (setenv): Test HAVE_DECL_UNSETENV, not HAVE_UNSETENV.
91549         * m4/setenv.m4 (gl_FUNC_UNSETENV): Test whether unsetenv is declared.
91550         Don't set HAVE_UNSETENV. In the test program, set _BSD.
91551         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_UNSETENV,
91552         not HAVE_UNSETENV.
91553         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_UNSETENV, not
91554         HAVE_UNSETENV.
91555         * doc/posix-functions/unsetenv.texi: Mention the OSF/1 5.1 problem.
91557 2010-12-19  Bruno Haible  <bruno@clisp.org>
91559         setenv: Add missing declaration on OSF/1 5.1.
91560         * lib/stdlib.in.h (setenv): Test HAVE_DECL_SETENV, not HAVE_SETENV.
91561         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Test whether setenv is
91562         declared. Don't set HAVE_SETENV.
91563         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_SETENV,
91564         not HAVE_SETENV.
91565         * modules/stdlib (Makefile.am): Substitute HAVE_DECL_SETENV, not
91566         HAVE_SETENV.
91567         * doc/posix-functions/setenv.texi: Mention the OSF/1 5.1 problem.
91569 2010-12-19  Bruno Haible  <bruno@clisp.org>
91571         nl_langinfo tests: Avoid gcc warning.
91572         * tests/test-nl_langinfo.c: Don't enable the GCC pragma for GCC 4.2.
91574 2010-12-19  Bruno Haible  <bruno@clisp.org>
91576         mknod: Avoid error in C++ mode on OSF/1 with GCC.
91577         * lib/sys_stat.in.h (mknod): Use _GL_CXXALIAS_SYS_CAST instead of
91578         _GL_CXXALIAS_SYS.
91580 2010-12-19  Bruno Haible  <bruno@clisp.org>
91582         stdbool: Relax test.
91583         * tests/test-stdbool.c (e): Don't require that casts from a variable's
91584         address to 'bool' work in static initializer, for compilers other than
91585         GCC.
91587 2010-12-19  Bruno Haible  <bruno@clisp.org>
91589         ftello: Add missing declaration on OSF/1 5.1.
91590         * lib/stdio.in.h (ftello): Test HAVE_DECL_FTELLO, not HAVE_FTELLO.
91591         * m4/ftello.m4 (gl_FUNC_FTELLO): Test whether ftello is declared.
91592         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_FTELLO.
91593         * modules/stdio (Makefile.am): Substitute HAVE_DECL_FTELLO.
91594         * doc/posix-functions/ftello.texi: Mention the OSF/1 5.1 problem.
91596 2010-12-19  Bruno Haible  <bruno@clisp.org>
91598         fseeko: Add missing declaration on OSF/1 5.1.
91599         * lib/stdio.in.h (fseeko): Test HAVE_DECL_FSEEKO, not HAVE_FSEEKO.
91600         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Test whether fseeko is declared.
91601         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_FSEEKO.
91602         * modules/stdio (Makefile.am): Substitute HAVE_DECL_FSEEKO.
91603         * doc/posix-functions/fseeko.texi: Mention the OSF/1 5.1 problem.
91605 2010-12-19  Bruno Haible  <bruno@clisp.org>
91607         fchdir: Add missing declaration on OSF/1 5.1.
91608         * lib/unistd.in.h (fchdir): Provide declaration if systems lacks it.
91609         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Check whether fchdir is declared.
91610         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_FCHDIR.
91611         * modules/unistd (Makefile.am): Substitute HAVE_DECL_FCHDIR.
91612         * doc/posix-functions/fchdir.texi: Mention the OSF/1 5.1 problem.
91614 2010-12-19  Bruno Haible  <bruno@clisp.org>
91616         relocatable-prog-wrapper: Separate from relocatable-prog.
91617         * modules/relocatable-prog (Makefile.am): Define uninstall-hook and
91618         uninstall-relocwrapper rule here.
91619         * modules/relocatable-prog-wrapper (Makefile.am): ... not here.
91620         Reported by Ian Beckwith <ianb@erislabs.net>.
91622 2010-12-19  Bruno Haible  <bruno@clisp.org>
91624         unistr/u8-mbsnlen: Add missing dependency.
91625         * modules/unistr/u8-mbsnlen (Depends-on): Add unistr/u8-mbtouc.
91626         Reported by Ian Beckwith <ianb@erislabs.net>.
91628 2010-12-19  Bruno Haible  <bruno@clisp.org>
91630         iconv: Make it possible again to use this module without 'iconv-h'.
91631         * modules/iconv (configure.ac): Don't invoke gl_ICONV_MODULE_INDICATOR
91632         if it is not defined.
91633         Reported by Ian Beckwith <ianb@erislabs.net>.
91635 2010-12-18  Paul Eggert  <eggert@cs.ucla.edu>
91637         acl: port to Solaris 8 when copying from tmpfs to ufs
91638         * lib/copy-acl.c (qcopy_acl): Also allow EINVAL as an ignorable
91639         error number.  Problem observed on Solaris 8 with latest
91640         coreutils, with "mv A B", where A is on a tmpfs file system and B
91641         is on a ufs file system.  This caused coreutils' mv/part-symlink
91642         test to fail.
91644         tests: set fail=0 at start
91645         * tests/init.sh (setup_): Move fail=0 initialization here ...
91646         (mktempd_): ... from here, so that tests can rely on fail being
91647         set to 0 initially.  This fixes a problem in coreutils; see:
91648         http://lists.gnu.org/r/coreutils/2010-12/msg00083.html
91650 2010-12-18  Bruno Haible  <bruno@clisp.org>
91652         memmem-simple: Stylistic changes.
91653         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Avoid possible gcc warning.
91654         Fix preprocessor directive indentation.
91656 2010-12-15  Pádraig Brady  <P@draigBrady.com>
91658         memmem, memmem-simple: reorganize and expand empty needle check
91659         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE, gl_FUNC_MEMMEM): Move all
91660         functional checks to memmem-simple so that one has a fully functional
91661         memmem by using just this module.
91662         Restrict the performance only check to the memmem module.
91663         Also expand the empty needle check to ensure the correct
91664         pointer is returned, not just a non NULL pointer.
91665         * doc/glibc-functions/memmem.texi: Rearrange the portability
91666         documentation to correlate with the rearranged checks.
91667         Clarify exactly how the memmem and memmem-simple modules
91668         relate to each other.
91670 2010-12-15  Pádraig Brady  <P@draigBrady.com>
91671             Bruno Haible  <bruno@clisp.org>
91673         Improve cross-compilation guesses for uClibc.
91674         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): When cross-compiling, assume
91675         that uClibc does not have the glibc bug.
91676         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Likewise.
91677         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE): Likewise.
91679 2010-12-14  Eric Blake  <eblake@redhat.com>
91681         configmake: provide fallbacks for oldest supported autotools
91682         * m4/configmake.m4: New file.
91683         * modules/configmake (Files): Ship it.
91684         (configure.ac): Use it to guarantee fallbacks.
91686 2010-12-13  Pádraig Brady  <P@draigBrady.com>
91688         read-file: Improve handling of large files
91689         * lib/read-file.c (fread_file): Minimize realloc()s
91690         for regular files, and better manage sizes around SIZE_MAX.
91692 2010-12-13  Eric Blake  <eblake@redhat.com>
91694         cloexec, fcntl: relax license
91695         * modules/cloexec (License): Change from LGPLv3+ to LGPLv2+, with
91696         consent from all contributors.
91697         * modules/fcntl (License): Likewise.
91699 2010-12-10  Bruno Haible  <bruno@clisp.org>
91701         Tests for module 'pipe-posix'.
91702         * modules/pipe-posix-tests: New file.
91703         * tests/test-pipe.c: New file, based on tests/test-pipe2.c.
91705 2010-12-10  Bruno Haible  <bruno@clisp.org>
91707         pipe-posix: Make it work in C++ mode.
91708         * lib/unistd.in.h: Don't include <io.h>, <fcntl.h> for pipe.
91709         (pipe): Use common idiom, not a macro definition.
91710         * lib/pipe.c: New file.
91711         * m4/pipe.m4: New file.
91712         * modules/pipe-posix (Description): Enhance.
91713         (Files): Add lib/pipe.c, m4/pipe.m4.
91714         (configure.ac): Invoke gl_FUNC_PIPE.
91715         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_PIPE.
91716         * modules/unistd (Makefile.am): Substitute HAVE_PIPE.
91717         * tests/test-unistd-c++.cc: Check the signature of pipe.
91719 2010-12-10  Bruno Haible  <bruno@clisp.org>
91721         Rename module 'pipe' to 'spawn-pipe'.
91722         * modules/spawn-pipe: New file, renamed from modules/pipe.
91723         (Files, configure.ac, Makefile.am): Update.
91724         (Include): Mention "spawn-pipe.h" instead of "pipe.h".
91725         * modules/pipe: Reduce to an obsolete indirection to 'spawn-pipe'.
91726         * lib/spawn-pipe.h: New file, renamed from lib/pipe.h.
91727         * lib/spawn-pipe.c: New file, renamed from lib/pipe.c. Include
91728         "spawn-pipe.h" instead of "pipe.h".
91729         * m4/spawn-pipe.m4: New file, renamed from m4/pipe.m4. Rename gl_PIPE
91730         to gl_SPAWN_PIPE.
91731         * modules/spawn-pipe-tests: New file, renamed from modules/pipe-tests.
91732         (Files, Makefile.am): Update.
91733         * tests/test-spawn-pipe.sh: New file, renamed from tests/test-pipe.sh.
91734         Update.
91735         * tests/test-spawn-pipe.c: New file, renamed from tests/test-pipe.c.
91736         Include "spawn-pipe.h" instead of "pipe.h".
91737         * lib/csharpcomp.c: Include "spawn-pipe.h" instead of "pipe.h".
91738         * lib/javacomp.c: Likewise.
91739         * lib/javaversion.c: Likewise.
91740         * lib/pipe-filter-gi.c: Likewise.
91741         * lib/pipe-filter-ii.c: Likewise.
91742         * modules/csharpcomp (Depends-on): Add 'spawn-pipe', remove 'pipe'.
91743         * modules/javacomp (Depends-on): Likewise.
91744         * modules/javaversion (Depends-on): Likewise.
91745         * modules/pipe-filter-gi (Depends-on): Likewise.
91746         * modules/pipe-filter-ii (Depends-on): Likewise.
91747         * MODULES.html.sh (Executing programs): Update.
91748         * NEWS: Mention the change.
91750 2010-12-10  Eric Blake  <eblake@redhat.com>
91752         pipe-posix: new module
91753         * modules/pipe-posix: New file.
91754         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set default.
91755         (gl_UNISTD_H): Check for declaration.
91756         * modules/unistd (Makefile.am): Substitute it.
91757         * lib/unistd.in.h (pipe): Provide it for mingw.
91758         * doc/posix-functions/pipe.texi (pipe): Update documentation.
91759         * MODULES.html.sh (File descriptor based Input/Output): Likewise.
91761 2010-12-07  Bruno Haible  <bruno@clisp.org>
91763         unistr/u8-strcmp: Avoid collision with libc function on Solaris 11.
91764         * lib/unistr.in.h (u8_strcmp) [__sun]: Declare with real name
91765         u8_strcmp_gnu.
91766         * modules/unistr/u8-strcmp (configure.ac): Bump version number.
91768 2010-12-06  Bruno Haible  <bruno@clisp.org>
91770         Update internal documentation.
91771         * m4/README: Document new idioms for AC_RUN_IFELSE invocations.
91773 2010-12-04  Bruno Haible  <bruno@clisp.org>
91775         Put more information about failed tests into the test return codes.
91776         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Change test
91777         program so that it returns an enumerated value (0, 1, 2, 3, 4, ...).
91778         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
91779         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
91780         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Likewise.
91781         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
91782         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
91783         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
91784         * m4/isapipe.m4 (gl_PREREQ_ISAPIPE): Likewise.
91785         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
91786         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Likewise.
91787         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
91788         * m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
91789         * m4/stdint.m4 (gl_STDINT_H): Likewise.
91790         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Change test program so that it
91791         returns a bit mask.
91792         * m4/canonicalize.m4 (gl_FUNC_REALPATH_WORKS): Likewise.
91793         * m4/chown.m4 (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Likewise.
91794         * m4/dup2.m4 (gl_FUNC_DUP2): Likewise.
91795         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): Likewise.
91796         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
91797         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Likewise.
91798         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
91799         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
91800         * m4/iconv.m4 (AM_ICONV_LINK): Likewise.
91801         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Likewise.
91802         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
91803         * m4/isnanf.m4 (gl_ISNANF_WORKS): Likewise.
91804         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
91805         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Likewise.
91806         * m4/link.m4 (gl_FUNC_LINK): Likewise.
91807         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
91808         * m4/mbrlen.m4 (gl_MBRLEN_RETVAL): Likewise.
91809         * m4/mbrtowc.m4 (gl_MBRTOWC_RETVAL): Likewise.
91810         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
91811         * m4/memchr.m4 (gl_FUNC_MEMCHR): Likewise.
91812         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
91813         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
91814         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Likewise.
91815         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
91816         * m4/open.m4 (gl_FUNC_OPEN): Likewise.
91817         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
91818         * m4/popen.m4 (gl_FUNC_POPEN): Likewise.
91819         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE,
91820         gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE,
91821         gl_PRINTF_DIRECTIVE_A, gl_PRINTF_DIRECTIVE_F, gl_PRINTF_DIRECTIVE_LS,
91822         gl_PRINTF_PRECISION): Likewise.
91823         * m4/regex.m4 (gl_REGEX): Likewise.
91824         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
91825         * m4/rmdir.m4 (gl_FUNC_RMDIR): Likewise.
91826         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Likewise.
91827         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
91828         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
91829         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
91830         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Likewise.
91831         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Likewise.
91832         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
91833         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
91834         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
91835         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
91836         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Likewise.
91837         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
91838         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
91839         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
91840         * m4/utimes.m4 (gl_FUNC_UTIMES): Likewise.
91841         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
91842         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
91843         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Likewise.
91844         (gl_FLOATTYPE_SIGN_LOCATION): Change test program so that it returns an
91845         enumerated value.
91846         * m4/acl.m4 (gl_ACL_GET_FILE): Use "if ... return 1; return 0;" style.
91848 2010-12-04  Bruno Haible  <bruno@clisp.org>
91850         Update for Solaris 11 2010-11.
91851         * doc/{glibc,posix}-{functions,headers}: Add info about Solaris 11
91852         Express, released in November 2010.
91854 2010-12-04  Bruno Haible  <bruno@clisp.org>
91856         nproc: Relax license.
91857         * modules/nproc (License): Change to LGPL, with consent by Glen Lenker
91858         and Paul Eggert.
91859         Requested by Ludovic Courtès <ludo@gnu.org>.
91861 2010-12-01  Paul Eggert  <eggert@cs.ucla.edu>
91863         utimecmp: fine-grained src to nearby coarse-grained dest
91865         * lib/utimecmp.c (utimecmp): When UTIMECMP_TRUNCATE_SOURCE is set,
91866         and the source is on a file system with higher-resolution time
91867         stamps, than the destination, and _PC_TIMESTAMP_RESOLUTION does
91868         not work, and the time stamps are close together, the algorithm to
91869         determine the exact resolution from the read-back mtime was buggy:
91870         it had a "!=" where it should have had an "==".  This bug has been
91871         in the code ever since it was introduced to gnulib.
91872         Problem reported by Dan Jacobson in
91873         <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=7529>.
91875 2010-11-30  Bruno Haible  <bruno@clisp.org>
91877         strerror_r-posix: Fix autoconf test.
91878         * m4/strerror_r.m4 (gl_FUNC_STRERROR_R): Fix typo.
91880 2010-11-28  Bruno Haible  <bruno@clisp.org>
91881             Paul Eggert  <eggert@cs.ucla.edu>
91883         Tests for module 'getdomainname'.
91884         * modules/getdomainname-tests: New file.
91885         * tests/test-getdomainname.c: New file, based on
91886         tests/test-gethostname.c.
91888 2010-11-28  Bruno Haible  <bruno@clisp.org>
91889             Paul Eggert  <eggert@cs.ucla.edu>
91891         getdomainname: Use the system function when possible.
91892         * lib/unistd.in.h: Include <netdb.h>, for getdomainname's declaration.
91893         (getdomainname): Replace if needed. Provide the declaration if it is
91894         missing. Don't use _GL_CXXALIAS_SYS_CAST.
91895         * lib/getdomainname.c: Include <limits.h> and <sys/systeminfo.h>.
91896         (getdomainname): When the system has getdomainname, call the system
91897         function. When sysinfo (SI_SRPC_DOMAIN, ...) is possible, use that.
91898         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Require
91899         gl_HEADER_SYS_SOCKET and gl_HEADER_NETDB. Test whether the function is
91900         found in libnsl. Look for the declaration also in <netdb.h>. Replace
91901         the function if its second argument is of type 'int' or if it is found
91902         in libnsl.
91903         (gl_PREREQ_GETDOMAINNAME): Define HAVE_GETDOMAINNAME. Check for
91904         <sys/systeminfo.h> and sysinfo().
91905         * modules/getdomainname (Depends-on): Add netdb, sys_socket.
91906         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
91907         HAVE_DECL_GETDOMAINNAME and REPLACE_GETDOMAINNAME instead of
91908         HAVE_GETDOMAINNAME.
91909         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETDOMAINNAME and
91910         REPLACE_GETDOMAINNAME instead of HAVE_GETDOMAINNAME.
91911         * doc/glibc-functions/getdomainname.texi: Document the problems with
91912         the getdomainname declaration.
91914 2010-11-28  Bruno Haible  <bruno@clisp.org>
91916         sys_socket: Ensure ss_family field on AIX.
91917         * lib/sys_socket.in.h (ss_family): New macro definition.
91918         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Set
91919         HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY. Set SYS_SOCKET_H if necessary.
91920         (gl_SYS_SOCKET_H_DEFAULTS): Initialize
91921         HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY.
91922         * modules/sys_socket (Makefile.am): Substitute
91923         HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY.
91924         * doc/posix-headers/sys_socket.texi: Mention the AIX bug.
91926 2010-11-27  Bruno Haible  <bruno@clisp.org>
91928         readline: Improve configure output.
91929         * m4/readline.m4 (gl_FUNC_READLINE): Make the
91930         "checking for readline..." result understandable.
91932 2010-11-27  Bruno Haible  <bruno@clisp.org>
91934         *printf-posix: Detect a bug on Solaris 10/x86.
91935         * m4/printf.m4 (gl_PRINTF_PRECISION): Detect crash with large precision
91936         for floating-point output.
91937         * tests/test-vasnprintf-posix.c (test_function): Test precision with %f
91938         directive.
91939         * tests/test-snprintf-posix.h (test_function): Likewise.
91940         * tests/test-sprintf-posix.h (test_function): Likewise.
91941         * tests/test-vasprintf-posix.c (test_function): Likewise.
91942         * doc/posix-functions/fprintf.texi: Mention Solaris/x86 bug.
91943         * doc/posix-functions/printf.texi: Likewise.
91944         * doc/posix-functions/snprintf.texi: Likewise.
91945         * doc/posix-functions/sprintf.texi: Likewise.
91946         * doc/posix-functions/vfprintf.texi: Likewise.
91947         * doc/posix-functions/vprintf.texi: Likewise.
91948         * doc/posix-functions/vsnprintf.texi: Likewise.
91949         * doc/posix-functions/vsprintf.texi: Likewise.
91950         * doc/glibc-functions/obstack_printf.texi: Likewise.
91951         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
91953 2010-11-27  Bruno Haible  <bruno@clisp.org>
91955         Fix link error when module libunistring-optional is in use.
91956         * modules/striconveh-tests (Makefile.am): Link with $(LIBUNISTRING).
91957         * modules/striconveha-tests (Makefile.am): Likewise.
91959 2010-11-27  Bruno Haible  <bruno@clisp.org>
91961         regex: Mention link dependencies.
91962         * modules/regex (Link): New section.
91963         * modules/rpmatch (Link): Likewise.
91964         * modules/regex-quote-tests (Makefile.am): Link with $(LIBINTL).
91966 2010-11-27  Bruno Haible  <bruno@clisp.org>
91968         ftoastr: Fix compilation error on Solaris.
91969         * lib/ftoastr.c: Include <config.h>.
91971 2010-11-27  Bruno Haible  <bruno@clisp.org>
91973         getloadavg: Update documentation.
91974         * doc/glibc-functions/getloadavg.texi: Mention the Solaris problem.
91976 2010-11-27  Bruno Haible  <bruno@clisp.org>
91978         sys_socket: Fix test whether the functions are declared.
91979         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Include <sys/socket.h>,
91980         not <sys/select.h>.
91982 2010-11-27  Bruno Haible  <bruno@clisp.org>
91984         getpass: Make sure to get system declaration on some platforms.
91985         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU): Require
91986         gl_USE_SYSTEM_EXTENSIONS.
91987         * modules/getpass (Depends-on): Add extensions.
91989 2010-11-26  Bruno Haible  <bruno@clisp.org>
91991         iconv-h: Fix test-iconv-h-c++ failure on Solaris 11 2010-11.
91992         * lib/iconv.in.h (iconv_open, iconv, iconv_close): Define only if the
91993         'iconv' module is present.
91994         (ICONV_CONST): New macro.
91995         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Initialize GNULIB_ICONV and
91996         ICONV_CONST.
91997         * m4/iconv.m4 (AM_ICONV): If the gnulib module 'iconv-h' is present,
91998         set ICONV_CONST.
91999         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Don't set ICONV_CONST
92000         here.
92001         * modules/iconv (configure.ac): Invoke gl_ICONV_MODULE_INDICATOR.
92002         * modules/iconv-h (Makefile.am): Substitute GNULIB_ICONV.
92003         * tests/test-iconv-h.c (ICONV_CONST): Don't define here.
92004         * tests/test-iconv-h-c++.cc (ICONV_CONST): Don't define here.
92005         (iconv_open, iconv, iconv_close): Test only if the 'iconv' module is
92006         present.
92008 2010-11-25  Paul Eggert  <eggert@cs.ucla.edu>
92010         ftoastr: comment fix
92011         * lib/ftoastr.c: "little" -> "little or no" in comment
92013 2010-11-24  Paul Eggert  <eggert@cs.ucla.edu>
92015         stdint: port to GCC 4.3 + OSX + Octave
92016         On this platform, stdint.h is buggy and defines int64_t to long
92017         long int.  The replacement defined it to long int, causing
92018         problems with C++ style name mangling.  Instead, trust the system
92019         definition if INT64_MAX is defined, and likewise for the unsigned
92020         variant.   Problem reported by Jarno Rajahalme in
92021         <http://lists.gnu.org/r/bug-gnulib/2010-04/msg00143.html>.
92022         * lib/stdint.in.h (GL_INT64_T): Define if INT64_MAX is defined,
92023         and don't mess with int64_t and INT64_MAX in this case.
92024         (GL_UINT64_T): Likewise for UINT64_MAX and uint64_t.
92026 2010-11-24  Bruno Haible  <bruno@clisp.org>
92028         doc: Corrections regarding MacOS X 10.4 and 10.5.
92029         * doc/{glibc,posix,pastposix}-functions/*.texi: Update info about
92030         MacOS X.
92031         Reported by Simon Josefsson.
92033 2010-11-22  Ben Pfaff  <blp@cs.stanford.edu>
92035         Uninstall ".bin" files installed by relocwrapper.
92036         * modules/relocatable-prog-wrapper (uninstall-relocwrapper):
92037         Recursively run "make uninstall" with ".bin" prefixed to EXEEXT,
92038         unless it is already there.
92040 2010-11-21  Bruno Haible  <bruno@clisp.org>
92042         Update for NetBSD 5.0.
92043         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Don't guess yes on
92044         NetBSD; the test fails on NetBSD 5.0.
92045         * doc/{glibc,posix,pastposix}-{headers,functions}/*.texi: Update info
92046         about NetBSD.
92048 2010-11-21  Bruno Haible  <bruno@clisp.org>
92050         Update for HP-UX 11.23 and HP-UX 11.31.
92051         * doc/{glibc,posix}-{headers,functions}/*.texi: Update info about
92052         HP-UX.
92054 2010-11-21  Bruno Haible  <bruno@clisp.org>
92056         Update for MacOS X 10.5.
92057         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Don't guess yes on
92058         MacOS X; the test fails on MacOS X 10.5.8.
92059         * doc/{glibc,posix,pastposix}-{headers,functions}/*.texi: Update info
92060         about MacOS X.
92062 2010-11-20  Joel E. Denny  <joeldenny@joeldenny.org>
92064         bootstrap: add bootstrap_sync option.
92065         See discussion at
92066         <http://lists.gnu.org/r/bug-gnulib/2010-10/msg00369.html>,
92067         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00200.html>.
92068         * build-aux/bootstrap: Accept --bootstrap-sync to update
92069         bootstrap if it is not identical to the local gnulib's
92070         bootstrap.  Accept bootstrap_sync=true in bootstrap.conf to
92071         enable this by default.  Accept --no-bootstrap-sync to disable
92072         it.
92074 2010-11-20  Bruno Haible  <bruno@clisp.org>
92076         Ensure that <features.h> is included before __GLIBC__ is tested.
92077         * lib/printf-parse.h: Include <features.h>.
92078         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gl_FEATURES_H.
92079         Reported by Mike Frysinger <vapier@gentoo.org>.
92081         Ensure that <features.h> is included before __GLIBC__ is tested.
92082         * lib/wchar.in.h: Include <features.h>.
92083         * m4/wchar_h.m4 (gl_WCHAR_H): Require gl_FEATURES_H.
92084         * modules/wchar (Makefile.am): Substitute HAVE_FEATURES_H.
92085         Reported by Mike Frysinger <vapier@gentoo.org>.
92087         Ensure that <features.h> is included before __GLIBC__ is tested.
92088         * lib/arpa_inet.in.h: Include <features.h>.
92089         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Require gl_FEATURES_H.
92090         * modules/arpa_inet (Makefile.am): Substitute HAVE_FEATURES_H.
92091         Reported by Mike Frysinger <vapier@gentoo.org>.
92093         Ensure that <features.h> is included before __GLIBC__ is tested.
92094         * build-aux/link-warning.h: Include <features.h>.
92095         * modules/link-warning (configure.ac): Require gl_FEATURES_H.
92096         (Makefile.am): Substitute HAVE_FEATURES_H into link-warning.h.
92097         Reported by Mike Frysinger <vapier@gentoo.org>.
92099         Ensure that <features.h> is included before __GLIBC__ is tested.
92100         * m4/gnulib-common.m4 (gl_FEATURES_H): New macro.
92101         Reported by Mike Frysinger <vapier@gentoo.org>.
92103 2010-11-20  Bruno Haible  <bruno@clisp.org>
92105         memmem: Fix autoconf test.
92106         * m4/memmem.m4 (gl_FUNC_MEMMEM): Test HAVE_DECL_MEMMEM, not HAVE_MEMMEM.
92108 2010-11-20  Bruno Haible  <bruno@clisp.org>
92110         Port to uClibc.
92111         * build-aux/link-warning.h (GL_LINK_WARNING): Treat uClibc like glibc.
92112         * lib/fcntl.in.h: Likewise.
92113         * lib/hard-locale.c (GLIBC_VERSION): Likewise.
92114         * lib/mbrtowc.c (mbrtowc): Likewise.
92115         * lib/relocatable.c (find_shared_library_fullname): Likewise.
92116         * lib/strerror_r.c: Likewise.
92117         * lib/unistr/u8-strnlen.c: Likewise.
92118         * lib/vasnprintf.c (decimal_point_char): Likewise.
92119         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Likewise.
92120         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Likewise.
92121         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Likewise.
92122         * m4/glibc21.m4 (gl_GLIBC21): Likewise.
92123         * tests/test-sigaction.c (handler, main): Likewise.
92124         * lib/freading.h: Treat uClibc like a non-glibc platform.
92125         * lib/freading.c: Likewise.
92126         * lib/gettext.h: Likewise.
92127         * lib/localename.c (gl_locale_name_thread_unsafe, HAVE_LOCALE_NULL):
92128         Likewise.
92129         * lib/printf-parse.h (FLAG_LOCALIZED): Likewise.
92130         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
92131         * lib/propername.c (proper_name_utf8): Likewise.
92132         * lib/spawn.in.h: Likewise.
92133         * lib/striconv.c (mem_cd_iconv, str_cd_iconv, str_iconv): Likewise.
92134         * lib/striconveh.c (iconveh_open, iconv_carefully, iconv_carefully_1,
92135         mem_cd_iconveh_internal): Likewise.
92136         * lib/striconveha.c (mem_iconveha, str_iconveha): Likewise.
92137         * lib/string.in.h (memchr, memrchr, rawmemchr, strchrnul, strpbrk,
92138         strstr, strcasestr): Likewise.
92139         * lib/unicodeio.c (unicode_to_mb): Likewise.
92140         * lib/uniconv/u16-conv-from-enc.c (UTF16_NAME): Likewise.
92141         * lib/uniconv/u16-conv-to-enc.c (UTF16_NAME): Likewise.
92142         * lib/uniconv/u16-strconv-to-enc.c (UTF16_NAME): Likewise.
92143         * lib/uniconv/u32-conv-from-enc.c (UTF32_NAME): Likewise.
92144         * lib/uniconv/u32-conv-to-enc.c (UTF32_NAME): Likewise.
92145         * lib/uniconv/u32-strconv-to-enc.c (UTF32_NAME): Likewise.
92146         * lib/unistr/u8-stpncpy.c: Likewise.
92147         * lib/vasnprintf.c (VASNPRINTF): Likewise.
92148         * lib/xmalloc.c (HAVE_GNU_CALLOC): Likewise.
92149         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
92150         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
92151         * m4/glibc2.m4 (gt_GLIBC2): Likewise.
92152         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Likewise.
92153         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE, gl_FUNC_MEMMEM): Likewise.
92154         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Likewise.
92155         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE, gl_FUNC_STRCASESTR):
92156         Likewise.
92157         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Likewise.
92158         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
92159         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
92160         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
92161         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
92162         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
92163         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
92164         * m4/wchar_h.m4 (gl_WCHAR_H): Likewise.
92165         * tests/test-getopt.h (OPTIND_MIN): Likewise.
92166         * tests/test-striconveha.c (main): Likewise.
92167         * tests/test-vasnprintf-posix.c (test_function): Likewise.
92168         * tests/test-vasnprintf-posix3.c (test_function, main): Likewise.
92169         * doc/posix-functions/getdelim.texi: Mention an uClibc bug.
92170         * doc/posix-functions/getline.texi: Likewise.
92171         Reported by Mike Frysinger <vapier@gentoo.org>.
92173 2010-11-20  Bruno Haible  <bruno@clisp.org>
92175         nproc: Fix condition.
92176         * lib/nproc.c: Test HAVE_PTHREAD_GETAFFINITY_NP, not
92177         HAVE_PTHREAD_AFFINITY_NP.
92179 2010-11-20  Bruno Haible  <bruno@clisp.org>
92181         Fix a comment.
92182         * lib/vasnprintf.c (VASNPRINTF): Fix comment.
92184 2010-11-19  Paul Eggert  <eggert@cs.ucla.edu>
92186         ftoastr: don't assume snprintf
92187         * lib/ftoastr.c (snprintf) [! GNULIB_SNPRINTF_POSIX]:
92188         Implement a subset of snprintf here, by using sprintf safely.
92189         * modules/ftoastr (Depends-on): Remove snprintf.
92191 2010-11-19  Jim Meyering  <meyering@redhat.com>
92193         test-rename.h: fix compilation failure
92194         * tests/test-rename.h (test_rename): Add omitted "}".
92196 2010-11-17  Jim Meyering  <meyering@redhat.com>
92198         maint.mk: add a URL discussing the no-@acronym policy
92199         * top/maint.mk (sc_texinfo_acronym): Add a URL in a comment.
92201 2010-11-18  Paul Eggert  <eggert@cs.ucla.edu>
92203         ftoastr: depend on snprintf, improve comments
92204         * lib/ftoastr.c: Also mention Loitsch's draft.
92205         * lib/ftoastr.h: Require WIDTH to be nonnegative.  This isn't
92206         needed in the current implementation, but it might simplify
92207         speeding up the code later.
92208         * modules/ftoastr: Depend on snprintf; this improves portability.
92209         Suggested by Bruno Haible in the same email.
92211         ftoastr: port to hosts lacking strtof and strtold
92212         Problem reported by Bruno Haible in
92213         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00242.html>.
92214         * lib/ftoastr.c (STRTOF): Define to strtod if in a pre-C99
92215         environment and strtold (and presumably strtof) are not available.
92216         * modules/ftoastr (Files): Add m4/c-strtod.m4.
92217         (configure.ac): Require gl_C99_STRTOLD.
92219 2010-11-18  Bruno Haible  <bruno@clisp.org>
92221         c-strtold: Avoid link error on AIX 7.
92222         * lib/c-strtod.c: Test also HAVE_STRTOD_L or HAVE_STRTOLD_L.
92223         * m4/c-strtod.m4 (gl_C_STRTOD): Test whether strtod_l exists.
92224         (gl_C_STRTOLD): Test whether strtold_l exists.
92225         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
92227 2010-11-17  Paul Eggert  <eggert@cs.ucla.edu>
92229         intprops: new macro INT_BITS_STRLEN_BOUND
92230         * lib/intprops.h (INT_BITS_STRLEN_BOUND): New macro, needed by
92231         ftoastr.h.  This exposes an internal of intprops.h that was formerly
92232         not exposed.  Also, it uses a slightly tighter bound than before;
92233         though this makes no practical difference, we might as well be as
92234         tight as we easily can.
92236         ftoastr: new module, for lossless conversion of floats to short strings
92237         * lib/ftoastr.h, lib/ftoastr.c, lib/dtoastr.c, lib/ldtoastr.c:
92238         * modules/ftoastr: New files.
92240 2010-11-15  Paul Eggert  <eggert@cs.ucla.edu>
92242         bootstrap: port to Solaris sed
92243         * build-aux/bootstrap (get_version): Port to Solaris sed.
92244         See Ralf Wildenhues's note in
92245         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00156.html>.
92247 2010-11-14  Jim Meyering  <meyering@redhat.com>
92249         maint.mk: rename variable: s/noteworthy/gl_noteworthy_news_/
92250         * top/maint.mk (gl_noteworthy_news_): Rename from "noteworthy"
92251         and move definition closer to sole use.
92253 2010-11-13  Jim Meyering  <meyering@redhat.com>
92255         remove autoconf-2.57 work-around requiring AC_PROG_EGREP and AC_PROG_CPP
92256         Now we require at least autoconf-2.59, which means the work-around
92257         is no longer needed.
92258         * m4/alloca.m4 (gl_FUNC_ALLOCA): Remove work-around.
92259         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
92260         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
92261         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
92262         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
92264 2010-11-13  Bruno Haible  <bruno@clisp.org>
92266         rename, renameat: Avoid test failures at NFS mounted locations.
92267         * tests/test-rename.h (dentry_exists, assert_nonexistent): New
92268         functions.
92269         (test_rename): Use assert_nonexistent.
92270         * tests/test-rename.c: Include <dirent.h>.
92271         * tests/test-renameat.c: Likewise.
92272         Reported by Gary V. Vaughan <gary@gnu.org>.
92274         rename, renameat: Document Linux bug with NFS
92275         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00154.html>.
92276         * doc/posix-functions/rename.texi: Mention the NFS bug on Linux.
92277         * doc/posix-functions/renameat.texi: Likewise.
92278         Suggested by Eric Blake.
92280 2010-11-13  Bruno Haible  <bruno@clisp.org>
92282         rename test: Add comments.
92283         * tests/test-rename.h (test_rename): Add structure and comments.
92285 2010-11-13  Eric Blake  <eblake@redhat.com>
92287         maintainer-makefile: cover a few more files
92288         * top/maint.mk (sc_prohibit_test_double_equal): Also cover shell
92289         scripts generated within C files, for libvirt.
92291 2010-11-13  Bruno Haible  <bruno@clisp.org>
92293         unistr/u8-mbtouc: Improve handling of ill-formed UTF-8 input.
92294         * lib/unistr/u8-mbtouc.c (u8_mbtouc): For an invalid multibyte
92295         character, return the number of bytes that belong together, not always
92296         1.
92297         * lib/unistr/u8-mbtouc-unsafe.c (u8_mbtouc_unsafe): Likewise.
92298         * lib/unistr/u8-mbtouc-aux.c (u8_mbtouc_aux): Likewise.
92299         * lib/unistr/u8-mbtouc-unsafe-aux.c (u8_mbtouc_unsafe_aux): Likewise.
92300         * lib/unistr/u8-mbsnlen.c (u8_mbsnlen): Use u8_mbtouc to determine the
92301         number of bytes of an invalid character.
92302         * tests/unistr/test-u8-mbtouc.c (test_safe_function): New function.
92303         (main): Invoke it.
92304         * tests/unistr/test-u8-mbtouc.h (test_function): Update two test
92305         results.
92306         * tests/unistr/test-u8-mbsnlen.c (main): Test various kinds of
92307         malformed byte sequences.
92308         * modules/unistr/u8-mbtouc (configure.ac): Bump version number.
92309         * modules/unistr/u8-mbtouc-unsafe (configure.ac): Likewise.
92310         * modules/unistr/u8-mbsnlen (configure.ac): Likewise.
92311         Reported by Ben Pfaff and Paolo Bonzini.
92313 2010-11-13  Bruno Haible  <bruno@clisp.org>
92315         openat: Work around glibc bug with fchownat() and empty file names.
92316         * m4/openat.m4 (gl_FUNC_FCHOWNAT_EMPTY_FILENAME_BUG): New macro.
92317         (gl_FUNC_FCHOWNAT): Invoke it.
92318         * lib/fchownat.c (rpl_fchownat): Handle the empty file name specially.
92319         * doc/posix-functions/fchownat.texi: Document the glibc bug.
92320         Reported by Gary V. Vaughan <gary@gnu.org>.
92322 2010-11-13  Bruno Haible  <bruno@clisp.org>
92324         openat: Ensure autoconf macro ordering.
92325         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Require
92326         gl_USE_SYSTEM_EXTENSIONS.
92327         (gl_FUNC_FCHOWNAT): Require gl_UNISTD_H_DEFAULTS.
92329 2010-11-13  Bruno Haible  <bruno@clisp.org>
92331         Update comments.
92332         * lib/unistr/u8-check.c: Update file name in comments.
92333         * lib/unistr/u8-mblen.c: Likewise.
92334         * lib/unistr/u8-prev.c: Likewise.
92335         * lib/unistr/u8-strmblen.c: Likewise.
92336         * lib/unistr/u8-strmbtouc.c: Likewise.
92338 2010-11-13  Jim Meyering  <meyering@redhat.com>
92340         tests: avoid test failure on Solaris 10 due to lack of PATH export
92341         * tests/test-update-copyright.sh: Don't forget to export PATH.
92343         init.sh: ensure that IFS is defined, just in case...
92344         * tests/init.sh (setup_): Ensure that IFS is defined,
92345         so that saving and restoring it works as expected.  This
92346         appears to be useful at least for an old version of dash
92347         from a long time ago (RH 6).  See here for details:
92348         http://thread.gmane.org/gmane.comp.gnu.coreutils.general/436/focus=455
92350         maint.mk: tighten "test a == b" check
92351         * top/maint.mk (sc_prohibit_test_double_equal): Restrict this
92352         test to files that contain something like #!/bin/sh.
92353         Without this, coreutils would get two false positives in
92354         the comments of C source files.
92356 2010-11-12  Eric Blake  <eblake@redhat.com>
92358         bootstrap: fix typo in previous attempt
92359         * build-aux/bootstrap (buildreq): Correct the grouping.
92360         Reported by Paul Eggert.
92362         maintainer-makefile: prohibit test x == x
92363         * top/maint.mk (sc_prohibit_test_double_equal): New rule.
92364         Based on a report by Matthias Bolte.
92366         bootstrap: allow FreeBSD gzip
92367         * build-aux/bootstrap (get_version): Parse FreeBSD gzip version,
92368         which has no '.' and goes to stderr.
92369         * build-aux/bootstrap.conf (buildreq): Improve the sample file.
92370         Reported by Matthias Bolte.
92372         maintainer-makefile: check for i18n setup
92373         * top/maint.mk (sc_bindtextdomain): Check for evidence that _()
92374         will likely work.
92376 2010-11-12  Bruno Haible  <bruno@clisp.org>
92378         sleep, nanosleep: Work around Linux 2.6.9 nanosleep bug.
92379         * lib/sleep.c (rpl_sleep): Split in chunks no larger than 24 days.
92380         * lib/nanosleep.c (nanosleep): Likewise.
92382 2010-11-11  Bruno Haible  <bruno@clisp.org>
92384         fcntl-h: Fix for use of C++ on glibc systems.
92385         * lib/fcntl.in.h: Include <sys/stat.h> before include_next <fcntl.h>
92386         also on glibc systems in C++ mode.
92387         Reported by Gary V. Vaughan <gary@gnu.org>.
92389 2010-11-11  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
92391         mknod: avoid false failure with dash
92392         * m4/mknod.m4 (gl_FUNC_MKNOD): Use portable shell syntax.
92394 2010-11-11  Paul Eggert  <eggert@cs.ucla.edu>
92396         unlink: Fix "is it should" typo in diagnostic.
92397         * m4/unlink.m4 (gl_FUNC_UNLINK): Fix typo, as per Reuben Thomas in
92398         <http://lists.gnu.org/r/bug-gnulib/2010-11/msg00106.html>.
92400 2010-11-11  Bruno Haible  <bruno@clisp.org>
92402         Tests for module 'strerror_r-posix'.
92403         * modules/strerror_r-posix-tests: New file.
92404         * tests/test-strerror_r.c: New file.
92405         * tests/test-string-c++.cc: Check the signature of strerror_r.
92407         New module 'strerror_r-posix'.
92408         * lib/string.in.h (strerror_r): New declaration.
92409         * lib/strerror_r.c: New file.
92410         * m4/strerror_r.m4: New file.
92411         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Check for the declaration
92412         of strerror_r.
92413         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_STRERROR_R,
92414         HAVE_DECL_STRERROR_R, REPLACE_STRERROR_R.
92415         * modules/strerror_r-posix: New file.
92416         * modules/string (Makefile.am): Substitute GNULIB_STRERROR_R,
92417         HAVE_DECL_STRERROR_R, REPLACE_STRERROR_R.
92418         * doc/posix-functions/strerror_r.texi: Mention the new module and the
92419         portability problems.
92421 2010-11-11  Torsten Scheck  <Torsten.Scheck@Leica-Microsystems.com> (tiny change)
92423         * build-aux/pmccabe2html: Fixed a off-by-one error, so last input
92424         line is also considered for output. Quoted function name in shell
92425         command, so temporary files for functions like MyClass::operator()
92426         are removed correctly without errors.
92428 2010-11-09  Bruno Haible  <bruno@clisp.org>
92430         * doc/posix-functions/strerror.texi: List more failing platforms.
92432         * doc/posix-functions/strerror.texi: Add a comment.
92434 2010-11-07  Paul Eggert  <eggert@cs.ucla.edu>
92436         fdopendir: fix bug on MacOS X when low on file descriptors
92438         * lib/fdopendir.c (REPLACE_FCHDIR): #define to 0 if not defined.
92439         (fdopendir_with_dup, fd_clone_opendir): Now have extra CWD arg.
92440         All callers changed.
92441         (fdopendir): Invoke save_cwd at the top level, not after using
92442         multiple dup() calls to use up file descriptors.  Then retry
92443         fdopendir_with_dup.  This avoids failure with EMFILE if FD is 1
92444         less than the maximum number of open file descriptors, because
92445         save_cwd fails with errno == EMFILE.  Problem reported by tsteven4
92446         on Mac OS X 10.6.4 for tar 1.24
92447         <http://lists.gnu.org/r/bug-tar/2010-10/msg00084.html>
92448         <http://lists.gnu.org/r/bug-tar/2010-11/msg00000.html>
92449         and for tar 1.25
92450         <http://lists.gnu.org/r/bug-tar/2010-11/msg00038.html>.
92452 2010-11-07  Bruno Haible  <bruno@clisp.org>
92454         vasnprintf: Support I flag on glibc systems.
92455         * lib/printf-parse.h (FLAG_LOCALIZED): New macro.
92456         * lib/printf-parse.c (PRINTF_PARSE): Handle the 'I' flag.
92457         * lib/vasnprintf.c (VASNPRINTF): Pass the 'I' flag on to the system's
92458         snprintf function.
92459         * tests/test-vasnprintf-posix.c (test_function): Test the 'I' flag on
92460         glibc systems.
92461         * tests/test-vasnprintf-posix3.c: New file.
92462         * modules/vasnprintf-posix-tests (Files): Add it.
92463         (TESTS, check_PROGRAMS): Add test-vasnprintf-posix3.
92465 2010-11-05  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
92467         [html] Fix copy/paste bug: Use unique name for compiler warnings.
92468         * MODULES.html.sh: For compiler warnings, use name
92469         `ansic_ext_compwarn' since `ansic_ext_misc' is already taken.
92471 2010-11-05  Eric Blake  <eblake@redhat.com>
92473         ceil, floor: avoid spurious failure with icc
92474         * tests/test-ceilf2.c (ceilf_reference): Avoid icc's use of DAZ
92475         [denormals-as-zero] when optimizing without -mieee-fp option.
92476         * tests/test-floorf2.c (floorf_reference): Likewise.
92477         * tests/test-ceilf1.c (dummy): New function.
92478         (main): Use it to outsmart icc's optimization.
92479         * tests/test-floorf1.c (dummy, main): Likewise.
92481         tests: require working signbit
92482         * modules/ceilf-tests (Depends-on): Add signbit.
92483         * modules/ceill-tests (Depends-on): Likewise.
92484         * modules/floorf-tests (Depends-on): Likewise.
92485         * modules/floorl-tests (Depends-on): Likewise.
92486         * modules/round-tests (Depends-on): Likewise.
92487         * modules/roundf-tests (Depends-on): Likewise.
92488         * modules/roundl-tests (Depends-on): Likewise.
92489         * modules/trunc-tests (Depends-on): Likewise.
92490         * modules/truncf-tests (Depends-on): Likewise.
92491         * modules/truncl-tests (Depends-on): Likewise.
92493         strtod: work around icc bug
92494         * lib/strtod.c (minus_zero): Define to working value.
92495         (strtod): Use it to avoid icc bug.
92497         copysign: enhance tests
92498         * modules/copysign-tests (Files): Add minus-zero.h.
92499         * tests/test-copysign.c (main): Also test zeros.
92501 2010-11-04  Eric Blake  <eblake@redhat.com>
92503         ceil, floor, round, trunc: enhance tests of -0
92504         * tests/test-ceilf1.c (main): Ensure correct sign of result.
92505         * tests/test-ceill.c (main): Likewise.
92506         * tests/test-floorf1.c (main): Likewise.
92507         * tests/test-floorl.c (main): Likewise.
92508         * tests/test-round1.c (main): Likewise.
92509         * tests/test-roundf1.c (main): Likewise.
92510         * tests/test-roundl.c (main): Likewise.
92511         * tests/test-trunc1.c (main): Likewise.
92512         * tests/test-truncf1.c (main): Likewise.
92513         * tests/test-truncl.c (main): Likewise.
92515 2010-11-04  Eric Blake  <eblake@redhat.com>
92517         frexp, tests: work around ICC bug with -zero
92518         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Compute -0.0 in a way that
92519         works with more compilers.
92520         * tests/minus-zero.h: New file.
92521         * modules/ceilf-tests (Files): Include it.
92522         * modules/ceill-tests (Files): Likewise.
92523         * modules/floorf-tests (Files): Likewise.
92524         * modules/floorl-tests (Files): Likewise.
92525         * modules/frexp-nolibm-tests (Files): Likewise.
92526         * modules/frexp-tests (Files): Likewise.
92527         * modules/frexpl-nolibm-tests (Files): Likewise.
92528         * modules/frexpl-tests (Files): Likewise.
92529         * modules/isnan-tests (Files): Likewise.
92530         * modules/isnand-nolibm-tests (Files): Likewise.
92531         * modules/isnand-tests (Files): Likewise.
92532         * modules/isnanf-nolibm-tests (Files): Likewise.
92533         * modules/isnanf-tests (Files): Likewise.
92534         * modules/isnanl-nolibm-tests (Files): Likewise.
92535         * modules/isnanl-tests (Files): Likewise.
92536         * modules/round-tests (Files): Likewise.
92537         * modules/roundf-tests (Files): Likewise.
92538         * modules/roundl-tests (Files): Likewise.
92539         * modules/ldexpl-tests (Files): Likewise.
92540         * modules/signbit-tests (Files): Likewise.
92541         * modules/snprintf-posix-tests (Files): Likewise.
92542         * modules/sprintf-posix-tests (Files): Likewise.
92543         * modules/strtod-tests (Files): Likewise.
92544         * modules/trunc-tests (Files): Likewise.
92545         * modules/truncf-tests (Files): Likewise.
92546         * modules/truncl-tests (Files): Likewise.
92547         * modules/vsnprintf-posix-tests (Files): Likewise.
92548         * modules/vsprintf-posix-tests (Files): Likewise.
92549         * modules/vasnprintf-posix-tests (Files): Likewise.
92550         * modules/vasprintf-posix-tests (Files): Likewise.
92551         * tests/test-ceilf1.c (main): Use it.
92552         * tests/test-ceill.c (main): Likewise.
92553         * tests/test-floorf1.c (main): Likewise.
92554         * tests/test-floorl.c (main): Likewise.
92555         * tests/test-frexp.c (main): Likewise.
92556         * tests/test-frexpl.c (main): Likewise.
92557         * tests/test-isnan.c (main): Likewise.
92558         * tests/test-isnand.h (main): Likewise.
92559         * tests/test-isnanf.h (main): Likewise.
92560         * tests/test-isnanl.h (main): Likewise.
92561         * tests/test-ldexpl.c (main): Likewise.
92562         * tests/test-round.c (main): Likewise.
92563         * tests/test-roundf.c (main): Likewise.
92564         * tests/test-roundl.c (main): Likewise.
92565         * tests/test-signbit.c (test_signbitf, test_signbitd)
92566         (test_signbitl): Likewise.
92567         * tests/test-snprintf-posix.h (test_function): Likewise.
92568         * tests/test-sprintf-posix.h (test_function): Likewise.
92569         * tests/test-strtod.c (main): Likewise.
92570         * tests/test-trunc1.c (main): Likewise.
92571         * tests/test-truncf1.c (main): Likewise.
92572         * tests/test-truncl.c (main): Likewise.
92574         isnanl: work around icc bug
92575         * lib/isnan.c (FUNC): Compute run-time NaN under ICC as well.
92577 2010-11-03  Eric Blake  <eblake@redhat.com>
92579         tests: fix compiler warnings
92580         * tests/test-getopt.h (test_getopt): Fix condition.
92581         * tests/test-getopt_long.h (test_getopt_long): Likewise.
92582         * tests/test-pipe2.c (main): Likewise.
92583         * tests/test-quotearg-simple.c (main): Avoid icc warning.
92585         utimens: fix broken m4 test
92586         * m4/utimens.m4 (gl_UTIMENS): Include correct headers.
92588 2010-10-28  Bruno Haible  <bruno@clisp.org>
92590         posix_spawn*, getdtablesize: Relax license.
92591         * modules/posix_spawn (License): Change to LGPLv2+.
92592         * modules/posix_spawnp (License): Likewise.
92593         * modules/posix_spawn-internal (License): Likewise.
92594         * modules/posix_spawnattr_init (License): Likewise.
92595         * modules/posix_spawnattr_getflags (License): Likewise.
92596         * modules/posix_spawnattr_setflags (License): Likewise.
92597         * modules/posix_spawnattr_getpgroup (License): Likewise.
92598         * modules/posix_spawnattr_setpgroup (License): Likewise.
92599         * modules/posix_spawnattr_getschedparam (License): Likewise.
92600         * modules/posix_spawnattr_setschedparam (License): Likewise.
92601         * modules/posix_spawnattr_getschedpolicy (License): Likewise.
92602         * modules/posix_spawnattr_setschedpolicy (License): Likewise.
92603         * modules/posix_spawnattr_getsigdefault (License): Likewise.
92604         * modules/posix_spawnattr_setsigdefault (License): Likewise.
92605         * modules/posix_spawnattr_getsigmask (License): Likewise.
92606         * modules/posix_spawnattr_setsigmask (License): Likewise.
92607         * modules/posix_spawnattr_destroy (License): Likewise.
92608         * modules/posix_spawn_file_actions_init (License): Likewise.
92609         * modules/posix_spawn_file_actions_addclose (License): Likewise.
92610         * modules/posix_spawn_file_actions_adddup2 (License): Likewise.
92611         * modules/posix_spawn_file_actions_addopen (License): Likewise.
92612         * modules/posix_spawn_file_actions_destroy (License): Likewise.
92613         * modules/getdtablesize (License): Likewise.
92614         Requested by Adam Stokes <ajs@redhat.com> for use in netcf.
92616 2010-10-26  Bruno Haible  <bruno@clisp.org>
92618         unistd: Refine workaround from 2009-12-23 against Cygwin bug.
92619         * lib/unistd.in.h: Don't include <stdio.h> and <fcntl.h>, except on
92620         Cygwin and mingw.
92621         Suggested by Eric Blake.
92623 2010-10-26  Bruno Haible  <bruno@clisp.org>
92625         stdio: Work around compilation error due to renameat() on Solaris 10.
92626         * lib/stdio.in.h: Include <unistd.h> on Solaris.
92627         * lib/renameat.c: Don't include <unistd.h> here.
92628         * doc/posix-functions/renameat.texi: Mention the Solaris problem.
92629         Reported by Paul Eggert and Eric Blake.
92631 2010-10-26  Paul Eggert  <eggert@cs.ucla.edu>
92633         renameat: port to Solaris 10, which declares renameat in unistd.h
92635         * lib/renameat.c: Include unistd.h before stdio.h, because
92636         Solaris 10 declares renameat in unistd.h.  Problem encountered
92637         when building GNU tar 1.24 on Solaris 10.
92639 2010-10-26  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
92641         fdopendir: fix C89 compilation
92642         * lib/fdopendir.c (fd_clone_opendir): Move declaration for older
92643         compilers.
92645 2010-10-23  Paul Eggert  <eggert@cs.ucla.edu>
92647         inttostr: simplify by removing unnecessary redundancy
92648         * lib/anytostr.c: Don't include verify.h.
92649         (anytostr): Don't verify that TYPE_SIGNED (inttype) equals
92650         inttype_is_signed.  Instead, disable the bogus GCC warnings, so that
92651         there's no need for inttype_is_signed and for calling TYPE_SIGNED.
92652         * lib/imaxtostr.c (inttype_is_signed): Remove; no longer needed.
92653         * lib/inttostr.c, lib/offtostr.c, lib/uinttostr.c, lib/umaxtostr.c:
92654         Likewise.
92655         * modules/inttostr (Depends-on): Remove 'verify'.
92657 2010-10-23  Bruno Haible  <bruno@clisp.org>
92659         nl_langinfo: Mention problem with CRNCYSTR on NetBSD 5.0.
92660         * doc/posix-functions/nl_langinfo.texi: Mention problem with CRNCYSTR.
92661         Reported by Eric Blake.
92663 2010-10-23  Bruno Haible  <bruno@clisp.org>
92665         Tests: Fix LOCALE_JA on MirBSD 10.
92666         * m4/locale-ja.m4 (gt_LOCALE_JA): Reject a locale identifier that leads
92667         to an UTF-8 locale.
92668         * m4/locale-fr.m4 (gt_LOCALE_FR): Likewise.
92669         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
92670         Reported by Eric Blake.
92672 2010-10-21  Bruno Haible  <bruno@clisp.org>
92674         nl_langinfo test: Avoid test failure on NetBSD 5.
92675         * tests/test-nl_langinfo.c (main): Relax test of nl_langinfo(CRNCYSTR).
92676         Reported by Eric Blake.
92678 2010-10-21  Eric Blake  <eblake@redhat.com>
92680         c-stack: work around libsigsegv 2.8 bug
92681         * lib/c-stack.c (SIGSTKSZ): Increase size to avoid alternate stack
92682         overflow on at least PowerPC64.
92684 2010-10-17  Bruno Haible  <bruno@clisp.org>
92686         userspec: Drop redundant file.
92687         * modules/userspec (Files): Remove lib/inttostr.h.
92689 2010-10-17  Bruno Haible  <bruno@clisp.org>
92691         nl_langinfo tests: Silence some warnings.
92692         * tests/test-nl_langinfo.c: Silence -Wtype-limits warnings.
92693         Reported by Jim Meyering.
92695 2010-10-17  Bruno Haible  <bruno@clisp.org>
92697         Make use of GCC's attribute __alloc_size__.
92698         * lib/xalloc.h (ATTRIBUTE_ALLOC_SIZE): New macro.
92699         (xmalloc, xzalloc, xcalloc, xrealloc, xmemdup, xnmalloc, xnrealloc,
92700         xcharalloc): Declare with ATTRIBUTE_ALLOC_SIZE.
92701         * lib/eealloc.h (eemalloc, eerealloc): Declare with attribute
92702         __alloc_size__.
92703         * lib/pagealign_alloc.h (pagealign_alloc, pagealign_xalloc): Likewise.
92704         Suggested by Jim Meyering.
92706 2010-10-16  Joel E. Denny  <joeldenny@joeldenny.org>
92708         bootstrap: anchor .gitignore entries.
92709         * build-aux/bootstrap (insert_sorted_if_absent): Replace all uses
92710         with...
92711         (insert_vc_ignore): ... this new function, which prepends `/' to
92712         all .gitignore entries before passing them to
92713         insert_sorted_if_absent.
92715 2010-10-16  Bruno Haible  <bruno@clisp.org>
92717         nextafter: Fix configure check.
92718         * modules/nextafter (configure.ac): Correct expected prototype.
92720 2010-10-16  Bruno Haible  <bruno@clisp.org>
92722         termios: Update documentation.
92723         * doc/posix-headers/termios.texi: Mention remaining mingw problems.
92725 2010-10-16  Bruno Haible  <bruno@clisp.org>
92727         tests: Make them compile with TinyCC.
92728         * tests/test-strstr.c (main): Remove parentheses around array
92729         initializer.
92731 2010-10-15  Eric Blake  <eblake@redhat.com>
92733         ignore-value: make header idempotent
92734         * lib/ignore-value.h: Add double-inclusion guards.
92735         Reported by Stefan Berger.
92737 2010-10-15  Jim Meyering  <meyering@redhat.com>
92739         GNUmakefile: handle "stable" target, not "major"
92740         * top/GNUmakefile (_is-dist-target): s/major/stable/ to match the
92741         lists in maint.mk and announce-gen.  Without this, "make stable"
92742         would fail to ensure that $(VERSION) is up to date.
92744 2010-10-15  Ludovic Courtès  <ludo@gnu.org>
92746         * lib/isnan.c (FUNC): Treat TinyCC (`__TINYC__') like `__SUNPRO_C'
92747         & co.
92749 2010-10-14  Bruno Haible  <bruno@clisp.org>
92751         vasnprintf: Don't set errno to 0.
92752         * lib/vasnprintf.c (VASNPRINTF): Save and restore errno around the
92753         block that sets it to 0.
92754         Reported by Gianluigi Tiesi <sherpya@netfarm.it>.
92756 2010-10-14  Bruno Haible  <bruno@clisp.org>
92758         socketlib: Fix.
92759         * modules/socketlib (Files): Add m4/sys_socket_h.m4. Needed for
92760         gl_PREREQ_SYS_H_WINSOCK2.
92761         Reported by Ian Beckwith <ianb@erislabs.net>.
92763 2010-10-13  Jim Meyering  <meyering@redhat.com>
92765         test-select-stdin.c: avoid warn_unused_result warnings
92766         * tests/test-select-stdin.c: Include "macros.h".
92767         ASSERT that read and fflush succeed.
92769 2010-10-13  Jim Meyering  <meyering@redhat.com>
92771         git-version-gen: do require git-VC'd files in cwd
92772         * build-aux/git-version-gen: Reject a git version string
92773         if there are no commits associated with the current directory.
92774         This avoids an unlikely false-positive (unrelated dir whose parent
92775         repository also contains a tag matching v*), as pointed out
92776         by Giuseppe Scrivano in
92777         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/21843/focus=23664
92779 2010-10-13  Paul Eggert  <eggert@cs.ucla.edu>
92781         argv-iter: omit nonconforming declaration
92782         * lib/argv-iter.h (enum argv_iter_err): Omit the useless
92783         enum arg_iter_err declaration, which doesn't conform to C99.
92784         Solaris 10 cc warns about this.
92786 2010-10-13  Eric Blake  <eblake@redhat.com>
92788         termios: fix compilation on mingw
92789         * m4/termios_h.m4 (gl_TERMIOS_H_DEFAULTS): Set default.
92790         (gl_TERMIOS_H): Adjust it on mingw.
92791         * modules/termios (Makefile.am): Substitute new key.
92792         * lib/termios.in.h (includes): Make include_next conditional.
92793         * doc/posix-headers/termios.texi (termios.h): Update
92794         documentation.
92795         Reported by Daniel P. Berrange.
92797 2010-10-13  Jim Meyering  <meyering@redhat.com>
92799         git-version-gen: don't require that .git/ be in the current dir
92800         * build-aux/git-version-gen: Adjust this script so that it works
92801         when run from any working directory beneath the top-level .git/-
92802         containing directory.  Inspired by a patch from Giuseppe Scrivano,
92803         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/21843/focus=21847
92805         test-select: avoid warn_unused_result warnings
92806         * tests/test-select.c: Include "macros.h".
92807         ASSERT that each call to read, write, and pipe succeeds.
92808         While not technically required, also check each "close".
92809         * modules/select-tests (Files): Add tests/macros.h.
92811         test-symlinkat: remove declaration of unused local
92812         * tests/test-symlinkat.c (main): Remove unused local, "buf".
92814         test-inttostr: avoid shadowing warnings
92815         * tests/test-inttostr.c (main): Rename local, "buf" to "b",
92816         and use malloc rather than the stack for the same reason as
92817         mentioned in the comment justifying the other allocation.
92819 2010-10-11  Bruno Haible  <bruno@clisp.org>
92821         stdlib: Allow multiple gnulib generated replacements to coexist.
92822         * lib/stdlib.in.h (struct random_data): Avoid identical redefinition.
92823         Reported by Sam Steingold <sds@gnu.org>.
92825 2010-10-11  Jim Meyering  <meyering@redhat.com>
92827         fix a documentation typo
92828         * doc/posix-functions/futimens.texi (futimens): Fix typo: s/itme/item/
92830 2010-10-11  Eric Blake  <eblake@redhat.com>
92832         futimens: work around Solaris 11 bug
92833         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Detect the bug.
92834         * tests/test-futimens.h (test_futimens): Enhance, rather than
92835         weaken test.
92836         * doc/posix-functions/futimens.texi (futimens): Document the bug.
92838 2010-10-11  Paul Eggert  <eggert@cs.ucla.edu>
92840         Indentation.
92841         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Indent
92842         higher-level operators more to the left.
92844 2010-10-11  Jim Meyering  <meyering@redhat.com>
92846         test-futimens: avoid unwarranted test failure on Solaris 5.11
92847         * tests/test-futimens.h (test_futimens): When provoking EBADF, use an
92848         invalid file descriptor, so we don't provoke EFAULT from Solaris 5.11,
92849         because it tries to dereference the NULL name argument.
92851 2010-10-11  Bruno Haible  <bruno@clisp.org>
92853         Indentation.
92854         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Improve
92855         indentation.
92857 2010-10-11  Jim Meyering  <meyering@redhat.com>
92859         spawn.in.h: make indentation consistent with parentheses
92860         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap):
92861         Make indentation consistent with parentheses.
92863 2010-10-11  Gary V. Vaughan  <gary@gnu.org>
92865         Fix mismatched parens in previous commit
92866         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Fix mismatched
92867         parens.
92869 2010-10-10  Paul Eggert  <eggert@cs.ucla.edu>
92871         rewrite int foo[2*X-1] to verify(X) or to int foo[X?1:-1]
92873         * lib/float+.h (verify_sizeof_flt, verify_sizeof_dbl):
92874         (verify_sizeof_ldbl): Rewrite 2*X-1 to X?1:-1.
92875         * lib/malloca.c: Include "verify.h".
92876         (verify1): Remove, replacing with a verify call.
92877         * lib/relocwrapper.c (verify1): Likewise.
92878         * lib/vasnprintf.c (mp_limb_verify, mp_twolimb_verify, TCHAR_T_verify):
92879         Likewise.
92880         * modules/malloca (Depends-on): Add 'verify'.
92881         * modules/relocatable-prog-wrapper (Depends-on): Add 'verify'.
92882         * modules/vasnprintf (Depends-on): Add 'verify'.
92883         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
92884         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
92885         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
92886         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
92887         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
92888         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
92889         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
92891         prefer (X ? 1 : -1) when converting from boolean (1,0) to int (1,-1)
92893         Formerly the style was sometimes 2*X - 1, because the C standard
92894         was wrongly thought to disallow ?: in integral constant expressions.
92895         * lib/inet_ntop.c (verify_int_size): Rewrite 2*X-7 (!) to 4<=X?1:-1.
92896         * lib/signal.in.h (verify_NSIG_constraint): Rewrite 2*X-1 to X?1:-1.
92897         * lib/spawn.in.h (verify_POSIX_SPAWN_USEVFORK_no_overlap): Likewise.
92898         * lib/stdint.in.h (_verify_intmax_size): Likewise.
92899         * lib/time.in.h (struct __time_t_must_be_integral): Rewrite
92900         2 * ((time_t) 1 / 2 == 0) - 1 to (time_t) 1; this suffices to
92901         verify that time_t cannot be floating.
92903 2010-10-08  Eric Blake  <eblake@redhat.com>
92905         time: enforce recent POSIX ruling that time_t is integral
92906         * lib/time.in.h (__time_t_must_be_integral): Detect any
92907         problematic systems, allowing the rest of gnulib to assume POSIX.
92909 2010-10-08  Jim Meyering  <meyering@redhat.com>
92911         fdopendir: fix a bug on systems lacking openat and /proc support
92912         OpenBSD 4.7 is one such system.  The most noticeable effect was
92913         failure of any application making nontrivial use of fts: rm, du,
92914         chown, chmod etc.  E.g., "mkdir -p a/b; ./rm -rf a" would fail with
92915           ./rm: traversal failed: `a': Bad file descriptor
92916         Debugging that, you see that even though FD 6 was closed just
92917         prior to the opendir call in fd_clone_opendir, its resulting
92918         dir->dd_fd was 8, rather than the expected value of 6:
92920         Breakpoint 3, fdopendir_with_dup (fd=6, older_dupfd=-1) at fdopendir.c:93
92921         93                close (fd);
92922         (gdb) n
92923         94                dir = fd_clone_opendir (dupfd);
92924         (gdb) n
92925         95                saved_errno = errno;
92926         (gdb) p dir->dd_fd
92927         $11 = 8
92929         Notice how it closes FD 6, then gets a DIR* pointer using FD 8.
92930         The problem is that on OpenBSD, fd_clone_opendir has to resort
92931         to using the old-style save/restore CWD mechanism, due to its
92932         lack of openat/proc support, and *that* would steal the FD (6)
92933         that opendir was supposed to use.
92935         The fix is to squirrel away the desired FD so that save_cwd uses a
92936         different one, and then free the dest FD right before calling opendir.
92937         That guarantees opendir will use the required file descriptor.
92939         * lib/fdopendir.c (fd_clone_opendir): Handle the above.
92941 2010-10-08  Bruno Haible  <bruno@clisp.org>
92943         sys_select: Avoid warning due to undeclared memset() on OpenBSD 4.5.
92944         * lib/sys_select.in.h: Include <string.h> also on OpenBSD.
92946 2010-10-08  Bruno Haible  <bruno@clisp.org>
92948         nanosleep: Make replacement POSIX compliant.
92949         * lib/nanosleep.c (nanosleep): Return -1/EINVAL if the delay's tv_nsec
92950         is out of range.
92951         Reported by Jim Meyering.
92953 2010-10-08  Paul Eggert  <eggert@cs.ucla.edu>
92955         bootstrap: add hook for altering gnulib.mk, for Bison
92956         * build-aux/bootstrap (gnulib_mk_hook): New function, so that
92957         the Bison bootstrapping process can rewrite file names and variables
92958         in this file before later parts of 'bootstrap' use the file.
92959         Bison wants to include lib/gnulib.mk from the top-level makefile,
92960         so it needs the file names in this file to be relative to the top
92961         level, not relative to lib; plus it needs variable names to be
92962         rewritten.
92963         (slurp): Use the new function.
92965         bootstrap: reformat for readability
92966         * build-aux/bootstrap: Rewrite to avoid lines longer than 80 columns.
92968 2010-10-08  Eric Blake  <eblake@redhat.com>
92970         docs: update cygwin progress
92971         * doc/posix-functions/cacos.texi (cacos): Added after cygwin
92972         1.7.7.
92973         * doc/posix-functions/cacosf.texi (cacosf): Likewise.
92974         * doc/posix-functions/cacosh.texi (cacosh): Likewise.
92975         * doc/posix-functions/cacoshf.texi (cacoshf): Likewise.
92976         * doc/posix-functions/carg.texi (carg): Likewise.
92977         * doc/posix-functions/cargf.texi (cargf): Likewise.
92978         * doc/posix-functions/casin.texi (casin): Likewise.
92979         * doc/posix-functions/casinf.texi (casinf): Likewise.
92980         * doc/posix-functions/casinh.texi (casinh): Likewise.
92981         * doc/posix-functions/casinhf.texi (casinhf): Likewise.
92982         * doc/posix-functions/catan.texi (catan): Likewise.
92983         * doc/posix-functions/catanf.texi (catanf): Likewise.
92984         * doc/posix-functions/catanh.texi (catanh): Likewise.
92985         * doc/posix-functions/catanhf.texi (catanhf): Likewise.
92986         * doc/posix-functions/ccos.texi (ccos): Likewise.
92987         * doc/posix-functions/ccosf.texi (ccosf): Likewise.
92988         * doc/posix-functions/ccosh.texi (ccosh): Likewise.
92989         * doc/posix-functions/ccoshf.texi (ccoshf): Likewise.
92990         * doc/posix-functions/cexp.texi (cexp): Likewise.
92991         * doc/posix-functions/cexpf.texi (cexpf): Likewise.
92992         * doc/posix-functions/cimag.texi (cimag): Likewise.
92993         * doc/posix-functions/cimagf.texi (cimagf): Likewise.
92994         * doc/posix-functions/clog.texi (clog): Likewise.
92995         * doc/posix-functions/clogf.texi (clogf): Likewise.
92996         * doc/posix-functions/conj.texi (conj): Likewise.
92997         * doc/posix-functions/conjf.texi (conjf): Likewise.
92998         * doc/posix-functions/cpow.texi (cpow): Likewise.
92999         * doc/posix-functions/cpowf.texi (cpowf): Likewise.
93000         * doc/posix-functions/cproj.texi (cproj): Likewise.
93001         * doc/posix-functions/cprojf.texi (cprojf): Likewise.
93002         * doc/posix-functions/creal.texi (creal): Likewise.
93003         * doc/posix-functions/crealf.texi (crealf): Likewise.
93004         * doc/posix-functions/csin.texi (csin): Likewise.
93005         * doc/posix-functions/csinf.texi (csinf): Likewise.
93006         * doc/posix-functions/csinh.texi (csinh): Likewise.
93007         * doc/posix-functions/csinhf.texi (csinhf): Likewise.
93008         * doc/posix-functions/csqrt.texi (csqrt): Likewise.
93009         * doc/posix-functions/csqrtf.texi (csqrtf): Likewise.
93010         * doc/posix-functions/ctan.texi (ctan): Likewise.
93011         * doc/posix-functions/ctanf.texi (ctanf): Likewise.
93012         * doc/posix-functions/ctanh.texi (ctanh): Likewise.
93013         * doc/posix-functions/ctanhf.texi (ctanhf): Likewise.
93014         * doc/posix-headers/complex.texi (complex.h): Likewise.
93016 2010-10-07  Jim Meyering  <meyering@redhat.com>
93018         parse-datetime: avoid compilation failure on OpenBSD 4.7
93019         * lib/parse-datetime.y (_STDLIB_H) [_STDLIB_H_]: Define.
93020         This works around a compilation failure on OpenBSD 4.7:
93021         http://thread.gmane.org/gmane.comp.parsers.bison.bugs/3418
93023 2010-10-07  Eric Blake  <eblake@redhat.com>
93025         docs: update cygwin progress
93026         * doc/glibc-functions/mkostemp.texi (mkostemp): Added in cygwin
93027         1.7.6.
93028         * doc/glibc-functions/mkostemps.texi (mkostemps): Likewise.
93029         * doc/posix-headers/fenv.texi (fenv.h): Added after cygwin 1.7.7.
93030         * doc/posix-functions/feclearexcept.texi (feclearexcept): Likewise.
93031         * doc/posix-functions/fegetenv.texi (fegetenv): Likewise.
93032         * doc/posix-functions/fegetexceptflag.texi (fegetexceptflag):
93033         Likewise.
93034         * doc/posix-functions/fegetround.texi (fegetround): Likewise.
93035         * doc/posix-functions/feholdexcept.texi (feholdexcept): Likewise.
93036         * doc/posix-functions/feraiseexcept.texi (feraiseexcept):
93037         Likewise.
93038         * doc/posix-functions/fesetenv.texi (fesetenv): Likewise.
93039         * doc/posix-functions/fesetexceptflag.texi (fesetexceptflag):
93040         Likewise.
93041         * doc/posix-functions/fesetround.texi (fesetround): Likewise.
93042         * doc/posix-functions/fetestexcept.texi (fetestexcept): Likewise.
93043         * doc/posix-functions/feupdateenv.texi (feupdateenv): Likewise.
93044         * doc/glibc-functions/feenableexcept.texi (feenableexcept):
93045         Likewise.
93046         * doc/glibc-functions/fedisableexcept.texi (fedisableexcept):
93047         Likewise.
93048         * doc/glibc-functions/fegetexcept.texi (fegetexcept): Likewise.
93050         docs: update parse-datetime history
93051         * doc/parse-datetime.texi (Authors of parse_datetime): Better
93052         documentation of this function's history and alternatives.
93054         cygwin: use more robust version check
93055         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE, gl_FUNC_MEMMEM): Don't
93056         exclude an eventual cygwin 1.9.1.
93057         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Likewise.
93058         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE)
93059         (gl_FUNC_STRCASESTR): Likewise.
93060         Reported by Bruno Haible.
93062 2010-10-06  Bruno Haible  <bruno@clisp.org>
93064         string, sys_select: Avoid #including large headers unless necessary.
93065         * lib/string.in.h: Don't include <unistd.h> except on NetBSD.
93066         * lib/sys_select.in.h: Don't include <string.h> except on Solaris,
93067         OSF/1, BeOS, Haiku.
93068         Reported by Jim Meyering.
93070 2010-10-05  Eric Blake  <eblake@redhat.com>
93072         memmem, strstr, strcasestr: fix bug with long periodic needle
93073         * lib/str-two-way.h (two_way_long_needle): Avoid bug with long
93074         periodic needle having false positive.
93075         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): Detect bug in glibc 2.12
93076         and cygwin 1.7.7.
93077         (gl_FUNC_MEMMEM): Be more pessimistic when cross-compiling.
93078         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE)
93079         (gl_FUNC_STRCASESTR): Likewise.
93080         * m4/strstr.m4 (gl_FUNC_STRSTR_SIMPLE, gl_FUNC_STRSTR): Likewise.
93081         * tests/test-memmem.c (main): Expose the bug.
93082         * tests/test-strcasestr.c (main): Likewise.
93083         * tests/test-strstr.c (main): Likewise.
93084         * tests/test-c-strcasestr.c (main): Likewise.
93085         * doc/glibc-functions/memmem.texi (memmem): Document the bug.
93086         * doc/posix-functions/strstr.texi (strstr): Likewise.
93087         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
93088         Reported via http://sourceware.org/bugzilla/show_bug.cgi?id=12092
93090 2010-10-05  Paul Eggert  <eggert@cs.ucla.edu>
93092         parse-datetime: do some more renaming
93093         * doc/parse-datetime.texi (Authors of parse_datetime): Call it
93094         parse_datetime, not get_date.  Mention the renaming.
93095         * lib/parse-datetime.y:  Call it parse_datetime, not getdate,
93096         in comments.
93097         * m4/bison.m4: Likewise.
93099 2010-10-05  Eric Blake  <eblake@redhat.com>
93101         parse-datetime: better name than get_date
93102         * NEWS: Reword the deprecation notice.
93103         * modules/get_date: Rename to modules/parse-datetime.
93104         * modules/get_date-tests: Rename to modules/parse-datetime-tests.
93105         * m4/get_date.m4: Rename to m4/parse-datetime.m4.
93106         * lib/get_date.y: Rename to lib/parse-datetime.y.
93107         * tests/test-get_date.c: Rename to tests/test-parse-datetime.c.
93108         * doc/get_date.texi: Rename to doc/parse-datetime.texi.
93109         * doc/getdate.texi: Provide fallback wrapper.
93110         * lib/getdate.h: Move guts, and wrap...
93111         * lib/parse-datetime.h: ...new file.
93112         * lib/parse-datetime.y (get_date): Rename...
93113         (parse_datetime): ...to this.
93114         * m4/parse-datetime.m4 (gl_GET_DATE): Rename...
93115         (gl_PARSE_DATETIME): ...to this.
93116         * doc/posix-functions/getdate.texi (get_date): Provide fallback
93117         documentation.
93118         * modules/getdate (Files): Provide fallback docs and header.
93119         (Notice, Depends-on): Update references.
93120         * tests/test-parse-datetime.c: Likewise.
93121         * DEPENDENCIES: Likewise.
93122         * MODULES.html.sh (Date and time <time.h>): Likewise.
93123         * doc/parse-datetime.texi (Date input formats)
93124         (Authors of parse_datetime): Likewise.
93125         * modules/parse-datetime (Files, configure.ac, Makefile.am)
93126         (Include): Likewise.
93127         * modules/parse-datetime-tests (Files, Makefile.am): Likewise.
93128         * gnulib-tool: Likewise.
93129         * m4/bison.m4 (gl_BISON): Likewise.
93130         Suggested by Bruno Haible.
93132 2010-10-05  Paul Eggert  <eggert@cs.ucla.edu>
93134         more ports to Solaris tr, which needs [] around ranges
93135         * gnulib-tool: Solaris tr needs [] around ranges.
93136         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX): Likewise.
93137         * tests/test-pipe-filter-gi1.c (main): Likewise.
93138         * tests/test-pipe-filter-ii1.c (main): Likewise.
93140 2010-10-05  Eric Blake  <eblake@redhat.com>
93142         bootstrap: fix Solaris regression
93143         * build-aux/bootstrap (check_versions): Solaris tr still needs []
93144         around ranges.
93145         Reported by Pádraig Brady.
93147         bootstrap: work with pkg-config
93148         * build-aux/bootstrap (check_versions): Also transliterate - in
93149         prerequisite name.
93150         (print_versions): Be robust to any \ in $buildreq.  Avoid listing
93151         prerequisites that were already found, to avoid confusion.
93152         Reported by Justin Clift.
93154         faccessat: remove unused wrappers
93155         * lib/openat.h (accessat, euidaccesat): Delete, since the mere
93156         presence of these wrappers dragged in -lgen on Solaris.
93157         Reported by Clemens Brogi; fix suggested by Paul Eggert.
93159 2010-10-05  Jim Meyering  <meyering@redhat.com>
93161         tests: require @PRAGMA_COLUMNS@ with each @PRAGMA_SYSTEM_HEADER@
93162         * Makefile (sc_pragma_columns): New syntax-check rule.
93164 2010-10-04  Bruno Haible  <bruno@clisp.org>
93166         gnulib-tool: Synthesize appropriate _LDFLAGS for a libtool library.
93167         * gnulib-tool (func_emit_lib_Makefile_am): When preparing for a libtool
93168         library, put '-no-undefined' and the link dependencies into _LDFLAGS.
93169         Reported by Bruce Korb and Eric Blake.
93171 2010-10-04  Bruno Haible  <bruno@clisp.org>
93173         threadlib: Make option --with-libpth-prefix work.
93174         * m4/threadlib.m4 (gl_THREADLIB_BODY): When testing whether pth works,
93175         use $LIBPTH, not just -lpth.
93177 2010-10-04  Bruno Haible  <bruno@clisp.org>
93179         Avoid line length limitation from HP NonStop system header files.
93180         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define also PRAGMA_COLUMNS.
93181         * lib/arpa_inet.in.h: Use PRAGMA_COLUMNS.
93182         * lib/ctype.in.h: Likewise.
93183         * lib/dirent.in.h: Likewise.
93184         * lib/errno.in.h: Likewise.
93185         * lib/fcntl.in.h: Likewise.
93186         * lib/float.in.h: Likewise.
93187         * lib/getopt.in.h: Likewise.
93188         * lib/iconv.in.h: Likewise.
93189         * lib/inttypes.in.h: Likewise.
93190         * lib/langinfo.in.h: Likewise.
93191         * lib/locale.in.h: Likewise.
93192         * lib/math.in.h: Likewise.
93193         * lib/netdb.in.h: Likewise.
93194         * lib/netinet_in.in.h: Likewise.
93195         * lib/poll.in.h: Likewise.
93196         * lib/pthread.in.h: Likewise.
93197         * lib/pty.in.h: Likewise.
93198         * lib/sched.in.h: Likewise.
93199         * lib/se-selinux.in.h: Likewise.
93200         * lib/search.in.h: Likewise.
93201         * lib/signal.in.h: Likewise.
93202         * lib/spawn.in.h: Likewise.
93203         * lib/stdarg.in.h: Likewise.
93204         * lib/stddef.in.h: Likewise.
93205         * lib/stdint.in.h: Likewise.
93206         * lib/stdio.in.h: Likewise.
93207         * lib/stdlib.in.h: Likewise.
93208         * lib/string.in.h: Likewise.
93209         * lib/strings.in.h: Likewise.
93210         * lib/sys_file.in.h: Likewise.
93211         * lib/sys_ioctl.in.h: Likewise.
93212         * lib/sys_select.in.h: Likewise.
93213         * lib/sys_socket.in.h: Likewise.
93214         * lib/sys_stat.in.h: Likewise.
93215         * lib/sys_time.in.h: Likewise.
93216         * lib/sys_times.in.h: Likewise.
93217         * lib/sys_utsname.in.h: Likewise.
93218         * lib/sys_wait.in.h: Likewise.
93219         * lib/sysexits.in.h: Likewise.
93220         * lib/termios.in.h: Likewise.
93221         * lib/time.in.h: Likewise.
93222         * lib/unistd.in.h: Likewise.
93223         * lib/wchar.in.h: Likewise.
93224         * lib/wctype.in.h: Likewise.
93225         * modules/arpa_inet (Makefile.am): Substitute PRAGMA_COLUMNS.
93226         * modules/ctype (Makefile.am): Likewise.
93227         * modules/dirent (Makefile.am): Likewise.
93228         * modules/errno (Makefile.am): Likewise.
93229         * modules/fcntl-h (Makefile.am): Likewise.
93230         * modules/float (Makefile.am): Likewise.
93231         * modules/getopt-posix (Makefile.am): Likewise.
93232         * modules/iconv-h (Makefile.am): Likewise.
93233         * modules/inttypes (Makefile.am): Likewise.
93234         * modules/langinfo (Makefile.am): Likewise.
93235         * modules/locale (Makefile.am): Likewise.
93236         * modules/math (Makefile.am): Likewise.
93237         * modules/netdb (Makefile.am): Likewise.
93238         * modules/netinet_in (Makefile.am): Likewise.
93239         * modules/poll-h (Makefile.am): Likewise.
93240         * modules/pthread (Makefile.am): Likewise.
93241         * modules/pty (Makefile.am): Likewise.
93242         * modules/sched (Makefile.am): Likewise.
93243         * modules/search (Makefile.am): Likewise.
93244         * modules/selinux-h (Makefile.am): Likewise.
93245         * modules/signal (Makefile.am): Likewise.
93246         * modules/spawn (Makefile.am): Likewise.
93247         * modules/stdarg (Makefile.am): Likewise.
93248         * modules/stddef (Makefile.am): Likewise.
93249         * modules/stdint (Makefile.am): Likewise.
93250         * modules/stdio (Makefile.am): Likewise.
93251         * modules/stdlib (Makefile.am): Likewise.
93252         * modules/string (Makefile.am): Likewise.
93253         * modules/strings (Makefile.am): Likewise.
93254         * modules/sys_file (Makefile.am): Likewise.
93255         * modules/sys_ioctl (Makefile.am): Likewise.
93256         * modules/sys_select (Makefile.am): Likewise.
93257         * modules/sys_socket (Makefile.am): Likewise.
93258         * modules/sys_stat (Makefile.am): Likewise.
93259         * modules/sys_time (Makefile.am): Likewise.
93260         * modules/sys_times (Makefile.am): Likewise.
93261         * modules/sys_utsname (Makefile.am): Likewise.
93262         * modules/sys_wait (Makefile.am): Likewise.
93263         * modules/sysexits (Makefile.am): Likewise.
93264         * modules/termios (Makefile.am): Likewise.
93265         * modules/time (Makefile.am): Likewise.
93266         * modules/unistd (Makefile.am): Likewise.
93267         * modules/wchar (Makefile.am): Likewise.
93268         * modules/wctype (Makefile.am): Likewise.
93270 2010-10-04  Bruno Haible  <bruno@clisp.org>
93272         read-file tests: Avoid a test failure on NonStop Kernel.
93273         * tests/test-read-file.c (main): Don't assume that /etc/resolv.conf is
93274         a regular file.
93275         Reported by Joachim Schmitz <schmitz@hp.com>.
93277 2010-10-03  Bruno Haible  <bruno@clisp.org>
93279         gnulib-tool: Fixes for --create-testdir with --libtool.
93280         * gnulib-tool (func_get_automake_snippet): Don't augment
93281         EXTRA_lib_SOURCES for the pt_chown module, since pt_chown.o goes into
93282         an executable.
93283         (func_create_testdir): Handle module 'alloca' like func_import.
93284         Reported by Bruce Korb <bruce.korb@gmail.com>.
93286 2010-10-03  Paul Eggert  <eggert@cs.ucla.edu>
93288         Avoid some lines longer than 80 characters.
93289         * lib/stdint.in.h: Break long comment lines.
93290         * lib/math.in.h: Likewise.
93291         (_GL_NUM_UINT_WORDS): New macro, for readability.
93292         (gl_signbitf, gl_signbitd, gl_signbitl): Use it.
93293         * lib/stdio.in.h: Break lines in _GL_WARN_ON_USE calls.
93294         * lib/stdlib.in.h: Likewise.
93295         * lib/spawn.in.h: Likewise.
93296         * lib/sys_socket.in.h: Update an URL.
93297         * lib/sys_stat.in.h: Break long line.
93299 2010-10-03  Reuben Thomas  <rrt@sc3d.org>
93301         Improve pmccabe2html.
93302         * build-aux/pmccabe2html: Add CYCLO_SRCS variable, and make
93303         cyclo-$(PACKAGE).html depend on it, so the HTML file is remade
93304         when the sources change. Remove the line in the HTML about "Used
93305         ranges" (which implied that there might be other unused ranges),
93306         rename "Resume" to "Summary" (easier to understand for more users).
93307         * build-aux/pmccabe.css: Removing the dashed dividers, some unused
93308         styles, and some unnecessary blank lines.
93310 2010-10-03  Bruno Haible  <bruno@clisp.org>
93311             Joachim Schmitz  <schmitz@hp.com>  (tiny change)
93313         acl: Add support for ACLs on NonStop Kernel.
93314         * m4/acl.m4 (gl_FUNC_ACL): For Solaris, test for facl(), not for acl().
93315         Check whether the function aclsort() exists.
93316         * lib/acl-internal.h: For Solaris, test HAVE_FACL, not HAVE_ACL.
93317         (acl_nontrivial) [HAVE_ACLSORT]: New declaration.
93318         * lib/file-has-acl.c: For Solaris, test HAVE_FACL, not HAVE_ACL.
93319         (acl_nontrivial [HAVE_ACLSORT]: New function.
93320         (file_has_acl): Implement for NonStop Kernel.
93321         * lib/set-mode-acl.c: For Solaris, test HAVE_FACL, not HAVE_ACL.
93322         (qset_acl): Implement for NonStop Kernel.
93323         * lib/copy-acl.c (qcopy_acl): Implement for NonStop Kernel.
93324         * tests/test-sameacls.c: For Solaris, test HAVE_FACL, not HAVE_ACL.
93325         (main): Implement for NonStop Kernel.
93326         * tests/test-file-has-acl.sh (acl_flavor): Set to 'nsk' on NonStop
93327         Kernel. Handle this flavor.
93328         * tests/test-set-mode-acl.sh: Likewise.
93329         * tests/test-copy-acl.sh: Likewise.
93330         * tests/test-copy-file.sh: Likewise.
93332 2010-10-03  Bruno Haible  <bruno@clisp.org>
93334         Info about ACLs on NonStop Kernel.
93335         * doc/acl-resources.txt: Add info about NonStop Kernel.
93336         References by Joachim Schmitz <schmitz@hp.com>.
93338 2010-10-02  Bruno Haible  <bruno@clisp.org>
93340         Define missing EDQUOT on NonStop Kernel.
93341         * lib/errno.in.h (EDQUOT): Assign a value if missing.
93342         * lib/strerror.c (rpl_strerror): Handle missing EDQUOT.
93343         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Also test whether EDQUOT is
93344         missing.
93345         * doc/posix-headers/errno.texi: Mention the NSK bug.
93346         * doc/posix-functions/strerror.texi: Mention the workaround on NSK.
93347         Reported by Joachim Schmitz <schmitz@hp.com>.
93349 2010-10-02  Bruno Haible  <bruno@clisp.org>
93351         Update doc for POSIX:2008.
93352         * doc/posix-headers/*.texi [except ucontext.texi, sys_timeb.texi]:
93353         Update URL of POSIX specification.
93355 2010-10-02  Bruno Haible  <bruno@clisp.org>
93357         gnulib-tool: In testdirs, use the newest available config.{guess.sub}.
93358         * gnulib-tool (func_create_testdir): Use config.guess and config.sub
93359         from gnulib, not from Automake.
93361 2010-10-02  Bruno Haible  <bruno@clisp.org>
93363         New module 'system-posix'.
93364         * modules/system-posix: New file.
93365         * lib/stdlib.in.h: Include <sys/wait.h> only when the 'system-posix'
93366         module is present.
93367         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
93368         GNULIB_SYSTEM_POSIX.
93369         * modules/stdlib (Depends-on): Remove sys_wait.
93370         (Makefile.am): Substitute GNULIB_SYSTEM_POSIX.
93371         * doc/posix-functions/system.texi: Mention the new module.
93372         * doc/posix-headers/stdlib.texi: Likewise.
93373         * tests/test-stdlib.c: If GNULIB_TEST_SYSTEM_POSIX is not defined,
93374         define test_sys_wait_macros to a no-op.
93375         Reported by Sam Steingold <sds@gnu.org>.
93377 2010-09-30  Bruno Haible  <bruno@clisp.org>
93379         More renaming from 'getdate' to 'get_date'.
93380         * doc/get_date.texi: Renamed from doc/getdate.texi.
93381         * modules/get_date (Files): Update.
93382         * MODULES.html.sh (Date and time <time.h>): Update.
93383         * DEPENDENCIES: Update.
93384         * gnulib-tool: Update comment.
93385         * m4/bison.m4 (gl_BISON): Likewise.
93386         * m4/get_date.m4 (gl_GET_DATE): Likewise.
93388 2010-09-30  Justin Clift  <jclift@redhat.com>  (tiny change)
93390         bootstrap: support ACLOCAL_FLAGS during aclocal
93391         * build-aux/bootstrap (aclocal): Honor ACLOCAL_FLAGS, so the user
93392         can add additional -I dir for third-party .m4 files.
93394 2010-09-30  Eric Blake  <eblake@redhat.com>
93396         bootstrap: use glibtoolize on MacOS
93397         * build-aux/bootstrap (check_versions): Convert libtool into
93398         libtoolize.
93399         (tool search): Move libtool check earlier, and look for
93400         glibtoolize for MacOS.
93401         (gnulib_tool_options): Auto-add --libtool when appropriate.
93402         Reported by Justin Clift.
93404         poll: fix typo that broke test on MacOS
93405         * m4/poll.m4 (gl_FUNC_POLL): Add missing test.
93406         Reported by Justin Clift.
93408         getdate: rename to get_date
93409         Note: getdate.h is not renamed, to minimize client impact.
93410         * modules/getdate: Mark obsolete.  Move old contents...
93411         * modules/get_date: ...to new module name.
93412         * modules/getdate-tests: Move...
93413         * modules/get_date-tests: ...here.
93414         * m4/getdate.m4: Move...
93415         * m4/get_date.m4: ...here, and rename gl_GETDATE to gl_GET_DATE.
93416         * lib/getdate.y: Move...
93417         * lib/get_date.y: ...here.
93418         * tests/test-getdate.c: Move...
93419         * tests/test-get_date.c: ...here.
93420         * doc/posix-functions/getdate.texi (getdate): Update name.
93421         * NEWS: Mention the change.
93423 2010-09-29  Bruno Haible  <bruno@clisp.org>
93425         Separate the module 'waitpid' from the module 'sys_wait'.
93426         * lib/sys_wait.in.h (waitpid): Declare only if the 'waitpid' module is
93427         present.
93428         * m4/sys_wait_h.m4 (gl_SYS_WAIT_MODULE_INDICATOR): Invoke
93429         gl_MODULE_INDICATOR_FOR_TESTS.
93430         (gl_SYS_WAIT_H_DEFAULTS): Initialize GNULIB_WAITPID.
93431         * modules/sys_wait (Depends-on): Remove waitpid.
93432         (Makefile.am): Substitute GNULIB_WAITPID.
93433         * modules/waitpid (configure.ac): Invoke gl_SYS_WAIT_MODULE_INDICATOR.
93434         * tests/test-sys_wait-c++.cc (GNULIB_NAMESPACE::waitpid): Check the
93435         signature only if the 'waitpid' module is present.
93436         * doc/posix-functions/waitpid.texi: Mention the 'waitpid' module.
93437         * NEWS: Mention the change.
93438         * modules/grantpt (Depends-on): Add waitpid.
93439         * modules/wait-process (Depends-on): Likewise.
93441 2010-09-29  Bruno Haible  <bruno@clisp.org>
93443         More tests for module 'sys_wait'.
93444         * modules/sys_wait-c++-tests: New file.
93445         * tests/test-sys_wait-c++.cc: New file.
93446         * modules/sys_wait-tests (Depends-on): Add sys_wait-c++-tests.
93447         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>.
93449 2010-09-29  Bruno Haible  <bruno@clisp.org>
93451         New module 'waitpid'.
93452         * lib/waitpid.c: New file, extracted from lib/sys_wait.in.h.
93453         * lib/sys_wait.in.h: Include <sys/types.h>, c++defs.h, warn-on-use.h.
93454         Don't include <process.h>.
93455         (waitpid): Declare only, using modern idiom.
93456         * m4/waitpid.m4: New file.
93457         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H): Check whether waitpid is declared.
93458         * modules/waitpid: New file.
93459         * modules/sys_wait (Depends-on): Add c++defs, warn-on-use, waitpid.
93460         (Makefile.am): Update.
93461         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>.
93463 2010-09-28  Bruno Haible  <bruno@clisp.org>
93465         poll: Assume ANSI C.
93466         * lib/poll.c (poll): Use an ANSI C declaration.
93468 2010-09-28  Bruno Haible  <bruno@clisp.org>
93470         poll-h: Create poll.h on all platforms.
93471         * lib/poll.in.h: Use double-inclusion guard. Don't define POLL*,
93472         struct pollfd, nfds_t, INFTIM when the system has <poll.h>.
93473         * m4/poll_h.m4 (gl_POLL_H): Set HAVE_POLL_H. Invoke
93474         gl_CHECK_NEXT_HEADERS. Don't set POLL_H.
93475         (gl_REPLACE_POLL_H): Don't set POLL_H.
93476         (gl_POLL_H_DEFAULTS): Don't initialize POLL_H.
93477         * modules/poll-h (Depends-on): Add include_next.
93478         (Makefile.am): Create poll.h unconditionally. Substitute also
93479         HAVE_POLL_H, INCLUDE_NEXT, PRAGMA_SYSTEM_HEADER, NEXT_POLL_H.
93481 2010-09-28  Bruno Haible  <bruno@clisp.org>
93483         Tests for module 'poll-h'.
93484         * modules/poll-h-c++-tests: New file.
93485         * tests/test-poll-h-c++.cc: New file.
93487         Tests for module 'poll-h'.
93488         * modules/poll-h-tests: New file.
93489         * tests/test-poll-h.c: New file.
93491 2010-09-28  Bruno Haible  <bruno@clisp.org>
93493         poll-h: Ensure POLL{RD,WR}{NORM,BAND} are defined on glibc platforms.
93494         * modules/poll-h (Depends-on): Add 'extensions'.
93496 2010-09-28  Bruno Haible  <bruno@clisp.org>
93498         New module 'poll-h'.
93499         * lib/poll.in.h: Include c++defs.h and warn-on-use.h.
93500         (poll): Use modern idiom.
93501         * modules/poll-h: New file.
93502         * modules/poll (Files): Remove lib/poll.in.h.
93503         (Depends-on): Add poll-h.
93504         (configure.ac): Invoke gl_POLL_MODULE_INDICATOR.
93505         (Makefile.am): Move code for generation of poll.h to modules/poll-h.
93506         * m4/poll_h.m4: New file.
93507         * m4/poll.m4 (gl_FUNC_POLL): Require gl_POLL_H. Don't check for poll.h
93508         here. Don't set POLL_H here. Instead, set HAVE_POLL and REPLACE_POLL
93509         and invoke gl_REPLACE_POLL_H.
93510         * lib/poll.c: Use common idiom.
93511         * tests/test-poll.c: Likewise.
93512         * doc/posix-headers/poll.texi: Mention the poll-h module.
93513         Suggested by Eric Blake.
93515 2010-09-26  Bruno Haible  <bruno@clisp.org>
93517         sys_wait: Implement WSTOPSIG.
93518         * lib/sys_wait.in.h (WSTOPSIG): New macro.
93519         Reported by Simon Josefsson.
93521 2010-09-26  Simon Josefsson  <simon@josefsson.org>
93523         stdlib, sys_wait: Avoid compilation error on mingw.
93524         * lib/sys_wait.in.h: Include <signal.h>, for SIGTERM.
93526 2010-09-26  Bruno Haible  <bruno@clisp.org>
93528         stdlib tests: Avoid code duplication.
93529         * modules/stdlib-tests (Files): Add tests/test-sys_wait.h.
93530         * modules/sys_wait-tests (Files): Likewise.
93531         * tests/test-sys_wait.h: New file, extracted from tests/test-stdlib.c.
93532         * tests/test-stdlib.c: Include test-sys_wait.h.
93533         (main): Invoke test_sys_wait_macros.
93534         * tests/test-sys_wait.c: Include test-sys_wait.h.
93535         (main): Invoke test_sys_wait_macros.
93537 2010-09-25  Simon Josefsson  <simon@josefsson.org>
93539         * modules/getaddrinfo (Depends-on): Depend on the sockets module.
93540         * lib/getaddrinfo.c (use_win32_p): Call gl_sockets_startup to make
93541         sure Windows sockets are working before calling getaddrinfo.
93542         * tests/test-getaddrinfo.c (main): Don't call WSAStartup here.
93543         * doc/gnulib.texi (Windows sockets): Fix typo.
93545 2010-09-25  Bruno Haible  <bruno@clisp.org>
93547         Tests for module 'regex-quote'.
93548         * modules/regex-quote-tests: New file.
93549         * tests/test-regex-quote.c: New file.
93551         New module 'regex-quote'.
93552         * lib/regex-quote.h: New file.
93553         * lib/regex-quote.c: New file.
93554         * modules/regex-quote: New file.
93555         Suggested by Reuben Thomas <rrt@sc3d.org>.
93557 2010-09-24  Bruno Haible  <bruno@clisp.org>
93559         unistr/u8-strchr: Fix a test failure on i586 glibc systems.
93560         * tests/unistr/test-strchr.h (test_strchr): Disable an invalid check.
93562 2010-09-23  Bruno Haible  <bruno@clisp.org>
93564         setenv: Relax license.
93565         * modules/setenv (License): Change to LGPLv2+, with consent by Eric
93566         Blake.
93567         Requested by Eric Blake.
93569 2010-09-22  Bruno Haible  <bruno@clisp.org>
93571         termios: Relax license.
93572         * modules/termios (License): Change to LGPLv2+.
93573         Requested by Eric Blake.
93575 2010-09-22  Bruno Haible  <bruno@clisp.org>
93577         threadlib: Allow the package to change the default to 'no'.
93578         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): When
93579         gl_THREADLIB_DEFAULT_NO is defined, change the default to 'no'.
93580         Reported by Paul Eggert.
93582 2010-09-22  Pádraig Brady  <P@draigbrady.com>
93583             Bruno Haible  <bruno@clisp.org>
93585         Fix endless loop in mbmemcasecoll.
93586         * lib/mbmemcasecoll.c (apply_towlower): When mbrtowc returns 0, copy 1
93587         byte.
93588         * tests/test-mbmemcasecmp.h (test_ascii): Test embedded NULs.
93590 2010-09-22  Bruno Haible  <bruno@clisp.org>
93592         Tests for module 'memcoll'.
93593         * modules/memcoll-tests: New file.
93594         * tests/test-memcoll.c: New file, based on tests/test-memcmp.c.
93596         memcoll, xmemcoll: Clarify size vs. length.
93597         * modules/memcoll.c (memcoll0): Clarify specification.
93598         * modules/xmemcoll.c (xmemcoll0): Likewise. Reduce by 1 the lengths
93599         passed to collate_error.
93601 2010-09-22  Bruno Haible  <bruno@clisp.org>
93603         Tests for module 'memcasecmp'.
93604         * modules/memcasecmp-tests: New file.
93605         * tests/test-memcasecmp.c: New file, based on tests/test-memcmp.c.
93607 2010-09-22  Paul Eggert  <eggert@cs.ucla.edu>
93609         * lib/pthread.in.h: Add split double-inclusion guard, and include
93610         system <pthread.h> if there is one.  Use @@-style as in other
93611         .in.h files.  Define PTHREAD_COND_INITIALIZER etc. only if system
93612         pthread.h doesn't.
93613         (pthread_mutexattr_destroy, pthread_mutexattr_init):
93614         (pthread_mutexattr_settype, pthread_mutex_trylock):
93615         New static inline functions, if there's no system <pthread.h>.
93616         (pthread_spinlock_t, pthread_spin_init, pthread_spin_destroy):
93617         (pthread_spin_lock, pthread_spin_trylock, pthread_spin_unlock):
93618         Approximate with mutexes if the system lacks spinlocks, as in
93619         MacOS.
93620         * m4/pthread.m4 (gl_PTHREAD_CHECK): Require gl_PTHREAD_DEFAULTS.
93621         Add gl_CHECK_NEXT_HEADERS for pthread.h, and support the usual
93622         @@-style.  Check for spinlocks separately.
93623         (gl_PTHREAD_DEFAULTS): New macro.
93624         * modules/pthread: Redo to use a more typical style for in.h files.
93626 2010-09-21  Eric Blake  <eblake@redhat.com>
93628         net_if: enhance tests
93629         * tests/test-net_if.c (main): Move signature checks earlier.
93630         Print failures to stderr.
93631         * doc/posix-functions/if_freenameindex.texi (if_freenameindex):
93632         Document the bug that we do not yet fix.
93634 2010-09-21  Reuben Thomas  <rrt@sc3d.org>
93636         * doc/gnulib.texi (Out of memory handling): Rewrite section to be
93637         about gnulib, not GSS.
93639 2010-09-21  Reuben Thomas  <rrt@sc3d.org>
93641         * build-aux/pmccabe2html: Look for sources in src/ instead of lib/.
93642         * build-aux/pmccabe2html: Set cut_dir properly, and add mode line
93643         for Emacs.
93644         * build-aux/pmccabe2html: Make Makefile.am example code more
93645         cut-and-paste friendly.
93647 2010-09-21  Simon Josefsson  <simon@josefsson.org>
93649         * tests/test-net_if.c: New file.
93650         * modules/net_if-tests: New file.
93652 2010-09-20  Paul Eggert  <eggert@cs.ucla.edu>
93654         pthread: add pthread_spin_destroy
93655         * lib/pthread.in.h (pthread_spin_destroy): New function.
93657 2010-09-19  Bruno Haible  <bruno@clisp.org>
93659         gnulib-tool: Fix --help output.
93660         * gnulib-tool (func_usage): Fix help message.
93661         Reported by Reuben Thomas <rrt@sc3d.org>.
93663 2010-09-18  Jim Meyering  <meyering@redhat.com>
93665         maint.mk: avoid unexpanded \n in two diagnostics
93666         * top/maint.mk (sc_prohibit_always_true_header_tests):
93667         Don't use a literal \n in a halt=... assignment.  It would not be
93668         expanded, and the two \n bytes would appear in the diagnostic output
93669         rather than the desired newline.  Use halt=$$(printf ... instead.
93670         (sc_vulnerable_makefile_CVE-2009-4029): Likewise.
93672 2010-09-18  Bruno Haible  <bruno@clisp.org>
93674         netinet_in: Doc tweak.
93675         * doc/posix-headers/netinet_in.texi: Mention an affected platform.
93676         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
93678 2010-09-18  Jim Meyering  <meyering@redhat.com>
93680         init.sh: correct an outdated comment
93681         * tests/init.sh (create_exe_shims_):  s/function/alias/
93683         init.sh: don't let an ephemeral "*.exe" make us skip all dir entries
93684         * tests/init.sh (find_exe_basenames_): Don't give up on a directory if
93685         a file named "*.exe" is removed between the glob expansion and the
93686         processing of that oddly named file.
93688 2010-09-17  Eric Blake  <eblake@redhat.com>
93690         mirbsd: add some more support
93691         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): MirBSD is
93692         in BSD family.
93693         * m4/gc-random.m4 (gl_GC_RANDOM): MirBSD supports same random
93694         devices as OpenBSD.
93695         * m4/host-os.m4 (mirbsd): Add MirBSD.
93697         tests: fix unportable assumption on sys/wait.h
93698         * tests/test-sys_wait.c (main): Relax test.
93699         * tests/test-stdlib.c (main): Likewise.
93701         init.sh: accommodate directory with no .exes
93702         * tests/init.sh: Accomodate directory containing only scripts.
93704         tests: avoid compiler warning
93705         * tests/test-stdlib.c (main): Use the variable.
93707         fdutimens, fdutimensat: update signature, again
93708         * lib/utimens.h (gl_futimens): Delete, and move signature...
93709         (fdutimens): ...here.
93710         (fdutimensat): Rearrange signature.
93711         (lutimensat): Rename variable for clarity.
93712         * lib/fdutimensat.c (fdutimensat): Update signature.
93713         * lib/utimens.c (fdutimens): Likewise.
93714         (gl_futimens): Delete.
93715         (utimens, lutimens): Update callers.
93716         * lib/futimens.c (futimens): Likewise.
93717         * tests/test-fdutimensat.c: Likewise.
93718         * tests/test-utimens.c: Likewise.
93719         * tests/test-futimens.h: Update comment.
93720         * NEWS: Mention this.
93721         Suggested by Paul Eggert.
93723 2010-09-17  Bruno Haible  <bruno@clisp.org>
93725         Take over the maintenance of some older macros from Autoconf.
93726         * m4/error.m4 (AC_FUNC_ERROR_AT_LINE): New macro, from GNU Autoconf.
93727         * m4/lstat.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): New macro, from
93728         GNU Autoconf.
93729         * m4/memcmp.m4 (AC_FUNC_MEMCMP): New macro, from GNU Autoconf.
93730         * m4/mktime.m4 (AC_FUNC_MKTIME): Change comment.
93732 2010-09-17  Eric Blake  <eblake@redhat.com>
93734         fdutimensat: drop atflag validation
93735         * lib/fdutimensat.c (fdutimensat): Allow AT_SYMLINK_NOFOLLOW even
93736         with valid fd, to close a race scenario where futimens is
93737         unsupported and FILE was replaced by a symlink.
93738         * tests/test-fdutimensat.c (do_fdutimens, main): Adjust test
93739         accordingly.
93740         Suggested by Paul Eggert.
93742 2010-09-16  Bruno Haible  <bruno@clisp.org>
93744         unlockpt: Fix declaration within GNULIB_POSIXCHECK.
93745         * lib/stdlib.in.h (unlockpt): Fix warning declaration.
93747 2010-09-16  Bruno Haible  <bruno@clisp.org>
93749         login_tty: Fix detection of function on FreeBSD, OpenBSD, NetBSD.
93750         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): Augment LIBS while checking whether
93751         login_tty exists.
93752         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
93754 2010-09-16  Bruno Haible  <bruno@clisp.org>
93756         login_tty: Make the replacement code work on BSD systems.
93757         * lib/login_tty.c: Include <sys/ioctl.h>.
93758         (login_tty): Use ioctl TIOCSCTTY when available.
93759         * modules/login_tty (Depends-on): Add sys_ioctl.
93760         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
93762 2010-09-16  Bruno Haible  <bruno@clisp.org>
93764         login_tty: Stricter unit test.
93765         * modules/login_tty-tests (Depends-on): Add tcgetsid.
93766         * tests/test-login_tty.c (main): Also check the results of tcgetpgrp()
93767         and tcgetsid() after login_tty.
93768         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
93770 2010-09-16  Bruno Haible  <bruno@clisp.org>
93772         New module 'tcgetsid'.
93773         * lib/tcgetsid.c: New file.
93774         * m4/tcgetsid.m4: New file.
93775         * modules/tcgetsid: New file.
93776         * modules/termios (Depends-on): Add c++defs, warn-on-use.
93777         (Makefile.am): Ensure c++defs.h, warn-on-use.h get included. Substitute
93778         GNULIB_TCGETSID, HAVE_TCGETSID.
93779         * lib/termios.in.h: Include <sys/types.h>.
93780         (tcgetsid): New declaration.
93781         * m4/termios_h.m4 (gl_TERMIOS_H): Check whether tcgetsid is declared.
93782         (gl_TERMIOS_H_DEFAULTS): Initialize GNULIB_TCGETSID, HAVE_TCGETSID.
93783         * doc/posix-functions/tcgetsid.texi: Mention the new module.
93784         * tests/test-termios-c++.cc: Check GNULIB_NAMESPACE::tcgetsid.
93786 2010-09-16  Bruno Haible  <bruno@clisp.org>
93788         Tests for module 'termios'.
93789         * modules/termios-c++-tests: New file.
93790         * modules/termios-tests: New file.
93791         * tests/test-termios-c++.cc: New file.
93792         * tests/test-termios.c: New file.
93794         New module 'termios'.
93795         * modules/termios: New file.
93796         * lib/termios.in.h: New file.
93797         * m4/termios_h.m4: New file.
93798         * doc/posix-headers/termios.texi: Mention the new module.
93800 2010-09-16  Eric Blake  <eblake@redhat.com>
93802         fdutimensat: add an atflag parameter
93803         * lib/fdutimensat.c (fdutimensat): Add new parameter.
93804         * lib/utimens.h (fdutimensat): Update prototype.
93805         * tests/test-fdutimensat.c: Adjust test to match.
93806         * NEWS: Document the change.
93807         Suggested by Paul Eggert.
93809 2010-09-16  Bruno Haible  <bruno@clisp.org>
93811         Fix typos in comments.
93812         * lib/striconveh.h: Fix typo in comment.
93813         * lib/login_tty.c (login_tty): Likewise.
93815 2010-09-15  Bruno Haible  <bruno@clisp.org>
93817         stdlib: clarify MirBSD WEXITSTATUS bug
93818         * lib/stdlib.in.h: Clarify the MirBSD bug regarding WEXITSTATUS.
93819         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
93821 2010-09-15  Eric Blake  <eblake@redhat.com>
93823         stdlib: work around MirBSD WEXITSTATUS bug
93824         * lib/stdlib.in.h (includes): Guarantee WEXITSTATUS.
93825         * modules/stdlib (Depends-on): Add sys_wait.
93826         * tests/test-sys_wait.c (main): Enhance test.
93827         * tests/test-stdlib.c (main): Likewise.
93828         * doc/posix-headers/stdlib.texi (stdlib.h): Document the bug.
93830         docs: mention MacOS issue with WEXITSTATUS(constant)
93831         * doc/posix-headers/sys_wait.texi (sys/wait.h): Document the
93832         issue.
93833         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
93835         strnlen: add tests
93836         * modules/strnlen-tests: New file.
93837         * tests/test-strnlen.c: Likewise.
93839 2010-09-14  Bruno Haible  <bruno@clisp.org>
93841         unistr/base: Avoid link errors when module 'libunistring' is also used.
93842         * lib/unistr.in.h (u8_mbtouc_unsafe, u16_mbtouc_unsafe,
93843         u32_mbtouc_unsafe, u8_mbtouc, u16_mbtouc, u32_mbtouc, u8_mbtoucr,
93844         u16_mbtoucr, u32_mbtoucr, u8_uctomb_aux, u16_uctomb_aux, u32_uctomb):
93845         Declare also when HAVE_LIBUNISTRING is set.
93846         Reported by Pádraig Brady <P@draigbrady.com>.
93848 2010-09-14  Eric Blake  <eblake@redhat.com>
93850         test-rawmemchr: make more robust
93851         * modules/rawmemchr-tests (Files): Add zerosize-ptr.h, mmap-anon.m4.
93852         (Depends-on, configure.ac): Add needed prerequisites to use it.
93853         * modules/memchr-tests (Files, Depends-on, configure.ac):
93854         Likewise, to avoid implicit reliance on memchr module prereqs.
93855         * tests/test-memchr.c (main): Ensure proper masking.
93856         * tests/test-rawmemchr.c (main): Likewise.  Detect oversized
93857         reads.
93859         memchr: detect glibc Alpha bug
93860         Avoids http://sourceware.org/bugzilla/show_bug.cgi?id=12019.
93861         * m4/memchr.m4 (gl_FUNC_MEMCHR): Detect glibc 2.11.2 failure on
93862         Alpha.
93863         * doc/posix-functions/memchr.texi (memchr): Tweak wording.
93864         * tests/test-memchr.c (main): Enhance test.
93865         Reported by Nelson H. F. Beebe.
93867 2010-09-13  Paul Eggert  <eggert@cs.ucla.edu>
93869         fts, getcwd, glob: audit for dirfd returning -1
93870         * lib/fts.c (opendir): Remove #define; no longer used.
93871         (opendirat): New arg PDIR_FD.  All callers changed.
93872         (fts_build, _opendir2): Use new opendirat to avoid the need for
93873         dirfd, or for checking whether dirfd returns a negative value.
93874         Don't use opendir; always use openat followed by fdopendir.
93875         * lib/getcwd.c (__getcwd): Don't reset fd; fdopendir no longer clobbers
93876         it.
93877         * lib/glob.c (link_exists_p): Add comment explaining why dirfd never
93878         returns -1 here.
93879         * modules/fts (Depends-on): Remove dirfd.
93880         * modules/getcwd (Depends-on): Likewise.
93882 2010-09-13  Eric Blake  <eblake@redhat.com>
93884         float: fix broken MirBSD header
93885         * m4/float_h.m4 (gl_FLOAT_H): MirBSD copied OpenBSD's bug.
93886         * doc/posix-headers/float.texi (float.h): Document it.
93888 2010-09-13  Paul Eggert  <eggert@cs.ucla.edu>
93890         fts: use O_NOFOLLOW to avoid race condition when opening a directory
93891         * lib/fts.c (opendirat): New arg extra_flags.
93892         (__opendir2): Use it to avoid following symlinks when opening
93893         a directory, if symlinks are not supposed to be followed.  See
93894         <http://lists.gnu.org/r/bug-gnulib/2010-09/msg00213.html>.
93896         fdopendir: preserve argument fd before returning
93897         * lib/fdopendir.c: Adjust comments to say POSIX, not Solaris.
93898         (fdopendir_with_dup, fd_clone_opendir): New static functions.
93899         (fdopendir): Use them, arranging for FD to be open to the same
93900         directory that it was when it started.  (It might be temporarily
93901         closed while fdopendir is running, so this not thread- or
93902         signal-safe.)  Be careful to do the right thing even when file
93903         descriptors are scarce and dup fails with errno == EMFILE.  See
93904         <http://lists.gnu.org/r/bug-gnulib/2010-09/msg00208.html>.
93906 2010-09-10  Paolo Bonzini  <bonzini@gnu.org>
93908         regex: Pass the system regex if its only problem is 32-bit regoff_t.
93909         * NEWS: Document change.
93910         * m4/regex.m4: Disable test for regoff_t size.
93912 2010-09-13  Jim Meyering  <meyering@redhat.com>
93914         fts: don't operate on an invalid file descriptor after failed dup
93915         * lib/fts.c (fts_build): Don't call set_cloexec_flag on a
93916         negative file descriptor.
93918 2010-09-12  Paul Eggert  <eggert@cs.ucla.edu>
93920         savedir: add streamsavedir, deprecate fdsavedir
93921         * NEWS: Mention deprecation of fdsavedir.
93922         * lib/savedir.c (streamsavedir): New extern function, whose name
93923         ends in "savedir" to be consistent with the others.  This differs
93924         from savedirstream in that it doesn't close its argument.  The
93925         next version of GNU tar will use this instead of fdsavedir, to
93926         avoid some race conditions and conserve file descriptors.
93927         (savedirstream): Reimplement as a wrapper around streamsavedir.
93928         (fdsavedir): Add a comment deprecating this function.  As far as
93929         I know, only GNU tar used it, and GNU tar doesn't need it any more.
93930         * lib/savedir.h (streamsavedir): New decl.
93931         (fdsavedir): Add a comment deprecating this.
93933 2010-09-10  Bruno Haible  <bruno@clisp.org>
93935         langinfo: Fix last commit.
93936         * m4/langinfo_h.m4 (gl_LANGINFO_H): Initialize
93937         HAVE_LANGINFO_T_FMT_AMPM, HAVE_LANGINFO_YESEXPR.
93938         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
93940 2010-09-10  Bruno Haible  <bruno@clisp.org>
93942         relocatable-prog-wrapper: Fix compilation failure due to O_EXEC.
93943         * lib/progreloc.c (O_EXEC): Define fallback.
93945 2010-09-10  Paul Eggert  <eggert@cs.ucla.edu>
93947         fcntl-h: define O_CLOEXEC and O_EXEC if not defined; use new defines
93948         * NEWS: Document recent changes to fcntl-h.
93949         * doc/posix-headers/fcntl.texi (fcntl.h): Document that
93950         O_CLOEXEC is now defined to 0 if it is not defined, like other flags.
93951         Also, O_EXEC is now defined to be O_RDONLY if O_EXEC is not defined.
93952         Similarly for O_SEARCH; this last was already true, but not documented.
93953         * lib/fcntl.in.h (O_CLOEXEC): Define to 0 if not defined.
93954         * lib/dup-safer-flag.c (O_CLOEXEC): Remove now-useless #define.
93955         * lib/dup3.c, lib/pipe2.c, tests/test-dup-safer.c, tests/test-fcntl.c:
93956         Likewise.
93957         * lib/popen-safer.c (open_noinherit): Check whether O_CLOEXEC
93958         is zero, not whether it is defined.
93959         * tests/test-dup3.c, tests/test-pipe2.c (main): Likewise.
93960         * lib/progreloc.c (find_executable): Use O_EXEC rather than O_RDONLY.
93961         * lib/open.c (open): Check for O_SEARCH as well as for O_RDONLY.
93963 2010-09-10  Bruno Haible  <bruno@clisp.org>
93965         langinfo, nl_langinfo: Fix for IRIX 5.3.
93966         * m4/langinfo_h.m4 (gl_LANGINFO_H): Test whether langinfo.h defines
93967         T_FMT_AMPM, YESEXPR. Set HAVE_LANGINFO_T_FMT_AMPM,
93968         HAVE_LANGINFO_YESEXPR.
93969         * modules/langinfo (Makefile.am): Substitute HAVE_LANGINFO_T_FMT_AMPM,
93970         HAVE_LANGINFO_YESEXPR.
93971         * lib/langinfo.in.h (T_FMT_AMPM, GNULIB_defined_T_FMT_AMPM): Define if
93972         HAVE_LANGINFO_T_FMT_AMPM is 0.
93973         (YESEXPR, NOEXPR, GNULIB_defined_YESEXPR): Define if
93974         HAVE_LANGINFO_YESEXPR is 0.
93975         * lib/nl_langinfo.c (rpl_nl_langinfo): Handle also T_FMT_AMPM, YESEXPR,
93976         NOEXPR.
93977         * doc/posix-headers/langinfo.texi: Mention the IRIX 5.3 problem.
93978         * doc/posix-functions/nl_langinfo.texi: Likewise.
93979         Reported by Eric Blake.
93981 2010-09-10  Bruno Haible  <bruno@clisp.org>
93983         pty, readutmp: Fix for FreeBSD 8.0 and OpenBSD 4.6.
93984         * doc/glibc-functions/login_tty.texi: Mention the include file problem
93985         on FreeBSD 8.0 and OpenBSD 4.6.
93986         * lib/pty.in.h: Include <sys/types.h> before <libutil.h>.
93987         * m4/pty_h.m4 (gl_PTY_H): Likewise.
93988         * m4/pty.m4 (gl_FUNC_FORKPTY, gl_FUNC_OPENPTY): Likewise.
93989         * m4/readutmp.m4 (gl_READUTMP): Include <sys/types.h> before <utmp.h>.
93990         Invoke AC_INCLUDES_DEFAULT instead of using the undocumented variable
93991         ac_includes_default.
93992         Reported by Mats Erik Andersson <mats.andersson@gisladisker.se>.
93994 2010-09-09  Eric Blake  <eblake@redhat.com>
93996         strsignal: work around NetBSD bug
93997         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Also check in <unistd.h>.
93998         * lib/string.in.h (includes): Likewise.
93999         * doc/posix-functions/strsignal.texi (strsignal): Document the
94000         bug.
94001         Reported by Nelson H. F. Beebe.
94003         gnulib-tool: work with NetBSD /bin/sh
94004         * gnulib-tool (func_cache_var, func_cache_lookup_module)
94005         (func_get_description, func_get_comment, func_get_status)
94006         (func_get_notice, func_get_applicability, func_get_filelist)
94007         (func_get_dependencies, func_get_autoconf_early_snippet)
94008         (func_get_autoconf_snippet, func_get_automake_snippet)
94009         (func_get_include_directive, func_get_link_directive)
94010         (func_get_license, func_get_maintainer, func_import): Avoid
94011         shell syntax errors from parsing syntax extensions.
94013 2010-09-09  Bruno Haible  <bruno@clisp.org>
94015         gnulib-tool: Avoid stderr output on IRIX related to 'alias', 'unalias'.
94016         * gnulib-tool: Don't fiddle with file descriptors 0, 1, 2. Instead, use
94017         a reliable way to determine whether the 'alias' command works.
94019 2010-09-08  Jim Meyering  <meyering@redhat.com>
94021         init.sh: penalize a set-x-impaired shell; don't disqualify it
94022         * tests/init.sh: Too many shells corrupt application stderr when
94023         you set -x, so we can't afford to disqualify them, since at least
94024         on Irix-6.5, that would disqualify all bourne shells.
94025         Instead, use a two-pass approach.
94026         On the first pass, try to find a shell that meets the stricter
94027         condition that set -x does not corrupt stderr.
94028         If no shell meets the stricter condition, retest each candidate
94029         shell, but without that extra condition.  Finally, when
94030         VERBOSE=yes is requested and set -x might cause trouble, simply
94031         issue a warning and refrain from enabling debug output.
94033 2010-09-08  Eric Blake  <eblake@redhat.com>
94035         unsetenv: fix OpenBSD bug
94036         * m4/setenv.m4 (gl_FUNC_UNSETENV): Check for OpenBSD bug.
94037         * doc/posix-functions/unsetenv.texi (unsetenv): Update
94038         documentation.
94039         Reported by Jim Meyering.
94041         strtod: work around IRIX 6.5 bug
94042         * lib/strtod.c (strtod): Reparse number on shorter string if
94043         exponent parse was invalid.
94044         * tests/test-strtod.c (main): Add check for "0x1p 2".
94045         Reported by Tom G. Christensen.
94047         getopt: optimize previous patch
94048         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Correctly check for
94049         empty variable.  Speed up awk script.
94050         Reported by Paolo Bonzini.
94052 2010-09-08  Jim Meyering  <meyering@redhat.com>
94054         test.sh: disqualify shells for which set -x corrupts stderr
94055         * tests/init.sh: Add a test to disqualify /bin/sh from SunOS 5.11
94056         and OpenBSD 4.7.  They make it so with "set -x", environment settings
94057         appear in stderr output.  For example, this command:
94058             /bin/sh -c 'set -x; P=1 true 2> err' 2>/dev/null; cat err
94059         prints "P=1" on those two systems:
94061 2010-09-08  Bruno Haible  <bruno@clisp.org>
94063         gnulib-tool: Avoid stderr output on IRIX related to 'alias', 'unalias'.
94064         * gnulib-tool: Use stderr redirection around the 'alias' and 'unalias'
94065         commands, because some shells ignore redirections when there is an
94066         error in the command lookup.
94067         Reported by Eric Blake.
94069 2010-09-07  Reuben Thomas  <rrt@sc3d.org>
94071         * lib/regex.h: Fix a mention of `regex_compile' (should be
94072         `re_compile_pattern').
94073         Correct and clarify documentation for RE_CONTEXT_INVALID_DUP.
94074         (re_set_registers): Correct name of parameter in comment.
94076         * doc/regex.texi: Add documentation for missing syntax flags.
94077         Remove commented-out documentation of defunct syntax option
94078         RE_NO_EMPTY_ALTS.
94079         Correct name of RE_CHAR_CLASSES in one incorrect occurrence.
94080         Add documentation of re_set_registers.
94081         Document trick to re-use a pattern buffer by setting fastmap manually.
94082         Update documentation of struct re_pattern_buffer per public members.
94083         Uncomment documentation of equivalence class operators and
94084         collating symbol operators, since they are now implemented,
94085         Explain leftmost-longest matching in relation to alternatives.
94086         Tidy documentation of substring matching.
94087         Remove POSIX documentation, which is done better in
94088         glibc, and refer the reader there. Keep BSD API documentation, as
94089         that is not readily available elsewhere.
94091 2010-09-07  Eric Blake  <eblake@redhat.com>
94093         getopt: handle POSIXLY_CORRECT set but not exported
94094         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Restore pre-existing
94095         export state of POSIXLY_CORRECT, due to bash set -o posix.
94096         Reported by Dustin J. Mitchell.
94098 2010-09-05  Bruno Haible  <bruno@clisp.org>
94100         gnulib-tool: Highlight the changed options.
94101         * gnulib-tool (func_usage): Display the --import, --add-import,
94102         --remove-import explanations in bold font.
94104 2010-09-06  Karl Berry  <karl@gnu.org>
94106         * doc/gnulib-tool.texi (Modified imports): doc tweaks.
94108 2010-09-05  Bruno Haible  <bruno@clisp.org>
94110         uniwidth/width: Update comment.
94111         * lib/uniwidth/width.c (uc_width): Update comment for Unicode >= 3.1.
94112         Reported by Emanuele Giaquinta <emanuele.giaquinta@gmail.com>.
94114 2010-09-05  Bruno Haible  <bruno@clisp.org>
94116         isinf, isnan: Relax license.
94117         * modules/isinf (License): Change from GPL to LGPL, with consent from
94118         Ben Pfaff.
94119         * modules/isnan (License): Likewise.
94120         Requested by Ludovic Courtès.
94122 2010-09-04  Bruno Haible  <bruno@clisp.org>
94124         gnulib-tool: Help migration from --import to --add-import or --update.
94125         * gnulib-tool: Emit a verbose error message when --import is used
94126         without any module name.
94128 2010-09-04  Bruno Haible  <bruno@clisp.org>
94130         Update doc about gnulib-tool.
94131         * doc/gnulib-tool.texi (VCS Issues): Explain 'gnulib-tool --import' vs.
94132         'gnulib-tool --update' in more detail.
94133         Reported by Eric Blake.
94135 2010-09-04  Bruno Haible  <bruno@clisp.org>
94137         gnulib-tool: Change --import. New options --add/remove-import.
94138         * gnulib-tool: New options --add-import, --remove-import.
94139         (func_usage): Document them.
94140         (have_associative): Define always.
94141         (func_import): In import mode, don't merge the specified settings with
94142         the cached settings. Implement remove-import mode.
94143         * doc/gnulib-tool.texi (Modified imports): Mention the new options.
94144         Explain when to use them versus --import.
94145         (Simple update): Use --add-import instead of --import.
94146         * NEWS: Mention the change.
94148 2010-09-04  Bruno Haible  <bruno@clisp.org>
94150         * doc/gnulib-tool.texi (Initial import): Update paragraph about
94151         separate gnulib.mk.
94153 2010-09-04  Bruno Haible  <bruno@clisp.org>
94155         gnulib-tool: Don't talk about CVS any more.
94156         * gnulib-tool (func_usage, func_import): Write "version control"
94157         instead of CVS.
94159 2010-09-04  Jim Meyering  <meyering@redhat.com>
94161         maint.mk: avoid obscure sc_copyright_check failure in coreutils
94162         * top/maint.mk (v_etc_file): Prepend $(gnulib_dir)/, to avoid
94163         false positives (whose names may be ill-chosen) when searching
94164         non-VC'd files.  Otherwise, a file named "a b/lib/version-etc.c"
94165         would cause a false-positive.
94167         avoid coreutils "make distcheck" failure
94168         Coreutils tests with an absolute build directory name that contains
94169         a space.  Not quoting this directory name caused a failure.
94170         * tests/test-vc-list-files-git.sh: Quote PATH dir name.
94171         * tests/test-vc-list-files-cvs.sh: Likewise.
94173 2010-09-04  Bruno Haible  <bruno@clisp.org>
94175         gnulib-tool: Avoid error when run in a package without Makefile.am.
94176         * gnulib-tool: When collecting the m4dirs in a package that does not
94177         have a Makefile.am, eliminate those directories that contain no
94178         gnulib-cache.m4. Fix expression that counts these directories.
94180 2010-09-04  Bruno Haible  <bruno@clisp.org>
94182         update-copyright test: Improve output when perl is missing or too old.
94183         * tests/test-update-copyright.sh: Move test of Perl version down after
94184         the test whether Perl exists. Provide an explanation relating Perl's
94185         error message to Automake's SKIP: message.
94187 2010-09-04  Bruno Haible  <bruno@clisp.org>
94189         Don't augment PATH in TESTS_ENVIRONMENT.
94190         * modules/update-copyright-tests (Makefile.am): In TESTS_ENVIRONMENT,
94191         set abs_aux_dir instead of augmenting PATH.
94192         * modules/vc-list-files-tests (Makefile.am): Likewise.
94193         * tests/test-update-copyright.sh: Augment PATH here.
94194         * tests/test-vc-list-files-cvs.sh: Augment PATH here, through
94195         path_prepend_.
94196         * tests/test-vc-list-files-git.sh: Likewise.
94198 2010-09-04  Jim Meyering  <meyering@redhat.com>
94200         tests: prohibit augmenting PATH via TESTS_ENVIRONMENT
94201         * Makefile (sc_prohibit_augmenting_PATH_via_TESTS_ENVIRONMENT): New rule.
94203 2010-09-04  Bruno Haible  <bruno@clisp.org>
94205         strdup: Fix compilation error in C++ mode.
94206         * lib/string.in.h (strdup): In C++ mode with GNULIB_NAMESPACE, undefine
94207         the macro.
94209 2010-09-04  Bruno Haible  <bruno@clisp.org>
94211         dirfd: Fix compilation error in C++ mode on MacOS X, *BSD, IRIX.
94212         * lib/dirent.in.h (dirfd): In C++ mode with GNULIB_NAMESPACE, turn the
94213         macro into a function.
94214         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
94216 2010-09-04  Bruno Haible  <bruno@clisp.org>
94218         Set PATH_SEPARATOR the same way autoconf does.
94219         * build-aux/relocatable.sh.in (func_find_curr_installdir): Determine
94220         the value of PATH_SEPARATOR the same way autoconf-generated configure
94221         scripts do.
94222         * m4/lib-ld.m4 (AC_LIB_PROG_LD): Likewise.
94223         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
94225 2010-09-04  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
94227         Set PATH_SEPARATOR the same way autoconf does.
94228         * gnulib-tool (func_gnulib_dir): Determine the value of PATH_SEPARATOR
94229         the same way autoconf-generated configure scripts do.
94230         * posix-modules: Likewise.
94232 2010-09-02  Paul Eggert  <eggert@cs.ucla.edu>
94234         hash: fix safe_hasher const typo
94235         * lib/hash.c (safe_hasher): Result is pointer, not pointer to
94236         const; otherwise, there is a type error later.
94238 2010-09-02  Jim Meyering  <meyering@redhat.com>
94240         test-update-copyright.sh: require perl 5.8.0
94241         * tests/test-update-copyright.sh: Require 5.8.0,
94242         which Tom G. Christensen has confirmed is adequate,
94243         while 5.6.1 is not.
94245 2010-09-02  Eric Blake  <eblake@redhat.com>
94247         tests: init.sh improvements for re-exec'ing with zsh
94248         * tests/init.sh: Borrow autoconf POSIX-mode sanitization.  Pass
94249         -vx through shell re-exec.
94250         Reported by Tom G. Christensen.
94252         wctype: fix typo in previous commit
94253         * m4/wctype_h.m4 (gl_WCTYPE_H): Fix spelling.
94254         Reported by Ludovic Courtès.
94256 2010-09-02  Jim Meyering  <meyering@redhat.com>
94258         test-update-copyright.sh: skip test if Perl is too old
94259         * tests/test-update-copyright.sh: Exit 77 if Perl is too old.
94260         Reported by Tom G. Christensen.
94262 2010-09-02  Bruno Haible  <bruno@clisp.org>
94264         wctype: Avoid compilation error on IRIX 6.5.30.
94265         * lib/wctype.in.h (iswblank): Declare with a replacement if
94266         REPLACE_ISWBLANK is set.
94267         * m4/wctype_h.m4 (gl_WCTYPE_H): Check also whether iswblank is
94268         declared. Set REPLACE_ISWBLANK.
94269         * modules/wctype (Makefile.am): Substitute REPLACE_ISWBLANK.
94270         * doc/posix-functions/iswblank.texi: Mention the IRIX 6.5.30 problem.
94271         * doc/posix-headers/wctype.texi: Likewise.
94272         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
94274 2010-09-01  Bruno Haible  <bruno@clisp.org>
94276         New module 'socketlib'.
94277         * modules/socketlib: New file.
94278         * m4/socketlib.m4: New file, extracted from m4/sockets.m4.
94279         * m4/sockets.m4 (gl_SOCKETS): Require gl_SOCKETLIB.
94280         * modules/sockets (Depends-on): Add socketlib.
94281         Suggested by Sam Steingold <sds@gnu.org>.
94283 2010-09-01  Paul Eggert  <eggert@cs.ucla.edu>
94285         fcntl-h, etc.: prefer O_SEARCH to O_RDONLY when applicable
94287         POSIX 2008 specifies a new 'open' flag O_SEARCH, which can be used
94288         when one needs search access to a directory but not read access.
94289         On systems where it is available, it works in some cases where
94290         O_RDONLY does not, namely on directories that are searchable but
94291         not readable, and which need only to be searchable.  If O_SEARCH
94292         is not available, fall back to the traditional method of using
94293         O_RDONLY.
94295         * lib/fcntl.in.h (O_SEARCH): #define to O_RDONLY if not defined.
94296         * lib/chdir-long.c (cdb_advance_fd): Use O_SEARCH, not O_RDONLY,
94297         when opening a directory that needs only to be searchable.
94298         * lib/chdir-safer.c (chdir_no_follow): Likewise.
94299         * lib/fts.c (diropen, fts_open, fd_ring_check): Likewise.
94300         * lib/openat-proc.c (openat_proc_name): Likewise.
94301         * lib/openat.c (openat_needs_fchdir): Likewise.
94302         * lib/save-cwd.c (save_cwd): Likewise.
94303         * lib/savewd.c (savewd_save, savewd_chdir): Likewise.
94305 2010-08-28  Bruno Haible  <bruno@clisp.org>
94307         New module 'host-cpu-c-abi'.
94308         * modules/host-cpu-c-abi: New file.
94309         * m4/host-cpu-c-abi.m4: New file, based on part of
94310         clisp/src/m4/general.m4.
94311         Requested by Sam Steingold <sds@gnu.org>.
94313 2010-08-31  Eric Blake  <eblake@redhat.com>
94314         and Jim Meyering  <meyering@redhat.com>
94316         hash: factor, and guard against misbehaving hasher function
94317         * lib/hash.c (safe_hasher): New function, to encapsulate the checking
94318         of table->hasher's return value.  Also protect against a hash value
94319         so large that adding it to table->bucket results in a NULL pointer.
94320         (hash_lookup, hash_get_next, hash_find_entry, transfer_entries):
94321         Use it in place of open-coded check-and-abort.
94323 2010-08-30  Bruno Haible  <bruno@clisp.org>
94325         hash: silence spurious clang warning
94326         * lib/hash.c (hash_get_next): Remove unnecessary test against NULL.
94327         Reported by Eric Blake.
94329 2010-08-30  Eric Blake  <eblake@redhat.com>
94331         strstr, memmem, strcasestr: avoid leaked shell message
94332         * m4/strstr.m4 (gl_FUNC_STRSTR): Avoid "Alarm clock" message from
94333         FreeBSD.
94334         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
94335         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
94337         tests: silence clang warning
94338         * tests/test-malloca.c (do_allocation): Avoid dead store.
94340 2010-08-29  Bruno Haible  <bruno@clisp.org>
94342         gettext: Fix recent mistake.
94343         * m4/intl.m4 (gt_CHECK_DECL): Fix typo introduced on 2010-08-26.
94345 2010-08-29  Bruno Haible  <bruno@clisp.org>
94347         selinux-h: Offer a --without-selinux option.
94348         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): If
94349         --without-selinux was specified, skip all tests and define
94350         HAVE_SELINUX_SELINUX_H to 0.
94351         (gl_LIBSELINUX): Offer --without-selinux option. If it is specified,
94352         set LIB_SELINUX to empty.
94353         * m4/selinux-context-h.m4 (gl_HEADERS_SELINUX_CONTEXT_H): Require
94354         gl_LIBSELINUX. If --without-selinux was specified, replace
94355         selinux/context.h.
94356         Reported by Johan Hattne <johan.hattne@utsouthwestern.edu>.
94358 2010-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
94359             Bruno Haible  <bruno@clisp.org>
94361         Make the module 'realloc-gnu' work again on AIX and OSF/1.
94362         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): Define HAVE_REALLOC_GNU instead
94363         of HAVE_REALLOC.
94364         * lib/realloc.c (NEED_REALLOC_GNU): Enable behaviour also when
94365         GNULIB_REALLOC_GNU && !HAVE_REALLOC_GNU.
94366         (SYSTEM_MALLOC_GLIBC_COMPATIBLE): Adjust definition.
94367         * modules/realloc-gnu (configure.ac): Use gl_MODULE_INDICATOR.
94369 2010-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
94370             Bruno Haible  <bruno@clisp.org>
94372         Make the module 'calloc-gnu' work again on AIX and OSF/1.
94373         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Define HAVE_CALLOC_GNU instead of
94374         HAVE_CALLOC.
94375         * lib/xmalloc.c: Update accordingly.
94376         * lib/calloc.c (NEED_CALLOC_GNU): Enable also when
94377         GNULIB_CALLOC_GNU && !HAVE_CALLOC_GNU.
94378         * modules/calloc-gnu (configure.ac): Invoke gl_MODULE_INDICATOR.
94380 2010-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
94381             Bruno Haible  <bruno@clisp.org>
94383         Make the module 'malloc-gnu' work again on AIX and OSF/1.
94384         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): Define HAVE_MALLOC_GNU instead of
94385         HAVE_MALLOC.
94386         * lib/malloc.c (NEED_MALLOC_GNU): Enable behaviour also when
94387         GNULIB_MALLOC_GNU && !HAVE_MALLOC_GNU.
94388         * modules/malloc-gnu (configure.ac): Use gl_MODULE_INDICATOR.
94390 2010-08-29  Bruno Haible  <bruno@clisp.org>
94392         Update modules list.
94393         * MODULES.html.sh (Memory management functions <stdlib.h>): Add
94394         malloc-gnu, calloc-gnu, realloc-gnu. Remove malloc, calloc, realloc.
94395         (String handling <string.h>): Add astrxfrm.
94396         (File system functions): Add readlinkat.
94398 2010-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
94400         Tests for module 'realloc-gnu'.
94401         * modules/realloc-gnu-tests: New file.
94402         * tests/test-realloc-gnu.c: New file.
94404         Tests for module 'calloc-gnu'.
94405         * modules/calloc-gnu-tests: New file.
94406         * tests/test-calloc-gnu.c: New file.
94408         Tests for module 'malloc-gnu'.
94409         * modules/malloc-gnu-tests: New file.
94410         * tests/test-malloc-gnu.c: New file.
94412 2010-08-28  Bruno Haible  <bruno@clisp.org>
94414         Rename module 'realloc' -> 'realloc-gnu'.
94415         * modules/realloc-gnu: New file, copied from modules/realloc.
94416         * modules/realloc: Convert to a redirection to 'realloc-gnu'. Mark as
94417         obsolete.
94418         * modules/mgetgroups (Depends-on): Update.
94419         * doc/posix-functions/realloc.texi: Update.
94420         * NEWS: Mention the change.
94422         Rename module 'calloc' -> 'calloc-gnu'.
94423         * modules/calloc-gnu: New file, copied from modules/calloc.
94424         * modules/calloc: Convert to a redirection to 'calloc-gnu'. Mark as
94425         obsolete.
94426         * doc/posix-functions/calloc.texi: Update.
94427         * NEWS: Mention the change.
94429         Rename module 'malloc' -> 'malloc-gnu'.
94430         * modules/malloc-gnu: New file, copied from modules/malloc.
94431         * modules/malloc: Convert to a redirection to 'malloc-gnu'. Mark as
94432         obsolete.
94433         * modules/argp (Depends-on): Update.
94434         * modules/regex (Depends-on): Update.
94435         * doc/posix-functions/malloc.texi: Update.
94436         * NEWS: Mention the change.
94438 2010-08-28  Eric Blake  <eblake@redhat.com>
94440         pread, pwrite: add missing dependency
94441         * modules/pread (Depends-on): Add extensions.
94442         * modules/pwrite (Depends-on): Likewise.
94444 2010-08-28  Bruno Haible  <bruno@clisp.org>
94446         unistr/u*-strchr: Fix tests dependencies.
94447         * modules/unistr/u8-strchr-tests (Depends-on): Add unistr/u32-to-u8.
94448         * modules/unistr/u16-strchr-tests (Depends-on): Add unistr/u32-to-u16.
94449         Reported by Ian Beckwith <ianb@erislabs.net>.
94451 2010-08-28  Bruno Haible  <bruno@clisp.org>
94453         read-file: Don't occupy too much unused memory.
94454         * lib/read-file.c (fread_file): Shrink the buffer at the end.
94456 2010-08-28  Giuseppe Scrivano  <gscrivano@gnu.org>
94457             Eric Blake  <eblake@redhat.com>
94458             Bruno Haible  <bruno@clisp.org>
94460         read-file: Avoid memory reallocations with regular files.
94461         * lib/read-file.c: Include <sys/stat.h>, <stdio.h>, <stdint.h>.
94462         (fread_file): With regular files, use the remaining length as the
94463         initial buffer size.  Check against overflow.
94464         * modules/read-file (Depends-on): Add ftello, malloc-posix, stdint,
94465         sys_stat.
94467 2010-08-28  Bruno Haible  <bruno@clisp.org>
94469         ftello: Relax license.
94470         * modules/ftello (License): Relax to LGPLv2+.
94471         Reported by Eric Blake.
94473 2010-08-28  Bruno Haible  <bruno@clisp.org>
94475         Avoid relocwrapper link errors due to gnulib replacement functions.
94476         * lib/canonicalize-lgpl.c [IN_RELOCWRAPPER]: Use the system's getcwd
94477         function.
94478         Reported by Ben Pfaff <blp@cs.stanford.edu>.
94480 2010-08-28  Bruno Haible  <bruno@clisp.org>
94482         Prefer using AC_DEFUN_ONCE over AC_DEFUN in projects with gnulib.
94483         * m4/iconv.m4 (gl_iconv_AC_DEFUN): Use AC_DEFUN_ONCE if gl_00GNULIB is
94484         defined.
94485         * m4/libunistring.m4 (gl_libunistring_AC_DEFUN): Likewise.
94486         Suggested by Eric Blake.
94488 2010-08-28  Bruno Haible  <bruno@clisp.org>
94490         sys_socket, netdb: Ensure socklen_t gets defined.
94491         * modules/sys_socket (Depends-on): Add socklen.
94492         * modules/netdb (Depends-on): Likewise.
94493         * modules/getaddrinfo (Depends-on): Remove socklen.
94494         * modules/getsockopt (Depends-on): Likewise.
94495         * modules/setsockopt (Depends-on): Likewise.
94496         * tests/test-sys_socket.c: Check that socklen_t is defined.
94497         * tests/test-netdb.c: Likewise.
94498         * m4/socklen.m4: Update comments.
94499         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
94501 2010-08-27  Eric Blake  <eblake@redhat.com>
94503         login_tty: add missing dependency
94504         * modules/login_tty (Depends-on): Add pty.
94506 2010-08-26  Eric Blake  <eblake@redhat.com>
94508         lib-symbol-versions: fix m4 quoting
94509         * m4/ld-version-script.m4 (gl_LD_VERSION_SCRIPT): Use correct
94510         format for AC_LINK_IFELSE.
94512         glob: fix compile test
94513         * m4/glob.m4 (gl_GLOB): Use correct format for AC_COMPILE_IFELSE.
94515         btowc: fix missing file
94516         * modules/btowc (Files): Also ship locale-fr.m4.
94518         lseek: fix link test
94519         * m4/lseek.m4 (gl_FUNC_LSEEK): Use correct format for
94520         AC_LINK_IFELSE.
94522         include_next: silence autoconf 2.68 warning
94523         * m4/include_next.m4 (gl_INCLUDE_NEXT): Mark this use of
94524         AC_COMPILE_IFELSE as special.
94525         (AC_LANG_DEFINES_PROVIDED): Provide dummy implementation for
94526         autoconf < 2.68.
94528         acl: fix compilation test
94529         * m4/acl.m4 (gl_FUNC_ALL): Use correct format for
94530         AC_COMPILE_IFELSE.
94532 2010-08-26  Bruno Haible  <bruno@clisp.org>
94534         Modernize AC_TRY_RUN invocations.
94535         * m4/btowc.m4 (gl_FUNC_BTOWC): Use AC_RUN_IFELSE instead of AC_TRY_RUN.
94536         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Likewise.
94537         * m4/exponentd.m4 (gl_DOUBLE_EXPONENT_LOCATION): Likewise.
94538         * m4/exponentf.m4 (gl_FLOAT_EXPONENT_LOCATION): Likewise.
94539         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Likewise.
94540         * m4/fopen.m4 (gl_FUNC_FOPEN): Likewise.
94541         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Likewise.
94542         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
94543         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
94544         * m4/iconv.m4 (AM_ICONV_LINK): Likewise.
94545         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN_UTF): Likewise.
94546         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
94547         * m4/isnanf.m4 (gl_ISNANF_WORKS): Likewise.
94548         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
94549         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Likewise.
94550         * m4/mbrlen.m4 (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL,
94551         gl_MBRLEN_NUL_RETVAL): Likewise.
94552         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
94553         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL):
94554         Likewise.
94555         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
94556         * m4/open.m4 (gl_FUNC_OPEN): Likewise.
94557         * m4/printf.m4 (gl_PRINTF_SIZES_C99, gl_PRINTF_LONG_DOUBLE,
94558         gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE,
94559         gl_PRINTF_DIRECTIVE_A, gl_PRINTF_DIRECTIVE_F, gl_PRINTF_DIRECTIVE_N,
94560         gl_PRINTF_DIRECTIVE_LS, gl_PRINTF_POSITIONS, gl_PRINTF_FLAG_GROUPING,
94561         gl_PRINTF_FLAG_LEFTADJUST, gl_PRINTF_FLAG_ZERO, gl_PRINTF_PRECISION,
94562         gl_SNPRINTF_TRUNCATION_C99, gl_SNPRINTF_RETVAL_C99,
94563         gl_SNPRINTF_DIRECTIVE_N, gl_SNPRINTF_SIZE1, gl_VSNPRINTF_ZEROSIZE_C99):
94564         Likewise.
94565         * m4/printf-posix.m4 (gt_PRINTF_POSIX): Likewise.
94566         * m4/signbit.m4 (gl_SIGNBIT, gl_FLOATTYPE_SIGN_LOCATION): Likewise.
94567         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
94568         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
94569         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
94570         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Likewise.
94571         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise.
94572         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION): Likewise.
94573         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
94574         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
94576 2010-08-26  Bruno Haible  <bruno@clisp.org>
94578         Modernize AC_TRY_LINK invocations.
94579         * m4/acosl.m4 (gl_FUNC_ACOSL): Use AC_LINK_IFELSE instead of
94580         AC_TRY_LINK.
94581         * m4/argp.m4 (gl_ARGP): Likewise.
94582         * m4/asinl.m4 (gl_FUNC_ASINL): Likewise.
94583         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
94584         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Likewise.
94585         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
94586         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
94587         * m4/codeset.m4 (AM_LANGINFO_CODESET): Likewise.
94588         * m4/cosl.m4 (gl_FUNC_COSL): Likewise.
94589         * m4/expl.m4 (gl_FUNC_EXPL): Likewise.
94590         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
94591         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Likewise.
94592         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
94593         * m4/frexp.m4 (gl_FUNC_FREXP, gl_CHECK_FREXP_NO_LIBM): Likewise.
94594         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_CHECK_FREXPL_NO_LIBM): Likewise.
94595         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
94596         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
94597         * m4/hostent.m4 (gl_HOSTENT): Likewise.
94598         * m4/iconv.m4 (AM_ICONV_LINK): Likewise.
94599         * m4/intl.m4 (gt_INTL_SUBDIR_CORE): Likewise.
94600         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Likewise.
94601         * m4/isnand.m4 (gl_HAVE_ISNAND_IN_LIBM, gl_HAVE_ISNAND_NO_LIBM):
94602         Likewise.
94603         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_HAVE_ISNANF_IN_LIBM):
94604         Likewise.
94605         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM):
94606         Likewise.
94607         * m4/lcmessage.m4 (gt_LC_MESSAGES): Likewise.
94608         * m4/ldexpl.m4 (gl_FUNC_LDEXPL, gl_CHECK_LDEXPL_NO_LIBM): Likewise.
94609         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Likewise.
94610         * m4/logb.m4 (gl_FUNC_LOGB): Likewise.
94611         * m4/logl.m4 (gl_FUNC_LOGL): Likewise.
94612         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Likewise.
94613         * m4/servent.m4 (gl_SERVENT): Likewise.
94614         * m4/signbit.m4 (gl_SIGNBIT): Likewise.
94615         * m4/sinl.m4 (gl_FUNC_SINL): Likewise.
94616         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Likewise.
94617         * m4/tanl.m4 (gl_FUNC_TANL): Likewise.
94618         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
94619         * m4/trunc.m4 (gl_FUNC_TRUNC): Likewise.
94620         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
94621         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
94622         * modules/tsearch-tests (configure.ac): Likewise.
94624 2010-08-26  Bruno Haible  <bruno@clisp.org>
94626         Modernize AC_TRY_COMPILE invocations.
94627         * m4/environ.m4 (gt_CHECK_VAR_DECL): Use AC_COMPILE_IFELSE instead of
94628         AC_TRY_COMPILE.
94629         * m4/iconv.m4 (gl_iconv_AC_DEFUN): Likewise.
94630         * m4/intl.m4 (gt_CHECK_DECL): Likewise.
94631         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Likewise.
94632         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
94633         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Likewise.
94634         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
94635         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
94636         * m4/lock.m4 (gl_LOCK): Likewise.
94637         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): Likewise.
94638         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
94639         * m4/minmax.m4 (gl_MINMAX_IN_HEADER): Likewise.
94640         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
94641         * m4/size_max.m4 (gl_SIZE_MAX): Likewise.
94642         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Likewise.
94643         * m4/stdarg.m4 (gl_STDARG_H): Likewise.
94644         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Likewise.
94645         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Likewise.
94646         * m4/visibility.m4 (gl_VISIBILITY): Likewise.
94647         * m4/wchar_t.m4 (gt_TYPE_WCHAR_T): Likewise.
94648         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
94649         * m4/libunistring.m4 (gl_LIBUNISTRING_CORE): Likewise. Remove
94650         extraneous semicolon.
94652 2010-08-26  Jim Meyering  <meyering@redhat.com>
94654         stat-time: relax license LGPL
94655         * modules/stat-time (License): Change from GPL to LGPL,
94656         with consent from all contributors, for use in libguile.
94657         Requested by Ludovic Courtès.
94659 2010-08-26  Erik Faye-Lund  <kusmabite@gmail.com>
94661         poll: return immediately on POLLHUP.
94662         * lib/poll.c (poll): Always set timeout before wait_timeout is
94663         computed.
94665 2010-08-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
94667         Fix test-unlinkat, test-rmdir failure on AIX 5.3.
94668         * tests/test-rmdir.h (test_rmdir_func): Also accept EEXIST for
94669         rmdir ("dir/.//"), unlinkat.
94671 2010-08-24  Paul Eggert  <eggert@cs.ucla.edu>
94673         stdbool: avoid spurious failure with modern xlc
94674         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Resync with autoconf.
94676 2010-08-24  Bruno Haible  <bruno@clisp.org>
94678         getloadavg: simplify code
94679         * m4/getloadavg.m4 (gl_GETLOADAVG): Remove useless test of
94680         gl_have_func. Update comments.
94682 2010-08-24  Eric Blake  <eblake@redhat.com>
94684         getloadavg: don't define SVR4 on cygwin
94685         * m4/getloadavg.m4 (gl_GETLOADAVG): Sync with autoconf fix, to
94686         only define SVR4 when -lkvm is required.
94687         Reported by Yaakov Selkowitz.
94689 2010-08-24  Bruno Haible  <bruno@clisp.org>
94691         priv-set: fix comment
94692         * lib/priv-set.c (priv_set_restore): Fix typo in comment.
94694 2010-08-23  Paul Eggert  <eggert@cs.ucla.edu>
94696         priv-set: fix comments
94697         * lib/priv-set.c (priv_set_remove, priv_set_restore): Fix comments
94698         to match code, as suggested by David Bartley in:
94699         http://lists.gnu.org/r/bug-tar/2010-08/msg00018.html
94701 2010-08-23  Eric Blake  <eblake@redhat.com>
94703         stdbool: avoid rejecting clang
94704         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Resync with autoconf.
94705         * tests/test-stdbool.c: Enable more tests if using the system
94706         <stdbool.h> instead of the gnulib replacement.
94707         (main): Move xlc bug test to a runtime test for all compilers.
94708         Reported by Anders Kaseorg.
94710         argz: fix shell quoting issue
94711         * m4/argz.m4 (gl_FUNC_ARGZ): Allow for spaces in argument.
94712         Reported by Charles Wilson.
94714 2010-08-22  Paolo Bonzini  <bonzini@gnu.org>
94715             Erik Faye-Lund <kusmabite@gmail.com>
94717         poll, select: handle ERROR_BROKEN_PIPE.
94718         * lib/poll.c (win32_compute_revents): Return POLLHUP when
94719         PeekNamedPipe fails with ERROR_BROKEN_PIPE.
94720         * lib/select.c (win32_compute_revents): Do not mark a pipe
94721         as writeable if PeekNamedPipe fails with ERROR_BROKEN_PIPE.
94723 2010-08-22  Giuseppe Scrivano  <gscrivano@gnu.org>
94725         fts: allow compilation with C++
94726         * lib/fts_.h: Specify extern "C" linkage with C++.
94728 2010-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
94730         Fix gnulib-tool sed script de-commentation for AIX sed.
94731         * gnulib-tool (sed_comments): Try indented comments, for AIX 5.3
94732         sed.
94734 2010-08-17  Eric Blake  <eblake@redhat.com>
94736         test-stddef: test for (some) offsetof bugs
94737         * tests/test-stddef.c: Enhance test to ensure correct type of
94738         offsetof.
94739         * doc/posix-headers/stddef.texi (stddef.h): Document a Solaris bug
94740         that we are not fixing at this time.
94742 2010-08-15  Bruno Haible  <bruno@clisp.org>
94744         stpncpy: Allow stpncpy to be defined as a macro.
94745         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Don't attempt to redeclare stpncpy
94746         if it's already correctly declared.
94747         * lib/string.in.h (stpncpy): Undefine before redefining.
94748         Reported by Jeremy Huddleston <jeremyhu@macports.org>.
94750 2010-08-14  Bruno Haible  <bruno@clisp.org>
94752         Rename module 'memxfrm' to 'amemxfrm'.
94753         * lib/amemxfrm.h: Renamed from lib/memxfrm.h.
94754         (amemxfrm): Renamed from memxfrm.
94755         * lib/amemxfrm.c: Renamed from lib/memxfrm.h. Include amemxfrm.h.
94756         (amemxfrm): Renamed from memxfrm.
94757         * modules/amemxfrm: Renamed from modules/memxfrm. Update.
94758         * NEWS: Mention the change.
94759         * MODULES.html.sh (String handling <string.h>): Update.
94760         * lib/unicase/u-casexfrm.h: Invoke amemxfrm instead of memxfrm.
94761         * lib/unicase/u8-casexfrm.c: Include amemxfrm.h instead of memxfrm.h.
94762         * lib/unicase/u16-casexfrm.c: Likewise.
94763         * lib/unicase/u32-casexfrm.c: Likewise.
94764         * lib/uninorm/u-normxfrm.h: Invoke amemxfrm instead of memxfrm.
94765         * lib/uninorm/u8-normxfrm.c: Include amemxfrm.h instead of memxfrm.h.
94766         * lib/uninorm/u16-normxfrm.c: Likewise.
94767         * lib/uninorm/u32-normxfrm.c: Likewise.
94768         * modules/unicase/u8-casexfrm (Depends-on): Add amemxfrm, remove
94769         memxfrm.
94770         * modules/unicase/u16-casexfrm (Depends-on): Likewise.
94771         * modules/unicase/u32-casexfrm (Depends-on): Likewise.
94772         * modules/uninorm/u8-normxfrm (Depends-on): Likewise.
94773         * modules/uninorm/u16-normxfrm (Depends-on): Likewise.
94774         * modules/uninorm/u32-normxfrm (Depends-on): Likewise.
94775         Suggested by Paul Eggert.
94777 2010-08-14  Bruno Haible  <bruno@clisp.org>
94779         Tests for module 'astrxfrm'.
94780         * modules/astrxfrm-tests: New file.
94781         * tests/test-astrxfrm.c: New file.
94783         New module 'astrxfrm'.
94784         * lib/astrxfrm.h: New file.
94785         * lib/astrxfrm.c: New file, based on lib/memxfrm.c.
94786         * modules/astrxfrm: New file.
94788 2010-08-14  Reuben Thomas  <rrt@sc3d.org>
94790         regex: Tweak doc.
94791         * doc/regex.texi (Overview): Don't mention regex.c.
94792         (GNU Regular Expression Compiling): Likewise.
94793         (Match-end-of-line Operator): Mention 'not_eol'.
94795 2010-08-14  Brian Gough  <bjg@gnu.org>
94796             Bruno Haible  <bruno@clisp.org>
94798         git-merge-changelog: add doc relating to use with bzr and hg.
94799         * lib/git-merge-changelog.c: Add comments regarding bzr, hg, diff3.
94801 2010-08-14  Matthias Bolte  <matthias.bolte@googlemail.com>
94803         pthread: fix pthread.h creation for srcdir != builddir
94804         * modules/pthread (Makefile.am): Fix the rule to work also in a
94805         non-srcdir build.
94807 2010-08-13  Karl Berry  <karl@gnu.org>
94809         * doc/regex.texi (Predefined Syntaxes): @smallexample.
94810         * doc/posix-*/*: force line break before @url of POSIX
94811         specifications.
94812         Suggested by Werner Lemberg.
94814 2010-08-10  Paul Eggert  <eggert@cs.ucla.edu>
94816         strtod: fix const diagnostic
94817         * lib/strtod.c (strtod): Don't assign const char * to char *,
94818         as this elicits a warning from GCC when warnings are enabled.
94820 2010-08-10  Pádraig Brady  <P@draigbrady.com>
94821         and Eric Blake  <eblake@redhat.com>
94823         copy-acl: ignore ENOTSUP on HP-UX
94824         * lib/acl-internal.h (ACL_NOT_WELL_SUPPORTED): Move definition up,
94825         so that it is available for HP-UX.
94826         * lib/copy-acl.c (qcopy_acl): Use it.
94827         Reported by Patrick M. Callahan.
94829 2010-08-10  Eric Blake  <eblake@redhat.com>
94831         open, chown: relax license
94832         * modules/open (License): Change to LGPLv2+, with consent by all
94833         authors, for use in augeas.
94834         * modules/chown (License): Likewise.
94835         * modules/lchown (Likewise): Likewise.
94836         Requested by Adam Stokes.
94838 2010-08-09  Karl Berry  <karl@gnu.org>
94840         * build-aux/ar-lib: new file, import from Automake.
94841         * config/srclist.txt: autocheck for updates.
94843 2010-08-09  Eric Blake  <eblake@redhat.com>
94845         readlinkat: adjust client modules
94846         * modules/areadlinkat (Depends-on): Use readlinkat, not
94847         symlinkat.
94848         * modules/areadlinkat-with-size (Depends-on): Likewise.
94850         mknod: be more vocal about danger of running tests as root
94851         * m4/mknod.m4 (gl_FUNC_MKNOD): Make it harder to run configure as
94852         root, since that is just asking for problems.
94853         Suggested by Bruno Haible, based on a report by Rainer Tammer.
94855         readlinkat: split into its own module
94856         * modules/symlinkat: Split readlinkat...
94857         * modules/readlinkat: ...into separate module.
94858         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Move readlinkat check...
94859         * m4/readlinkat.m4 (gl_FUNC_READLINAT): ...to new file.
94860         * lib/symlinkat.c (readlinkat): Move...
94861         * lib/readlinkat.c: ...into new file.
94862         * modules/symlinkat-tests: Split readlinkat test...
94863         * modules/readlinkat-tests: ...into separate module.
94864         * tests/test-symlinkat.c: Split...
94865         * tests/test-readlinkat.c: ...into new file.
94866         * NEWS: Document the split.
94867         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
94868         * lib/unistd.in.h (readlinkat): Likewise.
94869         Suggested by Bruno Haible.
94871 2010-08-08  Bruno Haible  <bruno@clisp.org>
94873         memxfrm: Speed up.
94874         * lib/memxfrm.c (memxfrm): Allocate enough memory ahead of time, so
94875         that usually only one call to strxfrm is necessary for each string
94876         part.
94877         Reported by Paul Eggert <eggert@cs.ucla.edu>.
94879 2010-08-07  Karl Berry  <karl@gnu.org>
94881         * doc/posix-headers/limits.texi,
94882         * doc/posix-functions/malloc.texi,
94883         * doc/posix-functions/strsignal.texi: missing @item.
94884         * doc/ld-version-script.texi: spurious leading i.
94885         * doc/regex.texi (Interval Operators): no commas inside @var.
94887 2010-08-01  Bruno Haible  <bruno@clisp.org>
94889         Integrate the regex documentation.
94890         * doc/gnulib.texi: Define 'cn' index.
94891         (Regular expressions): New a chapter that includes regex.texi and
94892         regexprops-generic.texi.
94893         * doc/regex.texi: Remove boilerplate stuff. Use simplified @node
94894         syntax.
94896         Whitespace cleanup.
94897         * doc/regex.texi: Remove trailing spaces.
94899         Add regex documentation.
94900         * doc/regex.texi: New file. Taken from regex-0.12/doc/regex.texi in
94901         http://ftp.gnu.org/old-gnu/regex/regex-0.12.tar.gz.
94902         Written by Kathy A. Hargreaves and Karl Berry.
94904 2010-08-01  Bruno Haible  <bruno@clisp.org>
94906         link: Update documentation.
94907         * doc/posix-functions/link.texi: Update regarding Solaris.
94909 2010-07-31  Bruno Haible  <bruno@clisp.org>
94911         Update modules list.
94912         * MODULES.html.sh (Sorting functions <stdlib.h>): Add array-mergesort.
94913         (String handling <string.h>): Add memcmp2, memxfrm.
94914         (Container data structures): Add xlist, xsublist, xoset.
94915         (Core language properties): Add alignof, unused-parameter.
94916         (Process control, Numeric conversion functions <stdlib.h>): Renamed
94917         from Numeric conversion functions <stdlib.h>. Add _Exit, atoll.
94918         (Unibyte characters <ctype.h>): New section.
94919         (String handling <string.h>): New section.
94920         (Mathematics <math.h>): Add acos, acosl, asin, asinl, atan, atan2,
94921         atanl, cbrt, copysign, cos, cosh, cosl, erf, erfc, exp, expl, fabs,
94922         fmod, hypot, j0, j1, jn, ldexp, lgamma, log, log10, log1p, logb, logl,
94923         modf, nextafter, pow, remainder, rint, sin, sinh, sinl, sqrt, sqrtl,
94924         tan, tanh, tanl, y0, y1, yn.
94925         (Support for systems lacking POSIX:2008): Add alphasort, dirent,
94926         dprintf, dprintf-posix, duplocale, fcntl, getlogin, getopt-posix,
94927         grantpt, iconv-h, ioctl, isblank, langinfo, nl_langinfo, pread,
94928         ptsname, pwrite, scandir, servent, sys_utsname, ttyname_r, uname,
94929         unlockpt, vdprintf, vdprintf-posix.
94930         (Enhancements for POSIX:2008 functions): Add getopt-gnu. Remove getopt.
94931         (File system functions): Add concat-filename, sys_file, sys_ioctl,
94932         xconcat-filename.
94933         (File descriptor based Input/Output): Add dup3, fd-safer-flag,
94934         getdtablesize, pipe2, pipe2-safer.
94935         (Security): New section.
94936         (Networking functions): Add accept4.
94937         (Signal handling): Add sigpipe.
94938         (Internationalization functions): Add xstriconveh, mbmemcasecmp,
94939         mbmemcasecoll.
94940         (Unicode string functions): Add libunistring-optional, unistr/u*-cmp2,
94941         unistr/u*-strcoll, uniwbrk/*, uninorm/*, unicase/*.
94942         (Executing programs): Add findprog-lgpl, pipe-filter-gi,
94943         pipe-filter-ii.
94944         (Misc): Add argp-version-etc, login_tty, parse-duration.
94946 2010-07-31  Bruno Haible  <bruno@clisp.org>
94948         Improve doc in MODULES.html.
94949         * modules/linkat (Description): Add the word "function".
94950         * modules/mkfifo (Description): Likewise.
94951         * modules/mknod (Description): Likewise.
94952         * modules/remove (Description): Likewise.
94953         * modules/renameat (Description): Likewise.
94954         * modules/stat (Description): Likewise.
94955         * modules/symlink (Description): Likewise.
94956         * modules/unlink (Description): Likewise.
94958 2010-07-31  Bruno Haible  <bruno@clisp.org>
94960         ansi-c++-opt: Provide option --enable-c++/--disable-c++ when possible.
94961         * m4/ansi-c++.m4 (gl_CXX_CHOICE): In Autoconf 2.66 or newer, provide
94962         option --enable/disable-c++ instead of --enable/disable-cxx.
94963         * NEWS: Mention the change.
94965 2010-07-31  Bruno Haible  <bruno@clisp.org>
94967         readlink, areadlink: Relax test a bit.
94968         * tests/test-readlink.h (test_readlink): Accept EINVAL as an
94969         alternative to ENOTDIR.
94970         * tests/test-areadlink.h (test_areadlink): Likewise.
94971         Reported by Rainer Tammer.
94973 2010-07-31  Bruno Haible  <bruno@clisp.org>
94975         unistr/u8-strstr, unistr/u16-strstr: Optimize the one-character case.
94976         * lib/unistr/u-strstr.h (FUNC): When the needle contains only one
94977         character, perform the search using U_STRCHR.
94978         * lib/unistr/u8-strstr.c (U_STRMBTOUC): New macro.
94979         * lib/unistr/u16-strstr.c (U_STRMBTOUC): Likewise.
94980         * modules/unistr/u8-strstr (Depends-on): Add unistr/u8-strmbtouc.
94981         * modules/unistr/u16-strstr (Depends-on): Add unistr/u16-strmbtouc.
94982         Suggested by Paolo Bonzini.
94984 2010-07-31  Bruno Haible  <bruno@clisp.org>
94986         unistr/u*-strstr: Fix dependencies.
94987         * modules/unistr/u8-strstr (Depends-on): Add unistr/u8-strchr.
94988         * modules/unistr/u16-strstr (Depends-on): Add unistr/u16-strchr.
94989         * modules/unistr/u32-strstr (Depends-on): Add unistr/u32-strchr.
94991 2010-07-31  Bruno Haible  <bruno@clisp.org>
94993         unistr/u8-chr, unistr/u8-strchr: Optimize and add comments.
94994         * lib/unistr/u8-chr.c (u8_chr): Add comments. Remove a useless test at
94995         the beginning of the loop.
94996         * lib/unistr/u8-strchr.c (u8_strchr): Add comments. Don't fall through
94997         cases in 'switch' statement.
94999         unistr/u8-strchr: Fix several bugs.
95000         * lib/unistr/u8-strchr.c (u8_strchr): Don't search beyond the end of
95001         the string. When not found, return NULL, not a pointer near the end.
95003         More tests for unistr/u8-strchr.
95004         * tests/unistr/test-strchr.h (test_strchr): Renamed from main. Check
95005         that the function does not read past the first occurrence of the byte
95006         being searched.
95007         * tests/unistr/test-u8-strchr.c (main): New function, with more tests.
95008         * tests/unistr/test-u16-strchr.c (main): New function.
95009         * tests/unistr/test-u32-strchr.c (main): New function.
95011 2010-07-31  Bruno Haible  <bruno@clisp.org>
95013         posix-modules: Ignore backup files of documentation files.
95014         * posix-modules: grep only through files named *.texi.
95016 2010-07-31  Bruno Haible  <bruno@clisp.org>
95018         symlinkat: Fix documentation.
95019         * doc/posix-functions/readlinkat.texi: Fix module name.
95021 2010-07-31  Bruno Haible  <bruno@clisp.org>
95023         fchownat: Replace also when chown has the trailing slash bug.
95024         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Move the test of REPLACE_CHOWN
95025         outside the gl_FUNC_FCHOWNAT_DEREF_BUG invocation. Fixes regression
95026         introduced on 2010-04-10.
95027         Reported by Rainer Tammer.
95029 2010-07-31  Bruno Haible  <bruno@clisp.org>
95031         linkat: Work around AIX 7.1 bug.
95032         * m4/linkat.m4 (gl_FUNC_LINKAT): Require AC_CANONICAL_HOST. Test
95033         whether linkat handles trailing slash correctly. If not, replace linkat
95034         and define LINKAT_TRAILING_SLASH_BUG.
95035         * lib/linkat.c (rpl_linkat): If LINKAT_TRAILING_SLASH_BUG is defined,
95036         check whether (fd1,file1) points to a directory if file1 or file2 ends
95037         in a slash. Code taken from lib/link.c.
95038         * doc/posix-functions/linkat.texi: Mention trailing slash bug.
95039         Reported by Rainer Tammer.
95041 2010-07-31  Bruno Haible  <bruno@clisp.org>
95043         Correctly determine whether pow is available in libc on AIX 7 with xlc.
95044         * m4/mathfunc.m4 (gl_MATHFUNC): Actually use the 'funcptr' variable.
95045         This disables an xlc optimization that was causing wrong test results.
95046         Reported by Rainer Tammer.
95048 2010-07-31  Bruno Haible  <bruno@clisp.org>
95050         iconv: Work around AIX 6.1..7.1 bug.
95051         * doc/posix-functions/iconv.texi: Mention AIX 6.1, 7.1 bug.
95052         * m4/iconv.m4 (AM_ICONV_LINK): Test against AIX 6.1, 7.1 bug. When
95053         cross-compiling, guess no on all versions of AIX.
95054         Reported by Rainer Tammer.
95056 2010-07-31  Bruno Haible  <bruno@clisp.org>
95058         readlink: Relax test a bit.
95059         * tests/test-readlink.h (test_readlink): Allow different errno value
95060         when readlink is called with a file name that ends in / and refers to
95061         a file.
95062         Suggested by Eric Blake.
95063         Reported by Rainer Tammer.
95065 2010-07-31  Bruno Haible  <bruno@clisp.org>
95067         copysign: Does not require -lm on glibc systems.
95068         * modules/copysign (configure.ac): Use gl_MATHFUNC, not
95069         gl_COMMON_DOUBLE_MATHFUNC.
95070         * m4/mathfunc.m4 (gl_COMMON_DOUBLE_MATHFUNC): Update comments.
95072 2010-07-31  Bruno Haible  <bruno@clisp.org>
95074         duplocale: Work around AIX 7.1 bug.
95075         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Let the test fail also when
95076         duplocale(LC_GLOBAL_LOCALE) returns (locale_t)0.
95077         * lib/duplocale.c (rpl_duplocale): Update comment.
95078         * doc/posix-functions/duplocale.texi: Mention the AIX 7.1 bug.
95079         Reported by Rainer Tammer.
95081 2010-07-30  Bruno Haible  <bruno@clisp.org>
95083         dirfd: Avoid link error on AIX 7.1.
95084         * lib/dirent.in.h (dirfd): Use modern idiom with REPLACE_DIRFD.
95085         * m4/dirfd.m4 (gl_FUNC_DIRFD): If the function is declared but does not
95086         exist, set REPLACE_DIRFD.
95087         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize REPLACE_DIRFD.
95088         * modules/dirent (Makefile.am): Substitute REPLACE_DIRFD.
95089         * doc/posix-functions/dirfd.texi: Update.
95090         Reported by Rainer Tammer.
95092 2010-07-30  Eric Blake  <eblake@redhat.com>
95094         strtod: next round of AIX fixes
95095         * lib/strtod.c (strtod): Work around AIX bug of parsing p with no
95096         exponent.
95097         * tests/test-strtod.c (main): Enhance tests.
95098         * doc/posix-functions/strtod.texi (strtod): Document next bug.
95099         Reported by Rainer Tammer.
95101         futimens: fix configure check
95102         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Use correct logic.
95103         Reported by Bruno Haible.
95105 2010-07-30  Bruno Haible  <bruno@clisp.org>
95107         getline: Update regarding AIX.
95108         * doc/posix-functions/getline.texi: Mention bug on AIX 7.1.
95109         Reported by Rainer Tammer.
95111 2010-07-30  Bruno Haible  <bruno@clisp.org>
95113         wcwidth: Drop replacement on AIX 7.
95114         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): When cross-compiling, guess yes on
95115         AIX 7.
95116         Reported by Rainer Tammer.
95118 2010-07-30  Bruno Haible  <bruno@clisp.org>
95120         strtok_r: Avoid triggering bug in AIX 7.1 xlc compiler.
95121         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Don't cast an invalid address to
95122         a 'char *'.
95123         Reported by Rainer Tammer.
95125 2010-07-30  Bruno Haible  <bruno@clisp.org>
95127         unlink: Update regarding AIX.
95128         * doc/posix-functions/unlink.texi: Mention bug on AIX 7.1.
95129         * m4/unlink.m4 (gl_FUNC_UNLINK): Update comment.
95130         Reported by Rainer Tammer.
95132 2010-07-30  Bruno Haible  <bruno@clisp.org>
95134         symlink: Update regarding AIX.
95135         * doc/posix-functions/symlink.texi: Mention bug on AIX 7.1.
95136         * m4/symlink.m4 (gl_FUNC_SYMLINK): Update comment.
95137         Reported by Rainer Tammer.
95139 2010-07-30  Bruno Haible  <bruno@clisp.org>
95141         strndup: Update regarding AIX.
95142         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, guess yes on
95143         AIX 7.
95144         Reported by Rainer Tammer.
95146 2010-07-30  Bruno Haible  <bruno@clisp.org>
95148         stat: Update regarding AIX.
95149         * doc/posix-functions/stat.texi: Mention bug on AIX 7.1.
95150         * m4/stat.m4 (gl_FUNC_STAT): Update comment.
95151         Reported by Rainer Tammer.
95153 2010-07-30  Bruno Haible  <bruno@clisp.org>
95155         truncl: Fix autoconf test.
95156         * m4/truncl.m4 (gl_FUNC_TRUNCL): Add TRUNCL_LIBM to LIBS while testing
95157         whether truncl works.
95158         Reported by Rainer Tammer.
95160 2010-07-30  Bruno Haible  <bruno@clisp.org>
95162         round: Update regarding AIX.
95163         * m4/round.m4 (gl_FUNC_ROUND): When cross-compiling, guess no on AIX 7.
95164         * doc/posix-functions/round.texi: Mention bug on AIX 7.1.
95165         Reported by Rainer Tammer.
95167 2010-07-30  Bruno Haible  <bruno@clisp.org>
95169         rename: Update regarding AIX.
95170         * doc/posix-functions/rename.texi: Mention bug on AIX 7.1.
95171         * m4/rename.m4 (gl_FUNC_RENAME): Update comment.
95172         Reported by Rainer Tammer.
95174 2010-07-30  Bruno Haible  <bruno@clisp.org>
95176         printf.m4: Update regarding AIX.
95177         * m4/printf.m4: Update comments regarding AIX.
95178         Reported by Rainer Tammer.
95180 2010-07-30  Bruno Haible  <bruno@clisp.org>
95182         iconv: Update regarding AIX.
95183         * m4/iconv.m4 (AM_ICONV_LINK): When cross-compiling, guess yes on
95184         AIX 7.
95185         Reported by Rainer Tammer.
95187 2010-07-30  Bruno Haible  <bruno@clisp.org>
95189         getopt: Update regarding AIX.
95190         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): When cross-compiling, guess
95191         no on AIX.
95192         * doc/posix-functions/getopt.texi: Mention that AIX has the optind bug.
95193         Reported by Rainer Tammer.
95195 2010-07-30  Bruno Haible  <bruno@clisp.org>
95197         ldexpl; Update regarding AIX.
95198         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): When cross-compiling, guess yes
95199         on AIX 7.
95200         Reported by Rainer Tammer.
95202 2010-07-30  Bruno Haible  <bruno@clisp.org>
95204         frexpl: Update regarding AIX.
95205         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): When cross-compiling, guess yes
95206         on AIX 7.
95207         Reported by Rainer Tammer.
95209 2010-07-30  Bruno Haible  <bruno@clisp.org>
95211         open, fopen: Update regarding AIX.
95212         * m4/open.m4 (gl_FUNC_OPEN): Adjust cross-compiling guess for AIX.
95213         * m4/fopen.m4 (gl_FUNC_FOPEN): Likewise.
95214         * doc/posix-functions/open.texi: Mention the trailing-slash bug on AIX.
95215         * doc/posix-functions/fopen.texi: Likewise.
95216         Reported by Rainer Tammer.
95218 2010-07-30  Bruno Haible  <bruno@clisp.org>
95220         chown: Update doc regarding AIX.
95221         * doc/posix-functions/chown.texi: Mention bug on AIX 7.1.
95222         * m4/chown.m4 (gl_FUNC_CHOWN): Update comment.
95223         Reported by Rainer Tammer.
95225 2010-07-30  Eric Blake  <eblake@redhat.com>
95227         strtod: fix bug in replacement function on AIX
95228         * lib/strtod.c (strtod): Special case broken "0x" parse in
95229         underlying strtod.
95230         * tests/test-strtod.c (main): Document AIX 7.1 bugs.
95231         * doc/posix-functions/strtod.texi (strtod): Likewise.
95232         Reported by Rainer Tammer.
95234 2010-07-30  Bruno Haible  <bruno@clisp.org>
95236         mbrlen: Fix cross-compilation guess for AIX.
95237         * m4/mbrlen.m4 (gl_MBRLEN_INCOMPLETE_STATE): Fix cross-compilation
95238         guess. Leftover from 2008-12-22.
95240 2010-07-30  Bruno Haible  <bruno@clisp.org>
95242         mbrtowc: Fix cross-compilation guess for AIX.
95243         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Fix cross-compilation
95244         guess. Leftover from 2008-12-21.
95246 2010-07-29  Peter O'Gorman  <pogma@thewrittenword.com>  (tiny change)
95248         init.sh: work around trap limitation of some shells
95249         * tests/init.sh (setup_): Move exit trap outside of shell function.
95251 2010-07-29  Eric Blake  <eblake@redhat.com>
95253         strtod: aid debugging
95254         * m4/strtod.m4(gl_FUNC_STRTOD): Use distinct exit status to aid
95255         understanding why strtod is rejected.
95257 2010-07-28  Bruno Haible  <bruno@clisp.org>
95259         unistr/u*-chr, unistr/u*-strchr: Fix link errors and warnings.
95260         * lib/unistr/u8-chr.c: Include <string.h>.
95261         * tests/unistr/test-u8-chr.c: Likewise.
95262         * tests/unistr/test-u16-chr.c: Likewise.
95263         * tests/unistr/test-u32-chr.c: Likewise.
95264         * tests/unistr/test-u8-strchr.c: Likewise.
95265         * tests/unistr/test-u16-strchr.c: Likewise.
95266         * tests/unistr/test-u32-strchr.c: Likewise.
95267         * modules/unistr/u8-chr-tests (Depends-on): Add unistr/u32-set.
95268         * modules/unistr/u16-chr-tests (Depends-on): Likewise.
95269         * modules/unistr/u8-strchr-tests (Depends-on): Likewise.
95270         * modules/unistr/u16-strchr-tests (Depends-on): Likewise.
95272 2010-07-28  Bruno Haible  <bruno@clisp.org>
95274         Use spaces for indentation, not tabs.
95275         * lib/**/*.[hcy] except lib/reg*.[hc]: Untabify.
95277 2010-07-27  Bruno Haible  <bruno@clisp.org>
95279         mbspcasecmp: Fix function specification.
95280         * lib/string.in.h (mbspcasecmp): Fix specification comment.
95281         * lib/mbspcasecmp.c (mbspcasecmp): Likewise.
95282         Reported by Eric Blake <eblake@redhat.com>.
95284 2010-07-26  Paul R. Eggert  <eggert@cs.ucla.edu>
95286         timespec: use cast and not conditional, as truncation isn't possible
95287         * lib/timespec.h (timespec_cmp): Use cast to pacify gcc -Wconversion
95288         instead of a conditional.  Comment about the situation in more detail.
95289         This undoes most of the 2009-10-29 patch.
95291 2010-07-23  Paolo Bonzini  <pbonzini@redhat.com>
95293         unistr/u8-chr, unistr/u8-strchr: use Boyer-Moore like algorithm.
95294         * lib/unistr/u8-chr.c: Add Boyer-Moore like operation.
95295         * lib/unistr/u8-strchr.c: Likewise.
95296         * modules/unistr/u8-chr: Depend on memchr.
95298         unistr/u*-strchr: add tests
95299         * modules/unistr/u8-strchr-tests: New file.
95300         * modules/unistr/u16-strchr-tests: New file.
95301         * modules/unistr/u32-strchr-tests: New file.
95302         * tests/unistr/test-strchr.h: New file.
95303         * tests/unistr/test-u8-strchr.c: New file.
95304         * tests/unistr/test-u16-strchr.c: New file.
95305         * tests/unistr/test-u32-strchr.c: New file.
95307         unistr/u*-chr: test multibyte sequences more
95308         * tests/unistr/test-chr.h: Do complete testing of the characters in the
95309         test vector.
95310         * tests/unistr/test-u8-chr.c (U_UCTOMB): Define.
95311         * tests/unistr/test-u16-chr.c (U_UCTOMB): Likewise.
95312         * tests/unistr/test-u32-chr.c (U_UCTOMB): Likewise.
95314         unistr/u*-chr: test multibyte sequences
95315         * tests/unistr/test-chr.h: Put characters above 0-127 in the test input.
95317         unistr/u*-chr: prepare for multibyte tests
95318         * modules/unistr/u8-chr-tests: Depend on u32-to-u8.
95319         * modules/unistr/u16-chr-tests: Depend on u32-to-u16.
95320         * tests/unistr/test-chr.h: Build initial version as UCS-4 then convert.
95321         * tests/unistr/test-u8-chr.c (U32_TO_U): Define.
95322         * tests/unistr/test-u16-chr.c (U32_TO_U): Likewise.
95323         * tests/unistr/test-u32-chr.c (U32_TO_U): Likewise.
95325 2010-07-18  Bruno Haible  <bruno@clisp.org>
95327         unistr/u8-strchr: Optimize non-ASCII argument case.
95328         * lib/unistr/u8-strchr.c (u8_strchr): Compare the last byte first,
95329         because the first byte often matches anyway.
95330         Reported by Pádraig Brady <P@draigbrady.com>.
95332 2010-07-15  Karl Berry  <karl@gnu.org>
95334         * config/srclist.txt (fdl.texi): only one copy, from gnustandards.
95336 2010-07-14  Paul R. Eggert  <eggert@cs.ucla.edu>
95338         getcwd: on Solaris, work better if ancestors are inaccessible
95339         * lib/getcwd.c (__getcwd): If getcwd returns EINVAL for zero
95340         buffer and size, try again with a large buffer.  This works better
95341         on Solaris, since its getcwd succeeds even if the path to the root
95342         is inaccessible, and this is helpful in common cases such as .zfs
95343         hidden directories.  Problem reported by J Chapman Flack in
95344         http://lists.gnu.org/r/bug-tar/2010-06/msg00000.html
95345         Use system getcwd if it's declared, not merely if it's partly
95346         working; use the partly-working test only to avoid needless effort
95347         if the system getcwd fails.
95348         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Omit
95349         comment that was already obsolete and is now even more obsolete.
95350         * modules/getcwd (Depends-on): Depend on strdup, since __getcwd
95351         now might call strdup.
95353 2010-07-13  Paul R. Eggert  <eggert@cs.ucla.edu>
95355         pthread: Add enough so that coreutils/src/sort.c compiles.
95356         * lib/pthread.in.h: Add self to author comment.  Conditionalize on
95357         _GL_PTHREAD_H, not PTHREAD_H_, for consistency with the rest of
95358         gnulib. Include <sched.h> and <time.h>, as per POSIX.
95359         Include <sys/types.h>, in case it defines pthread_t.
95360         (pthread_t, pthread_attr_t, pthread_barrier_t, pthread_barrierattr_t):
95361         (pthread_cond_t, pthread_condattr_t, pthread_key_t, pthread_mutex_t):
95362         (pthread_mutexattr_t, pthread_once_t, pthread_rwlock_t):
95363         (pthread_rwlockattr_t, pthread_spinlock_t):
95364         New typedefs, if HAVE_PTHREAD_T is not defined.
95365         (PTHREAD_COND_INITIALIZER, PTHREAD_MUTEX_INITIALIZER):
95366         (PTHREAD_ONCE_INIT, PTHREAD_RWLOCK_INITIALIZER):
95367         (PTHREAD_BARRIER_SERIAL_THREAD, PTHREAD_CANCEL_DEFERRED):
95368         (PTHREAD_CANCEL_ASYNCHRONOUS, PTHREAD_CANCEL_ENABLE):
95369         (PTHREAD_CANCEL_DISABLE, PTHREAD_CANCELED, PTHREAD_CREATE_JOINABLE):
95370         (PTHREAD_CREATE_DETACHED, PTHREAD_INHERIT_SCHED):
95371         (PTHREAD_EXPLICIT_SCHED, PTHREAD_MUTEX_DEFAULT, PTHREAD_MUTEX_NORMAL):
95372         (PTHREAD_MUTEX_ERRORCHECK, PTHREAD_MUTEX_RECURSIVE):
95373         (PTHREAD_MUTEX_STALLED, PTHREAD_MUTEX_ROBUST, PTHREAD_PRIO_NONE):
95374         (PTHREAD_PRIO_INHERIT, PTHREAD_PRIO_PROTECT, PTHREAD_PROCESS_PRIVATE):
95375         (PTHREAD_PROCESS_SHARED, PTHREAD_SCOPE_SYSTEM, PTHREAD_SCOPE_PROCESS):
95376         New macros.
95377         (pthread_cond_destroy, pthread_cond_init, pthread_cond_signal):
95378         (pthread_cond_wait, pthread_exit, pthread_mutex_destroy):
95379         (pthread_mutex_init, pthread_mutex_lock, pthread_mutex_unlock):
95380         (pthread_spin_init, pthread_spin_lock, pthread_spin_trylock);
95381         (pthread_spin_unlock): New dummy functions.
95382         (pthread_create): Return EAGAIN; don't set errno.
95383         * m4/pthread.m4 (gl_PTHREAD_CHECK): Check for pthread_t, and
95384         require AC_C_INLINE.
95385         * modules/pthread (Depends-on): Add sched, time.
95386         (pthread.h): Use AM_V_GEN.
95388 2010-07-13  Bruno Haible  <bruno@clisp.org>
95390         striconveh: Don't malloc memory if the result buffer is sufficient.
95391         * lib/striconveh.c (mem_cd_iconveh_internal): Use the provided result
95392         buffer if its size is sufficient.
95393         Reported by Ludovic Courtès <ludo@gnu.org>.
95395 2010-07-13  Bruno Haible  <bruno@clisp.org>
95397         strtod: Add safety check.
95398         * lib/strtod.c (ldexp): Abort if this dummy replacement gets called.
95400 2010-07-12  Bruno Haible  <bruno@clisp.org>
95402         Unify tests that set gl_cv_func_ldexpl_no_libm.
95403         * m4/ldexpl.m4 (gl_CHECK_LDEXPL_NO_LIBM): New macro, extracted from
95404         gl_FUNC_LDEXPL.
95405         (gl_FUNC_LDEXPL): Invoke it.
95406         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
95408 2010-07-12  Bruno Haible  <bruno@clisp.org>
95410         Unify tests that set gl_cv_func_ldexp_no_libm.
95411         * m4/ldexp.m4: New file, based on m4/mathfunc.m4.
95412         * m4/strtod.m4 (gl_PREREQ_STRTOD): Require gl_CHECK_LDEXP_NO_LIBM.
95413         * modules/ldexp (Files): Remove m4/mathfunc.m4. Add m4/ldexp.m4.
95414         (configure.ac): Simply invoke gl_FUNC_LDEXP.
95415         * modules/strtod (Files): Add m4/ldexp.m4.
95417 2010-07-12  Bruno Haible  <bruno@clisp.org>
95419         Unify tests that set gl_cv_func_frexpl_no_libm.
95420         * m4/frexpl.m4 (gl_CHECK_FREXPL_NO_LIBM): New macro, extracted from
95421         gl_FUNC_FREXPL_NO_LIBM.
95422         (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): Invoke it.
95423         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
95425 2010-07-12  Bruno Haible  <bruno@clisp.org>
95427         Unify tests that set gl_cv_func_frexp_no_libm.
95428         * m4/frexp.m4 (gl_CHECK_FREXP_NO_LIBM): New macro, extracted from
95429         gl_FUNC_FREXP_NO_LIBM.
95430         (gl_FUNC_FREXP, gl_FUNC_FREXP_NO_LIBM): Require it.
95431         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Likewise.
95433 2010-07-12  Paul R. Eggert  <eggert@cs.ucla.edu>
95435         memcoll: clarify sizes versus lengths, document better, and tweak perf
95436         * lib/memcoll.c (strcoll_loop, memcoll0):
95437         Improve quality of descriptive comments.  Name variables
95438         consistently as to whether they are lengths (which do not include
95439         terminating null) versus sizes (which do).
95440         * lib/xmemcoll.c (xmemcoll0): Likewise.
95441         * lib/memcoll.c (strcoll_loop): Tweak the way that the diff is
95442         returned when s1size == 0; this is easier to compile and saves
95443         about 17% of memcoll's code space on x86-64 with GCC 4.1.2.
95445 2010-07-12  Bruno Haible  <bruno@clisp.org>
95447         Tests for module '_Exit'.
95448         * modules/_Exit-tests: New file.
95449         * tests/test-_Exit.sh: New file.
95450         * tests/test-_Exit.c: New file.
95452         New module '_Exit'.
95453         * lib/stdlib.in.h (__attribute__): New macro.
95454         (_Exit): New declaration.
95455         * lib/_Exit.c: New file.
95456         * m4/_Exit.m4: New file.
95457         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether _Exit is declared.
95458         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB__EXIT and HAVE__EXIT.
95459         * modules/stdlib (Makefile.am): Substitute GNULIB__EXIT and HAVE__EXIT.
95460         * modules/_Exit: New file.
95461         * tests/test-stdlib-c++.cc (_Exit): Check signature.
95462         * doc/posix-functions/_Exit_C99.texi: Mention the new module.
95464 2010-07-12  Paul R. Eggert  <eggert@cs.ucla.edu>
95466         strtod: make it more-accurate typically, and don't require libm
95467         * lib/strtod.c (_GL_ARG_NONNULL): Remove; no longer needed.
95468         Include limits.h.  Don't include string.h.
95469         (HAVE_LDEXP_IN_LIBC, HAVE_RAW_DECL_STRTOD): Define to 0 if not defined.
95470         (locale_isspace): New function, so that no casts are needed to
95471         check whether *s is a space.
95472         (ldexp): Provide an unused dummy if not available.
95473         (scale_radix_exp, parse_number, underlying_strtod): New functions.
95474         (strtod): Use them.  This implementation prefers to use the
95475         underlying strtod if available, falling back on our own code
95476         only to fix known bugs.  This is more likely to produce an
95477         accurate result.  Also, it avoids the use of libm functions.
95478         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't invoke _AC_LIBOBJ_STRTOD;
95479         no longer needed.  Invoke AC_LIBOBJ([strtod]); don't know why this
95480         was absent, but it caused a test failure with coreutils.
95481         (gl_PREREQ_STRTOD): Check wither ldexp can be used without linking
95482         with libm.
95483         * modules/strtod (Makefile.am, Link): libm is no longer needed.
95484         * modules/strtod-tests (Makefile.am): Likewise.
95486 2010-07-11  Pádraig Brady  <P@draigBrady.com>
95487             Bruno Haible  <bruno@clisp.org>
95489         unistr/u8-strchr: Optimize ASCII argument case.
95490         * lib/unistr/u8-strchr.c (u8_strchr): For ASCII arguments, use strchr.
95492 2010-07-08  Paul Eggert  <eggert@cs.ucla.edu>
95494         (x)memcoll: minor tweaks
95495         * lib/memcoll.c (strcoll_loop): Prefer the style where 'const'
95496         is after the type that it qualifies.
95497         (memcoll0): Likewise.
95498         * lib/memcoll.h (memcoll0): Likewise.
95499         * lib/xmemcoll.c (collate_error, xmemcoll0): Likewise.
95500         * lib/xmemcoll.h (xmemcoll0): Likewise.
95501         * lib/memcoll.c (memcoll0): Correct the comment.  This function
95502         differs from memcoll in that the NUL byte is part of the argument.
95503         Omit the abort-checks, as performance is a real issue here.  Plus,
95504         the checks were wrong anyway (an off-by-one error).  Omit local
95505         variable 'diff', as it's a bit clearer that way.
95506         * m4/memcoll.m4 (gl_MEMCOLL): Omit AC_FUNC_STRCOLL, as it's
95507         no longer needed.
95509 2010-07-08  Chen Guo  <chenguo4@yahoo.com>
95511         (x)memcoll: speedup when input is known to be NUL delimited
95512         * lib/memcoll.c: Include stdlib.
95513         (memcoll0): New function.
95514         (strcoll_loop): New function, refactored for use in both memcoll
95515         and memcoll0.
95516         * lib/memcoll.h (memcoll0): Add prototype.
95517         * lib/xmemcoll.c (xmemcoll0): New function.
95518         (collate_error): New function, refactored for use in both xmemcoll
95519         and xmemcoll0.
95520         * lib/xmemcoll.h (xmemcoll0): Add prototype.
95521         * m4/memcoll.m4: add inline invocation.
95523 2010-07-06  Pádraig Brady  <P@draigBrady.com>
95525         * build-aux/bootstrap: Remove any local translations
95526         from the translation project synchronization directory,
95527         so that local only translations are not distributed.
95529 2010-07-04  Bruno Haible  <bruno@clisp.org>
95531         fsusage: Clarify which code applies to which platforms.
95532         * m4/fsusage.m4 (gl_FSUSAGE): Clarify which test succeeds on which
95533         platform.
95534         * lib/fsusage.c (get_fs_usage): Likewise.
95536 2010-07-04  Bruno Haible  <bruno@clisp.org>
95538         havelib: Fix bug when AC_LIB_FROMPACKAGE is used more than twice.
95539         * m4/lib-link.m4 (AC_LIB_FROMPACKAGE): Use m4_defn.
95540         Reported by Martin Lambers <marlam@marlam.de>.
95542 2010-07-04  Jim Meyering  <meyering@redhat.com>
95544         hash: once again explicitly disallow insertion of NULL
95545         * lib/hash.c (hash_insert0): Reinstate just-removed test:
95546         inserting a NULL pointer cannot work with these functions.
95547         Add a comment with details.
95548         This reverts part of the 2010-07-01 commit, 5bef1a35
95549         "hash: extend module to deal with non-pointer keys".
95551 2010-07-01  Bruno Haible  <bruno@clisp.org>
95553         stdbool: Update doc.
95554         * doc/posix-headers/stdbool.texi: Mention OpenBSD bug.
95555         Info from Christian Weisgerber <naddy@mips.inka.de>.
95557 2010-07-01  Jim Meyering  <meyering@redhat.com>
95559         hash: extend module to deal with non-pointer keys
95560         * lib/hash.c (hash_insert0): New interface, much like hash_insert
95561         but that allows insertion of non-pointer entries.
95562         Do not disallow an ENTRY value of NULL.
95563         (hash_insert): This is now just a thin wrapper.  Call hash_insert0.
95564         * lib/hash.h (hash_insert0): Declare.
95566 2010-07-01  Christian Weisgerber  <naddy@mips.inka.de>  (tiny change)
95568         gettext: Use AC_GNU_SOURCE as a fallback for AC_USE_SYSTEM_EXTENSIONS.
95569         * m4/fcntl-o.m4 (gl_FCNTL_O_FLAGS): When AC_USE_SYSTEM_EXTENSIONS is
95570         not present (i.e. with autoconf 2.59 and when using gettextize, not
95571         gnulib), require AC_GNU_SOURCE instead.
95573 2010-07-01  Ian Beckwith  <ianb@erislabs.net>
95575         idpriv-drop: Fix tests.
95576         * tests/test-idpriv-drop.su.sh: Refer to the test-idpriv-drop program,
95577         not to the test-idpriv-droptemp program.
95579 2010-06-29  Bruno Haible  <bruno@clisp.org>
95581         string: Fix syntax error with g++ 2.96.
95582         * lib/string.in.h (__pure__): Remove definition.
95583         (_GL_ATTRIBUTE_PURE): New macro.
95584         (memchr, memmem, memrchr, rawmemchr, strchrnul, strnlen, strpbrk,
95585         strstr, strcasestr): Use it instead of __attribute__ ((__pure__)).
95586         Reported by Christian Weisgerber <naddy@mips.inka.de>.
95588 2010-06-28  Ian Beckwith  <ianb@erislabs.net>
95590         unitypes: Fix bug introduced on 2010-05-18.
95591         * modules/unitypes (Files): Really add m4/libunistring-base.m4.
95593 2010-06-22  Eric Blake  <eblake@redhat.com>
95595         memmem: slight optimization
95596         * lib/str-two-way.h (critical_factorization): Update comments.
95597         Reduce work during factorization phase.
95598         Reported by Carlos Bueno <carlos@bueno.org>.
95600 2010-06-21  Bruno Haible  <bruno@clisp.org>
95602         Fix HAVE_CALLOC_POSIX misnomer.
95603         * lib/stdlib.in.h (calloc): Use REPLACE_CALLOC instead of
95604         !HAVE_CALLOC_POSIX.
95605         * m4/calloc.m4 (gl_REPLACE_CALLOC): Set REPLACE_CALLOC instead of
95606         HAVE_CALLOC_POSIX.
95607         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_CALLOC
95608         instead of HAVE_CALLOC_POSIX.
95609         * modules/stdlib (Makefile.am): Substitute REPLACE_CALLOC instead of
95610         HAVE_CALLOC_POSIX.
95612         Use modern idiom for calloc() replacement.
95613         * modules/calloc (configure.ac): Invoke gl_FUNC_CALLOC_GNU instead of
95614         AC_FUNC_CALLOC.
95615         * m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Renamed from AC_FUNC_CALLOC.
95616         Require gl_STDLIB_H_DEFAULTS. Invoke gl_REPLACE_CALLOC.
95617         (gl_FUNC_CALLOC_POSIX): Rely on gl_STDLIB_H_DEFAULTS to initialize
95618         HAVE_CALLOC_POSIX. Invoke gl_REPLACE_CALLOC.
95619         (gl_REPLACE_CALLOC): New macro.
95621 2010-06-21  Bruno Haible  <bruno@clisp.org>
95623         Fix HAVE_REALLOC_POSIX misnomer.
95624         * lib/stdlib.in.h (realloc): Use REPLACE_REALLOC instead of
95625         !HAVE_REALLOC_POSIX.
95626         * m4/realloc.m4 (gl_REPLACE_REALLOC): Set REPLACE_REALLOC instead of
95627         HAVE_REALLOC_POSIX.
95628         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_REALLOC
95629         instead of HAVE_REALLOC_POSIX.
95630         * modules/stdlib (Makefile.am): Substitute REPLACE_REALLOC instead of
95631         HAVE_REALLOC_POSIX.
95633         Use modern idiom for realloc() replacement.
95634         * modules/realloc (configure.ac): Invoke gl_FUNC_REALLOC_GNU instead of
95635         AC_FUNC_REALLOC.
95636         * m4/realloc.m4 (gl_FUNC_REALLOC_GNU): New macro, mostly copied from
95637         Autoconf's AC_FUNC_REALLOC.
95638         (gl_FUNC_REALLOC_POSIX): Rely on gl_STDLIB_H_DEFAULTS to initialize
95639         HAVE_REALLOC_POSIX. Invoke gl_REPLACE_REALLOC.
95640         (gl_REPLACE_REALLOC): New macro.
95641         Reported by Richard Lloyd <richard.lloyd@connectinternetsolutions.com>.
95643 2010-06-21  Bruno Haible  <bruno@clisp.org>
95645         Fix HAVE_MALLOC_POSIX misnomer.
95646         * lib/stdlib.in.h (malloc): Use REPLACE_MALLOC instead of
95647         !HAVE_MALLOC_POSIX.
95648         * m4/malloc.m4 (gl_REPLACE_MALLOC): Set REPLACE_MALLOC instead of
95649         HAVE_MALLOC_POSIX.
95650         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MALLOC
95651         instead of HAVE_MALLOC_POSIX.
95652         * modules/stdlib (Makefile.am): Substitute REPLACE_MALLOC instead of
95653         HAVE_MALLOC_POSIX.
95655         Use modern idiom for malloc() replacement.
95656         * modules/malloc (configure.ac): Invoke gl_FUNC_MALLOC_GNU instead of
95657         AC_FUNC_MALLOC.
95658         * m4/malloc.m4 (gl_FUNC_MALLOC_GNU): New macro, mostly copied from
95659         Autoconf's AC_FUNC_MALLOC.
95660         (gl_FUNC_MALLOC_POSIX): Rely on gl_STDLIB_H_DEFAULTS to initialize
95661         HAVE_MALLOC_POSIX. Invoke gl_REPLACE_MALLOC.
95662         (gl_REPLACE_MALLOC): New macro.
95663         Reported by Richard Lloyd <richard.lloyd@connectinternetsolutions.com>.
95665 2010-06-20  Richard Lloyd  <richard.lloyd@connectinternetsolutions.com>
95667         stdio.in.h: fix compilation failure when using HP-UX 11's C compiler
95668         * lib/stdio.in.h: Remove excess _GL_CXXALIAS_RPL macro argument.
95669         This macro takes 3 arguments, not 4.
95671 2010-06-15  Giuseppe Scrivano  <gscrivano@gnu.org>
95673         ipv6: fix detection under mingw
95674         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Include <ws2tcpip.h> for struct
95675         in6_addr.
95677 2010-06-14  Ben Pfaff  <blp@cs.stanford.edu>
95679         * m4/strtod.m4 (gl_FUNC_STRTOD): Factor out common code.  Assume
95680         that strtod() works when cross-compiling to a glibc version known
95681         to work.
95683 2010-06-15  Bruno Haible  <bruno@clisp.org>
95685         * m4/strtod.m4 (gl_FUNC_STRTOD): Stop using AC_FUNC_STRTOD.
95687 2010-06-15  René Berber  <r.berber@computer.org>  (tiny change)
95689         select: Correct timeout.
95690         * lib/select.c (rpl_select): Compute wait_timeout correctly.
95692 2010-06-14  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
95694         git-version-gen: init shell var to avoid env var influence
95695         * build-aux/git-version-gen (v): Init shell var to empty.
95697 2010-06-14  Paul Eggert  <eggert@cs.ucla.edu>
95699         priv-set: Don't assume that priv.h exists merely because getppriv does.
95700         See Jan Andersen's bug report about AIX 5L in
95701         http://lists.gnu.org/r/bug-tar/2010-06/msg00019.html
95702         * m4/priv-set.m4 (gl_PRIV_SET): Check for priv.h.
95703         * lib/priv-set.c: Do nothing unless HAVE_PRIV_H.
95704         * lib/priv-set.h: Likewise.
95705         * tests/test-priv-set.c: Likewise.
95707 2010-06-13  Bruno Haible  <bruno@clisp.org>
95709         relocatable: Make it easier to test whether to install wrappers.
95710         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): New automake conditional
95711         RELOCATABLE_VIA_WRAPPER.
95713 2010-06-13  Bruno Haible  <bruno@clisp.org>
95715         gnulib-tool: Display specified modules and dependencies differently.
95716         * gnulib-tool (func_show_module_list): New function.
95717         (func_import, func_create_testdir): Invoke it.
95718         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
95720 2010-06-13  Bruno Haible  <bruno@clisp.org>
95722         gnulib-tool: Align code of func_import and func_create_testdir.
95723         * gnulib-tool (func_create_testdir): Rename variable saved_modules to
95724         specified_modules.
95726 2010-06-12  Jim Meyering  <meyering@redhat.com>
95728         test-inttostr: avoid spurious failure on Solaris 9
95729         * tests/test-inttostr.c (main): Skip the test when snprintf fails
95730         to accept "%ju".  Reported by Bruno Haible.
95732 2010-06-11  Jim Meyering  <meyering@redhat.com>
95734         test-sys_socket: mark variables as used more readably
95735         * tests/test-sys_socket.c (main): Mark otherwise unused variables
95736         as "used" explicitly via (void) statement casts.  This is more
95737         readable than using them in an artificial return expression.
95738         Suggestion from Bruno Haible.
95740 2010-06-11  Bruno Haible  <bruno@clisp.org>
95742         Avoid some more warnings from "gcc -Wwrite-strings".
95743         * tests/test-argp.c (test_optional): Change 5th and 6th argument type
95744         to 'const char *'.
95745         * tests/test-c-strstr.c (main): Add 'const' to variable declaration.
95746         * tests/test-c-strcasestr.c (main): Likewise.
95747         * tests/test-mbscasestr1.c (main): Likewise.
95748         * tests/test-mbscasestr2.c (main): Likewise.
95749         * tests/test-memmem.c (main): Likewise.
95750         * tests/test-strstr.c (main): Likewise.
95751         * tests/test-strcasestr.c (main): Likewise.
95753 2010-06-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
95755         init.sh: change framework_failure_ to fail with status 99, not 1
95756         * tests/init.sh (framework_failure_): Exit 99, not 1.  This informs
95757         automake's parallel-tests rule that this is an unexpected failure,
95758         even if the test is listed in XFAIL_TESTS.
95760 2010-06-11  Jim Meyering  <meyering@redhat.com>
95762         test-inttostr: avoid warnings about 4-6KB literal strings
95763         * tests/test-inttostr.c: Don't use <assert.h>.  Instead, ...
95764         Include "macros.h", for its definition of ASSERT.
95765         (CK): s/assert/ASSERT/
95766         * modules/inttostr-tests (Files): Add macros.h.
95768         init.sh: don't use $ME_ or skip_ before they are defined
95769         * tests/init.sh: Hoist definitions of $ME_ and skip_ to precede
95770         their first uses.  Also hoist their companions: warn_, fail_,
95771         framework_failure_, $stderr_fileno.  Prompted by a patch from
95772         Stefano Lattarini.
95774         test-sys_socket: avoid set-but-not-used warnings from gcc
95775         * tests/test-sys_socket.c (main): Use "i" and "x", in order to
95776         avoid warning about set-but-not-used variables.
95778         test-xvasprintf: avoid 'const' discard warnings
95779         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Use
95780         "const" when assigning from literal strings.
95781         (test_xasprintf): Add "void" in function argument list to placate
95782         -Wstrict-prototypes and to be consistent with test_xvasprintf above.
95784         tests: avoid compilation warnings in argmatch and exclude tests...
95785         in packages that define ARGMATCH_DIE_DECL, like coreutils.
95786         * tests/test-exclude.c [ARGMATCH_DIE_DECL]: Also declare the function.
95787         Since it always exits, declare with the "noreturn" attribute.
95788         * tests/test-argmatch.c: Likewise.
95790         tests: avoid 'const' discard warnings in mbsstr tests
95791         * tests/test-mbsstr1.c (main): Add "const" to avoid trivial warning.
95792         * tests/test-mbsstr2.c (main): Likewise.
95794         test-verify: avoid warning from gcc's -Wmissing-declarations
95795         * tests/test-verify.c (function): Declare to be static.
95797         test-inttostr.c: include <string.h> for use of strcmp
95798         * tests/test-inttostr.c: Include <string.h> for strcmp declaration.
95800         test-linkat: avoid failed assertion on "other" architectures
95801         * tests/test-linkat.c: Include <sys/stat.h>, for declarations of stat,
95802         lstat, mkdir.  Patch by John Rigby, to fix FTBFS on armel, powerpc,
95803         sparc: https://bugs.launchpad.net/bugs/591968
95805 2010-06-11  Jim Meyering  <meyering@redhat.com>
95807         printf.m4: avoid autoconf's "Expanded Before Required" warning
95808         * m4/printf.m4 (gl_SNPRINTF_RETVAL_C99): Define using AC_DEFUN_ONCE,
95809         rather than AC_DEFUN, to avoid the classic "Expanded Before Required"
95810         autoconf warning.
95812 2010-06-10  Ben Pfaff  <blp@cs.stanford.edu>
95814         Replacement header templates are now named with ".in", not "_".
95815         * doc/gnulib-intro.texi: Correct.
95817 2010-06-10  Jim Meyering  <meyering@redhat.com>
95819         inttostr-tests: depend on snprintf, not snprintf-posix
95820         * modules/inttostr-tests (Depends-on): Depend on snprintf, not
95821         snprintf-posix, to avoid this aclocal failure:
95822           missing file gnulib-tests/vasnprintf.c
95823           configure.ac:45: error: expected source file, required through \
95824           AC_LIBSOURCES, not found
95826 2010-06-10  Jim Meyering  <meyering@redhat.com>
95828         inttostr: add a new function, inttostr, and tests
95829         The namesake function was not available.  The existence of the
95830         template file, inttostr.c makes its addition nontrivial.
95831         * lib/anytostr.c: Rename from inttostr.c.
95832         (anytostr): Rename from inttostr.
95833         * lib/inttostr.c: New file.
95834         * modules/inttostr (Files): Add anytostr.c.
95835         (Makefile.am): Set lib_SOURCES instead of ...
95836         * m4/inttostr.m4: Remove uses of AC_LIBOBJ.
95837         * lib/imaxtostr.c: Update use.  s/inttostr/anytostr/
95838         * lib/offtostr.c: Likewise.
95839         * lib/uinttostr.c: Likewise.
95840         * lib/umaxtostr.c: Likewise.
95841         * modules/inttostr-tests: New file.
95842         * tests/test-inttostr.c: New file.  Test these functions.
95844 2010-06-09  Ben Pfaff  <blp@cs.stanford.edu>
95845             Bruno Haible  <bruno@clisp.org>
95847         Add "Extending Gnulib" chapter to manual.
95848         * doc/gnulib.texi (Writing Modules): Add cross-reference to new
95849         chapter.
95850         (Extending Gnulib): New chapter.
95851         * doc/gnulib-intro.texi (Openness): Add cross-reference to new
95852         chapter.
95854 2010-06-09  Bruno Haible  <bruno@clisp.org>
95856         Avoid relocwrapper link errors due to gnulib replacement functions.
95857         * lib/areadlink.c: Use the system's malloc, realloc functions.
95858         (areadlink): Set errno to ENOMEM explicitly.
95859         * modules/areadlink (Depends-on): Remove malloc-posix.
95860         Reported by Ben Pfaff <blp@cs.stanford.edu>.
95862 2010-06-09  Bruno Haible  <bruno@clisp.org>
95864         Avoid relocwrapper link errors due to gnulib replacement functions.
95865         * lib/canonicalize-lgpl.c: Use the system's malloc function.
95866         * lib/malloca.c: Likewise.
95867         * lib/relocatable.c: Likewise.
95868         * lib/progreloc.c: Use the system's malloc, sprintf functions.
95869         * lib/relocwrapper.c: Use the system's fprintf, malloc functions.
95870         * lib/setenv.c: Use the system's malloc, realloc functions.
95871         * lib/strerror.c: Use the system's sprintf function.
95872         Reported by Ben Pfaff <blp@cs.stanford.edu>.
95874 2010-06-04  Bruno Haible  <bruno@clisp.org>
95876         Prefer documented low-level autoconf macro names.
95877         * m4/lib-link.m4: Use m4_translit instead of translit.
95878         * m4/environ.m4: Likewise.
95879         * m4/mathfunc.m4: Likewise.
95880         * m4/onceonly.m4: Likewise.
95881         * m4/stdint.m4: Likewise.
95882         Suggested by Eric Blake.
95884 2010-06-04  Martin Lambers  <marlam@marlam.de>
95885             Bruno Haible  <bruno@clisp.org>
95887         havelib: Allow library names with '+' characters.
95888         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
95889         AC_LIB_FROMPACKAGE, AC_LIB_LINKFLAGS_BODY): Convert '+' in name to '_'.
95891 2010-06-09  Bruno Haible  <bruno@clisp.org>
95893         Module setenv does not depend on 'malloc-posix', 'realloc-posix'.
95894         * lib/setenv.c (__add_to_environ): Set errno to ENOMEM when malloc or
95895         realloc failed.
95897 2010-06-08  Peter Simons  <simons@cryp.to>
95899         maint.mk: make the news-check rule more configurable
95900         * top/maint.mk (news-check-lines-spec): New variable.
95901         (news-check): Use "sed -n 1,10p" in place of "head".
95903 2010-06-07  Jim Meyering  <meyering@redhat.com>
95905         do-release-commit-and-tag: fix typo in --help
95906         * build-aux/do-release-commit-and-tag (Usage): Fix typo in --help.
95908         regex: avoid new dead-code warning with gcc-4.6.0
95909         * lib/regex_internal.c (re_string_reconstruct): #if-0-out a dead
95910         if-block containing a while-loop.  It's been unused for at least
95911         5 years.
95913 2010-06-05  Bruno Haible  <bruno@clisp.org>
95915         * doc/posix-functions/strcoll.texi: Mention Solaris limitation.
95916         Reported by River Tarnell <river.tarnell@wikimedia.de> via Eric Blake.
95918 2010-06-04  Bruno Haible  <bruno@clisp.org>
95920         Update to GNU gettext 0.18.1.
95921         * modules/gettext (configure.ac): Require gettext infrastructure from
95922         version 0.18.1.
95924 2010-06-03  Bruno Haible  <bruno@clisp.org>
95926         Don't use AC_LIBOBJ with file names in subdirectories.
95927         * m4/libunistring-base.m4 (gl_LIBUNISTRING_MODULE): Renamed from
95928         gl_LIBUNISTRING_LIBSOURCE. Take a module name as argument, not a file
95929         name. Define an automake conditional. Don't invoke AC_LIBOBJ.
95930         * m4/libunistring.m4 (gl_LIBUNISTRING): Update AC_BEFORE invocation.
95931         * modules/uni*/* (configure.ac): Use gl_LIBUNISTRING_MODULE instead of
95932         gl_LIBUNISTRING_LIBSOURCE.
95933         (Makefile.am): Augment lib_SOURCES here, conditionally.
95934         * NEWS: Drop requirement for Automake option 'subdir-objects'.
95936 2010-06-03  Bruno Haible  <bruno@clisp.org>
95938         Simplify gl_LIBUNISTRING_VERSION_CMP expansion.
95939         * m4/libunistring-base.m4 (gl_LIBUNISTRING_VERSION_CMP): Ensure
95940         expansion does not end with a newline.
95941         (gl_LIBUNISTRING_LIBSOURCE, gl_LIBUNISTRING_LIBHEADER): Avoid
95942         unnecessary newline.
95944 2010-06-03  Bruno Haible  <bruno@clisp.org>
95946         Reduce dependencies.
95947         * tests/test-quotearg.h: New file, extracted from
95948         tests/test-quotearg.c.
95949         * tests/test-quotearg-simple.c: New file, extracted from
95950         tests/test-quotearg.c.
95951         * tests/test-quotearg.c: Don't include <ctype.h>.
95952         (struct result_strings, struct result_groups, LQ, RQ, LQ_ENC, RQ_ENC,
95953         RQ_ESC, inputs, compare, use_quotearg_buffer, use_quotearg,
95954         use_quote_double_quotes, use_quotearg_colon): Moved to
95955         tests/test-quotearg.h.
95956         (results_g, flag_results, custom_quotes, custom_results): Moved
95957         to tests/test-quotearg-simple.c.
95958         (main): Moved the part that does not depend on gettext to
95959         tests/test-quotearg-simple.c. Return 77 if the test cannot be
95960         performed.
95961         * modules/quotearg-simple: New file.
95962         * modules/quotearg-simple-tests: New file.
95963         * modules/quotearg (Depends-on): Add quotearg-simple.
95964         * modules/quotearg-tests (Status): Mark as gettext-dependent-test.
95965         (Files): Add tests/test-quotearg.h.
95966         Reported by Paolo Bonzini.
95968 2010-06-03  Bruno Haible  <bruno@clisp.org>
95970         Reduce dependencies.
95971         * modules/acl (Depends-on): Add gettext-h. Remove gettext.
95973 2010-06-03  Bruno Haible  <bruno@clisp.org>
95975         time: Undefine more broken macros.
95976         * lib/time.in.h: Undefine broken localtime_r and gmtime_r macros only
95977         for pthread-win32. Undefine also asctime_r, ctime_r, rand_r, strtok_r.
95978         Reported by Eric Blake.
95980 2010-06-03  Bruno Haible  <bruno@clisp.org>
95982         Choose among AC_DEFUN_ONCE, AC_DEFUN in a way that aclocal understands.
95983         * m4/iconv.m4 (gl_iconv_AC_DEFUN): New macro.
95984         (AM_ICONV): Define it through gl_iconv_AC_DEFUN.
95985         * m4/libunistring.m4 (gl_libunistring_AC_DEFUN): New macro.
95986         (gl_LIBUNISTRING): Define it through gl_libunistring_AC_DEFUN.
95987         Reported by Ludovic Courtès <ludo@gnu.org>.
95989 2010-06-02  Eric Blake  <eblake@redhat.com>
95991         time: work with mingw + pthreads-win32 library
95992         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Set new variable
95993         if timespec is defined only in pthread.h.
95994         * modules/time (Makefile.am): Substitute it.
95995         * lib/time.in.h (!TIME_H_DEFINES_STRUCT_TIMESPEC): Include
95996         <pthread.h>, when needed.
95997         (GNULIB_TIME_R): Undefine broken localtime_r and gmtime_r macros
95998         from the library.
96000 2010-05-31  Bruno Haible  <bruno@clisp.org>
96002         Avoid expanding two macros in the wrong order.
96003         * m4/libunistring-base.m4 (gl_LIBUNISTRING_LIB_PREPARE): Require
96004         gl_LIBUNISTRING if it is defined.
96005         * m4/libunistring.m4 (gl_LIBUNISTRING): Define using AC_DEFUN_ONCE for
96006         autoconf >= 2.64.
96007         Reported by Ludovic Courtès <ludo@gnu.org>.
96009 2010-05-27  Jim Meyering  <meyering@redhat.com>
96011         maint.mk: also prohibit "#undef" of always-defined symbols
96012         * top/maint.mk (def_sym_regex): Handle #undef as well as #define.
96013         Allow more than one space before the symbol name.
96014         (sc_prohibit_always-defined_macros): Use grep's -E, now that
96015         the regexp uses alternation.
96017 2010-05-26  Eric Blake  <eblake@redhat.com>
96019         maint.mk: avoid echo -e
96020         * top/maint.mk (gzip_rsyncable, _ignore_case, _sc_say_and_exit):
96021         Convert all uses of echo -* to printf.
96022         Reported by Matthias Bolte.
96024 2010-05-25  Bruno Haible  <bruno@clisp.org>
96026         Update to GNU gettext 0.18, part 2.
96027         * build-aux/po/Makefile.in.in: Update to GNU gettext 0.18.
96028         Reported by Martin von Gagern <Martin.vGagern@gmx.net>.
96030 2010-05-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
96032         Add missing include in test-pwrite.c.
96033         * tests/test-pwrite.c: Include string.h, for strcmp.
96035 2010-05-24  Bruno Haible  <bruno@clisp.org>
96037         * NEWS: Mention requirement for Automake option 'subdir-objects'.
96039 2010-05-24  Bruno Haible  <bruno@clisp.org>
96041         Don't use conversion with transliteration in u{8,16,32}_strcoll.
96042         * lib/unistr/u-strcoll.h (FUNC): Use U_STRCONV_TO_ENCODING with
96043         iconveh_error argument.
96044         * lib/unistr/u8-strcoll.c: Define U_STRCONV_TO_ENCODING instead of
96045         U_STRCONV_TO_LOCALE.
96046         * lib/unistr/u16-strcoll.c: Likewise.
96047         * lib/unistr/u32-strcoll.c: Likewise.
96048         * modules/unistr/u8-strcoll (Depends-on): Add
96049         uniconv/u8-strconv-to-enc, localcharset. Remove
96050         uniconv/u8-strconv-to-locale.
96051         (configure.ac): Bump version number.
96052         * modules/unistr/u16-strcoll (Depends-on): Add
96053         uniconv/u16-strconv-to-enc, localcharset. Remove
96054         uniconv/u16-strconv-to-locale.
96055         (configure.ac): Bump version number.
96056         * modules/unistr/u32-strcoll (Depends-on): Add
96057         uniconv/u32-strconv-to-enc, localcharset. Remove
96058         uniconv/u32-strconv-to-locale.
96059         (configure.ac): Bump version number.
96061 2010-05-24  Bruno Haible  <bruno@clisp.org>
96063         Avoid a test failure on NetBSD 5.0.
96064         * tests/test-striconveh.c (main): On NetBSD, skip a test that triggers
96065         an iconv() bug.
96067 2010-05-24  Bruno Haible  <bruno@clisp.org>
96069         Adjust #include directive style.
96070         * modules/regex (Includes): Recommend to write <regex.h>.
96072 2010-05-24  Bruno Haible  <bruno@clisp.org>
96074         regex: Don't require alloca.
96075         * modules/regex (Depends-on): Remove alloca. Add alloca-opt.
96076         * lib/regex_internal.h (alloca): Ensure it's defined even if we call it
96077         only inside if (0).
96079 2010-05-23  Jim Meyering  <meyering@redhat.com>
96081         test-renameat.c: include <sys/stat.h>
96082         * tests/test-renameat.c: Include <sys/stat.h>; required for
96083         definition of S_IS* macros.
96085 2010-05-23  Ben Pfaff  <blp@cs.stanford.edu>
96087         Update maintainer documentation for 'relocatable-prog' module.
96088         * doc/relocatable-maint.texi: Update.
96089         Comments by Bruno Haible.
96091 2010-05-23  Bruno Haible  <bruno@clisp.org>
96093         git-merge-changelog: Enable --split-merged-entry by default.
96094         * lib/git-merge-changelog.c (main): Set split_merged_entry to true.
96095         (usage): Don't mention this option any more.
96096         Reported by Ralf Wildenhues.
96098 2010-05-23  Jim Meyering  <meyering@redhat.com>
96100         test-pwrite: do not leave behind a test file named "out"
96101         Revert commit d8fa18472a54c1cb2674c296b3d82443f234d5f7.
96102         The trivial-looking use of init.sh is really necessary.
96103         It ensures that the temporary file, "out", is created in
96104         a temporary directory, and removed upon termination.
96105         * tests/test-pwrite.sh: Re-add file.
96106         * modules/pwrite-tests: Reference it.
96108 2010-05-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
96110         Fix output redirection buglet in init.sh.
96111         * tests/init.sh: Fix redirection of stderr.
96113 2010-05-20  Simon Josefsson  <simon@josefsson.org>
96115         * modules/valgrind-tests (configure.ac): Invoke gl_VALGRIND_TESTS.
96117 2010-05-17  Simon Josefsson  <simon@josefsson.org>
96119         * modules/valgrind-tests: New file.
96120         * m4/valgrind-tests.m4: New file.
96121         * doc/valgrind-tests.texi: New file.
96122         * doc/gnulib.texi (Running self-tests under valgrind): New
96123         section.
96125 2010-05-19  Bruno Haible  <bruno@clisp.org>
96127         Clean up dead code in recent commit.
96128         * m4/libunistring-base.m4 (gl_LIBUNISTRING_VERSION_CMP): Include the
96129         body of gl_LIBUNISTRING_VERSION_CMP_ORIG as fallback.
96130         (gl_LIBUNISTRING_VERSION_CMP_ORIG): Remove macro.
96131         Suggested by Paolo Bonzini.
96133 2010-05-19  Bruno Haible  <bruno@clisp.org>
96135         Avoid valgrind error reports from libunistring.
96136         * lib/libunistring.valgrind: New file, based on lib/malloca.valgrind.
96137         * modules/libunistring (Files): Add it.
96138         * modules/libunistring-optional (Files): Likewise.
96140 2010-05-18  Paolo Bonzini  <bonzini@gnu.org>
96141             Bruno Haible  <bruno@clisp.org>
96143         New module 'libunistring-optional'.
96144         * modules/libunistring-optional: New file.
96145         * m4/libunistring-base.m4: New file.
96146         * m4/libunistring-optional.m4: New file.
96147         * lib/unicase.in.h: Renamed from lib/unicase.h.
96148         * lib/uniconv.in.h: Renamed from lib/uniconv.h.
96149         * lib/unictype.in.h: Renamed from lib/unictype.h.
96150         * lib/unilbrk.in.h: Renamed from lib/unilbrk.h.
96151         * lib/uniname.in.h: Renamed from lib/uniname.h.
96152         * lib/uninorm.in.h: Renamed from lib/uninorm.h.
96153         * lib/unistdio.in.h: Renamed from lib/unistdio.h.
96154         * lib/unistr.in.h: Renamed from lib/unistr.h.
96155         * lib/unitypes.in.h: Renamed from lib/unitypes.h.
96156         * lib/uniwbrk.in.h: Renamed from lib/uniwbrk.h.
96157         * lib/uniwidth.in.h: Renamed from lib/uniwidth.h.
96158         * m4/libunistring.m4 (gl_LIBUNISTRING_CORE): Renamed from
96159         gl_LIBUNISTRING. If the library was found, determine the installed
96160         version and set LIBUNISTRING_VERSION.
96161         (gl_LIBUNISTRING): New macro, as a wrapper arount it. Document that it
96162         sets LIBUNISTRING_VERSION. If the module libunistring-optional is used,
96163         handle a configuration option --with-included-libunistring.
96164         * modules/libunistring (Files): Add m4/absolute-header.m4.
96165         * modules/unicase/base (Files): Use unicase.in.h instead of unicase.h.
96166         Add m4/libunistring-base.m4.
96167         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96168         (Makefile.am): Build unicase.h from unicase.in.h.
96169         * modules/uniconv/base (Files): Use uniconv.in.h instead of uniconv.h.
96170         Add m4/libunistring-base.m4.
96171         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96172         (Makefile.am): Build uniconv.h from uniconv.in.h.
96173         * modules/unictype/base (Files): Use unictype.in.h instead of
96174         unictype.h. Add m4/libunistring-base.m4.
96175         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96176         (Makefile.am): Build unictype.h from unictype.in.h.
96177         * modules/unilbrk/base (Files): Use unilbrk.in.h instead of unilbrk.h.
96178         Add m4/libunistring-base.m4.
96179         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96180         (Makefile.am): Build unilbrk.h from unilbrk.in.h.
96181         * modules/uniname/base (Files): Use uniname.in.h instead of uniname.h.
96182         Add m4/libunistring-base.m4.
96183         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96184         (Makefile.am): Build uniname.h from uniname.in.h.
96185         * modules/uninorm/base (Files): Use uninorm.in.h instead of uninorm.h.
96186         Add m4/libunistring-base.m4.
96187         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96188         (Makefile.am): Build uninorm.h from uninorm.in.h.
96189         * modules/unistdio/base (Files): Use unistdio.in.h instead of
96190         unistdio.h. Add m4/libunistring-base.m4.
96191         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96192         (Makefile.am): Build unistdio.h from unistdio.in.h.
96193         * modules/unistr/base (Files): Use unistr.in.h instead of unistr.h.
96194         Add m4/libunistring-base.m4.
96195         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96196         (Makefile.am): Build unistr.h from unistr.in.h.
96197         * modules/unitypes (Files): Use unitypes.in.h instead of unitypes.h.
96198         Add m4/libunistring-base.m4.
96199         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96200         (Makefile.am): Build unitypes.h from unitypes.in.h.
96201         * modules/uniwbrk/base (Files): Use uniwbrk.in.h instead of uniwbrk.h.
96202         Add m4/libunistring-base.m4.
96203         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96204         (Makefile.am): Build uniwbrk.h from uniwbrk.in.h.
96205         * modules/uniwidth/base (Files): Use uniwidth.in.h instead of
96206         uniwidth.h. Add m4/libunistring-base.m4.
96207         (configure.ac): Invoke gl_LIBUNISTRING_LIBHEADER.
96208         (Makefile.am): Build uniwidth.h from uniwidth.in.h.
96209         * modules/unicase/empty-prefix-context: Use gl_LIBUNISTRING_LIBSOURCE
96210         instead of augmenting lib_SOURCES.
96211         * modules/unicase/empty-suffix-context: Likewise.
96212         * modules/unicase/locale-language: Likewise.
96213         * modules/unicase/tolower: Likewise.
96214         * modules/unicase/totitle: Likewise.
96215         * modules/unicase/toupper: Likewise.
96216         * modules/unicase/u8-casecmp: Likewise.
96217         * modules/unicase/u8-casecoll: Likewise.
96218         * modules/unicase/u8-casefold: Likewise.
96219         * modules/unicase/u8-casexfrm: Likewise.
96220         * modules/unicase/u8-ct-casefold: Likewise.
96221         * modules/unicase/u8-ct-tolower: Likewise.
96222         * modules/unicase/u8-ct-totitle: Likewise.
96223         * modules/unicase/u8-ct-toupper: Likewise.
96224         * modules/unicase/u8-is-cased: Likewise.
96225         * modules/unicase/u8-is-casefolded: Likewise.
96226         * modules/unicase/u8-is-lowercase: Likewise.
96227         * modules/unicase/u8-is-titlecase: Likewise.
96228         * modules/unicase/u8-is-uppercase: Likewise.
96229         * modules/unicase/u8-prefix-context: Likewise.
96230         * modules/unicase/u8-suffix-context: Likewise.
96231         * modules/unicase/u8-tolower: Likewise.
96232         * modules/unicase/u8-totitle: Likewise.
96233         * modules/unicase/u8-toupper: Likewise.
96234         * modules/unicase/u16-casecmp: Likewise.
96235         * modules/unicase/u16-casecoll: Likewise.
96236         * modules/unicase/u16-casefold: Likewise.
96237         * modules/unicase/u16-casexfrm: Likewise.
96238         * modules/unicase/u16-ct-casefold: Likewise.
96239         * modules/unicase/u16-ct-tolower: Likewise.
96240         * modules/unicase/u16-ct-totitle: Likewise.
96241         * modules/unicase/u16-ct-toupper: Likewise.
96242         * modules/unicase/u16-is-cased: Likewise.
96243         * modules/unicase/u16-is-casefolded: Likewise.
96244         * modules/unicase/u16-is-lowercase: Likewise.
96245         * modules/unicase/u16-is-titlecase: Likewise.
96246         * modules/unicase/u16-is-uppercase: Likewise.
96247         * modules/unicase/u16-prefix-context: Likewise.
96248         * modules/unicase/u16-suffix-context: Likewise.
96249         * modules/unicase/u16-tolower: Likewise.
96250         * modules/unicase/u16-totitle: Likewise.
96251         * modules/unicase/u16-toupper: Likewise.
96252         * modules/unicase/u32-casecmp: Likewise.
96253         * modules/unicase/u32-casecoll: Likewise.
96254         * modules/unicase/u32-casefold: Likewise.
96255         * modules/unicase/u32-casexfrm: Likewise.
96256         * modules/unicase/u32-ct-casefold: Likewise.
96257         * modules/unicase/u32-ct-tolower: Likewise.
96258         * modules/unicase/u32-ct-totitle: Likewise.
96259         * modules/unicase/u32-ct-toupper: Likewise.
96260         * modules/unicase/u32-is-cased: Likewise.
96261         * modules/unicase/u32-is-casefolded: Likewise.
96262         * modules/unicase/u32-is-lowercase: Likewise.
96263         * modules/unicase/u32-is-titlecase: Likewise.
96264         * modules/unicase/u32-is-uppercase: Likewise.
96265         * modules/unicase/u32-prefix-context: Likewise.
96266         * modules/unicase/u32-suffix-context: Likewise.
96267         * modules/unicase/u32-tolower: Likewise.
96268         * modules/unicase/u32-totitle: Likewise.
96269         * modules/unicase/u32-toupper: Likewise.
96270         * modules/unicase/ulc-casecmp: Likewise.
96271         * modules/unicase/ulc-casecoll: Likewise.
96272         * modules/unicase/ulc-casexfrm: Likewise.
96273         * modules/uniconv/u8-conv-from-enc: Likewise.
96274         * modules/uniconv/u8-conv-to-enc: Likewise.
96275         * modules/uniconv/u8-strconv-from-enc: Likewise.
96276         * modules/uniconv/u8-strconv-from-locale: Likewise.
96277         * modules/uniconv/u8-strconv-to-enc: Likewise.
96278         * modules/uniconv/u8-strconv-to-locale: Likewise.
96279         * modules/uniconv/u16-conv-from-enc: Likewise.
96280         * modules/uniconv/u16-conv-to-enc: Likewise.
96281         * modules/uniconv/u16-strconv-from-enc: Likewise.
96282         * modules/uniconv/u16-strconv-from-locale: Likewise.
96283         * modules/uniconv/u16-strconv-to-enc: Likewise.
96284         * modules/uniconv/u16-strconv-to-locale: Likewise.
96285         * modules/uniconv/u32-conv-from-enc: Likewise.
96286         * modules/uniconv/u32-conv-to-enc: Likewise.
96287         * modules/uniconv/u32-strconv-from-enc: Likewise.
96288         * modules/uniconv/u32-strconv-from-locale: Likewise.
96289         * modules/uniconv/u32-strconv-to-enc: Likewise.
96290         * modules/uniconv/u32-strconv-to-locale: Likewise.
96291         * modules/unictype/bidicategory-byname: Likewise.
96292         * modules/unictype/bidicategory-name: Likewise.
96293         * modules/unictype/bidicategory-of: Likewise.
96294         * modules/unictype/bidicategory-test: Likewise.
96295         * modules/unictype/block-list: Likewise.
96296         * modules/unictype/block-test: Likewise.
96297         * modules/unictype/category-C: Likewise.
96298         * modules/unictype/category-Cc: Likewise.
96299         * modules/unictype/category-Cf: Likewise.
96300         * modules/unictype/category-Cn: Likewise.
96301         * modules/unictype/category-Co: Likewise.
96302         * modules/unictype/category-Cs: Likewise.
96303         * modules/unictype/category-L: Likewise.
96304         * modules/unictype/category-Ll: Likewise.
96305         * modules/unictype/category-Lm: Likewise.
96306         * modules/unictype/category-Lo: Likewise.
96307         * modules/unictype/category-Lt: Likewise.
96308         * modules/unictype/category-Lu: Likewise.
96309         * modules/unictype/category-M: Likewise.
96310         * modules/unictype/category-Mc: Likewise.
96311         * modules/unictype/category-Me: Likewise.
96312         * modules/unictype/category-Mn: Likewise.
96313         * modules/unictype/category-N: Likewise.
96314         * modules/unictype/category-Nd: Likewise.
96315         * modules/unictype/category-Nl: Likewise.
96316         * modules/unictype/category-No: Likewise.
96317         * modules/unictype/category-P: Likewise.
96318         * modules/unictype/category-Pc: Likewise.
96319         * modules/unictype/category-Pd: Likewise.
96320         * modules/unictype/category-Pe: Likewise.
96321         * modules/unictype/category-Pf: Likewise.
96322         * modules/unictype/category-Pi: Likewise.
96323         * modules/unictype/category-Po: Likewise.
96324         * modules/unictype/category-Ps: Likewise.
96325         * modules/unictype/category-S: Likewise.
96326         * modules/unictype/category-Sc: Likewise.
96327         * modules/unictype/category-Sk: Likewise.
96328         * modules/unictype/category-Sm: Likewise.
96329         * modules/unictype/category-So: Likewise.
96330         * modules/unictype/category-Z: Likewise.
96331         * modules/unictype/category-Zl: Likewise.
96332         * modules/unictype/category-Zp: Likewise.
96333         * modules/unictype/category-Zs: Likewise.
96334         * modules/unictype/category-and: Likewise.
96335         * modules/unictype/category-and-not: Likewise.
96336         * modules/unictype/category-byname: Likewise.
96337         * modules/unictype/category-name: Likewise.
96338         * modules/unictype/category-none: Likewise.
96339         * modules/unictype/category-of: Likewise.
96340         * modules/unictype/category-or: Likewise.
96341         * modules/unictype/category-test: Likewise.
96342         * modules/unictype/combining-class: Likewise.
96343         * modules/unictype/ctype-alnum: Likewise.
96344         * modules/unictype/ctype-alpha: Likewise.
96345         * modules/unictype/ctype-blank: Likewise.
96346         * modules/unictype/ctype-cntrl: Likewise.
96347         * modules/unictype/ctype-digit: Likewise.
96348         * modules/unictype/ctype-graph: Likewise.
96349         * modules/unictype/ctype-lower: Likewise.
96350         * modules/unictype/ctype-print: Likewise.
96351         * modules/unictype/ctype-punct: Likewise.
96352         * modules/unictype/ctype-space: Likewise.
96353         * modules/unictype/ctype-upper: Likewise.
96354         * modules/unictype/ctype-xdigit: Likewise.
96355         * modules/unictype/decimal-digit: Likewise.
96356         * modules/unictype/digit: Likewise.
96357         * modules/unictype/mirror: Likewise.
96358         * modules/unictype/numeric: Likewise.
96359         * modules/unictype/property-alphabetic: Likewise.
96360         * modules/unictype/property-ascii-hex-digit: Likewise.
96361         * modules/unictype/property-bidi-arabic-digit: Likewise.
96362         * modules/unictype/property-bidi-arabic-right-to-left: Likewise.
96363         * modules/unictype/property-bidi-block-separator: Likewise.
96364         * modules/unictype/property-bidi-boundary-neutral: Likewise.
96365         * modules/unictype/property-bidi-common-separator: Likewise.
96366         * modules/unictype/property-bidi-control: Likewise.
96367         * modules/unictype/property-bidi-embedding-or-override: Likewise.
96368         * modules/unictype/property-bidi-eur-num-separator: Likewise.
96369         * modules/unictype/property-bidi-eur-num-terminator: Likewise.
96370         * modules/unictype/property-bidi-european-digit: Likewise.
96371         * modules/unictype/property-bidi-hebrew-right-to-left: Likewise.
96372         * modules/unictype/property-bidi-left-to-right: Likewise.
96373         * modules/unictype/property-bidi-non-spacing-mark: Likewise.
96374         * modules/unictype/property-bidi-other-neutral: Likewise.
96375         * modules/unictype/property-bidi-pdf: Likewise.
96376         * modules/unictype/property-bidi-segment-separator: Likewise.
96377         * modules/unictype/property-bidi-whitespace: Likewise.
96378         * modules/unictype/property-byname: Likewise.
96379         * modules/unictype/property-combining: Likewise.
96380         * modules/unictype/property-composite: Likewise.
96381         * modules/unictype/property-currency-symbol: Likewise.
96382         * modules/unictype/property-dash: Likewise.
96383         * modules/unictype/property-decimal-digit: Likewise.
96384         * modules/unictype/property-default-ignorable-code-point: Likewise.
96385         * modules/unictype/property-deprecated: Likewise.
96386         * modules/unictype/property-diacritic: Likewise.
96387         * modules/unictype/property-extender: Likewise.
96388         * modules/unictype/property-format-control: Likewise.
96389         * modules/unictype/property-grapheme-base: Likewise.
96390         * modules/unictype/property-grapheme-extend: Likewise.
96391         * modules/unictype/property-grapheme-link: Likewise.
96392         * modules/unictype/property-hex-digit: Likewise.
96393         * modules/unictype/property-hyphen: Likewise.
96394         * modules/unictype/property-id-continue: Likewise.
96395         * modules/unictype/property-id-start: Likewise.
96396         * modules/unictype/property-ideographic: Likewise.
96397         * modules/unictype/property-ids-binary-operator: Likewise.
96398         * modules/unictype/property-ids-trinary-operator: Likewise.
96399         * modules/unictype/property-ignorable-control: Likewise.
96400         * modules/unictype/property-iso-control: Likewise.
96401         * modules/unictype/property-join-control: Likewise.
96402         * modules/unictype/property-left-of-pair: Likewise.
96403         * modules/unictype/property-line-separator: Likewise.
96404         * modules/unictype/property-logical-order-exception: Likewise.
96405         * modules/unictype/property-lowercase: Likewise.
96406         * modules/unictype/property-math: Likewise.
96407         * modules/unictype/property-non-break: Likewise.
96408         * modules/unictype/property-not-a-character: Likewise.
96409         * modules/unictype/property-numeric: Likewise.
96410         * modules/unictype/property-other-alphabetic: Likewise.
96411         * modules/unictype/property-other-default-ignorable-code-point: Likewise.
96412         * modules/unictype/property-other-grapheme-extend: Likewise.
96413         * modules/unictype/property-other-id-continue: Likewise.
96414         * modules/unictype/property-other-id-start: Likewise.
96415         * modules/unictype/property-other-lowercase: Likewise.
96416         * modules/unictype/property-other-math: Likewise.
96417         * modules/unictype/property-other-uppercase: Likewise.
96418         * modules/unictype/property-paired-punctuation: Likewise.
96419         * modules/unictype/property-paragraph-separator: Likewise.
96420         * modules/unictype/property-pattern-syntax: Likewise.
96421         * modules/unictype/property-pattern-white-space: Likewise.
96422         * modules/unictype/property-private-use: Likewise.
96423         * modules/unictype/property-punctuation: Likewise.
96424         * modules/unictype/property-quotation-mark: Likewise.
96425         * modules/unictype/property-radical: Likewise.
96426         * modules/unictype/property-sentence-terminal: Likewise.
96427         * modules/unictype/property-soft-dotted: Likewise.
96428         * modules/unictype/property-space: Likewise.
96429         * modules/unictype/property-terminal-punctuation: Likewise.
96430         * modules/unictype/property-test: Likewise.
96431         * modules/unictype/property-titlecase: Likewise.
96432         * modules/unictype/property-unassigned-code-value: Likewise.
96433         * modules/unictype/property-unified-ideograph: Likewise.
96434         * modules/unictype/property-uppercase: Likewise.
96435         * modules/unictype/property-variation-selector: Likewise.
96436         * modules/unictype/property-white-space: Likewise.
96437         * modules/unictype/property-xid-continue: Likewise.
96438         * modules/unictype/property-xid-start: Likewise.
96439         * modules/unictype/property-zero-width: Likewise.
96440         * modules/unictype/scripts: Likewise.
96441         * modules/unictype/syntax-c-ident: Likewise.
96442         * modules/unictype/syntax-c-whitespace: Likewise.
96443         * modules/unictype/syntax-java-ident: Likewise.
96444         * modules/unictype/syntax-java-whitespace: Likewise.
96445         * modules/unilbrk/u8-possible-linebreaks: Likewise.
96446         * modules/unilbrk/u8-width-linebreaks: Likewise.
96447         * modules/unilbrk/u16-possible-linebreaks: Likewise.
96448         * modules/unilbrk/u16-width-linebreaks: Likewise.
96449         * modules/unilbrk/u32-possible-linebreaks: Likewise.
96450         * modules/unilbrk/u32-width-linebreaks: Likewise.
96451         * modules/unilbrk/ulc-possible-linebreaks: Likewise.
96452         * modules/unilbrk/ulc-width-linebreaks: Likewise.
96453         * modules/uniname/uniname: Likewise.
96454         * modules/uninorm/canonical-decomposition: Likewise.
96455         * modules/uninorm/composition: Likewise.
96456         * modules/uninorm/decomposing-form: Likewise.
96457         * modules/uninorm/decomposition: Likewise.
96458         * modules/uninorm/filter: Likewise.
96459         * modules/uninorm/nfc: Likewise.
96460         * modules/uninorm/nfd: Likewise.
96461         * modules/uninorm/nfkc: Likewise.
96462         * modules/uninorm/nfkd: Likewise.
96463         * modules/uninorm/u8-normalize: Likewise.
96464         * modules/uninorm/u8-normcmp: Likewise.
96465         * modules/uninorm/u8-normcoll: Likewise.
96466         * modules/uninorm/u8-normxfrm: Likewise.
96467         * modules/uninorm/u16-normalize: Likewise.
96468         * modules/uninorm/u16-normcmp: Likewise.
96469         * modules/uninorm/u16-normcoll: Likewise.
96470         * modules/uninorm/u16-normxfrm: Likewise.
96471         * modules/uninorm/u32-normalize: Likewise.
96472         * modules/uninorm/u32-normcmp: Likewise.
96473         * modules/uninorm/u32-normcoll: Likewise.
96474         * modules/uninorm/u32-normxfrm: Likewise.
96475         * modules/unistdio/u8-asnprintf: Likewise.
96476         * modules/unistdio/u8-asprintf: Likewise.
96477         * modules/unistdio/u8-snprintf: Likewise.
96478         * modules/unistdio/u8-sprintf: Likewise.
96479         * modules/unistdio/u8-u8-asnprintf: Likewise.
96480         * modules/unistdio/u8-u8-asprintf: Likewise.
96481         * modules/unistdio/u8-u8-snprintf: Likewise.
96482         * modules/unistdio/u8-u8-sprintf: Likewise.
96483         * modules/unistdio/u8-u8-vasnprintf: Likewise.
96484         * modules/unistdio/u8-u8-vasprintf: Likewise.
96485         * modules/unistdio/u8-u8-vsnprintf: Likewise.
96486         * modules/unistdio/u8-u8-vsprintf: Likewise.
96487         * modules/unistdio/u8-vasnprintf: Likewise.
96488         * modules/unistdio/u8-vasprintf: Likewise.
96489         * modules/unistdio/u8-vsnprintf: Likewise.
96490         * modules/unistdio/u8-vsprintf: Likewise.
96491         * modules/unistdio/u16-asnprintf: Likewise.
96492         * modules/unistdio/u16-asprintf: Likewise.
96493         * modules/unistdio/u16-snprintf: Likewise.
96494         * modules/unistdio/u16-sprintf: Likewise.
96495         * modules/unistdio/u16-u16-asnprintf: Likewise.
96496         * modules/unistdio/u16-u16-asprintf: Likewise.
96497         * modules/unistdio/u16-u16-snprintf: Likewise.
96498         * modules/unistdio/u16-u16-sprintf: Likewise.
96499         * modules/unistdio/u16-u16-vasnprintf: Likewise.
96500         * modules/unistdio/u16-u16-vasprintf: Likewise.
96501         * modules/unistdio/u16-u16-vsnprintf: Likewise.
96502         * modules/unistdio/u16-u16-vsprintf: Likewise.
96503         * modules/unistdio/u16-vasnprintf: Likewise.
96504         * modules/unistdio/u16-vasprintf: Likewise.
96505         * modules/unistdio/u16-vsnprintf: Likewise.
96506         * modules/unistdio/u16-vsprintf: Likewise.
96507         * modules/unistdio/u32-asnprintf: Likewise.
96508         * modules/unistdio/u32-asprintf: Likewise.
96509         * modules/unistdio/u32-snprintf: Likewise.
96510         * modules/unistdio/u32-sprintf: Likewise.
96511         * modules/unistdio/u32-u32-asnprintf: Likewise.
96512         * modules/unistdio/u32-u32-asprintf: Likewise.
96513         * modules/unistdio/u32-u32-snprintf: Likewise.
96514         * modules/unistdio/u32-u32-sprintf: Likewise.
96515         * modules/unistdio/u32-u32-vasnprintf: Likewise.
96516         * modules/unistdio/u32-u32-vasprintf: Likewise.
96517         * modules/unistdio/u32-u32-vsnprintf: Likewise.
96518         * modules/unistdio/u32-u32-vsprintf: Likewise.
96519         * modules/unistdio/u32-vasnprintf: Likewise.
96520         * modules/unistdio/u32-vasprintf: Likewise.
96521         * modules/unistdio/u32-vsnprintf: Likewise.
96522         * modules/unistdio/u32-vsprintf: Likewise.
96523         * modules/unistdio/ulc-asnprintf: Likewise.
96524         * modules/unistdio/ulc-asprintf: Likewise.
96525         * modules/unistdio/ulc-fprintf: Likewise.
96526         * modules/unistdio/ulc-snprintf: Likewise.
96527         * modules/unistdio/ulc-sprintf: Likewise.
96528         * modules/unistdio/ulc-vasnprintf: Likewise.
96529         * modules/unistdio/ulc-vasprintf: Likewise.
96530         * modules/unistdio/ulc-vfprintf: Likewise.
96531         * modules/unistdio/ulc-vsnprintf: Likewise.
96532         * modules/unistdio/ulc-vsprintf: Likewise.
96533         * modules/unistr/u8-check: Likewise.
96534         * modules/unistr/u8-chr: Likewise.
96535         * modules/unistr/u8-cmp: Likewise.
96536         * modules/unistr/u8-cmp2: Likewise.
96537         * modules/unistr/u8-cpy: Likewise.
96538         * modules/unistr/u8-cpy-alloc: Likewise.
96539         * modules/unistr/u8-endswith: Likewise.
96540         * modules/unistr/u8-mblen: Likewise.
96541         * modules/unistr/u8-mbsnlen: Likewise.
96542         * modules/unistr/u8-mbtouc: Likewise.
96543         * modules/unistr/u8-mbtouc-unsafe: Likewise.
96544         * modules/unistr/u8-mbtoucr: Likewise.
96545         * modules/unistr/u8-move: Likewise.
96546         * modules/unistr/u8-next: Likewise.
96547         * modules/unistr/u8-prev: Likewise.
96548         * modules/unistr/u8-set: Likewise.
96549         * modules/unistr/u8-startswith: Likewise.
96550         * modules/unistr/u8-stpcpy: Likewise.
96551         * modules/unistr/u8-stpncpy: Likewise.
96552         * modules/unistr/u8-strcat: Likewise.
96553         * modules/unistr/u8-strchr: Likewise.
96554         * modules/unistr/u8-strcmp: Likewise.
96555         * modules/unistr/u8-strcoll: Likewise.
96556         * modules/unistr/u8-strcpy: Likewise.
96557         * modules/unistr/u8-strcspn: Likewise.
96558         * modules/unistr/u8-strdup: Likewise.
96559         * modules/unistr/u8-strlen: Likewise.
96560         * modules/unistr/u8-strmblen: Likewise.
96561         * modules/unistr/u8-strmbtouc: Likewise.
96562         * modules/unistr/u8-strncat: Likewise.
96563         * modules/unistr/u8-strncmp: Likewise.
96564         * modules/unistr/u8-strncpy: Likewise.
96565         * modules/unistr/u8-strnlen: Likewise.
96566         * modules/unistr/u8-strpbrk: Likewise.
96567         * modules/unistr/u8-strrchr: Likewise.
96568         * modules/unistr/u8-strspn: Likewise.
96569         * modules/unistr/u8-strstr: Likewise.
96570         * modules/unistr/u8-strtok: Likewise.
96571         * modules/unistr/u8-to-u16: Likewise.
96572         * modules/unistr/u8-to-u32: Likewise.
96573         * modules/unistr/u8-uctomb: Likewise.
96574         * modules/unistr/u16-check: Likewise.
96575         * modules/unistr/u16-chr: Likewise.
96576         * modules/unistr/u16-cmp: Likewise.
96577         * modules/unistr/u16-cmp2: Likewise.
96578         * modules/unistr/u16-cpy: Likewise.
96579         * modules/unistr/u16-cpy-alloc: Likewise.
96580         * modules/unistr/u16-endswith: Likewise.
96581         * modules/unistr/u16-mblen: Likewise.
96582         * modules/unistr/u16-mbsnlen: Likewise.
96583         * modules/unistr/u16-mbtouc: Likewise.
96584         * modules/unistr/u16-mbtouc-unsafe: Likewise.
96585         * modules/unistr/u16-mbtoucr: Likewise.
96586         * modules/unistr/u16-move: Likewise.
96587         * modules/unistr/u16-next: Likewise.
96588         * modules/unistr/u16-prev: Likewise.
96589         * modules/unistr/u16-set: Likewise.
96590         * modules/unistr/u16-startswith: Likewise.
96591         * modules/unistr/u16-stpcpy: Likewise.
96592         * modules/unistr/u16-stpncpy: Likewise.
96593         * modules/unistr/u16-strcat: Likewise.
96594         * modules/unistr/u16-strchr: Likewise.
96595         * modules/unistr/u16-strcmp: Likewise.
96596         * modules/unistr/u16-strcoll: Likewise.
96597         * modules/unistr/u16-strcpy: Likewise.
96598         * modules/unistr/u16-strcspn: Likewise.
96599         * modules/unistr/u16-strdup: Likewise.
96600         * modules/unistr/u16-strlen: Likewise.
96601         * modules/unistr/u16-strmblen: Likewise.
96602         * modules/unistr/u16-strmbtouc: Likewise.
96603         * modules/unistr/u16-strncat: Likewise.
96604         * modules/unistr/u16-strncmp: Likewise.
96605         * modules/unistr/u16-strncpy: Likewise.
96606         * modules/unistr/u16-strnlen: Likewise.
96607         * modules/unistr/u16-strpbrk: Likewise.
96608         * modules/unistr/u16-strrchr: Likewise.
96609         * modules/unistr/u16-strspn: Likewise.
96610         * modules/unistr/u16-strstr: Likewise.
96611         * modules/unistr/u16-strtok: Likewise.
96612         * modules/unistr/u16-to-u32: Likewise.
96613         * modules/unistr/u16-to-u8: Likewise.
96614         * modules/unistr/u16-uctomb: Likewise.
96615         * modules/unistr/u32-check: Likewise.
96616         * modules/unistr/u32-chr: Likewise.
96617         * modules/unistr/u32-cmp: Likewise.
96618         * modules/unistr/u32-cmp2: Likewise.
96619         * modules/unistr/u32-cpy: Likewise.
96620         * modules/unistr/u32-cpy-alloc: Likewise.
96621         * modules/unistr/u32-endswith: Likewise.
96622         * modules/unistr/u32-mblen: Likewise.
96623         * modules/unistr/u32-mbsnlen: Likewise.
96624         * modules/unistr/u32-mbtouc: Likewise.
96625         * modules/unistr/u32-mbtouc-unsafe: Likewise.
96626         * modules/unistr/u32-mbtoucr: Likewise.
96627         * modules/unistr/u32-move: Likewise.
96628         * modules/unistr/u32-next: Likewise.
96629         * modules/unistr/u32-prev: Likewise.
96630         * modules/unistr/u32-set: Likewise.
96631         * modules/unistr/u32-startswith: Likewise.
96632         * modules/unistr/u32-stpcpy: Likewise.
96633         * modules/unistr/u32-stpncpy: Likewise.
96634         * modules/unistr/u32-strcat: Likewise.
96635         * modules/unistr/u32-strchr: Likewise.
96636         * modules/unistr/u32-strcmp: Likewise.
96637         * modules/unistr/u32-strcoll: Likewise.
96638         * modules/unistr/u32-strcpy: Likewise.
96639         * modules/unistr/u32-strcspn: Likewise.
96640         * modules/unistr/u32-strdup: Likewise.
96641         * modules/unistr/u32-strlen: Likewise.
96642         * modules/unistr/u32-strmblen: Likewise.
96643         * modules/unistr/u32-strmbtouc: Likewise.
96644         * modules/unistr/u32-strncat: Likewise.
96645         * modules/unistr/u32-strncmp: Likewise.
96646         * modules/unistr/u32-strncpy: Likewise.
96647         * modules/unistr/u32-strnlen: Likewise.
96648         * modules/unistr/u32-strpbrk: Likewise.
96649         * modules/unistr/u32-strrchr: Likewise.
96650         * modules/unistr/u32-strspn: Likewise.
96651         * modules/unistr/u32-strstr: Likewise.
96652         * modules/unistr/u32-strtok: Likewise.
96653         * modules/unistr/u32-to-u16: Likewise.
96654         * modules/unistr/u32-to-u8: Likewise.
96655         * modules/unistr/u32-uctomb: Likewise.
96656         * modules/uniwbrk/u8-wordbreaks: Likewise.
96657         * modules/uniwbrk/u16-wordbreaks: Likewise.
96658         * modules/uniwbrk/u32-wordbreaks: Likewise.
96659         * modules/uniwbrk/ulc-wordbreaks: Likewise.
96660         * modules/uniwbrk/wordbreak-property: Likewise.
96661         * modules/uniwidth/u8-strwidth: Likewise.
96662         * modules/uniwidth/u8-width: Likewise.
96663         * modules/uniwidth/u16-strwidth: Likewise.
96664         * modules/uniwidth/u16-width: Likewise.
96665         * modules/uniwidth/u32-strwidth: Likewise.
96666         * modules/uniwidth/u32-width: Likewise.
96667         * modules/uniwidth/width: Likewise.
96668         * modules/unicase/cased-tests (Makefile.am): Link all test programs
96669         with $(LIBUNISTRING).
96670         * modules/unicase/ignorable-tests: Likewise.
96671         * modules/unicase/locale-language-tests: Likewise.
96672         * modules/unicase/tolower-tests: Likewise.
96673         * modules/unicase/totitle-tests: Likewise.
96674         * modules/unicase/toupper-tests: Likewise.
96675         * modules/unicase/u8-casecmp-tests: Likewise.
96676         * modules/unicase/u8-casecoll-tests: Likewise.
96677         * modules/unicase/u8-casefold-tests: Likewise.
96678         * modules/unicase/u8-is-cased-tests: Likewise.
96679         * modules/unicase/u8-is-casefolded-tests: Likewise.
96680         * modules/unicase/u8-is-lowercase-tests: Likewise.
96681         * modules/unicase/u8-is-titlecase-tests: Likewise.
96682         * modules/unicase/u8-is-uppercase-tests: Likewise.
96683         * modules/unicase/u8-tolower-tests: Likewise.
96684         * modules/unicase/u8-totitle-tests: Likewise.
96685         * modules/unicase/u8-toupper-tests: Likewise.
96686         * modules/unicase/u16-casecmp-tests: Likewise.
96687         * modules/unicase/u16-casecoll-tests: Likewise.
96688         * modules/unicase/u16-casefold-tests: Likewise.
96689         * modules/unicase/u16-is-cased-tests: Likewise.
96690         * modules/unicase/u16-is-casefolded-tests: Likewise.
96691         * modules/unicase/u16-is-lowercase-tests: Likewise.
96692         * modules/unicase/u16-is-titlecase-tests: Likewise.
96693         * modules/unicase/u16-is-uppercase-tests: Likewise.
96694         * modules/unicase/u16-tolower-tests: Likewise.
96695         * modules/unicase/u16-totitle-tests: Likewise.
96696         * modules/unicase/u16-toupper-tests: Likewise.
96697         * modules/unicase/u32-casecmp-tests: Likewise.
96698         * modules/unicase/u32-casecoll-tests: Likewise.
96699         * modules/unicase/u32-casefold-tests: Likewise.
96700         * modules/unicase/u32-is-cased-tests: Likewise.
96701         * modules/unicase/u32-is-casefolded-tests: Likewise.
96702         * modules/unicase/u32-is-lowercase-tests: Likewise.
96703         * modules/unicase/u32-is-titlecase-tests: Likewise.
96704         * modules/unicase/u32-is-uppercase-tests: Likewise.
96705         * modules/unicase/u32-tolower-tests: Likewise.
96706         * modules/unicase/u32-totitle-tests: Likewise.
96707         * modules/unicase/u32-toupper-tests: Likewise.
96708         * modules/unicase/ulc-casecmp-tests: Likewise.
96709         * modules/unicase/ulc-casecoll-tests: Likewise.
96710         * modules/uniconv/u8-conv-from-enc-tests: Likewise.
96711         * modules/uniconv/u8-conv-to-enc-tests: Likewise.
96712         * modules/uniconv/u8-strconv-from-enc-tests: Likewise.
96713         * modules/uniconv/u8-strconv-to-enc-tests: Likewise.
96714         * modules/uniconv/u16-conv-from-enc-tests: Likewise.
96715         * modules/uniconv/u16-conv-to-enc-tests: Likewise.
96716         * modules/uniconv/u16-strconv-from-enc-tests: Likewise.
96717         * modules/uniconv/u16-strconv-to-enc-tests: Likewise.
96718         * modules/uniconv/u32-conv-from-enc-tests: Likewise.
96719         * modules/uniconv/u32-conv-to-enc-tests: Likewise.
96720         * modules/uniconv/u32-strconv-from-enc-tests: Likewise.
96721         * modules/uniconv/u32-strconv-to-enc-tests: Likewise.
96722         * modules/unictype/bidicategory-byname-tests: Likewise.
96723         * modules/unictype/bidicategory-name-tests: Likewise.
96724         * modules/unictype/bidicategory-of-tests: Likewise.
96725         * modules/unictype/bidicategory-test-tests: Likewise.
96726         * modules/unictype/block-list-tests: Likewise.
96727         * modules/unictype/block-of-tests: Likewise.
96728         * modules/unictype/block-test-tests: Likewise.
96729         * modules/unictype/category-C-tests: Likewise.
96730         * modules/unictype/category-Cc-tests: Likewise.
96731         * modules/unictype/category-Cf-tests: Likewise.
96732         * modules/unictype/category-Cn-tests: Likewise.
96733         * modules/unictype/category-Co-tests: Likewise.
96734         * modules/unictype/category-Cs-tests: Likewise.
96735         * modules/unictype/category-L-tests: Likewise.
96736         * modules/unictype/category-Ll-tests: Likewise.
96737         * modules/unictype/category-Lm-tests: Likewise.
96738         * modules/unictype/category-Lo-tests: Likewise.
96739         * modules/unictype/category-Lt-tests: Likewise.
96740         * modules/unictype/category-Lu-tests: Likewise.
96741         * modules/unictype/category-M-tests: Likewise.
96742         * modules/unictype/category-Mc-tests: Likewise.
96743         * modules/unictype/category-Me-tests: Likewise.
96744         * modules/unictype/category-Mn-tests: Likewise.
96745         * modules/unictype/category-N-tests: Likewise.
96746         * modules/unictype/category-Nd-tests: Likewise.
96747         * modules/unictype/category-Nl-tests: Likewise.
96748         * modules/unictype/category-No-tests: Likewise.
96749         * modules/unictype/category-P-tests: Likewise.
96750         * modules/unictype/category-Pc-tests: Likewise.
96751         * modules/unictype/category-Pd-tests: Likewise.
96752         * modules/unictype/category-Pe-tests: Likewise.
96753         * modules/unictype/category-Pf-tests: Likewise.
96754         * modules/unictype/category-Pi-tests: Likewise.
96755         * modules/unictype/category-Po-tests: Likewise.
96756         * modules/unictype/category-Ps-tests: Likewise.
96757         * modules/unictype/category-S-tests: Likewise.
96758         * modules/unictype/category-Sc-tests: Likewise.
96759         * modules/unictype/category-Sk-tests: Likewise.
96760         * modules/unictype/category-Sm-tests: Likewise.
96761         * modules/unictype/category-So-tests: Likewise.
96762         * modules/unictype/category-Z-tests: Likewise.
96763         * modules/unictype/category-Zl-tests: Likewise.
96764         * modules/unictype/category-Zp-tests: Likewise.
96765         * modules/unictype/category-Zs-tests: Likewise.
96766         * modules/unictype/category-and-not-tests: Likewise.
96767         * modules/unictype/category-and-tests: Likewise.
96768         * modules/unictype/category-byname-tests: Likewise.
96769         * modules/unictype/category-name-tests: Likewise.
96770         * modules/unictype/category-none-tests: Likewise.
96771         * modules/unictype/category-of-tests: Likewise.
96772         * modules/unictype/category-or-tests: Likewise.
96773         * modules/unictype/category-test-withtable-tests: Likewise.
96774         * modules/unictype/combining-class-tests: Likewise.
96775         * modules/unictype/ctype-alnum-tests: Likewise.
96776         * modules/unictype/ctype-alpha-tests: Likewise.
96777         * modules/unictype/ctype-blank-tests: Likewise.
96778         * modules/unictype/ctype-cntrl-tests: Likewise.
96779         * modules/unictype/ctype-digit-tests: Likewise.
96780         * modules/unictype/ctype-graph-tests: Likewise.
96781         * modules/unictype/ctype-lower-tests: Likewise.
96782         * modules/unictype/ctype-print-tests: Likewise.
96783         * modules/unictype/ctype-punct-tests: Likewise.
96784         * modules/unictype/ctype-space-tests: Likewise.
96785         * modules/unictype/ctype-upper-tests: Likewise.
96786         * modules/unictype/ctype-xdigit-tests: Likewise.
96787         * modules/unictype/decimal-digit-tests: Likewise.
96788         * modules/unictype/digit-tests: Likewise.
96789         * modules/unictype/mirror-tests: Likewise.
96790         * modules/unictype/numeric-tests: Likewise.
96791         * modules/unictype/property-alphabetic-tests: Likewise.
96792         * modules/unictype/property-ascii-hex-digit-tests: Likewise.
96793         * modules/unictype/property-bidi-arabic-digit-tests: Likewise.
96794         * modules/unictype/property-bidi-arabic-right-to-left-tests: Likewise.
96795         * modules/unictype/property-bidi-block-separator-tests: Likewise.
96796         * modules/unictype/property-bidi-boundary-neutral-tests: Likewise.
96797         * modules/unictype/property-bidi-common-separator-tests: Likewise.
96798         * modules/unictype/property-bidi-control-tests: Likewise.
96799         * modules/unictype/property-bidi-embedding-or-override-tests: Likewise.
96800         * modules/unictype/property-bidi-eur-num-separator-tests: Likewise.
96801         * modules/unictype/property-bidi-eur-num-terminator-tests: Likewise.
96802         * modules/unictype/property-bidi-european-digit-tests: Likewise.
96803         * modules/unictype/property-bidi-hebrew-right-to-left-tests: Likewise.
96804         * modules/unictype/property-bidi-left-to-right-tests: Likewise.
96805         * modules/unictype/property-bidi-non-spacing-mark-tests: Likewise.
96806         * modules/unictype/property-bidi-other-neutral-tests: Likewise.
96807         * modules/unictype/property-bidi-pdf-tests: Likewise.
96808         * modules/unictype/property-bidi-segment-separator-tests: Likewise.
96809         * modules/unictype/property-bidi-whitespace-tests: Likewise.
96810         * modules/unictype/property-byname-tests: Likewise.
96811         * modules/unictype/property-combining-tests: Likewise.
96812         * modules/unictype/property-composite-tests: Likewise.
96813         * modules/unictype/property-currency-symbol-tests: Likewise.
96814         * modules/unictype/property-dash-tests: Likewise.
96815         * modules/unictype/property-decimal-digit-tests: Likewise.
96816         * modules/unictype/property-default-ignorable-code-point-tests: Likewise.
96817         * modules/unictype/property-deprecated-tests: Likewise.
96818         * modules/unictype/property-diacritic-tests: Likewise.
96819         * modules/unictype/property-extender-tests: Likewise.
96820         * modules/unictype/property-format-control-tests: Likewise.
96821         * modules/unictype/property-grapheme-base-tests: Likewise.
96822         * modules/unictype/property-grapheme-extend-tests: Likewise.
96823         * modules/unictype/property-grapheme-link-tests: Likewise.
96824         * modules/unictype/property-hex-digit-tests: Likewise.
96825         * modules/unictype/property-hyphen-tests: Likewise.
96826         * modules/unictype/property-id-continue-tests: Likewise.
96827         * modules/unictype/property-id-start-tests: Likewise.
96828         * modules/unictype/property-ideographic-tests: Likewise.
96829         * modules/unictype/property-ids-binary-operator-tests: Likewise.
96830         * modules/unictype/property-ids-trinary-operator-tests: Likewise.
96831         * modules/unictype/property-ignorable-control-tests: Likewise.
96832         * modules/unictype/property-iso-control-tests: Likewise.
96833         * modules/unictype/property-join-control-tests: Likewise.
96834         * modules/unictype/property-left-of-pair-tests: Likewise.
96835         * modules/unictype/property-line-separator-tests: Likewise.
96836         * modules/unictype/property-logical-order-exception-tests: Likewise.
96837         * modules/unictype/property-lowercase-tests: Likewise.
96838         * modules/unictype/property-math-tests: Likewise.
96839         * modules/unictype/property-non-break-tests: Likewise.
96840         * modules/unictype/property-not-a-character-tests: Likewise.
96841         * modules/unictype/property-numeric-tests: Likewise.
96842         * modules/unictype/property-other-alphabetic-tests: Likewise.
96843         * modules/unictype/property-other-default-ignorable-code-point-tests:
96844         Likewise.
96845         * modules/unictype/property-other-grapheme-extend-tests: Likewise.
96846         * modules/unictype/property-other-id-continue-tests: Likewise.
96847         * modules/unictype/property-other-id-start-tests: Likewise.
96848         * modules/unictype/property-other-lowercase-tests: Likewise.
96849         * modules/unictype/property-other-math-tests: Likewise.
96850         * modules/unictype/property-other-uppercase-tests: Likewise.
96851         * modules/unictype/property-paired-punctuation-tests: Likewise.
96852         * modules/unictype/property-paragraph-separator-tests: Likewise.
96853         * modules/unictype/property-pattern-syntax-tests: Likewise.
96854         * modules/unictype/property-pattern-white-space-tests: Likewise.
96855         * modules/unictype/property-private-use-tests: Likewise.
96856         * modules/unictype/property-punctuation-tests: Likewise.
96857         * modules/unictype/property-quotation-mark-tests: Likewise.
96858         * modules/unictype/property-radical-tests: Likewise.
96859         * modules/unictype/property-sentence-terminal-tests: Likewise.
96860         * modules/unictype/property-soft-dotted-tests: Likewise.
96861         * modules/unictype/property-space-tests: Likewise.
96862         * modules/unictype/property-terminal-punctuation-tests: Likewise.
96863         * modules/unictype/property-test-tests: Likewise.
96864         * modules/unictype/property-titlecase-tests: Likewise.
96865         * modules/unictype/property-unassigned-code-value-tests: Likewise.
96866         * modules/unictype/property-unified-ideograph-tests: Likewise.
96867         * modules/unictype/property-uppercase-tests: Likewise.
96868         * modules/unictype/property-variation-selector-tests: Likewise.
96869         * modules/unictype/property-white-space-tests: Likewise.
96870         * modules/unictype/property-xid-continue-tests: Likewise.
96871         * modules/unictype/property-xid-start-tests: Likewise.
96872         * modules/unictype/property-zero-width-tests: Likewise.
96873         * modules/unictype/scripts-tests: Likewise.
96874         * modules/unictype/syntax-c-ident-tests: Likewise.
96875         * modules/unictype/syntax-c-whitespace-tests: Likewise.
96876         * modules/unictype/syntax-java-ident-tests: Likewise.
96877         * modules/unictype/syntax-java-whitespace-tests: Likewise.
96878         * modules/unilbrk/u8-possible-linebreaks-tests: Likewise.
96879         * modules/unilbrk/u8-width-linebreaks-tests: Likewise.
96880         * modules/unilbrk/u16-possible-linebreaks-tests: Likewise.
96881         * modules/unilbrk/u16-width-linebreaks-tests: Likewise.
96882         * modules/unilbrk/u32-possible-linebreaks-tests: Likewise.
96883         * modules/unilbrk/u32-width-linebreaks-tests: Likewise.
96884         * modules/unilbrk/ulc-possible-linebreaks-tests: Likewise.
96885         * modules/unilbrk/ulc-width-linebreaks-tests: Likewise.
96886         * modules/uniname/uniname-tests: Likewise.
96887         * modules/uninorm/canonical-decomposition-tests: Likewise.
96888         * modules/uninorm/compat-decomposition-tests: Likewise.
96889         * modules/uninorm/composition-tests: Likewise.
96890         * modules/uninorm/decomposing-form-tests: Likewise.
96891         * modules/uninorm/decomposition-tests: Likewise.
96892         * modules/uninorm/filter-tests: Likewise.
96893         * modules/uninorm/nfc-tests: Likewise.
96894         * modules/uninorm/nfd-tests: Likewise.
96895         * modules/uninorm/nfkc-tests: Likewise.
96896         * modules/uninorm/nfkd-tests: Likewise.
96897         * modules/uninorm/u8-normcmp-tests: Likewise.
96898         * modules/uninorm/u8-normcoll-tests: Likewise.
96899         * modules/uninorm/u16-normcmp-tests: Likewise.
96900         * modules/uninorm/u16-normcoll-tests: Likewise.
96901         * modules/uninorm/u32-normcmp-tests: Likewise.
96902         * modules/uninorm/u32-normcoll-tests: Likewise.
96903         * modules/unistdio/u8-asnprintf-tests: Likewise.
96904         * modules/unistdio/u8-vasnprintf-tests: Likewise.
96905         * modules/unistdio/u8-vasprintf-tests: Likewise.
96906         * modules/unistdio/u8-vsnprintf-tests: Likewise.
96907         * modules/unistdio/u8-vsprintf-tests: Likewise.
96908         * modules/unistdio/u16-asnprintf-tests: Likewise.
96909         * modules/unistdio/u16-vasnprintf-tests: Likewise.
96910         * modules/unistdio/u16-vasprintf-tests: Likewise.
96911         * modules/unistdio/u16-vsnprintf-tests: Likewise.
96912         * modules/unistdio/u16-vsprintf-tests: Likewise.
96913         * modules/unistdio/u32-asnprintf-tests: Likewise.
96914         * modules/unistdio/u32-vasnprintf-tests: Likewise.
96915         * modules/unistdio/u32-vasprintf-tests: Likewise.
96916         * modules/unistdio/u32-vsnprintf-tests: Likewise.
96917         * modules/unistdio/u32-vsprintf-tests: Likewise.
96918         * modules/unistdio/ulc-asnprintf-tests: Likewise.
96919         * modules/unistdio/ulc-vasnprintf-tests: Likewise.
96920         * modules/unistdio/ulc-vasprintf-tests: Likewise.
96921         * modules/unistdio/ulc-vsnprintf-tests: Likewise.
96922         * modules/unistdio/ulc-vsprintf-tests: Likewise.
96923         * modules/unistr/u8-check-tests: Likewise.
96924         * modules/unistr/u8-chr-tests: Likewise.
96925         * modules/unistr/u8-cmp-tests: Likewise.
96926         * modules/unistr/u8-cmp2-tests: Likewise.
96927         * modules/unistr/u8-cpy-alloc-tests: Likewise.
96928         * modules/unistr/u8-cpy-tests: Likewise.
96929         * modules/unistr/u8-mblen-tests: Likewise.
96930         * modules/unistr/u8-mbsnlen-tests: Likewise.
96931         * modules/unistr/u8-mbtouc-tests: Likewise.
96932         * modules/unistr/u8-mbtouc-unsafe-tests: Likewise.
96933         * modules/unistr/u8-mbtoucr-tests: Likewise.
96934         * modules/unistr/u8-move-tests: Likewise.
96935         * modules/unistr/u8-next-tests: Likewise.
96936         * modules/unistr/u8-prev-tests: Likewise.
96937         * modules/unistr/u8-set-tests: Likewise.
96938         * modules/unistr/u8-stpcpy-tests: Likewise.
96939         * modules/unistr/u8-stpncpy-tests: Likewise.
96940         * modules/unistr/u8-strcat-tests: Likewise.
96941         * modules/unistr/u8-strcmp-tests: Likewise.
96942         * modules/unistr/u8-strcoll-tests: Likewise.
96943         * modules/unistr/u8-strcpy-tests: Likewise.
96944         * modules/unistr/u8-strdup-tests: Likewise.
96945         * modules/unistr/u8-strlen-tests: Likewise.
96946         * modules/unistr/u8-strmblen-tests: Likewise.
96947         * modules/unistr/u8-strmbtouc-tests: Likewise.
96948         * modules/unistr/u8-strncat-tests: Likewise.
96949         * modules/unistr/u8-strncmp-tests: Likewise.
96950         * modules/unistr/u8-strncpy-tests: Likewise.
96951         * modules/unistr/u8-strnlen-tests: Likewise.
96952         * modules/unistr/u8-to-u16-tests: Likewise.
96953         * modules/unistr/u8-to-u32-tests: Likewise.
96954         * modules/unistr/u8-uctomb-tests: Likewise.
96955         * modules/unistr/u16-check-tests: Likewise.
96956         * modules/unistr/u16-chr-tests: Likewise.
96957         * modules/unistr/u16-cmp-tests: Likewise.
96958         * modules/unistr/u16-cmp2-tests: Likewise.
96959         * modules/unistr/u16-cpy-alloc-tests: Likewise.
96960         * modules/unistr/u16-cpy-tests: Likewise.
96961         * modules/unistr/u16-mblen-tests: Likewise.
96962         * modules/unistr/u16-mbsnlen-tests: Likewise.
96963         * modules/unistr/u16-mbtouc-tests: Likewise.
96964         * modules/unistr/u16-mbtouc-unsafe-tests: Likewise.
96965         * modules/unistr/u16-mbtoucr-tests: Likewise.
96966         * modules/unistr/u16-move-tests: Likewise.
96967         * modules/unistr/u16-next-tests: Likewise.
96968         * modules/unistr/u16-prev-tests: Likewise.
96969         * modules/unistr/u16-set-tests: Likewise.
96970         * modules/unistr/u16-stpcpy-tests: Likewise.
96971         * modules/unistr/u16-stpncpy-tests: Likewise.
96972         * modules/unistr/u16-strcat-tests: Likewise.
96973         * modules/unistr/u16-strcmp-tests: Likewise.
96974         * modules/unistr/u16-strcoll-tests: Likewise.
96975         * modules/unistr/u16-strcpy-tests: Likewise.
96976         * modules/unistr/u16-strdup-tests: Likewise.
96977         * modules/unistr/u16-strlen-tests: Likewise.
96978         * modules/unistr/u16-strmblen-tests: Likewise.
96979         * modules/unistr/u16-strmbtouc-tests: Likewise.
96980         * modules/unistr/u16-strncat-tests: Likewise.
96981         * modules/unistr/u16-strncmp-tests: Likewise.
96982         * modules/unistr/u16-strncpy-tests: Likewise.
96983         * modules/unistr/u16-strnlen-tests: Likewise.
96984         * modules/unistr/u16-to-u32-tests: Likewise.
96985         * modules/unistr/u16-to-u8-tests: Likewise.
96986         * modules/unistr/u16-uctomb-tests: Likewise.
96987         * modules/unistr/u32-check-tests: Likewise.
96988         * modules/unistr/u32-chr-tests: Likewise.
96989         * modules/unistr/u32-cmp-tests: Likewise.
96990         * modules/unistr/u32-cmp2-tests: Likewise.
96991         * modules/unistr/u32-cpy-alloc-tests: Likewise.
96992         * modules/unistr/u32-cpy-tests: Likewise.
96993         * modules/unistr/u32-mblen-tests: Likewise.
96994         * modules/unistr/u32-mbsnlen-tests: Likewise.
96995         * modules/unistr/u32-mbtouc-tests: Likewise.
96996         * modules/unistr/u32-mbtouc-unsafe-tests: Likewise.
96997         * modules/unistr/u32-mbtoucr-tests: Likewise.
96998         * modules/unistr/u32-move-tests: Likewise.
96999         * modules/unistr/u32-next-tests: Likewise.
97000         * modules/unistr/u32-prev-tests: Likewise.
97001         * modules/unistr/u32-set-tests: Likewise.
97002         * modules/unistr/u32-stpcpy-tests: Likewise.
97003         * modules/unistr/u32-stpncpy-tests: Likewise.
97004         * modules/unistr/u32-strcat-tests: Likewise.
97005         * modules/unistr/u32-strcmp-tests: Likewise.
97006         * modules/unistr/u32-strcoll-tests: Likewise.
97007         * modules/unistr/u32-strcpy-tests: Likewise.
97008         * modules/unistr/u32-strdup-tests: Likewise.
97009         * modules/unistr/u32-strlen-tests: Likewise.
97010         * modules/unistr/u32-strmblen-tests: Likewise.
97011         * modules/unistr/u32-strmbtouc-tests: Likewise.
97012         * modules/unistr/u32-strncat-tests: Likewise.
97013         * modules/unistr/u32-strncmp-tests: Likewise.
97014         * modules/unistr/u32-strncpy-tests: Likewise.
97015         * modules/unistr/u32-strnlen-tests: Likewise.
97016         * modules/unistr/u32-to-u16-tests: Likewise.
97017         * modules/unistr/u32-to-u8-tests: Likewise.
97018         * modules/unistr/u32-uctomb-tests: Likewise.
97019         * modules/uniwbrk/u8-wordbreaks-tests: Likewise.
97020         * modules/uniwbrk/u16-wordbreaks-tests: Likewise.
97021         * modules/uniwbrk/u32-wordbreaks-tests: Likewise.
97022         * modules/uniwbrk/ulc-wordbreaks-tests: Likewise.
97023         * modules/uniwidth/u8-strwidth-tests: Likewise.
97024         * modules/uniwidth/u8-width-tests: Likewise.
97025         * modules/uniwidth/u16-strwidth-tests: Likewise.
97026         * modules/uniwidth/u16-width-tests: Likewise.
97027         * modules/uniwidth/u32-strwidth-tests: Likewise.
97028         * modules/uniwidth/u32-width-tests: Likewise.
97029         * modules/uniwidth/width-tests: Likewise.
97031 2010-05-18  Richard Jones  <rjones@redhat.com>
97033         doc: users.txt: list hivex
97034         * users.txt: Add hivex.
97036 2010-05-18  Richard Jones  <rjones@redhat.com>
97038         doc: users.txt: list febootstrap
97039         * users.txt: Add febootstrap.
97041 2010-05-17  Giuseppe Scrivano  <gscrivano@gnu.org>
97043         bootstrap: fix an error when gnulib is not used as a git submodule
97044         * build-aux/bootstrap (gnulib_path): If its length is zero then
97045         assign "gnulib" to it.
97046         * build-aux/bootstrap: Redirect "git clone -h" stderr to stdout.
97048 2010-05-16  Bruno Haible  <bruno@clisp.org>
97050         Avoid autoconf warnings about AM_ICONV.
97051         * m4/iconv.m4 (AM_ICONV): Define using AC_DEFUN_ONCE for autoconf >=
97052         2.64.
97054 2010-05-16  Bruno Haible  <bruno@clisp.org>
97056         absolute-header: Make the macro usable in more situations.
97057         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER_ONE): New macro, extracted
97058         from gl_ABSOLUTE_HEADER.
97059         (gl_ABSOLUTE_HEADER): Use it. Fix comment.
97061 2010-05-16  James Youngman  <jay@gnu.org>
97063         doc: update users.txt
97064         * users.txt: Add CSSC.
97066 2010-05-16  Jim Meyering  <meyering@redhat.com>
97068         init.sh: fix an error in the previous change; add more comments
97069         * tests/init.sh: Compare exit code in loop against 9, not 2.
97070         Patch by Bruno Haible.
97071         Make the two tests more similar by adding an empty "then" clause.
97072         Add comments.
97074         init.sh: avoid unnecessary shell re-exec
97075         * tests/init.sh: Improve the re-exec-required check to first test the
97076         current shell.  If it passes the test, do not search for a shell that
97077         does pass, and do not re-exec.  This test is particularly contorted to
97078         avoid triggering misbehavior in Solaris 10's /bin/sh whereby any use
97079         of $(...) evokes a syntax error and causes immediate shell exit with
97080         status 2.  Bruno Haible reported that the re-exec made it impossible
97081         to single-step through any init.sh-using script.
97083 2010-05-16  Bruno Haible  <bruno@clisp.org>
97085         Fix collision between gnulib's and libintl's printf replacements.
97086         * lib/stdio.in.h (_GL_STDIO_STRINGIZE,
97087         _GL_STDIO_MACROEXPAND_AND_STRINGIZE): New macros.
97088         (printf): When using GNU C, map the __printf__ function to rpl_printf
97089         via __asm__. When not using GNU C, define rpl_printf instead of
97090         __printf__.
97091         * lib/printf.c: Ignore DEPENDS_ON_LIBINTL. Undoes the 2010-03-25
97092         commit.
97093         * lib/stdio-write.c: Ignore DEPENDS_ON_LIBINTL. Undoes the 2009-08-10
97094         commit.
97095         * m4/asm-underscore.m4: New file.
97096         * m4/stdio_h.m4 (gl_STDIO_H): Require gl_ASM_SYMBOL_PREFIX.
97097         * modules/stdio (Files): Add m4/asm-underscore.m4.
97098         (Makefile.am): Substitute ASM_SYMBOL_PREFIX.
97099         Reported by Ben Pfaff.
97101 2010-05-16  Bruno Haible  <bruno@clisp.org>
97103         verify: Avoid skipping the test on openSUSE 11.0.
97104         * tests/test-verify.sh: Unset MALLOC_PERTURB_.
97106 2010-05-13  Bruno Haible  <bruno@clisp.org>
97108         Avoid useless warnings from G++.
97109         * build-aux/c++defs.h (_GL_CXXALIASWARN_2, _GL_CXXALIASWARN1_2): Don't
97110         use _GL_WARN_ON_USE or _GL_WARN_ON_USE_CXX when optimizing.
97111         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
97113 2010-05-11  Jim Meyering  <meyering@redhat.com>
97115         maint.mk: tweak preceding change
97116         * top/maint.mk (gl_extract_significant_defines_): Make exclusion
97117         regexps tighter by anchoring at EOL, and make the new group "shy"
97118         for slightly decreased overhead.
97120 2010-05-11  Eric Blake  <eblake@redhat.com>
97122         maint.mk: gnulib doesn't guarantee NSIG
97123         * top/maint.mk (gl_extract_significant_defines_): Exclude NSIG.
97125 2010-05-10  Peter O'Gorman  <pogma@thewrittenword.com>
97127         test-pwrite.c: Remove unused variable declaration.
97128         * tests/test-pwrite.c (main): Remove read_buf declaration.
97130         Remove useless test-pwrite.sh file.
97131         * tests/test-pwrite.sh: Delete file.
97132         * modules/pwrite-tests: Remove references.
97133         Reported by Bruno Haible.
97135 2010-05-10  Peter O'Gorman  <pogma@thewrittenword.com>
97137         init.sh: fix a typo
97138         * tests/init.sh: Correct typo in MALLOC_PERTURB_ initialization.
97140 2010-05-10  Jim Meyering  <meyering@redhat.com>
97142         maint.mk: avoid using a temporary file in the always-defined-macros check
97143         * top/maint.mk (.re-defmac): Remove rule.
97144         (gl_trap_): Remove definition.
97145         (sc_prohibit_always-defined_macros): Rewrite not to create and
97146         depend on a temporary file.  Instead, depend on GNU grep's ability
97147         to read a list of regular expressions from stdin when given "-f -".
97149 2010-05-09  Bruno Haible  <bruno@clisp.org>
97151         Update to GNU gettext 0.18, part 1.
97152         * m4/gettext.m4: Update to GNU gettext 0.18.
97153         * m4/intl.m4: Likewise.
97154         * m4/po.m4: Likewise.
97155         * modules/gettext (Files): Add m4/fcntl-o.m4.
97156         (configure.ac): Require gettext infrastructure from version 0.18.
97158 2010-05-09  Jim Meyering  <meyering@redhat.com>
97160         init.sh: enable MALLOC_PERTURB_
97161         * tests/init.sh: Enable glibc's malloc-perturbing option.
97163         maint.mk: improve sc_cross_check_PATH_usage_in_tests
97164         With my recent change in init.sh from the two-line form:
97165             -#   : ${srcdir=.}
97166             -#   . "$srcdir/init.sh"; path_prepend_ .
97167             +#   . "${srcdir=.}/init.sh"; path_prepend_ .
97168         I noticed that using the one-line form would cause this test
97169         to fail with a false-positive, or to stop working altogether,
97170         depending on whether help-version changed or all the tests did.
97171         * top/maint.mk (_hv_regex): Remove this definition.
97172         (_hv_regex_weak): Use a weak regex to select all init.sh-sourcing files.
97173         (_hv_regex_strong): Use a stronger regex to check for conformance.
97174         (sc_cross_check_PATH_usage_in_tests): Rewrite to use the above.
97175         Give a separate diagnostic for lack of conforming use.
97177         maint.mk: prohibit definition of symbols defined by gnulib
97178         * top/maint.mk (sc_prohibit_always-defined_macros): Reject the
97179         definition of symbols defined by gnulib.
97181 2010-05-09  Bruno Haible  <bruno@clisp.org>
97183         acl: Avoid test failure on Cygwin-hosted mingw.
97184         * tests/test-set-mode-acl.sh: Skip test if USE_ACL is 0.
97186 2010-05-09  Bruno Haible  <bruno@clisp.org>
97188         error: Use system's fcntl function.
97189         * lib/error.c (fcntl): Undefine.
97191 2010-05-09  Jim Meyering  <meyering@redhat.com>
97193         verify: adjust formatting to be more consistent
97194         * lib/verify.h (_GL_GENSYM): Add a space before each of a few
97195         argument-list '('s, and after one comma.
97197 2010-05-09  Bruno Haible  <bruno@clisp.org>
97199         error: More reliable output on mingw.
97200         * lib/error.c: Include <windows.h>.
97201         (is_open): New function.
97202         (flush_stdout): Call it instead of fcntl, also if F_GETFL is not
97203         defined.
97205 2010-05-09  Bruno Haible  <bruno@clisp.org>
97207         vasnprintf: Fix syntax errors in libintl build on mingw.
97208         * lib/vasnprintf.c (VASNPRINTF): Move a closing brace. Undefine
97209         pad_ourselves and prec_ourselves after use.
97211 2010-05-08  Bruno Haible  <bruno@clisp.org>
97213         * lib/config.charset: Update comments for Cygwin 1.7.
97214         * lib/localcharset.c: Likewise.
97216 2010-05-07  Jim Meyering  <meyering@redhat.com>
97218         init.sh: improve comments
97219         * tests/init.sh: Recommend the one-line init.sh-sourcing idiom:
97220         . "${srcdir=.}/init.sh"; path_prepend_ .
97221         Add a note about path_prepend_ and the alternative of using
97222         TESTS_ENVIRONMENT.
97224 2010-05-06  Sergey Poznyakoff  <gray@gnu.org.ua>
97226         exclude: Unescape hashed patterns in wildcard mode.
97227         * lib/exclude.c (add_exclude): Unescape the pattern before adding it
97228         to the hash list.
97229         * tests/test-exclude8.sh: New test case.
97230         * modules/exclude-tests: Add new test.
97232 2010-05-05  Eric Blake  <eblake@redhat.com>
97234         verify: automate tests
97235         * modules/verify-tests: New module.
97236         * tests/test-verify.sh: New file.
97237         * tests/test-verify.c: Guard each negative test with a unique id.
97238         Also avoid warning about unused left hand of comma expressions.
97240 2010-05-05  Paul Eggert  <eggert@cs.ucla.edu>
97242         Further improvements to verify.h, suggested by Eric Blake.
97243         * lib/verify.h (_GL_CONCAT, _GL_CONCAT0, _GL_GENSYM): Renamed from
97244         the GL_* versions, to avoid collision with OpenGL.
97245         (_GL_COUNTER): New macro, so that we can fall back on __LINE__ if
97246         __COUNTER__ doesn't work.  Test that __COUNTER__ increments rather
97247         than testing merely whether it's defined.
97249         Modify verify.h to pacify gcc -Wredundant_decls.
97250         * lib/verify.h (GL_CONCAT, GL_CONCAT0, GL_GENSYM): New macros.
97251         These use the prefix "GL_" since they're likely to be useful elsewhere.
97252         We may need to break them out into a different .h file.
97253         (__COUNTER__): Define to 0 if the compiler doesn't support it.
97254         (verify) [!defined __cplusplus]: Use them to avoid duplicate decls
97255         of verify_function__.
97257 2010-05-05  Peter O'Gorman  <pogma@thewrittenword.com>
97259         Tests for module pwrite.
97260         * modules/pwrite-tests: New file.
97261         * tests/test-pwrite.sh: New file.
97262         * tests/test-pwrite.c: New file.
97264         New module pwrite.
97265         * lib/unistd.in.h (pwrite): New declaration.
97266         * lib/pwrite.c: New file, from glibc with modifications.
97267         * m4/pwrite.m4: New file.
97268         * m4/unistd_h.m4 (gl_UNISTD_H): Test whether pwrite is declared.
97269         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_PWRITE, HAVE_PWRITE,
97270         REPLACE_PWRITE.
97271         * modules/pwrite: New file.
97272         * modules/unistd (Makefile.am): Substitute GNULIB_PWRITE, HAVE_PWRITE,
97273         REPLACE_PWRITE.
97274         * tests/test-unistd-c++.cc: Check GNULIB_NAMESPACE::pwrite.
97275         * doc/posix-functions/pwrite.texi: Mention the new module.
97277 2010-05-05  Peter O'Gorman  <pogma@thewrittenword.com>
97279         pread: Update documentation.
97280         * doc/posix-functions/pread.texi: Mention the 'pread' module.
97282 2010-05-04  Eric Blake  <eblake@redhat.com>
97284         docs: update cygwin progress
97285         * doc/posix-functions/wctob.texi (wctob): Cygwin 1.7.6 will fix
97286         this bug.
97287         * doc/glibc-functions/get_nprocs_conf.texi (get_nprocs_conf):
97288         Added in cygwin 1.7.2.
97289         * doc/glibc-functions/get_phys_pages.texi (get_phys_pages):
97290         Likewise.
97291         * doc/glibc-functions/get_avphys_pages.texi (get_avphys_pages):
97292         Likewise.
97293         * doc/glibc-functions/dup3.texi (dup3): Likewise.
97294         * doc/glibc-functions/pipe2.texi (pipe2): Likewise.
97295         * doc/glibc-functions/accept4.texi (accept4): Likewise.
97296         * doc/posix-functions/strfmon.texi (strfmon): Likewise.
97297         * doc/glibc-functions/get_nprocs.texi (get_nprocs): Likewise.
97298         Mention nproc module.
97299         * doc/glibc-functions/xdr_uint16_t.texi (xdr_uint16_t): Mention
97300         bug in cygwin 1.7.5 addition.
97301         * doc/glibc-functions/xdr_uint32_t.texi (xdr_uint32_t): Likewise.
97302         * doc/glibc-functions/xdr_uint64_t.texi (xdr_uint64_t): Likewise.
97303         * doc/glibc-functions/xdr_uint8_t.texi (xdr_uint8_t): Likewise.
97304         * doc/glibc-functions/xdr_array.texi (xdr_array): Added in cygwin
97305         1.7.5.
97306         * doc/glibc-functions/xdr_bool.texi (xdr_bool): Likewise.
97307         * doc/glibc-functions/xdr_bytes.texi (xdr_bytes): Likewise.
97308         * doc/glibc-functions/xdr_char.texi (xdr_char): Likewise.
97309         * doc/glibc-functions/xdr_double.texi (xdr_double): Likewise.
97310         * doc/glibc-functions/xdr_enum.texi (xdr_enum): Likewise.
97311         * doc/glibc-functions/xdr_float.texi (xdr_float): Likewise.
97312         * doc/glibc-functions/xdr_free.texi (xdr_free): Likewise.
97313         * doc/glibc-functions/xdr_hyper.texi (xdr_hyper): Likewise.
97314         * doc/glibc-functions/xdr_int.texi (xdr_int): Likewise.
97315         * doc/glibc-functions/xdr_int16_t.texi (xdr_int16_t): Likewise.
97316         * doc/glibc-functions/xdr_int32_t.texi (xdr_int32_t): Likewise.
97317         * doc/glibc-functions/xdr_int64_t.texi (xdr_int64_t): Likewise.
97318         * doc/glibc-functions/xdr_int8_t.texi (xdr_int8_t): Likewise.
97319         * doc/glibc-functions/xdr_long.texi (xdr_long): Likewise.
97320         * doc/glibc-functions/xdr_longlong_t.texi (xdr_longlong_t):
97321         Likewise.
97322         * doc/glibc-functions/xdr_netobj.texi (xdr_netobj): Likewise.
97323         * doc/glibc-functions/xdr_opaque.texi (xdr_opaque): Likewise.
97324         * doc/glibc-functions/xdr_pointer.texi (xdr_pointer): Likewise.
97325         * doc/glibc-functions/xdr_reference.texi (xdr_reference):
97326         Likewise.
97327         * doc/glibc-functions/xdr_short.texi (xdr_short): Likewise.
97328         * doc/glibc-functions/xdr_sizeof.texi (xdr_sizeof): Likewise.
97329         * doc/glibc-functions/xdr_string.texi (xdr_string): Likewise.
97330         * doc/glibc-functions/xdr_u_char.texi (xdr_u_char): Likewise.
97331         * doc/glibc-functions/xdr_u_hyper.texi (xdr_u_hyper): Likewise.
97332         * doc/glibc-functions/xdr_u_int.texi (xdr_u_int): Likewise.
97333         * doc/glibc-functions/xdr_u_long.texi (xdr_u_long): Likewise.
97334         * doc/glibc-functions/xdr_u_longlong_t.texi (xdr_u_longlong_t):
97335         Likewise.
97336         * doc/glibc-functions/xdr_u_short.texi (xdr_u_short): Likewise.
97337         * doc/glibc-functions/xdr_union.texi (xdr_union): Likewise.
97338         * doc/glibc-functions/xdr_vector.texi (xdr_vector): Likewise.
97339         * doc/glibc-functions/xdr_void.texi (xdr_void): Likewise.
97340         * doc/glibc-functions/xdr_wrapstring.texi (xdr_wrapstring):
97341         Likewise.
97342         * doc/glibc-functions/xdrmem_create.texi (xdrmem_create):
97343         Likewise.
97344         * doc/glibc-functions/xdrrec_create.texi (xdrrec_create):
97345         Likewise.
97346         * doc/glibc-functions/xdrrec_endofrecord.texi
97347         (xdrrec_endofrecord): Likewise.
97348         * doc/glibc-functions/xdrrec_eof.texi (xdrrec_eof): Likewise.
97349         * doc/glibc-functions/xdrrec_skiprecord.texi (xdrrec_skiprecord):
97350         Likewise.
97351         * doc/glibc-functions/xdrstdio_create.texi (xdrstdio_create):
97352         Likewise.
97354 2010-05-04  Jim Meyering  <meyering@redhat.com>
97356         gendocs.sh: make its "-s FILE" option more useful
97357         * build-aux/gendocs.sh: When honoring the -s FILE option, update
97358         $PACKAGE to reflect the probably-different basename of "FILE".
97360 2010-05-03  Giuseppe Scrivano  <gscrivano@gnu.org>
97362         bootstrap: don't ignore download_po_files failure
97363         * build-aux/bootstrap (update_po_files): Don't ignore download_po_files
97364         failure.
97366 2010-05-03  Jim Meyering  <meyering@redhat.com>
97368         maint.mk: allow to pass options to gendocs.sh
97369         * top/maint.mk (web-manual): Pass gendocs_options_ to gendocs.sh.
97370         (gendocs_options_): New overridable variable.
97372         gnu-web-doc-update: don't ignore configure or build failure
97373         * build-aux/gnu-web-doc-update: Exit nonzero upon internal failure.
97375         announce-gen: backslash-escape '@'s in --help output
97376         * build-aux/announce-gen: Fix syntax errors.
97378         maint.mk, announce-gen: allow project-specific announcement mail headers
97379         * top/maint.mk (translation_project_): Define default.
97380         (announcement_Cc_, announcement_mail_headers_): Likewise.
97381         (announcement): Invoke announce-gen with new --mail-headers option.
97382         * build-aux/announce-gen: New option: --mail-headers=HEADERS.
97384         test-xalloc-die: avoid unwarranted test failure on OpenSolaris 5.11
97385         * tests/test-xalloc-die.sh: Redirect stdout before stderr, (i.e.,
97386         "> out 2> err", rather than "2> err > out").  Otherwise, with /bin/sh
97387         on OpenSolaris 5.11 snv_134, we would end up with a stray "1> out"
97388         line in the "err2" output file when running "make check" in verbose
97389         mode (i.e., with set -x enabled).
97391 2010-05-03  Bruno Haible  <bruno@clisp.org>
97393         wctob: Fix for weird platforms.
97394         * lib/wctob.c (wctob): When wint_t is larger than wchar_t, check the
97395         argument value.
97397 2010-05-03  Jim Meyering  <meyering@redhat.com>
97399         maint.mk: prohibit unwarranted use of <strings.h>
97400         * top/maint.mk (sc_prohibit_strings_without_use): Reject inclusion of
97401         strings.h in a file that does not also use strcasecmp, strncasecmp,
97402         ffs or ffsll.
97404         maint.mk: remove obsolete comments
97405         * top/maint.mk: Remove stale, commented-out rules.
97407 2010-05-02  Bruno Haible  <bruno@clisp.org>
97409         wcwidth: Declare also when it's aliased.
97410         * lib/wchar.in.h (wcwidth): Don't test whether wcwidth is defined as a
97411         macro.
97413 2010-05-02  Bruno Haible  <bruno@clisp.org>
97415         Fix regression from 2010-04-25.
97416         * gnulib-tool (func_modules_transitive_closure): Check the status of
97417         all modules, not only of the tests that are of the form foo-tests where
97418         foo is a module.
97420 2010-05-02  Bruno Haible  <bruno@clisp.org>
97422         wctob: Work around nasty Cygwin 1.7.2 bug.
97423         * m4/wctob.m4 (gl_FUNC_WCTOB): Detect the Cygwin bug.
97424         * doc/posix-functions/wctob.texi: Mention the Cygwin bug.
97426 2010-05-01  Bruno Haible  <bruno@clisp.org>
97428         fpurge: Sharper test.
97429         * tests/test-fpurge.c (main): Add one more ftell check.
97430         * modules/fpurge-tests (Depends-on): Add ftell.
97431         Suggested by Eric Blake.
97433 2010-05-01  Bruno Haible  <bruno@clisp.org>
97435         ftello: Another test.
97436         * tests/test-ftello3.c: New file.
97437         * modules/ftello-tests (Files): Add it.
97438         (Makefile.am): Add it to TESTS and check_PROGRAMS. Augment
97439         MOSTLYCLEANFILES.
97441         ftell: Another test.
97442         * tests/test-ftell3.c: New file.
97443         * modules/ftell-tests (Files): Add it.
97444         (Makefile.am): Add it to TESTS and check_PROGRAMS. Augment
97445         MOSTLYCLEANFILES.
97447 2010-05-01  Bruno Haible  <bruno@clisp.org>
97449         ftell, ftello: Work around Solaris bug.
97450         * m4/ftello.m4 (gl_FUNC_FTELLO): Detect Solaris bug.
97451         * lib/ftello.c: Include stdio-impl.h.
97452         (ftello): On Solaris, when _IOWRT is set, compute the result without
97453         looking at _IOREAD.
97454         * modules/ftello (Files): Add lib/stdio-impl.h.
97455         * doc/posix-functions/ftell.texi: Mention Solaris bug.
97456         * doc/posix-functions/ftello.texi: Likewise.
97457         Reported by Eric Blake.
97459 2010-05-01  Bruno Haible  <bruno@clisp.org>
97461         freading: Adapt to special meaning of _IOREAD flag on Solaris.
97462         * lib/freading.c (freading): On Solaris, ignore the _IOREAD flag if
97463         the _IOWRT flag is also set.
97465 2010-05-01  Bruno Haible  <bruno@clisp.org>
97467         Fix doc about a HP-UX stdio bug.
97468         * doc/posix-functions/ftell.texi: Mark HP-UX bug as unfixed.
97469         * doc/posix-functions/ftello.texi: Likewise.
97471 2010-05-01  Bruno Haible  <bruno@clisp.org>
97473         lseek test: Fix failure on Solaris.
97474         * tests/test-lseek.sh: Partially revert 2010-04-20 commit. Consume all
97475         output.
97477 2010-04-30  Jim Meyering  <meyering@redhat.com>
97479         bootstrap: don't ignore failure to generate po*/Makevars
97480         * build-aux/bootstrap (with_gettext): Don't ignore failure
97481         to create po/Makevars or runtime-po/Makevars.
97483 2010-04-29  Eric Blake  <eblake@redhat.com>
97485         headers: relax license to LGPLv2+
97486         * modules/fcntl-h (License): Relax license.
97487         * modules/getopt-posix (License): Likewise.
97488         * modules/locale (License): Likewise.
97489         * modules/math (License): Likewise.
97490         * modules/pty (License): Likewise.
97491         * modules/sched (License): Likewise.
97492         * modules/search (License): Likewise.
97493         * modules/spawn (License): Likewise.
97494         * modules/stdarg (License): Likewise.
97495         * modules/sysexits (License): Likewise.
97497 2010-04-29  Jim Meyering  <meyering@redhat.com>
97499         inttypes: relax license to LGPLv2+
97500         * modules/inttypes (License): Relax license.
97502 2010-04-29  Simon Josefsson  <simon@josefsson.org>
97504         * top/maint.mk (indent): Run twice to produce idempotent results.
97506 2010-04-28  Bruno Haible  <bruno@clisp.org>
97508         getdate: Generate getdate.c in the source directory.
97509         * modules/getdate (Makefile.am): Add rule for getdate.c. Augment
97510         MOSTLYCLEANFILES.
97511         Suggested by Daniel Richard G. <skunk@iskunk.org> and Ralf Wildenhues.
97513 2010-04-27  Andreas Gruenbacher  <agruen@suse.de>  (tiny change)
97515         * lib/utimens.c: On Tru64, the timestamp parameter of utimens(2)
97516         is not declared as a const *; avoid warnings in that case.
97518 2010-04-28  Eric Blake  <eblake@redhat.com>
97520         canonicalize-lgpl: avoid compiler warning
97521         * lib/canonicalize-lgpl.c (versioned_symbol): Avoid an 'empty
97522         declaration' / 'extraneous semicolon' warning with some compilers.
97523         Reported by Andreas Gruenbacher.
97525 2010-04-28  Jim Meyering  <meyering@redhat.com>
97527         init.sh: ensure a more reliable exit status when exiting via trap
97528         * tests/init.sh (setup_): Don't rely on $? in signal handler.
97529         Inspired by patches from Dmitry V. Levin.
97530         Also trap on signal 3 (SIGQUIT).
97532 2010-04-27  Bruno Haible  <bruno@clisp.org>
97534         Update doc about utimes().
97535         * doc/posix-functions/utimes.texi: Mention the OSF/1 problem and the
97536         'utimens' module.
97537         Reported by Andreas Gruenbacher <agruen@suse.de>.
97539 2010-04-27  Eric Blake  <eblake@redhat.com>
97541         full-read, full-write: relax license
97542         * modules/full-read (License): Drop to LGPLv2+.
97543         * modules/full-write (License): Likewise.
97544         * modules/safe-read (License): Likewise.
97545         * modules/safe-write (License): Likewise.
97547         pthread: mention library for linking
97548         * modules/pthread (Link): Mention $(LIB_PTHREAD).
97550 2010-04-27  Jim Meyering  <meyering@redhat.com>
97552         maint.mk: fix a bug introduced in last change
97553         * top/maint.mk (gl_assured_headers_): Now that all names are on
97554         one line, use sed's "g" modifier.  Note that while the \.in\.h LHS
97555         is not anchored to end of word, it should be adequate.
97557         maint.mk: avoid side-effect in latest syntax-check
97558         * top/maint.mk (sc_prohibit_always_true_header_tests): Rework not
97559         to run commands via $(shell...), and hence to incur cost only when
97560         the new rule is actually run.
97562         maint.mk: syntax-check: prohibit HAVE_<header>_H that are always true
97563         Derive the list of guaranteed header names from gnulib/lib/*.in.h,
97564         and use that to create a regexp used to detect all #if HAVE_..._H uses.
97565         * top/maint.mk (sc_prohibit_always_true_header_tests): New rule.
97566         (gl_assured_headers_, az_, AZ_): Define.
97567         (gl_header_upper_case_or_, gl_have_header_regex_): Define.
97569 2010-04-26  Jim Meyering  <jim@meyering.net>
97570             Bruno Haible  <bruno@clisp.org>
97572         gnulib-common.m4: make glibc write diagnostics to stderr, not /dev/tty
97573         * m4/gnulib-common.m4 (gl_COMMON_BODY): Set LIBC_FATAL_STDERR_.
97574         Prompted by an exchange with Gilles Espinasse.
97576 2010-04-26  Jim Meyering  <meyering@redhat.com>
97578         git-version-gen: aesthetic tweak
97579         * build-aux/git-version-gen: Use "$nl" rather than a literal,
97580         so that the command remains on a single line.
97582 2010-04-26  Eric Blake  <eblake@redhat.com>
97584         git-version-gen: allow use on EBCDIC hosts
97585         * build-aux/git-version-gen (dirty): Use literal rather than tying
97586         ourselves to ascii.
97587         Reported by Steve Goetze.
97589 2010-04-25  Bruno Haible  <bruno@clisp.org>
97591         netdb: Add support for GNULIB_POSIXCHECK.
97592         * lib/netdb.in.h: Include warn-on-use.h.
97593         (getaddrinfo, freeaddrinfo, gai_strerror, getnameinfo): Warn if these
97594         functions are used when GNULIB_POSIXCHECK is defined and the
97595         getaddrinfo module is not in use.
97596         * m4/netdb_h.m4 (gl_HEADER_NETDB): Test whether getaddrinfo,
97597         freeaddrinfo, gai_strerror, getnameinfo are declared.
97598         * modules/netdb (Depends-on): Add warn-on-use.
97599         (Makefile.am): Include warn-on-use.h in netdb.h.
97601 2010-04-24  Ian Beckwith  <ianb@erislabs.net>
97603         build: avoid "make check" failure without .git/ directory
97604         * Makefile (sc_prefer_ac_check_funcs_once): Skip this test when
97605         there is no .git/ directory.
97607 2010-04-25  Bruno Haible  <bruno@clisp.org>
97609         ptsname: Fix misuse of ttyname_r.
97610         * lib/ptsname.c (__ptsname_r): Use __ttyname_r's return value instead
97611         of errno.
97613 2010-04-25  Bruno Haible  <bruno@clisp.org>
97615         ttyname_r: Make it work on Solaris 10.
97616         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Define HAVE_POSIXDECL_TTYNAME_R
97617         if the system function has the POSIX declaration. Test whether the
97618         function fails if the buffer is less than 128 bytes large.
97619         * lib/ttyname_r.c (ttyname_r): Handle both possible declarations of the
97620         system's ttyname_r function. Provide a reasonably large buffer.
97621         * modules/ttyname_r (Depends-on): Add extensions.
97622         * doc/posix-functions/ttyname_r.texi: Mention the Solaris problem.
97624 2010-04-25  Bruno Haible  <bruno@clisp.org>
97626         Use the 'extensions' module for some more functions on Solaris.
97627         * doc/posix-functions/asctime_r.texi: Recommend to use the 'extensions'
97628         module.
97629         * doc/posix-functions/ctime_r.texi: Likewise.
97630         * doc/posix-functions/getgrgid_r.texi: Likewise.
97631         * doc/posix-functions/getgrnam_r.texi: Likewise.
97632         * doc/posix-functions/getpwnam_r.texi: Likewise.
97633         * doc/posix-functions/getpwuid_r.texi: Likewise.
97634         * doc/posix-functions/readdir_r.texi: Likewise.
97635         * doc/posix-functions/sigwait.texi: Likewise.
97636         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Add comment.
97637         * doc/posix-functions/getlogin_r.texi: Mark Solaris problem as fixed.
97639 2010-04-25  Bruno Haible  <bruno@clisp.org>
97641         ttyname_r: Make it work on MacOS X 10.4 and Solaris 10.
97642         * m4/ttyname_r.m4 (gl_FUNC_TTYNAME_R): Test whether the system function
97643         has the POSIX declaration. Set REPLACE_TTYNAME_R if not.
97644         * lib/ttyname_r.c: Include <limits.h>.
97645         (ttyname_r): Define using the system's ttyname_r function, if it exists
97646         and not on Solaris.
97647         * lib/unistd.in.h (ttyname_r): Replace function if REPLACE_TTYNAME_R is
97648         set.
97649         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize REPLACE_TTYNAME_R.
97650         * modules/unistd (Makefile.am): Substitute REPLACE_TTYNAME_R.
97651         * doc/posix-functions/ttyname_r.texi: Mark the problem as fixed.
97652         Reported by Simon Josefsson.
97654 2010-04-25  Bruno Haible  <bruno@clisp.org>
97656         Mention effects of _POSIX_PTHREAD_SEMANTICS on Solaris.
97657         * doc/posix-functions/asctime_r.texi: Mention the Solaris problem.
97658         * doc/posix-functions/ctime_r.texi: Likewise.
97659         * doc/posix-functions/getgrgid_r.texi: Likewise.
97660         * doc/posix-functions/getgrnam_r.texi: Likewise.
97661         * doc/posix-functions/getlogin_r.texi: Likewise.
97662         * doc/posix-functions/getpwnam_r.texi: Likewise.
97663         * doc/posix-functions/getpwuid_r.texi: Likewise.
97664         * doc/posix-functions/readdir_r.texi: Likewise.
97665         * doc/posix-functions/sigwait.texi: Likewise.
97666         * doc/posix-functions/ttyname_r.texi: Likewise.
97667         Reported by Simon Josefsson.
97669 2010-04-25  Bruno Haible  <bruno@clisp.org>
97671         gnulib-tool: Don't include hairy tests of dependencies in testdirs.
97672         * gnulib-tool (func_usage): Document that --with-*-tests options apply
97673         also to --create-testdir.
97674         (func_acceptable): Don't consider the status of *-tests modules here.
97675         (func_modules_transitive_closure): Consider it here, before including a
97676         test module.
97677         (func_import, func_create_testdir): Set inc_all_direct_tests,
97678         inc_all_indirect_tests.
97679         * doc/gnulib.texi (Extra tests modules): Document new behaviour of
97680         --create-testdir and --create-megatestdir.
97682 2010-04-25  Bruno Haible  <bruno@clisp.org>
97684         gnulib-tool: Add --without-*-tests options.
97685         * gnulib-tool (func_usage): Document the --without-*-tests options.
97686         (excl_cxx_tests, excl_longrunning_tests, excl_privileged_tests,
97687         excl_unportable_tests): New variables.
97688         Fail if they are specified with --import or --update.
97689         (func_acceptable): Respect the excl_*_tests variables.
97690         (func_import): Set the excl_*_tests variables to empty.
97692 2010-04-25  Simon Josefsson  <simon@josefsson.org>
97693             Bruno Haible  <bruno@clisp.org>
97695         Work around a MacOS X 10.4 bug with openpty.
97696         * doc/glibc-functions/openpty.texi: Mention the MacOS X 10.4 bug.
97697         * tests/test-openpty.c (main): Close the master side explicitly.
97699 2010-04-25  Bruno Haible  <bruno@clisp.org>
97701         strnlen: Fix a C++ test error on MacOS X and Solaris.
97702         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Don't set REPLACE_STRNLEN to 1 if
97703         the function is not declared.
97704         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com> and
97705         Simon Josefsson.
97707 2010-04-24  Bruno Haible  <bruno@clisp.org>
97709         Avoid a gcc warning.
97710         * tests/test-vasprintf.c (test_vasprintf, test_asprintf): Pass argument
97711         of correct type for %08lx directive.
97712         Reported by Eric Blake.
97714 2010-04-24  Bruno Haible  <bruno@clisp.org>
97716         vasnprintf: Correct errno value in case of out-of-memory.
97717         * lib/vasnprintf.c (VASNPRINTF): Set errno to 0 before calling SNPRINTF
97718         or sprintf. Use the errno value from SNPRINTF or sprintf.
97719         Reported by Ian Beckwith <ianb@erislabs.net>.
97721 2010-04-24  Bruno Haible  <bruno@clisp.org>
97723         ansi-c++-opt: Find correct compiler when cross-compiling.
97724         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): Use AC_CHECK_TOOLS instead of
97725         AC_CHECK_PROGS.
97726         Reported by Simon Josefsson.
97728 2010-04-24  Giuseppe Scrivano  <gscrivano@gnu.org>
97730         vc-list-files: Add support for subversion
97731         * build-aux/vc-list-files: Use "svn list" to generate the list of
97732         files controlled by subversion.
97734 2010-04-23  Jim Meyering  <meyering@redhat.com>
97736         vc-list-files tests: convert to use init.sh
97737         * tests/test-vc-list-files-cvs.sh: Invoke "$srcdir/init.sh" and
97738         path_prepend_.
97739         Use Exit, not exit.
97740         Use skip_ rather than open coding it.
97741         Remove trap set-up and compare definitions.
97742         * tests/test-vc-list-files-git.sh: Likewise.
97743         * modules/vc-list-files-tests (Files): Add tests/init.sh.
97745 2010-04-22  Simon Josefsson  <simon@josefsson.org>
97747         * top/maint.mk (sc_prohibit_backup_files): Prohibit checked in
97748         backup files.
97750 2010-04-21  Simon Josefsson  <simon@josefsson.org>
97752         * tests/test-vasprintf.c (test_vasprintf, test_asprintf): Test %08lx.
97754 2010-04-20  Eric Blake  <eblake@redhat.com>
97756         tests: be robust to ignored SIGPIPE
97757         * tests/test-select-in.sh: Consume all output.
97758         * tests/test-lseek.sh: Check correct exit status, while avoiding
97759         EPIPE.
97761 2010-04-20  Simon Josefsson  <simon@josefsson.org>
97762             Bruno Haible  <bruno@clisp.org>
97764         visibility: Don't use -fvisibility if it leads to a warning.
97765         * m4/visibility.m4 (gl_VISIBILITY): Check whether -Werror is usable. If
97766         yes, don't pretend that visibility works if it leads to a warning.
97767         Reported by Mike Gran <spk121@yahoo.com>.
97769 2010-04-20  Andreas Gruenbacher  <agruen@suse.de>
97771         * build-aux/bootstrap: Use "git -h" for testing for supported options
97772         instead of "git --help".  The short-form option only shows a summary,
97773         and doesn't layout the full man page.  Grep for the full option name
97774         in the summary, too.
97776 2010-04-19  Bruno Haible  <bruno@clisp.org>
97778         relocatable: Drop the need to define RELOCATABLE_STRIP in Makefile.am.
97779         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Set RELOCATABLE_STRIP.
97780         * doc/relocatable-maint.texi (Supporting Relocation): Remove the
97781         mention of RELOCATABLE_STRIP.
97782         Reported by Sylvain Beucler <beuc@beuc.net>.
97784 2010-04-19  Bruno Haible  <bruno@clisp.org>
97786         * lib/diffseq.h: Fix typo in comment.
97787         Reported by Eric Blake.
97789 2010-04-19  Bruno Haible  <bruno@clisp.org>
97791         ioctl: Move autoconf macro to a .m4 file.
97792         * m4/ioctl.m4: New file, extracted from modules/ioctl.
97793         * modules/ioctl (Files): Add it.
97794         (configure.ac): Simply invoke gl_FUNC_IOCTL.
97795         Reported by Ian Beckwith <ianb@erislabs.net>.
97797 2010-04-18  Andreas Gruenbacher  <agruen@suse.de>
97798             Bruno Haible  <bruno@clisp.org>
97800         diffseq: Accommodate use-case with abstract arrays.
97801         * lib/diffseq.h (struct context): Remove xvec, yvec fields if ELEMENT
97802         is not defined.
97803         (diag, compareseq): Remove local variables xv, yv if ELEMENT is not
97804         defined. Use local macro XREF_YREF_EQUAL instead of EQUAL.
97806 2010-04-18  Bruno Haible  <bruno@clisp.org>
97808         * doc/posix-headers/stdbool.texi: More precise wording.
97810 2010-04-17  Jim Meyering  <meyering@redhat.com>
97812         maint.mk: use gnu-style indentation in an embedded perl script
97813         * top/maint.mk (detect_empty_lines_at_EOF_): Clean up formatting.
97814         Rename variable: s/two/last_two_bytes/
97816 2010-04-16  Eric Blake  <eblake@redhat.com>
97818         test-stdbool: skip test that fails with Solaris CC
97819         * tests/test-stdbool.c (f): Skip test that causes compilation
97820         error under buggy C++ compiler.
97821         * lib/stdbool.in.h: Document the limitation.
97822         * doc/posix-headers/stdbool.texi (stdbool.h): Likewise.
97824         setenv: allow compilation with C++
97825         * lib/setenv.c (__add_to_environ): Add a cast.  Also, drop use of
97826         register keyword.
97828         stdint: allow test to pass with C++
97829         * tests/test-stdint.c: Define __STDC_CONSTANT_MACROS, for glibc.
97831         getopt: allow compilation with C++
97832         * lib/getopt_int.h (__ordering): Hoist enum declaration outside
97833         struct.
97834         * lib/getopt.c (_getopt_internal_r): Use correct type.
97835         Reported by Dagobert Michelson, via Joel E. Denny.
97837 2010-04-16  Bruno Haible  <bruno@clisp.org>
97839         Override netdb.h always.
97840         * modules/netdb (Makefile.am): Augment BUILT_SOURCES always.
97841         * m4/netdb_h.m4 (gl_HEADER_NETDB): Don't set NETDB_H.
97842         Reported by Ludovic Courtès <ludo@gnu.org>.
97844 2010-04-15  Bruno Haible  <bruno@clisp.org>
97846         openpty: Fix mistake from 2010-03-21.
97847         * m4/pty.m4 (gl_FUNC_OPENPTY): Define HAVE_OPENPTY when openpty exists.
97848         Reported by Simon Josefsson.
97850 2010-04-15  Eric Blake  <eblake@redhat.com>
97852         test-forkpty: fix expected signature
97853         * tests/test-forkpty.c (SIGNATURE_CHECK): Add appropriate const.
97854         Reported by Simon Josefsson.
97856 2010-04-15  Jim Meyering  <meyering@redhat.com>
97858         maint.mk: texinfo_suffix_re_: correct the default regexp
97859         * top/maint.mk (texinfo_suffix_re_): Fix default regexp.
97861         * top/maint.mk (sc_texinfo_acronym): Improve filename regexp, and
97862         make it configurable via texinfo_suffix_re_.
97864 2010-04-14  Eric Blake  <eblake@redhat.com>
97866         strtok_r: relax license to LGPLv2+
97867         * modules/strtok_r (License): Relax license.
97868         Reported by Matthias Bolte.
97870 2010-04-14  Simon Josefsson  <simon@josefsson.org>
97872         * lib/gc-libgcrypt.c (gc_init): Use MIN_GCRYPT_VERSION set to
97873         version 1.4.4 by default instead of requiring the libgcrypt
97874         version used during build.  This makes it possible to use the
97875         application with older but still binary compatible libgcrypt
97876         versions.
97878 2010-04-13  Eric Blake  <eblake@redhat.com>
97880         getopt-gnu: match recent glibc fixes and posix ruling
97881         * tests/test-getopt.h (test_getopt): Strengthen tests of leading
97882         '+' handling, when requesting extensions.
97883         * tests/test-getopt_long.h (test_getopt_long): Strengthen test of
97884         'W;' handling.
97885         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Detect glibc 2.11 bug.
97886         * doc/posix-functions/getopt.texi (getopt): Document this.
97887         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
97888         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
97889         Likewise.
97891         getopt: merge bug fixes from glibc
97892         * lib/getopt.c (_getopt_internal_r): Use correct message for 'W;'
97893         diagnostics.  Honor '+:' correctly.  Reject ';'.
97895         getopt-posix: detect MacOS bug
97896         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Reject MacOS botch of
97897         optind when missing a required argument.
97898         * doc/posix-functions/getopt.texi (getopt): Document the bug.
97899         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
97900         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
97901         Likewise.
97903         getopt-posix: avoid spurious failure on Solaris
97904         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Check for getopt_clip as
97905         an indicator that setting optind=1 is sufficient for reset.
97907         getopt-posix: avoid spurious failure on FreeBSD
97908         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Check for optreset even
97909         in POSIX mode, since the m4 test uses it.
97911         gnulib-tool: silence warning on BSD sh
97912         * gnulib-tool: Avoid leaking warning about unknown 'declare'.
97914 2010-04-13  Jim Meyering  <meyering@redhat.com>
97916         doc: users.txt: GNU patch now uses gnulib
97917         * users.txt: Add patch.
97919 2010-04-12  Jim Meyering  <meyering@redhat.com>
97921         maint.mk: generate more concise timing data for syntax-check rules
97922         * top/maint.mk ($(sc_z_rules_)): Remove the ":", "sc_" prefix and
97923         " done" from each line that reports a syntax-check test duration.
97925 2010-04-12  Andreas Gruenbacher  <agruen@suse.de>
97927         git-version-gen: use "git update-index..." rather than "git status"
97928         * build-aux/git-version-gen: Use git update-index --refresh, not
97929         "git status".  With some versions of git, "git status" would fail
97930         to update the index and result in an unwarranted "-dirty" suffix.
97932 2010-04-11  Jim Meyering  <meyering@redhat.com>
97934         openat: correct formatting (no semantic change)
97935         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Correct formatting in AC_DEFINE.
97936         Suggested by Bruno Haible.
97938 2010-04-11  Bruno Haible  <bruno@clisp.org>
97940         Stricter declaration checking in testdirs.
97941         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
97942         If for_tests is true, augment AM_CPPFLAGS to define
97943         GNULIB_STRICT_CHECKING.
97944         * build-aux/warn-on-use.h (_GL_WARN_ON_USE, _GL_WARN_ON_USE_CXX): When
97945         GNULIB_STRICT_CHECKING is defined, verify that the function is
97946         declared.
97948 2010-04-11  Paolo Bonzini  <bonzini@gnu.org>
97949             Bruno Haible  <bruno@clisp.org>
97951         libunistring: Improve configure output.
97952         * m4/libunistring.m4 (gl_LIBUNISTRING): Check for libiconv first.
97953         Don't say "consider installing GNU libunistring" when checking again
97954         with libiconv.
97956 2010-04-11  Bruno Haible  <bruno@clisp.org>
97958         libunistring: Correct value of $LTLIBUNISTRING.
97959         * m4/libunistring.m4 (gl_LIBUNISTRING): When it depends on libiconv,
97960         correct the value of $LTLIBUNISTRING.
97962 2010-04-11  Bruno Haible  <bruno@clisp.org>
97964         havelib: Add static libraries to LIBS in the right order.
97965         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): When $LIB[]NAME contains no
97966         -l options, prepend it to $LIBS, instead of appending it to $LIBS.
97968 2010-04-11  Bruno Haible  <bruno@clisp.org>
97970         libunistring: Detect libunistring also when it depends on libiconv.
97971         * m4/libunistring.m4 (gl_LIBUNISTRING): Unset the cached result before
97972         the second AC_LIB_HAVE_LINKFLAGS invocation.
97974 2010-04-11  James Youngman  <jay@gnu.org>
97976         close-stream: declare local scalars to be "const"
97977         * lib/close-stream.c (close_stream): Make boolean variables const
97978         to document the fact that we set but do not change them.
97980 2010-04-11  Bruno Haible  <bruno@clisp.org>
97982         * m4/libunistring.m4 (gl_LIBUNISTRING): Fix typo in comment.
97984 2010-04-11  Jim Meyering  <meyering@redhat.com>
97986         maint.mk: don't include dist-check.mk
97987         * top/maint.mk: Remove bogus include directive.
97989         maint.mk: improve empty-line-at-EOF check
97990         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Use Perl-based
97991         solution, rather than tail+Perl-based one.  The latter would read
97992         a few kilobytes from the end of each file, and did not handle empty
97993         files properly.
97995         maint.mk: print the elapsed time for each syntax-check rule
97996         * top/maint.mk (sc_m_rules_): Save start time in a file.
97997         (sc_z_rules_): New rules: remove temp file and print elapsed time.
97998         (local-check): Interpose the .z rules
98000 2010-04-11  Jim Meyering  <meyering@redhat.com>
98002         maint.mk: detect_empty_lines_at_EOF_: avoid FP for an empty file
98003         * top/maint.mk (detect_empty_lines_at_EOF_): Don't confuse an
98004         empty file with one that ends in an empty line.
98006 2010-04-10  Bruno Haible  <bruno@clisp.org>
98008         mkdir: Make it work on mingw64.
98009         * lib/sys_stat.in.h: Include <direct.h> together with <io.h>.
98010         * lib/mkdir.c: Update comment.
98011         Reported by Roman Donchenko (Роман Донченко) <dxdragon@yandex.ru>.
98013 2010-04-10  Bruno Haible  <bruno@clisp.org>
98015         Don't override improved macro from newer autoconf.
98016         * m4/gnulib-common.m4 (AC_C_RESTRICT): Don't define for
98017         autoconf >= 2.62.
98018         Reported by Joel E. Denny <jdenny@clemson.edu>.
98020 2010-04-10  Jim Meyering  <meyering@redhat.com>
98022         maint.mk: new syntax-check rule: prohibit empty lines at end of file
98023         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): New rule.
98025         maint.mk: correct a diagnostic
98026         * top/maint.mk (sc_prohibit_HAVE_MBRTOWC): Fix obsolete use of $re
98027         in diagnostic; now use $prohibit.
98029 2010-04-10  Bruno Haible  <address@hidden>
98031         fchownat: Fix a C++ test error on Solaris 8.
98032         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Don't set REPLACE_FCHOWNAT to 1 if
98033         the function does not exist.
98035 2010-04-10  Bruno Haible  <bruno@clisp.org>
98037         vasnprintf: Add more tests.
98038         * tests/test-vasnprintf-posix.c: Include <errno.h>.
98039         (test_function): Test converting an invalid wide string.
98041         vasnprintf: Correct handling of unconvertible wide string arguments.
98042         * lib/vasnprintf.c (MAX_ROOM_NEEDED): New function, extracted from
98043         VASNPRINTF.
98044         (VASNPRINTF): Use it. After snprintf failed, allocate more memory only
98045         if HAVE_SNPRINTF_RETVAL_C99 is false and the allocated memory is
98046         smaller than the expected maximum need for the directive. Set errno to
98047         EILSEQ, not EINVAL, when the directive is 'c' or 's'.
98048         (local_strnlen, local_wcslen, local_wcsnlen): Update conditions.
98049         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Require AC_C_INLINE and
98050         gl_SNPRINTF_RETVAL_C99. Define HAVE_SNPRINTF_RETVAL_C99.
98051         * modules/vasnprintf (Files): Add m4/printf.m4.
98052         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
98054 2010-04-10  Bruno Haible  <bruno@clisp.org>
98056         vasnprintf: Fix crash in %ls directive.
98057         * lib/vasnprintf.c (VASNPRINTF): Don't abort when a unconvertible wide
98058         string is passed as argument to %ls, with no precision and no width.
98059         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
98061 2010-04-10  Bruno Haible  <bruno@clisp.org>
98063         vasnprintf: Fix multiple test failures on mingw.
98064         * lib/vasnprintf.c (SNPRINTF) [mingw]: Define to snprintf, not
98065         _snprintf, or snwprintf, not _snwprintf.
98067 2010-04-10  Bruno Haible  <bruno@clisp.org>
98069         write: Fix a C++ test error on mingw.
98070         * lib/unistd.in.h (write): Use _GL_CXXALIAS_SYS_CAST.
98072 2010-04-10  Bruno Haible  <bruno@clisp.org>
98074         vasnprintf test: Reduce code duplication.
98075         * tests/test-vasnprintf.c (test_function): New function, extracted from
98076         test_vasnprintf.
98077         (test_vasnprintf, test_asnprintf): Invoke it.
98079 2010-04-10  Bruno Haible  <bruno@clisp.org>
98081         strnlen: Fix warning in C++ mode on MacOS X.
98082         * lib/string.in.h (strnlen): Use the modern idiom.
98083         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set REPLACE_STRNLEN to 1, instead of
98084         defining strnlen as a macro already in <config.h>.
98085         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
98086         REPLACE_STRNLEN.
98087         * modules/string (Makefile.am): Substitute REPLACE_STRNLEN.
98088         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
98090 2010-04-08  James Youngman  <jay@gnu.org>
98092         * doc/manywarnings.texi (manywarnings): Add missing parenthesis in
98093         the example.
98095 2010-04-09  Jim Meyering  <meyering@redhat.com>
98097         maint.mk: print better diagnostic when there is no $(_hv_file)
98098         * top/maint.mk (sc_cross_check_PATH_usage_in_tests): Skip test and
98099         announce that when $(_hv_file) (aka help-version) does not exist.
98101         init.sh: run tr in the "C" locale to avoid multibyte interpretation
98102         * tests/init.sh (rand_bytes_): Run tr in the "C" locale so it does
98103         not try to interpret its random input bytes.  Jarno Rajahalme reported
98104         that ./test-xalloc-die.sh would fail with "tr: Illegal byte sequence".
98105         on Darwin 10.3.0 with LC_CTYPE=UTF-8.
98106         (mktempd_): Likewise, just in case.
98108         ftruncate: add two years to projected module removal date: 2012
98109         * m4/ftruncate.m4: Adjust comments.
98111         ftruncate: mark module as obsolete; even MinGW provides it, now
98112         * modules/ftruncate (Status): Obsolete.
98113         (Notice): Say that.
98114         * doc/posix-functions/ftruncate.texi: Don't say MinGW lacks it.
98115         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/9203
98117 2010-04-08  Bruno Haible  <bruno@clisp.org>
98119         Fix side effects from tests-related modules.
98120         * modules/dprintf-posix (Comment): New section.
98121         * modules/fprintf-posix (Comment): Likewise.
98122         * modules/obstack-printf-posix (Comment): Likewise.
98123         * modules/printf-posix (Comment): Likewise.
98124         * modules/snprintf-posix (Comment): Likewise.
98125         * modules/sprintf-posix (Comment): Likewise.
98126         * modules/vasnprintf-posix (Comment): Likewise.
98127         * modules/vasprintf-posix (Comment): Likewise.
98128         * modules/vdprintf-posix (Comment): Likewise.
98129         * modules/vfprintf-posix (Comment): Likewise.
98130         * modules/vprintf-posix (Comment): Likewise.
98131         * modules/vsnprintf-posix (Comment): Likewise.
98132         * modules/vsprintf-posix (Comment): Likewise.
98133         * modules/xprintf-posix (Comment): Likewise.
98134         * modules/xvasprintf-posix (Comment): Likewise.
98135         * modules/ceilf-tests (Depends-on): Remove fprintf-posix.
98136         * modules/floorf-tests (Depends-on): Likewise.
98137         * modules/round-tests (Depends-on): Likewise.
98138         * modules/roundf-tests (Depends-on): Likewise.
98139         * modules/trunc-tests (Depends-on): Likewise.
98140         * modules/truncf-tests (Depends-on): Likewise.
98141         * tests/test-ceilf2.c (check): Don't invoke fprintf if the
98142         'fprintf-posix' module is not present.
98143         * tests/test-floorf2.c (check): Likewise.
98144         * tests/test-trunc2.c (check): Likewise.
98145         * tests/test-truncf2.c (check): Likewise.
98146         * tests/test-round2.c (equal): Likewise.
98147         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
98149 2010-04-07  Karl Berry  <karl@gnu.org>
98151         * config/srclist.txt,
98152         * config/srclistvars.sh,
98153         * config/srclist-update: doc fixes.
98155 2010-04-07  Jim Meyering  <meyering@redhat.com>
98157         maint.mk: add a PATH crosschecking syntax-check rule
98158         * top/maint.mk (sc_cross_check_PATH_usage_in_tests): New rule.
98159         Useful if you use a test like the one in help-version (coreutils,
98160         diffutils, grep, gzip) that ensures $(VERSION) matches what is
98161         printed by prog --version.
98163 2010-04-06  Bruno Haible  <bruno@clisp.org>
98165         Fix link error on mingw.
98166         * modules/unistd-c++-tests (test_unistd_c___LDADD): Add LIBSOCKET.
98167         * modules/fcntl-h-c++-tests (test_fcntl_h_c___LDADD): Likewise.
98169 2010-04-06  Bruno Haible  <bruno@clisp.org>
98171         Assume rmdir exists.
98172         * lib/rmdir.c (rpl_rmdir): Remove code that invokes the rmdir program.
98174 2010-04-06  Giuseppe Scrivano  <gscrivano@gnu.org>
98176         doc: update users.txt
98177         * users.txt: Add gcal.
98179 2010-04-06  Jim Meyering  <meyering@redhat.com>
98181         init.sh: simply unset TMPDIR rather than risking env -i
98182         * tests/init.sh (mktempd_): Using env -i is rather harsh, and
98183         although it probably works fine on all Unix-based systems, some
98184         systems (Cygwin?) cannot tolerate a totally cleared environment.
98185         Suggestion from Eric Blake.
98187 2010-04-06  Jim Meyering  <meyering@redhat.com>
98189         init.sh: portability fix: use env's POSIX-specified -i option not -u
98190         * tests/init.sh (mktempd_): Use env -i and set PATH explicitly rather
98191         than unportable env -u.  Solaris 5.11's env lacks support for -u.
98193 2010-04-05  Bruno Haible  <bruno@clisp.org>
98195         btowc: Work around Cygwin 1.7.2 bug.
98196         * m4/btowc.m4 (gl_FUNC_BTOWC): Set REPLACE_BTOWC to 1 if the function
98197         does not map NUL to 0.
98198         * doc/posix-functions/btowc.texi: Mention the Cygwin bug.
98200 2010-04-05  Bruno Haible  <bruno@clisp.org>
98202         Make the multithread modules work on Cygwin 1.7.2.
98203         * m4/threadlib.m4 (gl_THREADLIB_BODY): Improve the test whether
98204         imported symbols can be declared weak, so that it returns "no" on
98205         Cygwin 1.7.2.
98207 2010-04-05  Bruno Haible  <bruno@clisp.org>
98209         Use the module 'strncat'.
98210         * modules/unistr/u8-strncat (Depends-on): Add strncat.
98212         Tests for module 'strncat'.
98213         * modules/strncat-tests: New file.
98214         * tests/test-strncat.c: New file.
98216         New module 'strncat'.
98217         * lib/string.in.h (strncat): New declaration.
98218         * lib/strncat.c: New file, based on lib/unistr/u-strncat.h.
98219         * m4/strncat.m4: New file, based on m4/memchr.m4.
98220         * modules/strncat: New file.
98221         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Also check whether strncat
98222         is declared.
98223         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_STRNCAT,
98224         REPLACE_STRNCAT.
98225         * modules/string (Makefile.am): Substitute GNULIB_STRNCAT,
98226         REPLACE_STRNCAT.
98227         * doc/posix-functions/strncat.texi: Mention the Solaris bug and the new
98228         module.
98229         * tests/test-string-c++.cc: Check signature of strncat.
98231 2010-04-05  Jim Meyering  <meyering@redhat.com>
98233         xstrtoumax-tests: convert to use init.sh
98234         * modules/xstrtoumax-tests (Files): Add tests/init.sh.
98235         * tests/test-xstrtoumax.sh: Invoke "$srcdir/init.sh" and path_prepend_.
98236         Use Exit, not exit.
98237         Remove uses of $EXEEXT and "./" to run a program in the current dir.
98239         xstrtoimax-tests: convert to use init.sh
98240         * modules/xstrtoimax-tests (Files): Add tests/init.sh.
98241         * tests/test-xstrtoimax.sh: Invoke "$srcdir/init.sh" and path_prepend_.
98242         Use Exit, not exit.
98243         Remove uses of $EXEEXT and "./" to run a program in the current dir.
98245 2010-04-05  Bruno Haible  <bruno@clisp.org>
98247         sys_socket: Avoid #define replacements in C++ mode.
98248         * lib/sys_socket.in.h (close, gethostname, select): In C++, attach a
98249         warning to the function if possible, rather than #defining the symbol
98250         to a dysfunctional alias.
98252 2010-04-05  Bruno Haible  <bruno@clisp.org>
98254         fseeko: Fix C++ test error on mingw.
98255         * m4/fseeko.m4 (gl_HAVE_FSEEKO): New macro, extracted from
98256         gl_FUNC_FSEEKO.
98257         (gl_REPLACE_FSEEKO): Also set REPLACE_FSEEKO if appropriate.
98258         (gl_FUNC_FSEEKO): Require gl_HAVE_FSEEKO. Update.
98259         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't fiddle with internals of the
98260         fseeko module. Instead, invoke gl_REPLACE_FSEEKO.
98262 2010-04-05  Bruno Haible  <bruno@clisp.org>
98264         duplocale: Improve test output.
98265         * tests/test-duplocale.c (main): Print reason for skipped test.
98267 2010-04-05  Bruno Haible  <bruno@clisp.org>
98269         Assume rmdir exists.
98270         * m4/rmdir.m4 (gl_FUNC_RMDIR): Remove test whether rmdir exists.
98271         * doc/posix-functions/rmdir.texi: Remove mention of "old platforms".
98273 2010-04-05  Bruno Haible  <bruno@clisp.org>
98275         Fix link error on Solaris 8 with cc.
98276         * modules/pty-c++-tests (test_pty_c___LDADD): Add LIBINTL.
98278 2010-04-05  Bruno Haible  <bruno@clisp.org>
98280         frexpl: Fix a C++ test error on Solaris 8 and Cygwin.
98281         * lib/math.in.h (frexpl): Fix condition on _GL_CXXALIASWARN invocation.
98283 2010-04-05  Bruno Haible  <bruno@clisp.org>
98285         vasprintf: Update documentation.
98286         * doc/glibc-functions/asprintf.texi: Mention the 'vasprintf' module.
98288 2010-04-05  Bruno Haible  <bruno@clisp.org>
98290         ptsname: Improve test.
98291         * tests/test-ptsname.c (main): Also try the various master names of BSD
98292         systems.
98294 2010-04-05  Bruno Haible  <bruno@clisp.org>
98296         memchr: Avoid a possible C++ test error.
98297         * lib/string.in.h (memchr): Provide declaration if function is missing.
98298         * m4/memchr.m4 (gl_FUNC_MEMCHR): If the function is missing, set
98299         HAVE_MEMCHR to 0, not REPLACE_MEMCHR to 1.
98300         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize HAVE_MEMCHR.
98301         * modules/string (Makefile.am): Substitute HAVE_MEMCHR.
98303 2010-04-05  Bruno Haible  <bruno@clisp.org>
98305         strtok_r: Improve idiom.
98306         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Invoke gl_PREREQ_STRDUP only when
98307         AC_LIBOBJ is used.
98309 2010-04-05  Bruno Haible  <bruno@clisp.org>
98311         strdup: Improve idiom.
98312         * m4/strdup.m4 (gl_FUNC_STRDUP): Invoke gl_PREREQ_STRDUP only when
98313         AC_LIBOBJ is used.
98314         (gl_FUNC_STRDUP_POSIX): When strdup is missing and malloc is not POSIX
98315         compliant, don't set REPLACE_STRDUP to 1. Invoke gl_PREREQ_STRDUP only
98316         when AC_LIBOBJ is used.
98318 2010-04-05  Bruno Haible  <bruno@clisp.org>
98320         mbsinit, mbrtowc, wcrtomb: Improve idioms.
98321         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): When the function does not exist,
98322         don't set REPLACE_MBSINIT to 1.
98323         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): When the function does not exist,
98324         don't set REPLACE_MBRTOWC to 1.
98325         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): When the function does not
98326         exist, don't set REPLACE_MBSRTOWCS to 1.
98327         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): When the function does not
98328         exist, don't set REPLACE_MBSNRTOWCS to 1.
98329         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): When the function does not exist,
98330         don't set REPLACE_WCRTOMB to 1.
98331         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): When the function does not
98332         exist, don't set REPLACE_WCSRTOMBS to 1.
98333         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): When the function does not
98334         exist, don't set REPLACE_WCSNRTOMBS to 1.
98336 2010-04-05  Bruno Haible  <bruno@clisp.org>
98338         ldexpl: Improve idiom.
98339         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): When the function is not declared,
98340         make sure to set HAVE_DECL_LDEXPL to 0.
98342 2010-04-05  Jim Meyering  <meyering@redhat.com>
98344         xstrtol-tests: convert to use init.sh
98345         * modules/xstrtol-tests (Files): Add tests/init.sh.
98346         * tests/test-xstrtol.sh: Invoke "$srcdir/init.sh" and path_prepend_.
98347         Use Exit, not exit.
98348         Remove uses of $EXEEXT and "./" to run a program in the current dir.
98350         atexit-tests: convert to use init.sh
98351         * modules/atexit-tests (Files): Add tests/init.sh.
98352         * tests/test-atexit.sh: Invoke "$srcdir/init.sh" and path_prepend_.
98353         Use Exit, not exit.
98354         Remove uses of $EXEEXT and "./" to run a program in the current dir.
98356         init.sh: fix typo
98357         * tests/init.sh: Restore omitted ":" before stderr_fileno_ initialization.
98359         init.sh: make it easier for a test script to write to the tty, ...
98360         when using automake's parallel-tests mode.
98361         * tests/init.sh (stderr_fileno_): Define overridable variable.
98362         (warn_): New function, to use it.
98363         (fail_, skip_, framework_failure_): Use warn_.
98365 2010-04-04  Bruno Haible  <bruno@clisp.org>
98367         btowc: Avoid warning.
98368         * lib/btowc.c: Include <stdlib.h>.
98369         Reported by Hauke Fath <hauke@espresso.rhein-neckar.de>.
98371 2010-04-04  Hauke Fath  <hauke@espresso.rhein-neckar.de>  (tiny change)
98372             Bruno Haible  <bruno@clisp.org>
98374         wchar: Port to NetBSD 1.5.
98375         * lib/wchar.in.h (WEOF): Provide fallback also when wint_t exists.
98376         * lib/wctype.in.h (WEOF): Likewise.
98378 2010-04-04  Hauke Fath  <hauke@espresso.rhein-neckar.de>  (tiny change)
98379             Bruno Haible  <bruno@clisp.org>
98381         Port extended stdio to NetBSD 1.5.
98382         * lib/stdio-impl.h [NetBSD]: Include <sys/param.h>.
98383         (struct __sfileext, fp_ub): Define the "old way" for NetBSD 1.5Z and
98384         older.
98386 2010-04-04  Bruno Haible  <bruno@clisp.org>
98388         string: Remove unused substitution.
98389         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
98390         HAVE_DECL_STRERROR.
98391         * modules/string (Makefile.am): Don't substitute HAVE_DECL_STRERROR.
98393 2010-04-04  Bruno Haible  <bruno@clisp.org>
98395         strtod: Avoid a possible C++ test error.
98396         * m4/strtod.m4 (gl_FUNC_STRTOD): When setting HAVE_STRTOD to 0, don't
98397         set REPLACE_STRTOD.
98399 2010-04-04  Bruno Haible  <bruno@clisp.org>
98401         strerror: Update documentation.
98402         * doc/posix-functions/strerror.texi: Remove mention of old platforms.
98404 2010-04-04  Bruno Haible  <bruno@clisp.org>
98406         stdio: Fix some C++ test errors on Solaris 8 with GCC.
98407         * lib/stdio.in.h (vdprintf, vfprintf, vprintf, vsprintf): Use
98408         _GL_CXXALIAS_SYS_CAST.
98410 2010-04-04  Bruno Haible  <bruno@clisp.org>
98412         frexpl: Fix a C++ test error on Solaris 8 and Cygwin.
98413         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): When the
98414         function is not declared, set HAVE_DECL_FREXPL to 0, instead of setting
98415         REPLACE_FREXPL to 1.
98416         * doc/posix-functions/frexpl.texi: Update documentation.
98418 2010-04-04  Bruno Haible  <bruno@clisp.org>
98420         math: Fix some C++ test errors on Solaris 8 and Cygwin.
98421         * lib/math.in.h (cosl, logl, sinl): Use simpler idiom.
98423 2010-04-04  Bruno Haible  <bruno@clisp.org>
98425         Implement nanosleep for native Windows.
98426         * lib/nanosleep.c (nanosleep): New implementation for native Windows.
98428 2010-04-04  Bruno Haible  <bruno@clisp.org>
98430         math: Fix some C++ test errors on Solaris 8.
98431         * lib/math.in.h (truncf, trunc): Use simpler idiom.
98433 2010-04-04  Bruno Haible  <bruno@clisp.org>
98435         math: Fix some C++ test errors on Cygwin.
98436         * lib/math.in.h (ceilf, ceill, floorf, floorl, roundf, round, roundl,
98437         truncl): Provide declaration if the system does not have it.
98438         * m4/ceilf.m4 (gl_FUNC_CEILF): If the function is not declared, set
98439         HAVE_DECL_CEILF to 0, not REPLACE_CEILF to 1.
98440         * m4/ceill.m4 (gl_FUNC_CEILL): If the function is not declared, set
98441         HAVE_DECL_CEILL to 0, not REPLACE_CEILL to 1.
98442         * m4/floorf.m4 (gl_FUNC_FLOORF): If the function is not declared, set
98443         HAVE_DECL_FLOORF to 0, not REPLACE_FLOORF to 1.
98444         * m4/floorl.m4 (gl_FUNC_FLOORL): If the function is not declared, set
98445         HAVE_DECL_FLOORL to 0, not REPLACE_FLOORL to 1.
98446         * m4/round.m4 (gl_FUNC_ROUND): If the function is not declared, set
98447         HAVE_DECL_ROUND to 0, not REPLACE_ROUND to 1.
98448         * m4/roundf.m4 (gl_FUNC_ROUNDF): If the function is not declared, set
98449         HAVE_DECL_ROUNDF to 0, not REPLACE_ROUNDF to 1.
98450         * m4/roundl.m4 (gl_FUNC_ROUNDL): If the function is not declared, set
98451         HAVE_DECL_ROUNDL to 0, not REPLACE_ROUNDL to 1.
98452         * m4/truncl.m4 (gl_FUNC_TRUNCL): If the function is not declared, set
98453         HAVE_DECL_TRUNCL to 0, not REPLACE_TRUNCL to 1.
98454         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_CEILF,
98455         HAVE_DECL_CEILL, HAVE_DECL_FLOORF, HAVE_DECL_FLOORL, HAVE_DECL_ROUND,
98456         HAVE_DECL_ROUNDF, HAVE_DECL_ROUNDL, HAVE_DECL_TRUNCL.
98457         * modules/math (Makefile.am): Substitute HAVE_DECL_CEILF,
98458         HAVE_DECL_CEILL, HAVE_DECL_FLOORF, HAVE_DECL_FLOORL, HAVE_DECL_ROUND,
98459         HAVE_DECL_ROUNDF, HAVE_DECL_ROUNDL, HAVE_DECL_TRUNCL.
98461 2010-04-04  Bruno Haible  <bruno@clisp.org>
98463         * m4/ceilf.m4 (gl_FUNC_CEILF): Remove redundant AC_SUBST invocation.
98464         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
98465         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
98466         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
98467         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
98468         * m4/isinf.m4 (gl_ISINF): Likewise.
98469         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
98471 2010-04-04  Bruno Haible  <bruno@clisp.org>
98473         * m4/trunc.m4 (gl_FUNC_TRUNC): Remove redundant AC_SUBST invocation.
98474         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
98476 2010-04-04  Bruno Haible  <bruno@clisp.org>
98478         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Renamed from gl_TMPFILE.
98479         * modules/tmpfile (configure.ac): Update.
98481         tmpfile: Fix C++ test error on mingw.
98482         * lib/stdio.in.h (tmpfile): New declaration.
98483         * m4/tmpfile.m4 (gl_TMPFILE): Require gl_STDIO_H_DEFAULTS. Set
98484         REPLACE_TMPFILE instead of defining tmpfile as a macro in config.h.
98485         * modules/tmpfile (Depends-on): Add stdio.
98486         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
98487         * m4/stdio_h.m4 (gl_STDIO_H): Also check whether tmpfile is declared.
98488         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_TMPFILE and REPLACE_TMPFILE.
98489         * modules/stdio (Makefile.am): Substitute GNULIB_TMPFILE and
98490         REPLACE_TMPFILE.
98491         * tests/test-stdio-c++.cc (tmpfile): Verify signature.
98493 2010-04-04  Bruno Haible  <bruno@clisp.org>
98495         ioctl: Fix C++ test error on mingw.
98496         * lib/ioctl.c (ioctl): Renamed from rpl_ioctl.
98497         * lib/sys_ioctl.in.h (ioctl): When SYS_IOCTL_H_HAVE_WINSOCK2_H is 1,
98498         use _GL_FUNCDECL_SYS, not _GL_FUNCDECL_RPL.
98500 2010-04-03  Bruno Haible  <bruno@clisp.org>
98502         wcwidth: Fix C++ test error on mingw.
98503         * lib/wcwidth.c (wcwidth): Renamed from rpl_wcwidth.
98504         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): If the wcwidth function does not
98505         exist, don't set REPLACE_WCWIDTH. Instead, rely on HAVE_DECL_WCWIDTH.
98507 2010-04-03  Bruno Haible  <bruno@clisp.org>
98509         nanosleep: Fix C++ test error on mingw.
98510         * lib/nanosleep.c (nanosleep): Renamed from rpl_nanosleep.
98511         * lib/time.in.h (nanosleep): Use modern idiom.
98512         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): When the system does not have a
98513         nanosleep function, set HAVE_NANOSLEEP to 0, instead of setting
98514         REPLACE_NANOSLEEP to 1.
98515         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_NANOSLEEP.
98516         * modules/time (Makefile.am): Substitute HAVE_NANOSLEEP.
98518 2010-04-03  Bruno Haible  <bruno@clisp.org>
98520         strptime: Fix C++ test error on mingw.
98521         * lib/time.in.h (strptime): Use HAVE_STRPTIME, not REPLACE_STRPTIME.
98522         * m4/strptime.m4 (gl_FUNC_STRPTIME): Set HAVE_STRPTIME, not
98523         REPLACE_STRPTIME. Invoke gl_PREREQ_STRPTIME.
98524         (gl_PREREQ_STRPTIME): New macro, extracted from gl_FUNC_STRPTIME.
98525         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_STRPTIME,
98526         not REPLACE_STRPTIME.
98527         * modules/time (Makefile.am): Substitute HAVE_STRPTIME, not
98528         REPLACE_STRPTIME.
98530 2010-04-03  Bruno Haible  <bruno@clisp.org>
98532         timegm: Fix C++ test error on mingw.
98533         * lib/time.in.h (timegm): Use modern idiom.
98534         * m4/timegm.m4 (gl_FUNC_TIMEGM): When timegm does not exist, set
98535         HAVE_TIMEGM to 0, not REPLACE_TIMEGM to 1.
98536         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_TIMEGM.
98537         * modules/time (Makefile.am): Substitute HAVE_TIMEGM.
98539 2010-04-03  Bruno Haible  <bruno@clisp.org>
98541         timegm: Assume declaration if function exists.
98542         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume timegm is declared if and only
98543         if it exists. Don't clobber ac_cv_func_timegm.
98545 2010-04-03  Bruno Haible  <bruno@clisp.org>
98547         time_r: Fix C++ test error on mingw.
98548         * lib/time.in.h (localtime_r, gmtime_r): Use modern idiom.
98549         * m4/time_r.m4 (gl_TIME_R): When localtime_r does not exist, set
98550         HAVE_LOCALTIME_R to 0, not REPLACE_LOCALTIME_R to 1.
98551         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_LOCALTIME_R.
98552         * modules/time (Makefile.am): Substitute HAVE_LOCALTIME_R.
98554 2010-04-03  Bruno Haible  <bruno@clisp.org>
98556         time_r: Minor updates.
98557         * modules/time_r (Description): Mention the provided functions.
98558         * lib/time_r.c: Don't include <string.h>.
98559         * doc/posix-functions/gmtime_r.texi: Mention the 'time_r' module.
98560         * doc/posix-functions/localtime_r.texi: Likewise.
98562 2010-04-03  Bruno Haible  <bruno@clisp.org>
98564         time: Fix regression introduced on 2010-03-08.
98565         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Require
98566         gl_HEADER_TIME_H_DEFAULTS, not gl_HEADER_STRING_H_DEFAULTS.
98568 2010-04-03  Jim Meyering  <meyering@redhat.com>
98570         maint.mk: don't silently disable project-specific syntax-check rules
98571         * top/maint.mk (_prohibit_regexp): Define, to help people realize
98572         that they need to convert their project-specific syntax-check rules
98573         to use the new _sc_search_regexp.
98575 2010-04-03  Bruno Haible  <bruno@clisp.org>
98577         fchdir: Fix regression introduced on 2010-03-08.
98578         * lib/unistd.in.h (fchdir): Fix declaration.
98579         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set HAVE_FCHDIR, not REPLACE_FCHDIR.
98580         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_FCHDIR, not
98581         REPLACE_FCHDIR.
98582         * modules/unistd (Makefile.am): Substitute HAVE_FCHDIR, not
98583         REPLACE_FCHDIR.
98585 2010-04-03  Bruno Haible  <bruno@clisp.org>
98587         getpagesize: Fix C++ test error on mingw.
98588         * lib/unistd.in.h (getpagesize): Don't use _GL_CXXALIASWARN if the
98589         system does not declare the function.
98590         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Also check whether it's
98591         declared.
98592         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
98593         HAVE_DECL_GETPAGESIZE.
98594         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETPAGESIZE.
98596 2010-04-03  Bruno Haible  <bruno@clisp.org>
98598         stdio: Make C++ tests work on mingw.
98599         * lib/stdio.in.h (getline): Don't use _GL_CXXALIASWARN if the system
98600         does not declare the function.
98602 2010-04-03  Bruno Haible  <bruno@clisp.org>
98604         ftello: Fix C++ test error on mingw.
98605         * lib/stdio.in.h (ftello): Use modern idiom.
98606         * lib/ftello.c (ftello): Renamed from rpl_ftello.
98607         * m4/ftello.m4 (gl_FUNC_FTELLO): Distinguish the case that the function
98608         is missing and that it needs to be replaced.
98609         (gl_REPLACE_FTELLO): Don't set REPLACE_FTELLO here.
98610         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_FTELLO.
98611         * modules/stdio (Makefile.am): Substitute HAVE_FTELLO.
98613 2010-04-03  Bruno Haible  <bruno@clisp.org>
98615         fseeko: Fix C++ test error on mingw.
98616         * lib/stdio.in.h (fseeko): Use modern idiom.
98617         * lib/fseeko.c (fseeko): Renamed from rpl_fseeko.
98618         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Distinguish the case that the function
98619         is missing and that it needs to be replaced.
98620         (gl_REPLACE_FSEEKO): Don't set REPLACE_FSEEKO here.
98621         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_FSEEKO.
98622         * modules/stdio (Makefile.am): Substitute HAVE_FSEEKO.
98624 2010-04-03  Bruno Haible  <bruno@clisp.org>
98626         mkstemp: Fix C++ test error on mingw.
98627         * lib/stdlib.in.h (mkstemp): Use modern idiom.
98628         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Distinguish the case that the
98629         function is missing and that it needs to be replaced.
98630         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_MKSTEMP.
98631         * modules/stdlib (Makefile.am): Substitute HAVE_MKSTEMP.
98633 2010-04-03  Bruno Haible  <bruno@clisp.org>
98635         stpncpy: Fix C++ test error on mingw.
98636         * lib/string.in.h (stpncpy): Use modern idiom.
98637         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Distinguish the case that the
98638         function is missing and that it needs to be replaced.
98639         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
98640         REPLACE_STPNCPY.
98641         * modules/string (Makefile.am): Substitute REPLACE_STPNCPY.
98643 2010-04-03  Bruno Haible  <bruno@clisp.org>
98645         sys_stat: Fix C++ test error on mingw.
98646         * build-aux/c++defs.h (_GL_CXXALIAS_RPL_CAST_1): New macro.
98647         * lib/sys_stat.in.h (lchmod): Use it instead of _GL_CXXALIAS_RPL_1.
98649 2010-04-03  Bruno Haible  <bruno@clisp.org>
98651         pty: Update doc.
98652         * doc/glibc-headers/pty.texi: Mention changes done since 2010-03-18.
98654 2010-04-03  Bruno Haible  <bruno@clisp.org>
98656         unistd: Fix C++ test error on mingw.
98657         * lib/unistd.in.h (getcwd): Use _GL_CXXALIAS_SYS_CAST.
98659 2010-04-03  Bruno Haible  <bruno@clisp.org>
98661         Update doc regarding mingw.
98662         * doc/glibc-functions/openpty.texi: Update regarding mingw.
98663         * doc/glibc-functions/login_tty.texi: Likewise.
98664         * doc/glibc-functions/forkpty.texi: Likewise.
98666 2010-04-03  Bruno Haible  <bruno@clisp.org>
98668         stdlib: Avoid compilation failure of c-strtold on mingw.
98669         * lib/stdlib.in.h: Don't include <unistd.h> on native Windows systems.
98671 2010-04-03  Bruno Haible  <bruno@clisp.org>
98673         locale: Make C++ tests work on Cygwin and mingw.
98674         * lib/locale.in.h (duplocale): Don't use _GL_CXXALIASWARN if gnulib
98675         cannot provide the function.
98676         Reported by Simon Josefsson.
98678 2010-04-03  Bruno Haible  <bruno@clisp.org>
98680         localename: Port to MacOS X 10.6.
98681         * lib/localename.c (gl_locale_name_thread_unsafe): On MacOS X, try the
98682         memory layout of the locales in MacOS X 10.6 as well.
98683         Reported by Panu Kekäläinen <panu@kekalainen.eu>.
98685 2010-04-02  Bruno Haible  <bruno@clisp.org>
98687         gnulib-tool: Ensure that long-running tests are executed last.
98688         * gnulib-tool (func_emit_tests_Makefile_am): Emit the code for long-
98689         running tests after the one for the other tests.
98691 2010-04-02  Bruno Haible  <bruno@clisp.org>
98693         gnulib-tool: Ensure the tests in the main directory are executed first.
98694         * gnulib-tool (func_emit_tests_Makefile_am): Initialize SUBDIRS to
98695         start with the current directory.
98697 2010-04-02  Bruno Haible  <bruno@clisp.org>
98699         Tests for module 'havelib', moved here from GNU gettext.
98700         * modules/havelib-tests: New file, from gettext/autoconf-lib-link with
98701         modifications.
98702         * tests/havelib/README: New file, from gettext/autoconf-lib-link.
98703         * tests/havelib/Makefile.am: New file, from gettext/autoconf-lib-link
98704         with modifications.
98705         * tests/havelib/rpath-1: New file, from gettext/autoconf-lib-link with
98706         modifications.
98707         * tests/havelib/rpath-1a: New file, from gettext/autoconf-lib-link.
98708         * tests/havelib/rpath-1b: New file, from gettext/autoconf-lib-link.
98709         * tests/havelib/rpath-2_a: New file, from gettext/autoconf-lib-link
98710         with modifications.
98711         * tests/havelib/rpath-2_b: New file, from gettext/autoconf-lib-link
98712         with modifications.
98713         * tests/havelib/rpath-2aaa: New file, from gettext/autoconf-lib-link.
98714         * tests/havelib/rpath-2aab: New file, from gettext/autoconf-lib-link.
98715         * tests/havelib/rpath-2aac: New file, from gettext/autoconf-lib-link.
98716         * tests/havelib/rpath-2aad: New file, from gettext/autoconf-lib-link.
98717         * tests/havelib/rpath-2aba: New file, from gettext/autoconf-lib-link.
98718         * tests/havelib/rpath-2abb: New file, from gettext/autoconf-lib-link.
98719         * tests/havelib/rpath-2abc: New file, from gettext/autoconf-lib-link.
98720         * tests/havelib/rpath-2abd: New file, from gettext/autoconf-lib-link.
98721         * tests/havelib/rpath-2baa: New file, from gettext/autoconf-lib-link.
98722         * tests/havelib/rpath-2bab: New file, from gettext/autoconf-lib-link.
98723         * tests/havelib/rpath-2bac: New file, from gettext/autoconf-lib-link.
98724         * tests/havelib/rpath-2bad: New file, from gettext/autoconf-lib-link.
98725         * tests/havelib/rpath-2bba: New file, from gettext/autoconf-lib-link.
98726         * tests/havelib/rpath-2bbb: New file, from gettext/autoconf-lib-link.
98727         * tests/havelib/rpath-2bbc: New file, from gettext/autoconf-lib-link.
98728         * tests/havelib/rpath-2bbd: New file, from gettext/autoconf-lib-link.
98729         * tests/havelib/rpath-3_a: New file, from gettext/autoconf-lib-link
98730         with modifications.
98731         * tests/havelib/rpath-3_b: New file, from gettext/autoconf-lib-link
98732         with modifications.
98733         * tests/havelib/rpath-3aaa: New file, from gettext/autoconf-lib-link.
98734         * tests/havelib/rpath-3aab: New file, from gettext/autoconf-lib-link.
98735         * tests/havelib/rpath-3aac: New file, from gettext/autoconf-lib-link.
98736         * tests/havelib/rpath-3aad: New file, from gettext/autoconf-lib-link.
98737         * tests/havelib/rpath-3aae: New file, from gettext/autoconf-lib-link.
98738         * tests/havelib/rpath-3aaf: New file, from gettext/autoconf-lib-link.
98739         * tests/havelib/rpath-3aag: New file, from gettext/autoconf-lib-link.
98740         * tests/havelib/rpath-3aah: New file, from gettext/autoconf-lib-link.
98741         * tests/havelib/rpath-3aba: New file, from gettext/autoconf-lib-link.
98742         * tests/havelib/rpath-3abb: New file, from gettext/autoconf-lib-link.
98743         * tests/havelib/rpath-3abc: New file, from gettext/autoconf-lib-link.
98744         * tests/havelib/rpath-3abd: New file, from gettext/autoconf-lib-link.
98745         * tests/havelib/rpath-3abe: New file, from gettext/autoconf-lib-link.
98746         * tests/havelib/rpath-3abf: New file, from gettext/autoconf-lib-link.
98747         * tests/havelib/rpath-3abg: New file, from gettext/autoconf-lib-link.
98748         * tests/havelib/rpath-3abh: New file, from gettext/autoconf-lib-link.
98749         * tests/havelib/rpath-3baa: New file, from gettext/autoconf-lib-link.
98750         * tests/havelib/rpath-3bab: New file, from gettext/autoconf-lib-link.
98751         * tests/havelib/rpath-3bac: New file, from gettext/autoconf-lib-link.
98752         * tests/havelib/rpath-3bad: New file, from gettext/autoconf-lib-link.
98753         * tests/havelib/rpath-3bae: New file, from gettext/autoconf-lib-link.
98754         * tests/havelib/rpath-3baf: New file, from gettext/autoconf-lib-link.
98755         * tests/havelib/rpath-3bag: New file, from gettext/autoconf-lib-link.
98756         * tests/havelib/rpath-3bah: New file, from gettext/autoconf-lib-link.
98757         * tests/havelib/rpath-3bba: New file, from gettext/autoconf-lib-link.
98758         * tests/havelib/rpath-3bbb: New file, from gettext/autoconf-lib-link.
98759         * tests/havelib/rpath-3bbc: New file, from gettext/autoconf-lib-link.
98760         * tests/havelib/rpath-3bbd: New file, from gettext/autoconf-lib-link.
98761         * tests/havelib/rpath-3bbe: New file, from gettext/autoconf-lib-link.
98762         * tests/havelib/rpath-3bbf: New file, from gettext/autoconf-lib-link.
98763         * tests/havelib/rpath-3bbg: New file, from gettext/autoconf-lib-link.
98764         * tests/havelib/rpath-3bbh: New file, from gettext/autoconf-lib-link.
98765         * tests/havelib/rpathx/rpathx.c: New file, from
98766         gettext/autoconf-lib-link.
98767         * tests/havelib/rpathx/Makefile.am: New file, from
98768         gettext/autoconf-lib-link.
98769         * tests/havelib/rpathx/configure.ac: New file, from
98770         gettext/autoconf-lib-link with modifications.
98771         * tests/havelib/rpathy/rpathy.c: New file, from
98772         gettext/autoconf-lib-link.
98773         * tests/havelib/rpathy/Makefile.am: New file, from
98774         gettext/autoconf-lib-link.
98775         * tests/havelib/rpathy/configure.ac: New file, from
98776         gettext/autoconf-lib-link with modifications.
98777         * tests/havelib/rpathz/rpathz.c: New file, from
98778         gettext/autoconf-lib-link.
98779         * tests/havelib/rpathz/Makefile.am: New file, from
98780         gettext/autoconf-lib-link.
98781         * tests/havelib/rpathz/configure.ac: New file, from
98782         gettext/autoconf-lib-link with modifications.
98783         * tests/havelib/rpathlx/usex.c: New file, from
98784         gettext/autoconf-lib-link.
98785         * tests/havelib/rpathlx/Makefile.am: New file, from
98786         gettext/autoconf-lib-link.
98787         * tests/havelib/rpathlx/configure.ac: New file, from
98788         gettext/autoconf-lib-link with modifications.
98789         * tests/havelib/rpathly/usey.c: New file, from
98790         gettext/autoconf-lib-link.
98791         * tests/havelib/rpathly/Makefile.am: New file, from
98792         gettext/autoconf-lib-link.
98793         * tests/havelib/rpathly/configure.ac: New file, from
98794         gettext/autoconf-lib-link with modifications.
98795         * tests/havelib/rpathlz/usez.c: New file, from
98796         gettext/autoconf-lib-link.
98797         * tests/havelib/rpathlz/Makefile.am: New file, from
98798         gettext/autoconf-lib-link.
98799         * tests/havelib/rpathlz/configure.ac: New file, from
98800         gettext/autoconf-lib-link with modifications.
98801         * tests/havelib/rpathlyx/usey.c: New file, from
98802         gettext/autoconf-lib-link.
98803         * tests/havelib/rpathlyx/Makefile.am: New file, from
98804         gettext/autoconf-lib-link.
98805         * tests/havelib/rpathlyx/configure.ac: New file, from
98806         gettext/autoconf-lib-link with modifications.
98807         * tests/havelib/rpathlzyx/usez.c: New file, from
98808         gettext/autoconf-lib-link.
98809         * tests/havelib/rpathlzyx/Makefile.am: New file, from
98810         gettext/autoconf-lib-link.
98811         * tests/havelib/rpathlzyx/configure.ac: New file, from
98812         gettext/autoconf-lib-link with modifications.
98813         * tests/havelib/rpathcfg.sh: New file, from gettext/autoconf-lib-link
98814         with modifications.
98816 2010-04-02  Bruno Haible  <bruno@clisp.org>
98818         gnulib-tool: Create distributed built sources also for the tests.
98819         * gnulib-tool (func_create_testdir): Also generate distributed built
98820         sources in the tests directory.
98822 2010-04-02  Bruno Haible  <bruno@clisp.org>
98824         gnulib-tool: Obey user's environment variables.
98825         * gnulib-tool (func_create_testdir): When creating built sources,
98826         respect the environment variables for autoconf, automake, etc. given by
98827         the user.
98829 2010-04-02  Bruno Haible  <bruno@clisp.org>
98831         gnulib-tool: Provide the value of --m4-base to modules.
98832         * gnulib-tool (func_import, func_create_testdir): Emit a definition
98833         of gl_m4_base.
98835 2010-04-02  Eric Blake  <eblake@redhat.com>
98837         maint.mk: fix some fallout
98838         * NEWS: Document the incompatible change, and its effect on cfg.mk.
98839         * top/maint.mk (sc_prohibit_test_minus_ao): Update.
98841 2010-03-28  Jose E. Marchesi  <jemarch@gnu.org>
98843         maint.mk: _sc_search_regexp: generalize and rename from _prohibit_regexp
98844         * top/maint.mk (_sc_search_regexp): Rename from _prohibit_regexp.
98845         (sc_cast_of_argument_to_free): Adapt to use _sc_search_regexp.
98846         (sc_cast_of_x_alloc_return_value): Likewise.
98847         (sc_cast_of_alloca_return_value): Likewise.
98848         (sc_space_tab): Likewise.
98849         (sc_prohibit_atoi_atof): Likewise.
98850         (sc_prohibit_magic_number_exit): Likewise.
98851         (sc_error_exit_success): Likewise.
98852         (sc_file_system): Likewise.
98853         (sc_prohibit_have_config_h): Likewise.
98854         (sc_require_config_h): Likewise.
98855         (sc_prohibit_HAVE_MBRTOWC): Likewise.
98856         (sc_obsolete_symbols): Likewise.
98857         (sc_changelog): Likewise.
98858         (sc_program_name): Likewise.
98859         (sc_the_the): Likewise.
98860         (sc_trailing_blank): Likewise.
98861         (sc_two_space_separator_in_usage): Likewise.
98862         (sc_useless_cpp_parens): Likewise.
98863         (sc_GPL_version): Likewise.
98864         (sc_GFDL_version): Likewise.
98865         (sc_texinfo_acronym): Likewise.
98866         (sc_prohibit_cvs_keyword): Likewise.
98867         (sc_prohibit_stat_st_blocks): Likewise.
98868         (sc_prohibit_S_IS_definition): Likewise.
98869         (sc_redundant_const): Likewise.
98870         (sc_makefile_TAB_only_indentation): Likewise.
98871         (sc_m4_quote_check): Likewise.
98872         (sc_makefile_path_separator_check): Likewise.
98873         (sc_copyright_check): Likewise.
98874         (sc_Wundef_boolean): Likewise.
98875         (sc_vulnerable_makefile_CVE-2009-4029): Likewise.
98877         maint.mk: match 0 or more whitespace-before-function-call '('
98878         * top/maint.mk (sc_error_exit_success): Relax regexp to match uses
98879         that have zero or two-and-more spaces between the function name
98880         and the open parenthesis.
98881         (sc_error_message_warn_fatal): Likewise.
98882         (sc_error_message_uppercase): Likewise.
98883         (sc_error_message_period): Likewise.
98885 2010-03-31  Eric Blake  <eblake@redhat.com>
98887         maint.mk: check for [ as well as test
98888         * top/maint.mk (sc_prohibit_test_minus_ao): Extend test.
98889         Based on a libvirt report by Matthias Bolte.
98891         gnumakefile: don't squelch _version output
98892         * top/GNUmakefile (_version): Create one-shot dependency rather
98893         than using $(shell) when version must be regenerated.
98894         (_autoreconf): Run verbosely, by default.
98896         sys_time: avoid compiler warnings
98897         * lib/sys_time.in.h (includes): Ensure gcc pragma is
98898         unconditional, fixing regression from 2010-03-29.
98899         Reported by Simon Josefsson.
98901 2010-03-28  Jose E. Marchesi  <jemarch@gnu.org>
98903         maint.mk: s/_header_without_use/_sc_header_without_use/
98904         * top/maint.mk (_sc_header_without_use): Rename from _header_without_use.
98905         (sc_prohibit_assert_without_use): Use the new name.
98906         (sc_prohibit_close_stream_without_use): Likewise.
98907         (sc_prohibit_getopt_without_use): Likewise.
98908         (sc_prohibit_quotearg_without_use): Likewise.
98909         (sc_prohibit_quote_without_use): Likewise.
98910         (sc_prohibit_long_options_without_use): Likewise.
98911         (sc_prohibit_inttostr_without_use): Likewise.
98912         (sc_prohibit_ignore_value_without_use): Likewise.
98913         (sc_prohibit_error_without_use): Likewise.
98914         (sc_prohibit_xalloc_without_use): Likewise.
98915         (sc_prohibit_hash_without_use): Likewise.
98916         (sc_prohibit_hash_pjw_without_use): Likewise.
98917         (sc_prohibit_safe_read_without_use): Likewise.
98918         (sc_prohibit_argmatch_without_use): Likewise.
98919         (sc_prohibit_canonicalize_without_use): Likewise.
98920         (sc_prohibit_root_dev_ino_without_use): Likewise.
98921         (sc_prohibit_openat_without_use): Likewise.
98922         (sc_prohibit_c_ctype_without_use): Likewise.
98923         (sc_prohibit_signal_without_use): Likewise.
98924         (sc_prohibit_intprops_without_use): Likewise.
98926 2010-03-30  Eric Blake  <eblake@redhat.com>
98928         maint: improve module indicators
98929         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_SET_VARIABLE)
98930         (gl_MODULE_INDICATOR, gl_MODULE_INDICATOR_FOR_TESTS): Fit in 80
98931         columns, and avoid extra macro expansion.
98933         fdopendir: work around FreeBSD bug
98934         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
98935         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Set it.
98936         * modules/dirent (Makefile.am): Substitute it.
98937         * lib/dirent.in.h (fdopendir): Supply missing FreeBSD
98938         declaration.
98939         * doc/posix-functions/fdopendir.texi (fdopendir): Document the
98940         fix.
98941         Reported by Christian Weisgerber <naddy@mips.inka.de>.
98943 2010-03-29  Bruno Haible  <bruno@clisp.org>
98945         Emit #pragma system_header after the inclusion guard, not before.
98946         * lib/arpa_inet.in.h: Emit #pragma system_header after the inclusion
98947         guard that spans the entire file, not before. This enables an
98948         optimization in GCC's preprocessor.
98949         * lib/ctype.in.h: Likewise.
98950         * lib/dirent.in.h: Likewise.
98951         * lib/errno.in.h: Likewise.
98952         * lib/float.in.h: Likewise.
98953         * lib/getopt.in.h: Likewise.
98954         * lib/iconv.in.h: Likewise.
98955         * lib/langinfo.in.h: Likewise.
98956         * lib/locale.in.h: Likewise.
98957         * lib/math.in.h: Likewise.
98958         * lib/netdb.in.h: Likewise.
98959         * lib/netinet_in.in.h: Likewise.
98960         * lib/pty.in.h: Likewise.
98961         * lib/sched.in.h: Likewise.
98962         * lib/se-selinux.in.h: Likewise.
98963         * lib/search.in.h: Likewise.
98964         * lib/spawn.in.h: Likewise.
98965         * lib/stdarg.in.h: Likewise.
98966         * lib/stdint.in.h: Likewise.
98967         * lib/string.in.h: Likewise.
98968         * lib/strings.in.h: Likewise.
98969         * lib/sys_file.in.h: Likewise.
98970         * lib/sys_ioctl.in.h: Likewise.
98971         * lib/sys_time.in.h: Likewise.
98972         * lib/sys_times.in.h: Likewise.
98973         * lib/sys_utsname.in.h: Likewise.
98974         * lib/sys_wait.in.h: Likewise.
98975         * lib/sysexits.in.h: Likewise.
98976         * lib/wctype.in.h: Likewise.
98978 2010-03-28  James Youngman  <jay@gnu.org>
98980         save-cwd: don't leak a file descriptor when the caller execs.
98981         * lib/save-cwd.c (save_cwd): set the close-on-exec flag for the
98982         saved file descriptor.
98983         * modules/save-cwd (Depends-on): Depend on cloexec.
98985 2010-03-29  Bruno Haible  <bruno@clisp.org>
98987         Remove vestiges of fts-lgpl module.
98988         * lib/fts_.h: Assume GNULIB_FTS is 1.
98989         * lib/fts.c: Likewise.
98990         * modules/fts (configure.ac): Remove gl_MODULE_INDICATOR invocation.
98992 2010-03-28  Bruno Haible  <bruno@clisp.org>
98994         Fix definition of tests witness macro.
98995         * gnulib-tool (func_import): Fix definition of witness macro.
98997 2010-03-28  Bruno Haible  <bruno@clisp.org>
98999         Fix ioctl's protoype on glibc systems.
99000         * lib/sys_ioctl.in.h (ioctl): If REPLACE_IOCTL is 1, use a wrapper. Use
99001         _GL_CXXALIAS_SYS, not _GL_CXXALIAS_SYS_CAST.
99002         * lib/ioctl.c (rpl_ioctl) [HAVE_IOCTL]: New wrapper.
99003         * modules/ioctl (configure.ac): Test whether ioctl has the POSIX
99004         signature. If not, arrange to replace the ioctl function.
99005         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Initialize
99006         REPLACE_IOCTL.
99007         * modules/sys_ioctl (Makefile.am): Substitute REPLACE_IOCTL.
99008         * doc/posix-functions/ioctl.texi: Mention the glibc problem.
99009         Reported by Ludovic Courtès <ludo@gnu.org>.
99011 2010-03-28  Javier Villavicencio  <the_paya@gentoo.org>
99013         exclude: fix the case of globs vs. EXCLUDE_INCLUDE
99014         * lib/exclude.c (excluded_file_pattern_p): Fix logic error that
99015         made it so grep -r --include=GLOB* ... did not work.
99017 2010-03-26  Jim Meyering  <meyering@redhat.com>
99018             Eric Blake  <eblake@redhat.com>
99020         maint.mk: prohibit use of test's -o and -a operators
99021         * top/maint.mk (sc_prohibit_test_minus_ao): New rule.
99023 2010-03-28  Bruno Haible  <bruno@clisp.org>
99025         Remove unused GNULIB_XYZ macro definitions.
99026         * modules/crypto/gc-camellia (configure.ac): Remove gl_MODULE_INDICATOR
99027         invocation.
99029 2010-03-28  Bruno Haible  <bruno@clisp.org>
99031         Mark privileged tests modules.
99032         * modules/idpriv-drop-tests (Status): New section.
99033         * modules/idpriv-droptemp-tests (Status): New section.
99035 2010-03-28  Bruno Haible  <bruno@clisp.org>
99037         Split C++ tests into separate tests modules.
99038         * modules/dirent-c++-tests: New file, extracted from
99039         modules/dirent-tests.
99040         * modules/dirent-tests: Depend on it.
99041         * modules/fcntl-h-c++-tests: New file, extracted from
99042         modules/fcntl-h-tests.
99043         * modules/fcntl-h-tests: Depend on it.
99044         * modules/glob-c++-tests: New file, extracted from modules/glob-tests.
99045         * modules/glob-tests: Depend on it.
99046         * modules/iconv-h-c++-tests: New file, extracted from
99047         modules/iconv-h-tests.
99048         * modules/iconv-h-tests: Depend on it.
99049         * modules/langinfo-c++-tests: New file, extracted from
99050         modules/langinfo-tests.
99051         * modules/langinfo-tests: Depend on it.
99052         * modules/locale-c++-tests: New file, extracted from
99053         modules/locale-tests.
99054         * modules/locale-tests: Depend on it.
99055         * modules/math-c++-tests: New file, extracted from modules/math-tests.
99056         * modules/math-tests: Depend on it.
99057         * modules/pty-c++-tests: New file, extracted from modules/pty-tests.
99058         * modules/pty-tests: Depend on it.
99059         * modules/search-c++-tests: New file, extracted from
99060         modules/search-tests.
99061         * modules/search-tests: Depend on it.
99062         * modules/signal-c++-tests: New file, extracted from
99063         modules/signal-tests.
99064         * modules/signal-tests: Depend on it.
99065         * modules/spawn-c++-tests: New file, extracted from
99066         modules/spawn-tests.
99067         * modules/spawn-tests: Depend on it.
99068         * modules/stdio-c++-tests: New file, extracted from
99069         modules/stdio-tests.
99070         * modules/stdio-tests: Depend on it.
99071         * modules/stdlib-c++-tests: New file, extracted from
99072         modules/stdlib-tests.
99073         * modules/stdlib-tests: Depend on it.
99074         * modules/string-c++-tests: New file, extracted from
99075         modules/string-tests.
99076         * modules/string-tests: Depend on it.
99077         * modules/sys_ioctl-c++-tests: New file, extracted from
99078         modules/sys_ioctl-tests.
99079         * modules/sys_ioctl-tests: Depend on it.
99080         * modules/sys_select-c++-tests: New file, extracted from
99081         modules/sys_select-tests.
99082         * modules/sys_select-tests: Depend on it.
99083         * modules/sys_socket-c++-tests: New file, extracted from
99084         modules/sys_socket-tests.
99085         * modules/sys_socket-tests: Depend on it.
99086         * modules/sys_stat-c++-tests: New file, extracted from
99087         modules/sys_stat-tests.
99088         * modules/sys_stat-tests: Depend on it.
99089         * modules/sys_time-c++-tests: New file, extracted from
99090         modules/sys_time-tests.
99091         * modules/sys_time-tests: Depend on it.
99092         * modules/time-c++-tests: New file, extracted from modules/time-tests.
99093         * modules/time-tests: Depend on it.
99094         * modules/unistd-c++-tests: New file, extracted from
99095         modules/unistd-tests.
99096         * modules/unistd-tests: Depend on it.
99097         * modules/wchar-c++-tests: New file, extracted from
99098         modules/wchar-tests.
99099         * modules/wchar-tests: Depend on it.
99100         * modules/wctype-c++-tests: New file, extracted from
99101         modules/wctype-tests.
99102         * modules/wctype-tests: Depend on it.
99103         Reported by Simon Josefsson.
99105 2010-03-28  Bruno Haible  <bruno@clisp.org>
99107         gnulib-tool: Allow 'foo-tests' module even if there is no module 'foo'.
99108         * gnulib-tool (func_exists_module): New function, extracted from
99109         func_verify_module.
99110         (func_verify_module): Use it.
99111         (func_get_dependencies): Synthetize a dependency from 'foo-tests' to
99112         'foo' only if 'foo' exists.
99113         * doc/gnulib.texi (Extra tests modules): Explain how to split a tests
99114         module.
99116 2010-03-28  Bruno Haible  <bruno@clisp.org>
99118         gnulib-tool: Add support for special categories of tests.
99119         * gnulib-tool: New options --with-c++-tests, --with-longrunning-tests,
99120         --with-privileged-tests, --with-unportable-tests, --with-all-tests.
99121         (func_usage): Document them.
99122         (inc_cxx_tests, inc_longrunning_tests, inc_privileged_tests,
99123         inc_unportable_tests, inc_all_tests): New variables.
99124         (func_acceptable): Consider these variables.
99125         (func_modules_transitive_closure): Make it work when the 'Status' field
99126         consists of multiple words.
99127         (func_import): Store and restore the values of inc_cxx_tests,
99128         inc_longrunning_tests, inc_privileged_tests, inc_unportable_tests,
99129         inc_all_tests in gnulib-comp.m4.
99130         (func_create_testdir): Set inc_all_tests to true.
99131         * doc/gnulib.texi (Extra tests modules): New section.
99132         Suggested by Jim Meyering.
99134 2010-03-28  Bruno Haible  <bruno@clisp.org>
99136         ansi-c++-opt: Allow turning off the C++ build by default.
99137         * m4/ansi-c++.m4 (gl_CXX_CHOICE): Let CXX_CHOICE default to 'no' if
99138         gl_CXX_CHOICE_DEFAULT_NO is defined.
99139         Requested by Eric Blake.
99141 2010-03-28  Bruno Haible  <bruno@clisp.org>
99143         unistd: Avoid #define replacements in C++ mode.
99144         * lib/unistd.in.h (socket, connect, accept, bind, getpeername,
99145         getsockname, getsockopt, listen, recv, send, recvfrom, sendto,
99146         setsockopt, shutdown, select): In C++, attach a warning to the function
99147         if possible, rather than #defining the symbol to a dysfunctional alias.
99148         Reported by John W. Eaton <jwe@gnu.org>.
99150 2010-03-28  Bruno Haible  <bruno@clisp.org>
99152         Fix link errors on mingw.
99153         * lib/sys_ioctl.in.h (ioctl): Fix declaration idiom.
99154         * modules/sys_ioctl-tests (Makefile.am): Link test-sys_ioctl-c++ with
99155         $(LIBSOCKET).
99156         * modules/sys_select-tests (Makefile.am): Link test-sys_select-c++ with
99157         $(LIBSOCKET).
99159 2010-03-28  Bruno Haible  <bruno@clisp.org>
99160             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
99162         lib-ignore: Determine different options for different compilers.
99163         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Set a variable which
99164         depends on the current language (C/C++/Fortran). Don't set LDFLAGS.
99165         Add comments.
99166         (_gl_IGNORE_UNUSED_LIBRARIES_OPTIONS): New macro.
99167         * NEWS: Mention the change.
99169 2010-03-27  Bruno Haible  <bruno@clisp.org>
99171         Remove unused GNULIB_XYZ macro definitions.
99172         * modules/dup3 (configure.ac): Remove gl_MODULE_INDICATOR invocation.
99173         * modules/fseek (configure.ac): Likewise.
99174         * modules/ioctl (configure.ac): Likewise.
99175         * modules/open (configure.ac): Likewise.
99176         * modules/stdlib-safer (configure.ac): Likewise.
99178 2010-03-27  Bruno Haible  <bruno@clisp.org>
99180         Add a remark about certain modules.
99181         * modules/malloc (Comment): New section.
99182         * modules/realloc (Comment): Likewise.
99183         * modules/sigpipe (Comment): Likewise.
99185 2010-03-27  Bruno Haible  <bruno@clisp.org>
99187         Resolve conflict between the two kinds of module indicators.
99188         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_FOR_TESTS): Define
99189         GNULIB_TEST_XYZ instead of GNULIB_XYZ.
99190         * modules/canonicalize (configure.ac): Invoke
99191         gl_MODULE_INDICATOR_FOR_TESTS.
99192         * tests/test-canonicalize-lgpl.c: Test GNULIB_TEST_XYZ instead of
99193         GNULIB_XYZ.
99194         * tests/test-dirent-c++.cc: Likewise.
99195         * tests/test-dirent-safer.c: Likewise.
99196         * tests/test-dup2.c: Likewise.
99197         * tests/test-fchdir.c: Likewise.
99198         * tests/test-fcntl-h-c++.cc: Likewise.
99199         * tests/test-getopt.c: Likewise.
99200         * tests/test-getopt.h: Likewise.
99201         * tests/test-langinfo-c++.cc: Likewise.
99202         * tests/test-locale-c++.cc: Likewise.
99203         * tests/test-math-c++.cc: Likewise.
99204         * tests/test-pty-c++.cc: Likewise.
99205         * tests/test-search-c++.cc: Likewise.
99206         * tests/test-signal-c++.cc: Likewise.
99207         * tests/test-spawn-c++.cc: Likewise.
99208         * tests/test-stdio-c++.cc: Likewise.
99209         * tests/test-stdlib-c++.cc: Likewise.
99210         * tests/test-string-c++.cc: Likewise.
99211         * tests/test-sys_ioctl-c++.cc: Likewise.
99212         * tests/test-sys_select-c++.cc: Likewise.
99213         * tests/test-sys_socket-c++.cc: Likewise.
99214         * tests/test-sys_stat-c++.cc: Likewise.
99215         * tests/test-sys_time-c++.cc: Likewise.
99216         * tests/test-time-c++.cc: Likewise.
99217         * tests/test-unistd-c++.cc: Likewise.
99218         * tests/test-wchar-c++.cc: Likewise.
99219         * tests/uninorm/test-u8-nfc.c: Likewise.
99220         * tests/uninorm/test-u8-nfd.c: Likewise.
99221         * tests/uninorm/test-u8-nfkc.c: Likewise.
99222         * tests/uninorm/test-u8-nfkd.c: Likewise.
99223         * tests/uninorm/test-u16-nfc.c: Likewise.
99224         * tests/uninorm/test-u16-nfd.c: Likewise.
99225         * tests/uninorm/test-u16-nfkc.c: Likewise.
99226         * tests/uninorm/test-u16-nfkd.c: Likewise.
99227         * tests/uninorm/test-u32-nfc.c: Likewise.
99228         * tests/uninorm/test-u32-nfc-big.c: Likewise.
99229         * tests/uninorm/test-u32-nfd.c: Likewise.
99230         * tests/uninorm/test-u32-nfd-big.c: Likewise.
99231         * tests/uninorm/test-u32-nfkc.c: Likewise.
99232         * tests/uninorm/test-u32-nfkc-big.c: Likewise.
99233         * tests/uninorm/test-u32-nfkd.c: Likewise.
99234         * tests/uninorm/test-u32-nfkd-big.c: Likewise.
99235         * tests/uninorm/test-u32-normalize-big.c: Likewise.
99237 2010-03-27  Bruno Haible  <bruno@clisp.org>
99239         Distinguish two kinds of module indicators.
99240         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_FOR_TESTS): Renamed from
99241         gl_MODULE_INDICATOR.
99242         (gl_MODULE_INDICATOR): New macro.
99243         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Invoke
99244         gl_MODULE_INDICATOR_FOR_TESTS instead of gl_MODULE_INDICATOR.
99245         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Likewise.
99246         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Likewise.
99247         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Likewise.
99248         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Likewise.
99249         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Likewise.
99250         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Likewise.
99251         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Likewise.
99252         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Likewise.
99253         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Likewise.
99254         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Likewise.
99255         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Likewise.
99256         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Likewise.
99257         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Likewise.
99258         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Likewise.
99259         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Likewise.
99260         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Likewise.
99261         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Likewise.
99262         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Likewise.
99263         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Likewise.
99264         * modules/cloexec (configure.ac): Likewise.
99265         * modules/getopt-gnu (configure.ac): Likewise.
99266         * modules/uninorm/u8-normalize (configure.ac): Likewise.
99267         * modules/uninorm/u16-normalize (configure.ac): Likewise.
99268         * modules/uninorm/u32-normalize (configure.ac): Likewise.
99269         * modules/fdopendir (configure.ac): Invoke gl_MODULE_INDICATOR.
99271 2010-03-27  Bruno Haible  <bruno@clisp.org>
99273         New module description field 'Comment'.
99274         * gnulib-tool: New option --extract-comment.
99275         (func_usage): Document it.
99276         (sed_extract_prog, sed_extract_field_header): Support 'Comment' field.
99277         (func_get_comment): New function.
99278         * modules/TEMPLATE-EXTENDED: Add a blank Comment field.
99280 2010-03-27  Bruno Haible  <bruno@clisp.org>
99282         Addendum to 2010-02-07 commit.
99283         * gnulib-tool (func_usage): Document --extract-applicability option.
99285 2010-03-27  Bruno Haible  <bruno@clisp.org>
99287         Use GNULIB_POSIXCHECK instead of GNULIB_PORTCHECK.
99288         * lib/time.in.h (asctime, asctime_r, ctime, ctime_r): Test
99289         GNULIB_POSIXCHECK, not GNULIB_PORTCHECK. Provide compile-time warnings
99290         rather than link errors.
99292 2010-03-27  Bruno Haible  <bruno@clisp.org>
99294         Avoid side effects from tests-related modules on the compilation of lib.
99295         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_CONDITION): New macro.
99296         (gl_MODULE_INDICATOR_SET_VARIABLE): Use its expansion as a value.
99297         * gnulib-tool (func_emit_tests_Makefile_am): Accept a witness_macro
99298         parameter. Emit into AM_CPPFLAGS a definition of the designated C
99299         macro.
99300         (func_import): Define a witness macro. Assign it a value that depends
99301         on the current package. Override gl_MODULE_INDICATOR_CONDITION for the
99302         tests-related modules.
99303         (func_create_testdir): Update func_emit_tests_Makefile_am invocation.
99304         Reported by Jim Meyering.
99306 2010-03-27  Bruno Haible  <bruno@clisp.org>
99308         Factorize common .m4 code.
99309         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_SET_VARIABLE): New macro.
99310         * m4/arpa_inet_h.m4 (gl_ARPA_INET_MODULE_INDICATOR): Use it.
99311         * m4/ctype.m4 (gl_CTYPE_MODULE_INDICATOR): Likewise.
99312         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Likewise.
99313         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Likewise.
99314         * m4/iconv_h.m4 (gl_ICONV_MODULE_INDICATOR): Likewise.
99315         * m4/inttypes.m4 (gl_INTTYPES_MODULE_INDICATOR): Likewise.
99316         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Likewise.
99317         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Likewise.
99318         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Likewise.
99319         * m4/netdb_h.m4 (gl_NETDB_MODULE_INDICATOR): Likewise.
99320         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Likewise.
99321         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Likewise.
99322         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Likewise.
99323         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Likewise.
99324         * m4/stddef_h.m4 (gl_STDDEF_MODULE_INDICATOR): Likewise.
99325         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Likewise.
99326         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Likewise.
99327         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Likewise.
99328         * m4/strings_h.m4 (gl_STRINGS_MODULE_INDICATOR): Likewise.
99329         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_MODULE_INDICATOR): Likewise.
99330         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Likewise.
99331         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Likewise.
99332         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Likewise.
99333         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Likewise.
99334         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Likewise.
99335         * m4/sys_times_h.m4 (gl_SYS_TIMES_MODULE_INDICATOR): Likewise.
99336         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_MODULE_INDICATOR): Likewise.
99337         * m4/sys_wait_h.m4 (gl_SYS_WAIT_MODULE_INDICATOR): Likewise.
99338         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Likewise.
99339         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Likewise.
99340         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Likewise.
99342 2010-03-27  Bruno Haible  <bruno@clisp.org>
99344         Fix a compilation error on Cygwin with g++ >= 4.3.
99345         * lib/sys_stat.in.h (lchmod): Don't warn about the use of this function
99346         if it is undefined or if we alias it to chmod.
99347         (lstat): Don't warn about the use of this function if it is undefined
99348         or if we alias it to stat.
99349         Reported by Simon Josefsson.
99351 2010-03-27  Bruno Haible  <bruno@clisp.org>
99353         * m4/getlogin.m4 (gl_FUNC_GETLOGIN): Renamed from gl_GETLOGIN.
99354         * modules/getlogin (configure.ac): Update.
99356         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Renamed from gl_GETLOGIN_R.
99357         * modules/getlogin_r (configure.ac): Update.
99359         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Renamed from gl_INET_NTOP.
99360         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Update.
99361         * modules/inet_ntop (configure.ac): Update.
99363         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Renamed from gl_INET_PTON.
99364         * modules/inet_pton (configure.ac): Update.
99366         * m4/mbslen.m4 (gl_FUNC_MBSLEN): Renamed from gl_MBSLEN.
99367         * modules/mbslen (configure.ac): Update.
99369         * m4/pty.m4 (gl_FUNC_FORKPTY): Renamed from gl_FORKPTY.
99370         (gl_FUNC_OPENPTY): Renamed from gl_OPENPTY.
99371         * modules/forkpty (configure.ac): Update.
99372         * modules/openpty (configure.ac): Update.
99374 2010-03-26  Simon Josefsson  <simon@josefsson.org>
99376         * top/maint.mk (sc_texinfo_acronym): Don't infloop if there is
99377         no *.texi files.  Reported by Eric Blake <eblake@redhat.com>.
99379 2010-03-25  Eric Blake  <eblake@redhat.com>
99381         maint: use pragma consistently across replacement headers
99382         * lib/ctype.in.h (system_header): Hoist for consistent placement.
99383         * lib/dirent.in.h (system_header): Likewise.
99384         * lib/errno.in.h (system_header): Likewise.
99385         * lib/float.in.h (system_header): Likewise.
99386         * lib/getopt.in.h (system_header): Likewise.
99387         * lib/iconv.in.h (system_header): Likewise.
99388         * lib/inttypes.in.h (system_header): Likewise.
99389         * lib/langinfo.in.h (system_header): Likewise.
99390         * lib/locale.in.h (system_header): Likewise.
99391         * lib/math.in.h (system_header): Likewise.
99392         * lib/netdb.in.h (system_header): Likewise.
99393         * lib/netinet_in.in.h (system_header): Likewise.
99394         * lib/pty.in.h (system_header): Likewise.
99395         * lib/sched.in.h (system_header): Likewise.
99396         * lib/se-selinux.in.h (system_header): Likewise.
99397         * lib/search.in.h (system_header): Likewise.
99398         * lib/spawn.in.h (system_header): Likewise.
99399         * lib/stdarg.in.h (system_header): Likewise.
99400         * lib/stdint.in.h (system_header): Likewise.
99401         * lib/string.in.h (system_header): Likewise.
99402         * lib/strings.in.h (system_header): Likewise.
99403         * lib/sys_file.in.h (system_header): Likewise.
99404         * lib/sys_ioctl.in.h (system_header): Likewise.
99405         * lib/sys_socket.in.h (system_header): Likewise.
99406         * lib/sys_times.in.h (system_header): Likewise.
99407         * lib/sys_utsname.in.h (system_header): Likewise.
99408         * lib/sys_wait.in.h (system_header): Likewise.
99409         * lib/sysexits.in.h (system_header): Likewise.
99410         * lib/unistd.in.h (system_header): Likewise.
99411         * lib/wctype.in.h (system_header): Likewise.
99413         arpa/inet: fix mingw compilation warning
99414         * lib/arpa_inet.in.h (system_header): Hoist to be unconditional.
99415         Reported by Matthew Bolte.
99417 2010-03-25  Bruno Haible  <bruno@clisp.org>
99419         Avoid collision between gnulib wrapper and libintl wrapper.
99420         * lib/printf.c (printf): Don't define if a printf wrapper is already
99421         defined in intl/printf.c.
99422         Reported by Michel Boaventura <michel@michelboaventura.com>.
99424 2010-03-25  Bruno Haible  <bruno@clisp.org>
99426         Use ANSI C.
99427         * lib/readutmp.h (getutent): Provide ANSI C prototype.
99429 2010-03-25  Bruno Haible  <bruno@clisp.org>
99431         Minor formatting changes.
99432         * lib/acosl.c: Insert space before function argument list.
99433         * lib/argz.c: Likewise.
99434         * lib/asinl.c: Likewise.
99435         * lib/expl.c: Likewise.
99436         * lib/gen-uni-tables.c: Likewise.
99437         * lib/gettext.h: Likewise.
99438         * lib/glthread/lock.h: Likewise.
99439         * lib/tanl.c: Likewise.
99440         * lib/uniname/uniname.c: Likewise.
99441         * tests/test-idpriv-drop.c: Likewise.
99442         * tests/test-idpriv-droptemp.c: Likewise.
99443         * tests/test-lock.c: Likewise.
99444         * tests/test-tls.c: Likewise.
99445         * lib/argp-help.c: Insert space before function-like macro argument
99446         list.
99447         * lib/memcmp.c: Likewise.
99448         * tests/test-base64.c: Likewise.
99449         * lib/localename.c: Insert space before sizeof's argument list.
99450         * lib/safe-alloc.h: Likewise.
99451         * lib/file-set.h: Insert space before macro argument list.
99452         * tests/test-argp.c: Likewise.
99453         * lib/argp-namefrob.h: Insert space before function parameter list.
99454         * lib/getaddrinfo.c: Likewise.
99455         * lib/netdb.in.h: Likewise.
99456         * lib/parse-duration.h: Likewise.
99457         * lib/parse-duration.c: Likewise.
99458         * lib/poll.c: Likewise.
99459         * lib/select.c: Likewise.
99460         * lib/trim.h: Likewise.
99461         * tests/test-usleep.c: Likewise.
99462         * lib/ldexpl.c: Insert space before function parameter list and before
99463         function argument list.
99464         * lib/logl.c: Likewise.
99465         * lib/sqrtl.c: Likewise.
99466         * lib/trim.c: Likewise.
99467         * lib/cosl.c: Use GNU style indentation. Insert space before function
99468         argument list.
99469         * lib/sinl.c: Likewise.
99470         * lib/tsearch.c: Insert space after 'for'.
99471         Reported by Jim Meyering.
99473 2010-03-23  Pádraig Brady  <P@draigBrady.com>  (tiny change)
99475         * maint.mk (sc_Wundef_boolean): Check for the presence of the
99476         config header before grepping, as it's not present before
99477         autoreconf/configure are run.  Reported by Simon Josefsson.
99479 2010-03-23  Bruno Haible  <bruno@clisp.org>
99481         pt_chown: Make it work with automake < 1.11.
99482         * modules/pt_chown (Makefile.am): Define pkglibexecdir.
99483         Reported by Simon Josefsson.
99485 2010-03-23  Bruno Haible  <bruno@clisp.org>
99487         pt_chown: Don't depend on GPLed modules.
99488         * lib/pt_chown.c: Don't include idpriv.h.
99489         (main): Don't drop privileges.
99490         * modules/pt_chown (Depends-on): Remove idpriv-drop.
99491         Reported by Simon Josefsson.
99493 2010-03-24  Simon Josefsson  <simon@josefsson.org>
99495         * top/maint.mk (sc_texinfo_acronym): Add rule, based on
99496         suggestions from karl@freefriends.org (Karl Berry).
99498 2010-03-22  Eric Blake  <eblake@redhat.com>
99500         gethostname: further tweaks
99501         * lib/unistd.in.h (includes): Only worry about <winsock2.h> if we
99502         are overriding gethostname.
99503         Suggested by Bruno Haible.
99505 2010-03-21  Bruno Haible  <bruno@clisp.org>
99507         Fix comments.
99508         * lib/forkpty.c (rpl_forkpty): Fix comment.
99509         * lib/openpty.c (rpl_openpty): Likewise.
99510         Reported by Eric Blake.
99512 2010-03-22  Eric Blake  <eblake@redhat.com>
99514         gethostname: fix build on mingw
99515         * lib/unistd.in.h (includes): Work around fact that mingw
99516         <winsock2.h> re-includes <unistd.h>, by avoiding any
99517         redeclarations if we are being included by <winsock2.h>.
99518         Reported by Matthias Bolte.
99520 2010-03-21  Bruno Haible  <bruno@clisp.org>
99522         forkpty: Provide replacement on AIX, HP-UX, IRIX, Solaris.
99523         * lib/forkpty.c (forkpty): New replacement function, from glibc with
99524         modifications.
99525         * lib/pty.in.h (forkpty): Update declaration. Add comments.
99526         * m4/pty.m4 (gl_FORKPTY): If forkpty is not declared, arrange to
99527         provide the replacement.
99528         * modules/forkpty (Depends-on): Add openpty, login_tty.
99529         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Initialize HAVE_FORKPTY.
99530         * modules/pty (Makefile.am): Substitute HAVE_FORKPTY.
99531         * doc/glibc-functions/forkpty.texi: More supported platforms.
99532         * config/srclist.txt: Add forkpty.c (commented).
99534 2010-03-21  Bruno Haible  <bruno@clisp.org>
99536         * modules/forkpty-tests: Use the common TEMPLATE-TESTS.
99537         (Makefile.am): Verify that PTY_LIB is defined.
99539         * modules/openpty-tests: Use the common TEMPLATE-TESTS.
99541 2010-03-21  Bruno Haible  <bruno@clisp.org>
99543         Tests for module 'login_tty'.
99544         * modules/login_tty-tests: New file.
99545         * tests/test-login_tty.c: New file.
99547         New module 'login_tty'.
99548         * lib/login_tty.c: New file.
99549         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): New macro.
99550         * modules/login_tty: New file.
99551         * doc/glibc-functions/login_tty.texi: Mention the new module.
99553 2010-03-21  Bruno Haible  <bruno@clisp.org>
99555         login_tty: Documentation.
99556         * doc/glibc-functions/login_tty.texi: New file.
99557         * doc/gnulib.texi (Glibc <utmp.h>): Include it.
99559 2010-03-21  Bruno Haible  <bruno@clisp.org>
99561         pty: Consistent macro naming.
99562         * m4/pty_h.m4 (gl_PTY_H): Renamed from gl_PTY.
99563         * m4/pty.m4 (gl_FORKPTY, gl_OPENPTY): Update.
99564         * modules/pty (configure.ac): Update.
99566 2010-03-21  Bruno Haible  <bruno@clisp.org>
99568         Tests for openpty: Make stricter.
99569         * tests/test-openpty.c (main): Add test of canonical processing and
99570         erase.
99571         * modules/openpty-tests (Makefile.am): Verify that PTY_LIB is defined.
99573         openpty: Provide replacement on AIX, HP-UX, IRIX, Solaris.
99574         * lib/openpty.c (openpty): New replacement function.
99575         * lib/pty.in.h: Include <termios.h>.
99576         (openpty): Update declaration. Add comments.
99577         * m4/pty.m4 (gl_OPENPTY): Require AC_USE_SYSTEM_EXTENSIONS. If openpty
99578         is not declared, arrange to provide the replacement. Check for _getpty
99579         and posix_openpt.
99580         * modules/openpty (Depends-on): Add extensions, fcntl-h, ioctl.
99581         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Initialize HAVE_OPENPTY.
99582         * modules/pty (Makefile.am): Substitute HAVE_OPENPTY.
99583         * modules/pty-tests (test_pty_c___LDADD): New variable.
99584         * doc/glibc-functions/openpty.texi: More supported platforms.
99586 2010-03-21  Bruno Haible  <bruno@clisp.org>
99588         setenv: Tweaks.
99589         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Include necessary headers in
99590         the test program.
99591         * doc/posix-functions/setenv.texi: Update platforms list.
99593 2010-03-21  Bruno Haible  <bruno@clisp.org>
99595         New module 'unlockpt'.
99596         * lib/unlockpt.c: New file, from glibc with modifications.
99597         * m4/unlockpt.m4: New file.
99598         * modules/unlockpt: New file.
99599         * lib/stdlib.in.h (unlockpt): New declaration.
99600         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether unlockpt is declared.
99601         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_UNLOCKPT, HAVE_UNLOCKPT.
99602         * modules/stdlib (Makefile.am): Substitute GNULIB_UNLOCKPT,
99603         HAVE_UNLOCKPT.
99604         * doc/posix-functions/unlockpt.texi: Mention the new module.
99605         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::unlockpt.
99606         * config/srclist.txt: Add unlockpt.c (commented).
99608 2010-03-21  Jim Meyering  <meyering@redhat.com>
99610         maint.mk: prohibit inclusion of "intprops.h" without use
99611         * top/maint.mk (sc_prohibit_intprops_without_use): New rule.
99613 2010-03-21  Bruno Haible  <bruno@clisp.org>
99615         New module 'grantpt'.
99616         * lib/grantpt.c: New file, from glibc with modifications.
99617         * m4/grantpt.m4: New file.
99618         * modules/grantpt: New file.
99619         * lib/stdlib.in.h (grantpt): New declaration.
99620         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether grantpt is declared.
99621         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_GRANTPT, HAVE_GRANTPT.
99622         * modules/stdlib (Makefile.am): Substitute GNULIB_GRANTPT,
99623         HAVE_GRANTPT.
99624         * doc/posix-functions/grantpt.texi: Mention the new module.
99625         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::grantpt.
99626         * config/srclist.txt: Add grantpt.c (commented).
99628 2010-03-21  Bruno Haible  <bruno@clisp.org>
99630         New module 'pt_chown'.
99631         * lib/pt_chown.c: New file, from glibc with modifications.
99632         * lib/pty-private.h: New file, from glibc with modifications.
99633         * modules/pt_chown: New file.
99634         * config/srclist.txt: Add pt_chown.c, pty-private.h (commented).
99636 2010-03-21  Bruno Haible  <bruno@clisp.org>
99638         Tests for module 'ptsname'.
99639         * modules/ptsname-tests: New file.
99640         * tests/test-ptsname.c: New file.
99642         New module 'ptsname'.
99643         * lib/ptsname.c: New file, from glibc with modifications.
99644         * m4/ptsname.m4: New file.
99645         * modules/ptsname: New file.
99646         * lib/stdlib.in.h (ptsname): New declaration.
99647         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether ptsname is declared.
99648         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_PTSNAME, HAVE_PTSNAME.
99649         * modules/stdlib (Makefile.am): Substitute GNULIB_PTSNAME,
99650         HAVE_PTSNAME.
99651         * doc/posix-functions/ptsname.texi: Mention the new module.
99652         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::ptsname.
99653         * config/srclist.txt: Add ptsname.c (commented).
99655 2010-03-21  Bruno Haible  <bruno@clisp.org>
99657         Tests for module 'ttyname_r'.
99658         * modules/ttyname_r-tests: New file.
99659         * tests/test-ttyname_r.c: New file.
99661         New module 'ttyname_r'.
99662         * lib/ttyname_r.c: New file.
99663         * m4/ttyname_r.m4: New file.
99664         * modules/ttyname_r: New file.
99665         * lib/unistd.in.h (ttyname_r): New declaration.
99666         * m4/unistd_h.m4 (gl_UNISTD_H): Check whether ttyname_r is declared.
99667         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_TTYNAME_R, HAVE_TTYNAME_R.
99668         * modules/unistd (Makefile.am): Substitute GNULIB_TTYNAME_R,
99669         HAVE_TTYNAME_R.
99670         * tests/test-unistd-c++.cc: Check GNULIB_NAMESPACE::ttyname_r.
99671         * doc/posix-functions/ttyname_r.texi: Mention the new module.
99673 2010-03-20  Bruno Haible  <bruno@clisp.org>
99675         signal: Undefine macro definitions in C++ mode.
99676         * lib/signal.in.h (sigismember, sigemptyset, sigaddset, sigdelset,
99677         sigfillset): Undefine macro definitions from the system header in C++
99678         mode.
99679         Reported by John W. Eaton <jwe@gnu.org>.
99681 2010-03-20  Bruno Haible  <bruno@clisp.org>
99683         Ensure no #include statements inside extern "C" { ... }.
99684         * lib/obstack.h: Shrink extern "C" { ... } region so that it does not
99685         contain #include statements.
99686         * lib/time.in.h: Likewise.
99688 2010-03-20  Bruno Haible  <bruno@clisp.org>
99690         Make _GL_WARN_ON_USE usable in C++ and C mode in the same compilation.
99691         * build-aux/warn-on-use.h (_GL_WARN_EXTERN_C): New macro.
99692         (_GL_WARN_ON_USE, _GL_WARN_ON_USE_CXX): Likewise.
99693         Reported by John W. Eaton <jwe@gnu.org>.
99695 2010-03-20  Bruno Haible  <bruno@clisp.org>
99697         * m4/unlink.m4 (gl_FUNC_UNLINK): Fix last commit.
99698         Reported by Jim Meyering.
99700 2010-03-20  Bruno Haible  <bruno@clisp.org>
99702         pipe: Set errno upon failure.
99703         * lib/pipe.h: Specify that when -1 is returned, errno is set.
99704         * lib/pipe.c (create_pipe): Set errno when returning -1. Use the right
99705         errno value in error message.
99707 2010-03-20  Bruno Haible  <bruno@clisp.org>
99708             Jim Meyering  <meyering@redhat.com>
99710         lchown: Avoid "unused variable" warning.
99711         * lib/lchown.c (rpl_lchown): Move variable 'st' into #if block.
99713 2010-03-20  Bruno Haible  <bruno@clisp.org>
99715         Work around unlink() bug on MacOS X 10.5.6.
99716         * lib/unlink.c (rpl_unlink): If UNLINK_PARENT_BUG is defined, fail when
99717         attempting to unlink a parent directory.
99718         * m4/unlink.m4 (gl_FUNC_UNLINK): Require AC_CANONICAL_HOST. Test for
99719         MacOS X 10.5 bug. If the bug is present, define UNLINK_PARENT_BUG and
99720         activate for the replacement function.
99721         * doc/posix-functions/unlink.texi: Mention the MacOS X 10.5 bug.
99723 2010-03-20  Bruno Haible  <bruno@clisp.org>
99725         Fix link errors on Solaris 8.
99726         * modules/dirent-tests (test_dirent_c___LDADD): Add LIB_NANOSLEEP.
99727         * modules/wctype-tests (test_wctype_c___LDADD): Likewise.
99729 2010-03-19  Jim Meyering  <meyering@redhat.com>
99731         regcomp.c: make non-_LIBC implementation of build_range_exp consistent
99732         The _LIBC implementation of build_range_exp correctly honors the
99733         RE_NO_EMPTY_RANGES flag when checking for reversed range endpoints.
99734         However, the non-_LIBC implementation would ignore that syntax-bit
99735         flag and return REG_ERANGE unconditionally.
99736         This change makes it honor that flag.
99737         * lib/regcomp.c (build_range_exp) [!_LIBC]: Add a parameter: "syntax".
99738         Make two pointer parameters "const".
99739         Use "syntax" bits in order to honor RE_NO_EMPTY_RANGES.
99740         (parse_bracket_exp): Update caller.
99742         regex.m4: correct the reversed range endpoint ([b-a]) test
99743         * m4/regex.m4: When requiring that [b-a] evoke failure,
99744         use RE_NO_EMPTY_RANGES.  This makes this entire configure-time
99745         test pass once again for x86-based systems.
99747 2010-03-19  Bruno Haible  <bruno@clisp.org>
99749         scandir: Fix link error on Solaris 8.
99750         * lib/scandir.c (_D_EXACT_NAMLEN, _D_ALLOC_NAMLEN): New fallback
99751         macros.
99753 2010-03-19  Bruno Haible  <bruno@clisp.org>
99755         getusershell: Fix documentation.
99756         * doc/glibc-functions/endusershell.texi: Refer to the getusershell
99757         module.
99758         * doc/glibc-functions/setusershell.texi: Likewise.
99760         getusershell: Provide declaration, missing on Solaris 9.
99761         * lib/unistd.in.h (getusershell, setusershell, endusershell): Declare
99762         also if HAVE_GETUSERSHELL && !HAVE_DECL_GETUSERSHELL.
99763         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): When the function exists,
99764         check whether it is declared. Set HAVE_DECL_GETUSERSHELL.
99765         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
99766         HAVE_DECL_GETUSERSHELL, not HAVE_GETUSERSHELL.
99767         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETUSERSHELL, not
99768         HAVE_GETUSERSHELL.
99769         * doc/glibc-functions/getusershell.texi: Mention the Solaris problem.
99771 2010-03-19  Bruno Haible  <bruno@clisp.org>
99773         wctype: Provide iswblank function.
99774         * lib/wctype.in.h (iswblank): Provide a replacement also when iswcntrl
99775         exists and is fine.
99776         * m4/wctype_h.m4 (gl_WCTYPE_H): Also check whether iswcntrl exists.
99777         * modules/wctype (Makefile.am): Substitute HAVE_ISWBLANK.
99778         * tests/test-wctype.c (main): Re-enable the iswblank tests.
99779         * doc/posix-functions/iswblank.texi: Update.
99781 2010-03-19  Bruno Haible  <bruno@clisp.org>
99783         Tests of module 'pty' in C++ mode.
99784         * modules/pty-tests: New file.
99785         * tests/test-pty-c++.cc: New file.
99786         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
99788 2010-03-19  Eric Blake  <eblake@redhat.com>
99790         logb: fix documentation
99791         * doc/posix-functions/logb.texi (logb): Gnulib fixes the cygwin
99792         1.5 declaration bug.
99794         forkpty, openpty: prefer glibc's const-safe prototype
99795         * lib/forkpty.c (rpl_forkpty): New file.
99796         * lib/openpty.c (rpl_openpty): Likewise.
99797         * modules/forkpty (Files): Distribute it.
99798         * modules/openpty (Files): Likewise.
99799         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Add new witnesses.  Move decl
99800         check...
99801         * m4/pty.m4 (gl_FORKPTY, gl_OPENPTY): ...here.  Request
99802         replacement for non-const BSD signature.
99803         * modules/pty (Makefile.am): Substitute witnesses.
99804         * lib/pty.in.h (forkpty, openpty): Declare replacements.
99805         * tests/test-forkpty.c: Update signature check.
99806         * tests/test-openpty.c: Likewise.
99807         * doc/glibc-functions/forkpty.texi (forkpty): Document the fix.
99808         * doc/glibc-functions/openpty.texi (openpty): Likewise.
99810         forkpty, openpty: split functions into new modules
99811         * modules/pty (Makefile.am): Substitute new witnesses.
99812         (Libraries): Move library detection...
99813         * modules/forkpty: ...into new module.
99814         * modules/openpty: Another new module.
99815         * modules/pty-tests: Rename and split...
99816         * modules/forkpty-tests: ...to this...
99817         * modules/openpty-tests: ...and this.
99818         * tests/test-pty.c: Rename and split...
99819         * tests/test-forkpty.c: ...to this...
99820         * tests/test-openpty.c: ...and this.
99821         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Add new witnesses.
99822         (gl_PTY): Split library searching...
99823         * m4/pty.m4 (gl_PTY_LIB): ...into new file.
99824         (gl_FORKPTY, gl_OPENPTY): New macros.
99825         * lib/pty.in.h (forkpty, openpty): Honor new witnesses.
99826         * NEWS: Mention the split.
99827         * MODULES.html.sh (Misc): Document the modules.
99828         * doc/glibc-functions/forkpty.texi (forkpty): Likewise.
99829         * doc/glibc-functions/openpty.texi (openpty): Likewise.
99831         pty: improve replacement header
99832         * lib/pty.in.h: New file.
99833         * modules/pty (Files): Ship it.
99834         (Makefile.am): Always build replacement.
99835         * m4/pty.m4: Rename...
99836         * m4/pty_h.m4: ...to this.
99837         (gl_PTY): Modernize setting of witness macros; update check of
99838         forkpty to take proper advantage of cache.
99839         (gl_PTY_MODULE_INDICATOR, gl_PTY_H_DEFAULTS): New macros.
99841         getopt: avoid compiler warning
99842         * lib/getopt.c (attribute_hidden): Remove unused macro.
99844 2010-03-18  Bruno Haible  <bruno@clisp.org>
99846         Fix link errors on Solaris 8.
99847         * modules/iconv-h-tests (test_iconv_h_c___LDADD): Add LIB_NANOSLEEP.
99848         * modules/search-tests (test_search_c___LDADD): Likewise.
99849         * modules/signal-tests (test_signal_c___LDADD): Likewise.
99850         * modules/spawn-tests (test_spawn_c___LDADD): Likewise.
99851         * modules/stdio-tests (test_stdio_c___LDADD): Likewise.
99852         * modules/sys_select-tests (test_sys_select_c___LDADD): Likewise.
99853         * modules/sys_socket-tests (test_sys_socket_c___LDADD): Likewise.
99854         * modules/sys_time-tests (test_sys_time_c___LDADD): Likewise.
99855         * modules/wchar-tests (test_wchar_c___LDADD): Likewise.
99857 2010-03-18  Bruno Haible  <bruno@clisp.org>
99859         Fix bug introduced on 2010-03-14.
99860         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): New macro.
99861         (gl_SPAWN_H): Require it.
99862         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Likewise.
99863         Reported by Simon Josefsson.
99865 2010-03-18  Bruno Haible  <bruno@clisp.org>
99867         Fix typo introduced on 2009-12-31.
99868         * m4/spawn_h.m4 (gl_SPAWN_H): Check for the declaration of
99869         posix_spawn_file_actions_adddup2.
99871 2010-03-17  Bert Wesarg  <bert.wesarg@googlemail.com>  (tiny change)
99872         and Eric Blake  <eblake@redhat.com>
99874         test-vc-list-files-git: make more robust
99875         * tests/test-vc-list-files-git.sh: Unset problematic environment
99876         variables.  Chain commands together.
99878 2010-03-17  Ludovic Courtès  <ludo@gnu.org>  (tiny change)
99880         * m4/pty.m4: Unset $ac_cv_have_decl_forkpty before the second
99881         `AC_CHECK_DECL' invocation.
99883 2010-03-15  Sergey Poznyakoff  <gray@gnu.org.ua>
99885         * lib/inttostr.c (inttostr): Make sure the invocation of verify
99886         appears before executable statements. Suggested by Petr Sumbera
99887         <Petr.Sumbera@Sun.COM>.
99889 2010-03-14  Bruno Haible  <bruno@clisp.org>
99891         * tests/test-flock.c (test_exclusive): Comment out a test that causes
99892         portability problems. Instead use a simpler test.
99893         (main): Check that invalid arguments are rejected only on Linux.
99895 2010-03-14  Bruno Haible  <bruno@clisp.org>
99897         Fix bug introduced on 2009-12-31.
99898         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Invoke
99899         gl_PREREQ_SYS_H_WINSOCK2 always.
99900         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise. Remove
99901         SYS_SOCKET_H variable.
99902         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Remove test for flock.
99903         Update comments.
99904         * m4/ctype.m4 (gl_CTYPE_H): Update comments.
99905         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
99906         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
99907         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
99908         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H): Likewise.
99910 2010-03-14  Bruno Haible  <bruno@clisp.org>
99912         Fix values returned by sinl, cosl.
99913         * lib/trigl.h: Add specification comments.
99914         * lib/sincosl.c (kernel_sinl, kernel_cosl): Fix comments and formula
99915         that combines the values from the precomputed table with the values of
99916         the Chebyshev polynomials.
99918 2010-03-14  Bruno Haible  <bruno@clisp.org>
99920         Fix compilation error when modules 'posix_spawn[p]' are not used.
99921         * m4/spawn_h.m4 (gl_SPAWN_H): Set HAVE_POSIX_SPAWN here.
99922         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): ... not here.
99924 2010-03-14  Bruno Haible  <bruno@clisp.org>
99926         Fix compilation error on mingw when module 'time_r' is not used.
99927         * lib/time.in.h (localtime_r, gmtime_r): Declare only if GNULIB_TIME_R
99928         is 1.
99929         * tests/test-time-c++.cc (localtime_r, gmtime_r): Likewise.
99930         * modules/time_r (configure.ac): Invoke gl_TIME_MODULE_INDICATOR.
99931         * modules/time (Makefile.am): Substitute GNULIB_TIME_R.
99932         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_TIME_R.
99934 2010-03-14  Bruno Haible  <bruno@clisp.org>
99936         Fix compilation error with Sun C.
99937         * lib/strtol.c: Use LLONG_MIN instead of GCC specific LONG_LONG_MIN.
99938         Use LLONG_MAX instead of GCC specific LONG_LONG_MAX. Use ULLONG_MAX
99939         instead of GCC specific ULONG_LONG_MAX.
99940         * lib/xstrtoll.c: Likewise.
99941         * lib/xstrtoull.c: Likewise.
99943 2010-03-13  Bruno Haible  <bruno@clisp.org>
99945         Allow the user to disable C++ code and tests.
99946         * m4/ansi-c++.m4 (gl_CXX_CHOICE): New macro.
99947         (gl_PROG_ANSI_CXX): Require it.
99949 2010-03-13  Bruno Haible  <bruno@clisp.org>
99951         * DEPENDENCIES (libtool): Mention libtool 2.2.x requirement in special
99952         cases.
99954 2010-03-13  Bruno Haible  <bruno@clisp.org>
99956         Test that gnulib does not break the standard C++ headers.
99957         * tests/test-locale-c++2.cc: New file.
99958         * modules/locale-tests (Files): Add it.
99959         (Makefile.am): Compile it for test-locale-c++.
99960         * tests/test-math-c++2.cc: New file.
99961         * modules/math-tests (Files): Add it.
99962         (Makefile.am): Compile it for test-math-c++.
99963         * tests/test-signal-c++2.cc: New file.
99964         * modules/signal-tests (Files): Add it.
99965         (Makefile.am): Compile it for test-signal-c++.
99966         * tests/test-stdio-c++2.cc: New file.
99967         * modules/stdio-tests (Files): Add it.
99968         (Makefile.am): Compile it for test-stdio-c++.
99969         * tests/test-stdlib-c++2.cc: New file.
99970         * modules/stdlib-tests (Files): Add it.
99971         (Makefile.am): Compile it for test-stdlib-c++.
99972         * tests/test-string-c++2.cc: New file.
99973         * modules/string-tests (Files): Add it.
99974         (Makefile.am): Compile it for test-string-c++.
99975         * tests/test-time-c++2.cc: New file.
99976         * modules/time-tests (Files): Add it.
99977         (Makefile.am): Compile it for test-time-c++.
99978         Reported by John W. Eaton <jwe@gnu.org>.
99980 2010-03-13  Bruno Haible  <bruno@clisp.org>
99982         * gnulib-tool (func_usage): Clarify which options are available for
99983         --create-testdir and --create-megatestdir.
99985 2010-03-13  Bruno Haible  <bruno@clisp.org>
99987         Fix compilation error with glibc >= 2.10 and g++ >= 4.4.
99988         * build-aux/warn-on-use.h (_GL_WARN_ON_USE_CXX): New macro.
99989         * build-aux/c++defs.h (_GL_CXXALIASWARN1): New macro.
99990         * lib/string.in.h (memchr, memrchr, rawmemchr, strchrnul, strpbrk,
99991         strstr, strcasestr): Use _GL_CXXALIASWARN1 instead of _GL_CXXALIASWARN
99992         when appropriate.
99993         Reported by Jim Meyering.
99995 2010-03-12  Simon Josefsson  <simon@josefsson.org>
99997         * gnulib-tool (func_import): Explain origin of code.
99999 2010-03-12  Bruno Haible  <bruno@clisp.org>
100001         Fix problem with automake's definition of CXXLINK.
100002         * gnulib-tool (func_create_testdir): After LT_INIT, also use LT_LANG.
100003         Reported by Simon Josefsson and Ludovic Courtès.
100005 2010-03-12  Bruno Haible  <bruno@clisp.org>
100007         * doc/gnulib-intro.texi (Steady Development): Mention Ian Beckwith's
100008         stable releases.
100010 2010-03-11  Bruno Haible  <bruno@clisp.org>
100012         Fix problems with overloaded C++ definitions of memchr, strpbrk, etc.
100013         * build-aux/c++defs.h (_GL_CXXALIAS_SYS_CAST2): Make it work regardless
100014         whether the system provides one variant or multiple variants of the
100015         function.
100016         * lib/string.in.h (memchr, strpbrk): Use _GL_CXXALIAS_SYS_CAST2 for all
100017         C++ compilers.
100018         (memrchr, rawmemchr, strchrnul, strstr, strcasestr): Use
100019         _GL_CXXALIAS_SYS_CAST2 instead of _GL_CXXALIAS_SYS.
100020         Reported by Jim Meyering.
100022 2010-03-09  Simon Josefsson  <simon@josefsson.org>
100024         * gnulib-tool (LIBTOOLPATH): Fix cut'n'paste bug.
100026 2010-03-08  Bruno Haible  <bruno@clisp.org>
100028         gnulib-tool: Add support for --libtool in --create-testdir.
100029         * gnulib-tool (LIBTOOLPATH, LIBTOOLIZE): New variables.
100030         (func_create_testdir): Emit LT_INIT invocations. Invoke LIBTOOLIZE.
100032 2010-03-08  Eric Blake  <eblake@redhat.com>
100034         gnulib-tool.texi: mention possibility of git submodule
100035         * doc/gnulib-tool.texi (VCS Issues): Add details about using git
100036         submodules.
100037         * doc/.gitignore: Ignore another generated file.
100039 2010-03-08  Karl Berry  <karl@gnu.org>
100041         * doc/gnulib-tool.texi (VCS Issues): Mention third option
100042         of committing gnulib files while skipping others.
100044 2010-03-07  Bruno Haible  <bruno@clisp.org>
100046         Tests of module 'wctype' in C++ mode.
100047         * tests/test-wctype-c++.cc: New file.
100048         * modules/wctype-tests (Files): Add it and tests/signature.h.
100049         (Depends-on): Add ansi-c++-opt.
100050         (Makefile.am): Arrange to compile and run test-wctype-c++.
100052         Tests of module 'wchar' in C++ mode.
100053         * tests/test-wchar-c++.cc: New file.
100054         * modules/wchar-tests (Files): Add it and tests/signature.h.
100055         (Depends-on): Add ansi-c++-opt.
100056         (Makefile.am): Arrange to compile and run test-wchar-c++.
100057         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Invoke
100058         gl_MODULE_INDICATOR.
100060         Tests of module 'unistd' in C++ mode.
100061         * tests/test-unistd-c++.cc: New file.
100062         * modules/unistd-tests (Files): Add it and tests/signature.h.
100063         (Depends-on): Add ansi-c++-opt.
100064         (Makefile.am): Arrange to compile and run test-unistd-c++.
100065         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Invoke
100066         gl_MODULE_INDICATOR.
100068         Tests of module 'time' in C++ mode.
100069         * tests/test-time-c++.cc: New file.
100070         * modules/time-tests (Files): Add it and tests/signature.h.
100071         (Depends-on): Add ansi-c++-opt.
100072         (Makefile.am): Arrange to compile and run test-time-c++.
100073         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
100075         Tests of module 'sys_time' in C++ mode.
100076         * tests/test-sys_time-c++.cc: New file.
100077         * modules/sys_time-tests (Files): Add it and tests/signature.h.
100078         (Depends-on): Add ansi-c++-opt.
100079         (Makefile.am): Arrange to compile and run test-sys_time-c++.
100080         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Invoke
100081         gl_MODULE_INDICATOR.
100083         Tests of module 'sys_stat' in C++ mode.
100084         * tests/test-sys_stat-c++.cc: New file.
100085         * modules/sys_stat-tests (Files): Add it and tests/signature.h.
100086         (Depends-on): Add ansi-c++-opt.
100087         (Makefile.am): Arrange to compile and run test-sys_stat-c++.
100088         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Invoke
100089         gl_MODULE_INDICATOR.
100091         Tests of module 'sys_socket' in C++ mode.
100092         * tests/test-sys_socket-c++.cc: New file.
100093         * modules/sys_socket-tests (Files): Add it and tests/signature.h.
100094         (Depends-on): Add ansi-c++-opt.
100095         (Makefile.am): Arrange to compile and run test-sys_socket-c++.
100096         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Invoke
100097         gl_MODULE_INDICATOR.
100099         Tests of module 'sys_select' in C++ mode.
100100         * tests/test-sys_select-c++.cc: New file.
100101         * modules/sys_select-tests (Files): Add it and tests/signature.h.
100102         (Depends-on): Add ansi-c++-opt.
100103         (Makefile.am): Arrange to compile and run test-sys_select-c++.
100104         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Invoke
100105         gl_MODULE_INDICATOR.
100107         Tests of module 'sys_ioctl' in C++ mode.
100108         * tests/test-sys_ioctl-c++.cc: New file.
100109         * modules/sys_ioctl-tests (Files): Add it and tests/signature.h.
100110         (Depends-on): Add ansi-c++-opt.
100111         (Makefile.am): Arrange to compile and run test-sys_ioctl-c++.
100112         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Invoke
100113         gl_MODULE_INDICATOR.
100115         Tests of module 'string' in C++ mode.
100116         * tests/test-string-c++.cc: New file.
100117         * modules/string-tests (Files): Add it and tests/signature.h.
100118         (Depends-on): Add ansi-c++-opt.
100119         (Makefile.am): Arrange to compile and run test-string-c++.
100120         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Invoke
100121         gl_MODULE_INDICATOR.
100123         Tests of module 'stdlib' in C++ mode.
100124         * tests/test-stdlib-c++.cc: New file.
100125         * modules/stdlib-tests (Files): Add it and tests/signature.h.
100126         (Depends-on): Add ansi-c++-opt.
100127         (Makefile.am): Arrange to compile and run test-stdlib-c++.
100128         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Invoke
100129         gl_MODULE_INDICATOR.
100131         Tests of module 'stdio' in C++ mode.
100132         * tests/test-stdio-c++.cc: New file.
100133         * modules/stdio-tests (Files): Add it and tests/signature.h.
100134         (Depends-on): Add ansi-c++-opt.
100135         (Makefile.am): Arrange to compile and run test-stdio-c++.
100136         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Invoke
100137         gl_MODULE_INDICATOR.
100139         Tests of module 'spawn' in C++ mode.
100140         * tests/test-spawn-c++.cc: New file.
100141         * modules/spawn-tests (Files): Add it and tests/signature.h.
100142         (Depends-on): Add ansi-c++-opt.
100143         (Makefile.am): Arrange to compile and run test-spawn-c++.
100144         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Invoke
100145         gl_MODULE_INDICATOR.
100147         Tests of module 'signal' in C++ mode.
100148         * tests/test-signal-c++.cc: New file.
100149         * modules/signal-tests (Files): Add it and tests/signature.h.
100150         (Depends-on): Add ansi-c++-opt.
100151         (Makefile.am): Arrange to compile and run test-signal-c++.
100152         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Invoke
100153         gl_MODULE_INDICATOR.
100155         Tests of module 'search' in C++ mode.
100156         * tests/test-search-c++.cc: New file.
100157         * modules/search-tests (Files): Add it and tests/signature.h.
100158         (Depends-on): Add ansi-c++-opt.
100159         (Makefile.am): Arrange to compile and run test-search-c++.
100160         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Invoke
100161         gl_MODULE_INDICATOR.
100163         Tests of module 'math' in C++ mode.
100164         * tests/test-math-c++.cc: New file.
100165         * modules/math-tests (Files): Add it and tests/signature.h.
100166         (Depends-on): Add ansi-c++-opt.
100167         (Makefile.am): Arrange to compile and run test-math-c++.
100168         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
100170         Tests of module 'locale' in C++ mode.
100171         * tests/test-locale-c++.cc: New file.
100172         * modules/locale-tests (Files): Add it and tests/signature.h.
100173         (Depends-on): Add ansi-c++-opt.
100174         (Makefile.am): Arrange to compile and run test-locale-c++.
100175         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Invoke
100176         gl_MODULE_INDICATOR.
100178         Tests of module 'langinfo' in C++ mode.
100179         * tests/test-langinfo-c++.cc: New file.
100180         * modules/langinfo-tests (Files): Add it and tests/signature.h.
100181         (Depends-on): Add ansi-c++-opt.
100182         (Makefile.am): Arrange to compile and run test-langinfo-c++.
100183         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Invoke
100184         gl_MODULE_INDICATOR.
100186         Tests of module 'iconv-h' in C++ mode.
100187         * tests/test-iconv-h-c++.cc: New file.
100188         * modules/iconv-h-tests (Files): Add it and tests/signature.h.
100189         (Depends-on): Add ansi-c++-opt.
100190         (Makefile.am): Arrange to compile and run test-iconv-h-c++.
100192         Tests of module 'glob' in C++ mode.
100193         * tests/test-glob-c++.cc: New file.
100194         * modules/glob-tests (Files): Add it.
100195         (Depends-on): Add ansi-c++-opt.
100196         (Makefile.am): Arrange to compile and run test-glob-c++.
100198         Tests of module 'fcntl-h' in C++ mode.
100199         * tests/test-fcntl-h-c++.cc: New file.
100200         * modules/fcntl-h-tests (Files): Add it and tests/signature.h.
100201         (Depends-on): Add ansi-c++-opt.
100202         (Makefile.am): Arrange to compile and run test-fcntl-h-c++.
100203         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Invoke
100204         gl_MODULE_INDICATOR.
100206         Tests of module 'dirent' in C++ mode.
100207         * tests/test-dirent-c++.cc: New file.
100208         * modules/dirent-tests (Files): Add it and tests/signature.h.
100209         (Depends-on): Add ansi-c++-opt.
100210         (Makefile.am): Arrange to compile and run test-dirent-c++.
100211         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Invoke
100212         gl_MODULE_INDICATOR.
100214         New module 'ansi-c++-opt'.
100215         * modules/ansi-c++-opt: New file.
100216         * m4/ansi-c++.m4: New file, from GNU gettext with modifications.
100218         Document C++ namespace mode.
100219         * doc/gnulib.texi (A C++ namespace for gnulib): New section.
100221         wctype: Avoid #define replacements in C++ mode.
100222         * lib/wctype.in.h: Include c++defs.h, warn-on-use.h.
100223         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower,
100224         iswprint, iswpunct, iswspace, iswupper, iswxdigit, towlower, towupper):
100225         In C++, define a namespaced alias symbol.
100226         * m4/wctype_h.m4 (gl_WCTYPE_H): Don't set WCTYPE_H.
100227         * modules/wctype (Depends-on): Add c++defs, warn-on-use.
100228         (Makefile.am): Provide a wctype.h replacement always. Update wctype.h
100229         rule.
100231         wchar: Avoid #define replacements in C++ mode.
100232         * lib/wchar.in.h: Include c++defs.h.
100233         (btowc, wctob, mbsinit, mbrtowc, mbrlen, mbsrtowcs, mbsnrtowcs,
100234         wcrtomb, wcsrtombs, wcsnrtombs): In C++, define a namespaced alias
100235         symbol.
100236         (wcwidth): Likewise. Fix prototype to be POSIX compliant.
100237         * modules/wchar (Depends-on): Add c++defs.
100238         (Makefile.am): Update wchar.h rule.
100240         unistd: Avoid #define replacements in C++ mode.
100241         * lib/unistd.in.h: Include c++defs.h.
100242         (chown, close, dup, dup2, dup3, euidaccess, faccessat, fchdir,
100243         fchownat, fsync, ftruncate, getcwd, getdomainname, getdtablesize,
100244         getgroups, gethostname, getlogin, getlogin_r, getpagesize,
100245         getusershell, setusershell, endusershell, lchown, link, linkat, lseek,
100246         pipe2, pread, readlink, readlinkat, rmdir, sleep, symlink, symlinkat,
100247         unlink, unlinkat, usleep, write): In C++, define a namespaced alias
100248         symbol.
100249         (environ): Update.
100250         * modules/unistd (Depends-on): Add c++defs.
100251         (Makefile.am): Update unistd.h rule.
100253         time: Avoid #define replacements in C++ mode.
100254         * lib/time.in.h: Include c++defs.h, warn-on-use.h.
100255         (nanosleep, mktime, localtime_r, gmtime_r, strptime, timegm): In C++,
100256         define a namespaced alias symbol.
100257         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): New macro.
100258         (gl_HEADER_TIME_H_DEFAULTS): Initialize also GNULIB_MKTIME,
100259         GNULIB_NANOSLEEP, GNULIB_STRPTIME, GNULIB_TIMEGM.
100260         * modules/time (Depends-on): Add c++defs, warn-on-use.
100261         (Makefile.am): Update time.h rule.
100262         * modules/mktime (configure.ac): Invoke gl_TIME_MODULE_INDICATOR.
100263         * modules/nanosleep (configure.ac): Likewise.
100264         * modules/strptime (configure.ac): Likewise.
100265         * modules/timegm (configure.ac): Likewise.
100267         sys_time: Avoid #define replacements in C++ mode.
100268         * lib/sys_time.in.h: Include c++defs.h.
100269         (gettimeofday): In C++, define a namespaced alias symbol.
100270         * modules/sys_time (Depends-on): Add c++defs.
100271         (Makefile.am): Update sys/time.h rule.
100273         sys_stat: Avoid #define replacements in C++ mode.
100274         * lib/sys_stat.in.h: Include c++defs.h.
100275         (fchmodat, fstat, fstatat, futimens, lchmod, lstat, mkdir, mkdirat,
100276         mkfifo, mkfifoat, mknod, mknodat, utimensat): In C++, define a
100277         namespaced alias symbol.
100278         In C++, define a namespaced alias symbol.
100279         * modules/sys_stat (Depends-on): Add c++defs.
100280         (Makefile.am): Update sys/stat.h rule.
100282         sys_socket: Avoid #define replacements in C++ mode.
100283         * lib/sys_socket.in.h: Handle the case of recursive include on Cygwin.
100284         Include c++defs.h. Include warn-on-use.h earlier. Enable the function
100285         definitions also when the system has a <sys/socket.h>.
100286         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
100287         listen, recv, send, recvfrom, sendto, setsockopt, shutdown, accept4):
100288         In C++, define a namespaced alias symbol.
100289         * modules/sys_socket (Depends-on): Add c++defs.
100290         (Makefile.am): Update sys/socket.h rule.
100292         sys_select: Avoid #define replacements in C++ mode.
100293         * lib/sys_select.in.h: Include c++defs.h. Enable the function
100294         definitions also when the system has a <sys/select.h>.
100295         (select): In C++, define a namespaced alias symbol.
100296         * modules/sys_select (Depends-on): Add c++defs.
100297         (Makefile.am): Update sys/select.h rule.
100299         sys_ioctl: Avoid #define replacements in C++ mode.
100300         * lib/sys_ioctl.in.h: Include c++defs.h.
100301         (ioctl): In C++, define a namespaced alias symbol.
100302         * modules/sys_ioctl (Depends-on): Add c++defs.
100303         (Makefile.am): Update sys/ioctl.h rule.
100305         string: Avoid #define replacements in C++ mode.
100306         * lib/string.in.h: Include c++defs.h.
100307         (stpncpy): Define to rpl_stpncpy, not gnu_stpncpy.
100308         (memchr, memmem, mempcpy, memrchr, rawmemchr, stpcpy, stpncpy,
100309         strchrnul, strdup, strndup, strnlen, strpbrk, strsep, strstr,
100310         strcasestr, strtok_r, mbslen, mbschr, mbsrchr, mbspbrk, strerror,
100311         strsignal, strverscmp): In C++, define a namespaced alias symbol.
100312         * modules/string (Depends-on): Add c++defs.
100313         (Makefile.am): Update string.h rule.
100315         stdlib: Avoid #define replacements in C++ mode.
100316         * lib/stdlib.in.h: Include c++defs.h.
100317         (atoll, calloc, canonicalize_file_name, getloadavg, getsubopt, malloc,
100318         mkdtemp, mkostemp, mkostemps, mkstemp, mkstemps, putenv, random_r,
100319         srandom_r, initstate_r, setstate_r, realloc, realpath, rpmatch, setenv,
100320         strtod, strtoll, strtoull, unsetenv): In C++, define a namespaced alias
100321         symbol.
100322         * modules/stdlib (Depends-on): Add c++defs.
100323         (Makefile.am): Update stdlib.h rule.
100325         stdio: Avoid #define replacements in C++ mode.
100326         * lib/stdio.in.h: Include c++defs.h.
100327         (dprintf, fclose, fflush, fopen, fprintf, fpurge, fputc, fputs,
100328         freopen, fseek, fseeko, ftell, ftello, fwrite, getdelim, getline,
100329         obstack_printf, obstack_vprintf, perror, popen, printf, fputc, putchar,
100330         puts, remove, rename, renameat, snprintf, sprintf, asprintf, vasprintf,
100331         vdprintf, vfprintf, vprintf, vsnprintf, vsprintf): In C++, define a
100332         namespaced alias symbol.
100333         * modules/stdio (Depends-on): Add c++defs.
100334         (Makefile.am): Update stdio.h rule.
100336         spawn: Avoid #define replacements in C++ mode.
100337         * lib/spawn.in.h: Include c++defs.h.
100338         (posix_spawn, posix_spawnp, posix_spawnattr_init,
100339         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
100340         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
100341         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
100342         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
100343         posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy,
100344         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
100345         posix_spawnattr_setschedparam, posix_spawn_file_actions_init,
100346         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addopen,
100347         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
100348         In C++, define a namespaced alias symbol.
100349         * modules/spawn (Depends-on): Add c++defs.
100350         (Makefile.am): Update spawn.h rule.
100352         signal: Avoid #define replacements in C++ mode.
100353         * lib/signal.in.h: Include c++defs.h.
100354         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset,
100355         sigpending, sigprocmask, signal, raise, sigaction): In C++, define a
100356         namespaced alias symbol.
100357         * modules/signal (Depends-on): Add c++defs.
100358         (Makefile.am): Update signal.h rule.
100360         search: Avoid #define replacements in C++ mode.
100361         * lib/search.in.h: Include c++defs.h.
100362         (_gl_search_compar_fn, _gl_search_action_fn): New types.
100363         (tsearch, tfind, tdelete, twalk): In C++, define a namespaced alias
100364         symbol.
100365         * modules/search (Depends-on): Add c++defs.
100366         (Makefile.am): Update search.h rule.
100368         math: Avoid #define replacements in C++ mode.
100369         * lib/math.in.h: Include c++defs.h.
100370         (frexp, acosl, asinl, atanl, ceilf, ceill, cosl, expl, floorf, floorl,
100371         frexpl, ldexpl, logl, roundf, round, roundl, sinl, sqrtl, tanl, truncf,
100372         trunc, truncl): In C++, define a namespaced alias symbol.
100373         * modules/math (Depends-on): Add c++defs.
100374         (Makefile.am): Update math.h rule.
100376         locale: Avoid #define replacements in C++ mode.
100377         * lib/locale.in.h: Include c++defs.h.
100378         (duplocale): In C++, define a namespaced alias symbol.
100379         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize HAVE_DUPLOCALE.
100380         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Set HAVE_DUPLOCALE.
100381         * modules/locale (Depends-on): Add c++defs.
100382         (Makefile.am): Update locale.h rule. Substitute HAVE_DUPLOCALE.
100384         langinfo: Avoid #define replacements in C++ mode.
100385         * lib/langinfo.in.h: Include c++defs.h.
100386         (nl_langinfo): In C++, define a namespaced alias symbol.
100387         * modules/langinfo (Depends-on): Add c++defs.
100388         (Makefile.am): Update langinfo.h rule.
100390         iconv-h: Avoid #define replacements in C++ mode.
100391         * lib/iconv.in.h: Include c++defs.h, warn-on-use.h.
100392         (iconv_open, iconv, iconv_close): In C++, define a namespaced alias
100393         symbol.
100394         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H
100395         whenever iconv is present.
100396         * modules/iconv-h (Depends-on): Add c++defs, warn-on-use.
100397         (Makefile.am): Update iconv.h rule.
100399         glob: Avoid #define replacements in C++ mode.
100400         * lib/glob.in.h: Include c++defs.h, warn-on-use.h.
100401         (_gl_glob_errfunc_fn): New type.
100402         (glob, globfree, glob_pattern_p): In C++, define a namespaced alias
100403         symbol.
100404         * modules/glob (Depends-on): Add c++defs, warn-on-use.
100405         (Makefile.am): Update glob.h rule.
100407         fcntl-h: Avoid #define replacements in C++ mode.
100408         * lib/fcntl.in.h: Include c++defs.h.
100409         (fcntl, open, openat): In C++, define a namespaced alias symbol.
100410         * modules/fcntl-h (Depends-on): Add c++defs.
100411         (Makefile.am): Update fcntl.h rule.
100413         dirent: Avoid #define replacements in C++ mode.
100414         * lib/dirent.in.h: Include c++defs.h.
100415         (closedir, fdopendir, opendir, scandir, alphasort): In C++, define a
100416         namespaced alias symbol.
100417         (dirfd): Update declaration.
100418         * modules/dirent (Depends-on): Add c++defs.
100419         (Makefile.am): Update dirent.h rule.
100421         ctype: Make it usable in C++ code.
100422         * lib/ctype.in.h: Include c++defs.h.
100423         (isblank): Declare as extern "C".
100424         * modules/ctype (Depends-on): Add c++defs.
100425         (Makefile.am): Update ctype.h rule.
100427         New module 'c++defs'.
100428         * modules/c++defs: New file.
100429         * build-aux/c++defs.h: New file.
100430         Reported by John W. Eaton <jwe@gnu.org>.
100432 2010-03-07  Bruno Haible  <bruno@clisp.org>
100434         logb: Provide missing declaration for Cygwin.
100435         * lib/math.in.h (logb): New declaration.
100436         * m4/logb.m4: New file.
100437         * modules/logb (Files): Add m4/logb.m4.
100438         (Depends-on): Add math.
100439         (configure.ac): Invoke gl_FUNC_LOGB, gl_MATH_MODULE_INDICATOR.
100440         * m4/math_h.m4 (gl_MATH_H): Check also for logb declaration.
100441         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGB, HAVE_DECL_LOGB.
100442         * modules/math (Makefile.am): Substitute GNULIB_LOGB, HAVE_DECL_LOGB.
100443         * doc/posix-functions/logb.texi: Mention the Cygwin bug.
100445 2010-03-07  Bruno Haible  <bruno@clisp.org>
100447         Fix test-cond link error.
100448         * tests/test-cond.c: Include <stdio.h>.
100450 2010-03-07  Bruno Haible  <bruno@clisp.org>
100452         Fix test-dirent-safer link error.
100453         * modules/dirent-safer-tests (Makefile.am): Define
100454         test_dirent_safer_LDADD.
100456 2010-03-07  Bruno Haible  <bruno@clisp.org>
100458         * gnulib-tool (func_create_testdir): Don't use 'lib-ignore' module
100459         among default module list.
100461 2010-03-07  Bruno Haible  <bruno@clisp.org>
100463         Fix link error on platforms with GNU libiconv.
100464         * modules/unistr/u8-strcoll-tests (Makefile): Define
100465         test_u8_strcoll_LDADD.
100466         * modules/unistr/u16-strcoll-tests (Makefile): Define
100467         test_u16_strcoll_LDADD.
100468         * modules/unistr/u32-strcoll-tests (Makefile): Define
100469         test_u32_strcoll_LDADD.
100471 2010-03-07  Bruno Haible  <bruno@clisp.org>
100473         Use POSIX declarations for socket functions.
100474         * lib/sys_socket.in.h (rpl_connect, rpl_accept, rpl_bind,
100475         rpl_getpeername, rpl_getsockname, rpl_recv, rpl_send, rpl_recvfrom,
100476         rpl_sendto): Change declaration to match POSIX.
100477         * lib/connect.c (rpl_connect): Likewise.
100478         * lib/accept.c (rpl_accept): Likewise.
100479         * lib/bind.c (rpl_bind): Likewise.
100480         * lib/getpeername.c (rpl_getpeername): Likewise.
100481         * lib/getsockname.c (rpl_getsockname): Likewise.
100482         * lib/recv.c (rpl_recv): Likewise.
100483         * lib/send.c (rpl_send): Likewise.
100484         * lib/recvfrom.c (rpl_recvfrom): Likewise.
100485         * lib/sendto.c (rpl_sendto): Likewise.
100487 2010-03-06  Bruno Haible  <bruno@clisp.org>
100489         Clarify access, euidaccess, faccessat.
100490         * doc/posix-functions/faccessat.texi: Mention security problem under
100491         "Other problems", not "Portability problems".
100492         * doc/posix-functions/access.texi: Likewise. Mention a related security
100493         problem.
100494         * doc/glibc-functions/euidaccess.texi: Mention security problems.
100495         * lib/euidaccess.c: Add comments about platforms.
100496         * lib/unistd.in.h (access, euidaccess): Add warnings.
100498 2010-03-07  Bruno Haible  <bruno@clisp.org>
100500         Ensure posix_spawnattr_{get,set}sched{policy,param} are defined.
100501         * lib/spawn.in.h (POSIX_SPAWN_SETSCHEDPARAM): Define fallback.
100502         (POSIX_SPAWN_SETSCHEDULER): Likewise.
100503         (POSIX_SPAWN_USEVFORK): Define in a way that works when
100504         POSIX_SPAWN_SETSCHEDPARAM and POSIX_SPAWN_SETSCHEDULER are zero.
100505         (posix_spawnattr_getschedpolicy, posix_spawnattr_setschedpolicy): Also
100506         declare when POSIX_SPAWN_SETSCHEDULER is zero.
100507         (posix_spawnattr_getschedparam, posix_spawnattr_setschedparam): Also
100508         declare when POSIX_SPAWN_SETSCHEDPARAM is zero.
100509         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test whether
100510         POSIX_SPAWN_SETSCHEDULER or POSIX_SPAWN_SETSCHEDPARAM are zero.
100511         * modules/posix_spawnattr_getschedparam (configure.ac): Enable the
100512         replacement also when POSIX_SPAWN_SETSCHEDPARAM is zero.
100513         * modules/posix_spawnattr_setschedparam (configure.ac): Likewise.
100514         * modules/posix_spawnattr_getschedpolicy (configure.ac): Enable the
100515         replacement also when POSIX_SPAWN_SETSCHEDULER is zero.
100516         * modules/posix_spawnattr_setschedpolicy (configure.ac): Likewise.
100517         * lib/spawnattr_getschedparam.c (posix_spawnattr_getschedparam): Do
100518         nothing if POSIX_SPAWN_SETSCHEDPARAM is zero.
100519         * lib/spawnattr_setschedparam.c (posix_spawnattr_setschedparam):
100520         Likewise.
100521         * lib/spawnattr_getschedpolicy.c (posix_spawnattr_getschedpolicy): Do
100522         nothing if POSIX_SPAWN_SETSCHEDULER is zero.
100523         * lib/spawnattr_setschedpolicy.c (posix_spawnattr_setschedpolicy):
100524         Likewise.
100525         * tests/test-spawn.c (main): Make it work when
100526         POSIX_SPAWN_SETSCHEDPARAM and POSIX_SPAWN_SETSCHEDULER are zero.
100528 2010-03-07  Bruno Haible  <bruno@clisp.org>
100530         Fix incorrect Makefile.am generation in German locale.
100531         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
100532         Execute sed command with character range in C locale.
100534 2010-03-06  Bruno Haible  <bruno@clisp.org>
100536         Tests for module 'iconv-h'.
100537         * modules/iconv-h-tests: New file.
100538         * tests/test-iconv-h.c: New file.
100540         New module 'iconv-h'.
100541         * modules/iconv-h: New file.
100542         * modules/iconv_open (Files): Remove lib/iconv.in.h, m4/iconv_h.m4.
100543         (Depends-on): Add iconv-h. Remove include_next, arg-nonnull.
100544         (configure.ac): Remove gl_ICONV_H.
100545         (Makefile.am): Remove rule for iconv.h.
100547 2010-03-06  Bruno Haible  <bruno@clisp.org>
100549         More consistent naming of *.m4 files.
100550         * m4/wctype_h.m4: Renamed from m4/wctype.m4.
100551         * modules/wctype (Files): Update.
100553         More consistent naming of *.m4 files.
100554         * m4/wchar_h.m4: Renamed from m4/wchar.m4.
100555         * modules/wchar (Files): Update.
100557 2010-03-06  Jim Meyering  <meyering@redhat.com>
100559         euidaccess: relax license to LGPLv2+
100560         * modules/euidaccess (License): Relax to LGPLv2+.
100562 2010-03-06  Bruno Haible  <bruno@clisp.org>
100564         Prefer lib_SOURCES over unconditional AC_LIBOBJ.
100565         * modules/exitfail (configure.ac): Remove AC_LIBOBJ invocation.
100566         (Makefile.am): Augment lib_SOURCES instead.
100568 2010-03-04  Jim Meyering  <meyering@redhat.com>
100570         utime: remove obsolete module
100571         This module, like autoconf's AC_FUNC_UTIME_NULL macro, has been
100572         unnecessary for years, and has been marked as obsolete for 10 months.
100573         * modules/utime: Remove file.
100574         * lib/utime.c: Remove file.
100575         * m4/utime.m4: Remove file.
100576         * m4/utimes-null.m4: Remove file.
100577         * doc/posix-functions/utime.texi (utime): Remove reference to
100578         the module.  Move the sole "fixed by gnulib" item into the
100579         "problems not fixed by Gnulib" list.
100580         * MODULES.html.sh (func_all_modules): Remove reference to "utime".
100582 2010-03-05  Simon Josefsson  <simon@josefsson.org>
100584         * modules/exit (License): Relax license to LGPLv2+.
100585         (Status): Mark as obsolete.
100586         * NEWS: Mention deprecated 'exit' module.
100587         * doc/posix-functions/exit.texi: Recommend 'stdlib' module instead
100588         of now obsolete 'exit'.
100590 2010-03-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
100592         fts-lgpl: remove unused module
100593         * modules/fts-lgpl: Remove.
100594         * MODULES.html.sh (func_all_modules): Adjust.
100595         * check-module (find_included_lib_files): Adjust.
100596         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove.
100598 2010-03-02  Ben Walton  <bwalton@artsci.utoronto.ca>  (tiny change)
100600         copy-acl: enhance Solaris ACL error handling
100601         * lib/copy-acl.c (qcopy_acl): Also ignore EOPNOTSUPP.
100602         * lib/set-mode-acl.c (qset_acl): Likewise.
100604 2010-03-02  Bruno Haible  <bruno@clisp.org>
100606         spawn: Don't override the system defined values on FreeBSD 8.
100607         * lib/spawn.in.h (POSIX_SPAWN_RESETIDS, POSIX_SPAWN_SETPGROUP,
100608         POSIX_SPAWN_SETSIGDEF, POSIX_SPAWN_SETSIGMASK,
100609         POSIX_SPAWN_SETSCHEDPARAM, POSIX_SPAWN_SETSCHEDULER): Don't redefine
100610         if HAVE_POSIX_SPAWN is 1.
100611         Reported by Johan van Selst <johans@stack.nl> via Eric Blake.
100613 2010-03-01  Bruno Haible  <bruno@clisp.org>
100615         * doc/gnulib-tool.texi (Initial import): Clarify the requirements
100616         regarding Automake.
100618 2010-02-25  Bruno Haible  <bruno@clisp.org>
100620         Fix breakage of gnulib-tool with ksh, introduced on 2010-02-21.
100621         * gnulib-tool: Define 'echo' as a function only before the ksh alias
100622         setting, not afterwards.
100623         Reported by Ben Walton <bwalton@artsci.utoronto.ca>.
100625 2010-02-24  Eric Blake  <eblake@redhat.com>
100627         bootstrap, git-version-gen: use timestamp
100628         * build-aux/git-version-gen (scriptversion): Force UTC.
100629         * build-aux/bootstrap (scriptversion): New variable.
100631         bootstrap: allow older git
100632         * build-aux/bootstrap (GNULIB_SRCDIR): Add fallback if git is
100633         older than 1.6.4.  Requested by the libvirt project.
100635 2010-02-23  Eric Blake  <eblake@redhat.com>
100637         warn-on-use: work with old autoconf
100638         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Accomodate older
100639         AS_VAR semantics of autoconf 2.60.
100640         Reported by Bruno Haible.
100642         bootstrap: improve some comments
100643         * build-aux/bootstrap: Drop unneeded emacs hint.  Add some
100644         clarification comments.
100646         gettimeofday: provide correct function
100647         * lib/gettimeofday.c (gettimeofday): Provide rpl_gettimeofday only
100648         when replacement is declared, otherwise provide gettimeofday.
100649         Reported by Michael Goffioul.
100651 2010-02-23  Jim Meyering  <meyering@redhat.com>
100653         lib-ignore: relax license to "unlimited", not LGPLv2+
100654         * modules/lib-ignore (License): Relax to "unlimited".
100656 2010-02-23  Jim Meyering  <meyering@redhat.com>
100658         lib-ignore: relax license to LGPLv2+
100659         * modules/lib-ignore (License): Relax to LGPLv2+.
100661 2010-02-22  Eric Blake  <eblake@redhat.com>
100663         lseek: avoid bash 3.2 broken pipe bug
100664         * m4/lseek.m4 (gl_FUNC_LSEEK): Drain pipe, to avoid spurious
100665         warning from bash 3.2.
100666         Reported by Ben Pfaff, with analysis from Bruno Haible.
100668         bootstrap: support non-FSF copyright holder
100669         * build-aux/bootstrap (COPYRIGHT_HOLDER, with_gettext): Allow
100670         bootstrap.conf override of COPYRIGHT_HOLDER.
100671         (MSGID_BUGS_ADDRESS): Allow URL rather than email.
100673         bootstrap: interoperate with gettext 0.14.1
100674         * build-aux/bootstrap (slurp): Fix typo when using older gettext.
100676         bootstrap: allow for alternate submodule location
100677         * build-aux/bootstrap (gnulib_path): New variable; use instead of
100678         hardcoding submodule location.
100679         (gnulib_mk): Allow direct use of Makefile.am.
100681         bootstrap: use GNULIB_SRCDIR to reduce disk usage
100682         * build-aux/bootstrap (GNULIB_SRCDIR): If set, use as a reference,
100683         rather than reconfiguring where the submodule points.
100685         gettimeofday: restore support for platforms that lack function
100686         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Also compile
100687         replacement if function is missing.
100688         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): New witness.
100689         * modules/sys_time (Makefile.am): Substitute it.
100690         * lib/sys_time.in.h (gettimeofday): Check it.
100691         Reported by Michael Goffioul.
100693 2010-02-21  Bruno Haible  <bruno@clisp.org>
100695         * lib/stdio.in.h (obstack_printf): Fix typo.
100697 2010-02-21  Jose E. Marchesi  <jemarch@gnu.org>
100699         vc-list-files: use bzr ls's -R option
100700         * build-aux/vc-list-files: Invoke bazaar to generate a recursive
100701         list of versioned files based on 'dir' (usage of -R in 'bzr ls').
100703 2010-02-21  Jim Meyering  <meyering@redhat.com>
100705         init.sh: fix EXEEXT shims to work also for names like test-prog
100706         * tests/init.sh: Re-exec a better shell, when needed.
100707         If the current shell lacks support for posix $(...), an init.sh-using
100708         test will now try to find a shell that supports that.  If EXEEXT is
100709         nonempty, we also require support for hyphen-in-alias-name and shell
100710         substitutions like ${var#glob}.  Failure to find such a shell results
100711         in a skipped test.
100713 2010-02-21  Bruno Haible  <bruno@clisp.org>
100715         Really work around "broken pipe" error message from bash 3.2.
100716         * gnulib-tool (func_reset_sigpipe): Remove function.
100717         (echo): In bash 3.2, define to a function that uses printf.
100718         Analyzed by Ralf Wildenhues, Chet Ramey, Ben Pfaff.
100720 2010-02-20  Bruno Haible  <bruno@clisp.org>
100722         Restore support for automake 1.9.6 with autoconf 2.61.
100723         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): Ensure MKDIR_P is AC_SUBSTed.
100724         Reported by James Youngman <jay@gnu.org>.
100726 2010-02-20  Bruno Haible  <bruno@clisp.org>
100728         Improve *printf warning condition.
100729         * lib/stdio.in.h (fprintf, printf, vfprintf, vprintf): Emit warning
100730         also if GNULIB_POSIXCHECK is defined, the *-posix module is not used,
100731         and the function is overridden due to SIGPIPE emulation.
100733 2010-02-20  Bruno Haible  <bruno@clisp.org>
100735         * lib/stdio.in.h: Tweak comments.
100737 2010-02-19  Bruno Haible  <bruno@clisp.org>
100739         Make it easier to find modules. New gnulib-tool option '--find'.
100740         * gnulib-tool: New option --find.
100741         (func_usage): Document it.
100742         (func_sanitize_modulelist): New function, extracted from
100743         func_all_modules.
100744         (func_all_modules): Invoke it.
100745         * doc/gnulib-tool.texi (Which modules?): New node.
100747 2010-02-18  Markus Duft  <mduft@gentoo.org>  (tiny change)
100749         * lib/sys_select.in.h: Provide select replacement even if
100750         sys/select.h exists on a system, for Interix.
100752 2010-02-18  Jim Meyering  <meyering@redhat.com>
100754         init.sh: don't use $(...) just yet
100755         * tests/init.sh (create_exe_shim_functions_): Use `...`, not $(...),
100756         to accommodate e.g., Solaris' /bin/sh.
100758 2010-02-17  Bruno Haible  <bruno@clisp.org>
100760         * doc/posix-headers/netdb.texi: Mention NetBSD 5.0 problem.
100761         Reported by Ludovic Courtès <ludo@gnu.org>.
100763 2010-02-16  Simon Josefsson  <simon@josefsson.org>
100765         * modules/userspec-tests (test_userspec_LDADD): Add variable, for
100766         linking with -lintl.
100768 2010-02-17  Simon Josefsson  <simon@josefsson.org>
100770         * lib/netdb.in.h (AI_V4MAPPED, AI_ALL, AI_ADDRCONFIG): Define to 0
100771         if not provided by the system's netdb.h.  Reported by
100772         ludo@gnu.org (Ludovic Courtès).
100774 2010-02-15  Jim Meyering  <meyering@redhat.com>
100776         init.sh: improve portability and efficiency
100777         * tests/init.sh (find_exe_basenames_): Remove unnecessary use of
100778         "dummy" in a for loop.
100779         Use '!', not '^' to select the complement of a character set used
100780         in a "case" statement.
100781         Use shell variable manipulation, a la ${...%.exe}, rather than sed.
100782         Suggestions from Eric Blake.
100784         init.sh: automatically accommodate programs with the .exe suffix
100785         Automatically arrange for an invocation of "prog" to execute the
100786         program named "prog$EXEEXT" (usually prog.exe).  Thus, all invocations
100787         may use the simpler "prog", yet still work when built on a system
100788         that requires specifying the added suffix.
100789         Do this by constructing a function named "prog" that invokes
100790         "prog.exe" for each .exe file in selected directories.
100791         * tests/init.sh (find_exe_basenames_): New function.
100792         (create_exe_shim_functions_): New function.
100793         (path_prepend_): Use it.
100795         maint.mk: mark syntax-check sc_*.m rules as .PHONY
100796         * top/maint.mk ($(syntax-check-rules)): Add .PHONY, so that
100797         "make -t syntax-check" doesn't create a ton of sc_*.m files.
100799 2010-02-14  Jim Meyering  <meyering@redhat.com>
100801         maint.mk: prohibit inclusion of "hash-pjw.h" without_use
100802         * top/maint.mk (sc_prohibit_hash_without_use): Re-add "@".
100803         (sc_prohibit_hash_pjw_without_use): New rule.
100805         maint.mk: allow the default upload destination dir to be overridden
100806         * top/maint.mk (upload_dest_dir_): Define with a default that
100807         preserves the status quo.
100808         (emit_upload_commands): Use it, rather than hard-coding $(PACKAGE).
100809         Reported by Peter Simons.
100811         maint.mk: prohibit inclusion of "hash.h" without_use
100812         * top/maint.mk (sc_prohibit_hash_without_use): New rule.
100814 2010-02-10  Jim Meyering  <meyering@redhat.com>
100816         maint.mk: prohibit inclusion of "ignore-value.h" without_use
100817         * top/maint.mk (sc_prohibit_ignore_value_without_use): New rule.
100819 2010-02-09  Eric Blake  <ebb9@byu.net>
100820         and Bruno Haible  <bruno@clisp.org>
100822         obstack-printf-posix: ensure declaration
100823         * m4/obstack-printf.m4 (gl_DECL_OBSTACK_PRINTF): New macro,
100824         extracted from gl_FUNC_OBSTACK_PRINTF.
100825         (gl_FUNC_OBSTACK_PRINTF): Invoke it.
100826         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX):
100827         Likewise.
100828         * lib/stdio.in.h (obstack_printf, obstack_vprintf): Declare also
100829         if GNULIB_OBSTACK_PRINTF_POSIX is 1 and GNULIB_OBSTACK_PRINTF is
100830         0.
100832 2010-02-08  Bruno Haible  <bruno@clisp.org>
100834         gnulib-tool: Fix typo in 2010-02-07 commit.
100835         * gnulib-tool (func_get_dependencies): Fix typo in last commit.
100836         Reported by Eric Blake.
100838 2010-02-07  Bruno Haible  <bruno@clisp.org>
100840         gnulib-tool: Fix up caching patches.
100841         * gnulib-tool: New options --cache-modules, --no-cache-modules. Remove
100842         option --no-cache. Use associative arrays when supported by the shell.
100843         (sed_comments): New variable.
100844         (modcache): Renamed from do_cache.
100845         (sed_extract_field_header): Renamed from sed_extract_cache_prog. Don't
100846         abbreviate unnecessarily.
100847         (have_associative): New variable.
100848         (func_cache_var): Define correctly for bash 1.x. Define in an optimized
100849         way also for ksh and zsh.
100850         (func_init_sed_convert_to_cache_statements): New function, extracted
100851         from func_cache_lookup_module. Add support for associative arrays.
100852         Don't set the c_MODULE_cached variable here. Ignore all lines before
100853         the first field header. Remove only the final newline, not all trailing
100854         newlines. Support empty fields correctly. Limit the use of 'eval' to
100855         assignments.
100856         (func_get_description, func_get_status, func_get_notice,
100857         func_get_applicability, func_get_filelist, func_get_dependencies,
100858         func_get_autoconf_early_snippet, func_get_autoconf_snippet,
100859         func_get_automake_snippet, func_get_include_directive,
100860         func_get_link_directive, func_get_license, func_get_maintainer):
100861         Update documentation. List the unoptimized code first. Add support for
100862         associative arrays. Limit the use of 'eval' to assignments.
100863         (func_get_applicability): Undo stylistic pessimisations.
100864         (func_get_automake_snippet, func_get_include_directive): Reduce code
100865         duplication.
100866         (func_modules_transitive_closure, func_modules_add_dummy,
100867         func_modules_notice, func_modules_to_filelist, func_add_file,
100868         func_update_file, func_emit_lib_Makefile_am, func_emit_po_Makevars,
100869         func_emit_po_POTFILES_in, func_emit_tests_Makefile_am, func_import,
100870         func_create_testdir, func_create_megatestdir): Update documentation.
100872 2010-01-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
100874         * gnulib-tool (func_cache_lookup_module): Store the module name
100875         belonging to the cache variable; error out if two different
100876         module names map to the same cache variable name.
100878 2010-01-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
100880         gnulib-tool: Make caching optional.
100881         * gnulib-tool: Accept option --no-cache, turning off $do_cache.
100882         Update matching short versions of --no-changelog.
100883         (func_usage): Update.
100884         (sed_extract_cache_prog): Renamed from ...
100885         (sed_extract_prog): ... this; revert to old extraction script.
100886         (func_get_description, func_get_status)
100887         (func_get_notice, func_get_applicability, func_get_filelist)
100888         (func_get_dependencies, func_get_autoconf_early_snippet)
100889         (func_get_autoconf_snippet, func_get_automake_snippet)
100890         (func_get_include_directive, func_get_link_directive)
100891         (func_get_license, func_get_maintainer): If $do_cache is false,
100892         use old, non-caching extraction scripts.
100893         Suggestion by Bruno Haible.
100895 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
100897         gnulib-tool: cache module metainformation.
100898         * gnulib-tool (sed_extract_prog): Match newline before each
100899         header, and rewrite header to a shell variable suffix.
100900         (func_cache_var, func_cache_lookup_module): New functions,
100901         to turn a module name into a cache variable prefix, and to
100902         look up and cache module metainformation.
100903         (func_get_description, func_get_status)
100904         (func_get_notice, func_get_applicability, func_get_filelist)
100905         (func_get_dependencies, func_get_autoconf_early_snippet)
100906         (func_get_autoconf_snippet, func_get_automake_snippet)
100907         (func_get_include_directive, func_get_link_directive)
100908         (func_get_license, func_get_maintainer): Use
100909         func_cache_lookup_module.
100911 2010-02-07  Bruno Haible  <bruno@clisp.org>
100913         fnctl: Fix missing dependency.
100914         * modules/fcntl (Depends-on): Add getdtablesize.
100915         Reported by John W. Eaton <jwe@gnu.org>.
100917 2010-02-05  Sergey Poznyakoff  <gray@gnu.org.ua>
100919         Argp: fix recognition of short alias options.
100921         * lib/argp-parse.c (convert_options): Fix improper use of
100922         `|' between character values.
100923         * tests/test-argp.c (group1_option): New alias option
100924         --read (-r).
100925         (group1_parser): Special handling for 'r'.
100926         (test15): New test case.
100927         (test_fun): Add test15.
100928         * tests/test-argp-2.sh: Update expected --help and --usage
100929         outputs.
100931 2010-02-05  Sergey Poznyakoff  <gray@gnu.org.ua>
100933         * tests/test-argp.c: Fix indentation.
100935 2010-02-04  Eric Blake  <ebb9@byu.net>
100937         gettimeofday: expose type of second argument
100938         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Do better detection
100939         of glibc extension signature, and define GETTIMEOFDAY_TIMEZONE.
100940         * tests/test-gettimeofday.c: Use it to silence warning.
100941         * doc/posix-functions/gettimeofday.texi (gettimeofday): Document
100942         the issue.
100944 2010-02-03  Jim Meyering  <meyering@redhat.com>
100946         regcomp.c: avoid the sole warning from gcc's -Wtype-limits
100947         * lib/regcomp.c (TYPE_SIGNED): Define.
100948         (parse_dup_op): Use it to avoid the sole warning from -Wtype-limits.
100950         regcomp.c: avoid a new -Wshadow warning
100951         * lib/regcomp.c (create_initial_state): Do not shadow local "err".
100953 2010-02-01  Jim Meyering  <meyering@redhat.com>
100955         removing useless parentheses in cpp #define directives
100956         For motivation, see commit c0221df4, "define STREQ(a,b)
100957         consistently, removing useless parentheses"
100958         * lib/memcmp.c (CMP_LT_OR_GT): Remove useless parentheses.
100959         * lib/mountlist.c (MNT_IGNORE): Likewise.
100960         * lib/trim.h (trim, trim_trailing, trim_leading): Likewise.
100962 2010-02-01  Eric Blake  <ebb9@byu.net>
100964         sys_time: use link-warning
100965         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Split defaults...
100966         (gl_HEADER_SYS_TIME_H_DEFAULTS): ...into new macro.
100967         (gl_SYS_TIME_MODULE_INDICATOR): New macro.
100968         * modules/sys_time (Depends-on): Add warn-on-use.
100969         (Makefile.am): Always build replacement.
100970         (configure.ac): Update substitutions.
100971         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY)
100972         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Include defaults, and no longer
100973         bother with SYS_TIME_H.
100974         * modules/gettimeofday (configure.ac): Declare indicator.
100975         * lib/sys_time.in.h (gettimeofday): Warn if gnulib module is not
100976         in use.
100978         closein-tests: silence compiler warning
100979         * tests/test-closein.c (main): Ignore fread result.
100980         * modules/closein-tests (Depends-on): Add ignore-value.
100982         tests: silence warning about system return
100983         * tests/test-areadlink-with-size.c (main): Ignore system result.
100984         * tests/test-areadlink.c (main): Likewise.
100985         * tests/test-areadlinkat-with-size.c (main): Likewise.
100986         * tests/test-areadlinkat.c (main): Likewise.
100987         * tests/test-canonicalize-lgpl.c (main): Likewise.
100988         * tests/test-canonicalize.c (main): Likewise.
100989         * tests/test-chown.c (main): Likewise.
100990         * tests/test-fchownat.c (main): Likewise.
100991         * tests/test-fdutimensat.c (main): Likewise.
100992         * tests/test-fstatat.c (main): Likewise.
100993         * tests/test-futimens.c (main): Likewise.
100994         * tests/test-lchown.c (main): Likewise.
100995         * tests/test-link.c (main): Likewise.
100996         * tests/test-linkat.c (main): Likewise.
100997         * tests/test-lstat.c (main): Likewise.
100998         * tests/test-mkdir.c (main): Likewise.
100999         * tests/test-mkdirat.c (main): Likewise.
101000         * tests/test-mkfifo.c (main): Likewise.
101001         * tests/test-mkfifoat.c (main): Likewise.
101002         * tests/test-mknod.c (main): Likewise.
101003         * tests/test-readlink.c (main): Likewise.
101004         * tests/test-remove.c (main): Likewise.
101005         * tests/test-rename.c (main): Likewise.
101006         * tests/test-renameat.c (main): Likewise.
101007         * tests/test-rmdir.c (main): Likewise.
101008         * tests/test-symlink.c (main): Likewise.
101009         * tests/test-symlinkat.c (main): Likewise.
101010         * tests/test-unlink.c (main): Likewise.
101011         * tests/test-unlinkat.c (main): Likewise.
101012         * tests/test-utimens.c (main): Likewise.
101013         * tests/test-utimensat.c (main): Likewise.
101014         * modules/areadlink-tests (Depends-on): Add ignore-value.
101015         * modules/areadlink-with-size-tests (Depends-on): Likewise.
101016         * modules/areadlinkat-tests (Depends-on): Likewise.
101017         * modules/areadlinkat-with-size-tests (Depends-on): Likewise.
101018         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
101019         * modules/canonicalize-tests (Depends-on): Likewise.
101020         * modules/chown-tests (Depends-on): Likewise.
101021         * modules/fdutimensat-tests (Depends-on): Likewise.
101022         * modules/futimens-tests (Depends-on): Likewise.
101023         * modules/lchown-tests (Depends-on): Likewise.
101024         * modules/link-tests (Depends-on): Likewise.
101025         * modules/linkat-tests (Depends-on): Likewise.
101026         * modules/lstat-tests (Depends-on): Likewise.
101027         * modules/mkdir-tests (Depends-on): Likewise.
101028         * modules/mkfifo-tests (Depends-on): Likewise.
101029         * modules/mkfifoat-tests (Depends-on): Likewise.
101030         * modules/mknod-tests (Depends-on): Likewise.
101031         * modules/openat-tests (Depends-on): Likewise.
101032         * modules/readlink-tests (Depends-on): Likewise.
101033         * modules/remove-tests (Depends-on): Likewise.
101034         * modules/rename-tests (Depends-on): Likewise.
101035         * modules/renameat-tests (Depends-on): Likewise.
101036         * modules/rmdir-tests (Depends-on): Likewise.
101037         * modules/symlink-tests (Depends-on): Likewise.
101038         * modules/symlinkat-tests (Depends-on): Likewise.
101039         * modules/unlink-tests (Depends-on): Likewise.
101040         * modules/utimens-tests (Depends-on): Likewise.
101041         * modules/utimensat-tests (Depends-on): Likewise.
101043 2010-01-31  Bruno Haible  <bruno@clisp.org>
101045         Perform the same test for many <math.h> functions.
101046         * m4/mathfunc.m4 (gl_COMMON_DOUBLE_MATHFUNC,
101047         gl_COMMON_DOUBLE_MATHFUNC_TEST): New macros.
101048         * m4/sqrt.m4 (gl_FUNC_SQRT): Invoke gl_COMMON_DOUBLE_MATHFUNC instead
101049         of gl_MATHFUNC.
101050         * modules/acos (configure.ac): Likewise.
101051         * modules/asin (configure.ac): Likewise.
101052         * modules/atan (configure.ac): Likewise.
101053         * modules/atan2 (configure.ac): Likewise.
101054         * modules/cbrt (configure.ac): Likewise.
101055         * modules/copysign (configure.ac): Likewise.
101056         * modules/cos (configure.ac): Likewise.
101057         * modules/cosh (configure.ac): Likewise.
101058         * modules/erf (configure.ac): Likewise.
101059         * modules/erfc (configure.ac): Likewise.
101060         * modules/exp (configure.ac): Likewise.
101061         * modules/fmod (configure.ac): Likewise.
101062         * modules/hypot (configure.ac): Likewise.
101063         * modules/j0 (configure.ac): Likewise.
101064         * modules/j1 (configure.ac): Likewise.
101065         * modules/jn (configure.ac): Likewise.
101066         * modules/lgamma (configure.ac): Likewise.
101067         * modules/log (configure.ac): Likewise.
101068         * modules/log10 (configure.ac): Likewise.
101069         * modules/log1p (configure.ac): Likewise.
101070         * modules/pow (configure.ac): Likewise.
101071         * modules/remainder (configure.ac): Likewise.
101072         * modules/sin (configure.ac): Likewise.
101073         * modules/sinh (configure.ac): Likewise.
101074         * modules/tan (configure.ac): Likewise.
101075         * modules/tanh (configure.ac): Likewise.
101076         * modules/y0 (configure.ac): Likewise.
101077         * modules/y1 (configure.ac): Likewise.
101078         * modules/yn (configure.ac): Likewise.
101079         Suggested by Paolo Bonzini.
101081 2010-01-31  Bruno Haible  <bruno@clisp.org>
101083         * m4/getline.m4 (gl_FUNC_GETLINE): Add comment about REPLACE_GETLINE.
101085 2010-01-31  Bruno Haible  <bruno@clisp.org>
101087         Work around getdelim() bug on FreeBSD 8.0.
101088         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Test whether getdelim supports an
101089         initially NULL line. Set REPLACE_GETDELIM if getdelim exists but does
101090         not work.
101091         * lib/stdio.in.h (getdelim): Define as an alias if REPLACE_GETDELIM
101092         is 1.
101093         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize REPLACE_GETDELIM.
101094         * modules/stdio (Makefile.am): Also substitute REPLACE_GETDELIM.
101095         * tests/test-getdelim.c (main): Also test result for a NULL buffer and
101096         a non-zero size.
101097         * doc/posix-functions/getdelim.texi: Mention the FreeBSD bug.
101099 2010-01-31  Bruno Haible  <bruno@clisp.org>
101101         Work around getline() bug on FreeBSD 8.0.
101102         * m4/getline.m4 (gl_FUNC_GETLINE): Also test result for a NULL buffer
101103         and a non-zero size.
101104         * tests/test-getline.c (main): Likewise.
101105         * doc/posix-functions/getline.texi: Mention the FreeBSD bug.
101106         Reported by Dennis <noordsij@cs.helsinki.fi> via Eric Blake.
101108 2010-01-28  Eric Blake  <ebb9@byu.net>
101110         regex: fix build failure
101111         * lib/regex_internal.h (__GNUC_PREREQ): Define for non-glibc
101112         platforms.
101114 2010-01-28  Jim Meyering  <meyering@redhat.com>
101116         regex: do not ignore memory allocation failure
101117         * lib/regex_internal.c (create_cd_newstate): Detect
101118         re_node_set_init_copy failure.   Extracted from glibc commit
101119         2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
101121         regex: sync more white-space changes from libc
101122         * lib/regex_internal.c: White-space only changes.
101123         * lib/regexec.c: Likewise.
101125         regex: add many uses of __attribute_warn_unused_result__
101126         * lib/regex_internal.c: Use __attribute_warn_unused_result__.
101127         * lib/regexec.c: Likewise.
101128         Extracted from a messy glibc commit.
101130         regcomp.c: spelling and merge-artifact from glibc
101131         * lib/regcomp.c: Merge remainder of glibc's
101132         2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
101134         regcomp.c: sync white-space changes from glibc
101135         * lib/regcomp.c: Merge to accommodate white space
101136         changes from glibc's 2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
101138         regcomp.c: do not ignore internal return values
101139         * lib/regcomp.c: Do not ignore internal return values.
101140         This is from glibc's 2da42bc06566bc89785e580fa1ac89b4c9f2a63c,
101141         but without its white-space changes and spelling fixes.
101143         regex_internal.h: define __attribute_warn_unused_result__
101144         * lib/regex_internal.h (__attribute_warn_unused_result__): Define.
101146         maint: add a syntax-check rule to check for vulnerable Makefile.in
101147         * top/maint.mk (sc_vulnerable_makefile_CVE-2009-4029): New rule.
101149 2010-01-27  Jim Meyering  <meyering@redhat.com>
101151         ncftpput-ftp: clean up spaces
101152         * build-aux/ncftpput-ftp: Make Copyright line consistent.
101153         Remove trailing blanks.
101155 2010-01-27  Simon Josefsson  <simon@josefsson.org>
101157         * build-aux/git-version-gen: Fix copyright statement.
101158         * build-aux/gnupload: Likewise.
101159         * tests/test-arcfour.c: Likewise.
101160         * tests/test-arctwo.c: Likewise.
101161         * tests/test-count-one-bits.c: Likewise.
101162         * tests/test-crc.c: Likewise.
101163         * tests/test-des.c: Likewise.
101164         * tests/test-gc-arcfour.c: Likewise.
101165         * tests/test-gc-arctwo.c: Likewise.
101166         * tests/test-gc-des.c: Likewise.
101167         * tests/test-gc-hmac-md5.c: Likewise.
101168         * tests/test-gc-hmac-sha1.c: Likewise.
101169         * tests/test-gc-md2.c: Likewise.
101170         * tests/test-gc-md4.c: Likewise.
101171         * tests/test-gc-md5.c: Likewise.
101172         * tests/test-gc-pbkdf2-sha1.c: Likewise.
101173         * tests/test-gc-rijndael.c: Likewise.
101174         * tests/test-gc-sha1.c: Likewise.
101175         * tests/test-gc.c: Likewise.
101176         * tests/test-gethostname.c: Likewise.
101177         * tests/test-gettimeofday.c: Likewise.
101178         * tests/test-hash.c: Likewise.
101179         * tests/test-hmac-md5.c: Likewise.
101180         * tests/test-hmac-sha1.c: Likewise.
101181         * tests/test-md2.c: Likewise.
101182         * tests/test-md4.c: Likewise.
101183         * tests/test-md5.c: Likewise.
101184         * tests/test-memchr.c: Likewise.
101185         * tests/test-memchr2.c: Likewise.
101186         * tests/test-memcmp.c: Likewise.
101187         * tests/test-memmem.c: Likewise.
101188         * tests/test-memrchr.c: Likewise.
101189         * tests/test-rawmemchr.c: Likewise.
101190         * tests/test-read-file.c: Likewise.
101191         * tests/test-rijndael.c: Likewise.
101192         * tests/test-sockets.c: Likewise.
101193         * tests/test-strchrnul.c: Likewise.
101194         * tests/test-strstr.c: Likewise.
101195         * tests/test-strtod.c: Likewise.
101196         * build-aux/ncftpput-ftp: Likewise.
101198 2010-01-26  Eric Blake  <ebb9@byu.net>
101200         ignore-value: update recommended header name
101201         * modules/ignore-value (Include): Only use <> for headers that
101202         exist in glibc.
101204 2010-01-26  Jim Meyering  <meyering@redhat.com>
101206         test-userspec.c: avoid compiler warnings
101207         * tests/test-userspec.c (main): Avoid shadowing ("uid"),
101208         and "initialization discards qualifiers..." warnings.
101209         Put the first "uid" in its own scope, and make char* members "const".
101211 2010-01-25  Bruno Haible  <bruno@clisp.org>
101213         gnulib-tool: Make warning diagnostics consistent.
101214         * gnulib-tool (func_warning): New function.
101215         Use it everywhere where gnulib-tool produces output to stderr and it is
101216         not a fatal error.
101218 2010-01-25  Bruno Haible  <bruno@clisp.org>
101220         Fix test dependencies.
101221         * modules/xstrtol-tests (Depends-on): Add inttypes.
101222         * modules/xstrtoll-tests (Depends-on): Likewise. Remove xstrtoll.
101224 2010-01-25  Pádraig Brady  <P@draigBrady.com>
101226         syntax-check: detect incorrect boolean macro values in config.h
101227         * modules/maintainer-makefile (configure.ac): Parameterize the location
101228         of config.h which will be available to makefiles as $(CONFIG_INCLUDE).
101229         The logic is from Eric Blake and the location indicated by Jim Meyering.
101230         Note the more natural CONFIG_HEADER name is prohibited by automake
101231         for backwards compatibility reasons.
101232         * top/maint.mk (sc_Wundef_boolean): New rule.
101234 2010-01-25  Jim Meyering  <meyering@redhat.com>
101236         bootstrap: detect MacOS 10.6's shasum, too
101237         * build-aux/bootstrap: Also recognize MacOS 10.6's shasum.
101238         Suggested by Thomas Treichl <Thomas.Treichl@gmx.net>.
101240 2010-01-23  Jim Meyering  <meyering@redhat.com>
101242         xstrtoll: new module
101243         * modules/xstrtoll: New file.
101244         * MODULES.html.sh (Numeric conversion functions): Add xstrtoll.
101245         * lib/xstrtol.h [HAVE_LONG_LONG_INT]: Declare xstrtoll and xstrtoull.
101246         * lib/xstrtoll.c, lib/xstrtoull.c: New files.
101247         ./configure fails if you use this module and lack "long long".
101248         * modules/xstrtoll-tests: New module.
101249         * tests/test-xstrtoll.c, tests/test-xstrtoull.c: New files.
101250         * tests/test-xstrtoll.sh: Like test-xstrtol.c, but use the
101251         new init.sh-based test framework.
101253 2010-01-24  Bruno Haible  <bruno@clisp.org>
101255         Tests for module 'yn'.
101256         * modules/yn-tests: New file.
101257         * tests/test-yn.c: New file.
101259         Tests for module 'y1'.
101260         * modules/y1-tests: New file.
101261         * tests/test-y1.c: New file.
101263         Tests for module 'y0'.
101264         * modules/y0-tests: New file.
101265         * tests/test-y0.c: New file.
101267         Tests for module 'tanh'.
101268         * modules/tanh-tests: New file.
101269         * tests/test-tanh.c: New file.
101271         Tests for module 'tan'.
101272         * modules/tan-tests: New file.
101273         * tests/test-tan.c: New file.
101275         Tests for module 'sqrt'.
101276         * modules/sqrt-tests: New file.
101277         * tests/test-sqrt.c: New file.
101279         Tests for module 'sinh'.
101280         * modules/sinh-tests: New file.
101281         * tests/test-sinh.c: New file.
101283         Tests for module 'sin'.
101284         * modules/sin-tests: New file.
101285         * tests/test-sin.c: New file.
101287         Tests for module 'rint'.
101288         * modules/rint-tests: New file.
101289         * tests/test-rint.c: New file.
101291         Tests for module 'remainder'.
101292         * modules/remainder-tests: New file.
101293         * tests/test-remainder.c: New file.
101295         Tests for module 'pow'.
101296         * modules/pow-tests: New file.
101297         * tests/test-pow.c: New file.
101299         Tests for module 'nextafter'.
101300         * modules/nextafter-tests: New file.
101301         * tests/test-nextafter.c: New file.
101303         Tests for module 'modf'.
101304         * modules/modf-tests: New file.
101305         * tests/test-modf.c: New file.
101307         Tests for module 'logb'.
101308         * modules/logb-tests: New file.
101309         * tests/test-logb.c: New file.
101311         Tests for module 'log1p'.
101312         * modules/log1p-tests: New file.
101313         * tests/test-log1p.c: New file.
101315         Tests for module 'log10'.
101316         * modules/log10-tests: New file.
101317         * tests/test-log10.c: New file.
101319         Tests for module 'log'.
101320         * modules/log-tests: New file.
101321         * tests/test-log.c: New file.
101323         Tests for module 'lgamma'.
101324         * modules/lgamma-tests: New file.
101325         * tests/test-lgamma.c: New file.
101327         Tests for module 'ldexp'.
101328         * modules/ldexp-tests: New file.
101329         * tests/test-ldexp.c: New file.
101331         Tests for module 'jn'.
101332         * modules/jn-tests: New file.
101333         * tests/test-jn.c: New file.
101335         Tests for module 'j1'.
101336         * modules/j1-tests: New file.
101337         * tests/test-j1.c: New file.
101339         Tests for module 'j0'.
101340         * modules/j0-tests: New file.
101341         * tests/test-j0.c: New file.
101343         Tests for module 'hypot'.
101344         * modules/hypot-tests: New file.
101345         * tests/test-hypot.c: New file.
101347         Tests for module 'fmod'.
101348         * modules/fmod-tests: New file.
101349         * tests/test-fmod.c: New file.
101351         Tests for module 'fabs'.
101352         * modules/fabs-tests: New file.
101353         * tests/test-fabs.c: New file.
101355         Tests for module 'exp'.
101356         * modules/exp-tests: New file.
101357         * tests/test-exp.c: New file.
101359         Tests for module 'erfc'.
101360         * modules/erfc-tests: New file.
101361         * tests/test-erfc.c: New file.
101363         Tests for module 'erf'.
101364         * modules/erf-tests: New file.
101365         * tests/test-erf.c: New file.
101367         Tests for module 'cosh'.
101368         * modules/cosh-tests: New file.
101369         * tests/test-cosh.c: New file.
101371         Tests for module 'cos'.
101372         * modules/cos-tests: New file.
101373         * tests/test-cos.c: New file.
101375         Tests for module 'copysign'.
101376         * modules/copysign-tests: New file.
101377         * tests/test-copysign.c: New file.
101379         Tests for module 'cbrt'.
101380         * modules/cbrt-tests: New file.
101381         * tests/test-cbrt.c: New file.
101383         Tests for module 'atan2'.
101384         * modules/atan2-tests: New file.
101385         * tests/test-atan2.c: New file.
101387         Tests for module 'atan'.
101388         * modules/atan-tests: New file.
101389         * tests/test-atan.c: New file.
101391         Tests for module 'asin'.
101392         * modules/asin-tests: New file.
101393         * tests/test-asin.c: New file.
101395         Tests for module 'acos'.
101396         * modules/acos-tests: New file.
101397         * tests/test-acos.c: New file.
101399 2010-01-24  Bruno Haible  <bruno@clisp.org>
101401         Fix tests for common <math.h> functions.
101402         * m4/mathfunc.m4 (gl_MATHFUNC): Take two additional parameters. Use a
101403         code snippet that references the function pointer, rather than merely
101404         calling the function. Substitute the FUNC_LIBM variable.
101405         * m4/sqrt.m4 (gl_FUNC_SQRT): Update gl_MATHFUNC invocation.
101406         * modules/acos (configure.ac): Likewise.
101407         * modules/asin (configure.ac): Likewise.
101408         * modules/atan (configure.ac): Likewise.
101409         * modules/atan2 (configure.ac): Likewise.
101410         * modules/cbrt (configure.ac): Likewise.
101411         * modules/copysign (configure.ac): Likewise.
101412         * modules/cos (configure.ac): Likewise.
101413         * modules/cosh (configure.ac): Likewise.
101414         * modules/erf (configure.ac): Likewise.
101415         * modules/erfc (configure.ac): Likewise.
101416         * modules/exp (configure.ac): Likewise.
101417         * modules/fabs (configure.ac): Likewise.
101418         * modules/fmod (configure.ac): Likewise.
101419         * modules/hypot (configure.ac): Likewise.
101420         * modules/j0 (configure.ac): Likewise.
101421         * modules/j1 (configure.ac): Likewise.
101422         * modules/jn (configure.ac): Likewise.
101423         * modules/ldexp (configure.ac): Likewise.
101424         * modules/lgamma (configure.ac): Likewise.
101425         * modules/log (configure.ac): Likewise.
101426         * modules/log10 (configure.ac): Likewise.
101427         * modules/log1p (configure.ac): Likewise.
101428         * modules/logb (configure.ac): Likewise.
101429         * modules/modf (configure.ac): Likewise.
101430         * modules/nextafter (configure.ac): Likewise.
101431         * modules/pow (configure.ac): Likewise.
101432         * modules/remainder (configure.ac): Likewise.
101433         * modules/rint (configure.ac): Likewise.
101434         * modules/sin (configure.ac): Likewise.
101435         * modules/sinh (configure.ac): Likewise.
101436         * modules/tan (configure.ac): Likewise.
101437         * modules/tanh (configure.ac): Likewise.
101438         * modules/y0 (configure.ac): Likewise.
101439         * modules/y1 (configure.ac): Likewise.
101440         * modules/yn (configure.ac): Likewise.
101442 2010-01-24  Bruno Haible  <bruno@clisp.org>
101444         Tests: Defeat inlining of math functions by GCC >= 4.3.0.
101445         * tests/test-acosl.c (x): New variable.
101446         (main): Store argument in x and fetch it from x.
101447         * tests/test-asinl.c (x): New variable.
101448         (main): Store argument in x and fetch it from x.
101449         * tests/test-atanl.c (x): New variable.
101450         (main): Store argument in x and fetch it from x.
101451         * tests/test-cosl.c (x): New variable.
101452         (main): Store argument in x and fetch it from x.
101453         * tests/test-expl.c (x): New variable.
101454         (main): Store argument in x and fetch it from x.
101455         * tests/test-logl.c (x): New variable.
101456         (main): Store argument in x and fetch it from x.
101457         * tests/test-sinl.c (x): New variable.
101458         (main): Store argument in x and fetch it from x.
101459         * tests/test-sqrtl.c (x): New variable.
101460         (main): Store argument in x and fetch it from x.
101461         * tests/test-tanl.c (x): New variable.
101462         (main): Store argument in x and fetch it from x.
101464 2010-01-24  Bruno Haible  <bruno@clisp.org>
101466         Provide EXEEXT and srcdir in TESTS_ENVIRONMENT by default.
101467         * gnulib-tool (func_emit_tests_Makefile_am): Add EXEEXT and srcdir
101468         assignments to the initial TESTS_ENVIRONMENT.
101469         * doc/gnulib.texi (Unit test modules): Document it.
101470         * modules/acl-tests (Makefile.am): Drop EXEEXT assignment from
101471         TESTS_ENVIRONMENT.
101472         * modules/btowc-tests (Makefile.am): Likewise.
101473         * modules/c-stack-tests (Makefile.am): Likewise.
101474         * modules/c-strcase-tests (Makefile.am): Likewise.
101475         * modules/copy-file-tests (Makefile.am): Likewise.
101476         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
101477         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
101478         * modules/mbrtowc-tests (Makefile.am): Likewise.
101479         * modules/mbscasecmp-tests (Makefile.am): Likewise.
101480         * modules/mbscasestr-tests (Makefile.am): Likewise.
101481         * modules/mbschr-tests (Makefile.am): Likewise.
101482         * modules/mbscspn-tests (Makefile.am): Likewise.
101483         * modules/mbsinit-tests (Makefile.am): Likewise.
101484         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
101485         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
101486         * modules/mbspbrk-tests (Makefile.am): Likewise.
101487         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
101488         * modules/mbsrchr-tests (Makefile.am): Likewise.
101489         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
101490         * modules/mbsspn-tests (Makefile.am): Likewise.
101491         * modules/mbsstr-tests (Makefile.am): Likewise.
101492         * modules/nl_langinfo-tests (Makefile.am): Likewise.
101493         * modules/unicase/locale-language-tests (Makefile.am): Likewise.
101494         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
101495         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
101496         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
101497         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
101498         * modules/uniwbrk/ulc-wordbreaks-tests (Makefile.am): Likewise.
101499         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
101500         * modules/wcrtomb-tests (Makefile.am): Likewise.
101501         * modules/wcsnrtombs-tests (Makefile.am): Likewise.
101502         * modules/wcsrtombs-tests (Makefile.am): Likewise.
101503         * modules/quotearg-tests (Makefile.am): Drop EXEEXT and srcdir
101504         assignments from TESTS_ENVIRONMENT.
101505         * modules/argp-tests (Makefile.am): Drop TESTS_ENVIRONMENT
101506         augmentation.
101507         * modules/argp-version-etc-tests (Makefile.am): Likewise.
101508         * modules/atexit-tests (Makefile.am): Likewise.
101509         * modules/binary-io-tests (Makefile.am): Likewise.
101510         * modules/closein-tests (Makefile.am): Likewise.
101511         * modules/dprintf-posix-tests (Makefile.am): Likewise.
101512         * modules/exclude-tests (Makefile.am): Likewise.
101513         * modules/fflush-tests (Makefile.am): Likewise.
101514         * modules/fpending-tests (Makefile.am): Likewise.
101515         * modules/fprintf-posix-tests (Makefile.am): Likewise.
101516         * modules/freadahead-tests (Makefile.am): Likewise.
101517         * modules/freadptr-tests (Makefile.am): Likewise.
101518         * modules/freadseek-tests (Makefile.am): Likewise.
101519         * modules/fseek-tests (Makefile.am): Likewise.
101520         * modules/fseeko-tests (Makefile.am): Likewise.
101521         * modules/ftell-tests (Makefile.am): Likewise.
101522         * modules/ftello-tests (Makefile.am): Likewise.
101523         * modules/idpriv-drop-tests (Makefile.am): Likewise.
101524         * modules/idpriv-droptemp-tests (Makefile.am): Likewise.
101525         * modules/lseek-tests (Makefile.am): Likewise.
101526         * modules/parse-duration-tests (Makefile.am): Likewise.
101527         * modules/perror-tests (Makefile.am): Likewise.
101528         * modules/pipe-filter-gi-tests (Makefile.am): Likewise.
101529         * modules/pipe-filter-ii-tests (Makefile.am): Likewise.
101530         * modules/pipe-tests (Makefile.am): Likewise.
101531         * modules/pread-tests (Makefile.am): Likewise.
101532         * modules/printf-posix-tests (Makefile.am): Likewise.
101533         * modules/select-tests (Makefile.am): Likewise.
101534         * modules/sigpipe-tests (Makefile.am): Likewise.
101535         * modules/tsearch-tests (Makefile.am): Likewise.
101536         * modules/unicase/ulc-casecmp-tests (Makefile.am): Likewise.
101537         * modules/unicase/ulc-casecoll-tests (Makefile.am): Likewise.
101538         * modules/uniname/uniname-tests (Makefile.am): Likewise.
101539         * modules/uniwidth/width-tests (Makefile.am): Likewise.
101540         * modules/vdprintf-posix-tests (Makefile.am): Likewise.
101541         * modules/version-etc-tests (Makefile.am): Likewise.
101542         * modules/vfprintf-posix-tests (Makefile.am): Likewise.
101543         * modules/vprintf-posix-tests (Makefile.am): Likewise.
101544         * modules/xalloc-die-tests (Makefile.am): Likewise.
101545         * modules/xprintf-posix-tests (Makefile.am): Likewise.
101546         * modules/xstrtoimax-tests (Makefile.am): Likewise.
101547         * modules/xstrtol-tests (Makefile.am): Likewise.
101548         * modules/xstrtoumax-tests (Makefile.am): Likewise.
101549         * modules/yesno-tests (Makefile.am): Likewise.
101550         Suggested by Jim Meyering.
101552 2010-01-24  Bruno Haible  <bruno@clisp.org>
101554         More documentation.
101555         * doc/gnulib.texi (Writing modules): New chapter.
101556         (Miscellaneous Notes): Move sections "Comments" and "Header files" to
101557         the new chapter.
101559 2010-01-24  Jim Meyering  <meyering@redhat.com>
101561         maint.mk: do not prepend "./" after filtering
101562         * top/maint.mk (_prepend_srcdir_prefix): New variable
101563         (VC_LIST_EXCEPT): Use it to avoid prepending (post-filter)
101564         "./" when $(srcdir) is ".".
101566         define STREQ(a,b) consistently, removing useless parentheses
101567         #define STREQ(a, b) (strcmp ((a), (b)) == 0) is over-parenthesized,
101568         since the only risk is that "a" or "b" contains an unparenthesized
101569         comma, but if either did that, STREQ would have 3 or more arguments.
101570         Hence, #define STREQ(a, b) (strcmp (a, b) == 0) is better.
101571         * lib/fts.c (STREQ): Remove unnecessary parentheses.
101572         * lib/hash-triple.c (STREQ): Likewise.
101573         * tests/test-argv-iter.c (STREQ): Use a and b, not s1 and s2.
101574         * lib/getugroups.c (STREQ): Likewise.
101576 2010-01-23  Jim Meyering  <meyering@redhat.com>
101578         maint.mk: fix syntax-check in a non-srcdir build directory
101579         * top/maint.mk (_dot_escaped_srcdir): Remove erroneous backslash,
101580         introduced in my 2010-01-21 commit, a6da6c45.  Reported by Eric Blake.
101582 2010-01-22  Jim Meyering  <meyering@redhat.com>
101584         userspec: add unit tests
101585         * tests/test-userspec.c: New file.
101586         * modules/userspec-tests: Likewise.
101588 2010-01-21  Jim Meyering  <meyering@redhat.com>
101590         maint.mk: handle source file names containing "." robustly
101591         * top/maint.mk (_dot_escaped_srcdir): Define.
101592         (VC_LIST): Use it in LHS of sed substitution.
101594 2010-01-21  Jiri Denemark  <jdenemar@redhat.com>
101596         maint.mk: fix VC_LIST_EXCEPT for srcdir != builddir
101597         * top/maint.mk (VC_LIST_EXCEPT): Preprocess the output of
101598         $(VC_LIST) to remove a prefix of '$(srcdir)/', so that it works
101599         from a non-srcdir build.
101601 2010-01-20  Eric Blake  <ebb9@byu.net>
101603         warn-on-use: use instead of link-warning
101604         * modules/stdio (Depends-on, Makefile.am): Drop link-warning.
101605         * modules/unistd (Depends-on, Makefile.am): Likewise.
101606         * modules/arpa_inet (Depends-on): Replace link-warning with
101607         warn-on-use.
101608         (Makefile.am): Update rules accordingly.
101609         * modules/ctype (Depends-on, Makefile.am): Likewise.
101610         * modules/dirent (Depends-on, Makefile.am): Likewise.
101611         * modules/fcntl-h (Depends-on, Makefile.am): Likewise.
101612         * modules/inttypes (Depends-on, Makefile.am): Likewise.
101613         * modules/langinfo (Depends-on, Makefile.am): Likewise.
101614         * modules/locale (Depends-on, Makefile.am): Likewise.
101615         * modules/math (Depends-on, Makefile.am): Likewise.
101616         * modules/search (Depends-on, Makefile.am): Likewise.
101617         * modules/signal (Depends-on, Makefile.am): Likewise.
101618         * modules/spawn (Depends-on, Makefile.am): Likewise.
101619         * modules/stdlib (Depends-on, Makefile.am): Likewise.
101620         * modules/string (Depends-on, Makefile.am): Likewise.
101621         * modules/strings (Depends-on, Makefile.am): Likewise.
101622         * modules/sys_file (Depends-on, Makefile.am): Likewise.
101623         * modules/sys_ioctl (Depends-on, Makefile.am): Likewise.
101624         * modules/sys_select (Depends-on, Makefile.am): Likewise.
101625         * modules/sys_socket (Depends-on, Makefile.am): Likewise.
101626         * modules/sys_stat (Depends-on, Makefile.am): Likewise.
101627         * modules/sys_times (Depends-on, Makefile.am): Likewise.
101628         * modules/sys_utsname (Depends-on, Makefile.am): Likewise.
101629         * modules/wchar (Depends-on, Makefile.am): Likewise.
101630         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Check which functions
101631         should be poisoned.
101632         * m4/ctype.m4 (gl_CTYPE_H): Likewise.
101633         * m4/dirent_h.m4 (gl_DIRENT_H): Likewise.
101634         * m4/fcntl_h.m4 (gl_FCNTL_H): Likewise.
101635         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
101636         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
101637         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
101638         * m4/math_h.m4 (gl_MATH_H): Likewise.
101639         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
101640         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
101641         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
101642         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
101643         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
101644         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
101645         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Likewise.
101646         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H_DEFAULTS): Likewise.
101647         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
101648         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
101649         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
101650         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
101651         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
101652         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
101653         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
101654         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
101655         * lib/arpa_inet.in.h: Use _GL_WARN_ON_USE instead of
101656         GL_LINK_WARNING.
101657         * lib/ctype.in.h: Likewise.
101658         * lib/dirent.in.h: Likewise.
101659         * lib/fcntl.in.h: Likewise.
101660         * lib/inttypes.in.h: Likewise.
101661         * lib/langinfo.in.h: Likewise.
101662         * lib/locale.in.h: Likewise.
101663         * lib/math.in.h: Likewise.
101664         * lib/search.in.h: Likewise.
101665         * lib/signal.in.h: Likewise.
101666         * lib/spawn.in.h: Likewise.
101667         * lib/stdio.in.h: Likewise.
101668         * lib/stdlib.in.h: Likewise.
101669         * lib/string.in.h: Likewise.
101670         * lib/strings.in.h: Likewise.
101671         * lib/sys_file.in.h: Likewise.
101672         * lib/sys_ioctl.in.h: Likewise.
101673         * lib/sys_select.in.h: Likewise.
101674         * lib/sys_socket.in.h: Likewise.
101675         * lib/sys_stat.in.h: Likewise.
101676         * lib/sys_times.in.h: Likewise.
101677         * lib/sys_utsname.in.h: Likewise.
101678         * lib/unistd.in.h: Likewise.
101679         * lib/wchar.in.h: Likewise.
101681 2010-01-20  Bruno Haible  <bruno@clisp.org>
101683         Avoid duplicate -lm.
101684         * m4/isnan.m4 (gl_ISNAN): Avoid duplicate -lm in $ISNAN_LIBM.
101685         * m4/round.m4 (gl_FUNC_ROUND): Avoid duplicate -lm in $ROUND_LIBM.
101686         * m4/roundf.m4 (gl_FUNC_ROUNDF): Avoid duplicate -lm in $ROUNDF_LIBM.
101687         * m4/roundl.m4 (gl_FUNC_ROUNDL): Avoid duplicate -lm in $ROUNDL_LIBM.
101688         * m4/acosl.m4 (gl_FUNC_ACOSL): Avoid duplicate -lm in $ACOSL_LIBM.
101689         * m4/cosl.m4 (gl_FUNC_COSL): Avoid duplicate -lm in $COSL_LIBM.
101690         * m4/logl.m4 (gl_FUNC_LOGL): Avoid duplicate -lm in $LOGL_LIBM.
101691         * m4/sinl.m4 (gl_FUNC_SINL): Avoid duplicate -lm in $SINL_LIBM.
101692         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Avoid duplicate -lm in $SQRTL_LIBM.
101693         * m4/tanl.m4 (gl_FUNC_TANL): Avoid duplicate -lm in $TANL_LIBM.
101694         * m4/asinl.m4 (gl_FUNC_ASINL): Same change, for consistency.
101695         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
101696         Reported by Paolo Bonzini.
101698 2010-01-19  Bruno Haible  <bruno@clisp.org>
101700         langinfo, nl_langinfo: Relicense under LGPLv2+.
101701         * modules/langinfo (License): Change to LGPLv2+.
101702         * modules/nl_langinfo (License): Likewise.
101703         Patch by David Lutterkort <lutter@redhat.com>.
101705 2010-01-19  Bruno Haible  <bruno@clisp.org>
101707         Avoid compilation error with cc on OSF/1 5.1.
101708         * lib/fcntl.in.h: Include <unistd.h> after the #include_next <fcntl.h>
101709         statement, not before.
101710         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
101712 2010-01-18  Bruno Haible  <bruno@clisp.org>
101714         Avoid a link error due to the __printf__ symbol.
101715         * lib/stdio.in.h (__attribute__): Define to empty also for gcc 2.5.x
101716         and 2.6.x.
101717         (__format__, __printf__): Remove definitions.
101718         * lib/argp-fmtstream.h: Likewise.
101719         * lib/argp.h: Likewise.
101720         * lib/error.h: Likewise.
101721         * lib/vasnprintf.h: Likewise.
101722         * lib/xprintf.h: Likewise.
101723         * lib/xvasprintf.h: Likewise.
101724         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
101726 2010-01-18  Bruno Haible  <bruno@clisp.org>
101728         Tests for module 'tanl'.
101729         * modules/tanl-tests: New file.
101730         * tests/test-tanl.c: New file.
101732         Tests for module 'sqrtl'.
101733         * modules/sqrtl-tests: New file.
101734         * tests/test-sqrtl.c: New file.
101736         Tests for module 'sinl'.
101737         * modules/sinl-tests: New file.
101738         * tests/test-sinl.c: New file.
101740         Tests for module 'logl'.
101741         * modules/logl-tests: New file.
101742         * tests/test-logl.c: New file.
101744         Tests for module 'expl'.
101745         * modules/expl-tests: New file.
101746         * tests/test-expl.c: New file.
101748         Tests for module 'cosl'.
101749         * modules/cosl-tests: New file.
101750         * tests/test-cosl.c: New file.
101752         Tests for module 'atanl'.
101753         * modules/atanl-tests: New file.
101754         * tests/test-atanl.c: New file.
101756         Tests for module 'asinl'.
101757         * modules/asinl-tests: New file.
101758         * tests/test-asinl.c: New file.
101760         Tests for module 'acosl'.
101761         * modules/acosl-tests: New file.
101762         * tests/test-acosl.c: New file.
101764         New modules acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl.
101765         * lib/math.in.h (acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl,
101766         tanl): Use the standard gnulib idiom.
101767         * lib/cosl.c: Don't include trigl.c and sincosl.c.
101768         * lib/sinl.c: Likewise.
101769         * lib/tanl.c: Don't include trigl.c.
101770         (kernel_tanl): Make static.
101771         * lib/sincosl.c: Include trigl.h first.
101772         * lib/trigl.c: Likewise.
101773         * m4/acosl.m4: New file.
101774         * m4/asinl.m4: New file.
101775         * m4/atanl.m4: New file.
101776         * m4/cosl.m4: New file.
101777         * m4/expl.m4: New file.
101778         * m4/logl.m4: New file.
101779         * m4/sinl.m4: New file.
101780         * m4/sqrtl.m4: New file.
101781         * m4/tanl.m4: New file.
101782         * m4/mathl.m4: Remove file.
101783         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_* and HAVE_*
101784         variables for acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl.
101785         Don't initialize GNULIB_MATHL.
101786         * modules/acosl: New file.
101787         * modules/asinl: New file.
101788         * modules/atanl: New file.
101789         * modules/cosl: New file.
101790         * modules/expl: New file.
101791         * modules/logl: New file.
101792         * modules/sinl: New file.
101793         * modules/sqrtl: New file.
101794         * modules/tanl: New file.
101795         * modules/math (Makefile.am): Substitute GNULIB_* and HAVE_* variables
101796         for acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl. Don't
101797         substitute GNULIB_MATHL.
101798         * modules/mathl: Rewritten.
101799         * doc/posix-functions/acosl.texi: Mention the 'acosl' module.
101800         * doc/posix-functions/asinl.texi: Mention the 'asinl' module.
101801         * doc/posix-functions/atanl.texi: Mention the 'atanl' module.
101802         * doc/posix-functions/cosl.texi: Mention the 'cosl' module.
101803         * doc/posix-functions/expl.texi: Mention the 'expl' module.
101804         * doc/posix-functions/logl.texi: Mention the 'logl' module.
101805         * doc/posix-functions/sinl.texi: Mention the 'sinl' module.
101806         * doc/posix-functions/sqrtl.texi: Mention the 'sqrtl' module.
101807         * doc/posix-functions/tanl.texi: Mention the 'tanl' module.
101809 2010-01-18  Bruno Haible  <bruno@clisp.org>
101811         sqrt: Make gl_FUNC_SQRT requirable.
101812         * m4/sqrt.m4: New file.
101813         * modules/sqrt (Files): Add it.
101814         (configure.ac): Invoke gl_FUNC_SQRT.
101816 2010-01-18  Bruno Haible  <bruno@clisp.org>
101818         New modules for common <math.h> functions.
101819         * m4/mathfunc.m4: New file.
101820         * modules/acos: New file.
101821         * modules/asin: New file.
101822         * modules/atan: New file.
101823         * modules/atan2: New file.
101824         * modules/cbrt: New file.
101825         * modules/copysign: New file.
101826         * modules/cos: New file.
101827         * modules/cosh: New file.
101828         * modules/erf: New file.
101829         * modules/erfc: New file.
101830         * modules/exp: New file.
101831         * modules/fabs: New file.
101832         * modules/fmod: New file.
101833         * modules/hypot: New file.
101834         * modules/j0: New file.
101835         * modules/j1: New file.
101836         * modules/jn: New file.
101837         * modules/ldexp: New file.
101838         * modules/lgamma: New file.
101839         * modules/log: New file.
101840         * modules/log10: New file.
101841         * modules/log1p: New file.
101842         * modules/logb: New file.
101843         * modules/modf: New file.
101844         * modules/nextafter: New file.
101845         * modules/pow: New file.
101846         * modules/remainder: New file.
101847         * modules/rint: New file.
101848         * modules/sin: New file.
101849         * modules/sinh: New file.
101850         * modules/sqrt: New file.
101851         * modules/tan: New file.
101852         * modules/tanh: New file.
101853         * modules/y0: New file.
101854         * modules/y1: New file.
101855         * modules/yn: New file.
101856         * doc/posix-functions/acos.texi: Mention the 'acos' module.
101857         * doc/posix-functions/asin.texi: Mention the 'asin' module.
101858         * doc/posix-functions/atan.texi: Mention the 'atan' module.
101859         * doc/posix-functions/atan2.texi: Mention the 'atan2' module.
101860         * doc/posix-functions/cbrt.texi: Mention the 'cbrt' module.
101861         * doc/posix-functions/copysign.texi: Mention the 'copysign' module.
101862         * doc/posix-functions/cos.texi: Mention the 'cos' module.
101863         * doc/posix-functions/cosh.texi: Mention the 'cosh' module.
101864         * doc/posix-functions/erf.texi: Mention the 'erf' module.
101865         * doc/posix-functions/erfc.texi: Mention the 'erfc' module.
101866         * doc/posix-functions/exp.texi: Mention the 'exp' module.
101867         * doc/posix-functions/fabs.texi: Mention the 'fabs' module.
101868         * doc/posix-functions/fmod.texi: Mention the 'fmod' module.
101869         * doc/posix-functions/hypot.texi: Mention the 'hypot' module.
101870         * doc/posix-functions/j0.texi: Mention the 'j0' module.
101871         * doc/posix-functions/j1.texi: Mention the 'j1' module.
101872         * doc/posix-functions/jn.texi: Mention the 'jn' module.
101873         * doc/posix-functions/ldexp.texi: Mention the 'ldexp' module.
101874         * doc/posix-functions/lgamma.texi: Mention the 'lgamma' module.
101875         * doc/posix-functions/log.texi: Mention the 'log' module.
101876         * doc/posix-functions/log10.texi: Mention the 'log10' module.
101877         * doc/posix-functions/log1p.texi: Mention the 'log1p' module.
101878         * doc/posix-functions/logb.texi: Mention the 'logb' module.
101879         * doc/posix-functions/modf.texi: Mention the 'modf' module.
101880         * doc/posix-functions/nextafter.texi: Mention the 'nextafter' module.
101881         * doc/posix-functions/pow.texi: Mention the 'pow' module.
101882         * doc/posix-functions/remainder.texi: Mention the 'remainder' module.
101883         * doc/posix-functions/rint.texi: Mention the 'rint' module.
101884         * doc/posix-functions/sin.texi: Mention the 'sin' module.
101885         * doc/posix-functions/sinh.texi: Mention the 'sinh' module.
101886         * doc/posix-functions/sqrt.texi: Mention the 'sqrt' module.
101887         * doc/posix-functions/tan.texi: Mention the 'tan' module.
101888         * doc/posix-functions/tanh.texi: Mention the 'tanh' module.
101889         * doc/posix-functions/y0.texi: Mention the 'y0' module.
101890         * doc/posix-functions/y1.texi: Mention the 'y1' module.
101891         * doc/posix-functions/yn.texi: Mention the 'yn' module.
101893 2010-01-18  Jim Meyering  <meyering@redhat.com>
101895         ignore-value: relax license to LGPLv2+
101896         * modules/ignore-value (License): Relax to LGPLv2+.
101898         getdate: don't leak when TZ contains two or more '"'s
101899         * lib/getdate.y (get_date): Don't leak a copy of TZ for each
101900         double quote in TZ after the first one.
101902         readtokens: do not leak internal token_lengths buffer
101903         * lib/readtokens.c (readtokens): Free the local, lengths,
101904         when the supplied "token_lengths" parameter is NULL.
101906 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
101908         Fix a couple of missing LIBTHREAD link failures on AIX.
101909         * modules/git-merge-changelog (git_merge_changelog_LDADD): Add
101910         $(LIBTHREAD).
101911         * modules/strsignal-tests (test_strsignal_LDADD): Likewise.
101913         Link test-poll against INET_PTON_LIB.
101914         * modules/poll-tests (test_poll_LDADD): Add $(INET_PTON_LIB),
101915         for inet_pton on Solaris 10.
101917 2010-01-17  Bruno Haible  <bruno@clisp.org>
101919         unistdio/*-sprintf: Fix typo in module description.
101920         * modules/unistdio/u8-sprintf (Depends-on): Fix typo.
101921         * modules/unistdio/u8-u8-sprintf (Depends-on): Likewise.
101922         * modules/unistdio/u16-sprintf (Depends-on): Likewise.
101923         * modules/unistdio/u16-u16-sprintf (Depends-on): Likewise.
101924         * modules/unistdio/u32-sprintf (Depends-on): Likewise.
101925         * modules/unistdio/u32-u32-sprintf (Depends-on): Likewise.
101926         * modules/unistdio/ulc-sprintf (Depends-on): Likewise.
101927         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
101929 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
101931         gnulib-tool: fix filelist for AIX, HP-UX ksh.
101932         * gnulib-tool (func_filter_filelist): Do not quote possibly-empty
101933         variables in shell case patterns, for AIX and HP-UX ksh.
101935         Split large sed scripts, for HP-UX sed.
101936         * modules/stdio: Split sed scripts around 50 sed commands,
101937         to avoid HP-UX limit of 99 commands, in the near future.
101938         * modules/string: Likewise.
101939         * modules/unistd: Likewise.
101941         gnulib-tool: avoid writing in the current directory.
101942         * gnulib-tool (func_emit_lib_Makefile_am)
101943         (func_emit_tests_Makefile_am): Put temporary files in $tmp,
101944         not in the current directory, so concurrent gnulib-tool
101945         instances do not interfere.
101947 2010-01-16  Jim Meyering  <meyering@redhat.com>
101949         doc: update users.txt
101950         * users.txt: Add grep.
101951         (diffutils, gzip): Update URLs.
101953 2010-01-12  Bruno Haible  <bruno@clisp.org>
101955         posix_spawn: Avoid test failure on Cygwin.
101956         * tests/test-posix_spawn3.c (DATA_FILENAME) [CYGWIN]: Use less risky
101957         characters.
101958         Reported by Simon Josefsson.
101960 2010-01-12  Bruno Haible  <bruno@clisp.org>
101962         * tests/test-cond.c (main): When skipping the test, show the reason.
101964 2010-01-12  Simon Josefsson  <simon@josefsson.org>
101966         * lib/striconv.c (str_cd_iconv): Avoid if before free.
101968 2010-01-12  Simon Josefsson  <simon@josefsson.org>
101970         * top/maint.mk (VC_LIST_EXCEPT): Filter list through
101971         VC_LIST_ALWAYS_EXCLUDE_REGEX.
101973 2010-01-12  Eric Blake  <ebb9@byu.net>
101975         build: guarantee AS_VAR_IF
101976         * m4/warnings.m4 (gl_WARN_ADD): Use autoconf name.
101977         (gl_AS_VAR_IF): Move...
101978         * m4/gnulib-common.m4 (AS_VAR_IF): ...here.
101979         Reported by Simon Josefsson.
101981 2010-01-12  Simon Josefsson  <simon@josefsson.org>
101983         * lib/stdio.in.h: Fix typo.
101985 2010-01-12  Simon Josefsson  <simon@josefsson.org>
101987         * m4/gc.m4: Check if linking to libgcrypt also needs linking to
101988         libgpg-error.
101990 2010-01-12  Simon Josefsson  <simon@josefsson.org>
101992         * tests/test-xalloc-die.sh: Use $EXEEXT.
101994 2010-01-12  Simon Josefsson  <simon@josefsson.org>
101995             Bruno Haible  <bruno@clisp.org>
101997         getlogin, getlogin_r: Avoid test failure.
101998         * tests/test-getlogin.c: Include <stdio.h>.
101999         (main): Skip the test when the function fails because stdin is not a
102000         tty.
102001         * tests/test-getlogin_r.c: Include <stdio.h>.
102002         (main): Skip the test when the function fails because stdin is not a
102003         tty.
102005 2010-01-11  Eric Blake  <ebb9@byu.net>
102007         tests: avoid more large file warnings
102008         * tests/test-fflush.c: Avoid warning about ftell use.
102009         * tests/test-fseek.c: Avoid warning about fseek use.
102011 2010-01-10  Bruno Haible  <bruno@clisp.org>
102013         nproc: Work better on Linux when /proc and /sys are not mounted.
102014         * lib/nproc.c (num_processors): Use num_processors_via_affinity_mask ()
102015         as lower bound when, on glibc/Linux systems,
102016         sysconf (_SC_NPROCESSORS_CONF) returns 1.
102017         Suggested by Pádraig Brady <P@draigbrady.com>.
102018         Reported by Dmitry V. Levin <ldv@altlinux.org>.
102020         nproc: Refactor.
102021         * lib/nproc.c (num_processors_via_affinity_mask): New function,
102022         extracted from num_processors.
102023         (num_processors): Call it.
102025 2010-01-11  Jim Meyering  <meyering@redhat.com>
102027         utimecmp: avoid new warning from upcoming gcc-4.5.0
102028         * lib/utimecmp.c (BILLION): Define using #define rather than an
102029         anonymous enum, to placate upcoming gcc-4.5.0's -Wenum-compare.
102031 2010-01-11  Eric Blake  <ebb9@byu.net>
102033         math: add portability warnings for classification macros
102034         * modules/math (Depends-on): Add warn-on-use.
102035         (Makefile.am): Provide new substitutions.
102036         * m4/math_h.m4 (gl_MATH_H): Require inline.
102037         * lib/math.in.h (_GL_WARN_REAL_FLOATING_DECL)
102038         (_GL_WARN_REAL_FLOATING_IMPL): New helper macros.
102039         (isfinite, isinf, isnan, signbit) [GNULIB_POSIXCHECK]: Use them to
102040         implement warnings.
102042         unistd: warn on use of environ without module
102043         * modules/unistd (Depends-on): Add warn-on-use.
102044         (Makefile.am): Provide new substitutions.
102045         * m4/unistd_h.m4 (gl_UNISTD_H): Check for inline and environ.
102046         * lib/unistd.in.h (environ): Wrap with a warning helper function.
102048         stdio: warn on suspicious uses
102049         * modules/stdio (Depends-on): Add warn-on-use.
102050         (Makefile.am): Provide new substitutions.
102051         * m4/stdio_h.m4 (gl_STDIO_H): Check for inline, ftello, and
102052         fseeko.
102053         * lib/stdio.in.h (gets): Always warn on use.
102054         (fseek, ftell): Adjust when warnings are issued, and honor
102055         _GL_NO_LARGE_FILES as a way to silence the warning.
102056         * tests/test-fpurge.c [!GNULIB_FSEEK]: Use new means to squelch
102057         any warning about large file offsets.
102058         * tests/test-freadable.c [!GNULIB_FSEEK]: Likewise.
102059         * tests/test-freading.c [!GNULIB_FSEEK]: Likewise.
102060         * tests/test-fseeko.c [!GNULIB_FSEEK]: Likewise.
102061         * tests/test-ftell.c [!GNULIB_FSEEK]: Likewise.
102062         * tests/test-ftello.c [!GNULIB_FSEEK]: Likewise.
102063         * tests/test-fwritable.c [!GNULIB_FSEEK]: Likewise.
102064         * tests/test-fwriting.c [!GNULIB_FSEEK]: Likewise.
102065         * tests/test-getopt.c [!GNULIB_FTELL]: Likewise.
102067         warn-on-use: new module
102068         * modules/warn-on-use: New file.
102069         * build-aux/warn-on-use.h: Likewise.
102070         * m4/warn-on-use.m4: Likewise.
102071         * MODULES.html.sh (Support for building): Mention it.
102073 2010-01-10  Bruno Haible  <bruno@clisp.org>
102075         Tests for module 'unistr/u32-strdup'.
102076         * modules/unistr/u32-strdup-tests: New file.
102077         * tests/unistr/test-u32-strdup.c: New file.
102079         Tests for module 'unistr/u16-strdup'.
102080         * modules/unistr/u16-strdup-tests: New file.
102081         * tests/unistr/test-u16-strdup.c: New file.
102083         Tests for module 'unistr/u8-strdup'.
102084         * modules/unistr/u8-strdup-tests: New file.
102085         * tests/unistr/test-u8-strdup.c: New file.
102086         * tests/unistr/test-strdup.h: New file.
102088         Tests for module 'unistr/u32-strncmp'.
102089         * modules/unistr/u32-strncmp-tests: New file.
102090         * tests/unistr/test-u32-strncmp.c: New file.
102092         Tests for module 'unistr/u16-strncmp'.
102093         * modules/unistr/u16-strncmp-tests: New file.
102094         * tests/unistr/test-u16-strncmp.c: New file.
102096         Tests for module 'unistr/u8-strncmp'.
102097         * modules/unistr/u8-strncmp-tests: New file.
102098         * tests/unistr/test-u8-strncmp.c: New file.
102099         * tests/unistr/test-strncmp.h: New file.
102101         Tests for module 'unistr/u32-strcoll'.
102102         * modules/unistr/u32-strcoll-tests: New file.
102103         * tests/unistr/test-u32-strcoll.c: New file.
102105         Tests for module 'unistr/u16-strcoll'.
102106         * modules/unistr/u16-strcoll-tests: New file.
102107         * tests/unistr/test-u16-strcoll.c: New file.
102109         Tests for module 'unistr/u8-strcoll'.
102110         * modules/unistr/u8-strcoll-tests: New file.
102111         * tests/unistr/test-u8-strcoll.c: New file.
102113         Tests for module 'unistr/u32-strcmp'.
102114         * modules/unistr/u32-strcmp-tests: New file.
102115         * tests/unistr/test-u32-strcmp.c: New file.
102116         * tests/unistr/test-u32-strcmp.h: New file.
102118         Tests for module 'unistr/u16-strcmp'.
102119         * modules/unistr/u16-strcmp-tests: New file.
102120         * tests/unistr/test-u16-strcmp.c: New file.
102121         * tests/unistr/test-u16-strcmp.h: New file.
102123         Tests for module 'unistr/u8-strcmp'.
102124         * modules/unistr/u8-strcmp-tests: New file.
102125         * tests/unistr/test-u8-strcmp.c: New file.
102126         * tests/unistr/test-u8-strcmp.h: New file.
102127         * tests/unistr/test-strcmp.h: New file.
102129         Tests for module 'unistr/u32-strncat'.
102130         * modules/unistr/u32-strncat-tests: New file.
102131         * tests/unistr/test-u32-strncat.c: New file.
102133         Tests for module 'unistr/u16-strncat'.
102134         * modules/unistr/u16-strncat-tests: New file.
102135         * tests/unistr/test-u16-strncat.c: New file.
102137         Tests for module 'unistr/u8-strncat'.
102138         * modules/unistr/u8-strncat-tests: New file.
102139         * tests/unistr/test-u8-strncat.c: New file.
102140         * tests/unistr/test-strncat.h: New file.
102142         Tests for module 'unistr/u32-strcat'.
102143         * modules/unistr/u32-strcat-tests: New file.
102144         * tests/unistr/test-u32-strcat.c: New file.
102146         Tests for module 'unistr/u16-strcat'.
102147         * modules/unistr/u16-strcat-tests: New file.
102148         * tests/unistr/test-u16-strcat.c: New file.
102150         Tests for module 'unistr/u8-strcat'.
102151         * modules/unistr/u8-strcat-tests: New file.
102152         * tests/unistr/test-u8-strcat.c: New file.
102153         * tests/unistr/test-strcat.h: New file.
102155         Tests for module 'unistr/u32-stpncpy'.
102156         * modules/unistr/u32-stpncpy-tests: New file.
102157         * tests/unistr/test-u32-stpncpy.c: New file.
102159         Tests for module 'unistr/u16-stpncpy'.
102160         * modules/unistr/u16-stpncpy-tests: New file.
102161         * tests/unistr/test-u16-stpncpy.c: New file.
102163         Tests for module 'unistr/u8-stpncpy'.
102164         * modules/unistr/u8-stpncpy-tests: New file.
102165         * tests/unistr/test-u8-stpncpy.c: New file.
102166         * tests/unistr/test-stpncpy.h: New file.
102168         Tests for module 'unistr/u32-strncpy'.
102169         * modules/unistr/u32-strncpy-tests: New file.
102170         * tests/unistr/test-u32-strncpy.c: New file.
102172         Tests for module 'unistr/u16-strncpy'.
102173         * modules/unistr/u16-strncpy-tests: New file.
102174         * tests/unistr/test-u16-strncpy.c: New file.
102176         Tests for module 'unistr/u8-strncpy'.
102177         * modules/unistr/u8-strncpy-tests: New file.
102178         * tests/unistr/test-u8-strncpy.c: New file.
102179         * tests/unistr/test-strncpy.h: New file.
102181         Tests for module 'unistr/u32-stpcpy'.
102182         * modules/unistr/u32-stpcpy-tests: New file.
102183         * tests/unistr/test-u32-stpcpy.c: New file.
102185         Tests for module 'unistr/u16-stpcpy'.
102186         * modules/unistr/u16-stpcpy-tests: New file.
102187         * tests/unistr/test-u16-stpcpy.c: New file.
102189         Tests for module 'unistr/u8-stpcpy'.
102190         * modules/unistr/u8-stpcpy-tests: New file.
102191         * tests/unistr/test-u8-stpcpy.c: New file.
102192         * tests/unistr/test-stpcpy.h: New file.
102194         Tests for module 'unistr/u32-strcpy'.
102195         * modules/unistr/u32-strcpy-tests: New file.
102196         * tests/unistr/test-u32-strcpy.c: New file.
102198         Tests for module 'unistr/u16-strcpy'.
102199         * modules/unistr/u16-strcpy-tests: New file.
102200         * tests/unistr/test-u16-strcpy.c: New file.
102202         Tests for module 'unistr/u8-strcpy'.
102203         * modules/unistr/u8-strcpy-tests: New file.
102204         * tests/unistr/test-u8-strcpy.c: New file.
102205         * tests/unistr/test-strcpy.h: New file.
102207         Tests for module 'unistr/u32-strnlen'.
102208         * modules/unistr/u32-strnlen-tests: New file.
102209         * tests/unistr/test-u32-strnlen.c: New file.
102211         Tests for module 'unistr/u16-strnlen'.
102212         * modules/unistr/u16-strnlen-tests: New file.
102213         * tests/unistr/test-u16-strnlen.c: New file.
102215         Tests for module 'unistr/u8-strnlen'.
102216         * modules/unistr/u8-strnlen-tests: New file.
102217         * tests/unistr/test-u8-strnlen.c: New file.
102218         * tests/unistr/test-strnlen.h: New file.
102220         Tests for module 'unistr/u32-strlen'.
102221         * modules/unistr/u32-strlen-tests: New file.
102222         * tests/unistr/test-u32-strlen.c: New file.
102224         Tests for module 'unistr/u16-strlen'.
102225         * modules/unistr/u16-strlen-tests: New file.
102226         * tests/unistr/test-u16-strlen.c: New file.
102228         Tests for module 'unistr/u8-strlen'.
102229         * modules/unistr/u8-strlen-tests: New file.
102230         * tests/unistr/test-u8-strlen.c: New file.
102232         Tests for module 'unistr/u32-prev'.
102233         * modules/unistr/u32-prev-tests: New file.
102234         * tests/unistr/test-u32-prev.c: New file.
102236         Tests for module 'unistr/u16-prev'.
102237         * modules/unistr/u16-prev-tests: New file.
102238         * tests/unistr/test-u16-prev.c: New file.
102240         Tests for module 'unistr/u8-prev'.
102241         * modules/unistr/u8-prev-tests: New file.
102242         * tests/unistr/test-u8-prev.c: New file.
102244         Tests for module 'unistr/u32-next'.
102245         * modules/unistr/u32-next-tests: New file.
102246         * tests/unistr/test-u32-next.c: New file.
102248         Tests for module 'unistr/u16-next'.
102249         * modules/unistr/u16-next-tests: New file.
102250         * tests/unistr/test-u16-next.c: New file.
102252         Tests for module 'unistr/u8-next'.
102253         * modules/unistr/u8-next-tests: New file.
102254         * tests/unistr/test-u8-next.c: New file.
102256         Tests for module 'unistr/u32-strmbtouc'.
102257         * modules/unistr/u32-strmbtouc-tests: New file.
102258         * tests/unistr/test-u32-strmbtouc.c: New file.
102260         Tests for module 'unistr/u16-strmbtouc'.
102261         * modules/unistr/u16-strmbtouc-tests: New file.
102262         * tests/unistr/test-u16-strmbtouc.c: New file.
102264         Tests for module 'unistr/u8-strmbtouc'.
102265         * modules/unistr/u8-strmbtouc-tests: New file.
102266         * tests/unistr/test-u8-strmbtouc.c: New file.
102268         Tests for module 'unistr/u32-strmblen'.
102269         * modules/unistr/u32-strmblen-tests: New file.
102270         * tests/unistr/test-u32-strmblen.c: New file.
102272         Tests for module 'unistr/u16-strmblen'.
102273         * modules/unistr/u16-strmblen-tests: New file.
102274         * tests/unistr/test-u16-strmblen.c: New file.
102276         Tests for module 'unistr/u8-strmblen'.
102277         * modules/unistr/u8-strmblen-tests: New file.
102278         * tests/unistr/test-u8-strmblen.c: New file.
102280         Tests for module 'unistr/u32-cpy-alloc'.
102281         * modules/unistr/u32-cpy-alloc-tests: New file.
102282         * tests/unistr/test-u32-cpy-alloc.c: New file.
102284         Tests for module 'unistr/u16-cpy-alloc'.
102285         * modules/unistr/u16-cpy-alloc-tests: New file.
102286         * tests/unistr/test-u16-cpy-alloc.c: New file.
102288         Tests for module 'unistr/u8-cpy-alloc'.
102289         * modules/unistr/u8-cpy-alloc-tests: New file.
102290         * tests/unistr/test-u8-cpy-alloc.c: New file.
102291         * tests/unistr/test-cpy-alloc.h: New file.
102293         Tests for module 'unistr/u32-mbsnlen'.
102294         * modules/unistr/u32-mbsnlen-tests: New file.
102295         * tests/unistr/test-u32-mbsnlen.c: New file.
102297         Tests for module 'unistr/u16-mbsnlen'.
102298         * modules/unistr/u16-mbsnlen-tests: New file.
102299         * tests/unistr/test-u16-mbsnlen.c: New file.
102301         Tests for module 'unistr/u8-mbsnlen'.
102302         * modules/unistr/u8-mbsnlen-tests: New file.
102303         * tests/unistr/test-u8-mbsnlen.c: New file.
102305         Tests for module 'unistr/u32-chr'.
102306         * modules/unistr/u32-chr-tests: New file.
102307         * tests/unistr/test-u32-chr.c: New file.
102309         Tests for module 'unistr/u16-chr'.
102310         * modules/unistr/u16-chr-tests: New file.
102311         * tests/unistr/test-u16-chr.c: New file.
102313         Tests for module 'unistr/u8-chr'.
102314         * modules/unistr/u8-chr-tests: New file.
102315         * tests/unistr/test-u8-chr.c: New file.
102316         * tests/unistr/test-chr.h: New file, based on tests/test-memchr.c.
102318         Tests for module 'unistr/u32-cmp2'.
102319         * modules/unistr/u32-cmp2-tests: New file.
102320         * tests/unistr/test-u32-cmp2.c: New file.
102322         Tests for module 'unistr/u16-cmp2'.
102323         * modules/unistr/u16-cmp2-tests: New file.
102324         * tests/unistr/test-u16-cmp2.c: New file.
102326         Tests for module 'unistr/u8-cmp2'.
102327         * modules/unistr/u8-cmp2-tests: New file.
102328         * tests/unistr/test-u8-cmp2.c: New file.
102329         * tests/unistr/test-cmp2.h: New file, based on tests/unistr/test-cmp.h.
102331         Tests for module 'unistr/u32-cmp'.
102332         * modules/unistr/u32-cmp-tests: New file.
102333         * tests/unistr/test-u32-cmp.c: New file.
102335         Tests for module 'unistr/u16-cmp'.
102336         * modules/unistr/u16-cmp-tests: New file.
102337         * tests/unistr/test-u16-cmp.c: New file.
102339         Tests for module 'unistr/u8-cmp'.
102340         * modules/unistr/u8-cmp-tests: New file.
102341         * tests/unistr/test-u8-cmp.c: New file.
102342         * tests/unistr/test-cmp.h: New file, based on tests/test-memcmp.c.
102344         Tests for module 'unistr/u32-set'.
102345         * modules/unistr/u32-set-tests: New file.
102346         * tests/unistr/test-u32-set.c: New file.
102348         Tests for module 'unistr/u16-set'.
102349         * modules/unistr/u16-set-tests: New file.
102350         * tests/unistr/test-u16-set.c: New file.
102352         Tests for module 'unistr/u8-set'.
102353         * modules/unistr/u8-set-tests: New file.
102354         * tests/unistr/test-u8-set.c: New file.
102355         * tests/unistr/test-set.h: New file.
102357         Tests for module 'unistr/u32-move'.
102358         * modules/unistr/u32-move-tests: New file.
102359         * tests/unistr/test-u32-move.c: New file.
102361         Tests for module 'unistr/u16-move'.
102362         * modules/unistr/u16-move-tests: New file.
102363         * tests/unistr/test-u16-move.c: New file.
102365         Tests for module 'unistr/u8-move'.
102366         * modules/unistr/u8-move-tests: New file.
102367         * tests/unistr/test-u8-move.c: New file.
102368         * tests/unistr/test-move.h: New file.
102370         Tests for module 'unistr/u32-cpy'.
102371         * modules/unistr/u32-cpy-tests: New file.
102372         * tests/unistr/test-u32-cpy.c: New file.
102374         Tests for module 'unistr/u16-cpy'.
102375         * modules/unistr/u16-cpy-tests: New file.
102376         * tests/unistr/test-u16-cpy.c: New file.
102378         Tests for module 'unistr/u8-cpy'.
102379         * modules/unistr/u8-cpy-tests: New file.
102380         * tests/unistr/test-u8-cpy.c: New file.
102381         * tests/unistr/test-cpy.h: New file.
102383 2010-01-09  Bruno Haible  <bruno@clisp.org>
102385         Tests for module 'unistr/u32-uctomb'.
102386         * modules/unistr/u32-uctomb-tests: New file.
102387         * tests/unistr/test-u32-uctomb.c: New file.
102389         Tests for module 'unistr/u16-uctomb'.
102390         * modules/unistr/u16-uctomb-tests: New file.
102391         * tests/unistr/test-u16-uctomb.c: New file.
102393         Tests for module 'unistr/u8-uctomb'.
102394         * modules/unistr/u8-uctomb-tests: New file.
102395         * tests/unistr/test-u8-uctomb.c: New file.
102397         Tests for module 'unistr/u32-mbtoucr'.
102398         * modules/unistr/u32-mbtoucr-tests: New file.
102399         * tests/unistr/test-u32-mbtoucr.c: New file.
102401         Tests for module 'unistr/u16-mbtoucr'.
102402         * modules/unistr/u16-mbtoucr-tests: New file.
102403         * tests/unistr/test-u16-mbtoucr.c: New file.
102405         Tests for module 'unistr/u8-mbtoucr'.
102406         * modules/unistr/u8-mbtoucr-tests: New file.
102407         * tests/unistr/test-u8-mbtoucr.c: New file.
102409         Tests for module 'unistr/u32-mbtouc'.
102410         * modules/unistr/u32-mbtouc-tests: New file.
102411         * tests/unistr/test-u32-mbtouc.c: New file.
102413         Tests for module 'unistr/u16-mbtouc'.
102414         * modules/unistr/u16-mbtouc-tests: New file.
102415         * tests/unistr/test-u16-mbtouc.c: New file.
102417         Tests for module 'unistr/u8-mbtouc'.
102418         * modules/unistr/u8-mbtouc-tests: New file.
102419         * tests/unistr/test-u8-mbtouc.c: New file.
102421         Tests for module 'unistr/u32-mbtouc-unsafe'.
102422         * modules/unistr/u32-mbtouc-unsafe-tests: New file.
102423         * tests/unistr/test-u32-mbtouc-unsafe.c: New file.
102424         * tests/unistr/test-u32-mbtouc.h: New file.
102426         Tests for module 'unistr/u16-mbtouc-unsafe'.
102427         * modules/unistr/u16-mbtouc-unsafe-tests: New file.
102428         * tests/unistr/test-u16-mbtouc-unsafe.c: New file.
102429         * tests/unistr/test-u16-mbtouc.h: New file.
102431         Tests for module 'unistr/u8-mbtouc-unsafe'.
102432         * modules/unistr/u8-mbtouc-unsafe-tests: New file.
102433         * tests/unistr/test-u8-mbtouc-unsafe.c: New file.
102434         * tests/unistr/test-u8-mbtouc.h: New file.
102436         Tests for module 'unistr/u32-mblen'.
102437         * modules/unistr/u32-mblen-tests: New file.
102438         * tests/unistr/test-u32-mblen.c: New file.
102440         Tests for module 'unistr/u16-mblen'.
102441         * modules/unistr/u16-mblen-tests: New file.
102442         * tests/unistr/test-u16-mblen.c: New file.
102444         Tests for module 'unistr/u8-mblen'.
102445         * modules/unistr/u8-mblen-tests: New file.
102446         * tests/unistr/test-u8-mblen.c: New file.
102448         Tests for module 'unistr/u32-to-u16'.
102449         * modules/unistr/u32-to-u16-tests: New file.
102450         * tests/unistr/test-u32-to-u16.c: New file.
102452         Tests for module 'unistr/u32-to-u8'.
102453         * modules/unistr/u32-to-u8-tests: New file.
102454         * tests/unistr/test-u32-to-u8.c: New file.
102456         Tests for module 'unistr/u16-to-u32'.
102457         * modules/unistr/u16-to-u32-tests: New file.
102458         * tests/unistr/test-u16-to-u32.c: New file.
102460         Tests for module 'unistr/u16-to-u8'.
102461         * modules/unistr/u16-to-u8-tests: New file.
102462         * tests/unistr/test-u16-to-u8.c: New file.
102464         Tests for module 'unistr/u8-to-u32'.
102465         * modules/unistr/u8-to-u32-tests: New file.
102466         * tests/unistr/test-u8-to-u32.c: New file.
102468         Tests for module 'unistr/u8-to-u16'.
102469         * modules/unistr/u8-to-u16-tests: New file.
102470         * tests/unistr/test-u8-to-u16.c: New file.
102472         Tests for module 'unistr/u32-check'.
102473         * modules/unistr/u32-check-tests: New file.
102474         * tests/unistr/test-u32-check.c: New file.
102476         Tests for module 'unistr/u16-check'.
102477         * modules/unistr/u16-check-tests: New file.
102478         * tests/unistr/test-u16-check.c: New file.
102480         Tests for module 'unistr/u8-check'.
102481         * modules/unistr/u8-check-tests: New file.
102482         * tests/unistr/test-u8-check.c: New file.
102484         * tests/unictype/test-categ_byname.c: Include <stdbool.h>.
102485         (category_equals): New function.
102486         (main): Add more tests.
102487         * modules/unictype/category-byname-tests (Depends-on): Add stdbool.
102489         * tests/unictype/test-bidi_byname.c (main): Add more tests.
102491 2010-01-10  Bruno Haible  <bruno@clisp.org>
102493         unistr/u*-strcoll: Try harder to distinguish different strings.
102494         * lib/unistr/u-strcoll.h (FUNC): When sl1 and sl2 are the same,
102495         compare s1 and s2 to see if they are different.
102497 2010-01-10  Bruno Haible  <bruno@clisp.org>
102499         unistr/u*-stpncpy: Fix the return value.
102500         * lib/unistr.h (u8_stpncpy, u16_stpncpy, u32_stpncpy): Make the
102501         description of the return value consistent with stpncpy in glibc.
102502         * lib/unistr/u-stpncpy.h (FUNC): Return the pointer past the last
102503         written non-NUL unit.
102505 2010-01-10  Bruno Haible  <bruno@clisp.org>
102507         unistr/u*-next: Add missing dependencies.
102508         * modules/unistr/u8-next (Depends-on): Add unistr/u8-strmbtouc.
102509         * modules/unistr/u16-next (Depends-on): Add unistr/u16-strmbtouc.
102510         * modules/unistr/u32-next (Depends-on): Add unistr/u32-strmbtouc.
102512 2010-01-10  Bruno Haible  <bruno@clisp.org>
102514         unistr/u8-mbsnlen: Fix return value for incomplete character.
102515         * lib/unistr/u8-mbsnlen.c (u8_mbsnlen): Use u8_mbtoucr instead of
102516         u8_mblen.
102517         * modules/unistr/u8-mbsnlen (Depends-on): Add unistr/u8-mbtoucr.
102518         Remove unistr/u8-mblen.
102519         * lib/unistr/u16-mbsnlen.c (u16_mbsnlen): Use u16_mbtoucr instead of
102520         u16_mblen.
102521         * modules/unistr/u16-mbsnlen (Depends-on): Add unistr/u16-mbtoucr.
102522         Remove unistr/u16-mblen.
102524 2010-01-10  Bruno Haible  <bruno@clisp.org>
102526         wchar: Fix compilation error when <wchar.h> is used from coreutils.
102527         * lib/wchar.in.h: Treat __need_wint_t like __need_mbstate_t.
102528         Reported by Brian Gough <bjg@gnu.org> and
102529         Chris Clayton <chris2553@googlemail.com> via
102530         Mike Frysinger <vapier@gentoo.org> and Jim Meyering <jim@meyering.net>.
102532 2010-01-09  Bruno Haible  <bruno@clisp.org>
102534         unistr/u16-to-u32: Reject invalid input.
102535         * lib/unistr/u16-to-u32.c (u16_to_u32): Call u16_mbtoucr instead of
102536         u16_mbtouc.
102537         * modules/unistr/u16-to-u32 (Depends-on): Add unistr/u16-mbtoucr.
102538         Remove unistr/u16-mbtouc.
102540         unistr/u16-to-u8: Reject invalid input.
102541         * lib/unistr/u16-to-u8.c (u16_to_u8): Call u16_mbtoucr instead of
102542         u16_mbtouc.
102543         * modules/unistr/u16-to-u8 (Depends-on): Add unistr/u16-mbtoucr.
102544         Remove unistr/u16-mbtouc.
102546         unistr/u8-to-u32: Reject invalid input.
102547         * lib/unistr/u8-to-u32.c (u8_to_u32): Call u8_mbtoucr instead of
102548         u8_mbtouc.
102549         * modules/unistr/u8-to-u32 (Depends-on): Add unistr/u8-mbtoucr.
102550         Remove unistr/u8-mbtouc.
102552         unistr/u8-to-u16: Reject invalid input.
102553         * lib/unistr/u8-to-u16.c (u8_to_u16): Call u8_mbtoucr instead of
102554         u8_mbtouc.
102555         * modules/unistr/u8-to-u16 (Depends-on): Add unistr/u8-mbtoucr.
102556         Remove unistr/u8-mbtouc.
102558 2010-01-09  Bruno Haible  <bruno@clisp.org>
102560         Tests for module 'getlogin'.
102561         * modules/getlogin-tests: New file.
102562         * tests/test-getlogin.c: New file.
102564         New module 'getlogin'.
102565         * lib/unistd.in.h (getlogin): New declaration.
102566         * lib/getlogin.c: New file.
102567         * m4/getlogin.m4: New file.
102568         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETLOGIN,
102569         HAVE_GETLOGIN.
102570         * modules/unistd (Makefile.am): Substitute GNULIB_GETLOGIN,
102571         HAVE_GETLOGIN.
102572         * modules/getlogin: New file.
102573         * doc/posix-functions/getlogin.texi: Mention the new module.
102574         Reported by John W. Eaton <jwe@gnu.org>.
102576 2010-01-09  Bruno Haible  <bruno@clisp.org>
102578         getlogin_r: Support for native Windows.
102579         * lib/getlogin_r.c: Include <windows.h>
102580         (getlogin_r): Implement for native Windows.
102581         * tests/test-getlogin_r.c (main): Also test with a huge buffer.
102582         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>
102583         via John W. Eaton <jwe@gnu.org>.
102585 2010-01-09  Bruno Haible  <bruno@clisp.org>
102587         getlogin_r: Small fixes.
102588         * lib/getlogin_r.c (getlogin_r): Don't set errno if the function
102589         succeeds.
102590         * m4/getlogin_r.m4 (gl_GETLOGIN_R): Require gl_USE_SYSTEM_EXTENSIONS
102591         before testing whether getlogin_r is declared. No need to set
102592         HAVE_DECL_GETLOGIN_R to 1.
102593         (gl_PREREQ_GETLOGIN_R): Don't check for the getlogin_r declaration.
102595 2010-01-09  Bruno Haible  <bruno@clisp.org>
102597         * lib/unistd.in.h (getlogin_r): Add comment.
102599 2010-01-09  Bruno Haible  <bruno@clisp.org>
102601         Tests for module 'getlogin_r'.
102602         * modules/getlogin_r-tests: New file.
102603         * tests/test-getlogin_r.c: New file.
102605 2010-01-09  Jim Meyering  <meyering@redhat.com>
102607         maint.mk: extend proper_name_utf8-vs-LIBICONV-checking rule
102608         * top/maint.mk (sc_proper_name_utf8_requires_ICONV): Adapt to work
102609         also when $(LIBICONV) is part of LDADD, rather than ${prog}_LDADD.
102611 2010-01-08  Simon Josefsson  <simon@josefsson.org>
102613         * lib/dup2.c (rpl_dup2): Improve comment.
102615 2010-01-08  Eric Blake  <ebb9@byu.net>
102617         maint.mk: allow packages to add makefile @@ exceptions
102618         * top/maint.mk (_makefile_at_at_check_exceptions): New hook.
102619         (sc_makefile_check): Rename...
102620         (sc_makefile_at_at_check): ...to this, and use hook.
102622         dup2: work around mingw bug
102623         * lib/dup2.c (rpl_dup2): Sanitize return value on mingw.
102624         Reported by Simon Josefsson.
102626 2010-01-07  John W. Eaton  <jwe@octave.org>  (tiny change)
102628         glob: Fix C++ compilation.
102629         * lib/glob.in.h [__cplusplus]: Define __BEGIN_DECLS and __END_DECLS for
102630         C++.
102632 2010-01-07  Bruno Haible  <bruno@clisp.org>
102634         Fix indentation of wctype.in.h, broken since 2007-01-06.
102635         * lib/wctype.in.h: Fix indentation of preprocessor directives.
102637 2010-01-07  Bruno Haible  <bruno@clisp.org>
102639         mbslen: Avoid collision with system function.
102640         * lib/string.in.h [MirBSD]: Include <wchar.h>.
102641         (mbslen): Undefine first. Alias mbslen to rpl_mbslen.
102642         * m4/mbslen.m4: New file.
102643         * modules/mbslen (Files): Add it.
102644         (configure.ac): Invoke gl_MBSLEN.
102645         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize HAVE_MBSLEN.
102646         * modules/string (Makefile.am): Substitute HAVE_MBSLEN.
102647         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>
102648         via Ian Beckwith <ianb@erislabs.net>.
102650 2010-01-07  Bruno Haible  <bruno@clisp.org>
102652         dirent: Document the last fix.
102653         * doc/posix-headers/dirent.texi: Document the bug of missing 'ino_t'.
102655 2010-01-07  Bruno Haible  <bruno@clisp.org>
102657         stdio: Ensure <stdio.h> defines off_t, ssize_t, va_list.
102658         * lib/stdio.in.h: Include <sys/types.h> unconditionally.
102659         * tests/test-stdio.c: Verify that fpos_t, off_t, size_t, ssize_t,
102660         va_list are defined.
102661         * doc/posix-headers/stdio.texi: Document the bug of missing types.
102662         Reported by Eric Blake.
102664 2010-01-07  Bruno Haible  <bruno@clisp.org>
102666         xlist, xoset: Fix missing dependency bug, introduced on 2009-12-13.
102667         * modules/xlist (Depends-on): Add 'list',
102668         * modules/xoset (Depends-on): Add 'oset'.
102669         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
102671 2010-01-07  Bruno Haible  <bruno@clisp.org>
102673         * doc/posix-functions/strcasecmp.texi: Clarify the platforms.
102674         * doc/posix-functions/strncasecmp.texi: Likewise.
102676 2010-01-07  Bruno Haible  <bruno@clisp.org>
102678         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Simplify logic.
102680 2010-01-07  John W. Eaton  <jwe@octave.org>
102682         wctype: allow C++ use
102683         * lib/wctype.in.h: Add extern "C" block for C++.
102685 2010-01-06  Eric Blake  <ebb9@byu.net>
102687         maint.mk: detect incorrect GFDL usage
102688         * top/maint.mk (_GFDL_regexp, sc_GFDL_version): New rule.
102690 2010-01-06  Jim Meyering  <meyering@redhat.com>
102691         and Eric Blake  <ebb9@byu.net>
102693         maint.mk: ignore multi-line copyright in NEWS
102694         * top/maint.mk (NEWS_hash): Add immunity to multi-line copyright.
102696 2010-01-06  Eric Blake  <ebb9@byu.net>
102698         select: add missing dependency
102699         * modules/select-tests (Depends-on): Move sockets dependency...
102700         * modules/select (Depends-on): ...here.
102701         Reported by Ian Beckwith.
102703         doc: regenerate INSTALL
102704         * doc/INSTALL: Reflect recent autoconf update.
102705         * doc/INSTALL.ISO: Likewise.
102706         * doc/INSTALL.UTF-8: Likewise.
102708         pread: fix compilation on glibc
102709         * m4/pread.m4 (gl_FUNC_PREAD): Request all interfaces.
102710         Reported by Ralf Wildenhues.
102712         dirent: fix test failure
102713         * lib/dirent.in.h (includes): Guarantee ino_t.
102714         Reported by Ralf Wildenhues.
102716 2010-01-06  Petr Salinger  <Petr.Salinger@seznam.cz>  (tiny change)
102718         linkat, renameat: avoid bad free
102719         * lib/at-func2.c (at_func2): Fix typo.
102720         Reported via Ian Beckwith, from http://bugs.debian.org/561117.
102722 2010-01-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
102724         cleanup after gl_FUNC_READLINK, for gl_FUNC_SYMLINK test
102725         * m4/readlink.m4 (gl_FUNC_READLINK): Remove conftest.lnk2,
102726         to avoid failure of symlink test later.
102728 2010-01-06  Eric Blake  <ebb9@byu.net>
102730         stdio, unistd: guarantee ssize_t
102731         * lib/unistd.in.h (includes): Ensure that types required by POSIX
102732         2008 are exposed when needed.
102733         * lib/stdio.in.h (includes): Likewise.
102734         Reported by Ralf Wildenhues.
102736 2010-01-06  Paolo Bonzini  <bonzini@gnu.org>
102738         nl_langinfo: do not call AC_CHECK_FUNC_ONCE inside if.
102739         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Do not call
102740         AC_CHECK_FUNC_ONCE inside if, do not adjust ac_cv_func_nl_langinfo.
102742 2010-01-06  Jim Meyering  <meyering@redhat.com>
102744         readtokens: this module *does* require xalloc.h
102745         It uses only functions that were omitted by the old syntax-check rule.
102746         * lib/readtokens.c: Include "xalloc.h" once again.
102747         * modules/readtokens (Depends-on): Add xalloc.
102748         This reverts part of 0e0f8f12ec241c0f1c1f21f960bb5cf908a0fa3c.
102750 2010-01-05  Eric Blake  <ebb9@byu.net>
102752         maint: support 'make announcement' from a VPATH build
102753         * top/maint.mk (announcement): Look for correct NEWS file.
102755 2010-01-05  Aurelien Jarno  <aurelien@aurel32.net>  (tiny change)
102757         utimens (fdutimens): ignore a negative FD, per contract
102758         * lib/utimens.c (fdutimens) [HAVE_FUTIMENS]: Call futimens only
102759         when we have a valid file descriptor.  Otherwise, using a brand
102760         new glibc (with just-patched futimens that now fails with EBADF)
102761         would cause this function to fail with ENOSYS.
102762         Reported by Guillaume Ayoub in http://bugs.debian.org/563726.
102763         See also http://bugzilla.redhat.com/552320.
102765 2010-01-05  Eric Blake  <ebb9@byu.net>
102767         strcase: document what it provides
102768         * doc/posix-functions/strcasecmp.texi (strcasecmp): Mention the
102769         gnulib module.
102770         * doc/posix-functions/strncasecmp.texi (strncasecmp): Likewise.
102771         Reported by Dilyan Palauzov <Dilyan.Palauzov@aegee.org>.
102773 2010-01-05  Jim Meyering  <meyering@redhat.com>
102775         maint: remove useless inclusions of "xalloc.h"
102776         * lib/getloadavg.c: Remove useless inclusion of "xalloc.h".
102777         * lib/readtokens.c: Likewise.
102778         * lib/same.c: Likewise.
102779         * modules/getloadavg (Depends-on): Remove xalloc.
102780         * modules/readtokens: Likewise.
102781         * modules/same: Likewise.
102783         maint.mk: include 4 more function names in alloca.h-checking regexp
102784         * top/maint.mk (sc_prohibit_xalloc_without_use): Use more complete
102785         regexp.  Before, we would give a false-positive (saying alloca.h
102786         is included unnecessarily) when the only uses involved omitted symbols.
102788         xalloc.h: use consistent formatting
102789         * lib/xalloc.h: Move declarations to start in the first column.
102791 2010-01-05  Eric Blake  <ebb9@byu.net>
102793         mkdir: avoid xalloc
102794         * lib/mkdir.c (includes): Drop unused header.
102795         Reported by John W. Eaton.
102797 2010-01-04  Jim Meyering  <meyering@redhat.com>
102799         nl_langinfo: avoid configure-time syntax error
102800         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): When we've already tested
102801         for nl_langinfo.h, AC_CHECK_FUNCS_ONCE([nl_langinfo]) expands to
102802         the empty string.  Don't let that provoke a shell syntax error.
102804         regcomp, regexec, fnmatch: avoid array bounds read error
102805         * lib/regcomp.c (build_equiv_class): From glibc:
102806         Use only the low 24 bits of a findidx return value as an index
102807         into the weights array.  Patch by Ulrich Drepper:
102808         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commit;h=b7d1c5fa30
102809         * lib/regexec.c (check_node_accept_bytes): Likewise.
102810         * lib/fnmatch_loop.c (FCT): Likewise.
102812         regcomp: skip collseq lookup when there are no rules
102813         * lib/regcomp.c (lookup_collation_sequence_value): From glibc:
102814         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a532a41df58
102816         regcomp: recognize ill-formed { } expressions
102817         * lib/regcomp.c (parse_dup_op): From glibc:
102818         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a87cd2894cb
102820         regcomp: fix typo in comment
102821         * lib/regcomp.c (duplicate_node_closure): Sync from glibc.
102822         s/satisfy/satisfies/.
102824         regcomp: sync from glibc: remove dead store
102825         * lib/regcomp.c (duplicate_node_closure): Remove useless
102826         search_duplicated_node call and dead store.
102828         regcomp: sync from glibc; always use nl_langinfo
102829         * lib/regcomp.c (init_dfa) [!LIBC]: Always use nl_langinfo (CODESET),
102830         now that gnulib provides it.  Recognize UTF8 as well as UTF-8.
102831         * modules/regex (Depends-on): Add nl_langinfo.
102833 2010-01-04  Eric Blake  <ebb9@byu.net>
102835         fdopendir: fix configure test
102836         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for existing file.
102838 2010-01-01  Bruno Haible  <bruno@clisp.org>
102840         wchar: Remove unused configure check.
102841         * m4/wchar.m4 (gl_WCHAR_H): Don't test whether <wchar.h> is standalone.
102843 2010-01-01  Eric Blake  <ebb9@byu.net>
102845         headers: make check of system header explicit
102846         * m4/netdb_h.m4 (gl_HEADER_NETDB): Don't exploit knowledge of
102847         gl_CHECK_NEXT_HEADER internals, but call AC_CHECK_HEADERS_ONCE
102848         ourselves.
102849         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
102850         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
102851         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
102852         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise, for gt_INTTYPES_PRI
102853         internals.
102854         * m4/wchar.m4 (gl_WCHAR_H): Skip followup test if header is
102855         missing.
102856         Suggested by Bruno Haible.
102858 2010-01-01  Jim Meyering  <meyering@redhat.com>
102860         ChangeLog: tweak to eliminate unnecessary copyright line
102861         * ChangeLog: Remove a copyright line that was mistakenly updated
102862         by today's update-copyright run.  Reported by Eric Blake.
102864         test-update-copyright: don't let envvar setting cause test failure
102865         * tests/test-update-copyright.sh: Set UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
102867 2010-01-01  Bruno Haible  <bruno@clisp.org>
102869         localename: Avoid gcc warning.
102870         * lib/localename.c (gl_locale_name_thread_unsafe): Don't define this
102871         function if it is not used.
102873 2010-01-01  Jim Meyering  <meyering@redhat.com>
102875         update nearly all FSF copyright year lists to include 2010
102876         Use the same procedure as for 2009, outlined in
102877         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/20081
102879         version-etc: set COPYRIGHT_YEAR to 2010
102880         * lib/version-etc.c (COPYRIGHT_YEAR): Manually update the enum.
102882 2009-12-31  Eric Blake  <ebb9@byu.net>
102884         doc: correct availability of cygwin 1.5.x getopt
102885         * doc/posix-functions/optarg.texi (optarg): Cygwin supplies getopt
102886         variables.
102887         * doc/posix-functions/opterr.texi (opterr): Likewise.
102888         * doc/posix-functions/optind.texi (optind): Likewise.
102889         * doc/posix-functions/optopt.texi (optopt): Likewise.
102890         * doc/posix-functions/tzname.texi (tzname): Likewise.
102892         openat: update maintainer
102893         * modules/openat (Maintainer): Add myself.
102895         utimens: avoid shadowing warning
102896         * lib/utimens.c (fdutimens, lutimens): Consolidate separate stat
102897         buffers into one, to avoid shadowing, as well as avoiding a
102898         redundant stat.
102899         Reported by Jim Meyering.
102901         test-dup2: avoid compiler warning
102902         * tests/test-dup2.c (is_inheritable): Only define if used.
102904 2010-01-01  Bruno Haible  <bruno@clisp.org>
102906         vasnprintf: Avoid passing an 'rpl_mbstate_t *' to the system's wcrtomb.
102907         * lib/vasnprintf.c (VASNPRINTF): If GNULIB_defined_mbstate_t is
102908         defined, use wctomb instead of wcrtomb.
102910 2010-01-01  Bruno Haible  <bruno@clisp.org>
102912         iconv: Reject native Solaris iconv.
102913         * m4/iconv.m4 (AM_ICONV_LINK): Recognize native Solaris iconv() bug.
102914         * doc/posix-functions/iconv.texi: Document native Solaris iconv() bug.
102916 2009-12-31  Bruno Haible  <bruno@clisp.org>
102918         * tests/test-signal.c (main): Remove test of 'SIG'.
102920 2009-12-31  Bruno Haible  <bruno@clisp.org>
102922         spawn: Fix incomplete fix.
102923         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
102924         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
102925         warnings for GNULIB_POSIXCHECK again.
102926         Reported by Eric Blake.
102928 2009-12-31  Bruno Haible  <bruno@clisp.org>
102930         Avoid namespace pollution on glibc systems.
102931         * lib/spawn.in.h: Don't include <sched.h>, <signal.h> on glibc systems.
102932         * lib/sys_times.in.h: Don't include <time.h> on glibc systems.
102933         * lib/wchar.in.h: Don't include <stddef.h>, <stdio.h>, <time.h> on
102934         glibc systems.
102936 2009-12-31  Bruno Haible  <bruno@clisp.org>
102938         * m4/wchar.m4 (gl_WCHAR_H): Remove gl_STDDEF_H invocation.
102939         (gl_REPLACE_WCHAR_H): Turn into a no-op.
102940         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Likewise.
102941         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H): Likewise.
102942         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H): Likewise.
102943         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H): Likewise.
102944         * m4/sys_ioctl_h.m4 (gl_REPLACE_SYS_IOCTL_H): Likewise.
102946 2009-12-31  Bruno Haible  <bruno@clisp.org>
102948         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Invoke
102949         gl_CHECK_NEXT_HEADERS before testing ac_cv_header_sys_select_h, not
102950         afterwards.
102952 2009-12-31  Bruno Haible  <bruno@clisp.org>
102954         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H_DEFAULTS): Don't set
102955         SYS_UTSNAME_H.
102957 2009-12-31  Bruno Haible  <bruno@clisp.org>
102959         spawn: Fix misapplied patch.
102960         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
102961         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
102962         warnings for GNULIB_POSIXCHECK.
102964 2009-12-31  Bruno Haible  <bruno@clisp.org>
102966         times: Update after sys_times changed.
102967         * m4/times.m4: New file, extracted from modules/times. Set HAVE_TIMES.
102968         * modules/times (Files): Add it.
102969         (configure.ac): Invoke gl_FUNC_TIMES.
102971 2009-12-31  Bruno Haible  <bruno@clisp.org>
102973         Use AC_C_INLINE where necessary.
102974         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Require AC_C_INLINE.
102975         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
102976         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
102977         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
102978         * m4/mbfile.m4 (gl_MBFILE): Likewise.
102979         * m4/mbiter.m4 (gl_MBITER): Likewise.
102980         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
102981         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
102982         * m4/wait-process.m4 (gl_WAIT_PROCESS): Likewise.
102983         * modules/u64 (configure.ac): Likewise.
102985 2009-12-31  Bruno Haible  <bruno@clisp.org>
102987         Use AC_C_INLINE instead of module 'inline' where possible.
102988         * modules/inline (Description): Clarify purpose.
102989         * m4/count-one-bits.m4 (gl_COUNT_ONE_BITS): Require AC_C_INLINE.
102990         * modules/count-one-bits (Depends-on): Remove inline.
102991         * m4/openat.m4 (gl_PREREQ_OPENAT): Require AC_C_INLINE.
102992         * modules/openat (Depends-on): Remove inline.
102993         * modules/fdutimensat (Depends-on, configure.ac): Require AC_C_INLINE
102994         instead of depending on module 'inline'.
102995         * modules/filevercmp (Depends-on, configure.ac): Likewise.
102996         * modules/unicase/cased (Depends-on, configure.ac): Likewise.
102997         * modules/unicase/ignorable (Depends-on, configure.ac): Likewise.
102998         * modules/unictype/category-of (Depends-on, configure.ac): Likewise.
102999         * modules/unictype/category-test (Depends-on, configure.ac): Likewise.
103000         * modules/unictype/ctype-alnum (Depends-on, configure.ac): Likewise.
103001         * modules/unictype/ctype-alpha (Depends-on, configure.ac): Likewise.
103002         * modules/unictype/ctype-blank (Depends-on, configure.ac): Likewise.
103003         * modules/unictype/ctype-cntrl (Depends-on, configure.ac): Likewise.
103004         * modules/unictype/ctype-digit (Depends-on, configure.ac): Likewise.
103005         * modules/unictype/ctype-graph (Depends-on, configure.ac): Likewise.
103006         * modules/unictype/ctype-lower (Depends-on, configure.ac): Likewise.
103007         * modules/unictype/ctype-print (Depends-on, configure.ac): Likewise.
103008         * modules/unictype/ctype-punct (Depends-on, configure.ac): Likewise.
103009         * modules/unictype/ctype-space (Depends-on, configure.ac): Likewise.
103010         * modules/unictype/ctype-upper (Depends-on, configure.ac): Likewise.
103011         * modules/unictype/ctype-xdigit (Depends-on, configure.ac): Likewise.
103012         * modules/unictype/property-alphabetic (Depends-on, configure.ac):
103013         Likewise.
103014         * modules/unictype/property-ascii-hex-digit (Depends-on,
103015         configure.ac): Likewise.
103016         * modules/unictype/property-bidi-arabic-digit (Depends-on,
103017         configure.ac): Likewise.
103018         * modules/unictype/property-bidi-arabic-right-to-left (Depends-on,
103019         configure.ac): Likewise.
103020         * modules/unictype/property-bidi-block-separator (Depends-on,
103021         configure.ac): Likewise.
103022         * modules/unictype/property-bidi-boundary-neutral (Depends-on,
103023         configure.ac): Likewise.
103024         * modules/unictype/property-bidi-common-separator (Depends-on,
103025         configure.ac): Likewise.
103026         * modules/unictype/property-bidi-control (Depends-on, configure.ac):
103027         Likewise.
103028         * modules/unictype/property-bidi-embedding-or-override (Depends-on,
103029         configure.ac): Likewise.
103030         * modules/unictype/property-bidi-eur-num-separator (Depends-on,
103031         configure.ac): Likewise.
103032         * modules/unictype/property-bidi-eur-num-terminator (Depends-on,
103033         configure.ac): Likewise.
103034         * modules/unictype/property-bidi-european-digit (Depends-on,
103035         configure.ac): Likewise.
103036         * modules/unictype/property-bidi-hebrew-right-to-left (Depends-on,
103037         configure.ac): Likewise.
103038         * modules/unictype/property-bidi-left-to-right (Depends-on,
103039         configure.ac): Likewise.
103040         * modules/unictype/property-bidi-non-spacing-mark (Depends-on,
103041         configure.ac): Likewise.
103042         * modules/unictype/property-bidi-other-neutral (Depends-on,
103043         configure.ac): Likewise.
103044         * modules/unictype/property-bidi-pdf (Depends-on, configure.ac):
103045         Likewise.
103046         * modules/unictype/property-bidi-segment-separator (Depends-on,
103047         configure.ac): Likewise.
103048         * modules/unictype/property-bidi-whitespace (Depends-on,
103049         configure.ac): Likewise.
103050         * modules/unictype/property-combining (Depends-on, configure.ac):
103051         Likewise.
103052         * modules/unictype/property-composite (Depends-on, configure.ac):
103053         Likewise.
103054         * modules/unictype/property-currency-symbol (Depends-on,
103055         configure.ac): Likewise.
103056         * modules/unictype/property-dash (Depends-on, configure.ac): Likewise.
103057         * modules/unictype/property-decimal-digit (Depends-on, configure.ac):
103058         Likewise.
103059         * modules/unictype/property-default-ignorable-code-point (Depends-on,
103060         configure.ac): Likewise.
103061         * modules/unictype/property-deprecated (Depends-on, configure.ac):
103062         Likewise.
103063         * modules/unictype/property-diacritic (Depends-on, configure.ac):
103064         Likewise.
103065         * modules/unictype/property-extender (Depends-on, configure.ac):
103066         Likewise.
103067         * modules/unictype/property-format-control (Depends-on, configure.ac):
103068         Likewise.
103069         * modules/unictype/property-grapheme-base (Depends-on, configure.ac):
103070         Likewise.
103071         * modules/unictype/property-grapheme-extend (Depends-on, configure.ac):
103072         Likewise.
103073         * modules/unictype/property-grapheme-link (Depends-on, configure.ac):
103074         Likewise.
103075         * modules/unictype/property-hex-digit (Depends-on, configure.ac):
103076         Likewise.
103077         * modules/unictype/property-hyphen (Depends-on, configure.ac):
103078         Likewise.
103079         * modules/unictype/property-id-continue (Depends-on, configure.ac):
103080         Likewise.
103081         * modules/unictype/property-id-start (Depends-on, configure.ac):
103082         Likewise.
103083         * modules/unictype/property-ideographic (Depends-on, configure.ac):
103084         Likewise.
103085         * modules/unictype/property-ids-binary-operator (Depends-on,
103086         configure.ac): Likewise.
103087         * modules/unictype/property-ids-trinary-operator (Depends-on,
103088         configure.ac): Likewise.
103089         * modules/unictype/property-ignorable-control (Depends-on,
103090         configure.ac): Likewise.
103091         * modules/unictype/property-iso-control (Depends-on, configure.ac):
103092         Likewise.
103093         * modules/unictype/property-join-control (Depends-on, configure.ac):
103094         Likewise.
103095         * modules/unictype/property-left-of-pair (Depends-on, configure.ac):
103096         Likewise.
103097         * modules/unictype/property-line-separator (Depends-on, configure.ac):
103098         Likewise.
103099         * modules/unictype/property-logical-order-exception (Depends-on,
103100         configure.ac): Likewise.
103101         * modules/unictype/property-lowercase (Depends-on, configure.ac):
103102         Likewise.
103103         * modules/unictype/property-math (Depends-on, configure.ac): Likewise.
103104         * modules/unictype/property-non-break (Depends-on, configure.ac):
103105         Likewise.
103106         * modules/unictype/property-not-a-character (Depends-on, configure.ac):
103107         Likewise.
103108         * modules/unictype/property-numeric (Depends-on, configure.ac):
103109         Likewise.
103110         * modules/unictype/property-other-alphabetic (Depends-on,
103111         configure.ac): Likewise.
103112         * modules/unictype/property-other-default-ignorable-code-point
103113         (Depends-on, configure.ac): Likewise.
103114         * modules/unictype/property-other-grapheme-extend (Depends-on,
103115         configure.ac): Likewise.
103116         * modules/unictype/property-other-id-continue (Depends-on,
103117         configure.ac): Likewise.
103118         * modules/unictype/property-other-id-start (Depends-on, configure.ac):
103119         Likewise.
103120         * modules/unictype/property-other-lowercase (Depends-on, configure.ac):
103121         Likewise.
103122         * modules/unictype/property-other-math (Depends-on, configure.ac):
103123         Likewise.
103124         * modules/unictype/property-other-uppercase (Depends-on, configure.ac):
103125         Likewise.
103126         * modules/unictype/property-paired-punctuation (Depends-on,
103127         configure.ac): Likewise.
103128         * modules/unictype/property-paragraph-separator (Depends-on,
103129         configure.ac): Likewise.
103130         * modules/unictype/property-pattern-syntax (Depends-on, configure.ac):
103131         Likewise.
103132         * modules/unictype/property-pattern-white-space (Depends-on,
103133         configure.ac): Likewise.
103134         * modules/unictype/property-private-use (Depends-on, configure.ac):
103135         Likewise.
103136         * modules/unictype/property-punctuation (Depends-on, configure.ac):
103137         Likewise.
103138         * modules/unictype/property-quotation-mark (Depends-on, configure.ac):
103139         Likewise.
103140         * modules/unictype/property-radical (Depends-on, configure.ac):
103141         Likewise.
103142         * modules/unictype/property-sentence-terminal (Depends-on,
103143         configure.ac): Likewise.
103144         * modules/unictype/property-soft-dotted (Depends-on, configure.ac):
103145         Likewise.
103146         * modules/unictype/property-space (Depends-on, configure.ac): Likewise.
103147         * modules/unictype/property-terminal-punctuation (Depends-on,
103148         configure.ac): Likewise.
103149         * modules/unictype/property-titlecase (Depends-on, configure.ac):
103150         Likewise.
103151         * modules/unictype/property-unassigned-code-value (Depends-on,
103152         configure.ac): Likewise.
103153         * modules/unictype/property-unified-ideograph (Depends-on,
103154         configure.ac): Likewise.
103155         * modules/unictype/property-uppercase (Depends-on, configure.ac):
103156         Likewise.
103157         * modules/unictype/property-variation-selector (Depends-on,
103158         configure.ac): Likewise.
103159         * modules/unictype/property-white-space (Depends-on, configure.ac):
103160         Likewise.
103161         * modules/unictype/property-xid-continue (Depends-on, configure.ac):
103162         Likewise.
103163         * modules/unictype/property-xid-start (Depends-on, configure.ac):
103164         Likewise.
103165         * modules/unictype/property-zero-width (Depends-on, configure.ac):
103166         Likewise.
103167         * modules/unictype/syntax-c-ident (Depends-on, configure.ac): Likewise.
103168         * modules/unictype/syntax-java-ident (Depends-on, configure.ac):
103169         Likewise.
103171 2009-12-31  Bruno Haible  <bruno@clisp.org>
103173         Remove unnecessary AC_C_INLINE invocation.
103174         * m4/popen.m4 (gl_PREREQ_POPEN): Don't invoke AC_C_INLINE. Not needed
103175         since 2009-08-21.
103177 2009-12-31  Jim Meyering  <meyering@redhat.com>
103179         maint.mk: don't require explicit gpg_key_ID in cfg.mk
103180         * top/maint.mk (gpg_key_ID): Derive key ID from signed release tag.
103181         With this change, we can all remove the gpg_key_ID = ... definition
103182         from our respective cfg.mk files.
103184         maint.mk: create announcement template in ~/, not in /tmp
103185         * top/maint.mk (emit_upload_commands): Adjust.
103186         (release-prep): Emit into ~/announce-..., not /tmp/announce-...
103187         Remove temporary file, .ci-msg.
103189 2009-12-31  Eric Blake  <ebb9@byu.net>
103191         link-warning: always build headers with link warnings
103192         * modules/arpa_inet (Makefile.am): Always build replacement
103193         header.
103194         * modules/ctype (Makefile.am): Likewise.
103195         * modules/dirent (Makefile.am): Likewise.
103196         * modules/inttypes (Makefile.am): Likewise.
103197         * modules/langinfo (Makefile.am): Likewise.
103198         * modules/locale (Makefile.am): Likewise.
103199         * modules/spawn (Makefile.am): Likewise.
103200         * modules/sys_file (Makefile.am): Likewise.
103201         * modules/sys_ioctl (Makefile.am): Likewise.
103202         * modules/sys_select (Makefile.am): Likewise.
103203         * modules/sys_socket (Makefile.am): Likewise.
103204         * modules/sys_times (Makefile.am): Likewise.
103205         * modules/sys_utsname (Makefile.am): Likewise.
103206         * modules/sys_wait (Makefile.am): Likewise.
103207         * modules/wchar (Makefile.am): Likewise.
103208         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET)
103209         (gl_ARPA_INET_H_DEFAULTS): Drop unneeded variable.
103210         * m4/ctype.m4 (gl_CTYPE_H_DEFAULTS): Likewise.
103211         * m4/isblank.m4 (gl_FUNC_ISBLANK): Likewise.
103212         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H, gl_DIRENT_H_DEFAULTS):
103213         Likewise.
103214         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
103215         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
103216         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_H_DEFAULTS):
103217         Likewise.
103218         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H, gl_SPAWN_H_DEFAULTS):
103219         Likewise.
103220         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Likewise.
103221         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H, gl_REPLACE_SYS_IOCTL_H)
103222         (gl_SYS_IOCTL_H_DEFAULTS): Likewise.
103223         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
103224         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
103225         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
103226         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
103227         * m4/wchar.m4 (gl_WCHAR_H, gl_REPLACE_WCHAR_H)
103228         (gl_WCHAR_H_DEFAULTS): Likewise.
103230 2009-12-31  Eric Blake  <ebb9@byu.net>
103232         signal, spawn: use link warnings
103233         * lib/signal.in.h (sigset_t): Make unconditional.
103234         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset)
103235         (sigpending, sigprocmask, sigaction): Add link warnings.
103236         * lib/spawn.in.h (posix_spawn, posix_spawnp, posix_spawnattr_init)
103237         (posix_spawnattr_destroy, posix_spawnattr_getsigdefault)
103238         (posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask)
103239         (posix_spawnattr_setsigmask, posix_spawnattr_getflags)
103240         (posix_spawnattr_setflags, posix_spawnattr_getpgroup)
103241         (posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy)
103242         (posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam)
103243         (posix_spawnattr_setschedparam, posix_spawn_file_actions_init)
103244         (posix_spawn_file_actions_destroy)
103245         (posix_spawn_file_actions_addopen)
103246         (posix_spawn_file_actions_addclose)
103247         (posix_spawn_file_actions_adddup2): Likewise.
103248         * m4/signal_h.m4 (gl_SIGNAL_H): Guarantee uid_t.
103249         * tests/test-signal.c (main): Enhance test.
103251         spawn: improve wrapper support
103252         * m4/spawn_h.m4 (gl_SPAWN_H): Check for type existence.
103253         (gl_SPAWN_H_DEFAULTS): New defaults.
103254         * modules/spawn (Makefile.am): Substitute them.
103255         * lib/spawn.in.h: (posix_spawnattr_t, posix_spawn_file_actions_t):
103256         Only declare if missing or broken.
103258         sys_times, sys_utsname: use include_next
103259         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Support wrapping an existing
103260         header.
103261         (gl_SYS_TIMES_H_DEFAULTS): Add another variable.
103262         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
103263         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
103264         * modules/sys_times (Depends-on): Add include_next.
103265         (Makefile.am): Substitute additional values.
103266         * modules/sys_utsname (Depends-on, Makefile.am): Likewise.
103267         * lib/sys_times.in.h (includes): Include native header, if
103268         available.
103269         * lib/sys_utsname.in.h (includes): Likewise.
103270         * tests/test-sys_times.c (main): Enhance test.
103272         fdutimensat: revert prior patch
103273         * modules/fdutimensat (Depends-on): Re-add inline; it is needed by
103274         utimens.h.
103275         Reported by Bruno Haible.
103277 2009-12-30  Eric Blake  <ebb9@byu.net>
103279         sys_wait: drop link-warning dependency
103280         * modules/sys_wait (Depends-on, Makefile.am): Drop unneeded
103281         link-warning efforts.
103282         * lib/sys_wait.in.h: Likewise.
103284         fdutimensat: remove bogus dependency
103285         * modules/fdutimensat (Depends-on): Drop inline.
103287         unistd: fix typo
103288         * lib/unistd.in.h (linkat) [GNULIB_POSIXCHECK]: Fix typo.
103290 2009-12-30  Bruno Haible  <bruno@clisp.org>
103292         Fix compilation error with Solaris cc.
103293         * lib/unicase/u8-is-invariant.c: Include <stdbool.h>.
103294         * lib/unicase/u16-is-invariant.c: Likewise.
103295         * lib/unicase/u32-is-invariant.c: Likewise.
103296         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
103298 2009-12-30  Bruno Haible  <bruno@clisp.org>
103300         Fix test crash.
103301         * tests/test-localename.c (test_locale_name_thread): Skip unavailable
103302         locales.
103303         Reported by Simon Josefsson <simon@josefsson.org>.
103305 2009-12-30  Bruno Haible  <bruno@clisp.org>
103307         Fix compilation error on most platforms.
103308         * tests/test-localename.c (categories): Define only if HAVE_NEWLOCALE.
103309         Reported by Simon Josefsson <simon@josefsson.org>
103310         and Nelson H. F. Beebe <beebe@math.utah.edu>.
103312 2009-12-30  Eric Blake  <ebb9@byu.net>
103314         futimens, utimensat: work around ntfs-3g bug
103315         * lib/utimensat.c (rpl_utimensat): Drop attempts to cache whether
103316         a ctime bug is present, and expand workaround to cover ntfs-3g.
103317         * lib/utimens.c (fdutimens, lutimens): Likewise.
103318         (utimensat_ctime_really, detect_ctime_bug): Drop cache mechanism.
103319         (validate_timespec): Adjust return value.
103320         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Update comment.
103321         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
103322         Reported by ctrn3e8 <ctrn3e8@gmail.com>.
103324 2009-12-29  Eric Blake  <ebb9@byu.net>
103326         link-warning: make usage consistent
103327         * modules/ctype (Depends-on): Add link-warning.
103328         (Makefile.am): Update rules accordingly.
103329         * modules/langinfo (Depends-on, Makefile.am): Likewise.
103330         * modules/locale (Depends-on, Makefile.am): Likewise.
103331         * modules/sys_file (Makefile.am): Likewise.
103332         * modules/getopt-posix (Makefile.am): Delete unused link warning
103333         efforts.
103334         * lib/ctype.in.h (GL_LINK_WARNING): Ensure definition before use.
103335         * lib/langinfo.in.h (GL_LINK_WARNING): Likewise.
103336         * lib/locale.in.h (GL_LINK_WARNING): Likewise.
103337         * lib/sys_file.in.h (GL_LINK_WARNING): Likewise.
103339         stdio: remove unused variables
103340         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Remove unused variables.
103341         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Likewise.
103342         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
103344         tests: test more substitute headers
103345         * modules/ctype-tests: New file.
103346         * modules/dirent-tests: Likewise.
103347         * modules/spawn-tests: Likewise.
103348         * modules/sys_file-tests: Likewise.
103349         * modules/sys_ioctl-tests: Likewise.
103350         * modules/sys_wait-tests: Likewise.
103351         * tests/test-ctype.c: Likewise.
103352         * tests/test-dirent.c: Likewise.
103353         * tests/test-spawn.c: Likewise.
103354         * tests/test-sys_file.c: Likewise.
103355         * tests/test-sys_ioctl.c: Likewise.
103356         * tests/test-sys_wait.c: Likewise.
103357         * m4/spawn_h.m4 (gl_SPAWN_H): Replace header if it is missing.
103358         * lib/sys_file.in.h (LOCK_SH, LOCK_EX, LOCK_UN, LOCK_NB): Provide
103359         whether or not flock is in use.
103361         tests: remove License section from module
103362         * modules/arpa_inet-tests: Remove unneeded section.
103363         * modules/byteswap-tests: Likewise.
103364         * modules/ceilf-tests: Likewise.
103365         * modules/ceill-tests: Likewise.
103366         * modules/crypto/des-tests: Likewise.
103367         * modules/crypto/gc-arcfour-tests: Likewise.
103368         * modules/crypto/gc-arctwo-tests: Likewise.
103369         * modules/crypto/gc-des-tests: Likewise.
103370         * modules/crypto/gc-hmac-md5-tests: Likewise.
103371         * modules/crypto/gc-hmac-sha1-tests: Likewise.
103372         * modules/crypto/gc-md2-tests: Likewise.
103373         * modules/crypto/gc-md4-tests: Likewise.
103374         * modules/crypto/gc-md5-tests: Likewise.
103375         * modules/crypto/gc-pbkdf2-sha1-tests: Likewise.
103376         * modules/crypto/gc-rijndael-tests: Likewise.
103377         * modules/crypto/gc-sha1-tests: Likewise.
103378         * modules/crypto/gc-tests: Likewise.
103379         * modules/crypto/md2-tests: Likewise.
103380         * modules/crypto/md4-tests: Likewise.
103381         * modules/fcntl-h-tests: Likewise.
103382         * modules/floorf-tests: Likewise.
103383         * modules/floorl-tests: Likewise.
103384         * modules/frexp-nolibm-tests: Likewise.
103385         * modules/frexp-tests: Likewise.
103386         * modules/frexpl-nolibm-tests: Likewise.
103387         * modules/frexpl-tests: Likewise.
103388         * modules/getaddrinfo-tests: Likewise.
103389         * modules/inttypes-tests: Likewise.
103390         * modules/isfinite-tests: Likewise.
103391         * modules/isinf-tests: Likewise.
103392         * modules/ldexpl-tests: Likewise.
103393         * modules/locale-tests: Likewise.
103394         * modules/math-tests: Likewise.
103395         * modules/netdb-tests: Likewise.
103396         * modules/netinet_in-tests: Likewise.
103397         * modules/printf-frexp-tests: Likewise.
103398         * modules/printf-frexpl-tests: Likewise.
103399         * modules/priv-set-tests: Likewise.
103400         * modules/random_r-tests: Likewise.
103401         * modules/round-tests: Likewise.
103402         * modules/roundf-tests: Likewise.
103403         * modules/roundl-tests: Likewise.
103404         * modules/search-tests: Likewise.
103405         * modules/select-tests: Likewise.
103406         * modules/signal-tests: Likewise.
103407         * modules/stdbool-tests: Likewise.
103408         * modules/stddef-tests: Likewise.
103409         * modules/stdint-tests: Likewise.
103410         * modules/stdio-tests: Likewise.
103411         * modules/stdlib-tests: Likewise.
103412         * modules/string-tests: Likewise.
103413         * modules/strings-tests: Likewise.
103414         * modules/sys_select-tests: Likewise.
103415         * modules/sys_socket-tests: Likewise.
103416         * modules/sys_stat-tests: Likewise.
103417         * modules/sys_time-tests: Likewise.
103418         * modules/sys_utsname-tests: Likewise.
103419         * modules/sysexits-tests: Likewise.
103420         * modules/time-tests: Likewise.
103421         * modules/trunc-tests: Likewise.
103422         * modules/truncf-tests: Likewise.
103423         * modules/truncl-tests: Likewise.
103424         * modules/tsearch-tests: Likewise.
103425         * modules/unistd-tests: Likewise.
103426         * modules/wchar-tests: Likewise.
103427         * modules/wctype-tests: Likewise.
103429         tests: fix license on several tests
103430         * tests/test-des.c: Update to GPLv3+.
103431         * tests/test-flock.c: Likewise.
103432         * tests/test-fsync.c: Likewise.
103433         * tests/test-futimens.h: Likewise.
103434         * tests/test-gc-arcfour.c: Likewise.
103435         * tests/test-gc-arctwo.c: Likewise.
103436         * tests/test-gc-des.c: Likewise.
103437         * tests/test-gc-hmac-md5.c: Likewise.
103438         * tests/test-gc-hmac-sha1.c: Likewise.
103439         * tests/test-gc-md2.c: Likewise.
103440         * tests/test-gc-md4.c: Likewise.
103441         * tests/test-gc-md5.c: Likewise.
103442         * tests/test-gc-pbkdf2-sha1.c: Likewise.
103443         * tests/test-gc-rijndael.c: Likewise.
103444         * tests/test-gc-sha1.c: Likewise.
103445         * tests/test-gc.c: Likewise.
103446         * tests/test-getcwd.c: Likewise.
103447         * tests/test-link.c: Likewise.
103448         * tests/test-link.h: Likewise.
103449         * tests/test-lutimens.h: Likewise.
103450         * tests/test-md2.c: Likewise.
103451         * tests/test-md4.c: Likewise.
103452         * tests/test-mkdir.h: Likewise.
103453         * tests/test-rename.c: Likewise.
103454         * tests/test-rename.h: Likewise.
103455         * tests/test-safe-alloc.c: Likewise.
103456         * tests/test-utimens-common.h: Likewise.
103457         * tests/test-utimens.h: Likewise.
103459         maint: sync license texts
103460         * config/srclist.txt: Add gpl-1.3.texi, lgpl-1.3.texi.
103461         * doc/gpl-3.0.texi: Revert copyright year update.
103462         * doc/lgpl-3.0.texi: Likewise.
103464 2009-12-29  Jim Meyering  <meyering@redhat.com>
103466         update nearly all FSF copyright year lists to include 2009
103467         The files named by the following are exempted:
103468             grep -v '^#' config/srclist.txt|grep -v '^$' | while read src dst; do
103469               test -f "$dst" && { echo "$dst"; continue; }
103470               test -d "$dst" || continue
103471               echo "$dst"/$(basename "$src")
103472             done > exempt
103473             git ls-files tests/unictype >> exempt
103474         In the remaining files, convert to all-interval notation if
103475         - there is already at least one year interval like 2000-2003
103476         - the file is maintained by me
103477         - the file is in lib/uni*/, where that style already prevails
103478         Otherwise, use update-copyright's default.
103480 2009-12-29  Simon Josefsson  <simon@josefsson.org>
103481         and Eric Blake  <ebb9@byu.net>
103483         tests: don't require debug system() to pass
103484         * tests/test-lstat.h (test_lstat_func): Move debug cleanup...
103485         * tests/test-rmdir.h (test_rmdir_func): Likewise.
103486         * tests/test-unlink.h (test_unlink_func): Likewise.
103487         * tests/test-fstatat.c (main): ...into callers.
103488         * tests/test-lstat.c (main): Likewise.
103489         * tests/test-rmdir.c (main): Likewise.
103490         * tests/test-unlink.c (main): Likewise.
103491         * tests/test-unlinkat.c (main): Likewise.
103492         * tests/test-areadlink-with-size.c (main): Don't require a
103493         debug-only system call to pass, aiding cross-testing to mingw.
103494         * tests/test-areadlink.c (main): Likewise.
103495         * tests/test-areadlinkat-with-size.c (main): Likewise.
103496         * tests/test-areadlinkat.c (main): Likewise.
103497         * tests/test-canonicalize-lgpl.c (main): Likewise.
103498         * tests/test-canonicalize.c (main): Likewise.
103499         * tests/test-chown.c (main): Likewise.
103500         * tests/test-fchownat.c (main): Likewise.
103501         * tests/test-lchown.c (main): Likewise.
103502         * tests/test-fdutimensat.c (main): Likewise.
103503         * tests/test-futimens.c (main): Likewise.
103504         * tests/test-link.c (main): Likewise.
103505         * tests/test-linkat.c (main): Likewise.
103506         * tests/test-mkdir.c (main): Likewise.
103507         * tests/test-mkdirat.c (main): Likewise.
103508         * tests/test-mkfifo.c (main): Likewise.
103509         * tests/test-mkfifoat.c (main): Likewise.
103510         * tests/test-mknod.c (main): Likewise.
103511         * tests/test-readlink.c (main): Likewise.
103512         * tests/test-remove.c (main): Likewise.
103513         * tests/test-rename.c (main): Likewise.
103514         * tests/test-renameat.c (main): Likewise.
103515         * tests/test-symlink.c (main): Likewise.
103516         * tests/test-symlinkat.c (main): Likewise.
103517         * tests/test-utimens.c (main): Likewise.
103518         * tests/test-utimensat.c (main): Likewise.
103520 2009-12-29  Simon Josefsson  <simon@josefsson.org>
103522         * modules/selinux-h (selinux/selinux.h, selinux/context.h): Depend
103523         on $(UNUSED_PARAMETER_H) to avoid build failure.
103525 2009-12-28  Jim Meyering  <meyering@redhat.com>
103527         update-copyright: you may specify a max. line length other than 72
103528         * build-aux/update-copyright: Honor $UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
103530         maint: use consistent FSF copyright line syntax
103531         * lib/posixtm.c: Add missing comma in FSF copyright line.
103532         * lib/posixtm.h: Likewise.
103533         * lib/getugroups.c: Add missing ", Inc.".
103535         pmccabe2html: emit consistent FSF copyright; remove trailing blanks
103536         * build-aux/pmccabe2html: Insert comma before "Inc." in emitted
103537         FSF copyright line.  Remove trailing blanks.
103539 2009-12-28  Eric Blake  <ebb9@byu.net>
103541         test-dup2: reduce dependencies
103542         * modules/cloexec (Configure.ac): Set witness.
103543         * modules/dup2-tests (Depends-on): Drop cloexec.
103544         * tests/test-dup2.c (main): Skip portion of test if cloexec module
103545         not present.
103546         Suggested by Bruno Haible.
103548 2009-12-26  Bruno Haible  <bruno@clisp.org>
103550         Remove an unneeded dependency.
103551         * modules/fseterr (Depends-on): Remove dup2.
103553 2009-12-26  Eric Blake  <ebb9@byu.net>
103555         tests: use macros.h in more places
103556         * tests/macros.h (ASSERT): Depend on ASSERT_STREAM.
103557         (ASSERT_STREAM): Provide default of stderr.
103558         * tests/test-dirent-safer.c: Include macros.h, using alternate
103559         stream for assertions.
103560         * tests/test-dup-safer.c: Likewise.
103561         * tests/test-freopen-safer.c: Likewise.
103562         * tests/test-getopt.c: Likewise.
103563         * tests/test-openat-safer.c: Likewise.
103564         * tests/test-pipe.c: Likewise.
103565         * tests/test-popen-safer.c: Likewise.
103566         * modules/dirent-safer-tests (Files): Include macros.h.
103567         * modules/unistd-safer-tests (Files): Likewise.
103568         * modules/freopen-safer-tests (Files): Likewise.
103569         * modules/getopt-posix-tests (Files): Likewise.
103570         * modules/openat-safer-tests (Files): Likewise.
103571         * modules/pipe-tests (Files): Likewise.
103573 2009-12-26  Bruno Haible  <bruno@clisp.org>
103575         javacomp-script: Portability fix.
103576         * m4/javacomp.m4 (gt_JAVACOMP): Fix creation of conftestver.class so
103577         that it also works on Solaris.
103579 2009-12-26  Bruno Haible  <bruno@clisp.org>
103581         localename: Fix storage allocation of gl_locale_name_thread's result.
103582         * lib/localename.c (SIZE_BITS, string_hash, struct hash_node,
103583         HASH_TABLE_SIZE, struniq_hash_table, struniq_lock, struniq): Define on
103584         all platforms that have 'uselocale'.
103585         (gl_locale_name_thread_unsafe): New function, extracted from
103586         gl_locale_name_thread.
103587         (gl_locale_name_thread): Call struniq on all platforms that have
103588         'uselocale'.
103589         * tests/test-localename.c (test_locale_name_thread): Check that the
103590         resulting strings are permanently allocated.
103591         * modules/localename-tests (Depends-on): Add strdup.
103593 2009-12-26  Bruno Haible  <bruno@clisp.org>
103595         * tests/test-localename.c (categories): Fill in the strings.
103597 2009-12-26  Jim Meyering  <meyering@redhat.com>
103599         isdir: complete the removal of m4/isdir.m4
103600         * modules/isdir (configure.ac): Remove reference to gl_ISDIR.
103602         isdir: clean up, since at least grep still uses it
103603         * lib/isdir.c: Include "isdir.h".
103604         (S_ISDIR): Remove now-unneeded definition.
103605         * modules/isdir (Files): Add lib/isdir.h.
103606         * lib/isdir.h: New file, with declaration.
103607         * m4/isdir.m4: Remove file -- unneeded.
103609 2009-12-25  Bruno Haible  <bruno@clisp.org>
103611         selinux-h: Make generated .h files standalone.
103612         * lib/se-context.in.h: Arrange to include _GL_UNUSED_PARAMETER
103613         definition. Use _GL_UNUSED_PARAMETER instead of _GL_UNUSED.
103614         * lib/se-selinux.in.h: Likewise.
103615         * modules/selinux-h (Depends-on): Add unused-parameter.
103616         (Makefile.am): Insert definition of _GL_UNUSED_PARAMETER into
103617         selinux/selinux.h and selinux/context.h.
103618         Suggested by Eric Blake.
103620 2009-12-25  Bruno Haible  <bruno@clisp.org>
103622         Move gl_FCNTL_O_FLAGS to a separate .m4 file.
103623         * m4/fcntl-o.m4: New file, extracted from m4/fcntl_h.m4.
103624         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): Remove macro.
103625         * modules/fcntl-h (Files): Add m4/fcntl-o.m4.
103626         * modules/localcharset (Files): Likewise. Remove m4/fcntl_h.m4.
103628 2009-12-24  Bruno Haible  <bruno@clisp.org>
103630         openat: Fix warning.
103631         * lib/openat-proc.c: Include <unistd.h>.
103633 2009-12-24  Bruno Haible  <bruno@clisp.org>
103635         New module 'unused-parameter'.
103636         * build-aux/unused-parameter.h: New file, extracted from earlier
103637         gnulib-common.m4.
103638         * modules/unused-parameter: New file.
103639         * lib/unistr.h: Include unused-parameter.h.
103640         (u32_mbtouc_unsafe, u32_mbtouc): Use _GL_UNUSED_PARAMETER instead of
103641         _GL_UNUSED.
103642         * modules/unistr/base (Depends-on): Add unused-parameter.
103644 2009-12-24  Bruno Haible  <bruno@clisp.org>
103646         Add missing dependencies to 'extensions' module.
103647         * m4/extensions.m4: Add comment.
103648         * modules/accept4 (Depends-on): Add extensions.
103649         * modules/dup3 (Depends-on): Likewise.
103650         * modules/fcntl (Depends-on): Likewise.
103651         * modules/futimens (Depends-on): Likewise.
103652         * modules/mknod (Depends-on): Likewise.
103653         * modules/pipe2 (Depends-on): Likewise.
103654         * modules/stat-time (Depends-on): Likewise.
103655         * modules/strcasestr-simple (Depends-on): Likewise.
103656         * modules/strsignal (Depends-on): Likewise.
103657         * modules/utimensat (Depends-on): Likewise.
103658         * modules/localcharset (Depends-on): Likewise. Needed because of
103659         gl_FCNTL_O_FLAGS.
103660         * modules/wcrtomb (Depends-on): Likewise. Needed because of
103661         AC_TYPE_MBSTATE_T.
103662         * modules/wcsnrtombs (Depends-on): Likewise.
103663         * modules/wcsrtombs (Depends-on): Likewise.
103665 2009-12-24  Bruno Haible  <bruno@clisp.org>
103667         binary-io: Avoid gcc warning due to SET_BINARY.
103668         * lib/binary-io.h (SET_BINARY): Cast the result to void.
103669         Reported by Jim Meyering <jim@meyering.net>. Suggestion by Eric Blake.
103671 2009-12-24  Bruno Haible  <bruno@clisp.org>
103673         Avoid future namespace pollution on glibc systems.
103674         * lib/arpa_inet.in.h: Don't include <sys/socket.h> on glibc systems.
103675         * lib/sys_ioctl.in.h: Don't include <unistd.h> on glibc systems.
103676         * lib/sys_select.in.h: Don't include <sys/time.h> and <string.h> on
103677         glibc systems.
103679 2009-12-24  Bruno Haible  <bruno@clisp.org>
103681         Refactor common macros used in tests.
103682         * tests/macros.h: New file.
103683         * tests/test-areadlink.c: Include macros.h. Don't include <stdio.h>
103684         and/or <stdlib.h>, if appropriate.
103685         (ASSERT, SIZEOF): Remove macros.
103686         * tests/test-areadlink-with-size.c: Likewise.
103687         * tests/test-areadlinkat.c: Likewise.
103688         * tests/test-areadlinkat-with-size.c: Likewise.
103689         * tests/test-argmatch.c: Likewise.
103690         * tests/test-argv-iter.c: Likewise.
103691         * tests/test-array-mergesort.c: Likewise.
103692         * tests/test-array_list.c: Likewise.
103693         * tests/test-array_oset.c: Likewise.
103694         * tests/test-avltree_list.c: Likewise.
103695         * tests/test-avltree_oset.c: Likewise.
103696         * tests/test-avltreehash_list.c: Likewise.
103697         * tests/test-base64.c: Likewise.
103698         * tests/test-binary-io.c: Likewise.
103699         * tests/test-bitrotate.c: Likewise.
103700         * tests/test-btowc.c: Likewise.
103701         * tests/test-byteswap.c: Likewise.
103702         * tests/test-c-ctype.c: Likewise.
103703         * tests/test-c-stack.c: Likewise.
103704         * tests/test-c-strcasecmp.c: Likewise.
103705         * tests/test-c-strcasestr.c: Likewise.
103706         * tests/test-c-strncasecmp.c: Likewise.
103707         * tests/test-c-strstr.c: Likewise.
103708         * tests/test-canonicalize-lgpl.c: Likewise.
103709         * tests/test-canonicalize.c: Likewise.
103710         * tests/test-carray_list.c: Likewise.
103711         * tests/test-ceilf1.c: Likewise.
103712         * tests/test-ceilf2.c: Likewise.
103713         * tests/test-ceill.c: Likewise.
103714         * tests/test-chown.c: Likewise.
103715         * tests/test-cloexec.c: Likewise.
103716         * tests/test-copy-acl.c: Likewise.
103717         * tests/test-copy-file.c: Likewise.
103718         * tests/test-count-one-bits.c: Likewise.
103719         * tests/test-dprintf-posix.c: Likewise.
103720         * tests/test-dup2.c: Likewise.
103721         * tests/test-dup3.c: Likewise.
103722         * tests/test-duplocale.c: Likewise.
103723         * tests/test-fbufmode.c: Likewise.
103724         * tests/test-fchdir.c: Likewise.
103725         * tests/test-fchownat.c: Likewise.
103726         * tests/test-fcntl-safer.c: Likewise.
103727         * tests/test-fcntl.c: Likewise.
103728         * tests/test-fdopendir.c: Likewise.
103729         * tests/test-fdutimensat.c: Likewise.
103730         * tests/test-fflush2.c: Likewise.
103731         * tests/test-file-has-acl.c: Likewise.
103732         * tests/test-filevercmp.c: Likewise.
103733         * tests/test-flock.c: Likewise.
103734         * tests/test-floorf1.c: Likewise.
103735         * tests/test-floorf2.c: Likewise.
103736         * tests/test-floorl.c: Likewise.
103737         * tests/test-fnmatch.c: Likewise.
103738         * tests/test-fopen.h: Likewise.
103739         * tests/test-fpending.c: Likewise.
103740         * tests/test-fprintf-posix.c: Likewise.
103741         * tests/test-fpurge.c: Likewise.
103742         * tests/test-freadable.c: Likewise.
103743         * tests/test-freadahead.c: Likewise.
103744         * tests/test-freading.c: Likewise.
103745         * tests/test-freadptr.c: Likewise.
103746         * tests/test-freadptr2.c: Likewise.
103747         * tests/test-freadseek.c: Likewise.
103748         * tests/test-freopen.c: Likewise.
103749         * tests/test-frexp.c: Likewise.
103750         * tests/test-frexpl.c: Likewise.
103751         * tests/test-fseek.c: Likewise.
103752         * tests/test-fseeko.c: Likewise.
103753         * tests/test-fstatat.c: Likewise.
103754         * tests/test-fstrcmp.c: Likewise.
103755         * tests/test-fsync.c: Likewise.
103756         * tests/test-ftell.c: Likewise.
103757         * tests/test-ftello.c: Likewise.
103758         * tests/test-func.c: Likewise.
103759         * tests/test-futimens.c: Likewise.
103760         * tests/test-fwritable.c: Likewise.
103761         * tests/test-fwriting.c: Likewise.
103762         * tests/test-getcwd.c: Likewise.
103763         * tests/test-getdate.c: Likewise.
103764         * tests/test-getdelim.c: Likewise.
103765         * tests/test-getdtablesize.c: Likewise.
103766         * tests/test-getgroups.c: Likewise.
103767         * tests/test-getline.c: Likewise.
103768         * tests/test-getndelim2.c: Likewise.
103769         * tests/test-glob.c: Likewise.
103770         * tests/test-hash.c: Likewise.
103771         * tests/test-i-ring.c: Likewise.
103772         * tests/test-iconv-utf.c: Likewise.
103773         * tests/test-iconv.c: Likewise.
103774         * tests/test-idpriv-drop.c: Likewise.
103775         * tests/test-idpriv-droptemp.c: Likewise.
103776         * tests/test-inet_ntop.c: Likewise.
103777         * tests/test-inet_pton.c: Likewise.
103778         * tests/test-isblank.c: Likewise.
103779         * tests/test-isfinite.c: Likewise.
103780         * tests/test-isinf.c: Likewise.
103781         * tests/test-isnan.c: Likewise.
103782         * tests/test-isnand.h: Likewise.
103783         * tests/test-isnanf.h: Likewise.
103784         * tests/test-isnanl.h: Likewise.
103785         * tests/test-lchown.c: Likewise.
103786         * tests/test-ldexpl.c: Likewise.
103787         * tests/test-link.c: Likewise.
103788         * tests/test-linkat.c: Likewise.
103789         * tests/test-linked_list.c: Likewise.
103790         * tests/test-linkedhash_list.c: Likewise.
103791         * tests/test-localename.c: Likewise.
103792         * tests/test-lseek.c: Likewise.
103793         * tests/test-lstat.c: Likewise.
103794         * tests/test-mbmemcasecmp.c: Likewise.
103795         * tests/test-mbmemcasecoll.c: Likewise.
103796         * tests/test-mbrtowc.c: Likewise.
103797         * tests/test-mbscasecmp.c: Likewise.
103798         * tests/test-mbscasestr1.c: Likewise.
103799         * tests/test-mbscasestr2.c: Likewise.
103800         * tests/test-mbscasestr3.c: Likewise.
103801         * tests/test-mbscasestr4.c: Likewise.
103802         * tests/test-mbschr.c: Likewise.
103803         * tests/test-mbscspn.c: Likewise.
103804         * tests/test-mbsinit.c: Likewise.
103805         * tests/test-mbsncasecmp.c: Likewise.
103806         * tests/test-mbsnrtowcs.c: Likewise.
103807         * tests/test-mbspbrk.c: Likewise.
103808         * tests/test-mbspcasecmp.c: Likewise.
103809         * tests/test-mbsrchr.c: Likewise.
103810         * tests/test-mbsrtowcs.c: Likewise.
103811         * tests/test-mbsspn.c: Likewise.
103812         * tests/test-mbsstr1.c: Likewise.
103813         * tests/test-mbsstr2.c: Likewise.
103814         * tests/test-mbsstr3.c: Likewise.
103815         * tests/test-memchr.c: Likewise.
103816         * tests/test-memchr2.c: Likewise.
103817         * tests/test-memcmp.c: Likewise.
103818         * tests/test-memmem.c: Likewise.
103819         * tests/test-memrchr.c: Likewise.
103820         * tests/test-mkdir.c: Likewise.
103821         * tests/test-mkdirat.c: Likewise.
103822         * tests/test-mkfifo.c: Likewise.
103823         * tests/test-mkfifoat.c: Likewise.
103824         * tests/test-mknod.c: Likewise.
103825         * tests/test-nanosleep.c: Likewise.
103826         * tests/test-nl_langinfo.c: Likewise.
103827         * tests/test-obstack-printf.c: Likewise.
103828         * tests/test-open.c: Likewise.
103829         * tests/test-openat.c: Likewise.
103830         * tests/test-pipe-filter-gi1.c: Likewise.
103831         * tests/test-pipe-filter-gi2-main.c: Likewise.
103832         * tests/test-pipe-filter-ii1.c: Likewise.
103833         * tests/test-pipe-filter-ii2-main.c: Likewise.
103834         * tests/test-pipe2.c: Likewise.
103835         * tests/test-popen.h: Likewise.
103836         * tests/test-posixtm.c: Likewise.
103837         * tests/test-pread.c: Likewise.
103838         * tests/test-printf-frexp.c: Likewise.
103839         * tests/test-printf-frexpl.c: Likewise.
103840         * tests/test-printf-posix.c: Likewise.
103841         * tests/test-priv-set.c: Likewise.
103842         * tests/test-quotearg.c: Likewise.
103843         * tests/test-random_r.c: Likewise.
103844         * tests/test-rawmemchr.c: Likewise.
103845         * tests/test-rbtree_list.c: Likewise.
103846         * tests/test-rbtree_oset.c: Likewise.
103847         * tests/test-rbtreehash_list.c: Likewise.
103848         * tests/test-readlink.c: Likewise.
103849         * tests/test-remove.c: Likewise.
103850         * tests/test-rename.c: Likewise.
103851         * tests/test-renameat.c: Likewise.
103852         * tests/test-rmdir.c: Likewise.
103853         * tests/test-round1.c: Likewise.
103854         * tests/test-roundf1.c: Likewise.
103855         * tests/test-roundl.c: Likewise.
103856         * tests/test-safe-alloc.c: Likewise.
103857         * tests/test-sameacls.c: Likewise.
103858         * tests/test-set-mode-acl.c: Likewise.
103859         * tests/test-setenv.c: Likewise.
103860         * tests/test-sigaction.c: Likewise.
103861         * tests/test-signbit.c: Likewise.
103862         * tests/test-sleep.c: Likewise.
103863         * tests/test-snprintf-posix.c: Likewise.
103864         * tests/test-snprintf.c: Likewise.
103865         * tests/test-sprintf-posix.c: Likewise.
103866         * tests/test-stat-time.c: Likewise.
103867         * tests/test-stat.c: Likewise.
103868         * tests/test-strcasestr.c: Likewise.
103869         * tests/test-strchrnul.c: Likewise.
103870         * tests/test-strerror.c: Likewise.
103871         * tests/test-striconv.c: Likewise.
103872         * tests/test-striconveh.c: Likewise.
103873         * tests/test-striconveha.c: Likewise.
103874         * tests/test-strsignal.c: Likewise.
103875         * tests/test-strstr.c: Likewise.
103876         * tests/test-strtod.c: Likewise.
103877         * tests/test-strverscmp.c: Likewise.
103878         * tests/test-symlink.c: Likewise.
103879         * tests/test-symlinkat.c: Likewise.
103880         * tests/test-trunc1.c: Likewise.
103881         * tests/test-trunc2.c: Likewise.
103882         * tests/test-truncf1.c: Likewise.
103883         * tests/test-truncf2.c: Likewise.
103884         * tests/test-truncl.c: Likewise.
103885         * tests/test-uname.c: Likewise.
103886         * tests/test-unlink.c: Likewise.
103887         * tests/test-unlinkat.c: Likewise.
103888         * tests/test-unsetenv.c: Likewise.
103889         * tests/test-usleep.c: Likewise.
103890         * tests/test-utimens.c: Likewise.
103891         * tests/test-utimensat.c: Likewise.
103892         * tests/test-vasnprintf-posix.c: Likewise.
103893         * tests/test-vasnprintf-posix2.c: Likewise.
103894         * tests/test-vasnprintf.c: Likewise.
103895         * tests/test-vasprintf-posix.c: Likewise.
103896         * tests/test-vasprintf.c: Likewise.
103897         * tests/test-vdprintf-posix.c: Likewise.
103898         * tests/test-vfprintf-posix.c: Likewise.
103899         * tests/test-vprintf-posix.c: Likewise.
103900         * tests/test-vsnprintf-posix.c: Likewise.
103901         * tests/test-vsnprintf.c: Likewise.
103902         * tests/test-vsprintf-posix.c: Likewise.
103903         * tests/test-wcrtomb.c: Likewise.
103904         * tests/test-wcsnrtombs.c: Likewise.
103905         * tests/test-wcsrtombs.c: Likewise.
103906         * tests/test-wctype.c: Likewise.
103907         * tests/test-wcwidth.c: Likewise.
103908         * tests/test-xfprintf-posix.c: Likewise.
103909         * tests/test-xmemdup0.c: Likewise.
103910         * tests/test-xprintf-posix.c: Likewise.
103911         * tests/test-xvasprintf.c: Likewise.
103912         * tests/unicase/test-locale-language.c: Likewise.
103913         * tests/unicase/test-mapping-part1.h: Likewise.
103914         * tests/unicase/test-predicate-part1.h: Likewise.
103915         * tests/unicase/test-u8-casecmp.c: Likewise.
103916         * tests/unicase/test-u8-casecoll.c: Likewise.
103917         * tests/unicase/test-u8-casefold.c: Likewise.
103918         * tests/unicase/test-u8-is-cased.c: Likewise.
103919         * tests/unicase/test-u8-is-casefolded.c: Likewise.
103920         * tests/unicase/test-u8-is-lowercase.c: Likewise.
103921         * tests/unicase/test-u8-is-titlecase.c: Likewise.
103922         * tests/unicase/test-u8-is-uppercase.c: Likewise.
103923         * tests/unicase/test-u8-tolower.c: Likewise.
103924         * tests/unicase/test-u8-totitle.c: Likewise.
103925         * tests/unicase/test-u8-toupper.c: Likewise.
103926         * tests/unicase/test-u16-casecmp.c: Likewise.
103927         * tests/unicase/test-u16-casecoll.c: Likewise.
103928         * tests/unicase/test-u16-casefold.c: Likewise.
103929         * tests/unicase/test-u16-is-cased.c: Likewise.
103930         * tests/unicase/test-u16-is-casefolded.c: Likewise.
103931         * tests/unicase/test-u16-is-lowercase.c: Likewise.
103932         * tests/unicase/test-u16-is-titlecase.c: Likewise.
103933         * tests/unicase/test-u16-is-uppercase.c: Likewise.
103934         * tests/unicase/test-u16-tolower.c: Likewise.
103935         * tests/unicase/test-u16-totitle.c: Likewise.
103936         * tests/unicase/test-u16-toupper.c: Likewise.
103937         * tests/unicase/test-u32-casecmp.c: Likewise.
103938         * tests/unicase/test-u32-casecoll.c: Likewise.
103939         * tests/unicase/test-u32-casefold.c: Likewise.
103940         * tests/unicase/test-u32-is-cased.c: Likewise.
103941         * tests/unicase/test-u32-is-casefolded.c: Likewise.
103942         * tests/unicase/test-u32-is-lowercase.c: Likewise.
103943         * tests/unicase/test-u32-is-titlecase.c: Likewise.
103944         * tests/unicase/test-u32-is-uppercase.c: Likewise.
103945         * tests/unicase/test-u32-tolower.c: Likewise.
103946         * tests/unicase/test-u32-totitle.c: Likewise.
103947         * tests/unicase/test-u32-toupper.c: Likewise.
103948         * tests/unicase/test-ulc-casecmp.c: Likewise.
103949         * tests/unicase/test-ulc-casecoll.c: Likewise.
103950         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
103951         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
103952         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
103953         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
103954         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
103955         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
103956         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
103957         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
103958         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
103959         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
103960         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
103961         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
103962         * tests/unictype/test-bidi_byname.c: Likewise.
103963         * tests/unictype/test-bidi_name.c: Likewise.
103964         * tests/unictype/test-bidi_of.c: Likewise.
103965         * tests/unictype/test-bidi_test.c: Likewise.
103966         * tests/unictype/test-block_list.c: Likewise.
103967         * tests/unictype/test-block_of.c: Likewise.
103968         * tests/unictype/test-block_test.c: Likewise.
103969         * tests/unictype/test-categ_and.c: Likewise.
103970         * tests/unictype/test-categ_and_not.c: Likewise.
103971         * tests/unictype/test-categ_byname.c: Likewise.
103972         * tests/unictype/test-categ_name.c: Likewise.
103973         * tests/unictype/test-categ_none.c: Likewise.
103974         * tests/unictype/test-categ_of.c: Likewise.
103975         * tests/unictype/test-categ_or.c: Likewise.
103976         * tests/unictype/test-categ_test_withtable.c: Likewise.
103977         * tests/unictype/test-combining.c: Likewise.
103978         * tests/unictype/test-decdigit.c: Likewise.
103979         * tests/unictype/test-digit.c: Likewise.
103980         * tests/unictype/test-mirror.c: Likewise.
103981         * tests/unictype/test-numeric.c: Likewise.
103982         * tests/unictype/test-pr_byname.c: Likewise.
103983         * tests/unictype/test-pr_test.c: Likewise.
103984         * tests/unictype/test-predicate-part1.h: Likewise.
103985         * tests/unictype/test-scripts.c: Likewise.
103986         * tests/unictype/test-sy_c_ident.c: Likewise.
103987         * tests/unictype/test-sy_java_ident.c: Likewise.
103988         * tests/unilbrk/test-u8-possible-linebreaks.c: Likewise.
103989         * tests/unilbrk/test-u8-width-linebreaks.c: Likewise.
103990         * tests/unilbrk/test-u16-possible-linebreaks.c: Likewise.
103991         * tests/unilbrk/test-u16-width-linebreaks.c: Likewise.
103992         * tests/unilbrk/test-u32-possible-linebreaks.c: Likewise.
103993         * tests/unilbrk/test-u32-width-linebreaks.c: Likewise.
103994         * tests/unilbrk/test-ulc-possible-linebreaks.c: Likewise.
103995         * tests/unilbrk/test-ulc-width-linebreaks.c: Likewise.
103996         * tests/uninorm/test-canonical-decomposition.c: Likewise.
103997         * tests/uninorm/test-compat-decomposition.c: Likewise.
103998         * tests/uninorm/test-composition.c: Likewise.
103999         * tests/uninorm/test-decomposing-form.c: Likewise.
104000         * tests/uninorm/test-decomposition.c: Likewise.
104001         * tests/uninorm/test-u8-nfc.c: Likewise.
104002         * tests/uninorm/test-u8-nfd.c: Likewise.
104003         * tests/uninorm/test-u8-nfkc.c: Likewise.
104004         * tests/uninorm/test-u8-nfkd.c: Likewise.
104005         * tests/uninorm/test-u8-normcmp.c: Likewise.
104006         * tests/uninorm/test-u8-normcoll.c: Likewise.
104007         * tests/uninorm/test-u16-nfc.c: Likewise.
104008         * tests/uninorm/test-u16-nfd.c: Likewise.
104009         * tests/uninorm/test-u16-nfkc.c: Likewise.
104010         * tests/uninorm/test-u16-nfkd.c: Likewise.
104011         * tests/uninorm/test-u16-normcmp.c: Likewise.
104012         * tests/uninorm/test-u16-normcoll.c: Likewise.
104013         * tests/uninorm/test-u32-nfc.c: Likewise.
104014         * tests/uninorm/test-u32-nfd.c: Likewise.
104015         * tests/uninorm/test-u32-nfkc.c: Likewise.
104016         * tests/uninorm/test-u32-nfkd.c: Likewise.
104017         * tests/uninorm/test-u32-normalize-big.c: Likewise.
104018         * tests/uninorm/test-u32-normcmp.c: Likewise.
104019         * tests/uninorm/test-u32-normcoll.c: Likewise.
104020         * tests/uninorm/test-uninorm-filter-nfc.c: Likewise.
104021         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
104022         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
104023         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
104024         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
104025         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
104026         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
104027         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
104028         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
104029         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
104030         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
104031         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
104032         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
104033         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
104034         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
104035         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
104036         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
104037         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
104038         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
104039         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
104040         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
104041         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
104042         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
104043         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
104044         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
104045         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
104046         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
104047         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
104048         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
104049         * tests/uniwbrk/test-u8-wordbreaks.c: Likewise.
104050         * tests/uniwbrk/test-u16-wordbreaks.c: Likewise.
104051         * tests/uniwbrk/test-u32-wordbreaks.c: Likewise.
104052         * tests/uniwbrk/test-ulc-wordbreaks.c: Likewise.
104053         * tests/uniwidth/test-u8-strwidth.c: Likewise.
104054         * tests/uniwidth/test-u8-width.c: Likewise.
104055         * tests/uniwidth/test-u16-strwidth.c: Likewise.
104056         * tests/uniwidth/test-u16-width.c: Likewise.
104057         * tests/uniwidth/test-u32-strwidth.c: Likewise.
104058         * tests/uniwidth/test-u32-width.c: Likewise.
104059         * tests/uniwidth/test-uc_width.c: Likewise.
104060         * tests/uniwidth/test-uc_width2.c: Likewise.
104061         * modules/acl-tests (Files): Add tests/macros.h.
104062         * modules/areadlink-tests (Files): Likewise.
104063         * modules/areadlink-with-size-tests (Files): Likewise.
104064         * modules/areadlinkat-tests (Files): Likewise.
104065         * modules/areadlinkat-with-size-tests (Files): Likewise.
104066         * modules/argmatch-tests (Files): Likewise.
104067         * modules/argv-iter-tests (Files): Likewise.
104068         * modules/array-list-tests (Files): Likewise.
104069         * modules/array-mergesort-tests (Files): Likewise.
104070         * modules/array-oset-tests (Files): Likewise.
104071         * modules/avltree-list-tests (Files): Likewise.
104072         * modules/avltree-oset-tests (Files): Likewise.
104073         * modules/avltreehash-list-tests (Files): Likewise.
104074         * modules/base64-tests (Files): Likewise.
104075         * modules/binary-io-tests (Files): Likewise.
104076         * modules/bitrotate-tests (Files): Likewise.
104077         * modules/btowc-tests (Files): Likewise.
104078         * modules/byteswap-tests (Files): Likewise.
104079         * modules/c-ctype-tests (Files): Likewise.
104080         * modules/c-stack-tests (Files): Likewise.
104081         * modules/c-strcase-tests (Files): Likewise.
104082         * modules/c-strcasestr-tests (Files): Likewise.
104083         * modules/c-strstr-tests (Files): Likewise.
104084         * modules/canonicalize-lgpl-tests (Files): Likewise.
104085         * modules/canonicalize-tests (Files): Likewise.
104086         * modules/carray-list-tests (Files): Likewise.
104087         * modules/ceilf-tests (Files): Likewise.
104088         * modules/ceill-tests (Files): Likewise.
104089         * modules/chown-tests (Files): Likewise.
104090         * modules/cloexec-tests (Files): Likewise.
104091         * modules/copy-file-tests (Files): Likewise.
104092         * modules/count-one-bits-tests (Files): Likewise.
104093         * modules/dprintf-posix-tests (Files): Likewise.
104094         * modules/dup2-tests (Files): Likewise.
104095         * modules/dup3-tests (Files): Likewise.
104096         * modules/duplocale-tests (Files): Likewise.
104097         * modules/fbufmode-tests (Files): Likewise.
104098         * modules/fchdir-tests (Files): Likewise.
104099         * modules/fcntl-safer-tests (Files): Likewise.
104100         * modules/fcntl-tests (Files): Likewise.
104101         * modules/fdopendir-tests (Files): Likewise.
104102         * modules/fdutimensat-tests (Files): Likewise.
104103         * modules/fflush-tests (Files): Likewise.
104104         * modules/filevercmp-tests (Files): Likewise.
104105         * modules/flock-tests (Files): Likewise.
104106         * modules/floorf-tests (Files): Likewise.
104107         * modules/floorl-tests (Files): Likewise.
104108         * modules/fnmatch-tests (Files): Likewise.
104109         * modules/fopen-safer-tests (Files): Likewise.
104110         * modules/fopen-tests (Files): Likewise.
104111         * modules/fpending-tests (Files): Likewise.
104112         * modules/fprintf-posix-tests (Files): Likewise.
104113         * modules/fpurge-tests (Files): Likewise.
104114         * modules/freadable-tests (Files): Likewise.
104115         * modules/freadahead-tests (Files): Likewise.
104116         * modules/freading-tests (Files): Likewise.
104117         * modules/freadptr-tests (Files): Likewise.
104118         * modules/freadseek-tests (Files): Likewise.
104119         * modules/freopen-tests (Files): Likewise.
104120         * modules/frexp-nolibm-tests (Files): Likewise.
104121         * modules/frexp-tests (Files): Likewise.
104122         * modules/frexpl-nolibm-tests (Files): Likewise.
104123         * modules/frexpl-tests (Files): Likewise.
104124         * modules/fseek-tests (Files): Likewise.
104125         * modules/fseeko-tests (Files): Likewise.
104126         * modules/fstrcmp-tests (Files): Likewise.
104127         * modules/fsync-tests (Files): Likewise.
104128         * modules/ftell-tests (Files): Likewise.
104129         * modules/ftello-tests (Files): Likewise.
104130         * modules/func-tests (Files): Likewise.
104131         * modules/futimens-tests (Files): Likewise.
104132         * modules/fwritable-tests (Files): Likewise.
104133         * modules/fwriting-tests (Files): Likewise.
104134         * modules/getcwd-tests (Files): Likewise.
104135         * modules/getdate-tests (Files): Likewise.
104136         * modules/getdelim-tests (Files): Likewise.
104137         * modules/getdtablesize-tests (Files): Likewise.
104138         * modules/getgroups-tests (Files): Likewise.
104139         * modules/getline-tests (Files): Likewise.
104140         * modules/getndelim2-tests (Files): Likewise.
104141         * modules/glob-tests (Files): Likewise.
104142         * modules/hash-tests (Files): Likewise.
104143         * modules/i-ring-tests (Files): Likewise.
104144         * modules/iconv-tests (Files): Likewise.
104145         * modules/iconv_open-utf-tests (Files): Likewise.
104146         * modules/idpriv-drop-tests (Files): Likewise.
104147         * modules/idpriv-droptemp-tests (Files): Likewise.
104148         * modules/inet_ntop-tests (Files): Likewise.
104149         * modules/inet_pton-tests (Files): Likewise.
104150         * modules/isblank-tests (Files): Likewise.
104151         * modules/isfinite-tests (Files): Likewise.
104152         * modules/isinf-tests (Files): Likewise.
104153         * modules/isnan-tests (Files): Likewise.
104154         * modules/isnand-nolibm-tests (Files): Likewise.
104155         * modules/isnand-tests (Files): Likewise.
104156         * modules/isnanf-nolibm-tests (Files): Likewise.
104157         * modules/isnanf-tests (Files): Likewise.
104158         * modules/isnanl-nolibm-tests (Files): Likewise.
104159         * modules/isnanl-tests (Files): Likewise.
104160         * modules/lchown-tests (Files): Likewise.
104161         * modules/ldexpl-tests (Files): Likewise.
104162         * modules/link-tests (Files): Likewise.
104163         * modules/linkat-tests (Files): Likewise.
104164         * modules/linked-list-tests (Files): Likewise.
104165         * modules/linkedhash-list-tests (Files): Likewise.
104166         * modules/localename-tests (Files): Likewise.
104167         * modules/lseek-tests (Files): Likewise.
104168         * modules/lstat-tests (Files): Likewise.
104169         * modules/mbmemcasecmp-tests (Files): Likewise.
104170         * modules/mbmemcasecoll-tests (Files): Likewise.
104171         * modules/mbrtowc-tests (Files): Likewise.
104172         * modules/mbscasecmp-tests (Files): Likewise.
104173         * modules/mbscasestr-tests (Files): Likewise.
104174         * modules/mbschr-tests (Files): Likewise.
104175         * modules/mbscspn-tests (Files): Likewise.
104176         * modules/mbsinit-tests (Files): Likewise.
104177         * modules/mbsncasecmp-tests (Files): Likewise.
104178         * modules/mbsnrtowcs-tests (Files): Likewise.
104179         * modules/mbspbrk-tests (Files): Likewise.
104180         * modules/mbspcasecmp-tests (Files): Likewise.
104181         * modules/mbsrchr-tests (Files): Likewise.
104182         * modules/mbsrtowcs-tests (Files): Likewise.
104183         * modules/mbsspn-tests (Files): Likewise.
104184         * modules/mbsstr-tests (Files): Likewise.
104185         * modules/memchr-tests (Files): Likewise.
104186         * modules/memchr2-tests (Files): Likewise.
104187         * modules/memcmp-tests (Files): Likewise.
104188         * modules/memmem-tests (Files): Likewise.
104189         * modules/memrchr-tests (Files): Likewise.
104190         * modules/mkdir-tests (Files): Likewise.
104191         * modules/mkfifo-tests (Files): Likewise.
104192         * modules/mkfifoat-tests (Files): Likewise.
104193         * modules/mknod-tests (Files): Likewise.
104194         * modules/nanosleep-tests (Files): Likewise.
104195         * modules/nl_langinfo-tests (Files): Likewise.
104196         * modules/obstack-printf-tests (Files): Likewise.
104197         * modules/open-tests (Files): Likewise.
104198         * modules/openat-tests (Files): Likewise.
104199         * modules/pipe-filter-gi-tests (Files): Likewise.
104200         * modules/pipe-filter-ii-tests (Files): Likewise.
104201         * modules/pipe2-tests (Files): Likewise.
104202         * modules/popen-safer-tests (Files): Likewise.
104203         * modules/popen-tests (Files): Likewise.
104204         * modules/posixtm-tests (Files): Likewise.
104205         * modules/pread-tests (Files): Likewise.
104206         * modules/printf-frexp-tests (Files): Likewise.
104207         * modules/printf-frexpl-tests (Files): Likewise.
104208         * modules/printf-posix-tests (Files): Likewise.
104209         * modules/priv-set-tests (Files): Likewise.
104210         * modules/quotearg-tests (Files): Likewise.
104211         * modules/random_r-tests (Files): Likewise.
104212         * modules/rawmemchr-tests (Files): Likewise.
104213         * modules/rbtree-list-tests (Files): Likewise.
104214         * modules/rbtree-oset-tests (Files): Likewise.
104215         * modules/rbtreehash-list-tests (Files): Likewise.
104216         * modules/readlink-tests (Files): Likewise.
104217         * modules/remove-tests (Files): Likewise.
104218         * modules/rename-tests (Files): Likewise.
104219         * modules/renameat-tests (Files): Likewise.
104220         * modules/rmdir-tests (Files): Likewise.
104221         * modules/round-tests (Files): Likewise.
104222         * modules/roundf-tests (Files): Likewise.
104223         * modules/roundl-tests (Files): Likewise.
104224         * modules/safe-alloc-tests (Files): Likewise.
104225         * modules/setenv-tests (Files): Likewise.
104226         * modules/sigaction-tests (Files): Likewise.
104227         * modules/signbit-tests (Files): Likewise.
104228         * modules/sleep-tests (Files): Likewise.
104229         * modules/snprintf-posix-tests (Files): Likewise.
104230         * modules/snprintf-tests (Files): Likewise.
104231         * modules/sprintf-posix-tests (Files): Likewise.
104232         * modules/stat-tests (Files): Likewise.
104233         * modules/stat-time-tests (Files): Likewise.
104234         * modules/strcasestr-tests (Files): Likewise.
104235         * modules/strchrnul-tests (Files): Likewise.
104236         * modules/strerror-tests (Files): Likewise.
104237         * modules/striconv-tests (Files): Likewise.
104238         * modules/striconveh-tests (Files): Likewise.
104239         * modules/striconveha-tests (Files): Likewise.
104240         * modules/strsignal-tests (Files): Likewise.
104241         * modules/strstr-tests (Files): Likewise.
104242         * modules/strtod-tests (Files): Likewise.
104243         * modules/strverscmp-tests (Files): Likewise.
104244         * modules/symlink-tests (Files): Likewise.
104245         * modules/symlinkat-tests (Files): Likewise.
104246         * modules/trunc-tests (Files): Likewise.
104247         * modules/truncf-tests (Files): Likewise.
104248         * modules/truncl-tests (Files): Likewise.
104249         * modules/uname-tests (Files): Likewise.
104250         * modules/unicase/cased-tests (Files): Likewise.
104251         * modules/unicase/ignorable-tests (Files): Likewise.
104252         * modules/unicase/locale-language-tests (Files): Likewise.
104253         * modules/unicase/tolower-tests (Files): Likewise.
104254         * modules/unicase/totitle-tests (Files): Likewise.
104255         * modules/unicase/toupper-tests (Files): Likewise.
104256         * modules/unicase/u8-casecmp-tests (Files): Likewise.
104257         * modules/unicase/u8-casecoll-tests (Files): Likewise.
104258         * modules/unicase/u8-casefold-tests (Files): Likewise.
104259         * modules/unicase/u8-is-cased-tests (Files): Likewise.
104260         * modules/unicase/u8-is-casefolded-tests (Files): Likewise.
104261         * modules/unicase/u8-is-lowercase-tests (Files): Likewise.
104262         * modules/unicase/u8-is-titlecase-tests (Files): Likewise.
104263         * modules/unicase/u8-is-uppercase-tests (Files): Likewise.
104264         * modules/unicase/u8-tolower-tests (Files): Likewise.
104265         * modules/unicase/u8-totitle-tests (Files): Likewise.
104266         * modules/unicase/u8-toupper-tests (Files): Likewise.
104267         * modules/unicase/u16-casecmp-tests (Files): Likewise.
104268         * modules/unicase/u16-casecoll-tests (Files): Likewise.
104269         * modules/unicase/u16-casefold-tests (Files): Likewise.
104270         * modules/unicase/u16-is-cased-tests (Files): Likewise.
104271         * modules/unicase/u16-is-casefolded-tests (Files): Likewise.
104272         * modules/unicase/u16-is-lowercase-tests (Files): Likewise.
104273         * modules/unicase/u16-is-titlecase-tests (Files): Likewise.
104274         * modules/unicase/u16-is-uppercase-tests (Files): Likewise.
104275         * modules/unicase/u16-tolower-tests (Files): Likewise.
104276         * modules/unicase/u16-totitle-tests (Files): Likewise.
104277         * modules/unicase/u16-toupper-tests (Files): Likewise.
104278         * modules/unicase/u32-casecmp-tests (Files): Likewise.
104279         * modules/unicase/u32-casecoll-tests (Files): Likewise.
104280         * modules/unicase/u32-casefold-tests (Files): Likewise.
104281         * modules/unicase/u32-is-cased-tests (Files): Likewise.
104282         * modules/unicase/u32-is-casefolded-tests (Files): Likewise.
104283         * modules/unicase/u32-is-lowercase-tests (Files): Likewise.
104284         * modules/unicase/u32-is-titlecase-tests (Files): Likewise.
104285         * modules/unicase/u32-is-uppercase-tests (Files): Likewise.
104286         * modules/unicase/u32-tolower-tests (Files): Likewise.
104287         * modules/unicase/u32-totitle-tests (Files): Likewise.
104288         * modules/unicase/u32-toupper-tests (Files): Likewise.
104289         * modules/unicase/ulc-casecmp-tests (Files): Likewise.
104290         * modules/unicase/ulc-casecoll-tests (Files): Likewise.
104291         * modules/uniconv/u8-conv-from-enc-tests (Files): Likewise.
104292         * modules/uniconv/u8-conv-to-enc-tests (Files): Likewise.
104293         * modules/uniconv/u8-strconv-from-enc-tests (Files): Likewise.
104294         * modules/uniconv/u8-strconv-to-enc-tests (Files): Likewise.
104295         * modules/uniconv/u16-conv-from-enc-tests (Files): Likewise.
104296         * modules/uniconv/u16-conv-to-enc-tests (Files): Likewise.
104297         * modules/uniconv/u16-strconv-from-enc-tests (Files): Likewise.
104298         * modules/uniconv/u16-strconv-to-enc-tests (Files): Likewise.
104299         * modules/uniconv/u32-conv-from-enc-tests (Files): Likewise.
104300         * modules/uniconv/u32-conv-to-enc-tests (Files): Likewise.
104301         * modules/uniconv/u32-strconv-from-enc-tests (Files): Likewise.
104302         * modules/uniconv/u32-strconv-to-enc-tests (Files): Likewise.
104303         * modules/unictype/bidicategory-byname-tests (Files): Likewise.
104304         * modules/unictype/bidicategory-name-tests (Files): Likewise.
104305         * modules/unictype/bidicategory-of-tests (Files): Likewise.
104306         * modules/unictype/bidicategory-test-tests (Files): Likewise.
104307         * modules/unictype/block-list-tests (Files): Likewise.
104308         * modules/unictype/block-of-tests (Files): Likewise.
104309         * modules/unictype/block-test-tests (Files): Likewise.
104310         * modules/unictype/category-C-tests (Files): Likewise.
104311         * modules/unictype/category-Cc-tests (Files): Likewise.
104312         * modules/unictype/category-Cf-tests (Files): Likewise.
104313         * modules/unictype/category-Cn-tests (Files): Likewise.
104314         * modules/unictype/category-Co-tests (Files): Likewise.
104315         * modules/unictype/category-Cs-tests (Files): Likewise.
104316         * modules/unictype/category-L-tests (Files): Likewise.
104317         * modules/unictype/category-Ll-tests (Files): Likewise.
104318         * modules/unictype/category-Lm-tests (Files): Likewise.
104319         * modules/unictype/category-Lo-tests (Files): Likewise.
104320         * modules/unictype/category-Lt-tests (Files): Likewise.
104321         * modules/unictype/category-Lu-tests (Files): Likewise.
104322         * modules/unictype/category-M-tests (Files): Likewise.
104323         * modules/unictype/category-Mc-tests (Files): Likewise.
104324         * modules/unictype/category-Me-tests (Files): Likewise.
104325         * modules/unictype/category-Mn-tests (Files): Likewise.
104326         * modules/unictype/category-N-tests (Files): Likewise.
104327         * modules/unictype/category-Nd-tests (Files): Likewise.
104328         * modules/unictype/category-Nl-tests (Files): Likewise.
104329         * modules/unictype/category-No-tests (Files): Likewise.
104330         * modules/unictype/category-P-tests (Files): Likewise.
104331         * modules/unictype/category-Pc-tests (Files): Likewise.
104332         * modules/unictype/category-Pd-tests (Files): Likewise.
104333         * modules/unictype/category-Pe-tests (Files): Likewise.
104334         * modules/unictype/category-Pf-tests (Files): Likewise.
104335         * modules/unictype/category-Pi-tests (Files): Likewise.
104336         * modules/unictype/category-Po-tests (Files): Likewise.
104337         * modules/unictype/category-Ps-tests (Files): Likewise.
104338         * modules/unictype/category-S-tests (Files): Likewise.
104339         * modules/unictype/category-Sc-tests (Files): Likewise.
104340         * modules/unictype/category-Sk-tests (Files): Likewise.
104341         * modules/unictype/category-Sm-tests (Files): Likewise.
104342         * modules/unictype/category-So-tests (Files): Likewise.
104343         * modules/unictype/category-Z-tests (Files): Likewise.
104344         * modules/unictype/category-Zl-tests (Files): Likewise.
104345         * modules/unictype/category-Zp-tests (Files): Likewise.
104346         * modules/unictype/category-Zs-tests (Files): Likewise.
104347         * modules/unictype/category-and-not-tests (Files): Likewise.
104348         * modules/unictype/category-and-tests (Files): Likewise.
104349         * modules/unictype/category-byname-tests (Files): Likewise.
104350         * modules/unictype/category-name-tests (Files): Likewise.
104351         * modules/unictype/category-none-tests (Files): Likewise.
104352         * modules/unictype/category-of-tests (Files): Likewise.
104353         * modules/unictype/category-or-tests (Files): Likewise.
104354         * modules/unictype/category-test-withtable-tests (Files): Likewise.
104355         * modules/unictype/combining-class-tests (Files): Likewise.
104356         * modules/unictype/ctype-alnum-tests (Files): Likewise.
104357         * modules/unictype/ctype-alpha-tests (Files): Likewise.
104358         * modules/unictype/ctype-blank-tests (Files): Likewise.
104359         * modules/unictype/ctype-cntrl-tests (Files): Likewise.
104360         * modules/unictype/ctype-digit-tests (Files): Likewise.
104361         * modules/unictype/ctype-graph-tests (Files): Likewise.
104362         * modules/unictype/ctype-lower-tests (Files): Likewise.
104363         * modules/unictype/ctype-print-tests (Files): Likewise.
104364         * modules/unictype/ctype-punct-tests (Files): Likewise.
104365         * modules/unictype/ctype-space-tests (Files): Likewise.
104366         * modules/unictype/ctype-upper-tests (Files): Likewise.
104367         * modules/unictype/ctype-xdigit-tests (Files): Likewise.
104368         * modules/unictype/decimal-digit-tests (Files): Likewise.
104369         * modules/unictype/digit-tests (Files): Likewise.
104370         * modules/unictype/mirror-tests (Files): Likewise.
104371         * modules/unictype/numeric-tests (Files): Likewise.
104372         * modules/unictype/property-alphabetic-tests (Files): Likewise.
104373         * modules/unictype/property-ascii-hex-digit-tests (Files): Likewise.
104374         * modules/unictype/property-bidi-arabic-digit-tests (Files): Likewise.
104375         * modules/unictype/property-bidi-arabic-right-to-left-tests (Files):
104376         Likewise.
104377         * modules/unictype/property-bidi-block-separator-tests (Files):
104378         Likewise.
104379         * modules/unictype/property-bidi-boundary-neutral-tests (Files):
104380         Likewise.
104381         * modules/unictype/property-bidi-common-separator-tests (Files):
104382         Likewise.
104383         * modules/unictype/property-bidi-control-tests (Files): Likewise.
104384         * modules/unictype/property-bidi-embedding-or-override-tests (Files):
104385         Likewise.
104386         * modules/unictype/property-bidi-eur-num-separator-tests (Files):
104387         Likewise.
104388         * modules/unictype/property-bidi-eur-num-terminator-tests (Files):
104389         Likewise.
104390         * modules/unictype/property-bidi-european-digit-tests (Files): Likewise.
104391         * modules/unictype/property-bidi-hebrew-right-to-left-tests (Files):
104392         Likewise.
104393         * modules/unictype/property-bidi-left-to-right-tests (Files): Likewise.
104394         * modules/unictype/property-bidi-non-spacing-mark-tests (Files):
104395         Likewise.
104396         * modules/unictype/property-bidi-other-neutral-tests (Files): Likewise.
104397         * modules/unictype/property-bidi-pdf-tests (Files): Likewise.
104398         * modules/unictype/property-bidi-segment-separator-tests (Files):
104399         Likewise.
104400         * modules/unictype/property-bidi-whitespace-tests (Files): Likewise.
104401         * modules/unictype/property-byname-tests (Files): Likewise.
104402         * modules/unictype/property-combining-tests (Files): Likewise.
104403         * modules/unictype/property-composite-tests (Files): Likewise.
104404         * modules/unictype/property-currency-symbol-tests (Files): Likewise.
104405         * modules/unictype/property-dash-tests (Files): Likewise.
104406         * modules/unictype/property-decimal-digit-tests (Files): Likewise.
104407         * modules/unictype/property-default-ignorable-code-point-tests (Files):
104408         Likewise.
104409         * modules/unictype/property-deprecated-tests (Files): Likewise.
104410         * modules/unictype/property-diacritic-tests (Files): Likewise.
104411         * modules/unictype/property-extender-tests (Files): Likewise.
104412         * modules/unictype/property-format-control-tests (Files): Likewise.
104413         * modules/unictype/property-grapheme-base-tests (Files): Likewise.
104414         * modules/unictype/property-grapheme-extend-tests (Files): Likewise.
104415         * modules/unictype/property-grapheme-link-tests (Files): Likewise.
104416         * modules/unictype/property-hex-digit-tests (Files): Likewise.
104417         * modules/unictype/property-hyphen-tests (Files): Likewise.
104418         * modules/unictype/property-id-continue-tests (Files): Likewise.
104419         * modules/unictype/property-id-start-tests (Files): Likewise.
104420         * modules/unictype/property-ideographic-tests (Files): Likewise.
104421         * modules/unictype/property-ids-binary-operator-tests (Files): Likewise.
104422         * modules/unictype/property-ids-trinary-operator-tests (Files):
104423         Likewise.
104424         * modules/unictype/property-ignorable-control-tests (Files): Likewise.
104425         * modules/unictype/property-iso-control-tests (Files): Likewise.
104426         * modules/unictype/property-join-control-tests (Files): Likewise.
104427         * modules/unictype/property-left-of-pair-tests (Files): Likewise.
104428         * modules/unictype/property-line-separator-tests (Files): Likewise.
104429         * modules/unictype/property-logical-order-exception-tests (Files):
104430         Likewise.
104431         * modules/unictype/property-lowercase-tests (Files): Likewise.
104432         * modules/unictype/property-math-tests (Files): Likewise.
104433         * modules/unictype/property-non-break-tests (Files): Likewise.
104434         * modules/unictype/property-not-a-character-tests (Files): Likewise.
104435         * modules/unictype/property-numeric-tests (Files): Likewise.
104436         * modules/unictype/property-other-alphabetic-tests (Files): Likewise.
104437         * modules/unictype/property-other-default-ignorable-code-point-tests
104438         (Files): Likewise.
104439         * modules/unictype/property-other-grapheme-extend-tests (Files):
104440         Likewise.
104441         * modules/unictype/property-other-id-continue-tests (Files): Likewise.
104442         * modules/unictype/property-other-id-start-tests (Files): Likewise.
104443         * modules/unictype/property-other-lowercase-tests (Files): Likewise.
104444         * modules/unictype/property-other-math-tests (Files): Likewise.
104445         * modules/unictype/property-other-uppercase-tests (Files): Likewise.
104446         * modules/unictype/property-paired-punctuation-tests (Files): Likewise.
104447         * modules/unictype/property-paragraph-separator-tests (Files): Likewise.
104448         * modules/unictype/property-pattern-syntax-tests (Files): Likewise.
104449         * modules/unictype/property-pattern-white-space-tests (Files): Likewise.
104450         * modules/unictype/property-private-use-tests (Files): Likewise.
104451         * modules/unictype/property-punctuation-tests (Files): Likewise.
104452         * modules/unictype/property-quotation-mark-tests (Files): Likewise.
104453         * modules/unictype/property-radical-tests (Files): Likewise.
104454         * modules/unictype/property-sentence-terminal-tests (Files): Likewise.
104455         * modules/unictype/property-soft-dotted-tests (Files): Likewise.
104456         * modules/unictype/property-space-tests (Files): Likewise.
104457         * modules/unictype/property-terminal-punctuation-tests (Files):
104458         Likewise.
104459         * modules/unictype/property-test-tests (Files): Likewise.
104460         * modules/unictype/property-titlecase-tests (Files): Likewise.
104461         * modules/unictype/property-unassigned-code-value-tests (Files):
104462         Likewise.
104463         * modules/unictype/property-unified-ideograph-tests (Files): Likewise.
104464         * modules/unictype/property-uppercase-tests (Files): Likewise.
104465         * modules/unictype/property-variation-selector-tests (Files): Likewise.
104466         * modules/unictype/property-white-space-tests (Files): Likewise.
104467         * modules/unictype/property-xid-continue-tests (Files): Likewise.
104468         * modules/unictype/property-xid-start-tests (Files): Likewise.
104469         * modules/unictype/property-zero-width-tests (Files): Likewise.
104470         * modules/unictype/scripts-tests (Files): Likewise.
104471         * modules/unictype/syntax-c-ident-tests (Files): Likewise.
104472         * modules/unictype/syntax-c-whitespace-tests (Files): Likewise.
104473         * modules/unictype/syntax-java-ident-tests (Files): Likewise.
104474         * modules/unictype/syntax-java-whitespace-tests (Files): Likewise.
104475         * modules/unilbrk/u8-possible-linebreaks-tests (Files): Likewise.
104476         * modules/unilbrk/u8-width-linebreaks-tests (Files): Likewise.
104477         * modules/unilbrk/u16-possible-linebreaks-tests (Files): Likewise.
104478         * modules/unilbrk/u16-width-linebreaks-tests (Files): Likewise.
104479         * modules/unilbrk/u32-possible-linebreaks-tests (Files): Likewise.
104480         * modules/unilbrk/u32-width-linebreaks-tests (Files): Likewise.
104481         * modules/unilbrk/ulc-possible-linebreaks-tests (Files): Likewise.
104482         * modules/unilbrk/ulc-width-linebreaks-tests (Files): Likewise.
104483         * modules/uninorm/canonical-decomposition-tests (Files): Likewise.
104484         * modules/uninorm/compat-decomposition-tests (Files): Likewise.
104485         * modules/uninorm/composition-tests (Files): Likewise.
104486         * modules/uninorm/decomposing-form-tests (Files): Likewise.
104487         * modules/uninorm/decomposition-tests (Files): Likewise.
104488         * modules/uninorm/filter-tests (Files): Likewise.
104489         * modules/uninorm/nfc-tests (Files): Likewise.
104490         * modules/uninorm/nfd-tests (Files): Likewise.
104491         * modules/uninorm/nfkc-tests (Files): Likewise.
104492         * modules/uninorm/nfkd-tests (Files): Likewise.
104493         * modules/uninorm/u8-normcmp-tests (Files): Likewise.
104494         * modules/uninorm/u8-normcoll-tests (Files): Likewise.
104495         * modules/uninorm/u16-normcmp-tests (Files): Likewise.
104496         * modules/uninorm/u16-normcoll-tests (Files): Likewise.
104497         * modules/uninorm/u32-normcmp-tests (Files): Likewise.
104498         * modules/uninorm/u32-normcoll-tests (Files): Likewise.
104499         * modules/unistdio/u8-asnprintf-tests (Files): Likewise.
104500         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
104501         * modules/unistdio/u8-vasprintf-tests (Files): Likewise.
104502         * modules/unistdio/u8-vsnprintf-tests (Files): Likewise.
104503         * modules/unistdio/u8-vsprintf-tests (Files): Likewise.
104504         * modules/unistdio/u16-asnprintf-tests (Files): Likewise.
104505         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
104506         * modules/unistdio/u16-vasprintf-tests (Files): Likewise.
104507         * modules/unistdio/u16-vsnprintf-tests (Files): Likewise.
104508         * modules/unistdio/u16-vsprintf-tests (Files): Likewise.
104509         * modules/unistdio/u32-asnprintf-tests (Files): Likewise.
104510         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
104511         * modules/unistdio/u32-vasprintf-tests (Files): Likewise.
104512         * modules/unistdio/u32-vsnprintf-tests (Files): Likewise.
104513         * modules/unistdio/u32-vsprintf-tests (Files): Likewise.
104514         * modules/unistdio/ulc-asnprintf-tests (Files): Likewise.
104515         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
104516         * modules/unistdio/ulc-vasprintf-tests (Files): Likewise.
104517         * modules/unistdio/ulc-vsnprintf-tests (Files): Likewise.
104518         * modules/unistdio/ulc-vsprintf-tests (Files): Likewise.
104519         * modules/uniwbrk/u8-wordbreaks-tests (Files): Likewise.
104520         * modules/uniwbrk/u16-wordbreaks-tests (Files): Likewise.
104521         * modules/uniwbrk/u32-wordbreaks-tests (Files): Likewise.
104522         * modules/uniwbrk/ulc-wordbreaks-tests (Files): Likewise.
104523         * modules/uniwidth/u8-strwidth-tests (Files): Likewise.
104524         * modules/uniwidth/u8-width-tests (Files): Likewise.
104525         * modules/uniwidth/u16-strwidth-tests (Files): Likewise.
104526         * modules/uniwidth/u16-width-tests (Files): Likewise.
104527         * modules/uniwidth/u32-strwidth-tests (Files): Likewise.
104528         * modules/uniwidth/u32-width-tests (Files): Likewise.
104529         * modules/uniwidth/width-tests (Files): Likewise.
104530         * modules/unlink-tests (Files): Likewise.
104531         * modules/unsetenv-tests (Files): Likewise.
104532         * modules/usleep-tests (Files): Likewise.
104533         * modules/utimens-tests (Files): Likewise.
104534         * modules/utimensat-tests (Files): Likewise.
104535         * modules/vasnprintf-posix-tests (Files): Likewise.
104536         * modules/vasnprintf-tests (Files): Likewise.
104537         * modules/vasprintf-posix-tests (Files): Likewise.
104538         * modules/vasprintf-tests (Files): Likewise.
104539         * modules/vdprintf-posix-tests (Files): Likewise.
104540         * modules/vfprintf-posix-tests (Files): Likewise.
104541         * modules/vprintf-posix-tests (Files): Likewise.
104542         * modules/vsnprintf-posix-tests (Files): Likewise.
104543         * modules/vsnprintf-tests (Files): Likewise.
104544         * modules/vsprintf-posix-tests (Files): Likewise.
104545         * modules/wcrtomb-tests (Files): Likewise.
104546         * modules/wcsnrtombs-tests (Files): Likewise.
104547         * modules/wcsrtombs-tests (Files): Likewise.
104548         * modules/wctype-tests (Files): Likewise.
104549         * modules/wcwidth-tests (Files): Likewise.
104550         * modules/xmemdup0-tests (Files): Likewise.
104551         * modules/xprintf-posix-tests (Files): Likewise.
104552         * modules/xvasprintf-tests (Files): Likewise.
104554 2009-12-24  Eric Blake  <ebb9@byu.net>
104556         test-nanosleep: fix typo
104557         * tests/test-nanosleep.c (SIGNATURE_CHECK): Fix typo in previous
104558         patch.
104559         Reported by Bruno Haible.
104561 2009-12-24  Bruno Haible  <bruno@clisp.org>
104563         Reduce namespace pollution on glibc systems.
104564         * lib/inttypes.in.h: Don't include <stdint.h> on glibc systems.
104565         * lib/stdlib.in.h: Don't include <stdint.h>, <unistd.h> on glibc
104566         systems.
104567         * lib/unistd.in.h: Don't include <stdio.h>, <fcntl.h>, <stdlib.h>,
104568         <getopt.h> on glibc systems.
104569         * lib/fcntl.in.h: Don't include <sys/stat.h>, <unistd.h> on glibc
104570         systems.
104571         * lib/fcntl.c: Include <unistd.h> here instead.
104573 2009-12-24  Bruno Haible  <bruno@clisp.org>
104575         * lib/stdlib.in.h (includes): Fix typo in today's commit.
104577 2009-12-24  Eric Blake  <ebb9@byu.net>
104579         tests: add signature checks
104580         * tests/signature.h (SIGNATURE_CHECK): New file.
104581         * modules/atexit-tests (Files): Use it.
104582         * modules/btowc-tests (Files): Likewise.
104583         * modules/canonicalize-lgpl-tests (Files): Likewise.
104584         * modules/ceilf-tests (Files): Likewise.
104585         * modules/ceill-tests (Files): Likewise.
104586         * modules/chown-tests (Files): Likewise.
104587         * modules/dprintf-posix-tests (Files): Likewise.
104588         * modules/dup2-tests (Files): Likewise.
104589         * modules/dup3-tests (Files): Likewise.
104590         * modules/duplocale-tests (Files): Likewise.
104591         * modules/fchdir-tests (Files): Likewise.
104592         * modules/fcntl-tests (Files): Likewise.
104593         * modules/fdopendir-tests (Files): Likewise.
104594         * modules/fflush-tests (Files): Likewise.
104595         * modules/flock-tests (Files): Likewise.
104596         * modules/floorf-tests (Files): Likewise.
104597         * modules/floorl-tests (Files): Likewise.
104598         * modules/fnmatch-tests (Files): Likewise.
104599         * modules/fopen-tests (Files): Likewise.
104600         * modules/fprintf-posix-tests (Files): Likewise.
104601         * modules/freopen-tests (Files): Likewise.
104602         * modules/frexp-nolibm-tests (Files): Likewise.
104603         * modules/frexp-tests (Files): Likewise.
104604         * modules/frexpl-nolibm-tests (Files): Likewise.
104605         * modules/frexpl-tests (Files): Likewise.
104606         * modules/fseek-tests (Files): Likewise.
104607         * modules/fseeko-tests (Files): Likewise.
104608         * modules/fsync-tests (Files): Likewise.
104609         * modules/ftell-tests (Files): Likewise.
104610         * modules/ftello-tests (Files): Likewise.
104611         * modules/futimens-tests (Files): Likewise.
104612         * modules/getaddrinfo-tests (Files): Likewise.
104613         * modules/getcwd-tests (Files): Likewise.
104614         * modules/getdelim-tests (Files): Likewise.
104615         * modules/getdtablesize-tests (Files): Likewise.
104616         * modules/getgroups-tests (Files): Likewise.
104617         * modules/gethostname-tests (Files): Likewise.
104618         * modules/getline-tests (Files): Likewise.
104619         * modules/getopt-posix-tests (Files): Likewise.
104620         * modules/gettimeofday-tests (Files): Likewise.
104621         * modules/glob-tests (Files): Likewise.
104622         * modules/iconv-tests (Files): Likewise.
104623         * modules/inet_ntop-tests (Files): Likewise.
104624         * modules/inet_pton-tests (Files): Likewise.
104625         * modules/isblank-tests (Files): Likewise.
104626         * modules/lchown-tests (Files): Likewise.
104627         * modules/ldexpl-tests (Files): Likewise.
104628         * modules/link-tests (Files): Likewise.
104629         * modules/linkat-tests (Files): Likewise.
104630         * modules/lseek-tests (Files): Likewise.
104631         * modules/lstat-tests (Files): Likewise.
104632         * modules/mbrtowc-tests (Files): Likewise.
104633         * modules/mbsinit-tests (Files): Likewise.
104634         * modules/mbsnrtowcs-tests (Files): Likewise.
104635         * modules/mbsrtowcs-tests (Files): Likewise.
104636         * modules/memchr-tests (Files): Likewise.
104637         * modules/memcmp-tests (Files): Likewise.
104638         * modules/memmem-tests (Files): Likewise.
104639         * modules/memrchr-tests (Files): Likewise.
104640         * modules/mkdir-tests (Files): Likewise.
104641         * modules/mkfifo-tests (Files): Likewise.
104642         * modules/mkfifoat-tests (Files): Likewise.
104643         * modules/mknod-tests (Files): Likewise.
104644         * modules/nanosleep-tests (Files): Likewise.
104645         * modules/nl_langinfo-tests (Files): Likewise.
104646         * modules/obstack-printf-tests (Files): Likewise.
104647         * modules/open-tests (Files): Likewise.
104648         * modules/openat-tests (Files): Likewise.
104649         * modules/perror-tests (Files): Likewise.
104650         * modules/pipe2-tests (Files): Likewise.
104651         * modules/poll-tests (Files): Likewise.
104652         * modules/popen-tests (Files): Likewise.
104653         * modules/posix_spawn-tests (Files): Likewise.
104654         * modules/posix_spawnp-tests (Files): Likewise.
104655         * modules/pread-tests (Files): Likewise.
104656         * modules/printf-posix-tests (Files): Likewise.
104657         * modules/pty-tests (Files): Likewise.
104658         * modules/random_r-tests (Files): Likewise.
104659         * modules/rawmemchr-tests (Files): Likewise.
104660         * modules/readlink-tests (Files): Likewise.
104661         * modules/remove-tests (Files): Likewise.
104662         * modules/rename-tests (Files): Likewise.
104663         * modules/renameat-tests (Files): Likewise.
104664         * modules/rmdir-tests (Files): Likewise.
104665         * modules/round-tests (Files): Likewise.
104666         * modules/roundf-tests (Files): Likewise.
104667         * modules/roundl-tests (Files): Likewise.
104668         * modules/select-tests (Files): Likewise.
104669         * modules/setenv-tests (Files): Likewise.
104670         * modules/sigaction-tests (Files): Likewise.
104671         * modules/sleep-tests (Files): Likewise.
104672         * modules/snprintf-posix-tests (Files): Likewise.
104673         * modules/snprintf-tests (Files): Likewise.
104674         * modules/sprintf-posix-tests (Files): Likewise.
104675         * modules/stat-tests (Files): Likewise.
104676         * modules/strcasestr-tests (Files): Likewise.
104677         * modules/strchrnul-tests (Files): Likewise.
104678         * modules/strerror-tests (Files): Likewise.
104679         * modules/strsignal-tests (Files): Likewise.
104680         * modules/strstr-tests (Files): Likewise.
104681         * modules/strtod-tests (Files): Likewise.
104682         * modules/strverscmp-tests (Files): Likewise.
104683         * modules/symlink-tests (Files): Likewise.
104684         * modules/symlinkat-tests (Files): Likewise.
104685         * modules/times-tests (Files): Likewise.
104686         * modules/trunc-tests (Files): Likewise.
104687         * modules/truncf-tests (Files): Likewise.
104688         * modules/truncl-tests (Files): Likewise.
104689         * modules/tsearch-tests (Files): Likewise.
104690         * modules/uname-tests (Files): Likewise.
104691         * modules/unlink-tests (Files): Likewise.
104692         * modules/unsetenv-tests (Files): Likewise.
104693         * modules/usleep-tests (Files): Likewise.
104694         * modules/utimensat-tests (Files): Likewise.
104695         * modules/vasprintf-tests (Files): Likewise.
104696         * modules/vdprintf-posix-tests (Files): Likewise.
104697         * modules/vfprintf-posix-tests (Files): Likewise.
104698         * modules/vprintf-posix-tests (Files): Likewise.
104699         * modules/vsnprintf-posix-tests (Files): Likewise.
104700         * modules/vsnprintf-tests (Files): Likewise.
104701         * modules/vsprintf-posix-tests (Files): Likewise.
104702         * modules/wcrtomb-tests (Files): Likewise.
104703         * modules/wcsnrtombs-tests (Files): Likewise.
104704         * modules/wcsrtombs-tests (Files): Likewise.
104705         * modules/wcwidth-tests (Files): Likewise.
104706         * tests/test-isfinite.c (isfinite): Ensure macro declaration.
104707         * tests/test-isinf.c (isinf): Likewise.
104708         * tests/test-isnan.c (isnan): Likewise.
104709         * tests/test-signbit.c (signbit): Likewise.
104710         * tests/test-select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): Ensure
104711         declaration, either as macro or with correct signature.
104712         (select): Ensure function under test is declared with correct
104713         signature in correct header.
104714         * tests/test-atexit.c (atexit): Likewise.
104715         * tests/test-btowc.c (btowc): Likewise.
104716         * tests/test-canonicalize-lgpl.c (realpath)
104717         (canonicalize_file_name): Likewise.
104718         * tests/test-ceilf1.c (ceilf): Likewise.
104719         * tests/test-ceill.c (ceill): Likewise.
104720         * tests/test-chown.c (chown): Likewise.
104721         * tests/test-dprintf-posix.c (dprintf): Likewise.
104722         * tests/test-dup2.c (dup2): Likewise.
104723         * tests/test-dup3.c (dup3): Likewise.
104724         * tests/test-duplocale.c (duplocale): Likewise.
104725         * tests/test-fchdir.c (fchdir): Likewise.
104726         * tests/test-fchownat.c (fchownat): Likewise.
104727         * tests/test-fcntl.c (fcntl): Likewise.
104728         * tests/test-fdopendir.c (fdopendir): Likewise.
104729         * tests/test-fflush.c (fflush): Likewise.
104730         * tests/test-flock.c (flock): Likewise.
104731         * tests/test-floorf1.c (floorf): Likewise.
104732         * tests/test-floorl.c (floorl): Likewise.
104733         * tests/test-fnmatch.c (fnmatch): Likewise.
104734         * tests/test-fopen.c (fopen): Likewise.
104735         * tests/test-fprintf-posix.c (fprintf): Likewise.
104736         * tests/test-freopen.c (freopen): Likewise.
104737         * tests/test-frexp.c (frexp): Likewise.
104738         * tests/test-frexpl.c (frexpl): Likewise.
104739         * tests/test-fseek.c (fseek): Likewise.
104740         * tests/test-fseeko.c (fseeko): Likewise.
104741         * tests/test-fstatat.c (fstatat): Likewise.
104742         * tests/test-fsync.c (fsync): Likewise.
104743         * tests/test-ftell.c (ftell): Likewise.
104744         * tests/test-ftello.c (ftello): Likewise.
104745         * tests/test-futimens.c (futimens): Likewise.
104746         * tests/test-getaddrinfo.c (getaddrinfo, freeaddrinfo)
104747         (gai_strerror): Likewise.
104748         * tests/test-getcwd.c (getcwd): Likewise.
104749         * tests/test-getdelim.c (getdelim): Likewise.
104750         * tests/test-getdtablesize.c (getdtablesize): Likewise.
104751         * tests/test-getgroups.c (getgroups): Likewise.
104752         * tests/test-gethostname.c (gethostname): Likewise.
104753         * tests/test-getline.c (getline): Likewise.
104754         * tests/test-getopt.c (getopt, getopt_long, getopt_long_only):
104755         Likewise.
104756         * tests/test-gettimeofday.c (gettimeofday): Likewise.
104757         * tests/test-glob.c (glob, globfree): Likewise.
104758         * tests/test-iconv.c (iconv, iconv_open, iconv_close): Likewise.
104759         * tests/test-inet_ntop.c (inet_ntop): Likewise.
104760         * tests/test-inet_pton.c (inet_pton): Likewise.
104761         * tests/test-isblank.c (isblank): Likewise.
104762         * tests/test-lchown.c (lchown): Likewise.
104763         * tests/test-ldexpl.c (ldexpl): Likewise.
104764         * tests/test-link.c (link): Likewise.
104765         * tests/test-linkat.c (linkat): Likewise.
104766         * tests/test-lseek.c (lseek): Likewise.
104767         * tests/test-lstat.c (lstat): Likewise.
104768         * tests/test-mbrtowc.c (mbrtowc): Likewise.
104769         * tests/test-mbsinit.c (mbsinit): Likewise.
104770         * tests/test-mbsnrtowcs.c (mbsnrtowcs): Likewise.
104771         * tests/test-mbsrtowcs.c (mbsrtowcs): Likewise.
104772         * tests/test-memchr.c (memchr): Likewise.
104773         * tests/test-memcmp.c (memcmp): Likewise.
104774         * tests/test-memmem.c (memmem): Likewise.
104775         * tests/test-memrchr.c (memrchr): Likewise.
104776         * tests/test-mkdir.c (mkdir): Likewise.
104777         * tests/test-mkdirat.c (mkdirat): Likewise.
104778         * tests/test-mkfifo.c (mkfifo): Likewise.
104779         * tests/test-mkfifoat.c (mkfifoat, mknodat): Likewise.
104780         * tests/test-mknod.c (mknod): Likewise.
104781         * tests/test-nanosleep.c (nanosleep): Likewise.
104782         * tests/test-nl_langinfo.c (nl_langinfo): Likewise.
104783         * tests/test-obstack-printf.c (obstack_printf, obstack_vprintf):
104784         Likewise.
104785         * tests/test-open.c (open): Likewise.
104786         * tests/test-openat.c (openat): Likewise.
104787         * tests/test-perror.c (perror): Likewise.
104788         * tests/test-pipe2.c (pipe2): Likewise.
104789         * tests/test-poll.c (poll): Likewise.
104790         * tests/test-popen.c (popen, pclose): Likewise.
104791         * tests/test-posix_spawn1.c (posix_spawnp, posix_spawnattr_init)
104792         (posix_spawnattr_destroy, posix_spawnattr_setsigmask)
104793         (posix_spawnattr_setflags, posix_spawn_file_actions_init)
104794         (posix_spawn_file_actions_destroy)
104795         (posix_spawn_file_actions_addclose)
104796         (posix_spawn_file_actions_addopen)
104797         (posix_spawn_file_actions_adddup2): Likewise.
104798         * tests/test-posix_spawn3.c (posix_spawn): Likewise.
104799         * tests/test-pread.c (pread): Likewise.
104800         * tests/test-printf-posix.c (printf): Likewise.
104801         * tests/test-pty.c (openpty, forkpty): Likewise.
104802         * tests/test-random_r.c (srandom_r, initstate_r, setstate_r)
104803         (random_r): Likewise.
104804         * tests/test-rawmemchr.c (rawmemchr): Likewise.
104805         * tests/test-readlink.c (readlink): Likewise.
104806         * tests/test-remove.c (remove): Likewise.
104807         * tests/test-rename.c (rename): Likewise.
104808         * tests/test-renameat.c (renameat): Likewise.
104809         * tests/test-rmdir.c (rmdir): Likewise.
104810         * tests/test-round1.c (round): Likewise.
104811         * tests/test-roundf1.c (roundf): Likewise.
104812         * tests/test-roundl.c (roundl): Likewise.
104813         * tests/test-setenv.c (setenv): Likewise.
104814         * tests/test-sigaction.c (sigaction): Likewise.
104815         * tests/test-sleep.c (sleep): Likewise.
104816         * tests/test-snprintf.c (snprintf): Likewise.
104817         * tests/test-sprintf-posix.c (sprintf): Likewise.
104818         * tests/test-stat.c (stat): Likewise.
104819         * tests/test-stpncpy.c (stpncpy): Likewise.
104820         * tests/test-strcasestr.c (strcasestr): Likewise.
104821         * tests/test-strchrnul.c (strchrnul): Likewise.
104822         * tests/test-strerror.c (strerror): Likewise.
104823         * tests/test-strsignal.c (strsignal): Likewise.
104824         * tests/test-strstr.c (strstr): Likewise.
104825         * tests/test-strtod.c (strtod): Likewise.
104826         * tests/test-strverscmp.c (strverscmp): Likewise.
104827         * tests/test-symlink.c (symlink): Likewise.
104828         * tests/test-symlinkat.c (symlinkat, readlinkat): Likewise.
104829         * tests/test-times.c (times): Likewise.
104830         * tests/test-trunc1.c (trunc): Likewise.
104831         * tests/test-truncf1.c (truncf): Likewise.
104832         * tests/test-truncl.c (truncl): Likewise.
104833         * tests/test-tsearch.c (tdelete, tfind, tsearch, twalk):
104834         Likewise.
104835         * tests/test-uname.c (uname): Likewise.
104836         * tests/test-unlink.c (unlink): Likewise.
104837         * tests/test-unlinkat.c (unlinkat): Likewise.
104838         * tests/test-unsetenv.c (unsetenv): Likewise.
104839         * tests/test-usleep.c (usleep): Likewise.
104840         * tests/test-utimensat.c (utimensat): Likewise.
104841         * tests/test-vasprintf.c (asprintf, vasprintf): Likewise.
104842         * tests/test-vdprintf-posix.c (vdprintf): Likewise.
104843         * tests/test-vfprintf-posix.c (vfprintf): Likewise.
104844         * tests/test-vprintf-posix.c (vprintf): Likewise.
104845         * tests/test-vsnprintf.c (vsnprintf): Likewise.
104846         * tests/test-vsprintf-posix.c (vsprintf): Likewise.
104847         * tests/test-wcrtomb.c (wcrtomb): Likewise.
104848         * tests/test-wcsnrtombs.c (wcsnrtombs): Likewise.
104849         * tests/test-wcsrtombs.c (wcsrtombs): Likewise.
104850         * tests/test-wcwidth.c (wcwidth): Likewise.
104852         build: pull in conditional headers during GNULIB_POSIXCHECK
104853         * lib/stdio.in.h (includes): Using GNULIB_POSIXCHECK also requires
104854         definitions from any conditionally-included headers.
104855         * lib/stdlib.in.h (includes): Likewise.
104856         * lib/unistd.in.h (includes): Likewise.
104858 2009-12-24  Bruno Haible  <bruno@clisp.org>
104860         * tests/test-argv-iter.c: Include header file being tested immediately
104861         after config.h.
104862         * tests/test-base64.c: Likewise.
104863         * tests/test-flock.c: Likewise.
104864         * tests/test-fsync.c: Likewise.
104865         * tests/test-getdate.c: Likewise.
104866         * tests/test-getndelim2.c: Likewise.
104867         * tests/test-isfinite.c: Likewise.
104868         * tests/test-isinf.c: Likewise.
104869         * tests/test-strerror.c: Likewise.
104870         * tests/test-strsignal.c: Likewise.
104872 2009-12-23  Eric Blake  <ebb9@byu.net>
104874         unistd: work around cygwin bug
104875         * lib/unistd.in.h (includes): Pick up headers needed for cygwin.
104876         * doc/posix-functions/unlinkat.texi (unlinkat): Document the bug.
104877         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
104879 2009-12-23  Bruno Haible  <bruno@clisp.org>
104881         localename: More tests.
104882         * tests/test-localename.c (SIZEOF): New macro.
104883         (categories): New variable.
104884         (test_locale_name, test_locale_name_posix, test_locale_name_environ,
104885         test_locale_name_default): Add test w.r.t. thread locale.
104886         (test_locale_name_thread): New function.
104887         (main): Invoke it.
104889         localename: Make aware of thread locale.
104890         * lib/localename.h (gl_locale_name_thread): New declaration.
104891         (gl_locale_name, gl_locale_name_posix, gl_locale_name_default): Clarify
104892         behaviour with respect to thread locale.
104893         * lib/localename.c: Include <limits.h>, <stddef.h>, <xlocale.h>,
104894         <langinfo.h>, glthread/lock.h.
104895         (SIZE_BITS): New macro.
104896         (string_hash): New function.
104897         (struct hash_node): New type.
104898         (HASH_TABLE_SIZE): New macro.
104899         (struniq_hash_table, struniq_lock): New variables.
104900         (struniq): New function.
104901         (gl_locale_name_thread): New function.
104902         (gl_locale_name): Invoke it.
104903         * m4/localename.m4 (gl_LOCALENAME): Test for uselocale function.
104904         * modules/localename (Depends-on): Add lock.
104905         Reported by Mike Gran <spk121@yahoo.com>.
104907 2009-12-23  Eric Blake  <ebb9@byu.net>
104909         va-args: new module
104910         * modules/va-args: New file.
104911         * m4/va-args.m4 (gl_VA_ARGS): Likewise.
104912         * MODULES.html.sh (Core language properties): Mention it.
104914         gnulib-common: prefer _GL_UNUSED over _UNUSED_PARAMETER_
104915         * m4/gnulib-common.m4 (gl_COMMON): Create a more-appropriately
104916         named alias for __attribute__((__unused__)).
104917         * lib/chown.c: Update client.
104918         * lib/fchmodat.c: Likewise.
104919         * lib/fts.c: Likewise.
104920         * lib/getdate.y: Likewise.
104921         * lib/getgroups.c: Likewise.
104922         * lib/getopt.c: Likewise.
104923         * lib/getugroups.c: Likewise.
104924         * lib/mkdir.c: Likewise.
104925         * lib/mkfifo.c: Likewise.
104926         * lib/mkfifoat.c: Likewise.
104927         * lib/mknod.c: Likewise.
104928         * lib/mknodat.c: Likewise.
104929         * lib/readlink.c: Likewise.
104930         * lib/se-context.in.h: Likewise.
104931         * lib/se-selinux.in.h: Likewise.
104932         * lib/sockets.c: Likewise.
104933         * lib/symlink.c: Likewise.
104934         * lib/symlinkat.c: Likewise.
104935         * lib/unicodeio.c: Likewise.
104936         * lib/unistr.h: Likewise.
104937         * tests/test-areadlink.c: Likewise.
104938         * tests/test-areadlinkat.c: Likewise.
104939         * tests/test-filenamecat.c: Likewise.
104940         * tests/test-fseeko.c: Likewise.
104941         * tests/test-ftello.c: Likewise.
104942         * tests/test-getdate.c: Likewise.
104943         * tests/test-getgroups.c: Likewise.
104944         * tests/test-gethostname.c: Likewise.
104945         * tests/test-quotearg.c: Likewise.
104946         * tests/test-version-etc.c: Likewise.
104947         * tests/test-xalloc-die.c: Likewise.
104948         * tests/test-xfprintf-posix.c: Likewise.
104949         * tests/test-xprintf-posix.c: Likewise.
104950         * tests/test-xvasprintf.c: Likewise.
104952         tests: avoid compiler warnings
104953         * tests/test-fcntl.c (main): Delete unused parameters.
104954         * tests/test-freopen-safer.c (main): Likewise.
104955         * tests/test-xalloc-die.c (main): Mark unused parameters.
104956         * tests/test-fseeko.c (main): Likewise.
104957         * tests/test-ftello.c (main): Likewise.
104958         * tests/test-nanosleep.c (main): Avoid declaration warning.
104959         * tests/test-sleep.c (main): Likewise.
104960         * tests/test-unsetenv.c (main): Silence warning about string
104961         literal.
104962         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
104964 2009-12-23  Bruno Haible  <bruno@clisp.org>
104966         * tests/test-localename.c (test_locale_name): New function, extracted
104967         from main. Also test mixed situations.
104968         (test_locale_name_posix, test_locale_name_environ,
104969         test_locale_name_default): New functions.
104970         (main): Invoke them all.
104971         * modules/localename-tests (configure.ac): Test for newlocale.
104973 2009-12-23  Bruno Haible  <bruno@clisp.org>
104975         unistd: Ensure getcwd gets declared before being overridden.
104976         * lib/unistd.in.h: Conditionally include <io.h>.
104978 2009-12-22  Bruno Haible  <bruno@clisp.org>
104980         wchar: Diagnose broken combination of glibc and gcc versions and flags.
104981         * m4/wchar.m4 (gl_WCHAR_H_INLINE_OK): New macro.
104982         (gl_WCHAR_H): Invoke it.
104983         * m4/btowc.m4 (gl_FUNC_BTOWC): Require it.
104984         * doc/posix-headers/wchar.texi: Mention the interoperability problem.
104985         Reported by Karl Berry <karl@freefriends.org>.
104987 2009-12-22  Eric Blake  <ebb9@byu.net>
104989         math, unistd: avoid redundant includes
104990         * lib/math.in.h (isnan): No need to re-include <math.h>.
104991         * lib/unistd.in.h (getcwd): Likewise, for <stdlib.h>.
104993         getsubopt: work around cygwin bug
104994         * lib/stdlib.in.h (includes): Move unistd inclusion sooner, to
104995         avoid conflicting with system getsubopt.
104996         * doc/posix-functions/getsubopt.texi (getsubopt): Document the
104997         bug.
104999         getopt: synchronize from glibc
105000         * lib/getopt.c (_getopt_initialize, _getopt_internal_r): Swap
105001         parameter order.  Adjust all callers.
105002         (_getopt_internal_r, main): Adjust quoting in error messages.
105003         Drop considerations for outdated POSIX 1003.2 error message.
105004         * lib/getopt1.c (_getopt_long_r, _getopt_long_only_r): Adjust
105005         callers.
105006         * lib/getopt_int.h (_getopt_internal_r): Adjust prototype.
105008         test-getopt: test stderr behavior
105009         * modules/getopt-posix-tests (Depends-on): Add dup2.
105010         * tests/test-getopt.c (ASSERT): Avoid stderr.
105011         (main): Move stderr to a temporary file.
105012         * tests/test-getopt.h (getopt_loop): No longer manipulate opterr.
105013         Instead, add parameter to inform caller if output occurred.
105014         (test_getopt): Adjust all existing tests to expect silence, and
105015         add new tests of leading ":".
105016         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
105017         glibc shortcomings with leading "-:" or "+:" in optstring.
105018         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
105019         Likewise.
105020         * doc/posix-functions/getopt.texi (getopt): Likewise.
105022         test-getopt: enhance test
105023         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require that getopt_long
105024         supports optind=0.
105025         * tests/test-getopt.c (OPTIND_MIN): Move...
105026         * tests/test-getopt.h (OPTIND_MIN): ...here.
105027         * tests/test-getopt_long.h (test_getopt_long): Add more coverage.
105028         Require that optind=0 works, since modern BSD supports it in
105029         addition to optreset, and since coreutils expects it.
105030         (test_getopt_long_only): New test.
105031         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
105032         glibc shortcomings with 'W;', and enforcement of optind=0.
105033         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
105034         Likewise.
105036 2009-12-21  Bruno Haible  <bruno@clisp.org>
105038         localename: Improvements for MacOS X and Cygwin.
105039         * lib/localename.h (gl_locale_name_environ): New declaration.
105040         * lib/localename.c (gl_locale_name_environ): New function, extracted from
105041         gl_locale_name_posix. Ignore dummy LANG values on MacOS X and Cygwin.
105042         (gl_locale_name_posix): Invoke it.
105043         (gl_locale_name_default): Add comments. Use Windows native API also on
105044         Cygwin.
105046 2009-12-21  Bruno Haible  <bruno@clisp.org>
105048         Update list of Win32 locale ids.
105049         * lib/localename.c (LANG_ROMANSH): Renamed from LANG_RHAETO_ROMANCE.
105050         (LANG_SAMI): Renamed from LANG_SAAMI.
105051         (LANG_BASHKIR, LANG_LUXEMBOURGISH, LANG_GREENLANDIC,
105052         LANG_MAPUDUNGUN, LANG_MOHAWK, LANG_BRETON, LANG_OCCITAN, LANG_CORSICAN,
105053         LANG_ALSATIAN, LANG_YAKUT, LANG_KICHE, LANG_KINYARWANDA, LANG_WOLOF,
105054         LANG_DARI, LANG_SCOTTISH_GAELIC): New macros.
105055         (SUBLANG_AFRIKAANS_SOUTH_AFRICA, SUBLANG_ALBANIAN_ALBANIA,
105056         SUBLANG_ALSATIAN_FRANCE, SUBLANG_AMHARIC_ETHIOPIA,
105057         SUBLANG_ARMENIAN_ARMENIA, SUBLANG_ASSAMESE_INDIA,
105058         SUBLANG_BASHKIR_RUSSIA, SUBLANG_BASQUE_BASQUE,
105059         SUBLANG_BELARUSIAN_BELARUS, SUBLANG_BRETON_FRANCE,
105060         SUBLANG_BULGARIAN_BULGARIA, SUBLANG_CAMBODIAN_CAMBODIA,
105061         SUBLANG_CATALAN_SPAIN, SUBLANG_CORSICAN_FRANCE,
105062         SUBLANG_CZECH_CZECH_REPUBLIC, SUBLANG_DANISH_DENMARK,
105063         SUBLANG_DARI_AFGHANISTAN, SUBLANG_DIVEHI_MALDIVES,
105064         SUBLANG_DUTCH_SURINAM, SUBLANG_ESTONIAN_ESTONIA,
105065         SUBLANG_FAEROESE_FAROE_ISLANDS, SUBLANG_FARSI_IRAN,
105066         SUBLANG_FINNISH_FINLAND, SUBLANG_FRISIAN_NETHERLANDS,
105067         SUBLANG_GALICIAN_SPAIN, SUBLANG_GEORGIAN_GEORGIA,
105068         SUBLANG_GREEK_GREECE, SUBLANG_GREENLANDIC_GREENLAND,
105069         SUBLANG_GUJARATI_INDIA, SUBLANG_HAUSA_NIGERIA_LATIN,
105070         SUBLANG_HEBREW_ISRAEL, SUBLANG_HINDI_INDIA, SUBLANG_HUNGARIAN_HUNGARY,
105071         SUBLANG_ICELANDIC_ICELAND, SUBLANG_IGBO_NIGERIA,
105072         SUBLANG_INDONESIAN_INDONESIA, SUBLANG_INUKTITUT_CANADA,
105073         SUBLANG_INUKTITUT_CANADA_LATIN, SUBLANG_IRISH_IRELAND,
105074         SUBLANG_JAPANESE_JAPAN, SUBLANG_KANNADA_INDIA,
105075         SUBLANG_KAZAK_KAZAKHSTAN, SUBLANG_KICHE_GUATEMALA,
105076         SUBLANG_KINYARWANDA_RWANDA, SUBLANG_KONKANI_INDIA,
105077         SUBLANG_KYRGYZ_KYRGYZSTAN, SUBLANG_LAO_LAOS, SUBLANG_LATVIAN_LATVIA,
105078         SUBLANG_LITHUANIAN_LITHUANIA, SUBLANG_LOWER_SORBIAN_GERMANY,
105079         SUBLANG_LUXEMBOURGISH_LUXEMBOURG, SUBLANG_MACEDONIAN_MACEDONIA,
105080         SUBLANG_MALAYALAM_INDIA, SUBLANG_MALTESE_MALTA,
105081         SUBLANG_MAORI_NEW_ZEALAND, SUBLANG_MAPUDUNGUN_CHILE,
105082         SUBLANG_MARATHI_INDIA, SUBLANG_MOHAWK_CANADA, SUBLANG_NEPALI_NEPAL,
105083         SUBLANG_OCCITAN_FRANCE, SUBLANG_ORIYA_INDIA,
105084         SUBLANG_PASHTO_AFGHANISTAN, SUBLANG_POLISH_POLAND,
105085         SUBLANG_ROMANSH_SWITZERLAND, SUBLANG_SAMI_NORTHERN_NORWAY,
105086         SUBLANG_SAMI_NORTHERN_SWEDEN, SUBLANG_SAMI_NORTHERN_FINLAND,
105087         SUBLANG_SAMI_LULE_NORWAY, SUBLANG_SAMI_LULE_SWEDEN,
105088         SUBLANG_SAMI_SOUTHERN_NORWAY, SUBLANG_SAMI_SOUTHERN_SWEDEN,
105089         SUBLANG_SAMI_SKOLT_FINLAND, SUBLANG_SAMI_INARI_FINLAND,
105090         SUBLANG_SANSKRIT_INDIA, SUBLANG_SINHALESE_SRI_LANKA,
105091         SUBLANG_SLOVAK_SLOVAKIA, SUBLANG_SLOVENIAN_SLOVENIA,
105092         SUBLANG_SOTHO_SOUTH_AFRICA, SUBLANG_SWAHILI_KENYA,
105093         SUBLANG_SWEDISH_SWEDEN, SUBLANG_SYRIAC_SYRIA,
105094         SUBLANG_TAGALOG_PHILIPPINES, SUBLANG_TAJIK_TAJIKISTAN,
105095         SUBLANG_TAMIL_INDIA, SUBLANG_TATAR_RUSSIA, SUBLANG_TELUGU_INDIA,
105096         SUBLANG_THAI_THAILAND, SUBLANG_TSWANA_SOUTH_AFRICA,
105097         SUBLANG_TURKISH_TURKEY, SUBLANG_TURKMEN_TURKMENISTAN,
105098         SUBLANG_UKRAINIAN_UKRAINE, SUBLANG_UPPER_SORBIAN_GERMANY,
105099         SUBLANG_VIETNAMESE_VIETNAM, SUBLANG_WELSH_UNITED_KINGDOM,
105100         SUBLANG_WOLOF_SENEGAL, SUBLANG_XHOSA_SOUTH_AFRICA,
105101         SUBLANG_YAKUT_RUSSIA, SUBLANG_YI_PRC, SUBLANG_YORUBA_NIGERIA,
105102         SUBLANG_ZULU_SOUTH_AFRICA): New macros.
105103         (gl_locale_name_from_win32_LANGID): Handle also the territory neutral
105104         locale ids. Add support for Alsatian, Bashkir, Breton, Corsican, Dari,
105105         Greenlandic, K'iche', Kinyarwanda, Luxembourgish, Mapudungun, Mohawk,
105106         Occitan, Scottish Gaelic, Wolof, Yakut. Change language code for Yi.
105107         Add more languages and countries for Sami, Sorbian. Add more countries
105108         for Serbian, Dutch. Add more scripts for Inuktitut. Be more precise
105109         for Pashto. Change country for Syriac, Tswana.
105111 2009-12-21  Eric Blake  <ebb9@byu.net>
105113         test-utimens: avoid spurious failure
105114         * tests/test-chown.h (nap): Factor...
105115         * tests/nap.h: ...into new file.
105116         * tests/test-lchown.h (nap): Avoid duplication.
105117         * tests/test-utimens-common.h (nap): Use shared implementation,
105118         necessary on file systems with 1-second resolution.
105119         * modules/chown-tests (Files): Include new file.
105120         * modules/fdutimensat-tests (Files): Likewise.
105121         * modules/futimens-tests (Files): Likewise.
105122         * modules/lchown-tests (Files): Likewise.
105123         * modules/openat-tests (Files): Likewise.
105124         * modules/utimens-tests (Files): Likewise.
105125         * modules/utimensat-tests (Files): Likewise.
105127 2009-12-19  Eric Blake  <ebb9@byu.net>
105129         futimens, utimensat: work around Linux bug
105130         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Detect ctime bug.
105131         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
105132         * lib/utimensat.c (rpl_utimensat): Work around it.
105133         * lib/futimens.c (rpl_futimens): Adjust comment.
105135         utimens: work around Linux ctime bug
105136         * lib/utimens.c (detect_ctime_bug): New helper function.
105137         (update_timespec): Differentiate between workaround needed for
105138         this bug vs. what is needed for systems that lack utimensat.
105139         (fdutimens, lutimens): Work around bug.
105141         utimens: check for ctime update
105142         * tests/test-utimens-common.h (check_ctime): Define.
105143         * tests/test-utimens.h (test_utimens): Expose the Linux bug.
105144         * tests/test-futimens.h (test_futimens): Likewise.
105145         * tests/test-lutimens.h (test_lutimens): Likewise.
105146         * doc/posix-functions/futimens.texi (futimens): Document the bug.
105147         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
105149 2009-12-19  Bruno Haible  <bruno@clisp.org>
105151         dprintf-posix: Check against memory leak fixed on 2009-12-15.
105152         * tests/test-dprintf-posix2.sh: New file.
105153         * tests/test-dprintf-posix2.c: New file.
105154         * modules/dprintf-posix-tests (Files): Add them.
105155         (configure.ac): Check for getrlimit and setrlimit.
105156         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
105158 2009-12-19  Bruno Haible  <bruno@clisp.org>
105160         fprintf-posix: Check against memory leak fixed on 2009-12-15.
105161         * tests/test-fprintf-posix3.sh: New file.
105162         * tests/test-fprintf-posix3.c: New file.
105163         * modules/fprintf-posix-tests (Files): Add them.
105164         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
105166 2009-12-19  Eric Blake  <ebb9@byu.net>
105168         dirfd: fix prototype
105169         * lib/dirent.in.h (dirfd): Argument is not const, per POSIX.
105170         * lib/dirfd.c (dirfd): Likewise.
105172         canonicalize: reduce memory usage
105173         * lib/canonicalize.c (canonicalize_filename_mode): Trim the
105174         allocation to size.
105175         Reported by Solar Designer <solar@openwall.com>.
105177 2009-12-19  Bruno Haible  <bruno@clisp.org>
105179         New module attribute 'Applicability'.
105180         * modules/TEMPLATE-EXTENDED: New field 'Applicability'.
105181         * gnulib-tool: New option --extract-applicability.
105182         (func_usage): Document it.
105183         (sed_extract_prog): Recognize it.
105184         (func_get_applicability): New function.
105185         (func_import): Generalize handling of 'link-warning' module.
105186         * modules/link-warning (Applicability): New section.
105187         * modules/arg-nonnull (Applicability): New section.
105188         Repoted by Simon Josefsson <simon@josefsson.org>.
105190 2009-12-19  Bruno Haible  <bruno@clisp.org>
105192         fflush: tweak
105193         * lib/fflush.c (update_fpos_cache): Don't use fpos_t on Cygwin.
105194         * lib/fseeko.c (rpl_fseeko): Likewise.
105196 2009-12-16  José E. Marchesi  <jemarch@gnu.org>  (tiny change)
105198         * lib/gl_list.h: Fix typo in comment.
105200 2009-12-16  Eric Blake  <ebb9@byu.net>
105202         fcntl: use to simplify other modules
105203         * modules/cloexec (Depends-on): Add fcntl.
105204         * modules/fchdir (Depends-on): Likewise.
105205         * modules/fd-safer-flag (Depends-on): Likewise.
105206         * modules/unistd-safer (Depends-on): Likewise.
105207         * modules/dup3 (configure.ac): Set module indicator.
105208         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Replace fcntl if fchdir is
105209         missing.
105210         * lib/fchdir.c (_gl_register_dup): Fix comment.
105211         * lib/cloexec.c (dup_cloexec): Simplify, by relying on fcntl.
105212         * lib/dup-safer.c (dup_safer): Likewise.
105213         * lib/dup-safer-flag.c (dup_safer_flag): Likewise.
105214         * lib/dup3.c (dup3): Likewise.
105215         * tests/test-fchdir.c (main): Enhance test.
105216         Fixes a dup_cloexec bug reported by Ondřej Vašík.
105218         fcntl: port portions of fcntl to mingw
105219         * m4/fcntl.m4 (gl_FUNC_FCNTL): Also build fcntl.c on mingw.
105220         * lib/fcntl.c (fcntl) <F_DUPFD, F_DUPFD_CLOEXEC, F_GETFD>: Provide
105221         replacement for mingw.
105222         * modules/fcntl (Description): Update.
105223         (Depends-on): Add dup2.
105224         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness.
105225         * modules/fcntl-h (Makefile.am): Substitute it.
105226         * lib/fcntl.in.h (fcntl): Update declaration.
105227         (F_DUPFD, F_GETFD): New macros, when needed.
105228         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
105229         * doc/posix-functions/fcntl.texi (fcntl): Likewise.
105230         * tests/test-fcntl.c (check_flags, main): Enhance test for items
105231         we now guarantee.
105233         fcntl: work around cygwin bug in F_DUPFD
105234         * m4/fcntl.m4 (gl_REPLACE_FCNTL): New macro.
105235         (gl_FUNC_FCNTL): Use it.  Test for F_DUPFD bug.
105236         * lib/fcntl.c (rpl_fcntl) <F_DUPFD>: Work around it.
105237         <F_DUPFD_CLOEXEC>: Reduce calls to _gl_register_dup.
105238         * doc/posix-functions/fcntl.texi (fcntl): Document it.
105240         fcntl: support F_DUPFD_CLOEXEC on systems with fcntl
105241         * modules/fcntl (Files): List new files.
105242         (configure.ac): Run a test.
105243         * m4/fcntl.m4 (gl_FUNC_FCNTL): New file.
105244         * lib/fcntl.c (rpl_fcntl): Likewise.
105245         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness defaults.
105246         (gl_FCNTL_H): Always replace fcntl.h.
105247         * modules/fcntl-h (Makefile.am): Substitute witnesses.
105248         * lib/fcntl.in.h (fcntl): Declare replacement.
105249         (F_DUPFD_CLOEXEC, GNULIB_defined_F_DUPFD_CLOEXEC): New macro when
105250         needed, plus a witness.
105251         * doc/posix-functions/fcntl.texi (fcntl): Document this.
105252         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
105253         * tests/test-fcntl.c: New file.
105254         * modules/fcntl-tests: Likewise.
105256         binary-io: avoid potential compilation warning
105257         * lib/binary-io.h [__DJGPP__]: Avoid null preprocessor
105258         directives.
105260         fflush: avoid compilation error on NetBSD
105261         * lib/fflush.c (update_fpos_cache): Use a union to safely convert
105262         between off_t and fpos_t, since the latter is sometimes a struct.
105263         * lib/fseeko.c (rpl_fseeko): Likewise.
105264         Reported by Alexander Nasonov <alnsn@yandex.ru>.
105266 2009-12-15  Eric Blake  <ebb9@byu.net>
105268         fcntl-h, stdio, sys_ioctl: fix declarations
105269         * lib/stdio.in.h (dprintf): Use of link warning on a variadic
105270         function must not take arguments.
105271         * lib/sys_ioctl.in.h (ioctl): Likewise.
105272         * lib/fcntl.in.h (openat): Likewise.  Declare extern.
105273         (open): Add a link warning.
105275 2009-12-15  Jim Meyering  <meyering@redhat.com>
105277         areadlink, areadlink-with-size: relax license to LGPLv2+
105278         * modules/areadlink (License): Relax to LGPLv2+.
105279         * modules/areadlink-with-size (License): Likewise.
105281 2009-12-15  Joel E. Denny  <jdenny@clemson.edu>
105282             Bruno Haible  <bruno@clisp.org>
105284         *printf: Fix memory leak.
105285         * lib/fprintf.c (fprintf): Free memory allocated by vasnprintf.
105286         * lib/vfprintf.c (vfprintf): Likewise.
105287         * lib/dprintf.c (dprintf): Likewise.
105288         * lib/vdprintf.c (vdprintf): Likewise.
105290 2009-12-14  Eric Blake  <ebb9@byu.net>
105292         accept4: adjust module dependencies
105293         * modules/accept4 (Depends-on): Use fcntl-h, not fcntl.
105295         utimens: one more try at avoiding compiler warning
105296         * lib/utimens.c (lutimens): Lower scope of result.
105298 2009-12-13  Bruno Haible  <bruno@clisp.org>
105300         Move the malloc checking from module 'list' to new module 'xlist'.
105301         * modules/xlist: New file.
105302         * lib/gl_xlist.h: New file.
105303         * lib/gl_xlist.c: New file.
105304         * lib/gl_list.h (gl_list_create_empty, gl_list_create,
105305         gl_list_node_set_value, gl_list_set_at, gl_list_add_first,
105306         gl_list_add_last, gl_list_add_before, gl_list_add_after,
105307         gl_list_nx_add_at, gl_sortedlist_add): Disable declarations.
105308         (gl_list_nx_create_empty, gl_list_nx_create, gl_list_node_nx_set_value,
105309         gl_list_nx_set_at, gl_list_nx_add_first, gl_list_nx_add_last,
105310         gl_list_nx_add_before, gl_list_nx_add_after, gl_list_nx_add_at,
105311         gl_sortedlist_nx_add): New declarations.
105312         (struct gl_list_implementation): Rename and change methods accordingly.
105313         (gl_list_nx_create_empty): Renamed from gl_list_create_empty.
105314         (gl_list_nx_create): Renamed from gl_list_create.
105315         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
105316         (gl_list_nx_set_at): Renamed from gl_list_set_at.
105317         (gl_list_nx_add_first): Renamed from gl_list_add_first.
105318         (gl_list_nx_add_last): Renamed from gl_list_add_last.
105319         (gl_list_nx_add_before): Renamed from gl_list_add_before.
105320         (gl_list_nx_add_after): Renamed from gl_list_add_after.
105321         (gl_list_nx_add_at): Renamed from gl_list_add_at.
105322         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
105323         * lib/gl_list.c (gl_list_nx_create_empty): Renamed from
105324         gl_list_create_empty.
105325         (gl_list_nx_create): Renamed from gl_list_create.
105326         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
105327         (gl_list_nx_set_at): Renamed from gl_list_set_at.
105328         (gl_list_nx_add_first): Renamed from gl_list_add_first.
105329         (gl_list_nx_add_last): Renamed from gl_list_add_last.
105330         (gl_list_nx_add_before): Renamed from gl_list_add_before.
105331         (gl_list_nx_add_after): Renamed from gl_list_add_after.
105332         (gl_list_nx_add_at): Renamed from gl_list_add_at.
105333         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
105334         * lib/gl_array_list.c: Don't include xalloc.h.
105335         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Return
105336         NULL upon out-of-memory.
105337         (gl_array_nx_create): Renamed from gl_array_create. Return NULL upon
105338         out-of-memory.
105339         (gl_array_node_nx_set_value): Renamed from gl_array_node_set_value.
105340         Change return type to 'int'.
105341         (gl_array_nx_set_at): Renamed from gl_array_set_at.
105342         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
105343         (gl_array_nx_add_first): Renamed from gl_array_add_first. Return NULL
105344         upon out-of-memory.
105345         (gl_array_nx_add_last): Renamed from gl_array_add_last. Return NULL
105346         upon out-of-memory.
105347         (gl_array_nx_add_before): Renamed from gl_array_add_before. Return NULL
105348         upon out-of-memory.
105349         (gl_array_nx_add_after): Renamed from gl_array_add_after. Return NULL
105350         upon out-of-memory.
105351         (gl_array_nx_add_at): Renamed from gl_array_add_at. Return NULL upon
105352         out-of-memory.
105353         (gl_array_sortedlist_nx_add): Renamed from gl_array_sortedlist_add.
105354         Update.
105355         (gl_array_list_implementation): Update.
105356         * lib/gl_carray_list.c: Don't include xalloc.h.
105357         (gl_carray_nx_create_empty): Renamed from gl_carray_create_empty.
105358         Return NULL upon out-of-memory.
105359         (gl_carray_nx_create): Renamed from gl_carray_create. Return NULL upon
105360         out-of-memory.
105361         (gl_carray_node_nx_set_value): Renamed from gl_carray_node_set_value.
105362         Change return type to 'int'.
105363         (gl_carray_nx_set_at): Renamed from gl_carray_set_at.
105364         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
105365         (gl_carray_nx_add_first): Renamed from gl_carray_add_first. Return NULL
105366         upon out-of-memory.
105367         (gl_carray_nx_add_last): Renamed from gl_carray_add_last. Return NULL
105368         upon out-of-memory.
105369         (gl_carray_nx_add_at): Renamed from gl_carray_add_at. Return NULL upon
105370         out-of-memory.
105371         (gl_carray_nx_add_before): Renamed from gl_carray_add_before. Update.
105372         (gl_carray_nx_add_after): Renamed from gl_carray_add_after. Update.
105373         (gl_carray_sortedlist_nx_add): Renamed from gl_carray_sortedlist_add.
105374         Update.
105375         (gl_carray_list_implementation): Update.
105376         * lib/gl_anyhash_list2.h (hash_resize): Do nothing upon out-of-memory.
105377         * lib/gl_anylinked_list2.h (gl_linked_nx_create_empty): Renamed from
105378         gl_linked_create_empty. Return NULL upon out-of-memory.
105379         (gl_linked_nx_create): Renamed from gl_linked_create. Return NULL upon
105380         out-of-memory.
105381         (gl_linked_node_nx_set_value): Renamed from gl_linked_node_set_value.
105382         Change return type to 'int'. Return -1 upon out-of-memory.
105383         (gl_linked_nx_set_at): Renamed from gl_linked_set_at. Return NULL upon
105384         out-of-memory.
105385         (gl_linked_nx_add_first): Renamed from gl_linked_add_first. Return NULL
105386         upon out-of-memory.
105387         (gl_linked_nx_add_last): Renamed from gl_linked_add_last. Return NULL
105388         upon out-of-memory.
105389         (gl_linked_nx_add_before): Renamed from gl_linked_add_before. Return
105390         NULL upon out-of-memory.
105391         (gl_linked_nx_add_after): Renamed from gl_linked_add_after. Return NULL
105392         upon out-of-memory.
105393         (gl_linked_nx_add_at): Renamed from gl_linked_add_at. Return NULL upon
105394         out-of-memory.
105395         (gl_linked_sortedlist_nx_add): Renamed from gl_linked_sortedlist_add.
105396         Update.
105397         * lib/gl_linked_list.c: Don't include xalloc.h.
105398         (gl_linked_list_implementation): Update.
105399         * lib/gl_linkedhash_list.c: Don't include xalloc.h.
105400         (add_to_bucket): Change return type to 'int'.
105401         (gl_linkedhash_list_implementation): Update.
105402         * lib/gl_anytree_list1.h (free_subtree): New function.
105403         * lib/gl_anytree_list2.h (gl_tree_nx_create_empty): Renamed from
105404         gl_tree_create_empty. Return NULL upon out-of-memory.
105405         (gl_tree_node_nx_set_value): Renamed from gl_tree_node_set_value.
105406         Change return type to 'int'. Return -1 upon out-of-memory.
105407         (gl_tree_nx_set_at): Renamed from gl_tree_set_at. Return NULL upon
105408         out-of-memory.
105409         (gl_tree_nx_add_at): Renamed from gl_tree_add_at. Update.
105410         (gl_tree_remove_node): New function, moved here from
105411         lib/gl_anyavltree_list2.h and lib/gl_anyrbtree_list2.h.
105412         (gl_tree_sortedlist_nx_add): Renamed from gl_tree_sortedlist_add.
105413         Update.
105414         * lib/gl_anyavltree_list2.h (create_subtree_with_contents): Use
105415         malloc, not xmalloc. Return NULL upon out-of-memory.
105416         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
105417         out-of-memory.
105418         (gl_tree_remove_node_from_tree): New function, extracted from
105419         gl_tree_remove_node.
105420         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
105421         upon out-of-memory.
105422         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
105423         out-of-memory.
105424         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
105425         upon out-of-memory.
105426         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
105427         upon out-of-memory.
105428         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
105429         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents): Use malloc,
105430         not xmalloc. Return NULL upon out-of-memory.
105431         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
105432         out-of-memory.
105433         (gl_tree_remove_node_from_tree): New function, extracted from
105434         gl_tree_remove_node.
105435         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
105436         upon out-of-memory.
105437         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
105438         out-of-memory.
105439         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
105440         upon out-of-memory.
105441         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
105442         upon out-of-memory.
105443         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
105444         * lib/gl_avltree_list.c: Don't include xalloc.h. Include
105445         gl_anytree_list1.h before gl_anyavltree_list2.h.
105446         (gl_avltree_list_implementation): Update.
105447         * lib/gl_rbtree_list.c: Don't include xalloc.h. Include
105448         gl_anytree_list1.h before gl_anyavltree_list2.h.
105449         (gl_rbtree_list_implementation): Update.
105450         * lib/gl_anytreehash_list1.h (add_to_bucket, add_nodes_to_buckets):
105451         Change return type to 'int'. Return -1 upon out-of-memory. Use
105452         __builtin_expect.
105453         * lib/gl_avltreehash_list.c: Don't include xalloc.h.
105454         (gl_avltreehash_list_implementation): Update.
105455         * lib/gl_rbtreehash_list.c: Don't include xalloc.h.
105456         (gl_rbtreehash_list_implementation): Update.
105457         * modules/array-list (Depends-on): Remove xalloc.
105458         * modules/carray-list (Depends-on): Likewise.
105459         * modules/linked-list (Depends-on): Likewise.
105460         * modules/linkedhash-list (Depends-on): Likewise.
105461         * modules/avltree-list (Depends-on): Likewise.
105462         * modules/rbtree-list (Depends-on): Likewise.
105463         * modules/avltreehash-list (Depends-on): Likewise.
105464         * modules/rbtreehash-list (Depends-on): Likewise.
105466         * modules/xsublist: New file.
105467         * lib/gl_xsublist.h: New file.
105468         * lib/gl_xsublist.c: New file.
105469         * lib/gl_sublist.h (gl_sublist_create): Disable declaration.
105470         (gl_sublist_nx_create): New declaration.
105471         * lib/gl_sublist.c: Don't include xalloc.h.
105472         (gl_sublist_nx_create_empty): Renamed from gl_sublist_create_empty.
105473         (gl_sublist_nx_create_fill): Renamed from gl_sublist_create_fill.
105474         (gl_sublist_node_nx_set_value): Renamed from gl_sublist_node_set_value.
105475         Change return type to 'int'. Return -1 upon out-of-memory.
105476         (gl_sublist_nx_set_at): Renamed from gl_sublist_set_at. Return NULL
105477         upon out-of-memory.
105478         (gl_sublist_nx_add_first): Renamed from gl_sublist_add_first. Return
105479         NULL upon out-of-memory.
105480         (gl_sublist_nx_add_last): Renamed from gl_sublist_add_last. Return NULL
105481         upon out-of-memory.
105482         (gl_sublist_nx_add_before): Renamed from gl_sublist_add_before. Return
105483         NULL upon out-of-memory.
105484         (gl_sublist_nx_add_after): Renamed from gl_sublist_add_after. Return
105485         NULL upon out-of-memory.
105486         (gl_sublist_nx_add_at): Renamed from gl_sublist_add_at. Return NULL
105487         upon out-of-memory.
105488         (gl_sublist_sortedlist_nx_add): Renamed from gl_sublist_sortedlist_add.
105489         (gl_sublist_list_implementation): Update.
105490         (gl_sublist_nx_create): Renamed from gl_sublist_create. Return NULL
105491         upon out-of-memory.
105492         * modules/sublist (Depends-on): Remove xalloc.
105494         * tests/test-array_list.c: Use gl_list_nx_* functions where possible.
105495         * tests/test-carray_list.c: Likewise.
105496         * tests/test-linked_list.c: Likewise.
105497         * tests/test-linkedhash_list.c: Likewise.
105498         * tests/test-avltree_list.c: Likewise.
105499         * tests/test-rbtree_list.c: Likewise.
105500         * tests/test-avltreehash_list.c: Likewise.
105501         * tests/test-rbtreehash_list.c: Likewise.
105502         * modules/array-list-tests (Makefile.am): Don't link with @LIBINTL@.
105503         * modules/carray-list-tests (Makefile.am): Likewise.
105504         * modules/linked-list-tests (Makefile.am): Likewise.
105505         * modules/linkedhash-list-tests (Makefile.am): Likewise.
105506         * modules/avltree-list-tests (Makefile.am): Likewise.
105507         * modules/rbtree-list-tests (Makefile.am): Likewise.
105508         * modules/avltreehash-list-tests (Makefile.am): Likewise.
105509         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
105511         * NEWS: Mention the changes.
105513         * lib/clean-temp.c: Include gl_xlist.h.
105514         * modules/clean-temp (Depends-on): Add xlist.
105516         * lib/git-merge-changelog.c: Include gl_xlist.h instead of gl_list.h.
105517         * modules/git-merge-changelog (Depends-on): Add xlist. Remove list.
105519         * tests/test-array_oset.c: Include gl_xlist.h.
105520         * modules/array-oset-tests (Depends-on): Add xlist.
105522         Reported by José E. Marchesi <jemarch@gnu.org>.
105524 2009-12-13  Bruno Haible  <bruno@clisp.org>
105526         Move the malloc checking from module 'oset' to new module 'xoset'.
105527         * modules/xoset: New file.
105528         * lib/gl_xoset.h: New file.
105529         * lib/gl_xoset.c: New file.
105530         * lib/gl_oset.h (gl_oset_create_empty, gl_oset_add): Disable
105531         declarations.
105532         (gl_oset_nx_create_empty, gl_oset_nx_add): New declarations.
105533         (struct gl_oset_implementation): Rename and change methods accordingly.
105534         (gl_oset_nx_create_empty): Renamed from gl_oset_create_empty.
105535         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
105536         'int'. Mark as __warn_unused_result__.
105537         * lib/gl_oset.c (gl_oset_nx_create_empty): Renamed from
105538         gl_oset_create_empty.
105539         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
105540         'int'.
105541         * lib/gl_array_oset.c: Don't include xalloc.h.
105542         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Use
105543         malloc, not xmalloc.
105544         (grow): Change return type to 'int'. Don't call xalloc_die.
105545         (gl_array_nx_add_at): Renamed from gl_array_add_at. Change return type
105546         to 'int'.
105547         (gl_array_nx_add): Renamed from gl_array_add. Change return type to
105548         'int'.
105549         (gl_array_oset_implementation): Update.
105550         * lib/gl_anytree_oset.h (gl_tree_nx_create_empty): Renamed from
105551         gl_tree_create_empty.
105552         (gl_tree_nx_add): Renamed from gl_tree_add. Change return type to
105553         'int'.
105554         * lib/gl_avltree_oset.c: Don't include xalloc.h.
105555         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
105556         xmalloc.
105557         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
105558         not xmalloc.
105559         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
105560         xmalloc.
105561         (gl_avltree_oset_implementation): Update.
105562         * lib/gl_rbtree_oset.c: Don't include xalloc.h.
105563         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
105564         xmalloc.
105565         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
105566         not xmalloc.
105567         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
105568         xmalloc.
105569         (gl_rbtree_oset_implementation): Update.
105570         * modules/array-oset (Depends-on): Remove xalloc.
105571         * modules/avltree-oset (Depends-on): Likewise.
105572         * modules/rbtree-oset (Depends-on): Likewise.
105573         * tests/test-array_oset.c: Use gl_oset_nx_* functions where possible.
105574         * tests/test-avltree_oset.c: Likewise.
105575         * tests/test-rbtree_oset.c: Likewise.
105576         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
105577         * modules/avltree-oset-tests (Makefile.am): Don't link with @LIBINTL@.
105578         * modules/rbtree-oset-tests (Makefile.am): Likewise.
105579         * NEWS: Mention the change.
105581 2009-12-05  Alfred M. Szmidt  <ams@gnu.org>
105583         maint.mk: allow a project to override release-prep commands
105584         * top/maint.mk (alpha, beta, stable): Move release-preparatory
105585         commands into a new rule.
105586         (release-prep): New rule.
105587         (release-prep-hook): New overridable variable.
105589 2009-12-13  Bruno Haible  <bruno@clisp.org>
105591         * lib/localcharset.c (locale_charset): Fix comment about use of GetACP.
105593 2009-12-13  Jim Meyering  <meyering@redhat.com>
105595         maint.mk (null_AM_MAKEFLAGS, built_programs): remove unused definitions
105596         * top/maint.mk (null_AM_MAKEFLAGS, built_programs): Remove definitions.
105598 2009-12-12  Bruno Haible  <bruno@clisp.org>
105600         duplocale: Tweak.
105601         * lib/duplocale.c (rpl_duplocale): Mark categories array as 'const'.
105603 2009-12-12  Karl Berry  <karl@gnu.org>
105605         * config/srclist.txt (strtoll.c): tab changes, no more sync.
105607 2009-12-12  Bruno Haible  <bruno@clisp.org>
105609         * m4/po.m4: Undo incorrect untabification.
105611 2009-12-12  Bruno Haible  <bruno@clisp.org>
105613         c-strtod, c-strtold: Use multithread-safe implementation on MacOS X.
105614         * modules/c-strtod (Depends-on): Add locale.
105615         * modules/c-strtold (Depends-on): Likewise.
105617 2009-12-12  Bruno Haible  <bruno@clisp.org>
105619         * lib/localcharset.c (locale_charset): Add comment about use of GetACP.
105621 2009-12-11  Eric Blake  <ebb9@byu.net>
105623         setenv: relax requirement in light of POSIX ruling
105624         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Test handling of "" but
105625         not NULL.
105626         * tests/test-setenv.c (main): Relax test.
105627         * tests/test-unsetenv.c (main): Likewise.
105628         * doc/posix-functions/setenv.texi (setenv): Document this.
105629         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
105631 2009-12-11  Bruno Haible  <bruno@clisp.org>
105633         New module 'fd-safer-flag'.
105634         * lib/dup-safer-flag.c: New file, extracted from lib/dup-safer.c.
105635         * lib/dup-safer.c (dup_safer_flag): Remove function.
105636         * lib/fd-safer-flag.c: New file, extracted from lib/fd-safer.c.
105637         * lib/fd-safer.c (fd_safer_flag): Remove function.
105638         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): Update condition.
105639         * modules/cloexec (configure.ac): Drop indicator macro.
105640         * modules/fd-safer-flag: New file.
105641         * modules/pipe2-safer (Depends-on): Add fd-safer-flag. Remove cloexec.
105642         * modules/stdlib-safer (Depends-on): Add fd-safer-flag.
105643         * modules/unistd-safer-tests (Depends-on): Add fd-safer-flag.
105645 2009-12-11  Bruno Haible  <bruno@clisp.org>
105647         Tests for module 'nl_langinfo'.
105648         * modules/nl_langinfo-tests: New file.
105649         * tests/test-nl_langinfo.sh: New file.
105650         * tests/test-nl_langinfo.c: New file.
105652         New module 'nl_langinfo'.
105653         * lib/nl_langinfo.c: New file.
105654         * m4/nl_langinfo.m4: New file.
105655         * modules/nl_langinfo: New file.
105656         * doc/posix-functions/nl_langinfo.texi: Mention the new module.
105658 2009-12-11  Bruno Haible  <bruno@clisp.org>
105660         Tests for module 'langinfo'.
105661         * modules/langinfo-tests: New file.
105662         * tests/test-langinfo.c: New file.
105664         New module 'langinfo'.
105665         * lib/langinfo.in.h: New file.
105666         * m4/langinfo_h.m4: New file.
105667         * modules/langinfo: New file.
105668         * doc/posix-headers/langinfo.texi: Mention the new module.
105670 2009-12-11  Bruno Haible  <bruno@clisp.org>
105672         * lib/config.charset: Untabify.
105674 2009-12-11  Bruno Haible  <bruno@clisp.org>
105676         * modules/unistd-safer (configure.ac): Drop indicator macro.
105678 2009-12-11  Bruno Haible  <bruno@clisp.org>
105680         Move pipe2-safer code to its own file.
105681         * lib/pipe2-safer.c: New file, extracted from lib/pipe-safer.c.
105682         * lib/pipe-safer.c (pipe2_safer): Remove function.
105683         * modules/pipe2-safer (Files): Add lib/pipe2-safer.c.
105684         (Makefile.am): Add it to lib_SOURCES.
105686 2009-12-10  Bruno Haible  <bruno@clisp.org>
105688         * lib/recvfrom.c (rpl_recvfrom): Allow the from argument to be NULL.
105690 2009-12-10  Bruno Haible  <bruno@clisp.org>
105692         Declare which arguments expect non-NULL values, for GCC and clang.
105693         * build-aux/arg-nonnull.h: New file.
105694         * modules/arg-nonnull: New file.
105695         * lib/arpa_inet.in.h (_GL_ARG_NONNULL): New placeholder.
105696         (inet_ntop, inet_pton): Use it.
105697         * lib/dirent.in.h (_GL_ARG_NONNULL): New placeholder.
105698         (closedir, dirfd, opendir, scandir, alphasort): Use it.
105699         * lib/fcntl.in.h (_GL_ARG_NONNULL): New placeholder.
105700         (open, openat): Use it.
105701         * lib/fnmatch.in.h (_GL_ARG_NONNULL): New placeholder.
105702         (fnmatch): Use it.
105703         * lib/getopt.in.h (_GL_ARG_NONNULL): New placeholder.
105704         (getopt, getopt_long, getopt_long_only): Use it.
105705         * lib/glob.in.h (_GL_ARG_NONNULL): New placeholder.
105706         * lib/glob-libc.h (glob, globfree, glob64, globfree64, glob_pattern_p):
105707         Use it.
105708         * lib/iconv.in.h (_GL_ARG_NONNULL): New placeholder.
105709         (iconv_open): Use it.
105710         * lib/inttypes.in.h (_GL_ARG_NONNULL): New placeholder.
105711         (strtoimax, strtoumax): Use it.
105712         * lib/locale.in.h (_GL_ARG_NONNULL): New placeholder.
105713         (duplocale): Use it.
105714         * lib/math.in.h (_GL_ARG_NONNULL): New placeholder.
105715         (frexp, frexpl): Use it.
105716         * lib/netdb.in.h (_GL_ARG_NONNULL): New placeholder.
105717         (getaddrinfo, freeaddrinfo, getnameinfo): Use it.
105718         * lib/search.in.h (_GL_ARG_NONNULL): New placeholder.
105719         (tsearch, tfind, tdelete, twalk): Use it.
105720         * lib/signal.in.h (_GL_ARG_NONNULL): New placeholder.
105721         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset,
105722         sigpending): Use it.
105723         * lib/spawn.in.h (_GL_ARG_NONNULL): New placeholder.
105724         (posix_spawn, posix_spawnp, posix_spawnattr_init,
105725         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
105726         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
105727         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
105728         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
105729         posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy,
105730         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
105731         posix_spawnattr_setschedparam, posix_spawn_file_actions_init,
105732         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addopen,
105733         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
105734         Use it.
105735         * lib/stdio.in.h (_GL_ARG_NONNULL): New placeholder.
105736         (dprintf, fclose, fopen, fprintf, fpurge, fputc, fputs, freopen,
105737         rpl_fseek, fseeko, rpl_ftell, ftello, fwrite, getdelim, getline,
105738         obstack_printf, obstack_vprintf, popen, printf, putc, puts, remove,
105739         rename, renameat, snprintf, sprintf, asprintf, vasprintf, vdprintf,
105740         vfprintf, vprintf, vsnprintf, vsprintf): Use it.
105741         * lib/stdlib.in.h (_GL_ARG_NONNULL): New placeholder.
105742         (atoll, canonicalize_file_name, getloadavg, getsubopt, mkdtemp,
105743         mkostemp, mkostemps, mkstemp, mkstemps, putenv, srandom_r, initstate_r,
105744         setstate_r, random_r, realpath, rpmatch, setenv, strtod, strtoll,
105745         strtoull, unsetenv): Use it.
105746         * lib/string.in.h (_GL_ARG_NONNULL): New placeholder.
105747         (memchr, memmem, mempcpy, memrchr, rawmemchr, stpcpy, stpncpy,
105748         strchrnul, strdup, strndup, strnlen, strpbrk, strsep, strstr,
105749         strcasestr, strtok_r, mbslen, mbsnlen, mbschr, mbsrchr, mbsstr,
105750         mbscasecmp, mbsncasecmp, mbspcasecmp, mbscasestr, mbscspn, mbspbrk,
105751         mbsspn, mbssep, mbstok_r, strverscmp): Use it.
105752         * lib/strings.in.h (_GL_ARG_NONNULL): New placeholder.
105753         (strcasecmp, strncasecmp): Use it.
105754         * lib/sys_socket.in.h (_GL_ARG_NONNULL): New placeholder.
105755         (rpl_connect, rpl_bind, rpl_getpeername, rpl_getsockname,
105756         rpl_getsockopt, rpl_recv, rpl_send, rpl_recvfrom, rpl_sendto,
105757         rpl_setsockopt): Use it.
105758         * lib/sys_stat.in.h (_GL_ARG_NONNULL): New placeholder.
105759         (fchmodat, fstat, fstatat, lchmod, rpl_lstat, mkdir, mkdirat, mkfifo,
105760         mkfifoat, mknod, mknodat, stat, utimensat): Use it.
105761         * lib/sys_time.in.h (_GL_ARG_NONNULL): New placeholder.
105762         (gettimeofday): Use it.
105763         * lib/sys_times.in.h (_GL_ARG_NONNULL): New placeholder.
105764         (times): Use it.
105765         * lib/sys_utsname.in.h (_GL_ARG_NONNULL): New placeholder.
105766         (uname): Use it.
105767         * lib/time.in.h (_GL_ARG_NONNULL): New placeholder.
105768         (nanosleep, mktime, localtime_r, gmtime_r, strptime, timegm): Use it.
105769         * lib/unistd.in.h (_GL_ARG_NONNULL): New placeholder.
105770         (chown, euidaccess, faccessat, _gl_register_fd, fchownat,
105771         getdomainname, gethostname, getlogin_r, lchown, link, linkat, pipe2,
105772         pread, readlink, readlinkat, rmdir, symlink, symlinkat, unlink,
105773         unlinkat, write): Use it.
105774         * lib/wchar.in.h (_GL_ARG_NONNULL): New placeholder.
105775         (mbsrtowcs, mbsnrtowcs, wcsrtombs, wcsnrtombs): Use it.
105776         * lib/argv-iter.h: Include arg-nonnull.h.
105777         (_ATTRIBUTE_NONNULL_): Remove macro.
105778         (argv_iter_init_argv, argv_iter_init_stream, argv_iter,
105779         argv_iter_n_args, argv_iter_free): Use _GL_ARG_NONNULL.
105780         * lib/canonicalize-lgpl.c (_GL_ARG_NONNULL): Define, to defeat gcc
105781         optimization.
105782         * lib/getaddrinfo.c (_GL_ARG_NONNULL): Likewise.
105783         * lib/getdelim.c (_GL_ARG_NONNULL): Likewise.
105784         * lib/glob.c (_GL_ARG_NONNULL): Likewise.
105785         * lib/random_r.c (_GL_ARG_NONNULL): Likewise.
105786         * lib/setenv.c (_GL_ARG_NONNULL): Likewise.
105787         * lib/strtod.c (_GL_ARG_NONNULL): Likewise.
105788         * lib/tsearch.c (_GL_ARG_NONNULL): Likewise.
105789         * lib/unsetenv.c (_GL_ARG_NONNULL): Likewise.
105790         * modules/arpa_inet (Depends-on): Add arg-nonnull.
105791         (Makefile.am): Insert arg-nonnull.h into arpa/inet.h.
105792         * modules/dirent (Depends-on): Add arg-nonnull.
105793         (Makefile.am): Insert arg-nonnull.h into dirent.h.
105794         * modules/fcntl-h (Depends-on): Add arg-nonnull.
105795         (Makefile.am): Insert arg-nonnull.h into fcntl.h.
105796         * modules/fnmatch (Depends-on): Add arg-nonnull.
105797         (Makefile.am): Insert arg-nonnull.h into fnmatch.h.
105798         * modules/getopt-posix (Depends-on): Add arg-nonnull.
105799         (Makefile.am): Insert arg-nonnull.h into getopt.h.
105800         * modules/glob (Depends-on): Add arg-nonnull.
105801         (Makefile.am): Insert arg-nonnull.h into glob.h.
105802         * modules/iconv_open (Depends-on): Add arg-nonnull.
105803         (Makefile.am): Insert arg-nonnull.h into iconv.h.
105804         * modules/inttypes (Depends-on): Add arg-nonnull.
105805         (Makefile.am): Insert arg-nonnull.h into inttypes.h.
105806         * modules/locale (Depends-on): Add arg-nonnull.
105807         (Makefile.am): Insert arg-nonnull.h into locale.h.
105808         * modules/math (Depends-on): Add arg-nonnull.
105809         (Makefile.am): Insert arg-nonnull.h into math.h.
105810         * modules/netdb (Depends-on): Add arg-nonnull.
105811         (Makefile.am): Insert arg-nonnull.h into netdb.h.
105812         * modules/search (Depends-on): Add arg-nonnull.
105813         (Makefile.am): Insert arg-nonnull.h into search.h.
105814         * modules/signal (Depends-on): Add arg-nonnull.
105815         (Makefile.am): Insert arg-nonnull.h into signal.h.
105816         * modules/spawn (Depends-on): Add arg-nonnull.
105817         (Makefile.am): Insert arg-nonnull.h into spawn.h.
105818         * modules/stdio (Depends-on): Add arg-nonnull.
105819         (Makefile.am): Insert arg-nonnull.h into stdio.h.
105820         * modules/stdlib (Depends-on): Add arg-nonnull.
105821         (Makefile.am): Insert arg-nonnull.h into stdlib.h.
105822         * modules/string (Depends-on): Add arg-nonnull.
105823         (Makefile.am): Insert arg-nonnull.h into string.h.
105824         * modules/strings (Depends-on): Add arg-nonnull.
105825         (Makefile.am): Insert arg-nonnull.h into strings.h.
105826         * modules/sys_socket (Depends-on): Add arg-nonnull.
105827         (Makefile.am): Insert arg-nonnull.h into sys/socket.h.
105828         * modules/sys_stat (Depends-on): Add arg-nonnull.
105829         (Makefile.am): Insert arg-nonnull.h into sys/stat.h.
105830         * modules/sys_time (Depends-on): Add arg-nonnull.
105831         (Makefile.am): Insert arg-nonnull.h into sys/time.h.
105832         * modules/sys_times (Depends-on): Add arg-nonnull.
105833         (Makefile.am): Insert arg-nonnull.h into sys/times.h.
105834         * modules/sys_utsname (Depends-on): Add arg-nonnull.
105835         (Makefile.am): Insert arg-nonnull.h into sys/utsname.h.
105836         * modules/time (Depends-on): Add arg-nonnull.
105837         (Makefile.am): Insert arg-nonnull.h into time.h.
105838         * modules/unistd (Depends-on): Add arg-nonnull.
105839         (Makefile.am): Insert arg-nonnull.h into unistd.h.
105840         * modules/wchar (Depends-on): Add arg-nonnull.
105841         (Makefile.am): Insert arg-nonnull.h into wchar.h.
105842         * modules/argv-iter (Depends-on): Add arg-nonnull.
105843         * tests/test-canonicalize.c (null_ptr): New function.
105844         (main): Use it.
105845         * tests/test-canonicalize-lgpl.c (null_ptr): New function.
105846         (main): Use it.
105847         * tests/test-memmem.c (null_ptr): New function.
105848         (main): Use it.
105849         Reported by Jim Meyering.
105851 2009-12-10  Bruno Haible  <bruno@clisp.org>
105853         Use spaces for indentation, not tabs.
105854         * lib/**/*.[hcy] except lib/reg*.[hc]: Untabify.
105855         * m4/*.m4: Untabify.
105856         * build-aux/*.h: Untabify.
105857         * tests/**/*.[hc]: Untabify.
105858         * README: New section "Indent with spaces, not TABs", based on
105859         coreutils/HACKING and comments by Pádraig Brady and Paolo Bonzini.
105860         * NEWS: Mention the change.
105862 2009-12-10  Bruno Haible  <bruno@clisp.org>
105864         pty test: Fix link error.
105865         * modules/pty-tests (Makefile.am): Add the default LDADD value to
105866         test_pty_LDADD.
105868 2009-12-07  Simon Josefsson  <simon@josefsson.org>
105870         * modules/pty: New file.
105871         * modules/pty-tests: New file.
105872         * m4/pty.m4: New file.
105873         * tests/test-pty.c: New file.
105874         * doc/glibc-headers/pty.texi: Modified.
105875         * doc/glibc-functions/forkpty.texi: Modified.
105876         * doc/glibc-functions/openpty.texi: Modified.
105878 2009-12-10  Bruno Haible  <bruno@clisp.org>
105880         Avoid syntax error in C++ mode.
105881         * lib/stdio.in.h (rename): Don't use parameter name 'new'.
105883 2009-12-10  Bruno Haible  <bruno@clisp.org>
105885         Use sed with option -e.
105886         * gnulib-tool (func_version, func_emit_copyright_notice,
105887         func_emit_initmacro_end, func_import, func_create_testdir): Pass
105888         option -e to sed.
105889         * modules/link-warning (Makefile.am): Likewise.
105891 2009-12-10  Jim Meyering  <meyering@redhat.com>
105893         mgetgroups: do not write bytes beyond end of malloc'd buffer
105894         * lib/mgetgroups.c: Fix an off-by-one error.  When we have no
105895         username, we call getgroups with a one-element-shorter buffer,
105896         but still told it the length was original, max_n_groups.
105898 2009-12-09  Eric Blake  <ebb9@byu.net>
105900         cloexec: relax license
105901         * modules/cloexec (Maintainer): Add myself.
105902         (License): Use LGPL, not GPL.
105904         link-warning: optimize generation
105905         * modules/link-warning (Makefile.am): Reduce process usage.
105907 2009-12-09  Bruno Haible  <bruno@clisp.org>
105909         * doc/posix-functions/unsetenv.texi: Mention Solaris 10 bug for which a
105910         workaround was added on 2009-11-17.
105912 2009-12-09  Jim Meyering  <meyering@redhat.com>
105913             Bruno Haible  <bruno@clisp.org>
105915         link-warning: Allow extra lines at the top of build-aux/link-warning.h.
105916         * modules/link-warning (Makefile.am): Make the comment-removing sed
105917         command more robust in the face of bootstrap-prepended comment lines.
105919 2009-12-09  Bruno Haible  <bruno@clisp.org>
105921         * lib/mgetgroups.c (mgetgroups): Don't remove duplicates if there is at
105922         most one group.
105924 2009-12-09  Simon Josefsson  <simon@josefsson.org>
105925             Bruno Haible  <bruno@clisp.org>
105927         * build-aux/link-warning.h: Add copyright notice.
105928         * modules/link-warning (Makefile.am): Generate link-warning.h from
105929         build-aux/link-warning.h. Update LINK_WARNING_H accordingly.
105930         * NEWS: Mention change in link-warning module.
105931         * modules/arpa_inet (Makefile.am): Add dependency to arpa/inet.h.
105932         * modules/dirent (Makefile.am): Add dependency to dirent.h.
105933         * modules/fcntl-h (Makefile.am): Add dependency to fcntl.h.
105934         * modules/getopt-posix (Makefile.am): Add dependency to getopt.h.
105935         * modules/inttypes (Makefile.am): Add dependency to inttypes.h.
105936         * modules/math (Makefile.am): Add dependency to math.h.
105937         * modules/search (Makefile.am): Add dependency to search.h.
105938         * modules/signal (Makefile.am): Add dependency to signal.h.
105939         * modules/spawn (Makefile.am): Add dependency to spawn.h.
105940         * modules/stdio (Makefile.am): Add dependency to stdio.h.
105941         * modules/stdlib (Makefile.am): Add dependency to stdlib.h.
105942         * modules/string (Makefile.am): Add dependency to string.h.
105943         * modules/strings (Makefile.am): Add dependency to strings.h.
105944         * modules/sys_ioctl (Makefile.am): Add dependency to sys/ioctl.h.
105945         * modules/sys_select (Makefile.am): Add dependency to sys/select.h.
105946         * modules/sys_socket (Makefile.am): Add dependency to sys/socket.h.
105947         * modules/sys_stat (Makefile.am): Add dependency to sys/stat.h.
105948         * modules/sys_times (Makefile.am): Add dependency to sys/times.h.
105949         * modules/sys_utsname (Makefile.am): Add dependency to sys/utsname.h.
105950         * modules/sys_wait (Makefile.am): Add dependency to sys/wait.h.
105951         * modules/unistd (Makefile.am): Add dependency to unistd.h.
105952         * modules/wchar (Makefile.am): Add dependency to wchar.h.
105954 2009-12-09  Bruno Haible  <bruno@clisp.org>
105956         fchdir: Optimize away rpl_fstat when possible.
105957         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set REPLACE_FSTAT only together with
105958         REPLACE_OPEN_DIRECTORY.
105959         * lib/fchdir.c (rpl_fstat): Define only when REPLACE_OPEN_DIRECTORY.
105961 2009-12-09  Bruno Haible  <bruno@clisp.org>
105963         * lib/fchdir.c: Update comment.
105965 2009-12-09  Bruno Haible  <bruno@clisp.org>
105967         * lib/cloexec.c (set_cloexec_flag): Clarify intent of dup2 call.
105969 2009-12-08  Eric Blake  <ebb9@byu.net>
105971         fchdir: avoid memory leak on re-registration.
105972         * lib/fchdir.c (ensure_dirs_slot): Avoid memory leak.
105974 2009-12-08  Jim Meyering  <meyering@redhat.com>
105976         init.sh: avoid Solaris 10 /bin/sh portability problem
105977         Solaris 10's /bin/sh does not pass '.' arguments 2.. to the
105978         sourced script:
105979           $ printf 'echo "$@"\n' > f; /bin/sh -c '. ./f bar'
105980           $ printf 'echo "$@"\n' > f; /bin/bash -c '. ./f bar'
105981           bar
105982         tests/init.sh relied on that, accepting a --set-path=DIR argument,
105983         and two tests used that idiom.
105984         * tests/init.sh: Update suggested usage comments.
105985         (path_prepend_): New function, to be used in place
105986         of the --src-path=DIR option.
105987         (setup_): Move PATH-prepending code into path_prepend_.
105988         * tests/test-pread.sh: Adapt to new usage.
105989         * tests/test-xalloc-die.sh: Likewise.
105991 2009-12-08  Simon Josefsson  <simon@josefsson.org>
105993         * doc/gnulib.texi (Glibc pty.h): Add.
105994         * doc/glibc-functions/forkpty.texi: Add.
105995         * doc/glibc-functions/openpty.texi: Add.
105996         Suggested by Bruno Haible.
105998 2009-12-08  Eric Blake  <ebb9@byu.net>
106000         fchdir: fix logic bugs
106001         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Fix logic bug.
106002         * tests/test-fchdir.c (main): Enhance test.
106003         * lib/fchdir.c (rpl_fstat): Always provide if fchdir replacement
106004         is in use.
106006         dup2: fix logic bugs
106007         * lib/dup2.c (dup2): Fix logic bugs.  Use HAVE_DUP2 rather than
106008         REPLACE_DUP2 to decide when rpl_dup2 is needed.
106009         * m4/dup2.m4 (gl_REPLACE_DUP2): Only define REPLACE_DUP2 when dup2
106010         exists.
106011         (gl_FUNC_DUP2): Drop unneeded AC_DEFINE.
106013 2009-12-07  Eric Blake  <ebb9@byu.net>
106015         unlink: fix m4 detection
106016         * m4/unlink.m4 (gl_FUNC_UNLINK): Include correct header.
106018         unistd-safer: add unit test
106019         * modules/unistd-safer-tests: New file.
106020         * tests/test-dup-safer.c: Likewise.
106021         * tests/test-cloexec.c (setmode): Avoid compiler warning.
106022         * tests/test-dup2.c (setmode): Likewise.
106023         * lib/cloexec.c (dup_cloexec): Fix mingw compile error.
106025         cloexec: preserve text vs. binary across dup_cloexec
106026         * lib/cloexec.c (dup_cloexec) [W32]: Query and use translation
106027         mode.
106028         * modules/dup2-tests (Depends-on): Add binary-io.
106029         * modules/cloexec-tests (Depends-on): Likewise.
106030         * tests/test-dup2.c (setmode, is_mode): New helpers.
106031         (main): Add tests that translation mode is preserved.
106032         * tests/test-cloexec.c (setmode, is_mode, main): Likewise.
106033         Reported by Bruno Haible.
106035         mgetgroups: reduce duplicate listings
106036         * lib/mgetgroups.c (mgetgroups): Reduce duplicates from the
106037         resulting array.
106038         * tests/test-chown.h (test_chown): Simplify client.
106039         * tests/test-lchown.h (test_lchown): Likewise.
106041 2009-12-06  Bruno Haible  <bruno@clisp.org>
106043         * lib/cloexec.c (dup_cloexec): Fix handling of _gl_register_dup return
106044         value.
106046 2009-12-06  Bruno Haible  <bruno@clisp.org>
106048         * lib/progname.c: Include stdio.h, stdlib.h.
106049         (set_program_name): Reject a NULL argument.
106051 2009-12-05  Eric Blake  <ebb9@byu.net>
106053         pipe2-safer: new module
106054         * modules/pipe2-safer: New file.
106055         * lib/unistd-safer.h (pipe2_safer): New prototype.
106056         * lib/unistd--.h (pipe2): New wrapper.
106057         * lib/pipe-safer.c (pipe2_safer): New function.
106058         * modules/pipe (Depends-on): Add pipe2-safer.
106059         * lib/pipe.c (create_pipe) [WIN32]: Let pipe2_safer do the work.
106061         stdlib-safer: preserve cloexec flag for mkostemp[s]
106062         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer): Use new
106063         fd_safer_flag.
106065         unistd-safer: allow preservation of cloexec status via flag
106066         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): New
106067         prototypes.
106068         * lib/dup-safer.c (dup_safer_flag): New function.
106069         * lib/fd-safer.c (fd_safer_flag): Likewise.
106070         * modules/cloexec (configure.ac): Set witness.
106072         test-dup2: enhance test
106073         * modules/dup2-tests (Depends-on): Add cloexec.
106074         * tests/test-dup2.c (main): Enhance test.
106076         cloexec: add dup_cloexec
106077         * lib/cloexec.h (dup_cloexec): New prototype.  Add copyright
106078         header and comments.
106079         * lib/cloexec.c (set_cloexec_flag): Add comments.
106080         (dup_cloexec): New function, with mingw implementation borrowed
106081         from...
106082         * lib/w32spawn.h (dup_noinherit): ...here.
106083         * modules/execute (Depends-on): Add cloexec.
106084         * modules/pipe (Depends-on): Likewise.
106085         * modules/cloexec (Depends-on): Add dup2.
106086         * modules/cloexec-tests (Files): New file.
106087         * tests/test-cloexec.c: Likewise.
106089         test-xalloc-die: fix test for mingw
106090         * modules/xalloc-die-tests (Files): Add tests/init.sh.
106091         * tests/test-xalloc-die.sh: Rewrite to use init.sh.  Strip
106092         directory and .exe suffix off argv[0] output.
106094         test-fseeko: fix test for mingw
106095         * tests/test-fseeko.c (fseek): Redefine GL_LINK_WARNING, rather
106096         than undefining fseek, so test will pass on mingw.
106098 2009-12-05  Bruno Haible  <bruno@clisp.org>
106100         * lib/progname.h (set_program_name): Clarify specification.
106101         * lib/progname.c (set_program_name): Likewise.
106102         Reported by Jim Meyering.
106104 2009-12-05  Jim Meyering  <meyering@redhat.com>
106106         maint.mk: backslash-escape parens in default regexp
106107         * top/maint.mk (news-check-regexp): Now that we're using grep -E,
106108         backslash-escape the literal parentheses.
106110         maint.mk: news-date-check: use grep -E
106111         * top/maint.mk (today): Define a Make variable, not a...
106112         (news-date-check): ...shell variable.
106113         (news-date-regexp): Use the Make variable.
106114         Use grep's -E option.  Change the failing diagnostic to mention
106115         the variable, $(news-date-regexp).
106117 2009-12-04  Alfred M. Szmidt  <ams@gnu.org>
106119         maintainer-makefile: allow customization of NEWS entry format
106120         * top/maint.mk (news-date-regexp): New overridable variable.
106121         (news-date-check): Use it.
106123 2009-12-04  Eric Blake  <ebb9@byu.net>
106125         mgetgroups: add xgetgroups, and avoid ENOSYS failures
106126         * lib/mgetgroups.h (xgetgroups): New prototype.
106127         * lib/mgetgroups.c (xgetgroups): New wrapper.
106128         (mgetgroups): Handle ENOSYS.
106129         * modules/mgetgroups (Depends-on): Add realloc.
106130         Reported by Scott Harrison <scott.gnu.2009@scottrix.co.uk>.
106132         mgetgroups: avoid argument promotion issues with -1
106133         * lib/mgetgroups.c (mgetgroups): A cast is required when checking
106134         for invalid gid_t.
106135         * tests/test-chown.h (getegid, test_chown): Likewise.
106136         * tests/test-lchown.h (getegid, test_lchown): Likewise.
106138 2009-12-03  Paolo Bonzini  <bonzini@gnu.org>
106140         exclude: Fix header file problems.
106141         * lib/exclude.h: Add multiple inclusion guards and include stdbool.h.
106143 2009-12-01  Jim Meyering  <meyering@redhat.com>
106145         fts: fts_open: do not let an empty string cause immediate failure
106146         This is required in support of GNU rm, for which the command
106147         "rm A '' B" must process and remove both A and B, in spite of
106148         the empty string argument.
106149         * lib/fts.c (fts_open): Do not let the presence of an empty string
106150         cause fts_open to fail immediately.  Most fts-using tools must be
106151         able to process all arguments, in order, and can be expected to
106152         diagnose such arguments themselves.
106154 2009-11-30  Eric Blake  <ebb9@byu.net>
106156         utimens: fix compilation error
106157         * lib/utimens.c (lutimens) [!HAVE_UTIMENSAT && HAVE_LUTIMES]:
106158         Declare variable at right scope.
106160 2009-11-29  Jim Meyering  <meyering@redhat.com>
106162         bootstrap: handle perl-5.11's changed --version output
106163         * build-aux/bootstrap (get_version): Handle perl separately,
106164         since perl-5.11's --version output is different.
106166 2009-11-28  Jim Meyering  <meyering@redhat.com>
106168         userspec: depend on the inttostr module, too
106169         * modules/userspec (Depends-on): Add inttostr.
106171         userspec: disallow an ID that maps to (uid_t)-1 or (gid_t)-1
106172         * lib/userspec.c (parse_with_separator): Do not accept a user ID
106173         number of MAXUID when it evaluates to (uid_t) -1.
106174         Likewise for group ID.  Reported by Matt McCutchen in
106175         <http://savannah.gnu.org/bugs/?28113>
106177         userspec: reformat to use spaces, not TABs
106178         * lib/userspec.c: Expand TABs to spaces.
106179         Add Emacs' "indent-tabs-mode: nil" hint.
106181 2009-11-27  Eric Blake  <ebb9@byu.net>
106183         getopt-gnu: flush out another BSD bug
106184         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Test for the bug.
106185         * tests/test-getopt.c (main): Check POSIXLY_CORRECT first, to
106186         flush out BSD bug.
106187         * tests/test-getopt.h (test_getopt): End lists with NULL.
106188         * tests/test-getopt_long.h (test_getopt_long): Likewise.
106189         (test_getopt_long_posix): Enhance test.
106190         * modules/getopt-posix-tests (Depends-on): Add stdbool.
106191         * doc/glibc-functions/getopt_long.texi (getopt_long): Mention
106192         getopt-gnu.
106193         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
106194         Likewise.
106196 2009-11-27  Simon Josefsson  <simon@josefsson.org>
106198         * modules/idpriv-droptemp-tests (Notice): Fix text.
106200 2009-11-27  Jim Meyering  <meyering@redhat.com>
106202         test-xalloc-die: avoid spurious failure due to libtool argv difference
106203         In a libtool-enabled project, this test would fail due to a difference
106204         in the emitted program name, e.g.,
106205         -test-xalloc-die: memory exhausted
106206         +/tmp/.../tests/.libs/lt-test-xalloc-die: memory exhausted
106207         Use program to avoid that.
106208         * modules/xalloc-die-tests (Depends-on): Add progname.
106209         * tests/test-xalloc-die.c: Include progname.h".
106210         (program_name): Remove decl.
106211         (main): Call set_program_name.
106212         * tests/test-xalloc-die.sh (compare): Remove unnecessary ${EXE}.
106214 2009-11-26  Richard Jones  <rjones@redhat.com>
106216         w32sock: leave win32 error in place.
106217         * lib/w32sock.h (set_winsock_errno): Do not call WSASetLastError.
106219 2009-11-26  Eric Blake  <ebb9@byu.net>
106221         init.sh: suggest to use skip_ and fail_ functions in comments
106222         * tests/init.sh: Add a sentence.
106224 2009-11-25  Bruno Haible  <bruno@clisp.org>
106226         init.sh: add documentation in comments
106227         * tests/init.sh: Add some developer and user documentation.
106229 2009-11-26  Jim Meyering  <meyering@redhat.com>
106231         init.sh: accommodate even those who specify bogus srcdir manually
106232         * tests/init.sh: Normally, srcdir is guaranteed by automake and
106233         configure-time tests to be sanitized, so that there is no need to
106234         use "$srcdir" in Makefile rules and shell scripts.  Using $srcdir
106235         (with no double quotes) suffices.  However, since tests may be
106236         invoked manually, and since you may explicitly set srcdir to the
106237         name of a directory containing spaces, do quote its uses here.
106238         * tests/test-pread.sh: Likewise.
106239         Suggested by Bruno Haible.
106241         test-pread.sh: avoid diagnostics for those who ignore SIGPIPE
106242         * tests/test-pread.sh: Write no data into the pipe, because
106243         test-pread actually reads none.  This avoids a diagnostic,
106244         "bash: echo: write error: Broken pipe", that arises in the unusual
106245         event something is ignoring SIGPIPE, and might be interpreted
106246         as some sort of failure.  Reported by Bruno Haible.
106248 2009-11-25  Jim Meyering  <meyering@redhat.com>
106250         test-pread: cover failure with ESPIPE and EINVAL
106251         * tests/test-pread.c (main): Test for failure, too.
106252         * tests/test-pread.sh: Invoke with stdin on a pipe.
106253         Suggested by Eric Blake.
106255         pread: improvement and fix
106256         * modules/pread (Depends-on): Depend on lseek, for portability to
106257         e.g., mingw.  Suggested by Eric Blake.
106258         * lib/pread.c (__libc_read): Define.  Reported by Richard W.M. Jones.
106260         unistd.in.h: correct declaration of pread
106261         * lib/unistd.in.h: Correct type of "buf" parameter: void*, not char*
106262         Reported by Richard W.M. Jones.
106264         test-pread.sh: distribute the test script
106265         * modules/pread-tests (Files): Include test-pread.sh.
106267         test-pread.sh: clean up
106268         * tests/test-pread.sh: Don't refer to $builddir. Just use equivalent ".".
106269         * modules/pread-tests (TESTS_ENVIRONMENT): Don't export builddir.
106270         That is unnecessary, since it's always ".".
106271         Suggestion from Eric Blake.
106273         test-pread.sh: make executable
106274         * tests/test-pread.sh: Set executable bit.
106275         Reported by Eric Blake.
106277         correct typo in test-pread.sh
106278         * tests/test-pread.sh: Add #! line.
106280         test pread
106281         * tests/test-pread.c: New file.
106282         * tests/test-pread.sh: Likewise.
106283         * modules/pread-tests: Likewise.
106285         pread: new module
106286         * modules/pread: New file.
106287         * lib/unistd.in.h (pread): Define/declare.
106288         * lib/pread.c (pread): New file.
106289         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define defaults.
106290         * modules/unistd (Makefile.am): Substitute witnesses.
106291         * doc/posix-functions/pread.texi (pread): Update.
106292         * MODULES.html.sh: Add pread.
106294 2009-11-25  Jim Meyering  <meyering@redhat.com>
106296         tests/init.sh: new file to be used via most *.sh tests
106297         * tests/init.sh: New file.
106299 2009-11-25  Eric Blake  <ebb9@byu.net>
106301         utimens: work around older Linux failure with symlinks
106302         * lib/utimens.c (lutimensat_works_really): New variable.
106303         (fdutimens, lutimens): Use it to manage kernels that support
106304         nanosecond times on files, but not on symlinks.
106305         Reported by Ondřej Vašík.
106307         utimes: fix configure grammar
106308         * m4/utimes.m4 (gl_FUNC_UTIMES): Delete spurious word.
106310 2009-11-25  Paolo Bonzini  <bonzini@gnu.org>
106312         regex: Fix fastmap for multibyte character ranges.
106313         * lib/regcomp.c (re_compute_fastmap_iter): Add all multibyte lead
106314         characters when a multibyte character range is included.
106316 2009-11-22  Andy Wingo  <wingo@pobox.com>
106318         version-etc: work also with AM_INIT_AUTOMAKE's no-define option
106319         * lib/version-etc.c [!defined PACKAGE]: Define to PACKAGE_TARNAME.
106321 2009-11-24  Bruno Haible  <bruno@clisp.org>
106323         doc: Most *_l functions exist in MacOS X 10.5.
106324         * doc/posix-functions/duplocale.texi: Update platforms list.
106325         * doc/posix-functions/freelocale.texi: Likewise.
106326         * doc/posix-functions/newlocale.texi: Likewise.
106327         * doc/posix-functions/uselocale.texi: Likewise.
106328         * doc/posix-functions/isalnum_l.texi: Likewise.
106329         * doc/posix-functions/isalpha_l.texi: Likewise.
106330         * doc/posix-functions/isblank_l.texi: Likewise.
106331         * doc/posix-functions/iscntrl_l.texi: Likewise.
106332         * doc/posix-functions/isdigit_l.texi: Likewise.
106333         * doc/posix-functions/isgraph_l.texi: Likewise.
106334         * doc/posix-functions/islower_l.texi: Likewise.
106335         * doc/posix-functions/isprint_l.texi: Likewise.
106336         * doc/posix-functions/ispunct_l.texi: Likewise.
106337         * doc/posix-functions/isspace_l.texi: Likewise.
106338         * doc/posix-functions/isupper_l.texi: Likewise.
106339         * doc/posix-functions/iswalnum_l.texi: Likewise.
106340         * doc/posix-functions/iswalpha_l.texi: Likewise.
106341         * doc/posix-functions/iswblank_l.texi: Likewise.
106342         * doc/posix-functions/iswcntrl_l.texi: Likewise.
106343         * doc/posix-functions/iswctype_l.texi: Likewise.
106344         * doc/posix-functions/iswdigit_l.texi: Likewise.
106345         * doc/posix-functions/iswgraph_l.texi: Likewise.
106346         * doc/posix-functions/iswlower_l.texi: Likewise.
106347         * doc/posix-functions/iswprint_l.texi: Likewise.
106348         * doc/posix-functions/iswpunct_l.texi: Likewise.
106349         * doc/posix-functions/iswspace_l.texi: Likewise.
106350         * doc/posix-functions/iswupper_l.texi: Likewise.
106351         * doc/posix-functions/iswxdigit_l.texi: Likewise.
106352         * doc/posix-functions/isxdigit_l.texi: Likewise.
106353         * doc/posix-functions/nl_langinfo_l.texi: Likewise.
106354         * doc/posix-functions/strcasecmp_l.texi: Likewise.
106355         * doc/posix-functions/strcoll_l.texi: Likewise.
106356         * doc/posix-functions/strfmon_l.texi: Likewise.
106357         * doc/posix-functions/strftime_l.texi: Likewise.
106358         * doc/posix-functions/strncasecmp_l.texi: Likewise.
106359         * doc/posix-functions/strxfrm_l.texi: Likewise.
106360         * doc/posix-functions/tolower_l.texi: Likewise.
106361         * doc/posix-functions/toupper_l.texi: Likewise.
106362         * doc/posix-functions/towctrans_l.texi: Likewise.
106363         * doc/posix-functions/towlower_l.texi: Likewise.
106364         * doc/posix-functions/towupper_l.texi: Likewise.
106365         * doc/posix-functions/wcscoll_l.texi: Likewise.
106366         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
106367         * doc/posix-functions/wctrans_l.texi: Likewise.
106368         * doc/posix-functions/wctype_l.texi: Likewise.
106369         * doc/glibc-functions/strptime_l.texi: Likewise.
106370         * doc/glibc-functions/strtod_l.texi: Likewise.
106371         * doc/glibc-functions/strtof_l.texi: Likewise.
106372         * doc/glibc-functions/strtol_l.texi: Likewise.
106373         * doc/glibc-functions/strtold_l.texi: Likewise.
106374         * doc/glibc-functions/strtoll_l.texi: Likewise.
106375         * doc/glibc-functions/strtoul_l.texi: Likewise.
106376         * doc/glibc-functions/strtoull_l.texi: Likewise.
106377         * doc/glibc-functions/wcsftime_l.texi: Likewise.
106378         * doc/glibc-functions/wcstod_l.texi: Likewise.
106379         * doc/glibc-functions/wcstof_l.texi: Likewise.
106380         * doc/glibc-functions/wcstol_l.texi: Likewise.
106381         * doc/glibc-functions/wcstold_l.texi: Likewise.
106382         * doc/glibc-functions/wcstoll_l.texi: Likewise.
106383         * doc/glibc-functions/wcstoul_l.texi: Likewise.
106384         * doc/glibc-functions/wcstoull_l.texi: Likewise.
106386 2009-11-24  Bruno Haible  <bruno@clisp.org>
106388         duplocale: Fix logic bug.
106389         * lib/duplocale.c: Don't include <langinfo.h>.
106390         (_NL_LOCALE_NAME): Remove macro.
106391         (rpl_duplocale): Use setlocale instead of nl_langinfo.
106392         * tests/test-duplocale.c (main): Also test duplocale after uselocale.
106394 2009-11-23  Jim Meyering  <meyering@redhat.com>
106396         test-update-copyright: don't hard-code /usr/bin/perl
106397         * tests/test-update-copyright.sh (YEAR): Use date +%Y, rather than
106398         perl to print the current year.  Gilles Espinasse reported that
106399         the replaced use of perl was hard-coded as /usr/bin/perl.
106401 2009-11-23  Bruno Haible  <bruno@clisp.org>
106403         duplocale: Add support for glibc 2.3.x.
106404         * lib/duplocale.c (rpl_duplocale): Add fallback code for glibc 2.3.x.
106406 2009-11-22  Bruno Haible  <bruno@clisp.org>
106408         vasnprintf: Tiny optimization.
106409         * lib/vasnprintf.c (decimal_point_char): Choose the fast path also on
106410         MacOS X.
106412 2009-11-22  Bruno Haible  <bruno@clisp.org>
106414         Tests for module 'duplocale'.
106415         * modules/duplocale-tests: New file.
106416         * tests/test-duplocale.c: New file.
106418         New module 'duplocale'.
106419         * m4/duplocale.m4: New file.
106420         * lib/locale.in.h (duplocale): New declaration.
106421         * lib/duplocale.c: New file.
106422         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_MODULE_INDICATOR,
106423         gl_LOCALE_H_DEFAULTS): New macros.
106424         (gl_LOCALE_H): Require gl_LOCALE_H_DEFAULTS. Invoke
106425         gl_CHECK_NEXT_HEADERS unconditionally. Invoke gl_REPLACE_LOCALE_H.
106426         * modules/locale (Makefile.am): Substitute also GNULIB_DUPLOCALE,
106427         REPLACE_DUPLOCALE.
106428         * modules/duplocale: New file.
106429         * doc/posix-functions/duplocale.texi: Mention the glibc bug.
106431 2009-11-22  Bruno Haible  <bruno@clisp.org>
106433         * modules/locale-tests (configure.ac): Test for newlocale function.
106434         * tests/test-locale.c: When the system has extended locale functions,
106435         verify that <locale.h> defines locale_t and LC_GLOBAL_LOCALE.
106437         locale: Make locale_t available when possible.
106438         * lib/locale.in.h: Include <xlocale.h> when it exists.
106439         * m4/locale_h.m4 (gl_LOCALE_H): Check for <xlocale.h> and arrange to
106440         replace <locale.h> if it does not define locale_t but <xlocale.h> does.
106441         * modules/locale (Depends-on): Add extensions.
106442         (Makefile.am): Also substitute HAVE_XLOCALE_H.
106443         * doc/posix-headers/locale.texi: Document the problem with locale_t.
106445 2009-11-22  Bruno Haible  <bruno@clisp.org>
106447         Add comments.
106448         * m4/dirent_h.m4 (gl_DIRENT_H): Add comment about gl_CHECK_NEXT_HEADERS
106449         invocation.
106450         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
106451         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
106452         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
106454 2009-11-22  Bruno Haible  <bruno@clisp.org>
106456         error: account for the possibility of freopen (stdout).
106457         * lib/error.c: Include <unistd.h>.
106458         (flush_stdout): New function, extracted from error and error_at_line.
106459         Determine stdout's fd dynamically.
106460         (error, error_at_line): Invoke flush_stdout.
106461         * m4/error.m4 (gl_PREREQ_ERROR): Require AC_C_INLINE.
106462         * modules/error (Depends-on): Add unistd.
106464 2009-11-22  Bruno Haible  <bruno@clisp.org>
106466         diffseq: Add comment.
106467         * lib/diffseq.h (IF_LINT): Add comment about pitfall.
106469 2009-11-22  Jim Meyering  <meyering@redhat.com>
106471         c-stack: avoid defining an unused static function
106472         * lib/c-stack.c (find_stack_direction): Do not define this function
106473         when it will not be used.
106475         diffseq: avoid spurious gcc warnings
106476         * lib/diffseq.h (IF_LINT2): Define.
106477         (compareseq): Use it to initialize two members of "part".
106478         This avoids two used-uninitialized warnings.
106480 2009-11-21  Jim Meyering  <meyering@redhat.com>
106482         c-stack: avoid "ignoring return value of `write'" warning
106483         * lib/c-stack.c: Include "ignore-value.h".
106484         (die): Explicitly ignore each write return value.
106485         * modules/c-stack (Depends-on): Add ignore-value.
106487 2009-11-21  Bruno Haible  <bruno@clisp.org>
106489         diffseq: reduce scope of variable 'best'.
106490         * lib/diffseq.h (diag) [USE_HEURISTIC]: Reduce scope of 'best'
106491         variable, earlier used for two different purposes.
106493 2009-11-21  Jim Meyering  <meyering@redhat.com>
106495         diffseq: remove useless assignment to "best"
106496         * lib/diffseq.h (diag) [USE_HEURISTIC]: Remove useless "best = 0"
106497         assignment.  At that point "best" is already guaranteed to be zero.
106499 2009-11-20  Eric Blake  <ebb9@byu.net>
106501         build: mention ftp redirector in release announcements
106502         * top/maint.mk (gnu_rel_host, url_dir_list): Provide defaults for
106503         values that used to come from cfg.mk; mention FTP redirect URL.
106504         * build-aux/announce-gen: Mention the mirror list.
106505         Suggested by Karl Berry.
106507         nanosleep: improve port to mingw
106508         * lib/nanosleep.c (rpl_nanosleep): Reject invalid arguments.
106509         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Incorporate LIBSOCKET into
106510         LIB_NANOSLEEP, but only when needed.
106511         * modules/select (Link): Document LIBSOCKET.
106512         * m4/select.m4 (gl_FUNC_SELECT): Ensure LIBSOCKET is defined early
106513         enough.
106515         nanosleep: work around cygwin bug
106516         * lib/nanosleep.c (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]:
106517         Fix logic bug when nanosleep fails.  Work around cygwin 1.5.x
106518         bug.
106519         (getnow): Delete, not needed.
106520         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): No longer require
106521         LIB_CLOCK_GETTIME.
106522         * modules/nanosleep (Depends-on): Add intprops and verify.  Drop
106523         clock-time, gettime.
106524         * doc/posix-functions/nanosleep.texi (nanosleep): Document the
106525         bug.
106526         * modules/nanosleep-tests: New test.
106527         * tests/test-nanosleep.c: New file.
106529         sleep: work around cygwin bug
106530         * lib/sleep.c (rpl_sleep): Work around the bug.
106531         * m4/sleep.m4 (gl_FUNC_SLEEP): Detect the bug.
106532         (gl_PREREQ_SLEEP): Delete unused macro.
106533         * modules/sleep (Depends-on): Add verify.
106534         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
106535         * modules/unistd (Makefile.am): Substitute witness.
106536         * lib/unistd.in.h (sleep): Update prototype.
106537         * doc/posix-functions/sleep.texi (sleep): Document the bug.
106538         * tests/test-sleep.c (main) [HAVE_DECL_ALARM]: Test it.
106539         * modules/sleep-tests (Depends-on): Check for alarm.
106541 2009-11-20  Jim Meyering  <meyering@redhat.com>
106543         maint.mk: improve sc_prohibit_magic_number_exit
106544         * top/maint.mk (sc_prohibit_magic_number_exit): Tighten regexp
106545         so it does not match uses like System.exit(1).
106546         Add comments showing how to correct all offenders.
106548 2009-11-19  Eric Blake  <ebb9@byu.net>
106550         xalloc-die-tests: add missing library
106551         * modules/xalloc-die-tests (Makefile.am): Add LDADD line.
106553         test-xvasprintf: silence compiler warnings
106554         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Mask
106555         empty string from gcc.
106557 2009-11-19  Jim Meyering  <meyering@redhat.com>
106559         xfreopen: new module, from coreutils
106560         * modules/xfreopen: New module.
106561         * lib/xfreopen.c: New file.
106562         * lib/xfreopen.h: New file.
106563         * MODULES.html.sh (File stream based Input/Output"): Add it.
106565 2009-11-19  Eric Blake  <ebb9@byu.net>
106567         manywarnings: depend on warnings
106568         * modules/manywarnings (Depends-on): Add warnings.
106570         build: avoid compiler warnings
106571         * lib/select.c (rpl_select): Delete unused variable.
106572         * lib/setsockopt.c (rpl_setsockopt): Avoid incompatible pointer.
106574 2009-11-18  Eric Blake  <ebb9@byu.net>
106576         tests: avoid false negative with --with-packager
106577         * tests/test-version-etc.sh: Discard packager information.
106578         * tests/test-argp-version-etc-1.sh: Likewise.
106579         Reported by Mike Frysinger.
106581         utimens: fix regression on Solaris
106582         * m4/utimens.m4 (gl_UTIMENS): Check for BSD bug.
106583         * lib/utimens.c (fdutimens): Revert 2009-11-08 change; Solaris 10
106584         can only change fd timestamps via futimesat.  Instead, use an
106585         additional witness macro to avoid BSD bug.
106586         Reported by Jim Meyering.
106588 2009-11-17  Eric Blake  <ebb9@byu.net>
106590         usleep: use it to simplify tests
106591         * modules/stat-time-tests (Depends-on): Add usleep.
106592         (configure.ac): Drop usleep check.
106593         * modules/chown-tests (Depends-on, configure.ac): Likewise.
106594         * modules/lchown-tests (Depends-on, configure.ac): Likewise.
106595         * modules/fdutimensat-tests (Depends-on, configure.ac): Likewise.
106596         * modules/futimens-tests (Depends-on, configure.ac): Likewise.
106597         * modules/openat-tests (Depends-on, configure.ac): Likewise.
106598         * modules/utimens-tests (Depends-on, configure.ac): Likewise.
106599         * modules/utimensat-tests (Depends-on, configure.ac): Likewise.
106600         * modules/pipe-filter-gi-tests (Depends-on, configure.ac):
106601         Likewise.
106602         * tests/test-chown.h (nap): Rely on nicer usleep semantics.
106603         * tests/test-lchown.h (nap): Likewise.
106604         * tests/test-pipe-filter-gi2-main.c (small_nap): Likewise.
106605         * tests/test-stat-time.c (nap): Likewise.
106606         * tests/test-utimens-common.h (nap): Update comments.
106608         usleep: new module
106609         * modules/usleep: New file.
106610         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
106611         * lib/usleep.c (usleep): Likewise.
106612         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
106613         * modules/unistd (Makefile.am): Substitute witnesses.
106614         * lib/unistd.in.h (usleep): Add declaration.
106615         * doc/pastposix-functions/usleep.texi (usleep): Document this.
106616         * MODULES.html.sh (Date and time): Likewise.
106617         * modules/usleep-tests (Depends-on): New test.
106618         * tests/test-usleep.c: New file.
106620         chown: work around OpenBSD bug
106621         * lib/chown.c (rpl_chown): Work around the bug.
106622         * lib/lchown.c (rpl_lchown): Attempt to do likewise.
106623         * m4/chown.m4 (gl_FUNC_CHOWN): Test for ctime bug.
106624         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for lchmod.
106625         * modules/chown (Depends-on): Add stdbool.
106626         * modules/lchown (Depends-on): Likewise.
106627         * doc/posix-functions/chown.texi (chown): Document the bug.
106628         * doc/posix-functions/lchown.texi (lchown): Likewise.
106629         * tests/test-lchown.h (test_chown): Relax test.
106631         mkstemp: avoid conflict with C++ keyword template
106632         * lib/mkdtemp.c (mkdtemp): Change spelling of template.
106633         * lib/mkostemp.c (mkostemp): Likewise.
106634         * lib/mkostemps.c (mkostemps): Likewise.
106635         * lib/mkstemp.c (mkstemp): Likewise.
106636         * lib/mkstemps.c (mkstemps): Likewise.
106638         xalloc-die-tests: optimize
106639         * tests/test-xalloc-die.sh: Reduce number of processes.
106641 2009-11-17  Simon Josefsson  <simon@josefsson.org>
106643         * gnulib-tool: Support LGPLv3+ licenses in module files.  Tiny
106644         patch from ludo@gnu.org (Ludovic Courtès).
106646 2009-11-17  Jim Meyering  <meyering@redhat.com>
106648         version-etc: use proper license string
106649         * modules/version-etc (License): Use LGPL, not LGPLv3+.
106650         * modules/version-etc-fsf: Likewise.
106652 2009-11-17  Simon Josefsson  <simon@josefsson.org>
106654         * tests/test-xalloc-die.sh: Add license.  Check that nothing is
106655         printed to stdout.  Deal with EOL differences.
106657 2009-11-17  Eric Blake  <ebb9@byu.net>
106659         unsetenv: work around Solaris bug
106660         * m4/setenv.m4 (gl_FUNC_UNSETENV): Check for bug.
106661         * lib/unsetenv.c (rpl_unsetenv): Work around it.
106662         Reported by Jim Meyering.
106664         vasnprintf: avoid compiler warnings
106665         * lib/vasnprintf.c (VASNPRINTF): Avoid shadowing our own local
106666         variables.
106667         * lib/printf-args.c (PRINTF_FETCHARGS): Avoid type mismatch.
106669 2009-11-17  Simon Josefsson  <simon@josefsson.org>
106671         * modules/xalloc-die-tests (Makefile.am): Drop XFAIL_TESTS
106672         settings since xalloc-die is no longer the self test,
106673         xalloc-die.sh is.
106675 2009-11-17  Jim Meyering  <meyering@redhat.com>
106677         test-xalloc-die.sh: make the code agree with the commit log
106678         * tests/test-xalloc-die.sh: Put "." at the front of $PATH, not
106679         at the end, just in case you happen to have a test-xalloc-die
106680         program in some other PATH directory.
106682         test-xalloc-die.sh: fix a portability bug
106683         * tests/test-xalloc-die.sh: Do not invoke via ./test-xalloc-die.
106684         Instead, set PATH to start with "." and invoke via "test-xalloc-die".
106685         Otherwise, argv[0] (as often seen in diagnostics) would be too
106686         system-dependent, sometimes with, and sometimes without the leading "./".
106688         version-etc-fsf: relax license to LGPLv3+
106689         * modules/version-etc-fsf (License): Relax license.
106691 2009-11-16  Eric Blake  <ebb9@byu.net>
106693         xalloc-die-tests: avoid printing null pointer
106694         * modules/xalloc-die-tests (Files, Makefile.am): Wrap execution in
106695         shell script.
106696         * tests/test-xalloc-die.c (program_name): Declare.
106697         * tests/test-xalloc-die.sh (tmpfiles): New file.
106699         setenv, unsetenv: work around various bugs
106700         * lib/setenv.c (setenv) [!HAVE_SETENV]: Resync from glibc.
106701         (setenv) [HAVE_SETENV]: Work around bugs.
106702         * lib/unsetenv.c (unsetenv) [HAVE_UNSETENV]: Work around bugs.
106703         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE, gl_FUNC_UNSETENV): Check
106704         for bugs.
106705         (gl_FUNC_SETENV): Write in terms of gl_FUNC_SETENV_SEPARATE.
106706         * m4/environ.m4 (gl_ENVIRON): Avoid expand-before-require.
106707         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Update defaults.
106708         * modules/stdlib (Makefile.am): Update substitutions.
106709         * lib/stdlib.in.h (setenv, unsetenv): Update prototypes.
106710         * doc/posix-functions/setenv.texi (setenv): Document the bugs.
106711         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
106712         * modules/setenv-tests: New test.
106713         * modules/unsetenv-tests: Likewise.
106714         * tests/test-setenv.c: New file.
106715         * tests/test-unsetenv.c: Likewise.
106717 2009-11-16  Jim Meyering  <meyering@redhat.com>
106719         version-etc: relax license to LGPLv3+
106720         * modules/version-etc (License): Relax license.
106722         better AC_REQUIRE expanded-before-required-warning avoidance
106723         * m4/chown.m4 (gl_FUNC_CHOWN, gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Define
106724         with AC_DEFUN_ONCE, rather than AC_DEFUN, to avoid AC_REQUIRE warnings.
106725         Suggested by Eric Blake.  This change also reverts commit 1b712ba8,
106726         which is no longer needed.
106728 2009-11-16  Eric Blake  <ebb9@byu.net>
106730         test-freading: clean up temporary file
106731         * tests/test-freading.c (main): Remove file on success, and use
106732         ASSERT more liberally.
106733         Reported by Jim Meyering.
106735 2009-11-16  Jim Meyering  <meyering@redhat.com>
106737         avoid new AC_REQUIRE expanded-before-required warnings
106738         * modules/chown (configure.ac): Require gl_FUNC_CHOWN, rather than
106739         merely using it.
106740         * modules/euidaccess (configure.ac): Likewise for gl_FUNC_EUIDACCESS.
106741         * modules/faccessat (configure.ac): Likewise for gl_FUNC_FACCESSAT.
106743 2009-11-15  Simon Josefsson  <simon@josefsson.org>
106745         * tests/test-xalloc-die.c: New file.
106746         * modules/xalloc-die-tests: New file.
106747         * gnulib-tool (func_emit_tests_Makefile_am): Also initialize
106748         XFAIL_TESTS so it can be appended by modules.
106750 2009-11-15  Simon Josefsson  <simon@josefsson.org>
106752         * lib/gc-pbkdf2-sha1.c: Remove comments from RFC 2898.  Reported
106753         by Vladimir 'phcoder' Serbinenko <phcoder@gmail.com>.
106755 2009-11-14  Eric Blake  <ebb9@byu.net>
106757         fnmatch: avoid compiler warning
106758         * lib/fnmatch_loop.c (NEW_PATTERN): Coerce addition to unsigned,
106759         to silence compiler warning about mismatch signedness in ?:.
106760         Reported by Robert Millan.
106762         intprops: add double-inclusion guard
106763         * lib/intprops.h: Allow idempotent includes.
106764         Suggested by Bruce Korb.
106766         openat: detect Solaris fchownat bug
106767         * lib/fchownat.c (rpl_fchownat): Work around Solaris bug.  Avoid
106768         penalizing glibc chownat when only lchownat is broken.
106769         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Replace fchownat if there are
106770         trailing slash bugs.
106771         * doc/posix-functions/fchownat.texi (fchownat): Document the bug.
106772         * modules/openat-tests (Files): Include more files.
106773         (Depends-on): Add mgetgroups, sleep, stat-time.
106774         (configure.ac): Add additional checks.
106775         (Makefile.am): Build new test.
106776         * tests/test-fchownat.c: New file.
106778         lchown: detect Solaris and FreeBSD bug
106779         * lib/lchown.c (rpl_lchown): Work around bug.
106780         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for trailing slash bugs.
106781         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
106782         * modules/unistd (Makefile.am): Populate it.
106783         * lib/unistd.in.h (lchown): Update declaration.
106784         * doc/posix-functions/lchown.texi (lchown): Document the bug.
106785         * modules/lchown-tests: New file.
106786         * tests/test-lchown.h (test_lchown): Likewise.
106787         * tests/test-lchown.c (main): Likewise.
106789         chown: detect Solaris and FreeBSD bug
106790         * lib/chown.c (rpl_chown): Work around bug.
106791         * m4/chown.m4 (gl_FUNC_CHOWN): Check for trailing slash bugs.
106792         (gl_PREREQ_CHOWN): Delete.
106793         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
106794         * modules/unistd (Makefile.am): Populate it.
106795         * lib/unistd.in.h (chown): Update declaration.
106796         * lib/lchown.c (chown): Update client.
106797         * modules/lchown (Depends-on): Add lstat.
106798         * doc/posix-functions/chown.texi (chown): Document the bug.
106799         * doc/posix-functions/getgroups.texi (getgroups): Document
106800         getgroups pitfall.
106801         * modules/chown-tests: New file.
106802         * tests/test-chown.h (test_chown): Likewise.
106803         * tests/test-chown.c (main): Likewise.
106805 2009-11-14  Robert Millan  <rmh.grub@aybabtu.com>  (tiny change)
106807         gnulib-tool: correctly detect absence of m4 directories
106808         * gnulib-tool: Avoid extra newline on data passed to wc -l.
106810 2009-11-14  Jim Meyering  <meyering@redhat.com>
106812         maint.mk: Prohibit inclusion of "xalloc.h" without use.
106813         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
106815 2009-11-14  John W. Eaton  <jwe@gnu.org>
106817         strftime.h: wrap function declaration in extern "C" block
106818         * lib/strftime.h (nstrftime) [__cplusplus]: Wrap declaration.
106820 2009-11-13  Eric Blake  <ebb9@byu.net>
106822         getgroups: avoid compiler warning
106823         * lib/getgroups.c (rpl_getgroups): Delete shadowed variable.
106825         getgroups: work around FreeBSD bug
106826         * lib/getgroups.c (rpl_getgroups): Work around the bug.
106827         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Detect the bug.
106828         * doc/posix-functions/getgroups.texi (getgroups): Document it.
106829         * tests/test-getgroups.c (main): Fix buffer overrun.
106831         getgroups: avoid compilation failure
106832         * lib/getgroups.c (includes): Include <stdint.h> for SIZE_MAX.
106833         * modules/getgroups (Depends-on): Add stdint.
106835 2009-11-13  Jim Meyering  <meyering@redhat.com>
106837         test-getgroups: avoid compilation failure
106838         * tests/test-getgroups.c: Include <stdint.h> for use of SIZE_MAX.
106840 2009-11-13  Eric Blake  <ebb9@byu.net>
106842         mgetgroups: new module, taken from coreutils
106843         * modules/mgetgroups: New file.
106844         * lib/mgetgroups.h: Likewise.
106845         * lib/mgetgroups.c (mgetgroups): Likewise.
106846         * m4/mgetgroups.m4 (gl_MGETGROUPS): Likewise.
106847         * MODULES.html.sh (Users and groups): Mention it.
106849         getgroups: don't expose GETGROUPS_T to user
106850         * lib/getgroups.c (rpl_getgroups): Change signature.  Copy array
106851         an element at a time if GETGROUPS_T is wrong size.
106852         * lib/getugroups.h (getugroups): Change signature.
106853         * lib/unistd.in.h (getgroups): Likewise.
106854         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Use replacement if
106855         signature needs fixing.
106856         * m4/getugroups.m4 (gl_GETUGROUPS): No longer need
106857         AC_TYPE_GETGROUPS.
106858         * modules/group-member (Depends-on): Add getgroups.
106859         * lib/group-member.c (group_info, get_group_info): Use gid_t.
106860         (group_member): Rely on getgroups replacement.
106861         * lib/getugroups.c (getugroups): Use gid_t.
106862         * tests/test-getgroups.c (main): Likewise.
106863         * NEWS: Mention the signature change.
106864         * doc/posix-functions/getgroups.texi (getgroups): Mention the
106865         problem with signature.
106866         * doc/glibc-functions/setgroups.texi (setgroups): Mention that
106867         GETGROUPS_T is still useful for setgroups.
106869         getgroups, getugroups: provide stubs for mingw
106870         * lib/getgroups.c (getgroups): Provide ENOSYS stub for mingw.
106871         * lib/getugroups.c (getugroups): Likewise.
106872         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Check for missing
106873         function.  Modernize replacement scheme.
106874         (gl_PREREQ_GETGROUPS): Delete.
106875         * m4/getugroups.m4 (gl_GETUGROUPS): Check for <grp.h>.
106876         * modules/getgroups (configure.ac): Declare witness.
106877         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
106878         * modules/unistd (Depends-on): Substitute witness.
106879         * lib/unistd.in.h (getgroups): Declare replacement.
106881         getgroups: avoid calling exit
106882         * modules/getgroups (Depends-on): Add malloc-posix and unistd,
106883         drop xalloc.
106884         * modules/getgroups-tests (Depends-on, Makefile.am): Drop unneeded
106885         dependencies.
106886         * lib/getgroups.c (rpl_getgroups): Fail with ENOMEM rather than
106887         exiting, in the rare case of malloc failure.
106889         getgroups: fix logic error
106890         * lib/getgroups.c (rpl_getgroups): Don't fail if current process
106891         has more than 20 groups.
106892         * modules/getgroups-tests: New test.
106893         * tests/test-getgroups.c: New file.
106895 2009-11-13  Simon Josefsson  <simon@josefsson.org>
106897         * tests/test-base64.c: Improve.
106899 2009-11-13  Simon Josefsson  <simon@josefsson.org>
106901         * tests/test-xvasprintf.c: Fix memory leak, suggested by Eric
106902         Blake <ebb9@byu.net>.
106904 2009-11-13  Simon Josefsson  <simon@josefsson.org>
106906         * tests/test-xvasprintf.c: Add %s%s related checks.
106908 2009-11-12  Eric Blake  <ebb9@byu.net>
106910         version-etc: match standards.texi style
106911         * lib/version-etc.c (emit_bug_reporting_address): Drop periods,
106912         and use <> only for URLs.
106914 2009-11-10  Kamil Dudka  <kdudka@redhat.com>
106916         fts: do not fail on a submount during traversal
106917         * lib/fts.c (fts_build): Read the stat info again after opening
106918         a directory if the FTS_TIGHT_CYCLE_CHECK flag is set.
106919         Original report at http://bugzilla.redhat.com/501848.
106921 2009-11-12  Jim Meyering  <meyering@redhat.com>
106923         bootstrap: sync from coreutils
106924         * build-aux/bootstrap (bootstrap_epilogue): New function.
106925         Use git_modules_config in one more place.  This make bootstrap's
106926         --gnulib-srcdir option more useful for testing.
106928         bootstrap: generalize autoheader check
106929         * build-aux/bootstrap: Look for AC_CONFIG_HEADER as well as
106930         AC_CONFIG_HEADERS.
106932 2009-11-11  Eric Blake  <ebb9@byu.net>
106934         mkfifoat: use new modules for Solaris and BSD bugs
106935         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Simplify.
106936         * lib/mkfifoat.c (mknodat): Split...
106937         * lib/mknodat.c (mknodat): ...into new file.
106938         * modules/mkfifoat (Files): Ship new file.
106939         (Depends-on): Add mkfifo, mknod.
106940         * modules/mkfifoat-tests (Files): Reuse mkfifo tests.
106941         (Depends-on): Add symlink.
106942         * tests/test-mkfifoat.c (main): Enhance test.  Drop portions now
106943         redundant with test_mkfifo.h.
106944         (do_mkfifoat, do_mknodat): New helpers.
106946         mknod: new module
106947         * modules/mknod: New file.
106948         * m4/mknod.m4 (gl_FUNC_MKNOD): Likewise.
106949         * lib/mknod.c (mknod): Likewise.
106950         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
106951         defaults.
106952         * modules/sys_stat (Makefile.am): Substitute them.
106953         * lib/sys_stat.in.h (mknod): Declare replacement.
106954         * MODULES.html.sh (Support for systems lacking POSIX:2008):
106955         Document it.
106956         * doc/posix-functions/mknod.texi (mknod): Likewise.
106957         * modules/mknod-tests: New test.
106958         * tests/test-mknod.c: Likewise.
106960         mkfifo: new module
106961         * modules/mkfifo: New file.
106962         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
106963         * lib/mkfifo.c (mkfifo): Likewise.
106964         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
106965         defaults.
106966         * modules/sys_stat (Makefile.am): Substitute them.
106967         * lib/sys_stat.in.h (mkfifo): Declare replacement.
106968         * MODULES.html.sh (Support for systems lacking POSIX:2008):
106969         Document it.
106970         * doc/posix-functions/mkfifo.texi (mkfifo): Likewise.
106971         * modules/mkfifo-tests: New test.
106972         * tests/test-mkfifo.h (test_mkfifo): New file, borrowed in part
106973         from test-mkfifoat.c.
106974         * tests/test-mkfifo.c: New file.
106976         readlink: detect FreeBSD bug
106977         * m4/readlink.m4 (gl_FUNC_READLINK): Also detect FreeBSD bug with
106978         slash on symlink.
106979         * doc/posix-functions/readlink.texi (readlink): Document the bug.
106980         * tests/test-readlink.h (test_readlink): Enhance test.
106982         symlink: detect FreeBSD bug
106983         * m4/symlink.m4 (gl_FUNC_SYMLINK): Also detect FreeBSD bug with
106984         slash on symlink.
106985         * doc/posix-functions/symlink.texi (symlink): Document the bug.
106986         * tests/test-symlink.h (test_symlink): Enhance test.
106988 2009-11-10  Eric Blake  <ebb9@byu.net>
106990         link: detect FreeBSD bug
106991         * m4/link.m4 (gl_FUNC_LINK): Also detect FreeBSD bug with slash on
106992         symlink.
106993         * doc/posix-functions/link.texi (link): Document the bug.
106994         * tests/test-link.h (test_link): Enhance test.
106995         * tests/test-linkat.c (main): Update caller.
106997         unlink, remove: detect FreeBSD bug
106998         * m4/unlink.m4 (gl_FUNC_UNLINK): Also detect FreeBSD bug with
106999         slash on symlink.
107000         * doc/posix-functions/unlink.texi (unlink): Document the bug.
107001         * doc/posix-functions/remove.texi (remove): Likewise.
107002         * tests/test-unlink.h (test_unlink): Enhance test.
107003         * tests/test-remove.c (main): Likewise.
107005 2009-11-09  Eric Blake  <ebb9@byu.net>
107007         rename: detect FreeBSD bug
107008         * m4/rename.m4 (gl_FUNC_RENAME): Also detect FreeBSD bug with
107009         slash on symlink.
107010         * modules/renameat-tests (Depends-on): Add filenamecat.
107011         * tests/test-rename.h (test_rename): Allow one more errno.
107012         * tests/test-renameat.c (main): Likewise.
107013         * doc/posix-functions/rename.texi (rename): Document the bug.
107015         open: detect FreeBSD bug
107016         * m4/open.m4 (gl_FUNC_OPEN): Also detect FreeBSD bug with slash on
107017         symlink.
107018         * doc/posix-functions/open.texi (open): Document the bug.
107019         * doc/posix-functions/utimes.texi (utimes): Likewise.
107020         * tests/test-open.h (test_open): Add parameters, and test symlink
107021         handling.
107022         * tests/test-open.c (main): Adjust caller.
107023         * tests/test-fcntl-safer.c (main): Likewise.
107024         * modules/open-tests (Depends-on): Add stdbool, symlink.
107025         * modules/fcntl-safer-tests (Depends-on): Likewise.
107026         * tests/test-openat.c (main): Add test-open tests.
107028         stat: detect FreeBSD bug
107029         * m4/stat.m4 (gl_FUNC_STAT): Also detect FreeBSD bug with slash on
107030         symlink.
107031         * doc/posix-functions/stat.texi (stat): Document the bug.
107032         * tests/test-stat.h (test_stat_func): Add argument.
107033         * tests/test-stat.c (main): Adjust caller.
107034         * tests/test-fstatat.c (main): Likewise.
107035         * modules/stat-tests (Depends-on): Add stdbool, symlink.
107036         Reported by Jim Meyering.
107038 2009-11-09  James Youngman  <jay@gnu.org>
107040         strftime.c: include ignore-value.h only when FPRINTFTIME is defined
107041         * lib/strftime.c: Correct placement of #include "ignore-value.h".
107043 2009-11-08  Jim Meyering  <meyering@redhat.com>
107045         utimens: remove invalid futimesat call
107046         * lib/utimens.c (fdutimens): Remove invalid futimesat call.
107047         It used the file descriptor of the target file as the DIR_FD
107048         parameter and NULL as the file name.  That caused failure with
107049         errno == EFAULT on FreeBSD-8.0-rc2
107051 2009-11-07  Eric Blake  <ebb9@byu.net>
107053         fflush, freadseek: use fseeko, not fseek
107054         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
107055         (clear_ungetc_buffer): Avoid potential problems on large files.
107056         * lib/freadseek.c (freadseek): Likewise.
107057         * modules/freadseek (Depends-on): Add fseeko.
107058         * modules/fseek (configure.ac): Set a witness.
107059         * tests/test-fflush.c (main): Use fseeko.
107060         * tests/test-fpurge.c (fseek): Disable link warning.
107061         * tests/test-freadable.c (fseek): Likewise.
107062         * tests/test-freading.c (fseek): Likewise.
107063         * tests/test-fseeko.c (fseek): Likewise.
107064         * tests/test-ftell.c (fseek): Likewise.
107065         * tests/test-ftello.c (fseek): Likewise.
107066         * tests/test-fwritable.c (fseek): Likewise.
107067         * tests/test-fwriting.c (fseek): Likewise.
107069 2009-11-06  Simon Josefsson  <simon@josefsson.org>
107071         * modules/memchr (Depends-on): Drop getpagesize dependency.
107073 2009-11-06  Simon Josefsson  <simon@josefsson.org>
107075         * build-aux/pmccabe2html: Disable execute bit.  Suggested by
107076         Reported by Ludovic Courtès.
107077         * build-aux/pmccabe2html: Improve example usage.
107078         * build-aux/pmccabe2html: Drop #! header.  Doc fix.
107080 2009-11-06  Jim Meyering  <meyering@redhat.com>
107082         do-release-commit-and-tag: New module.
107083         Automate the release-commit and tag process.
107084         * build-aux/do-release-commit-and-tag: New script, from coreutils.
107085         * modules/do-release-commit-and-tag: New file.
107086         * MODULES.html.sh (Support for maintaining and releasing): Add it.
107088 2009-11-06  Simon Josefsson  <simon@josefsson.org>
107090         * modules/select-tests (test_select_LDADD): Add $(INET_PTON_LIB)
107091         because test-select.c uses inet_pton.
107093 2009-11-06  Simon Josefsson  <simon@josefsson.org>
107095         * m4/getaddrinfo.m4: Add content of INET_NTOP_LIB to
107096         GETADDRINFO_LIB.  Bump serial number.
107097         * modules/getaddrinfo (Link): Only mention GETADDRINFO_LIB again.
107098         Suggested by Eric Blake <ebb9@byu.net>.
107100 2009-11-05  Eric Blake  <ebb9@byu.net>
107102         strtod: detect darwin bug
107103         * m4/strtod.m4 (gl_FUNC_STRTOD): Filter out darwin bug on "nan(".
107104         Reported by Leo Davis.
107106         freopen-safer: new module
107107         * modules/freopen-safer: New module.
107108         * m4/stdio-safer.m4 (gl_FREOPEN_SAFER): New macro.
107109         * lib/freopen-safer.c (freopen_safer): New file.
107110         * lib/stdio-safer.h (freopen_safer): New declaration.
107111         * lib/stdio--.h (freopen): New override.
107112         * MODULES.html.sh (File stream based Input/Output): Mention it.
107113         * doc/posix-functions/freopen.texi (freopen): Mention pitfalls and
107114         freopen-safer module.
107115         * doc/posix-functions/stderr.texi (stderr): Likewise.
107116         * doc/posix-functions/stdin.texi (stdin): Likewise.
107117         * doc/posix-functions/stdout.texi (stdout): Likewise.
107118         * modules/freopen-safer-tests: New test.
107119         * tests/test-reopen-safer.c: New file.
107121 2009-11-05  Jim Meyering  <meyering@redhat.com>
107123         maint.mk: Prohibit inclusion of "close-stream.h" without use.
107124         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
107126 2009-11-05  Simon Josefsson  <simon@josefsson.org>
107128         * modules/pmccabe2html (configure.ac): Check for pmccabe tool.
107130 2009-11-05  Simon Josefsson  <simon@josefsson.org>
107132         * modules/getaddrinfo (Link): Add $(INET_NTOP_LIB).
107134 2009-11-05  Simon Josefsson  <simon@josefsson.org>
107136         Fix link error.
107137         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
107138         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
107140 2009-11-05  Simon Josefsson  <simon@josefsson.org>
107142         * tests/test-func.c: Also test value of __func__.
107144 2009-11-05  Simon Josefsson  <simon@josefsson.org>
107146         * tests/test-sys_socket.c: Use smaller constant value, sa_family_t
107147         may be an 8-bit type.  Reported by Bruno Haible <bruno@clisp.org>.
107149 2009-11-05  Bruno Haible  <bruno@clisp.org>
107151         Fix link error.
107152         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
107153         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
107154         Reported by Brad Hards <bradh@frogmouth.net> via Simon Josefsson.
107156 2009-11-05  Bruno Haible  <bruno@clisp.org>
107158         Tests for module 'inet_pton'.
107159         * modules/inet_pton-tests: New file.
107160         * tests/test-inet_pton.c: New file.
107162 2009-11-05  Bruno Haible  <bruno@clisp.org>
107164         Tests for module 'inet_ntop'.
107165         * modules/inet_ntop-tests: New file.
107166         * tests/test-inet_ntop.c: New file.
107168 2009-11-04  Eric Blake  <ebb9@byu.net>
107170         stdlib-safer: wrap all mkstemp variants
107171         * modules/mkostemp (configure.ac): Set witness.
107172         * modules/mkostemps (configure.ac): Likewise.
107173         * modules/mkstemps (configure.ac): Likewise.
107174         * lib/stdlib-safer.h (mkostemp_safer, mkostemps_safer)
107175         (mkstemps_safer): Wrap more functions.
107176         * lib/stdlib--.h (mkostemp, mkostemps, mkstemps): Default the
107177         wrapping.
107178         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer)
107179         (mkstemps_safer): Implement the wrappers.
107181         mkstemps, mkostemps: new modules
107182         * modules/mkostemps: New module.
107183         * modules/mkstemps: Likewise.
107184         * lib/mkostemps.c (mkostemps): New file.
107185         * lib/mkstemps.c (mkstemps): Likewise.
107186         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Likewise.
107187         * m4/mkstemps.m4 (gl_FUNC_MKSTEMPS): Likewise.
107188         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Add witnesses.
107189         * modules/stdlib (Makefile.am): Substitute them.
107190         * lib/stdlib.in.h (mkostemps, mkstemps): Declare them.
107191         * doc/glibc-functions/mkstemps.texi (mkstemps): New file.
107192         * doc/glibc-functions/mkostemps.texi (mkostemps): Likewise.
107193         * doc/gnulib.texi (Glibc stdlib.h): Include them.
107194         * MODULES.html.sh (File system functions): Mention them.
107196         tempname: resync from glibc
107197         * lib/tempname.c (__gen_tempname): Add suffixlen argument.  Use
107198         same values for __GT_FILE as glibc.  Abort even when assertions
107199         are disabled.
107200         * lib/tempname.h (GT_FILE): Use glibc __GT_FILE, if available, and
107201         match its value otherwise.  Allow idempotent inclusion.
107202         * lib/mkdtemp.c (mkdtemp): Adjust caller.
107203         * lib/mkostemp.c (mkostemp): Likewise.
107204         * lib/mkstemp.c (mkstemp): Likewise.
107205         * lib/tmpfile.c (tmpfile): Likewise.
107206         * NEWS: Document this.
107208         utimens: fix use of futimens on older Linux
107209         * lib/utimens.c (fdutimens): Use updated, rather than original,
107210         timespec to avoid bug in older Linux kernel.
107211         Reported by Simon Josefsson.
107213 2009-11-04  Bruno Haible  <bruno@clisp.org>
107215         Make num_processors more flexible and consistent.
107216         * lib/nproc.h (enum nproc_query): New type.
107217         (num_processors): Add a 'query' argument.
107218         * lib/nproc.c: Include <stdlib.h>, <sched.h>, c-ctype.h.
107219         (num_processors): Add a 'query' argument. Test the value of the
107220         OMP_NUM_THREADS environment variable if requested. On Linux, NetBSD,
107221         mingw, count the number of CPUs available for the current process.
107222         * m4/nproc.m4 (gl_PREREQ_NPROC): Require AC_USE_SYSTEM_EXTENSIONS.
107223         Check for sched_getaffinity and sched_getaffinity_np.
107224         * modules/nproc (Depends-on): Add c-ctype, extensions.
107225         * NEWS: Mention the change.
107227 2009-11-03  Bruno Haible  <bruno@clisp.org>
107229         * NEWS: Document the new library dependencies of inet_ntop, inet_pton.
107231 2009-11-03  Jim Meyering  <meyering@redhat.com>
107233         test-getaddrinfo: avoid compilation failure on FreeBSD 7.2
107234         * tests/test-getaddrinfo.c (simple): Test for EAI_NODATA only
107235         if it is defined.
107237 2009-11-02  Eric Blake  <ebb9@byu.net>
107239         mktime, timegm: share common declaration
107240         * lib/mktime-internal.h: New file.
107241         * lib/mktime.c: Use it rather than open-coding a declaration.
107242         * lib/timegm.c: Likewise.
107243         * modules/mktime (Files): Ship it.
107244         * modules/timegm (Files): Likewise.
107245         Suggested by Bruno Haible.
107247         test-update-copyright: update test to match script changes
107248         * tests/test-update-copyright.sh: Avoid hard-coding perl
107249         location.  Don't update *.bak created by earlier runs.
107251 2009-11-02  Paul Eggert  <eggert@cs.ucla.edu>
107252             Simon Josefsson  <simon@josefsson.org>
107253             Bruno Haible  <bruno@clisp.org>
107255         Fix link error on Solaris 8.
107256         * m4/inet_pton.m4 (gl_INET_PTON): Search for the function inet_pton
107257         also in libnsl. Define also INET_PTON_LIB.
107258         * modules/inet_pton (Link): New section.
107260 2009-11-02  Simon Josefsson  <simon@josefsson.org>
107261             Bruno Haible  <bruno@clisp.org>
107263         * m4/inet_ntop.m4 (gl_INET_NTOP): Define also INET_NTOP_LIB.
107264         * modules/inet_ntop (Link): New section.
107265         Reported by Boyan Kasarov <bkasarov@gmail.com>.
107267 2009-11-02  Eric Blake  <ebb9@byu.net>
107269         maint: avoid compiler warnings in m4 macros
107270         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Avoid unused variable.
107271         * m4/rmdir.m4 (gl_FUNC_RMDIR): Include correct header.
107273 2009-11-02  Simon Josefsson  <simon@josefsson.org>
107275         * m4/pmccabe2html.m4: Remove file.
107276         * modules/pmccabe2html: Drop pmccabe2html.m4.  Don't call m4
107277         function.  Change maintainer.
107278         * build-aux/pmccabe2html: Use /bin/sh with magic instead of
107279         hard-coding path to awk.  Tiny patch from ludo@gnu.org (Ludovic
107280         Courtès).
107282 2009-10-31  Eric Blake  <ebb9@byu.net>
107284         fseeko: fix m4 regression
107285         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Use modern macro.  Fixes
107286         regression from 2009-10-27.
107287         Reported by Ralf Wildenhues.
107289 2009-10-31  Jim Meyering  <meyering@redhat.com>
107291         inttostr: aesthetics and improved (compile-time) safety
107292         Define inttype_is_signed rather than inttype_is_unsigned,
107293         since the sole use is via "#if inttype_is_signed".
107294         * lib/imaxtostr.c (inttype_is_signed): Define this, rather than
107295         inttype_is_unsigned.
107296         * lib/offtostr.c (inttype_is_signed): Likewise.
107297         * lib/uinttostr.c (inttype_is_signed): Likewise.
107298         * lib/umaxtostr.c (inttype_is_signed): Likewise.
107299         * lib/inttostr.c (inttostr): Use verify to cross-check the
107300         inttype_is_signed value and the signedness of the actual type.
107301         * modules/inttostr (Depends-on): Add verify.
107303 2009-10-30  Eric Blake  <ebb9@byu.net>
107305         build: avoid compiler warnings
107306         * lib/fchmodat.c (lchmod): Mark unused variables.
107307         * lib/getopt.c (_getopt_initialize): Likewise.
107308         * lib/mktime.c (__mktime_internal): Provide prototype.
107309         * lib/inttostr.c (inttostr): Avoid compiler warning even with
107310         older gcc that do not understand #pragma GCC diagnostic.
107311         * lib/uinttostr.c (inttype_is_unsigned): Define.
107312         * lib/umaxtostr.c (inttype_is_unsigned): Likewise.
107314 2009-10-30  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
107316         stat: fix compilation on AIX
107317         * lib/sys_stat.in.h (stat): Work with fact that large files on AIX
107318         only see struct stat64.
107320 2009-10-30  Eric Blake  <ebb9@byu.net>
107322         exclude: make more robust
107323         * lib/exclude.c (excluded_file_name): Abort on unexpected value,
107324         rather than masking a coding bug.
107325         Suggested by Bruno Haible.
107327 2009-10-30  Jim Meyering  <meyering@redhat.com>
107329         perl scripts: remove #!/usr/bin/perl in favor of more portable...
107330         Rather than putting #!/usr/bin/perl on the first line,
107331         start with a variant of what's recommended by "man perlrun" that
107332         invokes the first "perl" program from your shell's search path.
107333         * build-aux/gitlog-to-changelog: Replace #!... as above.
107334         Add a "Local Variables" perl mode setting.
107335         Prompted by a patch from Ludovic Courtès.
107336         Improved by Eric Blake.
107337         * build-aux/useless-if-before-free: Likewise.
107338         * build-aux/announce-gen: Likewise.
107339         * build-aux/update-copyright: Likewise.
107341 2009-10-29  Eric Blake  <ebb9@byu.net>
107343         filenamecat-lgpl: adjust clients
107344         * modules/linkat (Depends-on): Use filenamecat-lgpl, not
107345         filenamecat.
107346         * modules/renameat (Depends-on): Likewise.
107348         filenamecat: split into filenamecat-lgpl
107349         * modules/filenamecat-lgpl: New module.
107350         * modules/filenamecat (Files): Move library-safe files into
107351         filenamecat-lgpl.
107352         (Depends-on): Add filenamecat-lgpl.
107353         (configure.ac): Declare witness.
107354         * lib/filenamecat.h (file_name_concat): Only declare when using
107355         GPL module.
107356         * lib/filenamecat.c (longest_relative_suffix, mfile_name_concat):
107357         Move...
107358         * lib/filenamecat-lgpl.c: ...into new file.
107359         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT_LGPL): New macro.
107360         (gl_FILE_NAME_CONCAT): Use it.
107361         * MODULES.html.sh (File system functions): Mention new module.
107363         argp: avoid memory leak
107364         * modules/argp (Depends-on): Use dirname-lgpl, not dirname.
107365         * lib/argp-namefrob.h (__argp_base_name): Use last_component, not
107366         base_name, since the latter malloc()s and can call exit().
107367         Leak introduced 2006-07-03.
107369         dirname-lgpl: adjust clients that don't need full dirname
107370         * modules/backupfile (Depends-on): Use dirname-lgpl, not dirname.
107371         * modules/filenamecat (Depends-on): Likewise.
107372         * modules/linkat (Depends-on): Likewise.
107373         * modules/mkancesdirs (Depends-on): Likewise.
107374         * modules/mkdir (Depends-on): Likewise.
107375         * modules/openat (Depends-on): Likewise.
107376         * modules/savewd (Depends-on): Likewise.
107377         * modules/rename (Depends-on): Likewise.
107378         (License): Relax license.
107379         * modules/mkdir-tests (Depends-on): Drop progname.
107380         (Makefile.am): Delete unneeded LDADD.
107381         * modules/rename-tests (Depends-on, Makefile.am): Likewise.
107383         dirname: split into dirname-lgpl
107384         * modules/dirname-lgpl: New module.
107385         * modules/dirname (Files): Move library-safe files into
107386         dirname-lgpl.
107387         (Depends-on): Add dirname-lgpl.
107388         (configure.ac): Declare witness.
107389         * modules/double-slash-root (License): Relax license.
107390         * lib/dirname.h (base_name, dir_name): Only declare when using GPL
107391         module.
107392         * lib/dirname.c (dir_len, mdir_name): Move...
107393         * lib/dirname-lgpl.c: ...into new file.
107394         * lib/basename.c (last_component, base_len): Move...
107395         * lib/basename-lgpl.c: ...into new file.
107396         * m4/dirname.m4 (gl_DIRNAME_LGPL): New macro.
107397         (gl_DIRNAME): Use it.
107398         * MODULES.html.sh (Enhancements for POSIX:2008 functions):
107399         Mention new module.
107400         * modules/dirname-tests (Depends-on): Add progname.
107401         * tests/test-dirname.c (program_name): Delete.
107403         mkdir: make safe for libraries
107404         * modules/mkdir (Depends-on): Drop xalloc.
107405         * lib/mkdir.c (rpl_mkdir): Fail with ENOMEM rather than calling
107406         exit.
107408         tests: avoid some compiler warnings
107409         * tests/test-getaddrinfo.c (simple): Mark static, and allow string
107410         literals.
107411         * tests/test-memchr.c (main): Avoid type mismatch.
107412         * tests/test-arpa_inet.c (main): Avoid unused parameters.
107413         * tests/test-base64.c (main): Likewise.
107414         * tests/test-getdelim.c (main): Likewise.
107415         * tests/test-gethostname.c (main): Likewise.
107416         * tests/test-getline.c (main): Likewise.
107417         * tests/test-netinet_in.c (main): Likewise.
107418         * tests/test-select.c (open_server_socket, main): Likewise.
107419         * tests/test-select-stdin.c (main): Likewise.
107420         * tests/test-sockets.c (main): Likewise.
107421         * tests/test-strsignal.c (main): Likewise.
107422         * tests/test-sys_select.c (main): Likewise.
107423         * tests/test-sys_socket.c (main): Likewise.
107424         * tests/test-u64.c (main): Likewise.
107425         * tests/test-xfprintf-posix.c (main): Likewise.
107426         * tests/test-xvasprintf.c (test_xvasprintf, main): Likewise.
107428         sockets: avoid compiler warning
107429         * lib/sockets.c (gl_sockets_startup): Mark unused parameter.
107431         maint: detect usage(1) and other suspicious exits
107432         * top/maint.mk (sc_prohibit_magic_number_exit): New rule.
107434 2009-10-29  Jim Meyering  <meyering@redhat.com>
107436         timespec: long-to-int truncation could make timespec_cmp malfunction
107437         * lib/timespec.h (timespec_cmp): Do not interpret a difference of
107438         a multiple of 2^32 nanoseconds as no difference.
107440 2009-10-28  Jim Meyering  <meyering@redhat.com>
107442         fprintftime: wrap macro code argument in "do {...} while(0)"
107443         * lib/strftime.c (cpy) [FPRINTFTIME]: The second argument to the
107444         cpy macro must be a statement that can be followed by a semicolon.
107445         Now that the else clause contains a comment and is hence longer
107446         than one line, I require curly braces.  That in turn requires
107447         that we wrap this code block in the standard do...while(0).
107449         fprintftime: remove stray semicolon from previous change
107450         * lib/strftime.c (cpy) [FPRINTFTIME]: Remove trailing semicolon.
107452         fprintftime: avoid a warning about ignored fwrite return value
107453         * lib/strftime.c [FPRINTFTIME]: Include "ignore-value.h".
107454         (cpy) [FPRINTFTIME]: Ignore fwrite failure, even though technically,
107455         that is unsafe.
107456         * modules/fprintftime (Depends-on): Add ignore-value.
107458         exclude: avoid an unwarranted warning
107459         * lib/exclude.c (excluded_file_name): Initialize "rc" before switch.
107461 2009-10-27  Eric Blake  <ebb9@byu.net>
107463         fseek: avoid compilation failure when fflush is replaced
107464         * m4/fseek.m4 (gl_REPLACE_FSEEK): New macro.
107465         * m4/fseeko.m4 (gl_REPLACE_FSEEKO): Also replace fseek, if fseek
107466         module is in use.
107467         * lib/stdio.in.h (GNULIB_FSEEKO): Only poison fseek if fseek
107468         module is not in use; since REPLACE_FSEEK worked otherwise.
107469         (GNULIB_FTELLO): Likewise for ftell.
107470         Reported by Ian Beckwith and others.
107472 2009-10-27  Bruno Haible  <bruno@clisp.org>
107474         * lib/isnan.c (rpl_isnan[fdl]): Repeat the specification declaration.
107475         Reported by Jim Meyering.
107477 2009-10-27  Jim Meyering  <jim@meyering.net>
107478             Bruno Haible  <bruno@clisp.org>
107480         Avoid warning despite dropping the return value of fwrite.
107481         * lib/unicodeio.c: Include ignore-value.h.
107482         (fwrite_success_callback): Explicitly ignore fwrite's return value.
107483         * modules/unicodeio (Depends-on): Add ignore-value.
107485 2009-10-26  Eric Blake  <ebb9@byu.net>
107487         areadlinkat: fix fallback path
107488         * lib/at-func.c (AT_FUNC_NAME): Avoid signed comparison between
107489         pointer and zero.
107491 2009-10-22  Pádraig Brady  <P@draigBrady.com>
107493         Use a better IO block size for modern systems
107494         * lib/copy-file.c (copy_file_preserving): Used a 32KiB malloced buffer.
107495         * lib/md2.c: Likewise.
107496         * lib/md4.c: Likewise.
107497         * lib/md5.c: Likewise.
107498         * lib/sha1.c: Likewise.
107499         * lib/sha256.c: Likewise.
107500         * lib/sha512.c: Likewise.
107502 2009-10-22  Eric Blake  <ebb9@byu.net>
107504         tests: avoid several compiler warnings
107505         * tests/test-getcwd.c (main): Avoid buffer underflow.
107506         * tests/test-getdate.c (main): String literals are not safe with
107507         putenv, so use setenv.  Declare unused argument.
107508         * modules/getdate-tests (Depends-on): Add setenv.
107509         * tests/test-argv-iter.c (main): Declare unused argument.  Avoid
107510         problems with string literals in char *.
107511         * tests/test-hash.c (main): Avoid shadowing declaration.
107512         (insert_new): Treat string literals as char const *.
107513         * tests/test-getopt.h (test_getopt): Likewise.
107514         (getopt_loop): Alter types to minimize casting elsewhere.
107515         * tests/test-getopt_long.h (test_getopt_long, getopt_long_loop)
107516         (test_getopt_long_posix): Likewise.
107517         (do_getopt_long): Add wrapper to minimize casting.
107518         * tests/test-atexit.c (clear_temp_file): Use void.
107519         * tests/test-areadlink-with-size.c (main): Declare unused
107520         arguments.
107521         * tests/test-areadlink.c (main): Likewise.
107522         * tests/test-areadlinkat-with-size.c (main): Likewise.
107523         * tests/test-areadlinkat.c (main): Likewise.
107524         * tests/test-canonicalize-lgpl.c (main): Likewise.
107525         * tests/test-canonicalize.c (main): Likewise.
107526         * tests/test-dirent-safer.c (main): Likewise.
107527         * tests/test-dirname.c (main): Likewise.
107528         * tests/test-dup2.c (main): Likewise.
107529         * tests/test-fchdir.c (main): Likewise.
107530         * tests/test-fcntl-h.c (main): Likewise.
107531         * tests/test-fcntl-safer.c (main): Likewise.
107532         * tests/test-fdopendir.c (main): Likewise.
107533         * tests/test-fdutimensat.c (main): Likewise.
107534         * tests/test-fflush.c (main): Likewise.
107535         * tests/test-filenamecat.c (main): Likewise.
107536         * tests/test-filevercmp.c (main): Likewise.
107537         * tests/test-fopen-safer.c (main): Likewise.
107538         * tests/test-fopen.c (main): Likewise.
107539         * tests/test-fpending.c (main): Likewise.
107540         * tests/test-fpurge.c (main): Likewise.
107541         * tests/test-freading.c (main): Likewise.
107542         * tests/test-fstatat.c (main): Likewise.
107543         * tests/test-fsync.c (main): Likewise.
107544         * tests/test-futimens.c (main): Likewise.
107545         * tests/test-getndelim2.c (main): Likewise.
107546         * tests/test-gettimeofday.c (main): Likewise.
107547         * tests/test-getopt.c (main): Likewise.
107548         * tests/test-i-ring.c (main): Likewise.
107549         * tests/test-inttypes.c (main): Likewise.
107550         * tests/test-link.c (main): Likewise.
107551         * tests/test-lstat.c (main): Likewise.
107552         * tests/test-math.c (main): Likewise.
107553         * tests/test-md5.c (main): Likewise.
107554         * tests/test-memchr2.c (main): Likewise.
107555         * tests/test-memrchr.c (main): Likewise.
107556         * tests/test-mkdir.c (main): Likewise.
107557         * tests/test-mkdirat.c (main): Likewise.
107558         * tests/test-mkfifoat.c (main): Likewise.
107559         * tests/test-open.c (main): Likewise.
107560         * tests/test-openat-safer.c (main): Likewise.
107561         * tests/test-openat.c (main): Likewise.
107562         * tests/test-quotearg.c (main): Likewise.
107563         * tests/test-rawmemchr.c (main): Likewise.
107564         * tests/test-readlink.c (main): Likewise.
107565         * tests/test-remove.c (main): Likewise.
107566         * tests/test-rename.c (main): Likewise.
107567         * tests/test-renameat.c (main): Likewise.
107568         * tests/test-rmdir.c (main): Likewise.
107569         * tests/test-sha1.c (main): Likewise.
107570         * tests/test-signal.c (main): Likewise.
107571         * tests/test-sigaction.c (main): Likewise.
107572         * tests/test-stat.c (main): Likewise.
107573         * tests/test-stat-time.c (main): Likewise.
107574         * tests/test-stddef.c (main): Likewise.
107575         * tests/test-stdint.c (main): Likewise.
107576         * tests/test-stdio.c (main): Likewise.
107577         * tests/test-stdlib.c (main): Likewise.
107578         * tests/test-strchrnul.c (main): Likewise.
107579         * tests/test-strerror.c (main): Likewise.
107580         * tests/test-string.c (main): Likewise.
107581         * tests/test-strtod.c (main): Likewise.
107582         * tests/test-strverscmp.c (main): Likewise.
107583         * tests/test-symlink.c (main): Likewise.
107584         * tests/test-symlinkat.c (main): Likewise.
107585         * tests/test-sys_stat.c (main): Likewise.
107586         * tests/test-sys_time.c (main): Likewise.
107587         * tests/test-time.c (main): Likewise.
107588         * tests/test-unistd.c (main): Likewise.
107589         * tests/test-unlink.c (main): Likewise.
107590         * tests/test-unlinkat.c (main): Likewise.
107591         * tests/test-utimens.c (main): Likewise.
107592         * tests/test-utimensat.c (main): Likewise.
107593         * tests/test-version-etc.c (main): Likewise.
107594         * tests/test-wchar.c (main): Likewise.
107595         * tests/test-wctype.c (main): Likewise.
107596         * tests/test-xprintf-posix.c (main): Likewise.
107597         * tests/test-posixtm.c (main): Likewise.
107598         (STREQ): Delete unused macro.
107599         * tests/test-linkat.c (main): Declare unused arguments.  Avoid
107600         shadowed variables.
107601         * tests/test-memchr.c (main): Likewise.
107603 2009-10-21  Eric Blake  <ebb9@byu.net>
107605         areadlinkat: avoid failure on older glibc
107606         * lib/at-func.c (AT_FUNC_NAME): Check for explicit FUNC_FAIL,
107607         rather than mis-comparing 0 against FUNC_RESULT of char*.
107609 2009-10-21  Bruno Haible  <bruno@clisp.org>
107611         * modules/stpncpy (License): Relicense under LGPLv2+.
107612         Reported by David Lutterkort <lutter@redhat.com>.
107614 2009-10-20  Eric Blake  <ebb9@byu.net>
107616         utimensat: work around Solaris 9 bug
107617         * lib/utimens.c (fdutimens, lutimens): Force a stat if platform
107618         has trailing slash bugs.
107619         * tests/test-lutimens.h (test_lutimens): Enhance test.
107620         * tests/test-utimens.h (test_utimens): Likewise.
107621         * doc/posix-functions/utime.texi (utime): Enhance documentation.
107622         * doc/posix-functions/utimes.texi (utimes): Likewise.
107623         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
107624         * doc/glibc-functions/futimesat.texi (futimesat): Likewise.
107625         * doc/glibc-functions/lutimes.texi (lutimes): Likewise.
107626         * doc/posix-functions/futimens.texi (futimens): Likewise.
107628         fdutimensat: new module
107629         * modules/fdutimensat: New file.
107630         * lib/fdutimensat.c (fdutimensat): Likewise.
107631         * lib/utimens.h (fdutimensat, lutimensat): Declare new functions.
107632         * MODULES.html.sh (File system functions): Mention module.
107633         * modules/fdutimensat-tests: New test.
107634         * tests/test-fdutimensat.c: Likewise.
107636         doc: regenerate INSTALL
107637         * doc/INSTALL: Reflect recent autoconf update.
107638         * doc/INSTALL.ISO: Likewise.
107639         * doc/INSTALL.UTF-8: Likewise.
107641 2009-10-20  Pádraig Brady  <P@draigBrady.com>
107643         acl: warn if ACL support is not detected
107644         * m4/acl.m4 (gl_FUNC_ACL): Output a warning if ACL support is not found.
107646 2009-10-19  Giuseppe Scrivano  <gscrivano@gnu.org>
107648         * lib/nproc.h: Add extern "C" block for C++.
107650 2009-10-18  Reuben Thomas  <rrt@sc3d.org>
107651             Bruno Haible  <bruno@clisp.org>
107653         * doc/posix-functions/isascii.texi: Document the 2 alternative APIs.
107654         * doc/posix-functions/isalnum.texi: Document the 4 alternative APIs.
107655         * doc/posix-functions/isalpha.texi: Likewise.
107656         * doc/posix-functions/isblank.texi: Likewise.
107657         * doc/posix-functions/iscntrl.texi: Likewise.
107658         * doc/posix-functions/isdigit.texi: Likewise.
107659         * doc/posix-functions/isgraph.texi: Likewise.
107660         * doc/posix-functions/islower.texi: Likewise.
107661         * doc/posix-functions/isprint.texi: Likewise.
107662         * doc/posix-functions/ispunct.texi: Likewise.
107663         * doc/posix-functions/isspace.texi: Likewise.
107664         * doc/posix-functions/isupper.texi: Likewise.
107665         * doc/posix-functions/isxdigit.texi: Likewise.
107667 2009-10-18  Bruno Haible  <bruno@clisp.org>
107669         Tests for module 'isblank'.
107670         * modules/isblank-tests: New file.
107671         * tests/test-isblank.c: New file.
107673         New module 'isblank'.
107674         * lib/isblank.c: New file.
107675         * m4/isblank.m4: New file.
107676         * modules/isblank: New file.
107677         * doc/posix-functions/isblank.texi: Mention the new module.
107679 2009-10-18  Bruno Haible  <bruno@clisp.org>
107681         New module 'ctype'.
107682         * lib/ctype.in.h: New file.
107683         * m4/ctype.m4: New file.
107684         * modules/ctype: New file.
107685         * doc/posix-headers/ctype.texi: Mention the new module.
107687 2009-10-18  Jim Meyering  <meyering@redhat.com>
107689         m4: stylistic-only: hoist AC_SUBST to be adjacent to initialization
107690         Declare a variable like LIB_CLOCK_GETTIME to be AC_SUBSTituted
107691         right after its initialization, rather than farther down.
107692         Keeping these in close proximity makes it easier to ensure
107693         that each such variable is initialized.  E.g.,
107695             LIB_CLOCK_GETTIME=
107696             AC_SUBST([LIB_CLOCK_GETTIME])
107698         This change also increments these serial numbers.
107699         * m4/clock_time.m4 (gl_CLOCK_TIME): Hoist AC_SUBST use.
107700         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
107701         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
107703 2009-10-18  Bruno Haible  <bruno@clisp.org>
107705         Don't let environment variables perturb build.
107706         * m4/gethrxtime.m4 (gl_GETHRXTIME): Initialize LIB_GETHRXTIME here...
107707         (gl_PREREQ_GETHRXTIME): ... not here.
107709 2009-10-18  Bruno Haible  <bruno@clisp.org>
107711         Avoid symlink attack in localcharset module.
107712         * lib/localcharset.c: Include <fcntl.h>, <unistd.h>.
107713         (O_NOFOLLOW): Define fallback.
107714         (get_charset_aliases): Don't open the file if it is a symbolic link.
107715         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): New macro, extracted from
107716         gl_FCNTL_H.
107717         (gl_FCNTL_H): Require it.
107718         * m4/localcharset.m4 (gl_LOCALCHARSET): Likewise.
107719         * modules/localcharset (Files): Add m4/fcntl_h.m4.
107720         Reported by Fergal Glynn <fglynn@veracode.com>.
107722 2009-10-18  Bruno Haible  <bruno@clisp.org>
107724         Implement nproc for mingw.
107725         * lib/nproc.c: Include <windows.h>
107726         (num_processors): On native Windows platforms, try GetSystemInfo.
107728 2009-10-18  Bruno Haible  <bruno@clisp.org>
107730         Implement nproc for IRIX.
107731         * lib/nproc.c: Include <sys/sysmp.h>.
107732         (num_processors): On IRIX systems, try sysmp.
107733         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/sysmp.h and sysmp.
107735 2009-10-18  Bruno Haible  <bruno@clisp.org>
107737         Implement nproc for HP-UX.
107738         * lib/nproc.c: Include <sys/pstat.h>
107739         (num_processors): On HP-UX systems, try pstat_getdynamic.
107740         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/pstat.h and
107741         pstat_getdynamic.
107743 2009-10-18  Giuseppe Scrivano  <gscrivano@gnu.org>
107744             Bruno Haible  <bruno@clisp.org>
107746         Implement nproc for NetBSD, OpenBSD.
107747         * lib/nproc.c: Include <sys/types.h>, <sys/param.h>, <sys/sysctl.h>.
107748         (ARRAY_SIZE): New macro.
107749         (num_processors): On BSD systems, try sysctl of HW_NCPU.
107750         * m4/nproc.m4: New file.
107751         * modules/nproc (Files): Add m4/nproc.m4.
107752         (configure.ac): Invoke gl_NPROC. Remove AC_LIBOBJ invocation.
107753         (Makefile.am): Instead, augment lib_SOURCES.
107755 2009-10-18  Bruno Haible  <bruno@clisp.org>
107757         Fix recognition of sys/sysctl.h on OpenBSD 4.0.
107758         * m4/physmem.m4 (gl_PHYSMEM): Before including sys/sysctl.h, include
107759         sys/param.h.
107761 2009-10-16  Eric Blake  <ebb9@byu.net>
107763         utimensat: new module
107764         * modules/utimensat: New file.
107765         * lib/utimensat.c (utimensat): Likewise.
107766         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
107767         * lib/utimens.c (utimensat): Avoid recursion into rpl_utimensat,
107768         so we can work around Linux bugs.
107769         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
107770         * modules/sys_stat (Makefile.am): Substitute them.
107771         * lib/sys_stat.in.h (utimensat): Declare it.
107772         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
107773         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
107774         * modules/utimensat-tests: New test.
107775         * tests/test-utimensat.c: Likewise.
107777         utimens: let lutimens work on non-symlinks
107778         * lib/utimens.c (lutimens): Fall back to utimens rather than
107779         failing with ENOSYS, when file is not a symlink.
107780         (utimens): Reduce redirection.
107781         * tests/test-lutimens.h (test_lutimens): Update test to cover
107782         non-symlinks.
107783         * tests/test-utimens.h (test_utimens): Update test to cover
107784         symlinks.
107785         * tests/test-utimens.c (main): Update caller.
107787         utimens: cache whether utimensat syscall works
107788         * lib/utimens.c (utimensat_works_really): New cache variable.
107789         (fdutimens, lutimens): Use it to avoid failing syscall.
107791         test-stat-time, test-utimens: improve portability
107792         * tests/test-stat-time.c (nap): Lengthen delay to 20ms, for
107793         ext4 on alpha, and for cygwin.
107794         * tests/test-utimens-common.h: New file.
107795         (nap): Factor delays into single function.
107796         * tests/test-lutimens.h (test_lutimens): Use new header.
107797         * tests/test-futimens.h (test_futimens): Likewise.
107798         * tests/test-utimens.h (test_utimens): Likewise.  Also, force NFS
107799         timestamps to occur from same machine, as was done previously for
107800         test_utimens.
107801         * modules/utimens-tests (Files): Ship new file.
107802         * modules/futimens-tests (Files): Likewise.
107803         Reported in part by Jim Meyering.
107805         sys_stat: sort replacement declarations
107806         * lib/sys_stat.in.h: Sort declarations.
107807         * lib/futimens.c (futimens): Fix typo.
107809 2009-10-15  Jim Meyering  <meyering@redhat.com>
107811         don't let environment settings perturb build
107812         Setting the envvars, LIB_CLOCK_GETTIME, LIB_EACCESS or LIB_NANOSLEEP
107813         could cause a configure-time and/or build-time malfunction.
107814         Typically, a configure-time function-in-library test is performed
107815         via code like this:
107817           LIB_VAR=
107818           AC_SUBST([LIB_VAR])
107819           prefix_saved_LIBS=$LIBS
107820             AC_SEARCH_LIBS([FUNC], [LIB_NAME],
107821                        [test "$ac_cv_search_FUNC" = "none required" ||
107822                         LIB_VAR=$ac_cv_search_FUNC])
107823           LIBS=$prefix_saved_LIBS
107825         However, in each of the files affected by this change, the LIB_VAR=
107826         initialization was omitted.  Thus, when set in the environment, its
107827         value would propagate into generated Makefiles when FUNC is not found
107828         in LIB_NAME.
107829         * m4/clock_time.m4 (gl_CLOCK_TIME): Initialize AC_SUBST'd var.
107830         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
107831         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
107833 2009-10-14  Eric Blake  <ebb9@byu.net>
107835         fchdir: avoid infinite recursion in mingw
107836         * lib/fchdir.c (rpl_fstat): Call system fstat, rather than
107837         recursing.
107839         test-stat-time: port to mingw
107840         * tests/test-stat-time.c (force_unlink): Return a value.
107841         (test_ctime) [W32]: Fix compilation error.
107842         (nap): Don't call usleep with too large an argument.  Use
107843         force_unlink.
107844         * doc/pastposix-functions/usleep.texi (usleep): Document the
107845         portability issue.
107847 2009-10-13  Jim Meyering  <meyering@redhat.com>
107849         use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS in modules/*
107850         * modules/pipe-filter-gi: Use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS.
107851         * modules/pipe-filter-ii: Likewise.
107852         * modules/sys_socket-tests: Likewise.
107853         * modules/tsearch-tests: Likewise.
107854         * Makefile (sc_prefer_ac_check_funcs_once): New rule.
107855         (check): Depend on it.
107857 2009-10-12  Eric Blake  <ebb9@byu.net>
107859         utimens-tests: port to NFS file systems
107860         * tests/test-utimens.h (test_utimens): Refactor utimecmp
107861         comparisons to avoid spurious failures from timestamp drift
107862         between NFS machines.
107864 2009-10-12  Eric Blake  <ebb9@byu.net>
107866         stat-time-tests: minor cleanups
107867         * modules/stat-time-tests (configure.ac): Use AC_CHECK_FUNCS_ONCE.
107868         * tests/test-stat-time.c (nap): Separate assignment from call.
107869         Suggested by Paolo Bonzini and Bruno Haible.
107871         sys_stat: guarantee struct timespec
107872         * lib/sys_stat.in.h (includes): Always include <time.h>
107873         * modules/sys_stat (Depends-on): Add time.
107874         * tests/test-sys_stat.c: Guarantee struct timespec, as well as
107875         mode_t permission values.
107876         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document how to
107877         get at subsecond timestamps.
107879 2009-10-10  Eric Blake  <ebb9@byu.net>
107881         futimens: new module
107882         * modules/futimens: New file.
107883         * lib/futimens.c (futimens): Likewise.
107884         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Likewise.
107885         * lib/utimens.c (futimens): Avoid recursion into rpl_futimens, so
107886         we can work around Linux bugs.
107887         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
107888         * modules/sys_stat (Makefile.am): Substitute them.
107889         * lib/sys_stat.in.h (futimens): Declare it.
107890         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
107891         * doc/posix-functions/futimens.texi (futimens): Likewise.
107892         * modules/futimens-tests: New test.
107893         * tests/test-futimens.c: Likewise.
107895         utimens: introduce fdutimens
107896         * lib/utimens.h (fdutimens): New prototype.
107897         * lib/utimens.c (gl_futimens): Move guts...
107898         (fdutimens): ...to new interface.
107899         * tests/test-utimens.c (do_fdutimens): Use it.
107901         utimens: add UTIME_NOW and UTIME_OMIT support
107902         * lib/utimens.c (validate_timespec, update_timespec): New helper
107903         functions.
107904         (gl_futimens, lutimens): Use them.
107905         * modules/utimens (Depends-on): Add gettime, lstat, stat-time,
107906         stdbool, sys_stat.
107907         (Link): Mention resulting library dependency.
107908         * modules/utimecmp (Link): Likewise.
107909         * modules/utimens-tests (Depends-on): Drop stat-time, stdbool.
107910         (Makefile.am): Pick up library dependency.
107911         * lib/sys_stat.in.h (UTIME_NOW, UTIME_OMIT): Guarantee a
107912         definition.
107913         * tests/test-sys_stat.c: Test the definitions.
107914         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document this.
107915         * NEWS: Document library dependency.
107917         utimecmp: support symlink timestamps
107918         * lib/utimecmp.c (utimecmp): Use new interface.  Skip effort of
107919         hashing when possible.  Use pathconf when available.
107920         (SYSCALL_RESOLUTION): Recognize tighter resolution.
107921         * modules/utimecmp (Depends-on): Add lstat.
107923         utimens: add lutimens interface
107924         * lib/utimens.c (lutimens): New function.
107925         * m4/utimens.m4 (gl_UTIMENS): Check for lutimes.
107926         * lib/utimens.h (lutimens): Declare new interface.
107927         * tests/test-utimens.c (main): Enhance test.
107928         * tests/test-lutimens.h (test_lutimens): New file.
107929         * modules/utimens-tests (Files): Distribute it.
107930         (Depends-on): Add symlink.
107931         (configure.ac): Check for usleep.
107933         utimens: validate futimens usage
107934         * lib/utimens.c (gl_futimens): Require valid fd up front, using
107935         fewer syscalls on failure later on.  Avoid compiler warning on
107936         mingw.
107937         * modules/utimens (Depends-on): Add dup2.
107939         utimens: add test
107940         * modules/utimens-tests: New test.
107941         * tests/test-utimens.h: New file.
107942         * tests/test-futimens.h: Likewise.
107943         * tests/test-utimens.c: Likewise.
107945         doc: mention timestamp portability issues
107946         * doc/glibc-functions/lutimes.texi (lutimes): Refer to utimensat
107947         instead.
107948         * doc/posix-functions/utime.texi (utime): Likewise.
107949         * doc/posix-functions/utimes.texi (utimes): Likewise.
107950         * doc/glibc-functions/futimes.texi (futimes): Refer to futimens
107951         instead.
107952         * doc/posix-functions/futimens.texi (futimens): Mention utimens
107953         module.
107954         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
107955         Mention weakness with symlink timestamps.
107956         * doc/glibc-functions/futimesat.texi (futimesat): New file; refer
107957         to utimensat/futimens instead.
107958         * doc/gnulib.texi (Glibc sys/time.h): Include new file.
107960         test-dup2: enhance test
107961         * tests/test-dup2.c (main): Also check AT_FDCWD.
107963         test-stat-time: avoid more spurious failures
107964         * tests/test-stat-time.c (nap): Wait for 15ms rather than 2ms, for
107965         xfs; and avoid race if the two timestamps cross quantization edge.
107967         relocatable: prefer 'file system' over 'filesystem'
107968         * m4/relocatable-lib.m4 (gl_RELOCATABLE_NOP): Use AS_HELP_STRING.
107969         (gl_RELOCATABLE_LIBRARY_BODY): Fix spelling.
107970         * doc/relocatable-maint.texi (Supporting Relocation): Likewise.
107971         * doc/relocatable.texi (Enabling Relocatability): Likewise.
107972         * lib/relocatable.c (compute_curr_prefix): Likewise.
107974 2009-10-10  Jim Meyering  <meyering@redhat.com>
107976         stat-time-tests: check for the usleep function
107977         * modules/stat-time-tests (configure.ac): Now that we test HAVE_USLEEP.
107979 2009-10-10  Bruno Haible  <bruno@clisp.org>
107981         * modules/xnanosleep: Put the Link section after the Include section.
107983 2009-10-09  Eric Blake  <ebb9@byu.net>
107985         dup2: work around FreeBSD 6.1 bug
107986         * m4/dup2.m4 (gl_FUNC_DUP2): Detect bug.
107987         * doc/posix-functions/dup2.texi (dup2): Document it.
107988         Reported by Nelson H. F. Beebe and Jim Meyering.
107990         test-stat-time: port to buggy NFS clients
107991         * tests/test-stat-time.c (main) [W32]: Reduce ifdefs.
107992         (test_ctime): Also skip test if mtime and ctime are skewed.
107994         maint: prefer 'file system' over 'filesystem'
107995         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
107996         * doc/posix-functions/lstat.texi (lstat): Likewise.
107997         * lib/file-has-acl.c (file_has_acl): Likewise.
107998         * lib/fwriteerror.c [TEST]: Likewise.
107999         * tests/test-areadlink.h (test_areadlink): Likewise.
108000         * tests/test-areadlinkat-with-size.c (main): Likewise.
108001         * tests/test-areadlinkat.c (main): Likewise.
108002         * tests/test-canonicalize-lgpl.c (main): Likewise.
108003         * tests/test-canonicalize.c (main): Likewise.
108004         * tests/test-fstatat.c (main): Likewise.
108005         * tests/test-linkat.c (main): Likewise.
108006         * tests/test-lstat.h (test_lstat_func): Likewise.
108007         * tests/test-mkdir.h (test_mkdir): Likewise.
108008         * tests/test-readlink.h (test_readlink): Likewise.
108009         * tests/test-remove.c (main): Likewise.
108010         * tests/test-rename.h (test_rename): Likewise.
108011         * tests/test-renameat.c (main): Likewise.
108012         * tests/test-rmdir.h (test_rmdir_func): Likewise.
108013         * tests/test-symlink.h (test_symlink): Likewise.
108014         * tests/test-symlinkat.c (main): Likewise.
108015         * tests/test-unlink.h (test_unlink_func): Likewise.
108016         * tests/test-unlinkat.c (main): Likewise.
108018         maint: make realtime library usage explicit
108019         * modules/gethrxtime (Link): Mention LIB_GETHRXTIME.
108020         * modules/gettime (Link): Mention LIB_CLOCK_GETTIME.
108021         * modules/settime (Link): Likewise.
108022         * modules/xnanosleep (Link): Mention LIB_NANOSLEEP.
108024         test-stat-time: speed up execution
108025         * tests/test-stat-time.c (test_ctime) [!W32]: Avoid compiler
108026         warning on mingw.
108027         (nap): New helper function.
108028         (prepare_test): Use it to reduce sleep time.
108029         (test_mtime, test_ctime, test_birthtime): Allow for subsecond
108030         execution.
108031         * modules/stat-time-tests (configure.ac): Check for usleep.
108033 2009-10-09  Jim Meyering  <meyering@redhat.com>
108035         selinux-h: always use getfilecon wrappers
108036         * lib/getfilecon.c: New file.
108037         * lib/se-selinux.in.h: Use a better inclusion guard symbol name.
108038         [HAVE_SELINUX_SELINUX_H]: Include-next <selinux/selinux.h>.
108039         [!HAVE_SELINUX_SELINUX_H]: Use better parameter names.
108040         (fgetfilecon): Provide a stub.
108041         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Don't
108042         AC_SUBST SELINUX_SELINUX_H, since now we're generating that
108043         file unconditionally.
108044         When <selinux/selinux.h> is found, arrange to use wrappers.
108045         * modules/selinux-h (Files): Add getfilecon.c.
108046         (Makefile.am): Substitute include-next-related bits
108047         into the now-always-generated selinux/selinux.h file.
108048         * doc/glibc-functions/lgetfilecon.texi: New file.
108049         * doc/glibc-functions/fgetfilecon.texi: New file.
108050         * doc/glibc-functions/getfilecon.texi: New file.
108051         * doc/glibc-functions/getfilecon-desc.texi: New file.
108052         * doc/gnulib.texi (Glibc selinux/selinux.h): New section, by
108053         which to pull in the new files.
108054         * MODULES.html.sh (Misc): Add selinux-h.
108056 2009-10-08  Jim Meyering  <meyering@redhat.com>
108058         unistd: fix comment typo
108059         * lib/unistd.in.h (euidaccess): Fix a comment typo.
108061 2009-10-08  Eric Blake  <ebb9@byu.net>
108063         areadlink: use SIZE_MAX consistently
108064         * modules/areadlink (Depends-on): Add stdint.
108065         * modules/areadlink-with-size (Depends-on): Likewise.
108066         * lib/areadlink-with-size.c (includes): Drop stdio, since stdlib
108067         gives NULL; drop sys/types, since unistd gives size_t; and add
108068         stdint for SIZE_MAX.
108069         (SIZE_MAX): Rely on headers.
108070         * lib/areadlinkat-with-size.c (includes): Drop stdio, sys/types,
108071         and add stdint.
108072         * lib/areadlink.c (includes): Drop sys/types, and add stdint.
108073         (SIZE_MAX): Likewise.
108074         (INITIAL_BUF_SIZE): Turn into enum.
108075         * lib/areadlinkat.c (INITIAL_BUF_SIZE): Likewise.
108077 2009-10-08  Jim Meyering  <meyering@redhat.com>
108079         areadlinkat: avoid compilation failure
108080         * lib/areadlinkat.c: Include <stdint.h> for use of SIZE_MAX.
108081         Fix typo in comment.
108083 2009-10-07  Eric Blake  <ebb9@byu.net>
108085         areadlinkat-with-size: new module
108086         * modules/areadlinkat-with-size: New module.
108087         * lib/areadlinkat-with-size.c (areadlinkat_with_size): New file.
108088         * lib/areadlink.h (areadlinkat): Declare it.
108089         * MODULES.html.sh (File system functions): Mention it.
108090         * modules/areadlinkat-with-size-tests: New test.
108091         * tests/test-areadlinkat-with-size.c: New file.
108093         xreadlinkat: new module
108094         * modules/xreadlinkat: New module.
108095         * lib/xreadlinkat.c (xreadlinkat): New file.
108096         * lib/xreadlink.h (xreadlinkat): Declare it.
108097         * MODULES.html.sh (File system functions): Mention it.
108099         areadlinkat: new module
108100         * lib/at-func.c (FUNC_FAIL): New define.
108101         (AT_FUNC_NAME, VALIDATE_FLAG): Use it rather than raw -1.
108102         * modules/areadlinkat: New module.
108103         * lib/linkat.c (areadlinkat): Move...
108104         * lib/areadlinkat.c (areadlinkat): ...to new file.
108105         * lib/areadlink.h (areadlinkat): Declare it.
108106         * modules/linkat (Depends-on): Add areadlinkat.
108107         * MODULES.html.sh (File system functions): Mention it.
108108         * modules/areadlinkat-tests: New test.
108109         * tests/test-areadlinkat.c: New file.
108111         areadlink, areadlink-with-size: add tests
108112         * modules/areadlink-tests: New test.
108113         * modules/areadlink-with-size-tests: Likewise.
108114         * tests/test-areadlink.h: New file.
108115         * tests/test-areadlink.c: Likewise.
108116         * tests/test-areadlink-with-size.c: Likewise.
108118         maint: minor cleanups
108119         * lib/fts.c (ATTRIBUTE_UNUSED): Delete; use gnulib-guaranteed
108120         _UNUSED_PARAMETER_ instead.
108121         * lib/getdate.y (ATTRIBUTE_UNUSED): Likewise.
108122         * lib/utimens.c (ATTRIBUTE_UNUSED): Likewise.
108123         * modules/linkat-tests (Files): Distribute test-link.h.
108125         openat, utimens: whitespace cleanup
108126         * lib/openat.c: Prefer space throughout, rather than mix of 8
108127         spaces vs. tabs.
108128         * lib/at-func.c: Likewise.
108129         * lib/utimens.c: Likewise.
108131         openat: avoid using wrong fd
108132         * lib/openat.c (openat_permissive): Reject user's fd if saving the
108133         working directory chooses same fd.
108134         * lib/at-func.c (AT_FUNC_NAME): Likewise.
108136         mkdir, mkdirat: fix cygwin 1.5.x bug
108137         * lib/mkdir.c (rpl_mkdir) [FUNC_MKDIR_DOT_BUG]: Work around bug.
108138         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Move...
108139         * m4/mkdir.m4 (gl_FUNC_MKDIR): ...here, and add check for cygwin
108140         bug.
108141         (gl_PREREQ_MKDIR): Delete unused macro.
108142         * modules/mkdir (Files): Track file rename.
108143         (configure.ac): Update macro name.
108144         * modules/openat (Depends-on): Add mkdir.
108145         * doc/posix-functions/mkdir.texi (mkdir): Document the bug.
108147         mkdir, mkdirat: add tests
108148         * modules/mkdir-tests: New test.
108149         * tests/test-mkdir.h: New file.
108150         * tests/test-mkdir.c: Likewise.
108151         * tests/test-mkdirat.c: Likewise.
108152         * modules/openat-tests (Files): Add new files.
108153         (Makefile.am): Run new test.
108155 2009-10-06  Eric Blake  <ebb9@byu.net>
108157         doc: tweak *at function documentation
108158         * doc/posix-functions/faccessat.texi (faccessat): Mention
108159         known issue with replacement.
108160         * doc/posix-functions/fchdir.texi (fchdir): Likewise.
108161         * doc/posix-functions/linkat.texi (linkat): Likewise.
108162         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
108163         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
108164         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
108165         * doc/posix-functions/renameat.texi (renameat): Likewise.
108166         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
108168         openat: fix GNU/Hurd bug in unlinkat
108169         * m4/openat.m4 (gl_FUNC_OPENAT): Replace unlinkat if unlink is
108170         broken.
108171         * doc/posix-functions/unlink.texi (unlink): Document this.
108172         * doc/posix-functions/unlinkat.texi (unlinkat): Likewise.
108174         fdopendir: fix GNU/Hurd bug
108175         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for Hurd bug in
108176         allowing non-directory fds.
108177         * lib/fdopendir.c (rpl_fdopendir): Work around it.
108178         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
108179         * modules/dirent (Makefile.am): Substitute it.
108180         * lib/dirent.in.h (fdopendir): Declare replacement.
108181         * doc/posix-functions/fdopendir.texi (fdopendir): Document this.
108182         * tests/test-fdopendir.c (main): Test something other than
108183         /dev/null, since on Hurd that behaves like a directory.
108185         test-symlink: port to GNU/Hurd
108186         * tests/test-symlink.h (test_symlink): Relax expected errno.
108188         doc: tweak more cygwin information
108189         * doc/glibc-headers/getopt.texi (getopt.h): Cygwin 1.7 getopt is
108190         now compatible with glibc.
108191         * doc/posix-functions/getopt.texi (getopt): Likewise.
108193         getopt-gnu: add another test
108194         * tests/test-getopt_long.h (test_getopt_long_posix): New test, to
108195         guarantee behavior relied on by m4.
108196         * tests/test-getopt.c (main): Use it.
108197         * modules/getopt-posix-tests (Depends-on): Add setenv.
108198         See http://lists.gnu.org/r/bug-m4/2006-09/msg00028.html.
108200         getopt: fix compilation on darwin
108201         * lib/getopt.in.h (includes): Leave breadcrumbs during system
108202         include.
108203         * lib/unistd.in.h (getopt): Use them to avoid recursive include.
108204         Reported by Ludovic Courtès.
108206 2009-10-06  Bruno Haible  <bruno@clisp.org>
108208         * modules/size_max (Description): Discourage its use.
108209         Reported by Simon Josefsson.
108211 2009-10-06  Jim Meyering  <meyering@redhat.com>
108213         linkat: avoid compilation failure
108214         * lib/linkat.c: Include <stdint.h> for use of SIZE_MAX.
108216 2009-10-05  Eric Blake  <ebb9@byu.net>
108218         linkat: support Linux 2.6.17
108219         * m4/linkat.m4 (gl_FUNC_LINKAT): Default to always replacing
108220         linkat on Linux, but allow cache variable override.
108221         * lib/linkat.c (rpl_linkat): Define override.
108222         * modules/linkat (Depends-on): Add symlinkat.
108223         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add new default.
108224         * modules/unistd (Makefile.am): Substitute it.
108225         * lib/unistd.in.h (linkat): Declare replacement.
108226         Reported by Pádraig Brady.
108228         quotearg: port test to systems with C.UTF-8 locale
108229         * tests/test-quotearg.c (struct result_strings): Add another
108230         member, differentiating between C.ASCII and C.UTF-8 handling.
108231         (compare_strings): Add parameter.
108232         (main): Adjust all callers.
108234         getopt: avoid clash with FreeBSD _getopt_internal
108235         * lib/getopt.in.h (_getopt_internal): Override the name.
108236         * lib/getopt_int.h (includes): Pick up any overrides.
108237         Reported by Reuben Thomas.
108239         hash: allow C89 compilation
108240         * lib/hash.c (check_tuning): Move declaration before statement.
108241         Reported by Reuben Thomas.
108243 2009-10-05  Karl Berry  <karl@gnu.org>
108245         * doc/gnulib.texi: @include execvpe.texi, missing for several days.
108247 2009-10-04  Paolo Bonzini  <bonzini@gnu.org>
108248             Bruno Haible  <bruno@clisp.org>
108250         * lib/uname.c (uname): Use a table-driven algorithm to compute
108251         Windows NT versions.
108253 2009-10-04  Bruno Haible  <bruno@clisp.org>
108255         * lib/progname.c (set_program_name): Also remove the "lt-" prefix from
108256         program_invocation_short_name.
108257         * modules/progname (configure.ac): Test for presence of
108258         program_invocation_short_name.
108259         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
108261 2009-10-04  Bruno Haible  <bruno@clisp.org>
108263         * lib/progname.c (set_program_name): Fix comment.
108264         Reported by Jim Meyering.
108266 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
108267             Bruno Haible  <bruno@clisp.org>
108269         * lib/uname.c: Include <string.h>.
108270         (uname): Do only one call to GetVersionEx in the common case.
108272 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
108273             Bruno Haible  <bruno@clisp.org>
108275         * lib/uname.c (VER_PLATFORM_WIN32_CE, PROCESSOR_ARCHITECTURE_AMD64,
108276         PROCESSOR_ARCHITECTURE_IA32_ON_WIN64): Define fallbacks.
108277         (uname): Add support for Windows CE and various non-x86 CPU types.
108279 2009-10-03  Bruno Haible  <bruno@clisp.org>
108281         * gnulib-tool (func_create_testdir): Conditionally emit AM_PROG_CC_C_O
108282         invocation to tests/configure.ac.
108283         Reported by Ian Beckwith <ianb@erislabs.net>.
108285 2009-10-02  Eric Blake  <ebb9@byu.net>
108287         fchdir: avoid compiler warning
108288         * lib/fchdir.c (canonicalize_file_name)
108289         [!HAVE_CANONICALIZE_FILE_NAME]: Avoid compiler warning on mingw.
108291         test-open: support mingw errno values
108292         * tests/test-open.h (test_open): Relax test.
108293         * tests/test-fopen.h (test_fopen): Likewise.
108294         * tests/test-openat-safer.c (main): Likewise.
108296         open: fix opening directory on mingw
108297         * lib/open.c (open) [REPLACE_OPEN_DIRECTORY]: Correct typo.
108299         test-open: on GNU/Hurd, /dev/null is a directory
108300         * tests/test-fopen.h (main): Rename...
108301         (test_fopen): ...to this.  Use a guaranteed non-directory when
108302         confirming open behavior on trailing slash.
108303         * tests/test-openat-safer.c (main): Likewise.
108304         * tests/test-open.h (main): Likewise....
108305         (test_open): ...to this.
108306         * tests/test-fopen.c (main): Adjust caller.
108307         * tests/test-fopen-safer.c (main): Likewise.
108308         * tests/test-open.c (main): Likewise.
108309         * tests/test-fcntl-safer.c (main): Likewise.
108310         Reported by Samuel Thibault.
108312         rename, fchdir: don't ignore chdir failure
108313         * lib/fchdir.c (get_name): Abort on unexpected chdir failure.
108314         * lib/rename.c (rpl_rename) [W32]: Likewise.
108315         (rpl_rename) [RENAME_DEST_EXISTS_BUG]: Avoid one case of losing
108316         an empty destination directory if source cannot be renamed,
108317         although there is still possibility for failure.
108318         * doc/posix-functions/rename.texi (rename): Document the race.
108319         Reported by Jim Meyering.
108321         maint: cleanup whitespace in recent commits
108322         * lib/rename.c (rpl_rename): Remove tabs.
108323         * tests/test-link.h (test_link): Likewise.
108324         * lib/fchdir.c (get_name): Likewise.
108325         Reported by Jim Meyering.
108327 2009-10-02  Ben Pfaff  <blp@gnu.org>
108329         relocatable-prog-wrapper: Add missing dependency on
108330         double-slash-root.
108331         * modules/relocatable-prog-wrapper: Add dependency.
108332         Reported by Ian Beckwith <ianb@erislabs.net>.
108334 2009-10-02  Eric Blake  <ebb9@byu.net>
108336         renameat: fix Solaris bugs
108337         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Replace renameat if rename
108338         needed fixing.
108339         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): New witness.
108340         * modules/stdio (Makefile.am): Substitute it.
108341         * lib/stdio.in.h (renameat): Declare replacement.
108342         * lib/renameat.c (rpl_renameat): Implement fix.
108344         renameat: new module
108345         * modules/renameat: New file.
108346         * lib/renameat.c (renameat): Likewise.
108347         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Likewise.
108348         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
108349         * modules/stdio (Makefile.am): Substitute them.
108350         * lib/stdio.in.h (renameat): Declare it.
108351         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
108352         * doc/posix-functions/renameat.texi (renameat): Likewise.
108353         * modules/renameat-tests: New test.
108354         * tests/test-renameat.c: Likewise.
108356         rename: fix mingw bugs
108357         * lib/rename.c (rpl_rename) [W32]: Fix trailing slash and
108358         directory overwrite bugs.
108360         rename: fix another cygwin 1.5 bug
108361         * m4/rename.m4 (gl_FUNC_RENAME): Split cygwin bugs into two
108362         checks.
108363         * lib/rename.c (rpl_rename): Don't penalize NetBSD with
108364         unnecessary cygwin workarounds.  Also work around bug with moving
108365         full directory onto an empty one.
108366         * modules/rename (Depends-on): Add canonicalize-lgpl, rmdir.
108368         rename-dest-slash: merge into rename module
108369         * modules/rename-dest-slash (Status): Mark obsolete.
108370         (Depends-on): Add rename.
108371         (Files): Let rename do it all.
108372         * m4/rename.m4 (gl_FUNC_RENAME): Also test for NetBSD bugs,
108373         subsuming the test from gl_FUNC_RENAME_TRAILING_DEST_SLASH...
108374         * m4/rename-dest-slash.m4: ...so this file can be deleted.
108375         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Delete.
108376         * lib/rename.c (rpl_rename): Update comments.
108378         rename: fix cygwin 1.5.x bugs
108379         * m4/rename.m4 (gl_FUNC_RENAME): Detect cygwin bugs.
108380         * lib/rename.c (rpl_rename): Work around them.
108381         * modules/rename (Depends-on): Add same-inode.
108383         rename: fix Solaris 10 bug
108384         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
108385         * lib/rename.c (rpl_rename): Don't cripple POSIX behavior if this
108386         was the only bug.
108388         rename: fix Solaris 9 bug
108389         * lib/rename.c (rpl_rename): Rewrite to recognize trailing slash
108390         on non-directory.  Avoid calling exit.
108391         * modules/rename (Depends-on): Drop xalloc; add lstat, stdbool,
108392         strdup.
108393         * modules/rename-tests (Depends-on): Drop lstat.
108394         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
108395         (gl_PREREQ_RENAME): Delete unused macro.
108397         rename-dest-slash: fix NetBSD bug
108398         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Detect hard
108399         links.
108400         * modules/rename-dest-slash (Depends-on): Add same-inode.
108402         rename-tests: new test, exposes several platform bugs
108403         * modules/rename-tests: New file.
108404         * tests/test-rename.h: Likewise.
108405         * tests/test-rename.c: Likewise.
108406         * doc/posix-functions/rename.texi (rename): Improve documentation,
108407         including bugs that will eventually be fixed in gnulib.
108409 2009-10-02  Paolo Bonzini  <bonzini@gnu.org>
108411         * lib/uname.c: Include <stdlib.h>
108412         (uname): Assume version info is available.
108414 2009-10-02  Jim Meyering  <meyering@redhat.com>
108416         gnu-web-doc-update: correct --help output
108417         * build-aux/gnu-web-doc-update: Make --help output relevant.
108419         gnu-web-doc-update: add standard options
108420         * build-aux/gnu-web-doc-update: Add --help, --version, etc.
108422         gnu-web-doc-update: New module.
108423         Use this script to automatically update the on-line web documentation
108424         for your GNU project at http://www.gnu.org/software/$pkg/manual/
108425         * modules/gnu-web-doc-update: New file, from coreutils.
108426         * build-aux/gnu-web-doc-update: New script.
108428 2009-10-01  Paolo Bonzini  <bonzini@gnu.org>
108430         link: LoadLibrary is not needed.
108431         * lib/link.c: Use GetModuleHandle.
108433 2009-10-01  Eric Blake  <ebb9@byu.net>
108435         getopt: bump serial number
108436         * m4/getopt.m4: Increment serial number, to account for 2009-09-24
108437         change.
108439         tests: tighten link, rmdir, and remove tests
108440         * tests/test-link.h (includes): No need to use <config.h> here.
108441         Clean up if directory hard link was created, otherwise test for
108442         trailing '.'.
108443         * tests/test-linkat.c (main): Simplify.
108444         * tests/test-remove.c (main): Enhance test for trailing '.'.
108445         * tests/test-rmdir.h (test_rmdir_func): Likewise.
108447 2009-10-01  Jim Meyering  <meyering@redhat.com>
108449         maint.mk: requiring "make major" was annoying, for a "minor" release.
108450         What is intended is "stable", to contrast with alpha and beta,
108451         so require "make stable", not "make major".
108452         * build-aux/announce-gen (%valid_release_types): s/major/stable/.
108453         (get_tool_versions): Likewise.
108454         * top/maint.mk (ALL_RECURSIVE_TARGETS): s/major/stable/
108456 2009-09-30  Ben Pfaff  <blp@gnu.org>
108458         Fix broken build of replacement for Windows tmpfile().
108459         * lib/tmpfile.c (tmpfile): Fix call to gen_tempname() to provide
108460         flags argument added along with the 'mkostemp' module.
108462 2009-09-28  Bruno Haible  <bruno@clisp.org>
108464         Avoid identifier clash with POSIX function 'remove' defined as a macro.
108465         * lib/gl_list.h (struct gl_list_implementation): Rename field 'remove'
108466         to 'remove_elt'.
108467         (gl_list_remove): Update.
108468         * lib/gl_list.c (gl_list_remove): Update.
108469         * lib/gl_oset.h (struct gl_oset_implementation): Rename field 'remove'
108470         to 'remove_elt'.
108471         (gl_oset_remove): Update.
108472         * lib/gl_list.c (gl_oset_remove): Update.
108473         Reported by Eric Blake.
108475 2009-09-28  Eric Blake  <ebb9@byu.net>
108477         doc: mention yet more cygwin 1.7 status
108478         * doc/posix-functions/fexecve.texi (fexecve): Now implemented in
108479         cygwin.
108480         * doc/glibc-functions/execvpe.texi (execvpe): New file.
108481         * doc/gnulib.texi (Glibc unistd.h): Mention it.
108483         argp: fix test failure
108484         * lib/argp-help.c (hol_entry_cmp): Don't use _tolower on values
108485         that are not upper-case.  Pass correct range to tolower.
108487 2009-09-27  Jim Meyering  <meyering@redhat.com>
108489         test-yesno: work around sparc-dash here-document infelicity
108490         Without this change, the literal \177 byte in a here document
108491         would make dash 0.5.5.1-3 access uninitialized memory.
108492         * tests/test-yesno.sh: Don't put the \177 byte in the here document.
108493         Instead, use a marker, "@", and filter through tr to create the desired
108494         contents.  Reported as <http://bugs.debian.org/548493> by Kurt Roeckx.
108496 2009-09-27  Bruno Haible  <bruno@clisp.org>
108498         Disable untested support for new flavours of ACLs on AIX.
108499         * lib/file-has-acl.c (file_has_acl): Mark newer AIX code as work in
108500         progress.
108501         * lib/set-mode-acl.c (qset_acl): Likewise.
108503 2008-12-07  Bruno Haible  <bruno@clisp.org>
108505         Add support for new flavours of ACLs on AIX. (Untested.)
108506         * lib/file-has-acl.c [AIX] (acl_nfs4_nontrivial): New function.
108507         (file_has_acl): Add support for newer AIX.
108508         * lib/set-mode-acl.c (qset_acl): Likewise.
108509         * tests/test-sameacls.c (main): Fix use of aclx_get function. Hint by
108510         Rainer Tammer <tammer@tammer.net>.
108512 2009-09-26  Eric Blake  <ebb9@byu.net>
108514         argp: fix compilation of getopt
108515         * lib/getopt.in.h (includes): Use different guard than glibc.
108516         Reported by Sergey Poznyakoff.
108518         doc: mention more cygwin 1.7 status
108519         * doc/posix-functions/access.texi (access): Mention cygwin 1.5
108520         bug.
108521         * doc/posix-functions/execl.texi (execl): Likewise.
108522         * doc/posix-functions/execle.texi (execle): Likewise.
108523         * doc/posix-functions/execlp.texi (execlp): Likewise.
108524         * doc/posix-functions/execv.texi (execv): Likewise.
108525         * doc/posix-functions/execve.texi (execve): Likewise.
108526         * doc/posix-functions/execvp.texi (execvp): Likewise.
108527         * doc/glibc-functions/canonicalize_file_name.texi
108528         (canonicalize_file_name): Cygwin 1.7 now provides this.
108529         * doc/glibc-functions/euidaccess.texi (euidaccess): Likewise.
108530         * doc/posix-functions/fchmodat.texi (fchmodat): Mention limitation
108531         on AT_SYMLINK_NOFOLLOW.
108533 2009-09-24  Eric Blake  <ebb9@byu.net>
108535         test-linkat: make test more robust
108536         * tests/test-linkat.c (main): Avoid collision with EEXIST.
108538         getopt: fix inclusion guards for cygwin
108539         * modules/getopt-posix (Depends-on): Add include-next.
108540         (Makefile.am): Substitute more items in replacement header.
108541         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Also check for native
108542         <getopt.h>.
108543         * lib/getopt.in.h (includes): Use split inclusion guard, and
108544         prefer <getopt.h> over include <unistd.h> when one is present.
108545         (option): Also override name of 'struct option'.
108547         same-inode: revert prior change; it is not yet ready
108548         * NEWS: Undo mention of this change.
108549         * lib/same-inode.h (same-inode.h): Undo tri-state change.
108550         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
108551         * lib/cycle-check.c (cycle_check): Likewise.
108552         * lib/same.c (same_name): Likewise.
108553         * lib/at-func2.c (at_func2): Likewise.
108555 2009-09-23  Eric Blake  <ebb9@byu.net>
108557         linkat: new module
108558         * modules/linkat: New file.
108559         * lib/at-func2.c (at_func2): Likewise.
108560         * lib/linkat.c (linkat): Likewise.
108561         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
108562         * lib/openat-priv.h (at_func2): Add declaration.
108563         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
108564         * modules/unistd (Makefile.am): Substitute them.
108565         * lib/unistd.in.h (linkat): Declare it.
108566         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
108567         * doc/posix-functions/linkat.texi (linkat): Likewise.
108568         * doc/posix-functions/link.texi (link): Tweak wording.
108569         * tests/test-link.c (main): Move guts...
108570         * tests/test-link.h (test_link): ...into new file.
108571         * modules/linkat-tests: New test.
108572         * tests/test-linkat.c: Likewise.
108573         * modules/link-tests (Files): Ship new file.
108574         (Depends-on): Add stdbool.
108576         dirname: add library-safe mdir_name
108577         * lib/dirname.h (mdir_name): New prototype.
108578         * lib/dirname.c (dir_name): Move guts...
108579         (mdir_name): ...to new function that avoids xalloc_die.
108581         fchdir: another mingw fix
108582         * modules/fchdir (Depends-on): Drop canonicalize-lgpl.
108583         * lib/fchdir.c (get_name): New helper method; skips canonicalize
108584         on mingw (where it has not yet been ported), and make it optional
108585         elsewhere.
108586         (_gl_register_fd): Use it.
108588         same-inode: make SAME_INODE tri-state, to port to mingw
108589         * NEWS: Mention this change.
108590         * lib/same-inode.h (same-inode.h): Recognize mingw limitation of
108591         st_ino always being 0.
108592         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
108593         * lib/cycle-check.c (cycle_check): Likewise.
108594         * lib/same.c (same_name): Likewise.
108596         lstat: avoid mingw compilation error
108597         * m4/lstat.m4 (gl_FUNC_LSTAT): Avoid duplicate calls to
108598         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, and deal with missing
108599         lstat ourselves.
108600         * lib/lstat.c [!HAVE_LSTAT]: Do nothing if <sys/stat.h> override
108601         was adequate.
108602         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Let lstat module handle
108603         the checks for lstat.
108604         (gl_SYS_STAT_H_DEFAULTS): Set default for HAVE_LSTAT.
108606         link: fix test failure on Solaris 9
108607         * lib/link.c (rpl_link): Don't assume link will catch bogus
108608         trailing slash on source.
108610         test-symlinkat: enhance test
108611         * tests/test-readlink.c (main): Move guts...
108612         * tests/test-readlink.h (test_readlink): ...into new file.
108613         * tests/test-symlink.c (main): Move guts...
108614         * tests/test-symlink.h (test_symlink): ...into new file.
108615         * tests/test-symlinkat.c (main): Use new files for further
108616         coverage.
108617         (do_symlink, do_readlink): New helper functions.
108618         * modules/symlink-tests (Files): Ship new file.
108619         (Depends-on): Add stdbool.
108620         * modules/readlink-tests (Files): Ship new file.
108621         (Depends-on): Add stdbool.
108622         * modules/symlinkat-tests (Files): Use new files.
108624 2009-09-23  Eric Blake  <ebb9@byu.net>
108626         readlink: document portability issue with symlink length
108627         * doc/posix-functions/lstat.texi (lstat): Mention that some file
108628         systems have bogus st_size on symlinks, and mention the
108629         areadlink-with-size module.
108630         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
108631         * doc/posix-functions/readlink.texi (readlink): Mention the
108632         areadlink module, and ERANGE failure.
108633         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
108634         * tests/test-readlink.c (main): Relax test for AIX, HP-UX.
108636         readlink: fix Solaris 9 bug with trailing slash
108637         * lib/readlink.c (rpl_readlink): Work around trailing slash bug.
108638         * m4/readlink.m4 (gl_FUNC_READLINK): Detect the bug.
108639         * doc/posix-functions/readlink.texi (readlink): Document this.
108640         * modules/readlink-tests: New test.
108641         * tests/test-readlink.c: Likewise.
108643         readlink: fix cygwin 1.5.x bug with return type
108644         * m4/readlink.m4 (gl_FUNC_READLINK): Require correct signature.
108645         * lib/unistd.in.h (readlink): Use ssize_t.
108646         * lib/readlink.c (readlink): Likewise.
108647         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
108648         * modules/unistd (Makefile.am): Substitute it.
108649         * lib/unistd.in.h (readlink): Declare replacement.
108650         * doc/posix-functions/readlink.texi (readlink): Document this.
108652         symlink: use throughout gnulib
108653         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Omit symlink check.
108654         * lib/symlinkat.c (symlinkat) [!HAVE_SYMLINK]: Document why
108655         symlink is not used.
108656         * modules/symlinkat (Depends-on): Add symlink.
108657         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
108658         * modules/canonicalize-tests (Depends-on): Likewise.
108659         * modules/lstat-tests (Depends-on): Likewise.
108660         * modules/openat-tests (Depends-on): Likewise.
108661         * modules/remove-tests (Depends-on): Likewise.
108662         * modules/rmdir-tests (Depends-on): Likewise.
108663         * modules/unlink-tests (Depends-on): Likewise.
108664         * tests/test-canonicalize-lgpl.c (symlink): Delete stub.
108665         * tests/test-canonicalize.c (symlink): Likewise.
108666         * tests/test-fstatat.c (symlink): Likewise.
108667         * tests/test-lstat.c (symlink): Likewise.
108668         * tests/test-remove.c (symlink): Likewise.
108669         * tests/test-rmdir.c (symlink): Likewise.
108670         * tests/test-unlink.c (symlink): Likewise.
108671         * tests/test-unlinkat.c (symlink): Likewise.
108673         symlink: new module, for Solaris 9 bug
108674         * modules/symlink: New file.
108675         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
108676         * lib/symlink.c: Likewise.
108677         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
108678         * modules/unistd (Makefile.am): Substitute them.
108679         * lib/unistd.in.h (symlink): Declare replacement.
108680         * MODULES.html.sh (File system functions): Mention it.
108681         * doc/posix-functions/symlink.texi (symlink): Likewise.
108682         * modules/symlink-tests: New test.
108683         * tests/test-symlink.c: Likewise.
108685 2009-09-23  Bruno Haible  <bruno@clisp.org>
108687         * gnulib-tool (func_import): Add 'link-warning' to testsrelated_modules
108688         when needed.
108689         Test case: gnulib-tool --import --with-tests atexit inttypes.
108690         Reported by Pauli Miettinen <pauli.miettinen@cs.helsinki.fi>.
108692 2009-09-23  Bruno Haible  <bruno@clisp.org>
108694         * gnulib-tool (func_emit_tests_Makefile_am): Set uses_subdirs in a
108695         subcommand, not in a subshell.
108697 2009-09-22  Eric Blake  <ebb9@byu.net>
108699         unistd: sort replacement declarations
108700         * lib/unistd.in.h: Sort declarations.
108702         open, openat: minor optimization
108703         * lib/open.c (open): If open succeeded, len is non-zero.
108704         * lib/openat.c (rpl_openat): Likewise.
108706         link-follow: ensure correct result
108707         * m4/fcntl_h.m4 (gl_FCNTL_H): Clean up temporary file.
108708         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Likewise, and
108709         distinguish between possible failures.
108711 2009-09-21  Eric Blake  <ebb9@byu.net>
108713         fts: avoid compiler warning
108714         * lib/fts.c (dirent_inode_sort_may_be_useful)
108715         (leaf_optimization_applies) [!__linux__]: Mark unused parameters.
108717 2009-09-19  Bruno Haible  <bruno@clisp.org>
108719         * lib/progreloc.c (canonicalize_file_name): New declaration.
108721 2009-09-19  Eric Blake  <ebb9@byu.net>
108723         link: fix quoting
108724         * m4/link.m4 (gl_FUNC_LINK): Fix shell quoting.
108726         openat: fix openat bugs on Solaris 9
108727         * lib/openat.c (rpl_openat): Work around Solaris 9 bug.
108728         * m4/openat.m4 (gl_FUNC_OPENAT): Also replace openat on Solaris.
108729         * modules/openat (Depends-on): Add open.
108730         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Provide new default.
108731         * modules/fcntl-h (Makefile.am): Substitute it.
108732         * lib/fcntl.in.h (openat): Declare replacement.
108733         * doc/posix-functions/openat.texi (openat): Document this.
108735         openat: move fstatat and unlinkat into correct files
108736         * m4/openat.m4 (gl_FUNC_OPENAT): Adjust which files will be
108737         compiled.
108738         * lib/openat.c (fstatat, unlinkat): Move...
108739         * lib/fstatat.c (fstatat): ...into correct files.
108740         * lib/unlinkat.c (unlinkat): Likewise.
108742         openat: fix unlinkat bugs on Solaris 9
108743         * lib/unlinkat.c (unlinkat): New file.
108744         * modules/openat (Depends-on): Add unlink.
108745         (Files): Distribute it.
108746         * m4/openat.m4 (gl_FUNC_OPENAT): Mark unlinkat for replacement if
108747         trailing slash behavior is broken.
108748         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
108749         * modules/unistd (Makefile.am): Substitute it.
108750         * lib/unistd.in.h (unlinkat): Declare replacement.
108751         * doc/posix-functions/unlinkat.texi (unlinkat): Document this.
108753         openat: fix fstatat bugs on Solaris 9
108754         * lib/fstatat.c (rpl_fstatat): Copy recent fixes from lstat and
108755         stat.
108756         * doc/posix-functions/fstatat.texi (fstatat): Document this.
108758         test-unlinkat: enhance test, to expose Solaris 9 bug
108759         * tests/test-unlink.c (main): Factor guts...
108760         * tests/test-unlink.h (test_rmdir_func): ...into new file.
108761         * tests/test-rmdir.h (test_rmdir_func): Add parameter.
108762         * tests/test-rmdir.c (main): Adjust caller.
108763         * tests/test-unlinkat.c (main): Likewise.  Add unlink tests.
108764         (unlinker): New helper function.
108765         (rmdirat): Enhance check.
108766         * modules/rmdir-tests (Depends-on): Add stdbool.
108767         * modules/unlink-tests (Depends-on): Likewise.
108768         (Files): Add test-unlink.h.
108769         * modules/openat-tests (Files): Likewise.
108770         (Depends-on): Add unlinkdir.
108772         test-fstatat: new test, to expose Solaris 9 bugs
108773         * tests/test-stat.c (main): Factor guts...
108774         * tests/test-stat.h (test_stat_func): ...into new file.
108775         * tests/test-lstat.c (main): Factor guts...
108776         * tests/test-lstat.h (test_lstat_func): ...into new file.
108777         * tests/test-fstatat.c: New file.
108778         * modules/stat-tests (Files): Add test-stat.h.
108779         * modules/lstat-tests (Files): Add test-lstat.h.
108780         (Depends-on): Add stdbool.
108781         * modules/openat-tests (Depends-on): Add pathmax.
108782         (Files): Add test-lstat.h, test-stat.h, test-fstatat.c.
108783         (Makefile.am): Run new test.
108785         remove: new module, for mingw and Solaris 9 bugs
108786         * modules/remove: New file.
108787         * lib/remove.c: Likewise.
108788         * m4/remove.m4 (gl_FUNC_REMOVE): Likewise.
108789         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
108790         * modules/stdio (Makefile.am): Use them.
108791         * lib/stdio.in.h (remove): Declare replacement.
108792         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
108793         * doc/posix-functions/remove.texi (remove): Likewise.
108794         * modules/remove-tests: New test.
108795         * tests/test-remove.c: Likewise.
108797         unlink: new module, for Solaris 9 bug
108798         * modules/unlink: New file.
108799         * lib/unlink.c: Likewise.
108800         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
108801         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
108802         * modules/unistd (Makefile.am): Use them.
108803         * lib/unistd.in.h (stat): Declare replacement.
108804         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
108805         * doc/posix-functions/unlink.texi (unlink): Likewise.
108806         * modules/unlink-tests: New test.
108807         * tests/test-unlink.c: Likewise.
108809         lstat: fix Solaris 9 bug
108810         * lib/lstat.c (lstat): Also check for trailing slash on
108811         non-symlink, non-directories.  Use stat module to simplify logic.
108812         * doc/posix-functions/lstat.texi (lstat): Document it.
108813         * modules/lstat-tests (Depends-on): Add errno, same-inode.
108814         (configure.ac): Check for symlink.
108815         * tests/test-lstat.c (main): Add more tests.
108817         stat: add as dependency to other modules
108818         * modules/chown (Depends-on): Add stat.
108819         * modules/euidaccess (Depends-on): Likewise.
108820         * modules/fchdir (Depends-on): Likewise.
108821         * modules/isdir (Depends-on): Likewise.
108822         * modules/link (Depends-on): Likewise.
108823         * modules/lstat (Depends-on): Likewise.
108824         * modules/mkdir-p (Depends-on): Likewise.
108825         * modules/modechange (Depends-on): Likewise.
108826         * modules/open (Depends-on): Likewise.
108827         * modules/readlink (Depends-on): Likewise.
108828         * modules/same (Depends-on): Likewise.
108830         stat: fix Solaris 9 bug
108831         * m4/stat.m4 (gl_FUNC_STAT): Detect Solaris 9 bug with trailing
108832         slash.
108833         * lib/stat.c (rpl_stat): Work around it.
108834         * doc/posix-functions/stat.texi (stat): Update documentation.
108836         stat: new module, for mingw bug
108837         * modules/stat: New file.
108838         * lib/stat.c: Likewise.
108839         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
108840         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
108841         * modules/sys_stat (Makefile.am): Use them.
108842         * lib/sys_stat.in.h (stat): Declare replacement.
108843         * lib/openat.c (fstatat): Deal with lstat and stat being function
108844         macros.
108845         * modules/openat (Depends-on): Add inline.
108846         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
108847         * doc/posix-functions/stat.texi (stat): Likewise.
108848         * modules/stat-tests: New test.
108849         * tests/test-stat.c: Likewise.
108851 2009-09-19  Jim Meyering  <meyering@redhat.com>
108853         syntax-check: detect unnecessary inclusion of canonicalize.h
108854         * top/maint.mk (sc_prohibit_canonicalize_without_use): New rule.
108856 2009-09-19  Eric Blake  <ebb9@byu.net>
108858         canonicalize-lgpl: adjust clients to use correct header
108859         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
108860         (gl_CANONICALIZE_LGPL): Use correct shell quoting.
108861         * modules/relocatable-prog-wrapper (Files): Drop canonicalize.h.
108862         * lib/fchdir.c (includes): Use <stdlib.h>, not "canonicalize.h".
108863         * lib/progreloc.c (includes): Likewise.
108865 2009-09-19  Jim Meyering  <meyering@redhat.com>
108867         test-posixtm.c: correct a comment
108868         * tests/test-posixtm.c: Correct first-line comment.
108869         Spotted by Eric Blake.
108871 2009-09-16  Jim Meyering  <meyering@redhat.com>
108873         posixtm-tests: make T const-correct; add a test case
108874         * tests/test-posixtm.c (T): Declare const.
108875         Add a test for -(2^31+1).
108876         Remove useless can-succeed-only-in-2002 test.
108878         posixtm-tests: adjust the sole failing test
108879         * tests/test-posixtm.c: Correct 0000-01-01 00:00:00 test so that
108880         expected output matches what mktime now produces.  Cross-checked via
108881         erlang's calendar:datetime_to_gregorian_seconds({{1970,1,1},{0,0,0}})
108883         posixtm: move #ifdef'd tests into a new module
108884         * lib/posixtm.c (posixtime): Remove #ifdef'd tests.  Move to...
108885         * tests/test-posixtm.c: ... this new file.
108886         * modules/posixtm-tests: New module.
108888 2009-09-19  Eric Blake  <ebb9@byu.net>
108890         openat: simplify use of at-func.c
108891         * lib/at-func.c (includes): Include prerequisites here, to
108892         simplify requirements on client files.
108893         * lib/openat-priv.h: Add double-inclusion guard.
108894         * lib/faccessat.c (includes): Simplify.
108895         * lib/fchmodat.c (includes): Likewise.
108896         * lib/fchownat.c (includes): Likewise.
108897         * lib/mkdirat.c (includes): Likewise.
108898         * lib/mkfifoat.c (includes): Likewise.
108899         * lib/symlinkat.c (includes): Likewise.
108901         openat: allow return of fd 0
108902         * modules/chdir-long (Depends-on): Relax openat-safer to openat.
108903         * modules/save-cwd (Depends-on): Replace fcntl-safer with
108904         unistd-safer.
108905         * lib/chdir-long.c (includes): Replace "fcntl--.h" with
108906         <fcntl.h>; this module does not leak fds.
108907         * lib/openat.c (includes): Do not use "fcntl_safer"; plain openat
108908         must be allowed to return 0, leaving openat_safer to add the
108909         safety.
108910         (openat_permissive): Avoid writing to just-opened fd 2 if
108911         restoring the current directory fails.
108912         * lib/openat-die.c (openat_restore_fail): Add comment.
108913         * lib/save-cwd.c (includes): Make "fcntl--.h" conditional.
108914         (save_cwd): Guarantee safe fd, but without use of open_safer.
108915         * tests/test-openat.c: New test.
108916         * modules/openat-tests (Files, Makefile.am): Distribute and build
108917         new file.
108919         relocatable-prog-wrapper: fix build
108920         * modules/relocatable-prog-wrapper (Files): Update name of
108921         canonicalize m4 file, broken on 2009-09-17.
108922         Reported by emad hajjar <aleppos@hotmail.com>.
108924 2009-09-19  Bruno Haible  <bruno@clisp.org>
108926         * lib/safe-alloc.h: Use the standard header with GPL copyright.
108927         * lib/safe-alloc.c: Likewise.
108928         Reported by Ian Beckwith <ianb@erislabs.net>.
108930 2009-09-18  Bruno Haible  <bruno@clisp.org>
108932         * gnulib-tool: Add advice to "cannot find configure.ac" error message.
108933         Reported by <erobles@sensacd.com.mx>.
108935 2009-09-17  Eric Blake  <ebb9@byu.net>
108937         canonicalize: in CAN_ALL_BUT_LAST, allow trailing slash
108938         * lib/canonicalize.c (canonicalize_filename_mode): Skip trailing
108939         slashes when checking if last component is missing.
108940         * tests/test-canonicalize.c (main): Test this.
108942         canonicalize, canonicalize-lgpl: honor // if distinct from /
108943         * modules/canonicalize (Files): Add double-slash-root.m4.
108944         * modules/canonicalize-lgpl (Files): Likewise.
108945         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
108946         (gl_CANONICALIZE_LGPL_SEPARATE): Add dependency.
108947         * lib/canonicalize.c (DOUBLE_SLASH_IS_DISTINCT_ROOT): Provide
108948         fallback definition.
108949         (canonicalize_filename_mode): Use it to protect //.
108950         * lib/canonicalize-lgpl.c (DOUBLE_SLASH_IS_DISTINCT_ROOT)
108951         (__realpath): Likewise.
108952         * tests/test-canonicalize.c (main): Test this.
108953         * tests/test-canonicalize-lgpl.c (main): Likewise.
108954         * modules/canonicalize-tests (Depends-on): Add same-inode.
108955         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
108957         canonicalize-lgpl: fix glibc bug with trailing slash
108958         * m4/canonicalize-lgpl.m4: Move contents...
108959         * m4/canonicalize.m4: ...here.
108960         (gl_CANONICALIZE_LGPL): Factor realpath check...
108961         (gl_FUNC_REALPATH_WORKS): ...into new macro.  Enhance to catch
108962         glibc 2.3.5 bug, fixed 2005-04-27.
108963         (gl_FUNC_CANONICALIZE_FILENAME_MODE): Use it.
108964         (gl_PREREQ_CANONICALIZE_LGPL): Inline...
108965         (gl_CANONICALIZE_LGPL_SEPARATE): ...into this macro.
108966         * modules/canonicalize-lgpl (Files): Manage file rename.
108967         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
108968         * modules/stdlib (Makefile.am): Substitute witness.
108969         * lib/stdlib.in.h (canonicalize_file_name): Declare if replacement
108970         is needed.
108971         * lib/canonicalize-lgpl.c: Also compile if canonicalize_file_name
108972         replacement is required.
108973         * lib/canonicalize.c (canonicalize_file_name): Likewise.
108974         * doc/glibc-functions/canonicalize_file_name.texi
108975         (canonicalize_file_name): Document this.
108976         * doc/posix-functions/realpath.texi (realpath): Likewise.
108978         canonicalize-lgpl: reject non-directory with trailing slash
108979         * lib/canonicalize-lgpl.c (__realpath): Synchronize with glibc.
108980         * tests/test-canonicalize-lgpl.c (main): Enhance test.  This
108981         catches failures in glibc 2.3.5.
108982         * tests/test-canonicalize.c (main): Likewise.
108984         canonicalize-lgpl: use native realpath if it works
108985         * lib/canonicalize-lgpl.c (realpath): Guard with
108986         FUNC_REALPATH_WORKS.
108987         * lib/stdlib.in.h (realpath): Make declaration optional based on
108988         HAVE_REALPATH.
108989         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Check whether
108990         native realpath works.
108991         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
108992         * modules/stdlib (Makefile.am): Substitute witness.
108994         canonicalize, canonicalize-lgpl: use <stdlib.h>
108995         * modules/canonicalize-lgpl (Files): Drop canonicalize.h.
108996         (Include): Mention <stdlib.h>.
108997         (configure.ac): Mention functions we provide.
108998         * modules/canonicalize (configure.ac): Likewise.
108999         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Always replace
109000         realpath if canonicalize_file_name is missing.
109001         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide defaults.
109002         * modules/stdlib (Makefile.am): Substitute witnesses.
109003         * lib/stdlib.in.h (canonicalize_file_name, realpath): Declare.
109004         * lib/canonicalize-lgpl.c (includes): Adjust accordingly.
109005         * lib/canonicalize.h (canonicalize_file_name): Drop declaration.
109006         * NEWS: Document this.
109007         * doc/glibc-functions/canonicalize_file_name.texi
109008         (canonicalize_file_name): Likewise.
109009         * doc/posix-functions/realpath.texi (realpath): Likewise.
109010         * tests/test-canonicalize-lgpl.c (includes): Use <stdlib.h>.
109012         test-canonicalize: consolidate into single C program
109013         * tests/test-canonicalize.sh: Delete; move setup into...
109014         * tests/test-canonicalize.c (main): ...the program, making it
109015         easier to run in debugger.  Add some tests.
109016         * modules/canonicalize-tests (Files): Remove unused file.
109017         (Depends-on): Add progname.
109018         (configure.ac, Makefile.am): Simplify.
109020         test-canonicalize-lgpl: consolidate into single C program
109021         * tests/test-canonicalize-lgpl.sh: Delete; move setup into...
109022         * tests/test-canonicalize-lgpl.c (main): ...the program, making it
109023         easier to run in debugger.  Add some tests.
109024         * modules/canonicalize-lgpl-tests (Files): Remove unused file.
109025         (configure.ac, Makefile.am): Simplify.
109027         canonicalize: avoid resolvepath
109028         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Delete
109029         unnecessary checks.
109030         * lib/canonicalize.c (includes): Simplify.
109031         (canonicalize_file_name): Drop resolvepath implementation.
109032         * modules/canonicalize (Depends-on): Drop filenamecat.
109034         canonicalize: don't lose errno
109035         * lib/canonicalize.c (canonicalize_filename_mode): Protect errno
109036         over calls to free.
109038         canonicalize: simplify errno handling
109039         * lib/canonicalize.c (__set_errno): Delete macro, and use direct
109040         assignment.
109042         canonicalize, canonicalize-lgpl: update module dependencies
109043         * modules/canonicalize (Depends-on): Add extensions, lstat,
109044         pathmax, stdlib.
109045         (Files): Drop pathmax.h.
109046         (configure.ac): Adjust macro name.
109047         * modules/canonicalize-lgpl (Depends-on): Add errno, extensions,
109048         lstat, stdlib, sys_stat.
109049         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Rename...
109050         (gl_FUNC_CANONICALIZE_FILENAME_MODE): ...to this, and require
109051         extensions.
109052         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL)
109053         (gl_CANONICALIZE_LGPL_SEPARATE): Require extensions.
109054         (gl_PREREQ_CANONICALIZE_LGPL): Assume unistd.h.
109055         * lib/canonicalize.h (canonicalize_file_name): Use <stdlib.h>
109056         declaration, if available.
109057         * lib/canonicalize-lgpl.c [HAVE_READLINK]: Delete this condition;
109058         we can rely on the readlink module.
109059         (MAXSYMLINKS): Also consult SYMLOOP_MAX.
109060         (includes): Use <unistd.h> unconditionally.
109062 2009-09-17  Eric Blake  <ebb9@byu.net>
109064         maint: make Include sections of modules consistent
109065         * modules/alloca: Use only header name; no need to list #include.
109066         * modules/alloca-opt: Likewise.
109067         * modules/arpa_inet: Likewise.
109068         * modules/canon-host: Likewise.
109069         * modules/configmake: Likewise.
109070         * modules/dirent: Likewise.
109071         * modules/eealloc: Likewise.
109072         * modules/environ: Likewise.
109073         * modules/fchdir: Likewise.
109074         * modules/fcntl: Likewise.
109075         * modules/fcntl-h: Likewise.
109076         * modules/gethrxtime: Likewise.
109077         * modules/gettime: Likewise.
109078         * modules/ignore-value: Likewise.
109079         * modules/inet_ntop: Likewise.
109080         * modules/inet_pton: Likewise.
109081         * modules/inttypes: Likewise.
109082         * modules/isnand-nolibm: Likewise.
109083         * modules/isnanf-nolibm: Likewise.
109084         * modules/mbchar: Likewise.
109085         * modules/mbfile: Likewise.
109086         * modules/mbiter: Likewise.
109087         * modules/mbuiter: Likewise.
109088         * modules/netdb: Likewise.
109089         * modules/netinet_in: Likewise.
109090         * modules/nproc: Likewise.
109091         * modules/pagealign_alloc: Likewise.
109092         * modules/poll: Likewise.
109093         * modules/printf-frexp: Likewise.
109094         * modules/pthread: Likewise.
109095         * modules/putenv: Likewise.
109096         * modules/random_r: Likewise.
109097         * modules/relocatable-prog: Likewise.
109098         * modules/search: Likewise.
109099         * modules/select: Likewise.
109100         * modules/selinux-h: Likewise.
109101         * modules/settime: Likewise.
109102         * modules/signal: Likewise.
109103         * modules/size_max: Likewise.
109104         * modules/socklen: Likewise.
109105         * modules/ssize_t: Likewise.
109106         * modules/stdarg: Likewise.
109107         * modules/stdbool: Likewise.
109108         * modules/stddef: Likewise.
109109         * modules/stdint: Likewise.
109110         * modules/stdio: Likewise.
109111         * modules/stdlib: Likewise.
109112         * modules/string: Likewise.
109113         * modules/strings: Likewise.
109114         * modules/sys_file: Likewise.
109115         * modules/sys_ioctl: Likewise.
109116         * modules/sys_select: Likewise.
109117         * modules/sys_socket: Likewise.
109118         * modules/sys_stat: Likewise.
109119         * modules/sys_time: Likewise.
109120         * modules/sys_times: Likewise.
109121         * modules/sys_utsname: Likewise.
109122         * modules/sys_wait: Likewise.
109123         * modules/sysexits: Likewise.
109124         * modules/time: Likewise.
109125         * modules/times: Likewise.
109126         * modules/tmpfile: Likewise.
109127         * modules/trim: Likewise.
109128         * modules/unistd: Likewise.
109129         * modules/wchar: Likewise.
109130         * modules/wctype: Likewise.
109132 2009-09-17  Bruno Haible  <bruno@clisp.org>
109134         Make getdate.y compile on QNX and NetBSD 5 / i386.
109135         * m4/getdate.m4 (gl_GETDATE): Conditionally define
109136         TIME_T_FITS_IN_LONG_INT.
109137         * lib/getdate.y (long_time_t): New type.
109138         (relative_time): Change type of 'seconds' field to long_time_t.
109139         (get_date): Update types of local variables. Check against overflow
109140         during conversion from long_time_t to time_t.
109141         Reported by Matt Kraai <kraai@ftbfs.org>
109142         and Hasso Tepper <hasso@netbsd.org>.
109144 2009-09-17  Bruno Haible  <bruno@clisp.org>
109146         * modules/COPYING: Update copyright years.
109147         * modules/README: Likeiwse.
109148         * doc/gnulib-intro.texi (Copyright): Use a wildcard year.
109149         Reported by Ian Beckwith <ianb@erislabs.net>.
109151 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
109153         * users.txt: Update references for gnuit package.
109155 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
109157         * m4/getdelim.m4: Fix typo in copyright line.
109159 2009-09-17  Bruno Haible  <bruno@clisp.org>
109161         * lib/atoll.c: Use the standard header with GPL copyright.
109162         * lib/argz.in.h: Likewise.
109163         * lib/glob.c: Likewise.
109164         * lib/glob-libc.h: Likewise.
109165         * lib/random_r.c: Likewise.
109166         * lib/siglist.h: Likewise.
109167         * lib/strsignal.c: Likewise.
109168         Reported by Ian Beckwith <ianb@erislabs.net>.
109170 2009-09-17  Eric Blake  <ebb9@byu.net>
109172         rmdir: ensure correct dependency order
109173         * m4/rmdir.m4 (gl_FUNC_RMDIR): Require unistd defaults.
109175 2009-09-17  Bruno Haible  <bruno@clisp.org>
109177         Disable assertion that fails on NetBSD 5 / i386.
109178         * lib/mktime.c (ydhms_diff): Disable assertion about time_t size.
109179         Reported by Sam Steingold <sds@gnu.org>
109180         and Hasso Tepper <hasso@netbsd.org>.
109182 2009-09-16  Eric Blake  <ebb9@byu.net>
109184         unlinkdir: port to mingw
109185         * m4/unlinkdir.m4 (gl_UNLINKDIR): Add mingw to list of platforms
109186         on which no one can unlink a directory.
109188         stdlib: sort witness names
109189         * modules/stdlib (Makefile.am): Sort replacements.
109190         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
109191         * lib/stdlib.in.h: Likewise.
109193         parse-duration-tests: avoid link failure
109194         * modules/parse-duration-tests (test_parse_duration_LDADD): Add
109195         LIBINTL.
109196         Reported by Tom G. Christensen.
109198         openat-tests: ensure unlinkat behaves like rmdir
109199         * tests/test-rmdir.c (main): Factor guts...
109200         * tests/test-rmdir.h (test_rmdir_func): ...into new file.
109201         * modules/rmdir-tests (Files): Ship new file.
109202         * modules/openat-tests: New test.
109203         * tests/test-unlinkat.c: Likewise.
109205         rmdir-errno: mark obsolete, it is unsafe for cross-compilation
109206         * modules/rmdir-errno (Status, Notice): Now obsolete.
109208         rmdir: work around cygwin 1.5.x and mingw bugs
109209         * m4/rmdir.m4 (gl_FUNC_RMDIR): Detect the bugs.
109210         * lib/rmdir.c (rmdir): Work around it.
109211         * modules/rmdir (Status, Notice): No longer obsolete.
109212         (Files): Add dos.m4.
109213         (Depends-on): Add unistd.
109214         (configure.ac): Set witnesses.
109215         (License): Relax to LGPLv2+.
109216         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set defaults.
109217         * modules/unistd (Makefile.am): Substitute witnesses.
109218         * lib/unistd.in.h (rmdir): Declare replacement.
109219         * doc/posix-functions/rmdir.texi (rmdir): Document this.
109220         * modules/rmdir-tests: New tests.
109221         * tests/test-rmdir.c: Likewise.
109223 2009-09-15  Eric Blake  <ebb9@byu.net>
109225         fchdir: improve use of replacement functions
109226         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set appropriate witnesses.
109227         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add REPLACE_FSTAT.
109228         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add REPLACE_OPENDIR,
109229         REPLACE_CLOSEDIR.
109230         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_DUP.
109231         * modules/sys_stat (Makefile.am): Substitute correct witness.
109232         * modules/dirent (Makefile.am): Likewise.
109233         * modules/unistd (Makefile.am): Likewise.
109234         * lib/dirent.in.h (opendir, closedir): Use better witnesses.
109235         * lib/unistd.in.h (dup): Likewise.
109236         * lib/sys_stat.in.h (fstat): Likewise.
109238         maint: ignore gnulib-tool temp files
109239         * .gitignore: Ignore files created during gnulib-tool --test.
109241 2009-09-13  Jim Meyering  <meyering@redhat.com>
109243         posixtm: don't reject a time that specify "60" as the number of seconds
109244         * lib/posixtm.c (posixtime): The code to reject invalid dates
109245         would also reject a time specified with the .60 suffix.
109246         But POSIX allows that, in order to accommodate leap seconds.
109247         So don't reject it.
109248         (main): Adjust tests accordingly.
109249         * modules/posixtm (Depends-on): Add stpcpy.
109251 2009-09-11  Jim Meyering  <meyering@redhat.com>
109253         announce-gen: include [$release_type] in emitted Subject:
109254         * build-aux/announce-gen (get_tool_versions): Include [$release_type],
109255         e.g., [stable] in the emitted Subject: line.
109257 2009-09-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
109259         Remove obsolete macros from several modules.
109260         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Replace
109261         obsolete Autoconf macros with their modern counterparts.
109262         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Likewise.
109263         * m4/gc-camellia.m4 (gl_GC_CAMELLIA): Likewise.
109264         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
109265         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
109266         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Likewise.
109267         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
109268         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
109269         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
109270         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
109271         * m4/readline.m4 (gl_FUNC_READLINE): Likewise.
109272         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
109273         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
109274         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
109275         * m4/sockets.m4 (gl_SOCKETS): Likewise.
109276         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Likewise.
109277         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Likewise.
109278         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
109279         * m4/time_r.m4 (gl_TIME_R): Likewise.
109280         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
109281         * m4/vararrays.m4 (AC_C_VARARRAYS): Likewise.
109282         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
109284         Fix copyright header in build-aux scripts.
109285         * build-aux/git-version-gen: Fix copyright header to match GPLv3
109286         recommendation.
109287         * build-aux/ncftpput-ftp: Likewise.
109288         * build-aux/update-copyright: Likewise.
109290 2009-09-09  Eric Blake  <ebb9@byu.net>
109292         test-link: allow Linux choice of errno
109293         * tests/test-link.c (main): Relax test for alternate error.
109295         strndup: fix improper m4 caching
109296         * m4/strndup.m4 (gl_FUNC_STRNDUP): Rework to avoid side effects
109297         inside AC_CACHE_CHECK.  Use REPLACE_STRNDUP, not HAVE_STRNDUP.
109298         (gl_PREREQ_STRNDUP): Delete.
109299         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Update default.
109300         * modules/string (Makefile.am): Substitute it.
109301         * lib/string.in.h (strndup): Modernize prototype.
109303         getcwd: port to mingw
109304         * m4/getcwd.m4 (gl_FUNC_GETCWD): Mingw directories are very
109305         different from the POSIX assumptions made throughout the getcwd
109306         module; fortunately, the mingw getcwd does not need replacement.
109307         (gl_FUNC_GETCWD_NULL): Skip test on mingw.
109308         * modules/getcwd-tests: New test.
109309         * tests/test-getcwd.c: Likewise.
109311         link: fix platform bugs
109312         * m4/link.m4 (gl_FUNC_LINK): Detect Solaris and Cygwin bugs.
109313         * lib/link.c (link): Work around them.  Fix related mingw bug.
109314         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_LINK.
109315         * modules/unistd (Makefile.am): Substitute it.
109316         * lib/unistd.in.h (link): Declare replacement.
109317         * doc/posix-functions/link.texi (link): Document this.
109318         * modules/link (Depends-on): Add strdup-posix, sys_stat.
109320         test-link: consolidate into single C program, test more cases
109321         * tests/test-link.sh: Delete.
109322         * tests/test-link.c: Test more error conditions.  Exposes bugs on
109323         at least Cygwin and Solaris.
109324         * modules/link-tests (Files): Remove unused file.
109325         (Depends-on): Add errno, sys_stat.
109326         (Makefile.am): Simplify.
109328 2009-09-08  Bruno Haible  <bruno@clisp.org>
109330         Work around towlower, towupper bug on mingw.
109331         * lib/wctype.in.h (towlower, towupper) [__MINGW32__]: New replacements.
109332         * m4/wctype.m4 (gl_WCTYPE_H): Replace <wctype.h> also on mingw.
109333         * doc/posix-functions/towlower.texi: Mention the mingw bug.
109334         * doc/posix-functions/towupper.texi: Likewise.
109335         Reported by Eric Blake.
109337 2009-09-08  Jim Meyering  <meyering@redhat.com>
109339         build: don't try to run autoheader if we don't use it
109340         * build-aux/bootstrap: Define AUTOHEADER=true when AC_CONFIG_HEADERS
109341         is not used in configure.ac.
109343 2009-09-08  Eric Blake  <ebb9@byu.net>
109345         euidaccess: fix compilation error
109346         * lib/euidaccess.c (includes): Add <fcntl.h>, for AT_EACCESS.
109348         rawmemchr: relax license
109349         * modules/rawmemchr (License): Derived from glibc, so LGPLv2+ is
109350         okay.
109351         Reported by Jim Meyering.
109353         mkfifoat: new module
109354         * modules/mkfifoat: New file.
109355         * lib/mkfifoat.c: Likewise.
109356         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Likewise.
109357         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
109358         * modules/sys_stat (Makefile.am): Use them.
109359         * lib/sys_stat.in.h (mkfifoat, mknodat): Declare them.
109360         * MODULES.html.sh (File system functions): Mention module.
109361         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
109362         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
109363         * modules/mkfifoat-tests: New test.
109364         * tests/test-mkfifoat.c: Likewise.
109366         strchrnul: relax license
109367         * modules/strchrnul (License): Derived from glibc, so LGPLv2+ is
109368         okay.
109369         Reported by Jim Meyering.
109371 2009-09-08  Eric Blake  <ebb9@byu.net>
109373         fstatat: fix compilation on Solaris
109374         * lib/fstatat.c (includes): Add fcntl.h.
109375         Reported by Pádraig Brady.
109377 2009-09-07  Eric Blake  <ebb9@byu.net>
109379         rename: modernize replacement
109380         * modules/rename (Depends-on): Add stdio.
109381         (configure.ac): Declare witness.
109382         * m4/rename.m4 (gl_FUNC_RENAME): Ensure dependency order, and let
109383         stdio take care of replacement.
109384         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
109385         * modules/stdio (Makefile.am): Substitute them.
109386         * lib/stdio.in.h (rename): Declare replacement.
109387         * lib/rename.c (includes): Allow cross-compilation to non-windows
109388         machines.
109389         * doc/posix-functions/rename.texi (rename): Improve
109390         documentation.
109392         stdio: sort witness names
109393         * modules/stdio (Makefile.am): Sort replacements.
109394         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
109395         * lib/stdio.in.h: Likewise.
109397         getcwd: minor cleanups
109398         * lib/getcwd.c (AT_FDCWD): Delete; rely on <fcntl.h> instead.
109399         (is_ENAMETOOLONG): Delete; ENAMETOOLONG is portable.
109401         openat: provide more convenience names
109402         * modules/faccessat (configure.ac): Add C witness.
109403         * lib/unistd.in.h (readlinkat): Fix typo.
109404         * lib/openat.h (statat, lstatat, accessat, euidaccessat): New
109405         convenience wrappers.
109406         * top/maint.mk (sc_prohibit_openat_without_use): Allow these
109407         wrappers in syntax checks.
109409 2009-09-06  Eric Blake  <ebb9@byu.net>
109411         doc: fix comments in recent patches
109412         * lib/faccessat.c: Mention correct function.
109413         * lib/fchmodat.c: Likewise.
109414         * lib/fchownat.c: Likewise.
109415         * lib/symlinkat.c: Likewise.
109416         * doc/posix-headers/fcntl.texi (fcntl.h): Cygwin 1.7 has AT_*
109417         constants.
109419         faccessat, symlinkat: continue cleanup of previous patch
109420         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Ensure dependency order.
109421         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
109422         * modules/unistd (Makefile.am): Substitute GNULIB_READLINKAT.
109423         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Offer GNULIB_READLINKAT.
109424         * modules/symlinkat (configure.ac): Set GNULIB_READLINKAT.
109425         * lib/unistd.in.h (readlinkat): Declare if GNULIB_READLINKAT is
109426         set.
109428 2009-09-06  Bruno Haible  <bruno@clisp.org>
109430         * lib/sys_stat.in.h (fchmodat): Declare if GNULIB_FCHMODAT is set.
109431         (fstatat): Declare if GNULIB_FSTATAT is set.
109432         (mkdirat): Declare if GNULIB_MKDIRAT is set.
109433         * lib/unistd.in.h (fchownat): Declare if GNULIB_FCHOWNAT is set.
109434         (unlinkat): Declare if GNULIB_UNLINKAT is set.
109435         * modules/fcntl-h (Files): Remove m4/openat.m4.
109436         * modules/sys_stat (Files): Remove m4/openat.m4.
109437         (Makefile.am): Substitute GNULIB_FCHMODAT, GNULIB_FSTATAT,
109438         GNULIB_MKDIRAT instead of GNULIB_OPENAT.
109439         * modules/unistd (Files): Remove m4/openat.m4.
109440         (Makefile.am): Substitute GNULIB_FCHOWNAT, GNULIB_UNLINKAT instead of
109441         GNULIB_OPENAT.
109442         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize GNULIB_OPENAT,
109443         HAVE_OPENAT here. Don't require gl_OPENAT_DEFAULTS.
109444         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
109445         GNULIB_FCHMODAT, GNULIB_FSTATAT, GNULIB_MKDIRAT, HAVE_FCHMODAT,
109446         HAVE_FSTATAT, HAVE_MKDIRAT, REPLACE_FSTATAT here. Don't require
109447         gl_OPENAT_DEFAULTS.
109448         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_FCHOWNAT,
109449         GNULIB_UNLINKAT, HAVE_FCHOWNAT, HAVE_UNLINKAT, REPLACE_FCHOWNAT here.
109450         Don't require gl_OPENAT_DEFAULTS.
109451         * m4/openat.m4 (gl_FUNC_OPENAT): Require gl_FCNTL_H_DEFAULTS,
109452         gl_SYS_STAT_H_DEFAULTS, gl_UNISTD_H_DEFAULTS. Set GNULIB_FCHMODAT,
109453         GNULIB_FSTATAT, GNULIB_MKDIRAT, GNULIB_FCHOWNAT, GNULIB_UNLINKAT.
109454         (gl_OPENAT_DEFAULTS): Remove macro.
109456 2009-09-06  Bruno Haible  <bruno@clisp.org>
109458         * modules/openat (configure.ac): Remove unneeded witness.
109460 2009-09-06  Bruno Haible  <bruno@clisp.org>
109462         Set errno to ENOSYS when a function is entirely unsupported.
109463         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Set errno to ENOSYS instead of
109464         EOPNOTSUPP.
109465         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
109466         * modules/chown (Depends-on): Remove errno.
109468 2009-09-06  Bruno Haible  <bruno@clisp.org>
109470         * doc/posix-headers/fcntl.texi (AT_*): Mention affected platforms.
109472 2009-09-06  Bruno Haible  <bruno@clisp.org>
109474         * lib/sys_stat.in.h: Fix preprocessor command indentation.
109476 2009-09-06  Ben Pfaff  <blp@gnu.org>
109477             Bruno Haible  <bruno@clisp.org>
109479         Work around a glibc bug in strtok_r.
109480         * lib/string.in.h (strtok_r): Replace if REPLACE_STRTOK_R is set.
109481         Undefine if UNDEFINE_STRTOK_R is set.
109482         * lib/strtok_r.c (strtok_r, __strtok_r) [!_LIBC]: Don't undefine.
109483         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
109484         REPLACE_STRTOK_R and UNDEFINE_STRTOK_R.
109485         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Check against the glibc bug.
109486         * modules/string (Makefile.am): Substitute REPLACE_STRTOK_R,
109487         UNDEFINE_STRTOK_R.
109488         * doc/posix-functions/strtok_r.texi: Mention the glibc 2.7 bug.
109490 2009-09-06  Sergey Poznyakoff  <gray@gnu.org.ua>
109492         exclude: minor fix
109493         * lib/exclude.c: Include wctype.h
109495 2009-09-06  Akim Demaille  <demaille@gostai.com>
109497         bootstrap: improve error message
109498         * build-aux/bootstrap (find_tool): Upon failure, report the list
109499         of candidates.
109500         Honor the initial value of the envvar.
109502 2009-09-05  Eric Blake  <ebb9@byu.net>
109504         symlinkat: new module
109505         * modules/symlinkat: New file.
109506         * lib/symlinkat.c: Likewise.
109507         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
109508         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
109509         * modules/unistd (Makefile.am): Use them.
109510         * lib/unistd.in.h (symlinkat, readlinkat): Declare them.
109511         (faccessat) [GNULIB_POSIXCHECK]: Fix typo.
109512         * lib/at-func.c (FUNC_RESULT): New macro, defaulting to int.
109513         * MODULES.html.sh (File system functions): Mention module.
109514         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
109515         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
109516         * modules/symlinkat-tests: New test.
109517         * tests/test-symlinkat.c: Likewise.
109519         test-openat-safer: add more checks
109520         * tests/test-openat-safer.c (main): Check more code paths.
109522 2009-09-05  Jim Meyering  <meyering@redhat.com>
109524         syntax-check: detect unnecessary inclusion of openat.h
109525         * top/maint.mk (sc_prohibit_openat_without_use): New rule.
109527 2009-09-05  Bruno Haible  <bruno@clisp.org>
109529         Support towlower, towupper.
109530         * doc/posix-functions/towlower.texi: Mention module wctype.
109531         * doc/posix-functions/towupper.texi: Likewise.
109532         * lib/wctype.in.h (towlower, towupper): New functions.
109533         * tests/test-wctype.c: Include stdio.h, stdlib.h.
109534         (ASSERT): New macro.
109535         (e): New variable.
109536         (main): Test also towlower, towupper. Test WEOF argument.
109537         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
109539 2009-09-05  Bruno Haible  <bruno@clisp.org>
109541         Fix conversion behaviour when the input is invalid.
109542         * lib/striconveh.c (mem_cd_iconveh_internal): Fix storing of question
109543         mark occurring in first pass of indirect conversion.
109544         * tests/test-striconveh.c (main): Test conversion of invalid ASCII
109545         input.
109546         Found by clang's static analyzer.
109548 2009-09-05  Bruno Haible  <bruno@clisp.org>
109550         * tests/test-striconveh.c (main): Test indirect conversion on platforms
109551         where direct conversion is possible.
109553 2009-09-04  Eric Blake  <ebb9@byu.net>
109555         openat: fail with ENOENT on empty name
109556         * lib/openat-proc.c (openat_proc_name): Special-case the empty
109557         buffer.
109559         link-follow: fix logic bug in prior patch
109560         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Fix bug that
109561         reversed sense of yes and no in prior patch.  Avoid confusing
109562         compilation failure with desired semantics.
109564         link-follow: accommodate mingw and cross-compilation
109565         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Rename...
109566         (gl_FUNC_LINK_FOLLOWS_SYMLINK): ...to this.  Change
109567         cross-compilation results to -1, to make linkat easier to
109568         implement when cross-compiling.  Trivially support mingw.
109569         * modules/link-follow (configure.ac): Call new name.
109570         * NEWS: Mention this.
109572 2009-09-03  Eric Blake  <ebb9@byu.net>
109574         faccessat: compile replacement
109575         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Build replacement when
109576         needed.
109578         fts: fix compilation error
109579         * lib/fts.c (includes): Re-add "openat.h", for
109580         openat_needs_fchdir.
109582         faccessat: new module
109583         * modules/faccessat: New file.
109584         * lib/faccessat.c: Likewise.
109585         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
109586         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
109587         * modules/unistd (Makefile.am): Use it.
109588         * lib/unistd.in.h (faccessat): Declare it.
109589         (F_OK, X_OK, W_OK, R_OK): Provide definitions.
109590         * lib/fcntl.in.h (AT_SYMLINK_FOLLOW, AT_EACCESS): Likewise.
109591         * MODULES.html.sh (File system functions): Mention it.
109592         * doc/posix-functions/faccessat.texi (faccessat): Likewise.
109593         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
109595         euidaccess: prefer POSIX over non-standard implementation
109596         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Check for faccessat.
109597         * lib/euidaccess.c (euidaccess): Use it if available.
109599         openat: make template easier to use
109600         * lib/at-func.c (CALL_FUNC): Allow AT_FUNC_USE_F1_COND and
109601         AT_FUNC_F2 to be undefined.
109602         (VALIDATE_FLAG): New macro; use it to reject bad flags.
109603         (AT_FUNC_USE_F1_COND): Change sense to just flag bit.
109604         * lib/fchmodat.c (AT_FUNC_USE_F1_COND): Adjust.
109605         * lib/fchownat.c (AT_FUNC_USE_F1_COND): Likewise.
109606         * lib/openat.c (AT_FUNC_USE_F1_COND) [fstatat, unlinkat]:
109607         Likewise.
109608         * lib/mkdirat.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND): Delete.
109609         * lib/selinux-at.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND)
109610         [getfileconat, lgetfileconat, setfileconat, lsetfileconat]:
109611         Likewise.
109613         openat: declare in POSIX headers
109614         * NEWS: Mention this.
109615         * modules/openat (configure.ac): Declare witnesses.
109616         (Depends-on): Add fcntl-h, sys_stat, unistd.
109617         (Include): Mention correct headers.
109618         * modules/fcntl-h (Depends-on): Add link-warning.
109619         (Files): Add openat.m4.
109620         (Makefile.am): Substitute witnesses.
109621         * modules/sys_stat (Files, Makefile.am): Likewise.
109622         * modules/unistd (Files, Makefile.am): Likewise.
109623         * m4/openat.m4 (gl_FUNC_OPENAT, gl_FUNC_FCHOWNAT): Set witnesses.
109624         (gl_OPENAT_DEFAULTS): New macro.
109625         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Use it.
109626         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
109627         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
109628         (SYS_STAT_H): Remove unused variable.
109629         * doc/posix-headers/fcntl.texi (fcntl.h): Update content.
109630         * lib/fcntl--.h (includes): Remove unneeded header.
109631         * lib/openat-safer.c (includes): Likewise.
109632         * lib/openat.h (AT_FDCWD, AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR)
109633         (openat, fstatat, unlinkat, mkdirat, fchmodat, fchownat): Move to
109634         appropriate headers.
109635         (__OPENAT_PREFIX): Delete.
109636         * lib/fcntl.in.h (openat): Provide declaration.
109637         (AT_FDCWD): Fix Solaris bug.
109638         (AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR): Provide macros.
109639         * lib/sys_stat.in.h (fstatat, mkdirat): Provide declaration.
109640         * lib/fchmodat.c (includes):  Adjust to find declaration.
109641         * lib/fchownat.c (includes): Likewise.
109642         * lib/mkdirat.c (includes): Likewise.
109643         * lib/fstatat.c (includes): Likewise.  Ensure original fstatat is
109644         still visible.
109646 2009-09-02  Eric Blake  <ebb9@byu.net>
109648         errno: use consistently
109649         * lib/c-stack.c (ENOTSUP): <errno.h> guarantees a definition.
109650         * lib/canonicalize-lgpl.c (ENAMETOOLONG): Likewise.
109651         * lib/canonicalize.c (ELOOP): Likewise.
109652         * lib/inet_ntop.c (EAFNOSUPPORT): Likewise.
109653         * lib/inet_pton.c (EAFNOSUPPORT): Likewise.
109654         * lib/lchown.c (EOPNOTSUPP): Likewise.
109655         * lib/openat-priv.h (ENOSYS, EOPNOTSUPP): Likewise.
109656         * lib/savewd.c (ESTALE): Likewise.
109657         * lib/settime.c (ENOSYS): Likewise.
109658         * lib/utimens.c (ENOSYS): Likewise.
109659         * lib/xgethostname.c (ENAMETOOLONG): Likewise.
109660         * lib/chdir-safer.c (ELOOP): Likewise.
109661         (chdir_no_follow): Use HAVE_READLINK, not ELOOP, as witness.
109662         * modules/c-stack (Depends-on): Add errno.
109663         * modules/canonicalize (Depends-on): Likewise.
109664         * modules/chdir-safer (Depends-on): Likewise.
109665         * modules/fdopendir (Depends-on): Likewise.
109666         * modules/inet_ntop (Depends-on): Likewise.
109667         * modules/inet_pton (Depends-on): Likewise.
109668         * modules/lchown (Depends-on): Likewise.
109669         * modules/openat (Depends-on): Likewise.
109670         * modules/savewd (Depends-on): Likewise.
109671         * modules/settime (Depends-on): Likewise.
109672         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Check for readlink.
109674         fts: avoid leaking fds
109675         * modules/fts (Depends-on): Add cloexec.
109676         * lib/fts.c (opendirat, diropen, fts_build): Set close-on-exec
109677         flag.
109679         fts: make directory fds more robust
109680         * lib/fts.c (O_DIRECTORY): Let <fcntl.h> take care of this.
109681         (opendirat): Specify O_DIRECTORY, and add fallbacks for safety.
109683         backupfile, chdir-long, fts, savedir: make safer
109684         * lib/backupfile.c (includes): Use "dirent--.h", since
109685         numbered_backup can write to stderr during readdir.
109686         * lib/savedir.c (includes): Likewise.
109687         * lib/chdir-long.c (includes): Use "fcntl--.h", since openat
109688         emulation can write to stderr on failure.
109689         * lib/fts.c (includes) [!_LIBC]: Likewise for opendir and openat.
109690         * lib/getcwd.c: Document why opendir_safer is unused.
109691         * lib/glob.c: Likewise.
109692         * lib/scandir.c: Likewise.
109693         * lib/openat-proc.c: Likewise, for open_safer.
109694         * modules/backupfile (Depends-on): Add dirent-safer.
109695         * modules/savedir (Depends-on): Likewise.
109696         * modules/fts (Depends-on): Add dirent-safer and openat-safer.
109697         * modules/chdir-long (Depends-on): Add openat-safer.
109699         openat-safer: new module
109700         * modules/openat-safer: New file.
109701         * lib/openat-safer.c: Likewise.
109702         * m4/fcntl-safer.m4 (gl_OPENAT_SAFER): New macro.
109703         * lib/fcntl-safer.h (openat_safer): Declare.
109704         * lib/fcntl--.h (openat): Override.
109705         * MODULES.html.sh (File descriptor based I/O): Mention it.
109706         * lib/openat.h: Add double-inclusion guards.
109707         * lib/openat.c (includes): Only include "fcntl-safer.h", not
109708         "fcntl--.h", so we can implement openat.
109709         * modules/openat-safer-tests: New test.
109710         * tests/test-openat-safer.c: New file.
109712         dirent-safer: new module
109713         * modules/dirent-safer: New file.
109714         * lib/dirent--.h: Likewise.
109715         * lib/dirent-safer.h: Likewise.
109716         * lib/opendir-safer.c: Likewise.
109717         * m4/dirent-safer.m4: Likewise.
109718         * MODULES.html.sh (Enhancements for POSIX:2008): Mention it.
109719         * modules/dirent-safer-tests: New test.
109720         * tests/test-dirent-safer.c: New file.
109721         * lib/fdopendir.c (includes): Ensure fdopendir is also safe.
109723         fdopendir: optimize on mingw
109724         * lib/unistd.in.h (_gl_directory_name): New prototype.
109725         * lib/fchdir.c (_gl_directory_name): Implement it.
109726         (fchdir): Use it to simplify implementation.
109727         * lib/fdopendir.c (fdopendir) [REPLACE_FCHDIR]: Use metadata from
109728         fchdir, when available, to avoid calling [f]chdir().
109730         fdopendir: split into its own module
109731         * lib/openat.c (fdopendir): Move...
109732         * lib/fdopendir.c: ...into new file.
109733         * modules/fdopendir: New module.
109734         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): New file.
109735         * modules/openat (Depends-on): Add fdopendir.
109736         * m4/openat.m4 (gl_FUNC_OPENAT): No longer need to check for
109737         fdopendir here.
109738         * modules/savedir (Depends-on): Only need fdopendir, not full
109739         openat.
109740         * lib/savedir.c (include): Use <dirent.h>, not "openat.h".
109741         * lib/openat.h (fdopendir): Drop prototype.
109742         * lib/dirent.in.h (fdopendir): Provide prototype.
109743         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add replacements.
109744         * modules/dirent (Makefile.am): Substitute them.
109745         * MODULES.html.sh (File system functions): Mention it.
109746         * doc/posix-functions/fdopendir.texi (fdopendir): Likewise.
109747         * modules/fdopendir-tests: New file.
109748         * tests/test-fdopendir.c: Likewise.
109750         fchdir: use more consistent macro convention
109751         * lib/fcntl.in.h (_gl_register_fd): Move declaration to unistd.
109752         * lib/sys_stat.in.h (rpl_fstat): Declare via make-time
109753         REPLACE_FCHDIR, rather than relying on config.h macros.
109754         * lib/unistd.in.h (fchdir): Move all fchdir internal declarations
109755         inside a single make-time REPLACE_FCHDIR block, rather than using
109756         the config.h FCHDIR_REPLACEMENT.
109757         * m4/fchdir.m4 (gl_FUNC_FCHDIR): REPLACE_FCHDIR was already
109758         AC_SUBST'd, also AC_DEFINE it.  Don't define FCHDIR_REPLACEMENT.
109759         Manage fstat replacement.
109760         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Pick up
109761         REPLACE_FCHDIR.
109762         * modules/sys_stat (Files): Add m4/unistd_h.m4.
109763         (Makefile.am): Substitute REPLACE_FCHDIR.
109764         * lib/close.c (rpl_close): Use REPLACE_FCHDIR, not
109765         FCHDIR_REPLACEMENT.
109766         * lib/dup-safer.c (dup_safer): Likewise.
109767         * lib/dup2.c (rpl_dup2): Likewise.
109768         * lib/dup3.c (rpl_dup3): Likewise.
109769         * lib/open.c (rpl_open): Likewise.
109771         fchdir: simplify error handling, and support dup3
109772         * modules/fchdir (Depends-on): Use strdup-posix, not strdup.  Add
109773         stdbool, malloc-posix, realloc-posix.
109774         * lib/fchdir.c (struct dir_info_t): Delete saved_errno.
109775         (ensure_dirs_slot): Return false on allocation failure.
109776         (rpl_dup2): Delete.
109777         (_gl_register_dup): New function.
109778         (_gl_unregister_fd, rpl_opendir, rpl_dup): Update callers.
109779         (_gl_register_fd): Close fd on allocation failure.
109780         * lib/fcntl.in.h (_gl_register_fd): Update signature.
109781         * lib/unistd.in.h (_gl_register_dup) [FCHDIR_REPLACEMENT]: New
109782         prototype.
109783         (rpl_dup2_fchdir): Delete prototype.
109784         * lib/open.c (open): Update caller.
109785         * lib/dup2.c (dup2): Track fchdir metadata.
109786         * lib/dup3.c (dup3): Likewise.
109787         * m4/dup2.m4 (gl_REPLACE_DUP2): New macro.
109788         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Use it.
109790 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
109792         * gnulib-tool (func_create_testdir, func_create_megatestdir): Use
109793         AC_CONFIG_HEADERS instead of AM_CONFIG_HEADER. Use AC_CONFIG_FILES and
109794         don't pass arguments to AC_OUTPUT.
109796 2009-09-02  Bruno Haible  <bruno@clisp.org>
109798         * modules/mkdtemp (License): Relicense under LGPLv2+.
109799         Reported by Paolo Bonzini.
109801 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
109803         Replace uses of obsolete autoconf macros in Jim's modules.
109804         The Autoconf macros AC_TRY_CPP, AC_TRY_COMPILE, AC_TRY_LINK and
109805         AC_TRY_RUN have been obsolete since Autoconf 2.55, and each use
109806         can evoke a warning from autoconf when run with -Wobsolete
109807         enabled.  They were declared obsolete for good reasons (see
109808         the `AC_FOO_IFELSE vs AC_TRY_FOO' node in the Autoconf manual,
109809         recently renamed to `AC_ACT_IFELSE vs AC_TRY_ACT'), and we
109810         should not continue using the deprecated macros.
109811         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Replace
109812         obsolete Autoconf macros with modern counterparts.
109813         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
109814         * m4/dos.m4 (gl_AC_DOS): Likewise.
109815         * m4/fpending.m4 (gl_FUNC_FPENDING): Likewise.
109816         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Likewise.
109817         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Likewise.
109818         * m4/jm-winsz1.m4 (gl_WINSIZE_IN_PTEM): Likewise.
109819         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Likewise.
109820         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Likewise.
109821         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Likewise.
109822         * m4/mode_t.m4 (gl_PROMOTED_TYPE_MODE_T): Likewise.
109823         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
109824         Likewise.
109825         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
109826         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
109827         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Likewise.
109828         * m4/st_dm_mode.m4 (AC_STRUCT_ST_DM_MODE): Likewise.
109829         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
109830         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
109832 2009-09-01  Eric Blake  <ebb9@byu.net>
109834         fchdir: fix off-by-one bug in previous patch
109835         * lib/fchdir.c (rpl_fstat): Use correct bounds.
109836         (_gl_unregister_fd): Delete useless if.
109838 2009-09-01  Daniel P. Berrange  <berrange@redhat.com>
109840         maint.mk: sort the list of syntax-check rules
109841         * top/maint.mk (syntax-check-rules): Sort syntax-check rules, so it's
109842         easier to get a sense of progress when the rules are run sequentially
109843         and take a long time.
109845 2009-09-01  Simon Josefsson  <simon@josefsson.org>
109847         * modules/arpa_inet: Use $(MKDIR_P) instead of @MKDIR_P@.
109848         * modules/netinet_in: Likewise.
109849         * modules/sys_file: Likewise.
109850         * modules/sys_ioctl: Likewise.
109851         * modules/sys_select: Likewise.
109852         * modules/sys_socket: Likewise.
109853         * modules/sys_stat: Likewise.
109854         * modules/sys_time: Likewise.
109855         * modules/sys_times: Likewise.
109856         * modules/sys_utsname: Likewise.
109857         * modules/sys_wait: Likewise.
109859 2009-09-01  Jim Meyering  <meyering@redhat.com>
109861         fts: help ensure that return values are not ignored
109862         * lib/fts_.h (__GNUC_PREREQ): Define.
109863         (__attribute_warn_unused_result__): Define.
109864         (fts_children, fts_close, fts_open, fts_read): Declare with
109865         __attribute_warn_unused_result__.
109867         fts: fts_close now fails also when closing a dir file descriptor fails
109868         * lib/fts.c (fts_close): Detect close failure, not just fchdir failure,
109869         and propagate to caller, along with errno.
109871         announce-gen: correct formatting in --help output
109872         * build-aux/announce-gen (usage): Move the one-line description in
109873         --help output "up", to where it belongs, just after Usage:.
109875 2009-08-31  Eric Blake  <ebb9@byu.net>
109877         fchdir: port to mingw
109878         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Check for mingw bug.
109879         * lib/open.c (open) [FCHDIR_REPLACEMENT]: If directories can't be
109880         opened, then use a substitute.
109881         * lib/sys_stat.in.h (fstat) [REPLACE_OPEN_DIRECTORY]: Declare
109882         replacement.
109883         * lib/fchdir.c (fstat) [REPLACE_OPEN_DIRECTORY]: Implement it.
109884         (_gl_register_fd): No need to check stat if open already filters
109885         all directories.
109886         (fchdir): Fix error condition to match POSIX.
109887         * modules/fchdir (Depends-on): Add sys_stat.
109888         * doc/posix-functions/open.texi (open): Document the limitation.
109889         * modules/fchdir-tests: New file.
109890         * tests/test-fchdir.c: Likewise.
109892         canonicalize: allow cross-testing from cygwin to mingw
109893         * modules/canonicalize-tests (configure.ac): Define HAVE_SYMLINK.
109894         (Makefile.am): Pass it through TESTS_ENVIRONMENT.
109895         * modules/canonicalize-lgpl-tests (configure.ac, Makefile.am):
109896         Likewise.
109897         * tests/test-canonicalize.sh: Also skip test if 'ln -s' works, but
109898         target does not support symlinks.
109899         * tests/test-canonicalize-lgpl.sh: Likewise.
109901         chown: avoid compilation warning on mingw
109902         * m4/chown.m4 (gl_FUNC_CHOWN): Recognize missing chown.
109903         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Always return failure on
109904         mingw.
109905         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
109906         * modules/chown (Depends-on): Add errno.
109908 2009-08-31  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
109910         * gnulib-tool: Fix test whether $CONFIG_SHELL has a working 'echo'
109911         command.
109913 2009-08-31  Jim Meyering  <meyering@redhat.com>
109915         canonicalize: remove useless initialization
109916         * lib/canonicalize.c (canonicalize_filename_mode): Remove useless
109917         initialization of local, "end".
109919 2009-08-30  Bruno Haible  <bruno@clisp.org>
109921         Fix an unnecessary error on Solaris 10 on NFSv3 file systems.
109922         * lib/set-mode-acl.c (qset_acl) [Solaris 10 new]: Treat EOPNOTSUPP like
109923         ENOSYS.
109925 2009-08-30  Bruno Haible  <bruno@clisp.org>
109927         * tests/test-pipe-filter-ii1.sh: Prefer /usr/xpg6/bin/tr over
109928         /usr/xpg4/bin/tr when it exists.
109929         * tests/test-pipe-filter-gi1.sh: Likewise.
109931 2009-08-30  Bruno Haible  <bruno@clisp.org>
109933         Work around deficient /usr/bin/id program on Solaris.
109934         * tests/test-file-has-acl.sh (ID): New variable.
109935         * tests/test-set-mode-acl.sh (ID): Likewise.
109936         * tests/test-copy-acl.sh (ID): Likewise.
109937         * tests/test-copy-file.sh (ID): Likewise.
109939 2009-08-30  Bruno Haible  <bruno@clisp.org>
109941         New module 'xstriconveh'.
109942         * lib/xstriconveh.h: New file.
109943         * lib/xstriconveh.c: New file.
109944         * modules/xstriconveh: New file.
109946 2009-08-30  Bruno Haible  <bruno@clisp.org>
109948         Make it easier to use mem_cd_iconveh.
109949         * lib/striconveh.h (iconveh_t): New type.
109950         (iconveh_open, iconveh_close): New declarations.
109951         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
109952         with a single 'const iconveh_t *' argument.
109953         * lib/striconveh.c (iconveh_open, iconveh_close): New functions.
109954         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
109955         with a single 'const iconveh_t *' argument.
109956         (mem_iconveh, str_iconveh): Use iconveh_open, iconveh_close.
109957         * tests/test-striconveh.c (main): Update.
109958         * NEWS: Mention the change.
109960 2009-08-30  Bruno Haible  <bruno@clisp.org>
109962         * doc/posix-functions/iconv_open.texi: Mention indirect conversion
109963         problem.
109965 2009-08-30  Bruno Haible  <bruno@clisp.org>
109967         Work around iconv_open problem on Solaris.
109968         * lib/iconv_open-solaris.gperf: New file.
109969         * lib/iconv_open.c (ICONV_FLAVOR_SOLARIS): New macro.
109970         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Also handle Solaris.
109971         * modules/iconv_open (Files): Add lib/iconv_open-solaris.gperf.
109972         (Makefile.am): Add rule for iconv_open-solaris.h. Augment
109973         BUILT_SOURCES, MOSTLYCLEANFILES, MAINTAINERCLEANFILES, EXTRA_DIST.
109974         * doc/posix-functions/iconv_open.texi: Mention the Solaris problem.
109976 2009-08-29  Jim Meyering  <meyering@redhat.com>
109978         maint.mk: remove more coreutils-specific targets; XZ_OPT=-9ev
109979         * top/maint.mk (cvs-check): Remove target; it was just an alias
109980         to the better-named vc-diff-check.
109981         (maintainer-distcheck): Remove rule.  It was used only from
109982         the (alpha/beta/major) target, and all of its commands but one
109983         were coreutils-specific.
109984         (vc-dist): Remove rule.
109985         (alpha beta major): Run "$(MAKE) distcheck" explicitly.
109986         Run vc-diff-check, not vc-dist.
109987         Run $(MAKE) dist with XZ_OPT=-9ev.  Note spelling, with "-".
109989 2009-08-27  Bruno Haible  <bruno@clisp.org>
109991         * tests/test-bitrotate.c (main): Remove test that uses a shift count
109992         of 0.
109994 2009-08-27  Bruno Haible  <bruno@clisp.org>
109996         * tests/test-func.c (main): Don't verify sizeof __func__ on SunPRO C
109997         compilers.
109998         * doc/func.texi: Document the SunPRO C bug.
110000 2009-08-27  Bruno Haible  <bruno@clisp.org>
110002         Fix link error on Solaris.
110003         * tests/test-parse-duration.c (xstrdup): Remove function.
110005 2009-08-26  Pádraig Brady  <P@draigbrady.com>
110007         ignore-value: handle pointer types, too
110008         * lib/ignore-value.h (__attribute__): Remove definition.
110009         (ignore_value): Remove use of "__attribute__ ((unused))" in favor
110010         of a more concise and more-often effective "(void) i" statement.
110011         (ignore_ptr): New function to suppress warnings from functions that
110012         return pointers, and to make it explicit that one function doesn't
110013         handle all cases.
110015 2009-08-25  Bruno Haible  <bruno@clisp.org>
110017         dup2: work around a Linux bug.
110018         * m4/dup2.m4 (gl_FUNC_DUP2): Test for the Linux bug.
110019         * lib/dup2.c (rpl_dup2): Correct the return value if it is -EBADF.
110020         * doc/posix-functions/dup2.texi: Mention the Linux bug.
110021         Reported by Simon Josefsson.
110023 2009-08-25  Jim Meyering  <meyering@redhat.com>
110025         libguestfs uses gnulib
110026         * users.txt: Add libguestfs.
110028 2009-08-24  Eric Blake  <ebb9@byu.net>
110030         dup2, pipe2: fix some recent test failures on cygwin 1.5.x
110031         * lib/pipe2.c (includes): Add binary-io.h.
110032         * lib/dup2.c (rpl_dup2): Correct buggy errno value.
110034 2009-08-24  Bruno Haible  <bruno@clisp.org>
110036         Tolerate declared but missing accept4 syscall.
110037         * lib/accept4.c (accept4): Invoke original accept4 function first, if
110038         available.
110039         * lib/sys_socket.in.h (accept4): If the function is already present,
110040         override it.
110041         * m4/accept4.m4 (gl_FUNC_ACCEPT4): Remove AC_LIBOBJ invocation.
110042         * modules/accept4 (Makefile.am): Compile accept4.c always.
110043         Reported by Paolo Bonzini and Eric Blake.
110045 2009-08-23  Bruno Haible  <bruno@clisp.org>
110047         New module 'accept4'.
110048         * lib/sys_socket.in.h (accept4): New declaration.
110049         * lib/accept4.c: New file.
110050         * m4/accept4.m4: New file.
110051         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
110052         GNULIB_ACCEPT4, HAVE_ACCEPT4.
110053         * modules/sys_socket (Makefile.am): Substitute GNULIB_ACCEPT4,
110054         HAVE_ACCEPT4.
110055         * modules/accept4: New file.
110056         * doc/glibc-functions/accept4.texi: Mention the new module.
110058 2009-08-24  Jim Meyering  <meyering@redhat.com>
110060         progname: also set global program_invocation_name, when possible
110061         Before this change, a libtool-enabled program that calls glibc's
110062         error function would report the program name as
110063         "/abs/dir/.libs/lt-program_name" rather than the desired program_name.
110064         * modules/progname (configure.ac): Check for a declaration of
110065         program_invocation_name.
110066         * lib/progname.c:  Include <errno.h>.
110067         (set_program_name) [HAVE_DECL_PROGRAM_INVOCATION_NAME]:
110068         Set program_invocation_name.
110070 2009-08-23  Bruno Haible  <bruno@clisp.org>
110072         * lib/dup3.c: Include <string.h>.
110074 2009-08-23  Bruno Haible  <bruno@clisp.org>
110076         * lib/dup3.c (dup3): Test only once whether the system actually exists.
110077         * lib/pipe2.c (pipe2): Likewise.
110078         Suggested by Eric Blake.
110080 2009-08-23  Bruno Haible  <bruno@clisp.org>
110082         Tolerate declared but missing dup3 syscall.
110083         * lib/dup3.c (dup3): Invoke original dup3 function first, if available.
110084         * lib/unistd.in.h (dup3): If the function is already present,
110085         override it.
110086         * m4/dup3.m4 (gl_FUNC_DUP3): Remove AC_LIBOBJ invocation.
110087         * modules/dup3 (Makefile.am): Compile dup3.c always.
110088         Reported by Paolo Bonzini.
110090 2009-08-23  Bruno Haible  <bruno@clisp.org>
110092         Tolerate declared but missing pipe2 syscall.
110093         * lib/pipe2.c (pipe2): Invoke original pipe2 function first, if
110094         available.
110095         * lib/unistd.in.h (pipe2): If the function is already present,
110096         override it.
110097         * m4/pipe2.m4 (gl_FUNC_PIPE2): Remove AC_LIBOBJ invocation.
110098         * modules/pipe2 (Makefile.am): Compile pipe2.c always.
110099         Reported by Paolo Bonzini.
110101 2009-08-23  Bruno Haible  <bruno@clisp.org>
110103         * lib/pipe2.c (pipe2): Move #ifs inside function.
110105 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
110107         quotearg: document limitations of quote_these_too
110108         * lib/quotearg.c (quotearg_buffer_restyled): Add comments where
110109         those limitations are created.
110110         * lib/quotearg.h (set_char_quoting): Document that digits and
110111         letters that are special after backslash are not permitted.
110112         (quotearg_char): Cross-reference set_char_quoting documentation.
110114 2009-08-23  Joel E. Denny  <jdenny@clemson.edu>
110116         quotearg: implement custom_quoting_style
110117         * lib/quotearg.c: (struct quoting_options): Add left_quote and
110118         right_quote fields.
110119         (set_custom_quoting): New public function.
110120         (quotearg_buffer_restyled): Add left_quote and right_quote
110121         arguments, handle them very much like locale quoting, and update
110122         all uses.
110123         (quotearg_n_custom): New public function.
110124         (quotearg_n_custom_mem): New public function.
110125         (quotearg_custom): New public function.
110126         (quotearg_custom_mem): New public function.
110127         * lib/quotearg.h: Prototype and document new public functions.
110128         (enum quoting_style): For escape_quoting_style and
110129         clocale_quoting_style, comment that QA_SPLIT_TRIGRAPHS is
110130         ignored even though they're otherwise like c_quoting_style.
110131         Add custom_quoting_style member and document with comparison to
110132         clocale_quoting_style.
110133         * tests/test-quotearg.c (custom_quotes): New array.
110134         (custom_results): New array.
110135         (main): Extend to test custom quoting.
110137 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
110139         quotearg: fix right quote escaping when it's in quote_these_too
110140         * lib/quotearg.c (quotearg_buffer_restyled): Upon seeing a right
110141         quote, be sure to prepend only one backslash.
110142         * tests/test-quotearg.c (use_quote_double_quotes): New function.
110143         (main): Test it.
110145 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
110147         quotearg-tests: test escaping of embedded locale quotes
110148         * tests/test-quotearg.c (struct result_strings): Add member for
110149         new input.
110150         (LQ_ENC, RQ_ENC, RQ_ESC): New macros.
110151         (inputs): Add new input.
110152         (results_g): Add expected results.
110153         (flag_results): Likewise.
110154         (locale_results): Likewise.
110155         (compare_strings): Check those.
110157 2009-08-23  Bruno Haible  <bruno@clisp.org>
110159         Tests for module 'dup3'.
110160         * modules/dup3-tests: New file.
110161         * tests/test-dup3.c: New file.
110163         New module 'dup3'.
110164         * lib/unistd.in.h (dup3): New declaration.
110165         * lib/dup3.c: New file.
110166         * m4/dup3.m4: New file.
110167         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_DUP3 and
110168         HAVE_DUP3.
110169         * modules/unistd (Makefile.am): Substitute GNULIB_DUP3 and HAVE_DUP3.
110170         * modules/dup3: New file.
110171         * doc/glibc-functions/dup3.texi: Mention the new module.
110173 2009-08-23  Bruno Haible  <bruno@clisp.org>
110175         Tweak the dup2 test.
110176         * tests/test-dup2.c (main): Create the test file empty. Verify that an
110177         out-of-range fd yields EBADF. Verify that after writing to /dev/null,
110178         the test file is still empty. Fix argument order of lseek.
110180 2009-08-23  Bruno Haible  <bruno@clisp.org>
110182         Avoid test link errors when the modules getopt-gnu, gettext are used.
110183         * modules/getopt-posix-tests (Makefile.am): Define test_getopt_LDADD.
110184         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
110186 2009-08-23  Bruno Haible  <bruno@clisp.org>
110188         Fix getdtablesize() on mingw.
110189         * lib/getdtablesize.c (getdtablesize): Implement differently.
110190         * lib/unistd.in.h (getdtablesize): Improve comment.
110192 2009-08-23  Bruno Haible  <bruno@clisp.org>
110194         New module 'mkostemp'.
110195         Based on Ulrich Drepper's 2007-08-10 change in glibc.
110196         * lib/stdlib.in.h (mksotemp): New declaration.
110197         * lib/mkostemp.c: New file, from glibc with modifications.
110198         * lib/tempname.h (GT_FILE): Remove outdated comment.
110199         (gen_tempname): Add flags argument.
110200         * lib/tempname.c (__GT_BIGFILE): Remove macro.
110201         (__GT_FILE): Map to 1.
110202         (small_open, large_open): Remove macros.
110203         (__gen_tempname): Add flags argument. Remove code for __GT_BIGFILE.
110204         * lib/mkstemp.c (mkstemp): Update.
110205         * lib/mkdtemp.c (mkdtemp): Likewise.
110206         * m4/mkostemp.m4: New file.
110207         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_MKOSTEMP,
110208         HAVE_MKOSTEMP.
110209         * modules/stdlib (Makefile.am): Substitute GNULIB_MKOSTEMP,
110210         HAVE_MKOSTEMP.
110211         * modules/mkostemp: New file, based on modules/mkstemp.
110212         * doc/glibc-functions/mkostemp.texi: Mention the new module.
110213         * NEWS: Mention the change.
110215 2009-08-23  Bruno Haible  <bruno@clisp.org>
110217         * lib/pipe2.c (pipe2): Support O_TEXT, O_BINARY on all platforms.
110218         Reported by Eric Blake.
110220 2009-08-23  Bruno Haible  <bruno@clisp.org>
110222         * lib/pipe2.c (pipe2): Fix test of fcntl's return value.
110223         Reported by Eric Blake.
110225 2009-08-23  Bruno Haible  <bruno@clisp.org>
110227         * modules/fchdir (Depends-on): Use fcntl-h instead of fcntl.
110228         * modules/pipe2 (Depends-on): Likewise.
110230 2009-08-23  Eric Blake  <ebb9@byu.net>
110232         fcntl-h: add O_TTY_INIT support
110233         * lib/fcntl.in.h (O_TTY_INIT): Support another POSIX macro.
110234         * tests/test-fcntl-h.c (o): Test it.
110235         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
110237         fcntl-h: rename from fcntl, in preparation for fcntl(2)
110238         * modules/fcntl: Move <fcntl.h> header replacement...
110239         * modules/fcntl-h: ...to new name, so as not to collide with
110240         like-named function.
110241         * tests/test-fcntl.c: Rename...
110242         * tests/test-fcntl-h.c: ...to this.  Test FD_CLOEXEC.
110243         * modules/fcntl-tests: Rename...
110244         * modules/fcntl-h-tests: ...to this.  Update test file name.
110245         * modules/chdir-long (Depends-on): Update clients.
110246         * modules/chdir-safer (Depends-on): Likewise.
110247         * modules/fcntl-safer (Depends-on): Likewise.
110248         * modules/fts (Depends-on): Likewise.
110249         * modules/mkancesdirs (Depends-on): Likewise.
110250         * modules/mkdir-p (Depends-on): Likewise.
110251         * modules/open (Depends-on): Likewise.
110252         * modules/savewd (Depends-on): Likewise.
110253         * MODULES.html.sh (systems lacking POSIX:2008): Update name.
110254         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
110256 2009-08-22  Bruno Haible  <bruno@clisp.org>
110258         * modules/binary-io (License): Relicense under LGPL.
110259         * modules/pipe2 (License): Likewise.
110261 2009-08-22  Bruno Haible  <bruno@clisp.org>
110263         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Fix test of fcntl's
110264         return value.
110265         * lib/pipe-filter-gi.c (filter_init): Likewise.
110266         Reported by Eric Blake.
110268 2009-08-22  Bruno Haible  <bruno@clisp.org>
110270         * lib/pipe.c (create_pipe): Use pipe2 instead of _pipe.
110271         * modules/pipe (Depends-on): Add pipe2.
110273 2009-08-22  Bruno Haible  <bruno@clisp.org>
110275         Tests for module 'pipe2'.
110276         * modules/pipe2-tests: New file.
110277         * tests/test-pipe2.c: New file.
110279         New module 'pipe2'.
110280         * lib/unistd.in.h (pipe2): New declaration.
110281         * lib/pipe2.c: New file.
110282         * m4/pipe2.m4: New file.
110283         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_PIPE2 and
110284         HAVE_PIPE2.
110285         * modules/unistd (Makefile.am): Substitute GNULIB_PIPE2 and HAVE_PIPE2.
110286         * modules/pipe2: New file.
110287         * doc/glibc-functions/pipe2.texi: Mention the new module.
110289 2009-08-22  Bruno Haible  <bruno@clisp.org>
110291         Reference some new glibc functions.
110292         * doc/glibc-functions/accept4.texi: New file.
110293         * doc/glibc-functions/dup3.texi: New file.
110294         * doc/glibc-functions/mkostemp.texi: New file.
110295         * doc/glibc-functions/pipe2.texi: New file.
110296         * doc/gnulib.texi (Glibc stdlib.h): Refer to mkostemp.
110297         (Glibc sys/socket.h): Refer to accept4.
110298         (Glibc unistd.h): Refer to dup3, pipe2.
110299         Reported by Eric Blake.
110301 2009-08-22  Jim Meyering  <meyering@redhat.com>
110302             Bruno Haible  <bruno@clisp.org>
110304         annotate automake snippets with $(AM_V_GEN) and $(AM_V_at)
110305         This makes it so packages using automake-1.11's silent-rules option
110306         can print e.g., a single "GEN    configmake.h" line, rather than
110307         the 30+ statements that perform the job.  If you want to see the
110308         actual commands, you can still run "make V=1".
110309         * modules/alloca-opt: Add $(AM_V_GEN) and $(AM_V_at) prefixes
110310         so that make output is abbreviated when those variables are defined
110311         appropriately.
110312         * modules/argz: Likewise.
110313         * modules/arpa_inet: Likewise.
110314         * modules/byteswap: Likewise.
110315         * modules/configmake: Likewise.
110316         * modules/dirent: Likewise.
110317         * modules/errno: Likewise.
110318         * modules/fcntl: Likewise.
110319         * modules/float: Likewise.
110320         * modules/fnmatch: Likewise.
110321         * modules/getopt-posix: Likewise.
110322         * modules/glob: Likewise.
110323         * modules/iconv_open: Likewise.
110324         * modules/inttypes: Likewise.
110325         * modules/localcharset: Likewise.
110326         * modules/locale: Likewise.
110327         * modules/math: Likewise.
110328         * modules/netdb: Likewise.
110329         * modules/netinet_in: Likewise.
110330         * modules/poll: Likewise.
110331         * modules/posix_spawnp-tests: Likewise.
110332         * modules/sched: Likewise.
110333         * modules/search: Likewise.
110334         * modules/selinux-h: Likewise.
110335         * modules/signal: Likewise.
110336         * modules/spawn: Likewise.
110337         * modules/stdarg: Likewise.
110338         * modules/stdbool: Likewise.
110339         * modules/stddef: Likewise.
110340         * modules/stdint: Likewise.
110341         * modules/stdio: Likewise.
110342         * modules/stdlib: Likewise.
110343         * modules/string: Likewise.
110344         * modules/strings: Likewise.
110345         * modules/sys_file: Likewise.
110346         * modules/sys_ioctl: Likewise.
110347         * modules/sys_select: Likewise.
110348         * modules/sys_socket: Likewise.
110349         * modules/sys_stat: Likewise.
110350         * modules/sys_time: Likewise.
110351         * modules/sys_times: Likewise.
110352         * modules/sys_utsname: Likewise.
110353         * modules/sys_wait: Likewise.
110354         * modules/sysexits: Likewise.
110355         * modules/time: Likewise.
110356         * modules/unistd: Likewise.
110357         * modules/wchar: Likewise.
110358         * modules/wctype: Likewise.
110360 2009-08-22  Jim Meyering  <meyering@redhat.com>
110362         announce-gen: detect write failure
110363         * build-aux/announce-gen: Add Coda at end.
110364         Remove equivalent-but-more-verbose block at top.
110366 2009-08-19  Akim Demaille  <demaille@gostai.com>
110368         bootstrap: --help to stdout.
110369         * bootstrap (usage): Don't send --help to stderr.
110370         Use a here doc instead of a long string.
110372 2009-08-21  Eric Blake  <ebb9@byu.net>
110374         test-popen-safer: split from test-popen
110375         * tests/test-popen.c (main): Move...
110376         * tests/test-popen.h: ...into new file.
110377         * tests/test-popen-safer2.c: New file.
110378         * modules/popen-tests (Files): Add test-popen.h.
110379         * modules/popen-safer-tests (Files): Add test-popen-safer2.c.
110380         Suggested by Bruno Haible.
110382         test-fcntl-safer: split from test-open
110383         * tests/test-open.c (main): Move...
110384         * tests/test-open.h: ...into new file.
110385         * tests/test-fcntl-safer.c: New file.
110386         * modules/open-tests (Files): Add test-open.h.
110387         * modules/fcntl-safer-tests: New file.
110388         Suggested by Bruno Haible.
110390         test-fopen-safer: split from test-fopen
110391         * tests/test-fopen.c (main): Move...
110392         * tests/test-fopen.h: ...into new file.
110393         * tests/test-fopen-safer.c: New file.
110394         * modules/fopen-tests (Files): Add test-fopen.h.
110395         * modules/fopen-safer-tests: New file.
110396         Suggested by Bruno Haible.
110398 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
110400         popen-safer: test O_CLOEXEC at run-time.
110401         * lib/popen-safer.c: Test O_CLOEXEC at run-time.
110403 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
110405         fcntl: move more flags to the header
110406         * lib/cloexec.c: Do not define FD_CLOEXEC here.
110407         * lib/popen-safer.c: Do not alias O_NOINHERIT to O_CLOEXEC here.
110408         * lib/fcntl.in.h: Do both things here.
110410 2009-08-21  Jim Meyering  <meyering@redhat.com>
110412         consistently remove $@-t before redirecting to it
110413         * modules/argz: Remove $@-t and $@ before redirecting to the former.
110414         * modules/alloca-opt: Likewise.
110415         * modules/byteswap: Likewise.
110416         * modules/fnmatch: Likewise.
110417         * modules/getopt-posix: Likewise.
110418         * modules/glob: Likewise.
110419         * modules/poll: Likewise.
110420         * modules/posix_spawnp-tests: Likewise.
110421         * modules/sys_socket: Likewise.
110422         * modules/sysexits: Likewise.
110424 2009-08-21  Eric Blake  <ebb9@byu.net>
110426         popen: simplify access to original popen
110427         * lib/popen.c (rpl_popen): No need to worry about popen being a
110428         macro.
110429         Reported by Bruno Haible.
110431 2009-08-20  Eric Blake  <ebb9@byu.net>
110433         build: avoid some compiler warnings
110434         * lib/selinux-at.h: Use dir_fd, not dirfd, to avoid shadowing.
110435         * lib/exclude.c (fnmatch_pattern_has_wildcards): Use correct
110436         type.
110437         (new_exclude_segment, excluded_file_pattern_p)
110438         (excluded_file_name_p): Reduce scope.
110439         * lib/vasnprintf.c (decimal_point_char): Avoid warning on
110440         old-style declaration.
110442 2009-08-20  Simon Josefsson  <simon@josefsson.org>
110444         * tests/test-exclude1.sh: Handle Windows EOL.
110445         * tests/test-exclude2.sh: Likewise.
110446         * tests/test-exclude3.sh: Likewise.
110447         * tests/test-exclude4.sh: Likewise.
110448         * tests/test-exclude5.sh: Likewise.
110449         * tests/test-exclude6.sh: Likewise.
110450         * tests/test-exclude7.sh: Likewise.
110452 2009-08-19  Akim Demaille  <demaille@gostai.com>
110454         bootstrap: find sha1sum when named gsha1sum.
110455         * bootstrap (find_tool): New.
110456         ($SHA1SUM): New.
110457         Use it.
110459 2009-08-20  Jim Meyering  <meyering@redhat.com>
110461         maint.mk: _header_without_use: fix a quoting bug and remove a bash'ism
110462         * top/maint.mk (_header_without_use): Use "\\\\", not "\\" in the sed
110463         expression that converts "." in a file name to "\." in the resulting
110464         regexp.  Start with a dummy statement, so that prior shell variable
110465         definitions are expanded portably.  Reported by Simon Josefsson.
110467 2009-08-20  Paolo Bonzini  <bonzini@gnu.org>
110469         Fix polling for writeability of a screen buffer.
110470         * lib/poll.c: Distinguish input and screen buffers for the
110471         Win32 implementation.
110472         * lib/select.c: Likewise.
110474 2009-08-19  Eric Blake  <ebb9@byu.net>
110476         popen-safer: prevent popen from clobbering std descriptors
110477         * modules/popen-safer: New file.
110478         * lib/popen-safer.c: Likewise.
110479         * m4/stdio-safer.m4 (gl_POPEN_SAFER): New macro.
110480         * lib/stdio--.h (popen): Provide override.
110481         * lib/stdio-safer.h (popen_safer): Provide declaration.
110482         * tests/test-popen.c (includes): Partially test this.
110483         * modules/popen-safer-tests: New file, for more tests.
110484         * tests/test-popen-safer.c: Likewise.
110485         * MODULES.html.sh (file stream based Input/Output): Mention it.
110487         tests: test some of the *-safer modules
110488         * modules/fopen-safer (Depends-on): Add fopen.
110489         * modules/fcntl-safer (Depends-on): Add fcntl.
110490         * modules/stdlib-safer (Depends-on): Add stdlib.
110491         (configure.ac): Set indicator.
110492         * modules/unistd-safer (configure.ac): Likewise.
110493         * modules/tmpfile-safer (configure.ac): Likewise.
110494         (Depends-on): Add tmpfile.
110495         * lib/stdio--.h (fopen, tmpfile): Don't override unless module is
110496         active.
110497         * tests/test-fopen.c (includes): Test safer versions when they are
110498         in use.
110499         * tests/test-open.c (includes): Likewise.
110501         popen: fix cygwin 1.5 bug when stdin closed
110502         * doc/posix-functions/popen.texi (popen): Document cygwin bugs.
110503         * modules/popen: New file.
110504         * modules/popen-tests: Likewise.
110505         * tests/test-popen.c: Likewise.
110506         * m4/popen.m4: Likewise.
110507         * lib/popen.c: Likewise.
110508         * lib/stdio.in.h (popen): New declaration.
110509         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add popen.
110510         * modules/stdio (Makefile.am): Likewise.
110511         * MODULES.html.sh (systems lacking POSIX:2008): Mention it.
110513 2009-08-17  Joel E. Denny  <jdenny@clemson.edu>
110515         maint.mk: give full control over update-copyright exclusions
110516         * top/maint.mk (VC_LIST_EXCEPT): Instead of ChangeLog, use
110517         ${VC_LIST_EXCEPT_DEFAULT-ChangeLog} as the default exclusion.
110518         (update-copyright): Don't force inclusion of top-level
110519         ChangeLog.  Don't force exclusion of all COPYING files, but make
110520         them the default exclusion instead.
110522 2009-08-16  Bruno Haible  <bruno@clisp.org>
110524         Fix test failures on Solaris 10.
110525         * tests/uniconv/test-u8-conv-from-enc.c (main): Disable autodetect_jp
110526         tests when Solaris iconv() is used.
110527         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
110528         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
110529         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
110530         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
110531         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
110533 2009-08-16  Bruno Haible  <bruno@clisp.org>
110535         Fix test failures on Solaris 10.
110536         * tests/test-pipe-filter-ii1.sh: Determine the filename of a working
110537         'tr' program and pass it as first argument.
110538         * tests/test-pipe-filter-gi1.sh: Likewise.
110539         * tests/test-pipe-filter-ii1.c (main): Except the filename of a 'tr'
110540         program as first argument.
110541         * tests/test-pipe-filter-gi1.c (main): Likewise.
110543 2009-08-16  Eric Blake  <ebb9@byu.net>
110545         fpurge: fix previous commits
110546         * modules/fpurge (Makefile.am): Make replacement conditional,
110547         partially reverting 2007-04-29 change; missed in previous
110548         attempt.
110549         * m4/fpurge.m4 (gl_FUNC_FPURGE): Also compile fpurge.c when fpurge
110550         is missing.
110552 2009-08-16  Bruno Haible  <bruno@clisp.org>
110554         Clarify fpurge's effect on the file position.
110555         * lib/stdio.in.h (fpurge): Specify the file position after fpurge.
110556         * tests/test-fpurge.c (main): Make a second pass for checking the file
110557         position.
110559 2009-08-16  Bruno Haible  <bruno@clisp.org>
110561         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't compile fpurge.c if only the
110562         declaration of fpurge is missing.
110563         * tests/test-fpurge.c (main): Check that the file has not more contents
110564         than expected. Close the file before removing it.
110566 2009-08-15  Eric Blake  <ebb9@byu.net>
110568         fpurge: don't wrap working cygwin implementation
110569         * lib/fpurge.c (fpurge): Fix comment typo.
110570         * m4/fpurge.m4 (gl_FUNC_FPURGE): Detect BSD bug, allowing cygwin
110571         1.7 to avoid replacement.
110572         * tests/test-fpurge.c (main): Enhance test.
110574 2009-08-15  Eric Blake  <ebb9@byu.net>
110575         and Jim Meyering  <meyering@redhat.com>
110577         test-update-copyright: skip if perl is insufficient
110578         * tests/test-update-copyright.sh: Failure to run maintainer tool
110579         should not cause testsuite failure on cygwin 1.5.
110581 2009-08-14  Eric Blake  <ebb9@byu.net>
110583         doc: mention more functions added in cygwin 1.7.0
110584         * doc/posix-headers/limits.texi (limits.h): Update for recent
110585         cygwin additions.
110586         * doc/posix-headers/wordexp.texi (wordexp.h): Likewise.
110587         * doc/posix-functions/wordexp.texi (wordexp): Likewise.
110588         * doc/posix-functions/wordfree.texi (wordfree): Likewise.
110589         * doc/posix-functions/setlocale.texi (setlocale): Likewise.
110590         * doc/posix-functions/nl_langinfo.texi (nl_langinfo): Likewise.
110592 2009-08-14  Eric Blake  <ebb9@byu.net>
110594         maint.mk: simplify update-copyright rule
110595         * top/maint.mk (update-copyright-local): Delete, and document how
110596         to do it in cfg.mk instead.
110597         (update-copyright-exclude-regexp): Delete, and document how to do
110598         it in .x-update-copyright instead.
110599         (update-copyright): Simplify, thanks to VC_LIST_EXCEPT.  Don't
110600         exclude ChangeLog.
110602 2009-08-14  Bruno Haible  <bruno@clisp.org>
110604         * m4/wchar.m4 (gl_WCHAR_H): Undo invalid optimization in last commit.
110606 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
110608         maint.mk: support update-copyright-env
110609         * top/maint.mk (update-copyright-env): Define place-holder.
110610         (update-copyright): Expand $(update-copyright-env) before
110611         invoking update-copyright.
110613 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
110615         update-copyright: implement forced reformatting
110616         * build-aux/update-copyright: Implement and document
110617         UPDATE_COPYRIGHT_FORCE.
110618         * tests/test-update-copyright.sh: Test it.
110620 2009-08-14  Eric Blake  <ebb9@byu.net>
110621         and Bruno Haible  <bruno@clisp.org>
110623         stddef: fix NetBSD 5.0 NULL bug, rather than working around it
110624         * tests/test-locale.c: Revert previous patch related to NULL.
110625         * tests/test-stdio.c: Likewise.
110626         * tests/test-stdlib.c: Likewise.
110627         * tests/test-string.c: Likewise.
110628         * tests/test-unistd.c: Likewise.
110629         * modules/time-tests (Depends-on): Add verify.
110630         * modules/wchar-tests (Depends-on): Likewise.
110631         * tests/test-time.c: Test for NULL compliance.
110632         * tests/test-wchar.c: Likewise.
110633         * modules/locale (Depends-on): Add stddef.
110634         * modules/stdio (Depends-on): Likewise.
110635         * modules/stdlib (Depends-on): Likewise.
110636         * modules/string (Depends-on): Likewise.
110637         * modules/time (Depends-on): Likewise.
110638         * modules/unistd (Depends-on): Likewise.
110639         * modules/wchar (Depends-on): Likewise.
110640         * lib/locale.in.h (includes): Use <stddef.h> to fix NULL.
110641         * lib/stdlib.in.h (includes): Likewise.
110642         * lib/string.in.h (includes): Likewise.
110643         * lib/time.in.h (includes): Likewise.
110644         * lib/unistd.in.h (includes): Likewise.
110645         * m4/locale_h.m4 (gl_LOCALE_H): Replace locale.h if stddef.h was
110646         replaced.
110647         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
110648         * m4/stddef_h.m4: New file.
110649         * modules/stddef: Likewise.
110650         * lib/stddef.in.h: Likewise.
110651         * modules/stddef-tests: Likewise.
110652         * tests/test-stddef.c: Likewise.
110653         * MODULES.html.sh (Basic types <stddef.h>): Mention new module.
110654         * doc/posix-headers/stddef.texi (stddef.h): Document the bug.
110655         * doc/posix-headers/locale.texi (locale.h): Likewise.
110656         * doc/posix-headers/stdio.texi (stdio.h): Likewise.
110657         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
110658         * doc/posix-headers/string.texi (string.h): Likewise.
110659         * doc/posix-headers/time.texi (time.h): Likewise.
110660         * doc/posix-headers/unistd.texi (unistd.h): Likewise.
110661         * doc/posix-headers/wchar.texi (wchar.h): Likewise.
110663 2009-08-14  Eric Blake  <ebb9@byu.net>
110665         doc: improve git diff of texinfo files
110666         * .gitattributes: Add rule for *.texi files, with hint on how to
110667         use it.
110668         Copied from m4, and based on a report by Bruno Haible.
110670 2009-08-14  Bruno Haible  <bruno@clisp.org>
110672         Disable multithread support by default on Cygwin 1.5.x for real.
110673         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Fix last commit.
110675 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
110677         update-copyright: much ado about intervals
110678         * build-aux/update-copyright: Implement and document
110679         UPDATE_COPYRIGHT_USE_INTERVALS to control expansion and collapse
110680         of copyright year intervals.
110681         Also, document UPDATE_COPYRIGHT_YEAR.
110682         * tests/test-update-copyright.sh: Test it.
110684         update-copyright: convert 2-digit to 4-digit years
110685         * build-aux/update-copyright: Implement and document.
110686         * tests/test-update-copyright.sh: Update.
110688 2009-08-14  Jim Meyering  <meyering@redhat.com>
110690         test-exclude: avoid coreutils "make check" failure
110691         * tests/test-exclude.c (ARGMATCH_DIE_DECL) [ARGMATCH_DIE_DECL]: Define,
110692         just as in test-argmatch.c.
110694 2009-08-13  Eric Blake  <ebb9@byu.net>
110696         test-dup2: fix bad assumption
110697         * tests/test-dup2.c (main): Tolerate leaked fds from environment.
110698         Reported by Peter Breitenlohner <peb@mppmu.mpg.de>.
110700         test-version-etc: fix CRLF portability issue
110701         * tests/test-version-etc.sh: Use tr, not sed, as not all sed
110702         recognize \r.
110703         * tests/test-argp-version-etc-1.sh: Likewise.
110705         getopt: update client modules
110706         * modules/argp (Depends-on): Use getopt-gnu.
110707         * modules/git-merge-changelog (Depends-on): Likewise.
110708         * modules/long-options (Depends-on): Likewise.
110709         * modules/xstrtol (Depends-on): Likewise.
110711 2009-08-13  Simon Josefsson  <simon@josefsson.org>
110713         * tests/test-version-etc.sh: Don't fail on different
110714         project/version.  Don't fail on CRLF differences.  Rewrite to use
110715         multiple -e instead of multiple sed forks, suggested by Eric Blake
110716         <ebb9@byu.net>.
110717         * tests/test-argp-version-etc-1.sh: Likewise.
110719 2009-08-13  Simon Josefsson  <simon@josefsson.org>
110721         * tests/test-version-etc.sh: Don't fail on different
110722         project/version.
110724 2009-08-12  Bruno Haible  <bruno@clisp.org>
110726         Tests for modules 'getopt-posix', 'getopt-gnu'.
110727         * modules/getopt-posix-tests: New file.
110728         * tests/test-getopt.c: New file.
110729         * tests/test-getopt.h: New file.
110730         * tests/test-getopt_long.h: New file.
110732         New modules 'getopt-posix', 'getopt-gnu'.
110733         * modules/getopt-gnu: New file, renamed from modules/getopt.
110734         * modules/getopt-posix: New file.
110735         * modules/getopt: Turn into an obsolete alias for getopt-gnu.
110736         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX, gl_FUNC_GETOPT_GNU): New macros.
110737         (gl_GETOPT): Remove macro.
110738         (gl_GETOPT_CHECK_HEADERS): Do some checks only for gl_FUNC_GETOPT_GNU.
110739         Disable the test against BSD systems that declare optreset. Test
110740         against mingw bug. Test against lack of support of optional arguments
110741         on many platforms.
110742         * doc/glibc-headers/getopt.texi: Update module name and list of
110743         relevant platforms.
110744         * doc/posix-functions/getopt.texi: Mention modules 'getopt-posix' and
110745         'getopt-gnu' and more portability problems.
110746         * NEWS: Mention the changes.
110748 2009-08-12  Bruno Haible  <bruno@clisp.org>
110750         Ensure that optarg etc. get declared by <unistd.h>.
110751         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require
110752         AC_USE_SYSTEM_EXTENSIONS.
110753         * modules/getopt (Depends-on): Add 'extensions'.
110755 2009-08-12  Bruno Haible  <bruno@clisp.org>
110757         Avoid test link errors.
110758         * modules/pipe-filter-ii-tests (Makefile.am): Define
110759         test_pipe_filter_ii1_LDADD and test_pipe_filter_ii2_main_LDADD.
110760         * modules/pipe-filter-gi-tests (Makefile.am): Define
110761         test_pipe_filter_gi1_LDADD and test_pipe_filter_gi2_main_LDADD.
110762         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
110764 2009-08-12  Bruno Haible  <bruno@clisp.org>
110766         * m4/getopt.m4 (gl_REPLACE_GETOPT): New macro, was called
110767         gl_GETOPT_SUBSTITUTE before.
110768         (gl_GETOPT): Use it.
110769         * m4/argp.m4 (gl_ARGP): Update.
110770         Reported by Sergey Poznyakoff.
110772         * m4/getopt.m4: Reorder macros.
110773         (gl_GETOPT): Inline gl_GETOPT_SUBSTITUTE.
110774         (gl_GETOPT_SUBSTITUTE): Remove macro.
110776 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
110778         Minor improvement in gitlog-to-changelog
110780         * build-aux/gitlog-to-changelog: New option `--format' makes
110781         output format string configurable.
110783 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
110785         Optimize exclude: use hash tables for non-wildcard patterns.
110787         * lib/exclude.c: Include hash.h and mbuiter.h
110788         (struct exclude_pattern, exclude_segment): New data types.
110789         (struct exclude): Rewrite.
110790         (fnmatch_pattern_has_wildcards): New function.
110791         (new_exclude_segment, free_exclude_segment): New functions.
110792         (excluded_file_pattern_p, excluded_file_name_p): New functions.
110793         (excluded_file_name, add_exclude): Rewrite using new struct exclude.
110794         * lib/exclude.h (is_fnmatch_pattern): New prototype.
110795         * modules/exclude: Depend on hash and mbuiter.
110797         * modules/exclude-tests: New file.
110798         * tests/test-exclude.c: New file.
110799         * tests/test-exclude1.sh: New file.
110800         * tests/test-exclude2.sh: New file.
110801         * tests/test-exclude3.sh: New file.
110802         * tests/test-exclude4.sh: New file.
110803         * tests/test-exclude5.sh: New file.
110804         * tests/test-exclude6.sh: New file.
110805         * tests/test-exclude7.sh: New file.
110807 2009-08-12  Bruno Haible  <bruno@clisp.org>
110809         Ensure that getopt() gets declared by <unistd.h>.
110810         * lib/unistd.in.h: Conditionally include getopt.h.
110811         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Require gl_UNISTD_H_DEFAULTS.
110812         Set GNULIB_UNISTD_H_GETOPT.
110813         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
110814         GNULIB_UNISTD_H_GETOPT.
110815         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_GETOPT.
110817 2009-08-12  Bruno Haible  <bruno@clisp.org>
110819         Clarify logic.
110820         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS, gl_GETOPT_IFELSE): Use
110821         gl_replace_getopt instead of GETOPT_H.
110823 2009-08-12  Bruno Haible  <bruno@clisp.org>
110825         * m4/getopt.m4: Add comments.
110827 2009-08-12  Bruno Haible  <bruno@clisp.org>
110829         Disable multithread support by default on Cygwin 1.5.x.
110830         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): On Cygwin 1.5.x and older,
110831         set gl_use_threads=no if not specified otherwise.
110833 2009-08-11  Bruno Haible  <bruno@clisp.org>
110835         Avoid compilation error on NetBSD 5.0.
110836         * tests/test-locale.c: Write sizeof (NULL) instead of sizeof NULL.
110837         * tests/test-stdio.c: Likewise.
110838         * tests/test-stdlib.c: Likewise.
110839         * tests/test-string.c: Likewise.
110840         * tests/test-unistd.c: Likewise.
110841         Reported by Greg Troxel <gdt@ir.bbn.com>
110842         at <https://savannah.gnu.org/support/?106973>.
110844 2009-08-11  Bruno Haible  <bruno@clisp.org>
110846         * modules/dup2-tests (Depends-on): Remove close.
110848         Undo 2009-07-19 commit.
110849         * modules/acl-tests (Depends-on): Remove close.
110850         * modules/binary-io-tests (Depends-on): Likewise.
110851         * modules/closein-tests (Depends-on): Likewise.
110852         * modules/flock-tests (Depends-on): Likewise.
110853         * modules/fsync-tests (Depends-on): Likewise.
110854         * modules/lseek-tests (Depends-on): Likewise.
110855         * modules/pipe-tests (Depends-on): Likewise.
110856         * modules/posix_spawn-tests (Depends-on): Likewise.
110857         * modules/posix_spawnp-tests (Depends-on): Likewise.
110858         * modules/stat-time-tests (Depends-on): Likewise.
110859         * modules/yesno-tests (Depends-on): Likewise.
110861 2009-08-10  Bruno Haible  <bruno@clisp.org>
110863         * lib/vasnprintf.c (DCHAR_SET): Undefine at the end.
110865 2009-08-10  Bruno Haible  <bruno@clisp.org>
110867         Fix a gcc warning.
110868         * lib/write.c (rpl_write): Cast result of _get_osfhandle.
110870 2009-08-10  Bruno Haible  <bruno@clisp.org>
110872         Don't optimize AC_LIBOBJs, as they may appear in different contexts.
110873         * m4/close.m4 (gl_REPLACE_CLOSE): Execute AC_LIBOBJ unconditionally,
110874         not only the first time.
110875         * m4/fclose.m4 (gl_REPLACE_FCLOSE): Likewise.
110876         * m4/open.m4 (gl_REPLACE_OPEN): Likewise.
110877         * m4/strstr.m4 (gl_FUNC_STRSTR): Execute AC_LIBOBJ when REPLACE_STRSTR
110878         is 1, not only the first time.
110880 2009-08-10  Bruno Haible  <bruno@clisp.org>
110882         Make it possible to use module 'gethostname' without module 'close'.
110883         * lib/unistd.in.h (close): Evoke a link error only if
110884         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
110885         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
110886         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
110887         * modules/unistd (Makefile.am): Substitute
110888         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
110889         * lib/sys_ioctl.in.h (ioctl): Evoke a link error only if
110890         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
110891         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Initialize
110892         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
110893         * modules/sys_ioctl (Makefile.am): Substitute
110894         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
110895         * modules/socket (configure.ac): On native Windows, set
110896         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS and
110897         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
110898         Reported by Sam Steingold <sds@gnu.org>.
110900 2009-08-10  Bruno Haible  <bruno@clisp.org>
110902         * m4/close.m4 (gl_FUNC_CLOSE): Add comment.
110903         * modules/ioctl (configure.ac): Likewise.
110905 2009-08-10  Bruno Haible  <bruno@clisp.org>
110907         Avoid collision between gnulib wrapper and libintl wrapper.
110908         * lib/stdio-write.c (printf): Don't define if a printf wrapper is
110909         already defined in intl/printf.c.
110910         (vprintf): Test REPLACE_VPRINTF_POSIX, not REPLACE_VFPRINTF_POSIX.
110911         (vfprintf): Test REPLACE_VFPRINTF_POSIX, not REPLACE_VPRINTF_POSIX.
110913 2009-08-09  Bruno Haible  <bruno@clisp.org>
110915         Make <sys/select.h> really self-contained, also on Solaris 10.
110916         * lib/sys_select.in.h: Include <string.h>.
110917         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Test also against
110918         Solaris 10 problem.
110919         * tests/test-sys_select.c (main): Add check that FD_ZERO can be used.
110920         * doc/posix-headers/sys_select.texi: Mention the Solaris 10 problem.
110921         Reported by Jim Meyering.
110923 2009-08-09  Bruno Haible  <bruno@clisp.org>
110925         Avoid warnings from 'aclocal' that are due to a use of macro name
110926         AM_XGETTEXT_OPTION that is not defined in automake.
110927         * modules/argp (configure.ac): Hide use of AM_XGETTEXT_OPTION from
110928         automake.
110929         * modules/error (configure.ac): Likewise.
110930         * modules/propername (configure.ac): Likewise.
110931         * modules/vasprintf (configure.ac): Likewise.
110932         * modules/verror (configure.ac): Likewise.
110933         * modules/xprintf (configure.ac): Likewise.
110934         * modules/xvasprintf (configure.ac): Likewise.
110936 2009-08-08  Bruno Haible  <bruno@clisp.org>
110938         Avoid compilation error in C++ mode.
110939         * lib/gettimeofday.c (rpl_gettimeofday): Cast timezone argument.
110940         Reported by Sam Steingold <sds@gnu.org>.
110942 2009-08-08  Bruno Haible  <bruno@clisp.org>
110944         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Define HOST_NAME_MAX also
110945         for the various Unix platforms.
110946         * doc/posix-headers/limits.texi: Update platforms list regarding
110947         HOST_NAME_MAX.
110948         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
110950 2009-08-07  Jim Meyering  <meyering@redhat.com>
110952         selinux-at: fix typo in a comment
110953         * lib/selinux-at.h: s/getfileconat/getfilecon/ in a comment.
110954         Spotted by Paolo Bonzini.
110956         selinux-at: remove redundant m4 code, add documentation
110957         * modules/selinux-at (configure.ac): Remove redundant code.
110958         LIB_SELINUX is already set via the dependent module, selinux-h.
110959         (Include): Add quotes around selinux-at.h.
110960         * lib/selinux-at.h: Add documentation.
110961         Reported by Bruno Haible in
110962         http://marc.info/?l=gnulib-bug&m=124958988300749
110964 2009-08-07  Bruno Haible  <bruno@clisp.org>
110966         Avoid link error on MacOS X 10.3 and 10.4.
110967         * lib/argp-ba.c (argp_program_bug_address): Explicitly zero-initialize
110968         on non-ELF systems.
110969         * lib/argp-pv.c (argp_program_version): Likewise.
110970         Reported by Simon Josefsson.
110972 2009-08-07  Simon Josefsson  <simon@josefsson.org>
110974         * tests/test-version-etc.sh: Use $EXEEXT.
110976 2009-08-06  Joel E. Denny  <jdenny@clemson.edu>
110978         update-copyright: update documentation to point to maint.mk
110979         * build-aux/update-copyright: Here.
110981 2009-08-06  Jim Meyering  <meyering@redhat.com>
110983         maint.mk: support update-copyright-local
110984         * top/maint.mk (update-copyright-local): Define place-holder.
110985         (update-copyright): Depend on $(update-copyright-local).
110987 2009-08-06  Jim Meyering  <meyering@redhat.com>
110989         selinux-at: new module
110990         Initially written for coreutils, this module will soon be
110991         used by findutils, too.
110992         * MODULES.html.sh [Misc]: Add selinux-at.
110993         * lib/selinux-at.h: New file, from coreutils.
110994         * lib/selinux-at.c: Likewise.
110995         * modules/selinux-at: Likewise.
110996         (License): Change from LGPL to GPL, since it depends
110997         on the GPL'd openat module.
110999         doc: update README
111000         * README: Remove references to cogito.
111001         Remove cvs-repo-updating instructions from 2007.
111002         Don't imply that CVS is better if you have limited disk space.
111004 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
111006         update-copyright: support C-style comments
111007         * build-aux/update-copyright: Implement and document.
111008         * tests/test-update-copyright.sh: Test.
111010 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
111012         update-copyright: support omitted "(C)"
111013         * build-aux/update-copyright: Implement and document.  Also,
111014         allow variable whitespace before "(C)".
111015         * tests/test-update-copyright.sh: Test.
111017 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
111019         update-copyright: don't trip on non-FSF copyright statements
111020         * build-aux/update-copyright: Fix so that the first correctly
111021         formatted FSF copyright statement is recognized no matter what
111022         appears before it.  Update documentation.
111023         * tests/test-update-copyright.sh: Test that.
111025 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
111027         update-copyright: clean up code a little
111028         * build-aux/update-copyright: Append "_re" to the name of any
111029         variable holding a regular expression.
111030         Replace "old" and "new" with "stmt" in variable names.
111031         Do not accept 2-digit UPDATE_COPYRIGHT_YEAR, which was not
111032         handled correctly.
111033         Format code more consistently.
111035 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
111037         update-copyright-tests: improve portability
111038         * tests/test-update-copyright.sh: Use cmp if diff cannot handle
111039         -u or /dev/null.  Suggested by Jim Meyering and Eric Blake.
111041 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
111043         update-copyright: support @copyright{} and &copy;
111044         * build-aux/update-copyright: Implement and document.
111045         * tests/test-update-copyright.sh: Test.
111047 2009-08-04  Jim Meyering  <meyering@redhat.com>
111049         update-copyright-tests: correctly test EOL=\r\n handling
111050         * tests/test-update-copyright.sh: Put \r at the end of some lines
111051         for the dos-eol tests.  Based on a patch by Joel E. Denny.
111053         maint.mk: make update-copyright exclusion list more configurable
111054         * top/maint.mk (update-copyright): Default to excluding COPYING,
111055         but allow an override, in case someone does want to update that file.
111057         maint.mk: don't update copyright date in COPYING
111058         * top/maint.mk (update-copyright): Exclude COPYING.
111060         maint.mk: add a copyright-updating rule
111061         * top/maint.mk (update-copyright): New rule.
111062         Derived from coreutils/Makefile.am.
111064         update-copyright: rename some variables
111065         * build-aux/update-copyright: Rename a few variables for clarity.
111066         Tweak syntax.  List Joel E. Denny as coauthor.
111068 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
111070         update-copyright: fix bug for 2-digit last year and add tests
111071         * build-aux/update-copyright: Fix bug.
111072         Use UPDATE_COPYRIGHT_YEAR from environment as current year if
111073         specified.
111074         * modules/update-copyright-tests: New
111075         * tests/test-update-copyright.sh: New.
111077 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
111079         update-copyright: handle leading tabs in line prefix
111080         * build-aux/update-copyright: Count leading tabs as 8 spaces
111081         when computing margin.  This helps with the formatting of
111082         ChangeLogs, for example.
111083         Fix documentation a little.
111085 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
111087         update-copyright: support EOL=\r\n
111088         * build-aux/update-copyright: Implement that.
111090 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
111092         update-copyright: automatically format copyright statements
111093         * build-aux/update-copyright: Implement that.
111094         Also, be a little more predictable and safer by always failing
111095         when the full copyright format is not perfectly recognized as an
111096         unbroken whole.  Discussed at
111097         <http://lists.gnu.org/r/bug-gnulib/2009-07/msg00131.html>.
111098         Rewrite documentation.
111100 2009-08-03  Bruno Haible  <bruno@clisp.org>
111102         * m4/iconv.m4 (AM_ICONV): Fix displayed message with autoconf-2.64.
111104 2009-08-02  Bruno Haible  <bruno@clisp.org>
111106         Tests for module 'uname'.
111107         * modules/uname-tests: New file.
111108         * tests/test-uname.c: New file.
111110         New module 'uname'.
111111         * lib/uname.c: New file.
111112         * m4/uname.m4: New file.
111113         * modules/uname: New file.
111114         * doc/posix-functions/uname.texi: Mention the new module.
111116 2009-08-02  Bruno Haible  <bruno@clisp.org>
111118         Tests for module 'sys_utsname'.
111119         * modules/sys_utsname-tests: New file.
111120         * tests/test-sys_utsname.c: New file.
111122         New module 'sys_utsname'.
111123         * lib/sys_utsname.in.h: New file, based on glibc's <sys/utsname.h>.
111124         * m4/sys_utsname_h.m4: New file.
111125         * modules/sys_utsname: New file.
111126         * doc/posix-headers/sys_utsname.texi: Mention the new module.
111128 2009-08-02  Bruno Haible  <bruno@clisp.org>
111130         Implicitly initialize the sockets library.
111131         * lib/gethostname.c: Include sockets.h.
111132         (rpl_gethostname): Invoke gl_sockets_startup.
111133         * lib/socket.c: Include sockets.h.
111134         (rpl_socket): Invoke gl_sockets_startup.
111135         * modules/gethostname (Depends-on): Add sockets.
111136         * modules/socket (Depends-on): Likewise.
111137         * tests/test-poll.c: Don't include sockets.h.
111138         (main): Don't invoke gl_sockets_startup.
111139         * tests/test-select.c: Don't include sockets.h.
111140         (main): Don't invoke gl_sockets_startup.
111142 2009-08-02  Bruno Haible  <bruno@clisp.org>
111144         Allow multiple calls to gl_sockets_startup.
111145         * lib/sockets.c (initialized_sockets_version): New variable.
111146         (gl_sockets_startup): Do nothing if already called for this or a higher
111147         version.
111148         (gl_sockets_cleanup): Reset initialized_sockets_version.
111150 2009-08-03  Simon Josefsson  <simon@josefsson.org>
111152         * tests/test-argp-version-etc-1.sh: Use EXEEXT.  Don't fail on
111153         different project/version.
111155 2009-08-02  Paolo Bonzini  <bonzini@gnu.org>
111156             Bruno Haible  <bruno@clisp.org>
111158         Tests for module 'pipe-filter-gi'.
111159         * modules/pipe-filter-gi-tests: New file.
111160         * tests/test-pipe-filter-gi1.sh: New file.
111161         * tests/test-pipe-filter-gi1.c: New file.
111162         * tests/test-pipe-filter-gi2.sh: New file.
111163         * tests/test-pipe-filter-gi2-main.c: New file.
111164         * tests/test-pipe-filter-gi2-child.c: New file.
111166         New module 'pipe-filter-gi'.
111167         * lib/pipe-filter-gi.c: New file.
111168         * modules/pipe-filter-gi: New file.
111170 2009-08-02  Bruno Haible  <bruno@clisp.org>
111171             Paolo Bonzini  <bonzini@gnu.org>
111173         Tests for module 'pipe-filter-ii'.
111174         * modules/pipe-filter-ii-tests: New file.
111175         * tests/test-pipe-filter-ii1.sh: New file.
111176         * tests/test-pipe-filter-ii1.c: New file.
111177         * tests/test-pipe-filter-ii2.sh: New file.
111178         * tests/test-pipe-filter-ii2-main.c: New file.
111179         * tests/test-pipe-filter-ii2-child.c: New file.
111181         New module 'pipe-filter-ii'.
111182         * lib/pipe-filter.h: New file.
111183         * lib/pipe-filter-ii.c: New file.
111184         * lib/pipe-filter-aux.h: New file.
111185         * modules/pipe-filter-ii: New file.
111187 2009-08-02  Simon Josefsson  <simon@josefsson.org>
111189         * lib/gc-libgcrypt.c: Change copyright to FSF.
111190         * lib/gc-gnulib.c: Likewise.
111192 2009-08-02  Martin Lambers  <marlam@marlam.de>  (tiny change)
111194         * lib/gethostname.c: Include limits.h.
111196 2009-08-02  Simon Josefsson  <simon@josefsson.org>
111197             Bruno Haible  <bruno@clisp.org>
111199         Ensure HOST_NAME_MAX as part of the gethostname module.
111200         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): On native Windows platforms,
111201         define also HOST_NAME_MAX.
111202         * tests/test-gethostname.c: Include <limits.h>.
111203         (main): Check also HOST_NAME_MAX.
111204         * doc/posix-headers/limits.texi: Document the mingw problem.
111206 2009-08-02  Bruno Haible  <bruno@clisp.org>
111208         * lib/gethostname.c (gethostname): Fix handling of large len argument.
111209         Add comments.
111211 2009-03-31  Simon Josefsson  <simon@josefsson.org>
111213         * lib/gethostname.c: Add Windows wrapper.
111214         * m4/gethostname.m4: Look for gethostname in -lws2_32.
111215         * modules/gethostname: Depend on sys_socket & errno, for also
111216         added lib/w32sock.h.  Add GETHOSTNAME_LIB link directive.
111217         * modules/gethostname-tests: Link to @GETHOSTNAME_LIB@.
111219 2009-07-31  Jim Meyering  <meyering@redhat.com>
111221         getloadavg: fix symbol name in comment
111222         * lib/getloadavg.c: Correct a typo I introduced when adding
111223         comments to Matt's change: s/NLIST_POINTER/N_NAME_POINTER/.
111224         Matt Kraai spotted the problem.
111226 2009-07-29  Matt Kraai  <mkraai@beckman.com>
111228         getloadavg: check whether n_name is a pointer, for QNX 6.4.1
111229         * lib/getloadavg.c (getloadavg): Use the strcpy-into-nlist.n_name
111230         code also if ! defined N_NAME_POINTER.
111231         * m4/getloadavg.m4 (gl_GETLOADAVG): Add a link-test for N_NAME_POINTER.
111232         This is required on QNX 6.4.1, where /usr/include/nlist.h exists,
111233         but the n_name member is a 12-byte array.
111235 2009-07-29  Joel E. Denny  <jdenny@clemson.edu>
111237         update-copyright: generalize comment handling
111238         * build-aux/update-copyright: Handle copyright statements
111239         within more comment styles.
111240         Document usage.
111241         Report any file with an external copyright holder or parse failure.
111243 2009-07-29  Jim Meyering  <meyering@redhat.com>
111245         mktime: correct setting of REPLACE_MKTIME
111246         * m4/mktime.m4 (gl_FUNC_MKTIME): Set REPLACE_MKTIME=0, when required.
111248         update-copyright: new module
111249         * modules/update-copyright: New file.
111250         * build-aux/update-copyright: New file.
111251         * MODULES.html.sh (maint+release support): Add update-copyright.
111253 2009-07-27  Bruno Haible  <bruno@clisp.org>
111255         Fix compilation error when <ctime> is used and mktime is replaced.
111256         * lib/time.in.h (mktime): New declaration.
111257         * m4/mktime.m4 (gl_FUNC_MKTIME): Require gl_HEADER_TIME_H_DEFAULTS. Set
111258         REPLACE_MKTIME instead of defining mktime in config.h.
111259         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize REPLACE_MKTIME.
111260         * modules/time (Makefile.am): Substitute REPLACE_MKTIME.
111261         Reported by Ross McFarland <rwmcfa1@neces.com>.
111263 2009-07-27  Bruno Haible  <bruno@clisp.org>
111265         * lib/math.in.h (cosl, logl, sinl): Undefine before declaring it.
111266         Reported by Matt Kraai <mkraai@beckman.com>.
111268 2009-07-25  Jim Meyering  <meyering@redhat.com>
111270         maint.mk: avoid warnings about missing files
111271         * top/maint.mk (PREV_VERSION): Suppress stderr, to hide a
111272         diagnostic when .prev-version does not exist.
111273         (_cfg_mk): Define, so it can be empty when cfg.mk does not exist.
111274         (syntax-check-rules): Use $(_cfg_mk) to avoid a diagnostic about
111275         nonexistent cfg.mk.
111276         Suggestions from Simon Josefsson.
111278 2009-07-25  Bruno Haible  <bruno@clisp.org>
111280         * lib/math.in.h (cosl, logl, sinl): Don't declare if they are already
111281         defined as macros. Needed on QNX 6.4.1.
111282         Reported by Matt Kraai <mkraai@beckman.com>.
111284 2009-07-23  Jim Meyering  <meyering@redhat.com>
111286         maint.mk: invoke "make dist" with a working value of XZ_OPT
111287         * top/maint.mk (vc-dist): Use no "-" in the value of XZ_OPT.
111289 2009-07-22  Matt Kraai  <mkraai@beckman.com>  (tiny change)
111291         Make fseeko.c compile on QNX.
111292         * lib/fseeko.c (rpl_fseeko): Use the numerical value of _MWRITE.
111294 2009-07-22  Peter Simons  <simons@cryp.to>
111296         C++: wrap md2,md5,sha1,etc. function declarations in extern "C" scope
111297         * lib/md2.h [__cplusplus]: Wrap declarations in extern "C" scope.
111298         * lib/md4.h: Likewise.
111299         * lib/md5.h: Likewise.
111300         * lib/sha1.h: Likewise.
111301         * lib/sha256.h: Likewise.
111302         * lib/sha512.h: Likewise.
111304         tests-sha1: don't assign literal string to 'char *' variable
111305         * tests/test-sha1.c (main): Declare locals with "const" to match
111306         attributes of the right hand side.
111308 2009-07-21  Eric Blake  <ebb9@byu.net>
111310         dup2: fix more mingw problems
111311         * lib/dup2.c (rpl_dup2) [_WIN32]: Avoid hanging when duplicating
111312         fd to itself.
111313         * doc/posix-functions/dup2.texi (dup2): Document the bug.
111314         * lib/unistd.in.h (dup2) [REPLACE_FCHDIR]: Avoid name collision.
111315         * lib/fchdir.c (dup2): Manage preprocessor macros correctly.
111316         (rpl_dup2_fchdir): Rename from rpl_dup2, and let dup2 module take
111317         care of mingw bugs.
111319 2009-07-21  Jim Meyering  <meyering@redhat.com>
111321         vc-list-files: avoid failure when /bin/sh is dash
111322         * build-aux/vc-list-files: Avoid a shell portability problem with dash.
111323         On some Debian based systems, /bin/sh is a symlink to dash, and running
111324         this command would omit the "/" following each 'tests' prefix:
111325           dash -x build-aux/vc-list-files -C . tests
111326         That is because bash and dash work differently:
111327           $ for i in bash dash; do $i -c 'a=odd; a=ok b=$a; echo '$i' $b'; done
111328           bash ok
111329           dash odd
111331 2009-07-21  Eric Blake  <ebb9@byu.net>
111333         dup2-tests: test previous patch
111334         * modules/dup2-tests: New file.
111335         * tests/test-dup2.c: Likewise.
111336         * tests/test-open.c (main): Avoid unspecified behavior.
111337         * tests/test-pipe.c (child_main): Use dup2 semantics to simplify
111338         test.
111340         dup2: work around mingw and cygwin 1.5 bug
111341         * m4/dup2.m4 (gl_FUNC_DUP2): Detect mingw bug.
111342         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
111343         * modules/unistd (Makefile.am): Substitute it.
111344         * lib/unistd.in.h (dup2): Declare the replacement.
111345         * lib/dup2.c (dup2) [REPLACE_DUP2]: Implement it.
111346         * doc/posix-functions/dup2.texi (dup2): Document the bugs.
111347         * lib/fchdir.c (rpl_dup2): Don't collide with mingw replacement.
111348         * modules/execute (Depends-on): Add dup2.
111349         * modules/fseterr (Depends-on): Likewise.
111350         * modules/pipe (Depends-on): Likewise.
111351         * modules/posix_spawn-internal (Depends-on): Likewise.
111353 2009-07-21  Bruno Haible  <bruno@clisp.org>
111355         * modules/.gitattributes: New file.
111357 2009-07-20  Bruno Haible  <bruno@clisp.org>
111359         * tests/test-pipe.c (BACKUP_STDERR_FILENO): New macro.
111360         (main): Use it.
111362 2009-07-20  Eric Blake  <ebb9@byu.net>
111364         test-pipe: make a bit more robust.
111365         * tests/test-pipe.c (myerr): Allow error messages regardless of
111366         what we do to stderr.
111367         (test_pipe): Rearrange to avoid deadlock.
111368         (child_main): Try a larger read, to ensure we avoided deadlock.
111369         * lib/pipe.c (create_pipe) [_WIN32]: Fix comment.
111370         * lib/pipe.h (create_pipe_bidi): Document potential for deadlock
111371         if misused.
111373 2009-07-19  Jim Meyering  <meyering@redhat.com>
111375         fts: avoid false-positive cycle-detection
111376         * lib/fts.c (fts_read): Reinitialize cycle-detection data structures
111377         for each new command line argument.
111379 2009-07-19  Bruno Haible  <bruno@clisp.org>
111381         Fix build error on mingw with the modules sys_select and unistd.
111382         * modules/acl-tests (Depends-on): Add close.
111383         * modules/binary-io-tests (Depends-on): Likewise.
111384         * modules/closein-tests (Depends-on): Likewise.
111385         * modules/flock-tests (Depends-on): Likewise.
111386         * modules/fsync-tests (Depends-on): Likewise.
111387         * modules/lseek-tests (Depends-on): Likewise.
111388         * modules/pipe-tests (Depends-on): Likewise.
111389         * modules/posix_spawn-tests (Depends-on): Likewise.
111390         * modules/posix_spawnp-tests (Depends-on): Likewise.
111391         * modules/stat-time-tests (Depends-on): Likewise.
111392         * modules/yesno-tests (Depends-on): Likewise.
111394 2009-07-19  Bruno Haible  <bruno@clisp.org>
111396         Unify conditionals.
111397         * lib/pipe.h: Detect native Win32 by looking at _WIN32 and __WIN32__
111398         macros, not at the compiler macros.
111399         * lib/pipe.c: Likewise.
111400         * lib/execute.c: Likewise.
111401         * lib/spawni.c: Likewise.
111403 2009-07-19  Bruno Haible  <bruno@clisp.org>
111405         Fix handling of closed stdin/stdout/stderr on mingw.
111406         * lib/w32spawn.h: Include unistd.h.
111407         (dup_noinherit): Return -1 if the old handle is invalid. Allocate new
111408         file descriptor with O_NOINHERIT flag.
111409         (fd_safer_noinherit): New function, based on fd-safer.c.
111410         (dup_safer_noinherit): New function, based on dup-safer.c.
111411         (undup_safer_noinherit): New function.
111412         * lib/execute.c (execute) [WIN32]: Use dup_safer_noinherit instead of
111413         dup_noinherit. Use undup_safer_noinherit instead of dup2 and close.
111414         * lib/pipe.c (create_pipe) [WIN32]: Likewise. Use fd_safer_noinherit
111415         instead of fd_safer.
111416         * tests/test-pipe.c: Include <windows.h>.
111417         (child_main) [WIN32]: Test the handle of STDERR_FILENO, not its close()
111418         result.
111420         * tests/test-pipe.c (child_main, parent_main): New functions, extracted
111421         from main.
111422         (test_pipe): Pass an extra argument for disambiguation.
111423         (main): Invoke parent_main or child_main.
111425         * tests/test-pipe.c (test_pipe): Pass slave_process = true argument
111426         consistently.
111428 2009-07-18  Eric Blake  <ebb9@byu.net>
111430         test-pipe: fix mingw build
111431         * tests/test-pipe.c (main): Avoid fcntl on mingw.
111433 2009-07-18  Bruno Haible  <bruno@clisp.org>
111435         * modules/pipe-tests (Makefile.am): Fix typo.
111437 2009-07-18  Eric Blake  <ebb9@byu.net>
111439         error: fix mingw build
111440         * lib/error.c (error, error_at_line): Avoid fcntl on mingw.
111441         Reported by Bruno Haible.
111443         error: avoid undefined use of stdout
111444         * lib/error.c (error, error_at_line): Check that fd 1 is open
111445         before flushing stdout.  Avoids a crash on cygwin when libsigsegv
111446         is handling faults and the close_stdout module wants to report the
111447         detection of closed stdout as an error.
111449 2009-07-17  Eric Blake  <ebb9@byu.net>
111451         pipe: be robust in face of closed fds
111452         * lib/pipe.c (create_pipe): Closed standard descriptors in parent
111453         should cause child to misbehave.
111454         * modules/pipe-tests: New module.
111455         * tests/test-pipe.c: New file.
111456         * tests/test-pipe.sh: New file.
111457         Reported by Akim Demaille.
111459 2009-07-14  Bruno Haible  <bruno@clisp.org>
111461         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Guess it works on glibc systems.
111462         Reported by anonymous kc.
111464 2009-07-07  Jim Meyering  <meyering@redhat.com>
111466         maint.mk: don't look for translatable strings in *.m4 or *.mk
111467         * top/maint.mk (sc_po_check): Skip *.m4 and *.mk files,
111468         when searching for translatable strings.
111470 2009-07-05  Jim Meyering  <meyering@redhat.com>
111472         remove superfluous parentheses in STREQ definition
111473         * tests/test-argv-iter.c (STREQ): Remove redundant parentheses.
111474         * lib/getugroups.c (STREQ): Likewise.
111475         * lib/fnmatch.c (STREQ): Likewise.
111476         Spotted by Bruno Haible.
111478 2009-07-04  Jim Meyering  <meyering@redhat.com>
111480         argv-iter: new module
111481         * MODULES.html.sh: Add argv-iter.
111482         * lib/argv-iter.c, lib/argv-iter.h: New files.
111483         * modules/argv-iter: New file.
111484         * modules/argv-iter-tests: New file.
111485         * tests/test-argv-iter.c: Test it.
111487 2009-07-04  Bruno Haible  <bruno@clisp.org>
111489         Fix assertion.
111490         * lib/git-merge-changelog.c (compute_mapping): In the case where file1
111491         contains more exact copies of a given entry than file2, leave the extra
111492         copies unpaired rather than aborting.
111493         Reported by Eric Blake.
111495 2009-07-02  Bruno Haible  <bruno@clisp.org>
111497         Speedup git-merge-changelog for git cherry-pick.
111498         * lib/git-merge-changelog.c (struct entries_mapping): New type.
111499         (entries_mapping_get): New function, extracted from compute_mapping.
111500         (entries_mapping_reverse_get): New function.
111501         (compute_mapping): Add a 'full' argument. Return the result in a
111502         'struct entries_mapping'.
111503         (main): Update. Access the mappings through entries_mapping_get.
111504         Reported by Eric Blake.
111506 2009-07-02  Bruno Haible  <bruno@clisp.org>
111508         * lib/git-merge-changelog.c (compute_mapping): Fix determination of
111509         best_i.
111511 2009-07-02  Bruno Haible  <bruno@clisp.org>
111513         Speed up approximate search for matching ChangeLog entries.
111514         * lib/git-merge-changelog.c (entry_fstrcmp): Add a lower_bound
111515         argument. Call fstrcmp_bounded instead of fstrcmp.
111516         (compute_mapping, try_split_merged_entry, main): Update callers.
111518 2009-07-02  Bruno Haible  <bruno@clisp.org>
111520         * lib/git-merge-changelog.c (main): Add comment about git cherry-pick.
111522 2009-06-30  Bruno Haible  <bruno@clisp.org>
111524         Reduce the number of uc_is_cased calls.
111525         * lib/unicase.h (casing_suffix_context_t): Add
111526         'first_char_except_ignorable' field.
111527         * lib/unicase/context.h (SCC_FINAL_SIGMA_MASK): Remove macro.
111528         (SCC_MORE_ABOVE_MASK, SCC_BEFORE_DOT_MASK): Update.
111529         * lib/unicase/empty-suffix-context.c (unicase_empty_suffix_context):
111530         Update initializer.
111531         * lib/unicase/u-casemap.h (FUNC): Don't invoke uc_is_cased on
111532         case-ignorable characters.
111533         * lib/unicase/u-ct-totitle.h (FUNC): Likewise.
111534         * lib/unicase/u-suffix-context.h (FUNC2): Don't call uc_is_cased here.
111535         * modules/unicase/u8-suffix-context (Depends-on): Remove unicase/cased.
111536         * modules/unicase/u16-suffix-context (Depends-on): Likewise.
111537         * modules/unicase/u32-suffix-context (Depends-on): Likewise.
111539 2009-06-30  Bruno Haible  <bruno@clisp.org>
111541         Tests for module 'unicase/ignorable'.
111542         * modules/unicase/ignorable-tests: New file.
111543         * tests/unicase/test-ignorable.c: New file, generated by
111544         gen-uni-tables.
111546         Tests for module 'unicase/cased'.
111547         * modules/unicase/cased-tests: New file.
111548         * tests/unicase/test-cased.c: New file, generated by gen-uni-tables.
111549         * tests/unicase/test-predicate-part1.h: New file, derived from
111550         tests/unictype/test-predicate-part1.h.
111551         * tests/unicase/test-predicate-part2.h: New file, same as
111552         tests/unictype/test-predicate-part2.h.
111554         Fix evaluation of "Before C" condition of FINAL_SIGMA.
111555         * lib/gen-uni-tables.c (is_cased, is_case_ignorable): New functions.
111556         (output_casing_properties): New function.
111557         (main): Call it.
111558         * lib/unicase/cased.h: New file, generated by gen-uni-tables.
111559         * lib/unicase/cased.c: Include unictype/bitmap.h.
111560         (uc_is_cased): Define through a bitmap lookup.
111561         * lib/unicase/ignorable.h: New file, generated by gen-uni-tables.
111562         * lib/unicase/ignorable.c: Include unictype/bitmap.h.
111563         (uc_is_case_ignorable): Define through a bitmap lookup.
111564         * modules/unicase/cased (Files): Add lib/unicase/cased.h,
111565         lib/unictype/bitmap.h.
111566         (Depends-on): Add inline. Clean up.
111567         * modules/unicase/ignorable (Files): Add lib/unicase/ignorable.h,
111568         lib/unictype/bitmap.h.
111569         (Depends-on): Add inline. Clean up.
111570         * tests/unicase/test-u8-tolower.c (main): Add more tests of FINAL_SIGMA
111571         recognition.
111572         * tests/unicase/test-u16-tolower.c (main): Likewise.
111573         * tests/unicase/test-u32-tolower.c (main): Likewise.
111575 2009-06-30  Bruno Haible  <bruno@clisp.org>
111577         * lib/unicase/u8-casemap.c: Don't include uniwbrk.h.
111578         * lib/unicase/u16-casemap.c: Likewise.
111579         * lib/unicase/u32-casemap.c: Likewise.
111581 2009-06-29  Bruno Haible  <bruno@clisp.org>
111583         Define u32_casefold as a wrapper around u32_ct_casefold.
111584         * lib/unicase/u32-casefold.c: Update.
111585         * modules/unicase/u32-casefold (Depends-on): Add
111586         unicase/u32-ct-casefold, unicase/empty-prefix-context,
111587         unicase/empty-suffix-context. Clean up.
111589         Define u16_casefold as a wrapper around u16_ct_casefold.
111590         * lib/unicase/u16-casefold.c: Update.
111591         * modules/unicase/u16-casefold (Depends-on): Add
111592         unicase/u16-ct-casefold, unicase/empty-prefix-context,
111593         unicase/empty-suffix-context. Clean up.
111595         Define u8_casefold as a wrapper around u8_ct_casefold.
111596         * lib/unicase/u-casefold.h (FUNC): Delegate to U_CT_CASEFOLD.
111597         * lib/unicase/u8-casefold.c: Update.
111598         * modules/unicase/u8-casefold (Depends-on): Add unicase/u8-ct-casefold,
111599         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
111601         Define u32_totitle as a wrapper around u32_ct_totitle.
111602         * lib/unicase/u32-totitle.c: Update.
111603         * modules/unicase/u32-totitle (Depends-on): Add unicase/u32-ct-totitle,
111604         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
111606         Define u16_totitle as a wrapper around u16_ct_totitle.
111607         * lib/unicase/u16-totitle.c: Update.
111608         * modules/unicase/u16-totitle (Depends-on): Add unicase/u16-ct-totitle,
111609         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
111611         Define u8_totitle as a wrapper around u8_ct_totitle.
111612         * lib/unicase/u-totitle.h (is_cased, is_case_ignorable): Remove
111613         functions.
111614         (FUNC): Delegate to U_CT_TOTITLE.
111615         * lib/unicase/u8-totitle.c: Update.
111616         * modules/unicase/u8-totitle (Depends-on): Add unicase/u8-ct-totitle,
111617         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
111619         * lib/unicase/u32-tolower.c (u32_tolower): Update u32_casemap
111620         invocation.
111621         * modules/unicase/u32-tolower (Depends-on): Add
111622         unicase/empty-prefix-context, unicase/empty-suffix-context.
111624         * lib/unicase/u16-tolower.c (u16_tolower): Update u16_casemap
111625         invocation.
111626         * modules/unicase/u16-tolower (Depends-on): Add
111627         unicase/empty-prefix-context, unicase/empty-suffix-context.
111629         * lib/unicase/u8-tolower.c (u8_tolower): Update u8_casemap invocation.
111630         * modules/unicase/u8-tolower (Depends-on): Add
111631         unicase/empty-prefix-context, unicase/empty-suffix-context.
111633         * lib/unicase/u32-toupper.c (u32_toupper): Update u32_casemap
111634         invocation.
111635         * modules/unicase/u32-toupper (Depends-on): Add
111636         unicase/empty-prefix-context, unicase/empty-suffix-context.
111638         * lib/unicase/u16-toupper.c (u16_toupper): Update u16_casemap
111639         invocation.
111640         * modules/unicase/u16-toupper (Depends-on): Add
111641         unicase/empty-prefix-context, unicase/empty-suffix-context.
111643         * lib/unicase/u8-toupper.c (u8_toupper): Update u8_casemap invocation.
111644         * modules/unicase/u8-toupper (Depends-on): Add
111645         unicase/empty-prefix-context, unicase/empty-suffix-context.
111647         New module 'unicase/u32-ct-casefold'.
111648         * lib/unicase/u32-ct-casefold.c: New file.
111649         * modules/unicase/u32-ct-casefold: New file.
111651         New module 'unicase/u16-ct-casefold'.
111652         * lib/unicase/u16-ct-casefold.c: New file.
111653         * modules/unicase/u16-ct-casefold: New file.
111655         New module 'unicase/u8-ct-casefold'.
111656         * lib/unicase/u8-ct-casefold.c: New file.
111657         * lib/unicase/u-ct-casefold.h: New file, derived from
111658         lib/unicase/u-casefold.h.
111659         * modules/unicase/u8-ct-casefold: New file.
111661         New module 'unicase/u32-ct-totitle'.
111662         * lib/unicase/u32-ct-totitle.c: New file.
111663         * modules/unicase/u32-ct-totitle: New file.
111665         New module 'unicase/u16-ct-totitle'.
111666         * lib/unicase/u16-ct-totitle.c: New file.
111667         * modules/unicase/u16-ct-totitle: New file.
111669         New module 'unicase/u8-ct-totitle'.
111670         * lib/unicase/u8-ct-totitle.c: New file.
111671         * lib/unicase/u-ct-totitle.h: New file, derived from
111672         lib/unicase/u-totitle.h.
111673         * modules/unicase/u8-ct-totitle: New file.
111675         New module 'unicase/u32-ct-tolower'.
111676         * lib/unicase/u32-ct-tolower.c: New file.
111677         * modules/unicase/u32-ct-tolower: New file.
111679         New module 'unicase/u16-ct-tolower'.
111680         * lib/unicase/u16-ct-tolower.c: New file.
111681         * modules/unicase/u16-ct-tolower: New file.
111683         New module 'unicase/u8-ct-tolower'.
111684         * lib/unicase/u8-ct-tolower.c: New file.
111685         * modules/unicase/u8-ct-tolower: New file.
111687         New module 'unicase/u32-ct-toupper'.
111688         * lib/unicase/u32-ct-toupper.c: New file.
111689         * modules/unicase/u32-ct-toupper: New file.
111691         New module 'unicase/u16-ct-toupper'.
111692         * lib/unicase/u16-ct-toupper.c: New file.
111693         * modules/unicase/u16-ct-toupper: New file.
111695         New module 'unicase/u8-ct-toupper'.
111696         * lib/unicase/u8-ct-toupper.c: New file.
111697         * modules/unicase/u8-ct-toupper: New file.
111699         Add context arguments to u*_casemap functions.
111700         * lib/unicase/unicasemap.h: Include unicase.h.
111701         (u8_casemap, u16_casemap, u32_casemap): Add prefix_context and
111702         suffix_context arguments.
111703         * lib/unicase/u-casemap.h (is_cased, is_case_ignorable): Remove
111704         functions.
111705         (FUNC): Add prefix_context and suffix_context arguments. Use
111706         uc_is_cased and uc_is_case_ignorable.
111707         * lib/unicase/u8-casemap.c: Include caseprop.h and context.h.
111708         * lib/unicase/u16-casemap.c: Likewise.
111709         * lib/unicase/u32-casemap.c: Likewise.
111710         * modules/unicase/u8-casemap (Files): Add lib/unicase/context.h.
111711         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
111712         * modules/unicase/u16-casemap (Files): Add lib/unicase/context.h.
111713         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
111714         * modules/unicase/u32-casemap (Files): Add lib/unicase/context.h.
111715         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
111717         New module 'unicase/u32-suffix-context'.
111718         * lib/unicase/u32-suffix-context.c: New file.
111719         * modules/unicase/u32-suffix-context: New file.
111721         New module 'unicase/u16-suffix-context'.
111722         * lib/unicase/u16-suffix-context.c: New file.
111723         * modules/unicase/u16-suffix-context: New file.
111725         New module 'unicase/u8-suffix-context'.
111726         * lib/unicase/u8-suffix-context.c: New file.
111727         * lib/unicase/u-suffix-context.h: New file.
111728         * modules/unicase/u8-suffix-context: New file.
111730         New module 'unicase/empty-suffix-context'.
111731         * lib/unicase/empty-suffix-context.c: New file.
111732         * modules/unicase/empty-suffix-context: New file.
111734         New module 'unicase/u32-prefix-context'.
111735         * lib/unicase/u32-prefix-context.c: New file.
111736         * modules/unicase/u32-prefix-context: New file.
111738         New module 'unicase/u16-prefix-context'.
111739         * lib/unicase/u16-prefix-context.c: New file.
111740         * modules/unicase/u16-prefix-context: New file.
111742         New module 'unicase/u8-prefix-context'.
111743         * lib/unicase/u8-prefix-context.c: New file.
111744         * lib/unicase/u-prefix-context.h: New file.
111745         * lib/unicase/context.h: New file.
111746         * modules/unicase/u8-prefix-context: New file.
111748         New module 'unicase/empty-prefix-context'.
111749         * lib/unicase/empty-prefix-context.c: New file.
111750         * modules/unicase/empty-prefix-context: New file.
111752         New module 'unicase/ignorable'.
111753         * lib/unicase/ignorable.c: New file.
111754         * modules/unicase/ignorable: New file.
111756         New module 'unicase/cased'.
111757         * lib/unicase/caseprop.h: New file.
111758         * lib/unicase/cased.c: New file.
111759         * modules/unicase/cased: New file.
111761         New functions for case mapping of substrings.
111762         * lib/unicase.h (casing_prefix_context_t): New type.
111763         (unicase_empty_prefix_context): New variable.
111764         (u8_casing_prefix_context, u16_casing_prefix_context,
111765         u32_casing_prefix_context, u8_casing_prefixes_context,
111766         u16_casing_prefixes_context, u32_casing_prefixes_context): New
111767         declarations.
111768         (casing_suffix_context_t): New type.
111769         (unicase_empty_suffix_context): New variable.
111770         (u8_casing_suffix_context, u16_casing_suffix_context,
111771         u32_casing_suffix_context, u8_casing_suffixes_context,
111772         u16_casing_suffixes_context, u32_casing_suffixes_context,
111773         u8_ct_toupper, u16_ct_toupper, u32_ct_toupper, u8_ct_tolower,
111774         u16_ct_tolower, u32_ct_tolower, u8_ct_totitle, u16_ct_totitle,
111775         u32_ct_totitle, u8_ct_casefold, u16_ct_casefold, u32_ct_casefold): New
111776         declarations.
111778 2009-06-28  Jim Meyering  <meyering@redhat.com>
111780         boostrap: indent only with spaces
111781         * build-aux/bootstrap: Indent only with spaces, never TABs.
111783         bootstrap: split long lines
111784         * build-aux/bootstrap: Keep line length < 80.
111786         bootstrap: sync from coreutils
111787         * build-aux/bootstrap: Honor variables like $ACLOCAL, etc.,
111788         just as autoreconf does.  Verify a list of prerequisite
111789         package-name,version-number pairs if defined in bootstrap.conf.
111790         Refer to README-prereq, if prerequisites are not satisfied.
111792 2009-06-27  Eric Blake  <ebb9@byu.net>
111794         tests: add test for bogus NULL definition
111795         * tests/test-stdio.c: Ensure POSIX 2008 requirement on NULL.
111796         * tests/test-stdlib.c: Likewise.
111797         * tests/test-string.c: Likewise.
111798         * tests/test-locale.c: Likewise.
111799         * tests/test-unistd.c: Likewise.
111800         * modules/stdio-tests (Depends-on): Add verify.
111801         * modules/stdlib-tests (Depends-on): Likewise.
111802         * modules/string-tests (Depends-on): Likewise.
111803         * modules/locale-tests (Depends-on): Likewise.
111804         * modules/unistd-tests (Depends-on): Likewise.
111806 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
111808         * m4/selinux-context-h (gl_HEADERS_SELINUX_CONTEXT_H): Remove
111809         self-explaining comment.
111810         * m4/selinux-selinux-h: Update serial.
111811         (gl_LIBSELINUX): New macro, adding a warning for missing development
111812         packages to code extracted from...
111813         (gl_HEADERS_SELINUX_SELINUX_H): ... this one.  Require gl_LIBSELINUX.
111814         Add warning for missing development packages here, too.
111816 2009-06-26  Paolo Bonzini  <bonzini@gnu.org>
111818         * build-aux/bootstrap: Do not use GIT_CONFIG_LOCAL.
111820 2009-06-25  Eric Blake  <ebb9@byu.net>
111822         version-etc: fix regression
111823         * lib/version-etc.h (ATTRIBUTE_SENTINEL): Define for new enough
111824         gcc.
111825         (version_etc): Use it, to catch bugs with trailing NULL.
111826         * lib/version-etc.c (version_etc_arn): Delete unused argument.
111827         (version_etc_va): Fix logic bug.
111828         * modules/version-etc-tests: Add test.
111829         * tests/test-version-etc.c: New file.
111830         * tests/test-version-etc.sh: Likewise.
111832 2009-06-25  Sam Steingold  <sds@gnu.org>
111834         * mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): Include <stdlib.h>, for the
111835         mbtowc declaration.
111837 2009-06-25  Eric Blake  <ebb9@byu.net>
111839         fpurge: migrate into <stdio.h>
111840         * lib/fpurge.h: Delete...
111841         * lib/stdio.in.h (fpurge): ...and declare here, instead.
111842         * lib/fpurge.c (fpurge): Change declaring header.
111843         * modules/fpurge (Files): Drop deleted file.
111844         (Depends-on): Add stdio.
111845         (configure.ac): Set witness.
111846         * modules/stdio (Makefile.am): Support fpurge macros.
111847         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
111848         * m4/fpurge.m4 (gl_FUNC_FPURGE): Set appropriate variables.
111849         * lib/fflush.c: Update client.
111850         * tests/test-fpurge.c: Likewise.
111851         * NEWS: Mention the change.
111853 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
111855         * lib/argp-version-etc.c (program_authors): Add const
111856         qualifier.
111857         * lib/version-etc.c: Fix typos in the comments.
111858         * modules/argp-version-etc: Depends on version-etc.
111860 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
111862         argp-version-etc: new module.
111864         * lib/argp-version-etc.c: New file.
111865         * lib/argp-version-etc.h: New file.
111866         * modules/argp-version-etc: New file.
111867         * modules/argp-version-etc-tests: New file.
111868         * tests/test-argp-version-etc.c: New test.
111869         * tests/test-argp-version-etc-1.sh: New test.
111871 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
111873         Provide additional interfaces and documentation for version-etc
111874         module.
111876         * lib/version-etc.c (version_etc_arn, version_etc_ar): New
111877         interfaces.
111878         * lib/version-etc.h (version_etc_arn, version_etc_ar): New
111879         prototypes.
111881 2009-06-24  Bruno Haible  <bruno@clisp.org>
111883         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Fix description of
111884         HAVE_LIB${NAME} macro.
111885         Reported by Sam Steingold <sds@gnu.org>.
111887 2009-06-23  Simon Josefsson  <simon@josefsson.org>
111889         * modules/hash-tests (test_hash_LDADD): Link to libintl when
111890         needed.
111892 2009-06-21  Bruno Haible  <bruno@clisp.org>
111894         Make two consecutive identical invocations of AC_LIB_HAVE_LINKFLAGS
111895         work.
111896         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Reset HAVE_LIB${NAME}
111897         together with LIB${NAME}, LTLIB${NAME}.
111898         Reported by Sam Steingold <sds@gnu.org>.
111900 2009-06-20  Jim Meyering  <meyering@redhat.com>
111902         tests: make sc_require_test_exit_idiom more generic
111903         * top/maint.mk (Exit_witness_file): New overridable variable.
111904         (sc_require_test_exit_idiom): Don't hard-code tests/test-lib.sh.
111905         Relax test for /^Exit \$fail$$/ to just /^Exit ./.
111907 2009-06-19  Jim Meyering  <meyering@redhat.com>
111909         hash: reverse order of src/dst parameters in an internal interface
111910         * lib/hash.c (transfer_entries): Reverse order of parameters to
111911         put DST before SRC.  Adjust callers.
111913         tests: test-hash: avoid wholesale duplication
111914         * tests/test-hash.c (main): Don't copy/paste a 60-line loop.
111915         Instead, use a loop and add a single conditional.
111917         tests: test-hash: allow seed selection via a command line argument
111918         * tests/test-hash.c (get_seed): New function.
111919         (main): Use it.
111921 2009-06-19  Eric Blake  <ebb9@byu.net>
111923         hash: avoid memory leak on allocation failure
111924         * lib/hash.c: (hash_rehash): Avoid memory leak on allocation
111925         failure.  Factor repeated algorithm...
111926         (transfer_entries): ...into new helper routine.
111927         (hash_delete): React to hash_rehash return value.
111929         hash: reduce memory pressure in hash_rehash no-op case
111930         * lib/hash.c (next_prime): Avoid overflow.
111931         (hash_initialize): Factor bucket size computation...
111932         (compute_bucket_size): ...into new helper function.
111933         (hash_rehash): Use new function and open coding to reduce memory
111934         pressure, and avoid a memory leak in USE_OBSTACK code.
111935         Reported by Jim Meyering.
111937 2009-06-18  Eric Blake  <ebb9@byu.net>
111939         hash: make rotation more obvious
111940         * modules/hash (Depends-on): Add bitrotate and stdint.
111941         * lib/bitrotate.h (rotl_sz, rotr_sz): New functions.
111942         * lib/hash.c (headers): Drop limits.h.  Add stdint.h.
111943         (SIZE_MAX): Rely on headers for definition.
111944         (hash_string) [USE_DIFF_HASH]: Use rotl_sz.
111945         (raw_hasher): Use rotr_sz.
111946         Suggested by Jim Meyering.
111948         hash: fix memory leak in last patch
111949         * lib/hash.c (hash_rehash): Avoid memory leak.
111951         hash: avoid no-op rehashing
111952         * lib/hash.c (hash_rehash): Recognize useless rehash attempts.
111954         hash: provide default callback functions
111955         * lib/hash.c (raw_hasher, raw_comparator): New functions.
111956         (hash_initialize): Use them as defaults.
111957         * tests/test-hash.c (main): Test this.
111959         hash: minor optimization
111960         * lib/hash.c (hash_lookup, hash_find_entry): Avoid function call
111961         when possible.
111962         (hash_initialize): Document this promise.
111963         (hash_do_for_each, hash_clear, hash_free): Use C89 syntax.
111964         * tests/test-hash.c (hash_compare_strings): Test this.
111966 2009-06-18  Bruno Haible  <bruno@clisp.org>
111968         * m4/strstr.m4 (gl_FUNC_STRSTR): Skip linear time test if strstr is
111969         going to be replaced anyway.
111971 2009-06-18  Bruno Haible  <bruno@clisp.org>
111973         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Invoke AC_LIBOBJ only
111974         in one place.
111975         (gl_FUNC_STRCASESTR): Skip linear time test if strcasestr is going to
111976         be replaced anyway.
111978 2009-06-18  Eric Blake  <ebb9@byu.net>
111980         hash: check for resize before insertion
111981         * lib/hash.c (hash_insert): Check whether bucket usage exceeds
111982         threshold before insertion, so that a pathological hash_rehash
111983         that fills every bucket can still trigger another rehash.
111985 2009-06-18  Jim Meyering  <meyering@redhat.com>
111987         hash-tests: add a loop around the small tests
111988         * tests/test-hash.c (main): Repeat small tests with selected
111989         small initial table sizes.
111991 2009-06-17  Eric Blake  <ebb9@byu.net>
111993         hash: minor cleanups
111994         * lib/hash.h (hash_entry): Make opaque, by moving...
111995         * lib/hash.c (hash_entry): ...here.
111996         (hash_insert): Clarify restrictions on what can be inserted.
111997         (hash_get_next): Clarify when it is safe to remove an element
111998         during traversal.
111999         (check_tuning): Skip verification when tuning is known safe.
112000         (hash_initialize): Clarify restrictions on tuning.
112002 2009-06-17  Jim Meyering  <jim@meyering.net>
112003         and Eric Blake  <ebb9@byu.net>
112005         hash-tests: new module
112006         * modules/hash-tests: New file.
112007         * tests/test-hash.c: New file.
112009 2009-06-17  Eric Blake  <ebb9@byu.net>
112011         strstr-simple: document new module
112012         * MODULES.html.sh: Document new module.
112014         strstr, strcasestr: replace on platforms with broken memchr
112015         * modules/strstr: Split into...
112016         * modules/strstr-simple: ...new module that does not care about
112017         performance, but does care about glibc bug.
112018         * m4/strstr.m4 (gl_FUNC_STRSTR): Split...
112019         (gl_FUNC_STRSTR_SIMPLE): ...into new macro, which replaces strstr
112020         if platform memchr is broken, per Debian bug 521737.
112021         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): React to broken
112022         memchr.
112023         * m4/memchr.m4 (gl_FUNC_MEMCHR): Only expand once.
112024         * doc/posix-functions/strstr.texi (strstr): Document the fix.
112025         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
112026         * modules/mountlist (Depends-on): Add strstr-simple.
112027         * modules/gen-uni-tables (Depends-on): Likewise.
112028         * modules/argz (Depends-on): Add strstr.
112030 2009-06-17  Bruno Haible  <bruno@clisp.org>
112032         * modules/posix_spawn-internal (Depends-on): Add errno.
112034 2009-06-17  Bruno Haible  <bruno@clisp.org>
112036         Define missing ESTALE on Interix 3.5.
112037         * lib/errno.in.h (ESTALE): Assign a value if missing.
112038         * lib/strerror.c (rpl_strerror): Handle missing ESTALE and ECANCELED.
112039         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Also test whether ESTALE is
112040         missing.
112041         * doc/posix-headers/errno.texi: Mention the Interix bug.
112042         Reported by Jay Krell <jay.krell@cornell.edu> via Eric Blake.
112044 2009-06-15  Eric Blake  <ebb9@byu.net>
112046         memchr, memchr2: add valgrind exception
112047         * lib/memchr.valgrind: New file.
112048         * lib/memchr2.valgrind: New file.
112049         * modules/memchr (Files): Distribute valgrind file.
112050         * modules/memchr2 (Files): Likewise.
112052         docs: memchr is no longer obsolete
112053         * MODULES.html.sh: Move memchr from obsolete to string.h section.
112054         * lib/string.in.h (memchr): Simplify logic.
112056 2009-06-14  Jim Meyering  <meyering@redhat.com>
112058         link-follow: fix the "checking..." message to not mention trailing slash
112059         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): This test has
112060         never considered trailing slashes.
112062 2009-06-14  Bruno Haible  <bruno@clisp.org>
112064         * m4/memchr.m4: Mention also the bug on IA-64.
112065         * doc/posix-functions/memchr.texi: Likewise.
112067 2009-06-12  Eric Blake  <ebb9@byu.net>
112069         memchr: detect broken x86_64 and alpha implementations
112070         * modules/memchr-tests (Depends-on): Move mmap detection...
112071         * modules/memchr (Depends-on): ...here.
112072         (configure.ac): Set indicator.
112073         * lib/string.in.h (memchr): Declare replacement.
112074         * modules/string (Makefile.am): Trigger replacement.
112075         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
112076         * m4/memchr.m4 (gl_FUNC_MEMCHR): Use mmap to detect platform
112077         bugs.
112078         * doc/posix-functions/memchr.texi (memchr): Document the bug.
112079         * modules/getpagesize (License): Relax license.
112081 2009-06-11  Bruno Haible  <bruno@clisp.org>
112083         * lib/idpriv.h: Add more references.
112085 2009-06-08  Bruno Haible  <bruno@clisp.org>
112087         Tests for module 'idpriv-droptemp'.
112088         * modules/idpriv-droptemp-tests: New file.
112089         * tests/test-idpriv-droptemp.sh: New file.
112090         * tests/test-idpriv-droptemp.su.sh: New file.
112091         * tests/test-idpriv-droptemp.c: New file.
112093         New module 'idpriv-droptemp'.
112094         * lib/idpriv-droptemp.c: New file.
112095         * modules/idpriv-droptemp: New file.
112097 2009-06-08  Bruno Haible  <bruno@clisp.org>
112099         Tests for module 'idpriv-drop'.
112100         * modules/idpriv-drop-tests: New file.
112101         * tests/test-idpriv-drop.sh: New file.
112102         * tests/test-idpriv-drop.su.sh: New file.
112103         * tests/test-idpriv-drop.c: New file.
112105         New module 'idpriv-drop'.
112106         * lib/idpriv.h: New file.
112107         * lib-idpriv-drop.c: New file.
112108         * m4/idpriv.m4: New file.
112109         * modules/idpriv-drop: New file.
112111 2009-06-08  Bruno Haible  <bruno@clisp.org>
112113         * modules/unistdio/u8-vasnprintf (Depends-on): Add memchr.
112114         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
112115         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
112116         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
112117         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
112118         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
112119         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
112121 2009-06-08  Eric Blake  <ebb9@byu.net>
112123         test-strstr: use memory fence, when possible
112124         * tests/test-strstr.c (main): Use memory fence, in order to be
112125         more likely to trigger Debian bug 521737.
112126         * modules/strstr-tests (Files): Pull in additional files.
112128         memchr: no longer obsolete, for wider field testing
112129         * modules/memchr (Status, Notice): Delete, this module is no
112130         longer obsolete.
112131         * modules/vasnprintf (Depends-on): Add memchr.
112133 2009-06-07  Jim Meyering  <meyering@redhat.com>
112135         hash: declare some functions with the warn_unused_result attribute
112136         * lib/hash.h (__attribute__, ATTRIBUTE_WUR): Define.
112138 2009-06-07  Bruno Haible  <bruno@clisp.org>
112140         * tests/test-alignof.c: Don't test int64_t if it does not exist.
112141         Reported by Eric Blake.
112143 2009-06-06  Eric Blake  <ebb9@byu.net>
112145         test-alignof: fix typo with long double
112146         * tests/test-alignof.c (CHECK): Use longdouble typedef to avoid
112147         compiler error.
112149 2009-06-06  Neil Jerram  <neil@ossau.uklinux.net>  (tiny change)
112151         Escape non-texinfo { and }s.
112152         * doc/ld-output-def.texi (Visual Studio Compatibility): Fix
112153         markup error.
112155 2009-06-04  Jim Meyering  <meyering@redhat.com>
112157         gitlog-to-changelog: don't infloop on an empty commit log
112158         * build-aux/gitlog-to-changelog: Warn about an empty log message.
112159         Reported by Boris Petersen <transacid@centerim.org>.
112161 2009-06-03  Mike Frysinger  <vapier@gentoo.org>
112163         version-etc: extend for packagers
112164         Add three new configure options, intended for packagers:
112165           --with-packager="packager name"
112166           --with-packager-version="packager-specific version"
112167           --with-packager-bug-reports="packager bug reporting"
112168         An example with coreutils:
112169           $ ./configure \
112170             --with-packager=Gentoo \
112171             --with-packager-bug-report=http://bugs.gentoo.org/ \
112172             --with-packager-version="patchset 1.6"
112173           $ ./src/ls --version | head -n2
112174           ls (GNU coreutils) 7.1-dirty
112175           Packaged by Gentoo (patchset 1.6)
112176         Note that the bug reporting info via --help doesn't show up because
112177         coreutils uses its own custom emit_bug_reporting_address() implementation
112178         in src/system.h.  If it didn't, it'd look like:
112179           $ ./src/ls --help | tail -n4
112180           Report bugs to <bug-coreutils@gnu.org>.
112181           Report Gentoo bugs to <http://bugs.gentoo.org/>.
112182           GNU coreutils home page: <http://www.gnu.org/software/coreutils/>.
112183           General help using GNU software: <http://www.gnu.org/gethelp/>.
112184         * lib/version-etc.c: Print new information, if provided.
112185         * m4/version-etc.m4: New file.
112186         * modules/version-etc (Files): Add m4/version-etc.m4.
112187         (configure.ac): Add gl_VERSION_ETC.
112189 2009-05-31  Bruno Haible  <bruno@clisp.org>
112191         * tests/test-alignof.c: Include <stdint.h>. Check also 'long double'
112192         and 'int64_t'.
112193         * modules/alignof-tests (Dependencies): Add stdint.
112194         Reported by Eric Blake.
112196 2009-05-31  Bruno Haible  <bruno@clisp.org>
112198         * lib/alignof.h (alignof_slot, alignof_type, alignof): Document
112199         restriction due to compiler bugs.
112200         Reported by Eric Blake.
112202 2009-05-31  Simon Josefsson  <simon@josefsson.org>
112203             Bruno Haible  <bruno@clisp.org>
112205         Fix test-alignof failure.
112206         * lib/alignof.h (alignof_slot): New macro.
112207         (alignof_type): New macro, with the same semantics as the previous
112208         'alignof'.
112209         (alignof): Alias to alignof_slot.
112210         * tests/test-alignof.c (CHECK): Check alignof_slot, not alignof. Also
112211         check that the results are usable as constant expressions.
112213 2009-05-31  Bruno Haible  <bruno@clisp.org>
112215         * tests/zerosize-ptr.h (zerosize_ptr): Specify more details.
112216         * tests/test-memchr.c (main): Check that memchr does not read past the
112217         first occurrence of the byte.
112218         * tests/test-strstr.c (main): Update comment.
112219         Suggested by Eric Blake.
112221 2009-05-30  Bruno Haible  <bruno@clisp.org>
112223         * doc/ld-output-def.texi (Visual Studio Compatibility): Explain in more
112224         detail how to use dumpbin.
112225         Reported by David Byron <dbyron@dbyron.com>.
112227 2009-06-02  Simon Josefsson  <simon@josefsson.org>
112229         * tests/test-parse-duration.sh: Don't use non-portable 'read -u3'.
112231 2009-06-02  Simon Josefsson  <simon@josefsson.org>
112233         * m4/manywarnings.m4: Add GCC 4.4 warnings.
112235 2009-05-28  Bruno Haible  <bruno@clisp.org>
112237         * gnulib-tool (func_import): Don't do HAVE_CONFIG_H replacements on
112238         build-aux/ files.
112240 2009-05-28  Simon Josefsson  <simon@josefsson.org>
112242         * gnulib-tool (func_import): Transform license on build-aux/ files too.
112244 2009-05-27  Simon Josefsson  <simon@josefsson.org>
112246         * gnulib-tool (sed_transform_main_lib_file)
112247         (sed_transform_testsrelated_lib_file): : Don't use non-POSIX
112248         regexps.
112250 2009-05-26  Simon Josefsson  <simon@josefsson.org>
112252         * tests/test-strstr.c: Add another self-test.
112253         * tests/test-strstr.c: Rewrite to use malloc/strcpy instead of
112254         strdup.  Suggested by Eric Blake  <ebb9@byu.net>.
112256 2009-05-23  Bruno Haible  <bruno@clisp.org>
112258         * doc/havelib.texi (AC_LIB_HAVE_LINKFLAGS): Update for 2009-04-26
112259         change.
112261 2009-05-21  Bruno Haible  <bruno@clisp.org>
112263         Simplify use of mode_t varargs.
112264         * lib/open.c (open): Use PROMOTED_MODE_T instead of a conditional that
112265         uses 'mode_t' or 'int'.
112266         * lib/openat.c (openat): Likewise.
112267         * lib/open-safer.c (open_safer): Likewise.
112268         * m4/mode_t.m4: New file.
112269         * m4/open.m4 (gl_PREREQ_OPEN): Require gl_PROMOTED_TYPE_MODE_T.
112270         * m4/openat.m4 (gl_PREREQ_OPENAT): Likewise.
112271         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Likewise.
112272         * modules/open (Files): Add m4/mode_t.m4.
112273         * modules/openat (Files): Likewise.
112274         * modules/fcntl-safer (Files): Likewise.
112275         Suggested by Eric Blake.
112277 2009-05-21  Pádraig Brady  <P@draigbrady.com>
112279         * doc/glibc-functions/fallocate.texi: New file.
112280         * doc/gnulib.texi: Include it.
112282 2009-05-21  Eric Blake  <ebb9@byu.net>
112283             Bruno Haible  <bruno@clisp.org>
112285         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Remove redundant m4_quote
112286         invocations.
112287         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
112289 2009-05-21  Eric Blake  <ebb9@byu.net>
112290             Bruno Haible  <bruno@clisp.org>
112292         Second attempt to work around an AIX 5.3, 6.1 compiler bug with
112293         include_next. Fix of 2008-11-20 commit.
112294         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Also set
112295         NEXT_AS_FIRST_DIRECTIVE_FOO_H.
112296         * lib/math.in.h: Use NEXT_AS_FIRST_DIRECTIVE_MATH_H instead of
112297         NEXT_MATH_H.
112298         * modules/math (Makefile.am): Substitute NEXT_AS_FIRST_DIRECTIVE_MATH_H
112299         instead of NEXT_MATH_H.
112301 2009-05-21  Bruno Haible  <bruno@clisp.org>
112303         Avoid redefinition warnings for SIZE_MAX.
112304         * m4/size_max.m4 (gl_SIZE_MAX): Avoid redefining SIZE_MAX in config.h.
112305         Reported by Simon Josefsson.
112307 2009-05-21  Bruno Haible  <bruno@clisp.org>
112309         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_CACHE_CHECK instead of
112310         AC_CACHE_VAL.
112312 2009-05-20  Bruno Haible  <bruno@clisp.org>
112314         Make zeroptr.h work on mingw.
112315         * tests/zerosize-ptr.h: Test for the presence of <sys/mman.h> and
112316         mprotect.
112317         * modules/memchr-tests (configure.ac): Also test for sys/mman.h.
112318         * modules/memchr2-tests (configure.ac): Likewise.
112319         * modules/memcmp-tests (configure.ac): Likewise.
112320         * modules/memmem-tests (configure.ac): Likewise.
112321         * modules/memrchr-tests (configure.ac): Likewise.
112322         Reported by Simon Josefsson.
112324 2009-05-20  Simon Josefsson  <simon@josefsson.org>
112326         * tests/test-glob.c: Include string.h for strcmp prototype.
112328 2009-05-20  Simon Josefsson  <simon@josefsson.org>
112330         * modules/getdelim (Depends-on): Add explicit stdint, although it
112331         was implicitly already pulled in via realloc-posix.
112332         * lib/getdelim.c: Get SIZE_MAX from stdint.h.
112334 2009-05-20  Simon Josefsson  <simon@josefsson.org>
112336         MinGW and IRIX does not have sa_family_t type.  Reported by "Tom
112337         G. Christensen" <tgc@jupiterrise.com>.
112338         * m4/sys_socket_h.m4: Check for sa_family_t.
112339         * lib/sys_socket.in.h: Typedef sa_family_t when needed.
112340         * modules/sys_socket: Substitute HAVE_SA_FAMILY_T.
112341         * tests/test-sys_socket.c: Check that sa_family_t works.
112343 2009-05-18  Eric Blake  <ebb9@byu.net>
112345         maint.mk: allow gnulib_dir in VPATH build
112346         * top/maint.mk (gnulib_dir): Make relative to $(srcdir).
112348 2009-05-15  Jim Meyering  <meyering@redhat.com>
112350         maint.mk: Give gnulib_dir a default definition.
112351         * top/maint.mk (gnulib_dir): Define to 'gnulib', by default.
112352         Thus, most packages no longer need to specify this variable in cfg.mk
112354 2009-05-14  Tom Prince  <tom.prince@ualberta.net>  (tiny change)
112356         rename.m4: fix typos that would make non-mingw cross-configure fail
112357         * m4/rename.m4 (gl_FUNC_RENAME): Fix typos.
112359 2009-05-13  Eric Blake  <ebb9@byu.net>
112361         mmap-anon: avoid out-of-order autoconf expansion
112362         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Use correct
112363         SYSTEM_EXTENSIONS macro to silence warnings from autoconf 2.63b.
112364         * modules/memchr-tests (Depends-on): Add extensions.
112365         * modules/memchr2-tests (Depends-on): Add extensions.
112366         * modules/memcmp-tests (Depends-on): Add extensions.
112367         * modules/memmem-tests (Depends-on): Add extensions.
112368         * modules/memrchr-tests (Depends-on): Add extensions.
112370 2009-05-13  Bruno Haible  <bruno@clisp.org>
112372         Make some tests ISO C 99 compliant.
112373         * tests/zerosize-ptr.h: New file.
112374         * tests/test-memchr.c: Include zerosize-ptr.h.
112375         (main): Use a zero-size object pointer instead of NULL.
112376         * tests/test-memchr2.c: Include zerosize-ptr.h.
112377         (main): Use a zero-size object pointer instead of NULL.
112378         * tests/test-memcmp.c: Include zerosize-ptr.h.
112379         (main): Use a zero-size object pointer instead of NULL.
112380         * tests/test-memmem.c: Include zerosize-ptr.h.
112381         (main): Use a zero-size object pointer instead of NULL.
112382         * tests/test-memrchr.c: Include zerosize-ptr.h.
112383         (main): Use a zero-size object pointer instead of NULL.
112384         * modules/memchr-tests (Files): Add tests/zerosize-ptr.h,
112385         m4/mmap-anon.m4.
112386         (Depends-on): Add getpagesize.
112387         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
112388         * modules/memchr2-tests (Files): Add tests/zerosize-ptr.h,
112389         m4/mmap-anon.m4.
112390         (Depends-on): Add getpagesize.
112391         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
112392         * modules/memcmp-tests (Files): Add tests/zerosize-ptr.h,
112393         m4/mmap-anon.m4.
112394         (Depends-on): Add getpagesize.
112395         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
112396         * modules/memmem-tests (Files): Add tests/zerosize-ptr.h,
112397         m4/mmap-anon.m4.
112398         (Depends-on): Add getpagesize.
112399         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
112400         * modules/memrchr-tests (Files): Add tests/zerosize-ptr.h,
112401         m4/mmap-anon.m4.
112402         (Depends-on): Add getpagesize.
112403         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
112405 2009-05-12  Bruno Haible  <bruno@clisp.org>
112407         Tests for module 'alignof'.
112408         * modules/alignof-tests: New file.
112409         * tests/test-alignof.c: New file.
112411 2009-05-12  Bruno Haible  <bruno@clisp.org>
112413         Fix alignof macro.
112414         * lib/alignof.h (alignof): Remove special cases for AIX and HP-UX
112415         vendor compilers that are always correct.
112417 2009-05-12  Bruno Haible  <bruno@clisp.org>
112419         Make the MAP_ANONYMOUS detection work on HP-UX 11.
112420         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check whether mmap exists, but
112421         not whether its fully works.
112423 2009-05-12  Bruno Haible  <bruno@clisp.org>
112425         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Add comments.
112427 2009-05-12  Jim Meyering  <meyering@redhat.com>
112429         * top/maint.mk: Adjust backslash alignment.
112431 2009-05-11  Simon Josefsson  <simon@josefsson.org>
112433         * top/maint.mk: Make $(srcdir)/build-aux configurable.
112435 2009-05-11  Eric Blake  <ebb9@byu.net>
112437         argp: avoid undefined behavior
112438         * lib/argp-fmtstream.c (weak_alias): Pass correct types to ctype
112439         macros.
112441 2009-05-08  Simon Josefsson  <simon@josefsson.org>
112443         * tests/test-vc-list-files-git.sh: Do git config of user.email and
112444         user.name to prevent git commit from complaining.
112446 2009-05-10  Bruno Haible  <bruno@clisp.org>
112448         * gnulib-tool (func_import, func_create_testdir, copy-file): Change
112449         sed_rewrite_old_files, sed_rewrite_new_files, sed_rewrite_files so that
112450         it rewrites every file name only once.
112451         Reported by Simon Josefsson. Helped by Ralf Wildenhues.
112453 2009-05-08  Bruno Haible  <bruno@clisp.org>
112455         * lib/sys_socket.in.h (_SS_PADSIZE): Use a conditional expression
112456         instead of 'max'.
112458 2009-05-08  Simon Josefsson  <simon@josefsson.org>
112460         * m4/sys_socket_h.m4: Test for ws2tcpip.h earlier, needed for
112461         sockaddr_storage test.
112463 2009-05-07  Simon Josefsson  <simon@josefsson.org>
112465         * modules/sys_socket (Makefile.am): Substitute
112466         HAVE_STRUCT_SOCKADDR_STORAGE.  Depend on alignof.
112467         * m4/sys_socket_h.m4: Check for sockaddr_storage.
112468         * lib/sys_socket.in.h (sockaddr_storage): Define when needed.
112469         * tests/test-sys_socket.c: Check sockaddr_storage.
112471 2009-05-08  Bruno Haible  <bruno@clisp.org>
112473         New module 'alignof'.
112474         * lib/alignof.h: New file.
112475         * modules/alignof: New file.
112477 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
112478             Bruno Haible  <bruno@clisp.org>
112480         Fix test-file-has-acl on FreeBSD.
112481         * tests/test-file-has-acl.sh: Also test a directory. On FreeBSD, the
112482         mask is implicitly added.
112483         * tests/test-file-has-acl.c: Include <signal.h>.
112484         (main): Terminate the test after 5 seconds.
112485         * modules/acl-tests (configure.ac): Check for alarm function.
112487 2009-05-04  Bruno Haible  <bruno@clisp.org>
112489         Exploit new semantics of AC_DEFUN_ONCE available since 2009-01-26.
112490         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Remove outdated comment.
112491         * modules/errno (configure.ac): Drop AC_REQUIRE.
112492         * m4/multiarch.m4 (gl_MULTIARCH): Remove outdated comment.
112493         * modules/multiarch (configure.ac): Drop AC_REQUIRE.
112495 2009-05-04  Simon Josefsson  <simon@josefsson.org>
112497         * modules/glob-tests: New module.
112498         * tests/test-glob.c: Add.
112500 2009-05-04  Simon Josefsson  <simon@josefsson.org>
112502         * modules/fnmatch-tests: New module.
112503         * tests/test-fnmatch.c: Add.
112505 2009-05-04  Eric Blake  <ebb9@byu.net>
112507         maint: make the new no-submodule-changes rule VPATH-safe
112508         * top/maint.mk (no-submodule-changes): Don't assume a srcdir build.
112510 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
112511             Bruno Haible  <bruno@clisp.org>
112513         acl: Fix infinite loop on FreeBSD.
112514         * lib/acl_entries.c (acl_entries) [Linux, FreeBSD]: Fix interpretation
112515         of return value from acl_get_entry.
112516         * lib/file-has-acl.c (acl_access_nontrivial) [Linux, FreeBSD]:
112517         Likewise.
112519 2009-05-03  Bruno Haible  <bruno@clisp.org>
112521         * lib/acl-internal.h (acl_entries): Clarify return value.
112522         * lib/acl_entries.c (acl_entries): Likewise.
112524 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
112526         Bug fix in acl module.
112527         * lib/set-mode-acl.c: Use correct struct with ACL_SETACL.
112529 2009-05-03  Bruno Haible  <bruno@clisp.org>
112531         Create gperf-generated file in the source dir, not in the build dir.
112532         * modules/iconv_open (iconv_open-aix.h, iconv_open-hpux.h,
112533         iconv_open-irix.h, iconv_open-osf.h): Create file in the source tree.
112534         * modules/unicase/locale-language (unicase/locale-languages.h):
112535         Likewise.
112536         * modules/unicase/special-casing (unicase/special-casing-table.h):
112537         Likewise.
112538         * modules/unictype/property-byname (unictype/pr_byname.h): Likewise.
112539         * modules/unictype/scripts (unictype/scripts_byname.h): Likewise.
112540         * modules/uninorm/composition (uninorm/composition-table.h): Likewise.
112541         Reported by Ralf Wildenhues.
112543 2009-05-03  Bruno Haible  <bruno@clisp.org>
112545         * modules/fnmatch (Description, configure.ac): Taken from
112546         fnmatch-posix.
112547         * modules/fnmatch-posix: Turn into a symbolic reference to the
112548         'fnmatch' module, and deprecate.
112549         * doc/posix-functions/fnmatch.texi: Mention the fnmatch module.
112551 2009-05-03  Bruno Haible  <bruno@clisp.org>
112553         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF,
112554         gl_PREREQ_VASNPRINTF_LONG_DOUBLE): Define through AC_DEFUN_ONCE.
112555         Reported by Ralf Wildenhues.
112557 2009-05-04  Simon Josefsson  <simon@josefsson.org>
112559         * m4/fnmatch.m4: Fix fnmatch re-define.
112561 2009-04-27  David Bartley  <dtbartle@csclub.uwaterloo.ca>
112563         priv-set: new module and tests; adapt write-any-file
112564         * lib/priv-set.c: New file.
112565         * lib/priv-set.h: New file.
112566         * lib/unlinkdir.c: Make cannot_unlink_dir thread-safe.
112567         * lib/write-any-file.c: Simplify by using priv-set module.
112568         * m4/priv-set.m4: New file.
112569         * modules/priv-set: New file.
112570         * modules/unlinkdir: Add dependency on priv-set module.
112571         * modules/write-any-file: Likewise.
112573         Tests for module 'priv-set'.
112574         * modules/priv-set-tests: New file.
112575         * tests/test-priv-set.c: New file.
112577 2009-05-03  Jim Meyering  <meyering@redhat.com>
112578             Bruno Haible  <bruno@clisp.org>
112580         * lib/propername.c (proper_name_utf8): Ignore no-op translations;
112581         use the converted UTF-8 variant of the name instead.
112583 2009-05-03  Jim Meyering  <meyering@redhat.com>
112585         tests: tighten some getdate tests
112586         * tests/test-getdate.c (main): Tighten tests: require equality,
112587         not just greater than.  Set TZ envvar to UTC0.
112589 2009-05-03  Giuseppe Scrivano  <gscrivano@gnu.org>
112591         getdate: correctly interpret "next monday" when run on a Monday
112592         * lib/getdate.y (get_date): Correct the calculation of tm_mday so
112593         that e.g., "next tues" (when run on a tuesday) results in a date
112594         that is one week in the future, and not today's date.
112595         I.e., add a week when the wday is the same as the current one.
112596         Reported by Tom Broadhurst in http://savannah.gnu.org/bugs/?25406,
112597         and earlier by Martin Bernreuther and Jan Minář.
112598         * tests/test-getdate.c (main): Check that "next DAY" is always in
112599         the future and that "last DAY" is always in the past.
112601 2009-05-02  Jim Meyering  <meyering@redhat.com>
112603         build: ensure that a release build fails when a submodule is unclean
112604         * top/maint.mk (no-submodule-changes): New rule.
112605         (alpha beta major): Depend on it.
112607 2009-05-02  Bruno Haible  <bruno@clisp.org>
112609         Remove incompatibility between modules fnmatch-posix and fnmatch-gnu.
112610         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Use a
112611         shell variable gl_fnmatch_required to detect which variant is
112612         requested.
112613         (_AC_FUNC_FNMATCH_IF, _AC_LIBOBJ_FNMATCH): Remove macros. Inlined into
112614         gl_FUNC_FNMATCH_POSIX.
112615         * gnulib-tool (func_create_testdir, func_create_megatestdir): Don't
112616         exclude fnmatch-posix.
112618 2009-05-02  Bruno Haible  <bruno@clisp.org>
112620         Relicense mbsrtowcs and strnlen1 under LGPLv2+.
112621         * modules/mbsrtowcs (License): Change to LGPLv2+.
112622         * modules/strnlen1 (License): Likewise.
112623         Reported by Simon Josefsson.
112625 2009-05-02  Bruno Haible  <bruno@clisp.org>
112627         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Say "guessing no" instead of
112628         "cross".
112629         (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Update. Don't assume that
112630         gnulib-tool was called with option --source-base=lib.
112632 2009-05-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
112634         Use automake *-local hooks without commands, for extensibility.
112635         * modules/localcharset (Makefile.am): Rename install-exec-local
112636         rule to install-exec-localcharset, and make it a prerequisite of
112637         install-exec-local.  Likewise, rename the uninstall-local rule to
112638         uninstall-localcharset, and make it a prerequisite of the former.
112640 2009-05-01  Bruno Haible  <bruno@clisp.org>
112642         * lib/wchar.in.h (wcsnrtombs): Define if REPLACE_WCSNRTOMBS is 1.
112643         * m4/wcsnrtombs.m4 (gl_FUNC_WCSRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
112644         set REPLACE_WCSNRTOMBS if mbstate_t must be replaced.
112645         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSNRTOMBS.
112646         * modules/wchar (Makefile.am): Substitute REPLACE_WCSNRTOMBS.
112647         * modules/wcsnrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
112648         m4/locale-zh.m4, m4/codeset.m4.
112650         * m4/wcsrtombs.m4 (gl_FUNC_WCSNRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
112651         set REPLACE_WCSRTOMBS if mbstate_t must be replaced.
112652         * modules/wcsrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
112653         m4/locale-zh.m4.
112655         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Invoke gl_MBSTATE_T_BROKEN, and set
112656         REPLACE_WCRTOMB if mbstate_t must be replaced.
112657         * modules/wcrtomb (Files): Add m4/mbrtowc.m4.
112658         Reported by Jens Rehsack <rehsack@googlemail.com> via Eric Blake.
112660 2009-05-01  Bruno Haible  <bruno@clisp.org>
112662         Avoid compiler warnings when redefining macros defined by <libintl.h>.
112663         * lib/gettext.h [!ENABLE_NLS] (gettext, dgettext, dcgettext, ngettext,
112664         dngettext, dcngettext, textdomain, bindtextdomain,
112665         bind_textdomain_codeset): Undefine before redefining.
112667 2009-04-30  Bruno Haible  <bruno@clisp.org>
112669         Fix bug introduced on 2009-04-25.
112670         * lib/math.in.h (gl_signbitf_OPTIMIZED_MACRO,
112671         gl_signbitd_OPTIMIZED_MACRO, gl_signbitl_OPTIMIZED_MACRO): New macros.
112672         * lib/signbitf.c (gl_signbitd): Undefine if gl_signbitf_OPTIMIZED_MACRO
112673         is defined.
112674         * lib/signbitd.c (gl_signbitd): Undefine if gl_signbitd_OPTIMIZED_MACRO
112675         is defined.
112676         * lib/signbitl.c (gl_signbitd): Undefine if gl_signbitl_OPTIMIZED_MACRO
112677         is defined.
112678         Reported by Elbert_Pol <elbert.pol@gmail.com>.
112680 2009-04-28  Bruno Haible  <bruno@clisp.org>
112682         Comment tweaks.
112683         * lib/unistr.h (u*_cmp2): Clarify what memcmp2 is.
112684         * lib/uninorm.h (u*_normxfrm): Fix description of return value.
112685         * lib/unicase.h (u*_casexfrm): Likewise.
112686         Reported by Paolo Bonzini.
112688 2009-04-28  Bruno Haible  <bruno@clisp.org>
112690         Fix a compilation error.
112691         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Fix initializer.
112692         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
112693         Reported by Jim Meyering.
112695 2009-04-27  Bruno Haible  <bruno@clisp.org>
112697         New module 'libunistring'.
112698         * modules/libunistring: New file.
112699         * m4/libunistring.m4: New file.
112700         * MODULES.html.sh (Unicode string functions): Add it.
112702 2009-04-27  Eric Blake  <ebb9@byu.net>
112704         maint.mk: allow package-specific header to provide <config.h>
112705         * top/maint.mk (sc_require_config_h): New variable.
112706         (sc_require_config_h, sc_require_config_h_first): Use it.
112708 2009-04-27  Simon Josefsson  <simon@josefsson.org>
112710         * top/maint.mk (sc_avoid_if_before_free): Except
112711         useless-if-before-free script.
112713 2009-04-27  Eric Blake  <ebb9@byu.net>
112715         maintainer-makefile: depend on all required helper scripts
112716         * modules/maintainer-makefile (Depends-on): Add vc-list-files and
112717         useless-if-before-free.
112718         * top/maint.mk (VC_LIST, sc_avoid_if_before_free): Use local
112719         version, rather than assuming gnulib checkout is available.
112720         Reported by Simen Josefsson.
112722 2009-04-26  Bruno Haible  <bruno@clisp.org>
112724         Make the lib vs. lib64 recognition work on openSUSE 11 with "gcc -m32".
112725         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Ignore paths that end in
112726         "../" or "..".
112728 2009-04-26  Bruno Haible  <bruno@clisp.org>
112730         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Accept a fifth argument.
112731         * m4/libsigsegv.m4 (gl_LIBSIGSEGV): Simplify by using
112732         AC_LIB_HAVE_LINKFLAGS.
112734 2009-04-26  Bruno Haible  <bruno@clisp.org>
112736         Simplify calling convention of u*_conv_from_encoding.
112737         * lib/uniconv.h (u8_conv_from_encoding, u16_conv_from_encoding,
112738         u32_conv_from_encoding): Expect a resultbuf argument and return the
112739         result directly as a pointer.
112740         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Likewise.
112741         * lib/uniconv/u-conv-from-enc.h (FUNC): Likewise.
112742         * lib/uniconv/u-strconv-from-enc.h (FUNC): Update.
112743         * lib/unicase/ulc-casecmp.c (ulc_u8_casefold): Update.
112744         * lib/unicase/ulc-casexfrm.c (ulc_casexfrm): Update.
112745         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
112746         Update.
112747         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Update.
112748         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Update.
112749         * lib/vasnprintf.c (VASNPRINTF): Update.
112750         * tests/uniconv/test-u8-conv-from-enc.c (main): Update.
112751         * tests/uniconv/test-u16-conv-from-enc.c (main): Update.
112752         * tests/uniconv/test-u32-conv-from-enc.c (main): Update.
112753         * NEWS: Mention the change.
112755 2009-04-26  Bruno Haible  <bruno@clisp.org>
112757         Simplify calling convention of u*_conv_to_encoding.
112758         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
112759         u32_conv_to_encoding): Expect a resultbuf argument and return the
112760         result directly as a pointer.
112761         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
112762         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Preserve errno while
112763         freeing scaled_offsets if mem_iconveha failed.
112764         * lib/unicase/u-casexfrm.h (FUNC): Update.
112765         * lib/uninorm/u-normxfrm.h (FUNC): Update.
112766         * lib/vasnprintf.c (VASNPRINTF): Update.
112767         * tests/uniconv/test-u8-conv-to-enc.c (main): Update.
112768         * tests/uniconv/test-u16-conv-to-enc.c (main): Update.
112769         * tests/uniconv/test-u32-conv-to-enc.c (main): Update.
112770         * NEWS: Mention the change.
112772 2009-04-26  Bruno Haible  <bruno@clisp.org>
112774         Avoid test failures on AIX and OSF/1.
112775         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Avoid calling
112776         malloc(0).
112777         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
112778         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
112779         Likewise.
112780         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Likewise.
112781         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Likewise.
112782         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Fix memory leak.
112783         * lib/unistr/u-cpy-alloc.h (FUNC): Call malloc(1) instead of malloc(0).
112784         * doc/posix-functions/malloc.texi: Document the portability problem
112785         related to malloc(0).
112787 2009-04-26  Bruno Haible  <bruno@clisp.org>
112789         * modules/unistr/u8-cpy-alloc (Depends-on): Add malloc-posix.
112790         * modules/unistr/u16-cpy-alloc (Depends-on): Likewise.
112791         * modules/unistr/u32-cpy-alloc (Depends-on): Likewise.
112793 2009-04-25  Bruno Haible  <bruno@clisp.org>
112795         Avoid link error when creating a namespace clean library.
112796         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Don't define
112797         as macro with arguments if already defined as an alias.
112798         * lib/signbitf.c (gl_signbitf): Don't undefine.
112799         * lib/signbitd.c (gl_signbitd): Don't undefine.
112800         * lib/signbitl.c (gl_signbitl): Don't undefine.
112802 2009-04-25  Jim Meyering  <meyering@redhat.com>
112804         vc-list-files: fix another quoting bug
112805         * build-aux/vc-list-files: Avoid sed backslash expansion
112806         of pathological directory names.
112808 2009-04-25  Eric Blake  <ebb9@byu.net>
112810         vc-list-files: fix shell quoting error
112811         * build-aux/vc-list-files: Protect against $ in $dir.  Normalize
112812         timestamp.
112814 2009-04-25  Jim Meyering  <meyering@redhat.com>
112816         vc-list-files: restore lost functionality with subdir argument
112817         * build-aux/vc-list-files: When given a non-"." sub-directory
112818         argument, substitute the $dir/ prefix back onto each resulting name.
112819         Otherwise, coreutils' root_tests check would fail.
112821 2009-04-24  Eric Blake  <ebb9@byu.net>
112823         vc-list-files: ignore git symlinks
112824         * build-aux/vc-list-files (.git): Use ls-tree and a filter, rather
112825         than ls-files, to ignore git symlinks.
112827         maint.mk: import improvements from m4
112828         * top/maint.mk (VC-tag): Use signing key from cfg.mk.
112829         (move_if_change): Delete unused macro.
112830         (news-date-check, vc-diff-check): Support VPATH builds.
112831         (announcement): Likewise.  Split --bootstrap-tools list...
112832         (boostrap-tools): ...into separate list, which can be overridden
112833         in cfg.mk.
112834         (sc_avoid_if_before_free): Point to $(gnulib_dir), rather than
112835         requiring dependency on useless-if-before-free module.
112836         (VC_LIST, VC_LIST_EXCEPT): Likewise for vc-list-files module.
112837         Support VPATH builds.
112839 2009-04-24  Jim Meyering  <meyering@redhat.com>
112841         maint.mk: remove coreutils-specific rules and variables
112842         * top/maint.mk (bin, taint-distcheck, coreutils-path-check, t): Remove.
112843         (fake_home, install-transform-check, my-instcheck, pfx, TMPDIR): Remove.
112844         (t_prefix, t_taint, tp, warn_cflags, write_loser, my-distcheck): Remove.
112846         maint.mk: remove obsolete rule
112847         * top/maint.mk (rel-check): Remove rule.
112848         (WGET, WGETFLAGS): Remove now-unused variables.
112850 2009-04-24  Simon Josefsson  <simon@josefsson.org>
112852         * top/maint.mk (makefile-check): Renamed to sc_makefile_check for
112853         consistency.
112855         * modules/vc-list-files-tests (TESTS_ENVIRONMENT): Use
112856         '$(PATH_SEPARATOR)' instead of ':'.
112858 2009-04-24  Simon Josefsson  <simon@josefsson.org>
112860         * lib/getopt1.c (main): Use 'const' for static array.
112862 2009-04-24  Simon Josefsson  <simon@josefsson.org>
112864         * top/maint.mk: Sync with coreutils.
112865         * NEWS: Explain incompatibilities.
112867 2009-04-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
112868             Bruno Haible  <bruno@clisp.org>
112870         Fix cross-compilation results.
112871         * m4/btowc.m4 (gl_FUNC_BTOWC): Use no-op statement, rather than empty
112872         statement, as third argument of AC_TRY_RUN.
112873         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
112874         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL):
112875         Likewise.
112876         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
112877         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
112878         Likewise.
112879         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
112880         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise. Update for AIX 4.3.
112881         * doc/posix-functions/wcrtomb.texi: Mention the bug on AIX 4.3.
112883 2009-04-20  Bruno Haible  <bruno@clisp.org>
112885         Avoid test failure on mingw.
112886         * tests/uniwidth/test-uc_width2.sh: Convert newlines in output.
112888 2009-04-20  Bruno Haible  <bruno@clisp.org>
112890         Avoid compilation error on mingw.
112891         * modules/localename-tests (Depends-on): Add locale.
112893 2009-04-19  Bruno Haible  <bruno@clisp.org>
112895         Support for building a shared library on Windows platforms.
112896         * tests/uninorm/test-nfc.c (n): Don't define if WOE32DLL.
112897         (main): Test the presence of UNINORM_NFC here.
112898         * tests/uninorm/test-nfd.c (n): Don't define if WOE32DLL.
112899         (main): Test the presence of UNINORM_NFD here.
112900         * tests/uninorm/test-nfkc.c (n): Don't define if WOE32DLL.
112901         (main): Test the presence of UNINORM_NFKC here.
112902         * tests/uninorm/test-nfkd.c (n): Don't define if WOE32DLL.
112903         (main): Test the presence of UNINORM_NFKD here.
112905 2009-04-19  Bruno Haible  <bruno@clisp.org>
112907         Avoid a compiler warning.
112908         * tests/uninorm/test-u32-normalize-big.c (read_normalization_test_file):
112909         Change type of variable 'sequence'.
112911 2009-04-19  Bruno Haible  <bruno@clisp.org>
112913         * modules/configmake (Makefile.am): When the contents of configmake.h
112914         does not change, arrange to preserve its modification time.
112916 2009-04-17  Simon Josefsson  <simon@josefsson.org>
112918         * top/maint.mk (PO_DOMAIN): New variable, allows overriding of
112919         gettext domain.
112921 2009-04-16  Jim Meyering  <meyering@redhat.com>
112923         useless-if-before-free: improve conversion code
112924         * build-aux/useless-if-before-free: Adjust code-in-comment to match
112925         "...!= 0" as well as "...!= NULL".  emacs has one of the former.
112927 2009-04-14  Bruno Haible  <bruno@clisp.org>
112929         * modules/fcntl (Depends-on): Add extensions.
112930         * m4/fcntl_h.m4 (gl_FCNTL_H): Add a comment.
112932 2009-04-12  Ben Pfaff  <blp@gnu.org>
112934         Make fcntl module detect O_NOATIME, O_NOFOLLOW on GNU/Linux.
112935         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_USE_SYSTEM_EXTENSIONS.
112937 2009-03-20  Ben Pfaff  <blp@gnu.org>
112939         Make rename replace existing destinations on Windows.
112940         * m4/rename.m4: Add test for Mingw.
112941         * lib/rename.c: Add rename replacement that uses MoveFileEx with
112942         MOVEFILE_REPLACE_EXISTING to replace existing destination files.
112943         * doc/posix-functions/rename.texi: Document.
112945 2009-04-10  Bruno Haible  <bruno@clisp.org>
112947         New include file "iconveh.h".
112948         * lib/iconveh.h: New file, extracted from lib/striconveh.h.
112949         * lib/striconveh.h: Include it.
112950         (enum iconv_ilseq_handler): Remove definition.
112951         * lib/striconveha.h: Include <stddef.h> and iconveh.h instead of
112952         striconveh.h.
112953         * lib/striconveha.c: Include striconveh.h.
112954         * lib/uniconv.h: Include iconveh.h instead of striconveh.h.
112955         * modules/striconveh (Files): Add lib/iconveh.h.
112956         * modules/uniconv/base (Files): Add lib/iconveh.h. Remove
112957         lib/striconveh.h.
112959 2009-04-10  Bruno Haible  <bruno@clisp.org>
112961         * lib/uniconv.h: Update comment.
112963 2009-04-10  Bruno Haible  <bruno@clisp.org>
112965         * lib/unistr/u8-mbtouc-aux.c: Inside libunistring, define the function
112966         always.
112967         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
112968         * lib/unistr/u16-mbtouc-aux.c: Likewise.
112969         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
112970         * lib/unistr/u8-mbtouc.c: Inside libunistring, include
112971         "unistring-notinline.h", so that the function gets defined always.
112972         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
112973         * lib/unistr/u8-uctomb.c: Likewise.
112974         * lib/unistr/u16-mbtouc.c: Likewise.
112975         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
112976         * lib/unistr/u16-uctomb.c: Likewise.
112977         * lib/unistr/u32-mbtouc.c: Likewise.
112978         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
112979         * lib/unistr/u32-uctomb.c: Likewise.
112981 2009-04-10  Bruno Haible  <bruno@clisp.org>
112983         Mark 'utime' obsolete.
112984         * modules/utime (Status, Notice): New sections.
112985         Suggested by Jim Meyering.
112987         Fix cross-compile guess for utime test.
112988         * m4/utime.m4 (AC_FUNC_UTIME_NULL): Add definition from newest unstable
112989         autoconf.
112990         * doc/posix-functions/utime.texi: Give more precisions.
112991         Reported by Jan <ipif@ymail.com>.
112993 2009-04-09  Kamil Dudka  <kdudka@redhat.com>
112995         filevercmp: correct today's change
112996         * lib/filevercmp.c: Also handle coreutils' test inputs.
112997         * tests/test-filevercmp.c: Add inputs from one of coreutils' test scripts.
112999         Fix regression in 'filevercmp' module. Thanks Sven Joachim
113000         for reporting it.
113001         * lib/filevercmp.c: Special handle for "", "." and "..".
113002         * tests/test-filevercmp.c: Enlarge the set suite.
113004 2009-04-07  Jim Meyering  <meyering@redhat.com>
113006         useless-if-before-free: show how to remove braced useless free, too
113007         * build-aux/useless-if-before-free: still only in a comment, though.
113009 2009-04-07  Reuben Thomas  <rrt@sc3d.org>
113011         maint.mk: import changes to syntax-check macros from coreutils
113012         * top/maint.mk (_prohibit_regexp, _header_without_use): Define.
113013         Use them in the relevant macros.
113015 2009-04-06  Bruno Haible  <bruno@clisp.org>
113017         Fix unportable use of bit-fields.
113018         * lib/unicase/special-casing.h (struct special_casing_rule): Change the
113019         bit-field type from 'int' to 'signed int'. Otherwise Solaris cc,
113020         AIX xlc, and OSF/1 cc interpret it as 'unsigned int'.
113022 2009-04-06  Bruno Haible  <bruno@clisp.org>
113024         Avoid test failures on AIX and OSF/1.
113025         * tests/unicase/test-u8-casefold.c (check): Account for the possibility
113026         that malloc(0) = NULL.
113027         * tests/unicase/test-u8-tolower.c (check): Likewise.
113028         * tests/unicase/test-u8-totitle.c (check): Likewise.
113029         * tests/unicase/test-u8-toupper.c (check): Likewise.
113030         * tests/unicase/test-u16-casefold.c (check): Likewise.
113031         * tests/unicase/test-u16-tolower.c (check): Likewise.
113032         * tests/unicase/test-u16-totitle.c (check): Likewise.
113033         * tests/unicase/test-u16-toupper.c (check): Likewise.
113034         * tests/unicase/test-u32-casefold.c (check): Likewise.
113035         * tests/unicase/test-u32-tolower.c (check): Likewise.
113036         * tests/unicase/test-u32-totitle.c (check): Likewise.
113037         * tests/unicase/test-u32-toupper.c (check): Likewise.
113038         * tests/uninorm/test-u8-nfc.c (check): Likewise.
113039         * tests/uninorm/test-u8-nfd.c (check): Likewise.
113040         * tests/uninorm/test-u8-nfkc.c (check): Likewise.
113041         * tests/uninorm/test-u8-nfkd.c (check): Likewise.
113042         * tests/uninorm/test-u16-nfc.c (check): Likewise.
113043         * tests/uninorm/test-u16-nfd.c (check): Likewise.
113044         * tests/uninorm/test-u16-nfkc.c (check): Likewise.
113045         * tests/uninorm/test-u16-nfkd.c (check): Likewise.
113046         * tests/uninorm/test-u32-nfc.c (check): Likewise.
113047         * tests/uninorm/test-u32-nfd.c (check): Likewise.
113048         * tests/uninorm/test-u32-nfkc.c (check): Likewise.
113049         * tests/uninorm/test-u32-nfkd.c (check): Likewise.
113051 2009-04-05  Bruno Haible  <bruno@clisp.org>
113053         Work around an autoconf limitation.
113054         * gnulib-tool (func_emit_lib_Makefile_am): Omit the "Reproduce by"
113055         comment line if it would be longer than 3 KB.
113057 2009-04-05  Bruno Haible  <bruno@clisp.org>
113059         Avoid test failure with libiconv-1.13.
113060         * tests/test-striconveh.c (main): Allow result of libiconv 1.13 as one
113061         of the expected test results.
113063 2009-04-05  Bruno Haible  <bruno@clisp.org>
113065         * gnulib-tool (func_emit_lib_Makefile_am): Don't add the library to
113066         noinst_LTLIBRARIES if the Makefile.am in the same directory specifies
113067         that it should be installed.
113069 2009-04-05  Bruno Haible  <bruno@clisp.org>
113071         * gnulib-tool: New option --copy-file.
113072         (func_usage): Document it.
113073         (func_dest_tmpfilename): Moved out of func_import.
113074         (func_add_file, func_update_file): New functions, extracted from
113075         func_import.
113076         (func_import): Update.
113078 2009-04-05  Karl Berry  <karl@gnu.org>
113080         * README: prominently mention gnulib-tool.
113081         Rearrange sections so getting the code is near the top.
113083 2009-04-05  Bruno Haible  <bruno@clisp.org>
113085         * lib/unicase.h: Mention u*_cmp2.
113086         * lib/unicase/u-casecmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
113087         * lib/unicase/u8-casecmp.c: Use u8_cmp2 instead of u8_cmp.
113088         * lib/unicase/ulc-casecmp.c: Likewise.
113089         * lib/unicase/u16-casecmp.c: Use u16_cmp2 instead of u16_cmp.
113090         * lib/unicase/u32-casecmp.c: Use u32_cmp2 instead of u32_cmp.
113091         * modules/unicase/u8-casecmp (Depends-on): Add unistr/u8-cmp2, remove
113092         unistr/u8-cmp.
113093         * modules/unicase/ulc-casecmp (Depends-on): Likewise.
113094         * modules/unicase/u16-casecmp (Depends-on): Add unistr/u16-cmp2, remove
113095         unistr/u16-cmp.
113096         * modules/unicase/u32-casecmp (Depends-on): Add unistr/u32-cmp2, remove
113097         unistr/u32-cmp.
113099         * lib/uninorm.h: Mention u*_cmp2.
113100         * lib/uninorm/u-normcmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
113101         * lib/uninorm/u8-normcmp.c: Use u8_cmp2 instead of u8_cmp.
113102         * lib/uninorm/u16-normcmp.c: Use u16_cmp2 instead of u16_cmp.
113103         * lib/uninorm/u32-normcmp.c: Use u32_cmp2 instead of u32_cmp.
113104         * modules/uninorm/u8-normcmp (Depends-on): Add unistr/u8-cmp2, remove
113105         unistr/u8-cmp.
113106         * modules/uninorm/u16-normcmp (Depends-on): Add unistr/u16-cmp2, remove
113107         unistr/u16-cmp.
113108         * modules/uninorm/u32-normcmp (Depends-on): Add unistr/u32-cmp2, remove
113109         unistr/u32-cmp.
113111         New module 'unistr/u32-cmp2'.
113112         * lib/unistr/u32-cmp2.c: New file.
113113         * modules/unistr/u32-cmp2: New file.
113115         New module 'unistr/u16-cmp2'.
113116         * lib/unistr/u16-cmp2.c: New file.
113117         * modules/unistr/u16-cmp2: New file.
113119         New module 'unistr/u8-cmp2'.
113120         * lib/unistr.h (u8_cmp2, u16_cmp2, u32_cmp2): New declarations.
113121         * lib/unistr/u8-cmp2.c: New file.
113122         * lib/unistr/u-cmp2.h: New file.
113123         * modules/unistr/u8-cmp2: New file.
113125 2009-04-05  Bruno Haible  <bruno@clisp.org>
113127         * lib/unictype.h (uc_property_is_valid): New macro.
113128         * tests/unictype/test-pr_byname.c (main): Use it.
113130         * lib/unistr.h: Doc fixes.
113131         * lib/uniconv.h: Doc fixes.
113132         * lib/unictype.h: Doc fixes.
113134 2009-04-03  Paul Eggert  <eggert@cs.ucla.edu>
113136         Port coreutils 7.2 to Solaris 8.
113138         * modules/arpa_inet (arpa/inet.h): Depend on arpa_inet.in.h.
113139         * m4/inet_ntop.m4 (gl_INET_NTOP): Search for inet_ntop in -lnsl,
113140         for Solaris 8.  This is a bit of a hack, as it means it's the
113141         caller's responsibility to add -lnsl if needed, but most likely it
113142         won't be needed since only getaddrinfo uses this and getaddrinfo
113143         isn't needed on Solaris 8.
113145         * modules/fnmatch (Depends-on): Add mbsrtowcs, to fix a porting
113146         problem to Solaris 8 encountered with coreutils 7.2, which
113147         resulted in a message "fnmatch.c:292: warning: passing argument 4
113148         of 'mbsrtowcs' from incompatible pointer type".  Also, add mbsinit
113149         at the suggestion of Bruno Haible, since fnmatch uses mbsinit.
113151 2009-04-03  Simon Josefsson  <simon@josefsson.org>
113153         * m4/ld-version-script.m4: Add FIXME comment.
113155 2009-04-02  Simon Josefsson  <simon@josefsson.org>
113157         * doc/ld-output-def.texi: Use DLL_VERSION instead of confusing
113158         SOVERSION variable.
113160 2009-04-02  Bruno Haible  <bruno@clisp.org>
113162         * Makefile (info, html, dvi, pdf): Combine the rules.
113163         Suggested by Jim Meyering.
113165 2009-04-01  Bruno Haible  <bruno@clisp.org>
113167         * Makefile (info, html, dvi, pdf): New targets.
113168         Reported by Reuben Thomas <rrt@sc3d.org>.
113170 2009-04-01  Bruno Haible  <bruno@clisp.org>
113172         * doc/gnulib-tool.texi (Invoking gnulib-tool): Document how gnulib-tool
113173         can be put into PATH.
113174         Reported by Reuben Thomas <rrt@sc3d.org>. Suggested by Karl Berry.
113176 2009-04-01  Bruno Haible  <bruno@clisp.org>
113178         * doc/lib-symbol-visibility.texi: Follow texinfo style conventions.
113180 2009-04-01  Bruno Haible  <bruno@clisp.org>
113182         Rename module 'visibility'.
113183         * modules/lib-symbol-visibility: Renamed from modules/visibility.
113184         * doc/lib-symbol-visibility.texi: Renamed from visibility.texi.
113185         * doc/gnulib.texi: Update.
113186         * MODULES.html.sh (Misc): Update.
113187         * NEWS: Mention the change.
113189 2009-04-01  Simon Josefsson  <simon@josefsson.org>
113191         * modules/lib-msvc-compat: New module.  Thanks to Bruno Haible
113192         <bruno@clisp.org>, Ralf Wildenhues <Ralf.Wildenhues@gmx.de>, and
113193         Eric Blake <ebb9@byu.net> for review.
113194         * MODULES.html.sh: Add lib-msvc-compat.
113195         * doc/gnulib.texi: Link to new section.
113196         * m4/ld-output-def.m4: New file.
113197         * doc/ld-output-def.texi: New file.
113199 2009-04-01  Simon Josefsson  <simon@josefsson.org>
113201         Rename ld-version-script to lib-symbol-versions.  Suggested by
113202         Bruno Haible <bruno@clisp.org>.
113203         * modules/ld-version-script: Renamed to lib-symbol-versions.
113204         * doc/ld-version-script.texi: Fix module name.
113205         * MODULES.html.sh: Add lib-symbol-versions.
113207 2009-03-31  Simon Josefsson  <simon@josefsson.org>
113209         * modules/u64-tests: New file.
113210         * tests/test-u64.c: New file.
113212 2009-03-04  Simon Josefsson  <simon@josefsson.org>
113214         * MODULES.html.sh: Mention u64.
113215         * modules/u64: New module.
113216         * modules/crypto/sha512: Depend on u64 module instead of providing
113217         u64.h.
113219 2009-03-27  Eric Blake  <ebb9@byu.net>
113221         test-strerror: make debugging EAI_SYSTEM easier
113222         * modules/getaddrinfo-tests (Depends-on): Add strerror.
113223         * test-getaddrinfo.c (simple) [ENABLE_DEBUGGING]: Report errno if
113224         failure was EAI_SYSTEM.
113226 2009-03-25  Bruno Haible  <bruno@clisp.org>
113228         Fix a problem with --enable-relocatable on Solaris 7.
113229         * modules/relocatable-prog-wrapper (Depends-on): Add environ. Needed
113230         since 2008-02-24.
113232 2009-03-25  Eric Blake  <ebb9@byu.net>
113234         test-sockets: avoid gcc warning
113235         * tests/test-sockets.c (main): Silence compiler warning.
113237 2009-03-25  Paul Eggert  <eggert@cs.ucla.edu>
113239         New modules nproc, pthread, contributed by Glen Lenker.
113241         * MODULES.html.sh: Add pthread, nproc.
113242         * lib/nproc.c: New file.
113243         * lib/nproc.h: New file.
113244         * lib/pthread.in.h: New file.
113245         * m4/pthread.m4: New file.
113246         * modules/nproc: New file.
113247         * modules/pthread: New file.
113249 2009-03-24  Simon Josefsson  <simon@josefsson.org>
113251         * modules/unicase/locale-language-tests (test_locale_language_LDADD):
113252         New variable.
113254 2009-03-24  Kamil Dudka  <kdudka@redhat.com>
113256         filevercmp: handle simple~ and numbered.~3~ backup suffixes
113257         * lib/filevercmp.c: Handle simple~ and numbered.~3~ backup suffixes.
113258         * tests/test-filevercmp.c: Add tests for backup suffixes.
113260 2009-03-24  Simon Josefsson  <simon@josefsson.org>
113262         * modules/stdlib (Depends-on): Add stdint, needed when defining
113263         struct random_data on, for example, HP-UX 10.20.  Reported by
113264         Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
113266 2009-03-24  Simon Josefsson  <simon@josefsson.org>
113268         * lib/readline.c (readline): Call fflush on stdout after printing
113269         prompt.
113271 2009-03-20  Bruno Haible  <bruno@clisp.org>
113273         Remove dependency from 'close' module to -lws2_32 on native Windows.
113274         * lib/close-hook.h: New file.
113275         * lib/close-hook.c: New file.
113276         * lib/close.c: Include close-hook.h. Don't include <sys/socket.h>,
113277         w32sock.h.
113278         (_gl_close_fd_maybe_socket): Remove function.
113279         (rpl_close): Invoke execute_all_close_hooks instead of
113280         _gl_close_fd_maybe_socket.
113281         * lib/sockets.c: Include close-hook.h, w32sock.h.
113282         (close_fd_maybe_socket): New function, essentially from lib/close.c.
113283         (close_sockets_hook): New variable.
113284         (gl_sockets_startup): Register close_fd_maybe_socket as a hook.
113285         (gl_sockets_cleanup): Unregister it.
113286         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): Remove macro.
113287         * m4/close.m4 (gl_REPLACE_CLOSE): Undo 2009-02-05 change.
113288         * modules/close-hook: New file.
113289         * modules/close (Files): Remove lib/w32sock.h.
113290         (Depends-on): Add close-hook.
113291         (Link): Remove section.
113292         * modules/sockets (Files): Add lib/w32sock.h.
113293         (Depends-on): Add close-hook.
113294         * modules/sys_socket (configure.ac): Remove gl_MODULE_INDICATOR
113295         invocation.
113296         * NEWS: Mention that LIB_CLOSE is gone.
113298 2009-03-23  Eric Blake  <ebb9@byu.net>
113300         signal-tests: test previous patch
113301         * tests/test-signal.c: New file.
113302         * modules/signal-tests: Likewise.
113304         signal.h: always support 'volatile sig_atomic_t'
113305         * m4/signal_h.m4 (gl_SIGNAL_H): Check for AIX limitation.
113306         (gl_SIGNAL_H_DEFAULTS): Add a default.
113307         * modules/signal (Makefile.am): Substitute if needed.
113308         * lib/signal.in.h (sig_atomic_t): Redefine if needed, so that
113309         users can blindly add volatile.
113310         * doc/posix-headers/signal.texi (signal.h): Document it.
113311         Reported by Matthew Woehlke.
113313 2009-03-23  Jim Meyering  <meyering@redhat.com>
113315         pathmax: PATH_MAX: use pathconf only when available
113316         * lib/pathmax.h (PATH_MAX): Select the pathconf-using definition
113317         only if HAVE_PATHCONF is defined.  Patch by Sylvain Beucler.
113318         * m4/pathmax.m4 (gl_PATHMAX): Check for pathconf.
113319         This avoids a link failure in a PSP cross-compilation environment
113320         described in http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/17048
113322         * lib/vasnprintf.c (divide): Fix typo in comment.
113324 2009-03-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
113326         * gnulib-tool (func_filter_filelist): Fix comment.
113328 2009-03-20  Bruno Haible  <bruno@clisp.org>
113330         Make sockets.h self-contained.
113331         * lib/sockets.c: Include sockets.h first.
113332         * lib/sockets.h: Include <sys/socket.h> before using the SOCKET type.
113334 2009-03-19  Eric Blake  <ebb9@byu.net>
113336         doc: mention more functions added in cygwin 1.7.0
113337         * doc/posix-functions/log2.texi: Mention recent cygwin 1.7.0
113338         addition.
113339         * doc/posix-functions/log2f.texi: Likewise.
113341 2009-03-19  Jim Meyering  <meyering@redhat.com>
113343         fsusage: avoid syntax error due to statement-before-declaration
113344         * lib/fsusage.c (get_fs_usage): Put warning-avoidance statement
113345         after all declarations.  Reported by Matthew Woehlke in
113346         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/16231
113348 2009-03-18  Eric Blake  <ebb9@byu.net>
113350         build-aux/compile: sync from automake
113351         * build-aux/compile: New file, from automake.
113352         * config/srclist.txt: Mention build-aux/compile.
113354 2009-03-17  Bruno Haible  <bruno@clisp.org>
113356         * lib/git-merge-changelog.c: Fix typo in comment.
113357         Reported by Reuben Thomas <rrt@sc3d.org>.
113359 2009-03-17  Reuben Thomas  <rrt@sc3d.org>
113361         * m4/regex.m4: update and improve help for
113362         --without-included-regex.
113364 2009-03-17  Simon Josefsson  <simon@josefsson.org>
113366         * modules/isnanl-nolibm-tests (Files): Add tests/nan.h to avoid
113367         failure on missing include files.
113369 2009-03-17  Eric Blake  <ebb9@byu.net>
113371         doc: mention more functions added in cygwin 1.7.0
113372         * doc/posix-functions/fwprintf.texi: Mention recent cygwin 1.7.0
113373         addition.
113374         * doc/posix-functions/fwscanf.texi: Likewise.
113375         * doc/posix-functions/swprintf.texi: Likewise.
113376         * doc/posix-functions/swscanf.texi: Likewise.
113377         * doc/posix-functions/vfwprintf.texi: Likewise.
113378         * doc/posix-functions/vfwscanf.texi: Likewise.
113379         * doc/posix-functions/vswprintf.texi: Likewise.
113380         * doc/posix-functions/vswscanf.texi: Likewise.
113381         * doc/posix-functions/vwprintf.texi: Likewise.
113382         * doc/posix-functions/vwscanf.texi: Likewise.
113383         * doc/posix-functions/wcscasecmp.texi: Likewise.
113384         * doc/posix-functions/wcsdup.texi: Likewise.
113385         * doc/posix-functions/wcsftime.texi: Likewise.
113386         * doc/posix-functions/wcsncasecmp.texi: Likewise.
113387         * doc/posix-functions/wprintf.texi: Likewise.
113388         * doc/posix-functions/wscanf.texi: Likewise.
113389         * doc/glibc-functions/gethostbyname2.texi: Likewise.
113391 2009-03-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
113393         maint.mk: really add $(AM_MAKEFLAGS)
113394         * top/maint.mk (init-coverage, build-coverage): `$(AM_MAKEFLAGS)'
113395         was inadvertently omitted in the last commit.
113396         Spotted by Bruno Haible.
113398         maint.mk: use $(MAKE) $(AM_MAKEFLAGS) not make
113399         * top/maint.mk (init-coverage, build-coverage): Use `$(MAKE)
113400         $(AM_MAKEFLAGS)' rather than plain `make'.
113402         gnulib-tool: execute $MAKE not make
113403         * gnulib-tool: Default $MAKE to 'make'.
113404         (func_create_testdir, func_create_megatestdir): Use $MAKE rather
113405         than make.  Initialize $MAKE in the do-autobuild script.
113407         gnulib-tool: use $MAKE not make in generated files
113408         * gnulib-tool (func_create_megatestdir): Use $MAKE rather than
113409         make, in generated files.  Initialize $MAKE in the do-autobuild
113410         script.
113412         * top/GNUmakefile (_have-git-version-gen): Fix typo.
113414         GNUmakefile: disable parallelism only for multiple, recursive targets
113415         * top/GNUmakefile (ALL_RECURSIVE_TARGETS): New macro; allow user
113416         additions in the Makefile.
113417         (AM_RECURSIVE_TARGETS): New macro, override only if not provided
113418         by Automake.
113419         (.NOTPARALLEL): Only disable parallel builds if multiple targets
113420         are listed on the command line and at least one of them is
113421         listed in $(ALL_RECURSIVE_TARGETS).
113423 2009-03-14  Bruno Haible  <bruno@clisp.org>
113425         * modules/unilbrk/u8-possible-linebreaks (Depends-on): Replace
113426         utf8-ucs4-unsafe with unistr/u8-mbtouc-unsafe.
113427         * modules/unilbrk/u8-width-linebreaks (Depends-on): Likewise.
113428         * modules/unilbrk/u16-possible-linebreaks (Depends-on): Replace
113429         utf16-ucs4-unsafe with unistr/u16-mbtouc-unsafe.
113430         * modules/unilbrk/u16-width-linebreaks (Depends-on): Likewise.
113431         * modules/unistr/u8-chr (Depends-on): Replace ucs4-utf8 with
113432         unistr/u8-uctomb.
113433         * modules/unistr/u8-strchr (Depends-on): Likewise.
113434         * modules/unistr/u8-strrchr (Depends-on): Likewise.
113435         * modules/unistr/u16-chr (Depends-on): Replace ucs4-utf16 with
113436         unistr/u16-uctomb.
113437         * modules/unistr/u16-strchr (Depends-on): Likewise.
113438         * modules/unistr/u16-strrchr (Depends-on): Likewise.
113440 2009-03-12  Bruno Haible  <bruno@clisp.org>
113442         Work around select() bug on Interix 3.5.
113443         * lib/sys_select.in.h (select): Also replace if REPLACE_SELECT is 1.
113444         * lib/select.c (rpl_select): Add an implementation for Unix platforms.
113445         * m4/select.m4: New file.
113446         * m4/sys_select_h.m4 (gl_SYS_SELECT_H_DEFAULTS): Initialize REPLACE_SELECT.
113447         * modules/sys_select (Makefile.am): Substitute REPLACE_SELECT.
113448         * modules/select (Files): Add m4/select.m4.
113449         (configure.ac): Move conditional to m4/select.m4. Invoke gl_FUNC_SELECT.
113450         * modules/nanosleep (Depends-on): Add select.
113451         * modules/poll (Depends-on): Likewise.
113452         * doc/posix-functions/select.texi: Mention the Interix bug.
113453         Reported by Markus Duft <mduft@gentoo.org>.
113455         * lib/select.c: Renamed from lib/winsock-select.c.
113456         * modules/select (Files): Add lib/select.c, remove
113457         lib/winsock-select.c.
113458         (configure.ac): Update.
113460 2009-03-12  Jim Meyering  <meyering@redhat.com>
113462         avoid gcc warnings about unused macro definitions
113463         * lib/readtokens.c (STREQ): Remove unused definition.
113464         * lib/xmalloc.c (SIZE_MAX): Likewise.
113465         * lib/openat-die.c (N_): Likewise.
113466         * lib/mountlist.c (SIZE_MAX): Remove definition.
113467         Instead, include <stdint.h>.
113468         * lib/readutmp.c: Likewise.
113469         * modules/readutmp (Depends-on): Add stdint.
113470         * modules/mountlist (Depends-on): Add stdint.
113471         * lib/userspec.c (ISDIGIT): Move definition into #if block where used.
113473 2009-03-10  Bruno Haible  <bruno@clisp.org>
113475         Tests for module 'mbmemcasecoll'.
113476         * modules/mbmemcasecoll-tests: New file.
113477         * tests/test-mbmemcasecoll1.sh: New file.
113478         * tests/test-mbmemcasecoll2.sh: New file.
113479         * tests/test-mbmemcasecoll3.sh: New file.
113480         * tests/test-mbmemcasecoll.c: New file.
113482         New module 'mbmemcasecoll'.
113483         * lib/mbmemcasecoll.h: New file.
113484         * lib/mbmemcasecoll.c: New file.
113485         * modules/mbmemcasecoll: New file.
113487         * tests/test-mbmemcasecmp.h: New file, extracted from
113488         tests/test-mbmemcasecmp.c.
113489         * tests/test-mbmemcasecmp.c: Include test-mbmemcasecmp.h.
113490         (test_ascii, test_iso_8859_1, test_utf_8): Remove functions.
113491         (main): Update.
113492         * modules/mbmemcasecmp-tests (Files): Add tests/test-mbmemcasecmp.h.
113494 2009-03-09  Bruno Haible  <bruno@clisp.org>
113496         Tests for module 'mbmemcasecmp'.
113497         * modules/mbmemcasecmp-tests: New file.
113498         * tests/test-mbmemcasecmp1.sh: New file.
113499         * tests/test-mbmemcasecmp2.sh: New file.
113500         * tests/test-mbmemcasecmp3.sh: New file.
113501         * tests/test-mbmemcasecmp.c: New file.
113503         New module 'mbmemcasecmp'.
113504         * lib/mbmemcasecmp.h: New file.
113505         * lib/mbmemcasecmp.c: New file.
113506         * modules/mbmemcasecmp: New file.
113508 2009-03-09  Bruno Haible  <bruno@clisp.org>
113510         Tests for module 'unicase/ulc-casecoll'.
113511         * modules/unicase/ulc-casecoll-tests: New file.
113512         * tests/unicase/test-ulc-casecoll1.sh: New file.
113513         * tests/unicase/test-ulc-casecoll2.sh: New file.
113514         * tests/unicase/test-ulc-casecoll.c: New file.
113516         New module 'unicase/ulc-casecoll'.
113517         * lib/unicase.h (ulc_casecoll): New declaration.
113518         * lib/unicase/ulc-casecoll.c: New file.
113519         * modules/unicase/ulc-casecoll: New file.
113521         New module 'unicase/ulc-casexfrm'.
113522         * lib/unicase.h (ulc_casexfrm): New declaration.
113523         * lib/unicase/ulc-casexfrm.c: New file.
113524         * modules/unicase/ulc-casexfrm: New file.
113526 2009-03-09  Bruno Haible  <bruno@clisp.org>
113528         Followup to 2008-12-22 commit: Remove unnecessary AC_FUNC_MBRTOWC
113529         invocations.
113531         * m4/mbscasecmp.m4: Remove file.
113532         * modules/mbscasecmp (Files): Remove it and m4/mbrtowc.m4
113533         (configure.ac): Remove gl_FUNC_MBSCASECMP invocation.
113535         * m4/mbscasestr.m4: Remove file.
113536         * modules/mbscasestr (Files): Remove it and m4/mbrtowc.m4
113537         (configure.ac): Remove gl_FUNC_MBSCASESTR invocation.
113539         * m4/mbschr.m4: Remove file.
113540         * modules/mbschr (Files): Remove it and m4/mbrtowc.m4
113541         (configure.ac): Remove gl_FUNC_MBSCHR invocation.
113543         * m4/mbscspn.m4: Remove file.
113544         * modules/mbscspn (Files): Remove it and m4/mbrtowc.m4
113545         (configure.ac): Remove gl_FUNC_MBSCSPN invocation.
113547         * m4/mbslen.m4: Remove file.
113548         * modules/mbslen (Files): Remove it and m4/mbrtowc.m4
113549         (configure.ac): Remove gl_FUNC_MBSLEN invocation.
113551         * m4/mbsncasecmp.m4: Remove file.
113552         * modules/mbsncasecmp (Files): Remove it and m4/mbrtowc.m4
113553         (configure.ac): Remove gl_FUNC_MBSNCASECMP invocation.
113555         * m4/mbsnlen.m4: Remove file.
113556         * modules/mbsnlen (Files): Remove it and m4/mbrtowc.m4
113557         (configure.ac): Remove gl_FUNC_MBSNLEN invocation.
113559         * m4/mbspbrk.m4: Remove file.
113560         * modules/mbspbrk (Files): Remove it and m4/mbrtowc.m4
113561         (configure.ac): Remove gl_FUNC_MBSPBRK invocation.
113563         * m4/mbspcasecmp.m4: Remove file.
113564         * modules/mbspcasecmp (Files): Remove it and m4/mbrtowc.m4
113565         (configure.ac): Remove gl_FUNC_MBSPCASECMP invocation.
113567         * m4/mbsrchr.m4: Remove file.
113568         * modules/mbsrchr (Files): Remove it and m4/mbrtowc.m4
113569         (configure.ac): Remove gl_FUNC_MBSRCHR invocation.
113571         * m4/mbssep.m4: Remove file.
113572         * modules/mbssep (Files): Remove it and m4/mbrtowc.m4
113573         (configure.ac): Remove gl_FUNC_MBSSEP invocation.
113575         * m4/mbsspn.m4: Remove file.
113576         * modules/mbsspn (Files): Remove it and m4/mbrtowc.m4
113577         (configure.ac): Remove gl_FUNC_MBSSPN invocation.
113579         * m4/mbsstr.m4: Remove file.
113580         * modules/mbsstr (Files): Remove it and m4/mbrtowc.m4
113581         (configure.ac): Remove gl_FUNC_MBSSTR invocation.
113583         * m4/mbstok_r.m4: Remove file.
113584         * modules/mbstok_r (Files): Remove it and m4/mbrtowc.m4
113585         (configure.ac): Remove gl_FUNC_MBSTOK_R invocation.
113587         * m4/mbswidth.m4 (gl_MBSWIDTH): Remove AC_FUNC_MBRTOWC invocation.
113589         * m4/quotearg.m4 (gl_QUOTEARG): Remove mbsinit test and
113590         AC_TYPE_MBSTATE_T, AC_FUNC_MBRTOWC invocations.
113592         * modules/trim (configure.ac): Remove AC_FUNC_MBRTOWC invocation.
113594 2009-03-08  Bruno Haible  <bruno@clisp.org>
113596         Tests for module 'unicase/ulc-casecmp'.
113597         * modules/unicase/ulc-casecmp-tests: New file.
113598         * tests/unicase/test-ulc-casecmp1.sh: New file.
113599         * tests/unicase/test-ulc-casecmp2.sh: New file.
113600         * tests/unicase/test-ulc-casecmp.c: New file.
113602         New module 'unicase/ulc-casecmp'.
113603         * lib/unicase.h (ulc_casecmp): New declaration.
113604         * lib/unicase/ulc-casecmp.c: New file.
113605         * lib/unicase/u-casecmp.h (FUNC): Change argument types to
113606         'const SRC_UNIT *'.
113607         * lib/unicase/u8-casecmp.c (SRC_UNIT): Define like UNIT.
113608         * lib/unicase/u16-casecmp.c (SRC_UNIT): Likewise.
113609         * lib/unicase/u32-casecmp.c (SRC_UNIT): Likewise.
113610         * modules/unicase/ulc-casecmp: New file.
113612         Tests for module 'unicase/u32-is-cased'.
113613         * modules/unicase/u32-is-cased-tests: New file.
113614         * tests/unicase/test-u32-is-cased.c: New file.
113616         Tests for module 'unicase/u16-is-cased'.
113617         * modules/unicase/u16-is-cased-tests: New file.
113618         * tests/unicase/test-u16-is-cased.c: New file.
113620         Tests for module 'unicase/u8-is-cased'.
113621         * modules/unicase/u8-is-cased-tests: New file.
113622         * tests/unicase/test-u8-is-cased.c: New file.
113623         * tests/unicase/test-is-cased.h: New file.
113625         New module 'unicase/u32-is-cased'.
113626         * lib/unicase/u32-is-cased.c: New file.
113627         * modules/unicase/u32-is-cased: New file.
113629         New module 'unicase/u16-is-cased'.
113630         * lib/unicase/u16-is-cased.c: New file.
113631         * modules/unicase/u16-is-cased: New file.
113633         New module 'unicase/u8-is-cased'.
113634         * lib/unicase/u8-is-cased.c: New file.
113635         * lib/unicase/u-is-cased.h: New file.
113636         * modules/unicase/u8-is-cased: New file.
113638         Tests for module 'unicase/u32-is-casefolded'.
113639         * modules/unicase/u32-is-casefolded-tests: New file.
113640         * tests/unicase/test-u32-is-casefolded.c: New file.
113642         Tests for module 'unicase/u16-is-casefolded'.
113643         * modules/unicase/u16-is-casefolded-tests: New file.
113644         * tests/unicase/test-u16-is-casefolded.c: New file.
113646         Tests for module 'unicase/u8-is-casefolded'.
113647         * modules/unicase/u8-is-casefolded-tests: New file.
113648         * tests/unicase/test-u8-is-casefolded.c: New file.
113649         * tests/unicase/test-is-casefolded.h: New file.
113651         New module 'unicase/u32-is-casefolded'.
113652         * lib/unicase/u32-is-casefolded.c: New file.
113653         * modules/unicase/u32-is-casefolded: New file.
113655         New module 'unicase/u16-is-casefolded'.
113656         * lib/unicase/u16-is-casefolded.c: New file.
113657         * modules/unicase/u16-is-casefolded: New file.
113659         New module 'unicase/u8-is-casefolded'.
113660         * lib/unicase/u8-is-casefolded.c: New file.
113661         * modules/unicase/u8-is-casefolded: New file.
113663         Tests for module 'unicase/u32-is-titlecase'.
113664         * modules/unicase/u32-is-titlecase-tests: New file.
113665         * tests/unicase/test-u32-is-titlecase.c: New file.
113667         Tests for module 'unicase/u16-is-titlecase'.
113668         * modules/unicase/u16-is-titlecase-tests: New file.
113669         * tests/unicase/test-u16-is-titlecase.c: New file.
113671         Tests for module 'unicase/u8-is-titlecase'.
113672         * modules/unicase/u8-is-titlecase-tests: New file.
113673         * tests/unicase/test-u8-is-titlecase.c: New file.
113674         * tests/unicase/test-is-titlecase.h: New file.
113676         New module 'unicase/u32-is-titlecase'.
113677         * lib/unicase/u32-is-titlecase.c: New file.
113678         * modules/unicase/u32-is-titlecase: New file.
113680         New module 'unicase/u16-is-titlecase'.
113681         * lib/unicase/u16-is-titlecase.c: New file.
113682         * modules/unicase/u16-is-titlecase: New file.
113684         New module 'unicase/u8-is-titlecase'.
113685         * lib/unicase/u8-is-titlecase.c: New file.
113686         * modules/unicase/u8-is-titlecase: New file.
113688         Tests for module 'unicase/u32-is-lowercase'.
113689         * modules/unicase/u32-is-lowercase-tests: New file.
113690         * tests/unicase/test-u32-is-lowercase.c: New file.
113692         Tests for module 'unicase/u16-is-lowercase'.
113693         * modules/unicase/u16-is-lowercase-tests: New file.
113694         * tests/unicase/test-u16-is-lowercase.c: New file.
113696         Tests for module 'unicase/u8-is-lowercase'.
113697         * modules/unicase/u8-is-lowercase-tests: New file.
113698         * tests/unicase/test-u8-is-lowercase.c: New file.
113699         * tests/unicase/test-is-lowercase.h: New file.
113701         New module 'unicase/u32-is-lowercase'.
113702         * lib/unicase/u32-is-lowercase.c: New file.
113703         * modules/unicase/u32-is-lowercase: New file.
113705         New module 'unicase/u16-is-lowercase'.
113706         * lib/unicase/u16-is-lowercase.c: New file.
113707         * modules/unicase/u16-is-lowercase: New file.
113709         New module 'unicase/u8-is-lowercase'.
113710         * lib/unicase/u8-is-lowercase.c: New file.
113711         * modules/unicase/u8-is-lowercase: New file.
113713         Tests for module 'unicase/u32-is-uppercase'.
113714         * modules/unicase/u32-is-uppercase-tests: New file.
113715         * tests/unicase/test-u32-is-uppercase.c: New file.
113717         Tests for module 'unicase/u16-is-uppercase'.
113718         * modules/unicase/u16-is-uppercase-tests: New file.
113719         * tests/unicase/test-u16-is-uppercase.c: New file.
113721         Tests for module 'unicase/u8-is-uppercase'.
113722         * modules/unicase/u8-is-uppercase-tests: New file.
113723         * tests/unicase/test-u8-is-uppercase.c: New file.
113724         * tests/unicase/test-is-uppercase.h: New file.
113726         New module 'unicase/u32-is-uppercase'.
113727         * lib/unicase/u32-is-uppercase.c: New file.
113728         * modules/unicase/u32-is-uppercase: New file.
113730         New module 'unicase/u16-is-uppercase'.
113731         * lib/unicase/u16-is-uppercase.c: New file.
113732         * modules/unicase/u16-is-uppercase: New file.
113734         New module 'unicase/u8-is-uppercase'.
113735         * lib/unicase/u8-is-uppercase.c: New file.
113736         * modules/unicase/u8-is-uppercase: New file.
113738         New module 'unicase/u32-is-invariant'.
113739         * lib/unicase/u32-is-invariant.c: New file.
113740         * modules/unicase/u32-is-invariant: New file.
113742         New module 'unicase/u16-is-invariant'.
113743         * lib/unicase/u16-is-invariant.c: New file.
113744         * modules/unicase/u16-is-invariant: New file.
113746         New module 'unicase/u8-is-invariant'.
113747         * lib/unicase/u8-is-invariant.c: New file.
113748         * lib/unicase/invariant.h: New file.
113749         * lib/unicase/u-is-invariant.h: New file.
113750         * modules/unicase/u8-is-invariant: New file.
113752         Tests for module 'unicase/u32-casecoll'.
113753         * modules/unicase/u32-casecoll-tests: New file.
113754         * tests/unicase/test-u32-casecoll.c: New file.
113756         Tests for module 'unicase/u16-casecoll'.
113757         * modules/unicase/u16-casecoll-tests: New file.
113758         * tests/unicase/test-u16-casecoll.c: New file.
113760         Tests for module 'unicase/u8-casecoll'.
113761         * modules/unicase/u8-casecoll-tests: New file.
113762         * tests/unicase/test-u8-casecoll.c: New file.
113764         New module 'unicase/u32-casecoll'.
113765         * lib/unicase/u32-casecoll.c: New file.
113766         * modules/unicase/u32-casecoll: New file.
113768         New module 'unicase/u16-casecoll'.
113769         * lib/unicase/u16-casecoll.c: New file.
113770         * modules/unicase/u16-casecoll: New file.
113772         New module 'unicase/u8-casecoll'.
113773         * lib/unicase/u8-casecoll.c: New file.
113774         * lib/unicase/u-casecoll.h: New file.
113775         * modules/unicase/u8-casecoll: New file.
113777         New module 'unicase/u32-casexfrm'.
113778         * lib/unicase/u32-casexfrm.c: New file.
113779         * modules/unicase/u32-casexfrm: New file.
113781         New module 'unicase/u16-casexfrm'.
113782         * lib/unicase/u16-casexfrm.c: New file.
113783         * modules/unicase/u16-casexfrm: New file.
113785         New module 'unicase/u8-casexfrm'.
113786         * lib/unicase/u8-casexfrm.c: New file.
113787         * lib/unicase/u-casexfrm.h: New file.
113788         * modules/unicase/u8-casexfrm: New file.
113790         Tests for module 'unicase/u32-casecmp'.
113791         * modules/unicase/u32-casecmp-tests: New file.
113792         * tests/unicase/test-u32-casecmp.c: New file.
113794         Tests for module 'unicase/u16-casecmp'.
113795         * modules/unicase/u16-casecmp-tests: New file.
113796         * tests/unicase/test-u16-casecmp.c: New file.
113798         Tests for module 'unicase/u8-casecmp'.
113799         * modules/unicase/u8-casecmp-tests: New file.
113800         * tests/unicase/test-u8-casecmp.c: New file.
113801         * tests/unicase/test-casecmp.h: New file.
113803         New module 'unicase/u32-casecmp'.
113804         * lib/unicase/u32-casecmp.c: New file.
113805         * modules/unicase/u32-casecmp: New file.
113807         New module 'unicase/u16-casecmp'.
113808         * lib/unicase/u16-casecmp.c: New file.
113809         * modules/unicase/u16-casecmp: New file.
113811         New module 'unicase/u8-casecmp'.
113812         * lib/unicase/u8-casecmp.c: New file.
113813         * lib/unicase/u-casecmp.h: New file.
113814         * modules/unicase/u8-casecmp: New file.
113816         Tests for module 'unicase/u32-casefold'.
113817         * modules/unicase/u32-casefold-tests: New file.
113818         * tests/unicase/test-u32-casefold.c: New file.
113820         Tests for module 'unicase/u16-casefold'.
113821         * modules/unicase/u16-casefold-tests: New file.
113822         * tests/unicase/test-u16-casefold.c: New file.
113824         Tests for module 'unicase/u8-casefold'.
113825         * modules/unicase/u8-casefold-tests: New file.
113826         * tests/unicase/test-u8-casefold.c: New file.
113828         New module 'unicase/u32-casefold'.
113829         * lib/unicase/u32-casefold.c: New file.
113830         * modules/unicase/u32-casefold: New file.
113832         New module 'unicase/u16-casefold'.
113833         * lib/unicase/u16-casefold.c: New file.
113834         * modules/unicase/u16-casefold: New file.
113836         New module 'unicase/u8-casefold'.
113837         * lib/unicase/u8-casefold.c: New file.
113838         * lib/unicase/u-casefold.h: New file.
113839         * modules/unicase/u8-casefold: New file.
113841         New module 'unicase/tocasefold'.
113842         * lib/unicase/casefold.h: New file.
113843         * lib/unicase/tocasefold.c: New file.
113844         * lib/unicase/tocasefold.h: New file, generated by gen-uni-tables.c.
113845         * modules/unicase/tocasefold: New file.
113847         Tests for module 'unicase/u32-totitle'.
113848         * modules/unicase/u32-totitle-tests: New file.
113849         * tests/unicase/test-u32-totitle.c: New file.
113851         Tests for module 'unicase/u16-totitle'.
113852         * modules/unicase/u16-totitle-tests: New file.
113853         * tests/unicase/test-u16-totitle.c: New file.
113855         Tests for module 'unicase/u8-totitle'.
113856         * modules/unicase/u8-totitle-tests: New file.
113857         * tests/unicase/test-u8-totitle.c: New file.
113859         New module 'unicase/u32-totitle'.
113860         * lib/unicase/u32-totitle.c: New file.
113861         * modules/unicase/u32-totitle: New file.
113863         New module 'unicase/u16-totitle'.
113864         * lib/unicase/u16-totitle.c: New file.
113865         * modules/unicase/u16-totitle: New file.
113867         New module 'unicase/u8-totitle'.
113868         * lib/unicase/u8-totitle.c: New file.
113869         * lib/unicase/u-totitle.h: New file.
113870         * modules/unicase/u8-totitle: New file.
113872         Tests for module 'unicase/u32-tolower'.
113873         * modules/unicase/u32-tolower-tests: New file.
113874         * tests/unicase/test-u32-tolower.c: New file.
113876         Tests for module 'unicase/u16-tolower'.
113877         * modules/unicase/u16-tolower-tests: New file.
113878         * tests/unicase/test-u16-tolower.c: New file.
113880         Tests for module 'unicase/u8-tolower'.
113881         * modules/unicase/u8-tolower-tests: New file.
113882         * tests/unicase/test-u8-tolower.c: New file.
113884         New module 'unicase/u32-tolower'.
113885         * lib/unicase/u32-tolower.c: New file.
113886         * modules/unicase/u32-tolower: New file.
113888         New module 'unicase/u16-tolower'.
113889         * lib/unicase/u16-tolower.c: New file.
113890         * modules/unicase/u16-tolower: New file.
113892         New module 'unicase/u8-tolower'.
113893         * lib/unicase/u8-tolower.c: New file.
113894         * modules/unicase/u8-tolower: New file.
113896         Tests for module 'unicase/u32-toupper'.
113897         * modules/unicase/u32-toupper-tests: New file.
113898         * tests/unicase/test-u32-toupper.c: New file.
113900         Tests for module 'unicase/u16-toupper'.
113901         * modules/unicase/u16-toupper-tests: New file.
113902         * tests/unicase/test-u16-toupper.c: New file.
113904         Tests for module 'unicase/u8-toupper'.
113905         * modules/unicase/u8-toupper-tests: New file.
113906         * tests/unicase/test-u8-toupper.c: New file.
113908         New module 'unicase/u32-toupper'.
113909         * lib/unicase/u32-toupper.c: New file.
113910         * modules/unicase/u32-toupper: New file.
113912         New module 'unicase/u16-toupper'.
113913         * lib/unicase/u16-toupper.c: New file.
113914         * modules/unicase/u16-toupper: New file.
113916         New module 'unicase/u8-toupper'.
113917         * lib/unicase/u8-toupper.c: New file.
113918         * modules/unicase/u8-toupper: New file.
113920         New module 'unicase/u32-casemap'.
113921         * lib/unicase/u32-casemap.c: New file.
113922         * modules/unicase/u32-casemap: New file.
113924         New module 'unicase/u16-casemap'.
113925         * lib/unicase/u16-casemap.c: New file.
113926         * modules/unicase/u16-casemap: New file.
113928         New module 'unicase/u8-casemap'.
113929         * lib/unicase/unicasemap.h: New file.
113930         * lib/unicase/u8-casemap.c: New file.
113931         * lib/unicase/u-casemap.h: New file.
113932         * modules/unicase/u8-casemap: New file.
113934         New module 'unicase/special-casing'.
113935         * lib/unicase/special-casing.h: New file.
113936         * lib/unicase/special-casing.c: New file.
113937         * lib/unicase/special-casing-table.gperf: New file, generated by
113938         gen-uni-tables.c.
113939         * modules/unicase/special-casing: New file.
113941         Tests for module 'unicase/locale-language'.
113942         * modules/unicase/locale-language-tests: New file.
113943         * tests/unicase/test-locale-language.sh: New file.
113944         * tests/unicase/test-locale-language.c: New file.
113946         New module 'unicase/locale-language'.
113947         * lib/unicase/locale-language.c: New file.
113948         * lib/unicase/locale-languages.gperf: New file.
113949         * modules/unicase/locale-language: New file.
113951         Generate more tables for case conversion and case folding.
113952         * lib/gen-uni-tables.c (SCC_*): New enum items.
113953         (struct special_casing_rule): New type.
113954         (casing_rules, num_casing_rules, allocated_casing_rules): New
113955         variables.
113956         (add_casing_rule, fill_casing_rules): New functions.
113957         (struct casefold_rule): New type.
113958         (casefolding_rules, num_casefolding_rules,
113959         allocated_casefolding_rules): New variables.
113960         (fill_casefolding_rules): New function.
113961         (unicode_casefold): New variable.
113962         (to_casefold, redistribute_casefolding_rules, compare_casing_rules,
113963         sort_casing_rules, output_casing_rules): New functions.
113964         (main): Accept to more arguments: SpecialCasing.txt and
113965         CaseFolding.txt. Invoke fill_casing_rules, fill_casefolding_rules,
113966         redistribute_casefolding_rules, sort_casing_rules, output_casing_rules.
113967         Output mapping for casefolding.
113969         * lib/unicase.h: Include stdbool.h, uninorm.h.
113970         (u8_toupper, u16_toupper, u32_toupper, u8_tolower, u16_tolower,
113971         u32_tolower, u8_totitle, u16_totitle, u32_totitle): Add nf argument.
113972         (u8_casefold, u16_casefold, u32_casefold): Add iso639_language and nf
113973         arguments.
113974         (u8_casecmp, u16_casecmp, u32_casecmp): Add iso639_language, nf,
113975         resultp arguments.
113976         (u8_casexfrm, u16_casexfrm, u32_casexfrm): New declarations.
113977         (u8_casecoll, u16_casecoll, u32_casecoll): Add iso639_language, nf,
113978         resultp arguments.
113979         (u8_is_uppercase, u16_is_uppercase, u32_is_uppercase, u8_is_lowercase,
113980         u16_is_lowercase, u32_is_lowercase, u8_is_titlecase, u16_is_titlecase,
113981         u32_is_titlecase, u8_is_casefolded, u16_is_casefolded,
113982         u32_is_casefolded, u8_is_cased, u16_is_cased, u32_is_cased): New
113983         declarations.
113984         * modules/unicase/base (Depends-on): Add uninorm/base, stdbool.
113986 2009-03-08  Bruno Haible  <bruno@clisp.org>
113988         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
113989         u16_normcoll, u32_normcoll): Rename argument 'result' to 'resultp'.
113990         * lib/uninorm/u-normcmp.h (FUNC): Likewise.
113991         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
113993 2009-03-07  Bruno Haible  <bruno@clisp.org>
113995         Adjust u*_normcmp, u*_normcoll API.
113996         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
113997         u16_normcoll, u32_normcoll): Change failure conventions.
113998         * lib/uninorm/u-normcmp.h (FUNC): Upon failure, store the error code in
113999         errno and return -1.
114000         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
114002 2009-03-07  Bruno Haible  <bruno@clisp.org>
114004         Tests for module 'uninorm/u32-normcoll'.
114005         * modules/uninorm/u32-normcoll-tests: New file.
114006         * tests/uninorm/test-u32-normcoll.c: New file.
114008         Tests for module 'uninorm/u16-normcoll'.
114009         * modules/uninorm/u16-normcoll-tests: New file.
114010         * tests/uninorm/test-u16-normcoll.c: New file.
114012         Tests for module 'uninorm/u8-normcoll'.
114013         * modules/uninorm/u8-normcoll-tests: New file.
114014         * tests/uninorm/test-u8-normcoll.c: New file.
114016 2009-03-07  Bruno Haible  <bruno@clisp.org>
114018         * tests/uninorm/test-u32-normcmp.h: New file, extracted from
114019         tests/uninorm/test-u32-normcmp.c.
114020         * tests/uninorm/test-u32-normcmp.c: Include it.
114021         (test_nonascii): New function, extracted from main. Add some more
114022         tests.
114023         (main): Invoke test_ascii and test_nonascii.
114024         * modules/uninorm/u32-normcmp-tests (Files): Add
114025         tests/uninorm/test-u32-normcmp.h.
114026         (Depends-on): Remove uninorm/u32-normcmp.
114028         * tests/uninorm/test-u16-normcmp.h: New file, extracted from
114029         tests/uninorm/test-u16-normcmp.c.
114030         * tests/uninorm/test-u16-normcmp.c: Include it.
114031         (test_nonascii): New function, extracted from main. Add some more
114032         tests.
114033         (main): Invoke test_ascii and test_nonascii.
114034         * modules/uninorm/u16-normcmp-tests (Files): Add
114035         tests/uninorm/test-u16-normcmp.h.
114036         (Depends-on): Remove uninorm/u16-normcmp.
114038         * tests/uninorm/test-u8-normcmp.h: New file, extracted from
114039         tests/uninorm/test-u8-normcmp.c.
114040         * tests/uninorm/test-u8-normcmp.c: Include it.
114041         (test_nonascii): New function, extracted from main. Add some more
114042         tests.
114043         (main): Invoke test_ascii and test_nonascii.
114044         * modules/uninorm/u8-normcmp-tests (Files): Add
114045         tests/uninorm/test-u8-normcmp.h.
114046         (Depends-on): Remove uninorm/u8-normcmp.
114048 2009-03-07  Bruno Haible  <bruno@clisp.org>
114050         New module 'uninorm/u32-normcoll'.
114051         * lib/uninorm/u32-normcoll.c: New file.
114052         * modules/uninorm/u32-normcoll: New file.
114054         New module 'uninorm/u16-normcoll'.
114055         * lib/uninorm/u16-normcoll.c: New file.
114056         * modules/uninorm/u16-normcoll: New file.
114058         New module 'uninorm/u8-normcoll'.
114059         * lib/uninorm.h (u8_normcoll, u16_normcoll, u32_normcoll): New
114060         declarations.
114061         * lib/uninorm/u8-normcoll.c: New file.
114062         * lib/uninorm/u-normcoll.h: New file.
114063         * modules/uninorm/u8-normcoll: New file.
114065         New module 'uninorm/u32-normxfrm'.
114066         * lib/uninorm/u32-normxfrm.c: New file.
114067         * modules/uninorm/u32-normxfrm: New file.
114069         New module 'uninorm/u16-normxfrm'.
114070         * lib/uninorm/u16-normxfrm.c: New file.
114071         * modules/uninorm/u16-normxfrm: New file.
114073         New module 'uninorm/u8-normxfrm'.
114074         * lib/uninorm.h (u8_normxfrm, u16_normxfrm, u32_normxfrm): New
114075         declarations.
114076         * lib/uninorm/u8-normxfrm.c: New file.
114077         * lib/uninorm/u-normxfrm.h: New file.
114078         * modules/uninorm/u8-normxfrm: New file.
114080 2009-03-07  Bruno Haible  <bruno@clisp.org>
114082         * modules/uninorm/u8-normcmp (Depends-on): Add uninorm/base.
114083         * modules/uninorm/u16-normcmp (Depends-on): Likewise.
114084         * modules/uninorm/u32-normcmp (Depends-on): Likewise.
114086 2009-03-07  Bruno Haible  <bruno@clisp.org>
114088         New module 'memxfrm'.
114089         * lib/memxfrm.h: New file.
114090         * lib/memxfrm.c: New file.
114091         * modules/memxfrm: New file.
114093 2009-03-07  Bruno Haible  <bruno@clisp.org>
114095         New module 'memcmp2'.
114096         * lib/memcmp2.h: New file.
114097         * lib/memcmp2.c: New file.
114098         * modules/memcmp2: New file.
114100 2009-03-07  Bruno Haible  <bruno@clisp.org>
114102         Tests for module 'uninorm/decomposing-form'.
114103         * modules/uninorm/decomposing-form-tests: New file.
114104         * tests/uninorm/test-decomposing-form.c: New file.
114106         New module 'uninorm/decomposing-form'.
114107         * lib/uninorm.h (uninorm_decomposing_form): New declaration.
114108         * lib/uninorm/normalize-internal.h (struct unicode_normalization_form):
114109         Add 'decomposing_variant' field.
114110         * lib/uninorm/decomposing-form.c: New file.
114111         * lib/uninorm/nfc.c (uninorm_nfc): Update.
114112         * lib/uninorm/nfd.c (uninorm_nfd): Update.
114113         * lib/uninorm/nfkc.c (uninorm_nfkc): Update.
114114         * lib/uninorm/nfkd.c (uninorm_nfkd): Update.
114115         * modules/uninorm/decomposing-form: New file.
114116         * modules/uninorm/nfc (Depends-on): Add uninorm/nfd.
114117         * modules/uninorm/nfkc (Depends-on): Add uninorm/nfkd.
114119 2009-03-07  Bruno Haible  <bruno@clisp.org>
114121         * lib/uninorm/u-normcmp.h (FUNC): Use stack=allocated buffers for small
114122         strings.
114124 2009-03-06  Bruno Haible  <bruno@clisp.org>
114126         Tests for module 'uninorm/u32-normcmp'.
114127         * tests/uninorm/test-u32-normcmp.c: New file.
114128         * modules/uninorm/u32-normcmp-tests: New file.
114130         Tests for module 'uninorm/u16-normcmp'.
114131         * tests/uninorm/test-u16-normcmp.c: New file.
114132         * modules/uninorm/u16-normcmp-tests: New file.
114134         Tests for module 'uninorm/u8-normcmp'.
114135         * tests/uninorm/test-u8-normcmp.c: New file.
114136         * modules/uninorm/u8-normcmp-tests: New file.
114138         New module 'uninorm/u32-normcmp'.
114139         * lib/uninorm/u32-normcmp.c: New file.
114140         * modules/uninorm/u32-normcmp: New file.
114142         New module 'uninorm/u16-normcmp'.
114143         * lib/uninorm/u16-normcmp.c: New file.
114144         * modules/uninorm/u16-normcmp: New file.
114146         New module 'uninorm/u8-normcmp'.
114147         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp): New
114148         declarations.
114149         * lib/uninorm/u8-normcmp.c: New file.
114150         * lib/uninorm/u-normcmp.h: New file.
114151         * modules/uninorm/u8-normcmp: New file.
114153 2009-03-06  Bruno Haible  <bruno@clisp.org>
114155         * lib/w32spawn.h (dup_noinherit): Add cast, to avoid gcc warning.
114156         Reported by Eric Blake.
114158 2009-03-06  Eric Blake  <ebb9@byu.net>
114159             Bruno Haible  <bruno@clisp.org>
114161         * lib/spawni.c (__spawni) [WIN32_NATIVE]: Define as a stub.
114162         * modules/posix_spawn-tests (configure.ac): Define POSIX_SPAWN_PORTED
114163         condition.
114164         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
114165         * modules/posix_spawnp-tests (configure.ac): Define POSIX_SPAWN_PORTED
114166         condition.
114167         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
114169 2009-03-06  Eric Blake  <ebb9@byu.net>
114171         * lib/execute.c (execute) [WIN32_NATIVE]: Cast arguments of spawnvpe,
114172         to avoid compiler warnings.
114173         * lib/pipe.c (create_pipe) [WIN32_NATIVE]: Likewise.
114175 2009-03-05  Bruno Haible  <bruno@clisp.org>
114177         * tests/test-ftell.c (main): Disable test beyond end of file on
114178         FreeMiNT.
114179         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
114181 2009-03-05  Kamil Dudka  <kdudka@redhat.com>
114183         * lib/filevercmp.c: Move hidden files up in ordering.
114184         * tests/test-filevercmp.c: Add tests for hidden files.
114186 2009-03-04  Bruno Haible  <bruno@clisp.org>
114188         * modules/visibility (Makefile.am): Augment AM_CFLAGS.
114189         * gnulib-tool (func_emit_lib_Makefile_am): Emit initialization of
114190         AM_CFLAGS.
114191         Reported by Simon Josefsson.
114193 2009-03-03  Bruno Haible  <bruno@clisp.org>
114195         * doc/visibility.texi: Recommend to use HAVE_VISIBILITY as a C macro.
114196         Reported by Simon Josefsson.
114198         * doc/ld-version-script.texi: Update node reference.
114200 2009-03-03  Bruno Haible  <bruno@clisp.org>
114202         * modules/visibility (License): Change to 'unlimited'.
114203         Suggested by Simon Josefsson.
114205 2009-03-03  Jim Meyering  <meyering@redhat.com>
114207         unlinkdir: cannot_unlink_dir may modify process state
114208         * lib/unlinkdir.c (cannot_unlink_dir): Add a comment warning that
114209         it's neither thread-safe nor appropriate for use in a library.
114211 2009-03-03  Eric Blake  <ebb9@byu.net>
114213         test-closein: silence test under Darwin
114214         * tests/test-closein.sh: Ignore stderr from cat, since we don't
114215         care if it dies from EPIPE or EBADF.
114217 2009-03-03  Bruno Haible  <bruno@clisp.org>
114219         * doc/gnulib.texi: Include visibility.texi and ld-version-script.texi
114220         earlier.
114221         * doc/visibility.texi: Fix @node and @section.
114223 2009-03-03  Simon Josefsson  <simon@josefsson.org>
114225         * doc/gnulib.texi: Link to sections for ld version script and
114226         visibility.
114227         * doc/visibility.texi: Add @node and @section.
114228         * modules/ld-version-script: New module.
114229         * m4/ld-version-script.m4: New file.
114230         * doc/ld-version-script.texi: New file.
114232 2009-03-02  David Lutterkort  <lutter@redhat.com>
114234         * lib/safe-alloc.h (__GNUC_PREREQ): New macro.
114235         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
114237 2009-03-02  Bruno Haible  <bruno@clisp.org>
114239         * doc/visibility.texi: Mention libtool's -export-symbols option.
114241 2009-03-02  Jim Meyering  <meyering@redhat.com>
114243         announce-gen: new option: --no-print-checksums
114244         * build-aux/announce-gen (usage): Describe it.
114245         (print_checksums): Print a newline here, not in the [*] footnote.
114246         (main): Honor it.
114248 2009-03-01  Bruno Haible  <bruno@clisp.org>
114250         Use socklen_t in the native Windows replacements prototypes.
114251         * lib/sys_socket.in.h (rpl_getsockopt, rpl_setsockopt): Use socklen_t
114252         instead of 'int'.
114253         * lib/getsockopt.c (rpl_getsockopt): Likewise.
114254         * lib/setsockopt.c (rpl_setsockopt): Likewise.
114255         * modules/getsockopt (Depends-on): Add socklen.
114256         * modules/setsockopt (Depends-on): Add socklen.
114258 2009-03-01  Bruno Haible  <bruno@clisp.org>
114260         * gnulib-tool (sed): Do alias as "sed --posix" if sed's version is at
114261         least 4.2.
114263 2009-03-01  Eric Blake  <ebb9@byu.net>
114264             Bruno Haible  <bruno@clisp.org>
114266         * lib/wait-process.h (wait_subprocess): Describe effect of termsigp on
114267         error messages.
114268         * lib/wait-process.c (wait_subprocess): Omit error message about
114269         deadly signal sent to the child of termsigp != NULL.
114271 2009-03-01  Eric Blake  <ebb9@byu.net>
114273         * lib/wait-process.c (wait_subprocess): Remove unnecessary cast.
114275 2009-03-01  Bruno Haible  <bruno@clisp.org>
114277         Avoid a gcc warning.
114278         * tests/test-sched.c (b): Make global.
114279         Reported by Eric Blake.
114281 2009-01-19  Martin Lambers  <marlam@marlam.de>
114283         Provide POSIX semantics for socket timeout options on W32.
114284         * lib/setsockopt.c: Convert struct timeval to milliseconds on W32.
114285         * lib/getsockopt.c: Convert milliseconds to struct timeval on W32.
114286         * modules/setsockopt: Depend on sys_time module for struct timeval.
114287         * modules/getsockopt: Depend on sys_time module for struct timeval.
114289 2009-03-01  Simon Josefsson  <simon@josefsson.org>
114291         * lib/gai_strerror.c (values): Use EAI_INPROGRESS instead of
114292         __USE_GNU, for consistency with netdb.in.h.
114293         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
114295 2009-03-01  Bruno Haible  <bruno@clisp.org>
114297         More support for FreeMiNT.
114298         * lib/fseeko.c (rpl_fseeko): Complete last commit.
114299         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
114301 2009-03-01  Bruno Haible  <bruno@clisp.org>
114303         More support for FreeMiNT.
114304         * lib/fpurge.c (fpurge): Correct last commit.
114305         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
114307 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
114309         Fix unportable awk script in vc-list-files.
114310         * build-aux/vc-list-files: In the replacement awk script, use
114311         substr with a second argument of 1, not zero.
114312         Report by Simon Josefsson.
114314 2009-02-28  Bruno Haible  <bruno@clisp.org>
114316         More support for FreeMiNT.
114317         * lib/freading.c (freading) [__MINT__]: Use new macros that were added
114318         to FreeMiNT today.
114319         * lib/fwriting.c (fwriting): Likewise.
114320         Based on patch by Alan Hourihane <alanh@fairlite.co.uk>.
114322 2009-02-28  Bruno Haible  <bruno@clisp.org>
114324         * tests/test-freadseek.c (main): Disable test beyond end of file on
114325         FreeMiNT.
114326         * tests/test-ftello.c (main): Likewise.
114327         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
114329 2009-02-28  Bruno Haible  <bruno@clisp.org>
114331         Add tentative support for FreeMiNT.
114332         * lib/fbufmode.c (fbufmode) [__MINT__]: Add conditional code.
114333         * lib/fpurge.c (fpurge): Likewise.
114334         * lib/freadable.c (freadable): Likewise.
114335         * lib/freading.c (freading): Likewise.
114336         * lib/freadptr.c (freadptr): Likewise.
114337         * lib/freadseek.c (freadptrinc): Likewise.
114338         * lib/fseeko.c (rpl_fseeko): Likewise.
114339         * lib/fseterr.c (fseterr): Likewise.
114340         * lib/fwritable.c (fwritable): Likewise.
114341         * lib/fwriting.c (fwriting): Likewise.
114342         * lib/freadahead.c (freadahead): Likewise, based on code by Alan
114343         Hourihane.
114344         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
114346 2009-02-28  Bruno Haible  <bruno@clisp.org>
114348         * lib/wait-process.h (wait_subprocess): Clarify restriction regarding
114349         SIGCHLD.
114350         Reported by Jim Meyering.
114352 2009-02-28  Bruno Haible  <bruno@clisp.org>
114354         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Separate the two first tests.
114355         Mention the results of these tests on various platforms.
114356         * doc/posix-functions/fprintf.texi: Mention platforms in canonical
114357         order.
114358         * doc/posix-functions/printf.texi: Likewise.
114359         * doc/posix-functions/snprintf.texi: Likewise.
114360         * doc/posix-functions/sprintf.texi: Likewise.
114361         * doc/posix-functions/vfprintf.texi: Likewise.
114362         * doc/posix-functions/vprintf.texi: Likewise.
114363         * doc/posix-functions/vsnprintf.texi: Likewise.
114364         * doc/posix-functions/vsprintf.texi: Likewise.
114365         * doc/glibc-functions/obstack_printf.texi: Likewise.
114366         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
114368 2009-02-28  Bruno Haible  <bruno@clisp.org>
114370         * build-aux/po/Makefile.in.in: Update from GNU gettext 0.17.
114371         Reported by Loïc Minier <lool@dooz.org>.
114373 2009-02-27  Bruno Haible  <bruno@clisp.org>
114375         * gnulib-tool (func_import): Make the sed expression used to create the
114376         sed script for updating the .gitignore file POSIX compliant.
114377         Reported by Eric Blake.
114379 2009-02-27  Bruno Haible  <bruno@clisp.org>
114381         * gnulib-tool (sed): Don't alias as "sed --posix".
114382         Reported by Eric Blake.
114384 2009-02-27  Bruno Haible  <bruno@clisp.org>
114386         Avoid test link errors.
114387         * modules/uninorm/nfc-tests (test_u32_nfc_big_LDADD): New variable.
114388         * modules/uninorm/nfd-tests (test_u32_nfd_big_LDADD): New variable.
114389         * modules/uninorm/nfkc-tests (test_u32_nfkc_big_LDADD): New variable.
114390         * modules/uninorm/nfkd-tests (test_u32_nfkd_big_LDADD): New variable.
114391         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
114393 2009-02-27  Bruno Haible  <bruno@clisp.org>
114395         Avoid spurious "(cached)" in configure output.
114396         * m4/gnulib-common.m4 (gl_CACHE_VAL_SILENT): New macro.
114397         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Use it instead of AC_CACHE_VAL.
114398         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
114399         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
114400         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
114401         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Likewise.
114402         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
114403         * m4/stdarg.m4 (gl_STDARG_H): Likewise.
114404         Reported by Eric Blake.
114406 2009-02-27  Eric Blake  <ebb9@byu.net>
114408         printf: fix regression in previous patch
114409         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Fix compilation error.
114411 2009-02-27  Bruno Haible  <bruno@clisp.org>
114413         * lib/inttypes.in.h: Test merely whether _LP64 is defined, not its
114414         value.
114415         * lib/stdint.in.h: Likewise.
114416         Suggested by Eric Blake. Reported by Peter Bray <pdb_ml@yahoo.com.au>.
114418 2009-02-27  Eric Blake  <ebb9@byu.net>
114420         doc: mention more functions added in cygwin 1.7.0
114421         * doc/posix-functions/mbsnrtowcs.texi: Mention recent cygwin 1.7.0
114422         addition.
114423         * doc/posix-functions/open_wmemstream.texi: Likewise.
114424         * doc/posix-functions/wcsnlen.texi: Likewise.
114425         * doc/posix-functions/wcsnrtombs.texi: Likewise.
114426         * doc/posix-functions/wcstod.texi: Likewise.
114427         * doc/posix-functions/wcstof.texi: Likewise.
114428         * doc/posix-functions/wcstoimax.texi: Likewise.
114429         * doc/posix-functions/wcstok.texi: Likewise.
114430         * doc/posix-functions/wcstoumax.texi: Likewise.
114432         Detect bug in cygwin 1.5.x *printf on 1-character %ls.
114433         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Enhance filter.
114434         * doc/posix-functions/fprintf.texi: Update.
114435         * doc/posix-functions/printf.texi: Update.
114436         * doc/posix-functions/snprintf.texi: Update.
114437         * doc/posix-functions/sprintf.texi: Update.
114438         * doc/posix-functions/vfprintf.texi: Update.
114439         * doc/posix-functions/vprintf.texi: Update.
114440         * doc/posix-functions/vsnprintf.texi: Update.
114441         * doc/posix-functions/vsprintf.texi: Update.
114442         * doc/glibc-functions/obstack_printf.texi: Update.
114443         * doc/glibc-functions/obstack_vprintf.texi: Update.
114445 2009-02-26  Eric Blake  <ebb9@byu.net>
114447         avoid gcc 3.4.3 bug on long double NaN on Irix 6.5
114448         * tests/nan.h (NaNl): Rewrite as function on Irix, to avoid
114449         compilation bug by using runtime conversion.
114450         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
114451         * m4/isnanl.m4 (gl_FUNC_ISNANL): Likewise.
114452         * modules/ceill-tests (Files): Use nan.h.
114453         * modules/floorl-tests (Files): Likewise.
114454         * modules/frexpl-tests (Files): Likewise.
114455         * modules/isnanl-tests (Files): Likewise.
114456         * modules/ldexpl-tests (Files): Likewise.
114457         * modules/roundl-tests (Files): Likewise.
114458         * modules/truncl-tests (Files): Likewise.
114459         * tests/test-ceill.c (main): Use a working NaN.
114460         * tests/test-floorl.c (main): Likewise.
114461         * tests/test-frexpl.c (main): Likewise.
114462         * tests/test-isnan.c (test_long_double): Likewise.
114463         * tests/test-isnanl.h (main): Likewise.
114464         * tests/test-ldexpl.h (main): Likewise.
114465         * tests/test-roundl.h (main): Likewise.
114466         * tests/test-truncl.h (main): Likewise.
114467         See http://lists.gnu.org/r/bug-gnulib/2009-02/msg00190.html.
114469 2009-02-26  Eric Blake  <ebb9@byu.net>
114470             Bruno Haible  <bruno@clisp.org>
114472         Work around a *printf bug with %ls on Solaris.
114473         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Also test whether, when a
114474         precision is specified, sprintf stops converting the wide string
114475         argument when the number of bytes that have been produced by this
114476         conversion equals or exceeds the precision.
114477         * doc/posix-functions/fprintf.texi: Update.
114478         * doc/posix-functions/printf.texi: Update.
114479         * doc/posix-functions/snprintf.texi: Update.
114480         * doc/posix-functions/sprintf.texi: Update.
114481         * doc/posix-functions/vfprintf.texi: Update.
114482         * doc/posix-functions/vprintf.texi: Update.
114483         * doc/posix-functions/vsnprintf.texi: Update.
114484         * doc/posix-functions/vsprintf.texi: Update.
114485         * doc/glibc-functions/obstack_printf.texi: Update.
114486         * doc/glibc-functions/obstack_vprintf.texi: Update.
114488 2009-02-26  Eric Blake  <ebb9@byu.net>
114490         stdlib: favor compiler check of random.h
114491         * m4/stdlib_h.m4 (gl_STDLIB_H): Skip preprocessor check.  Needed
114492         to avoid an ObjC random.h installed by Swarm.
114494 2009-02-26  Bruno Haible  <bruno@clisp.org>
114496         Work around *printf bug with %g directive and 0.0 on HP-UX 10.20.
114497         * m4/printf.m4 (gl_PRINTF_INFINITE): Also test for %g output of -0.0.
114498         Reported by Gary V. Vaughan <gary@gnu.org>.
114500 2009-02-26  Bruno Haible  <bruno@clisp.org>
114502         Fix *printf behaviour regarding the %ls directive.
114503         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): New macro.
114504         * lib/vasnprintf.c (local_wcslen, VASNPRINTF): Handle
114505         NEED_PRINTF_DIRECTIVE_LS.
114506         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_LS): New macro.
114507         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
114508         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
114509         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS and test its result. Invoke
114510         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS.
114511         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Likewise.
114512         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
114513         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
114514         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
114515         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
114516         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
114517         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
114518         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
114519         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
114520         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
114521         * doc/posix-functions/fprintf.texi: Update.
114522         * doc/posix-functions/printf.texi: Update.
114523         * doc/posix-functions/snprintf.texi: Update.
114524         * doc/posix-functions/sprintf.texi: Update.
114525         * doc/posix-functions/vfprintf.texi: Update.
114526         * doc/posix-functions/vprintf.texi: Update.
114527         * doc/posix-functions/vsnprintf.texi: Update.
114528         * doc/posix-functions/vsprintf.texi: Update.
114529         * doc/glibc-functions/obstack_printf.texi: Update.
114530         * doc/glibc-functions/obstack_vprintf.texi: Update.
114531         Reported by Eric Blake.
114533 2009-02-25  Bruno Haible  <bruno@clisp.org>
114535         * m4/mbrtowc.m4 (gl_MBRTOWC_NUL_RETVAL): Update guess for Solaris 8
114536         with known value.
114537         Reported by Gary V. Vaughan <gary@gnu.org>.
114539 2009-02-25  Bruno Haible  <bruno@clisp.org>
114541         Work around mbrtowc bug in zh_CN.GB18030 locale on Solaris 8.
114542         * m4/mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): New macro.
114543         (gl_MBSTATE_T_BROKEN): Invoke it. Replace mbstate_t when it says "no".
114544         * doc/posix-functions/mbrtowc.texi: Document the Solaris 8 bug.
114545         Reported by Gary V. Vaughan <gary@gnu.org>.
114547 2009-02-25  Bruno Haible  <bruno@clisp.org>
114549         Work around broken INT8_MAX, UINT8_MAX etc. values on HP-UX 11.23.
114550         * m4/stdint.m4 (gl_STDINT_H): Also check whether the expansions of
114551         INT8_MAX, UINT8_MAX etc. contain casts to elementary types.
114552         * doc/posix-headers/stdint.texi: Mention the HP-UX bug.
114553         Reported by Gary V. Vaughan <gary@gnu.org>.
114555 2009-02-25  Eric Blake  <ebb9@byu.net>
114557         tests: skip fseek/ftell tests if ungetc is broken
114558         * m4/ungetc.m4: New file.
114559         * modules/fseek-tests: Split test, so ungetc dependency is
114560         separate from rest of test.
114561         * modules/fseeko-tests: Likewise.
114562         * modules/ftell-tests: Likewise.
114563         * modules/ftello-tests: Likewise.
114564         * tests/test-fseek.c (main): Isolate ungetc dependency.
114565         * tests/test-fseeko.c (main): Likewise.
114566         * tests/test-ftell.c (main): Likewise.
114567         * tests/test-ftello.c (main): Likewise.
114568         * tests/test-fseek2.sh: New file.
114569         * tests/test-fseeko2.sh: Likewise.
114570         * tests/test-ftell2.sh: Likewise.
114571         * tests/test-ftello2.sh: Likewise.
114573 2009-02-25  Ondřej Vašík  <ovasik@redhat.com>
114575         test-getaddrinfo: fix usage of skip return code 77
114576         * tests/test-gettaddrinfo.c: Return skip code 77 only
114577         for first occurrence of skip (4x77 is not 77)
114579 2009-02-25  Gary V. Vaughan  <gary@gnu.org>
114581         strtod: avoid C99 decl-after-statement
114582         * m4/strtod.m4 (gl_FUNC_STRTOD): Rearrange declaration.
114584 2009-02-24  Eric Blake  <ebb9@byu.net>
114586         strtod: detect HP-UX 11.31 bug
114587         * m4/strtod.m4 (gl_FUNC_STRTOD): Detect errno handling bug.
114588         Reported by Gary V. Vaughan.
114590 2009-02-23  Bruno Haible  <bruno@clisp.org>
114592         Fix invalid read past end of memory block.
114593         * lib/vasnprintf.c (DCHAR_SET): Define.
114594         (local_wcslen): Define only when needed.
114595         (local_strnlen, local_wcsnlen): New functions.
114596         (VASNPRINTF) [!USE_SNPRINTF && HAVE_WCHAR_T]: Implement the %s and %ls
114597         directives that involve a conversion ourselves.
114598         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for strnlen,
114599         wcsnlen, mbrtowc, wcrtomb.
114600         * tests/test-vasnprintf-posix.c (test_function): Add tests for %.*s.
114601         * tests/test-vasprintf-posix.c (test_function): Likewise.
114602         * tests/test-snprintf-posix.h (test_function): Likewise.
114603         * tests/test-sprintf-posix.h (test_function): Likewise.
114604         Reported by Ben Pfaff <blp@cs.stanford.edu>.
114606 2009-02-22  Bruno Haible  <bruno@clisp.org>
114608         Implement new clarified decomposition of Hangul syllables.
114609         * lib/uninorm/decomposition.c (uc_decomposition): For Hangul syllables
114610         of type LTV, return only a pairwise decomposition.
114611         * lib/uninorm/canonical-decomposition.c (uc_canonical_decomposition):
114612         Likewise.
114613         * tests/uninorm/test-decomposition.c (main): Updated expected result.
114614         * tests/uninorm/test-canonical-decomposition.c (main): Likewise.
114615         * tests/uninorm/test-compat-decomposition.c (main): Likewise.
114617 2009-02-22  Bruno Haible  <bruno@clisp.org>
114619         * lib/uninorm/u-normalize-internal.h (FUNC): At the end, handle
114620         zero-length results and shrink excess allocated memory.
114621         * tests/uninorm/test-u8-nfc.c (test_u8_nfc): Check empty string result.
114622         * tests/uninorm/test-u8-nfd.c (test_u8_nfd): Likewise.
114623         * tests/uninorm/test-u8-nfkc.c (test_u8_nfkc): Likewise.
114624         * tests/uninorm/test-u8-nfkd.c (test_u8_nfkd): Likewise.
114625         * tests/uninorm/test-u16-nfc.c (test_u16_nfc): Likewise.
114626         * tests/uninorm/test-u16-nfd.c (test_u16_nfd): Likewise.
114627         * tests/uninorm/test-u16-nfkc.c (test_u16_nfkc): Likewise.
114628         * tests/uninorm/test-u16-nfkd.c (test_u16_nfkd): Likewise.
114629         * tests/uninorm/test-u32-nfc.c (test_u32_nfc): Likewise.
114630         * tests/uninorm/test-u32-nfd.c (test_u32_nfd): Likewise.
114631         * tests/uninorm/test-u32-nfkc.c (test_u32_nfkc): Likewise.
114632         * tests/uninorm/test-u32-nfkd.c (test_u32_nfkd): Likewise.
114634 2009-02-21  Bruno Haible  <bruno@clisp.org>
114636         * doc/gnulib.texi: Include safe-alloc.texi earlier.
114637         * doc/safe-alloc.texi: Terminate sentences with a period. Use two
114638         spaces after a period. Put a space between a macro name and its
114639         argument list. Trivial rewordings.
114640         * lib/safe-alloc.c: Include safe-alloc.h right after config.h.
114641         * tests/test-safe-alloc.c: Likewise. Include stdlib.h.
114642         (main): Return 0 explicitly.
114644 2009-02-21  Bruno Haible  <bruno@clisp.org>
114646         Tests for module 'uninorm/filter'.
114647         * tests/uninorm/test-uninorm-filter-nfc.c: New file.
114648         * modules/uninorm/filter-tests: New file.
114650         New module 'uninorm/filter'.
114651         * lib/uninorm.h (uninorm_filter_create, uninorm_filter_write,
114652         uninorm_filter_flush, uninorm_filter_free): New declarations.
114653         * lib/uninorm/uninorm-filter.c: New file.
114654         * modules/uninorm/filter: New file.
114656 2009-02-21  Bruno Haible  <bruno@clisp.org>
114658         Tests for module 'uninorm/nfkc'.
114659         * tests/uninorm/test-nfkc.c: New file.
114660         * tests/uninorm/test-u8-nfkc.c: New file.
114661         * tests/uninorm/test-u16-nfkc.c: New file.
114662         * tests/uninorm/test-u32-nfkc.c: New file.
114663         * tests/uninorm/test-u32-nfkc-big.sh: New file.
114664         * tests/uninorm/test-u32-nfkc-big.c: New file.
114665         * modules/uninorm/nfkc-tests: New file.
114667         New module 'uninorm/nfkc'.
114668         * lib/uninorm/nfkc.c: New file.
114669         * modules/uninorm/nfkc: New file.
114671         Tests for module 'uninorm/nfkd'.
114672         * tests/uninorm/test-nfkd.c: New file.
114673         * tests/uninorm/test-u8-nfkd.c: New file.
114674         * tests/uninorm/test-u16-nfkd.c: New file.
114675         * tests/uninorm/test-u32-nfkd.c: New file.
114676         * tests/uninorm/test-u32-nfkd-big.sh: New file.
114677         * tests/uninorm/test-u32-nfkd-big.c: New file.
114678         * modules/uninorm/nfkd-tests: New file.
114680         New module 'uninorm/nfkd'.
114681         * lib/uninorm/nfkd.c: New file.
114682         * modules/uninorm/nfkd: New file.
114684         Tests for module 'uninorm/nfc'.
114685         * tests/uninorm/test-nfc.c: New file.
114686         * tests/uninorm/test-u8-nfc.c: New file.
114687         * tests/uninorm/test-u16-nfc.c: New file.
114688         * tests/uninorm/test-u32-nfc.c: New file.
114689         * tests/uninorm/test-u32-nfc-big.sh: New file.
114690         * tests/uninorm/test-u32-nfc-big.c: New file.
114691         * modules/uninorm/nfc-tests: New file.
114693         New module 'uninorm/nfc'.
114694         * lib/uninorm/nfc.c: New file.
114695         * modules/uninorm/nfc: New file.
114697         Tests for module 'uninorm/nfd'.
114698         * tests/uninorm/test-nfd.c: New file.
114699         * tests/uninorm/test-u8-nfd.c: New file.
114700         * tests/uninorm/test-u16-nfd.c: New file.
114701         * tests/uninorm/test-u32-nfd.c: New file.
114702         * tests/uninorm/test-u32-nfd-big.sh: New file.
114703         * tests/uninorm/test-u32-nfd-big.c: New file.
114704         * tests/uninorm/test-u32-normalize-big.h: New file.
114705         * tests/uninorm/test-u32-normalize-big.c: New file.
114706         * tests/uninorm/NormalizationTest.txt: New file, created from
114707         Unicode 5.1.0 NormalizationTest.txt.
114708         * modules/uninorm/nfd-tests: New file.
114710         New module 'uninorm/nfd'.
114711         * lib/uninorm/nfd.c: New file.
114712         * modules/uninorm/nfd: New file.
114714         New module 'uninorm/u32-normalize'.
114715         * lib/uninorm/u32-normalize.c: New file.
114716         * modules/uninorm/u32-normalize: New file.
114718         New module 'uninorm/u16-normalize'.
114719         * lib/uninorm/u16-normalize.c: New file.
114720         * modules/uninorm/u16-normalize: New file.
114722         New module 'uninorm/u8-normalize'.
114723         * lib/uninorm/u8-normalize.c: New file.
114724         * lib/uninorm/normalize-internal.h: New file.
114725         * lib/uninorm/u-normalize-internal.h: New file.
114726         * modules/uninorm/u8-normalize: New file.
114728         New module 'uninorm/decompose-internal'.
114729         * lib/uninorm/decompose-internal.c: New file.
114730         * modules/uninorm/decompose-internal: New file.
114732         Tests for module 'uninorm/composition'.
114733         * tests/uninorm/test-composition.c: New file.
114734         * modules/uninorm/composition-tests: New file.
114736         New module 'uninorm/composition'.
114737         * lib/uninorm/composition.c: New file.
114738         * lib/uninorm/composition-table.gperf: New file, generated by
114739         gen-uni-tables.
114740         * modules/uninorm/composition: New file.
114742         Tests for module 'uninorm/compat-decomposition'.
114743         * tests/uninorm/test-compat-decomposition.c: New file.
114744         * modules/uninorm/compat-decomposition-tests: New file.
114746         New module 'uninorm/compat-decomposition'.
114747         * lib/uninorm/decompose-internal.h: New file.
114748         * lib/uninorm/compat-decomposition.c: New file.
114749         * modules/uninorm/compat-decomposition: New file.
114751         Tests for module 'uninorm/canonical-decomposition'.
114752         * tests/uninorm/test-canonical-decomposition.c: New file.
114753         * modules/uninorm/canonical-decomposition-tests: New file.
114755         New module 'uninorm/canonical-decomposition'.
114756         * lib/uninorm/canonical-decomposition.c: New file.
114757         * modules/uninorm/canonical-decomposition: New file.
114759         Tests for module 'uninorm/decomposition'.
114760         * tests/uninorm/test-decomposition.c: New file.
114761         * modules/uninorm/decomposition-tests: New file.
114763         New module 'uninorm/decomposition'.
114764         * lib/uninorm/decomposition.c: New file.
114765         * modules/uninorm/decomposition: New file.
114767         New module 'uninorm/decomposition-table'.
114768         * lib/uninorm/decomposition-table.h: New file.
114769         * lib/uninorm/decomposition-table.c: New file.
114770         * lib/uninorm/decomposition-table1.h: New file, generated by
114771         gen-uni-tables.
114772         * lib/uninorm/decomposition-table2.h: New file, generated by
114773         gen-uni-tables.
114774         * modules/uninorm/decomposition-table: New file.
114776         * lib/gen-uni-tables.c (MAX_DECOMP_LENGTH): New macro.
114777         (UC_DECOMP_*): New enumeration items.
114778         (get_decomposition): New function.
114779         (struct decomp_table): New type.
114780         (output_decomposition, output_decomposition_tables): New functions.
114781         (unicode_composition_exclusions): New variable.
114782         (fill_composition_exclusions, debug_output_composition_tables): New
114783         functions.
114784         (main): Accept one more argument. Invoke fill_composition_exclusions.
114785         Output decomposition and composition tables.
114787         New module 'uninorm/base'.
114788         * lib/uninorm.h: New file.
114789         * lib/unictype.h: Update comment.
114790         * modules/uninorm/base: New file.
114792 2009-02-21  David Lutterkort  <lutter@redhat.com>
114794         Tests for module 'safe-alloc'.
114795         * tests/test-safe-alloc.c: New file.
114796         * modules/safe-alloc-tests: New file.
114798         New module 'safe-alloc'.
114799         * lib/safe-alloc.h: New file.
114800         * lib/safe-alloc.c: New file.
114801         * m4/safe-alloc.m4: New file.
114802         * modules/safe-alloc: New file.
114803         * doc/safe-alloc.texi: New file.
114804         * doc/gnulib.texi: Include it.
114805         * MODULES.html.sh (Memory management functions <stdlib.h>): Add
114806         safe-alloc.
114808 2009-02-18  Bruno Haible  <bruno@clisp.org>
114810         Fix link error on non-glibc systems.
114811         * modules/uniwbrk/ulc-wordbreaks-tests (test_ulc_wordbreaks_LDADD): New
114812         variable.
114813         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
114815 2009-02-18  Jim Meyering  <meyering@redhat.com>
114817         fts: avoid used-uninitialized error due to recent change
114818         * lib/fts.c (fts_read): Guard uses of the new member,
114819         parent->fts_n_dirs_remaining, since it's not relevant for
114820         the parent of a directory specified on the command-line.
114822 2009-02-17  James Youngman  <jay@gnu.org>
114823             Bruno Haible  <bruno@clisp.org>
114825         * m4/include_next.m4: Reformulate comment.
114827 2009-02-16  Jim Meyering  <meyering@redhat.com>
114829         fts: add #if guards so that the fts_lgpl module still builds
114830         * lib/fts.c: Guard just-added hash-table-using parts with
114831         #if GNULIB_FTS, so as not to break builds of the fts_lgpl module.
114832         Reported by Simon Josefsson.
114834 2009-02-15  Bruno Haible  <bruno@clisp.org>
114836         * modules/array-mergesort-tests: New file.
114837         * tests/test-array-mergesort.c: New file.
114839         New module 'array-mergesort'.
114840         * modules/array-mergesort: New file.
114841         * lib/array-mergesort.h: New file.
114843 2009-02-15  Bruno Haible  <bruno@clisp.org>
114845         Fix 2009-02-07 commit.
114846         * lib/gen-uni-tables.c (output_predicate, output_category,
114847         output_combclass, output_bidi_category, output_decimal_digit,
114848         output_digit, output_numeric, output_mirror, output_scripts,
114849         output_ident_category, output_simple_mapping): Fix format directives.
114850         (output_lbp, output_wbp): Don't convert -1 to a size_t implicitly.
114852 2009-02-15  Albert Chin-A-Young  <china@thewrittenword.com>
114854         * m4/include_next.m4: Update comment about IBM C 9.0/10.1 bug, now that
114855         fixes are available from IBM.
114857 2009-02-13  Jim Meyering  <meyering@redhat.com>
114859         fts: arrange not to stat non-directories in more cases
114860         This makes GNU find (when it doesn't need to stat each file)
114861         *much* more efficient at traversing reiserfs file systems.
114862         * lib/fts_.h (struct ftsent) [fts_n_dirs_remaining]: New member.
114863         (struct FTS) [fts_leaf_optimization_works_ht]: Add member.
114864         * lib/fts.c (fts_close): Free ->fts_leaf_optimization_works_ht.
114865         (S_MAGIC_REISERFS, S_MAGIC_PROC): Define.
114866         (leaf_optimization_applies): New function.
114867         (LCO_hash, LCO_compare): New helper functions.
114868         (link_count_optimize_ok): New function.
114869         (fts_stat): Initialize new member (if dir).
114870         (fts_read): Decrement parent's fts_n_dirs_remaining count if
114871         we've just stat'ed a directory.  Skip the stat call when possible.
114872         ---
114873         Note this AFS-related exchange:
114874         http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=143111
114875         and note find's pioctl call in find/fstype.c.
114876         But that is necessary only if you want to enable the
114877         optimization for AFS, and for now, I don't.
114879         fts: move a function definition "up" (no semantic change)
114880         * lib/fts.c (dirent_inode_sort_may_be_useful): Move definition
114881         "up" to precede upcoming use of a related function.
114883 2009-02-11  Jim Meyering  <meyering@redhat.com>
114885         fts: correct internal computation of nlinks (optimization-related)
114886         * lib/fts.c (fts_build): ISSET(FTS_NOSTAT) has no bearing on
114887         whether the current entry is a directory, so don't test it.
114889 2009-02-10  Bruno Haible  <bruno@clisp.org>
114891         Tests for module 'uniwbrk/ulc-wordbreaks'.
114892         * modules/uniwbrk/ulc-wordbreaks-tests: New file.
114893         * tests/uniwbrk/test-ulc-wordbreaks.sh: New file.
114894         * tests/uniwbrk/test-ulc-wordbreaks.c: New file.
114896         Tests for module 'uniwbrk/u32-wordbreaks'.
114897         * modules/uniwbrk/u32-wordbreaks-tests: New file.
114898         * tests/uniwbrk/test-u32-wordbreaks.c: New file.
114900         Tests for module 'uniwbrk/u16-wordbreaks'.
114901         * modules/uniwbrk/u16-wordbreaks-tests: New file.
114902         * tests/uniwbrk/test-u16-wordbreaks.c: New file.
114904         Tests for module 'uniwbrk/u8-wordbreaks'.
114905         * modules/uniwbrk/u8-wordbreaks-tests: New file.
114906         * tests/uniwbrk/test-u8-wordbreaks.c: New file.
114908 2009-02-10  Bruno Haible  <bruno@clisp.org>
114910         * modules/uniwbrk/u8-wordbreaks (Depends-on): Add uniwbrk/wordbreak
114911         property.
114912         * modules/uniwbrk/u16-wordbreaks (Depends-on): Likewise.
114913         * modules/uniwbrk/u32-wordbreaks (Depends-on): Likewise.
114914         * modules/uniwbrk/ulc-wordbreaks (Depends-on): Add localcharset.
114916 2009-02-10  Simon Josefsson  <simon@josefsson.org>
114918         * m4/sockets.m4: Call AC_C_INLINE since sockets.h now can use
114919         inline keywords.  Reported by Bruno Haible <bruno@clisp.org>.
114921 2009-02-10  Bruno Haible  <bruno@clisp.org>
114923         * lib/unilbrk/lbrktables.h: Renamed from lib/unilbrk/tables.h.
114924         * lib/unilbrk/lbrktables.c: Renamed from lib/unilbrk/tables.c.
114925         * modules/unilbrk/tables (Files, Makefile.am, Include): Update.
114926         * lib/unilbrk/u8-possible-linebreaks.c: Update.
114927         * lib/unilbrk/u16-possible-linebreaks.c: Likewise.
114928         * lib/unilbrk/u32-possible-linebreaks.c: Likewise.
114930 2009-02-09  Simon Josefsson  <simon@josefsson.org>
114932         * lib/sockets.h (gl_fd_to_handle): New function.
114934         * tests/test-sockets.c: Call gl_fd_to_handle.
114936 2009-02-09  Bruno Haible  <bruno@clisp.org>
114938         * doc/havelib.texi: Document the conventions on bi-arch systems.
114940 2009-02-08  Bruno Haible  <bruno@clisp.org>
114942         Document the AC_LIB_LINKFLAGS macro.
114943         * doc/havelib.texi: New file, mostly written on 2005-05-24.
114944         * doc/gnulib.texi: Include it.
114946 2009-02-08  Bruno Haible  <bruno@clisp.org>
114948         Fix wrong order of sections, compared to TOC.
114949         * doc/gnulib.texi: Include relocatable-maint.texi after the
114950         "Regular expressions" node, not before.
114952 2009-02-08  Bruno Haible  <bruno@clisp.org>
114954         Tests for module 'unicase/totitle'.
114955         * modules/unicase/totitle-tests: New file.
114957         Tests for module 'unicase/tolower'.
114958         * modules/unicase/tolower-tests: New file.
114960         Tests for module 'unicase/toupper'.
114961         * modules/unicase/toupper-tests: New file.
114962         * tests/unicase/test-mapping-part1.h: New file.
114963         * tests/unicase/test-mapping-part2.h: New file.
114965         New module 'unicase/totitle'.
114966         * modules/unicase/totitle: New file.
114967         * lib/unicase/totitle.c: New file.
114969         New module 'unicase/tolower'.
114970         * modules/unicase/tolower: New file.
114971         * lib/unicase/tolower.c: New file.
114973         New module 'unicase/toupper'.
114974         * modules/unicase/toupper: New file.
114975         * lib/unicase/toupper.c: New file.
114976         * lib/unicase/simple-mapping.h: New file.
114978         * lib/gen-uni-tables.c (output_simple_mapping_test): New function.
114979         (mapping_table): New structure.
114980         (output_simple_mapping): New function.
114981         (main): Invoke output_simple_mapping_test and output_simple_mapping.
114982         * modules/gen-uni-tables (Description): Update.
114983         * lib/unicase/toupper.h: New file, automatically generated by
114984         gen-uni-tables.
114985         * lib/unicase/tolower.h: New file, automatically generated by
114986         gen-uni-tables.
114987         * lib/unicase/totitle.h: New file, automatically generated by
114988         gen-uni-tables.
114989         * tests/unicase/test-uc_toupper.c: New file, automatically generated by
114990         gen-uni-tables.
114991         * tests/unicase/test-uc_tolower.c: New file, automatically generated by
114992         gen-uni-tables.
114993         * tests/unicase/test-uc_totitle.c: New file, automatically generated by
114994         gen-uni-tables.
114996         New module 'unicase/base'.
114997         * modules/unicase/base: New file.
114998         * lib/unicase.h: New file.
115000 2009-02-08  Bruno Haible  <bruno@clisp.org>
115002         New module 'uniwbrk/ulc-wordbreaks'.
115003         * modules/uniwbrk/ulc-wordbreaks: New file.
115004         * lib/uniwbrk/ulc-wordbreaks.c: New file.
115006         New module 'uniwbrk/u32-wordbreaks'.
115007         * modules/uniwbrk/u32-wordbreaks: New file.
115008         * lib/uniwbrk/u32-wordbreaks.c: New file.
115010         New module 'uniwbrk/u16-wordbreaks'.
115011         * modules/uniwbrk/u16-wordbreaks: New file.
115012         * lib/uniwbrk/u16-wordbreaks.c: New file.
115014         New module 'uniwbrk/u8-wordbreaks'.
115015         * modules/uniwbrk/u8-wordbreaks: New file.
115016         * lib/uniwbrk/u8-wordbreaks.c: New file.
115017         * lib/uniwbrk/u-wordbreaks.h: New file.
115019         New module 'uniwbrk/table'.
115020         * modules/uniwbrk/table: New file.
115021         * lib/uniwbrk/wbrktable.h: New file.
115022         * lib/uniwbrk/wbrktable.c: New file.
115024         New module 'uniwbrk/wordbreak-property'.
115025         * modules/uniwbrk/wordbreak-property: New file.
115026         * lib/uniwbrk/wordbreak-property.c: New file.
115028         * lib/gen-uni-tables.c (WBP_*): New enum items.
115029         (get_wbp, debug_output_wbp, debug_output_wbrk_tables): New functions.
115030         (unicode_org_wbp): New variable.
115031         (fill_org_wbp, debug_output_org_wbp, debug_output_org_wbrk_tables):
115032         New functions.
115033         (wbp_table): New structure.
115034         (output_wbp, output_wbrk_tables): New functions.
115035         (main): Accept additional argument. Invoke fill_org_wbp,
115036         debug_output_wbrk_tables, debug_output_org_wbrk_tables,
115037         output_wbrk_tables.
115038         * modules/gen-uni-tables (Description): Update.
115039         * lib/uniwbrk/wbrkprop.h: New file, automatically generated by
115040         gen-uni-tables.
115042         New module 'uniwbrk/base'.
115043         * modules/uniwbrk/base: New file.
115044         * lib/uniwbrk.h: New file.
115046 2009-02-08  Bruno Haible  <bruno@clisp.org>
115048         Update to Unicode 5.1.0.
115049         * lib/gen-uni-tables.c (is_property_alphabetic): Include
115050         U+2185..U+2188.
115051         (is_property_default_ignorable_code_point): Don't include characters
115052         of category Cc or Cs and not-a-characters.
115053         (get_lbp): Assume REVISION_22. Special handling of U+0609, U+060A,
115054         U+0D79, U+109E, U+109F, U+A60C.
115055         * lib/unictype/bidi_of.h: Regenerated.
115056         * lib/unictype/blocks.h: Regenerated.
115057         * lib/unictype/categ_C.h: Regenerated.
115058         * lib/unictype/categ_Cf.h: Regenerated.
115059         * lib/unictype/categ_Cn.h: Regenerated.
115060         * lib/unictype/categ_L.h: Regenerated.
115061         * lib/unictype/categ_Ll.h: Regenerated.
115062         * lib/unictype/categ_Lm.h: Regenerated.
115063         * lib/unictype/categ_Lo.h: Regenerated.
115064         * lib/unictype/categ_Lu.h: Regenerated.
115065         * lib/unictype/categ_M.h: Regenerated.
115066         * lib/unictype/categ_Mc.h: Regenerated.
115067         * lib/unictype/categ_Me.h: Regenerated.
115068         * lib/unictype/categ_Mn.h: Regenerated.
115069         * lib/unictype/categ_N.h: Regenerated.
115070         * lib/unictype/categ_Nd.h: Regenerated.
115071         * lib/unictype/categ_Nl.h: Regenerated.
115072         * lib/unictype/categ_No.h: Regenerated.
115073         * lib/unictype/categ_P.h: Regenerated.
115074         * lib/unictype/categ_Pd.h: Regenerated.
115075         * lib/unictype/categ_Pe.h: Regenerated.
115076         * lib/unictype/categ_Pf.h: Regenerated.
115077         * lib/unictype/categ_Pi.h: Regenerated.
115078         * lib/unictype/categ_Po.h: Regenerated.
115079         * lib/unictype/categ_Ps.h: Regenerated.
115080         * lib/unictype/categ_S.h: Regenerated.
115081         * lib/unictype/categ_Sk.h: Regenerated.
115082         * lib/unictype/categ_Sm.h: Regenerated.
115083         * lib/unictype/categ_So.h: Regenerated.
115084         * lib/unictype/categ_of.h: Regenerated.
115085         * lib/unictype/combining.h: Regenerated.
115086         * lib/unictype/ctype_alnum.h: Regenerated.
115087         * lib/unictype/ctype_alpha.h: Regenerated.
115088         * lib/unictype/ctype_graph.h: Regenerated.
115089         * lib/unictype/ctype_lower.h: Regenerated.
115090         * lib/unictype/ctype_print.h: Regenerated.
115091         * lib/unictype/ctype_punct.h: Regenerated.
115092         * lib/unictype/ctype_upper.h: Regenerated.
115093         * lib/unictype/decdigit.h: Regenerated.
115094         * lib/unictype/digit.h: Regenerated.
115095         * lib/unictype/mirror.h: Regenerated.
115096         * lib/unictype/numeric.h: Regenerated.
115097         * lib/unictype/pr_alphabetic.h: Regenerated.
115098         * lib/unictype/pr_bidi_arabic_digit.h: Regenerated.
115099         * lib/unictype/pr_bidi_arabic_right_to_left.h: Regenerated.
115100         * lib/unictype/pr_bidi_boundary_neutral.h: Regenerated.
115101         * lib/unictype/pr_bidi_eur_num_terminator.h: Regenerated.
115102         * lib/unictype/pr_bidi_left_to_right.h: Regenerated.
115103         * lib/unictype/pr_bidi_non_spacing_mark.h: Regenerated.
115104         * lib/unictype/pr_bidi_other_neutral.h: Regenerated.
115105         * lib/unictype/pr_combining.h: Regenerated.
115106         * lib/unictype/pr_dash.h: Regenerated.
115107         * lib/unictype/pr_decimal_digit.h: Regenerated.
115108         * lib/unictype/pr_default_ignorable_code_point.h: Regenerated.
115109         * lib/unictype/pr_deprecated.h: Regenerated.
115110         * lib/unictype/pr_diacritic.h: Regenerated.
115111         * lib/unictype/pr_extender.h: Regenerated.
115112         * lib/unictype/pr_format_control.h: Regenerated.
115113         * lib/unictype/pr_grapheme_base.h: Regenerated.
115114         * lib/unictype/pr_grapheme_extend.h: Regenerated.
115115         * lib/unictype/pr_grapheme_link.h: Regenerated.
115116         * lib/unictype/pr_id_continue.h: Regenerated.
115117         * lib/unictype/pr_id_start.h: Regenerated.
115118         * lib/unictype/pr_ideographic.h: Regenerated.
115119         * lib/unictype/pr_ignorable_control.h: Regenerated.
115120         * lib/unictype/pr_lowercase.h: Regenerated.
115121         * lib/unictype/pr_math.h: Regenerated.
115122         * lib/unictype/pr_numeric.h: Regenerated.
115123         * lib/unictype/pr_other_alphabetic.h: Regenerated.
115124         * lib/unictype/pr_other_default_ignorable_code_point.h: Regenerated.
115125         * lib/unictype/pr_other_grapheme_extend.h: Regenerated.
115126         * lib/unictype/pr_other_id_continue.h: Regenerated.
115127         * lib/unictype/pr_other_lowercase.h: Regenerated.
115128         * lib/unictype/pr_other_math.h: Regenerated.
115129         * lib/unictype/pr_punctuation.h: Regenerated.
115130         * lib/unictype/pr_sentence_terminal.h: Regenerated.
115131         * lib/unictype/pr_soft_dotted.h: Regenerated.
115132         * lib/unictype/pr_terminal_punctuation.h: Regenerated.
115133         * lib/unictype/pr_unassigned_code_value.h: Regenerated.
115134         * lib/unictype/pr_unified_ideograph.h: Regenerated.
115135         * lib/unictype/pr_uppercase.h: Regenerated.
115136         * lib/unictype/pr_xid_continue.h: Regenerated.
115137         * lib/unictype/pr_xid_start.h: Regenerated.
115138         * lib/unictype/pr_zero_width.h: Regenerated.
115139         * lib/unictype/scripts.h: Regenerated.
115140         * lib/unictype/scripts_byname.gperf: Regenerated.
115141         * lib/unictype/sy_java_ident.h: Regenerated.
115142         * lib/unilbrk/lbrkprop1.h: Regenerated.
115143         * lib/unilbrk/lbrkprop2.h: Regenerated.
115144         * tests/unictype/test-categ_C.c: Regenerated.
115145         * tests/unictype/test-categ_Cf.c: Regenerated.
115146         * tests/unictype/test-categ_Cn.c: Regenerated.
115147         * tests/unictype/test-categ_L.c: Regenerated.
115148         * tests/unictype/test-categ_Ll.c: Regenerated.
115149         * tests/unictype/test-categ_Lm.c: Regenerated.
115150         * tests/unictype/test-categ_Lo.c: Regenerated.
115151         * tests/unictype/test-categ_Lu.c: Regenerated.
115152         * tests/unictype/test-categ_M.c: Regenerated.
115153         * tests/unictype/test-categ_Mc.c: Regenerated.
115154         * tests/unictype/test-categ_Me.c: Regenerated.
115155         * tests/unictype/test-categ_Mn.c: Regenerated.
115156         * tests/unictype/test-categ_N.c: Regenerated.
115157         * tests/unictype/test-categ_Nd.c: Regenerated.
115158         * tests/unictype/test-categ_Nl.c: Regenerated.
115159         * tests/unictype/test-categ_No.c: Regenerated.
115160         * tests/unictype/test-categ_P.c: Regenerated.
115161         * tests/unictype/test-categ_Pd.c: Regenerated.
115162         * tests/unictype/test-categ_Pe.c: Regenerated.
115163         * tests/unictype/test-categ_Pf.c: Regenerated.
115164         * tests/unictype/test-categ_Pi.c: Regenerated.
115165         * tests/unictype/test-categ_Po.c: Regenerated.
115166         * tests/unictype/test-categ_Ps.c: Regenerated.
115167         * tests/unictype/test-categ_S.c: Regenerated.
115168         * tests/unictype/test-categ_Sk.c: Regenerated.
115169         * tests/unictype/test-categ_Sm.c: Regenerated.
115170         * tests/unictype/test-categ_So.c: Regenerated.
115171         * tests/unictype/test-ctype_alnum.c: Regenerated.
115172         * tests/unictype/test-ctype_alpha.c: Regenerated.
115173         * tests/unictype/test-ctype_graph.c: Regenerated.
115174         * tests/unictype/test-ctype_lower.c: Regenerated.
115175         * tests/unictype/test-ctype_print.c: Regenerated.
115176         * tests/unictype/test-ctype_punct.c: Regenerated.
115177         * tests/unictype/test-ctype_upper.c: Regenerated.
115178         * tests/unictype/test-decdigit.h: Regenerated.
115179         * tests/unictype/test-digit.h: Regenerated.
115180         * tests/unictype/test-numeric.h: Regenerated.
115181         * tests/unictype/test-pr_alphabetic.c: Regenerated.
115182         * tests/unictype/test-pr_bidi_arabic_digit.c: Regenerated.
115183         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Regenerated.
115184         * tests/unictype/test-pr_bidi_boundary_neutral.c: Regenerated.
115185         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Regenerated.
115186         * tests/unictype/test-pr_bidi_left_to_right.c: Regenerated.
115187         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Regenerated.
115188         * tests/unictype/test-pr_bidi_other_neutral.c: Regenerated.
115189         * tests/unictype/test-pr_combining.c: Regenerated.
115190         * tests/unictype/test-pr_dash.c: Regenerated.
115191         * tests/unictype/test-pr_decimal_digit.c: Regenerated.
115192         * tests/unictype/test-pr_default_ignorable_code_point.c: Regenerated.
115193         * tests/unictype/test-pr_deprecated.c: Regenerated.
115194         * tests/unictype/test-pr_diacritic.c: Regenerated.
115195         * tests/unictype/test-pr_extender.c: Regenerated.
115196         * tests/unictype/test-pr_format_control.c: Regenerated.
115197         * tests/unictype/test-pr_grapheme_base.c: Regenerated.
115198         * tests/unictype/test-pr_grapheme_extend.c: Regenerated.
115199         * tests/unictype/test-pr_grapheme_link.c: Regenerated.
115200         * tests/unictype/test-pr_id_continue.c: Regenerated.
115201         * tests/unictype/test-pr_id_start.c: Regenerated.
115202         * tests/unictype/test-pr_ideographic.c: Regenerated.
115203         * tests/unictype/test-pr_ignorable_control.c: Regenerated.
115204         * tests/unictype/test-pr_lowercase.c: Regenerated.
115205         * tests/unictype/test-pr_math.c: Regenerated.
115206         * tests/unictype/test-pr_numeric.c: Regenerated.
115207         * tests/unictype/test-pr_other_alphabetic.c: Regenerated.
115208         * tests/unictype/test-pr_other_default_ignorable_code_point.c:
115209         Regenerated.
115210         * tests/unictype/test-pr_other_grapheme_extend.c: Regenerated.
115211         * tests/unictype/test-pr_other_id_continue.c: Regenerated.
115212         * tests/unictype/test-pr_other_lowercase.c: Regenerated.
115213         * tests/unictype/test-pr_other_math.c: Regenerated.
115214         * tests/unictype/test-pr_punctuation.c: Regenerated.
115215         * tests/unictype/test-pr_sentence_terminal.c: Regenerated.
115216         * tests/unictype/test-pr_soft_dotted.c: Regenerated.
115217         * tests/unictype/test-pr_terminal_punctuation.c: Regenerated.
115218         * tests/unictype/test-pr_unassigned_code_value.c: Regenerated.
115219         * tests/unictype/test-pr_unified_ideograph.c: Regenerated.
115220         * tests/unictype/test-pr_uppercase.c: Regenerated.
115221         * tests/unictype/test-pr_xid_continue.c: Regenerated.
115222         * tests/unictype/test-pr_xid_start.c: Regenerated.
115223         * tests/unictype/test-pr_zero_width.c: Regenerated.
115225         Update to Unicode 5.1.0.
115226         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0487,
115227         U+0616..U+061A, U+0A51, U+0A75, U+0B44, U+0B62..U+0B63, U+0C62..U+0C63,
115228         U+0D44, U+0D62..U+0D63, U+1033..U+1035, U+103A, U+103D..U+103E,
115229         U+105E..U+1060, U+1071..U+1074, U+1082, U+1085..U+1086, U+108D,
115230         U+1B80..U+1B81, U+1BA2..U+1BA5, U+1BA8..U+1BA9, U+1C2C..U+1C33,
115231         U+1C36..U+1C37, U+1DCB..U+1DE6, U+2064, U+20F0, U+2DE0..U+2DFF,
115232         U+A66F..U+A672, U+A67C..U+A67D, U+A8C4, U+A926..U+A92D, U+A947..U+A951,
115233         U+AA29..U+AA2E, U+AA31..U+AA32, U+AA35..U+AA36, U+AA43, U+AA4C,
115234         U+FE24..U+FE26, U+101FD. Remove U+1929..U+192B.
115235         (nonspacing_table_ind): Update.
115236         * tests/uniwidth/test-uc_width2.sh: Update expected result.
115238         Update to Unicode 5.1.0.
115239         * lib/uniname/gen-uninames.lisp (main): Add the range 0x1Fxxx to the
115240         code transform.
115241         * lib/uniname/uniname.c (unicode_character_name,
115242         unicode_name_character): Add the range 0x1Fxxx to the code transform.
115243         * lib/uniname/uninames.h: Regenerated.
115244         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.1.0.
115246 2009-02-07  Bruno Haible  <bruno@clisp.org>
115248         Merge gen-ctype and gen-lbrk into a single program.
115249         * lib/gen-uni-tables.c: New file, incorporating
115250         lib/unictype/gen-ctype.c and lib/unilbrk/gen-lbrk.c.
115251         Add directory prefixes to the names of the generated files.
115252         * lib/unictype/gen-ctype.c: Remove file.
115253         * lib/unilbrk/gen-lbrk.c: Remove file.
115254         * modules/gen-uni-tables: New file.
115255         * modules/unictype/gen-ctype: Remove file.
115256         * modules/unilbrk/gen-lbrk: Remove file.
115258 2009-02-07  Bruno Haible  <bruno@clisp.org>
115260         * lib/unistr.h (u8_strcoll, u16_strcoll, u32_strcoll): New declations.
115262         New module 'unistr/u32-strcoll'.
115263         * modules/unistr/u32-strcoll: New file.
115264         * lib/unistr/u32-strcoll.c: New file.
115266         New module 'unistr/u16-strcoll'.
115267         * modules/unistr/u16-strcoll: New file.
115268         * lib/unistr/u16-strcoll.c: New file.
115270         New module 'unistr/u8-strcoll'.
115271         * modules/unistr/u8-strcoll: New file.
115272         * lib/unistr/u8-strcoll.c: New file.
115273         * lib/unistr/u-strcoll.h: New file.
115275 2009-02-07  Bruno Haible  <bruno@clisp.org>
115277         * test-mbrtowc4.sh (LOCALE_ZH_CN): Fix default value.
115278         * test-mbsnrtowcs4.sh (LOCALE_ZH_CN): Likewise.
115279         * test-mbsrtowcs4.sh (LOCALE_ZH_CN): Likewise.
115280         * test-wcrtomb.sh (LOCALE_ZH_CN): Likewise.
115281         * test-wcsnrtombs4.sh (LOCALE_ZH_CN): Likewise.
115282         * test-wcsrtombs4.sh (LOCALE_ZH_CN): Likewise.
115284 2009-02-07  Bruno Haible  <bruno@clisp.org>
115286         Make 64-bit clean.
115287         * lib/unictype/gen-ctype.c (output_predicate, output_category,
115288         output_combclass, output_bidi_category, output_decimal_digit,
115289         output_digit, output_numeric, output_mirror, output_scripts,
115290         output_ident_category): Use proper width specifier in format strings.
115292 2009-02-07  Bruno Haible  <bruno@clisp.org>
115294         * doc/posix-functions/dirfd.texi: Clarify situation on mingw. Document
115295         failure behaviour.
115297 2009-02-07  Jim Meyering  <meyering@redhat.com>
115299         regex: avoid compilation failure with upcoming gcc-4.4
115300         * lib/regex_internal.h: Revert e48d8b47fb3eee81d341b71c3e006efe9e3433a7
115301         [workaround for PGC prior to 6.1-2].  Otherwise, we'd get this:
115302         "... error: integer overflow in preprocessor expression".
115304 2009-02-05  Ben Pfaff  <blp@gnu.org>
115306         Fix link errors on Windows when close module is used.
115307         * modules/close: Add $(LIB_CLOSE) to Link section.
115308         * m4/close.m4 (gl_REPLACE_CLOSE): Substitute -lws2_32 into
115309         $(LIB_CLOSE) on Windows.
115311 2009-02-05  Jim Meyering  <meyering@redhat.com>
115313         still avoid unused-parameter warnings, but do it cleanly
115314         * lib/fsusage.c (UNUSED_PARAM): Remove definition.
115315         (get_fs_usage): Cast to void instead.
115316         * lib/mountlist.c (UNUSED_PARAM): Remove definition.
115317         (dev_from_mount_options, read_file_system_list): Cast to void.
115318         Prompted by Bruno Haible.
115320 2009-02-04  Jim Meyering  <meyering@redhat.com>
115322         fsusage.c: correct copyright year
115323         * lib/fsusage.c: Reflect year in which the change is pushed into
115325         avoid misc. warnings
115326         * lib/fsusage.c (UNUSED_PARAM): Define.
115327         (get_fs_usage): Mark parameter "disk" as unused.
115328         * lib/getugroups.c (getgrent): Use "void" in prototype.
115329         * lib/mountlist.c: Mark unused parameters.
115330         (read_file_system_list): Declare a local with "const".
115331         * lib/nanosleep.c (getnow): Declare static.
115332         * lib/strftime.c: Include strftime.h, for declaration of nstrftime.
115334         dirfd: set errno upon failure
115335         * lib/dirfd.c: Include <errno.h>.
115336         Set errno to ENOTSUP when returning -1.
115337         * modules/dirfd (Depends-on): Add errno.
115338         Suggested by John Kodis <kodis@comcast.net>.
115340 2009-02-01  Bruno Haible  <bruno@clisp.org>
115342         Don't assume sizeof (long) >= sizeof (void *).
115343         * lib/memcmp.c: Include stdint.h.
115344         (memcmp_bytes): Change argument types to op_t. Change type of srcp1,
115345         srcp2 to 'const byte *'.
115346         (memcmp_common_alignment, memcmp_not_common_alignment): Change argument
115347         types to uintptr_t.
115348         (rpl_memcmp): Change type of srcp1, srcp2 to 'uintptr_t'.
115349         * modules/memcmp (Depends-on): Add stdint.
115350         Reported by Ozkan Sezer <sezeroz@gmail.com>.
115352 2009-01-30  Eric Blake  <ebb9@byu.net>
115354         fix more require-before-expand issues
115355         * m4/pmccabe2html.m4 (gl_PMCCABE2HTML): Require, rather than
115356         expand, AC_PROG_AWK.
115357         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): Use AC_DEFUN_ONCE.
115359 2009-01-28  Eric Blake  <ebb9@byu.net>
115361         version-etc: use consistent URL formatting
115362         * lib/version-etc.c (emit_bug_reporting_address, version_etc_va):
115363         Improve formatting.  Use fputs for string without %.
115365 2009-01-28  Jim Meyering  <meyering@redhat.com>
115367         00gnulib.m4: add m4 quotes in shell comment to avoid autoconf warning
115368         * m4/00gnulib.m4 (AC_DEFUN_ONCE): Add quotes to avoid an
115369         "underquoted definition of NAME" from autoconf-2.59.
115371 2009-01-28  Bruno Haible  <bruno@clisp.org>
115373         * doc/gnulib.texi: Add "Obsolete modules" to index.
115375 2009-01-28  Jim Meyering  <meyering@redhat.com>
115377         useless-if-before-free: recognize more variants
115378         * build-aux/useless-if-before-free: Also recognize e.g.,
115379         if (NULL != p) free (p);
115381 2009-01-27  Mark McLoughlin  <markmc@redhat.com>
115383         test-getaddrinfo: skip (don't fail) this test when there's no network
115384         * tests/test-getaddrinfo.c: Skip test upon failure with EAI_AGAIN,
115385         on the presumption that it means you lack network access.
115387 2009-01-26  Jim Meyering  <meyering@redhat.com>
115389         fflush: avoid warnings on modern systems
115390         * lib/fflush.c (rpl_fflush): Move declarations of locals,
115391         pos and result, into scopes where they're used.
115393 2009-01-26  Eric Blake  <ebb9@byu.net>
115395         Silence warning reintroduced by recent extensions patch.
115396         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS)
115397         (gl_USE_SYSTEM_EXTENSIONS): Use AC_DEFUN_ONCE to silence newer
115398         autoconf.
115400         Backport improved autoconf semantics of AC_DEFUN_ONCE.
115401         * m4/00gnulib.m4: New file.
115402         * gnulib-tool (func_get_filelist): Always use it.
115403         * m4/gnulib-common.m4 (gl_COMMON): Force the file to be used.
115404         Reported by Bruno Haible, with suggestions from Paolo Bonzini.
115406 2009-01-25  Bruno Haible  <bruno@clisp.org>
115408         Make test-quotearg work on MacOS X and AIX.
115409         * tests/test-quotearg.sh: New file.
115410         * tests/locale/fr/LC_MESSAGES/test-quotearg.po: New file.
115411         * tests/locale/fr/LC_MESSAGES/test-quotearg.mo: New file.
115412         * tests/test-quotearg.c: Include <locale.h> and gettext.h. Don't
115413         include <libintl.h>.
115414         (fake_locale): Remove variable.
115415         (gettext, dgettext, dcgettext): Remove functions.
115416         (main): Instead of setting a fake locale, set a real locale. Call
115417         textdomain and bindtextdomain.
115418         * modules/quotearg-tests (Files): Add the new files.
115419         (Depends-on): Add gettext, setenv, unsetenv.
115420         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
115421         (Makefile.am): Add test-quotearg.sh to TESTS, remove test-quotearg.
115422         Augment TESTS_ENVIRONMENT.
115424 2009-01-25  Bruno Haible  <bruno@clisp.org>
115426         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove special code that hid the
115427         fr_FR.ISO8859-1 locale on MacOS X.
115428         * m4/locale-ja.m4 (gt_LOCALE_JA): Remove special code that hid the
115429         ja_JP.eucJP locale on MacOS X.
115430         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Remove special code that hid the
115431         zh_CN.GB18030 locale on MacOS X.
115433 2009-01-25  Bruno Haible  <bruno@clisp.org>
115435         Avoid link errors on MacOS X 10.3.
115436         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Add initializer.
115437         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
115439 2009-01-25  Bruno Haible  <bruno@clisp.org>
115441         * lib/pipe.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
115442         * m4/pipe.m4 (gl_PIPE): Remove tests for vfork() based code.
115443         * modules/pipe (Files): Remove m4/posix_spawn.m4.
115444         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
115445         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2,
115446         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
115447         posix_spawnattr_init, posix_spawnattr_setsigmask,
115448         posix_spawnattr_setflags, posix_spawnattr_destroy.
115450         * lib/execute.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
115451         * m4/execute.m4 (gl_EXECUTE): Remove tests for vfork() based code.
115452         * modules/execute (Files): Remove m4/posix_spawn.m4.
115453         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
115454         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
115455         posix_spawnattr_init, posix_spawnattr_setsigmask,
115456         posix_spawnattr_setflags, posix_spawnattr_destroy.
115458 2009-01-25  Bruno Haible  <bruno@clisp.org>
115460         * lib/glthread/threadlib.c: Include <stdlib.h>.
115462 2009-01-25  Bruno Haible  <bruno@clisp.org>
115464         * lib/glthread/threadlib.c (dummy): New declaration.
115466 2009-01-25  Bruno Haible  <bruno@clisp.org>
115468         * lib/mbrtowc.c (mbrtowc): Distinguish invalid and incomplete
115469         multibyte characters also for the GB18030 encoding. Don't crash when
115470         the encoding is unknown and nstate = 0. Needed on OSF/1 5.1.
115472 2009-01-25  Bruno Haible  <bruno@clisp.org>
115474         Avoid redefining 'struct random_data' on OSF/1 5.1.
115475         * lib/stdlib.in.h: Include <random.h> if it exists.
115476         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether <random.h> exists. Set
115477         HAVE_RANDOM_H. Include <random.h> when testing whether
115478         'struct random_data' exists.
115479         * modules/stdlib (Makefile.am): Substitute HAVE_RANDOM_H.
115481 2009-01-25  Bruno Haible  <bruno@clisp.org>
115483         Don't install charset.alias on MacOS X >= 10.3.
115484         * lib/localcharset.c (DARWIN7): New macro.
115485         (get_charset_aliases): Hardcode the result for Darwin7.
115486         * modules/localcharset (install-exec-local): Don't install
115487         charset.alias on MacOS X >= 10.3, if the file does not yet exist.
115489 2009-01-25  Bruno Haible  <bruno@clisp.org>
115491         Don't install charset.alias on mingw and Cygwin.
115492         * modules/localcharset (install-exec-local): Don't install
115493         charset.alias on mingw and Cygwin, if the file does not yet exist.
115494         The result for these platforms is hardcoded in localcharset.c.
115496 2009-01-25  Bruno Haible  <bruno@clisp.org>
115498         Make it possible again to use AC_GNU_SOURCE together with gnulib.
115499         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_GNU_SOURCE
115500         before requiring AC_USE_SYSTEM_EXTENSIONS.
115502 2009-01-25  Jim Meyering  <meyering@redhat.com>
115504         c-strtod: avoid warnings
115505         * lib/c-strtod.c (C_STRTOD): Cast nptr to (char *) to avoid
115506         "assignment discards qualifiers from pointer target type" warnings.
115508 2009-01-24  Bruno Haible  <bruno@clisp.org>
115510         Add support for non-UTF-8 locales on MacOS X.
115511         * lib/config.charset: Add CP1131, ARMSCII-8, PT154 to the list of
115512         canonical encodings. For Darwin 7 and newer, don't map traditional
115513         encodings to UTF-8.
115514         Reported by Vincent Lefevre <vincent@vinc17.org>
115515         at <http://savannah.gnu.org/bugs/?25235>.
115517 2009-01-24  Bruno Haible  <bruno@clisp.org>
115519         * doc/gnulib.texi (Obsolete modules): New section.
115520         Reported by Mike Frysinger <vapier@gentoo.org>.
115522 2009-01-24  Bruno Haible  <bruno@clisp.org>
115524         * doc/Makefile (%.pdf): Clarify where to find texmf.cnf.
115525         (%.dvi): New rule.
115527 2009-01-24  Bruno Haible  <bruno@clisp.org>
115529         * lib/c-strtod.h (c_strtod, c_strtold): Adjust specification.
115530         Reported by Eric Blake.
115532 2009-01-24  Bruno Haible  <bruno@clisp.org>
115534         * lib/c-stack.c (segv_handler): If !HAVE_XSI_STACK_OVERFLOW_HEURISTIC,
115535         set signo = 0 also if info->si_code <= 0. Needed on HP-UX 11.11.
115536         Reported by Gary V. Vaughan <gary@gnu.org>.
115538 2009-01-24  Bruno Haible  <bruno@clisp.org>
115540         * lib/c-strtod.h (c_strtod, c_strtold): Add specification.
115542 2009-01-23  Bruno Haible  <bruno@clisp.org>
115544         Make c-strtod, c-strtold usable in libraries.
115545         * lib/c-strtod.c: Include string.h instead of xalloc.h.
115546         (C_STRTOD): Call strdup instead of xstrdup.
115547         * modules/c-strtod (Depends-on): Add strdup-posix, remove xalloc.
115548         * modules/c-strtold (Depends-on): Likewise.
115549         * doc/c-strtod.texi: Remove the sentence mentioning xalloc_die.
115550         * NEWS: Mention the change.
115551         Reported by Michael Gold <mgold@ncf.ca>.
115553 2009-01-23  Jim Meyering  <meyering@redhat.com>
115555         c-strtod: when ENDPTR is non-NULL, set *ENDPTR in new failure path
115556         * lib/c-strtod.c (C_STRTOD) [LC_ALL_MASKC]: Ensure that when
115557         ENDPTR is non-NULL, *ENDPTR is set to NPTR upon failure.
115559 2009-01-23  Simon Josefsson  <simon@josefsson.org>
115561         * lib/version-etc.c: Add emit_bug_reporting_address, inspired by
115562         GNU CoreUtils.
115563         * lib/version-etc.h: Add prototype for emit_bug_reporting_address.
115564         * modules/version-etc (Description): Update.
115566 2009-01-22  Bruno Haible  <bruno@clisp.org>
115568         Cache the C locale object.
115569         * lib/c-strtod.c (c_locale_cache): New variable.
115570         (c_locale): New function.
115571         (C_STRTOD): Use it, and don't call freelocale.
115572         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOLD): Require AC_C_INLINE.
115573         Suggested by Paolo Bonzini.
115575 2009-01-21  Bruno Haible  <bruno@clisp.org>
115577         * lib/getloadavg.c (getloadavg): Check c_strtod result against error
115578         conditions other than overflow.
115580 2009-01-21  Bruno Haible  <bruno@clisp.org>
115582         * lib/c-strtod.c: Include errno.h.
115583         (C_STRTOD): Check against NULL return from newlocale. Preserve errno
115584         value from STRTOD_L and STRTOD.
115586 2009-01-21  Bruno Haible  <bruno@clisp.org>
115587         and Jim Meyering  <meyering@redhat.com>
115589         nanosleep: skip configure test (fail it) for apple universal builds
115590         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_MULTIARCH. In Apple
115591         universal builds, assume that nanosleep does not work.
115592         * modules/nanosleep (Depends-on): Add multiarch.
115594         mktime: skip configure test (fail it) for apple universal builds
115595         * m4/mktime.m4 (AC_FUNC_MKTIME): Require gl_MULTIARCH. In Apple
115596         universal builds, assume that mktime does not work.
115597         * modules/mktime (Depends-on): Add multiarch.
115599 2009-01-21  Eric Blake  <ebb9@byu.net>
115601         multiarch: avoid expand-before-require warning
115602         * modules/multiarch (configure.ac): Require, rather than expand,
115603         gl_MULTIARCH.
115604         * m4/multiarch.m4 (gl_MULTIARCH_BODY): Merge...
115605         (gl_MULTIARCH): ...into this macro, and use AC_DEFUN_ONCE to
115606         enforce that all clients require it.  Partial reversion of
115607         2008-12-29 patch.
115609         error: avoid expand-before-require warning
115610         * modules/errno (configure.ac): Require, rather than expand,
115611         gl_HEADER_ERRNO_H.
115612         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Merge...
115613         (gl_HEADER_ERRNO_H): ...into this macro, and use AC_DEFUN_ONCE to
115614         enforce that all clients require it.
115616         gnulib-tool: avoid warnings from using obsolete AC_GNU_SOURCE
115617         * gnulib-tool (func_dest_tmpfilename, func_create_testdir): Using
115618         obsolete AC_GNU_SOURCE causes out-of-order expansion; avoid it,
115619         and rely solely on gl_USE_SYSTEM_EXTENSIONS.
115621 2009-01-21  Paolo Bonzini  <bonzini@gnu.org>
115623         Revert:
115624         2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
115626         regex: do not depend on obsolete modules.
115627         * modules/regex: Remove memcmp and memmove.
115629 2009-01-20  Bruno Haible  <bruno@clisp.org>
115631         Make the 'link' module link on Windows NT 4.
115632         * lib/link.c (_WIN32_WINNT): Don't define.
115633         (CreateHardLinkFuncType): New type.
115634         (CreateHardLinkFunc, initialized): New variables.
115635         (initialize): New function.
115636         (link): Invoke CreateHardLink indirectly through the function pointer.
115638 2009-01-20  Bruno Haible  <bruno@clisp.org>
115640         Fix compilation failure on mingw.
115641         * tests/test-link.c (main): Don't assume that EOPNOTSUPP exists.
115643 2009-01-20  Michael Gold  <mgold@ncf.ca>  (tiny change)
115645         * doc/c-strtod.texi: Mention a couple of restrictions.
115647 2009-01-20  Jim Meyering  <meyering@redhat.com>
115649         gettimeofday: move more declarations out of functions
115650         * lib/gettimeofday.c: Move extern declarations of tzset and
115651         gmtime out of containing functions.  Prompted by Bruno Haible.
115653 2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
115655         regex: do not depend on obsolete modules.
115656         * modules/regex: Remove memcmp and memmove.
115658 2009-01-19  Bruno Haible  <bruno@clisp.org>
115660         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
115661         * modules/uniconv/u16-conv-from-enc (configure.ac): Require
115662         gl_BIGENDIAN, not AC_C_BIGENDIAN.
115663         * modules/uniconv/u16-conv-to-enc (configure.ac): Likewise.
115664         * modules/uniconv/u16-strconv-to-enc (configure.ac): Likewise.
115666 2009-01-19  Bruno Haible  <bruno@clisp.org>
115668         * tests/test-link.c: Include <errno.h>.
115669         (main): Exit with code 77 when a hard link cannot be created due to
115670         the file system.
115671         * tests/test-link.sh: Skip test when a hard link cannot be created due
115672         to the file system.
115673         Suggested by Eric Blake.
115675 2009-01-19  Martin Lambers  <marlam@marlam.de>
115677         * modules/link-tests: New file.
115678         * tests/test-link.sh: New file.
115679         * tests/test-link.c: New file.
115681 2009-01-19  Eric Blake  <ebb9@byu.net>
115683         doc: mention another function added in cygwin 1.7.0
115684         * doc/glibc-functions/glob_pattern_p.texi (glob_pattern_p):
115685         Another new function in cygwin 1.7.
115687 2009-01-19  Bruno Haible  <bruno@clisp.org>
115689         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
115690         * m4/gnulib-common.m4 (gl_BIGENDIAN): New macro.
115691         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require
115692         gl_BIGENDIAN, not AC_C_BIGENDIAN.
115693         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
115694         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
115695         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
115696         * m4/md4.m4 (gl_MD4): Likewise.
115697         * m4/md5.m4 (gl_MD5): Likewise.
115698         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Likewise.
115699         * m4/sha1.m4 (gl_SHA1): Likewise.
115700         * m4/sha256.m4 (gl_SHA256): Likewise.
115701         * m4/sha512.m4 (gl_SHA512): Likewise.
115703 2009-01-19  Bruno Haible  <bruno@clisp.org>
115705         * modules/uniname/uniname-tests (Depends-on): Add progname.
115706         * tests/uniname/test-uninames.c: Include progname.h.
115707         (main): Call set_program_name.
115709         * modules/unistdio/u8-vsprintf-tests (Depends-on): Add progname.
115710         * tests/unistdio/test-u8-vsprintf1.c: Include progname.h.
115711         (main): Call set_program_name.
115713         * modules/unistdio/u8-vsnprintf-tests (Depends-on): Add progname.
115714         * tests/unistdio/test-u8-vsnprintf1.c: Include progname.h.
115715         (main): Call set_program_name.
115717         * modules/unistdio/u16-vsprintf-tests (Depends-on): Add progname.
115718         * tests/unistdio/test-u16-vsprintf1.c: Include progname.h.
115719         (main): Call set_program_name.
115721         * modules/unistdio/u16-vsnprintf-tests (Depends-on): Add progname.
115722         * tests/unistdio/test-u16-vsnprintf1.c: Include progname.h.
115723         (main): Call set_program_name.
115725         * modules/unistdio/u32-vsprintf-tests (Depends-on): Add progname.
115726         * tests/unistdio/test-u32-vsprintf1.c: Include progname.h.
115727         (main): Call set_program_name.
115729         * modules/unistdio/u32-vsnprintf-tests (Depends-on): Add progname.
115730         * tests/unistdio/test-u32-vsnprintf1.c: Include progname.h.
115731         (main): Call set_program_name.
115733         * modules/unistdio/ulc-vsprintf-tests (Depends-on): Add progname.
115734         * tests/unistdio/test-ulc-vsprintf1.c: Include progname.h.
115735         (main): Call set_program_name.
115737         * modules/unistdio/ulc-vsnprintf-tests (Depends-on): Add progname.
115738         * tests/unistdio/test-ulc-vsnprintf1.c: Include progname.h.
115739         (main): Call set_program_name.
115741 2009-01-19  Eric Blake  <ebb9@byu.net>
115743         test-unistd: test previous patch
115744         * tests/test-unistd.c: Test *_FILENO macros.
115746         unistd: guarantee STDIN_FILENO here, for OS/2 EMX
115747         * lib/unistd.in.h (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
115748         Guarantee a definition.
115749         * doc/posix-headers/unistd.texi (unistd.h): Document the bug.
115750         * modules/unistd-safer (Depends-on): Add dependency on unistd.
115751         * lib/c-stack.c (STDERR_FILENO): Rely on <unistd.h>.
115752         * lib/dup-safer.c (STDERR_FILENO): Likewise.
115753         * lib/execute.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
115754         Likewise.
115755         * lib/fd-safer.c (STDIN_FILENO, STDERR_FILENO): Likewise.
115756         * lib/fopen-safer.c (STDERR_FILENO): Likewise.
115757         * lib/pipe.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
115758         Likewise.
115759         * lib/tmpfile-safer.c (STDERR_FILENO): Likewise.
115760         * tests/test-posix_spawn1.c (STDIN_FILENO, STDOUT_FILENO)
115761         (STDERR_FILENO): Likewise.
115762         * tests/test-posix_spawn2.c (STDIN_FILENO, STDOUT_FILENO)
115763         (STDERR_FILENO): Likewise.
115764         * tests/test-posix_spawn3.c (STDIN_FILENO, STDOUT_FILENO)
115765         (STDERR_FILENO): Likewise.
115766         Reported by Elbert Pol.
115768 2009-01-19  Eric Blake  <ebb9@byu.net>
115770         doc: mention more functions added in cygwin 1.7.0
115771         * doc/posix-functions/abort.texi (abort): Update wording related
115772         to cygwin.
115773         * doc/posix-functions/daylight.texi (daylight): Likewise.
115774         * doc/posix-functions/optarg.texi (optarg): Likewise.
115775         * doc/posix-functions/optarg.texi (opterr): Likewise.
115776         * doc/posix-functions/optarg.texi (optind): Likewise.
115777         * doc/posix-functions/optarg.texi (optopt): Likewise.
115778         * doc/posix-functions/wprintf.texi (wprintf): Cygwin wprintf never
115779         worked in 1.5.x, and was withdrawn in 1.7.
115780         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
115781         * doc/posix-functions/fprintf.texi (fprintf): Tighten mention of
115782         cygwin versions.
115783         * doc/posix-functions/perror.texi (perror): Likewise.
115784         * doc/posix-functions/printf.texi (printf): Likewise.
115785         * doc/posix-functions/snprintf.texi (snprintf): Likewise.
115786         * doc/posix-functions/sprintf.texi (sprintf): Likewise.
115787         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
115788         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
115789         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
115790         * doc/posix-functions/vsprintf.texi (vsprintf): Likewise.
115791         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
115792         Likewise.
115793         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
115794         Likewise.
115795         * doc/glibc-functions/cfmakeraw.texi (cfmakeraw): Cygwin 1.7 adds
115796         this function.
115797         * doc/glibc-functions/in6addr_any.texi (in6addr_any): Likewise.
115798         * doc/glibc-functions/in6addr_loopback.texi (in6addr_loopback):
115799         Likewise.
115800         * doc/glibc-functions/updwtmpx.texi (updwtmpx): Likewise.
115801         * doc/posix-functions/_Exit_C99.texi (_Exit): Likewise.
115802         * doc/posix-functions/confstr.texi (confstr): Likewise.
115803         * doc/posix-functions/dprintf.texi (dprintf): Likewise.
115804         * doc/posix-functions/fgetwc.texi (fgetwc): Likewise.
115805         * doc/posix-functions/fgetws.texi (fgetws): Likewise.
115806         * doc/posix-functions/fputwc.texi (fputwc): Likewise.
115807         * doc/posix-functions/fputws.texi (fputws): Likewise.
115808         * doc/posix-functions/fwide.texi (fwide): Likewise.
115809         * doc/posix-functions/getwc.texi (getwc): Likewise.
115810         * doc/posix-functions/getwchar.texi (getwchar): Likewise.
115811         * doc/posix-functions/putwc.texi (putwc): Likewise.
115812         * doc/posix-functions/putwchar.texi (putwchar): Likewise.
115813         * doc/posix-functions/sigignore.texi (sigignore): Likewise.
115814         * doc/posix-functions/ungetwc.texi (ungetwc): Likewise.
115815         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
115816         * doc/posix-functions/wcpcpy.texi (wcpcpy): Likewise.
115817         * doc/posix-functions/wcpncpy.texi (wcpncpy): Likewise.
115818         * doc/posix-functions/wcstol.texi (wcstol): Likewise.
115819         * doc/posix-functions/wcstoll.texi (wcstoll): Likewise.
115820         * doc/posix-functions/wcstoul.texi (wcstoul): Likewise.
115821         * doc/posix-functions/wcstoull.texi (wcstoull): Likewise.
115822         * doc/posix-functions/wcsxfrm.texi (wcsxfrm): Likewise.
115824 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
115826         ioctl: avoid warning: no previous prototype for 'rpl_ioctl'
115827         * lib/ioctl.c: Include <sys/ioctl.h>.
115829 2009-01-19  Simon Josefsson  <simon@josefsson.org>
115831         * modules/getdate-tests (Depends-on): Add progname.
115832         * tests/test-getdate.c: Use progname module, to avoid link errors
115833         on non-glibc systems.
115835 2009-01-18  Simon Josefsson  <simon@josefsson.org>
115837         * modules/filenamecat-tests (Depends-on): Add progname.
115838         * modules/fstrcmp-tests (Depends-on): Likewise.
115840         * tests/test-filenamecat.c: Use progname module, to avoid link
115841         errors on non-glibc systems.
115842         * tests/test-fstrcmp.c: Likewise.
115844 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
115846         gettimeofday: avoid warning: nested extern declaration of 'localtime'
115847         * lib/gettimeofday.c: Move extern declaration out of function.
115849 2009-01-18  Bruno Haible  <bruno@clisp.org>
115851         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mblen and mbrlen.
115852         * lib/strftime.c (HAVE_MBLEN, HAVE_MBRLEN): Remove macros.
115853         (MULTIBYTE_IS_FORMAT_SAFE): Define to 1 on all platforms except OSF/1.
115855 2009-01-18  Bruno Haible  <bruno@clisp.org>
115857         * lib/strftime.c (MEMPCPY): Remove unused macro.
115858         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mempcpy.
115860 2009-01-18  Martin Lambers  <marlam@marlam.de>
115862         New module 'link'.
115863         * lib/unistd.in.h (link): New declaration.
115864         * lib/link.c: New file.
115865         * m4/link.m4: New file.
115866         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_LINK,
115867         HAVE_LINK.
115868         * modules/unistd (Makefile.am): Substitute GNULIB_LINK, HAVE_LINK.
115869         * modules/link: New file.
115870         * doc/posix-functions/link.texi: Mention the new module.
115872 2009-01-18  Bruno Haible  <bruno@clisp.org>
115874         * tests/test-avltree_list.c (main): Call set_program_name.
115875         * tests/test-avltree_oset.c (main): Likewise.
115876         * tests/test-obstack-printf.c: Include progname.h.
115877         (main): Call set_program_name.
115878         * tests/test-quotearg.c: Include progname.h.
115879         (main): Call set_program_name.
115880         * tests/test-xmemdup0.c: Include progname.h.
115881         (main): Call set_program_name.
115883 2009-01-18  Bruno Haible  <bruno@clisp.org>
115885         New module 'alphasort'.
115886         * lib/dirent.in.h (alphasort): New declaration.
115887         * lib/alphasort.c: New file, from glibc with modifications.
115888         * m4/alphasort.m4: New file.
115889         * modules/alphasort: New file.
115890         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_ALPHASORT,
115891         HAVE_ALPHASORT.
115892         * modules/dirent (Makefile.am): Substitute GNULIB_ALPHASORT,
115893         HAVE_ALPHASORT.
115894         * doc/posix-functions/alphasort.texi: Mention the new module and the
115895         portability problems.
115897 2009-01-18  Bruno Haible  <bruno@clisp.org>
115899         New module 'scandir'.
115900         * lib/dirent.in.h (scandir): New declaration.
115901         * lib/scandir.c: New file, from glibc with modifications.
115902         * m4/scandir.m4: New file.
115903         * modules/scandir: New file.
115904         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_SCANDIR,
115905         HAVE_SCANDIR.
115906         * modules/dirent (Makefile.am): Substitute GNULIB_SCANDIR,
115907         HAVE_SCANDIR.
115908         * doc/posix-functions/scandir.texi: Mention the new module and the
115909         portability problems.
115911 2009-01-17  Bruno Haible  <bruno@clisp.org>
115913         * gnulib-tool (func_remove_prefix): Escape all dots in the prefix.
115914         Update documentation.
115915         (func_remove_suffix): Escape all dots in the suffix. Update
115916         documentation.
115917         (func_filter_filelist): Update documentation.
115918         Reported by Ralf Wildenhues.
115920 2009-01-17  Bruno Haible  <bruno@clisp.org>
115922         * modules/dprintf-posix-tests: New file.
115923         * tests/test-dprintf-posix.sh: New file.
115924         * tests/test-dprintf-posix.c: New file.
115926         New modules 'dprintf', 'dprintf-posix'.
115927         * lib/stdio.in.h (dprintf): New declaration.
115928         * lib/dprintf.c: New file.
115929         * m4/dprintf.m4: New file.
115930         * m4/dprintf-posix.m4: New file.
115931         * modules/dprintf: New file.
115932         * modules/dprintf-posix: New file.
115933         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_DPRINTF,
115934         HAVE_DPRINTF, REPLACE_DPRINTF.
115935         * modules/stdio (Makefile.am): Substitute also GNULIB_DPRINTF,
115936         HAVE_DPRINTF, REPLACE_DPRINTF.
115937         * doc/posix-functions/dprintf.texi: Mention the new modules.
115939 2009-01-17  Bruno Haible  <bruno@clisp.org>
115941         * modules/vdprintf-posix-tests: New file.
115942         * tests/test-vdprintf-posix.sh: New file.
115943         * tests/test-vdprintf-posix.c: New file.
115945         New modules 'vdprintf', 'vdprintf-posix'.
115946         * lib/stdio.in.h (vdprintf): New declaration.
115947         * lib/vdprintf.c: New file.
115948         * m4/vdprintf.m4: New file.
115949         * m4/vdprintf-posix.m4: New file.
115950         * modules/vdprintf: New file.
115951         * modules/vdprintf-posix: New file.
115952         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_VDPRINTF,
115953         HAVE_VDPRINTF, REPLACE_VDPRINTF.
115954         * modules/stdio (Makefile.am): Substitute also GNULIB_VDPRINTF,
115955         HAVE_VDPRINTF, REPLACE_VDPRINTF.
115956         * doc/posix-functions/vdprintf.texi: Mention the new modules.
115958 2009-01-17  Bruno Haible  <bruno@clisp.org>
115960         Fix replacement of fopen on mingw.
115961         * m4/fopen.m4 (gl_FUNC_FOPEN): Define FOPEN_TRAILING_SLASH_BUG also on
115962         mingw.
115964 2009-01-17  Bruno Haible  <bruno@clisp.org>
115966         Fix compilation error on HP-UX 11.00, present since 2008-09-24.
115967         * lib/fopen.c: Include <sys/types.h> and <sys/types.h>.
115969 2009-01-17  Bruno Haible  <bruno@clisp.org>
115971         Avoid test-fflush2.sh failure on mingw.
115972         * tests/test-fflush2.c: Include binary-io.h.
115973         (main): Put standard input into binary mode.
115974         * modules/fflush-tests (Depends-on): Add binary-io.
115976 2009-01-17  Bruno Haible  <bruno@clisp.org>
115978         * lib/wchar.in.h: In another particular situation, include only the
115979         system's <wchar.h> file.
115980         (_GL_ALREADY_INCLUDING_WCHAR_H): New macro.
115981         Reported by Albert Chin-A-Young <china@thewrittenword.com>
115982         and Thomas Guyot-Sionnest <dermoth@aei.ca>.
115984 2009-01-17  Bruno Haible  <bruno@clisp.org>
115986         Support for stripping executables in --enable-relocatable.
115987         * build-aux/install-reloc: Expect one more argument, or an environment
115988         variable RELOC_STRIP_PROG. If set, strip the destination program and
115989         its wrapper.
115990         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV, set
115991         RELOC_STRIP_PROG.
115992         * doc/relocatable-maint.texi (Supporting Relocation): Mention the need
115993         to set RELOCATABLE_STRIP.
115994         * NEWS: Mention the new Makefile requirement.
115996 2009-01-17  Bruno Haible  <bruno@clisp.org>
115998         * build-aux/install-reloc: Remove debugging information left over by
115999         C compiler on MacOS X.
116001 2009-01-17  Bruno Haible  <bruno@clisp.org>
116003         Update use of _NSGetExecutablePath after API change in MacOS X 10.4.
116004         * lib/progreloc.c (find_executable): Fix type of pointer passed to
116005         _NSGetExecutablePath.
116007 2009-01-16  Jim Meyering  <meyering@redhat.com>
116009         strerror: avoid warnings about discarding "const"
116010         * lib/strerror.c (rpl_strerror): Instead of returning a const
116011         string from each and every "case", use a variable, and add a single
116012         cast after the switch.
116014 2009-01-16  Albert Chin-A-Young  <china@thewrittenword.com>
116016         * lib/arpa_inet.in.h: Add extern "C" block for C++.
116018 2009-01-16  Bruno Haible  <bruno@clisp.org>
116020         * m4/printf.m4 (gl_SNPRINTF_SIZE1, gl_VSNPRINTF_ZEROSIZE_C99): Use an
116021         array initializer syntax that also works in C++ mode.
116022         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
116024 2009-01-16  Jim Meyering  <meyering@redhat.com>
116026         poll: suppress a warning
116027         * lib/poll.c: Use #pragma GCC diagnostic ignored "-Wtype-limits"
116028         to ignore "...unsigned expression < 0 is always false" warnings.
116030 2009-01-16  Daniel P. Berrange  <berrange@redhat.com>
116032         poll: remove declarations of unused variables
116033         * lib/poll.c (poll) [WIN32_NATIVE]: Remove declarations of unused
116034         sockbuf and optlen.
116036 2009-01-15  Bruno Haible  <bruno@clisp.org>
116038         Make fflush-after-ungetc POSIX compliant on BSD systems.
116039         * lib/fflush.c (clear_ungetc_buffer_preserving_position): New function.
116040         (clear_ungetc_buffer): Implement also for other systems.
116041         (rpl_fflush): On glibc systems, invoke
116042         clear_ungetc_buffer_preserving_position. Otherwise, invoke
116043         clear_ungetc_buffer after fetching the stream's position, not before.
116045 2009-01-15  Bruno Haible  <bruno@clisp.org>
116047         Make fflush-after-ungetc POSIX compliant on glibc systems.
116048         * m4/fflush.m4 (gl_FUNC_FFLUSH): Test also the behaviour of fflush
116049         after ungetc.
116050         * lib/fflush.c (clear_ungetc_buffer): Implement for glibc systems.
116051         (rpl_fflush): On glibc systems, simply call the system's fflush
116052         function after clearing the ungetc buffer.
116053         * lib/fseeko.c (rpl_fseeko): Don't try to lseek past the end of file.
116054         Instead, lseek only to the end of file, then use the system's fseeko
116055         for the rest. On glibc systems, reset the EOF indicator bit.
116057 2009-01-15  Jim Meyering  <meyering@redhat.com>
116059         openmp.m4: revert quote-adding change, for portability to older autoconf
116060         * m4/openmp.m4: Remove the quotes added on 2009-01-14.
116061         This reverts part of 42d1eda5dcce2d68deab7a642e7f29bcd7144a0d.
116062         Simon Josefsson noticed the problem when using autoconf-2.61.
116064 2009-01-15  Bruno Haible  <bruno@clisp.org>
116066         * tests/test-fflush2.sh: Invoke test-fflush2 twice.
116067         * tests/test-fflush2.c (ASSERT): Always fail.
116068         (main): Add two tests for fflush() after ungetc(), taking into account
116069         the Austin Group's clarification.
116070         Suggested by Eric Blake.
116072 2009-01-15  Albert Chin-A-Young  <china@thewrittenword.com>
116074         mktime.m4: remove K&R-style function prototypes
116075         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove K&R-style function prototypes
116076         for the Sun C++ compiler.
116078 2009-01-14  Bruno Haible  <bruno@clisp.org>
116080         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_WCHAR_H): New macro, defined
116081         while including <wchar.h>.
116082         * lib/wchar.in.h: In two particular situations on HP-UX, include only
116083         the system's <wchar.h> file.
116084         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
116086 2009-01-14  Bruno Haible  <bruno@clisp.org>
116088         * m4/csharp.m4: Don't mention gettext on the serial number line.
116089         * m4/csharpexec.m4: Likewise.
116090         * m4/eaccess.m4: Likewise.
116091         * m4/javaexec.m4: Likewise.
116092         * m4/sig_atomic_t.m4: Likewise.
116093         * m4/tmpdir.m4: Likewise.
116094         * m4/intldir.m4: Bump gettext version.
116095         * m4/lib-ld.m4: Likewise.
116097 2009-01-14  Bruno Haible  <bruno@clisp.org>
116099         * lib/progname.c (set_program_name): Add more comments.
116100         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
116102 2009-01-14  Simon Josefsson  <simon@josefsson.org>
116104         * lib/sys_stat.in.h: Include sys/types.h for nlink_t on systems
116105         were sys/stat.h does not define it.
116107 2009-01-14  Jim Meyering  <meyering@redhat.com>
116109         many *.m4 files: improve m4 quoting
116110         99% of this change was performed by running the following commands:
116111         git ls-files | grep '\.m4$' | xargs perl -pi \
116112           -e 's/(AC_\w+\()([^[()]+?)([,)])/$1\[$2]$3/g;' \
116113           -e 's/(AC_\w+\((?:\[[^,]+?\], ){1})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
116114           -e 's/(AC_\w+\((?:\[[^,]+?\], ){2})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
116115           -e 's/(AC_\w+\((?:\[[^,]+?\], ){3})([^,[()]+?)([,)])/$1\[$2]$3/g'
116116         perl -pi -e 's/\[\.\.\.\]/.../' m4/onceonly.m4
116117         The remainder were to add Copyright dates, increment serial numbers,
116118         undo some changes in comments, exclude m4/intl.m4, and add quotes
116119         around the "1" in ",1" where the unusual spacing prohibited the
116120         above regexps from doing the job.  For more details, see
116121         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16175>.
116122         * m4/acl.m4: Modified.
116123         * m4/afs.m4: Likewise.
116124         * m4/alloca.m4: Likewise.
116125         * m4/argp.m4: Likewise.
116126         * m4/argz.m4: Likewise.
116127         * m4/atexit.m4: Likewise.
116128         * m4/bison-i18n.m4: Likewise.
116129         * m4/bison.m4: Likewise.
116130         * m4/byteswap.m4: Likewise.
116131         * m4/c-stack.m4: Likewise.
116132         * m4/c-strtod.m4: Likewise.
116133         * m4/calloc.m4: Likewise.
116134         * m4/canonicalize-lgpl.m4: Likewise.
116135         * m4/chown.m4: Likewise.
116136         * m4/clock_time.m4: Likewise.
116137         * m4/codeset.m4: Likewise.
116138         * m4/copy-file.m4: Likewise.
116139         * m4/csharp.m4: Likewise.
116140         * m4/csharpcomp.m4: Likewise.
116141         * m4/csharpexec.m4: Likewise.
116142         * m4/d-ino.m4: Likewise.
116143         * m4/d-type.m4: Likewise.
116144         * m4/dirfd.m4: Likewise.
116145         * m4/double-slash-root.m4: Likewise.
116146         * m4/eaccess.m4: Likewise.
116147         * m4/eealloc.m4: Likewise.
116148         * m4/environ.m4: Likewise.
116149         * m4/errno_h.m4: Likewise.
116150         * m4/euidaccess.m4: Likewise.
116151         * m4/execute.m4: Likewise.
116152         * m4/fatal-signal.m4: Likewise.
116153         * m4/fchdir.m4: Likewise.
116154         * m4/fcntl_h.m4: Likewise.
116155         * m4/fileblocks.m4: Likewise.
116156         * m4/filenamecat.m4: Likewise.
116157         * m4/findprog.m4: Likewise.
116158         * m4/flexmember.m4: Likewise.
116159         * m4/fnmatch.m4: Likewise.
116160         * m4/fopen.m4: Likewise.
116161         * m4/fpending.m4: Likewise.
116162         * m4/fprintf-posix.m4: Likewise.
116163         * m4/free.m4: Likewise.
116164         * m4/frexp.m4: Likewise.
116165         * m4/frexpl.m4: Likewise.
116166         * m4/fsusage.m4: Likewise.
116167         * m4/ftruncate.m4: Likewise.
116168         * m4/gc-camellia.m4: Likewise.
116169         * m4/gc-random.m4: Likewise.
116170         * m4/gc.m4: Likewise.
116171         * m4/getaddrinfo.m4: Likewise.
116172         * m4/getcwd-abort-bug.m4: Likewise.
116173         * m4/getcwd-path-max.m4: Likewise.
116174         * m4/getdate.m4: Likewise.
116175         * m4/getdomainname.m4: Likewise.
116176         * m4/getgroups.m4: Likewise.
116177         * m4/gethostname.m4: Likewise.
116178         * m4/gethrxtime.m4: Likewise.
116179         * m4/getline.m4: Likewise.
116180         * m4/getloadavg.m4: Likewise.
116181         * m4/getndelim2.m4: Likewise.
116182         * m4/getpass.m4: Likewise.
116183         * m4/gettext.m4: Likewise.
116184         * m4/gettime.m4: Likewise.
116185         * m4/gettimeofday.m4: Likewise.
116186         * m4/gnulib-common.m4: Likewise.
116187         * m4/group-member.m4: Likewise.
116188         * m4/host-os.m4: Likewise.
116189         * m4/iconv.m4: Likewise.
116190         * m4/iconv_open.m4: Likewise.
116191         * m4/inet_ntop.m4: Likewise.
116192         * m4/inet_pton.m4: Likewise.
116193         * m4/inline.m4: Likewise.
116194         * m4/intldir.m4: Likewise.
116195         * m4/intlmacosx.m4: Likewise.
116196         * m4/intmax.m4: Likewise.
116197         * m4/intmax_t.m4: Likewise.
116198         * m4/inttypes.m4: Likewise.
116199         * m4/inttypes_h.m4: Likewise.
116200         * m4/inttypes-pri.m4: Likewise.
116201         * m4/isapipe.m4: Likewise.
116202         * m4/isnand.m4: Likewise.
116203         * m4/isnanf.m4: Likewise.
116204         * m4/isnanl.m4: Likewise.
116205         * m4/javacomp.m4: Likewise.
116206         * m4/javaexec.m4: Likewise.
116207         * m4/jm-winsz1.m4: Likewise.
116208         * m4/jm-winsz2.m4: Likewise.
116209         * m4/lchown.m4: Likewise.
116210         * m4/lcmessage.m4: Likewise.
116211         * m4/ldexpl.m4: Likewise.
116212         * m4/lib-ld.m4: Likewise.
116213         * m4/lib-link.m4: Likewise.
116214         * m4/libsigsegv.m4: Likewise.
116215         * m4/link-follow.m4: Likewise.
116216         * m4/localcharset.m4: Likewise.
116217         * m4/locale-fr.m4: Likewise.
116218         * m4/locale-ja.m4: Likewise.
116219         * m4/locale-tr.m4: Likewise.
116220         * m4/locale-zh.m4: Likewise.
116221         * m4/lock.m4: Likewise.
116222         * m4/longlong.m4: Likewise.
116223         * m4/ls-mntd-fs.m4: Likewise.
116224         * m4/lstat.m4: Likewise.
116225         * m4/malloc.m4: Likewise.
116226         * m4/mathl.m4: Likewise.
116227         * m4/mbrtowc.m4: Likewise.
116228         * m4/mbstate_t.m4: Likewise.
116229         * m4/mbswidth.m4: Likewise.
116230         * m4/memchr.m4: Likewise.
116231         * m4/memcmp.m4: Likewise.
116232         * m4/memcpy.m4: Likewise.
116233         * m4/memmem.m4: Likewise.
116234         * m4/memmove.m4: Likewise.
116235         * m4/mempcpy.m4: Likewise.
116236         * m4/memrchr.m4: Likewise.
116237         * m4/memset.m4: Likewise.
116238         * m4/minmax.m4: Likewise.
116239         * m4/mkdir-slash.m4: Likewise.
116240         * m4/mkdtemp.m4: Likewise.
116241         * m4/mktime.m4: Likewise.
116242         * m4/mmap-anon.m4: Likewise.
116243         * m4/mountlist.m4: Likewise.
116244         * m4/nanosleep.m4: Likewise.
116245         * m4/nls.m4: Likewise.
116246         * m4/nocrash.m4: Likewise.
116247         * m4/open.m4: Likewise.
116248         * m4/openat.m4: Likewise.
116249         * m4/openmp.m4: Likewise.
116250         * m4/pathmax.m4: Likewise.
116251         * m4/perl.m4: Likewise.
116252         * m4/physmem.m4: Likewise.
116253         * m4/pipe.m4: Likewise.
116254         * m4/po.m4: Likewise.
116255         * m4/poll.m4: Likewise.
116256         * m4/posixtm.m4: Likewise.
116257         * m4/posixver.m4: Likewise.
116258         * m4/printf-frexp.m4: Likewise.
116259         * m4/printf-frexpl.m4: Likewise.
116260         * m4/printf-posix.m4: Likewise.
116261         * m4/printf-posix-rpl.m4: Likewise.
116262         * m4/printf.m4: Likewise.
116263         * m4/progtest.m4: Likewise.
116264         * m4/putenv.m4: Likewise.
116265         * m4/readline.m4: Likewise.
116266         * m4/readlink.m4: Likewise.
116267         * m4/readutmp.m4: Likewise.
116268         * m4/realloc.m4: Likewise.
116269         * m4/regex.m4: Likewise.
116270         * m4/relocatable.m4: Likewise.
116271         * m4/relocatable-lib.m4: Likewise.
116272         * m4/rename-dest-slash.m4: Likewise.
116273         * m4/rename.m4: Likewise.
116274         * m4/rmdir-errno.m4: Likewise.
116275         * m4/rmdir.m4: Likewise.
116276         * m4/roundf.m4: Likewise.
116277         * m4/roundl.m4: Likewise.
116278         * m4/rpmatch.m4: Likewise.
116279         * m4/save-cwd.m4: Likewise.
116280         * m4/selinux-selinux-h.m4: Likewise.
116281         * m4/setenv.m4: Likewise.
116282         * m4/settime.m4: Likewise.
116283         * m4/sig2str.m4: Likewise.
116284         * m4/sig_atomic_t.m4: Likewise.
116285         * m4/signalblocking.m4: Likewise.
116286         * m4/signbit.m4: Likewise.
116287         * m4/sigpipe.m4: Likewise.
116288         * m4/sockets.m4: Likewise.
116289         * m4/sockpfaf.m4: Likewise.
116290         * m4/st_dm_mode.m4: Likewise.
116291         * m4/stat-time.m4: Likewise.
116292         * m4/stdbool.m4: Likewise.
116293         * m4/stdint.m4: Likewise.
116294         * m4/stdint_h.m4: Likewise.
116295         * m4/stpcpy.m4: Likewise.
116296         * m4/stpncpy.m4: Likewise.
116297         * m4/strcase.m4: Likewise.
116298         * m4/strchrnul.m4: Likewise.
116299         * m4/strcspn.m4: Likewise.
116300         * m4/strdup.m4: Likewise.
116301         * m4/strftime.m4: Likewise.
116302         * m4/strndup.m4: Likewise.
116303         * m4/strnlen.m4: Likewise.
116304         * m4/strpbrk.m4: Likewise.
116305         * m4/strptime.m4: Likewise.
116306         * m4/strsep.m4: Likewise.
116307         * m4/strtod.m4: Likewise.
116308         * m4/strtoimax.m4: Likewise.
116309         * m4/strtok_r.m4: Likewise.
116310         * m4/strtol.m4: Likewise.
116311         * m4/strtoll.m4: Likewise.
116312         * m4/strtoul.m4: Likewise.
116313         * m4/strtoull.m4: Likewise.
116314         * m4/strtoumax.m4: Likewise.
116315         * m4/strverscmp.m4: Likewise.
116316         * m4/threadlib.m4: Likewise.
116317         * m4/timegm.m4: Likewise.
116318         * m4/tm_gmtoff.m4: Likewise.
116319         * m4/tmpdir.m4: Likewise.
116320         * m4/tmpfile.m4: Likewise.
116321         * m4/tzset.m4: Likewise.
116322         * m4/uintmax_t.m4: Likewise.
116323         * m4/unlinkdir.m4: Likewise.
116324         * m4/unlocked-io.m4: Likewise.
116325         * m4/uptime.m4: Likewise.
116326         * m4/userspec.m4: Likewise.
116327         * m4/utimbuf.m4: Likewise.
116328         * m4/utime.m4: Likewise.
116329         * m4/utimes-null.m4: Likewise.
116330         * m4/utimes.m4: Likewise.
116331         * m4/vararrays.m4: Likewise.
116332         * m4/vasnprintf.m4: Likewise.
116333         * m4/vfprintf-posix.m4: Likewise.
116334         * m4/vprintf-posix.m4: Likewise.
116335         * m4/wait-process.m4: Likewise.
116336         * m4/wchar_t.m4: Likewise.
116337         * m4/wint_t.m4: Likewise.
116338         * m4/write-any-file.m4: Likewise.
116339         * m4/yield.m4: Likewise.
116341 2009-01-13  Bruno Haible  <bruno@clisp.org>
116343         Avoid test-copy-file.sh failures when ACL support insufficient.
116344         * modules/copy-file-tests (Makefile.am): Pass USE_ACL in
116345         TESTS_ENVIRONMENT.
116346         * tests/test-copy-file.sh: Skip the ACL comparisons if USE_ACL is 0.
116347         Reported by Jim Meyering.
116349 2009-01-13  Bruno Haible  <bruno@clisp.org>
116351         * modules/unistdio/u-printf-args (Files): Add m4/stdint_h.m4 and
116352         m4/inttypes_h.m4, needed by m4/intmax_t.m4.
116353         * modules/unistdio/u8-printf-parse (Files): Likewise.
116354         * modules/unistdio/u32-printf-parse (Files): Likewise.
116355         * modules/unistdio/ulc-printf-parse (Files): Likewise.
116357 2009-01-13  Simon Josefsson  <simon@josefsson.org>
116359         * modules/unistdio/u16-printf-parse (Files): Add m4/stdint_h.m4
116360         and m4/inttypes_h.m4 too.
116362 2009-01-12  Eric Blake  <ebb9@byu.net>
116364         tests: IRIX 6.2 cc can't compile -0.0 into .data
116365         * tests/test-ceill.c (minus_zero): Compute -0.0L at runtime,
116366         rather than at compile-time.
116367         * tests/test-floorl.c (minus_zero): Likewise.
116368         * tests/test-frexpl.c (minus_zero): Likewise.
116369         * tests/test-isnan.c (minus_zerol): Likewise.
116370         * tests/test-isnanl.h (minus_zero): Likewise.
116371         * tests/test-ldexpl.c (minus_zero): Likewise.
116372         * tests/test-roundl.c (minus_zero): Likewise.
116373         * tests/test-signbit.c (minus_zerol): Likewise.
116374         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
116375         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
116376         * tests/test-truncl.c (minus_zero): Likewise.
116377         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
116378         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
116379         Reported by Tom G. Christensen and Nelson H. F. Beebe.
116381 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
116383         regex: fix glibc bug 9697
116384         * lib/regcomp.c (re_compile_fastmap_iter): Rewrite COMPLEX_BRACKET
116385         handling.
116387 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
116389         regex: fix glibc bug 697
116390         * lib/regexec.c (prune_impossible_nodes): Handle sifted_states[0]
116391         being NULL also if there are no backreferences.
116393 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
116395         regex: merge glibc changes
116396         * lib/regcomp.c (re_compile_fastmap_iter): Use __mbrtowc.
116397         * lib/regex_internal.c (build_wcs_buffer, build_wcs_upper_buffer,
116398         re_string_skip_chars, re_string_reconstruct): Likewise.
116399         * lib/regex_internal.h [!_LIBC] (__mbrtowc): New #define.
116401 2009-01-07  Jim Meyering  <meyering@redhat.com>
116403         poll: filter through cppi
116404         * lib/poll.c: Indent cpp directives to reflect nesting.
116406 2009-01-07  Daniel P. Berrange  <berrange@redhat.com>
116408         poll: don't return uninitialized
116409         * lib/poll.c (poll) [WIN32_NATIVE]: Initialize "rc".
116411 2009-01-06  Jeremy Olexa  <darkside@gentoo.org>  (tiny change)
116413         avoid compile failure on AIX 6.1
116414         * lib/getloadavg.c [HAVE_LIBPERFSTAT]: Include <sys/protosw.h>.
116415         Details in http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/15465
116417 2009-01-04  Jim Meyering  <meyering@redhat.com>
116419         remove duplicate inclusion of <stdio.h>
116420         * tests/test-fprintf-posix.c: Likewise.
116421         * tests/test-printf-posix.c: Likewise.
116422         * tests/test-snprintf-posix.c: Likewise.
116423         * tests/test-sprintf-posix.c: Likewise.
116424         * tests/test-vasprintf-posix.c: Likewise.
116425         * tests/test-vfprintf-posix.c: Likewise.
116426         * tests/test-vprintf-posix.c: Likewise.
116427         * tests/test-vsnprintf-posix.c: Likewise.
116428         * tests/test-vsprintf-posix.c: Likewise.
116430 2009-01-03  Jim Meyering  <meyering@redhat.com>
116432         gnulib-tool: fix sed-based filtering
116433         * gnulib-tool (func_filter_filelist): Remove extra backslash
116434         in sed_fff_filter definition.
116436 2009-01-02  Jim Meyering  <meyering@redhat.com>
116438         strftime: avoid compilation failure on Solaris 2.6
116439         * modules/strftime (Depends-on): Add mbrlen and mbsinit.
116440         * lib/strftime.c [DO_MULTIBYTE]: Include <wchar.h> unconditionally.
116441         Don't #define mbrlen or mbsinit, since now they're guaranteed to
116442         be available.  Reported by Tom G. Christensen.  Details in
116443         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16180>.
116445 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
116446             Bruno Haible  <bruno@clisp.org>
116448         Speed up gnulib-tool by doing more string processing through shell
116449         built-ins.
116450         * gnulib-tool (fast_func_append): New variable.
116451         (func_remove_prefix, func_remove_suffix): New functions.
116452         (fast_func_remove_prefix, fast_func_remove_suffix): New variables.
116453         (func_filter_filelist): New function.
116454         (func_get_dependencies): Use func_remove_suffix instead of sed.
116455         (func_get_automake_snippet): Use func_filter_filelist instead of a
116456         subshell and sed invocation.
116458 2009-01-01  Bruno Haible  <bruno@clisp.org>
116460         Fix a security bug.
116461         * gnulib-tool (func_import, import, update): Don't allow the characters
116462         '"', '$', '`', '\' in macro arguments that become part of commands that
116463         are evaluated.
116465 2009-01-01  Bruno Haible  <bruno@clisp.org>
116467         * gnulib-tool (func_reset_sigpipe): Add more comments.
116469 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
116471         * gnulib-tool (func_modules_add_dummy, func_emit_lib_Makefile_am,
116472         func_emit_tests_Makefile_am, func_import): Abort loops early if we
116473         already know the answer.
116475 2009-01-01  Jim Meyering  <meyering@redhat.com>
116477         * lib/version-etc.c (version_etc_va): Update copyright year.
116479 2008-12-30  Bruno Haible  <bruno@clisp.org>
116481         * m4/lib-prefix.m4 (AC_LIB_LINKFLAGS_BODY): Don't overwrite
116482         LIB${NAME}_PREFIX when considering the dependencies of lib${name}.
116483         Reported by Charles Wilson <cygwin@cwilson.fastmail.fm>.
116485 2008-12-29  Eric Blake  <ebb9@byu.net>
116487         multiarch: avoid autoconf AC_REQUIRE bug
116488         * m4/multiarch.m4 (gl_MULTIARCH): Split body...
116489         (gl_MULTIARCH_BODY): ...into new macro, to work around bug in Autoconf
116490         2.63 and older.
116491         Reported by Bruno Haible, and analyzed in
116492         http://lists.gnu.org/r/bug-autoconf/2008-12/msg00039.html
116494 2008-12-29  Bruno Haible  <bruno@clisp.org>
116496         * gnulib-tool (func_import): When generating sed-ignore-removed, handle
116497         files in subdirectories correctly.
116498         Reported by Ralf Wildenhues.
116500 2008-12-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
116502         * gnulib-tool (func_update_ignorelist): Use 'join - FILE'
116503         rather than 'join FILE -', for Solaris join.
116505 2008-12-29  Bruno Haible  <bruno@clisp.org>
116507         * m4/codeset.m4 (AM_LANGINFO_CODESET): More systematic m4 argument
116508         quoting.
116509         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
116510         * m4/glibc2.m4 (gt_GLIBC2): Likewise.
116511         * m4/glibc21.m4 (gl_GLIBC21): Likewise.
116512         * m4/iconv.m4 (AM_ICONV_LINK, AM_ICONV): Likewise.
116513         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
116514         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Likewise.
116515         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Likewise.
116516         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Likewise.
116517         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
116518         * m4/lcmessage.m4 (gt_LC_MESSAGES): Likewise.
116519         * m4/nls.m4 (AM_NLS): Likewise.
116520         * m4/po.m4 (AM_PO_SUBDIRS): Likewise.
116521         * m4/printf-posix.m4 (gt_PRINTF_POSIX): Likewise.
116522         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
116523         * m4/size_max.m4 (gl_SIZE_MAX): Likewise.
116524         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Likewise.
116525         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
116526         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Likewise.
116527         * m4/visibility.m4 (gl_VISIBILITY): Likewise.
116528         * m4/wchar_t.m4 (gt_TYPE_WCHAR_T): Likewise.
116529         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
116530         * m4/xsize.m4 (gl_XSIZE): Likewise.
116531         Suggested by Jim Meyering.
116533 2008-11-17  Bruce Korb  <bkorb@gnu.org>
116535         * lib/parse-duration.h: non-iso form accepts years, months weeks, too
116536         * lib/parse-duration.c: use a switch instead of cascading if's.
116538 2008-12-29  Eric Blake  <ebb9@byu.net>
116540         wchar.h: supply WEOF on Irix 5.3
116541         * lib/wchar.in.h (wint_t): Also supply WEOF.
116542         * lib/wctype.in.h (wint_t): Likewise.
116543         * doc/posix-headers/wchar.texi (wchar.h): Document the bug.
116544         * doc/posix-headers/wctype.texi (wctype.h): Likewise.
116545         Reported by Tom G. Christensen.
116547 2008-12-26  Bruno Haible  <bruno@clisp.org>
116549         * m4/multiarch.m4 (gl_MULTIARCH): Recognize also the architecture names
116550         i486, i586, i686.
116552 2008-12-26  Bruno Haible  <bruno@clisp.org>
116554         * lib/stdlib.in.h (struct random_data): Fix indentation of comments.
116556 2008-12-26  Bruno Haible  <bruno@clisp.org>
116558         * lib/stdint.in.h: Move the include of <wchar.h> down until after all
116559         the types are defined. Also conditionalize it on __STDC_LIMIT_MACROS,
116560         not __STDC_CONSTANT_MACROS.
116561         Reported by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
116563 2008-12-25  Bruno Haible  <bruno@clisp.org>
116565         Add support for universal builds to vasnprintf.
116566         * m4/printf.m4 (gl_PRINTF_ENOMEM): Require gl_MULTIARCH. In Apple
116567         universal builds, guess no.
116568         * modules/vasnprintf-posix (Depends-on): Add multiarch.
116569         * modules/vasprintf-posix (Depends-on): Likewise.
116570         * modules/fprintf-posix (Depends-on): Likewise.
116571         * modules/vfprintf-posix (Depends-on): Likewise.
116572         * modules/snprintf-posix (Depends-on): Likewise.
116573         * modules/vsnprintf-posix (Depends-on): Likewise.
116574         * modules/sprintf-posix (Depends-on): Likewise.
116575         * modules/vsprintf-posix (Depends-on): Likewise.
116576         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
116577         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
116578         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
116579         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
116580         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
116581         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
116582         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
116584         Add support for universal builds to <inttypes.h>.
116585         * lib/inttypes.in.h (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX,
116586         _SCNu64_PREFIX): In Apple
116587         universal builds, define directly, using _LP64.
116588         * m4/inttypes.m4 (gl_INTTYPES_H): In Apple universal builds, set
116589         INT64_MAX_EQ_LONG_MAX and UINT64_MAX_EQ_ULONG_MAX to -1.
116590         * modules/inttypes (Depends-on): Add multiarch.
116591         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
116593         Add support for universal builds to <stdint.h>.
116594         * lib/stdint.in.h (PDFDIFF_MIN, PTRDIFF_MAX, SIZE_MAX): In Apple
116595         universal builds, define directly, using _LP64.
116596         * m4/stdint.m4 (gl_STDINT_TYPE_PROPERTIES): Require gl_MULTIARCH. In
116597         Apple universal builds, don't test for the size and suffix of ptrdiff_t
116598         and size_t.
116599         * modules/stdint (Depends-on): Add multiarch.
116600         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
116602         New module 'multiarch'.
116603         * modules/multiarch: New file.
116604         * m4/multiarch.m4: New file.
116606 2008-12-25  Bruno Haible  <bruno@clisp.org>
116608         * gnulib-tool (func_create_testdir): Avoid failure of mv command.
116610 2008-12-25  Bruno Haible  <bruno@clisp.org>
116612         * modules/btowc (License): Relicense under LGPLv2+.
116613         * modules/mbsinit (License): Likewise.
116614         * modules/mbrtowc (License): Likewise.
116615         * modules/wcrtomb (License): Likewise.
116616         * modules/streq (License): Likewise.
116617         Reported by David Lutterkort <lutter@redhat.com>.
116619 2008-12-23  Bruno Haible  <bruno@clisp.org>
116621         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Fix conditional and comment.
116623 2008-12-23  Bruno Haible  <bruno@clisp.org>
116625         Module getaddrinfo requires linking with $(GETADDRINFO_LIB).
116626         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Put link options into
116627         GETADDRINFO_LIB, not in LIBS.
116628         * modules/getaddrinfo (Link): Set to $(GETADDRINFO_LIB).
116629         * modules/canon-host (Link): Likewise.
116630         * NEWS: Mention the change.
116631         * modules/getaddrinfo-tests (test_getaddrinfo_LDADD): Add the
116632         GETADDRINFO_LIB.
116634 2008-12-22  Bruno Haible  <bruno@clisp.org>
116636         * doc/posix-functions/iswalnum_l.texi: Mention limitation of wchar_t.
116637         * doc/posix-functions/iswalpha_l.texi: Likewise.
116638         * doc/posix-functions/iswblank_l.texi: Likewise.
116639         * doc/posix-functions/iswcntrl_l.texi: Likewise.
116640         * doc/posix-functions/iswctype_l.texi: Likewise.
116641         * doc/posix-functions/iswdigit_l.texi: Likewise.
116642         * doc/posix-functions/iswgraph_l.texi: Likewise.
116643         * doc/posix-functions/iswlower_l.texi: Likewise.
116644         * doc/posix-functions/iswprint_l.texi: Likewise.
116645         * doc/posix-functions/iswpunct_l.texi: Likewise.
116646         * doc/posix-functions/iswspace_l.texi: Likewise.
116647         * doc/posix-functions/iswupper_l.texi: Likewise.
116648         * doc/posix-functions/iswxdigit_l.texi: Likewise.
116649         * doc/posix-functions/mbsnrtowcs.texi: Likewise.
116650         * doc/posix-functions/open_wmemstream.texi: Likewise.
116651         * doc/posix-functions/swscanf.texi: Likewise.
116652         * doc/posix-functions/towctrans_l.texi: Likewise.
116653         * doc/posix-functions/towlower.texi: Likewise.
116654         * doc/posix-functions/towlower_l.texi: Likewise.
116655         * doc/posix-functions/towupper.texi: Likewise.
116656         * doc/posix-functions/towupper_l.texi: Likewise.
116657         * doc/posix-functions/vfwprintf.texi: Likewise.
116658         * doc/posix-functions/vfwscanf.texi: Likewise.
116659         * doc/posix-functions/vswscanf.texi: Likewise.
116660         * doc/posix-functions/vwprintf.texi: Likewise.
116661         * doc/posix-functions/vwscanf.texi: Likewise.
116662         * doc/posix-functions/wcpcpy.texi: Likewise.
116663         * doc/posix-functions/wcpncpy.texi: Likewise.
116664         * doc/posix-functions/wcscasecmp.texi: Likewise.
116665         * doc/posix-functions/wcscasecmp_l.texi: Likewise.
116666         * doc/posix-functions/wcscoll_l.texi: Likewise.
116667         * doc/posix-functions/wcsdup.texi: Likewise.
116668         * doc/posix-functions/wcsncasecmp.texi: Likewise.
116669         * doc/posix-functions/wcsncasecmp_l.texi: Likewise.
116670         * doc/posix-functions/wcsnlen.texi: Likewise.
116671         * doc/posix-functions/wcsnrtombs.texi: Likewise.
116672         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
116673         * doc/posix-functions/wctrans_l.texi: Likewise.
116674         * doc/posix-functions/wctype_l.texi: Likewise.
116675         * doc/glibc-functions/fgetwc_unlocked.texi: Likewise.
116676         * doc/glibc-functions/fgetws_unlocked.texi: Likewise.
116677         * doc/glibc-functions/fputwc_unlocked.texi: Likewise.
116678         * doc/glibc-functions/fputws_unlocked.texi: Likewise.
116679         * doc/glibc-functions/getwc_unlocked.texi: Likewise.
116680         * doc/glibc-functions/getwchar_unlocked.texi: Likewise.
116681         * doc/glibc-functions/putwc_unlocked.texi: Likewise.
116682         * doc/glibc-functions/putwchar_unlocked.texi: Likewise.
116683         * doc/glibc-functions/wcschrnul.texi: Likewise.
116684         * doc/glibc-functions/wcsftime_l.texi: Likewise.
116685         * doc/glibc-functions/wcstod_l.texi: Likewise.
116686         * doc/glibc-functions/wcstof_l.texi: Likewise.
116687         * doc/glibc-functions/wcstol_l.texi: Likewise.
116688         * doc/glibc-functions/wcstold_l.texi: Likewise.
116689         * doc/glibc-functions/wcstoll_l.texi: Likewise.
116690         * doc/glibc-functions/wcstoq.texi: Likewise.
116691         * doc/glibc-functions/wcstoul_l.texi: Likewise.
116692         * doc/glibc-functions/wcstoull_l.texi: Likewise.
116693         * doc/glibc-functions/wcstouq.texi: Likewise.
116694         * doc/glibc-functions/wmempcpy.texi: Likewise.
116696 2008-12-22  Ingo Weinhold  <ingo_weinhold@gmx.de>  (tiny change)
116697             Eric Blake  <ebb9@byu.net>
116698             Paolo Bonzini  <bonzini@gnu.org>
116699             Bruno Haible  <bruno@clisp.org>
116701         Make c-stack work on Haiku.
116702         * lib/c-stack.c (SA_ONSTACK): Define fallback.
116703         (c_stack_action): Use SA_ONSTACK flag.
116705 2008-12-22  Bruno Haible  <bruno@clisp.org>
116707         * m4/locale-fr.m4 (gt_LOCALE_FR_UTF8): Treat Haiku like BeOS.
116709 2008-12-22  Bruno Haible  <bruno@clisp.org>
116711         Work around mbrlen() bugs on AIX, HP-UX, OSF/1, Solaris.
116712         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): Set REPLACE_MBRLEN if mbrtowc is
116713         being overridden.
116714         (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL, gl_MBRLEN_NUL_RETVAL):
116715         New macros.
116716         * lib/wchar.in.h (mbrlen): Override if REPLACE_MBRLEN is set.
116717         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBRLEN.
116718         * modules/wchar (Makefile.am): Substitute REPLACE_MBRLEN.
116719         * doc/posix-functions/mbrlen.texi: Mention the various platform bugs.
116721 2008-12-22  Bruno Haible  <bruno@clisp.org>
116723         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Remove unused variable
116724         from test code.
116726 2008-12-22  Eric Blake  <ebb9@byu.net>
116728         Avoid gcc warnings on cygwin.
116729         * lib/regex_internal.c (re_string_reconstruct) [!RE_ENABLE_I18N]:
116730         Avoid unused variable.
116731         * lib/regexec.c (check_arrival_add_next_nodes) [!RE_ENABLE_I18N]:
116732         Likewise.
116734 2008-12-22  Bruno Haible  <bruno@clisp.org>
116736         Remove HAVE_MBRTOWC conditionals.
116737         * lib/mbscasecmp.c: Include mbuiter.h unconditionally.
116738         (mbscasecmp): Assume mbrtowc function.
116739         * lib/mbscasestr.c: Include mbuiter.h unconditionally.
116740         (knuth_morris_pratt_multibyte, mbscasestr): Assume mbrtowc function.
116741         * lib/mbschr.c: Include mbuiter.h unconditionally.
116742         (mbschr): Assume mbrtowc function.
116743         * lib/mbscspn.c: Include mbuiter.h unconditionally.
116744         (mbscspn): Assume mbrtowc function.
116745         * lib/mbslen.c: Include mbuiter.h unconditionally.
116746         (mbslen): Assume mbrtowc function.
116747         * lib/mbsncasecmp.c: Include mbuiter.h unconditionally.
116748         (mbsncasecmp): Assume mbrtowc function.
116749         * lib/mbsnlen.c: Include mbiter.h unconditionally.
116750         (mbsnlen): Assume mbrtowc function.
116751         * lib/mbspbrk.c: Include mbuiter.h unconditionally.
116752         (mbspbrk): Assume mbrtowc function.
116753         * lib/mbspcasecmp.c: Include mbuiter.h unconditionally.
116754         (mbspcasecmp): Assume mbrtowc function.
116755         * lib/mbsrchr.c: Include mbuiter.h unconditionally.
116756         (mbsrchr): Assume mbrtowc function.
116757         * lib/mbssep.c: Include mbuiter.h unconditionally.
116758         (mbssep): Assume mbrtowc function.
116759         * lib/mbsspn.c: Include mbuiter.h unconditionally.
116760         (mbsspn): Assume mbrtowc function.
116761         * lib/mbsstr.c: Include mbuiter.h unconditionally.
116762         (knuth_morris_pratt_multibyte, mbsstr): Assume mbrtowc function.
116763         * lib/mbstok_r.c: Include mbuiter.h unconditionally.
116764         (mbstok_r): Assume mbrtowc function.
116765         * lib/propername.c: Include mbuiter.h unconditionally.
116766         (mbsstr_trimmed_wordbounded): Assume mbrtowc function.
116767         * lib/trim.c: Include mbchar.h, mbiter.h unconditionally.
116768         (trim2): Assume mbrtowc function.
116769         * lib/mbswidth.c (mbsinit): Remove fallback definition.
116770         (mbsnwidth): Assume mbrtowc function.
116771         * modules/mbswidth (Depends-on): Add mbrtowc, mbsinit.
116772         * lib/quotearg.c (MB_CUR_MAX, mbstate_t, mbrtowc, iswprint): Remove
116773         fallback definitions.
116774         * modules/quotearg (Depends-on): Add mbrtowc, mbsinit.
116776 2008-12-22  Bruno Haible  <bruno@clisp.org>
116778         * doc/posix-functions/mbtowc.texi: Mention a glibc bug.
116780 2008-12-22  Paolo Bonzini  <bonzini@gnu.org>
116782         * modules/regex: Request emulations for the mb*/wc* functions we need.
116783         * m4/regex.m4: Don't look for those functions here.
116784         * lib/regex_internal.h: Do not check HAVE_WCRTOMB and HAVE_MBRTOWC.
116786 2008-12-22  Bruno Haible  <bruno@clisp.org>
116788         * modules/fnmatch (Depends-on): Remove duplicated dependency.
116790 2008-12-21  Bruno Haible  <bruno@clisp.org>
116792         Make mbiter.h, mbuiter.h, mbfile.h usable unconditionally.
116793         * modules/mbiter (Depends-on): Add mbrtowc, mbsinit.
116794         (Include): Remove conditionalization.
116795         * modules/mbuiter (Depends-on): Add mbrtowc, mbsinit.
116796         (Include): Remove conditionalization.
116797         * modules/mbfile (Depends-on): Add mbrtowc, mbsinit.
116798         (Include): Remove conditionalization.
116799         * m4/mbiter.m4 (gl_MBITER): Deprecate the use of AC_FUNC_MBRTOWC.
116800         * m4/mbfile.m4 (gl_MBFILE): Likewise.
116801         * NEWS: Mention the change.
116802         Reported by Alan Hourihane <alanh@fairlite.co.uk>
116803         via Sergey Poznyakoff <gray@gnu.org.ua>.
116805 2008-12-21  Bruno Haible  <bruno@clisp.org>
116807         * MODULES.html.sh (Extended multibyte and wide character utilities
116808         <wchar.h>): Add btowc, wctob, mbsinit, mbrlen, mbrtowc, mbsrtowcs,
116809         wcrtomb, wcsrtombs.
116810         (Support for systems lacking POSIX:2008): Add accept, bind, close,
116811         connect, fclose, getpeername, getsockname, getsockopt, hostent, listen,
116812         mbsnrtowcs, posix_spawn*, recv, recvfrom, sched, select, send, sendto,
116813         setsockopt, shutdown, socket, spawn, sys_wait, wcsnrtombs, write.
116815 2008-12-21  Bruno Haible  <bruno@clisp.org>
116817         * MODULES.html.sh: Change section titles to refer to POSIX:2008.
116819 2008-12-21  Bruno Haible  <bruno@clisp.org>
116821         * modules/wcsnrtombs-tests: New file.
116822         * tests/test-wcsnrtombs1.sh: New file.
116823         * tests/test-wcsnrtombs2.sh: New file.
116824         * tests/test-wcsnrtombs3.sh: New file.
116825         * tests/test-wcsnrtombs4.sh: New file.
116826         * tests/test-wcsnrtombs.c: New file.
116828         New module 'wcsnrtombs'.
116829         * lib/wchar.in.h (wcsnrtombs): New declaration.
116830         * lib/wcsnrtombs.c: New file.
116831         * lib/wcsrtombs-state.c: New file.
116832         * lib/wcsrtombs.c: Refer to _gl_wcsrtombs_state.
116833         (internal_state): Remove variable.
116834         * m4/wcsnrtombs.m4: New file.
116835         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): Add wcsrtombs-state.c to the
116836         compilation units.
116837         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNRTOMBS,
116838         HAVE_WCSNRTOMBS.
116839         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNRTOMBS,
116840         HAVE_WCSNRTOMBS.
116841         * modules/wcsnrtombs: New file.
116842         * modules/wcsrtombs (Files): Add lib/wcsrtombs-state.c.
116843         * doc/posix-functions/wcsnrtombs.texi: Mention the new module.
116845 2008-12-21  Bruno Haible  <bruno@clisp.org>
116847         * modules/wcsrtombs-tests: New file.
116848         * tests/test-wcsrtombs1.sh: New file.
116849         * tests/test-wcsrtombs2.sh: New file.
116850         * tests/test-wcsrtombs3.sh: New file.
116851         * tests/test-wcsrtombs4.sh: New file.
116852         * tests/test-wcsrtombs.c: New file.
116854         New module 'wcsrtombs'.
116855         * lib/wchar.in.h (wcsrtombs): New declaration.
116856         * lib/wcsrtombs.c: New file.
116857         * m4/wcsrtombs.m4: New file.
116858         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSRTOMBS,
116859         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
116860         * modules/wchar (Makefile.am): Substitute GNULIB_WCSRTOMBS,
116861         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
116862         * modules/wcsrtombs: New file.
116863         * doc/posix-functions/wcsrtombs.texi: Mention the new module and the
116864         bugs.
116866 2008-12-21  Bruno Haible  <bruno@clisp.org>
116868         Work around a wcrtomb() bug on Solaris 10 and OSF/1 5.1.
116869         * lib/wchar.in.h (wcrtomb): Override if REPLACE_WCRTOMB is set.
116870         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Test the return value of wcrtomb
116871         with NULL destination argument in various locales. Set REPLACE_WCRTOMB
116872         if not correct.
116873         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCRTOMB.
116874         * modules/wchar (Makefile.am): Substitute REPLACE_WCRTOMB.
116875         * modules/wcrtomb (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
116876         m4/locale-zh.m4, m4/codeset.m4.
116877         * doc/posix-functions/wcrtomb.texi: Document the bug.
116879 2008-12-21  Bruno Haible  <bruno@clisp.org>
116881         Work around a btowc() bug on IRIX 6.5.
116882         * lib/wchar.in.h (btowc): Override if REPLACE_BTOWC is set.
116883         * m4/btowc.m4 (gl_FUNC_BTOWC): Test whether btowc(EOF) is correct. Set
116884         REPLACE_WTOBC if not.
116885         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_BTOWC.
116886         * modules/wchar (Makefile.am): Substitute REPLACE_BTOWC.
116887         * doc/posix-functions/btowc.texi: Mention the IRIX bug.
116889 2008-12-21  Bruno Haible  <bruno@clisp.org>
116891         * modules/wcrtomb-tests: New file.
116892         * tests/test-wcrtomb.sh: New file.
116893         * tests/test-wcrtomb.c: New file.
116895         New module 'wcrtomb'.
116896         * lib/wchar.in.h (wcrtomb): New declaration.
116897         * lib/wcrtomb.c: New file.
116898         * m4/wcrtomb.m4: New file.
116899         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCRTOMB,
116900         HAVE_WCRTOMB.
116901         * modules/wchar (Makefile.am): Substitute GNULIB_WCRTOMB,
116902         HAVE_WCRTOMB.
116903         * modules/wcrtomb: New file.
116904         * doc/posix-functions/wcrtomb.texi: Mention the new module.
116906 2008-12-21  Bruno Haible  <bruno@clisp.org>
116908         * modules/mbrtowc (Files): Add m4/codeset.m4, needed by m4/locale-fr.m4.
116909         * modules/mbsrtowcs (Files): Likewise.
116910         * modules/wctob (Files): Likewise.
116911         * modules/c-strcase-tests (Files): Likewise.
116912         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
116913         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
116914         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
116915         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
116916         * modules/vasnprintf-posix-tests (Files): Likewise.
116918 2008-12-21  William Pursell  <bill.pursell@gmail.com>
116920         gitlog-to-changelog: pass all command-line arguments to git-log
116921         * build-aux/gitlog-to-changelog: When producing a ChangeLog,
116922         it is sometimes convenient to filter the commits in various ways.
116923         gitlog-to-changelog only allows --since to specify a start date,
116924         but git-log itself supports many other filtering mechanisms.
116925         At the moment, I want to filter by branch name.  Rather than
116926         adding a --branch option to gitlog-to-changelog, it seems more
116927         flexible to simply pass all options directly to git-log and let
116928         git do the work.  Notice that this effectively makes --since a
116929         redundant option for gitlog-to-changelog, but removing it would
116930         require current usage to change since calls would then require
116931         an additional '--'.
116933 2008-12-21  Bruno Haible  <bruno@clisp.org>
116935         * modules/mbsnrtowcs-tests: New file.
116936         * tests/test-mbsnrtowcs1.sh: New file.
116937         * tests/test-mbsnrtowcs2.sh: New file.
116938         * tests/test-mbsnrtowcs3.sh: New file.
116939         * tests/test-mbsnrtowcs4.sh: New file.
116940         * tests/test-mbsnrtowcs.c: New file.
116942         New module 'mbsnrtowcs'.
116943         * lib/wchar.in.h (mbsnrtowcs): New declaration.
116944         * lib/mbsnrtowcs.c: New file.
116945         * lib/mbsrtowcs-state.c: New file.
116946         * lib/mbsrtowcs.c: Refer to _gl_mbsrtowcs_state.
116947         (internal_state): Remove variable.
116948         * m4/mbsnrtowcs.m4: New file.
116949         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Add mbsrtowcs-state.c to the
116950         compilation units.
116951         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSNRTOWCS,
116952         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
116953         * modules/wchar (Makefile.am): Substitute GNULIB_MBSNRTOWCS,
116954         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
116955         * modules/mbsnrtowcs: New file.
116956         * modules/mbsrtowcs (Files): Add lib/mbsrtowcs-state.c.
116957         * doc/posix-functions/mbsnrtowcs.texi: Mention the new module and a
116958         portability problem.
116960 2008-12-21  Bruno Haible  <bruno@clisp.org>
116962         Work around mbsrtowcs bug.
116963         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): New macro.
116964         (gl_FUNC_MBSRTOWCS): Invoke it.
116965         * modules/mbsrtowcs (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
116966         m4/locale-zh.m4.
116967         * doc/posix-functions/mbsrtowcs.texi: Document the bug.
116969 2008-12-21  Bruno Haible  <bruno@clisp.org>
116971         * tests/test-mbsrtowcs.c (main): Execute the loop also for unlimited=1.
116973 2008-12-21  Bruno Haible  <bruno@clisp.org>
116975         Update doc for AIX.
116976         * doc/pastposix-functions/wcswcs.texi: Mention that AIX has only a
116977         16-bit wchar_t type.
116978         * doc/posix-functions/btowc.texi: Likewise.
116979         * doc/posix-functions/fgetwc.texi: Likewise.
116980         * doc/posix-functions/fgetws.texi: Likewise.
116981         * doc/posix-functions/fputwc.texi: Likewise.
116982         * doc/posix-functions/fputws.texi: Likewise.
116983         * doc/posix-functions/fwide.texi: Likewise.
116984         * doc/posix-functions/fwprintf.texi: Likewise.
116985         * doc/posix-functions/fwscanf.texi: Likewise.
116986         * doc/posix-functions/getwchar.texi: Likewise.
116987         * doc/posix-functions/getwc.texi: Likewise.
116988         * doc/posix-functions/iswalnum.texi: Likewise.
116989         * doc/posix-functions/iswalpha.texi: Likewise.
116990         * doc/posix-functions/iswblank.texi: Likewise.
116991         * doc/posix-functions/iswcntrl.texi: Likewise.
116992         * doc/posix-functions/iswctype.texi: Likewise.
116993         * doc/posix-functions/iswdigit.texi: Likewise.
116994         * doc/posix-functions/iswgraph.texi: Likewise.
116995         * doc/posix-functions/iswlower.texi: Likewise.
116996         * doc/posix-functions/iswprint.texi: Likewise.
116997         * doc/posix-functions/iswpunct.texi: Likewise.
116998         * doc/posix-functions/iswspace.texi: Likewise.
116999         * doc/posix-functions/iswupper.texi: Likewise.
117000         * doc/posix-functions/iswxdigit.texi: Likewise.
117001         * doc/posix-functions/mbrtowc.texi: Likewise.
117002         * doc/posix-functions/mbsrtowcs.texi: Likewise.
117003         * doc/posix-functions/mbstowcs.texi: Likewise.
117004         * doc/posix-functions/mbtowc.texi: Likewise.
117005         * doc/posix-functions/putwchar.texi: Likewise.
117006         * doc/posix-functions/putwc.texi: Likewise.
117007         * doc/posix-functions/swprintf.texi: Likewise.
117008         * doc/posix-functions/tolower.texi: Likewise.
117009         * doc/posix-functions/toupper.texi: Likewise.
117010         * doc/posix-functions/towctrans.texi: Likewise.
117011         * doc/posix-functions/ungetwc.texi: Likewise.
117012         * doc/posix-functions/vswprintf.texi: Likewise.
117013         * doc/posix-functions/wcrtomb.texi: Likewise.
117014         * doc/posix-functions/wcscat.texi: Likewise.
117015         * doc/posix-functions/wcschr.texi: Likewise.
117016         * doc/posix-functions/wcscmp.texi: Likewise.
117017         * doc/posix-functions/wcscoll.texi: Likewise.
117018         * doc/posix-functions/wcscpy.texi: Likewise.
117019         * doc/posix-functions/wcscspn.texi: Likewise.
117020         * doc/posix-functions/wcsftime.texi: Likewise.
117021         * doc/posix-functions/wcslen.texi: Likewise.
117022         * doc/posix-functions/wcsncat.texi: Likewise.
117023         * doc/posix-functions/wcsncmp.texi: Likewise.
117024         * doc/posix-functions/wcsncpy.texi: Likewise.
117025         * doc/posix-functions/wcspbrk.texi: Likewise.
117026         * doc/posix-functions/wcsrchr.texi: Likewise.
117027         * doc/posix-functions/wcsrtombs.texi: Likewise.
117028         * doc/posix-functions/wcsspn.texi: Likewise.
117029         * doc/posix-functions/wcsstr.texi: Likewise.
117030         * doc/posix-functions/wcstod.texi: Likewise.
117031         * doc/posix-functions/wcstof.texi: Likewise.
117032         * doc/posix-functions/wcstoimax.texi: Likewise.
117033         * doc/posix-functions/wcstok.texi: Likewise.
117034         * doc/posix-functions/wcstold.texi: Likewise.
117035         * doc/posix-functions/wcstoll.texi: Likewise.
117036         * doc/posix-functions/wcstol.texi: Likewise.
117037         * doc/posix-functions/wcstombs.texi: Likewise.
117038         * doc/posix-functions/wcstoull.texi: Likewise.
117039         * doc/posix-functions/wcstoul.texi: Likewise.
117040         * doc/posix-functions/wcstoumax.texi: Likewise.
117041         * doc/posix-functions/wcswidth.texi: Likewise.
117042         * doc/posix-functions/wcsxfrm.texi: Likewise.
117043         * doc/posix-functions/wctob.texi: Likewise.
117044         * doc/posix-functions/wctomb.texi: Likewise.
117045         * doc/posix-functions/wctrans.texi: Likewise.
117046         * doc/posix-functions/wctype.texi: Likewise.
117047         * doc/posix-functions/wcwidth.texi: Likewise.
117048         * doc/posix-functions/wmemchr.texi: Likewise.
117049         * doc/posix-functions/wmemcmp.texi: Likewise.
117050         * doc/posix-functions/wmemcpy.texi: Likewise.
117051         * doc/posix-functions/wmemmove.texi: Likewise.
117052         * doc/posix-functions/wmemset.texi: Likewise.
117053         * doc/posix-functions/wprintf.texi: Likewise.
117054         * doc/posix-functions/wscanf.texi: Likewise.
117056 2008-12-21  Bruno Haible  <bruno@clisp.org>
117058         Update doc for HP-UX 11.11.
117059         * doc/posix-functions/btowc.texi: Clarify that the function is missing
117060         in HP-UX version 11.00, not in all versions of HP-UX 11.
117061         * doc/posix-functions/fwide.texi: Likewise.
117062         * doc/posix-functions/fwprintf.texi: Likewise.
117063         * doc/posix-functions/fwscanf.texi: Likewise.
117064         * doc/posix-functions/inet_ntop.texi: Likewise.
117065         * doc/posix-functions/inet_pton.texi: Likewise.
117066         * doc/posix-functions/mbrlen.texi: Likewise.
117067         * doc/posix-functions/mbrtowc.texi: Likewise.
117068         * doc/posix-functions/mbsinit.texi: Likewise.
117069         * doc/posix-functions/mbsrtowcs.texi: Likewise.
117070         * doc/posix-functions/swprintf.texi: Likewise.
117071         * doc/posix-functions/swscanf.texi: Likewise.
117072         * doc/posix-functions/towctrans.texi: Likewise.
117073         * doc/posix-functions/vfwprintf.texi: Likewise.
117074         * doc/posix-functions/vswprintf.texi: Likewise.
117075         * doc/posix-functions/vwprintf.texi: Likewise.
117076         * doc/posix-functions/wcrtomb.texi: Likewise.
117077         * doc/posix-functions/wcsrtombs.texi: Likewise.
117078         * doc/posix-functions/wcsstr.texi: Likewise.
117079         * doc/posix-functions/wctob.texi: Likewise.
117080         * doc/posix-functions/wctrans.texi: Likewise.
117081         * doc/posix-functions/wmemchr.texi: Likewise.
117082         * doc/posix-functions/wmemcmp.texi: Likewise.
117083         * doc/posix-functions/wmemcpy.texi: Likewise.
117084         * doc/posix-functions/wmemmove.texi: Likewise.
117085         * doc/posix-functions/wmemset.texi: Likewise.
117086         * doc/posix-functions/wprintf.texi: Likewise.
117087         * doc/posix-functions/wscanf.texi: Likewise.
117089 2008-12-21  Bruno Haible  <bruno@clisp.org>
117091         Work around a portability problem.
117092         * tests/test-mbsrtowcs.c (main): Use a temporary conversion state.
117093         * doc/posix-functions/mbsrtowcs.texi: Document the portability problem.
117095 2008-12-20  Bruno Haible  <bruno@clisp.org>
117097         * lib/wchar.in.h (mbsrtowcs): Redefine if REPLACE_MBSRTOWCS is set.
117098         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Invoke gl_MBSTATE_T_BROKEN. Set
117099         REPLACE_MBSRTOWCS if mbsrtowcs needs to be overridden.
117100         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSRTOWCS.
117101         * modules/wchar (Makefile.am): Substitute REPLACE_MBSRTOWCS.
117103         Work around mbrtowc bugs on AIX, HP-UX, OSF/1, Solaris.
117104         * lib/wchar.in.h (mbstate_t): Redefine also if REPLACE_MBSTATE_T is
117105         set.
117106         (GNULIB_defined_mbstate_t): New macro.
117107         (mbsinit): Redefine if REPLACE_MBSINIT is set.
117108         (mbrtowc): Redefine if REPLACE_MBRTOWC is set.
117109         * lib/mbrtowc.c (rpl_mbrtowc): Add an alternative implementation that
117110         reuses the system's mbrtowc function but works around the bugs.
117111         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN, gl_MBRTOWC_INCOMPLETE_STATE,
117112         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL): New
117113         macros.
117114         (gl_FUNC_MBRTOWC): Invoke them. Set REPLACE_MBRTOWC if mbrtowc needs to
117115         be overridden. Optionally define MBRTOWC_NULL_ARG_BUG,
117116         MBRTOWC_RETVAL_BUG, MBRTOWC_NUL_RETVAL_BUG.
117117         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_MBSTATE_T_BROKEN. Set
117118         REPLACE_MBSINIT if mbsinit needs to be overridden.
117119         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSTATE_T,
117120         REPLACE_MBSINIT, REPLACE_MBRTOWC.
117121         * modules/wchar (Makefile.am): Substitute REPLACE_MBSTATE_T,
117122         REPLACE_MBSINIT, REPLACE_MBRTOWC.
117123         * modules/mbrtowc (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
117124         m4/locale-zh.m4.
117125         (Depends): Add mbsinit.
117126         * modules/mbsinit (Depends): Add mbrtowc.
117127         * doc/posix-functions/mbrtowc.texi: Mention the various bugs.
117129 2008-12-20  Bruno Haible  <bruno@clisp.org>
117131         * tests/test-mbrtowc.c (main): Change sample string in EUC-JP encoding
117132         so that there are no conversion errors on AIX.
117133         * tests/test-mbsrtowcs.c (main): LIkewise.
117135 2008-12-20  Bruno Haible  <bruno@clisp.org>
117137         Work around wctob bug on Solaris <= 9.
117138         * lib/wchar.in.h (wctob): Redefine if REPLACE_WCTOB is set.
117139         * m4/wctob.m4 (gl_FUNC_WCTOB): Test whether wctob works.
117140         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCTOB.
117141         * modules/wchar (Makefile.am): Substitute REPLACE_WCTOB.
117142         * modules/wctob (Files): Add m4/locale-fr.m4.
117143         * doc/posix-functions/wctob.texi: Mention the Solaris bug.
117145 2008-12-20  Bruno Haible  <bruno@clisp.org>
117147         * doc/posix-functions/select.texi: Mention Solaris 2.6 bug with
117148         /dev/null.
117149         * tests/test-select-in.sh: Likewise.
117150         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
117152 2008-12-20  Bruno Haible  <bruno@clisp.org>
117154         Don't pretend that Cygwin has a ja_JP.EUC-JP locale.
117155         * m4/locale-ja.m4 (gt_LOCALE_JA): Add test for MB_CUR_MAX. Needed on
117156         Cygwin 1.5.x.
117158 2008-12-20  Bruno Haible  <bruno@clisp.org>
117160         Ensure mbstate_t is defined on HP-UX 11.11.
117161         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Require
117162         AC_CANONICAL_HOST. On HP-UX, define _XOPEN_SOURCE to 500.
117163         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Require
117164         AC_USE_SYSTEM_EXTENSIONS.
117165         * modules/fnmatch (Depends-on): Add extensions.
117166         * modules/mbrlen (Depends-on): Likewise.
117167         * modules/mbrtowc (Depends-on): Likewise.
117168         * modules/mbsinit (Depends-on): Likewise.
117169         * modules/mbsrtowcs (Depends-on): Likewise.
117170         * modules/mbswidth (Depends-on): Likewise.
117171         * modules/quotearg (Depends-on): Likewise.
117172         * modules/strftime (Depends-on): Likewise.
117174 2008-12-20  Bruno Haible  <bruno@clisp.org>
117176         Ensure wctob is declared on IRIX 6.5.
117177         * lib/wchar.in.h (wctob): Declare also when HAVE_DECL_WCTOB is 0.
117178         * m4/wctob.m4 (gl_FUNC_WCTOB): Set HAVE_DECL_WCTOB instead of
117179         HAVE_WCTOB. Also test whether <wchar.h> declares wctob.
117180         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize HAVE_DECL_WCTOB instead
117181         of HAVE_WCTOB.
117182         * modules/wchar (Makefile.am): Substitute HAVE_DECL_WCTOB instead of
117183         HAVE_WCTOB.
117184         * doc/posix-functions/wctob.texi: Mention missing declaration on IRIX.
117186 2008-12-19  Bruno Haible  <bruno@clisp.org>
117188         * modules/mbsrtowcs-tests: New file.
117189         * tests/test-mbsrtowcs1.sh: New file.
117190         * tests/test-mbsrtowcs2.sh: New file.
117191         * tests/test-mbsrtowcs3.sh: New file.
117192         * tests/test-mbsrtowcs4.sh: New file.
117193         * tests/test-mbsrtowcs.c: New file.
117195         New module 'mbsrtowcs'.
117196         * lib/wchar.in.h (mbsrtowcs): New declaration.
117197         * lib/mbsrtowcs.c: New file.
117198         * m4/mbsrtowcs.m4: New file.
117199         * modules/mbsrtowcs: New file.
117200         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSRTOWCS and
117201         HAVE_MBSRTOWCS.
117202         * modules/wchar (Makefile.am): Substitute GNULIB_MBSRTOWCS and
117203         HAVE_MBSRTOWCS.
117204         * doc/posix-functions/mbsrtowcs.texi: Document the new module.
117206 2008-12-19  Bruno Haible  <bruno@clisp.org>
117208         New module 'mbrlen'.
117209         * lib/wchar.in.h (mbrlen): New declaration.
117210         * lib/mbrlen.c: New file.
117211         * m4/mbrlen.m4: New file.
117212         * modules/mbrlen: New file.
117213         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRLEN and
117214         HAVE_MBRLEN.
117215         * modules/wchar (Makefile.am): Substitute GNULIB_MBRLEN and
117216         HAVE_MBRLEN.
117217         * doc/posix-functions/mbrlen.texi: Document the new module.
117219 2008-12-19  Bruno Haible  <bruno@clisp.org>
117221         * lib/mbrtowc.c: Include verify.h. Verify an assumption.
117222         * modules/mbrtowc (Depends-on): Add verify.
117223         Suggested by Paul Eggert.
117225 2008-12-18  Bruno Haible  <bruno@clisp.org>
117227         * modules/mbsinit-tests: New file.
117228         * tests/test-mbsinit.sh: New file.
117229         * tests/test-mbsinit.c: New file.
117231 2008-12-18  Bruno Haible  <bruno@clisp.org>
117233         * modules/mbrtowc-tests: New file.
117234         * tests/test-mbrtowc1.sh: New file.
117235         * tests/test-mbrtowc2.sh: New file.
117236         * tests/test-mbrtowc3.sh: New file.
117237         * tests/test-mbrtowc4.sh: New file.
117238         * tests/test-mbrtowc.c: New file.
117240         New module 'mbrtowc'.
117241         * lib/wchar.in.h (mbstate_t): Override when the system does not have
117242         mbsinit and mbrtowc.
117243         (mbrtowc): New declaration.
117244         * lib/mbrtowc.c: New file.
117245         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC, gl_PREREQ_MBRTOWC): New macros.
117246         * modules/mbrtowc: New file.
117247         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRTOWC and
117248         HAVE_MBRTOWC.
117249         * modules/wchar (Makefile.am): Substitute GNULIB_MBRTOWC and
117250         HAVE_MBRTOWC.
117251         * doc/posix-functions/mbrtowc.texi: Document the new module.
117253 2008-12-18  Bruno Haible  <bruno@clisp.org>
117255         New module 'wctob'.
117256         * lib/wchar.in.h (wctob): New declaration.
117257         * lib/wctob.c: New file.
117258         * m4/wctob.m4: New file.
117259         * modules/wctob: New file.
117260         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCTOB and
117261         HAVE_WCTOB.
117262         * modules/wchar (Makefile.am): Substitute GNULIB_WCTOB and HAVE_WCTOB.
117263         * doc/posix-functions/wctob.texi: Document the new module.
117265 2008-12-18  Bruno Haible  <bruno@clisp.org>
117267         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_REPLACE_WCHAR_H.
117268         * m4/btowc.m4 (gl_FUNC_BTOWC): Likewise.
117270 2008-12-18  Simon Josefsson  <simon@josefsson.org>
117272         * lib/flock.c: Use proper #if symbol in check.  Reported by "Tom
117273         G. Christensen" <tgc@jupiterrise.com>.
117275         * lib/flock.c: Need to include errno.h.  Reported by "Tom
117276         G. Christensen" <tgc@jupiterrise.com>.
117278         * lib/flock.c: Need to include string.h.  Reported by "Tom
117279         G. Christensen" <tgc@jupiterrise.com> and Eric Blake
117280         <ebb9@byu.net>.
117282 2008-12-18  Bruno Haible  <bruno@clisp.org>
117284         * m4/locale-ja.m4: New file, from GNU gettext.
117286 2008-12-17  Bruno Haible  <bruno@clisp.org>
117288         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Don't override in autoconf >= 2.60.
117289         Suggested by Eric Blake.
117291 2008-12-17  Bruno Haible  <bruno@clisp.org>
117293         * m4/errno_h.m4 (AC_COMPUTE_INT): Provide fallback definition.
117295 2008-12-17  Bruno Haible  <bruno@clisp.org>
117297         * lib/mbsinit.c: Include verify.h. Verify an assumption.
117298         * modules/mbsinit (Depends-on): Add verify.
117299         Suggested by Paul Eggert.
117301 2008-12-17  Bruno Haible  <bruno@clisp.org>
117303         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Renamed from gl_FUNC_MBRTOWC.
117304         * m4/mbfile.m4 (gl_MBFILE): Use AC_FUNC_MBRTOWC instead of
117305         gl_FUNC_MBRTOWC.
117306         * m4/mbiter.m4 (gl_MBITER): LIkewise.
117307         * m4/mbscasecmp.m4 (gl_PREREQ_MBSCASECMP): Likewise.
117308         * m4/mbscasestr.m4 (gl_PREREQ_MBSCASESTR): Likewise.
117309         * m4/mbschr.m4 (gl_PREREQ_MBSCHR): Likewise.
117310         * m4/mbscspn.m4 (gl_PREREQ_MBSCSPN): Likewise.
117311         * m4/mbslen.m4 (gl_PREREQ_MBSLEN): Likewise.
117312         * m4/mbsncasecmp.m4 (gl_PREREQ_MBSNCASECMP): Likewise.
117313         * m4/mbsnlen.m4 (gl_PREREQ_MBSNLEN): Likewise.
117314         * m4/mbspbrk.m4 (gl_PREREQ_MBSPBRK): Likewise.
117315         * m4/mbspcasecmp.m4 (gl_PREREQ_MBSPCASECMP): Likewise.
117316         * m4/mbsrchr.m4 (gl_PREREQ_MBSRCHR): Likewise.
117317         * m4/mbssep.m4 (gl_PREREQ_MBSSEP): Likewise.
117318         * m4/mbsspn.m4 (gl_PREREQ_MBSSPN): Likewise.
117319         * m4/mbsstr.m4 (gl_PREREQ_MBSSTR): Likewise.
117320         * m4/mbstok_r.m4 (gl_PREREQ_MBSTOK_R): Likewise.
117321         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
117322         * m4/quotearg.m4 (gl_QUOTEARG): Likewise.
117323         * modules/trim (configure.ac): Likewise.
117325 2008-12-17  Bruno Haible  <bruno@clisp.org>
117327         * modules/btowc-tests: New file.
117328         * tests/test-btowc1.sh: New file.
117329         * tests/test-btowc2.sh: New file.
117330         * tests/test-btowc.c: New file.
117332         New module 'btowc'.
117333         * lib/wchar.in.h (btowc): New declaration.
117334         * lib/btowc.c: New file.
117335         * m4/btowc.m4: New file.
117336         * modules/btowc: New file.
117337         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_BTOWC and
117338         HAVE_BTOWC.
117339         * modules/wchar (Makefile.am): Substitute GNULIB_BTOWC and HAVE_BTOWC.
117340         * doc/posix-functions/btowc.texi: Document the new module.
117342 2008-12-17  Bruno Haible  <bruno@clisp.org>
117344         New module 'mbsinit'.
117345         * lib/wchar.in.h (mbsinit): New declaration.
117346         * lib/mbsinit.c: New file.
117347         * m4/mbsinit.m4: New file.
117348         * modules/mbsinit: New file.
117349         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSINIT and
117350         HAVE_MBSINIT.
117351         * modules/wchar (Makefile.am): Substitute GNULIB_MBSINIT and
117352         HAVE_MBSINIT.
117353         * doc/posix-functions/mbsinit.texi: Document the new module.
117355 2008-12-16  Bruno Haible  <bruno@clisp.org>
117357         * lib/unistd.in.h: Add comment.
117358         * tests/test-environ.c: Don't include <stdlib.h>.
117360 2008-12-16  Bruno Haible  <bruno@clisp.org>
117362         * lib/parse-duration.h (parse_duration): Document return value
117363         convention.
117364         * lib/parse-duration.c: Include specification header first. Add
117365         comments.
117366         (_): Remove macro.
117367         (parse_year_month_day, parse_hour_minute_second): Move side effects
117368         outside of strchr call.
117369         (parse_non_iso8601): Move side effects outside of isspace call.
117370         (parse_duration): Don't test errno is res != BAD_TIME. Remove fprintf
117371         call.
117373 2008-12-16  Bruno Haible  <bruno@clisp.org>
117375         * tests/test-parse-duration.sh: Produce no output when the test
117376         succeeds.
117378 2008-12-16  Bruno Haible  <bruno@clisp.org>
117380         * tests/test-parse-duration.sh: Fix quoting of $tmp and $tmpf
117381         expressions.
117383 2008-12-15  Bruno Haible  <bruno@clisp.org>
117385         * doc/glibc-functions/fgetxattr.texi: Tweak wording.
117386         * doc/glibc-functions/flistxattr.texi: Likewise.
117387         * doc/glibc-functions/fopencookie.texi: Likewise.
117388         * doc/glibc-functions/fremovexattr.texi: Likewise.
117389         * doc/glibc-functions/fsetxattr.texi: Likewise.
117390         * doc/glibc-functions/getxattr.texi: Likewise.
117391         * doc/glibc-functions/lgetxattr.texi: Likewise.
117392         * doc/glibc-functions/listxattr.texi: Likewise.
117393         * doc/glibc-functions/llistxattr.texi: Likewise.
117394         * doc/glibc-functions/lremovexattr.texi: Likewise.
117395         * doc/glibc-functions/lsetxattr.texi: Likewise.
117396         * doc/glibc-functions/removexattr.texi: Likewise.
117397         * doc/glibc-functions/setxattr.texi: Likewise.
117398         * doc/posix-functions/open_memstream.texi: Likewise.
117400 2008-12-15  Eric Blake  <ebb9@byu.net>
117402         Update doc for cygwin 1.7.
117403         * doc/posix-functions/faccessat.texi: Cygwin 1.7 added several new
117404         functions.
117405         * doc/posix-functions/fchmodat.texi: Likewise.
117406         * doc/posix-functions/fchownat.texi: Likewise.
117407         * doc/posix-functions/fdopendir.texi: Likewise.
117408         * doc/posix-functions/fmemopen.texi: Likewise.
117409         * doc/posix-functions/freeaddrinfo.texi: Likewise.
117410         * doc/posix-functions/fstatat.texi: Likewise.
117411         * doc/posix-functions/futimens.texi: Likewise.
117412         * doc/posix-functions/gai_strerror.texi: Likewise.
117413         * doc/posix-functions/getaddrinfo.texi: Likewise.
117414         * doc/posix-functions/getnameinfo.texi: Likewise.
117415         * doc/posix-functions/if_freenameindex.texi: Likewise.
117416         * doc/posix-functions/if_indextoname.texi: Likewise.
117417         * doc/posix-functions/if_nameindex.texi: Likewise.
117418         * doc/posix-functions/if_nametoindex.texi: Likewise.
117419         * doc/posix-functions/insque.texi: Likewise.
117420         * doc/posix-functions/linkat.texi: Likewise.
117421         * doc/posix-functions/llrint.texi: Likewise.
117422         * doc/posix-functions/llrintf.texi: Likewise.
117423         * doc/posix-functions/llrintl.texi: Likewise.
117424         * doc/posix-functions/lockf.texi: Likewise.
117425         * doc/posix-functions/lrintl.texi: Likewise.
117426         * doc/posix-functions/mkdirat.texi: Likewise.
117427         * doc/posix-functions/mkfifoat.texi: Likewise.
117428         * doc/posix-functions/mknodat.texi: Likewise.
117429         * doc/posix-functions/mq_close.texi: Likewise.
117430         * doc/posix-functions/mq_getattr.texi: Likewise.
117431         * doc/posix-functions/mq_notify.texi: Likewise.
117432         * doc/posix-functions/mq_open.texi: Likewise.
117433         * doc/posix-functions/mq_receive.texi: Likewise.
117434         * doc/posix-functions/mq_send.texi: Likewise.
117435         * doc/posix-functions/mq_setattr.texi: Likewise.
117436         * doc/posix-functions/mq_timedreceive.texi: Likewise.
117437         * doc/posix-functions/mq_timedsend.texi: Likewise.
117438         * doc/posix-functions/mq_unlink.texi: Likewise.
117439         * doc/posix-functions/open_memstream.texi: Likewise.
117440         * doc/posix-functions/openat.texi: Likewise.
117441         * doc/posix-functions/posix_fadvise.texi: Likewise.
117442         * doc/posix-functions/posix_fallocate.texi: Likewise.
117443         * doc/posix-functions/posix_madvise.texi: Likewise.
117444         * doc/posix-functions/posix_memalign.texi: Likewise.
117445         * doc/posix-functions/posix_openpt.texi: Likewise.
117446         * doc/posix-functions/readlinkat.texi: Likewise.
117447         * doc/posix-functions/remque.texi: Likewise.
117448         * doc/posix-functions/renameat.texi: Likewise.
117449         * doc/posix-functions/rintl.texi: Likewise.
117450         * doc/posix-functions/sem_unlink.texi: Likewise.
117451         * doc/posix-functions/shm_open.texi: Likewise.
117452         * doc/posix-functions/shm_unlink.texi: Likewise.
117453         * doc/posix-functions/signgam.texi: Likewise.
117454         * doc/posix-functions/sigset.texi: Likewise.
117455         * doc/posix-functions/stpcpy.texi: Likewise.
117456         * doc/posix-functions/stpncpy.texi: Likewise.
117457         * doc/posix-functions/strerror.texi: Likewise.
117458         * doc/posix-functions/strtod.texi: Likewise.
117459         * doc/posix-functions/symlinkat.texi: Likewise.
117460         * doc/posix-functions/unlinkat.texi: Likewise.
117461         * doc/posix-functions/utimensat.texi: Likewise.
117462         * doc/glibc-functions/bindresvport.texi: Likewise.
117463         * doc/glibc-functions/dn_expand.texi: Likewise.
117464         * doc/glibc-functions/exp10.texi: Likewise.
117465         * doc/glibc-functions/exp10f.texi: Likewise.
117466         * doc/glibc-functions/fgetxattr.texi: Likewise.
117467         * doc/glibc-functions/flistxattr.texi: Likewise.
117468         * doc/glibc-functions/fopencookie.texi: Likewise.
117469         * doc/glibc-functions/freeifaddrs.texi: Likewise.
117470         * doc/glibc-functions/fremovexattr.texi: Likewise.
117471         * doc/glibc-functions/fsetxattr.texi: Likewise.
117472         * doc/glibc-functions/getifaddrs.texi: Likewise.
117473         * doc/glibc-functions/getxattr.texi: Likewise.
117474         * doc/glibc-functions/lgetxattr.texi: Likewise.
117475         * doc/glibc-functions/listxattr.texi: Likewise.
117476         * doc/glibc-functions/llistxattr.texi: Likewise.
117477         * doc/glibc-functions/lremovexattr.texi: Likewise.
117478         * doc/glibc-functions/lsetxattr.texi: Likewise.
117479         * doc/glibc-functions/pow10.texi: Likewise.
117480         * doc/glibc-functions/pow10f.texi: Likewise.
117481         * doc/glibc-functions/rcmd_af.texi: Likewise.
117482         * doc/glibc-functions/removexattr.texi: Likewise.
117483         * doc/glibc-functions/res_init.texi: Likewise.
117484         * doc/glibc-functions/res_mkquery.texi: Likewise.
117485         * doc/glibc-functions/res_query.texi: Likewise.
117486         * doc/glibc-functions/res_querydomain.texi: Likewise.
117487         * doc/glibc-functions/res_send.texi: Likewise.
117488         * doc/glibc-functions/rresvport_af.texi: Likewise.
117489         * doc/glibc-functions/setxattr.texi: Likewise.
117490         * doc/glibc-functions/strcasestr.texi: Likewise.
117492 2008-12-15  Bruno Haible  <bruno@clisp.org>
117494         Fix compilation error on OSF/1 4.0.
117495         * lib/sys_select.in.h: When invoked from OSF/1 <sys/types.h> or
117496         <sys/time.h>, simply delegate to the system header.
117497         Reported by Daniel Richard G. <oss@teragram.com>.
117499 2008-12-15  Bruno Haible  <bruno@clisp.org>
117501         * doc/posix-functions/openat.texi: Mention the 'openat' module.
117502         * doc/posix-functions/fchmodat.texi: Likewise.
117503         * doc/posix-functions/fchownat.texi: Likewise.
117504         * doc/posix-functions/fdopendir.texi: Likewise.
117505         * doc/posix-functions/fstatat.texi: Likewise.
117506         * doc/posix-functions/mkdirat.texi: Likewise.
117507         * doc/posix-functions/unlinkat.texi: Likewise.
117509 2008-12-14  Bruno Haible  <bruno@clisp.org>
117511         Update doc for POSIX:2008.
117512         * doc/posix-functions/faccessat.texi: New file.
117513         * doc/posix-functions/fchmodat.texi: New file.
117514         * doc/posix-functions/fchownat.texi: New file.
117515         * doc/posix-functions/fdopendir.texi: New file.
117516         * doc/posix-functions/fstatat.texi: New file.
117517         * doc/posix-functions/futimens.texi: New file.
117518         * doc/posix-functions/linkat.texi: New file.
117519         * doc/posix-functions/mkdirat.texi: New file.
117520         * doc/posix-functions/mkfifoat.texi: New file.
117521         * doc/posix-functions/mknodat.texi: New file.
117522         * doc/posix-functions/open_wmemstream.texi: New file.
117523         * doc/posix-functions/openat.texi: New file.
117524         * doc/posix-functions/psiginfo.texi: New file.
117525         * doc/posix-functions/pthread_mutex_consistent.texi: New file.
117526         * doc/posix-functions/pthread_mutexattr_getrobust.texi: New file.
117527         * doc/posix-functions/pthread_mutexattr_setrobust.texi: New file.
117528         * doc/posix-functions/readlinkat.texi: New file.
117529         * doc/posix-functions/renameat.texi: New file.
117530         * doc/posix-functions/strerror_l.texi: New file.
117531         * doc/posix-functions/symlinkat.texi: New file.
117532         * doc/posix-functions/unlinkat.texi: New file.
117533         * doc/posix-functions/utimensat.texi: New file.
117534         * doc/gnulib.texi (Function Substitutes): Add these subsections.
117536 2008-12-14  Bruno Haible  <bruno@clisp.org>
117538         Update doc for POSIX:2008.
117539         * doc/posix-functions/alphasort.texi: Renamed from
117540         doc/glibc-functions/alphasort.texi.
117541         * doc/posix-functions/dirfd.texi: Renamed from
117542         doc/glibc-functions/dirfd.texi.
117543         * doc/posix-functions/dprintf.texi: Renamed from
117544         doc/glibc-functions/dprintf.texi.
117545         * doc/posix-functions/duplocale.texi: Renamed from
117546         doc/glibc-functions/duplocale.texi.
117547         * doc/posix-functions/fexecve.texi: Renamed from
117548         doc/glibc-functions/fexecve.texi.
117549         * doc/posix-functions/fmemopen.texi: Renamed from
117550         doc/glibc-functions/fmemopen.texi.
117551         * doc/posix-functions/freelocale.texi: Renamed from
117552         doc/glibc-functions/freelocale.texi.
117553         * doc/posix-functions/getdate_err.texi: Renamed from
117554         doc/glibc-functions/getdate_err.texi.
117555         * doc/posix-functions/isalnum_l.texi: Renamed from
117556         doc/glibc-functions/isalnum_l.texi.
117557         * doc/posix-functions/isalpha_l.texi: Renamed from
117558         doc/glibc-functions/isalpha_l.texi.
117559         * doc/posix-functions/isblank_l.texi: Renamed from
117560         doc/glibc-functions/isblank_l.texi.
117561         * doc/posix-functions/iscntrl_l.texi: Renamed from
117562         doc/glibc-functions/iscntrl_l.texi.
117563         * doc/posix-functions/isdigit_l.texi: Renamed from
117564         doc/glibc-functions/isdigit_l.texi.
117565         * doc/posix-functions/isgraph_l.texi: Renamed from
117566         doc/glibc-functions/isgraph_l.texi.
117567         * doc/posix-functions/islower_l.texi: Renamed from
117568         doc/glibc-functions/islower_l.texi.
117569         * doc/posix-functions/isprint_l.texi: Renamed from
117570         doc/glibc-functions/isprint_l.texi.
117571         * doc/posix-functions/ispunct_l.texi: Renamed from
117572         doc/glibc-functions/ispunct_l.texi.
117573         * doc/posix-functions/isspace_l.texi: Renamed from
117574         doc/glibc-functions/isspace_l.texi.
117575         * doc/posix-functions/isupper_l.texi: Renamed from
117576         doc/glibc-functions/isupper_l.texi.
117577         * doc/posix-functions/iswalnum_l.texi: Renamed from
117578         doc/glibc-functions/iswalnum_l.texi.
117579         * doc/posix-functions/iswalpha_l.texi: Renamed from
117580         doc/glibc-functions/iswalpha_l.texi.
117581         * doc/posix-functions/iswblank_l.texi: Renamed from
117582         doc/glibc-functions/iswblank_l.texi.
117583         * doc/posix-functions/iswcntrl_l.texi: Renamed from
117584         doc/glibc-functions/iswcntrl_l.texi.
117585         * doc/posix-functions/iswctype_l.texi: Renamed from
117586         doc/glibc-functions/iswctype_l.texi.
117587         * doc/posix-functions/iswdigit_l.texi: Renamed from
117588         doc/glibc-functions/iswdigit_l.texi.
117589         * doc/posix-functions/iswgraph_l.texi: Renamed from
117590         doc/glibc-functions/iswgraph_l.texi.
117591         * doc/posix-functions/iswlower_l.texi: Renamed from
117592         doc/glibc-functions/iswlower_l.texi.
117593         * doc/posix-functions/iswprint_l.texi: Renamed from
117594         doc/glibc-functions/iswprint_l.texi.
117595         * doc/posix-functions/iswpunct_l.texi: Renamed from
117596         doc/glibc-functions/iswpunct_l.texi.
117597         * doc/posix-functions/iswspace_l.texi: Renamed from
117598         doc/glibc-functions/iswspace_l.texi.
117599         * doc/posix-functions/iswupper_l.texi: Renamed from
117600         doc/glibc-functions/iswupper_l.texi.
117601         * doc/posix-functions/iswxdigit_l.texi: Renamed from
117602         doc/glibc-functions/iswxdigit_l.texi.
117603         * doc/posix-functions/isxdigit_l.texi: Renamed from
117604         doc/glibc-functions/isxdigit_l.texi.
117605         * doc/posix-functions/mbsnrtowcs.texi: Renamed from
117606         doc/glibc-functions/mbsnrtowcs.texi.
117607         * doc/posix-functions/mkdtemp.texi: Renamed from
117608         doc/glibc-functions/mkdtemp.texi.
117609         * doc/posix-functions/newlocale.texi: Renamed from
117610         doc/glibc-functions/newlocale.texi.
117611         * doc/posix-functions/nl_langinfo_l.texi: Renamed from
117612         doc/glibc-functions/nl_langinfo_l.texi.
117613         * doc/posix-functions/open_memstream.texi: Renamed from
117614         doc/glibc-functions/open_memstream.texi.
117615         * doc/posix-functions/opterr.texi: Renamed from
117616         doc/glibc-functions/opterr.texi.
117617         * doc/posix-functions/optind.texi: Renamed from
117618         doc/glibc-functions/optind.texi.
117619         * doc/posix-functions/optopt.texi: Renamed from
117620         doc/glibc-functions/optopt.texi.
117621         * doc/posix-functions/psignal.texi: Renamed from
117622         doc/glibc-functions/psignal.texi.
117623         * doc/posix-functions/scandir.texi: Renamed from
117624         doc/glibc-functions/scandir.texi.
117625         * doc/posix-functions/sched_get_priority_min.texi: Renamed from
117626         doc/glibc-functions/sched_get_priority_min.texi.
117627         * doc/posix-functions/signgam.texi: Renamed from
117628         doc/glibc-functions/signgam.texi.
117629         * doc/posix-functions/stpcpy.texi: Renamed from
117630         doc/glibc-functions/stpcpy.texi.
117631         * doc/posix-functions/stpncpy.texi: Renamed from
117632         doc/glibc-functions/stpncpy.texi.
117633         * doc/posix-functions/strcasecmp_l.texi: Renamed from
117634         doc/glibc-functions/strcasecmp_l.texi.
117635         * doc/posix-functions/strcoll_l.texi: Renamed from
117636         doc/glibc-functions/strcoll_l.texi.
117637         * doc/posix-functions/strfmon_l.texi: Renamed from
117638         doc/glibc-functions/strfmon_l.texi.
117639         * doc/posix-functions/strftime_l.texi: Renamed from
117640         doc/glibc-functions/strftime_l.texi.
117641         * doc/posix-functions/strncasecmp_l.texi: Renamed from
117642         doc/glibc-functions/strncasecmp_l.texi.
117643         * doc/posix-functions/strndup.texi: Renamed from
117644         doc/glibc-functions/strndup.texi.
117645         * doc/posix-functions/strnlen.texi: Renamed from
117646         doc/glibc-functions/strnlen.texi.
117647         * doc/posix-functions/strsignal.texi: Renamed from
117648         doc/glibc-functions/strsignal.texi.
117649         * doc/posix-functions/strxfrm_l.texi: Renamed from
117650         doc/glibc-functions/strxfrm_l.texi.
117651         * doc/posix-functions/timer_gettime.texi: Renamed from
117652         doc/glibc-functions/timer_gettime.texi.
117653         * doc/posix-functions/tolower_l.texi: Renamed from
117654         doc/glibc-functions/tolower_l.texi.
117655         * doc/posix-functions/toupper_l.texi: Renamed from
117656         doc/glibc-functions/toupper_l.texi.
117657         * doc/posix-functions/towctrans_l.texi: Renamed from
117658         doc/glibc-functions/towctrans_l.texi.
117659         * doc/posix-functions/towlower_l.texi: Renamed from
117660         doc/glibc-functions/towlower_l.texi.
117661         * doc/posix-functions/towupper_l.texi: Renamed from
117662         doc/glibc-functions/towupper_l.texi.
117663         * doc/posix-functions/uselocale.texi: Renamed from
117664         doc/glibc-functions/uselocale.texi.
117665         * doc/posix-functions/vdprintf.texi: Renamed from
117666         doc/glibc-functions/vdprintf.texi.
117667         * doc/posix-functions/wcpcpy.texi:
117668         Renamed from doc/glibc-functions/wcpcpy.texi.
117669         * doc/posix-functions/wcpncpy.texi: Renamed from
117670         doc/glibc-functions/wcpncpy.texi.
117671         * doc/posix-functions/wcscasecmp.texi: Renamed from
117672         doc/glibc-functions/wcscasecmp.texi.
117673         * doc/posix-functions/wcscasecmp_l.texi: Renamed from
117674         doc/glibc-functions/wcscasecmp_l.texi.
117675         * doc/posix-functions/wcscoll_l.texi: Renamed from
117676         doc/glibc-functions/wcscoll_l.texi.
117677         * doc/posix-functions/wcsdup.texi: Renamed from
117678         doc/glibc-functions/wcsdup.texi.
117679         * doc/posix-functions/wcsncasecmp.texi: Renamed from
117680         doc/glibc-functions/wcsncasecmp.texi.
117681         * doc/posix-functions/wcsncasecmp_l.texi: Renamed from
117682         doc/glibc-functions/wcsncasecmp_l.texi.
117683         * doc/posix-functions/wcsnlen.texi: Renamed from
117684         doc/glibc-functions/wcsnlen.texi.
117685         * doc/posix-functions/wcsnrtombs.texi: Renamed from
117686         doc/glibc-functions/wcsnrtombs.texi.
117687         * doc/posix-functions/wcsxfrm_l.texi: Renamed from
117688         doc/glibc-functions/wcsxfrm_l.texi.
117689         * doc/posix-functions/wctrans_l.texi: Renamed from
117690         doc/glibc-functions/wctrans_l.texi.
117691         * doc/posix-functions/wctype_l.texi: Renamed from
117692         doc/glibc-functions/wctype_l.texi.
117693         * doc/gnulib.texi (Function Substitutes): Add these subsections.
117694         (Glibc ctype.h, Glibc dirent.h, Glibc getopt.h, Glibc math.h,
117695         Glibc sched.h, Glibc signal.h, Glibc stdio.h, Glibc stdlib.h,
117696         Glibc string.h, Glibc time.h, Glibc unistd.h, Glibc wchar.h): Remove
117697         these subsections.
117698         (Glibc langinfo.h, Glibc locale.h, Glibc monetary.h, Glibc wctype.h):
117699         Remove sections.
117701 2008-12-14  Bruno Haible  <bruno@clisp.org>
117703         Update doc for POSIX:2008.
117704         * doc/posix-functions/*.texi: Update URL of POSIX specification.
117706 2008-12-14  Bruno Haible  <bruno@clisp.org>
117708         Update doc for POSIX:2008.
117709         * doc/pastposix-functions/bcmp.texi: Renamed from
117710         doc/posix-functions/bcmp.texi.
117711         * doc/pastposix-functions/bcopy.texi: Renamed from
117712         doc/posix-functions/bcopy.texi.
117713         * doc/pastposix-functions/bsd_signal.texi: Renamed from
117714         doc/posix-functions/bsd_signal.texi.
117715         * doc/pastposix-functions/bzero.texi: Renamed from
117716         doc/posix-functions/bzero.texi.
117717         * doc/pastposix-functions/ecvt.texi: Renamed from
117718         doc/posix-functions/ecvt.texi.
117719         * doc/pastposix-functions/fcvt.texi: Renamed from
117720         doc/posix-functions/fcvt.texi.
117721         * doc/pastposix-functions/ftime.texi: Renamed from
117722         doc/posix-functions/ftime.texi.
117723         * doc/pastposix-functions/gcvt.texi: Renamed from
117724         doc/posix-functions/gcvt.texi.
117725         * doc/pastposix-functions/getcontext.texi: Renamed from
117726         doc/posix-functions/getcontext.texi.
117727         * doc/pastposix-functions/gethostbyaddr.texi: Renamed from
117728         doc/posix-functions/gethostbyaddr.texi.
117729         * doc/pastposix-functions/gethostbyname.texi: Renamed from
117730         doc/posix-functions/gethostbyname.texi.
117731         * doc/pastposix-functions/getwd.texi: Renamed from
117732         doc/posix-functions/getwd.texi.
117733         * doc/pastposix-functions/h_errno.texi: Renamed from
117734         doc/posix-functions/h_errno.texi.
117735         * doc/pastposix-functions/index.texi: Renamed from
117736         doc/posix-functions/index.texi.
117737         * doc/pastposix-functions/makecontext.texi: Renamed from
117738         doc/posix-functions/makecontext.texi.
117739         * doc/pastposix-functions/mktemp.texi: Renamed from
117740         doc/posix-functions/mktemp.texi.
117741         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Renamed from
117742         doc/posix-functions/pthread_attr_getstackaddr.texi.
117743         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Renamed from
117744         doc/posix-functions/pthread_attr_setstackaddr.texi.
117745         * doc/pastposix-functions/rindex.texi: Renamed from
117746         doc/posix-functions/rindex.texi.
117747         * doc/pastposix-functions/scalb.texi: Renamed from
117748         doc/posix-functions/scalb.texi.
117749         * doc/pastposix-functions/setcontext.texi: Renamed from
117750         doc/posix-functions/setcontext.texi.
117751         * doc/pastposix-functions/swapcontext.texi: Renamed from
117752         doc/posix-functions/swapcontext.texi.
117753         * doc/pastposix-functions/ualarm.texi: Renamed from
117754         doc/posix-functions/ualarm.texi.
117755         * doc/pastposix-functions/usleep.texi: Renamed from
117756         doc/posix-functions/usleep.texi.
117757         * doc/pastposix-functions/vfork.texi: Renamed from
117758         doc/posix-functions/vfork.texi.
117759         * doc/pastposix-functions/wcswcs.texi: Renamed from
117760         doc/posix-functions/wcswcs.texi.
117761         * doc/gnulib.texi (Legacy Function Substitutes): New chapter.
117762         (Function Substitutes): Update.
117764 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
117766         * modules/relocatable-prog-wrapper (Depends-on): Add errno, needed by
117767         m4/strerror.m4.
117769 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
117770             Bruno Haible  <bruno@clisp.org>
117772         * modules/unilbrk/tables (Depends-on): Add unilbrk/base.
117774 2008-12-13  Bruno Haible  <bruno@clisp.org>
117776         * modules/strtoull (Depends-on): Remove unistd.
117778 2008-12-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
117780         * modules/strtoull (Depends-on): Add stdlib.
117782 2008-12-11  Simon Josefsson  <simon@josefsson.org>
117784         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add more warnings.
117786 2008-12-10  Jim Meyering  <meyering@redhat.com>
117788         gl_ASSERT: don't say assertions are disabled when they're not
117789         * m4/assert.m4 (gl_ASSERT): Do not make configure report
117790         "checking whether to enable assertions... no", when they are in
117791         fact enabled.  This is solely a bug in the output of configure.
117792         In spite of saying "no", NDEBUG was not defined in that case.
117793         Also, as noted by Eric Blake, leave assertions enabled upon
117794         --enable-assert=INVALID.
117796 2008-12-10  Bruno Haible  <bruno@clisp.org>
117798         Change MODULES.html to refer to POSIX:2008 where possible.
117799         * MODULES.html.sh (POSIX2008_URL): New variable.
117800         (posix_headers): Remove sys/timeb, ucontext.
117801         (posix2001_headers): New variable.
117802         (posix_functions): Remove bcmp, bcopy, bsd_signal, bzero, ecvt, fcvt,
117803         ftime, gcvt, getcontext, gethostbyaddr, gethostbyname, getwd, h_errno,
117804         index, makecontext, mktemp, pthread_attr_getstackaddr,
117805         pthread_attr_setstackaddr, rindex, scalb, setcontext, swapcontext,
117806         ualarm, usleep, vfork, wcswcs. Add the new POSIX:2008 functions.
117807         (posix2001_functions): New variable.
117808         (func_module): Use URLs to POSIX:2008 where possible and to POSIX:2001
117809         otherwise.
117811 2008-12-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
117813         add missing include to parse-duration.c
117814         * lib/parse-duration.c: #include "xalloc.h", for xstrdup.
117815         * modules/parse-duration (Depends-on): Add xalloc.
117817         fix sed script reading maint.mk
117818         * top/maint.mk (MYSELF): New macro, define as $(srcdir)/$(ME).
117819         (syntax-check-rules): Use it.
117821 2008-12-09  Bruno Haible  <bruno@clisp.org>
117823         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Add another check, that fails on
117824         MacOS X 10.4/PowerPC.
117825         Reported by Simon Josefsson.
117827 2008-12-08  Jim Meyering  <meyering@redhat.com>
117829         work around mingw's lack of some S_IF definitions
117830         * lib/fts.c (S_IFLNK, S_IFSOCK): Define if not already defined.
117831         Reported by Simon Josefsson.
117833 2008-12-08  Bruno Haible  <bruno@clisp.org>
117835         * m4/signbitl.m4 (gl_SIGNBIT_TEST_PROGRAM): Add a link check of signbit
117836         applied to variables. Needed on MacOS X 10.4/PowerPC.
117837         Reported by Simon Josefsson.
117839 2008-12-08  William Pursell  <bill.pursell@gmail.com>  (tiny change)
117840         and Eric Blake  <ebb9@byu.net>
117842         assert: honor --enable-assert
117843         * m4/assert.m4 (gl_ASSERT): Synchronize with autoconf 2.64, in
117844         order to honor --enable-assert, rather than treating it as a
117845         synonym for --disable-assert.
117847 2008-12-08  Jim Meyering  <meyering@redhat.com>
117849         * lib/posixtm.c: Remove now-useless declaration of mktime.
117851         * build-aux/announce-gen (get_tool_versions): Accept .xz tarballs.
117853 2008-12-07  Bruno Haible  <bruno@clisp.org>
117855         * tests/test-lock.c (test_lock, test_rwlock, test_recursive_lock,
117856         test_once): Mark functions as static.
117857         * tests/test-tls.c (test_tls): Likewise.
117859 2008-12-07  Bruno Haible  <bruno@clisp.org>
117861         * lib/striconveha.h (uniconv_register_autodetect): Renamed from
117862         iconv_register_autodetect.
117864 2008-12-07  Jim Meyering  <meyering@redhat.com>
117866         posixtm.c: avoid a warning
117867         * lib/posixtm.c (posixtime): Don't initialize tm0.
117868         It's no longer needed to placate gcc4's -Wuninitialized,
117869         and the attempt to placate would elicit a new warning.
117871         unicodeio.c: mark unused parameters
117872         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
117873         (fallback_failure_callback): Likewise.
117875 2008-12-07  Bruno Haible  <bruno@clisp.org>
117877         * gnulib-tool (func_create_testdir): When building the tests
117878         subdirectory, ignore the modules gnumakefile and maintainer-makefile.
117879         Reported by Simon Josefsson.
117881 2008-12-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
117883         * doc/manywarnings.texi, doc/gnulib-intro.texi: Fix typos.
117885 2008-12-06  Bruno Haible  <bruno@clisp.org>
117887         * lib/c-stack.h (c_stack_action): Clarify possible side effects.
117888         Suggested by Eric Blake.
117890 2008-12-06  Bruno Haible  <bruno@clisp.org>
117892         Fix a c-stack test failure on MacOS X.
117893         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Require
117894         AC_CANONICAL_HOST. Define FAULT_YIELDS_SIGBUS. If set, install a signal
117895         handler for SIGBUS as well.
117896         * lib/c-stack.c (c_stack_action): If FAULT_YIELDS_SIGBUS is set,
117897         install a signal handler for SIGBUS as well.
117898         Reported by Bruce Dugan <bld0401@gmail.com> via Eric Blake.
117900 2008-12-06  Bruno Haible  <bruno@clisp.org>
117902         Advocacy documentation.
117903         * doc/gnulib-intro.texi (Benefits): New section.
117904         * doc/gnulib.texi: Update.
117906 2008-12-06  Bruno Haible  <bruno@clisp.org>
117908         Document the 'manywarnings' module.
117909         * doc/manywarnings.texi: New file.
117910         * doc/gnulib.texi: Include it.
117912 2008-12-05  Eric Blake  <ebb9@byu.net>
117914         tests: silence some gcc warnings
117915         * tests/test-getdate.c (LOG) [!DEBUG]: Mark no-op void.
117916         * tests/uniwidth/test-uc_width2.c (finish_interval): Avoid printf
117917         type mismatches.
117919 2008-12-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
117920             Bruno Haible  <bruno@clisp.org>
117922         * m4/openmp.m4 (AC_OPENMP): Do not define with Autoconf 2.62 or newer.
117924 2008-11-29  Jim Meyering  <meyering@redhat.com>
117926         unicodeio.c: mark unused parameters
117927         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
117928         (fallback_failure_callback): Likewise.
117930         fts: fix a thinko
117931         * lib/fts.c (s_ifmt_shift_bits): Remove function.  Not needed after all.
117932         (set_stat_type): Return S_IF*-valued "type" directly.
117933         Prompted by James Youngman's spotting a related bug.
117934         Confirmed by further testing through find.
117936         fts: provide dirent.d_type via FTSENT.fts_statp, when possible
117937         * lib/fts.c (D_TYPE): Define.
117938         (DT_UNKNOWN, DT_BLK, DT_CHR) [HAVE_STRUCT_DIRENT_D_TYPE]: Define.
117939         (DT_DIR, DT_FIFO, DT_LNK, DT_REG, DT_SOCK): Likewise.
117940         (s_ifmt_shift_bits): New function.
117941         (set_stat_type): New function.
117942         (fts_build): When not calling fts_stat, call set_stat_type
117943         to propagate dirent.d_type info to fts_read caller.
117944         * lib/fts_.h (FTSENT) [FTS_DEFER_STAT]: Mention that
117945         fts_statp->st_mode type information may be valid.
117947 2008-11-28  Simon Josefsson  <simon@josefsson.org>
117949         * lib/sys_time.in.h: Add extern "C" block for C++.  Suggested by
117950         Brian Dessent <brian@dessent.net>.  Reported by Sam Steingold
117951         <sds@gnu.org>.
117953 2008-11-20  Bruno Haible  <bruno@clisp.org>
117955         Attempt to work around an AIX 5.3, 6.1 compiler bug with include_next.
117956         * lib/math.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of
117957         INCLUDE_NEXT.
117958         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also
117959         INCLUDE_NEXT_AS_FIRST_DIRECTIVE.
117960         * modules/math (Makefile.am): Substitute
117961         INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of INCLUDE_NEXT.
117962         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
117964 2008-11-18  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
117965             Bruno Haible  <bruno@clisp.org>
117967         * lib/stdint.in.h: Define all type macros so that their expansion is
117968         a single typedef'ed token. Fixes a compilation failure in Boost which
117969         does "using ::int8_t;".
117971 2008-11-18  Simon Josefsson  <simon@josefsson.org>
117973         * m4/manywarnings.m4: New file with gl_MANYWARN_COMPLEMENT and
117974         gl_MANYWARN_ALL_GCC.
117975         * m4/warnings.m4: Removed gl_WARN_SUPPORTED and
117976         gl_WARN_COMPLEMENT.  Suggested by Bruno Haible <bruno@clisp.org>.
117977         * modules/manywarnings: New file.
117978         * MODULES.html.sh: Mention manywarnings module.
117980 2008-11-18  Bruno Haible  <bruno@clisp.org>
117982         * doc/gnulib-tool.texi (Unit tests): New section.
117984 2008-11-18  Simon Josefsson  <simon@josefsson.org>
117986         * top/maint.mk (refresh-po): Fix sed regexp to avoid problems with
117987         paths like 'lib/po/foo.po'.
117989 2008-11-17  Simon Josefsson  <simon@josefsson.org>
117991         * m4/warnings.m4: Improve code.  Reported by Ralf Wildenhues
117992         <Ralf.Wildenhues@gmx.de> and Paolo Bonzini <bonzini@gnu.org>.
117994 2008-11-17  Simon Josefsson  <simon@josefsson.org>
117996         * m4/warnings.m4: Use CPPFLAGS to really check whether the
117997         parameter works.
117999 2008-11-17  Simon Josefsson  <simon@josefsson.org>
118001         * m4/warnings.m4: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.
118003 2008-11-17  Bruce Korb  <bkorb@gnu.org>
118005         * modules/parse-duration-tests: New file.
118006         * tests/test-parse-duration.sh: New file.
118007         * tests/test-parse-duration.c: New file.
118009         New module 'parse-duration'.
118010         * lib/parse-duration.h: New file.
118011         * lib/parse-duration.c: New file.
118012         * modules/parse-duration: New file.
118014 2008-11-17  Bruno Haible  <bruno@clisp.org>
118016         * tests/test-select-out.sh: Comment out the first pipe test.
118017         Reported by Simon Josefsson.
118019 2008-11-17  Bruno Haible  <bruno@clisp.org>
118021         * modules/getaddrinfo (Depends-on): Add servent, hostent.
118022         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_SERVENT and
118023         gl_HOSTENT.
118025 2008-11-17  Bruno Haible  <bruno@clisp.org>
118027         * m4/sockets.m4 (gl_SOCKETS): After trying -lsocket, try also
118028         -lnetwork and -lnet. Needed for Haiku and BeOS.
118030 2008-11-16  Bruno Haible  <bruno@clisp.org>
118032         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix indentation.
118034 2008-11-16  Bruno Haible  <bruno@clisp.org>
118036         Avoid test failure on Haiku.
118037         * tests/test-fsync.c: Include <errno.h>.
118038         (main): Don't require that fsync (0) fails.
118040 2008-11-15  Bruno Haible  <bruno@clisp.org>
118042         New module 'hostent'.
118043         * modules/hostent: New file.
118044         * m4/hostent.m4: New file, based on code in m4/getaddrinfo.m4.
118046 2008-11-15  Bruno Haible  <bruno@clisp.org>
118048         New module 'servent'.
118049         * modules/servent: New file.
118050         * m4/servent.m4: New file, based on code in m4/getaddrinfo.m4.
118052 2008-11-15  Bruno Haible  <bruno@clisp.org>
118054         Avoid generating same test program with two different rules.
118055         * modules/frexp-nolibm-tests (Makefile.am): Rename test program from
118056         test-frexp to test-frexp-nolibm.
118057         * modules/frexpl-nolibm-tests (Makefile.am): Rename test program from
118058         test-frexpl to test-frexpl-nolibm.
118060 2008-11-15  Bruno Haible  <bruno@clisp.org>
118062         * modules/frexpl-tests (Makefile.am): Link test-frexpl with
118063         $(FREXPL_LIBM).
118065 2008-11-15  Bruno Haible  <bruno@clisp.org>
118067         * lib/netdb.in.h: Activate the definitions also when the system's
118068         <netdb.h> has 'struct addrinfo'.
118069         * m4/netdb_h.m4 (gl_HEADER_NETDB): Replace netdb.h also when it lacks
118070         EAI_OVERFLOW or AI_NUMERICSERV.
118071         * doc/posix-headers/netdb.texi: Document the problem.
118073 2008-11-15  Bruno Haible  <bruno@clisp.org>
118075         * tests/test-sched.c: Test also the existence of the SCHED_* macros.
118077         Make the 'sched' module work on platforms where <sched.h> exists but
118078         is incomplete (such as Haiku).
118079         * lib/sched.in.h; Include the system's <sched.h> if it exists.
118080         (SCHED_FIFO, SCHED_RR, SCHED_OTHER): New macros.
118081         * m4/sched_h.m4 (gl_SCHED_H): Test whether <sched.h> exists and also
118082         defines SCHED_FIFO, SCHED_RR, SCHED_OTHER. Set HAVE_SCHED_H,
118083         HAVE_STRUCT_SCHED_PARAM.
118084         * modules/sched (Depends-on): Add include_next.
118085         (Makefile.am): Substitute HAVE_SCHED_H, INCLUDE_NEXT,
118086         PRAGMA_SYSTEM_HEADER, NEXT_SCHED_H, HAVE_STRUCT_SCHED_PARAM.
118087         * doc/posix-headers/sched.texi: Document the issue.
118089 2008-11-13  Jim Meyering  <meyering@redhat.com>
118091         test-argp-2: avoid test failure when PACKAGE_BUGREPORT is defined
118092         * tests/test-argp-2.sh: When PACKAGE_BUGREPORT was defined, this
118093         test would fail due to the difference in the Report bugs to ...
118094         line.  The expected address is empty, "<>", while the actual
118095         would contain e.g., "<bug-tar@gnu.org>".  Filter out any address.
118097 2008-11-12  Bruno Haible  <bruno@clisp.org>
118099         lstat: don't compile lstat.c on systems lacking lstat
118100         * m4/lstat.m4 (gl_FUNC_LSTAT): Don't compile lstat.c on systems
118101         which don't have lstat; this is handled by lib/sys_stat.in.h already.
118102         Reported by Daniel P. Berrange via Jim Meyering.
118104 2008-11-12  Jim Meyering  <meyering@redhat.com>
118106         * lib/unicodeio.c (unicode_to_mb): Correct spelling of u8_uctomb.
118108 2008-11-12  Simon Josefsson  <simon@josefsson.org>
118110         * modules/warnings (configure.ac): Do AC_SUBST([WARN_CFLAGS]) here
118111         instead.
118113 2008-11-12  Bruno Haible  <bruno@clisp.org>
118115         * lib/unicodeio.c: Include unistr.h.
118116         (utf8_wctomb): Remove function.
118117         (unicode_to_mb): Use utf8_uctomb instead of utf8_wctomb.
118119 2008-11-12  Simon Josefsson  <simon@josefsson.org>
118121         * m4/warnings.m4 (gl_WARN_INIT): Remove, suggested by Ralf
118122         Wildenhues <Ralf.Wildenhues@gmx.de> and Bruno Haible
118123         <bruno@clisp.org>.
118124         * modules/warnings (configure.ac): Don't call gl_WARN_INIT.
118126 2008-11-12  Simon Josefsson  <simon@josefsson.org>
118128         * doc/warnings.texi: New file, from Bruno Haible <bruno@clisp.org>.
118129         * doc/gnulib.texi: Add section for warnings.
118131 2008-11-11  Bruno Haible  <bruno@clisp.org>
118133         * lib/sockets.h: Add a comment.
118135 2008-11-11  Karl Berry  <karl@gnu.org>
118137         * config/srclist.txt (fdl.texi): add, syncing from gnustandards.
118139 2008-11-11  Eric Blake  <ebb9@byu.net>
118141         fdl.texi: avoid git symlinks
118142         * doc/fdl.texi: Copy, rather than link, fdl-1.3.texi.
118144 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
118146         * m4/warnings.m4 (gl_WARN_ADD): Don't AC_SUBST the empty string.
118148 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
118150         * m4/warnings.m4 (gl_WARN_INIT): Substitute WARN_CFLAGS.
118151         (gl_WARN_ADD): Substitute $2 if literal.
118153 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
118155         * m4/warning.m4: Remove.
118157 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
118159         * m4/warnings.m4: Almost complete rewrite. :-)
118161 2008-11-10  Simon Josefsson  <simon@josefsson.org>
118163         * modules/warnings: New module.
118164         * m4/warnings.m4: New file.
118165         * MODULES.html.sh: Mention warnings module.
118166         With review improvements from Paolo Bonzini <bonzini@gnu.org> and
118167         Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
118169 2008-11-10  Eric Blake  <ebb9@byu.net>
118171         fdl.texi: make a symlink to the latest version
118172         * doc/standards.texi: Revert today's earlier change.
118173         * doc/fdl-1.2.texi: Rename from old fdl.texi...
118174         * doc/fdl.texi: ...and replace this with a symlink to the newer
118175         fdl-1.3.texi.
118177 2008-11-10  Bruno Haible  <bruno@clisp.org>
118179         * tests/test-select-fd.c (main): Accept the result file name as fourth
118180         argument.
118181         * tests/test-select-in.sh: Pass t-select-in.tmp as fourth argument.
118182         * tests/test-select-out.sh: Pass t-select-out.tmp as fourth argument.
118184 2008-11-10  Bruno Haible  <bruno@clisp.org>
118186         * lib/netdb.in.h: Use HAVE_STRUCT_ADDRINFO, HAVE_DECL_GETADDRINFO,
118187         HAVE_DECL_FREEADDRINFO, HAVE_DECL_GAI_STRERROR, HAVE_DECL_GETNAMEINFO
118188         as autoconf-substituted macros.
118189         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Initialize these variables to 1.
118190         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require
118191         gl_NETDB_H_DEFAULTS. Set these variables.
118192         * modules/netdb (Makefile.am): Substitute these variables.
118194 2008-11-10  Eric Blake  <ebb9@byu.net>
118196         standards.texi: include correct file for FDL 1.3
118197         * doc/standards.texi (GNU Free Documentation License): Change
118198         include file to pull in FDL 1.3, not 1.2.
118200         fdl.texi: revert accidental change to license
118201         * doc/fdl.texi: This is FDL 1.2, not 1.3.
118203 2008-11-10  Bruno Haible  <bruno@clisp.org>
118205         * m4/printf.m4 (gl_PRINTF_ENOMEM): Guess yes on Haiku. Use the
118206         cross-compiling guesses also when the native compile gives no result.
118208 2008-11-10  Bruno Haible  <bruno@clisp.org>
118210         * lib/spawni.c (__spawni): Force variable into the stack.
118212 2008-11-10  Bruno Haible  <bruno@clisp.org>
118214         Add support for Haiku.
118215         * lib/fbufmode.c (fbufmode): Test a symbol that is not only defined on
118216         glibc and BeOS, but also on Haiku.
118217         * lib/fpurge.c (fpurge): Likewise.
118218         * lib/freadable.c (freadable): Likewise.
118219         * lib/freadahead.c (freadahead): Likewise.
118220         * lib/freading.c (freading): Likewise.
118221         * lib/freadptr.c (freadptr): Likewise.
118222         * lib/freadseek.c (freadptrinc): Likewise.
118223         * lib/fseeko.c (rpl_fseeko): Likewise.
118224         * lib/fseterr.c (fseterr): Likewise.
118225         * lib/fwritable.c (fwritable): Likewise.
118226         * lib/fwriting.c (fwriting): Likewise.
118227         Reported by Ingo Weinhold <ingo_weinhold@gmx.de>.
118229 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
118231         * lib/config.charset: Treat Haiku like BeOS.
118233 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
118235         * lib/binary-io.h (O_BINARY, O_TEXT): Treat Haiku like BeOS.
118236         * lib/fcntl.in.h (O_BINARY, O_TEXT): Likewise.
118238 2008-11-08  Bruno Haible  <bruno@clisp.org>
118240         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Avoid using AC_CHECK_DECL inside
118241         AC_CACHE_CHECK.
118243 2008-11-08  Bruno Haible  <bruno@clisp.org>
118245         * modules/select-tests (configure.ac): Check for unistd.h, sys/wait.h.
118247 2008-11-08  Bruno Haible  <bruno@clisp.org>
118249         * tests/test-select-fd.c: New file.
118250         * tests/test-select-in.sh: New file.
118251         * tests/test-select-out.sh: New file.
118252         * tests/test-select-stdin.c: New file.
118253         * modules/select-tests (Files): Add the new files.
118254         (Depends-on): Add gettimeofday.
118255         (Makefile.am): Add test-select-in.sh, test-select-out.sh to TESTS.
118256         Set TESTS_ENVIRONMENT. Add test-select-fd, test-select-stdin to
118257         check_PROGRAMS. Define test_select_fd_LDADD, test_select_stdin_LDADD.
118259 2008-11-06  Alexander V. Lukyanov  <lav@netis.ru>
118260             Bruno Haible  <bruno@clisp.org>
118262         * lib/sys_stat.in.h: Enclose function definitions in extern "C".
118264 2008-10-12  Giuseppe Scrivano  <gscrivano@gnu.org>
118266         * build-aux/pmccabe2html: Added support for C++ source files.
118268 2008-11-05  Ben Pfaff  <blp@gnu.org>
118270         Fix lib/close.c build on Windows.
118271         * modules/close (Files): Add lib/w32sock.h.
118273 2008-11-05  Joel E. Denny  <jdenny@ces.clemson.edu>
118275         Accept Bison's NEWS format.
118276         * build-aux/announce-gen (print_news_deltas): Tweak
118277         $re_prefix.
118279 2008-11-04  Bruno Haible  <bruno@clisp.org>
118281         * modules/random_r (Maintainer): Add glibc.
118283 2008-11-04  Simon Josefsson  <simon@josefsson.org>
118285         * doc/alloca-opt.texi: Change license to GFDLv1.3+, as suggested
118286         by karl@freefriends.org (Karl Berry).
118287         * doc/alloca.texi: Likewise.
118288         * doc/c-ctype.texi: Likewise.
118289         * doc/c-strcase.texi: Likewise.
118290         * doc/c-strcaseeq.texi: Likewise.
118291         * doc/c-strcasestr.texi: Likewise.
118292         * doc/c-strstr.texi: Likewise.
118293         * doc/c-strtod.texi: Likewise.
118294         * doc/c-strtold.texi: Likewise.
118295         * doc/ctime.texi: Likewise.
118296         * doc/error.texi: Likewise.
118297         * doc/fdl.texi: Likewise.
118298         * doc/gcd.texi: Likewise.
118299         * doc/getdate.texi: Likewise.
118300         * doc/gnulib-intro.texi: Likewise.
118301         * doc/gnulib-tool.texi: Likewise.
118302         * doc/gnulib.texi: Likewise.
118303         * doc/inet_ntoa.texi: Likewise.
118304         * doc/maintain.texi: Likewise.
118305         * doc/make-stds.texi: Likewise.
118306         * doc/quote.texi: Likewise.
118307         * doc/regexprops-generic.texi: Likewise.
118308         * doc/standards.texi: Likewise.
118309         * doc/verify.texi: Likewise.
118310         * doc/visibility.texi: Likewise.
118311         * doc/gnulib.texi (GNU Free Documentation License): Include
118312         fdl-1.3.texi instead of fdl.texi.
118314 2008-11-04  Simon Josefsson  <simon@josefsson.org>
118316         * doc/fdl-1.3.texi: New file, from
118317         <http://www.gnu.org/licenses/fdl-1.3.texi>.
118318         * modules/fdl-1.3: Add.
118319         * MODULES.html.sh: Add fdl-1.3.
118321 2008-11-03  Bruno Haible  <bruno@clisp.org>
118323         Make determination of absolute name of header file work with AIX xlc.
118324         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Require
118325         AC_CANONICAL_HOST. On AIX, use "$CPP -C" rather than "$CPP" for
118326         preprocessing.
118327         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
118328         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
118330 2008-11-03  Simon Josefsson  <simon@josefsson.org>
118332         * top/maint.mk (COVERAGE_CCOPTS): Use --coverage instead of
118333         -fprofile-arcs -ftest-coverage.  Suggested by Ludovic Courtès
118334         <ludo@gnu.org>.
118336 2008-11-02  Bruno Haible  <bruno@clisp.org>
118338         Mark 'strpbrk' obsolete.
118339         * modules/strpbrk (Status, Notice): New sections.
118340         * modules/strtok_r (Depends-on): Add strpbrk.
118342 2008-11-02  Bruno Haible  <bruno@clisp.org>
118344         Mark 'strdup' obsolete.
118345         * modules/strdup (Status, Notice): New sections.
118346         * modules/findprog (Depends-on): Add strdup.
118347         * modules/getaddrinfo (Depends-on): Likewise.
118348         * modules/localename (Depends-on): Likewise.
118349         * modules/relocatable-lib (Depends-on): Likewise.
118350         * modules/relocatable-lib-lgpl (Depends-on): Likewise.
118351         * modules/relocatable-prog (Depends-on): Likewise.
118352         * modules/trim (Depends-on): Likewise.
118353         * modules/unictype/gen-ctype (Depends-on): Likewise.
118354         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
118356 2008-11-02  Bruno Haible  <bruno@clisp.org>
118358         Mark 'strcspn' obsolete.
118359         * modules/strcspn (Status, Notice): New sections.
118361 2008-11-02  Bruno Haible  <bruno@clisp.org>
118363         Mark 'rmdir' obsolete.
118364         * modules/rmdir (Status, Notice): New sections.
118365         * modules/clean-temp (Depends-on): Add rmdir.
118366         * modules/openat (Depends-on): Likewise.
118368 2008-11-02  Bruno Haible  <bruno@clisp.org>
118370         Mark 'raise' obsolete.
118371         * modules/raise (Status, Notice): New sections.
118372         (Include): Specify <signal.h>.
118373         * modules/stdio (Depends-on): Add raise.
118374         * modules/write (Depends-on): Likewise.
118376 2008-11-02  Bruno Haible  <bruno@clisp.org>
118378         Mark 'memset' obsolete.
118379         * modules/memset (Status, Notice): New sections.
118381 2008-11-02  Bruno Haible  <bruno@clisp.org>
118383         Mark 'memmove' obsolete.
118384         * modules/memmove (Status, Notice): New sections.
118385         * modules/argp (Depends-on): Add memmove.
118386         * modules/argz (Depends-on): Likewise.
118387         * modules/canonicalize (Depends-on): Likewise.
118388         * modules/canonicalize-lgpl (Depends-on): Likewise.
118389         * modules/fts (Depends-on): Likewise.
118390         * modules/getcwd (Depends-on): Likewise.
118391         * modules/human (Depends-on): Likewise.
118392         * modules/regex (Depends-on): Likewise.
118393         * modules/striconveh (Depends-on): Likewise.
118394         * modules/trim (Depends-on): Likewise.
118395         * modules/unistr/u8-move (Depends-on): Likewise.
118396         * modules/unistr/u16-move (Depends-on): Likewise.
118397         * modules/unistr/u32-move (Depends-on): Likewise.
118399 2008-11-02  Bruno Haible  <bruno@clisp.org>
118401         Mark 'memcpy' obsolete.
118402         * modules/memcpy (Status, Notice): New sections.
118404 2008-11-02  Bruno Haible  <bruno@clisp.org>
118406         Mark 'memcmp' obsolete.
118407         * modules/memcmp (Status, Notice): New sections.
118408         * modules/argmatch (Depends-on): Add memchr.
118409         * modules/backupfile (Depends-on): Likewise.
118410         * modules/c-strcasestr (Depends-on): Likewise.
118411         * modules/crypto/des (Depends-on): Likewise.
118412         * modules/csharpcomp (Depends-on): Likewise.
118413         * modules/fnmatch (Depends-on): Likewise.
118414         * modules/git-merge-changelog (Depends-on): Likewise.
118415         * modules/isnand (Depends-on): Likewise.
118416         * modules/isnand-nolibm (Depends-on): Likewise.
118417         * modules/isnanf (Depends-on): Likewise.
118418         * modules/isnanf-nolibm (Depends-on): Likewise.
118419         * modules/isnanl (Depends-on): Likewise.
118420         * modules/isnanl-nolibm (Depends-on): Likewise.
118421         * modules/mbchar (Depends-on): Likewise.
118422         * modules/memcoll (Depends-on): Likewise.
118423         * modules/quotearg (Depends-on): Likewise.
118424         * modules/regex (Depends-on): Likewise.
118425         * modules/relocatable-prog (Depends-on): Likewise.
118426         * modules/same (Depends-on): Likewise.
118427         * modules/signbit (Depends-on): Likewise.
118428         * modules/strcasestr-simple (Depends-on): Likewise.
118429         * modules/unictype/gen-ctype (Depends-on): Likewise.
118430         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
118431         * modules/uniname/uniname (Depends-on): Likewise.
118432         * modules/unistr/u8-cmp (Depends-on): Likewise.
118434 2008-11-02  Bruno Haible  <bruno@clisp.org>
118436         Mark 'memchr' obsolete.
118437         * modules/memchr (Status, Notice): New sections.
118438         * modules/argp (Depends-on): Add memchr.
118439         * modules/base64 (Depends-on): Likewise.
118440         * modules/c-strcasestr (Depends-on): Likewise.
118441         * modules/chdir-long (Depends-on): Likewise.
118442         * modules/fnmatch (Depends-on): Likewise.
118443         * modules/getsubopt (Depends-on): Likewise.
118444         * modules/git-merge-changelog (Depends-on): Likewise.
118445         * modules/glob (Depends-on): Likewise.
118446         * modules/strcasestr-simple (Depends-on): Likewise.
118447         * modules/strnlen (Depends-on): Likewise.
118449 2008-11-02  Bruno Haible  <bruno@clisp.org>
118451         Mark 'atexit' obsolete.
118452         * modules/atexit (Status, Notice): New sections.
118453         * modules/chdir-long (Depends-on): Add atexit.
118454         * modules/wait-process (Depends-on): Likewise.
118456 2008-11-02  Bruno Haible  <bruno@clisp.org>
118458         * gnulib-tool: New option --with-obsolete.
118459         (func_usage): Document it.
118460         (func_modules_transitive_closure): Drop obsolete dependencies if
118461         incobsolete is not true.
118462         (func_import): Read and save the incobsolete variable to the cache.
118464 2008-11-02  Bruno Haible  <bruno@clisp.org>
118466         * modules/TEMPLATE-EXTENDED: New field 'Status'.
118467         * gnulib-tool: New option --extract-status.
118468         (func_usage): Document it.
118469         (sed_extract_prog): Recognize it.
118470         (func_get_status): New function.
118472 2008-10-30  Simon Josefsson  <simon@josefsson.org>
118474         * modules/sockets (License): Change from LGPL to LGPLv2+.
118476 2008-10-28  Simon Josefsson  <simon@josefsson.org>
118478         * top/maint.mk: Add coverage rules, inspired by scripts in gnupdf.
118480 2008-10-28  Simon Josefsson  <simon@josefsson.org>
118482         * MODULES.html.sh (Support for systems lacking POSIX:2001):
118483         Mention times and sys_times.
118484         * modules/sys_times, modules/sys_times-tests: New modules.
118485         * modules/times, modules/times-tests: Likewise
118486         * m4/sys_times_h.m4: New file.
118487         * lib/sys_times.in.h: Likewise
118488         * lib/times.c: Likewise.
118489         * tests/test-sys_times.c: Likewise.
118490         * tests/test-times.c: Likewise.
118491         * doc/posix-headers/sys_times.texi: Update.
118492         * doc/posix-functions/times.texi: Update.
118494 2008-10-28  Jim Meyering  <meyering@redhat.com>
118496         * modules/tempname (Depends-on): Add lstat.
118498         * modules/lstat (License): Relicense: LGPL -> LGPLv2+.
118500 2008-10-28  Simon Josefsson  <simon@josefsson.org>
118502         * gnulib-tool (func_emit_tests_Makefile_am): Revert last commit.
118503         * modules/argp-tests (test_argp_LDADD): Set EXEEXT here instead,
118504         using idiom used elsewhere in gnulib.
118506 2008-10-27  Jim Meyering  <meyering@redhat.com>
118508         * modules/gethostname (License): Relicense: LGPL -> LGPLv2+.
118510 2008-10-27  Simon Josefsson  <simon@josefsson.org>
118512         * gnulib-tool (func_emit_tests_Makefile_am): Set EXEEXT in
118513         TESTS_ENVIRONMENT, for shell scripts that needs to call built
118514         programs.
118515         * tests/test-argp-2.sh: Use $EXEEXT when needed.
118517 2008-10-27  Simon Josefsson  <simon@josefsson.org>
118519         * lib/sys_stat.in.h (lstat): Fix declaration for mingw.
118521 2008-10-27  Bruno Haible  <bruno@clisp.org>
118523         * tests/test-lstat.c: Include <stdio.h>.
118525 2008-10-27  Simon Josefsson  <simon@josefsson.org>
118527         * modules/lstat-tests: New module.
118528         * tests/test-lstat.c: New file.
118530 2008-10-26  Jim Meyering  <meyering@redhat.com>
118532         * lib/mkdir.c (rpl_mkdir) [_WIN32...]: Mark mode as an unused parameter.
118534 2008-10-26  Simon Josefsson  <simon@josefsson.org>
118535             Bruno Haible  <bruno@clisp.org>
118537         Fix a clash between the type DATADIR on Windows and the macro DATADIR.
118538         * modules/configmake (Include): Add a note that the include must come
118539         after all system headers.
118540         * lib/javaversion.c: Include configmake.h after all other includes.
118542 2008-10-26  Bruno Haible  <bruno@clisp.org>
118544         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Set default of
118545         HAVE_STRUCT_RANDOM_DATA to 1.
118546         (gl_STDLIB_H): Simplify.
118548 2008-10-26  Simon Josefsson  <simon@josefsson.org>
118550         * m4/stdlib_h.m4: Check for struct random_data.  Initialize and
118551         substitute HAVE_STRUCT_RANDOM_DATA.
118552         * lib/stdlib.in.h [!HAVE_STRUCT_RANDOM_DATA]: Provide struct
118553         random_data.
118554         * modules/stdlib (Makefile.am): Substitute
118555         HAVE_STRUCT_RANDOM_DATA.
118557 2008-10-26  Simon Josefsson  <simon@josefsson.org>
118559         * doc/gnulib.texi (@copying): Use GFDLv1.2+.
118560         * doc/gnulib-intro.texi (Copyright): Likewise.
118562 2008-10-26  Simon Josefsson  <simon@josefsson.org>
118564         * doc/gnulib.texi (Header files): C++ fixes, based on Bruno's
118565         findings.
118567 2008-10-25  Ben Pfaff  <blp@cs.stanford.edu>
118568             Bruno Haible  <bruno@clisp.org>
118570         * lib/unistd.in.h: Include <winsock2.h>.
118571         (socket, connect,accept, bind, getpeername, getsockname, getsockopt,
118572         listen, recv, send, recvfrom, sendto, setsockopt, shutdown, select):
118573         Provide dummy declarations.
118574         (gethostname): Override.
118575         * lib/sys_socket.in.h (gethostname): Provide dummy declaration.
118576         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Invoke
118577         gl_PREREQ_SYS_H_WINSOCK2.
118578         * modules/gethostname (Files): Add m4/sys_socket_h.m4.
118579         * doc/posix-functions/gethostname.texi: More details.
118581 2008-10-25  Bruno Haible  <bruno@clisp.org>
118583         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
118584         gl_UNISTD_H_DEFAULTS, gl_SYS_IOCTL_H_DEFAULTS only if they exist.
118585         * modules/sys_socket (Files): Remove m4/unistd_h.m4, m4/sys_ioctl_h.m4.
118587         * lib/sys_socket.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); Move macro from
118588         here ...
118589         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); ... to here.
118590         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Remove invocation of
118591         gl_UNISTD_H_DEFAULTS.
118593 2008-10-25  Eric Blake  <ebb9@byu.net>
118595         signbit: avoid spurious compiler failure
118596         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Move non-constant
118597         declarations inside function.
118599 2008-10-24  Simon Josefsson  <simon@josefsson.org>
118600             Bruno Haible  <bruno@clisp.org>
118602         * lib/stdlib.in.h (@GNULIB_RANDOM_R@): Include stdint.h.
118603         * modules/random_r (Depends-on): Add stdint.
118605 2008-10-24  Bruno Haible  <bruno@clisp.org>
118607         * modules/intprops (License): Change to LGPLv2+, with approval by Paul
118608         Eggert.
118609         * modules/strerror (License): Likewise.
118611 2008-10-24  Jim Meyering  <meyering@redhat.com>
118613         sys_socket: fix typo that inhibited expansion of @GNULIB_SEND@
118614         * modules/sys_socket (Depends-on) [Depends-on]: Fix typo.
118616 2008-10-24  Eric Blake  <ebb9@byu.net>
118618         getgroups: fix compilation when getgroups is available
118619         * lib/getgroups.c (includes): Include <unistd.h> for getgroups,
118620         but with <config.h> override of getgroups disabled.
118622 2008-10-24  Simon Josefsson  <simon@josefsson.org>
118624         * doc/gnulib.texi (Header files): Add note about C++ problems.
118625         Explained by Bruno Haible <bruno@clisp.org>.
118627 2008-10-23  Bruno Haible  <bruno@clisp.org>
118629         Define a dummy SA_NODEFER macro on Interix.
118630         * lib/signal.in.h (SA_NODEFER): Define fallback.
118631         Reported by Aleksey Cheusov <cheusov@tut.by> via
118632         Thomas Klausner <wiz@netbsd.org> and Eric Blake.
118634 2008-10-23  Bruno Haible  <bruno@clisp.org>
118636         * modules/freadahead (License): Change to LGPLv2+.
118637         Suggested by Simon Josefsson.
118639 2008-10-23  Jim Meyering  <meyering@redhat.com>
118641         random_r: new module
118642         * modules/random_r: New file.
118643         * m4/random_r.m4: New file.
118644         * lib/random_r.c: New file, from glibc.
118645         * modules/random_r-tests: New file.
118646         * tests/test-random_r.c: New file.
118647         * lib/stdlib.in.h (srandom_r, initstate_r, setstate_r, random_r):
118648          Declare.
118649         (RAND_MAX): Define.
118650         * m4/stdlib_h.m4: Define and AC_SUBST GNULIB_RANDOM_R and HAVE_RANDOM_R.
118651         * modules/stdlib: Substitute them, too.
118652         * MODULES.html.sh (Extra functions based on POSIX:2001) [Misc]: Add it.
118653         * doc/glibc-functions/initstate_r.texi: Mention the new module.
118654         * doc/glibc-functions/random_r.texi: Likewise.
118655         * doc/glibc-functions/setstate_r.texi: Likewise.
118656         * doc/glibc-functions/srandom_r.texi: Likewise.
118657         * config/srclist.txt: Mention it.
118659 2008-10-23  David Lutterkort  <lutter@redhat.com>
118661         * modules/selinux-h: Search for LIB_SELINUX and mark it as a
118662         link requirement
118664 2008-10-23  Jim Meyering  <meyering@redhat.com>
118666         selinux-h: mark parameters of stub functions as intentionally unused
118667         * lib/se-selinux.in.h: Mark parameters as _UNUSED_PARAMETER_.
118668         * lib/se-context.in.h: Likewise.
118670 2008-10-22  Simon Josefsson  <simon@josefsson.org>
118672         * lib/sys_socket.in.h (FD_ISSET): Fix warnings under mingw.
118674 2008-10-22  Simon Josefsson  <simon@josefsson.org>
118676         * m4/getgroups.m4: Avoid invoking test with wrong parameters.
118678 2008-10-22  Eric Blake  <ebb9@byu.net>
118680         glthread/thread: avoid compiler warning
118681         * lib/glthread/thread.c (gl_thread_exit_func) [USE_WIN32_THREADS]:
118682         Add unreachable abort to silence compiler.
118684 2008-10-22  Eric Blake  <ebb9@byu.net>
118686         netdb: also supply struct addrinfo for cygwin 1.5.x
118687         * m4/netdb_h.m4 (gl_HEADER_NETDB): Check for incomplete header on
118688         older cygwin.
118689         * lib/netdb.in.h [!HAVE_STRUCT_ADDRINFO]: Also supply contents for
118690         cygwin.
118691         * doc/posix-headers/netdb.texi (netdb.h): Document this.
118693 2008-10-22  Bruno Haible  <bruno@clisp.org>
118695         * users.txt: Update entry about pspp.
118697 2008-10-21  Bruno Haible  <bruno@clisp.org>
118699         Simplification.
118700         * lib/sys_socket.in.h (_gl_close_fd_maybe_socket): Remove declaration.
118701         * lib/close.c (_gl_close_fd_maybe_socket): Make static.
118703         Simplification.
118704         * lib/ioctl.c (ioctl): Don't undefine.
118705         * lib/socket.c (socket): Don't undefine.
118707         Remove unused module indicator macros.
118708         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Don't define
118709         GNULIB_$1 as a C macro.
118711         * doc/posix-functions/close.texi: Undo last change.
118712         * doc/posix-functions/ioctl.texi: Merge the two paragraphs about
118713         Windows platforms.
118715 2008-10-21  Bruno Haible  <bruno@clisp.org>
118717         Add gethostname() declaration to <unistd.h>.
118718         * lib/unistd.in.h (gethostname): New declaration.
118719         * lib/gethostname.c: Include <unistd.h>.
118720         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Require
118721         gl_UNISTD_H_DEFAULTS. Set HAVE_GETHOSTNAME.
118722         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETHOSTNAME
118723         and HAVE_GETHOSTNAME.
118724         * modules/gethostname (Depends-on): Add unistd.
118725         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
118726         (Include): Specify <unistd.h>.
118727         * modules/unistd (Makefile.am): Substitute GNULIB_GETHOSTNAME and
118728         HAVE_GETHOSTNAME.
118729         * tests/test-gethostname.c: Include <unistd.h> first.
118731 2008-10-21  Bruno Haible  <bruno@clisp.org>
118733         * modules/poll-tests (Depends-on): Add sys_ioctl, ioctl.
118734         * modules/select-tests (Depends-on): Likewise.
118735         Reported by Simon Josefsson.
118737 2008-10-21  Simon Josefsson  <simon@josefsson.org>
118739         * lib/close.c: Add _gl_close_fd_maybe_socket from winsock.c.
118740         * lib/accept.c: New file, based on winsock.c.
118741         * lib/bind.c: New file, based on winsock.c.
118742         * lib/connect.c: New file, based on winsock.c.
118743         * lib/getpeername.c: New file, based on winsock.c.
118744         * lib/getsockname.c: New file, based on winsock.c.
118745         * lib/getsockopt.c: New file, based on winsock.c.
118746         * lib/ioctl.c: New file, based on winsock.c.
118747         * lib/listen.c: New file, based on winsock.c.
118748         * lib/recv.c: New file, based on winsock.c.
118749         * lib/recvfrom.c: New file, based on winsock.c.
118750         * lib/send.c: New file, based on winsock.c.
118751         * lib/sendto.c: New file, based on winsock.c.
118752         * lib/setsockopt.c: New file, based on winsock.c.
118753         * lib/shutdown.c: New file, based on winsock.c.
118754         * lib/socket.c: New file, based on winsock.c.
118755         * lib/w32sock.h: New file, based on winsock.c.
118756         * lib/winsock.c: Remove file.
118757         * modules/accept: Likewise.
118758         * modules/bind: Likewise.
118759         * modules/connect: Likewise.
118760         * modules/getpeername: Likewise.
118761         * modules/getsockname: Likewise.
118762         * modules/getsockopt: Likewise.
118763         * modules/ioctl: Likewise.
118764         * modules/listen: Likewise.
118765         * modules/recv: Likewise.
118766         * modules/recvfrom: Likewise.
118767         * modules/send: Likewise.
118768         * modules/sendto: Likewise.
118769         * modules/setsockopt: Likewise.
118770         * modules/shutdown: Likewise.
118771         * modules/socket: Use socket.c instead of winsock.c.
118772         * modules/sys_socket: Remove (unneeded?) dependency on winsock.c.
118773         * doc/posix-functions/accept.texi: Doc fix.
118774         * doc/posix-functions/bind.texi: Doc fix.
118775         * doc/posix-functions/close.texi: Doc fix.
118776         * doc/posix-functions/connect.texi: Doc fix.
118777         * doc/posix-functions/getpeername.texi: Doc fix.
118778         * doc/posix-functions/getsockname.texi: Doc fix.
118779         * doc/posix-functions/getsockopt.texi: Doc fix.
118780         * doc/posix-functions/ioctl.texi: Doc fix.
118781         * doc/posix-functions/listen.texi: Doc fix.
118782         * doc/posix-functions/recv.texi: Doc fix.
118783         * doc/posix-functions/recvfrom.texi: Doc fix.
118784         * doc/posix-functions/send.texi: Doc fix.
118785         * doc/posix-functions/sendto.texi: Doc fix.
118786         * doc/posix-functions/setsockopt.texi: Doc fix.
118787         * doc/posix-functions/shutdown.texi: Doc fix.
118788         * doc/posix-functions/socket.texi: Doc fix.
118790 2008-10-20  Bruno Haible  <bruno@clisp.org>
118792         Take into account the role of SIGABRT_COMPAT on Windows 2008.
118793         * lib/sigprocmask.c (SIGABRT_COMPAT, SIGABRT_COMPAT_MASK): New macros.
118794         (sigismember, sigaddset, sigdelset, sigfillset, rpl_signal): Handle it
118795         as an alias for SIGABRT.
118796         * lib/sigaction.c (SIGABRT_COMPAT): New macro.
118797         (sigaction): Map it to SIGABRT.
118798         Reported by Ramiro Polla <ramiro.polla@gmail.com> via Eric Blake.
118800 2008-10-20  Bruno Haible  <bruno@clisp.org>
118802         * lib/fts.c: Don't include lstat.h.
118803         * lib/openat.c: Include <sys/stat.h> instead of lstat.h.
118805         Move the lstat() declaration to <sys/stat.h>.
118806         * lib/lstat.h: Remove file.
118807         * lib/sys_stat.in.h: Add special invocation convention.
118808         (lstat): New declaration.
118809         * lib/lstat.c (orig_lstat): New function.
118810         (rpl_lstat): Use orig_lstat instead of lstat.
118811         * m4/lstat.m4 (gl_FUNC_LSTAT): Require gl_SYS_STAT_H_DEFAULTS and
118812         AC_C_INLINE. Set REPLACE_LSTAT.
118813         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LSTAT
118814         and REPLACE_LSTAT.
118815         * modules/lstat (Files): Remove lib/lstat.h.
118816         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
118817         (Include): Specify <sys/stat.h> instead of lstat.h.
118818         * modules/sys_stat (Makefile.am): Substitute GNULIB_LSTAT and
118819         REPLACE_LSTAT.
118820         * NEWS: Mention the change.
118822 2008-10-20  Bruno Haible  <bruno@clisp.org>
118824         * modules/posix_spawn-tests: New file.
118825         * tests/test-posix_spawn3.c: New file.
118827 2008-10-20  Bruno Haible  <bruno@clisp.org>
118829         * modules/posix_spawnp-tests (Depends-on): Add sys_wait.
118830         * tests/test-posix_spawn1.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
118831         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Remove fallback definitions.
118832         * tests/test-posix_spawn2.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
118833         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Likewise.
118835 2008-10-20  Bruno Haible  <bruno@clisp.org>
118837         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Test against another bug
118838         of posix_spawn on AIX 5.3.
118840 2008-10-20  Bruno Haible  <bruno@clisp.org>
118842         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Make the check on MacOS X.
118844 2008-10-20  Bruno Haible  <bruno@clisp.org>
118846         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Use AC_LANG_SOURCE instead
118847         of AC_LANG_PROGRAM.
118849 2008-10-20  Simon Josefsson  <simon@josefsson.org>
118851         * lib/netdb.in.h: Don't define GNU specific constants until they
118852         are supported or needed.  Reported by Bruno Haible
118853         <bruno@clisp.org>.
118855 2008-10-20  Simon Josefsson  <simon@josefsson.org>
118857         * lib/canon-host.c: Include netdb.h instead of getaddrinfo.h.
118859 2008-10-20  Simon Josefsson  <simon@josefsson.org>
118861         * lib/getaddrinfo.h: Remove file.
118862         * modules/getaddrinfo: Reflect move from getaddrinfo.h to netdb.h.
118863         * m4/getaddrinfo.m4: Call gl_HEADER_NETDB.  Don't check for netdb.h.
118864         * lib/netdb.in.h: Add declarations from getaddrinfo.h.
118865         * m4/netdb_h.m4: Initialize GNULIB_GETADDRINFO to 0.
118866         * modules/netdb: Substitute GNULIB_GETADDRINFO.
118867         * lib/getaddrinfo.c: Include netdb.h instead of getaddrinfo.h.
118868         * tests/test-getaddrinfo.c: Likewise.
118869         * lib/gai_strerror.c: Likewise.  Also drop HAVE_NETDB_H check.
118870         * NEWS: Mention change.
118872 2008-10-19  Bruno Haible  <bruno@clisp.org>
118874         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Remove unneeded code.
118876 2008-10-19  Bruno Haible  <bruno@clisp.org>
118878         * lib/wait-process.c: Include simply <sys/wait.h>.
118879         (waitpid, WTERMSIG, WCOREDUMP, WEXITSTATUS, WIFSIGNALED, WIFEXITED,
118880         WIFSTOPPED): Remove fallback definitions.
118881         * modules/wait-process (Depends-on): Add sys_wait.
118883         New module 'sys_wait'.
118884         * modules/sys_wait: New file.
118885         * lib/sys_wait.in.h: New file, partially copied from
118886         lib/wait-process.c.
118887         * m4/sys_wait_h.m4: New file.
118888         * doc/posix-headers/sys_wait.texi: Mention the new module.
118890 2008-10-19  Bruno Haible  <bruno@clisp.org>
118892         * m4/wait-process.m4 (gl_WAIT_PROCESS): Remove test for unistd.h.
118894 2008-10-19  Bruno Haible  <bruno@clisp.org>
118896         Assume that waitpid() fills an 'int' status, not a 'union wait'.
118897         * lib/wait-process.c (WAIT_T): Remove type.
118898         (WTERMSIG, WCOREDUMP, WEXITSTATUS): Define fallbacks using bit masks.
118899         (wait_subprocess): Update.
118901 2008-10-19  Bruno Haible  <bruno@clisp.org>
118903         New module 'atoll'.
118904         * modules/atoll: New file.
118905         * lib/stdlib.in.h (atoll): New declaration.
118906         * lib/atoll.c: New file, from glibc with modifications.
118907         * m4/atoll.m4: New file.
118908         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_ATOLL,
118909         HAVE_ATOLL.
118910         * modules/stdlib (Makefile.am): Substitute GNULIB_ATOLL, HAVE_ATOLL.
118911         * doc/posix-functions/atoll.texi: Mention the new module.
118913 2008-10-19  Bruno Haible  <bruno@clisp.org>
118915         Add strtoull() declaration to <stdlib.h>.
118916         * lib/stdlib.in.h (strtoull): New declaration.
118917         * m4/strtoull.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
118918         Set HAVE_STRTOULL.
118919         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOULL,
118920         HAVE_STRTOULL.
118921         * modules/strtoull (Depends-on): Add stdlib.
118922         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
118923         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOULL,
118924         HAVE_STRTOULL.
118926 2008-10-19  Bruno Haible  <bruno@clisp.org>
118928         Add strtoll() declaration to <stdlib.h>.
118929         * lib/stdlib.in.h (strtoll): New declaration.
118930         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
118931         Set HAVE_STRTOLL.
118932         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOLL,
118933         HAVE_STRTOLL.
118934         * modules/strtoll (Depends-on): Add stdlib.
118935         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
118936         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOLL, HAVE_STRTOLL.
118938 2008-10-19  Bruno Haible  <bruno@clisp.org>
118940         * modules/bcopy (Depends-on): Add strings.
118941         (Include): Specify <strings.h>.
118943 2008-10-19  Bruno Haible  <bruno@clisp.org>
118945         * doc/posix-functions/atexit.texi: Update doc regarding mingw.
118947 2008-10-19  Bruno Haible  <bruno@clisp.org>
118949         * lib/openat-die.c (openat_save_fail, openat_restore_fail): Rename
118950         the parameter from 'errno' to 'errnum'. Fixes a compilation error on
118951         mingw.
118953 2008-10-19  Bruno Haible  <bruno@clisp.org>
118955         * lib/atanl.c: Don't include isnanl.h.
118956         * lib/cosl.c: Likewise.
118957         * lib/ldexpl.c: Likewise.
118958         * lib/logl.c: Likewise.
118959         * lib/sinl.c: Likewise.
118960         * lib/sqrtl.c: Likewise.
118961         * lib/tanl.c: Likewise.
118963         Move the isnanf(), isnand(), isnanl() declarations to <math.h>.
118964         * lib/isnanf.h: Remove file.
118965         * lib/isnand.h: Remove file.
118966         * lib/isnanl.h: Remove file.
118967         * lib/math.in.h: Include the contents of lib/isnanf.h, lib/isnand.h,
118968         lib/isnanl.h. Use HAVE_ISNANF, HAVE_ISNAND, HAVE_ISNANL as substituted
118969         macros.
118970         * m4/isnanf.m4 (gl_FUNC_ISNANF): Require gl_MATH_H_DEFAULTS. Set
118971         HAVE_ISNANF, don't define it as a C macro.
118972         * m4/isnand.m4 (gl_FUNC_ISNAND): Require gl_MATH_H_DEFAULTS. Set
118973         HAVE_ISNAND, don't define it as a C macro.
118974         * m4/isnanl.m4 (gl_FUNC_ISNANL): Require gl_MATH_H_DEFAULTS. Set
118975         HAVE_ISNANL, don't define it as a C macro.
118976         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_ISNAN[FDL] and
118977         HAVE_ISNAN[FDL].
118978         * modules/isnanf (Files): Remove lib/isnanf.h.
118979         (Depends-on): Add math.
118980         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
118981         (Include): Specify <math.h> instead of isnanf.h.
118982         * modules/isnand (Files): Remove lib/isnand.h.
118983         (Depends-on): Add math.
118984         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
118985         (Include): Specify <math.h> instead of isnand.h.
118986         * modules/isnanl (Files): Remove lib/isnanl.h.
118987         (Depends-on): Add math.
118988         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
118989         (Include): Specify <math.h> instead of isnanl.h.
118990         * modules/math (Makefile.am): Substitute GNULIB_ISNAN[FDL] and
118991         HAVE_ISNAN[FDL].
118992         * tests/test-isnanf.c: Include <math.h> instead of isnanf.h.
118993         * tests/test-isnand.c: Include <math.h> instead of isnand.h.
118994         * tests/test-isnanl.c: Include <math.h> instead of isnanl.h.
118995         * NEWS: Mention the change.
118997 2008-10-18  Bruno Haible  <bruno@clisp.org>
118999         Add getusershell(), setusershell(), endusershell() declarations to
119000         <unistd.h>.
119001         * lib/unistd.in.h (getusershell, setusershell, endusershell): New
119002         declarations.
119003         * lib/getusershell.c: Include unistd.h.
119004         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): Require
119005         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
119006         HAVE_GETUSERSHELL.
119007         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETUSERSHELL
119008         and HAVE_GETUSERSHELL.
119009         * modules/getusershell (Depends-on): Add unistd, extensions.
119010         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
119011         (Include): Specify <unistd.h>.
119012         * modules/unistd (Makefile.am): Substitute GNULIB_GETUSERSHELL and
119013         HAVE_GETUSERSHELL.
119015 2008-10-18  Bruno Haible  <bruno@clisp.org>
119017         Add a getloadavg() declaration to <stdlib.h>.
119018         * lib/stdlib.in.h; Include <sys/loadavg.h> when needed for the
119019         getloadavg declaration.
119020         (getloadavg): New declaration.
119021         * lib/getloadavg.c: Include <stdlib.h> first.
119022         * m4/getloadavg.m4 (gl_GETLOADAVG): Require gl_STDLIB_H_DEFAULTS and
119023         AC_USE_SYSTEM_EXTENSIONS. Test whether sys/loadavg.h exists. Set
119024         HAVE_SYS_LOADAVG_H and HAVE_DECL_GETLOADAVG.
119025         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_GETLOADAVG,
119026         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
119027         * modules/getloadavg (Depends-on): Add stdlib, extensions.
119028         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
119029         (Include): Specify <stdlib.h>.
119030         * modules/stdlib (Makefile.am): Substitute GNULIB_GETLOADAVG,
119031         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
119033 2008-10-18  Bruno Haible  <bruno@clisp.org>
119035         * lib/dirchownmod.c: Don't include lchmod.h.
119037         Move the lchmod() declaration to <sys/stat.h>.
119038         * lib/lchmod.h: Remove file.
119039         * lib/sys_stat.in.h: Add placeholder for GL_LINK_WARNING.
119040         (lchmod): New declaration, moved here from lib/lchown.h.
119041         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Require gl_SYS_STAT_H_DEFAULTS and
119042         AC_USE_SYSTEM_EXTENSIONS. Set HAVE_LCHMOD.
119043         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LCHMOD
119044         and HAVE_LCHMOD.
119045         * modules/lchmod (Files): Remove lib/lchmod.h.
119046         (Depends-on): Add sys_stat, extensions.
119047         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
119048         (Include): Specify <sys/stat.h> instead of lchmod.h.
119049         * modules/sys_stat (Depends-on): Add link-warning.
119050         (Makefile.am): Substitute GNULIB_LCHMOD, HAVE_LCHMOD, and the
119051         definition of GL_LINK_WARNING.
119052         * NEWS: Mention the change.
119054 2008-10-18  Bruno Haible  <bruno@clisp.org>
119056         * lib/fchdir.c: Don't include dirfd.h.
119057         * lib/fts.c: Likewise.
119058         * lib/getcwd.c: Likewise.
119059         * lib/glob.c: Likewise.
119061         Move the dirfd() declaration to <dirent.h>.
119062         * lib/dirfd.h: Remove file.
119063         * lib/dirent.in.h: Add placeholder for GL_LINK_WARNING.
119064         (dirfd): New declaration.
119065         * lib/dirfd.c: Include <dirent.h> instead of dirfd.h.
119066         * m4/dirfd.m4 (gl_FUNC_DIRFD): Require gl_DIRENT_H_DEFAULTS and
119067         AC_USE_SYSTEM_EXTENSIONS. Invoke gl_REPLACE_DIRENT_H. Set
119068         HAVE_DECL_DIRFD.
119069         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_DIRFD and
119070         HAVE_DECL_DIRFD.
119071         * modules/dirfd (Files): Remove lib/dirfd.h.
119072         (Depends-on): Add dirent, extensions.
119073         (configure.ac): Invoke gl_DIRENT_MODULE_INDICATOR.
119074         (Include): Specify <dirent.h> instead of dirfd.h.
119075         * modules/dirent (Depends-on): Add link-warning.
119076         (Makefile.am): Substitute GNULIB_DIRFD, HAVE_DECL_DIRFD, and
119077         definition of GL_LINK_WARNING.
119078         * NEWS: Mention the change.
119080 2008-10-18  Bruno Haible  <bruno@clisp.org>
119082         Move the euidaccess() declaration to <unistd.h>.
119083         * lib/euidaccess.h: Remove file.
119084         * lib/unistd.in.h (euidaccess): New declaration.
119085         * lib/euidaccess.c: Don't include euidaccess.h.
119086         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Require gl_UNISTD_H_DEFAULTS.
119087         Don't check whether euidaccess is declared. Set HAVE_EUIDACCESS.
119088         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_EUIDACCESS
119089         and HAVE_EUIDACCESS.
119090         * modules/euidaccess (Files): Remove lib/euidaccess.h.
119091         (Depends-on): Add unistd.
119092         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
119093         (Include): Specify <unistd.h> instead of euidaccess.h.
119094         * modules/unistd (Makefile.am): Substitute GNULIB_EUIDACCESS and
119095         HAVE_EUIDACCESS.
119096         * NEWS: Mention the change.
119098 2008-10-18  Bruno Haible  <bruno@clisp.org>
119100         * lib/xgetdomainname.c: Include <unistd.h> instead of getdomainname.h.
119102         Move the getdomainname() declaration to <unistd.h>.
119103         * lib/getdomainname.h: Remove file.
119104         * lib/unistd.in.h (getdomainname): New declaration.
119105         * lib/getdomainname.c: Include <unistd.h> instead of getdomainname.h.
119106         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Require
119107         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
119108         HAVE_GETDOMAINNAME.
119109         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
119110         GNULIB_GETDOMAINNAME and HAVE_GETDOMAINNAME.
119111         * modules/getdomainname (Files): Remove lib/getdomainname.h.
119112         (Depends-on): Add unistd, extensions.
119113         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
119114         (Includes): Specify <unistd.h> instead of getdomainname.h.
119115         * modules/unistd (Makefile.am): Substitute GNULIB_GETDOMAINNAME and
119116         HAVE_GETDOMAINNAME.
119117         * NEWS: Mention the change.
119119 2008-10-18  Bruno Haible  <bruno@clisp.org>
119121         * modules/dirent: New file.
119122         * m4/dirent_h.m4: New file.
119123         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_DIRENT_H_DEFAULTS.
119124         Invoke gl_REPLACE_DIRENT_H. Don't assign DIRENT_H directly.
119125         * modules/fchdir (Files): Remove lib/dirent.in.h.
119126         (Depends-on): Add dirent.
119127         (Makefile.am): Move rules to modules/dirent.
119128         * doc/posix-headers/dirent.texi: Mention the new module.
119130 2008-10-18  Bruno Haible  <bruno@clisp.org>
119132         Avoid -Wunused-parameter warnings in public gnulib header files.
119133         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _UNUSED_PARAMETER_ as a
119134         macro.
119135         * lib/unistr.h (u32_mbtouc_unsafe, u32_mbtouc): Use it.
119137 2008-10-18  Bruno Haible  <bruno@clisp.org>
119139         * doc/glibc-functions/dirfd.texi: Mention the module 'dirfd'.
119140         * doc/glibc-functions/error.texi: Mention the module 'error'.
119141         * doc/glibc-functions/euidaccess.texi: Mention the module 'euidaccess'.
119142         * doc/glibc-functions/getdomainname.texi: Mention the module
119143         'getdomainname'.
119144         * doc/glibc-functions/getloadavg.texi: Mention the module 'getloadavg'.
119145         * doc/glibc-functions/getpagesize.texi: Mention the module
119146         'getpagesize'.
119147         * doc/glibc-functions/getusershell.texi: Mention the module
119148         'getusershell'.
119149         * doc/glibc-functions/isnanl.texi: Mention the module 'isnanl'.
119150         * doc/glibc-functions/lchmod.texi: Mention the module 'lchmod'.
119151         * doc/glibc-functions/mempcpy.texi: Mention the module 'mempcpy'.
119152         * doc/glibc-functions/memrchr.texi: Mention the module 'memrchr'.
119153         * doc/glibc-functions/mkdtemp.texi: Mention the module 'mkdtemp'.
119154         * doc/glibc-functions/rpmatch.texi: Mention the module 'rpmatch'.
119155         * doc/glibc-functions/stpcpy.texi: Mention the module 'stpcpy'.
119156         * doc/glibc-functions/stpncpy.texi: Mention the module 'stpncpy'.
119157         * doc/glibc-functions/strchrnul.texi: Mention the module 'strchrnul'.
119158         * doc/glibc-functions/strndup.texi: Mention the module 'strndup'.
119159         * doc/glibc-functions/strnlen.texi: Mention the module 'strnlen'.
119160         * doc/glibc-functions/strsep.texi: Mention the module 'strsep'.
119161         * doc/glibc-functions/timegm.texi: Mention the module 'timegm'.
119162         * doc/glibc-functions/vasprintf.texi: Mention the module 'vasprintf'.
119164 2008-10-17  Bruno Haible  <bruno@clisp.org>
119166         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): On platforms other than
119167         HP-UX and IRIX, use -0.0L.
119168         * tests/test-ceill.c (minus_zero): Likewise.
119169         * tests/test-floorl.c (minus_zero): Likewise.
119170         * tests/test-frexpl.c (minus_zero): Likewise.
119171         * tests/test-isnan.c (minus_zerol): Likewise.
119172         * tests/test-isnanl.h (minus_zero): Likewise.
119173         * tests/test-ldexpl.c (minus_zero): Likewise.
119174         * tests/test-roundl.c (minus_zero): Likewise.
119175         * tests/test-signbit.c (minus_zerol): Likewise.
119176         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
119177         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
119178         * tests/test-truncl.c (minus_zero): Likewise.
119179         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
119180         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
119181         Reported by Markus Armbruster <armbru@redhat.com> via Jim Meyering
119182         and by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
119184 2008-10-17  Bruno Haible  <bruno@clisp.org>
119186         Avoid gcc warnings because of #pragma GCC system_header on older gcc.
119187         * lib/arpa_inet.in.h: Encloses reference to PRAGMA_SYSTEM_HEADER so
119188         that it gets activated only for gcc >= 3.0.
119189         * lib/dirent.in.h: Likewise.
119190         * lib/errno.in.h: Likewise.
119191         * lib/fcntl.in.h: Likewise.
119192         * lib/float.in.h: Likewise.
119193         * lib/iconv.in.h: Likewise.
119194         * lib/inttypes.in.h: Likewise.
119195         * lib/locale.in.h: Likewise.
119196         * lib/math.in.h: Likewise.
119197         * lib/netdb.in.h: Likewise.
119198         * lib/netinet_in.in.h: Likewise.
119199         * lib/search.in.h: Likewise.
119200         * lib/signal.in.h: Likewise.
119201         * lib/spawn.in.h: Likewise.
119202         * lib/stdarg.in.h: Likewise.
119203         * lib/stdint.in.h: Likewise.
119204         * lib/stdio.in.h: Likewise.
119205         * lib/stdlib.in.h: Likewise.
119206         * lib/string.in.h: Likewise.
119207         * lib/strings.in.h: Likewise.
119208         * lib/sys_file.in.h: Likewise.
119209         * lib/sys_ioctl.in.h: Likewise.
119210         * lib/sys_select.in.h: Likewise.
119211         * lib/sys_socket.in.h: Likewise.
119212         * lib/sys_stat.in.h: Likewise.
119213         * lib/sys_time.in.h: Likewise.
119214         * lib/sysexits.in.h: Likewise.
119215         * lib/time.in.h: Likewise.
119216         * lib/unistd.in.h: Likewise.
119217         * lib/wchar.in.h: Likewise.
119218         * lib/wctype.in.h: Likewise.
119219         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
119221 2008-10-17  Jim Meyering  <meyering@redhat.com>
119223         ignore-value: don't depend on inline module
119224         * modules/ignore-value (Depends-on): Remove 'inline'.
119225         (configure.ac): Instead, add AC_REQUIRE([AC_C_INLINE]) here.
119226         Suggestion from Bruno Haible.
119228 2008-10-17  Bruno Haible  <bruno@clisp.org>
119230         New implementation of condition variables for Win32.
119231         * lib/glthread/cond.h (struct gl_waitqueue_link): New type.
119232         (gl_linked_waitqueue_t): New type.
119233         (gl_cond_t): Use it.
119234         * lib/glthread/cond.c (struct gl_waitqueue_element): New type.
119235         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_remove,
119236         gl_waitqueue_notify_first, gl_waitqueue_notify_all): New functions.
119237         (glthread_cond_init_func, glthread_cond_wait_func,
119238         glthread_cond_timedwait_func, glthread_cond_signal_func,
119239         glthread_cond_broadcast_func, glthread_cond_destroy_func):
119240         Reimplemented on the basis of gl_linked_waitqueue_t.
119241         * lib/glthread/lock.h (gl_carray_waitqueue_t): Renamed from
119242         gl_waitqueue_t.
119243         (gl_rwlock_t): Update.
119244         * lib/glthread/lock.c (gl_waitqueue_t): Alias to gl_carray_waitqueue_t.
119246 2008-10-17  Simon Josefsson  <simon@josefsson.org>
119248         * modules/recvfrom (Depends-on): Add dependency on getpeername.
119249         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
119251 2008-10-17  Jim Meyering  <meyering@redhat.com>
119253         ignore-value: new module
119254         * modules/ignore-value: New file.
119255         * lib/ignore-value.h: New file.
119256         * MODULES.html.sh (Compiler warning management): New section,
119257         just for this module.  More to come.
119259 2008-10-16  Paul Eggert  <eggert@cs.ucla.edu>
119261         open-safer.c: avoid 'signed and unsigned in conditional...' warning
119262         * lib/open-safer.c (open_safer): Use an "if/else" statement in place
119263         of the ternary operator.  Reported by Reuben Thomas <rrt@sc3d.org>.
119265 2008-10-16  Jim Meyering  <meyering@redhat.com>
119267         openat-die.c: avoid 'no previous prototype' warning
119268         * lib/openat-die.c: Include "openat.h".
119269         Reported by Reuben Thomas <rrt@sc3d.org>.
119271 2008-10-16  Simon Josefsson  <simon@josefsson.org>
119273         * m4/netdb_h.m4: Assume that if netdb.h exists, it works.
119274         * lib/netdb.in.h: Fix typo.
119275         Reported by Bruno Haible  <bruno@clisp.org>
119277         * lib/netdb.in.h: Include sys/socket.h for platforms without
119278         netdb.h, to get structures like hostent on MinGW.
119279         * modules/netdb (Depends-on): Add sys_socket.
119281 2008-10-15  Simon Josefsson  <simon@josefsson.org>
119283         * modules/netdb, modules/netdb-tests: New file.
119284         * m4/netdb_h.m4: New file.
119285         * lib/netdb.in.h: Add, currently just an empty file pending
119286         definitions.
119287         * tests/test-netdb.c: New file.
119288         * doc/posix-headers/netdb.texi: Mention that we replace it if
119289         needed.
119290         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
119291         netdb.
119293 2008-10-15  Simon Josefsson  <simon@josefsson.org>
119295         * doc/gnulib.texi (Getaddrinfo and WINVER): Sync documentation
119296         with code.
119298 2008-10-13  Bruno Haible  <bruno@clisp.org>
119300         * lib/glthread/cond.c (glthread_cond_wait_func,
119301         glthread_cond_timedwait_func): Add a comment.
119303 2008-10-13  Yoann Vandoorselaere  <yoann@prelude-ids.org>
119305         * tests/test-poll.c: Include <sys/ioctl.h>, for ioctl().
119306         * tests/test-select.c: Likewise,
119308 2008-10-13  Bruno Haible  <bruno@clisp.org>
119310         * lib/glthread/cond.c (glthread_cond_wait_func,
119311         glthread_cond_timedwait_func): Fix variable name.
119312         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
119314 2008-10-13  Paolo Bonzini  <bonzini@gnu.org>
119316         fix getaddrinfo emulation for systems with struct sockaddr.sa_len
119317         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Detect
119318         struct sockaddr.sa_len.
119319         * lib/getaddrinfo.c (getaddrinfo): Set it if appropriate.
119321 2008-10-13  Simon Josefsson  <simon@josefsson.org>
119323         * build-aux/pmccabe2html: Add css and css_url parameters.
119325 2008-10-12  Bruno Haible  <bruno@clisp.org>
119327         * tests/test-sameacls.c (main) [AIX]: Clear type argument before
119328         calling aclx_get.
119329         Reported by Rainer Tammer <tammer@tammer.net>.
119331 2008-10-12  Bruno Haible  <bruno@clisp.org>
119333         Use msvcrt aware primitives for creation/termination of Win32 threads.
119334         * lib/glthread/thread.c: Include <process.h>.
119335         (glthread_create_func): Use _beginthreadex instead of CreateThread.
119336         (wrapper_func): Update signature.
119337         (gl_thread_exit_func): Use _endthreadex instead of EndThread.
119339 2008-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
119340             Bruno Haible  <bruno@clisp.org>
119342         Provide a Win32 implementation of the 'cond' module.
119343         * lib/glthread/cond.h [USE_WIN32]: New implementation.
119344         * lib/glthread/cond.c (glthread_cond_init_func,
119345         glthread_cond_wait_func, glthread_cond_timedwait_func,
119346         glthread_cond_signal_func, glthread_cond_broadcast_func,
119347         glthread_cond_destroy_func) [USE_WIN32]: New functions.
119348         * modules/cond (Dependencies): Add gettimeofday.
119350 2008-10-11  Bruno Haible  <bruno@clisp.org>
119352         Make sleep work on older versions of mingw.
119353         * m4/sleep.m4 (gl_FUNC_SLEEP): Test whether 'sleep' is declared, not
119354         only whether it exists.
119355         * doc/posix-functions/sleep.texi: Mention the problem with older
119356         versions of mingw.
119358 2008-10-11  Bruno Haible  <bruno@clisp.org>
119360         New module 'shutdown'.
119361         * modules/shutdown: New file.
119362         * lib/sys_socket.in.h (shutdown): New declaration.
119363         * lib/winsock.c (shutdown): New function.
119364         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
119365         GNULIB_SHUTDOWN.
119366         * modules/sys_socket (Makefile.am): Substitute GNULIB_SHUTDOWN.
119367         * doc/posix-functions/shutdown.texi: Document the new module.
119369 2008-10-11  Jim Meyering  <meyering@redhat.com>
119371         * lib/fclose.c: Fix typo in comment: s/close/fclose/.
119373 2008-10-11  Bruno Haible  <bruno@clisp.org>
119375         New module 'fclose'.
119376         * modules/fclose: New file.
119377         * lib/stdio.in.h (fclose): New declaration.
119378         * lib/fclose.c: New file.
119379         * m4/fclose.m4: New file.
119380         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FCLOSE,
119381         REPLACE_FCLOSE.
119382         * m4/close.m4 (gl_REPLACE_CLOSE): Invoke gl_REPLACE_FCLOSE.
119383         * modules/stdio (Makefile.am): Substitute GNULIB_FCLOSE,
119384         REPLACE_FCLOSE.
119385         * modules/close (Depends-on): fclose.
119386         * doc/posix-functions/fclose.texi: Mention the problem on Windows.
119388 2008-10-11  Bruno Haible  <bruno@clisp.org>
119390         * lib/winsock.c (_gl_close_fd_maybe_socket): If closesocket fails,
119391         set errno and don't call _close.
119393 2008-10-10  Bruno Haible  <bruno@clisp.org>
119395         * lib/copy-acl.c (qcopy_acl) [CYGWIN]: Call chmod before setting the
119396         ACL, not afterwards. Fixes test failure on Cygwin.
119398 2008-10-09  Ben Pfaff  <blp@gnu.org>
119400         * build-aux/announce-gen: Fix gnulib version related part of usage
119401         message.  Die with a useful error message if no tarballs are
119402         found.
119404 2008-10-10  Jim Meyering  <meyering@redhat.com>
119406         bootstrap: use git's --depth=N option only if it's supported
119407         * build-aux/bootstrap: Work with git-1.4.4.4, which does not
119408         recognize the --depth option.  Reported by Pádraig Brady.
119410 2008-10-09  Bruno Haible  <bruno@clisp.org>
119412         New module 'ioctl'.
119413         * modules/ioctl: New file.
119414         * lib/sys_socket.in.h (ioctl): Remove declaration.
119415         * lib/winsock.c: Include <sys/ioctl.h>.
119416         (rpl_ioctl): Define only of the gnulib module 'ioctl' is present.
119417         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
119418         gl_SYS_IOCTL_H_DEFAULTS. Set also SYS_IOCTL_H_HAVE_WINSOCK2_H.
119419         * modules/sys_socket (Files): Add m4/sys_ioctl_h.m4.
119420         * doc/posix-functions/ioctl.texi: Mention the new module.
119422 2008-10-09  Bruno Haible  <bruno@clisp.org>
119424         New module 'sys_ioctl'.
119425         * lib/sys_ioctl.in.h: New file.
119426         * m4/sys_ioctl_h.m4: New file.
119427         * modules/sys_ioctl: New file.
119428         * doc/glibc-headers/sys_ioctl.texi: Mention the new module.
119430 2008-10-09  Bruno Haible  <bruno@clisp.org>
119432         * lib/sys_socket.in.h (ioctl): Make signature POSIX compliant.
119433         * lib/winsock.c: Include <stdarg.h>.
119434         (rpl_ioctl): Change to second argument 'int' and then varargs.
119436 2008-10-09  Bruno Haible  <bruno@clisp.org>
119438         * m4/close.m4 (gl_FUNC_CLOSE): Arrange to replace the close() function
119439         when the sys_socket module is present and the system has <winsock2.h>.
119441 2008-10-09  Bruno Haible  <bruno@clisp.org>
119443         * doc/posix-functions/close.texi: Mention module 'close' instead of
119444         module 'sys_socket'.
119446 2008-10-09  Bruno Haible  <bruno@clisp.org>
119448         * doc/glibc-headers/sys_ioctl.texi: New file.
119449         * doc/gnulib.texi: Include it.
119451 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
119452             Bruno Haible  <bruno@clisp.org>
119454         Combine the two replacements of 'close'.
119455         * lib/sys_socket.in.h (close): Define to a reminder to include
119456         <unistd.h>.
119457         (_gl_close_fd_maybe_socket): New declaration.
119458         (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): New macro.
119459         * lib/winsock.c (close): Remove undefinition.
119460         (_gl_close_fd_maybe_socket): Renamed from rpl_close. Define only when
119461         needed for the gnulib module 'close'.
119462         * lib/unistd.in.h (close): If the gnulib module 'close' is not used,
119463         define to an error symbol or to a warning, if suitable.
119464         * lib/close.c: Include <sys/socket.h>.
119465         (rpl_close): Invoke _gl_close_fd_maybe_socket when gnulib defines it.
119466         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Set also
119467         UNISTD_H_HAVE_WINSOCK2_H.
119468         (gl_SYS_SOCKET_H_DEFAULTS): Require gl_UNISTD_H_DEFAULTS.
119469         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
119470         UNISTD_H_HAVE_WINSOCK2_H.
119471         * modules/sys_socket (Files): Add m4/unistd_h.m4.
119472         (configure.ac): Set a module indicator.
119473         (Makefile.am): Substitute GNULIB_CLOSE.
119474         * modules/unistd (Makefile.am): Substitute UNISTD_H_HAVE_WINSOCK2_H.
119475         * modules/poll-tests (Depends-on): Add close.
119476         * modules/select-tests (Depends-on): Likewise.
119478 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
119479             Bruno Haible  <bruno@clisp.org>
119481         New module 'close'.
119482         * modules/close: New file.
119483         * lib/unistd.in.h (close): Move declaration out of the
119484         FCHDIR_REPLACEMENT scope.
119485         (_gl_unregister_fd): New declaration.
119486         * lib/close.c: New file.
119487         * lib/fchdir.c (rpl_close): Remove function.
119488         * m4/close.m4: New file.
119489         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
119490         close.
119491         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_CLOSE and
119492         REPLACE_CLOSE.
119493         * modules/unistd (Makefile.am): Substitute GNULIB_CLOSE and
119494         REPLACE_CLOSE.
119495         * modules/fchdir (Depends-on): Add close.
119497 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
119498             Bruno Haible  <bruno@clisp.org>
119500         * lib/fcntl.in.h (open): Simplify conditionals.
119501         (_gl_register_fd): New declaration.
119502         * lib/fchdir.c (rpl_open): Remove function.
119503         * lib/open.c: When FCHDIR_REPLACEMENT is defined, compile the file
119504         also.
119505         (open): When FCHDIR_REPLACEMENT is defined, invoke _gl_register_fd.
119506         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
119507         open.
119509 2008-10-09  Jim Meyering  <meyering@redhat.com>
119511         GNUmakefile: use the more name-space-friendly "_version"
119512         * top/GNUmakefile (_dummy): Update.
119513         (_version): Rename from "version".
119515 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
119516             Bruno Haible  <bruno@clisp.org>
119518         * lib/fchdir.c (_gl_unregister_fd): New functions, extracted from
119519         rpl_close.
119520         (_gl_register_fd): New function, extracted from rpl_open.
119521         (rpl_close, rpl_closedir): Use _gl_unregister_fd.
119522         (rpl_open, rpl_opendir): Use _gl_register_fd.
119524 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
119526         Fix organization of 'open' replacement.
119527         * m4/open.m4 (gl_REPLACE_OPEN): New macro.
119528         (gl_FUNC_OPEN): Use it.
119529         (gl_PREREQ_OPEN): Add a : to make the body non-empty.
119531 2008-10-08  Bruno Haible  <bruno@clisp.org>
119533         * modules/getdate-tests (test_getdata_LDADD): Add LIBINTL.
119535 2008-10-08  Simon Josefsson  <simon@josefsson.org>
119537         * m4/sys_socket_h.m4: Don't AC_LIBOBJ(winsock).  The file is
119538         AC_LIBOBJ'ed by each gnulib module that needs it (e.g., socket,
119539         listen).
119541 2008-10-08  Eric Blake  <ebb9@byu.net>
119543         GNUmakefile: add 'make version' target
119544         * top/GNUmakefile (_curr-ver): Split version update rules...
119545         (version): ...into a target.
119547 2008-10-07  Bruno Haible  <bruno@clisp.org>
119549         Use a more portable replacement expression for -0.0L.
119550         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Use -LDBL_MIN * LDBL_MIN
119551         instead of -0.0L. Fix m4 quotation.
119553         * tests/test-signbit.c: Include <float.h>.
119554         (minus_zero): New variable.
119555         (test_signbitl): Use minus_zero instead of -zero.
119556         * modules/signbit-tests (Depends-on): Add float.
119558         * tests/test-ceill.c: Include <float.h>.
119559         (zero): Remove variable.
119560         (minus_zero): New variable.
119561         (main): Use minus_zero instead of -zero.
119562         * modules/ceill-tests (Depends-on): Add float.
119564         * tests/test-floorl.c: Include <float.h>.
119565         (zero): Remove variable.
119566         (minus_zero): New variable.
119567         (main): Use minus_zero instead of -zero.
119568         * modules/floorl-tests (Depends-on): Add float.
119570         * tests/test-roundl.c: Include <float.h>.
119571         (zero): Remove variable.
119572         (minus_zero): New variable.
119573         (main): Use minus_zero instead of -zero.
119574         * modules/roundl-tests (Depends-on): Add float.
119576         * tests/test-truncl.c: Include <float.h>.
119577         (zero): Remove variable.
119578         (minus_zero): New variable.
119579         (main): Use minus_zero instead of -zero.
119580         * modules/truncl-tests (Depends-on): Add float.
119582         * tests/test-frexpl.c (zero): Remove variable.
119583         (minus_zero): New variable.
119584         (main): Use minus_zero instead of -zero.
119585         * modules/frexpl-tests (Depends-on): Add float.
119587         * tests/test-isnan.c (zerol): Remove variable.
119588         (minus_zerol): New variable.
119589         (test_long_double): Use minus_zerol instead of -zerol.
119590         * modules/isnan-tests (Depends-on): Add float.
119592         * tests/test-isnanl.h (zero): Remove variable.
119593         (minus_zero): New variable.
119594         (main): Use minus_zero instead of -zero.
119595         * modules/isnanl-nolibm-tests (Depends-on): Add float.
119596         * modules/isnanl-tests (Depends-on): Add float.
119598         * tests/test-ldexpl.c (zero): Remove variable.
119599         (minus_zero): New variable.
119600         (main): Use minus_zero instead of -zero.
119601         * modules/ldexpl-tests (Depends-on): Add float.
119603         * tests/test-snprintf-posix.h (zerol): Remove variable.
119604         (minus_zerol): New variable.
119605         (test_function): Use minus_zerol instead of -zerol.
119606         * modules/snprintf-posix-tests (Depends-on): Add float.
119607         * modules/vsnprintf-posix-tests (Depends-on): Add float.
119609         * tests/test-sprintf-posix.h (zerol): Remove variable.
119610         (minus_zerol): New variable.
119611         (test_function): Use minus_zerol instead of -zerol.
119612         * modules/sprintf-posix-tests (Depends-on): Add float.
119613         * modules/vsprintf-posix-tests (Depends-on): Add float.
119615         * tests/test-vasnprintf-posix.c (zerol): Remove variable.
119616         (minus_zerol): New variable.
119617         (test_function): Use minus_zerol instead of -zerol.
119618         * modules/vasnprintf-posix-tests (Depends-on): Add float.
119620         * tests/test-vasprintf-posix.c (zerol): Remove variable.
119621         (minus_zerol): New variable.
119622         (test_function): Use minus_zerol instead of -zerol.
119623         * modules/vasprintf-posix-tests (Depends-on): Add float.
119625 2008-10-07  Simon Josefsson  <simon@josefsson.org>
119627         * MODULES.html.sh (Support for building documentation): Mention
119628         pmccabe2html.  Sort entries.
119630         Add pmccabe2html module, from gnupdf.
119631         * build-aux/pmccabe.css: New file.
119632         * build-aux/pmccabe2html: New file.
119633         * m4/pmccabe2html.m4: New file.
119634         * modules/pmccabe2html: New file.
119636 2008-10-07  Richard W.M. Jones  <rjones@redhat.com>
119638         flock: new module
119639         * MODULES.html.sh: Add to list of modules.
119640         * lib/flock.c: flock implementation for Windows and Unix systems
119641         which have fcntl.
119642         * doc/glibc-functions/flock.texi: Update documentation.
119643         * lib/sys_file.in.h: <sys/file.h> header file.
119644         * m4/flock.m4: M4 macros.
119645         * m4/sys_file_h.m4: M4 macros for replacement sys/file.h.
119646         * modules/flock: flock module.
119647         * modules/flock-tests: flock tests module.
119648         * modules/sys_file: sys/file.h module.
119649         * tests/test-flock.c: test suite for flock.
119651 2008-10-06  Jim Meyering  <meyering@redhat.com>
119653         bootstrap: check for LT_INIT more portably still ;-)
119654         * build-aux/bootstrap: Don't rely on \>, since it's not portable.
119655         Spotted by Bruno Haible.
119657 2008-10-06  Eric Blake  <ebb9@byu.net>
119659         test-signbit: avoid tripping Irix cc bug on -0.0L
119660         * tests/test-signbit.c (minus_zerol): Delete, and replace with
119661         '-zerol'.  This may break on HP-UX/hppa, but at least makes the
119662         entire testsuite consistent and avoids an Irix 6.2 bug.
119664 2008-10-05  Bruno Haible  <bruno@clisp.org>
119665             Jim Meyering  <jim@meyering.net>
119667         Add an option for ignoring EPIPE during close_stdout.
119668         * lib/closeout.h: Include <stdbool.h>.
119669         (close_stdout_set_ignore_EPIPE): New declaration.
119670         * lib/closeout.c: Include <stdbool.h>.
119671         (ignore_EPIPE): New variable.
119672         (close_stdout_set_ignore_EPIPE): New function.
119673         (close_stdout): Ignore EPIPE error if ignore_EPIPE is set.
119674         * lib/close-stream.c (close_stream): Mention the possible EPIPE
119675         failure.
119676         * modules/closeout (Depends-on): Add stdbool.
119678 2008-10-05  Bruno Haible  <bruno@clisp.org>
119680         * modules/accept: New file.
119681         * modules/bind: New file.
119682         * modules/connect: New file.
119683         * modules/getpeername: New file.
119684         * modules/getsockname: New file.
119685         * modules/getsockopt: New file.
119686         * modules/listen: New file.
119687         * modules/recv: New file.
119688         * modules/recvfrom: New file.
119689         * modules/send: New file.
119690         * modules/sendto: New file.
119691         * modules/setsockopt: New file.
119692         * modules/socket: New file.
119693         * lib/sys_socket.in.h: Include the GL_LINK_WARNING definition.
119694         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
119695         listen, recv, send, recvfrom, sendto, setsockopt): Declare only when
119696         the particular module is requested. Add a link warning when the
119697         particular module is not requested.
119698         * lib/winsock.c (rpl_socket, rpl_connect, rpl_accept, rpl_bind,
119699         rpl_getpeername, rpl_getsockname, rpl_getsockopt, rpl_listen, rpl_recv,
119700         rpl_send, rpl_recvfrom, rpl_sendto, rpl_setsockopt): Define only when
119701         the particular module is requested.
119702         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR,
119703         gl_SYS_SOCKET_H_DEFAULTS): New macros.
119704         (gl_HEADER_SYS_SOCKET): Require gl_SYS_SOCKET_H_DEFAULTS.
119705         * modules/sys_socket (Depends-on): Add link-warning.
119706         (Makeifle.am): Substitute GNULIB_SOCKET, GNULIB_CONNECT, GNULIB_ACCEPT,
119707         GNULIB_BIND, GNULIB_GETPEERNAME, GNULIB_GETSOCKNAME, GNULIB_GETSOCKOPT,
119708         GNULIB_LISTEN, GNULIB_RECV, GNULIB_SEND, GNULIB_RECVFROM,
119709         GNULIB_SENDTO, GNULIB_SETSOCKOPT, and the definition of
119710         GL_LINK_WARNING.
119711         * doc/posix-functions/accept.texi: Mention the new module 'accept'.
119712         * doc/posix-functions/bind.texi: Mention the new module 'bind'.
119713         * doc/posix-functions/connect.texi: Mention the new module 'connect'.
119714         * doc/posix-functions/getpeername.texi: Mention the new module
119715         'getpeername'.
119716         * doc/posix-functions/getsockname.texi: Mention the new module
119717         'getsockname'.
119718         * doc/posix-functions/getsockopt.texi: Mention the new module
119719         'getsockopt'.
119720         * doc/posix-functions/listen.texi: Mention the new module 'listen'.
119721         * doc/posix-functions/recv.texi: Mention the new module 'recv'.
119722         * doc/posix-functions/recvfrom.texi: Mention the new module 'recvfrom'.
119723         * doc/posix-functions/send.texi: Mention the new module 'send'.
119724         * doc/posix-functions/sendto.texi: Mention the new module 'sendto'.
119725         * doc/posix-functions/setsockopt.texi: Mention the new module
119726         'setsockopt'.
119727         * doc/posix-functions/socket.texi: Mention the new module 'socket'.
119728         * modules/poll-tests (Depends-on): Add socket, bind, getsockopt,
119729         listen, connect, accept.
119730         * modules/select-tests (Depends-on): Likewise.
119732 2008-10-05  Bruno Haible  <bruno@clisp.org>
119734         * lib/winsock.c (strerror): Remove unused #undef.
119735         (rpl_close): Remove unused local variable.
119737         * modules/sys_socket (Depends-on); Add errno.
119739 2008-10-05  Bruno Haible  <bruno@clisp.org>
119741         * lib/sys_select.in.h: Include the GL_LINK_WARNING definition.
119742         (select): Add a link warning when the 'select' module is not used.
119743         * modules/sys_select (Depends-on): Add link-warning.
119744         (Makefile.am): Substitute the definition of GL_LINK_WARNING.
119745         Suggested by Paolo Bonzini.
119747 2008-10-05  Jim Meyering  <meyering@redhat.com>
119749         bootstrap: check for LT_INIT more portably
119750         * build-aux/bootstrap: Avoid using grep -E, since it's not
119751         portable enough.  Suggestion from Bruno Haible.
119753 2008-10-05  Bruno Haible  <bruno@clisp.org>
119755         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem
119756         as being fixed by gnulib.
119758 2008-10-05  Bruno Haible  <bruno@clisp.org>
119760         * modules/select-tests: New file, mostly copied from
119761         modules/sys_select-tests.
119762         * tests/test-select.c: New file, mostly copied from
119763         tests/test-sys_select.c.
119764         * tests/test-sys_select.c: Move most of the code to tests/test-select.c.
119765         * modules/sys_select-tests (Depends-on): Remove all dependencies.
119766         (Makefile.am): Remove test_sys_select_LDADD.
119768         * lib/sys_select.in.h (select): If GNULIB_SELECT is not set, define it
119769         to an undefined symbol, for an error message.
119770         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): New macro.
119771         (gl_SYS_SELECT_H_DEFAULTS): New macro.
119772         (gl_HEADER_SYS_SELECT): Require it. Don't require compilation of
119773         winsock-select.c here.
119774         * modules/sys_select (Files): Remove lib/winsock-select.c.
119775         (Depends-on): Remove alloca.
119776         (Makefile.am): Substitute GNULIB_SELECT.
119777         * modules/select: New file.
119778         * doc/posix-functions/select.texi: Update.
119780 2008-10-05  Bruno Haible  <bruno@clisp.org>
119782         * lib/spawn_faction_addclose.c (__sysconf): Use getdtablesize always.
119783         * lib/spawn_faction_adddup2.c (__sysconf): Likewise.
119784         * lib/spawn_faction_addopen.c (__sysconf): Likewise.
119785         * modules/posix_spawn_file_actions_addclose (Depends-on): Add
119786         getdtablesize.
119787         * modules/posix_spawn_file_actions_adddup2 (Depends-on): Likewise.
119788         * modules/posix_spawn_file_actions_addopen (Depends-on): Likewise.
119790 2008-10-05  Bruno Haible  <bruno@clisp.org>
119792         * modules/getdtablesize-tests: New file.
119793         * tests/test-getdtablesize.c: New file.
119795         New module 'getdtablesize'.
119796         * lib/unistd.in.h (getdtablesize): New declaration.
119797         * lib/getdtablesize.c: New file.
119798         * m4/getdtablesize.m4: New file.
119799         * modules/getdtablesize: New file.
119800         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
119801         GNULIB_GETDTABLESIZE, HAVE_GETDTABLESIZE.
119802         * modules/unistd (Makefile.am): Substitute GNULIB_GETDTABLESIZE,
119803         HAVE_GETDTABLESIZE.
119804         * doc/glibc-functions/getdtablesize.texi: Mention the new module.
119806 2008-10-05  Bruno Haible  <bruno@clisp.org>
119808         * modules/sched (Makefile.am): Fix typo.
119809         Reported by Simon Josefsson.
119811 2008-10-05  Jim Meyering  <meyering@redhat.com>
119813         bootstrap: check for LT_INIT, too
119814         * build-aux/bootstrap: Both AC_PROG_LIBTOOL and AM_PROG_LIBTOOL
119815         are deprecated.  Suggestion from Ralf Wildenhues.
119817 2008-10-05  Bruno Haible  <bruno@clisp.org>
119819         * lib/spawn.in.h (POSIX_SPAWN_*): Use the system's values, rather than
119820         overriding them by ours.
119821         (POSIX_SPAWN_USEVFORK): Use the next free bit position.
119823 2008-10-05  Jim Meyering  <meyering@redhat.com>
119825         bootstrap: check for AC_PROG_LIBTOOL as well as AM_PROG_LIBTOOL
119826         * build-aux/bootstrap: Check for AC_PROG_LIBTOOL, as well as the
119827         obsolete AM_PROG_LIBTOOL.  Spotted by Debarshi Ray <rishi@gnu.org>.
119829 2008-10-04  Bruno Haible  <bruno@clisp.org>
119831         * modules/dup2 (License): Change to LGPLv2+.
119832         * modules/sleep (License): Likewise.
119833         * modules/perror (License): Likewise.
119834         * modules/fopen (License): Change to LGPLv2+, with approval by Eric
119835         Blake.
119836         * modules/signal (License): Likewise.
119837         * modules/sigprocmask (License): Likewise.
119838         * modules/raise (License): Change to LGPLv2+, with approval by Jim
119839         Meyering.
119841 2008-10-04  Bruno Haible  <bruno@clisp.org>
119843         * lib/spawn.in.h (POSIX_SPAWN_*): Undefine before redefining.
119844         Reported by Rainer Tammer <tammer@tammer.net>.
119846 2008-10-03  Paolo Bonzini  <bonzini@gnu.org>
119847             Bruno Haible  <bruno@clisp.org>
119849         * lib/errno.in.h (EWOULDBLOCK) [win32]: Define to EAGAIN.
119850         * lib/winsock.c (set_winsock_errno): Map WSAEWOULDBLOCK to EWOULDBLOCK.
119851         * lib/strerror.c (rpl_strerror): Remove error string for EWOULDBLOCK.
119853 2008-10-03  Kamil Dudka  <kdudka@redhat.com>
119855         filevercmp: new module
119856         * lib/filevercmp.h: New function filevercmp comparing version strings.
119857         * lib/filevercmp.c: Implementation of filevercmp function.
119858         * modules/filevercmp: Module metadata.
119859         * tests/test-filevercmp.c: Unit test for new module.
119860         * modules/filevercmp-tests: Unit test metadata.
119861         * MODULES.html.sh: Add filevercmp module.
119863 2008-10-03  Bruno Haible  <bruno@clisp.org>
119865         * lib/c-ctype.h: Add comment.
119866         Reported by Jim Meyering.
119868 2008-10-02  Bruno Haible  <bruno@clisp.org>
119870         * modules/posix_spawn-internal (Depends-on): Add 'open'.
119872 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
119874         * build-aux/bootstrap: Allow renaming bootstrap, and change the
119875         name of bootstrap.conf accordingly.
119877 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
119879         * build-aux/bootstrap: Install git-merge-changelog configuration
119880         items into .gitconfig if needed.
119882 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
119884         * build-aux/bootstrap: Recognize `gnulib' being a submodule in a
119885         git repository, and initialize/update it accordingly.
119887 2008-10-02  Richard W.M. Jones  <rjones@redhat.com>
119889         * modules/fsync-tests: New file.
119890         * tests/test-fsync.c: New file.
119892         New module 'fsync'.
119893         * lib/fsync.c: New file.
119894         * m4/fsync.m4: New file.
119895         * modules/fsync: New file.
119896         * lib/unistd.in.h (fsync): New declaration.
119897         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define and AC_SUBST both
119898         GNULIB_FSYNC and HAVE_FSYNC.
119899         * modules/unistd: Substitute GNULIB_FSYNC and HAVE_FSYNC.
119900         * MODULES.html.sh (posix_functions): Add fsync.
119901         * doc/posix-functions/fsync.texi: Mention the new module.
119903 2008-10-02  Jim Meyering  <meyering@redhat.com>
119905         fts.c: sync with similar code from coreutils' remove.c
119906         * lib/fts.c (dirent_inode_sort_may_be_useful): Merge from coreutils.
119907         Guard also with "#if defined __linux__", since for now at least,
119908         this code is Linux-kernel-specific.
119910 2008-10-02  Jim Meyering  <meyering@redhat.com>
119912         fts: bug fixes
119913         * lib/fts.c: Remove unnecessary "defined" in cpp directive.
119914         Include <sys/vfs.h>, not <sys/statfs.h>.
119916         * m4/fts.m4 (gl_FUNC_FTS_CORE): Fix typo s/vfs/vfs.h/.
119917         Include <sys/vfs.h>, not <sys/statfs.h>.
119919 2008-10-01  Bruno Haible  <bruno@clisp.org>
119921         Avoid the broken posix_spawn function on AIX 5.3 and 6.1.
119922         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): New macro.
119923         (gl_POSIX_SPAWN_BODY): Invoke it. Set REPLACE_POSIX_SPAWN if needed.
119924         * doc/posix-functions/posix_spawn.texi: Mention the AIX bugs.
119925         * doc/posix-functions/posix_spawnp.texi: Likewise.
119926         * m4/execute.m4 (gl_EXECUTE): Invoke gl_POSIX_SPAWN_WORKS, to check
119927         whether posix_spawn actually works.
119928         * m4/pipe.m4 (gl_PIPE): Likewise.
119929         * modules/execute (Files): Add m4/posix_spawn.m4.
119930         * modules/pipe (Files): Add m4/posix_spawn.m4.
119931         Reported and analyzed by Rainer Tammer <tammer@tammer.net>.
119933 2008-10-01  Jim Meyering  <meyering@redhat.com>
119935         remove trailing spaces
119936         * NEWS: Likewise.
119937         * lib/poll.c (poll): Likewise.
119938         * lib/sys_socket.in.h (SHUT_RDWR): Likewise.
119939         * lib/winsock.c (rpl_close): Likewise.
119940         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Likewise.
119941         * modules/yield: Likewise.
119942         * tests/test-poll.c (connect_to_socket, poll1): Likewise.
119943         * tests/test-sys_select.c (connect_to_socket): Likewise.
119945         fts.c: adjust a new interface to be more generally useful
119946         * lib/fts.c (dirent_inode_sort_may_be_useful): Take an FD parameter.
119947         (fts_build): Adjust caller.
119949 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
119951         * modules/cond-tests: New file.
119952         * tests/test-cond.c: New file.
119954 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
119955             Bruno Haible  <bruno@clisp.org>
119957         * modules/cond (Dependencies): Add errno, time.
119958         * lib/glthread/cond.h: Include <time.h>.
119959         (gl_cond_define, gl_cond_define_initialized): Use the same definition
119960         across platforms.
119962 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
119963             Bruno Haible  <bruno@clisp.org>
119965         * m4/thread.m4 (gl_THREAD): Fix detection of pthread_atfork function.
119967 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
119968             Bruno Haible  <bruno@clisp.org>
119970         * modules/tls-tests (Depends-on): Add thread, yield.
119971         (configure.ac): Remove all checks.
119972         (test_tls_LDADD): Use YIELD_LIB instead of LIBSCHED.
119973         * tests/test-tls.c (gl_thread_t, gl_thread_join, gl_thread_yield,
119974         gl_thread_self): Remove definitions. Include glthread/thread.h and
119975         glthread/yield.h instead.
119976         (test_tls): Pass an additional NULL argument to gl_thread_join.
119978 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
119979             Bruno Haible  <bruno@clisp.org>
119981         * modules/lock-tests (Depends-on): Add thread, yield.
119982         (configure.ac): Remove all checks.
119983         (test_lock_LDADD): Use YIELD_LIB instead of LIBSCHED.
119984         * tests/test-lock.c (gl_thread_t, gl_thread_join, gl_thread_yield,
119985         gl_thread_self): Remove definitions. Include glthread/thread.h and
119986         glthread/yield.h instead.
119987         (test_lock, test_rwlock, test_recursive_lock, test_once): Pass an
119988         additional NULL argument to gl_thread_join.
119990 2008-09-30  Bruno Haible  <bruno@clisp.org>
119992         Fix the Win32 implementation of the 'thread' module.
119993         * lib/glthread/thread.h [USE_WIN32_THREADS] (gl_thread_t): Change to a
119994         pointer type.
119995         (gl_thread_self): Invoke gl_thread_self_func.
119996         (gl_thread_self_func): New declaration.
119997         * lib/glthread/thread.c [USE_WIN32_THREADS] (self_key): New variable.
119998         (do_init_self_key, init_self_key): New functions.
119999         (struct gl_thread_struct): Renamed from 'struct thread_extra'.
120000         Remove some fields.
120001         (running_threads, running_lock): Remove variables.
120002         (get_current_thread_handle): New function.
120003         (gl_thread_self_func, wrapper_func, glthread_create_func,
120004         glthread_join_func, gl_thread_exit_func): Largely rewritten and
120005         simplified.
120007 2008-09-30  Bruno Haible  <bruno@clisp.org>
120009         * lib/winsock-select.c (win32_poll_handle): Add shortcut for regular
120010         files.
120012 2008-09-30  Jim Meyering  <meyering@redhat.com>
120014         fts.m4: correct the test for statfs.f_type
120015         * m4/fts.m4 (gl_FUNC_FTS_CORE): Include <sys/statfs.h>
120016         when checking for statfs.f_type.
120018 2008-09-15  Simon Josefsson  <simon@josefsson.org>
120020         tests: avoid some compiler warnings
120021         * tests/test-memchr.c (main): Pass NULL indirectly.
120022         * tests/test-getdate.c (main): Remove unused variable 'ret'.
120024 2008-09-29  Ondřej Vašík  <ovasik@redhat.com>
120026         getdate.y: disallow countable dayshifts like "4 yesterday ago"
120027         * lib/getdate.y (relative_time_table) [tDAY_SHIFT]: New type for
120028         exactly specified dayshifts.
120029         (dayshift): New rule.
120030         (rel): Add dayshift.
120031         (relative_time_table) [tomorrow, yesterday, today, now]:
120032         Use tDAY_SHIFT in place of tDAY_UNIT.
120033         * tests/test-getdate.c: Add tests for now-disallowed countable
120034         dayshifts, e.g., "4 yesterday ago".
120036 2008-09-29  Bruno Haible  <bruno@clisp.org>
120038         * tests/test-posix_spawn1.c: Renamed from tests/test-posix_spawn.c.
120039         * tests/test-posix_spawn1.in.sh: Renamed from
120040         tests/test-posix_spawn.in.sh.
120041         * tests/test-posix_spawn2.c: New file.
120042         * tests/test-posix_spawn2.in.sh: New file.
120043         * modules/posix_spawnp-tests (Files): Update.
120044         (Makefile.am): Update. Add test-posix_spawn2 to the tests.
120046 2008-09-29  Bruno Haible  <bruno@clisp.org>
120048         Propagate effects of putenv/setenv/unsetenv to child processes.
120049         * lib/execute.c (execute): Use spawnvpe instead of spawnvp.
120050         * lib/pipe.c (create_pipe): Likewise.
120052 2008-09-29  Bruno Haible  <bruno@clisp.org>
120054         Enable use of shell scripts as executables in mingw.
120055         * lib/execute.c (execute): When spawnv fails with error ENOEXEC,
120056         run the program as a shell script.
120057         * lib/pipe.c (create_pipe): Likewise.
120058         * lib/w32spawn.h (prepare_spawn): Add a hidden element in front of the
120059         resulting array.
120061 2008-09-29  Eric Blake  <ebb9@byu.net>
120063         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Fix typo.
120065 2008-08-24  Paolo Bonzini  <bonzini@gnu.org>
120067         * doc/posix-functions/accept.texi: Update mingw problems.
120068         * doc/posix-functions/bind.texi: Update mingw problems.
120069         * doc/posix-functions/close.texi: Update mingw problems.
120070         * doc/posix-functions/connect.texi: Update mingw problems.
120071         * doc/posix-functions/getpeername.texi: Update mingw problems.
120072         * doc/posix-functions/getsockname.texi: Update mingw problems.
120073         * doc/posix-functions/getsockopt.texi: Update mingw problems.
120074         * doc/posix-functions/ioctl.texi: Update mingw problems.
120075         * doc/posix-functions/listen.texi: Update mingw problems.
120076         * doc/posix-functions/recv.texi: Update mingw problems.
120077         * doc/posix-functions/recvfrom.texi: Update mingw problems.
120078         * doc/posix-functions/select.texi: Update mingw problems.
120079         * doc/posix-functions/send.texi: Update mingw problems.
120080         * doc/posix-functions/sendto.texi: Update mingw problems.
120081         * doc/posix-functions/setsockopt.texi: Update mingw problems.
120082         * doc/posix-functions/socket.texi: Update mingw problems.
120084 2008-09-29  Paolo Bonzini  <bonzini@gnu.org>
120085             Bruno Haible  <bruno@clisp.org>
120087         * lib/sys_select.in.h: Include sys/time.h.
120088         * m4/sys_select.h.m4: Test that struct timeval is fully defined.
120089         * modules/sys_select: Depend on sys_time.
120090         * tests/test-sys_select.c: Test that sys/select.h defines struct
120091         timeval fully.
120093 2008-09-29  Bruno Haible  <bruno@clisp.org>
120095         * lib/sys_socket.in.h: Wrap the definitions in 'extern "C"'.
120096         * lib/sys_select.in.h: Likewise.
120098 2008-09-29  Bruno Haible  <bruno@clisp.org>
120100         * lib/winsock.c (rpl_close, rpl_socket): Remove unused variables.
120102 2008-09-29  Bruno Haible  <bruno@clisp.org>
120104         * m4/sockets.m4 (gl_SOCKETS): Check also for the need to use -lsocket.
120105         Set LIBSOCKET instead of augmenting LIBS.
120106         * modules/sockets (Link): New section.
120107         * modules/sockets-tests (test_sockets_LDADD): New variable.
120108         * modules/sys_select-tests (test_sys_select_LDADD): New variable.
120109         * modules/poll-tests (test_poll_LDADD): New variable.
120110         * NEWS: Document the change.
120112 2008-09-29  Bruno Haible  <bruno@clisp.org>
120114         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): New macro.
120115         * m4/inet_ntop.m4 (gl_INET_NTOP): Invoke it instead of assigning
120116         ARPA_INET_H directly.
120117         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
120119 2008-09-28  Bruno Haible  <bruno@clisp.org>
120121         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): New macro, extracted
120122         from gl_HEADER_SYS_SOCKET.
120123         (gl_HEADER_SYS_SOCKET): Invoke it.
120124         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
120126 2008-09-28  Bruno Haible  <bruno@clisp.org>
120128         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem.
120129         * tests/test-sys_select.c: Include <sys/time.h>, for struct timeval.
120130         Needed on OSF/1 4.0.
120132 2008-09-28  Bruno Haible  <bruno@clisp.org>
120134         Override open more carefully.
120135         * lib/open.c (orig_open): New function.
120136         (rpl_open): Use orig_open instead of open.
120137         * lib/fcntl.in.h: Add special invocation convention.
120138         * m4/open.m4 (gl_PREREQ_OPEN): New macro.
120139         (gl_FUNC_OPEN): Invoke it.
120141         Override freopen more carefully.
120142         * lib/freopen.c (orig_freopen): New function.
120143         (rpl_freopen): Use orig_freopen instead of freopen.
120144         * m4/freopen.m4 (gl_PREREQ_FREOPEN): New macro.
120145         (gl_FUNC_FREOPEN): Invoke it.
120147         Override fopen more carefully.
120148         * lib/fopen.c (orig_fopen): New function.
120149         (rpl_fopen): Use orig_fopen instead of fopen.
120150         * m4/fopen.m4 (gl_PREREQ_FOPEN): New macro.
120151         (gl_FUNC_FOPEN): Invoke it.
120152         Needed on AIX. Reported by Rainer Tammer <tammer@tammer.net>.
120154 2008-09-28  Bruno Haible  <bruno@clisp.org>
120156         * lib/pipe.h (create_pipe_out, create_pipe_bidi): Add comment about
120157         SIGPIPE.
120159 2008-09-28  Bruno Haible  <bruno@clisp.org>
120161         * tests/test-sigaction.c (handler, main): Disable the check whether
120162         SA_RESETHAND has reverted the installed handler to SIG_DFL. Needed on
120163         glibc systems with LinuxThreads.
120165 2008-09-28  Bruno Haible  <bruno@clisp.org>
120167         * doc/posix-functions/freopen.texi: Mention the trailing slash problem.
120169         * lib/stdio.in.h (fopen, freopen): Undefine before redefining. Needed
120170         with AIX xlc.
120171         * lib/fcntl.in.h (open): Likewise.
120172         Reported by Rainer Tammer <tammer@tammer.net>.
120174 2008-09-28  Bruno Haible  <bruno@clisp.org>
120176         * modules/posix_spawnp-tests: New file.
120177         * tests/test-posix_spawn.c: New file.
120178         * tests/test-posix_spawn.in.sh: New file.
120180         New module 'posix_spawnp'.
120181         * modules/posix_spawnp: New file.
120182         * lib/spawnp.c: New file, from GNU libc with modifications.
120183         * doc/posix-functions/posix_spawnp.texi: Mention the new module.
120185         New module 'posix_spawn'.
120186         * modules/posix_spawn: New file.
120187         * lib/spawn.c: New file, from GNU libc with modifications.
120188         * doc/posix-functions/posix_spawn.texi: Mention the new module.
120190         New module 'posix_spawnattr_destroy'.
120191         * modules/posix_spawnattr_destroy: New file.
120192         * lib/spawnattr_destroy.c: New file, from GNU libc with modifications.
120193         * doc/posix-functions/posix_spawnattr_destroy.texi: Mention the new
120194         module.
120196         New module 'posix_spawnattr_setsigmask'.
120197         * modules/posix_spawnattr_setsigmask: New file.
120198         * lib/spawnattr_setsigmask.c: New file, from GNU libc with
120199         modifications.
120200         * doc/posix-functions/posix_spawnattr_setsigmask.texi: Mention the
120201         new module.
120203         New module 'posix_spawnattr_getsigmask'.
120204         * modules/posix_spawnattr_getsigmask: New file.
120205         * lib/spawnattr_getsigmask.c: New file, from GNU libc with
120206         modifications.
120207         * doc/posix-functions/posix_spawnattr_getsigmask.texi: Mention the
120208         new module.
120210         New module 'posix_spawnattr_setsigdefault'.
120211         * modules/posix_spawnattr_setsigdefault: New file.
120212         * lib/spawnattr_setdefault.c: New file, from GNU libc with
120213         modifications.
120214         * doc/posix-functions/posix_spawnattr_setsigdefault.texi: Mention the
120215         new module.
120217         New module 'posix_spawnattr_getsigdefault'.
120218         * modules/posix_spawnattr_getsigdefault: New file.
120219         * lib/spawnattr_getdefault.c: New file, from GNU libc with
120220         modifications.
120221         * doc/posix-functions/posix_spawnattr_getsigdefault.texi: Mention the
120222         new module.
120224         New module 'posix_spawnattr_setschedpolicy'.
120225         * modules/posix_spawnattr_setschedpolicy: New file.
120226         * lib/spawnattr_setschedpolicy.c: New file, from GNU libc with
120227         modifications.
120228         * doc/posix-functions/posix_spawnattr_setschedpolicy.texi: Mention the
120229         new module.
120231         New module 'posix_spawnattr_getschedpolicy'.
120232         * modules/posix_spawnattr_getschedpolicy: New file.
120233         * lib/spawnattr_getschedpolicy.c: New file, from GNU libc with
120234         modifications.
120235         * doc/posix-functions/posix_spawnattr_getschedpolicy.texi: Mention the
120236         new module.
120238         New module 'posix_spawnattr_setschedparam'.
120239         * modules/posix_spawnattr_setschedparam: New file.
120240         * lib/spawnattr_setschedparam.c: New file, from GNU libc with
120241         modifications.
120242         * doc/posix-functions/posix_spawnattr_setschedparam.texi: Mention the
120243         new module.
120245         New module 'posix_spawnattr_getschedparam'.
120246         * modules/posix_spawnattr_getschedparam: New file.
120247         * lib/spawnattr_getschedparam.c: New file, from GNU libc with
120248         modifications.
120249         * doc/posix-functions/posix_spawnattr_getschedparam.texi: Mention the
120250         new module.
120252         New module 'posix_spawnattr_setpgroup'.
120253         * modules/posix_spawnattr_setpgroup: New file.
120254         * lib/spawnattr_setpgroup.c: New file, from GNU libc with
120255         modifications.
120256         * doc/posix-functions/posix_spawnattr_setpgroup.texi: Mention the new
120257         module.
120259         New module 'posix_spawnattr_getpgroup'.
120260         * modules/posix_spawnattr_getpgroup: New file.
120261         * lib/spawnattr_getpgroup.c: New file, from GNU libc with
120262         modifications.
120263         * doc/posix-functions/posix_spawnattr_getpgroup.texi: Mention the new
120264         module.
120266         New module 'posix_spawnattr_setflags'.
120267         * modules/posix_spawnattr_setflags: New file.
120268         * lib/spawnattr_setflags.c: New file, from GNU libc with modifications.
120269         * doc/posix-functions/posix_spawnattr_setflags.texi: Mention the new
120270         module.
120272         New module 'posix_spawnattr_getflags'.
120273         * modules/posix_spawnattr_getflags: New file.
120274         * lib/spawnattr_getflags.c: New file, from GNU libc with modifications.
120275         * doc/posix-functions/posix_spawnattr_getflags.texi: Mention the new
120276         module.
120278         New module 'posix_spawnattr_init'.
120279         * modules/posix_spawnattr_init: New file.
120280         * lib/spawnattr_init.c: New file, from GNU libc with modifications.
120281         * doc/posix-functions/posix_spawnattr_init.texi: Mention the new
120282         module.
120284         New module 'posix_spawn_file_actions_destroy'.
120285         * modules/posix_spawn_file_actions_destroy: New file.
120286         * lib/spawn_faction_destroy.c: New file, from GNU libc with
120287         modifications.
120288         * doc/posix-functions/posix_spawn_file_actions_destroy.texi: Mention
120289         the new module.
120291         New module 'posix_spawn_file_actions_addopen'.
120292         * modules/posix_spawn_file_actions_addopen: New file.
120293         * lib/spawn_faction_addopen.c: New file, from GNU libc with
120294         modifications.
120295         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Mention
120296         the new module.
120298         New module 'posix_spawn_file_actions_adddup2'.
120299         * modules/posix_spawn_file_actions_adddup2: New file.
120300         * lib/spawn_faction_adddup2.c: New file, from GNU libc with
120301         modifications.
120302         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Mention
120303         the new module.
120305         New module 'posix_spawn_file_actions_addclose'.
120306         * modules/posix_spawn_file_actions_addclose: New file.
120307         * lib/spawn_faction_addclose.c: New file, from GNU libc with
120308         modifications.
120309         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
120310         the new module.
120312         New module 'posix_spawn_file_actions_init'.
120313         * modules/posix_spawn_file_actions_init: New file.
120314         * lib/spawn_faction_init.c: New file, from GNU libc with modifications.
120315         * doc/posix-functions/posix_spawn_file_actions_init.texi: Mention the
120316         new module.
120318         New module 'posix_spawn-internal'.
120319         * modules/posix_spawn-internal: New file.
120320         * lib/spawn_int.h: New file, from GNU libc with modifications.
120321         * lib/spawni.c: New file, from GNU libc with modifications.
120322         * m4/posix_spawn.m4: New file.
120324         New module 'spawn'.
120325         * modules/spawn: New file.
120326         * lib/spawn.in.h: New file, from GNU libc with modifications.
120327         * m4/spawn_h.m4: New file.
120328         * doc/posix-headers/spawn.texi: Mention the new module.
120330 2008-09-28  Bruno Haible  <bruno@clisp.org>
120332         * modules/sched-tests: New file.
120333         * tests/test-sched.c: New file.
120335         New module 'sched'.
120336         * modules/sched: New file.
120337         * lib/sched.in.h: New file.
120338         * m4/sched_h.m4: New file.
120339         * doc/posix-headers/sched.texi: Mention the new module.
120341 2008-09-27  Eric Blake  <ebb9@byu.net>
120343         Fix previous patch, and tweak references to $0.
120344         * posix-modules: Call func_gnulib_dir before using $gnulib_dir.
120345         (func_version, func_gnulib_dir): Don't call this program
120346         gnulib-tool.
120347         (func_gnulib_dir, func_tmpdir, func_fatal_error): Avoid shell bugs
120348         with using $0 in function.
120349         * gnulib-tool (func_gnulib_dir, func_tmpdir): Likewise.
120350         (func_fatal_error): Reuse the name the user invoked us with.
120352 2008-09-27  Bruno Haible  <bruno@clisp.org>
120354         * m4/iconv_h.m4 (gl_REPLACE_ICONV_H): New macro.
120355         (gl_ICONV_H_DEFAULTS): Initialize ICONV_H here...
120356         (gl_ICONV_H): Not here.
120357         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H
120358         instead of assigning ICONV_H directly.
120360         * m4/wchar.m4 (gl_REPLACE_WCHAR_H): New macro.
120361         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Invoke it instead of assigning
120362         WCHAR_H directly.
120364 2008-09-27  Bruno Haible  <bruno@clisp.org>
120366         * lib/arpa_inet.in.h: Include the GL_LINK_WARNING anchor.
120367         * modules/arpa_inet (Depends-on): Add link-warning.
120368         (Makefile.am): Insert the definition of GL_LINK-WARNING.
120369         * modules/unistd (Makefile.am): Likewise.
120371 2008-09-26  Bruno Haible  <bruno@clisp.org>
120373         * posix-modules (cvsdatestamp, last_checkin_date, version): Remove
120374         variables.
120375         (func_version): Essentially copied from gnulib-tool.
120376         (func_exit, func_gnulib_dir, func_tmpdir, func_fatal_error,
120377         func_readlink): Copied from gnulib-tool.
120379 2008-09-26  Bruno Haible  <bruno@clisp.org>
120381         * gnulib-tool (func_version): Change directory to $gnulib_dir before
120382         invoking git-version-gen.
120384 2008-09-26  Bruno Haible  <bruno@clisp.org>
120386         * posix-modules: Update to directory names changed on 2008-01-19.
120387         Remove commas in output before splitting into words. No more need to
120388         avoid 'ftruncate' since 2007-02-19.
120390 2008-09-26  Bruno Haible  <bruno@clisp.org>
120392         * doc/posix-headers/errno.texi: Remove mention of module 'EOVERFLOW'.
120394 2008-09-26  Bruno Haible  <bruno@clisp.org>
120396         * lib/fwriteerror.c (do_fwriteerror): Ignore error EPIPE.
120397         * modules/fwriteerror (Depends-on): Add errno.
120399 2008-09-26  Bruno Haible  <bruno@clisp.org>
120401         * tests/test-vc-list-files-git.sh: Explain reason for skipping test.
120402         * tests/test-vc-list-files-cvs.sh: Likewise.
120404 2008-09-26  Bruno Haible  <bruno@clisp.org>
120406         * doc/posix-headers/sys_resource.texi: Reorder items.
120408 2008-09-26  Jim Meyering  <meyering@redhat.com>
120410         fts: tweak inode comparison function
120411         * lib/fts.c (fts_compare_ino): Sort on increasing, not decreasing
120412         inode numbers, as documented.
120414         fts: sort dirent entries on inode number before traversing
120415         This avoids a quadratic, seek-related performance penalty when
120416         operating on a directory containing many entries (measurable at 10k;
120417         3.5 hours at 2 million entries with a cold cache) on certain types
120418         of file systems, including ext3 and ext4, but not tmpfs.
120419         * lib/fts.c (DT_MUST_BE, NOT_AN_INODE_NUMBER, D_INO): Define.
120420         (FTS_INODE_SORT_DIR_ENTRIES_THRESHOLD): Define if not defined.
120421         (S_MAGIC_TMPFS, S_MAGIC_NFS): Define.
120422         (fs_handles_readdir_ordered_dirents_efficiently): New function.
120423         (dirent_inode_sort_may_be_useful, fts_compare_ino): Likewise.
120424         (fts_build): Set the stat.st_ino member from D_INO.
120425         If it is likely to be useful, sort dirent entries on inode number.
120427         * m4/fts.m4 (gl_FUNC_FTS_CORE): Check for fstatfs, sys/vfs.h,
120428         and the struct statfs.f_type member.
120429         * modules/fts (Depends-on): Add d-ino.
120431 2008-09-26  Bruno Haible  <bruno@clisp.org>
120433         * modules/sigpipe-die (Depends-on): Add sigpipe.
120435         * lib/stdio.in.h (fprintf, vfprintf, printf, vprintf, fputc, putc,
120436         putchar, fputs, puts, fwrite): Replace when REPLACE_STDIO_WRITE_FUNCS
120437         and GNULIB_STDIO_H_SIGPIPE are set.
120438         * lib/stdio-write.c: New file.
120439         * m4/stdio_h.m4 (gl_STDIO_H): Set GNULIB_FPRINTF, GNULIB_PRINTF,
120440         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
120441         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
120442         REPLACE_STDIO_WRITE_FUNCS.
120443         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FPRINTF, GNULIB_PRINTF,
120444         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
120445         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
120446         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
120447         * modules/stdio (Files): Add lib/stdio-write.c.
120448         (Makefile.am): Substitute GNULIB_FPRINTF, GNULIB_PRINTF,
120449         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
120450         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
120451         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
120452         * m4/fprintf-posix.m4 (gl_REPLACE_FPRINTF): Define
120453         REPLACE_FPRINTF_POSIX.
120454         * m4/printf-posix-rpl.m4 (gl_REPLACE_PRINTF): Define
120455         REPLACE_PRINTF_POSIX.
120456         * m4/vfprintf-posix.m4 (gl_REPLACE_VFPRINTF): Define
120457         REPLACE_VFPRINTF_POSIX.
120458         * m4/vprintf-posix.m4 (gl_REPLACE_VPRINTF): Define
120459         REPLACE_VPRINTF_POSIX.
120460         * doc/posix-functions/fprintf.texi: Mention the sigpipe module and the
120461         SIGPIPE issue.
120462         * doc/posix-functions/fputc.texi: Likewise.
120463         * doc/posix-functions/fputs.texi: Likewise.
120464         * doc/posix-functions/fwrite.texi: Likewise.
120465         * doc/posix-functions/printf.texi: Likewise.
120466         * doc/posix-functions/putc.texi: Likewise.
120467         * doc/posix-functions/putchar.texi: Likewise.
120468         * doc/posix-functions/puts.texi: Likewise.
120469         * doc/posix-functions/vfprintf.texi: Likewise.
120470         * doc/posix-functions/vprintf.texi: Likewise.
120472         * modules/safe-write (Depends-on): Add write.
120474         * modules/sigpipe-tests: New file.
120475         * tests/test-sigpipe.c: New file.
120476         * tests/test-sigpipe.sh: New file.
120478         * modules/write: New file.
120479         * lib/unistd.in.h: Include <sys/types.h>.
120480         (write): New declaration.
120481         * lib/write.c: New file.
120482         * m4/write.m4: New file.
120483         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
120484         GNULIB_UNISTD_H_SIGPIPE, GNULIB_WRITE, REPLACE_WRITE.
120485         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_SIGPIPE,
120486         GNULIB_WRITE, REPLACE_WRITE.
120487         * doc/posix-functions/write.texi: Mention the write, sigpipe modules
120488         and the SIGPIPE issue.
120490         * lib/signal.in.h (SIGPIPE): Define to a replacement value.
120491         (raise): New declaration.
120492         * lib/sigprocmask.c (SIGPIPE_handler): New variable.
120493         (ext_signal): New function.
120494         (rpl_raise): New function.
120495         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
120496         GNULIB_SIGNAL_H_SIGPIPE.
120497         * modules/signal (Makefile.am): Substitute GNULIB_SIGNAL_H_SIGPIPE.
120498         * doc/posix-headers/signal.texi: Mention the SIGPIPE issue.
120500         * modules/sigpipe: New file.
120501         * m4/sigpipe.m4: New file.
120503 2008-09-25  Derek Price  <derek@ximbiot.com>
120504             Bruno Haible  <bruno@clisp.org>
120506         * gnulib-tool (func_import): Report all license incompatibilities, not
120507         just the first one.
120509 2008-09-25  Bruno Haible  <bruno@clisp.org>
120511         * gnulib-tool (func_import): When computing the edits, consider not
120512         only the Makefile.ams that exist but also those that will be generated.
120514 2008-09-25  Simon Josefsson  <simon@josefsson.org>
120516         * modules/sys_select-tests (Depends-on): Remove sys_select itself,
120517         fixes gnulib-tool --test warning about duplicate dependency.
120519 2008-09-25  Bruno Haible  <bruno@clisp.org>
120521         * gnulib-tool: Don't ask the user to perform edits in the generated
120522         Makefile.ams.
120523         (func_emit_lib_Makefile_am): Emit empty SUBDIRS. Execute edits that
120524         apply to the Makefile.am being generated.
120525         (func_emit_tests_Makefile_am): Execute edits that apply to the
120526         Makefile.am being generated.
120527         (func_import): Setup list of Makefile.am edits before emitting the
120528         Makefile.ams, not at the end.
120529         (func_create_testdir): Update.
120530         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
120532 2008-09-25  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
120534         * gnulib-tool (func_import): Store the --tests-base option in the
120535         comment in gnulib-cache.m4.
120537 2008-09-24  Paolo Bonzini  <bonzini@gnu.org>
120539         * NEWS: Document increased portability that sys_select now provides.
120541         * lib/sys_select.in.h: Install select wrapper.
120542         * lib/sys_socket.in.h: Use more descriptive name when there is no
120543         select wrapper.
120544         * lib/winsock-select.c: New.
120545         * m4/sys_select_h.m4: Compile lib/winsock-select.c if WinSock is used.
120546         Require gl_HEADER_SYS_SOCKET.
120547         * modules/sys_select: Depend on alloca, add lib/winsock-select.c.
120548         * modules/sys_select-tests: Copy dependencies from modules/poll-tests.
120549         * tests/test-sys_select.c: Add functional tests.
120551 2008-09-24  Eric Blake  <ebb9@byu.net>
120553         open, fopen: close fd leak in last patch
120554         * lib/open.c (rpl_open): Close fd before returning error.
120555         * lib/fopen.c (rpl_fopen): Close fd before returning error.
120556         * doc/posix-functions/open.texi (open): Document that Irix also
120557         has the bug.
120558         * doc/posix-functions/fopen.texi (fopen): Likewise.
120559         Reported by Paolo Bonzini.
120561 2008-09-24  Bruno Haible  <bruno@clisp.org>
120563         Ensure that a filename ending in a slash cannot be used to access a
120564         non-directory.
120565         * lib/open.c (rpl_open): When the filename ends in a slash, use fstat()
120566         to check whether it's really a directory.
120567         * lib/fopen.c: Include fcntl.h, unistd.h.
120568         (rpl_fopen): When the filename ends in a slash, use open(), fstat(),
120569         and fdopen().
120570         * modules/fopen (Depends-on): Add unistd.
120571         * tests/test-open.c (main): Try to open "/dev/null/" as a directory.
120572         * tests/test-fopen.c (main): Likewise.
120573         * doc/posix-functions/open.texi: Mention the HP-UX, Solaris bug.
120574         * doc/posix-functions/fopen.texi: Likewise.
120575         Reported by Eric Blake.
120577 2008-09-23  Eric Blake  <ebb9@byu.net>
120579         c-stack: avoid compiler optimizations when provoking overflow
120580         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Make
120581         recursion harder to optimize, to ensure a stack overflow occurs.
120582         * tests/test-c-stack.c (recurse): Likewise.
120583         Borrowed from libsigsegv.
120585         c-stack: work around Irix sigaltstack bug
120586         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check
120587         whether sigaltstack uses wrong end of stack_t (copied in part from
120588         libsigsegv).
120589         * lib/c-stack.c (c_stack_action) [!HAVE_LIBSIGSEGV]: Work around
120590         Irix bug, without requiring an over-allocation.
120591         * doc/posix-functions/sigaltstack.texi (sigaltstack): Document the
120592         bug.
120594         fopen: document mingw bug on directories
120595         * doc/posix-functions/fopen.texi (fopen): Mention mingw bug for
120596         not allowing a stream visiting a directory, even though reading
120597         from such a stream is not portable.
120599 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
120601         * lib/poll.c: Rewrite.
120602         * modules/poll: Depend on alloca.
120604 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
120606         * lib/sys_socket.in.h: Do not implement rpl_setsockopt here,
120607         instead define prototypes for a full set of wrappers.  Ensure
120608         that Cygwin does not use the compatibility code, which is only
120609         for MinGW.
120610         * lib/winsock.c: New.
120611         * m4/sys_socket_h.m4: Compile lib/winsock.c if WinSock is being used.
120612         * modules/sys_socket: Add lib/winsock.c.
120614         * modules/poll-tests: Add errno and perror.
120615         * tests/test-poll.c: Use ioctl, not ioctlsocket.
120617 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
120619         * tests/test-poll.c: Downgrade minimum needed Winsock version.
120621 2008-09-23  Bruno Haible  <bruno@clisp.org>
120623         * doc/posix-functions/*: Add info about functions missing on IRIX 5.3.
120624         * doc/glibc-functions/*: Likewise.
120626 2008-09-23  Simon Josefsson  <simon@josefsson.org>
120628         * tests/test-perror.sh (tmpfiles): Cleanup temporary files on
120629         success.
120631 2008-09-22  Eric Blake  <ebb9@byu.net>
120632             Bruno Haible  <bruno@clisp.org>
120634         vasnprintf: fix x86/glibc regression on printf("%La", 0.0L)
120635         * lib/vasnprintf.c (VASNPRINTF): Support 0.0 on platforms that
120636         supply %A but mishandle pseudo-NaN.
120637         Reported by Simon Josefsson.
120639 2008-09-21  Bruno Haible  <bruno@clisp.org>
120641         * tests/test-lock.c (main): Tweak skip message.
120642         * tests/test-tls.c (main): Likewise.
120644 2008-09-21  Bruno Haible  <bruno@clisp.org>
120646         * m4/sigaction.m4 (gl_SIGACTION): Remove unnecessary AC_SUBST. Check
120647         whether 'struct sigaction' has sa_sigaction here...
120648         (gl_PREREQ_SIG_HANDLER_H): ... not here.
120649         (gl_PREREQ_SIGACTION): Remove unnecessary AC_SUBST.
120651 2008-09-21  Bruno Haible  <bruno@clisp.org>
120653         * MODULES.html.sh (Support for obsolete systems lacking ANSI C 89): New
120654         section.
120655         (Support for systems lacking ANSI C 89): Move stdlib, exit, strtol,
120656         strtoul, memchr, memcmp, memcpy, memmove, memset, strcspn, strpbrk to
120657         the new section.
120658         (Support for obsolete systems lacking POSIX:2001): New section.
120659         (String handling <string.h>): Move strdup to the new section.
120660         Suggested by Simon Josefsson and Paolo Bonzini.
120662 2008-09-21  Bruno Haible  <bruno@clisp.org>
120664         * tests/test-vasnprintf-posix.c (test_function): Allow 3-digit
120665         exponents in %e and %g results on 'long double'. Needed for mingw's
120666         improved *printf functions.
120667         * tests/test-vasprintf-posix.c (test_function): Likewise.
120668         * tests/test-snprintf-posix.h (test_function): Likewise.
120669         * tests/test-sprintf-posix.h (test_function): Likewise.
120670         Reported by Eric Blake.
120672 2008-09-21  Bruno Haible  <bruno@clisp.org>
120674         * tests/test-snprintf-posix.h (test_function): Remove useless ASSERTs.
120675         * tests/test-sprintf-posix.h (test_function): Likewise.
120677 2008-09-21  Bruno Haible  <bruno@clisp.org>
120679         * modules/getpass (Depends-on): Add strdup-posix.
120681         New module 'strdup-posix'.
120682         * modules/strdup-posix: New file.
120683         * m4/strdup.m4 (gl_FUNC_STRDUP_POSIX): New macro.
120684         * lib/string.in.h (strdup): Replace if REPLACE_STRDUP is 1.
120685         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
120686         REPLACE_STRDUP.
120687         * modules/string (Makefile.am): Substitute REPLACE_STRDUP.
120688         * doc/posix-functions/strdup.texi: Mention module strdup-posix.
120689         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
120690         strdup-posix.
120692         * modules/strdup (Depends-on): Remove malloc-posix.
120694 2008-09-20  Bruno Haible  <bruno@clisp.org>
120696         * lib/fstrcmp.c: Add data about branch probabilities, from Ralf
120697         Wildenhues.
120699 2008-09-20  Bruno Haible  <bruno@clisp.org>
120701         Ensure that wint_t gets defined on IRIX 5.3.
120702         * lib/wchar.in.h (wint_t): Define if not defined by the system.
120703         * lib/wctype.in.h (wint_t): Likewise.
120704         (__wctype_wint_t): Remove type.
120705         (isw*): Use wint_t instead of __wctype_wint_t.
120706         * m4/wchar.m4 (gl_WCHAR_H): Invoke gt_TYPE_WINT_T and set HAVE_WINT_T.
120707         * modules/wchar (Files): Add m4/wint_t.m4.
120708         (Makefile.am): Substitute HAVE_WINT_T.
120709         * tests/test-wchar.c: Check that wchar_t and wint_t are defined.
120710         * tests/test-wctype.c: Check that wint_t is defined.
120711         * doc/posix-headers/wchar.texi: Mention the IRIX 5 problem.
120712         * doc/posix-headers/wctype.texi: Likewise.
120713         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
120715 2008-09-18  Bruno Haible  <bruno@clisp.org>
120717         * gnulib-tool (func_exit): Update comment.
120719 2008-09-18  Simon Josefsson  <simon@josefsson.org>
120721         * modules/getaddrinfo (Depends-on): Remove strdup, this module
120722         assumes strdup exists and does not depend on strdup to return
120723         ENOMEM on out of memory conditions.
120725 2008-09-18  Bruno Haible  <bruno@clisp.org>
120727         * lib/vasnprintf.c (VASNPRINTF): When printing ±0.0L in
120728         NEED_PRINTF_INFINITE_LONG_DOUBLE case with 'e' format, always use two
120729         digits for the exponent.
120731 2008-09-18  Jim Meyering  <meyering@redhat.com>
120732             Bruno Haible  <bruno@clisp.org>
120734         * lib/vasnprintf.c (decimal_point_char): Define also if
120735         NEED_PRINTF_INFINITE_LONG_DOUBLE.
120737 2008-09-16  Bruno Haible  <bruno@clisp.org>
120738         and Eric Blake  <ebb9@byu.net>
120740         vasnprintf: support Irix 5.3
120741         * lib/vasnprintf.c (VASNPRINTF): Also handle -0.0L on platforms
120742         that mishandle long double infinity.
120743         Reported by Tom G. Christensen.
120745 2008-09-16  Bruno Haible  <bruno@clisp.org>
120747         * doc/glibc-functions/scandir.texi: Mention the function is missing on
120748         Solaris 9.
120749         * doc/glibc-functions/alphasort.texi: Likewise.
120750         Reported by Michael Haubenwallner <michael.haubenwallner@salomon.at>.
120752 2008-09-16  Jim Meyering  <meyering@redhat.com>
120754         posix-shell.m4: reject opensolaris's "sh (AT&T Research) 1993-12-28 s+"
120755         * m4/posix-shell.m4 (gl_POSIX_SHELL): Reject a shell that lets
120756         a umask modification leak out of a subshell.  Otherwise, the
120757         opensolaris /bin/sh would be accepted and thus cause unwarranted
120758         failures in the coreutils test suite.
120760 2008-09-16  Paolo Bonzini  <bonzini@gnu.org>
120762         * tests/test-poll.c (connect_to_socket): Allow non-blocking connect
120763         to succeed.
120765 2008-09-16  Jim Meyering  <meyering@redhat.com>
120767         avoid spurious test failure when library is built without ACL support
120768         * m4/acl.m4 (USE_ACL): Define as a shell variable, too, for...
120769         * modules/acl-tests (Makefile.am) [TESTS_ENVIRONMENT]: Add USE_ACL.
120770         * tests/test-file-has-acl.sh: Skip if USE_ACL == 0.
120771         * tests/test-copy-acl.sh: Likewise.
120773 2008-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
120775         * lib/fstrcmp.c (fstrcmp_bounded): Use a second, less quick upper bound
120776         based on character occurrence counts.
120778 2008-09-15  Eric Blake  <ebb9@byu.net>
120780         tests: avoid some compiler warnings
120781         * tests/test-memchr.c (main): Pass NULL indirectly.
120782         * tests/test-closein.c (main): Avoid unused variable.
120784 2008-09-15  Bruno Haible  <bruno@clisp.org>
120786         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test for all the macros that
120787         are missing on OpenBSD 4.0 individually.
120788         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
120790 2008-09-15  Bruno Haible  <bruno@clisp.org>
120792         * doc/posix-headers/errno.texi: Mention the Cygwin problem.
120793         * doc/posix-functions/strerror.texi: Mention also Cygwin.
120794         * doc/posix-functions/perror.texi: Likewise.
120795         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test also whether ECANCELED
120796         is missing.
120797         Reported by Eric Blake.
120799         * lib/errno.in.h: Use replacement values >= 2000.
120800         Reported by Eric Blake.
120802 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
120804         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Add field 'edit_count_limit'.
120805         (EARLY_ABORT): Return true when the edit_count has grown too beyond the
120806         limit.
120807         (fstrcmp_bounded): Initialize the edit_count_limit. Return 0 when
120808         compareseq was aborted.
120810 2008-09-14  Bruno Haible  <bruno@clisp.org>
120812         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Combine xvec_edit_count and
120813         yvec_edit_count.
120814         (NOTE_DELETE, NOTE_INSERT): Increment the combined edit count.
120815         (fstrcmp_bounded): Simplify result computation accordingly.
120817 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
120819         * lib/fstrcmp.h (fstrcmp_bounded): New declaration.
120820         (fstrcmp): Define in terms of fstrcmp_bounded.
120821         * lib/fstrcmp.c (fstrcmp_bounded): Renamed from fstrcmp. Add
120822         lower_bound argument.
120823         Return quickly if the result is certainly < lower_bound.
120824         * tests/test-fstrcmp.c (check_fstrcmp): Test also fstrcmp_bounded.
120826 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
120828         * lib/diffseq.h (EARLY_ABORT): New macro.
120829         (compareseq): Change return type to bool. Return true when EARLY_ABORT
120830         evaluates to true.
120832 2008-09-14  Bruno Haible  <bruno@clisp.org>
120834         * modules/perror-tests: New file.
120835         * tests/test-perror.sh: New file.
120836         * tests/test-perror.c: New file.
120838         New module 'perror'.
120839         * lib/stdio.in.h (perror): New declaration.
120840         * lib/perror.c: New file.
120841         * m4/perror.m4: New file.
120842         * modules/perror: New file.
120843         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add perror.
120844         * doc/posix-functions/perror.texi: Mention the perror module.
120845         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_PERROR,
120846         REPLACE_PERROR.
120847         * modules/stdio (Makefile.am): Substitute GNULIB_PERROR,
120848         REPLACE_PERROR.
120850 2008-09-14  Bruno Haible  <bruno@clisp.org>
120852         * modules/stdio (Makefile.am): Reorder to match the order in
120853         lib/stdio.in.h.
120854         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
120856 2008-09-13  Bruno Haible  <bruno@clisp.org>
120858         * lib/sys_socket.in.h (EINPROGRESS, ...): Remove definitions.
120860 2008-09-13  Bruno Haible  <bruno@clisp.org>
120862         Extend strerror to cover the added errno values.
120863         * lib/strerror.c: Include errno.h and winsock2.h if it exists.
120864         (rpl_strerror): Provide error messages for the added errno values and
120865         for the WSA* values.
120866         * m4/strerror.m4 (gl_FUNC_STRERROR): Test REPLACE_STRERROR.
120867         (gl_FUNC_STRERROR_SEPARATE): If errno.h is replaced, always replace
120868         strerror.
120869         (gl_PREREQ_STRERROR): Test whether winsock2.h exists.
120870         * modules/strerror (Depends-on): Add errno.
120871         * doc/posix-functions/strerror.texi: Document the change.
120872         * tests/test-strerror.c (main): Check also the string for ETIMEDOUT
120873         and EOVERFLOW.
120875 2008-09-13  Bruno Haible  <bruno@clisp.org>
120877         * modules/EOVERFLOW: Remove file.
120878         * m4/eoverflow.m4: Remove file.
120879         * modules/EOVERFLOW-tests: Remove file.
120880         * tests/test-EOVERFLOW.c: Remove file.
120881         * modules/fprintf-posix (Depends-on): Replace EOVERFLOW with errno.
120882         * modules/ftell (Depends-on): Likewise.
120883         * modules/getdelim (Depends-on): Likewise.
120884         * modules/getugroups (Depends-on): Likewise.
120885         * modules/poll (Depends-on): Likewise.
120886         * modules/snprintf (Depends-on): Likewise.
120887         * modules/sprintf-posix (Depends-on): Likewise.
120888         * modules/vasnprintf (Depends-on): Likewise.
120889         * modules/vasprintf (Depends-on): Likewise.
120890         * modules/vfprintf-posix (Depends-on): Likewise.
120891         * modules/vsnprintf (Depends-on): Likewise.
120892         * modules/vsprintf-posix (Depends-on): Likewise.
120893         * modules/xvasprintf (Depends-on): Likewise.
120894         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
120895         * modules/unistdio/u8-vasprintf (Depends-on): Likewise.
120896         * modules/unistdio/u8-vsnprintf (Depends-on): Likewise.
120897         * modules/unistdio/u8-vsprintf (Depends-on): Likewise.
120898         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
120899         * modules/unistdio/u8-u8-vasprintf (Depends-on): Likewise.
120900         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Likewise.
120901         * modules/unistdio/u8-u8-vsprintf (Depends-on): Likewise.
120902         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
120903         * modules/unistdio/u16-u16-vasprintf (Depends-on): Likewise.
120904         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Likewise.
120905         * modules/unistdio/u16-u16-vsprintf (Depends-on): Likewise.
120906         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
120907         * modules/unistdio/u16-vasprintf (Depends-on): Likewise.
120908         * modules/unistdio/u16-vsnprintf (Depends-on): Likewise.
120909         * modules/unistdio/u16-vsprintf (Depends-on): Likewise.
120910         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
120911         * modules/unistdio/u32-vasprintf (Depends-on): Likewise.
120912         * modules/unistdio/u32-vsnprintf (Depends-on): Likewise.
120913         * modules/unistdio/u32-vsprintf (Depends-on): Likewise.
120914         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
120915         * modules/unistdio/u32-u32-vasprintf (Depends-on): Likewise.
120916         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Likewise.
120917         * modules/unistdio/u32-u32-vsprintf (Depends-on): Likewise.
120918         * modules/unistdio/ulc-fprintf (Depends-on): Likewise.
120919         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
120920         * modules/unistdio/ulc-vasprintf (Depends-on): Likewise.
120921         * modules/unistdio/ulc-vfprintf (Depends-on): Likewise.
120922         * modules/unistdio/ulc-vsnprintf (Depends-on): Likewise.
120923         * modules/unistdio/ulc-vsprintf (Depends-on): Likewise.
120924         * MODULES.html.sh: Remove EOVERFLOW.
120925         * NEWS: Mention the change.
120927 2008-09-13  Bruno Haible  <bruno@clisp.org>
120929         * modules/errno-tests: New file.
120930         * tests/test-errno.c: New file, incorporating tests/test-EOVERFLOW.c.
120932         * lib/errno.in.h: New file.
120933         * m4/errno_h.m4: New file, borrowing from m4/eoverflow.m4.
120934         * modules/errno: New file.
120935         * doc/posix-headers/errno.texi: Update documentation.
120936         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add errno.
120938 2008-09-13  Bruno Haible  <bruno@clisp.org>
120940         * tests/test-poll.c: Use #if for native Windows, rather than testing
120941         __MSVCRT__.
120943 2008-09-13  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
120944             Bruno Haible  <bruno@clisp.org>
120946         * lib/glob.c: Don't include <pwd.h> on native Windows.
120947         (WINDOWS32): New macro.
120948         (glob) [WINDOW32]: Provide a reasonable replacement for getenv("HOME").
120950 2008-09-13  Bruno Haible  <bruno@clisp.org>
120952         * lib/glthread/cond.h [USE_SOLARIS_THREADS]
120953         (ETIMEDOUT): Remove macro.
120954         (glthread_cond_timedwait_multithreaded): New declaration.
120955         (glthread_cond_timedwait): Use it.
120956         * lib/glthread/cond.c [USE_SOLARIS_THREADS]
120957         (glthread_cond_timedwait_multithreaded): New function.
120959 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
120961         * modules/poll-tests: Do not check for io.h.
120962         * tests/test-poll.c: Check for __MSVCRT__ instead.
120964 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
120966         * lib/sys_socket.in.h (EINPROGRESS): Define for Winsock case.
120967         * modules/poll-tests: Add inet_pton, stdbool, sockets.
120968         * tests/test-poll.c: Use them.  Use _pipe on Windows.
120970 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
120972         * modules/poll-tests: New.
120973         * tests/test-poll.c: New.
120975 2008-09-12  Eric Blake  <ebb9@byu.net>
120977         frexp: test for NetBSD failure on -0.0
120978         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Enhance test, since some, but
120979         not all, bugs from NetBSD 3.0 have been fixed.
120980         * doc/posix-functions/frexp.texi (frexp): Document bug.
120981         Reported by Thomas Klausner.
120983         signbit: work around bug of HP-UX 10.20 cc with -0.0 literal
120984         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Rewrite test to avoid
120985         literal -0.0.
120986         Reported by Jonathan C. Patschke <jp@centtech.com>.
120988 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
120990         * lib/glthread/cond.h: Use dummy implementation also if
120991         USE_WIN32_THREADS.
120993 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
120995         * modules/fnmatch-posix (License): Change to LGPLv2+.
120996         * modules/fnmatch-gnu (License): Likewise.
120998 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121000         * lib/poll.c (poll): Fix polling unconnected server sockets on WIN32.
121002 2008-09-11  Jim Meyering  <meyering@redhat.com>
121004         * users.txt: Add gtk-vnc.
121006 2008-09-08  Simon Josefsson  <simon@josefsson.org>
121008         * tests/test-bitrotate.c: Test 8/16-bit rotates with 0 and maximum
121009         rotate amounts.
121011         * lib/bitrotate.h: Doc fix, mention that N can be wider than minimally
121012         required for 16-bit and 8-bit rotates.
121013         * lib/bitrotate.h (rotl64, rotr64, rotl32, rotl32, rotl16, rotr16,
121014         rotl8, rotr8): Use UINT64_MAX, UINT32_MAX, UINT16_MAX, and
121015         UINT8_MAX instead of hard-coded constants.
121016         Suggested by Paul Eggert.
121018 2008-09-07  Bruno Haible  <bruno@clisp.org>
121020         * tests/test-striconveh.c (main): Check behaviour when converting from
121021         UTF-7.
121023         Make striconveh work better with stateful encodings.
121024         * lib/striconveh.c (iconv_carefully, iconv_carefully_1): Don't assume
121025         that iconv does not increment the inptr when returning -1/EINVAL.
121027 2008-09-07  Bruno Haible  <bruno@clisp.org>
121029         * build-aux/config.rpath: Update according to libtool-2.2.6.
121030         * build-aux/config.libpath: Likewise.
121032 2008-09-06  Bruno Haible  <bruno@clisp.org>
121034         * lib/freadahead.c (freadahead): Add conditional for SLOW_BUT_NO_HACKS.
121035         * lib/freadptr.c (freadptr): Likewise.
121036         * lib/freadseek.c (freadptrinc): Likewise.
121037         Reported by Simon Josefsson.
121039 2008-09-06  Bruno Haible  <bruno@clisp.org>
121041         * modules/freadptr (License): Change to LGPLv2+.
121042         * modules/freadseek (License): Likewise.
121043         Suggested by Eric Blake.
121045         * modules/memchr2 (License): Change to LGPLv2+.
121046         Approved by Eric Blake.
121048 2008-09-04  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
121049             Bruno Haible  <bruno@clisp.org>
121051         Make gnulib-tool work with native 'sed' on AIX.
121052         * gnulib-tool (sed_noop): New variable.
121053         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am, func_import,
121054         func_add_or_update, func_create_testdir): Use it to initialize sed
121055         script variables.
121056         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
121058 2008-09-04  Albert Chin  <bug-gnulib@mlists.thewrittenword.com>
121059             Bruno Haible  <bruno@clisp.org>
121061         * m4/include_next.m4 (gl_INCLUDE_NEXT): Add check whether #include_next
121062         also works after #include directives.
121064 2008-09-04  Ondřej Vašík  <ovasik@redhat.com>
121066         getdate.y: reject an out-of-range timezone value
121067         * lib/getdate.y (time_zone_hhmm): Reject any TZ offset that is outside
121068         the range [-24...+24].  When specified with only one or two digits,
121069         * tests/test-getdate.c: Tests for the fix.
121070         * doc/getdate.texi: Document this change.
121072 2008-09-03  Bruno Haible  <bruno@clisp.org>
121074         * doc/glibc-functions/strverscmp.texi: Mention the strverscmp module.
121076 2008-09-02  Simon Josefsson  <simon@josefsson.org>
121078         * lib/bitrotate.h (rotl64, rotr64): Add.  Suggested by Bruce Korb
121079         <bruce.korb@gmail.com> with ideas from Ben Pfaff
121080         <blp@cs.stanford.edu>, Bruno Haible <bruno@clisp.org> and Eric
121081         Blake <ebb9@byu.net>.
121083         * tests/test-bitrotate.c: Add more test vectors.
121085 2008-09-02  Eric Blake  <ebb9@byu.net>
121087         vasnprintf-posix: handle large precision via %.*d
121088         * lib/vasnprintf.c (VASNPRINTF): Don't pass precision to snprintf
121089         when handling it ourselves.
121090         * tests/test-vasnprintf-posix.c (test_function): Add test.
121091         * tests/test-snprintf-posix.h (test_function): Likewise.
121092         * tests/test-sprintf-posix.h (test_function): Likewise.
121093         * tests/test-vasprintf-posix.c (test_function): Likewise.
121094         Reported by Alain Guibert.
121096 2008-09-01  Eric Blake  <ebb9@byu.net>
121098         c-stack: make configure-time check more robust
121099         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check for
121100         successful sigaction call.
121101         Reported by Tom G. Christensen.
121103 2008-09-01  Bruno Haible  <bruno@clisp.org>
121105         New module 'findprog-lgpl'.
121106         * modules/findprog-lgpl: New file.
121107         * lib/findprog-lgpl.c: New file.
121108         * lib/findprog.c: Compile nothing in findprog.c if findprog-lgpl.c is
121109         also compiled. Consider the possibly defined symbol IN_FINDPROG_LGPL
121110         to decide whether to use strdup or xstrdup, concatenated_filename or
121111         xconcatenated_filename.
121113 2008-09-01  Bruno Haible  <bruno@clisp.org>
121115         Split module 'concat-filename' into 'concat-filename' (LGPL) and
121116         'xconcat-filename' (GPL).
121117         * modules/concat-filename (Depends-on): Add malloc-posix, remove xalloc.
121118         (License): Change to LGPLv2+.
121119         * modules/xconcat-filename: New file.
121120         * lib/concat-filename.h (concatenated_filename): Change specification.
121121         (xconcatenated_filename): New declaration.
121122         * lib/concat-filename.c: Include errno.h, stdlib.h, not xalloc.h.
121123         (concatenated_filename): Use malloc instead of xalloc. Handle out-of-
121124         memory situations.
121125         * lib/xconcat-filename.c: New file.
121126         * NEWS: Mention the change.
121127         * lib/findprog.c: Include concat-filename.h, not filename.h.
121128         (find_in_path): Use xconcatenated_filename instead of
121129         concatenated_filename.
121130         * lib/javacomp.c: Include concat-filename.h, not filename.h.
121131         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
121132         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
121133         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
121134         is_oldgcj_14_13_usable, is_javac_usable): Use xconcatenated_filename
121135         instead of concatenated_filename.
121136         * lib/javaexec.c: Include concat-filename.h, not filename.h.
121137         (execute_java_class): Use xconcatenated_filename instead of
121138         concatenated_filename.
121139         * modules/findprog (Depends-on): Add xconcat-filename, remove filename.
121140         * modules/javacomp (Depends-on): Likewise.
121141         * modules/javaexec (Depends-on): Likewise.
121143 2008-09-01  Bruno Haible  <bruno@clisp.org>
121145         Split module 'filename' into 'filename' and 'concat-filename'.
121146         * modules/filename: Keep only lib/filename.h.
121147         (License): Change to LGPLv2+.
121148         * modules/concat-filename: New file, extracted from modules/filename.
121149         * lib/filename.h (concatenated_filename): Remove declaration.
121150         * lib/concat-filename.h: New file, extracted from lib/filename.h.
121151         * lib/concat-filename.c: Include concat-filename.h.
121152         * NEWS: Mention the change.
121154 2008-09-01  Simon Josefsson  <simon@josefsson.org>
121156         * lib/bitrotate.h (rotl8, rotr8): Add.
121158         * modules/bitrotate (configure.ac): Need
121159         AC_REQUIRE([AC_C_INLINE]).
121160         (Description): Mention stdint.h.  Reported by Bruno Haible
121161         <bruno@clisp.org>.
121163         * lib/bitrotate.h (rotr16, rotl16): Fix mask value.  Reported by
121164         Paolo Bonzini <bonzini@gnu.org>.
121166 2008-08-31  Bruno Haible  <bruno@clisp.org>
121168         Assume Solaris specific bi-arch conventions on Solaris systems.
121169         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On Solaris in 64-bit
121170         mode, set acl_libdirstem to lib/64. Also set acl_libdirstem2.
121171         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): If acl_libdirstem does not
121172         work, try acl_libdirstem2 as fallback. Otherwise treat acl_libdirstem2
121173         like acl_libdirstem.
121174         (AC_LIB_LINKFLAGS_FROM_LIBS): Treat acl_libdirstem2 like
121175         acl_libdirstem.
121176         * NEWS: Mention the change.
121177         Reported by Ben Taylor <bentaylor.solx86@gmail.com>.
121179 2008-08-31  Jim Meyering  <meyering@redhat.com>
121181         * lib/strftime.h: Add comments describing the two added arguments.
121183         remove duplicate #include directives
121184         * lib/chdir-long.c [TEST_CHDIR]: Remove duplicate #include <stdio.h>.
121185         * lib/putenv.c: Remove duplicate #include <stdlib.h>.
121187 2008-08-31  Bruno Haible  <bruno@clisp.org>
121189         New module 'sigpipe-die'.
121190         * modules/sigpipe-die: New file.
121191         * lib/sigpipe-die.h: New file.
121192         * lib/sigpipe-die.c: New file.
121193         * MODULES.html.sh (Signal handling): Add sigpipe-die.
121195 2008-08-31  Bruno Haible  <bruno@clisp.org>
121197         Don't override previously installed signal handlers.
121198         * lib/fatal-signal.c (saved_sigactions): New variable.
121199         (uninstall_handlers): Reset the signal to the saved handler, not
121200         to SIG_DFL (except when ignored).
121201         (install_handlers): Save the previous handlers.
121203 2008-08-30  Bruno Haible  <bruno@clisp.org>
121205         * gnulib-tool (func_reset_sigpipe): New function.
121206         (func_get_automake_snippet, func_modules_transitive_closure,
121207         func_import): Invoke it before a join command that reads from stdin,
121208         to avoid "echo: write error: Broken pipe" error messages on stderr.
121209         Reported by Sam Steingold <sds@gnu.org>.
121211 2008-08-30  Bruno Haible  <bruno@clisp.org>
121213         * m4/fopen.m4 (gl_FUNC_FOPEN): Test against bug with trailing slash.
121214         Code copied from m4/open.m4.
121215         * lib/fopen.c (rpl_fopen): Return NULL if the mode specifies write
121216         access and the filename ends in a slash. Code copied from lib/open.c.
121217         * doc/posix-functions/fopen.texi: Document bug with trailing slash.
121218         * tests/test-fopen.c (main): Check against bug with trailing slash.
121220 2008-08-29  Bruno Haible  <bruno@clisp.org>
121222         Avoid some "gcc -pedantic" warnings.
121223         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also PRAGMA_SYSTEM_HEADER.
121224         * lib/arpa_inet.in.h: Use PRAGMA_SYSTEM_HEADER.
121225         * lib/dirent.in.h: Likewise.
121226         * lib/fcntl.in.h: Likewise.
121227         * lib/float.in.h: Likewise.
121228         * lib/iconv.in.h: Likewise.
121229         * lib/inttypes.in.h: Likewise.
121230         * lib/locale.in.h: Likewise.
121231         * lib/math.in.h: Likewise.
121232         * lib/netinet_in.in.h: Likewise.
121233         * lib/search.in.h: Likewise.
121234         * lib/signal.in.h: Likewise.
121235         * lib/stdarg.in.h: Likewise.
121236         * lib/stdint.in.h: Likewise.
121237         * lib/stdio.in.h: Likewise.
121238         * lib/stdlib.in.h: Likewise.
121239         * lib/string.in.h: Likewise.
121240         * lib/strings.in.h: Likewise.
121241         * lib/sys_select.in.h: Likewise.
121242         * lib/sys_socket.in.h: Likewise.
121243         * lib/sys_stat.in.h: Likewise.
121244         * lib/sys_time.in.h: Likewise.
121245         * lib/sysexits.in.h: Likewise.
121246         * lib/time.in.h: Likewise.
121247         * lib/unistd.in.h: Likewise.
121248         * lib/wchar.in.h: Likewise.
121249         * lib/wctype.in.h: Likewise.
121250         * modules/arpa_inet (Makefile.am): Also substitute PRAGMA_SYSTEM_HEADER.
121251         * modules/fchdir (Makefile.am): Likewise.
121252         * modules/fcntl (Makefile.am): Likewise.
121253         * modules/float (Makefile.am): Likewise.
121254         * modules/iconv_open (Makefile.am): Likewise.
121255         * modules/inttypes (Makefile.am): Likewise.
121256         * modules/locale (Makefile.am): Likewise.
121257         * modules/math (Makefile.am): Likewise.
121258         * modules/netinet_in (Makefile.am): Likewise.
121259         * modules/search (Makefile.am): Likewise.
121260         * modules/signal (Makefile.am): Likewise.
121261         * modules/stdarg (Makefile.am): Likewise.
121262         * modules/stdint (Makefile.am): Likewise.
121263         * modules/stdio (Makefile.am): Likewise.
121264         * modules/stdlib (Makefile.am): Likewise.
121265         * modules/string (Makefile.am): Likewise.
121266         * modules/strings (Makefile.am): Likewise.
121267         * modules/sys_select (Makefile.am): Likewise.
121268         * modules/sys_socket (Makefile.am): Likewise.
121269         * modules/sys_stat (Makefile.am): Likewise.
121270         * modules/sys_time (Makefile.am): Likewise.
121271         * modules/sysexits (Makefile.am): Likewise.
121272         * modules/time (Makefile.am): Likewise.
121273         * modules/unistd (Makefile.am): Likewise.
121274         * modules/wchar (Makefile.am): Likewise.
121275         * modules/wctype (Makefile.am): Likewise.
121276         Reported by Reuben Thomas <rrt@sc3d.org>.
121278 2008-08-29  Bruno Haible  <bruno@clisp.org>
121280         * m4/include_next.m4 (gl_INCLUDE_NEXT): Don't define HAVE_INCLUDE_NEXT
121281         any more.
121283 2008-08-29  Simon Josefsson  <simon@josefsson.org>
121285         * MODULES.html.sh (Misc): Add bitrotate.
121287         * modules/bitrotate: New file.
121289         * lib/bitrotate.h: New file.
121291         * modules/bitrotate-tests: New file.
121293         * tests/test-bitrotate.c: New file.
121295         * modules/crypto/gc-arctwo, modules/crypto/arctwo: Add dependency
121296         on the bitrotate module.
121298         * lib/arctwo.c: Use new bitrotate module.
121300 2008-08-29  Jim Meyering  <meyering@redhat.com>
121302         bootstrap: merge changes from coreutils
121303         * build-aux/bootstrap (cp_mark_as_generated): Preserve perms
121304         of copied files.  Remove a kludge, now that this is fixed.
121305         * build-aux/bootstrap: Fix unportable expr usage. (by Ralf Wildenhues)
121306         * build-aux/bootstrap: Remove $bt and $bt2 also when not using gettext.
121307         * build-aux/bootstrap: Remove coreutils-specific SUBDIRS-related code.
121309 2008-08-29  Bruno Haible  <bruno@clisp.org>
121311         * MODULES.html.sh: Remove --cvs-urls option.
121313 2008-08-28  Jose E. Marchesi  <jemarch@gnu.org>  (tiny change)
121315         maint.mk: adjust to file name change
121316         * top/maint.mk: s/Makefile.cfg/cfg.mk/.
121318 2008-08-28  Jim Meyering  <meyering@redhat.com>
121320         * modules/getndelim2 (License): Relicense to LGPLv2+.
121321         Approved by Richard Stallman for the version of 1995, and by
121322         Paul Eggert, Bruno Haible, Eric Blake for their contributions.
121324 2008-08-27  Paolo Bonzini  <bonzini@gnu.org>
121326         * lib/getdelim.c (flockfile, funlockfile): Make all of them
121327         dummy if one is not available.  Do not touch them if
121328         USE_UNLOCKED_IO, instead letting unlocked-io.h do that.
121329         (getc_maybe_unlocked): New.
121330         * m4/getdelim.m4 (gl_PREREQ_GETDELIM): Check for getc_unlocked.
121332 2008-08-26  Eric Blake  <ebb9@byu.net>
121334         doc/INSTALL: resync from autoconf
121335         * doc/Makefile (INSTALL, INSTALL.ISO, INSTALL.UTF-8): Simplify.
121336         (INSTALL_PRELUDE): Delete; this is done more efficiently by
121337         moving...
121338         * install.texi [!autoconf]: ...here.  Resync from autoconf.
121339         * INSTALL: Regenerate.
121340         * INSTALL.ISO: New file.
121341         * INSTALL.UTF-8: Likewise.
121343 2008-08-26  Jim Meyering  <meyering@redhat.com>
121345         GNUmakefile: cfg.mk definitions override default autoreconf-rerun policy
121346         * top/GNUmakefile (_is-dist-target, _is-install-target): Make
121347         these definitions conditional, so that they may be overridden, too.
121349 2008-08-26  Bruno Haible  <bruno@clisp.org>
121351         Generate INSTALL file variants with prettier quotes.
121352         * doc/Makefile (INSTALL_PRELUDE): New macro.
121353         (INSTALL): Use it.
121354         (INSTALL.ISO, INSTALL.UTF-8): New rules.
121356 2008-08-26  Bruno Haible  <bruno@clisp.org>
121358         Run makeinfo in an English locale.
121359         * doc/Makefile (MAKEINFO): New variable.
121361 2008-08-26  Bruno Haible  <bruno@clisp.org>
121363         * doc/Makefile (INSTALL): Use --no-validate instead of --no-warn.
121364         Suggested by Eric Blake.
121366 2008-08-25  Bruno Haible  <bruno@clisp.org>
121368         * doc/Makefile (INSTALL): Generate with @firstparagraphindent set.
121370 2008-08-25  Eric Blake  <ebb9@byu.net>
121372         c-stack: test that stack overflow can be caught
121373         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Also check
121374         that platform allows handling stack overflow; at least OS/2 EMX
121375         has sigaltstack, but crashes before transferring control to
121376         handler on stack overflow.
121377         * lib/c-stack.c [HAVE_SIGALTSTACK]: Adjust conditions to also
121378         check for HAVE_STACK_OVERFLOW_HANDLING.
121379         Reported by Elbert Pol.
121381 2008-08-25  Bruno Haible  <bruno@clisp.org>
121383         * doc/posix-functions/strftime.texi: Fix description of strftime
121384         module.
121386 2008-08-24  Bruno Haible  <bruno@clisp.org>
121388         * tests/uniwidth/test-uc_width2.c: New file.
121389         * tests/uniwidth/test-uc_width2.sh: New file.
121390         * modules/uniwidth/width-tests (Files): Add the new files.
121391         (TESTS): Add uniwidth/test-uc_width2.sh.
121392         (TESTS_ENVIRONMENT): New variable.
121393         (check_PROGRAMS): Add test-uc_width2.
121394         (test_uc_width2_SOURCES): New variable.
121396         Fix uc_width(0x00AB) bug, introduced on 2007-07-08.
121397         * lib/uniwidth/width.c (nonspacing_table_data): Set bit for 0x00AD,
121398         not 0x00AB.
121399         Reported by Alexander V. Lukyanov <lav@netis.ru>.
121401 2008-08-22  Eric Blake  <ebb9@byu.net>
121403         test-lock, test-tls: mention why a test is skipped
121404         * tests/test-lock.c (main) [!USE_*_THREADS]: Print why test is
121405         skipped.
121406         * tests/test-tls.c (main) [!USE_*_THREADS]: Likewise.
121408         count-one-bits: relax license
121409         * modules/count-one-bits (License): Relicense to LGPLv2+.
121410         Suggested by Ludovic Courtès, approved by Ben Pfaff.
121412 2008-08-22  Andreas Schwab  <schwab@suse.de>
121414         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX):
121415         Remove spurious space in assignment.
121417 2008-08-21  Simon Josefsson  <simon@josefsson.org>
121419         * m4/autobuild.m4: Use TZ=UTC0 instead of TZ=UTC.  Reported by
121420         Paul Eggert <eggert@CS.UCLA.EDU>.
121422 2008-08-20  Paolo Bonzini  <bonzini@gnu.org>
121424         * modules/gettext: Add m4/threadlib.m4.
121426 2008-08-19  Eric Blake  <ebb9@byu.net>
121428         test-c-stack: fix compilation failure on FreeBSD 5.0
121429         * tests/test-c-stack.c [HAVE_SETRLIMIT]: Include prerequisite
121430         headers before <sys/resource.h>.
121431         * doc/posix-headers/sys_resource.texi (sys/resource.h): Document
121432         the bug.
121433         Reported by Nelson H. F. Beebe.
121435         strverscmp: migrate from "strverscmp.h" to <string.h>
121436         * modules/string (Makefile.am): Add new hooks.
121437         * modules/strverscmp (Files): Remove strverscmp.h.
121438         (Depends-on): Add string.
121439         (configure.ac): Add indicator.
121440         (Include): Mention new header.
121441         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Provide new
121442         defaults.
121443         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Inform string module of
121444         results.
121445         * lib/strverscmp.h: Delete.
121446         * lib/string.in.h (strverscmp): Provide declaration, when needed.
121447         * tests/test-strverscmp.c (includes): Adjust client.
121448         * lib/check-version.c (includes): Likewise.
121449         * NEWS: Document the change.
121451         strverscmp: add unit test
121452         * modules/strverscmp-tests: New file.
121453         * tests/test-strverscmp.c: Likewise.
121455 2008-08-19  Simon Josefsson  <simon@josefsson.org>
121457         * lib/gc-gnulib.c: Indentation cleanup.  Add some comments
121458         regarding Windows crypto stuff, from Mono.
121460 2008-08-19  Adam Strzelecki  <ono@java.pl>  (tiny change)
121462         * lib/gc-gnulib.c: Use CRYPT_VERIFY_CONTEXT.  Try to use Intel CSP
121463         if present, for intel RND.  Return error on failures.
121465 2008-08-18  Ben Pfaff  <blp@gnu.org>
121467         gitlog-to-changelog: give better diagnostic for failed pipe-open
121468         * build-aux/gitlog-to-changelog: Improve error message: suggest
121469         that the version of Git may be too old.
121471 2008-08-18  Simon Josefsson  <simon@josefsson.org>
121473         * m4/autobuild.m4: Use TZ=UTC to avoid time zone complexity.  Use
121474         ISO 8601 format.  Suggested by Greg Troxel <gdt@ir.bbn.com>.
121476 2008-08-18  Bruno Haible  <bruno@clisp.org>
121478         * lib/glthread/thread.h [USE_SOLARIS_THREADS]: Use thread_in_use(), not
121479         pthread_in_use().
121481 2008-08-18  Bruno Haible  <bruno@clisp.org>
121483         * lib/glthread/threadlib.c: Include <pthread.h>.
121485 2008-08-18  Bruno Haible  <bruno@clisp.org>
121487         * lib/glthread/lock.h [USE_SOLARIS_THREADS]: Fix
121488         glthread_recursive_lock_* macros.
121489         * lib/glthread/lock.c (glthread_recursive_lock_destroy_multithreaded):
121490         Fix syntax error.
121492 2008-08-18  Bruno Haible  <bruno@clisp.org>
121494         * lib/glthread/thread.c: Avoid forcing a context switch right after
121495         thread creation.
121497 2008-08-17  Bruno Haible  <bruno@clisp.org>
121499         * lib/glthread/thread.c: New file, based on code from tests/test-lock.c.
121500         * lib/glthread/thread.h: Provide Win32 specific implementation.
121501         * modules/thread (Files): Add lib/glthread/thread.c.
121502         (Depends-on): Add lock.
121503         (Makefile.am): Add glthread/thread.c to lib_SOURCES.
121505 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121507         New module 'yield'.
121508         * modules/yield: New file.
121509         * lib/glthread/yield.h: New file.
121510         * m4/yield.m4: New file.
121511         * MODULES.html.sh (Multithreading): Add yield.
121513 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121515         New module 'thread'.
121516         * modules/thread: New file.
121517         * lib/glthread/thread.h: New file.
121518         * m4/thread.m4: New file.
121519         * MODULES.html.sh (Multithreading): Add thread.
121521 2008-08-17  Bruno Haible  <bruno@clisp.org>
121523         * lib/glthread/lock.h: Include <stdlib.h> always.
121524         * lib/glthread/tls.h: Likewise.
121525         * lib/glthread/cond.h: Likewise.
121527 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
121529         New module 'cond'.
121530         * modules/cond: New file.
121531         * lib/glthread/cond.h: New file.
121532         * lib/glthread/cond.c: New file.
121533         * m4/cond.m4: New file.
121534         * MODULES.html.sh (Multithreading): Add cond.
121536 2008-08-16  Eric Blake  <ebb9@byu.net>
121538         c-stack: fix regression on Irix 5.3 from 2008-06-21
121539         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Move check for
121540         sa_sigaction...
121541         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): ...here.
121542         (gl_PREREQ_SIGACTION): Depend on sig-handler.h prereq's.
121543         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Set the default.
121544         * modules/signal (Makefile.am): Use the value.
121545         * lib/signal.in.h (sa_sigaction) [HAVE_SIGACTION
121546         && !HAVE_STRUCT_SIGACTION_SA_SIGACTION]: Define.
121547         * doc/posix-headers/signal.texi (signal.h): Document this
121548         portability issue.
121549         * doc/posix-functions/sigaction.texi (sigaction): Likewise.
121550         Reported by Tom G. Christensen.
121552 2008-08-17  Bruno Haible  <bruno@clisp.org>
121554         New module 'threadlib'.
121555         * modules/threadlib: New file.
121556         * lib/glthread/threadlib.c: New file, extracted from
121557         lib/glthread/lock.c.
121558         * lib/glthread/lock.c (dummy_thread_func, glthread_in_use): Remove
121559         functions.
121560         * m4/threadlib.m4: New file, from m4/lock.m4, renaming gl_LOCK to
121561         gl_THREADLIB and gl_LOCK_EARLY to gl_THREADLIB_EARLY.
121562         * m4/lock.m4 (gl_LOCK_EARLY, gl_LOCK_EARLY_BODY, gl_LOCK_BODY): Remove
121563         macros.
121564         (gl_LOCK): Just require gl_THREADLIB and perform checks for lock.h.
121565         (gl_DISABLE_THREADS): Remove macro.
121566         * modules/lock (Files): Remove build-aux/config.rpath.
121567         (Depends-on): Remove havelib. Add threadlib.
121568         (configure.ac-early): Remove section.
121569         * m4/tls.m4 (gl_TLS): Require gl_THREADLIB instead of gl_LOCK.
121570         * modules/tls (Depends-on): Remove lock. Add threadlib.
121571         (Link): New section, copied from threadlib.
121572         * MODULES.html.sh (Multithreading): Add threadlib.
121574 2008-08-14  Bruno Haible  <bruno@clisp.org>
121576         * lib/glthread/lock.h (glthread_lock_lock, glthread_lock_unlock,
121577         glthread_lock_destroy, glthread_rwlock_rdlock, glthread_rwlock_wrlock,
121578         glthread_rwlock_unlock, glthread_rwlock_destroy,
121579         glthread_recursive_lock_lock, glthread_recursive_lock_unlock,
121580         glthread_recursive_lock_destroy): Define as macros always.
121581         * lib/glthread/lock.c (glthread_lock_lock_func): Renamed from
121582         glthread_lock_lock.
121583         (glthread_lock_unlock_func): Renamed from glthread_lock_unlock.
121584         (glthread_lock_destroy_func): Renamed from glthread_lock_destroy.
121585         (glthread_rwlock_rdlock_func): Renamed from glthread_rwlock_rdlock.
121586         (glthread_rwlock_wrlock_func): Renamed from glthread_rwlock_wrlock.
121587         (glthread_rwlock_unlock_func): Renamed from glthread_rwlock_unlock.
121588         (glthread_rwlock_destroy_func): Renamed from glthread_rwlock_destroy.
121589         (glthread_recursive_lock_lock_func): Renamed from
121590         glthread_recursive_lock_lock.
121591         (glthread_recursive_lock_unlock_func): Renamed from
121592         glthread_recursive_lock_unlock.
121593         (glthread_recursive_lock_destroy_func): Renamed from
121594         glthread_recursive_lock_destroy.
121596 2008-08-14  Bruno Haible  <bruno@clisp.org>
121598         * lib/glthread/lock.h: Renamed from lib/lock.h.
121599         * lib/glthread/lock.c: Renamed from lib/lock.c. Update includes.
121600         * lib/glthread/tls.h: Renamed from lib/tls.h.
121601         * lib/glthread/tls.c: Renamed from lib/tls.c. Update includes.
121602         * lib/fstrcmp.c: Update includes.
121603         * lib/strsignal.c: Update includes.
121604         * modules/lock (Files, Makefile.am): Update.
121605         (Include): Change to "glthread/lock.h".
121606         * modules/tls (Files, Makefile.am): Update.
121607         (Include): Change to "glthread/tls.h".
121608         * tests/test-lock.c: Update includes.
121609         * tests/test-tls.c: Update includes.
121610         * NEWS: Mention the renamed header files.
121612 2008-08-11  Jim Meyering  <meyering@redhat.com>
121614         * lib/fts_.h: Fix grammar (insert a missing "is") in a comment.
121616 2008-08-11  Eric Blake  <ebb9@byu.net>
121618         test-c-stack: avoid C99-ism
121619         * tests/test-c-stack.c (main): Fix whitespace, move declaration
121620         before statement.
121621         Reported by Alain Guibert.
121623 2008-08-10  Jim Meyering  <meyering@redhat.com>
121625         ensure that return value of uinttostr et al are not ignored
121626         * lib/inttostr.h (__GNUC_PREREQ): Define.
121627         (__attribute_warn_unused_result__): Define.
121628         (offtostr, imaxtostr, umaxtostr, uinttostr): Apply the attribute.
121630 2008-08-07  Paolo Bonzini  <bonzini@gnu.org>
121632         * lib/lock.c (glthread_recursive_lock_init_multithreaded)
121633         [!PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Fix typo.
121635 2008-08-07  Jim Meyering  <meyering@redhat.com>
121637         * m4/inet_pton.m4: Fix typo in comment: s/inet_ntop/inet_pton/.
121639         * modules/mkstemp (License): Relicense under LGPLv2+.
121640         * modules/tempname (License): Likewise.
121642 2008-08-06  Bruno Haible  <bruno@clisp.org>
121644         * lib/poll.c (poll): Further micro-optimization.
121646 2008-08-06  Jim Meyering  <meyering@redhat.com>
121648         inet_pton.c: use locale-independent tolower
121649         * lib/inet_pton.c: Include <c-ctype.h> rather than <ctype.h>.
121650         (inet_pton6): Use c_tolower rather than tolower.
121651         * modules/inet_pton (Depends-on): Add c-ctype.
121653 2008-08-06  Paolo Bonzini  <bonzini@gnu.org>
121655         * lib/poll.c (poll): Avoid division when timeout is 0, cache
121656         _SC_OPEN_MAX, avoid repeated access to errno.  Check for nfd < 0.
121658 2008-08-06  Jim Meyering  <meyering@redhat.com>
121660         * modules/inet_pton (License): Relicense under LGPLv2+.
121662 2008-08-03  Bruno Haible  <bruno@clisp.org>
121664         Additional non-aborting API for lock and tls.
121665         * lib/lock.h: Include <errno.h>.
121666         (glthread_lock_init): New macro/function.
121667         (gl_lock_init): Define as wrapper around glthread_lock_init.
121668         (glthread_lock_lock): New macro/function.
121669         (gl_lock_lock): Define as wrapper around glthread_lock_lock.
121670         (glthread_lock_unlock): New macro/function.
121671         (gl_lock_unlock): Define as wrapper around glthread_lock_unlock.
121672         (glthread_lock_destroy): New macro/function.
121673         (gl_lock_destroy): Define as wrapper around glthread_lock_destroy.
121674         (glthread_rwlock_init): New macro/function.
121675         (gl_rwlock_init): Define as wrapper around glthread_rwlock_init.
121676         (glthread_rwlock_rdlock): New macro/function.
121677         (gl_rwlock_rdlock): Define as wrapper around glthread_rwlock_rdlock.
121678         (glthread_rwlock_wrlock): New macro/function.
121679         (gl_rwlock_wrlock): Define as wrapper around glthread_rwlock_wrlock.
121680         (glthread_rwlock_unlock): New macro/function.
121681         (gl_rwlock_unlock): Define as wrapper around glthread_rwlock_unlock.
121682         (glthread_rwlock_destroy): New macro/function.
121683         (gl_rwlock_destroy): Define as wrapper around glthread_rwlock_destroy.
121684         (glthread_recursive_lock_init): New macro/function.
121685         (gl_recursive_lock_init): Define as wrapper around
121686         glthread_recursive_lock_init.
121687         (glthread_recursive_lock_lock): New macro/function.
121688         (gl_recursive_lock_lock): Define as wrapper around
121689         glthread_recursive_lock_lock.
121690         (glthread_recursive_lock_unlock): New macro/function.
121691         (gl_recursive_lock_unlock): Define as wrapper around
121692         glthread_recursive_lock_unlock.
121693         (glthread_recursive_lock_destroy): New macro/function.
121694         (gl_recursive_lock_destroy): Define as wrapper around
121695         glthread_recursive_lock_destroy.
121696         (glthread_once): New macro/function.
121697         (gl_once): Define as wrapper around glthread_once.
121698         Update function declarations.
121699         * lib/lock.c (glthread_rwlock_init_multithreaded): Renamed from
121700         glthread_rwlock_init. Return error code.
121701         (glthread_rwlock_rdlock_multithreaded): Renamed from
121702         glthread_rwlock_rdlock. Return error code.
121703         (glthread_rwlock_wrlock_multithreaded): Renamed from
121704         glthread_rwlock_wrlock. Return error code.
121705         (glthread_rwlock_unlock_multithreaded): Renamed from
121706         glthread_rwlock_unlock. Return error code.
121707         (glthread_rwlock_destroy_multithreaded): Renamed from
121708         glthread_rwlock_destroy. Return error code.
121709         (glthread_recursive_lock_init_multithreaded): Renamed from
121710         glthread_recursive_lock_init. Return error code.
121711         (glthread_recursive_lock_lock_multithreaded): Renamed from
121712         glthread_recursive_lock_lock. Return error code.
121713         (glthread_recursive_lock_unlock_multithreaded): Renamed from
121714         glthread_recursive_lock_unlock. Return error code.
121715         (glthread_recursive_lock_destroy_multithreaded): Renamed from
121716         glthread_recursive_lock_destroy. Return error code.
121717         (glthread_once_call): Make static.
121718         (glthread_once_multithreaded): Renamed from glthread_once.
121719         * lib/tls.h: Include <errno.h>.
121720         (glthread_tls_key_init): New macro/function.
121721         (gl_tls_key_init): Define as wrapper around glthread_tls_key_init.
121722         (glthread_tls_set): New macro/function.
121723         (gl_tls_set): Define as wrapper around glthread_tls_set.
121724         (glthread_tls_key_destroy): New macro/function.
121725         (gl_tls_key_destroy): Define as wrapper around glthread_tls_key_destroy.
121726         Update function declarations.
121727         * lib/tls.c (glthread_tls_get_multithreaded): Renamed from
121728         glthread_tls_get.
121729         Suggested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
121731 2008-08-04  Eric Blake  <ebb9@byu.net>
121733         gnumakefile: use space, not TAB, outside of targets
121734         * top/GNUmakefile (_dummy): Fix whitespace error in prior edit.
121736 2008-08-02  Jim Meyering  <meyering@redhat.com>
121738         getdate.y: avoid locale-dependent date parsing failure
121739         In Turkish locales, getdate would fail to recognize keywords
121740         containing a lowercase "i".  The solution is not to rely on
121741         locale-sensitive case-conversion.
121742         * lib/getdate.y: Include <c-ctype.h> rather than <ctype.h>.
121743         (lookup_word): Use c_toupper in place of toupper.
121744         (yylex, get_date): Use c_ prefixed variants of isspace and isalpha, too.
121745         Reported by Vefa Bicakci <bicave@superonline.com> in
121746         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/14184>.
121747         * modules/getdate (Depends-on): Add c-ctype.
121749 2008-08-02  Bruno Haible  <bruno@clisp.org>
121751         * gnulib-tool (func_import): When updating or creating a .gitignore
121752         file, prepend each added line with a slash, and ignore leading slashes
121753         from the existing lines.
121754         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
121756 2008-08-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
121758         Portability fix for GNU make 3.79.1.
121759         * top/GNUmakefile: Avoid 'else COND', which older GNU make
121760         versions do not understand.
121762 2008-08-01  Bruno Haible  <bruno@clisp.org>
121764         Work around bug of HP-UX 10.20 cc with -0.0 literal.
121765         * tests/test-isnanf.h (zero): New variable.
121766         (main): Avoid literal -0.0f.
121767         * tests/test-isnand.h (zero): New variable.
121768         (main): Avoid literal -0.0.
121769         * tests/test-isnanl.h (zero): New variable.
121770         (main): Avoid literal -0.0L.
121771         * tests/test-isnan.c (zerof, zerod, zerol): New variables.
121772         (test_float, test_double, test_long_double): Avoid literals -0.0f,
121773         -0.0, -0.0L.
121774         * tests/test-signbit.c (test_signbitf): Avoid literal -0.0f.
121775         (test_signbitd): Avoid literal -0.0.
121776         (test_signbitl): Avoid literal -0.0L.
121777         * tests/test-ceilf1.c (zero): New variable.
121778         (main): Avoid literal -0.0f.
121779         * tests/test-ceill.c (zero): New variable.
121780         (main): Avoid literal -0.0L.
121781         * tests/test-floorf1.c (zero): New variable.
121782         (main): Avoid literal -0.0f.
121783         * tests/test-floorl.c (zero): New variable.
121784         (main): Avoid literal -0.0L.
121785         * tests/test-roundf1.c (zero): New variable.
121786         (main): Avoid literal -0.0f.
121787         * tests/test-round1.c (zero): New variable.
121788         (main): Avoid literal -0.0.
121789         * tests/test-roundl.c (zero): New variable.
121790         (main): Avoid literal -0.0L.
121791         * tests/test-truncf1.c (zero): New variable.
121792         (main): Avoid literal -0.0f.
121793         * tests/test-trunc1.c (zero): New variable.
121794         (main): Avoid literal -0.0.
121795         * tests/test-truncl.c (zero): New variable.
121796         (main): Avoid literal -0.0L.
121797         * tests/test-frexp.c (zero): New variable.
121798         (main): Avoid literal -0.0.
121799         * tests/test-frexpl.c (zero): New variable.
121800         (main): Avoid literal -0.0L.
121801         * tests/test-ldexpl.c (zero): New variable.
121802         (main): Avoid literal -0.0L.
121803         * tests/test-snprintf-posix.h (have_minus_zero): Avoid literal -0.0.
121804         (zerod, zerol): New variables.
121805         (test_function): Avoid literals -0.0, -0.0L.
121806         * tests/test-sprintf-posix.h (have_minus_zero): Avoid literal -0.0.
121807         (zerod, zerol): New variables.
121808         (test_function): Avoid literals -0.0, -0.0L.
121809         * tests/test-vasnprintf-posix.c (have_minus_zero): Avoid literal -0.0.
121810         (zerod, zerol): New variables.
121811         (test_function): Avoid literals -0.0, -0.0L.
121812         * tests/test-vasprintf-posix.c (have_minus_zero): Avoid literal -0.0.
121813         (zerod, zerol): New variables.
121814         (test_function): Avoid literals -0.0, -0.0L.
121815         * tests/test-strtod.c (zero): New variable.
121816         (main): Avoid literal -0.0.
121817         Reported by Jonathan C. Patschke <jp@centtech.com>.
121819 2008-07-31  Jim Meyering  <meyering@redhat.com>
121821         sha256.h: correct definition of SHA224_DIGEST_SIZE
121822         * lib/sha256.h (SHA224_DIGEST_SIZE): Define to 28, not 24.
121823         Reported by Paulie Pena IV <paulie4@gmail.com>.
121824         Define as 224 / 8, rather than as a literal.
121825         (SHA256_DIGEST_SIZE): Define as 256/8 rather than equivalent literal.
121826         * lib/sha512.h (SHA384_DIGEST_SIZE): Likewise, define as equiv: 384/8.
121827         (SHA512_DIGEST_SIZE): Likewise, define as equivalent quotient: 512/8.
121829 2008-07-31  Bruno Haible  <bruno@clisp.org>
121831         * lib/regex_internal.h (BITSET_WORD_BITS): Make first conditional work
121832         on HP-UX 10.20 with "cc -Ae". Fix second conditional.
121833         Reported by Jonathan Patschke <jp@centtech.com>.
121835 2008-07-31  Bruno Haible  <bruno@clisp.org>
121837         * gnulib-tool (func_import): Make change from 2008-06-23 more robust.
121838         Reported by Paolo Bonzini <bonzini@gnu.org>.
121840 2008-07-30  Eric Blake  <ebb9@byu.net>
121842         test-strtod: allow compilation without -lm
121843         * tests/test-strtod.c (main): Avoid link dependence on fabs.
121844         Reported by Dennis Clarke <blastwave@gmail.com>.
121846 2008-07-28  Jim Meyering  <meyering@redhat.com>
121848         bootstrap: work also when there are no .po files in po/
121849         * build-aux/bootstrap (update_po_files): Complete the change
121850         that I began in bc960df8c789c878f1c1c54a28a3c2648dead8d9.
121852 2008-07-27  Jim Meyering  <meyering@redhat.com>
121854         * users.txt: Add zile.
121856 2008-07-26  Ben Pfaff  <blp@gnu.org>
121858         Add missing dependencies on new m4/exponent[fdl].m4 files.
121859         * modules/isnanf-nolibm: Add m4/exponentf.m4.
121860         * modules/isnand-nolibm: Add m4/exponentd.m4.
121861         * modules/isnanl-nolibm: Add m4/exponentl.m4.
121862         * modules/signbit-tests: Use m4/exponent[fdl].m4 instead of
121863         m4/isnan[fdl].m4, because the macros actually used moved.
121864         Reported by Jim Meyering.
121866 2008-07-14  Ben Pfaff  <blp@gnu.org>
121868         Add isinf module.
121869         * lib/isinf.c: New file.
121870         * lib/math.in.h: Define isinf macro if we have decided to replace
121871         it.
121872         * m4/isinf.m4: New file.
121873         * m4/math_h.m4: Initialize and substitute variables for isinf
121874         module.
121875         * modules/isinf: New file.
121876         * modules/isinf-tests: New file.
121877         * modules/math: Add substitutions for new module.
121878         * tests/test-isinf.c: New file.
121879         * doc/posix-functions/isinf.texi: Mention new module.
121880         * MODULES.html.sh: Mention new module.
121882 2008-07-14  Ben Pfaff  <blp@gnu.org>
121884         Factor out some macros for use by additional modules.
121885         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Move into new file
121886         exponentf.m4.
121887         * m4/isnand.m4 (gl_DOUBLE_EXPONENT_LOCATION): Move into new file
121888         exponentd.m4.
121889         * m4/isnanl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Move into new
121890         file exponentl.m4.
121891         * m4/exponentf.m4: New file.
121892         * m4/exponentd.m4: New file.
121893         * m4/exponentl.m4: New file.
121894         * modules/isnanf: Use new file m4/exponentf.m4.
121895         * modules/isnand: Use new file m4/exponentd.m4.
121896         * modules/isnanl: Use new file m4/exponentl.m4.
121898 2008-07-23  Ulrich Drepper  <drepper@redhat.com>
121900         mktime.c: normalize tp->tm_isdst value to -1/0/1.
121901         * lib/mktime.c (__mktime_internal): Normalize tp->tm_isdst value.
121902         Reported by Michael Ringe <Michael.Ringe@gmx.de> in
121903         <http://sourceware.org/bugzilla/show_bug.cgi?id=6723>.
121905         * lib/canonicalize-lgpl.c (__realpath): Avoid buffer overflow after
121906         readlink on platforms without PATH_MAX.
121908 2008-07-21  Eric Blake  <ebb9@byu.net>
121910         Warn, not fail, on stale version.
121911         * top/GNUmakefile (_curr-ver): Tone down previous patch.
121913         Don't allow installation with stale devel version number.
121914         * top/GNUmakefile (_is-install-target): New macro.
121915         (_curr-ver): Forbid installation with stale version number.
121917 2008-07-20  Bruno Haible  <bruno@clisp.org>
121919         * modules/c-stack-tests (Makefile.am): Add LIBSIGSEGV to
121920         TESTS_ENVIRONMENT.
121921         * tests/test-c-stack2.sh: React differently if LIBSIGSEGV is in use.
121923 2008-07-20  Bruno Haible  <bruno@clisp.org>
121925         * lib/c-stack.h (c_stack_action): Add documentation.
121926         * lib/c-stack.c (c_stack_action): Remove incomplete documentation.
121928 2008-07-20  Bruno Haible  <bruno@clisp.org>
121930         * modules/canonicalize-lgpl (License): Relicense under LGPLv2+.
121931         * modules/readlink (License): Likewise.
121933 2008-07-17  Eric Blake  <ebb9@byu.net>
121935         * modules/c-stack (Link): Fix typo.
121937         Make c-stack use libsigsegv, when available.
121938         * modules/c-stack (Depends-on): Add libsigsegv.
121939         * modules/c-stack-tests (Makefile.am): Link with libsigsegv, if
121940         needed.
121941         * lib/c-stack.c (SIGSTKSZ): Define fallback.
121942         (segv_handler, overflow_handler, c_stack_action)
121943         [HAVE_LIBSIGSEGV && !HAVE_XSI_STACK_OVERFLOW_HEURISTIC]: Add new
121944         implementation when libsigsegv is available, but only when using
121945         the library is necessary.
121946         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Add
121947         comment, explaining why XSI check fails on Linux.
121948         (gl_PREREQ_C_STACK): Supply LIBCSTACK, LTLIBCSTACK.
121949         * tests/test-c-stack2.sh: Tweak skip message.
121950         * NEWS: Document new link-time requirements.
121952 2008-07-16  Eric Blake  <ebb9@byu.net>
121954         c-stack: Expose false positives when not using libsigsegv.
121955         * modules/c-stack-tests (Files): Expand test.
121956         * tests/test-c-stack.c (main): Add means to conditionally trigger
121957         non-overflow SIGSEGV.
121958         * tests/test-c-stack2.sh: New file.
121960 2008-07-14  Bruno Haible  <bruno@clisp.org>
121962         * m4/libsigsegv.m4: Remove unneeded AC_PREREQ.
121963         Reported by Eric Blake.
121965 2008-07-14  Sam Steingold  <sds@gnu.org>
121966             Bruno Haible  <bruno@clisp.org>
121968         New module libsigsegv.
121969         * modules/libsigsegv: New file.
121970         * m4/libsigsegv.m4: New file, from GNU clisp sigsegv.m4 with
121971         modifications.
121972         * MODULES.html.sh (Signal handling): New section.
121974 2008-07-14  Bruno Haible  <bruno@clisp.org>
121976         * modules/unictype/ctype-* (Description): Add the word "function".
121977         Improves the resulting doc in MODULES.html.
121979 2008-07-12  Ben Pfaff  <blp@gnu.org>
121981         Add longlong module.
121982         * modules/longlong: New file.
121984 2008-07-12  Bruno Haible  <bruno@clisp.org>
121986         * m4/isnan.m4 (gl_ISNAN): When the replacement is used, set ISNAN_LIBM
121987         to empty.
121989 2008-07-10  Ben Pfaff  <blp@gnu.org>
121991         Add isnan module.
121992         * doc/posix-functions/isnan.texi: Mention new module.
121993         * lib/math.in.h: Define isnan macro if we have decided to replace
121994         it.
121995         * m4/isnan.m4: New file.
121996         * m4/isnanl.m4 (gl_FUNC_ISNANL): Factor out some code into new
121997         macro gl_BUILD_ISNANL so that isnan.m4 can use that functionality
121998         also.
121999         (gl_FUNC_ISNANL_NO_LIBM): Factor out same code, to reduce
122000         redundancy.
122001         * m4/math_h.m4: Initialize and substitute variables for isnan
122002         module.
122003         * modules/isnan: New file.
122004         * modules/isnan-tests: New file.
122005         * modules/math: Add substitutions for new module.
122006         * tests/test-isnan.c: New file.
122007         * MODULES.html.sh: Mention new module.
122009 2008-07-10  Ben Pfaff  <blp@gnu.org>
122011         Add isnanf module.
122012         * lib/isnanf.m4: New file.
122013         * m4/isnanf.m4 (gl_FUNC_ISNANF): New macro.
122014         (gl_HAVE_ISNANF_IN_LIBM): New macro.
122015         (gl_BUILD_ISNANF): New macro used by gl_FUNC_ISNANF,
122016         gl_FUNC_ISNANF_NO_LIBM, and gl_FUNC_ISNAN.
122017         * modules/isnanf: New file.
122018         * modules/isnanf-tests: New file.
122019         * modules/isnanf-nolibm-tests: Add tests/test-isnanf.h to list of
122020         files.
122021         * tests/test-isnanf-nolibm.c: factored most of its contents into
122022         new file tests/test-isnanf.h.
122023         * tests/test-isnanf.h: New file.
122024         * tests/test-isnanf.c: New file.
122025         * MODULES.html.sh: Mention new module.
122026         * doc/glibc-functions/isnanf.texi: Mention new module.
122028 2008-07-10  Ben Pfaff  <blp@gnu.org>
122030         Add isnand module.
122031         * lib/isnand.h: New file.
122032         * m4/isnand.m4 (gl_FUNC_ISNAND): New macro.
122033         (gl_FUNC_ISNAND_NO_LIBM): Split partially into new macro
122034         gl_HAVE_ISNAND_NO_LIBM so that gl_FUNC_ISNAND can use that
122035         functionality also.
122036         (gl_BUILD_ISNAND): New macro used by gl_FUNC_ISNAND,
122037         gl_FUNC_ISNAND_NO_LIBM, and gl_FUNC_ISNAN.
122038         (gl_HAVE_ISNAND_IN_LIBM): New macro.
122039         * modules/isnand: New file.
122040         * modules/isnand-tests: New file.
122041         * modules/isnand-nolibm-tests: Add tests/test-isnand.h to list of
122042         files.
122043         * tests/test-isnand-nolibm.c: factored most of its contents into
122044         new file tests/test-isnand.h.
122045         * tests/test-isnand.h: New file.
122046         * tests/test-isnand.c: New file.
122047         * MODULES.html.sh: Mention new module.
122049 2008-07-10  Ben Pfaff  <blp@gnu.org>
122051         * lib/isnanf.h: Rename lib/isnanf-nolibm.h.
122052         * lib/isnand.h: Rename lib/isnand-nolibm.h.
122053         * tests/test-isnanf.c: Rename tests/test-isnanf-nolibm.c.
122054         * tests/test-isnand.c: Rename tests/test-isnand-nolibm.c.
122055         * modules/isnanf-nolibm: Update references to renamed files.
122056         * modules/isnand-nolibm: Likewise.
122057         * modules/isnanf-nolibm-tests: Likewise.
122058         * modules/isnand-nolibm-tests: Likewise.
122059         * lib/frexp.c: Likewise.
122060         * lib/isfinite.c: Likewise.
122061         * lib/signbitd.c: Likewise.
122062         * lib/signbitf.c: Likewise.
122063         * lib/vasnprintf.c: Likewise.
122064         * tests/test-ceilf1.c: Likewise.
122065         * tests/test-ceilf2.c: Likewise.
122066         * tests/test-floorf1.c: Likewise.
122067         * tests/test-floorf2.c: Likewise.
122068         * tests/test-frexp.c: Likewise.
122069         * tests/test-round1.c: Likewise.
122070         * tests/test-round2.c: Likewise.
122071         * tests/test-roundf1.c: Likewise.
122072         * tests/test-strtod.c: Likewise.
122073         * tests/test-trunc1.c: Likewise.
122074         * tests/test-trunc2.c: Likewise.
122075         * tests/test-truncf1.c: Likewise.
122076         * tests/test-truncf2.c: Likewise.
122077         * NEWS: Mention the renamed header files.
122079 2008-07-11  Jim Meyering  <meyering@redhat.com>
122081         vc-list-files: make the last-resort awk code more portable
122082         * build-aux/vc-list-files: Don't rely on awk's "sub" command.
122083         /bin/awk from OpenSolaris 11's SUNWesu version 2008.03.22.10.56
122084         does not support it.
122086 2008-07-10  Eric Blake  <ebb9@byu.net>
122088         Work with tar's bootstrap.
122089         * gnulib-tool (func_emit_initmacro_end): Use m4_defn in the case
122090         where LIBSOURCES_DIR contains .#bootmp but must not be treated as
122091         an m4 comment.
122093 2008-07-09  Jim Meyering  <meyering@redhat.com>
122095         posix-shell.m4: fix typo that made this test malfunction
122096         * m4/posix-shell.m4: Remove capitalization in variable name.
122098 2008-07-08  Bruno Haible  <bruno@clisp.org>
122100         * m4/onceonly.m4: Update comments.
122101         Reported by Ben Pfaff <blp@cs.stanford.edu>.
122103 2008-07-04  Jim Meyering  <meyering@redhat.com>
122105         * users.txt: Add vc-dwim.
122106         (bison, coreutils): Use the gitweb URL.
122108 2008-07-03  Jim Meyering  <meyering@redhat.com>
122110         * users.txt: Add libffcall.  From Sam Steingold.
122112 2008-07-03  Ondřej Vašík  <ovasik@redhat.com>
122114         getdate.y: do not ignore TZ with relative day, month or year offset
122115         * lib/getdate.y (get_date): Move the tz-handling block to follow the
122116         relative-date-handling, since otherwise, the latter would clobber the
122117         sole output (an updated Start value) of the tz-handling block.
122118         * tests/test-getdate.c: Tests for the fix
122120 2008-07-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
122122         Recognize 'foo_LIBRARIES += libgnu.a'.
122123         * gnulib-tool (func_emit_lib_Makefile_am): Recognize if a
122124         makefile snippet has already specified an installation location,
122125         also using '+='.
122127 2008-07-02  Ondřej Vašík  <ovasik@redhat.com>
122129         getdate.y: factor out common actions
122130         * lib/getdate.y (apply_relative_time, set_hhmmss): New functions.
122131         Use them in place of open-coded actions.
122133 2008-07-01  Simon Josefsson  <simon@josefsson.org>
122135         Add self-test for getdate module.
122136         * modules/getdate-tests: New file.
122137         * tests/test-getdate.c: New file.
122139 2008-06-29  Bruno Haible  <bruno@clisp.org>
122141         * gnulib-tool (func_import): Put gnulib-comp.m4 into .cvsignore or
122142         .gitignore.
122143         Reported by Sylvain Beucler <beuc@beuc.net>.
122145 2008-06-29  Bruno Haible  <bruno@clisp.org>
122147         * doc/gnulib-tool.texi (VCS Issues): Mention --no-vc-files option.
122148         * m4/gnulib-tool.m4: Update to match current gnulib-tool.
122150 2008-06-29  Bruno Haible  <bruno@clisp.org>
122152         * gnulib-tool (func_import): Recommend to put gnulib-cache.m4 into
122153         EXTRA_DIST.
122154         Reported by Sylvain Beucler <beuc@beuc.net>.
122156 2008-06-26  Jim Meyering  <meyering@redhat.com>
122158         make several modules depend on the "open" module
122159         This provides slightly increased consistency when opening-for-write
122160         the name of a non-directory spelled with a trailing slash.
122161         * modules/chdir-safer: Likewise.
122162         * modules/chown: Likewise.
122163         * modules/clean-temp: Likewise.
122164         * modules/copy-file: Likewise.
122165         * modules/fchdir: Likewise.
122166         * modules/fcntl-safer: Likewise.
122167         * modules/pipe: Likewise.
122168         * modules/utime: Likewise.
122169         Prompted by Eric Blake and Bruno Haible.
122171 2008-06-24  Andreas Schwab  <schwab@suse.de>
122173         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Don't test whether compound
122174         literals can be used as initializers for global variables.
122176 2008-06-23  Eric Blake  <ebb9@byu.net>
122178         Make gnulib-cache.m4 easier to diff.
122179         * gnulib-tool (func_import): Allow newlines when reading cached
122180         gl_MODULES, and generate newlines when creating gnulib-cache.m4.
122182 2008-06-23  Bruno Haible  <bruno@clisp.org>
122184         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): Remove macro.
122185         (gl_PREREQ_SIGPROCMASK): Don't invoke it.
122186         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): New macro, moved here from
122187         m4/signalblocking.m4.
122188         (gl_PREREQ_SIGACTION): Don't invoke it.
122189         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Invoke
122190         gl_PREREQ_SIG_HANDLER_H.
122191         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
122192         Don't check for sigaction here.
122194 2008-06-23  Bruno Haible  <bruno@clisp.org>
122196         * lib/fatal-signal.c (fatal_signal_handler): Update comment.
122197         (install_handlers): Don't set the SA_RESETHAND flag.
122199 2008-06-23  Bruno Haible  <bruno@clisp.org>
122201         * m4/sigaction.m4: Comment fixes.
122202         * lib/signal.in.h: Likewise.
122204 2008-06-23  Eric Blake  <ebb9@byu.net>
122206         Fix typo.
122207         * tests/test-sigaction.c (MASK_SA_FLAGS): Add missing operator.
122209         Avoid SA_ namespace.
122210         * tests/test-sigaction.c (MASK_SA_FLAGS): Rename from SA_MASK.
122211         Reported by Ralf Wildenhues.
122213         Avoid test failure due to SA_RESTORER.
122214         * tests/test-sigaction.c (SA_MASK): New macro.
122215         (main): Avoid failing due to extension flags being set.
122216         Reported by Jim Meyering.
122218         Revert use of sig-handler.h in sigprocmask.c.
122219         * modules/sigprocmask (Files): Don't rely on sig-handler.h, since
122220         it requires the existence of struct sigaction.
122221         * lib/sigprocmask.c (handler_t): Restore typedef.
122222         (rpl_signal, old_handlers): Use local type.
122224 2008-06-22  Bruno Haible  <bruno@clisp.org>
122226         * tests/test-stdint.c: Disable the INTMAX_MAX preprocessor test
122227         conditionally.
122228         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
122230 2008-06-22  Bruno Haible  <bruno@clisp.org>
122232         * doc/posix-functions/siginterrupt.texi: Move note.
122234         * lib/signal.in.h (SA_RESTART): New macro.
122235         * lib/sigaction.c: Update comment.
122237         * m4/sigaction.m4 (gl_SIGACTION): Require gl_SIGNAL_H_DEFAULTS.
122239         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): New macro.
122240         (gl_PREREQ_SIGPROCMASK): Invoke it.
122241         * m4/sigaction.m4 (gl_PREREQ_SIGACTION): Likewise.
122243         * lib/nanosleep.c (rpl_nanosleep): Setup newact only when it is needed.
122245         * lib/sigprocmask.c: Update a comment.
122247 2008-06-21  Eric Blake  <ebb9@byu.net>
122249         Use sigaction module rather than signal().
122250         * modules/c-stack (Depends-on): Add sigaction.
122251         * modules/fatal-signal (Depends-on): Likewise.
122252         * modules/nanosleep (Depends-on): Likewise.
122253         * modules/sigprocmask (Files): Add sig-handler.h.
122254         * modules/sigaction (Files): Likewise.
122255         * lib/sig-handler.h (get_handler): New file, suggested by Paul
122256         Eggert.
122257         * lib/c-stack.c (SIGACTION_WORKS): Simplify conditions.
122258         (c_stack_action) [!SIGACTION_WORKS]: Use sigaction, not signal.
122259         * lib/fatal-signal.c (uninstall_handlers, install_handlers)
122260         (init_fatal_signals): Likewise.
122261         * lib/nanosleep.c (rpl_nanosleep): Likewise.
122262         (siginterrupt): Delete fallback.
122263         * lib/sigprocmask.c (handler_t, old_handlers): Use sa_handler_t
122264         instead.
122265         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Drop check for
122266         siginterrupt.
122268         New module sigaction, for mingw.
122269         * modules/sigaction: New module...
122270         * modules/sigaction-tests: ...and its test.
122271         * m4/sigaction.m4: New file.
122272         * lib/sigaction.c: Likewise.
122273         * tests/test-sigaction.c: Likewise.
122274         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Add sigaction variables.
122275         * modules/signal (Makefile.am): Likewise.
122276         * lib/signal.in.h (!@HAVE_SIGACTION@): Define replacements when
122277         needed.
122278         * doc/posix-headers/signal.texi (signal.h): Mention provided
122279         types.
122280         * doc/posix-functions/siginterrupt.texi (siginterrupt): Mention
122281         that sigaction is preferable.
122282         * doc/posix-functions/sigaction.texi (sigaction): Mention new
122283         module.
122284         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
122285         sigaction.
122287         Improve robustness of sigprocmask by overriding signal.
122288         * lib/signal.in.h (rpl_signal): Override signal when sigprocmask
122289         is in use.
122290         * lib/sigprocmask.c (blocked_handler): Reinstall block handler.
122291         (SIGKILL, SIGSTOP): Provide fallbacks.
122292         (rpl_signal): Implement.
122293         (old_handlers, blocked_set): Mark volatile, since sigprocmask and
122294         signal can be called inside handlers.
122296         Fix nanosleep module on mingw.
122297         * modules/nanosleep (Depends-on): Add sys_select.
122298         * lib/nanosleep.c (HAVE_SYS_SELECT_H): Rely on gnulib module.
122300         Fix licensing of sigprocmask.
122301         * modules/raise (License): Relicense as LGPL.
122303 2008-06-21  Bruno Haible  <bruno@clisp.org>
122305         * lib/propername.c (proper_name_utf8): Don't use the transliterated
122306         result if it contains question marks.
122307         Reported by Michael Geng <linux@michaelgeng.de>.
122309 2008-06-19  Bruno Haible  <bruno@clisp.org>
122311         Fix CVS-ism.
122312         * doc/gnulib.texi: Include updated-stamp.texi.
122313         * doc/Makefile (GNULIB_TEXI_FILES): New variable.
122314         (updated-stamp.texi): New rule.
122315         (gnulib.info): Depend on it.
122316         * doc/.gitignore: Add updated-stamp.texi.
122317         Based on a patch by Thien-Thi Nguyen <ttn@gnuvola.org>.
122319 2008-06-19  Bruno Haible  <bruno@clisp.org>
122321         * doc/Makefile (gnulib.info): Update and simplify dependencies.
122322         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
122324 2008-06-19  Eric Blake  <ebb9@byu.net>
122326         Fix VPATH 'make dist' with GNU make and non-VCS tarball.
122327         * top/GNUmakefile (_curr-ver): Don't use $(srcdir) unnecessarily.
122328         Reported by Stepan Kasal.
122330 2008-06-18  Bruno Haible  <bruno@clisp.org>
122332         * lib/fatal-signal.c (init_fatal_signals): Add comment.
122333         Reported by Eric Blake.
122335 2008-06-18  Eric Blake  <ebb9@byu.net>
122337         Work around cygwin 1.5.25 strsignal bug.
122338         * tests/test-strsignal.c: Allow for const char *.
122339         * doc/glibc-functions/strsignal.texi (strsignal): Document the bug.
122341 2008-06-18  Simon Josefsson  <simon@josefsson.org>
122343         * users.txt: Update URL to article and add author/date
122344         information.
122346 2008-06-17  Bruno Haible  <bruno@clisp.org>
122348         New macro gl_DISABLE_THREADS.
122349         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Use value gl_use_threads_default
122350         if the user did not pass --enable-threads or --disable-threads option.
122351         (gl_DISABLE_THREADS): New macro.
122352         Reported by Eric Blake <ebb9@byu.net>.
122354 2008-06-17  Bruno Haible  <bruno@clisp.org>
122356         * lib/tls.h (gl_tls_key_init): Evaluate the destructor argument also
122357         when the macro ignores it.
122358         Based on a patch by Eric Blake <ebb9@byu.net>.
122360 2008-06-17  Bruno Haible  <bruno@clisp.org>
122362         * modules/tls (License): Change to LGPLv2+.
122363         Reported by Eric Blake.
122365 2008-06-17  Eric Blake  <ebb9@byu.net>
122367         Simplify c-stack prerequisites.
122368         * lib/c-stack.c (includes): Remove unused <sys/resource.h>.
122369         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Posix 200x
122370         no longer requires <ucontext.h> to exist.  Optimize setrlimit
122371         check.
122372         (gl_PREREQ_C_STACK): Remove check for unused getcontext and
122373         <sys/resource.h>.
122375         Move c-stack test into testsuite.
122376         * modules/c-stack-tests: New file.
122377         * lib/c-stack.c [DEBUG]: Move test program...
122378         * tests/test-c-stack.c: ...into this new file.  Skip rather than
122379         fail test if sigaltstack is lacking.
122380         * tests/test-c-stack.sh: New driver file.
122382 2008-06-16  Eric Blake  <ebb9@byu.net>
122384         Use raise module consistently.
122385         * modules/fatal-signal (Depends-on): Add raise.
122386         * modules/sigprocmask (Depends-on): Likewise.
122387         * lib/fatal-signal.c (fatal_signal_handler): Rely on raise.
122388         * lib/sigprocmask.c (sigprocmask): Likewise.
122389         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
122390         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Likewise.
122392         Fix compliance bug in sigpending.
122393         * lib/sigprocmask.c (sigpending): Return pending array via
122394         parameter, not return value.
122396 2008-06-14  Eric Blake  <ebb9@byu.net>
122398         Improve obstack-printf test code.
122399         * tests/test-obstack-printf.c (test_function): Fix comment, and
122400         simplify usage of obstack_* in macros.  Add a test for coverage.
122401         Reported by Bruno Haible.
122403 2008-06-14  Bruno Haible  <bruno@clisp.org>
122405         * lib/obstack_printf.c (obstack_vprintf): Define the stack-allocated
122406         array size as a constant, not as a const variable.
122407         * m4/obstack-printf.m4 (gl_FUNC_OBSTACK_PRINTF): Require
122408         AC_USE_SYSTEM_EXTENSIONS.
122409         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
122410         Test whether the obstack_printf function actually exists.
122411         * modules/obstack-printf (Depends-on): Add extensions.
122412         (Include): Remove obstack.h.
122413         * modules/obstack-printf-posix (Depends-on): Add extensions.
122414         (Include): Remove obstack.h.
122416 2008-06-13  Eric Blake  <ebb9@byu.net>
122418         Add obstack-printf and obstack-printf-posix modules.
122419         * modules/obstack-printf: New file.
122420         * modules/obstack-printf-posix: Likewise.
122421         * MODULES.html.sh (Misc): Mention them.
122422         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
122423         Likewise.
122424         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
122425         Likewise.
122426         * modules/stdio (Makefile.am): Accomodate new modules.
122427         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
122428         * lib/stdio.in.h (rpl_obstack_printf, rpl_obstack_vprintf):
122429         Declare.
122430         * lib/obstack_printf.c (obstack_printf, obstack_vprintf): New
122431         functions.
122432         * m4/obstack-printf.m4 (gl_OBSTACK_PRINTF)
122433         (gl_REPLACE_OBSTACK_PRINTF): New macros
122434         * m4/obstack-printf-posix.m4 (gl_OBSTACK_PRINTF_POSIX): Likewise.
122435         * tests/test-obstack-printf.c: New file.
122436         * modules/obstack-printf-tests: Likewise.
122437         * modules/obstack-printf-posix-tests: Likewise.
122439 2008-06-11  Bruno Haible  <bruno@clisp.org>
122441         * m4/open.m4 (gl_FUNC_OPEN): Add test against trailing slash bug.
122442         * lib/open.c: Include errno.h.
122443         (open): Fail when attempting to write to a file that has a trailing
122444         slash.
122445         * tests/test-open.c (main): Test against trailing slash bug.
122446         * doc/posix-functions/open.texi: Mention the trailing slash bug.
122448 2008-06-10  Bruno Haible  <bruno@clisp.org>
122450         * tests/test-vc-list-files-git.sh: Make double use of 'exit'. Needed
122451         for $? to work inside the trap command, with various /bin/sh-s.
122452         * tests/test-vc-list-files-cvs.sh: Likewise.
122454 2008-06-10  Bruno Haible  <bruno@clisp.org>
122456         * lib/acl-internal.h: Don't include gettext.h here.
122457         * lib/set-mode-acl.c: Include gettext.h here.
122458         * lib/copy-acl.c: Likewise.
122460 2008-06-10  Bruno Haible  <bruno@clisp.org>
122462         * lib/wait-process.h (wait_subprocess): Add termsigp argument.
122463         * lib/wait-process.c (wait_subprocess): Likewise.
122464         * lib/execute.h (execute): Add termsigp argument.
122465         * lib/execute.c (execute): Likewise.
122466         * lib/csharpcomp.c (compile_csharp_using_pnet,
122467         compile_csharp_using_mono, compile_csharp_using_sscli): Update.
122468         * lib/csharpexec.c (execute_csharp_using_pnet,
122469         execute_csharp_using_mono, execute_csharp_using_sscli): Update.
122470         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
122471         compile_using_javac, compile_using_jikes, is_envjavac_gcj,
122472         is_envjavac_gcj43, is_gcj_present, is_gcj_43, is_javac_present,
122473         is_jikes_present): Update.
122474         * lib/javaexec.c (execute_java_class): Update.
122475         * lib/javaversion.c (execute_and_read_line): Update.
122476         * NEWS: Document the changes.
122477         Reported by Eric Blake.
122479 2008-06-10  Eric Blake  <ebb9@byu.net>
122481         Add missing include.
122482         * tests/test-strstr.c (includes): Add <signal.h>.
122483         * tests/test-strcasestr.c (includes): Likewise.
122484         * tests/test-memmem.c (includes): Likewise.
122486 2008-06-10  Bruno Haible  <bruno@clisp.org>
122488         * lib/wait-process.c (wait_subprocess): Add an assertion.
122490 2008-06-10  Bruno Haible  <bruno@clisp.org>
122492         * lib/wait-process.c (wait_subprocess): Try to fix waitid() based code.
122494 2008-06-10  Bruno Haible  <bruno@clisp.org>
122496         * tests/test-memmem.c (main): Reset SIGALRM to default handling before
122497         using alarm().
122498         * tests/test-strcasestr.c (main): Likewise.
122499         * tests/test-strstr.c (main): Likewise.
122501 2008-06-09  Bruno Haible  <bruno@clisp.org>
122503         Work around the Solaris 10 ACE ACLs ABI change.
122504         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): Don't
122505         declare if ACL_NO_TRIVIAL is present.
122506         (ACE_ACCESS_ALLOWED_ACE_TYPE, ACE_ACCESS_DENIED_ACE_TYPE,
122507         NEW_ACE_OWNER, NEW_ACE_GROUP, NEW_ACE_IDENTIFIER_GROUP, ACE_EVERYONE,
122508         NEW_ACE_READ_DATA, NEW_ACE_WRITE_DATA, NEW_ACE_EXECUTE): New macros.
122509         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): Don't
122510         define if ACL_NO_TRIVIAL is present.
122511         (acl_ace_nontrivial): Detect whether the old or new ABI is in use,
122512         and use the current ABI.
122513         (file_has_acl): Use same #if condition as elsewhere.
122514         * lib/set-mode-acl.c (qset_acl): Detect whether the old or new ABI is
122515         in use, and use the current ABI.
122516         * doc/acl-resources.txt: More doc about newer Solaris 10 versions.
122517         Reported by Jim Meyering.
122519 2008-06-09  Eric Blake  <ebb9@byu.net>
122521         Work around environments that (stupidly) ignore SIGALRM.
122522         * m4/strstr.m4 (gl_FUNC_STRSTR): Reset SIGALRM to default handling
122523         before using alarm().
122524         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
122525         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
122526         Reported by Ian Beckwith <ianb@erislabs.net>.
122528         Produce autobuild blurb earlier in log.
122529         * modules/autobuild (configure.ac-early): Move AB_INIT here.
122531 2008-06-09  Jim Meyering  <meyering@redhat.com>
122532         and Ondřej Vašík  <ovasik@redhat.com>
122534         utimens.c: correct kernel bug work-around
122535         Ondřej Vašík found that the invalid return value of 280 indicates
122536         failure, not success, and the kernel bug we're trying to work
122537         around affects not just the utimensat call, but also the fallback
122538         futimens call.
122539         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Simulate failure,
122540         not success.
122541         [HAVE_FUTIMENS]: Use the same work-around, here.
122543 2008-06-09  Jim Meyering  <meyering@redhat.com>
122545         add more guards around definition of ACE_-related code
122546         * lib/file-has-acl.c (acl_ace_nontrivial): Define only if
122547         ALLOW and ACE_OWNER are also defined.
122549 2008-06-08  Bruno Haible  <bruno@clisp.org>
122551         * lib/acl-internal.h: Add me as co-author.
122552         * lib/file-has-acl.c: Likewise.
122553         * lib/set-mode-acl.c: Likewise.
122554         * lib/copy-acl.c: Likewise.
122556 2008-06-08  Bruno Haible  <bruno@clisp.org>
122558         Add support for AIX ACLs.
122559         * lib/acl-internal.h (acl_nontrivial): New declaration.
122560         * lib/file-has-acl.c (acl_nontrivial): New function.
122561         (file_has_acl): Add implementation using AIX 4 ACL API.
122562         * lib/set-mode-acl.c (qset_acl): Likewise.
122563         * lib/copy-acl.c (qcopy_acl): Likewise.
122565 2008-06-08  Bruno Haible  <bruno@clisp.org>
122567         Add support for HP-UX ACLs.
122568         * lib/acl-internal.h (acl_nontrivial): New declaration.
122569         * lib/file-has-acl.c (acl_nontrivial): New function.
122570         (file_has_acl): Add implementation using HP-UX 11 ACL API.
122571         * lib/set-mode-acl.c (qset_acl): Likewise.
122572         * lib/copy-acl.c (qcopy_acl): Likewise.
122574 2008-06-08  Bruno Haible  <bruno@clisp.org>
122576         Add support for Cygwin ACLs.
122577         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro for Solaris-like API.
122578         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Don't optimize away
122579         the chmod_or_fchmod call.
122580         * lib/copy-acl.c (qcopy_acl) [!MODE_INSIDE_ACL]: Likewise.
122582 2008-06-08  Bruno Haible  <bruno@clisp.org>
122584         Fix bug with setuid modes in Solaris 10+ code.
122585         * lib/set-mode-acl.c (qset_acl): Call chmod_or_fchmod when acl_set
122586         succeeded, when the mode contains some special bits.
122588 2008-06-08  Bruno Haible  <bruno@clisp.org>
122590         Add support for Solaris 7..10 ACLs.
122591         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): New
122592         declarations.
122593         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): New
122594         functions.
122595         (file_has_acl): Add implementation using Solaris 7..10 ACL API.
122596         * lib/set-mode-acl.c (qset_acl): Likewise.
122597         * lib/copy-acl.c (qcopy_acl): Likewise.
122599 2008-06-08  Bruno Haible  <bruno@clisp.org>
122601         * lib/acl-internal.h (acl_extended_nontrivial) [MacOS X]: New
122602         declaration.
122603         * lib/file-has-acl.c (acl_extended_nontrivial) [MacOS X]: New function.
122604         (acl_access_nontrivial): Remove MacOS X case.
122605         (file_has_acl): Use acl_extended_nontrivial.
122606         * lib/copy-acl.c (qcopy_acl): Likewise.
122608 2008-06-08  Bruno Haible  <bruno@clisp.org>
122610         * lib/set-mode-acl.c (qset_acl): Trivial code simplifications.
122612 2008-06-08  Jim Meyering  <meyering@redhat.com>
122614         * modules/acl (Maintainer): Add Bruno Haible.
122616 2008-06-07  Bruno Haible  <bruno@clisp.org>
122618         Improve support for Tru64 ACLs.
122619         * lib/file-has-acl.c (file_has_acl): Don't test the ACL_TYPE_DEFAULT
122620         ACL on OSF/1.
122622 2008-06-07  Bruno Haible  <bruno@clisp.org>
122624         Add support for MacOS X ACLs.
122625         * lib/file-has-acl.c (file_has_acl): Use ACL_TYPE_EXTENDED instead of
122626         ACL_TYPE_ACCESS and ACL_TYPE_DEFAULT.
122627         * lib/set-mode-acl.c (qset_acl): Likewise.
122628         * lib/copy-acl.c (qcopy_acl): Likewise.
122630 2008-06-07  Bruno Haible  <bruno@clisp.org>
122632         Fix memory leak introduced on 2008-05-22.
122633         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Free ACLs after
122634         use.
122636 2008-06-07  Bruno Haible  <bruno@clisp.org>
122638         * lib/set-mode-acl.c (qset_acl): Use acl_init(), not acl_from_text(),
122639         to construct an empty ACL.
122641 2008-06-07  Bruno Haible  <bruno@clisp.org>
122643         * lib/set-mode-acl.c (chmod_or_fchmod): Document return value
122644         precisely.
122645         * lib/copy-acl.c (qcopy_acl): Trivial code simplifications.
122647 2008-06-07  Bruno Haible  <bruno@clisp.org>
122649         * lib/copy-acl.c (qcopy_acl): Make the #if branches independent.
122650         * lib/set-mode-acl.c (qset_acl): Choose better local variable names.
122652 2008-06-07  Bruno Haible  <bruno@clisp.org>
122654         * doc/posix-functions/_setjmp.texi: Explain the use of this function
122655         regardless of POSIX.
122656         * doc/posix-functions/_longjmp.texi: Likewise.
122657         * doc/posix-functions/setjmp.texi: Mention HP-UX as not counting as a
122658         SystemV platform in this case.
122660 2008-06-06  Eric Blake  <ebb9@byu.net>
122662         Document abort() bugs.
122663         * doc/posix-functions/abort.texi (abort): Mention anomalies.
122665         * doc/posix-functions/setjmp.texi (setjmp): Mingw has setjmp.
122666         * doc/posix-functions/sigsetjmp.texi (sigsetjmp): Cygwin has
122667         sigsetjmp.
122668         * doc/posix-functions/siglongjmp.texi (siglongjmp): Cygwin has
122669         siglongjmp, but only as a macro.
122670         * doc/posix-functions/_longjmp.texi (_longjmp): Mention that this
122671         is obsolete.
122672         * doc/posix-functions/_setjmp.texi (_setjmp): Likewise.
122674         Tweak documentation to cover cygwin argz bugs.
122675         * m4/argz.m4 (gl_FUNC_ARGZ): Mention date of last known cygwin
122676         argz bug fix; no code change needed since no cygwin releases
122677         occurred between the last fix and the bug being tested.
122678         * doc/glibc-functions/argz_add.texi (argz_add): Document the argz
122679         module and recently fixed cygwin bugs.
122680         * doc/glibc-functions/argz_add_sep.texi (argz_add_sep): Likewise.
122681         * doc/glibc-functions/argz_append.texi (argz_append): Likewise.
122682         * doc/glibc-functions/argz_count.texi (argz_count): Likewise.
122683         * doc/glibc-functions/argz_create.texi (argz_create): Likewise.
122684         * doc/glibc-functions/argz_create_sep.texi (argz_create_sep):
122685         Likewise.
122686         * doc/glibc-functions/argz_delete.texi (argz_delete): Likewise.
122687         * doc/glibc-functions/argz_extract.texi (argz_extract): Likewise.
122688         * doc/glibc-functions/argz_insert.texi (argz_insert): Likewise.
122689         * doc/glibc-functions/argz_next.texi (argz_next): Likewise.
122690         * doc/glibc-functions/argz_replace.texi (argz_replace): Likewise.
122691         * doc/glibc-functions/argz_stringify.texi (argz_stringify):
122692         Likewise.
122694         Avoid gcc warning on cygwin.
122695         * lib/copy-acl.c (qcopy_acl) [!HAVE_ACL_GET_FILE &&
122696         !ACL_NO_TRIVIAL]: Avoid unused variable.
122698 2008-06-05  Eric Blake  <ebb9@byu.net>
122700         Be tolerant of UNKNOWN version in gnulib-tool test dir.
122701         * top/GNUmakefile (_dummy): Warn rather than reconfigure if
122702         git-version-gen fails to come up with a version.
122703         Reported by Simon Josefsson.
122705 2008-06-05  Jim Meyering  <meyering@redhat.com>
122706             Paul Eggert  <eggert@cs.ucla.edu>
122708         utimens.c: work around a probable Linux kernel bug
122709         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Work around what
122710         appears to be a kernel bug that causes utimensat to return 280
122711         instead of 0, indicating success.
122713 2008-06-04  Bruno Haible  <bruno@clisp.org>
122715         * lib/copy-acl.c (qcopy_acl): Call qset_acl, not set_acl. Fixes
122716         2008-06-01 commit.
122718 2008-06-04  Bruno Haible  <bruno@clisp.org>
122720         * lib/acl-internal.h (acl_access_nontrivial): New declaration.
122721         * lib/file-has-acl.c (acl_access_nontrivial): New function.
122722         (file_has_acl): Use it. Save errno afterwards.
122723         * lib/copy-acl.c (qcopy_acl): Use acl_access_nontrivial.
122725 2008-06-03  Bruno Haible  <bruno@clisp.org>
122727         * lib/file-has-acl.c (file_has_acl): Put Solaris 10 code after POSIX-
122728         draft code. Simplify #ifs.
122729         * lib/set-mode-acl.c (qset_acl): Don't test for symlink if !USE_ACL.
122730         Put Solaris code after POSIX-draft code. Fix comments regarding
122731         Solaris 10, HP-UX. Mention Cygwin.
122732         * lib/copy-acl.c (qcopy_acl): Simplify #ifs.
122734 2008-06-03  Eric Blake  <ebb9@byu.net>
122736         Provide fallback for older kernels.
122737         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT, HAVE_FUTIMENS]:
122738         Provide runtime fallback if kernel lacks support.
122739         Reported by Mike Frysinger.
122741 2008-06-02  Bruno Haible  <bruno@clisp.org>
122743         * lib/acl-internal.h (ACL_NOT_WELL_SUPPORTED): Include EOPNOTSUPP if
122744         it exists.
122746 2008-06-02  Bruno Haible  <bruno@clisp.org>
122748         * lib/acl_entries.c (acl_entries): Rewrite to use acl_get_entry.
122749         * lib/copy-acl.c (qcopy_acl): Update comment.
122751 2008-06-02  Bruno Haible  <bruno@clisp.org>
122753         * lib/acl-entries.h: Enclose most definitions in #ifs for POSIX-draft
122754         like ACL APIs.
122756 2008-06-02  Bruno Haible  <bruno@clisp.org>
122758         * tests/test-file-has-acl.sh: Use different code for Cygwin.
122759         * tests/test-set-mode-acl.sh: Likewise.
122760         * tests/test-copy-acl.sh: Likewise.
122761         * tests/test-copy-file.sh: Likewise.
122763 2008-06-02  Bruno Haible  <bruno@clisp.org>
122765         * tests/test-file-has-acl.sh: Remove unused code.
122767 2008-06-01  Bruno Haible  <bruno@clisp.org>
122769         * lib/copy-acl.c (qcopy_acl): New function, extracted from copy_acl.
122770         (copy_acl): Just a wrapper around qcopy_acl that emits the error
122771         messages.
122772         * lib/set-mode-acl.c (qset_acl): Document return value precisely.
122774 2008-06-01  Bruno Haible  <bruno@clisp.org>
122776         * m4/acl.m4 (gl_FUNC_ACL): Separate the POSIX-like and the Solaris
122777         tests. Test for libpacl, needed for OSF/1. Test for extended ACLs,
122778         needed for MacOS X. Test for HP-UX API. Test for newer and older AIX
122779         APIs.
122780         * modules/acl-tests (configure.ac): Remove tests now contained in
122781         m4/acl.m4.
122783 2008-06-02  Jim Meyering  <meyering@redhat.com>
122785         announce-gen: use a better key-server host name
122786         * build-aux/announce-gen (main): Recommend keys.gnupg.net, since
122787         it may be more consistently reliable.  Suggested by Werner Koch
122788         in <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/13717>.
122790 2008-06-01  Bruno Haible  <bruno@clisp.org>
122792         * lib/stdio-impl.h (fp_ub): Use fp_. Needed for DragonFly BSD.
122793         Reported by Voroskoi Andras <voroskoi@gmail.com>.
122795 2008-06-01  Voroskoi Andras  <voroskoi@gmail.com>  (tiny change)
122797         * lib/stdio-impl.h [__DragonFly__]: Fix typo.
122799 2008-06-01  Bruno Haible  <bruno@clisp.org>
122801         New ACL tests.
122802         * tests/test-file-has-acl.sh: New file.
122803         * tests/test-file-has-acl.c: New file.
122804         * tests/test-set-mode-acl.sh: New file.
122805         * tests/test-set-mode-acl.c: New file.
122806         * tests/test-copy-acl.sh: New file, based on tests/test-copy-file.sh.
122807         * tests/test-copy-acl.c: New file.
122808         * modules/acl-tests: New file, based on modules/copy-file-tests.
122809         * modules/copy-file-tests (Files): Remove tests/test-sameacls.c.
122810         (Depends-on): Add acl-tests.
122811         (configure.ac): Remove checks.
122812         (Makefile.am): Don't create test-sameacls program here any more.
122814 2008-06-01  Bruno Haible  <bruno@clisp.org>
122816         * tests/test-copy-file.sh: Portability fixes for Solaris, HP-UX, IRIX.
122817         * tests/test-sameacls.c: Include progname.h.
122818         (main): Invoke set_program_name. Portability fixes for MacOS X,
122819         Solaris, HP-UX.
122821 2008-06-01  Bruno Haible  <bruno@clisp.org>
122823         * lib/freadahead.c (freadahead) [__DragonFly__]: Use the __sreadahead
122824         function.
122825         Reported by VOROSKOI Andras <voroskoi@gmail.com>.
122827 2008-06-01  Bruno Haible  <bruno@clisp.org>
122829         * modules/rpmatch (Depends-on): Add strdup.
122831 2008-06-01  Bruno Haible  <bruno@clisp.org>
122833         * lib/pipe.c: Include unistd-safer.h.
122834         (create_pipe): Ensure the returned file descriptors are not in {0,1,2}.
122835         * modules/pipe (Depends-on): Add unistd-safer.
122837 2008-05-30  Simon Josefsson  <simon@josefsson.org>
122839         * modules/autobuild (configure.ac): Call AB_INIT.
122841 2008-05-30  Simon Josefsson  <simon@josefsson.org>
122843         * tests/test-getaddrinfo.c: Don't print debug messages by default.
122844         Suggested by Bruno Haible <bruno@clisp.org>.
122846 2008-05-30  Simon Josefsson  <simon@josefsson.org>
122848         * tests/test-base64.c: Cast size_t to unsigned long when invoking
122849         printf.  Use %lu instead of %d.  Reported by Bruno Haible
122850         <bruno@clisp.org>.
122852 2008-05-29  Eric Blake  <ebb9@byu.net>
122854         Prefer new POSIX 200x interfaces over futimesat.
122855         * m4/utimens.m4 (gl_UTIMENS): Check for futimens, utimensat.
122856         * lib/utimens.c (gl_futimens): Use them for nanosecond resolution
122857         when available.
122858         [HAVE_BUGGY_NFS_TIME_STAMPS]: Allow C89 compilation.
122860 2008-05-28  Bruno Haible  <bruno@clisp.org>
122862         * modules/stpcpy (License): Change to LGPLv2+.
122863         Requested by David Lutterkort <dlutter@redhat.com>.
122865 2008-05-27  Bruno Haible  <bruno@clisp.org>
122867         * lib/localename.c (SUBLANG_TIBETAN_BHUTAN): Force value 2. Needed for
122868         current mingw.
122869         Reported by Jose E. Marchesi <jemarch@gnu.org>.
122871 2008-05-27  Bruno Haible  <bruno@clisp.org>
122873         * modules/iconv_open (Link): New section, from module 'iconv'.
122874         * modules/striconv (Link): Likewise.
122875         * modules/striconveh (Link): Likewise.
122876         * modules/xstriconv (Link): Likewise.
122877         * modules/unicodeio (Link): Likewise.
122878         * modules/propername (Link): Likewise.
122879         Reported by Jim Meyering.
122881 2008-05-26  Jim Meyering  <meyering@redhat.com>
122883         sha256: do not artificially restrict buffer length to be < 2^32
122884         * lib/sha256.h (struct sha256_ctx) [buflen]: Change type from
122885         uint32_t to size_t.
122886         * lib/sha256.c (sha256_conclude_ctx): Change type of a local
122887         to match.
122889         avoid unaligned access errors, e.g., on sparc
122890         * lib/sha512.c (sha512_conclude_ctx): Use set_uint64 rather than
122891         direct access through a possibly-unaligned uint64* pointer.
122892         * lib/sha256.c (sha256_conclude_ctx): Use set_uint32 rather than
122893         direct access through a possibly-unaligned uint32* pointer.
122894         Prompted by this patch from Tom "spot" Callaway:
122895         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/13638
122897         sha512.c: fix typo in comment
122898         * lib/sha512.c (sha512_conclude_ctx): Length is 128-bit, not 64-bit.
122900 2008-05-25  Bruno Haible  <bruno@clisp.org>
122902         * lib/set-mode-acl.c: Renamed from lib/acl.c.
122903         * modules/acl (Files): Add lib/set-mode-acl.c, remove lib/acl.c.
122904         (Makefile.am): Update lib_SOURCES.
122906 2008-05-25  Bruno Haible  <bruno@clisp.org>
122908         * m4/acl.m4 (gl_FUNC_ACL): Don't set LIB_ACL_TRIVIAL.
122910 2008-05-25  Jim Meyering  <meyering@redhat.com>
122912         useless-if-before-free: freed expr may have white-space differences
122913         * build-aux/useless-if-before-free: Recognize cases in which the
122914         freed expression differs from the tested one in embedded white
122915         space, e.g., if (p[i + 1]) free(p[i+1]).  Correct thinko in prev:
122916         $1 was used, so we can't make any regexp shy.  Improved tests now
122917         detect this.
122919         useless-if-before-free: accept white space in the expression.
122920         * build-aux/useless-if-before-free: For now, any white space
122921         in the expression must be identical in the free argument.
122923         useless-if-before-free: efficiency tweak
122924         * build-aux/useless-if-before-free: Make the expression-matching
122925         regexp "shy".
122926         Make the *outer* regexp shy, not the expr-matching one.
122928         update code-in-comment to accept cast of free arg
122929         * build-aux/useless-if-before-free: Update regexp.
122931 2008-05-25  Bruno Haible  <bruno@clisp.org>
122933         * tests/test-sameacls.c: Renamed from tests/test-copy-file-sameacls.c.
122934         * modules/copy-file-tests (Files, Makefile.am): Update.
122935         * tests/test-copy-file.c (func_test_copy): Update.
122937 2008-05-24  Andreas Färber  <andreas.faerber@web.de>  (tiny change)
122939         * lib/stdbool.in.h [__HAIKU__]: Disable __BEOS__ workarounds.
122941 2008-05-23  Bruno Haible  <bruno@clisp.org>
122943         Improve support for ACLs on OSF/1.
122944         * lib/acl.c (qset_acl): For OSF/1, use a string that ends in a comma.
122945         Remove fallback for unknown flavors of ACLs.
122947 2008-05-22  Bruno Haible  <bruno@clisp.org>
122949         Add support for ACLs on OSF/1.
122950         * lib/acl-internal.h (acl_get_fd, acl_set_fd): New inline function
122951         replacements.
122952         (acl_free_text): New macro fallback.
122953         * lib/acl_entries.c (acl_entries): Use acl_free_text instead of
122954         acl_free.
122955         * m4/acl.m4 (gl_FUNC_ACL): Look also in libpacl library. Test for
122956         acl_free_text function. Require AC_C_INLINE.
122958 2008-05-22  Bruno Haible  <bruno@clisp.org>
122960         Make copy_acl work on MacOS X 10.5.
122961         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro.
122962         (ACL_NOT_WELL_SUPPORTED): On MacOS X, also handle ENOENT.
122963         * lib/acl.c (qset_acl): Add different code branch for !MODE_INSIDE_ACL.
122964         If MODE_INSIDE_ACL, don't assume that every system has the same text
122965         representation for ACLs as FreeBSD.
122966         * lib/copy-acl.c (copy_acl): Add support for platforms with
122967         !MODE_INSIDE_ACL.
122968         * lib/file-has-acl.c (file_has_acl): Likewise.
122969         * m4/acl.m4 (gl_FUNC_ACL): Test for some functions that are witness of
122970         FreeBSD, MacOS X, or IRIX, respectively.
122972 2008-05-22  Bruno Haible  <bruno@clisp.org>
122974         * lib/acl.h: Don't include <sys/acl.h>.
122975         (GETACLCNT): Move fallback to lib/acl-internal.h.
122976         * lib/acl-internal.h: Include <sys/acl.h> here.
122977         (GETACLCNT): New macro fallback, moved here from lib/acl.h.
122979 2008-05-22  Bruno Haible  <bruno@clisp.org>
122981         Split off copy_acl function to separate file.
122982         * lib/copy-acl.c: New file, extracted from lib/acl.c.
122983         * lib/acl.c (copy_acl): Moved function to separate file.
122984         * m4/acl.m4 (gl_FUNC_ACL): Remove unconditional AC_LIBOBJs.
122985         * modules/acl (Files): Add lib/copy-acl.c.
122986         (Makefiles.am): Augment lib_SOURCES.
122988 2008-05-22  Bruno Haible  <bruno@clisp.org>
122990         * modules/copy-file-tests: New file.
122991         * tests/test-copy-file.sh: New file.
122992         * tests/test-copy-file.c: New file.
122993         * tests/test-copy-file-sameacls.c: New file.
122995 2008-05-22  Eric Blake  <ebb9@byu.net>
122997         Avoid gcc warning.
122998         * tests/test-memcmp.c (main): Pass NULL indirectly.
123000 2008-05-21  Bruno Haible  <bruno@clisp.org>
123002         Add reference doc about ACLs.
123003         * doc/acl-resources.txt: New file.
123004         * doc/acl-cygwin.txt: New file.
123006 2008-05-21  Bruno Haible  <bruno@clisp.org>
123008         Avoid one more warning from gcc.
123009         * lib/vasnprintf.c (IF_LINT): Update comments.
123010         (VASNPRINTF): Use it also for the 'prefix' array initializer.
123012 2008-05-21  Jim Meyering  <meyering@redhat.com>
123014         avoid a warning from gcc
123015         * lib/vasnprintf.c (IF_LINT): Define.
123016         (scale10_round_decimal_long_double):
123017         Use it to avoid a "may be used uninitialized" warning.
123018         (scale10_round_decimal_double): Likewise.
123020 2008-05-21  Simon Josefsson  <simon@josefsson.org>
123022         * m4/memcmp.m4: When cross-compiling, assume memcmp works if it is
123023         declared.
123025 2008-05-20  Bruno Haible  <bruno@clisp.org>
123027         * tests/test-memcmp.c (main): Test also the sign of the result. Test
123028         against two known bugs; code taken from autoconf's AC_FUNC_MEMCMP.
123030 2008-05-20  Simon Josefsson  <simon@josefsson.org>
123032         * modules/memcmp-tests: New file.
123033         * tests/test-memcmp.c: New file.
123035 2008-05-19  Bruno Haible  <bruno@clisp.org>
123037         * modules/propername (Notice, configure.ac): Put quoted "..." into
123038         --keyword option.
123039         * lib/propername.h: Update comments accordingly.
123040         Reported by Eric Blake.
123042 2008-05-19  Martin Lambers  <marlam@marlam.de>  (tiny change)
123044         * modules/getpass-gnu (Depends-on): Add fseeko.
123046 2008-05-19  Simon Josefsson  <simon@josefsson.org>
123048         * modules/base64-tests: New file.
123050 2008-05-19  Bo Borgerson  <gigabo@gmail.com>
123052         * lib/base64.c (base64_decode_ctx): If a decode context structure
123053         was passed in use it to ignore newlines.  If a context structure
123054         was _not_ passed in, continue to treat newlines as garbage (this
123055         is the historical behavior).  Formerly base64_decode.
123056         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
123057         takes a decode context structure.
123058         * lib/base64.h (base64_decode): Macro for four-argument calls.
123059         (base64_decode_alloc): Likewise.
123060         * lib/base64.c (base64_decode_ctx): If a decode context structure
123061         was passed in use it to ignore newlines.  If a context structure
123062         was _not_ passed in, continue to treat newlines as garbage (this
123063         is the historical behavior).  Formerly base64_decode.
123064         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
123065         takes a decode context structure.
123066         * lib/base64.h (base64_decode): Macro for four-argument calls.
123067         (base64_decode_alloc): Likewise.
123069 2008-05-19  Jim Meyering  <meyering@redhat.com>
123071         avoid a warning from gcc
123072         * lib/trim.c (IF_LINT): Define.
123073         (trim2): Use it to avoid a "may be used uninitialized" warning.
123075         Fix doc typo.
123076         * doc/glibc-functions/getpass.texi (getpass): s/PATH_MAX/PASS_MAX/.
123078 2008-05-19  Bruno Haible  <bruno@clisp.org>
123080         * doc/glibc-functions/getpass.texi: Document limits of other
123081         implementations.
123083 2008-05-19  Simon Josefsson  <simon@josefsson.org>
123084             Bruno Haible <bruno@clisp.org>
123086         * doc/glibc-functions/getpass.texi: Document gnulib implementation.
123088 2008-05-18  Bruno Haible  <bruno@clisp.org>
123090         * modules/propername: New file, from GNU gettext.
123091         * lib/propername.h: New file, from GNU gettext.
123092         * lib/propername.c: New file, from GNU gettext.
123093         * MODULES.html.sh (Internationalization functions): Add propername.
123095 2008-05-16  Jim Meyering  <meyering@redhat.com>
123096             Bruno Haible  <bruno@clisp.org>
123098         Avoid some warnings from "gcc -Wshadow".
123099         * lib/vasnprintf.c (exp, remainder): Define to different identifiers.
123101 2008-05-15  Eric Blake  <ebb9@byu.net>
123103         Extend previous patch to cygwin 1.7.0.
123104         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a
123105         fast implementation in cygwin >= 1.7.0.
123106         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
123107         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
123109 2008-05-15  Bruno Haible  <bruno@clisp.org>
123111         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a fast
123112         implementation in glibc >= 2.9.
123113         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
123114         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
123116 2008-05-15  Bruno Haible  <bruno@clisp.org>
123118         * MODULES.html.sh (Internationalization functions): Remove linebreak.
123119         (Unicode string functions): Add unilbrk/*.
123120         Reported by Karl Berry.
123122 2008-05-15  Eric Blake  <ebb9@byu.net>
123124         Fix violation of <stdbool.h> replacement in regex.
123125         * lib/regcomp.c (re_compile_internal): Avoid implicit cast to bool.
123126         * lib/regexec.c (re_search_internal): Likewise.
123127         Reported by Heinrich Mislik <Heinrich.Mislik@univie.ac.at>.
123129 2008-05-15  Jim Meyering  <meyering@redhat.com>
123131         avoid distracting test output when git or cvs is not found
123132         * tests/test-vc-list-files-cvs.sh: Suppress 'init' error output.
123133         * tests/test-vc-list-files-git.sh: Likewise.
123135 2008-05-15  Eric Blake  <ebb9@byu.net>
123137         Glibc finally accepted the memmem speedup code, bugzilla #5514.
123138         * doc/glibc-functions/memmem.texi (memmem): Mention last broken
123139         glibc version.
123140         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
123141         * doc/posix-functions/strstr.texi (strstr): Likewise.
123142         * lib/str-two-way.h (MAX): Sychronize with glibc.
123144 2008-05-15  Paolo Bonzini  <bonzini@gnu.org>
123146         * lib/regcomp.c (optimize_utf8): Add a note on why we test
123147         opr.ctx_type.
123148         (calc_first): Initialize constraint field.
123149         (duplicate_node_closure): Use it instead of special casing ANCHORS.
123150         Fix grammar.
123151         (duplicate_node): Merge constraint field for all node types.
123152         (calc_eclosure_iter): Look at constraint field for all node types.
123153         * lib/regex_internal.c (create_cd_newstate): Don't look at
123154         opr.ctx_type.
123156 2008-05-14  Bruno Haible  <bruno@clisp.org>
123158         Help GCC to do better code generation.
123159         * lib/eealloc.h (eemalloc) [GCC >= 3]: Declare with attribute 'malloc'.
123160         * lib/pagealign_alloc.h (pagealign_alloc, pagealign_xalloc): Likewise.
123161         * lib/xalloc.h (ATTRIBUTE_MALLOC): New macro.
123162         (xmalloc, xzalloc, xcalloc, xmemdup, xstrdup, xnmalloc, xcharalloc):
123163         Declare with attribute 'malloc' if supported.
123165 2008-05-14  Lasse Collin  <lasse.collin@tukaani.org>
123167         use "echo STR|wc -c" rather than unportable "expr length STR"
123168         * build-aux/mktempd (mktempd): Vendor-supplied expr from at least
123169         OpenBSD 4.3 and Solaris 10 do not honor expr's "length" function.
123171 2008-05-14  Jim Meyering  <meyering@redhat.com>
123173         use dd ibs=$n count=1 ... rather than less-portable head -c$n
123174         * build-aux/mktempd (rand_bytes): head's -cN option is not accepted
123175         by Solaris 10's /bin/head or by the one from HP-UX 11.x.
123176         Reported in http://sourceforge.net/forum/message.php?msg_id=4960334
123177         via Collin Lasse.
123179 2008-05-14  Eric Blake  <ebb9@byu.net>
123181         Avoid quadratic growth in gl_LIBSOURCES.
123182         * gnulib-tool (func_emit_initmacro_done): s/\(m4_append\)_uniq/\1/.
123183         Suggested by Bruno Haible.
123185         Test xmemdup0.
123186         * modules/xmemdup0-tests: New file.
123187         * tests/test-xmemdup0.c: Likewise.
123189 2008-05-13  Eric Blake  <ebb9@byu.net>
123191         Split xmemdup0 into its own module.
123192         * modules/xmemdup0: New file.
123193         * lib/xmemdup0.h: Likewise.
123194         * lib/xmemdup0.c: Likewise.
123195         * MODULES.html.sh (Memory management functions): Add xmemdup0.
123196         * lib/xalloc.h (xmemdup0): Remove.
123197         * lib/xmalloc.c (xmemdup0): Likewise.
123199 2008-05-13  Eric Blake  <ebb9@byu.net>
123200             Bruno Haible  <bruno@clisp.org>
123202         Reduce number of forks required during autoconf.
123203         * gnulib-tool (func_emit_initmacro_start): Prepare gl_LIBSOURCES_LIST
123204         and gl_LIBSOURCES_DIR.
123205         (func_emit_initmacro_end): Use them here in a single m4_syscmd...
123206         (func_emit_initmacro_done) <gl_LIBSOURCES>: ...rather than in one
123207         m4_syscmd per file.
123208         <m4_foreach_w>: Move...
123209         * m4/gnulib-common.m4 (m4_foreach_w): ...here.
123211 2008-05-13  Eric Blake  <ebb9@byu.net>
123213         * gnulib-tool: Fix various comment typos.
123215 2008-05-12  Bruno Haible  <bruno@clisp.org>
123217         Tailor the linebreaking algorithm.
123218         * lib/unilbrk/tables.c (unilbrk_table): Change (IS,AL) entry.
123220 2008-05-12  Bruno Haible  <bruno@clisp.org>
123222         Update to Unicode 5.0.0.
123223         * lib/unilbrk/tables.h (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
123224         LBP_JV, LBP_JT. Redistribute values.
123225         (unilbrk_table): Change size.
123226         * lib/unilbrk/tables.c (unilbrk_table): Change size. Update to match
123227         Unicode TR#14 rev. 22.
123228         * lib/unilbrk/gen-lbrk.c (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
123229         LBP_JV, LBP_JT. Redistribute values.
123230         (get_lbp): Update to match Unicode TR#14 rev. 21/22 and Unicode 5.0.0.
123231         (debug_output_lbp, fill_org_lbp, debug_output_org_lbp, output_lbp):
123232         Update.
123233         * lib/unilbrk/lbrkprop1.h: Regenerated.
123234         * lib/unilbrk/lbrkprop2.h: Regenerated.
123235         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks):
123236         Change handling of LBP_CM after LBP_ZW. Update for new value of LBP_BK.
123237         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
123238         Likewise.
123239         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
123240         Likewise.
123241         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update expected
123242         result.
123243         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
123244         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
123245         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
123246         * tests/unilbrk/test-u8-width-linebreaks.c (main): Likewise.
123247         * tests/unilbrk/test-u16-width-linebreaks.c (main): Likewise.
123248         * tests/unilbrk/test-u32-width-linebreaks.c (main): Likewise.
123250 2008-05-11  Bruno Haible  <bruno@clisp.org>
123252         * lib/unilbrk/gen-lbrk.c (output_lbp): Fix whitespace.
123254 2008-05-11  Bruno Haible  <bruno@clisp.org>
123256         * lib/unilbrk/gen-lbrk.c: New file, from GNU gettext (gen-lbrkprop.c).
123257         * modules/unilbrk/gen-lbrk: New file.
123259 2008-05-11  Bruno Haible  <bruno@clisp.org>
123261         * m4/sha256.m4 (gl_SHA256): Require AC_C_INLINE.
123262         * m4/sha512.m4 (gl_SHA512): Likewise.
123264 2008-05-11  Jim Meyering  <meyering@redhat.com>
123266         New modules: crypto/sha256, crypto/sha512 (from coreutils)
123267         * modules/crypto/sha256: New file.
123268         * modules/crypto/sha512: Likewise.
123269         * lib/sha256.c: Likewise.
123270         * lib/sha256.h: Likewise.
123271         * lib/sha512.c: Likewise.
123272         * lib/sha512.h: Likewise.
123273         * lib/u64.h: Likewise.
123274         * m4/sha256.m4: Likewise.
123275         * m4/sha512.m4: Likewise.
123276         * MODULES.html.sh (Cryptographic computations (low-level)): List them.
123278 2008-05-10  Bruno Haible  <bruno@clisp.org>
123280         * MODULES.html.sh (Environment variables <stdlib.h>): Add unsetenv.
123281         (Input/Output <stdio.h>): Add xprintf.
123282         (Signal handling <signal.h>): Add strsignal.
123283         (Cryptographic computations (high-level)): Add crypto/gc-camellia.
123284         (Core language properties): Add func.
123285         (Mathematics <math.h>): Add ceil, floor, frexp-nolibm.
123286         (Support for systems lacking POSIX:2001): Add environ, EOVERFLOW,
123287         strings.
123288         (Enhancements for POSIX:2001 functions): Add iconv_open-utf.
123289         (Input/output): New section.
123290         (File system functions): Add openat-die, stat-macros.
123291         (Networking functions): Add sockets.
123292         (Unicode string functions): Add unictype/*.
123293         (Support for building libraries and executables): Add gperf.
123294         (Support for building documentation): Add agpl-3.0.
123295         (Misc): Add nocrash.
123297 2008-05-10  Bruno Haible  <bruno@clisp.org>
123299         * modules/unictype/gen-ctype: New file.
123301 2008-05-10  Jim Meyering  <meyering@redhat.com>
123303         Make chdir-safer.c more efficient on a system with no symlinks.
123304         * lib/chdir-safer.c (chdir_no_follow): Skip lstat and fstat calls
123305         also if ELOOP is zero.  Suggested by Bruno Haible.
123307         Make chdir-safer.c slightly safer.
123308         * lib/chdir-safer.c (chdir_no_follow): Test HAVE_WORKING_O_NOFOLLOW,
123309         not O_NOFOLLOW, in case the latter is nonzero and open ignores it.
123311         Avoid compile failure on systems without ELOOP (like mingw).
123312         * lib/chdir-safer.c (ELOOP): Define if not already defined.
123313         Reported by Bruno Haible.
123315 2008-05-10  Bruno Haible  <bruno@clisp.org>
123317         * lib/unilbrk/ulc-common.c: Include c-strcaseeq.h instead of streq.h.
123318         (is_utf8_encoding): Use a case-insensitive comparison.
123319         * modules/unilbrk/ulc-common (Depends-on): Add c-strcaseeq. Remove
123320         streq.
123322 2008-05-10  Bruno Haible  <bruno@clisp.org>
123324         * lib/unilbrk/ulc-common.c: Don't include <stdlib.h>.
123325         (iconv_string_length, iconv_string_keeping_offsets): Remove functions.
123326         * lib/unilbrk/ulc-common.h (iconv_string_length,
123327         iconv_string_keeping_offsets): Remove declarations.
123328         * lib/unilbrk/ulc-possible-linebreaks.c: Include <string.h>, uniconv.h.
123329         Don't include <iconv.h>, streq.h, xsize.h.
123330         (ulc_possible_linebreaks): Use u8_conv_from_encoding for doing the
123331         conversion.
123332         * lib/unilbrk/ulc-width-linebreaks.c: Include uniconv.h. Don't include
123333         <iconv.h>, streq.h, xsize.h.
123334         (ulc_width_linebreaks): Use u8_conv_from_encoding for doing the
123335         conversion.
123336         * modules/unilbrk/ulc-common (Depends-on): Remove iconv.
123337         * modules/unilbrk/ulc-possible-linebreaks (Depends-on): Add
123338         uniconv/u8-conv-from-enc. Remove iconv_open, streq, xsize.
123339         * modules/unilbrk/ulc-width-linebreaks (Depends-on): Likewise.
123341 2008-05-10  Bruno Haible  <bruno@clisp.org>
123343         * modules/unilbrk/ulc-width-linebreaks-tests: New file.
123344         * tests/unilbrk/test-ulc-width-linebreaks.c: New file.
123346         * modules/unilbrk/u32-width-linebreaks-tests: New file.
123347         * tests/unilbrk/test-u32-width-linebreaks.c: New file.
123349         * modules/unilbrk/u16-width-linebreaks-tests: New file.
123350         * tests/unilbrk/test-u16-width-linebreaks.c: New file.
123352         * modules/unilbrk/u8-width-linebreaks-tests: New file.
123353         * tests/unilbrk/test-u8-width-linebreaks.c: New file.
123355         * modules/unilbrk/ulc-possible-linebreaks-tests: New file.
123356         * tests/unilbrk/test-ulc-possible-linebreaks.c: New file.
123358         * modules/unilbrk/u32-possible-linebreaks-tests: New file.
123359         * tests/unilbrk/test-u32-possible-linebreaks.c: New file.
123361         * modules/unilbrk/u16-possible-linebreaks-tests: New file.
123362         * tests/unilbrk/test-u16-possible-linebreaks.c: New file.
123364         * modules/unilbrk/u8-possible-linebreaks-tests: New file.
123365         * tests/unilbrk/test-u8-possible-linebreaks.c: New file.
123367 2008-05-10  Bruno Haible  <bruno@clisp.org>
123369         Split up 'linebreak' module.
123370         * lib/unilbrk.h: New file, based on lib/linebreak.h.
123371         * lib/unilbrk/lbrkprop1.h: New file, extracted from lib/lbrkprop.h.
123372         * lib/unilbrk/lbrkprop2.h: New file, renamed from lib/lbrkprop.h with
123373         modifications.
123374         * lib/unilbrk/tables.h: New file, extracted from lib/linebreak.c.
123375         * lib/unilbrk/tables.c: New file, extracted from lib/linebreak.c.
123376         * lib/unilbrk/u8-possible-linebreaks.c: New file, extracted from
123377         lib/linebreak.c.
123378         * lib/unilbrk/u16-possible-linebreaks.c: New file, extracted from
123379         lib/linebreak.c.
123380         * lib/unilbrk/u32-possible-linebreaks.c: New file, extracted from
123381         lib/linebreak.c.
123382         * lib/unilbrk/ulc-common.h: New file, extracted from lib/linebreak.c.
123383         * lib/unilbrk/ulc-common.c: New file, extracted from lib/linebreak.c.
123384         * lib/unilbrk/ulc-possible-linebreaks.c: New file, extracted from
123385         lib/linebreak.c.
123386         * lib/unilbrk/u8-width-linebreaks.c: New file, extracted from
123387         lib/linebreak.c.
123388         * lib/unilbrk/u16-width-linebreaks.c: New file, extracted from
123389         lib/linebreak.c.
123390         * lib/unilbrk/u32-width-linebreaks.c: New file, extracted from
123391         lib/linebreak.c.
123392         * lib/unilbrk/ulc-width-linebreaks.c: New file, extracted from
123393         lib/linebreak.c.
123394         * modules/unilbrk/base: New file.
123395         * modules/unilbrk/tables: New file.
123396         * modules/unilbrk/u8-possible-linebreaks: New file.
123397         * modules/unilbrk/u16-possible-linebreaks: New file.
123398         * modules/unilbrk/u32-possible-linebreaks: New file.
123399         * modules/unilbrk/ulc-common: New file.
123400         * modules/unilbrk/ulc-possible-linebreaks: New file.
123401         * modules/unilbrk/u8-width-linebreaks: New file.
123402         * modules/unilbrk/u16-width-linebreaks: New file.
123403         * modules/unilbrk/u32-width-linebreaks: New file.
123404         * modules/unilbrk/ulc-width-linebreaks: New file.
123405         * lib/linebreak.h: Remove file.
123406         * lib/linebreak.c: Remove file.
123407         * m4/linebreak.m4: Remove file.
123408         * modules/linebreak: Remove file.
123409         * NEWS: Mention the changes.
123411 2008-05-09  Eric Blake  <ebb9@byu.net>
123413         Add xmemdup0.
123414         * lib/xalloc.h (xmemdup0): New prototype and C++ typesafe
123415         implementation.
123416         * lib/xmalloc.c (xmemdup0): New C implementation.
123418 2008-05-08  Bruno Haible  <bruno@clisp.org>
123420         * m4/wctype.m4 (gl_WCTYPE_H): Correct indentation.
123422 2008-05-07  Eric Blake  <ebb9@byu.net>
123424         Support cross-compilation of <wctype.h>.
123425         * m4/wctype.m4 (gl_WCTYPE_H): Fix improper nesting in
123426         AC_CACHE_CHECK.
123428 2008-05-06  Soren Hansen  <soren@ubuntu.com>  (tiny change)
123430         * build-aux/vc-list-files: Add support for bzr.
123432 2008-05-03  Jim Meyering  <meyering@redhat.com>
123434         avoid failed assertion with tight malloc
123435         * tests/test-getndelim2.c: Correct an off-by-one assertion.
123437 2008-05-03  Simon Josefsson  <simon@josefsson.org>
123439         * m4/inet_pton.m4: Set HAVE_DECL_INET_PTON to 0 when declarations
123440         are needed from arpa/inet.h.
123441         * m4/inet_ntop.m4: Likewise, for HAVE_DECL_INET_NTOP.
123442         Reported by Bruno Haible.
123444 2008-05-02  Jim Meyering  <meyering@redhat.com>
123446         avoid compilation error on FreeBSD 6
123447         * tests/test-getaddrinfo.c [!defined EAI_NODATA] (EAI_NODATA): Define.
123449 2008-05-01  Jim Meyering  <meyering@redhat.com>
123451         useless-if-before-free: correct --help's exit status description
123452         * build-aux/useless-if-before-free (usage): Like grep, exit 0
123453         for one or more matches, etc.  Reported by Bruno Haible.
123455         vc-list-files: make the stand-alone gnulib test work
123456         * modules/vc-list-files-tests (configure.ac):
123457         Define and AC_SUBST abs_aux_dir.
123458         (Makefile.am) [TESTS_ENVIRONMENT]: Rather than passing
123459         $(abs_top_srcdir) to each script and having each of them
123460         duplicate the work of setting PATH, set PATH here, using
123461         the new variable, abs_aux_dir instead.
123462         * tests/test-vc-list-files-cvs.sh: Don't set PATH here.
123463         * tests/test-vc-list-files-git.sh: Likewise.
123464         Reported by Bruno Haible.
123466 2008-05-01  Bruno Haible  <bruno@clisp.org>
123468         * lib/getndelim2.c (getndelim2): Fix newsize computation during
123469         reallocation. Rename 'done' to 'found_delimiter'.
123471 2008-05-01  Jim Meyering  <meyering@redhat.com>
123473         vc-list-files: accommodate /bin/sh like the one from Solaris 10
123474         * build-aux/vc-list-files: Use `...`, not $(...).
123476 2008-04-30  Jim Meyering  <meyering@redhat.com>
123478         add tests for vc-list-files
123479         * modules/vc-list-files-tests: New module.
123480         * tests/test-vc-list-files-cvs.sh: New file.
123481         * tests/test-vc-list-files-git.sh: New file.
123483         avoid a warning from gcc
123484         * lib/getndelim2.c (IF_LINT): Define.
123485         (getndelim2): Use it to avoid a "may be used uninitialized" warning.
123487         vc-list-files: work properly with build-aux/cvsu, too
123488         * build-aux/vc-list-files: Hoist the "./"-removing code to apply
123489         to all cvs-based clauses.
123491         vc-list-files: work properly in the CVS+awk case, too
123492         * build-aux/vc-list-files: In the CVS+awk case, remove "./" prefix.
123494         vc-list-files: avoid use of ${*-*} that fails when /bin/sh is dash
123495         * build-aux/vc-list-files: Simplify ${*-*} to $dir, since we no longer
123496         take more than one file argument, so .  Add quotes, just in case $dir
123497         ever contains a shell meta-character.  Prompted by Soren Hansen in
123498         <http://thread.gmane.org/gmane.comp.emulators.libvirt/6221/focus=6240>.
123500 2008-04-29  Eric Blake  <ebb9@byu.net>
123502         Optimize getndelim2 to use block operations when possible.
123503         * modules/getndelim2 (Depends-on): Add stdbool, freadptr,
123504         freadseek, and memchr2.
123505         * lib/getndelim2.c (getndelim2): Use them for block reads.
123507 2008-04-29  Bruno Haible  <bruno@clisp.org>
123509         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_USE_SYSTEM_EXTENSIONS.
123510         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
123511         * modules/inet_ntop (Depends-on): Add extensions.
123512         * modules/inet_pton (Depends-on): Likewise.
123513         Reported by Simon Josefsson.
123515 2008-04-29  Jim Meyering  <meyering@redhat.com>
123517         When the is more than one match in a block, match all of them.
123518         * build-aux/useless-if-before-free: Iterate through each block
123519         until there are no more matches.
123521         Fix broken useless-if-before-free script.
123522         * build-aux/useless-if-before-free: Fix typo: missing "?" after
123523         the expression to match cast of argument to free-like function.
123525 2008-04-29  Eric Blake  <ebb9@byu.net>
123527         Use new header.
123528         * lib/getaddrinfo.c (includes): s/"inet_ntop.h"/<arpa/inet.h>/.
123530 2008-04-29  Jim Meyering  <meyering@redhat.com>
123532         Avoid test segfault on x86_64 due to lack of inet_ntop declaration.
123533         * tests/test-getaddrinfo.c: Include <arpa/inet.h>, now guaranteed
123534         by gnulib to exist and to declare e.g., inet_ntop.
123535         Don't include "inet_ntop.h", now removed.
123537         * m4/arpa_inet_h.m4: Remove trailing blanks.
123539 2008-04-29  Eric Blake  <ebb9@byu.net>
123541         Silence valgrind on safe reads beyond potential array bounds.
123542         * lib/rawmemchr.valgrind: New file.
123543         * lib/strchrnul.valgrind: Likewise.
123544         * modules/rawmemchr (Files): Distribute new file.
123545         * modules/strchrnul (Files): Likewise.
123546         Suggested by Bruno Haible.
123548 2008-04-29  Bruno Haible  <bruno@clisp.org>
123550         * lib/arpa_inet.in.h: Include system's <arpa/inet.h> if it exists.
123551         (inet_ntop, inet_pton): Change portability warning's wording.
123552         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Set HAVE_ARPA_INET_H.
123553         Invoke gl_CHECK_NEXT_HEADERS.
123554         (gl_ARPA_INET_H_DEFAULTS): Initialize ARPA_INET_H.
123555         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_ARPA_INET_H_DEFAULTS and
123556         set ARPA_INET_H.
123557         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
123558         * modules/arpa_inet (Description): No longer only for systems that
123559         lack it.
123560         (Depends-on): Add include_next.
123561         (Makeile.am): Substitute INCLUDE_NEXT, NEXT_ARPA_INET_H,
123562         HAVE_ARPA_INET_H.
123564 2008-04-29  Jim Meyering  <meyering@redhat.com>
123566         * modules/mkdir (License): Re-license as LGPLv2+.
123568 2008-04-29  Bruno Haible  <bruno@clisp.org>
123570         * modules/rawmemchr (Maintainer): Set to Eric.
123571         * modules/strchrnul (Maintainer): Likewise.
123573 2008-04-29  Simon Josefsson  <simon@josefsson.org>
123575         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Set
123576         HAVE_DECL_INET_NTOP and HAVE_DECL_INET_PTON.
123578         * modules/arpa_inet (arpa/inet.h): Use them.
123580 2008-04-28  Eric Blake  <ebb9@byu.net>
123582         Test getndelim2.
123583         * modules/getndelim2-tests: New file.
123584         * tests/test-getndelim2.c: Likewise.
123585         * lib/getndelim2.c (getndelim2): Never return 0.  Lock the
123586         stream.
123587         * m4/getndelim2.m4 (gl_GETNDELIM2): Check for lock functions.
123589         * MODULES.html.sh: Document new module.
123591 2008-04-20  Bruno Haible  <bruno@clisp.org>
123593         * lib/c-stack.c (die): Use raise.
123594         * modules/c-stack (Depends-on): Add raise.
123596 2008-04-28  Bruno Haible  <bruno@clisp.org>
123598         Expect rpmatch to be declared.
123599         * lib/yesno.c (rpmatch): Remove declaration.
123601         Declare rpmatch.
123602         * lib/stdlib.in.h (rpmatch): New declaration.
123603         * lib/rpmatch.c: Include <stdlib.h> first.
123604         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Require AC_USE_SYSTEM_EXTENSIONS and
123605         gl_STDLIB_H_DEFAULTS. Set HAVE_RPMATCH.
123606         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_RPMATCH,
123607         HAVE_RPMATCH.
123608         * modules/rpmatch (Depends-on): Add stdlib, extensions.
123609         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
123610         (Include): Set to <stdlib.h>.
123611         * modules/stdlib (Makefile.am): Substitute GNULIB_RPMATCH and
123612         HAVE_RPMATCH.
123613         * NEWS: Document the change.
123615 2008-04-28  Bruno Haible  <bruno@clisp.org>
123617         Change rpmatch to use nl_langinfo when appropriate.
123618         * lib/rpmatch.c: Include stdbool.h, string.h, langinfo.h.
123619         (N_): New macro.
123620         (localized_pattern): New function/macro.
123621         (try): Remove match, nomatch arguments. Copy the pattern into safe
123622         memory before caching it.
123623         (rpmatch): Use localized_pattern. Add translator comments.
123624         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Test for nl_langinfo and YESEXPR.
123625         Suggested by Eric Blake.
123626         * modules/rpmatch (Depends-on): Add stdbool.
123628 2008-04-28  Eric Blake  <ebb9@byu.net>
123630         Add rawmemchr module, matching glibc.
123631         * modules/string (Makefile.am): New indicator.
123632         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set it.
123633         * lib/string.in.h (rawmemchr): Declare when appropriate.
123634         * modules/rawmemchr: New file.
123635         * m4/rawmemchr.m4: Likewise.
123636         * lib/rawmemchr.c: Likewise.
123637         * modules/rawmemchr-tests: Likewise.
123638         * tests/test-rawmemchr.c: Likewise.
123639         * doc/glibc-functions/rawmemchr.texi (rawmemchr): Document
123640         module.
123641         * modules/strchrnul (Depends-on): Add rawmemchr.
123642         * lib/strchrnul.c (strchrnul): Optimize a corner case.
123644         Whitespace cleanup.
123645         * tests/test-strchrnul.c: Reindent.
123646         * lib/strchrnul.c: Likewise.
123648         Optimize and test strchrnul.
123649         * lib/strchrnul.c (strchrnul): Rewrite to do parallel search.
123650         * modules/strchrnul-tests: New file.
123651         * tests/test-strchrnul.c: Likewise.
123653         Remove intprops dependency.
123654         * modules/memchr (Depends-on): Remove intprops.
123655         * modules/memrchr (Depends-on): Likewise.
123656         * modules/memchr2 (Depends-on): Likewise.
123657         * lib/memchr.c (__memchr): Hand-inline the TYPE_MAXIMUM check.
123658         * lib/memrchr.c (__memrchr): Likewise.
123659         * lib/memrchr2.c (memchr2): Likewise.
123660         Reported by Simon Josefsson.
123662 2008-04-28  Simon Josefsson  <simon@josefsson.org>
123664         * m4/sys_socket_h.m4: Move AC_REQUIRE([AC_C_INLINE]) to top.
123665         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
123667 2008-04-28  Simon Josefsson  <simon@josefsson.org>
123669         * lib/inet_ntop.h, lib/inet_pton.h: Remove files.
123671         * lib/inet_ntop.c: Include arpa/inet.h instead of inet_ntop.h.
123673         * lib/inet_pton.c: Include arpa/inet.h instead of inet_pton.h.
123675         * lib/arpa_inet.in.h [@GNULIB_INET_NTOP@]: Inline inet_ntop.h
123676         declarations.
123677         [@GNULIB_INET_PTON@]: Inline inet_pton.h declarations.
123679         * m4/inet_pton.m4: Don't check for header files.
123681         * m4/inet_ntop.m4: Don't check for header files.
123683 2008-04-28  Simon Josefsson  <simon@josefsson.org>
123685         * m4/sys_socket_h.m4: Require AC_C_INLINE when necessary.
123686         * lib/sys_socket.in.h (setsockopt): Use proper win32 tests (don't
123687         trigger for cygwin).
123688         Reported by Bruno Haible  <bruno@clisp.org>.
123690 2008-04-28  Bruno Haible  <bruno@clisp.org>
123692         * doc/posix-functions/strdup.texi: Mention mingw problem.
123694 2008-04-27  Bruno Haible  <bruno@clisp.org>
123696         * modules/stat-time-tests (Depends-on): Add sleep.
123697         * tests/test-stat-time.c (force_unlink): New function.
123698         (cleanup): Use it.
123699         (test_mtime): Remove the ctime related tests.
123700         (test_ctime): New function, containing the ctime related tests.
123701         (main): Call test_ctime, except on native Windows platforms.
123703 2008-04-27  Bruno Haible  <bruno@clisp.org>
123705         * lib/rpmatch.c (rpmatch): Add some comments.
123706         Reported by James Youngman <jay@gnu.org>.
123708 2008-04-27  Bruno Haible  <bruno@clisp.org>
123710         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Also test the behaviour on
123711         quiet NaNs.
123713 2008-04-27  Bruno Haible  <bruno@clisp.org>
123715         Make test-yesno.sh work on mingw.
123716         * tests/test-yesno.sh: Postprocess the output to convert CR/LF to LF.
123717         * tests/test-yesno.c: Include yesno.h first. Include binary-io.h.
123718         (main): Set stdin to binary mode.
123719         * modules/yesno-tests (Depends-on): Add binary-io.
123721 2008-04-27  Bruno Haible  <bruno@clisp.org>
123723         Fix 'isfinite' on x86, x86_64, ia64 platforms.
123724         * tests/test-isfinite.c (test_isfinitel): Also test the behavior on
123725         argument that lie outside the IEEE 854 domain.
123726         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): New macro.
123727         (gl_ISFINITE): Use it.
123728         * doc/posix-functions/isfinite.texi: Document the fixed bugs.
123730 2008-04-27  Bruno Haible  <bruno@clisp.org>
123732         Allow local renaming in config.h.
123733         * lib/memrchr.c (memrchr): Don't undefine outside libc.
123735 2008-04-27  Bruno Haible  <bruno@clisp.org>
123737         * lib/memchr.c (__memchr): Change type of 'i'.
123738         * lib/memchr2.c (memchr2): Likewise.
123740 2008-04-26  Eric Blake  <ebb9@byu.net>
123741         and Bruno Haible  <bruno@clisp.org>
123743         Optimize and test memrchr.
123744         * modules/memrchr (Depends-on): Add intprops.
123745         * lib/memrchr.c (__memrchr): Avoid false positives in loop.
123746         * modules/memrchr-tests: New file.
123747         * tests/test-memrchr.c: New file.
123749 2008-04-26  Bruno Haible  <bruno@clisp.org>
123751         Add tentative support for DragonFly BSD.
123752         * lib/stdio-impl.h: Add macros for DragonFly BSD.
123753         * lib/fbufmode.c (fbufmode): Update conditionals. Use fp_ instead of
123754         fp.
123755         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
123756         restore_seek_optimization, update_fpos_cache, rpl_fflush: Likewise.
123757         * lib/fpurge.c (fpurge): Likewise.
123758         * lib/freadable.c (freaadable): Likewise.
123759         * lib/freadahead.c (freadahead): Likewise.
123760         * lib/freading.c (freading): Likewise.
123761         * lib/freadptr.c (freadptr): Likewise.
123762         * lib/freadseek.c (freadptrinc): Likewise.
123763         * lib/fseeko.c (fseeko): Likewise.
123764         * lib/fseterr.c (fseterr): Likewise.
123765         * lib/fwritable.c (fwritable): Likewise.
123766         * lib/fwriting.c (fwriting): Likewise.
123768 2008-04-26  Bruno Haible  <bruno@clisp.org>
123770         * lib/stdio-impl.h: New file.
123771         * lib/fbufmode.c: Include stdio-impl.h.
123772         (fbufmode): Use fp_, remove redundant #defines.
123773         * lib/fflush.c: Include stdio-impl.h.
123774         (clear_ungetc_buffer): Remove redundant #defines.
123775         * lib/fpurge.c: Include stdio-impl.h.
123776         (fpurge): Remove redundant #defines.
123777         * lib/freadable.c: Include stdio-impl.h.
123778         (freadable): Remove redundant #defines.
123779         * lib/freadahead.c: Include stdio-impl.h.
123780         (freadahead): Remove redundant #defines.
123781         * lib/freading.c: Include stdio-impl.h.
123782         (freading): Remove redundant #defines.
123783         * lib/freadptr.c: Include stdio-impl.h.
123784         (freadptr): Remove redundant #defines.
123785         * lib/freadseek.c: Include stdio-impl.h.
123786         (freadptrinc): Remove redundant #defines.
123787         * lib/fseeko.c: Include stdio-impl.h.
123788         (rpl_fseeko): Remove redundant #defines.
123789         * lib/fseterr.c: Include stdio-impl.h.
123790         (fseterr): Remove redundant #defines.
123791         * lib/fwritable.c: Include stdio-impl.h.
123792         (fwritable: Remove redundant #defines.
123793         * lib/fwriting.c: Include stdio-impl.h.
123794         (fwriting): Remove redundant #defines.
123795         * modules/fbufmode (Files): Add lib/stdio-impl.h.
123796         * modules/fflush (Files): Likewise.
123797         * modules/fpurge (Files): Likewise.
123798         * modules/freadable (Files): Likewise.
123799         * modules/freadahead (Files): Likewise.
123800         * modules/freading (Files): Likewise.
123801         * modules/freadptr (Files): Likewise.
123802         * modules/freadseek (Files): Likewise.
123803         * modules/fseeko (Files): Likewise.
123804         * modules/fseterr (Files): Likewise.
123805         * modules/fwritable (Files): Likewise.
123806         * modules/fwriting (Files): Likewise.
123808 2008-04-26  Bruno Haible  <bruno@clisp.org>
123810         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
123811         restore_seek_optimization, update_fpos_cache): New functions, extracted
123812         from rpl_fflush.
123813         (rpl_fflush): Use them.
123814         * m4/fflush.m4 (gl_PREREQ_FFLUSH): New macro.
123815         (gl_REPLACE_FFLUSH): Use it.
123817 2008-04-26  Bruno Haible  <bruno@clisp.org>
123819         * tests/test-xstrtol.sh: Work around limitation of an old 'tr' program
123820         on Solaris.
123821         * tests/test-xstrtoimax.sh: Likewise.
123822         * tests/test-xstrtoumax.sh: Likewise.
123823         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
123825 2008-04-26  Bruno Haible  <bruno@clisp.org>
123827         * modules/memchr-tests: New file.
123828         * tests/test-memchr.c; New file, based on tests/test-memchr2.c.
123830 2008-04-26  Eric Blake  <ebb9@byu.net>
123831             Bruno Haible  <bruno@clisp.org>
123833         * lib/memchr.c: Include intprops.h.
123834         (__memchr): Optimize parallel detection of matching bytes. Rename local
123835         variables. Add explanatory comments.
123837 2008-04-26  Bruno Haible  <bruno@clisp.org>
123839         Fix module 'memchr', broken since 2000-10-28.
123840         * lib/memchr.c: Outside glibc, define memchr, not __memchr.
123842 2008-04-26  Bruno Haible  <bruno@clisp.org>
123844         * lib/memchr2.c (memchr2): Rename local variables. Add explanatory
123845         comments.
123847 2008-04-25  Eric Blake  <ebb9@byu.net>
123849         Use native fstatat on cygwin 1.7.0.
123850         * m4/openat.m4 (gl_FUNC_OPENAT): Make sure lstat check is made
123851         first.
123853 2008-04-23  Eric Blake  <ebb9@byu.net>
123855         Improve memchr2 performance.
123856         * lib/memchr2.c (memchr2): Further optimize parallel detection of
123857         NUL bytes.
123858         * modules/memchr2 (Depends-on): Use intprops.h.
123860 2008-04-23  Simon Josefsson  <simon@josefsson.org>
123862         * lib/sys_socket.in.h (setsockopt): Be more type safe by declaring
123863         an inline function instead of a CPP macro.  Patch by Ben Pfaff
123864         <blp@cs.stanford.edu>.
123866 2008-04-23  Simon Josefsson  <simon@josefsson.org>
123868         * lib/arpa_inet.in.h: New file.
123870         * modules/arpa_inet (Files): Add lib/arpa_inet.in.h.
123871         (Makefile.am): Sed in substitute header file.
123873         * m4/arpa_inet_h.m4: Add gl_ARPA_INET_H_DEFAULTS and
123874         gl_ARPA_INET_MODULE_INDICATOR.  Use them.
123876         * modules/inet_ntop (configure.ac): Use
123877         gl_ARPA_INET_MODULE_INDICATOR.
123879         * modules/inet_pton (configure.ac): Use
123880         gl_ARPA_INET_MODULE_INDICATOR.
123882 2008-04-22  Jim Meyering  <meyering@redhat.com>
123884         * modules/verify (License): Re-license as LGPLv2+.
123886 2008-04-22  Simon Josefsson  <simon@josefsson.org>
123888         * lib/sys_socket.in.h: Define setsockopt macro to cast fourth
123889         parameter to void* as per POSIX standard (MinGW uses char*).
123891 2008-04-21  Bruno Haible  <bruno@clisp.org>
123893         * lib/wctype.in.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
123894         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
123895         Define to replacements if REPLACE_ISWCNTRL is 1.
123896         * m4/wctype.m4 (gl_WCTYPE_H): Test whether the isw* functions work.
123897         If not, set WCTYPE_H to nonempty and REPLACE_ISWCNTRL to 1.
123898         * modules/wctype (Makefile.am): Substitute REPLACE_ISWCNTRL.
123899         * doc/posix-functions/iswalnum.texi: Mention the 'wctype' module and
123900         what it fixes.
123901         * doc/posix-functions/iswalpha.texi: Likewise.
123902         * doc/posix-functions/iswblank.texi: Likewise.
123903         * doc/posix-functions/iswcntrl.texi: Likewise.
123904         * doc/posix-functions/iswdigit.texi: Likewise.
123905         * doc/posix-functions/iswgraph.texi: Likewise.
123906         * doc/posix-functions/iswlower.texi: Likewise.
123907         * doc/posix-functions/iswprint.texi: Likewise.
123908         * doc/posix-functions/iswpunct.texi: Likewise.
123909         * doc/posix-functions/iswspace.texi: Likewise.
123910         * doc/posix-functions/iswupper.texi: Likewise.
123911         * doc/posix-functions/iswxdigit.texi: Likewise.
123912         Reported by Alain Guibert.
123914 2008-04-21  Bruno Haible  <bruno@clisp.org>
123916         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Fix typo in last commit.
123917         Patch by Alain Guibert.
123919 2008-04-21  Bruno Haible  <bruno@clisp.org>
123921         Fix test failures on mingw.
123922         * tests/test-xstrtol.c (print_no_progname): New function.
123923         (main): Install it in error_print_progname hook.
123924         * tests/test-xstrtol.sh: Convert CR/LF to NL in output.
123925         * tests/test-xstrtoimax.sh: Likewise.
123926         * tests/test-xstrtoumax.sh: Likewise.
123928 2008-04-21  Bruno Haible  <bruno@clisp.org>
123930         Fix test failure on mingw.
123931         * tests/test-argp-2.sh (func_compare): Remove CRs from sed's output.
123933 2008-04-21  Bruno Haible  <bruno@clisp.org>
123935         * lib/localename.c (SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN):
123936         Actually assign a value.
123938 2008-04-20  Bruno Haible  <bruno@clisp.org>
123940         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl',
123941         take 2.
123942         * lib/canonicalize.c (canonicalize_file_name): Elide if the
123943         'canonicalize-lgpl' module is also used.
123944         * lib/canonicalize-lgpl.c: Undo last change.
123945         * modules/canonicalize-lgpl (configure.ac): Invoke gl_MODULE_INDICATOR.
123947 2008-04-20  Bruno Haible  <bruno@clisp.org>
123949         * lib/mkdir.c (mkdir): Undefine after the includes, not right after
123950         config.h. Provide _mkdir based fallback for mingw.
123951         * lib/sys_stat.in.h (mkdir): Define through an 'extern' declaration
123952         if REPLACE_MKDIR is 1. Otherwise, test for mingw directly.
123953         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Require
123954         gl_SYS_STAT_H_DEFAULTS. When doing the replacement, set REPLACE_MKDIR
123955         rather than defining mkdir in config.h.
123956         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): New macro.
123957         (gl_SYS_STAT_H_DEFAULTS): New macro.
123958         (gl_HEADER_SYS_STAT_H): Require it. Don't set HAVE_DECL_MKDIR and
123959         HAVE_IO_H any more.
123960         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKDIR instead of
123961         HAVE_DECL_MKDIR and HAVE_IO_H.
123963 2008-04-20  Bruno Haible  <bruno@clisp.org>
123965         * lib/isapipe.c: Port to native Windows platforms.
123967 2008-04-20  Bruno Haible  <bruno@clisp.org>
123969         * lib/gc-gnulib.c: Include <windows.h> before <wincrypt.h>.
123971 2008-04-21  Eric Blake  <ebb9@byu.net>
123973         Work around preprocessors that don't handle UINTMAX_MAX.
123974         * lib/memchr2.c (memchr2): Avoid embedded #if.
123975         Reported by Alain Guibert, fix suggested by Bruno Haible.
123977 2008-04-21  Simon Josefsson  <simon@josefsson.org>
123979         * doc/posix-functions/strftime.texi (strftime): Explain better
123980         Windows incompatibility.  Suggested by Micah Cowan
123981         <micah@cowan.name>.
123983 2008-04-20  Bruno Haible  <bruno@clisp.org>
123985         * modules/uniconv/u32-conv-to-enc (Depends-on): Add unistr/u32-mblen,
123986         unistr/u8-mblen.
123988 2008-04-20  Bruno Haible  <bruno@clisp.org>
123990         Fix test failure on platforms with non-GNU iconv.
123991         * lib/uniconv/u16-conv-to-enc.c (u16_to_u8_lenient): New function.
123992         (U_TO_U8): Use it, rather than u16_to_u8.
123993         * lib/uniconv/u-conv-to-enc.h (FUNC): Allow an incomplete sequence of
123994         units at the end of the input string.
123995         * modules/uniconv/u16-conv-to-enc (Depends-on): Update.
123997 2008-04-20  Bruno Haible  <bruno@clisp.org>
123999         * tests/uniconv/test-u8-conv-to-enc.c (main): Accept result == NULL
124000         when the resulting length is 0.
124001         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
124003 2008-04-20  Bruno Haible  <bruno@clisp.org>
124005         * m4/roundf.m4 (gl_FUNC_ROUNDF): Add test whether roundf actually
124006         works.
124007         * doc/posix-functions/roundf.texi: Mention roundf bug on mingw.
124009 2008-04-20  Bruno Haible  <bruno@clisp.org>
124011         * tests/test-tsearch.c (main): Don't use initstate if it is missing.
124012         * modules/tsearch-tests (configure.ac): Test for initstate function.
124014 2008-04-20  Bruno Haible  <bruno@clisp.org>
124016         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Also provided a substitute
124017         for nlink_t if missing.
124018         * tests/test-sys_stat.c: Check the existence of the nlink_t type.
124020 2008-04-19  Bruno Haible  <bruno@clisp.org>
124022         Work around snprintf bug on Linux libc5.
124023         * m4/printf.m4 (gl_SNPRINTF_SIZE1): New macro.
124024         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
124025         gl_SNPRINTF_SIZE1.
124026         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
124027         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Likewise. Replace snprintf if
124028         that test failed.
124029         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Likewise.
124030         * lib/vasnprintf.c (USE_SNPRINTF): Set to 0 on Linux libc5 systems.
124031         * modules/snprintf (Files): Add m4/printf.m4.
124032         * modules/vsnprintf (Files): Likewise.
124033         * doc/posix-functions/snprintf.texi: Document Linux libc5 problem.
124034         * doc/posix-functions/vsnprintf.texi: Likewise.
124036 2008-04-19  Bruno Haible  <bruno@clisp.org>
124038         * lib/vasnprintf.c (floorlog10l, floorlog10): Reduce maximum error
124039         from 0.0058 to less than 10^-7.
124041 2008-04-19  Bruno Haible  <bruno@clisp.org>
124043         Fix rounding when a precision is given.
124044         * lib/vasnprintf.c (is_borderline): New function.
124045         (VASNPRINTF): For %e and %g, consider replacing the digits 10....0 with
124046         9...9x.
124047         * tests/test-vasnprintf-posix.c (test_function): Test rounding with %f,
124048         %e, %g.
124049         * tests/test-vasprintf-posix.c (test_function): Likewise.
124050         * tests/test-snprintf-posix.h (test_function): Likewise.
124051         * tests/test-sprintf-posix.h (test_function): Likewise.
124052         * tests/test-fprintf-posix.h (test_function): Test rounding with %f.
124053         * tests/test-printf-posix.h (test_function): Likewise.
124054         * tests/test-printf-posix.output: Update.
124055         Reported by John Darrington <john@darrington.wattle.id.au> via
124056         Ben Pfaff <blp@cs.stanford.edu>.
124058 2008-04-18  Simon Josefsson  <simon@josefsson.org>
124060         * doc/posix-functions/strftime.texi (strftime): Clarify platform.
124061         Suggested by Bruno Haible <bruno@clisp.org>.
124063 2008-04-17  Bruno Haible  <bruno@clisp.org>
124065         * lib/lock.h (gl_lock_destroy, gl_rwlock_destroy,
124066         gl_recursive_lock_destroy): Provide no-op definitions for the dummy
124067         implementation.
124068         Patch by Bruce Merry <bmerry@gmail.com>.
124070 2008-04-17  Simon Josefsson  <simon@josefsson.org>
124072         * doc/posix-functions/strftime.texi (strftime): Mention that %e
124073         doesn't work under Windows.
124075 2008-04-16  Bruno Haible  <bruno@clisp.org>
124077         * lib/localename.c (LANG_MAORI, LANG_QUECHUA, LANG_SOTHO, LANG_UIGHUR):
124078         New macros.
124079         (SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_LATIN,
124080         SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_CYRILLIC,
124081         SUBLANG_CROATIAN_CROATIA, SUBLANG_CROATIAN_BOSNIA_HERZEGOVINA_LATIN,
124082         SUBLANG_MONGOLIAN_CYRILLIC_MONGOLIA, SUBLANG_MONGOLIAN_PRC,
124083         SUBLANG_QUECHUA_BOLIVIA, SUBLANG_QUECHUA_ECUADOR, SUBLANG_QUECHUA_PERU,
124084         SUBLANG_RUSSIAN_RUSSIA, SUBLANG_RUSSIAN_MOLDAVIA, SUBLANG_SPANISH_US,
124085         SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN, SUBLANG_UIGHUR_PRC): New
124086         macros.
124087         (gl_locale_name_from_win32_LANGID): Refine code for Croatian/Bosnian,
124088         Mongolian, Russian, Spanish, Tibetan. Add code for Maori, Quechua,
124089         Northern Sotho, Uighur.
124091 2008-04-16  Bruno Haible  <bruno@clisp.org>
124093         * lib/localename.c (SUBLANG_SINDHI_INDIA): New macro.
124094         (SUBLANG_SINDHI_PAKISTAN): Change value from 1 to 2.
124095         (gl_locale_name_from_win32_LANGID): Fix code for Sindhi.
124096         Reported by Daniel Bergström <daniel@octocode.com>.
124098 2007-12-25  KJK::Hyperion  <hackbunny@reactos.com>
124099             Bruno Haible  <bruno@clisp.org>
124101         * lib/localename.c (gl_locale_name_canonicalize) [WIN32_NATIVE]: New
124102         function.
124103         (gl_locale_name_from_win32_LANGID, gl_locale_name_from_win32_LCID):
124104         New functions, mostly extracted from gl_locale_name_default.
124105         (gl_locale_name_default): Use gl_locale_name_from_win32_LCID.
124107 2008-04-16  Eric Blake  <ebb9@byu.net>
124109         Adjust strtod detection to catch glibc 2.7 bug.
124110         * m4/strtod.m4 (gl_FUNC_STRTOD): Test "nan()" behavior.
124111         Reported by John Gatewood Ham.
124113 2008-04-16  Bruno Haible  <bruno@clisp.org>
124115         Add tentative support for Linux libc5.
124116         * lib/fbufmode.c (fbufmode) [__GNU_LIBRARY__==1]: Reuse glibc2 code.
124117         * lib/fpurge.c (fpurge): Likewise.
124118         * lib/freadable.c (freadable): Likewise.
124119         * lib/freadahead.c (freadahead): Likewise.
124120         * lib/freading.c (freading): Likewise.
124121         * lib/freadptr.c (freadptr): Likewise.
124122         * lib/freadseek.c (freadptrinc): Likewise.
124123         * lib/fseeko.c (rpl_fseeko): Likewise.
124124         * lib/fseterr.c (fseterr): Likewise.
124125         * lib/fwritable.c (fwritable): Likewise.
124126         * lib/fwriting.c (fwriting): Likewise.
124127         Reported by Alain Guibert <alguibert+bts@free.fr>.
124129 2008-04-15  Bruno Haible  <bruno@clisp.org>
124131         * modules/mathl (configure.ac): Define module indicator.
124133 2008-04-15  Bruno Haible  <bruno@clisp.org>
124135         * lib/logl.c (logl): Remove unused variables.
124137 2008-04-15  Bruno Haible  <bruno@clisp.org>
124139         * lib/uniconv/u-conv-to-enc.h (FUNC): Fix return value when U_TO_U8
124140         fails.
124142 2008-04-15  Bruno Haible  <bruno@clisp.org>
124144         * lib/trim.c (trim2): Fix argument of isspace() macro.
124146 2008-04-15  Paolo Bonzini  <bonzini@gnu.org>
124148         * lib/tanl.c (kernel_tanl): Rename flag to invert, initialize it
124149         to 0.
124150         * lib/trigl.c (ieee754_rem_pio2l): Fix range checks.
124152 2008-04-14  Bruno Haible  <bruno@clisp.org>
124154         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Fix underquoting of
124155         AC_LANG_PROGRAM argument.
124156         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Likewise.
124157         * m4/gethrxtime.m4 (gl_ARITHMETIC_HRTIME_T): Likewise.
124158         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
124159         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
124160         * m4/math_h.m4 (gl_MATH_H): Likewise.
124161         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
124162         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
124163         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
124164         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Likewise.
124165         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
124166         * m4/regex.m4 (gl_REGEX): Likewise.
124167         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Likewise.
124168         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET): Likewise.
124169         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
124170         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Likewise.
124171         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
124172         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
124173         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
124174         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
124176 2008-04-14  Jim Meyering  <meyering@redhat.com>
124178         test-strtod: fix typos: s/abs/fabs/
124179         * tests/test-strtod.c (main): Use fabs, not narrowing-to-int "abs".
124181 2008-04-13  Bruno Haible  <bruno@clisp.org>
124183         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl'.
124184         * lib/canonicalize-lgpl.c: Elide the contents if the 'canonicalize'
124185         module is also used and while not building the reloc-wrapper.
124187 2008-04-13  Bruno Haible  <bruno@clisp.org>
124189         * tests/test-getaddrinfo.c (simple): Ignore EAI_NODATA error.
124191 2008-04-13  Bruno Haible  <bruno@clisp.org>
124193         Fix AIX compilation failure introduced on 2008-04-02.
124194         * tests/test-frexp.c (exp): Undefine before redefining.
124195         * tests/test-frexpl.c (exp): Likewise.
124197 2008-04-13  Bruno Haible  <bruno@clisp.org>
124199         Work around a HP-UX stdio bug.
124200         * tests/test-ftell.c (main): Disable the fseek/ftell test on HP-UX.
124201         * tests/test-ftello.c (main): Likewise.
124202         * doc/posix-functions/ftell.texi: Mention HP-UX bug.
124203         * doc/posix-functions/ftello.texi: Likewise.
124205 2008-04-13  Bruno Haible  <bruno@clisp.org>
124207         Make test-signbit pass on HP-UX/hppa.
124208         * tests/test-signbit.c (minus_zerol): New variable.
124209         (test_signbitl): Use it.
124211 2008-04-13  Bruno Haible  <bruno@clisp.org>
124213         Make truncl work on OSF/1 4.0.
124214         * m4/truncl.m4 (gl_FUNC_TRUNCL): Test whether truncl actually works.
124215         Set REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
124216         * lib/math.in.h (truncl): Test REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
124217         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNCL, not
124218         HAVE_DECL_TRUNCL.
124219         * modules/math (Makefile.am): Substitute REPLACE_TRUNCL, not
124220         HAVE_DECL_TRUNCL.
124221         * doc/posix-functions/truncl.texi: Document the OSF/1 4.0 problem.
124223 2008-04-13  Bruno Haible  <bruno@clisp.org>
124225         * lib/unictype.h: Remove trailing comma from enumeration definitions.
124227 2008-04-13  Bruno Haible  <bruno@clisp.org>
124229         * lib/count-one-bits.h (COUNT_ONE_BITS): Rewrite verification
124230         expression, so as to avoid HP-UX 11 cc compiler bug.
124232 2008-04-13  Bruno Haible  <bruno@clisp.org>
124234         * m4/regex.m4 (gl_PREREQ_REGEX): Also check for <libintl.h>.
124236 2008-04-13  Bruno Haible  <bruno@clisp.org>
124238         * lib/git-merge-changelog.c: Remove empty declaration outside of
124239         functions.
124241 2008-04-13  Bruno Haible  <bruno@clisp.org>
124243         * modules/quotearg-tests (Makefile.am): Define test_quotearg_LDADD.
124245 2008-04-13  Bruno Haible  <bruno@clisp.org>
124247         * doc/posix-headers/sys_socket.texi: Document the problem on EMX.
124248         * lib/sys_socket.in.h (SHUT_RD, SHUT_WR, SHUT_RDWR): Define if missing.
124249         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Replace <sys/socket.h>
124250         also if it exists but lacks definitions of the SHUT_* macros.
124251         * modules/sys_socket (Description): Update.
124252         Reported by Elbert Pol <e.pol@chello.nl>.
124254 2008-04-13  Bruno Haible  <bruno@clisp.org>
124256         * lib/localcharset.c (OS2): Don't redefine if already defined.
124257         Reported by Elbert Pol <e.pol@chello.nl>.
124259 2008-04-13  Bruno Haible  <bruno@clisp.org>
124261         * lib/binary-io.h [__EMX__]: Include <io.h>.
124262         Reported by Elbert Pol <e.pol@chello.nl>.
124264 2008-04-12  Bruno Haible  <bruno@clisp.org>
124266         * lib/fpucw.h: Enable the definitions also for x86_64.
124267         Needed for NetBSD/x86_64.
124268         Reported by Thomas Klausner <tk@giga.or.at>.
124270 2008-04-12  Bruno Haible  <bruno@clisp.org>
124272         * tests/test-strtod.c: Include isnand.h.
124273         (main): Use isnand instead of isnan.
124274         Reported by Jim Meyering.
124276 2008-04-12  Bruno Haible  <bruno@clisp.org>
124278         * m4/isnanf.m4 (gl_ISNANF_WORKS): Add a test for a special NaN.
124279         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
124281 2008-04-12  Jim Meyering  <meyering@redhat.com>
124283         * m4/math_h.m4 (gl_MATH_H): Fix typos.
124285 2008-04-12  Bruno Haible  <bruno@clisp.org>
124287         * lib/freadptr.c (freadptr) [__EMX__]: Fix wrong assertion.
124288         Reported by Elbert Pol <e.pol@chello.nl>.
124290 2008-04-12  Eric Blake  <ebb9@byu.net>
124292         Work around Solaris 10 math.h bug.
124293         * m4/math_h.m4 (gl_MATH_H): Check for bug.
124294         (gl_MATH_H_DEFAULTS): Set up default.
124295         * modules/math (Makefile.am): Replace new indicators.
124296         * lib/math.in.h (NAN, HUGE_VAL): Provide replacements.
124297         * tests/test-math.c (main): Test this.
124298         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't rely on HUGE_VAL.
124299         * doc/posix-headers/math.texi (math.h): Mention bug.
124300         Reported by Nelson H. F. Beebe and Jim Meyering.
124302 2008-04-11  Bruno Haible  <bruno@clisp.org>
124304         Adapt to future versions of Apple GCC.
124305         * lib/argp-fmtstream.h (ARGP_FS_EI): Don't test __GNUC_GNU_INLINE__.
124306         Reported by Peter O'Gorman <peter@pogma.com>.
124308 2008-04-11  Bruno Haible  <bruno@clisp.org>
124310         * tests/test-getaddrinfo.c (simple): Ignore EAI_NONAME error.
124312 2008-04-11  Bruno Haible  <bruno@clisp.org>
124314         * modules/strsignal-tests (Makefile.am): Define test_strsignal_LDADD.
124316         * modules/getaddrinfo-tests (Makefile.am): Define
124317         test_getaddrinfo_LDADD.
124319 2008-04-11  Bruno Haible  <bruno@clisp.org>
124321         * lib/strsignal.c (_sys_siglist): Don't declare if already declared.
124322         (init): Fix syntax error.
124323         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Check whether _sys_siglist
124324         is declared.
124326 2008-04-11  Bruno Haible  <bruno@clisp.org>
124328         * lib/glob.c: Include <stdbool.h>. Needed at least with IRIX cc.
124329         * modules/glob (Depends-on): Add stdbool.
124331 2008-04-11  Bruno Haible  <bruno@clisp.org>
124333         * lib/trim.c: Include <string.h>.
124335 2008-04-11  Eric Blake  <ebb9@byu.net>
124337         Avoid compile failure on OS/2.
124338         * lib/regex_internal.h (internal_function): Disable optimization
124339         on OS/2 (__EMX__), where it caused compiler error.
124340         Reported by Elbert Pol.
124342 2008-04-11  Bruno Haible  <bruno@clisp.org>
124344         Flush the standard error stream before aborting. Needed on mingw.
124345         * tests/test-argmatch.c (ASSERT): Call fflush(stderr) before abort().
124346         * tests/test-array_list.c (ASSERT): Likewise.
124347         * tests/test-array_oset.c (ASSERT): Likewise.
124348         * tests/test-avltree_list.c (ASSERT): Likewise.
124349         * tests/test-avltree_oset.c (ASSERT): Likewise.
124350         * tests/test-avltreehash_list.c (ASSERT): Likewise.
124351         * tests/test-binary-io.c (ASSERT): Likewise.
124352         * tests/test-byteswap.c (ASSERT): Likewise.
124353         * tests/test-c-ctype.c (ASSERT): Likewise.
124354         * tests/test-c-strcasecmp.c (ASSERT): Likewise.
124355         * tests/test-c-strcasestr.c (ASSERT): Likewise.
124356         * tests/test-c-strncasecmp.c (ASSERT): Likewise.
124357         * tests/test-c-strstr.c (ASSERT): Likewise.
124358         * tests/test-canonicalize-lgpl.c (ASSERT): Likewise.
124359         * tests/test-canonicalize.c (ASSERT): Likewise.
124360         * tests/test-carray_list.c (ASSERT): Likewise.
124361         * tests/test-ceilf1.c (ASSERT): Likewise.
124362         * tests/test-ceilf2.c (ASSERT): Likewise.
124363         * tests/test-ceill.c (ASSERT): Likewise.
124364         * tests/test-count-one-bits.c (ASSERT): Likewise.
124365         * tests/test-fbufmode.c (ASSERT): Likewise.
124366         * tests/test-fflush2.c (ASSERT): Likewise.
124367         * tests/test-floorf1.c (ASSERT): Likewise.
124368         * tests/test-floorf2.c (ASSERT): Likewise.
124369         * tests/test-floorl.c (ASSERT): Likewise.
124370         * tests/test-fopen.c (ASSERT): Likewise.
124371         * tests/test-fpending.c (ASSERT): Likewise.
124372         * tests/test-fprintf-posix.c (ASSERT): Likewise.
124373         * tests/test-fpurge.c (ASSERT): Likewise.
124374         * tests/test-freadable.c (ASSERT): Likewise.
124375         * tests/test-freadahead.c (ASSERT): Likewise.
124376         * tests/test-freading.c (ASSERT): Likewise.
124377         * tests/test-freadptr.c (ASSERT): Likewise.
124378         * tests/test-freadptr2.c (ASSERT): Likewise.
124379         * tests/test-freadseek.c (ASSERT): Likewise.
124380         * tests/test-freopen.c (ASSERT): Likewise.
124381         * tests/test-frexp.c (ASSERT): Likewise.
124382         * tests/test-frexpl.c (ASSERT): Likewise.
124383         * tests/test-fseek.c (ASSERT): Likewise.
124384         * tests/test-fseeko.c (ASSERT): Likewise.
124385         * tests/test-fstrcmp.c (ASSERT): Likewise.
124386         * tests/test-ftell.c (ASSERT): Likewise.
124387         * tests/test-ftello.c (ASSERT): Likewise.
124388         * tests/test-func.c (ASSERT): Likewise.
124389         * tests/test-fwritable.c (ASSERT): Likewise.
124390         * tests/test-fwriting.c (ASSERT): Likewise.
124391         * tests/test-getdelim.c (ASSERT): Likewise.
124392         * tests/test-getline.c (ASSERT): Likewise.
124393         * tests/test-i-ring.c (ASSERT): Likewise.
124394         * tests/test-iconv-utf.c (ASSERT): Likewise.
124395         * tests/test-iconv.c (ASSERT): Likewise.
124396         * tests/test-isfinite.c (ASSERT): Likewise.
124397         * tests/test-isnand.c (ASSERT): Likewise.
124398         * tests/test-isnanf.c (ASSERT): Likewise.
124399         * tests/test-isnanl.h (ASSERT): Likewise.
124400         * tests/test-ldexpl.c (ASSERT): Likewise.
124401         * tests/test-linked_list.c (ASSERT): Likewise.
124402         * tests/test-linkedhash_list.c (ASSERT): Likewise.
124403         * tests/test-localename.c (ASSERT): Likewise.
124404         * tests/test-lseek.c (ASSERT): Likewise.
124405         * tests/test-mbscasecmp.c (ASSERT): Likewise.
124406         * tests/test-mbscasestr1.c (ASSERT): Likewise.
124407         * tests/test-mbscasestr2.c (ASSERT): Likewise.
124408         * tests/test-mbscasestr3.c (ASSERT): Likewise.
124409         * tests/test-mbscasestr4.c (ASSERT): Likewise.
124410         * tests/test-mbschr.c (ASSERT): Likewise.
124411         * tests/test-mbscspn.c (ASSERT): Likewise.
124412         * tests/test-mbsncasecmp.c (ASSERT): Likewise.
124413         * tests/test-mbspbrk.c (ASSERT): Likewise.
124414         * tests/test-mbspcasecmp.c (ASSERT): Likewise.
124415         * tests/test-mbsrchr.c (ASSERT): Likewise.
124416         * tests/test-mbsspn.c (ASSERT): Likewise.
124417         * tests/test-mbsstr1.c (ASSERT): Likewise.
124418         * tests/test-mbsstr2.c (ASSERT): Likewise.
124419         * tests/test-mbsstr3.c (ASSERT): Likewise.
124420         * tests/test-memchr2.c (ASSERT): Likewise.
124421         * tests/test-memmem.c (ASSERT): Likewise.
124422         * tests/test-open.c (ASSERT): Likewise.
124423         * tests/test-printf-frexp.c (ASSERT): Likewise.
124424         * tests/test-printf-frexpl.c (ASSERT): Likewise.
124425         * tests/test-printf-posix.c (ASSERT): Likewise.
124426         * tests/test-quotearg.c (ASSERT): Likewise.
124427         * tests/test-rbtree_list.c (ASSERT): Likewise.
124428         * tests/test-rbtree_oset.c (ASSERT): Likewise.
124429         * tests/test-rbtreehash_list.c (ASSERT): Likewise.
124430         * tests/test-round1.c (ASSERT): Likewise.
124431         * tests/test-roundf1.c (ASSERT): Likewise.
124432         * tests/test-roundl.c (ASSERT): Likewise.
124433         * tests/test-signbit.c (ASSERT): Likewise.
124434         * tests/test-sleep.c (ASSERT): Likewise.
124435         * tests/test-snprintf-posix.c (ASSERT): Likewise.
124436         * tests/test-snprintf.c (ASSERT): Likewise.
124437         * tests/test-sprintf-posix.c (ASSERT): Likewise.
124438         * tests/test-stat-time.c (ASSERT): Likewise.
124439         * tests/test-strcasestr.c (ASSERT): Likewise.
124440         * tests/test-strerror.c (ASSERT): Likewise.
124441         * tests/test-striconv.c (ASSERT): Likewise.
124442         * tests/test-striconveh.c (ASSERT): Likewise.
124443         * tests/test-striconveha.c (ASSERT): Likewise.
124444         * tests/test-strsignal.c (ASSERT): Likewise.
124445         * tests/test-strstr.c (ASSERT): Likewise.
124446         * tests/test-strtod.c (ASSERT): Likewise.
124447         * tests/test-trunc1.c (ASSERT): Likewise.
124448         * tests/test-trunc2.c (ASSERT): Likewise.
124449         * tests/test-truncf1.c (ASSERT): Likewise.
124450         * tests/test-truncf2.c (ASSERT): Likewise.
124451         * tests/test-truncl.c (ASSERT): Likewise.
124452         * tests/test-vasnprintf-posix.c (ASSERT): Likewise.
124453         * tests/test-vasnprintf-posix2.c (ASSERT): Likewise.
124454         * tests/test-vasnprintf.c (ASSERT): Likewise.
124455         * tests/test-vasprintf-posix.c (ASSERT): Likewise.
124456         * tests/test-vasprintf.c (ASSERT): Likewise.
124457         * tests/test-vfprintf-posix.c (ASSERT): Likewise.
124458         * tests/test-vprintf-posix.c (ASSERT): Likewise.
124459         * tests/test-vsnprintf-posix.c (ASSERT): Likewise.
124460         * tests/test-vsnprintf.c (ASSERT): Likewise.
124461         * tests/test-vsprintf-posix.c (ASSERT): Likewise.
124462         * tests/test-wcwidth.c (ASSERT): Likewise.
124463         * tests/test-xfprintf-posix.c (ASSERT): Likewise.
124464         * tests/test-xprintf-posix.c (ASSERT): Likewise.
124465         * tests/test-xvasprintf.c (ASSERT): Likewise.
124466         * tests/uniconv/test-u16-conv-from-enc.c (ASSERT): Likewise.
124467         * tests/uniconv/test-u16-conv-to-enc.c (ASSERT): Likewise.
124468         * tests/uniconv/test-u16-strconv-from-enc.c (ASSERT): Likewise.
124469         * tests/uniconv/test-u16-strconv-to-enc.c (ASSERT): Likewise.
124470         * tests/uniconv/test-u32-conv-from-enc.c (ASSERT): Likewise.
124471         * tests/uniconv/test-u32-conv-to-enc.c (ASSERT): Likewise.
124472         * tests/uniconv/test-u32-strconv-from-enc.c (ASSERT): Likewise.
124473         * tests/uniconv/test-u32-strconv-to-enc.c (ASSERT): Likewise.
124474         * tests/uniconv/test-u8-conv-from-enc.c (ASSERT): Likewise.
124475         * tests/uniconv/test-u8-conv-to-enc.c (ASSERT): Likewise.
124476         * tests/uniconv/test-u8-strconv-from-enc.c (ASSERT): Likewise.
124477         * tests/uniconv/test-u8-strconv-to-enc.c (ASSERT): Likewise.
124478         * tests/unictype/test-bidi_byname.c (ASSERT): Likewise.
124479         * tests/unictype/test-bidi_name.c (ASSERT): Likewise.
124480         * tests/unictype/test-bidi_of.c (ASSERT): Likewise.
124481         * tests/unictype/test-bidi_test.c (ASSERT): Likewise.
124482         * tests/unictype/test-block_list.c (ASSERT): Likewise.
124483         * tests/unictype/test-block_of.c (ASSERT): Likewise.
124484         * tests/unictype/test-block_test.c (ASSERT): Likewise.
124485         * tests/unictype/test-categ_and.c (ASSERT): Likewise.
124486         * tests/unictype/test-categ_and_not.c (ASSERT): Likewise.
124487         * tests/unictype/test-categ_byname.c (ASSERT): Likewise.
124488         * tests/unictype/test-categ_name.c (ASSERT): Likewise.
124489         * tests/unictype/test-categ_none.c (ASSERT): Likewise.
124490         * tests/unictype/test-categ_of.c (ASSERT): Likewise.
124491         * tests/unictype/test-categ_or.c (ASSERT): Likewise.
124492         * tests/unictype/test-categ_test_withtable.c (ASSERT): Likewise.
124493         * tests/unictype/test-combining.c (ASSERT): Likewise.
124494         * tests/unictype/test-decdigit.c (ASSERT): Likewise.
124495         * tests/unictype/test-digit.c (ASSERT): Likewise.
124496         * tests/unictype/test-mirror.c (ASSERT): Likewise.
124497         * tests/unictype/test-numeric.c (ASSERT): Likewise.
124498         * tests/unictype/test-pr_byname.c (ASSERT): Likewise.
124499         * tests/unictype/test-pr_test.c (ASSERT): Likewise.
124500         * tests/unictype/test-predicate-part1.h (ASSERT): Likewise.
124501         * tests/unictype/test-scripts.c (ASSERT): Likewise.
124502         * tests/unictype/test-sy_c_ident.c (ASSERT): Likewise.
124503         * tests/unictype/test-sy_java_ident.c (ASSERT): Likewise.
124504         * tests/unistdio/test-u16-asnprintf1.c (ASSERT): Likewise.
124505         * tests/unistdio/test-u16-vasnprintf1.c (ASSERT): Likewise.
124506         * tests/unistdio/test-u16-vasnprintf2.c (ASSERT): Likewise.
124507         * tests/unistdio/test-u16-vasnprintf3.c (ASSERT): Likewise.
124508         * tests/unistdio/test-u16-vasprintf1.c (ASSERT): Likewise.
124509         * tests/unistdio/test-u16-vsnprintf1.c (ASSERT): Likewise.
124510         * tests/unistdio/test-u16-vsprintf1.c (ASSERT): Likewise.
124511         * tests/unistdio/test-u32-asnprintf1.c (ASSERT): Likewise.
124512         * tests/unistdio/test-u32-vasnprintf1.c (ASSERT): Likewise.
124513         * tests/unistdio/test-u32-vasnprintf2.c (ASSERT): Likewise.
124514         * tests/unistdio/test-u32-vasnprintf3.c (ASSERT): Likewise.
124515         * tests/unistdio/test-u32-vasprintf1.c (ASSERT): Likewise.
124516         * tests/unistdio/test-u32-vsnprintf1.c (ASSERT): Likewise.
124517         * tests/unistdio/test-u32-vsprintf1.c (ASSERT): Likewise.
124518         * tests/unistdio/test-u8-asnprintf1.c (ASSERT): Likewise.
124519         * tests/unistdio/test-u8-vasnprintf1.c (ASSERT): Likewise.
124520         * tests/unistdio/test-u8-vasnprintf2.c (ASSERT): Likewise.
124521         * tests/unistdio/test-u8-vasnprintf3.c (ASSERT): Likewise.
124522         * tests/unistdio/test-u8-vasprintf1.c (ASSERT): Likewise.
124523         * tests/unistdio/test-u8-vsnprintf1.c (ASSERT): Likewise.
124524         * tests/unistdio/test-u8-vsprintf1.c (ASSERT): Likewise.
124525         * tests/unistdio/test-ulc-asnprintf1.c (ASSERT): Likewise.
124526         * tests/unistdio/test-ulc-vasnprintf1.c (ASSERT): Likewise.
124527         * tests/unistdio/test-ulc-vasnprintf2.c (ASSERT): Likewise.
124528         * tests/unistdio/test-ulc-vasnprintf3.c (ASSERT): Likewise.
124529         * tests/unistdio/test-ulc-vasprintf1.c (ASSERT): Likewise.
124530         * tests/unistdio/test-ulc-vsnprintf1.c (ASSERT): Likewise.
124531         * tests/unistdio/test-ulc-vsprintf1.c (ASSERT): Likewise.
124532         * tests/uniwidth/test-u16-strwidth.c (ASSERT): Likewise.
124533         * tests/uniwidth/test-u16-width.c (ASSERT): Likewise.
124534         * tests/uniwidth/test-u32-strwidth.c (ASSERT): Likewise.
124535         * tests/uniwidth/test-u32-width.c (ASSERT): Likewise.
124536         * tests/uniwidth/test-u8-strwidth.c (ASSERT): Likewise.
124537         * tests/uniwidth/test-u8-width.c (ASSERT): Likewise.
124538         * tests/uniwidth/test-uc_width.c (ASSERT): Likewise.
124539         Reported by Eric Blake.
124541 2008-04-11  Bruno Haible  <bruno@clisp.org>
124543         * lib/wchar.in.h: Tweak comment.
124545 2008-04-11  Bruno Haible  <bruno@clisp.org>
124547         Fix __GNUC_STDC_INLINE__ predefine with Apple GCC on MacOS X 10.5.
124548         * gnulib-tool (func_emit_initmacro_start): Emit an invocation of
124549         gl_COMMON.
124550         * m4/gnulib-common.m4 (gl_COMMON, gl_COMMON_BODY): New macros.
124552 2008-04-11  Bruno Haible  <bruno@clisp.org>
124554         * modules/git-merge-changelog (git_merge_changelog_LDADD): Add LIBINTL.
124556 2008-04-11  Simon Josefsson  <simon@josefsson.org>
124558         * lib/gc-gnulib.c: On Windows, use CryptGenRandom from CSP instead
124559         of attempting to use nonexistent /dev/*random.  Based on patch
124560         from Adam Strzelecki <ono@java.pl> in
124561         <http://lists.gnu.org/r/help-gsasl/2008-02/msg00000.html>.
124563 2008-04-08  Bruno Haible  <bruno@clisp.org>
124565         Add tentative support for emx+gcc.
124566         * lib/fbufmode.c (fbufmode) [__EMX__]: Add conditional code.
124567         * lib/fpurge.c (fpurge): Likewise.
124568         * lib/freadable.c (freadable): Likewise.
124569         * lib/freadahead.c (freadahead): Likewise.
124570         * lib/freading.c (freading): Likewise.
124571         * lib/freadptr.c (freadptr): Likewise.
124572         * lib/freadseek.c (freadptrinc): Likewise.
124573         * lib/fseeko.c (rpl_fseeko): Likewise.
124574         * lib/fseterr.c (fseterr): Likewise.
124575         * lib/fwritable.c (fwritable): Likewise.
124576         * lib/fwriting.c (fwriting): Likewise.
124577         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for emx+gcc.
124579 2008-04-09  Eric Blake  <ebb9@byu.net>
124581         Avoid some autoconf warnings.
124582         * m4/regex.m4 (gl_REGEX): s/AC_HELP_STRING/AS_HELP_STRING/.
124583         * m4/acl.m4 (gl_FUNC_ACL): Likewise.
124584         * m4/afs.m4 (gl_AFS): Likewise.
124585         * m4/gc-random.m4 (gl_GC_RANDOM): Likewise.
124586         * m4/include_next.m4 (gl_INCLUDE_NEXT): s/AC_FOREACH/m4_foreach_w/.
124587         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
124588         * m4/stdint.m4 (gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED)
124589         (gl_INTEGER_TYPE_SUFFIX): Likewise.
124590         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE)
124591         (AC_CHECK_DECLS_ONCE): Likewise.
124592         Rename file...
124593         * m4/onceonly.m4: ...to this, and delete 2.54 variant, now that
124594         gnulib-tool requires autoconf 2.59 or better.
124595         * gnulib-tool (func_get_filelist): s/\(onceonly\)_2_57.m4/\1.m4/.
124597 2008-04-08  Eric Blake  <ebb9@byu.net>
124599         Use 'git describe --match' if present (added in git 1.5.5).
124600         * build-aux/git-version-gen: Limit result to tags that match 'v*'
124601         if possible.
124603 2008-04-08  Bruno Haible  <bruno@clisp.org>
124605         Add tentative support for OpenServer.
124606         * lib/fbufmode.c (fbufmode): Add conditional define for _flag, _base,
124607         _ptr, _cnt.
124608         * lib/fpurge.c (fpurge): Likewise.
124609         * lib/freadable.c (freadable): Likewise.
124610         * lib/freadahead.c (freadahead): Likewise.
124611         * lib/freading.c (freading): Likewise.
124612         * lib/freadptr.c (freadptr): Likewise.
124613         * lib/freadseek.c (freadptrinc): Likewise.
124614         * lib/fseeko.c (rpl_fseeko): Likewise.
124615         * lib/fseterr.c (fseterr): Likewise.
124616         * lib/fwritable.c (fwritable): Likewise.
124617         * lib/fwriting.c (fwriting): Likewise.
124618         Reported by Roger Cornelius <rac@tenzing.org> and
124619         Brian K. White <brian@aljex.com>.
124621 2008-04-06  Jim Meyering  <meyering@redhat.com>
124623         * gnulib-tool (func_add_or_update): s/backuped/backed up/ in diagnostic
124625 2008-04-06  Bruno Haible  <bruno@clisp.org>
124627         Avoid possible error with non-ASCII bytes in UTF-8 locales.
124628         * tests/test-fprintf-posix.sh: Use "LC_ALL=C tr" instead of "tr".
124629         * tests/test-printf-posix.sh: Likewise.
124630         * tests/test-vfprintf-posix.sh: Likewise.
124631         * tests/test-vprintf-posix.sh: Likewise.
124632         * tests/test-xprintf-posix.sh: Likewise.
124634 2008-04-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
124636         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT): Fix quoting,
124637         hide error from 'ls', needed on OS/2.
124638         Report by Elbert Pol <elbert.pol@gmail.com>.
124640 2008-04-04  Eric Blake  <ebb9@byu.net>
124642         Make test-fseeko.c failures meaningful.
124643         * tests/test-fseeko.c: Print line number on failure.
124644         * tests/test-fseek.c: Likewise.
124645         Reported by Nelson H. F. Beebe.
124647         Improve strtod bug detection check.
124648         * m4/strtod.m4 (gl_FUNC_STRTOD): Also check for hex-float parsing,
124649         required for Solaris 10.
124650         Reported by Bob Friesenhahn and Nelson H. F. Beebe.
124652 2008-04-04  Bruno Haible  <bruno@clisp.org>
124654         * modules/relocatable-prog-wrapper (Files): Add m4/environ.m4. Needed
124655         by m4/setenv.m4.
124657 2008-04-03  Eric Blake  <ebb9@byu.net>
124659         Ensure sane .version contents.
124660         * top/GNUmakefile (_dummy): Also delete .version when rebuilding
124661         version string.
124662         * build-aux/git-version-gen: Improve documentation.
124664         Make GNU make output nicer.
124665         * top/GNUmakefile [!_have-Makefile]: Add dependency on
124666         MAKECMDGOALS to enforce message for all command line targets.  Set
124667         srcdir for use in maint.mk.
124669         Another maintainer tweak.
124670         * top/GNUmakefile (_is-dist-target): Allow maintainer-distcheck as
124671         a target that regenerates version.
124673 2008-04-03  Jim Meyering  <meyering@redhat.com>
124675         vc-list-files: don't cause coreutils "make po-check" failure
124676         * build-aux/vc-list-files: Skip postprocessing when $2 is '.'
124678 2008-04-03  Eric Blake  <ebb9@byu.net>
124680         Allow VPATH usage of vc-list-files.
124681         * build-aux/vc-list-files (scriptversion): Add timestamp.
124682         (options): Add --help, --version, -C.
124683         (CVS): Support installed cvsu.
124685 2008-04-02  Bruno Haible  <bruno@clisp.org>
124687         Avoid some "statement with no effect" warnings from gcc.
124688         * tests/test-wctype.c (main): Explicitly ignore unused values.
124689         Reported by Jim Meyering.
124691 2008-04-02  Jim Meyering  <meyering@redhat.com>
124693         Avoid some warnings from "gcc -Wshadow".
124694         * tests/test-frexp.c (exp): Define to a different identifier.
124695         * tests/test-frexpl.c (exp): Likewise.
124697 2008-04-03  Jim Meyering  <meyering@redhat.com>
124699         bootstrap: remove dangling *.[ch] symlinks from lib
124700         * build-aux/bootstrap [dangling symlink removal]: Move find's
124701         -depth option to precede all others, to avoid a warning.
124702         Remove *.[ch] files too, and from "$source_base" (usually lib/).
124704 2008-04-02  Bruno Haible  <bruno@clisp.org>
124706         Avoid some warnings from "gcc -Wshadow".
124707         * tests/tests-vfprintf-posix.c (my_fprintf): Move after test_function.
124708         * tests/tests-vprintf-posix.c (my_printf): Move after test_function.
124709         * tests/tests-vsnprintf-posix.c (my_snprintf): Move after test_function.
124710         * tests/tests-vsprintf-posix.c (my_sprintf): Move after test_function.
124711         Reported by Jim Meyering.
124713 2008-04-01  Bruno Haible  <bruno@clisp.org>
124715         Fix test to work on IRIX 6.5 with cc.
124716         * tests/test-math.c (numeric_equal): New function.
124717         (main): Use it.
124719 2008-04-01  Bruno Haible  <bruno@clisp.org>
124721         * doc/posix-headers/math.texi: Refine documentation of NAN problem.
124723 2008-04-01  Bruno Haible  <bruno@clisp.org>
124725         * tests/test-vasnprintf-posix.c: Include nan.h instead of <math.h>.
124726         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
124727         * modules/vasnprintf-posix-tests (Files): Add tests/nan.h.
124728         (Depends-on): Remove math.
124730         * tests/test-vasprintf-posix.c: Include nan.h instead of <math.h>.
124731         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
124732         * modules/vasprintf-posix-tests (Files): Add tests/nan.h.
124733         (Depends-on): Remove math.
124735         * tests/test-snprintf-posix.h: Include nan.h instead of <math.h>.
124736         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
124737         * modules/snprintf-posix-tests (Files): Add tests/nan.h.
124738         (Depends-on): Remove math.
124739         * modules/vsnprintf-posix-tests (Files): Add tests/nan.h.
124740         (Depends-on): Remove math.
124742         * tests/test-sprintf-posix.h: Include nan.h instead of <math.h>.
124743         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
124744         * modules/sprintf-posix-tests (Files): Add tests/nan.h.
124745         (Depends-on): Remove math.
124746         * modules/vsprintf-posix-tests (Files): Add tests/nan.h.
124747         (Depends-on): Remove math.
124749         * tests/test-round1.c: Include nan.h.
124750         (main): Use NaNd instead of NAN.
124751         * modules/round-tests (Files): Add tests/nan.h.
124753         * tests/test-trunc1.c: Include nan.h.
124754         (main): Use NaNd instead of NAN.
124755         * modules/trunc-tests (Files): Add tests/nan.h.
124757         * tests/test-roundf1.c: Include nan.h.
124758         (main): Use NaNf instead of NAN.
124759         * modules/roundf-tests (Files): Add tests/nan.h.
124761         * tests/test-truncf1.c: Include nan.h.
124762         (main): Use NaNf instead of NAN.
124763         * modules/truncf-tests (Files): Add tests/nan.h.
124765         * tests/test-ceilf1.c: Include nan.h.
124766         (main): Use NaNf instead of NAN.
124767         * modules/ceilf-tests (Files): Add tests/nan.h.
124769         * tests/test-floorf1.c: Include nan.h.
124770         (main): Use NaNf instead of NAN.
124771         * modules/floorf-tests (Files): Add tests/nan.h.
124773         * tests/test-isnanf.c: Include nan.h instead of <math.h>.
124774         (main): Use NaNf instead of NAN.
124775         * modules/isnanf-nolibm-tests (Files): Add tests/nan.h.
124777         * tests/test-isnand.c: Include nan.h instead of <math.h>.
124778         (main): Use NaNd instead of NAN.
124779         * modules/isnand-nolibm-tests (Files): Add tests/nan.h.
124781         * tests/test-frexp.c: Include nan.h.
124782         (main): Use NaNd instead of NAN.
124783         * modules/frexp-tests (Files): Add tests/nan.h.
124785         * lib/isnan.c: Don't include <math.h>.
124786         (FUNC): Don't use NAN macro.
124787         * modules/isnand-nolibm (Depends-on): Remove math.
124788         * modules/isnanf-nolibm (Depends-on): Remove math.
124789         * modules/isnanl (Depends-on): Remove math.
124790         * modules/isnanl-nolibm (Depends-on): Remove math.
124792         * tests/nan.h: New file.
124794 2008-04-01  Eric Blake  <ebb9@byu.net>
124796         Fix typos.
124797         * tests/test-strtod.c (main): s/FLT_/DBL_/ for minimum and epsilon
124798         values to be the right type.
124800         For now, cater to gnulib strtod inaccuracies.
124801         * tests/test-strtod.c (main): Allow 1-ulp error on expected
124802         fractional results.  While not as nice from a QoI perspective, it
124803         is a quicker patch than correctly implementing decimal to binary
124804         rounding.
124806 2008-03-31  Eric Blake  <ebb9@byu.net>
124808         Guarantee a definition of NAN.
124809         * lib/math.in.h (NAN): Define if missing.
124810         * tests/test-math.c (main): Test it.
124811         * doc/posix-headers/math.texi (math.h): Document this.
124812         * lib/isnan.c (rpl_isnand): Use it.
124813         * tests/test-ceilf1.c (NaN): Delete, and use NAN instead.
124814         * tests/test-floorf1.c (NaN): Likewise.
124815         * tests/test-frexp.c (NaN): Likewise.
124816         * tests/test-isnand.c (NaN): Likewise.
124817         * tests/test-isnanf.c (NaN): Likewise.
124818         * tests/test-round1.c (NaN): Likewise.
124819         * tests/test-roundf1.c (NaN): Likewise.
124820         * tests/test-snprintf-posix.h (NaN): Likewise.
124821         * tests/test-sprintf-posix.h (NaN): Likewise.
124822         * tests/test-trunc1.c (NaN): Likewise.
124823         * tests/test-truncf1.c (NaN): Likewise.
124824         * tests/test-vasnprintf-posix.c (NaN): Likewise.
124825         * tests/test-vasprintf-posix.c (NaN): Likewise.
124826         * modules/isnand-nolibm (Depends-on): Add math.
124827         * modules/isnanf-nolibm (Depends-on): Likewise.
124828         * modules/isnanl (Depends-on): Likewise.
124829         * modules/isnanl-nolibm (Depends-on): Likewise.
124830         * modules/snprintf-posix-tests (Depends-on): Likewise.
124831         * modules/sprintf-posix-tests (Depends-on): Likewise.
124832         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
124833         * modules/vsprintf-posix-tests (Depends-on): Likewise.
124834         * modules/vasnprintf-posix-tests (Depends-on): Likewise.
124835         * modules/vasprintf-posix-tests (Depends-on): Likewise.
124837 2008-03-31  Bruno Haible  <bruno@clisp.org>
124839         * tests/test-strtod.c (main): Update results for OSF/1 platforms.
124840         * doc/posix-functions/strtod.texi: Likewise.
124842 2008-03-31  Bruno Haible  <bruno@clisp.org>
124844         * tests/test-strtod.c (main): Don't use C99 syntax.
124846 2008-03-31  Bruno Haible  <bruno@clisp.org>
124848         * tests/test-strtod.c (main): Don't test NAN macro. Needed for Solaris.
124849         Reported by Eric Blake.
124851 2008-03-31  Jim Meyering  <meyering@redhat.com>
124853         Don't compare actual signbit return values.
124854         * tests/test-strtod.c (main): Rather, compare only their
124855         zero/non-zero nature.
124857 2008-03-31  Eric Blake  <ebb9@byu.net>
124859         More strtod documentation.
124860         * doc/posix-functions/strtod.texi (strtod): Interpret more test
124861         failures as distinct bugs.
124863 2008-03-30  Paul Eggert  <eggert@cs.ucla.edu>
124865         * lib/wchar.in.h [defined __need_mbstate_t]: Just include <wchar.h>.
124866         Problem reported by Erik Benada in
124867         <http://lists.gnu.org/r/bug-gnulib/2008-03/msg00249.html>.
124869 2008-03-30  Bruno Haible  <bruno@clisp.org>
124871         * tests/test-strtod.c: Add comments about which assertion fails on which
124872         platform.
124873         * doc/posix-functions/strtod.texi: Add info about many more platforms.
124875 2008-03-30  Eric Blake  <ebb9@byu.net>
124877         Test signbit behavior on zeros.
124878         * tests/test-signbit.c (test_signbitf): Add tests for zero.
124879         (test_signbitd, test_signbitl): Likewise.
124881         More strtod touchups.
124882         * tests/test-strtod.c (main): Ignore tests for signbit on NaN, and
124883         sign of negative underflow, for now.  Use .5, not .1.
124884         * doc/posix-functions/strtod.texi (strtod): Mention these
124885         limitations.
124886         Reported by Jim Meyering.
124888 2008-03-30  Bruno Haible  <bruno@clisp.org>
124890         * lib/striconveh.h (mem_iconveh, str_iconveh): Optimize the conversion
124891         from UTF-8 to UTF-8//TRANSLIT in the same way as from UTF-8 to UTF-8.
124893 2008-03-30  Bruno Haible  <bruno@clisp.org>
124895         Avoid failure when attempting to return empty iconv results on some
124896         platforms.
124897         * lib/striconveh.c (mem_cd_iconveh_internal): In the final memory
124898         allocation, don't report ENOMEM when the resulting string is empty.
124900 2008-03-30  Bruno Haible  <bruno@clisp.org>
124902         Fix buffer overrun.
124903         * lib/vasnprintf.c (VASNPRINTF): If !USE_SNPRINTF && pad_ourselves:
124904         Don't consider the width for tmp_length. Check count against tmp_length
124905         before doing the padding. Ensure enough allocation during padding.
124907 2008-03-30  Eric Blake  <ebb9@byu.net>
124909         strtod touchups.
124910         * lib/strtod.c (strtod): Avoid compiler warnings.
124911         Reported by Jim Meyering.
124913 2008-03-30  Bruno Haible  <bruno@clisp.org>
124915         * lib/unistdio/u-vsprintf.h (EOVERFLOW): Remove fallback.
124916         * modules/unistdio/ulc-vsprintf (Depends-on): Add EOVERFLOW.
124917         * modules/unistdio/u8-vsprintf (Depends-on): Add EOVERFLOW.
124918         * modules/unistdio/u8-u8-vsprintf (Depends-on): Add EOVERFLOW.
124919         * modules/unistdio/u16-vsprintf (Depends-on): Add EOVERFLOW.
124920         * modules/unistdio/u16-u16-vsprintf (Depends-on): Add EOVERFLOW.
124921         * modules/unistdio/u32-vsprintf (Depends-on): Add EOVERFLOW.
124922         * modules/unistdio/u32-u32-vsprintf (Depends-on): Add EOVERFLOW.
124924         * lib/unistdio/u-vsnprintf.h (EOVERFLOW): Remove fallback.
124925         * modules/unistdio/ulc-vsnprintf (Depends-on): Add EOVERFLOW.
124926         * modules/unistdio/u8-vsnprintf (Depends-on): Add EOVERFLOW.
124927         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Add EOVERFLOW.
124928         * modules/unistdio/u16-vsnprintf (Depends-on): Add EOVERFLOW.
124929         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Add EOVERFLOW.
124930         * modules/unistdio/u32-vsnprintf (Depends-on): Add EOVERFLOW.
124931         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Add EOVERFLOW.
124933         * lib/unistdio/u-vasprintf.h (EOVERFLOW): Remove fallback.
124934         * modules/unistdio/ulc-vasprintf (Depends-on): Add EOVERFLOW.
124935         * modules/unistdio/u8-vasprintf (Depends-on): Add EOVERFLOW.
124936         * modules/unistdio/u8-u8-vasprintf (Depends-on): Add EOVERFLOW.
124937         * modules/unistdio/u16-vasprintf (Depends-on): Add EOVERFLOW.
124938         * modules/unistdio/u16-u16-vasprintf (Depends-on): Add EOVERFLOW.
124939         * modules/unistdio/u32-vasprintf (Depends-on): Add EOVERFLOW.
124940         * modules/unistdio/u32-u32-vasprintf (Depends-on): Add EOVERFLOW.
124942         * lib/unistdio/ulc-vfprintf.c (EOVERFLOW): Remove fallback.
124943         * modules/unistdio/ulc-vfprintf (Depends-on): Add EOVERFLOW.
124945         * lib/unistdio/ulc-fprintf.c (EOVERFLOW): Remove fallback.
124946         * modules/unistdio/ulc-fprintf (Depends-on): Add EOVERFLOW.
124948         * lib/xvasprintf.c (EOVERFLOW): Remove fallback.
124949         * modules/xvasprintf (Depends-on): Add EOVERFLOW.
124951         * lib/vsprintf.c (EOVERFLOW): Remove fallback.
124952         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Drop gl_EOVERFLOW.
124953         * modules/vsprintf-posix (Depends-on): Add EOVERFLOW.
124955         * lib/vsnprintf.c (EOVERFLOW): Remove fallback.
124956         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Drop gl_EOVERFLOW.
124957         * modules/vsnprintf (Depends-on): Add EOVERFLOW.
124959         * lib/vfprintf.c (EOVERFLOW): Remove fallback.
124960         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Drop gl_EOVERFLOW.
124961         * modules/vfprintf-posix (Depends-on): Add EOVERFLOW.
124963         * lib/vasprintf.c (EOVERFLOW): Remove fallback.
124964         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Drop gl_EOVERFLOW.
124965         * modules/vasprintf (Depends-on): Add EOVERFLOW.
124967         * lib/vasnprintf.c (EOVERFLOW): Remove fallback.
124968         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Drop gl_EOVERFLOW.
124969         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Drop gl_EOVERFLOW.
124970         * modules/vasnprintf (Files): Remove m4/eoverflow.m4.
124971         (Depends-on): Add EOVERFLOW.
124972         * modules/unistdio/ulc-vasnprintf (Files): Remove m4/eoverflow.m4.
124973         (Depends-on): Add EOVERFLOW.
124974         * modules/unistdio/u8-vasnprintf (Files): Remove m4/eoverflow.m4.
124975         (Depends-on): Add EOVERFLOW.
124976         * modules/unistdio/u8-u8-vasnprintf (Files): Remove m4/eoverflow.m4.
124977         (Depends-on): Add EOVERFLOW.
124978         * modules/unistdio/u16-vasnprintf (Files): Remove m4/eoverflow.m4.
124979         (Depends-on): Add EOVERFLOW.
124980         * modules/unistdio/u16-u16-vasnprintf (Files): Remove m4/eoverflow.m4.
124981         (Depends-on): Add EOVERFLOW.
124982         * modules/unistdio/u32-vasnprintf (Files): Remove m4/eoverflow.m4.
124983         (Depends-on): Add EOVERFLOW.
124984         * modules/unistdio/u32-u32-vasnprintf (Files): Remove m4/eoverflow.m4.
124985         (Depends-on): Add EOVERFLOW.
124987         * lib/sprintf.c (EOVERFLOW): Remove fallback.
124988         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Drop gl_EOVERFLOW.
124989         * modules/sprintf-posix (Depends-on): Add EOVERFLOW.
124991         * lib/snprintf.c (EOVERFLOW): Remove fallback.
124992         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Drop gl_EOVERFLOW.
124993         * modules/snprintf (Depends-on): Add EOVERFLOW.
124995         * lib/poll.c (EOVERFLOW): Remove fallback.
124996         * modules/poll (Depends-on): Add EOVERFLOW.
124998         * lib/getugroups.c (EOVERFLOW): Remove fallback.
124999         * modules/getugroups (Depends-on): Add EOVERFLOW.
125001         * lib/getdelim.c (EOVERFLOW): Remove fallback.
125002         * modules/getdelim (Depends-on): Add EOVERFLOW.
125004         * lib/ftell.c (EOVERFLOW): Remove fallback.
125005         * modules/ftell (Depends-on): Add EOVERFLOW.
125007         * lib/fprintf.c (EOVERFLOW): Remove fallback.
125008         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Drop gl_EOVERFLOW.
125009         * modules/fprintf-posix (Depends-on): Add EOVERFLOW.
125011         * lib/c-stack.c (EOVERFLOW): Remove unused fallback.
125013         * modules/EOVERFLOW-tests: New file.
125014         * tests/test-EOVERFLOW.c: New file.
125016         * modules/EOVERFLOW: New file.
125017         * doc/posix-headers/errno.texi: Mention EOVERFLOW portability problem.
125019 2008-03-30  Bruno Haible  <bruno@clisp.org>
125021         Fix bug introduced on 2007-06-10.
125022         * lib/vasnprintf.c (VASNPRINTF): When performing zero-padding, use
125023         spaces instead of 0 digits for 's' also when ENABLE_UNISTDIO.
125025 2008-03-30  Bruno Haible  <bruno@clisp.org>
125027         Improve freadseek's efficiency after ungetc.
125028         * lib/freadseek.c: Include freadahead.h.
125029         (freadptrinc): New function, extracted from freadseek.
125030         (freadseek): Use it in a loop. Use freadahead to determine the number
125031         of loop iterations.
125032         * modules/freadseek (Depends-on): Add freadahead.
125033         (configure.ac): Require AC_C_INLINE.
125035 2008-03-30  Bruno Haible  <bruno@clisp.org>
125037         * lib/freadseek.c (freadseek): Don't ignore the return value of
125038         freadptr.
125040 2008-03-29  Eric Blake  <ebb9@byu.net>
125042         Add hex float support.
125043         * modules/strtod (Depends-on): Add c-ctype.
125044         (Link): Mention POW_LIB.
125045         * lib/strtod.c (strtod): Recognize hex floats.  Don't allow
125046         whitespace between 'e' and exponent.
125047         * tests/test-strtod.c (main): Enable hex float tests.
125048         * doc/posix-functions/strtod.texi (strtod): Document what gnulib
125049         now provides.
125051         Document various strtod bugs, with some fixes.
125052         * doc/posix-functions/strtod.texi (strtod): Document bugs with
125053         "-0x", "inf", "nan", and hex constants.
125054         * doc/posix-functions/atof.texi (atof): Likewise.
125055         * modules/stdlib (Makefile.am): Support strtod.
125056         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
125057         * m4/strtod.m4 (gl_FUNC_STRTOD): Fit in stdlib framework, and
125058         detect additional strtod bugs.
125059         * lib/stdlib.in.h (rpl_strtod): Add declarations.
125060         * lib/strtod.c (strtod): Return -0.0 on negative underflow.  Use
125061         bool where appropriate.  Parse 'inf' and 'nan'.
125062         * tests/test-strtod.c: New file.
125063         * modules/strtod (Depends-on): Add stdbool, stdlib.
125064         (configure.ac): Turn on module indicator.
125065         * modules/strtod-tests: New module.
125067 2008-03-29  Eric Blake  <ebb9@byu.net>
125069         Fix ftell on mingw.
125070         * lib/ftell.c (EOVERFLOW): Define if the system lacks it.
125071         * modules/ftell-tests (Depends-on): Add binary-io.
125072         * modules/ftello-tests (Depends-on): Likewise.
125073         * tests/test-ftell.c (main): Enhance test to cover behavior after
125074         ungetc.  Enforce binary mode.
125075         * tests/test-ftello.c (main): Likewise.
125077         Pass test-freadseek on cygwin.
125078         * modules/freadseek (Depends-on): Use freadptr, not freadahead.
125079         * lib/freadseek.c (freadseek): Don't increment beyond bounds of
125080         ungetc buffer.
125082         * tests/test-fflush2.c (main): Fix typo.
125084 2008-03-29  Bruno Haible  <bruno@clisp.org>
125086         * tests/test-fflush2.c (main): Temporarily disable the contents of
125087         this test.
125088         * m4/fflush.m4 (gl_FUNC_FFLUSH): Add a TODO.
125089         Reported by Eric Blake.
125091 2008-03-28  Simon Josefsson  <simon@josefsson.org>
125093         * lib/gc.h (enum Gc_hash): Add GC_SHA224.
125094         (GC_SHA224_DIGEST_SIZE): Add.
125096         * lib/gc-libgcrypt.c (gc_hash_open): Handle SHA-224.
125097         (gc_hash_digest_length): Likewise.
125098         (gc_hash_buffer): Likewise.
125100 2008-03-25  Bruno Haible  <bruno@clisp.org>
125102         * doc/gnulib-tool.texi (gettextize and autopoint): Explain in more
125103         detail which gettext release to use.
125104         Reported by Simon Josefsson.
125106 2008-03-26  Jim Meyering  <meyering@redhat.com>
125108         gnumakefile: remove file from $(top_builddir), not from $(top_srcdir)
125109         * modules/gnumakefile (clean-GNUmakefile): Also, use
125110         test ... && ... || : syntax rather than if-then ... fi.
125112         gnumakefile: Don't double-quote-expand $(VPATH) value.
125113         * modules/gnumakefile (clean-GNUmakefile): Use single quotes.
125115 2008-03-24  Eric Blake  <ebb9@byu.net>
125117         Alter GNUmakefile to install into top directory.
125118         * modules/maintainer-makefile: Split, and add dependency...
125119         * modules/gnumakefile: to this new module.
125120         * build-aux/GNUmakefile: Move...
125121         * top/GNUmakefile: ...here.
125122         * build-aux/maint.mk: Move...
125123         * top/maint.mk: ...here.
125124         * MODULES.html.sh (Support for maintaining...): Document new
125125         module.
125127 2008-03-23  Bruno Haible  <bruno@clisp.org>
125129         * gnulib-tool: New options --vc-files, --no-vc-files.
125130         (func_usage): Document them.
125131         (vc_files): New variable.
125132         (func_import): Consider vc_files.
125133         (func_create_testdir): Set vc_files to empty.
125134         Suggested by Jim Meyering and Karl Berry.
125136 2008-03-23  Bruno Haible  <bruno@clisp.org>
125138         Fix regex compilation error on HP-UX 11.
125139         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_TYPE_MBSTATE_T.
125140         * modules/regex (Files): Add m4/mbstate_t.m4.
125141         Reported by Ton Voon <ton.voon@altinity.com>.
125143 2008-03-23  Bruno Haible  <bruno@clisp.org>
125145         * doc/gnulib-tool.texi (gettextize and autopoint): New section.
125147 2008-03-23  Eric Blake  <ebb9@byu.net>
125148             Bruno Haible  <bruno@clisp.org>
125150         Install files from top/ in the destination directory.
125151         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
125152         augmentation also for the files from top/.
125153         (func_import, func_create_testdir): Rewrite file names:
125154         top/filename -> filename.
125156 2008-03-23  Bruno Haible  <bruno@clisp.org>
125158         Tweak "gnulib --version" output.
125159         * gnulib-tool (func_version): Replace "-dirty" suffix with "-modified".
125161 2008-03-23  Bruno Haible  <bruno@clisp.org>
125163         Tweak "gnulib --version" output.
125164         * gnulib-tool (func_version): Use date of last commit to ChangeLog,
125165         rather than contents of ChangeLog, when possible.
125167 2008-03-21  Eric Blake  <ebb9@byu.net>
125169         More --version tweaks.
125170         * gnulib-tool (func_version): Obey GNU Coding Standards.  Output
125171         date of last ChangeLog entry.
125173 2008-03-21  Jim Meyering  <meyering@redhat.com>
125175         * build-aux/GNUmakefile (_have-git-version-gen): Split long line.
125177 2008-03-20  Eric Blake  <ebb9@byu.net>
125179         VPATH fix.
125180         * build-aux/GNUmakefile (_have_git-version-gen): Look in correct dir.
125182 2008-03-20  Simon Josefsson  <simon@josefsson.org>
125184         * build-aux/GNUmakefile: Make git-version-gen optional.  Add
125185         _build-aux variable.  Suggested by Eric Blake <ebb9@byu.net>.
125187 2008-03-20  Eric Blake  <ebb9@byu.net>
125189         Sync GNUmakefile with coreutils.
125190         * build-aux/GNUmakefile (have-Makefile): Rename...
125191         (_have-Makefile): ...to this, for namespace consideration.
125192         (GNUmakefile.cfg): Include, if present.
125193         (_autoreconf): Define a default.
125194         (_is-dist-target): New rule for rebuilds to pick up intra-release
125195         version.
125196         (maint-cfg.mk): Rename...
125197         (cfg.mk): ...to this.
125199 2008-03-18  Jim Meyering  <meyering@redhat.com>
125201         New script and module: mktempd
125202         * MODULES.html.sh (maint+release support): Add mktempd.
125203         * build-aux/mktempd: New file.
125204         * modules/mktempd: New file.
125206 2008-03-15  Jim Meyering  <meyering@redhat.com>
125208         Undo last change.
125209         * lib/sha1.c, lib/md5.c: 63 != ~63.
125210         Reported by Andreas Schwab.
125212         sha1.c, md5.c: Hoist a redundant expression.
125213         * lib/sha1.c (sha1_process_bytes): AND-off the low bits in
125214         "ctx->buflen" only once, before calling *_process_block.
125215         * lib/md5.c (md5_process_bytes): Likewise.
125217 2008-03-14  Eric Blake  <ebb9@byu.net>
125219         Bump copyright year in files generated by gnulib-tool.
125220         * gnulib-tool (func_emit_copyright_notice): Extract copyright from
125221         gnulib-tool, rather than hard-coding it.
125223         Fix 'gnulib-tool --version' output to work with git.
125224         * gnulib-tool (func_gnulib_dir): New function, extracted from...
125225         (startup): ...here.
125226         (func_version): Use it to invoke git-version-gen, rather than
125227         relying on CVS keyword expansion.  Modernize wording.
125228         (cvsdatestamp, last_checkin_date, version): Kill unused
125229         variables.
125231 2008-03-12  Jim Meyering  <meyering@redhat.com>
125233         Recognize optional cast of the argument to free.
125234         * build-aux/useless-if-before-free: Update regexps.
125236         * build-aux/bootstrap (gnulib_tool): Remove trailing blanks.
125238 2008-03-11  Bruno Haible  <bruno@clisp.org>
125240         Extend AC_LIB_LINKFLAGS to the situation of several libraries provided
125241         by a single package.
125242         * m4/lib-link.m4 (AC_LIB_FROMPACKAGE): New macro.
125243         (AC_LIB_LINKFLAGS_BODY): Use the information stored by
125244         AC_LIB_FROMPACKAGE. Use AC_ARG_WITH instead of AC_LIB_ARG_WITH.
125245         Reported by Sam Steingold <sds@gnu.org>.
125247 2008-03-12  Sergey Poznyakoff  <gray@gnu.org.ua>
125249         * build-aux/bootstrap (version_controlled_file): Adapt for SVN
125250         repositories.
125252 2008-03-11  Bruno Haible  <bruno@clisp.org>
125254         Avoid conflicts between local macro definitions.
125255         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
125256         AC_LIB_LINKFLAGS_BODY): Use pushdef/popdef instead of define/undefine.
125258 2008-03-10  Peter O'Gorman  <bug-gnulib@mlists.thewrittenword.com>
125259             Bruno Haible  <bruno@clisp.org>
125261         Make va_copy work with some version of xlc on AIX 5.1.
125262         * lib/stdarg.in.h: New file.
125263         * m4/stdarg.m4 (gl_STDARG_H): Initialize STDARG_H and NEXT_STDARG_H.
125264         On AIX, use a <stdarg.h> file substitute.
125265         * modules/stdarg (Files): Add lib/stdarg.in.h.
125266         (Depends-on): Add include_next.
125267         (Makefile.am): Build a stdarg.h substitute if requested.
125268         * doc/posix-functions/va_copy.texi: Document the platforms lacking it.
125270 2008-03-10  Bruno Haible  <bruno@clisp.org>
125272         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Document a restriction.
125273         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
125274         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
125276 2008-03-10  Bruno Haible  <bruno@clisp.org>
125278         * modules/stdlib (Depends-on): Add include_next, remove
125279         absolute-header.
125281 2008-03-09  Bruno Haible  <bruno@clisp.org>
125283         * lib/freadahead.h (freadahead): Document more precisely.
125284         * lib/freadahead.c (freadahead): When an ungetc is in effect, return
125285         the sum of both buffer sizes.
125286         * tests/test-freadahead.c (main): Also test behaviour after ungetc.
125287         * NEWS: Document the change.
125289 2008-03-09  Bruno Haible  <bruno@clisp.org>
125291         Extend freadptr to return also the buffer size.
125292         * lib/freadptr.h (freadptr): Add sizep argument.
125293         * lib/freadptr.c: Include freadptr.h, not freadahead.h.
125294         (freadptr): Add sizep argument. Determine buffer size like freadahead
125295         does.
125296         * tests/test-freadptr.c: Don't include freadahead.h.
125297         (main): Adapt for new calling convention of freadptr.
125298         * tests/test-freadptr2.c: New file, based on tests/test-freadahead.c.
125299         * tests/test-freadptr2.sh: New file, based on tests/test-freadahead.sh.
125300         * modules/freadptr-tests (Files): Add tests/test-freadptr2.c,
125301         tests/test-freadptr2.sh.
125302         (Depends): Remove freadahead.
125303         (TESTS): Add test-freadptr2.sh.
125304         (check_PROGRAMS): Add test-freadptr2.
125306 2008-03-09  Bruno Haible  <bruno@clisp.org>
125308         * doc/Makefile (%.pdf): Explain how to remedy the save_size error.
125309         Report and solution by Simon Josefsson.
125311 2008-03-06  Bruno Haible  <bruno@clisp.org>
125313         Make fflush after ungetc work on BSD platforms.
125314         * lib/fflush.c (rpl_fflush): Discard ungetc buffer if possible.
125315         * tests/test-fflush2.c: New file.
125316         * tests/test-fflush2.sh: New file.
125317         * modules/fflush-tests (Files): Add tests/test-fflush2.sh,
125318         tests/test-fflush2.c.
125319         (Makefile.am): Build test-fflush2 and run test-fflush2.sh.
125320         * doc/posix-functions/fflush.texi: Document fflush after ungetc bug.
125322 2008-03-06  Eric Blake  <ebb9@byu.net>
125324         Likewise for ftello.
125325         * modules/ftello (Dependencies): Add extensions.
125326         * m4/ftello.m4 (gl_FUNC_FTELLO): Require AC_USE_SYSTEM_EXTENSIONS.
125328 2008-03-06  Bruno Haible  <bruno@clisp.org>
125330         * modules/fseeko (Dependencies): Add extensions.
125331         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Require AC_USE_SYSTEM_EXTENSIONS.
125332         Needed on glibc systems.
125334 2008-03-06  Bruno Haible  <bruno@clisp.org>
125336         * doc/gnulib-tool.texi (@nosuchmodulenote): Avoid line break inside
125337         email address.
125338         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
125340 2008-03-06  Bruno Haible  <bruno@clisp.org>
125342         * users.txt: Add libgnupdf.
125344 2008-03-06  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
125346         * doc/gnulib-tool.texi (@nosuchmodulenote): New macro.
125347         (Header File Substitutes, Function Substitutes,
125348         Glibc Header File Substitutes, Glibc Function Substitutes): Use it.
125349         (Build robot for gnulib): Fix typo.
125351 2008-03-06  Bruno Haible  <bruno@clisp.org>
125353         * doc/gnulib-tool.texi (VCS Issues): Small updates.
125354         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
125356 2008-03-06  Bruno Haible  <bruno@clisp.org>
125358         * doc/func.texi: New file, extracted from doc/gnulib.texi.
125359         * doc/gnulib.texi: Include it.
125361 2008-03-06  Simon Josefsson  <simon@josefsson.org>
125363         * modules/func (License): Change license to unlimited; there was
125364         no LGPL parts in the module anyway.
125366 2008-03-06  Simon Josefsson  <simon@josefsson.org>
125368         * modules/__func__: Renamed to modules/func.
125369         * modules/__func__-tests: Renamed to modules/func-tests.
125370         * tests/test-__func__.c: Renamed to tests/test-func.c.
125371         * m4/__func__.m4: Renamed to m4/func.m4.
125372         * doc/gnulib.texi (__func__): Section renamed to func.
125373         Suggested by Eric Blake <ebb9@byu.net>.
125375 2008-03-06  Simon Josefsson  <simon@josefsson.org>
125377         * doc/gnulib.texi (__func__): Use C99 terminology when talking
125378         about __func__.  Make example self-contained.  Suggested by Eric
125379         Blake <ebb9@byu.net>.
125381         * tests/test-__func__.c (main): Avoid extraneous () around __func.
125382         Suggested by Eric Blake <ebb9@byu.net>.
125384 2008-03-06  Simon Josefsson  <simon@josefsson.org>
125386         * modules/__func__: New file.
125387         * modules/__func__-tests: New file.
125388         * tests/test-__func__.c: New file.
125389         * m4/__func__.m4: New file.
125390         * doc/gnulib.texi (__func__): Document __func__ module.
125392 2008-03-05  Simon Josefsson  <simon@josefsson.org>
125394         * modules/byteswap (License): Re-license as LGPLv2+.
125396 2008-03-05  Simon Josefsson  <simon@josefsson.org>
125398         * doc/Makefile: Add pdf target.
125400 2008-03-05  Simon Josefsson  <simon@josefsson.org>
125402         * modules/inline (License): Use 'unlimited', since there are only
125403         *.m4 files in this module.
125405 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
125406             Bruno Haible  <bruno@clisp.org>
125408         Add support for HP C 7.1 on OpenVMS 8.3.
125409         * lib/alloca.in.h (alloca): Define as alias for DEC C on VMS.
125411 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
125413         Update VMS specifics.
125414         * lib/getopt.c [VMS]: Remove include of unixlib.h.
125416 2008-03-02  Jim Meyering  <meyering@redhat.com>
125418         Remove the last dependency on the "free" module.
125419         * m4/readutmp.m4 (gl_READUTMP): Don't require gl_FUNC_FREE.
125420         Reported by Bob Proulx.
125422         * lib/getdelim.c (getdelim): Don't leak memory upon failed realloc.
125424         Remove useless "if" tests before free.  Deprecate "free" module.
125425         * doc/posix-functions/free.texi: Mention that this
125426         module is no longer useful.
125427         * modules/free (Notice): Say this module is obsolete.
125428         * modules/readutmp (Depends-on): Remove free.
125429         * lib/save-cwd.c (free_cwd): Remove useless "if" before free.
125430         * lib/putenv.c (putenv): Likewise.
125431         * lib/gc-gnulib.c (gc_cipher_close): Likewise.
125432         * lib/getaddrinfo.c (freeaddrinfo): Likewise.
125433         * tests/test-c-strcasestr.c (main): Likewise.
125434         * tests/test-c-strstr.c (main): Likewise.
125435         * tests/test-mbscasestr1.c (main): Likewise.
125436         * tests/test-mbscasestr2.c (main): Likewise.
125437         * tests/test-mbsstr1.c (main): Likewise.
125438         * tests/test-mbsstr2.c (main): Likewise.
125439         * tests/test-memmem.c (main): Likewise.
125440         * tests/test-strcasestr.c (main): Likewise.
125441         * tests/test-striconv.c (main): Likewise.
125442         * tests/test-striconveh.c (main): Likewise.
125443         * tests/test-striconveha.c (main): Likewise.
125444         * tests/test-strstr.c (main): Likewise.
125446         * build-aux/git-version-gen: Adjust a comment and the Usage string.
125448         bootstrap: sync from coreutils again
125449         * build-aux/bootstrap: Remove dangling m4/*.m4 symlinks.
125451 2008-03-01  Jim Meyering  <meyering@redhat.com>
125453         bootstrap: sync from coreutils
125454         * build-aux/bootstrap (update_po_files): Copy a .po file into place
125455         also when the target doesn't exist.
125457 2008-03-01  Eric Blake  <ebb9@byu.net>
125459         Fix bugs in last patch.
125460         * lib/memchr2.c (memchr2): Fix typo.
125461         * tests/test-memchr2.c: Test previous bug, and don't use GNU
125462         extension.
125463         Reported by Bruce Korb.
125465         New module 'memchr2'.
125466         * modules/memchr2: New file.
125467         * modules/memchr2-tests: Likewise.
125468         * lib/memchr2.h: Likewise.
125469         * lib/memchr2.c: Likewise, based on memchr.c.
125470         * tests/test-memchr2.c: New test.
125471         * MODULES.html.sh (String handling): Add memchr2.
125473 2008-02-29  Bruno Haible  <bruno@clisp.org>
125475         * modules/freadseek-tests: New file.
125476         * tests/test-freadseek.sh: New file.
125477         * tests/test-freadseek.c: New file.
125479         New module 'freadseek'.
125480         * modules/freadseek: New file.
125481         * lib/freadseek.h: New file.
125482         * lib/freadseek.c: New file.
125483         * MODULES.html.sh (File stream based Input/Output): Add freadseek.
125485 2008-02-29  Sergey Poznyakoff  <gray@gnu.org.ua>
125487         * users.txt: Add anubis, cpio, mailfromd, mailutils, radius,
125488         wydawca.
125490         * m4/argp.m4 (gl_ARGP): Use AC_TRY_LINK to test if
125491         program_invocation_name and program_invocation_short_name are
125492         present.
125494 2008-02-28  Bruno Haible  <bruno@clisp.org>
125496         * tests/test-freadptr.c: Add a test for behaviour after ungetc.
125497         * tests/test-freadptr.sh: Also test non-seekable stdin.
125499 2008-02-28  Sergey Poznyakoff  <gray@gnu.org.ua>
125501         * build-aux/bootstrap (source_base, m4_base)
125502         (doc_base, tests_base): New variables.
125503         (gnulib_tool_options): Do not hardcode base directories, use
125504         the above variables instead.
125506 2008-02-28  Atsushi SAKAI  <sakaia@jp.fujitsu.com>
125508         * lib/xsize.h: Fix typo in comment: s/tupe/type/.
125510 2008-02-28  Bruno Haible  <bruno@clisp.org>
125512         * modules/freadptr-tests: New file.
125513         * tests/test-freadptr.sh: New file.
125514         * tests/test-freadptr.c: New file.
125516         New module 'freadptr'.
125517         * modules/freadptr: New file.
125518         * lib/freadptr.h: New file.
125519         * lib/freadptr.c: New file.
125520         * MODULES.html.sh (File stream based Input/Output): Add freadptr.
125522 2008-02-26  Karl Berry  <karl@freefriends.org>
125524         Sync from Libtool:
125525         * libltdl/argz.c (argz_add, argz_count): New functions.
125526         * libltdl/argz.in.h: Declare them.
125527         Report by Juan Manuel Guerrero <juan.guerrero@gmx.de>.
125529 2008-02-22  Bruno Haible  <bruno@clisp.org>
125531         * m4/time_r.m4 (gl_TIME_R): Also check that localtime_r's return type
125532         is a pointer type.  Needed for HP-UX 10.
125533         * doc/posix-functions/localtime_r.texi: Mention HP-UX 10.
125534         * doc/posix-functions/gmtime_r.texi: Likewise.
125535         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
125537 2008-02-24  Bruno Haible  <bruno@clisp.org>
125539         * modules/environ-tests: New file.
125540         * tests/test-environ.c: New file.
125542         New module 'environ'.
125543         * modules/environ: New file.
125544         * lib/unistd.in.h (environ): New declaration.
125545         * m4/environ.m4: New file.
125546         (gt_CHECK_VAR_DECL): Moved here from m4/setenv.m4. Undefine gt_cv_var
125547         after use.
125548         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ENVIRON and
125549         HAVE_DECL_ENVIRON.
125550         * modules/unistd (Makefile.am): Substitute also GNULIB_ENVIRON and
125551         HAVE_DECL_ENVIRON.
125552         * doc/posix-functions/environ.texi: Mention module 'environ'. Remove
125553         wrong claim that 'environ' is missing on some systems.
125554         * modules/execute (Depends-on): Add environ.
125555         * lib/execute.c (environ): Remove fallback declaration.
125556         * modules/pipe (Depends-on): Add environ.
125557         * lib/pipe.c (environ): Remove fallback declaration.
125558         * modules/setenv (Depends-on): Add environ.
125559         * lib/setenv.c (environ): Remove fallback declaration.
125560         * modules/unsetenv (Depends-on): Add environ.
125561         * lib/unsetenv.c (environ): Remove fallback declaration.
125562         * m4/setenv.m4 (gt_CHECK_VAR_DECL): Remove macro. Moved to
125563         m4/environ.m4.
125564         (gl_PREREQ_SETENV): Require gl_ENVIRON instead of testing for environ.
125565         (gl_PREREQ_UNSETENV): Likewise.
125567 2008-02-24  Bruno Haible  <bruno@clisp.org>
125569         * doc/posix-functions/environ.texi: Document the MacOS X problem.
125571 2008-02-20  Bob Proulx  <bob@proulx.com>
125573         Enable use of older two part flavor 'git describe'.
125574         * build-aux/git-version-gen: If using the older two part flavor of
125575         git version then recreate the third part now present in the
125576         newer three part flavor of git describe.
125578 2008-02-20  Martin Buchholz  <martin@xemacs.org>  (tiny change)
125580         * lib/fts.c (fts_build): Typo correction to comment.
125582 2008-02-17  Bruno Haible  <bruno@clisp.org>
125584         * lib/git-merge-changelog.c (main) [split_merged_entry]: Avoid
125585         generating no-op conflicts.
125587 2008-02-17  Bruno Haible  <bruno@clisp.org>
125589         Speed up by 10%.
125590         * lib/git-merge-changelog.c (main): Use the iterator to iterate through
125591         result_entries, rather than an index-based loop.
125593 2008-02-17  Bruno Haible  <bruno@clisp.org>
125595         Speed up by 25%.
125596         * lib/git-merge-changelog.c (struct entry): New fields 'hashcode',
125597         'hashcode_cached'.
125598         (entry_create): New function.
125599         (entry_hashcode): Use the cached hashcode if possible.
125600         (read_changelog_file, try_split_merged_entry): Use entry_create.
125602 2008-02-17  Bruno Haible  <bruno@clisp.org>
125604         Speed up from O(n^2) to O(n) for long ChangeLog files.
125605         * lib/git-merge-changelog.c: Include gl_rbtreehash_list.h.
125606         (read_changelog_file): Change implementation of entries_reversed list
125607         to rbtreehash.
125608         * modules/git-merge-changelog (Depends-on): Add rbtreehash-list.
125610 2008-02-17  Bruno Haible  <bruno@clisp.org>
125612         New option --split-merged-entry.
125613         * lib/git-merge-changelog.c (FSTRCMP_STRICTER_THRESHOLD): New macro.
125614         (find_paragraph_end, try_split_merged_entry): New functions.
125615         (long_options): Add option --split-merged-entry.
125616         (usage): Document option --split-merged-entry.
125617         (main): Implement option --split-merged-entry.
125618         Reported by Eric Blake.
125620 2008-02-17  Bruno Haible  <bruno@clisp.org>
125622         * lib/git-merge-changelog.c: Include c-strstr.h.
125623         (main): Support the "git pull --rebase" situation.
125624         * modules/git-merge-changelog (Depends-on): Add c-strstr.
125625         Reported by Eric Blake.
125627 2008-02-16  Eric Blake  <ebb9@byu.net>
125629         Avoid doubling \ in common case of "c-maybe" quoting style.
125630         * lib/quotearg.c (quotearg_buffer_restyled): Don't escape \ when
125631         eliding outer quotes.
125632         * lib/quotearg.h: Document this.
125633         * tests/test-quotearg.c (result_strings, inputs, results_g)
125634         (flag_results, locale_results): Test it by adding a new string to
125635         each test group.
125636         (compare_strings): Test new string.
125638 2008-02-13  Eric Blake  <ebb9@byu.net>
125640         Avoid trigraph quoting in default output.
125641         * lib/quotearg.h (enum quoting_flags): Add QA_SPLIT_TRIGRAPHS.
125642         * lib/quotearg.c (quotearg_buffer_restyled): Don't quote trigraphs
125643         unless explicitly requested.
125644         * tests/test-quotearg.c (flag_results, main): Add additional tests.
125646 2008-02-13  Lasse Collin  <lasse.collin@tukaani.org>
125648         Don't rely on signed integer overflowing to negative value.
125649         * lib/getugroups.c (getugroups): Include <limits.h>.
125650         Instead, compare against INT_MAX, and increment only if the test passes.
125652 2008-02-13  Jim Meyering  <meyering@redhat.com>
125653         and Eric Blake  <ebb9@byu.net>
125655         Avoid shadowing warning and compile errors on Linux.
125656         * tests/test-quotearg.c [ENABLE_NLS]: Disable <libintl.h>
125657         forwarding macros on Linux.
125658         (dcgettext): Define a stub, for Linux.
125659         (results_g, main): Avoid warnings.
125661 2008-02-12  Eric Blake  <ebb9@byu.net>
125663         Silence warning in last patch.
125664         * lib/quotearg.c (quotearg_buffer_restyled): Add missing const.
125666         Quotearg part 4: add tests, fix c-maybe colon quoting.
125667         * lib/quotearg.h: Improve documentation.
125668         * lib/quotearg.c (quotearg_buffer_restyled): Don't add extra
125669         escapes when adding outer quotes.  When quoting trigraphs, use
125670         valid C notation.  When quoting NUL, omit extra characters if next
125671         character is not digit.  Alter prototype.
125672         (quotearg_buffer, quotearg_alloc_mem, quotearg_n_options): Adjust
125673         callers.
125674         * modules/quotearg-tests: New module.
125675         * tests/test-quotearg.c: New test.
125677 2008-02-07  Eric Blake  <ebb9@byu.net>
125679         Quotearg part 3: add flag to control outer quote elision.
125680         * lib/quotearg.h (c_maybe_quoting_style): New style.
125681         (enum quoting_flags): Better documentation of flags.
125682         * lib/quotearg.c (quoting_style_args, quoting_style_vals): Add
125683         c-maybe style.
125684         (quotearg_buffer_restyled): Handle new flag to elide outer
125685         quotes.
125687         Quotearg part 2: add flag that can control NUL elision.
125688         * lib/quotearg.h (set_quoting_flags): New prototype.
125689         * lib/quotearg.c (struct quoting_options): Add flag field.
125690         (set_quoting_flags): New function.
125691         (quotearg_buffer_restyled): Add flags parameter.
125692         (quotearg_alloc_mem): Set the flag if length cannot be returned.
125693         (quotearg_n_options): Set the flag, since length cannot be
125694         returned.
125695         (quoting_options_from_style): Default flags correctly.
125697         Quotearg part 1: more wrappers, restore quotearg_char state.
125698         * lib/quotearg.h (quotearg_alloc_mem, quotearg_n_mem)
125699         (quotearg_mem, quotearg_style_mem, quotearg_char_mem)
125700         (quotearg_colon_mem): New wrappers.
125701         * lib/quotearg.c (quotearg_alloc, quotearg_char): Rewrite...
125702         (quotearg_alloc_mem, quotearg_char_mem): ...in terms of these new
125703         functions.
125704         (quotearg_n_mem, quotearg_mem, quotearg_style_mem)
125705         (quotearg_colon_mem): New functions.
125707 2008-02-11  Bruno Haible  <bruno@clisp.org>
125709         * modules/git-merge-changelog (Makefile.am): Don't use -L and -l for a
125710         library in the current directory: it does not work with parallel make.
125711         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
125713 2008-02-11  Bruno Haible  <bruno@clisp.org>
125715         * .gitattributes: New file.
125717 2008-02-11  Jim Meyering  <meyering@redhat.com>
125719         useless-if-before-free: Fix reversed exit values.
125720         * build-aux/useless-if-before-free: Use correct values
125721         for EXIT_MATCH and EXIT_NO_MATCH.
125723         * build-aux/useless-if-before-free: Close stdout carefully.
125725 2008-02-10  Bruno Haible  <bruno@clisp.org>
125727         New module 'git-merge-changelog'.
125728         * modules/git-merge-changelog: New file.
125729         * lib/git-merge-changelog.c: New file.
125731 2008-02-10  Jim Meyering  <meyering@redhat.com>
125733         useless-if-before-free: New option: --list (-l).
125735         useless-if-before-free: Don't exit immediately upon open failure.
125736         * build-aux/useless-if-before-free: Exit 2 for errors.
125737         Upon failure to open a file, don't exit immediately.
125738         Rather, just warn and continue with any remaining files.
125740 2008-02-10  Bruno Haible  <bruno@clisp.org>
125742         New abstract list operation 'node_set_value'.
125743         * lib/gl_list.h (gl_list_node_set_value): New function.
125744         (struct gl_list_implementation): New field node_set_value.
125745         * lib/gl_list.c (gl_list_node_set_value): New function.
125746         * lib/gl_array_list.c (gl_array_node_set_value): New function.
125747         (gl_array_list_implementation): Update.
125748         * lib/gl_carray_list.c (gl_carray_node_set_value): New function.
125749         (gl_carray_list_implementation): Update.
125750         * lib/gl_anylinked_list2.h (gl_linked_node_set_value): New function.
125751         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
125752         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
125753         * lib/gl_anytree_list2.h (gl_tree_node_set_value): New function.
125754         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
125755         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
125756         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
125757         Update.
125758         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
125759         * lib/gl_sublist.c (gl_sublist_node_set_value): New function.
125760         (gl_sublist_list_implementation): Update.
125762 2008-02-10  Bruno Haible  <bruno@clisp.org>
125764         * lib/diffseq.h: Write "ELEMENT const" instead of "const ELEMENT".
125765         Needed when ELEMENT is #defined to 'some_type *'.
125767 2008-02-10  Jim Meyering  <meyering@redhat.com>
125769         New script and module: useless-if-before-free
125770         * MODULES.html.sh (maint+release support): Add useless-if-before-free.
125771         * build-aux/useless-if-before-free: New file.
125772         * modules/useless-if-before-free: New file.
125774         * build-aux/gitlog-to-changelog: Use committer date, not author date.
125776         xstrtol_error: Fix typo.
125777         * lib/xstrtol-error.c (xstrtol_error): The parameter was unused:
125778         s/exit_failure/exit_status/.
125780 2008-02-09  Jim Meyering  <meyering@redhat.com>
125782         New script and module: gitlog-to-changelog
125783         * MODULES.html.sh (maint+release support): Add gitlog-to-changelog.
125784         * modules/gitlog-to-changelog: New file.
125785         * build-aux/gitlog-to-changelog: New file.
125787 2008-02-08  Jim Meyering  <meyering@redhat.com>
125789         Avoid two "parameter unused" warnings.
125790         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime):
125791         Mark "st" as used.
125793         Use "git COMMAND", not "git-COMMAND".
125794         * build-aux/bootstrap (version_controlled_file): s/git-rm/git-rm/.
125795         * build-aux/announce-gen (get_tool_versions): Correct a diagnostic.
125796         * build-aux/git-version-gen: Use "git status", not "git-status".
125798 2008-02-07  Bruno Haible  <bruno@clisp.org>
125800         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on native Woe32 systems.
125801         Avoids a crash on Windows Vista.
125802         Reported by Adam Strzelecki <ono@java.pl> via
125803         Simon Josefsson <simon@josefsson.org>.
125805 2008-02-06  Bruno Haible  <bruno@clisp.org>
125807         Fix *printf behaviour regarding the left-adjust flag on HP-UX 10.20.
125808         * m4/printf.m4 (gl_PRINTF_FLAG_LEFTADJUST): New macro.
125809         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_FLAG_LEFTADJUST.
125810         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST): New macro.
125811         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
125812         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
125813         gl_PRINTF_FLAG_LEFTADJUST and test its result. Invoke
125814         gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST.
125815         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
125816         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
125817         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
125818         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
125819         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
125820         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
125821         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
125822         * tests/test-vasnprintf-posix.c (test_function): Add testcases for the
125823         left-adjust flag.
125824         * tests/test-snprintf-posix.h (test_function): Likewise.
125825         * tests/test-sprintf-posix.h (test_function): Likewise.
125826         * tests/test-vasprintf-posix.c (test_function): Likewise.
125827         * doc/posix-functions/fprintf.texi: Update.
125828         * doc/posix-functions/printf.texi: Update.
125829         * doc/posix-functions/snprintf.texi: Update.
125830         * doc/posix-functions/sprintf.texi: Update.
125831         * doc/posix-functions/vfprintf.texi: Update.
125832         * doc/posix-functions/vprintf.texi: Update.
125833         * doc/posix-functions/vsnprintf.texi: Update.
125834         * doc/posix-functions/vsprintf.texi: Update.
125835         Reported by Peter Fales <psfales@alcatel-lucent.com>.
125837 2008-02-06  Bruno Haible  <bruno@clisp.org>
125839         Fix bug introduced on 2008-01-26.
125840         * lib/isnan.c (FUNC): Set to rpl_isnand, not rpl_isnan.
125842 2008-02-06  Bruno Haible  <bruno@clisp.org>
125844         Fix bug introduced on 2007-06-10.
125845         * lib/vasnprintf.c (VASNPRINTF): Perform zero-padding also if
125846         !NEED_PRINTF_FLAG_ZERO.
125848 2008-02-05  Peter O'Gorman  <pogma@thewrittenword.com>
125850         getloadavg: use libperfstat on AIX5
125851         * lib/getloadavg.c, m4/getloadavg.m4 [aix]: Use libperfstat
125853 2008-02-03  Bruno Haible  <bruno@clisp.org>
125855         * lib/diffseq.h: Add comments about required #includes.
125856         Reported by Michael Biggs <gnulib@doubleplum.net>.
125858 2008-02-01  Bruno Haible  <bruno@clisp.org>
125860         * users.txt: Add gnuit.
125862 2008-01-31  Bruno Haible  <bruno@clisp.org>
125864         * lib/md4.c (set_uint32): Mark as inline.
125865         * lib/md5.c (set_uint32): Likewise.
125866         * lib/sha1.c (set_uint32): Likewise.
125867         * m4/md4.m4 (gl_MD4): Require AC_C_INLINE.
125868         * m4/md5.m4 (gl_MD5): Likewise.
125869         * m4/sha1.m4 (gl_SHA1): Likewise.
125871 2008-01-31  Jim Meyering  <meyering@redhat.com>
125873         Use "sizeof VAR", rather than a literal "4".
125874         * lib/md5.c (md5_read_ctx): Use sizeof ctx->A, not 4.
125875         * lib/md4.c (md4_read_ctx): Likewise.
125876         * lib/sha1.c (sha1_read_ctx): Likewise.
125878 2008-01-31  Simon Josefsson  <simon@josefsson.org>
125880         * tests/test-sha1.c: New file, based on test-md5.c.
125882         * modules/crypto/sha1-tests: New file.
125884 2008-01-31  Simon Josefsson  <simon@josefsson.org>
125886         * lib/sha1.h (SHA1_DIGEST_SIZE): Define.
125888 2008-01-31  Jim Meyering  <meyering@redhat.com>
125890         Prefer "sizeof v" over the equivalent "4".
125891         * lib/md4.c (set_uint32): Use "sizeof v" as memcpy length, not 4.
125892         * lib/md5.c (set_uint32): Likewise.
125893         * lib/sha1.c (set_uint32): Likewise.
125895 2008-01-31  Simon Josefsson  <simon@josefsson.org>
125897         * lib/sha1.c (set_uint32): Mark function as static.
125899 2008-01-31  Simon Josefsson  <simon@josefsson.org>
125901         md2: clarify comments to say that alignment is not required.
125902         * lib/md2.h: Remove warning about alignment in comment.
125903         * lib/md2.c (md2_read_ctx, md2_finish_ctx): Doc fix, alignment has
125904         never been required.
125906 2008-01-31  Simon Josefsson  <simon@josefsson.org>
125908         md4: adapt alignment constraint fix from sha1.
125909         * lib/md4.c (set_uint32): New function, from sha1.c
125910         (md4_read_ctx): Use it.
125911         (md4_finish_ctx): Doc fix.
125912         * lib/md4.h: Doc fix.
125914 2008-01-31  Simon Josefsson  <simon@josefsson.org>
125916         md5: adapt alignment constraint fix from sha1.
125917         * lib/md5.c (set_uint32): New function, from sha1.c
125918         (md5_read_ctx): Use it.
125919         (md5_finish_ctx): Doc fix.
125920         * lib/md5.h: Doc fix.
125922 2008-01-30  Peter Palfrader  <weasel@debian.org>
125924         sha1: remove the result buffer alignment constraint
125925         * lib/sha1.c (set_uint32): New function.
125926         (sha1_read_ctx): Rewrite to remove the result buffer alignment
125927         constraint.
125928         (sha1_finish_ctx): Remove comment warning about alignment constraint.
125929         * lib/sha1.h: Likewise.
125931 2008-01-30  Andreas Schwab  <schwab@suse.de>
125932             Bruno Haible  <bruno@clisp.org>
125934         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Include <float.h> and ensure a
125935         correct definition of LDBL_MIN_EXP.
125937 2008-01-30  Karl Berry  <karl@gnu.org>
125939         * config/srclist-update: try to preserve x bit on updates.
125940         * config/srclistvars.sh: update for karl.
125942 2008-01-29  Jim Meyering  <meyering@redhat.com>
125944         vasnprintf.c: Avoid warning about unused label
125945         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Guard the
125946         "overflow" label definition and associated code with the
125947         same cpp condition that guards the sole use of that label.
125949 2008-01-26  Bruno Haible  <bruno@clisp.org>
125951         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM,
125952         gl_FUNC_ISNANL_WORKS): Test the GCC >= 4.0 built-in.
125953         * lib/isnanl.h (isnanl): Use the GCC >= 4.0 built-in.
125954         * lib/isnanl-nolibm.h (isnanl): Likewise.
125955         Reported by Paul Eggert <eggert@cs.ucla.edu>.
125957 2008-01-26  Bruno Haible  <bruno@clisp.org>
125959         * m4/isnand.m4 (gl_FUNC_ISNAND_NO_LIBM): Test the GCC >= 4.0 built-in.
125960         * lib/isnand.h (isnand): Use the GCC >= 4.0 built-in.
125962 2008-01-26  Bruno Haible  <bruno@clisp.org>
125964         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_ISNANF_WORKS): Test the
125965         GCC >= 4.0 built-in.
125966         * lib/isnanf.h (isnanf): Use the GCC >= 4.0 built-in.
125968 2008-01-26  Bruno Haible  <bruno@clisp.org>
125970         Rename isnan, applicable to 'double' only, to isnand.
125971         * modules/isnand-nolibm: Renamed from modules/isnan-nolibm.
125972         (Files): Add lib/isnand.h, lib/isnand.c. Remove lib/isnan.h.
125973         (configure.ac): Update.
125974         (Include): Replace "isnan.h" with "isnand.h".
125975         * m4/isnand.m4: Renamed from m4/isnan.m4.
125976         (gl_FUNC_ISNAND_NO_LIBM): Renamed from gl_FUNC_ISNAN_NO_LIBM. Set
125977         HAVE_ISNAND_IN_LIBC instead of HAVE_ISNAN_IN_LIBC. Build isnand.c
125978         instead of isnan.c.
125979         * lib/isnand.h: Renamed from lib/isnan.h. Test HAVE_ISNAND_IN_LIBC
125980         instead of HAVE_ISNAN_IN_LIBC.
125981         (isnand): Renamed from isnan.
125982         * lib/isnand.c: New file.
125983         * modules/isnand-nolibm-tests: Renamed from modules/isnan-nolibm-tests.
125984         (Files): Add tests/test-isnand.c. Remove tests/test-isnan.c.
125985         (Makefile.am): Update.
125986         * tests/test-isnand.c: Renamed from tests/test-isnan.c.
125987         Include isnand.h instead of isnan.h.
125988         (main): Test isnand instead of isnan.
125989         * modules/fprintf-posix (Depends-on): Add isnand-nolibm, remove
125990         isnan-nolibm.
125991         * modules/frexp (Depends-on): Likewise.
125992         * modules/frexp-tests (Depends-on): Likewise.
125993         * modules/frexp-nolibm (Depends-on): Likewise.
125994         * modules/frexp-nolibm-tests (Depends-on): Likewise.
125995         * modules/isfinite (Depends-on): Likewise.
125996         * modules/round-tests (Depends-on): Likewise.
125997         * modules/signbit (Depends-on): Likewise.
125998         * modules/signbit-tests (Depends-on): Likewise.
125999         * modules/snprintf-posix (Depends-on): Likewise.
126000         * modules/sprintf-posix (Depends-on): Likewise.
126001         * modules/trunc-tests (Depends-on): Likewise.
126002         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
126003         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
126004         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
126005         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
126006         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
126007         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
126008         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
126009         * modules/vasnprintf-posix (Depends-on): Likewise.
126010         * modules/vasprintf-posix (Depends-on): Likewise.
126011         * modules/vfprintf-posix (Depends-on): Likewise.
126012         * modules/vsnprintf-posix (Depends-on): Likewise.
126013         * modules/vsprintf-posix (Depends-on): Likewise.
126014         * lib/frexp.c: Include isnand.h instead of isnan.h.
126015         (ISNAN): Set to isnand instead of isnan.
126016         * lib/isfinite.c: Include isnand.h instead of isnan.h.
126017         (gl_isfinited): Use isnand instead of isnan.
126018         * lib/signbitd.c: Include isnand.h instead of isnan.h.
126019         (gl_signbitd): Use isnand instead of isnan.
126020         * lib/vasnprintf.c: Include isnand.h instead of isnan.h.
126021         (is_infinite_or_zero, VASNPRINTF): Use isnand instead of isnan.
126022         * tests/test-frexp.c: Include isnand.h instead of isnan.h.
126023         (main): Use isnand instead of isnan.
126024         * tests/test-round1.c: Include isnand.h.
126025         (main): Use isnand instead of isnan.
126026         * tests/test-round2.c: Include isnand.h instead of isnan.h.
126027         (ISNAN): Set to isnand instead of isnan.
126028         * tests/test-trunc1.c: Include isnand.h.
126029         (main): Use isnand instead of isnan.
126030         * tests/test-trunc2.c: Include isnand.h instead of isnan.h.
126031         (equal): Use isnand instead of isnan.
126032         * MODULES.html.sh (Mathematics <math.h>): Replace isnan-nolibm with
126033         isnand-nolibm.
126034         * NEWS: Mention the change.
126036 2008-01-25  Paul Eggert  <eggert@cs.ucla.edu>
126037             Bruno Haible  <bruno@clisp.org>
126039         * m4/signbit.m4 (gl_SIGNBIT): Require a macro definition. Test whether
126040         the GCC builtins for signbits are present and set
126041         REPLACE_SIGNBIT_USING_GCC if so.
126042         * lib/math.in.h (signbit): Define using GCC builtins if
126043         REPLACE_SIGNBIT_USING_GCC is set.
126044         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize
126045         REPLACE_SIGNBIT_USING_GCC.
126046         * modules/math (Makefile.am): Substitute REPLACE_SIGNBIT_USING_GCC.
126048 2008-01-25  Jim Meyering  <meyering@redhat.com>
126050         Prefer <config.h> over "config.h".  See autoconf doc for explanation.
126051         * lib/poll.c: Include <config.h>, not "config.h".
126052         * tests/test-getaddrinfo.c: Likewise.
126054 2008-01-25  Simon Josefsson  <simon@josefsson.org>
126056         * modules/sockets-tests: New file.
126058 2008-01-24  Simon Josefsson  <simon@josefsson.org>
126060         * modules/sockets: New module, can be used to call WSA_Startup and
126061         WSA_Cleanup when needed.
126063         * lib/sockets.h, lib/sockets.c: New files.
126065         * m4/sockets.m4: New file.
126067         * tests/test-sockets.c: New file.
126069 2008-01-19  Bruno Haible  <bruno@clisp.org>
126071         * doc/posix-headers: Renamed from doc/headers.
126072         * doc/posix-functions: Renamed from doc/functions.
126073         * doc/gnulib.texi: Update.
126075 2008-01-19  Bruno Haible  <bruno@clisp.org>
126077         * doc/glibc-functions/strcasestr.texi: Include contents of
126078         doc/functions/strcasestr.texi, fixing the list of platforms.
126079         * doc/functions/strcasestr.texi: Remove file.
126081 2008-01-19  Bruno Haible  <bruno@clisp.org>
126083         * doc/glibc-functions/memmem.texi: Include contents of
126084         doc/functions/memmem.texi.
126085         * doc/functions/memmem.texi: Remove file.
126087 2008-01-18  Bruno Haible  <bruno@clisp.org>
126089         * doc/glibc-functions/*.texi: New files.
126090         * doc/gnulib.texi (Glibc Function Substitutes): Completely rewritten
126091         to use the new files.
126093 2008-01-17  Bruno Haible  <bruno@clisp.org>
126095         * tests/test-gethostname.c (main): Fix printf statement.
126097 2008-01-17  Simon Josefsson  <simon@josefsson.org>
126099         * modules/gethostname-tests: New file.
126101         * tests/test-gethostname.c: New file.
126103 2008-01-17  Simon Josefsson  <simon@josefsson.org>
126105         * lib/gethostname.c: Include string.h unconditionally, strncpy is
126106         used by the UNAME case.  Reported by Bruno Haible
126107         <bruno@clisp.org>.
126109 2008-01-17  Eric Blake  <ebb9@byu.net>
126111         Convert c-strcasestr to be more efficient.
126112         * modules/c-strcasestr (Files): Use Two-Way, not KMP.
126113         (Depends-on): Add c-strcase, remove malloca, strnlen.
126114         * tests/test-c-strcasestr.c (main): Enhance test.
126115         * lib/c-strcasestr.c (c_strcasestr): Rewrite to new algorithm.
126117 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
126119         * build-aux/bootstrap (MSGID_BUGS_ADDRESS): New overridable variable.
126120         Use it in creating po/Makevars.
126122 2008-01-15  Simon Josefsson  <simon@josefsson.org>
126124         * lib/gc-libgcrypt.c (gc_init): Disable secure memory by default.
126125         Applications that requires it should initialize libgcrypt
126126         manually.
126128 2008-01-16  Simon Josefsson  <simon@josefsson.org>
126130         * lib/gethostname.c [!HAVE_UNAME]: Need string.h for strcpy.
126132 2008-01-15  Paul Eggert  <eggert@cs.ucla.edu>
126134         Fix problem with getdate on mingw32 reported by Simon Josefsson
126135         in <http://lists.gnu.org/r/bug-gnulib/2008-01/msg00192.html>.
126136         * lib/getdate.y (get_date): Check "HAVE_DECL_TZNAME", not "defined
126137         tzname", when deciding whether to declare tzname.
126138         * lib/strftime.c (tzname): Likewise.
126140 2008-01-15  Bruno Haible  <bruno@clisp.org>
126142         Work around a MacOS X 10.5 bug in frexpl().
126143         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Also check denormalized numbers.
126144         * doc/functions/frexpl.texi: Document the bug.
126145         Reported by Elias Pipping <pipping@gentoo.org>.
126147 2008-01-14  Eric Blake  <ebb9@byu.net>
126149         Touch up previous patch.
126150         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Fix typo.
126151         * doc/functions/strcasestr.texi (strcasestr): Document OpenBSD bug.
126153         Convert strcasestr module to use Two-Way algorithm.
126154         * modules/strcasestr-simple: New module, based on the old
126155         strcasestr, but with Two-Way rather than KMP.
126156         * modules/strcasestr (Depends-on): Change to strcasestr-simple.
126157         * lib/string.in.h (rpl_strcasestr): Declare.
126158         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Check for linear
126159         performance.
126160         * lib/strcasestr.c (strcasestr): Simplify, and avoid malloc.
126161         * modules/string (Makefile.am): Support strcasestr.
126162         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
126163         * modules/strcasestr-tests (Depends-on): Check for alarm.
126164         * tests/test-strcasestr.c: Augment test.
126165         * lib/str-two-way.h: Clean up stray macro.
126166         * NEWS: Document new module.
126167         * MODULES.html.sh (string handling): Likewise.
126168         * doc/functions/strcasestr.texi: New file.
126169         * doc/gnulib.texi (Function Substitutes): New node.  Move memmem
126170         here, since it is not a POSIX function.
126172 2008-01-14  Colin Watson  <cjwatson@debian.org>
126173             Bruno Haible  <bruno@clisp.org>
126175         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Also check whether strsignal
126176         works fine; if not, set REPLACE_STRSIGNAL.
126177         (gl_PREREQ_STRSIGNAL): Require AC_DECL_SYS_SIGLIST.
126178         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
126179         REPLACE_STRSIGNAL.
126180         * lib/string.in.h (strsignal): Consider REPLACE_STRSIGNAL.
126181         * modules/string (Makefile.am): Substitute REPLACE_STRSIGNAL.
126182         * tests/test-strsignal.c (main): Check out-of-range signal numbers.
126184 2008-01-14  Bruno Haible  <bruno@clisp.org>
126186         * modules/strsignal (Include): Change to <string.h>.
126188 2008-01-14  Colin Watson  <cjwatson@debian.org>
126190         * modules/argp (Notice): Add a notice recommending to change
126191         XGETTEXT_OPTIONS.
126192         (configure.ac): Invoke AM_XGETTEXT_OPTION if it exists.
126194 2008-01-13  Colin Watson  <cjwatson@debian.org>
126196         * modules/strsignal-tests: New file.
126197         * tests/test-strsignal.c: New file.
126199         * lib/strsignal.c: New file, from glibc with modifications.
126200         * lib/siglist.h: New file, from glibc with modifications.
126201         * lib/string.in.h (strsignal): New declaration.
126202         * m4/strsignal.m4: New file.
126203         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
126204         GNULIB_STRSIGNAL and HAVE_DECL_STRSIGNAL.
126205         * modules/strsignal: New file.
126206         * modules/string (Makefile.am): Substitute GNULIB_STRSIGNAL and
126207         HAVE_DECL_STRSIGNAL.
126209 2008-01-13  Bruno Haible  <bruno@clisp.org>
126211         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check that the
126212         locale encoding is not ASCII. Needed for OpenBSD 4.0.
126213         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
126214         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
126216 2008-01-13  Bruno Haible  <bruno@clisp.org>
126218         * lib/argp-fmtstream.h (__attribute__): Don't redefine if
126219         __STRICT_ANSI__ is set: it's not needed by any version of gcc.
126220         * lib/argp.h (__attribute__): Likewise.
126221         * lib/c-stack.c (__attribute__): Likewise.
126222         * lib/error.h (__attribute__): Likewise.
126223         * lib/fts.c (__attribute__): Likewise.
126224         * lib/openat.h (__attribute__): Likewise.
126225         * lib/stdio.in.h (__attribute__): Likewise.
126226         * lib/string.in.h (__attribute__): Likewise.
126227         * lib/utimens.c (__attribute__): Likewise.
126228         * lib/vasnprintf.h (__attribute__): Likewise.
126229         * lib/xalloc.h (__attribute__): Likewise.
126230         * lib/xprintf.h (__attribute__): Likewise.
126231         * lib/xstrtol.h (__attribute__): Likewise.
126232         * lib/xvasprintf.h (__attribute__): Likewise.
126234 2008-01-12  Bruno Haible  <bruno@clisp.org>
126236         * doc/gnulib.texi (Glibc Header File Substitutes): New chapter.
126237         * doc/glibc-headers/a.out.texi: New file.
126238         * doc/glibc-headers/aliases.texi: New file.
126239         * doc/glibc-headers/alloca.texi: New file.
126240         * doc/glibc-headers/ar.texi: New file.
126241         * doc/glibc-headers/argp.texi: New file.
126242         * doc/glibc-headers/argz.texi: New file.
126243         * doc/glibc-headers/byteswap.texi: New file.
126244         * doc/glibc-headers/crypt.texi: New file.
126245         * doc/glibc-headers/endian.texi: New file.
126246         * doc/glibc-headers/envz.texi: New file.
126247         * doc/glibc-headers/err.texi: New file.
126248         * doc/glibc-headers/error.texi: New file.
126249         * doc/glibc-headers/execinfo.texi: New file.
126250         * doc/glibc-headers/fpu_control.texi: New file.
126251         * doc/glibc-headers/fstab.texi: New file.
126252         * doc/glibc-headers/fts.texi: New file.
126253         * doc/glibc-headers/getopt.texi: New file.
126254         * doc/glibc-headers/ieee754.texi: New file.
126255         * doc/glibc-headers/ifaddrs.texi: New file.
126256         * doc/glibc-headers/libintl.texi: New file.
126257         * doc/glibc-headers/mcheck.texi: New file.
126258         * doc/glibc-headers/mntent.texi: New file.
126259         * doc/glibc-headers/obstack.texi: New file.
126260         * doc/glibc-headers/paths.texi: New file.
126261         * doc/glibc-headers/printf.texi: New file.
126262         * doc/glibc-headers/pty.texi: New file.
126263         * doc/glibc-headers/resolv.texi: New file.
126264         * doc/glibc-headers/shadow.texi: New file.
126265         * doc/glibc-headers/sysexits.texi: New file.
126266         * doc/glibc-headers/ttyent.texi: New file.
126268 2008-01-12  Jim Meyering  <meyering@redhat.com>
126270         announce-gen: emit Gnulib's git-based version string.
126271         * build-aux/announce-gen: Remove option: --gnulib-snapshot-time-stamp=S.
126272         New option --gnulib-version=V, where V is expected to be
126273         the output of running git describe in the gnulib directory.
126274         (get_tool_versions): Request feedback on xdelta.  I suspect it's
126275         not useful, and plan to stop publishing an xdelta file with each
126276         coreutils release.
126278         * build-aux/announce-gen: Also check for lzma-compressed files.
126280 2008-01-11  Bruno Haible  <bruno@clisp.org>
126282         * tests/test-memmem.c (main): Increase maximum allowed time.
126283         * tests/test-strstr.c (main): Likewise.
126285 2008-01-11  Bruno Haible  <bruno@clisp.org>
126287         * doc/functions/memmem.texi: Add more precisions about platforms.
126288         * doc/functions/strstr.texi: Likewise.
126290 2008-01-10  Eric Blake  <ebb9@byu.net>
126292         * m4/strstr.m4: Delete cruft from copy-n-paste.
126293         Reported by Bruno Haible.
126295 2008-01-10  Bruno Haible  <bruno@clisp.org>
126297         Make c-strstr rely on strstr.
126298         * lib/c-strstr.c: Don't include str-kmp.h.
126299         (c_strstr): Define in terms of strstr.
126300         * modules/c-strstr (Files): Remove lib/str-kmp.h.
126301         (Depends-on): Remove stdbool, malloca, strnlen. Add strstr.
126303 2008-01-10  Bruno Haible  <bruno@clisp.org>
126305         * doc/gnulib.texi (String Functions in C Locale): New section.
126306         * doc/c-ctype.texi: New file.
126307         * doc/c-strcase.texi: New file.
126308         * doc/c-strcaseeq.texi: New file.
126309         * doc/c-strcasestr.texi: New file.
126310         * doc/c-strstr.texi: New file.
126311         * doc/c-strtod.texi: New file.
126312         * doc/c-strtold.texi: New file.
126314 2008-01-10  Eric Blake  <ebb9@byu.net>
126316         * lib/relocatable.h: Fix a comment.
126318 2008-01-10  Eric Blake  <ebb9@byu.net>
126320         Share two-way algorithm.
126321         * lib/str-two-way.h: New file, merged from...
126322         * lib/memmem.c: ...here...
126323         * lib/strstr.c: ...and here.
126324         * modules/memmem (Files): Use it.
126325         * modules/strstr (Files): Likewise.
126327         Avoid quadratic strstr implementations.
126328         * lib/strstr.c: New file.
126329         * m4/strstr.m4: Likewise.
126330         * modules/strstr: Likewise.
126331         * modules/strstr-tests: Likewise.
126332         * tests/test-strstr.c: Likewise.
126333         * lib/string.in.h (rpl_strstr): Declare.
126334         (memmem) [GNULIB_POSIXCHECK]: Document speed issue.
126335         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Support strstr.
126336         * modules/string (Makefile.am): Likewise.
126337         * MODULES.html.sh (string handling): Mention new module.
126338         * doc/functions/strstr.texi (strstr): Document the bug.
126340 2008-01-10  Bruno Haible  <bruno@clisp.org>
126342         * lib/relocatable.h (relocate): State whether result is freshly
126343         allocated or not.
126344         * lib/relocatable.c (relocate): Return a freshly allocated string
126345         instead of a pointer to a privately held string.
126346         Reported by Sylvain Beucler <beuc@gnu.org>.
126348 2008-01-10  Colin Watson  <cjwatson@debian.org>
126350         * lib/canonicalize-lgpl.c [!_LIBC]: Fix typo in #if directive:
126351         s/S_ISNLK/S_ISLNK/.
126353 2008-01-09  Bruno Haible  <bruno@clisp.org>
126355         * doc/functions/memmem.texi: Use the same structure as snprintf.texi
126356         and other files.
126357         * m4/memmem.m4 (gl_FUNC_MEMMEM): Say "guessing no" instead of "no"
126358         if it's only a guess.
126359         * modules/memmem: Simplify by depending on memmem-simple.
126361 2008-01-09  Bruno Haible  <bruno@clisp.org>
126363         Work around OpenBSD 4.0 tdelete() bug.
126364         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Also check tdelete's return value.
126365         * lib/search.in.h: If REPLACE_TSEARCH is 1, define tsearch etc. as
126366         macros and don't redefine the enum values.
126367         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize REPLACE_TSEARCH.
126368         * modules/search (Makefile.am): Also substitute REPLACE_TSEARCH.
126369         * doc/functions/tdelete.texi: Document the OpenBSD 4.0 bug.
126371 2008-01-09  Bruno Haible  <bruno@clisp.org>
126373         * tests/test-wcwidth.c: Include <string.h> and localcharset.h.
126374         (main): Don't perform the tests if setlocale did not install a UTF-8
126375         locale. Needed on OpenBSD 4.0.
126376         * modules/wcwidth-tests (Depends-on): Add localcharset.
126378 2008-01-09  Paul Eggert  <eggert@cs.ucla.edu>
126380         gl_FUNC_ALLOCA no longer defines HAVE_ALLOCA_H unconditionally.
126381         See <http://lists.gnu.org/r/bug-gnulib/2007-12/msg00149.html>.
126382         * NEWS: announce this.
126383         * m4/alloca.m4 (gl_FUNC_ALLOCA): Don't define HAVE_ALLOCA_H.
126385 2008-01-09  Simon Josefsson  <simon@josefsson.org>
126386         and Eric Blake  <ebb9@byu.net>
126388         Add memmem-simple module.
126389         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): New macro.
126390         (gl_FUNC_MEMMEM): Separate performance from presence checks.
126391         * modules/memmem-simple: New file.
126392         * modules/memmem (Description): Tweak.
126393         * MODULES.html.sh (string handling): Mention new module.
126394         * doc/functions/memmem.texi (memmem): Distinguish which flaws are
126395         addressed by memmem-simple.
126396         * NEWS: Document the difference.
126398 2008-01-09  Eric Blake  <ebb9@byu.net>
126400         Give gcc some memmem optimization hints.
126401         * lib/string.in.h (memmem, memrchr, strchrnul, strnlen, strpbrk)
126402         (strcasestr): Declare as pure.
126403         * modules/memmem (Maintainer): Claim my implementation.
126405 2008-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
126407         Support AIX 6.1 and higher.
126408         * build-aux/config.libpath: Likewise.
126409         * build-aux/config.rpath: Likewise.
126411 2008-01-08  Jim Meyering  <meyering@redhat.com>
126412             Bruno Haible  <bruno@clisp.org>
126414         * lib/printf-parse.c (PRINTF_PARSE): Handle a size specifier "q"
126415         on MacOS X and a size specifier "I64" on mingw. Needed for PRIdMAX.
126416         Reported by Peter Fales in
126417         <http://lists.gnu.org/r/bug-coreutils/2007-12/msg00148.html>.
126419 2008-01-08  Bruno Haible  <bruno@clisp.org>
126421         * modules/unictype/category-of (Depends-on): Add
126422         unictype/category-none.
126423         * modules/unictype/category-and-tests (Depends-on): Add
126424         unictype/category-{L,N,Lu,Nd}.
126425         * modules/unictype/category-and-not-tests (Depends-on): Likewise.
126426         * modules/unictype/category-or-tests (Depends-on): Add
126427         unictype/category-{L,N}.
126428         * modules/unictype/category-name-tests (Depends-on): Add
126429         unictype/category-{Z,Nl}.
126430         Reported by Simon Josefsson.
126432 2008-01-08  Bruno Haible  <bruno@clisp.org>
126434         * lib/str-kmp.h (knuth_morris_pratt_unibyte): Document the calling
126435         convention better.
126436         * lib/mbsstr.c (knuth_morris_pratt_multibyte): Likewise.
126437         * lib/mbscasestr.c (knuth_morris_pratt_multibyte): Likewise.
126438         Reported by Peter Miller <millerp@canb.auug.org.au>.
126440 2008-01-08  Eric Blake  <ebb9@byu.net>
126442         Rewrite memmem to guarantee linear complexity without malloc.
126443         * lib/memmem.c (memmem): Use Two-Way rather than
126444         Knuth-Morris-Pratt, to allow O(1) space usage.
126445         (critical_factorization, two_way_short_needle)
126446         (two_way_long_needle): New functions.
126447         (knuth_morris_pratt): Delete.
126448         * modules/memmem (Depends-on): No longer need malloca or stdbool.
126449         Add stdint.
126450         * tests/test-memmem.c (main): Add tests for periodic needle and
126451         sublinear performance.
126452         * doc/functions/memmem.texi (memmem): Document other deficiencies
126453         in cygwin and older glibc.
126455 2008-01-08  Bruno Haible  <bruno@clisp.org>
126457         * modules/memmem-tests (Makefile.am): Remove TESTS_ENVIRONMENT
126458         augmentation.
126460 2008-01-08  Mike Frysinger  <vapier@gentoo.org>
126462         Add a configure time option: --disable-acl.
126463         * m4/acl.m4 (gl_FUNC_ACL): Wrap all ACL logic in a call to
126464         AC_ARG_ENABLE(acl).
126466 2008-01-06  Simon Josefsson  <simon@josefsson.org>
126468         * tests/test-localename.c: Don't include obsolete "setenv.h".
126470         * modules/localename-tests (Depends-on): Need unsetenv.
126472 2008-01-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
126474         * DEPENDENCIES: Require Texinfo version 4.6 or newer.
126476 2008-01-06  Colin Watson  <cjwatson@debian.org>
126478         * users.txt: Add man-db.
126480 2008-01-07  Bruno Haible  <bruno@clisp.org>
126482         * doc/gnulib-intro.texi (Library vs Reusable Code): Restore the
126483         previous section name.
126485 2008-01-07  Bruno Haible  <bruno@clisp.org>
126487         * lib/progname.c (set_program_name): Don't strip off a leading
126488         "lt-" prefix outside a .libs directory.
126489         Suggested by Paul Eggert.
126491 2008-01-01  Sylvain Beucler  <beuc@gnu.org>
126492             Bruno Haible  <bruno@clisp.org>
126494         Improve memory cleanup in 'relocatable' module.
126495         * lib/relocatable.h (compute_curr_prefix): Change return type to
126496         'char *'.
126497         * lib/relocatable.c (compute_curr_prefix): Change return type to
126498         'char *'. Free curr_installdir after use.
126499         (relocate): Free curr_prefix_better after use.
126500         * lib/progreloc.c (prepare_relocate): Free curr_prefix after use.
126502 2008-01-01  Bruno Haible  <bruno@clisp.org>
126504         * tests/test-wcwidth.c (main): Relax test of U+2060. Avoids a test
126505         failure on older glibc systems.
126506         Reported by Peter Fales <psfales@alcatel-lucent.com>.
126508 2008-01-05  Eric Blake  <ebb9@byu.net>
126510         Avoid quadratic system memmem.
126511         * m4/memmem.m4 (gl_FUNC_MEMMEM): Check for quadratic memmem.
126512         Reported by Ralf Wildenhues.
126514         Fix memmem test for mingw.
126515         * modules/memmem-tests (configure.ac): Check for alarm.
126516         * tests/test-memmem.c (main): Avoid alarm on platforms that lack
126517         it.
126518         * doc/functions/memmem.texi: New file.
126519         * doc/gnulib.texi (Function Substitutes): Add memmem.
126520         Reported by Bruno Haible.
126522 2008-01-04  Bruno Haible  <bruno@clisp.org>
126524         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP):
126525         Require gl_HEADER_STRINGS_H_DEFAULTS, not
126526         gl_HEADER_STRING_H_DEFAULTS.
126528 2008-01-04  Eric Blake  <ebb9@byu.net>
126530         Shorten duration of memmem test.
126531         * tests/test-memmem.c (main): Use alarm to declare failure if test
126532         is taking too long.
126533         Reported by Ralf Wildenhues.
126535 2007-12-21  Simon Josefsson  <simon@josefsson.org>
126537         * modules/relocatable-prog-wrapper (Depends-on): Add intprops and
126538         string, needed by strerror.
126540 2008-01-03  Colin Watson  <cjwatson@debian.org>
126541             Bruno Haible  <bruno@clisp.org>
126543         * doc/gnulib-tool.texi (Localization): New section.
126545 2008-01-02  Bruno Haible  <bruno@clisp.org>
126547         * lib/memmem.c (knuth_morris_pratt, memmem): Change all 'char *'
126548         variables to 'unsigned char *' type.
126549         Reported by Paul Eggert.
126551 2008-01-02  Jim Meyering  <jim@meyering.net>
126553         * lib/version-etc.c (COPYRIGHT_YEAR): Increase for new year.
126555 2007-12-31  Jim Meyering  <jim@meyering.net>
126557         Avoid use of private FTS type name.
126558         * lib/fts.c (fts_sort): Use FTSENT rather than "struct _ftsent".
126560 2007-12-30  Karl Berry  <karl@gnu.org>
126562         * doc/gnulib.texi (Library vs. Reusable Code): remove period, to
126563         work around defect in Texinfo and/or the standalone Info browser.
126565 2007-12-30  Bruno Haible  <bruno@clisp.org>
126567         Unify 5 copies of the KMP code.
126568         * lib/str-kmp.h: New file.
126569         * lib/c-strcasestr.c: Include str-kmp.h.
126570         (knuth_morris_pratt): Remove function.
126571         (c_strcasestr): Update.
126572         * lib/c-strstr.c: Include str-kmp.h.
126573         (knuth_morris_pratt): Remove function.
126574         (c_strcasestr): Update.
126575         * lib/mbscasestr.c: Include str-kmp.h.
126576         (knuth_morris_pratt_unibyte): Remove function.
126577         * lib/mbsstr.c: Include str-kmp.h.
126578         (knuth_morris_pratt_unibyte): Remove function.
126579         * lib/strcasestr.c: Include str-kmp.h.
126580         (knuth_morris_pratt): Remove function.
126581         (strcasestr): Update.
126582         * modules/c-strcasestr (Files): Add lib/str-kmp.h.
126583         * modules/c-strstr (Files): Likewise.
126584         * modules/mbscasestr (Files): Likewise.
126585         * modules/mbsstr (Files): Likewise.
126586         * modules/strcasestr (Files): Likewise.
126587         Suggested by Paul Eggert.
126589 2007-12-30  Bruno Haible  <bruno@clisp.org>
126591         * lib/xmalloca.c (xmmalloca): Don't define if HAVE_ALLOCA is not
126592         defined.
126594 2007-12-30  Bruno Haible  <bruno@clisp.org>
126596         * lib/xmalloca.h: Include xalloc.h.
126597         (xnmalloca): New macro.
126599 2007-12-30  Bruno Haible  <bruno@clisp.org>
126601         * lib/malloca.h (nmalloca): New macro.
126602         * lib/c-strcasestr.c (knuth_morris_pratt): Use it.
126603         * lib/c-strstr.c (knuth_morris_pratt): Likewise.
126604         * lib/mbscasestr.c (knuth_morris_pratt_unibyte,
126605         knuth_morris_pratt_multibyte): Likewise.
126606         * lib/mbsstr.c (knuth_morris_pratt_unibyte,
126607         knuth_morris_pratt_multibyte): Likewise.
126608         * lib/memmem.c (knuth_morris_pratt): Likewise.
126609         * lib/strcasestr.c (knuth_morris_pratt): Likewise.
126611 2007-12-25  Bruno Haible  <bruno@clisp.org>
126613         Fixup after 2007-10-17 commit. Ensure that 'glob' stays under LGPLv2+.
126614         * lib/glob.c: Don't include openat.h.
126615         (link_exists2_p): Add back the code that deals with the
126616         !GLOB_ALTDIRFUNC case.
126617         (link_exists_p) [!_LIBC && !HAVE_FSTATAT]: Just call link_exists2_p and
126618         let it do the filename concatenation.
126619         * m4/glob.m4 (gl_PREREQ_GLOB): Add check for fstatat.
126620         * modules/glob (Depends-on): Remove openat.
126622 2007-12-31  Bruno Haible  <bruno@clisp.org>
126624         * modules/dirfd (License): Change to LGPLv2+.
126625         Approved by Jim Meyering.
126627 2007-12-29  Paul Eggert  <eggert@cs.ucla.edu>
126629         * lib/memmem.c (knuth_morris_pratt): Check for size_t overflow
126630         when multiplying M by sizeof (size_t).
126632 2007-12-10  Martin Lambers  <marlam@marlam.de>
126634         Override getpagesize on mingw.
126635         * lib/getpagesize.c: New file.
126636         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Enable replacement on mingw.
126637         * modules/getpagesize (Files): Add lib/getpagesize.c.
126638         * lib/unistd.in.h (getpagesize): Declare if we are using a replacement.
126639         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
126640         REPLACE_GETPAGESIZE.
126641         * modules/unistd (Makefile.am): Substitute REPLACE_GETPAGESIZE.
126643 2007-12-25  Bruno Haible  <bruno@clisp.org>
126645         * modules/localcharset (Notice): New field.
126646         (configure.ac): Define LOCALCHARSET_TESTS_ENVIRONMENT.
126647         Suggested by Ben Pfaff <blp@cs.stanford.edu>.
126649 2007-12-25  Paul Eggert  <eggert@cs.ucla.edu>
126650             Bruno Haible  <bruno@clisp.org>
126652         Avoid using the syntax symbol() in formatted documentation.
126653         * MODULES.html.sh (func_module): When replacing symbol() with a
126654         hyperlink, remove the parentheses. Show an error if some remain.
126655         Recognize and render the '...' syntax.
126656         * doc/alloca-opt.texi: Remove parentheses from symbol reference.
126657         Rework. Add paragraph about GCC's inlining.
126658         * doc/alloca.texi: Likewise.
126659         * doc/error.texi: Remove parentheses from symbol reference.
126660         * doc/gnulib-intro.texi: Likewise.
126661         * doc/gnulib.texi (alloca, alloca-opt): New nodes.
126662         * modules/fnmatch (Description): Reword to say "the ... function".
126663         * modules/full-read (Description): Likewise.
126664         * modules/full-write (Description): Likewise.
126665         * modules/safe-read (Description): Likewise.
126666         * modules/safe-write (Description): Likewise.
126667         * modules/strchrnul (Description): Likewise.
126668         * modules/trim (Description): Likewise.
126669         * modules/error (Description): Remove parentheses from symbol
126670         references.
126671         * modules/verror (Description): Likewise.
126672         Reported by Karl Berry.
126674 2007-12-25  Bruno Haible  <bruno@clisp.org>
126676         Fixup after 2007-10-16 commit.
126677         * lib/glob.c (glob_in_dir): Don't use ISO C99 syntax.
126679 2007-12-24  Bruno Haible  <bruno@clisp.org>
126681         Make --enable-relocatable work with DESTDIR.
126682         * build-aux/install-reloc: Accept another argument 'destdir'. Use it
126683         to compute installdir from destprog.
126684         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV,
126685         also set the RELOC_DESTDIR variable.
126686         Reported by Левашев Иван <octagram@bluebottle.com>.
126688 2007-12-24  Bruno Haible  <bruno@clisp.org>
126690         Fix link error due to xalloc_die().
126691         * lib/progreloc.c: When NO_XMALLOC is defined, use areadlink instead
126692         of xreadlink.
126693         * lib/relocwrapper.c: Update comments.
126694         * build-aux/install-reloc: Remove xreadlink.c from file list.
126695         * modules/relocatable-prog-wrapper (Files): Remove xreadlink.h and
126696         xreadlink.c.
126697         Reported by Левашев Иван <octagram@bluebottle.com>.
126699 2007-12-24  Bruno Haible  <bruno@clisp.org>
126701         Split setenv module into setenv and unsetenv. Get rid of setenv.h.
126702         * lib/setenv.h: Remove file.
126703         * lib/stdlib.in.h (setenv, unsetenv): New declarations, moved here from
126704         lib/setenv.h.
126705         * modules/setenv (Files): Remove lib/setenv.h, lib/unsetenv.c.
126706         (Depends-on): Add stdlib.
126707         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR. Don't invoke
126708         gl_FUNC_UNSETENV.
126709         (Include): Replace setenv.h with <stdlib.h>.
126710         * modules/unsetenv: New file.
126711         * lib/setenv.c: Include <stdlib.h> first, after alloca.h.
126712         * lib/unsetenv.c: Include <stdlib.h> first.
126713         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_SETENV_SEPARATE): Require
126714         gl_STDLIB_H_DEFAULTS. Conditionally set HAVE_SETENV to 0.
126715         (gl_FUNC_UNSETENV): Require gl_STDLIB_H_DEFAULTS. Conditionally set
126716         HAVE_UNSETENV to 0. Set VOID_UNSETENV as an AC_SUBSTed variable.
126717         * modules/stdlib (Makefile.am): Substitute also GNULIB_SETENV,
126718         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
126719         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_SETENV,
126720         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
126721         * doc/functions/unsetenv.texi: Update.
126722         * modules/xsetenv (Depends-on): Add unsetenv.
126723         * modules/getdate (Depends-on): Likewise.
126724         * lib/xsetenv.h: Include <stdlib.h> instead of setenv.h.
126725         * lib/xsetenv.c: Don't include setenv.h.
126726         * lib/getdate.y: Likewise.
126727         * lib/relocwrapper.c: Likewise.
126728         * modules/relocatable-prog-wrapper (Files): Remove lib/setenv.h.
126729         (Depends-on): Add stdlib.
126730         * NEWS: Mention the changes.
126731         Reported by Левашев Иван <octagram@bluebottle.com>.
126733 2007-12-23  Bruno Haible  <bruno@clisp.org>
126735         * lib/memmem.c (memmem): Use lowercase variable names. Tab
126736         indentation.
126738 2007-12-23  Bruno Haible  <bruno@clisp.org>
126740         * lib/c-strcasestr.c: Add more comments.
126741         * lib/c-strstr.c: Likewise.
126742         * lib/mbscasestr.c: Likewise.
126743         * lib/mbsstr.c: Likewise.
126744         * lib/strcasestr.c: Likewise.
126745         * lib/memmem.c: Likewise.
126747 2007-12-23  Bruno Haible  <bruno@clisp.org>
126749         * tests/test-memmem.c: Include <string.h> first.
126751 2007-12-22  Bruno Haible  <bruno@clisp.org>
126753         * gnulib-tool (func_create_testdir): Change $auxdir while generating
126754         the contents of $testsbase.
126755         Reported by Ralf Wildenhues.
126757 2007-12-22  Bruno Haible  <bruno@clisp.org>
126759         * gnulib-tool (func_emit_tests_Makefile_am): Replace local_ldadd with
126760         two variables local_ldadd_before, local_ldadd_last.
126762 2007-12-20  Eric Blake  <ebb9@byu.net>
126764         Work around circular library issue when cross-compiling.
126765         * lib/progname.c (set_program_name): Use strncmp, not memcmp, so
126766         that progname.o does not need to pull in rpl_memcmp.
126768 2007-12-19  Eric Blake  <ebb9@byu.net>
126770         Fix memmem to avoid O(n^2) worst-case complexity.
126771         * lib/memmem.c (knuth_morris_pratt): New function.
126772         (memmem): Use it if first few naive iterations fail.
126773         * m4/memmem.m4 (gl_FUNC_MEMMEM): Detect cygwin bug.
126774         * modules/memcmp (License): Set to LGPLv2+, not LGPL.
126775         * modules/memchr (License): Likewise.
126776         * modules/memmem (Depends-on): Add memcmp, memchr, stdbool, and
126777         malloca.
126778         * tests/test-memmem.c: Rewrite, borrowing ideas from
126779         test-mbsstr1.c; the old version wouldn't even compile!
126780         * modules/memmem-tests: New file.
126781         * lib/string.in.h (rpl_memmem): Add declaration.
126782         * modules/string (Makefile.am): Substitute REPLACE_MEMMEM.
126783         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Default for
126784         REPLACE_MEMMEM.
126786 2007-12-18  Paul Eggert  <eggert@cs.ucla.edu>
126788         Fix problem with _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H on VMS.
126789         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_INTTYPES_H): Define
126790         before any system include files, and undef after them all.  This
126791         should fix a problem on VMS reported by John E. Malmberg in
126792         <http://lists.gnu.org/r/bug-gnulib/2007-12/msg00118.html>.
126794 2007-12-17  Eric Blake  <ebb9@byu.net>
126796         Revert addition of verify, for BSD/OS.
126797         * lib/fseeko.c [!HAVE_FSEEKO]: Allow off_t > long, even though it
126798         can't handle large files, for the sake of obsolete platforms.
126799         * modules/fseeko (Depends-on): Remove verify.
126800         * doc/functions/fseeko.texi (fseeko): Document BSD/OS limitation.
126801         * doc/functions/ftello.texi (ftello): Likewise.
126802         * doc/functions/fgetpos.texi (fgetpos): Likewise.
126803         Reported by Larry Jones.
126805 2007-12-17  Petr Salinger  <Petr.Salinger@seznam.cz>
126807         getcwd.c: Use a more readable witness: HAVE_OPENAT_SUPPORT
126808         * lib/getcwd.c: Define and use HAVE_OPENAT_SUPPORT, in place of AT_FDCWD.
126810 2007-12-17  Jim Meyering  <meyering@redhat.com>
126812         Port to GNU/kFreeBSD - FreeBSD kernel + GNU libc,
126813         which has no openat syscall, yet <fcntl.h> does define AT_FDCWD.
126814         * lib/getcwd.c: Undef AT_FDCWD if there is no openat function.
126815         * modules/getcwd (Depends-on): Add openat.
126816         Reported by Petr Salinger.
126818 2007-12-17  Bruno Haible  <bruno@clisp.org>
126820         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Use GL_NOCRASH to
126821         avoid a segmentation fault of the configure test on x86_64 systems.
126823 2007-12-15  Jim Meyering  <meyering@redhat.com>
126825         * build-aux/gnupload (GPG): Don't hard-code absolute name of gpg binary.
126827 2007-12-13  Eric Blake  <ebb9@byu.net>
126829         Another fseek test.
126830         * tests/test-fseek.c (main): Also test ungetc handling.
126831         * tests/test-fseeko.c (main): Likewise.
126832         * modules/fseeko (Depends-on): Add verify.
126833         * lib/fseeko.c [!HAVE_FSEEKO]: Verify that off_t is not too
126834         large.
126835         Reported by Larry Jones.
126837         Fix fseeko on mingw.
126838         * lib/fseeko.c (rpl_fseeko) [_IOERR]: Reset EOF flag on successful
126839         seek.
126841         Beef up fseek tests.
126842         * tests/test-fseek.c (main): Also test eof handling.
126843         * tests/test-fseeko.c (main): Likewise.
126844         Reported by Larry Jones.
126846 2007-12-13  Larry Jones  <lawrence.jones@siemens.com>  (tiny change)
126848         Fix fseeko on BSD-based platforms.
126849         * lib/fseeko.c (rpl_fseeko) [__sferror]: Reset EOF flag on
126850         successful seek.
126852 2007-12-12  Eric Blake  <ebb9@byu.net>
126854         Allow circular dependency of separate libtests.a
126855         * gnulib-tool (func_emit_tests_Makefile_am): Add AM_LIBTOOLFLAGS
126856         when use_libtests.
126858 2007-12-11  Eric Blake  <ebb9@byu.net>
126860         Fix bug with -0.0L in previous patch.
126861         * lib/isnan.c (rpl_isnanl): Make robust to -0.0L and pad bits.
126862         * tests/test-isnan.c (main): Also test on zeroes.
126863         * tests/test-isnanf.c (main): Likewise.
126864         * tests/test-isnanl.h (main): Likewise.
126866         Detect pseudo-denormals on x86 even when cross-compiling.
126867         * lib/isnan.c (rpl_isnanl) [!KNOWN_EXPBIT0_LOCATION
126868         && USE_LONG_DOUBLE && x86]: Add one more check to filter out
126869         invalid bit patterns that happen to satisfy ==.
126871         Avoid link failures with separate libtests.a.
126872         * gnulib-tool (func_emit_tests_Makefile_am): Also list local_ldadd
126873         last, to satisfy circular dependencies.
126875 2007-12-11  Eric Blake  <ebb9@byu.net>
126876         and Bruno Haible  <bruno@clisp.org>
126878         Fix OpenBSD 4.0 <float.h> handling of long double.
126879         * m4/float_h.m4 (gl_FLOAT_H): Also claim OpenBSD is broken.
126880         * lib/float.in.h [__OpenBSD__]: Add fixes for OpenBSD.
126881         * doc/headers/float.texi (float.h): Document OpenBSD bug.
126883 2007-12-11  Jim Meyering  <meyering@redhat.com>
126885         * users.txt: Add libvirt.
126887         Support versions of autoconf prior to 2.59c.
126888         * gnulib-tool (func_emit_initmacro_done): Define m4_foreach_w
126889         if it is not already defined.
126891 2007-12-09  Bruno Haible  <bruno@clisp.org>
126893         Let 'gnulib-tool --import' collect sources needed for the tests in
126894         tests/ rather than in lib/.
126895         * gnulib-tool (func_emit_tests_Makefile_am): Accept use_libtests
126896         argument. If true, add rules to generate libtests.a, and put libtests.a
126897         into $(LDADD). Consider source files in subdirectories and set
126898         uses_subdirs.
126899         (func_emit_initmacro_start, func_emit_initmacro_end,
126900         func_emit_initmacro_done): Pass all arguments explicitly.
126901         (func_import): Determine two module lists main_modules,
126902         testsrelated_modules. Determine use_libtests. Determine two variables
126903         sed_transform_main_lib_file, sed_transform_testsrelated_lib_file
126904         instead of just sed_transform_lib_file. Determine two variables
126905         main_files and testsrelated_files. Compute 'files' as the union of
126906         both. Adjust sed_rewrite_old_files, sed_rewrite_new_files,
126907         func_add_or_update. In the generated gnulib-comp.m4, collect the
126908         object files for tests/ in different variables than those for lib/.
126909         Substitute LIBTESTS_LIBDEPS.
126910         (func_create_testdir): Combine the uses_subdirs results from
126911         func_emit_lib_Makefile_am and from func_emit_tests_Makefile_am.
126913 2007-12-09  Bruno Haible  <bruno@clisp.org>
126915         * gnulib-tool (func_emit_tests_Makefile_am): Expand references to
126916         the build-aux directory.
126918 2007-12-09  Bruno Haible  <bruno@clisp.org>
126920         * gnulib-tool (func_emit_tests_Makefile_am): Remove redundant code
126921         introduced on 2006-09-09.
126923 2007-12-07  Jim Meyering  <meyering@redhat.com>
126925         Let these macros work also with autoconf-2.59.
126926         * m4/getline.m4 (gl_FUNC_GETLINE): Require only autoconf-2.59.  2.60
126927         is not needed, since gnulib now permits use of AC_CHECK_DECLS_ONCE.
126928         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
126930 2007-12-06  Jim Meyering  <meyering@redhat.com>
126932         Avoid a configure-time syntax error in gl_FUNC_ACL.
126933         * m4/acl.m4 (gl_FUNC_ACL): Be careful to check for the acl_trivial
126934         function in each branch, before testing the cache variable.
126936 2007-12-04  Eric Blake  <ebb9@byu.net>
126938         Make scripts executable.
126939         * build-aux/config.guess: Add execute permissions.
126940         * build-aux/config.sub: Likewise.
126941         * build-aux/gendocs.sh: Likewise.
126943         Fix frexp on mingw.
126944         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Detect mingw bug when
126945         cross-compiling.
126946         * doc/functions/frexp.texi (frexp): Document the bug.
126948         Make cygwin fseeko check more reliable.
126949         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Use cygwin
126950         version numbers, rather than unrelated feature check.
126951         * doc/functions/fseeko.texi (fseeko): Tweak failure report.
126952         * doc/functions/ftello.texi (ftello): Likewise.
126953         Reported by Bruno Haible.
126955         * m4/strerror.m4: Bump version number.
126957 2007-12-03  Bruno Haible  <bruno@clisp.org>
126959         * doc/functions/mprotect.texi: Mention the mingw problem.
126961 2007-12-03  Eric Blake  <ebb9@byu.net>
126963         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Ensure
126964         REPLACE_STRERROR is initialized before this macro.
126966 2007-12-03  Paul Eggert  <eggert@cs.ucla.edu>
126968         Add support for Solaris 10 ACLs.  Also, ACLs are Gnulib, not Autoconf.
126969         * modules/acl (configure.ac): Rename AC_FUNC_ACL to gl_FUNC_ACL.
126970         * m4/acl.m4 (gl_FUNC_ACL): Renamed from AC_FUNC_ACL.  On Solaris,
126971         put -lsec in even for programs other than 'ls'.  This fixes a problem
126972         for gettext reported by Bruno Haible in
126973         <http://lists.gnu.org/r/bug-gnulib/2007-12/msg00007.html>.
126974         * lib/acl.c (copy_acl, qset_acl) [USE_ACL && defined ACL_NO_TRIVIAL]:
126975         Add support for Solaris 10.  This isn't efficient, but should get the
126976         job done for now.
126978 2007-12-03  James Youngman  <jay@gnu.org>
126980         * doc/regexprops-generic.texi: change "an close-group" to "a
126981         close-group" and "illegal" to "not allowed".
126983 2007-11-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
126985         * lib/unictype/pr_byname.c: Include unictype/pr_byname.h instead of
126986         pr_byname.h. Needed for the rare case when the maintainer has done
126987         "make maintainer-clean" in the source directory and then attempts a
126988         build outside the source directory.
126989         * lib/unictype/scripts.c: Include unictype/scripts_byname.h instead of
126990         scripts_byname.h.
126992 2007-12-02  Martin Lambers  <marlam@marlam.de>
126993             Bruno Haible  <bruno@clisp.org>
126995         * lib/getpagesize.h: Remove file.
126996         * lib/unistd.in.h: Include declaration of getpagesize here.
126997         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Renamed from gl_GETPAGESIZE.
126998         Invoke gl_UNISTD_H_DEFAULTS. Set HAVE_GETPAGESIZE, HAVE_OS_H,
126999         HAVE_SYS_PARAM_H.
127000         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETPAGESIZE,
127001         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
127002         * modules/getpagesize (Files): Remove lib/getpagesize.h.
127003         (Depends-on): Add unistd.
127004         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
127005         (Include): Use <unistd.h> instead of getpagesize.h.
127006         * modules/unistd (Makefile.am): Substitute also GNULIB_GETPAGESIZE,
127007         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
127008         * m4/pagealign_alloc.m4 (gl_PREREQ_PAGEALIGN_ALLOC): Remove
127009         gl_GETPAGESIZE invocation, already handled by module dependency.
127010         * lib/pagealign_alloc.c: Don't include getpagesize.h.
127012 2007-12-02  Bruno Haible  <bruno@clisp.org>
127014         * modules/strings-tests: New file.
127015         * tests/test-strings.c: New file.
127017         Move declarations of str{,n}casecmp from <string.h> to <strings.h>.
127018         * lib/strings.in.h: New file.
127019         * lib/string.in.h (strcasecmp, strncasecmp): Remove declarations.
127020         * m4/strings_h.m4: New file.
127021         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Remove initialization
127022         of HAVE_STRCASECMP, HAVE_DECL_STRNCASECMP.
127023         * modules/strings: New file.
127024         * modules/string (Makefile.am): Update.
127025         * modules/strcase (Include): Mention <strings.h>, not <string.h>.
127026         Reported by Karl Berry.
127028 2007-12-01  Eric Blake  <ebb9@byu.net>
127030         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Rewrite to
127031         accommodate fix in cygwin 1.5.25.
127033 2007-12-01  Jim Meyering  <meyering@redhat.com>
127035         Fix a bug that inhibited much of the utf8-optimization in regcomp.c.
127036         * lib/regcomp.c (optimize_utf8): Fix a typo, s/idx/ctx_type/,
127037         that would inhibit utf8-optimization of a regexp containing line-
127038         or buffer-anchors, e.g., `^', `$'.
127040 2007-11-30  Bruno Haible  <bruno@clisp.org>
127042         * lib/lock.h (gl_recursive_lock_init) [PTHREAD &&
127043         PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Call
127044         glthread_recursive_lock_init.
127045         * lib/lock.c (glthread_recursive_lock_init)
127046         [PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: New function.
127047         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
127049 2007-11-28  Paul Eggert  <eggert@cs.ucla.edu>
127051         New function qset_acl, like set_acl but with syscall semantics.
127052         * lib/acl.h (qset_acl): New decl.
127053         * lib/acl.c (qset_acl): New function.
127054         (set_acl): Use new function.  Use more-consistent diagnostics.
127056 2007-11-28  Jim Meyering  <meyering@redhat.com>
127058         * modules/physmem (License): Change from GPL to LGPLv2+.
127060 2007-11-26  Bruno Haible  <bruno@clisp.org>
127062         * lib/vasnprintf.c (decode_long_double): Don't abort if the
127063         'long double' type has excess precision.
127064         Reported by Jim Meyering in
127065         <http://lists.gnu.org/r/bug-gnulib/2007-11/msg00120.html>.
127067 2007-11-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
127069         * doc/fdl.texi, doc/gpl-3.0.texi, doc/lgpl-3.0.texi:
127070         Sync from <http://gnu.org/licenses>.
127071         * modules/agpl-3.0, doc/agpl-3.0.texi: New module,
127072         with license text from same location.
127073         * doc/maintain.texi, doc/standards.texi:  Sync from
127074         <http://savannah.gnu.org/projects/gnustandards>.
127076 2007-11-22  Ondřej Vašík  <ovasik@redhat.com>
127077         and Jim Meyering  <meyering@redhat.com>
127079         Adjust getdate' grammar to accept a slightly more regular language.
127080         E.g., accept "YYYYMMDD +N days" as well as "YYYYMMDD N days".
127081         Before, the former was rejected.
127082         * lib/getdate.y (digits_to_date_time): New function, factored
127083         out of ...
127084         (number): ...here.  Just call digits_to_date_time.
127085         (hybrid): New non-terminal to handle an <unsigned number,
127086         signed relative offset> sequence consistently.
127088 2007-11-18  Jim Meyering  <meyering@redhat.com>
127090         Pull my changes from coreutils:
127091         bootstrap: fix typo to enable use of $gnulib_tool_option_extras.
127092         * build-aux/bootstrap (gnulib_tool_options): Add a space before the
127093         use of $gnulib_tool_option_extras, so that it's separated from the
127094         preceding argument.
127096         Fix bootstrap failure to handle files like lib/uniwidth/cjk.h.
127097         * build-aux/bootstrap (cp_mark_as_generated): Create any required
127098         parent destination directories before copying a file into place.
127100 2007-11-18  Sergey Poznyakoff  <gray@gnu.org.ua>
127102         bootstrap: work also with 4-argument variant of AC_INIT
127103         * build-aux/bootstrap (gnulib_extra_files): Adjust sed command.
127105 2007-11-16  Paul Eggert  <eggert@cs.ucla.edu>
127107         Port test-getaddrinfo to Solaris.
127108         Problem reported by Bruno Haible in
127109         <http://lists.gnu.org/r/bug-gnulib/2007-03/msg00171.html>.
127110         * tests/test-getaddrinfo.c (simple): Add a comment asking for an
127111         explanation of setting 'hints'.
127112         Don't reject an implementation merely because it returns EAI_SERVICE.
127113         (EAI_SERVICE): Define to 0 if not defined.
127115 2007-11-15  Paul Eggert  <eggert@cs.ucla.edu>
127117         The license of gnu-make and posix-shell is now "GPLed build tool".
127118         * modules/gnu-make (License): Likewise.
127119         * modules/posix-shell (License): Likewise.
127121         New module posix-shell, for determining a POSIX shell
127122         or perhaps something that is close enough to a POSIX shell.
127123         * m4/posix-shell.m4: New file.
127124         * modules/posix-shell: New file.
127126         * MODULES.html.sh: Mention new module.
127128         New module gnu-make, for determining whether we're using GNU Make.
127129         * m4/gnu-make.m4: New file.
127130         * modules/gnu-make: New file.
127131         * MODULES.html.sh: Mention new module.
127133 2007-11-14  Jim Meyering  <meyering@redhat.com>
127135         Define a sometimes-link-required function using ARGMATCH_DIE_DECL.
127136         * tests/test-argmatch.c (ARGMATCH_DIE_DECL): When defined,
127137         use this macro to create a function _definition_.
127138         Remove useless "#undef ARGMATCH_DIE".
127140 2007-11-14  Bruno Haible  <bruno@clisp.org>
127142         * lib/config.charset: Update for OpenBSD 4.1.
127143         Reported and helped by Ben Pfaff <blp@cs.stanford.edu>.
127145 2007-11-12  Paul Eggert  <eggert@cs.ucla.edu>
127147         Document 64-bit #if problems in stdint.texi.
127148         * doc/headers/stdint.texi (stdint.h): Mention problems with
127149         64-bit-#if, and how to work around them.
127151         Don't insist on 'long long int' support in the preprocessor.  It
127152         breaks too many things.  For example, PRIdMAX still uses a 'long
127153         long int' format with the latest Sun compiler, even though
127154         HAVE_LONG_LONG_INT isn't defined due to that compiler's
127155         preprocessor problem.  This causes the latest coreutils to dump
127156         core on Solaris 10 sparc with the Sun C compiler.
127157         Instead, fix the 2007-10-16 problem in a different way, by evaluating
127158         the troublesome expressions at configure-time, not at #if-time.
127159         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): Don't test the
127160         preprocessor.
127161         * m4/inttypes.m4 (gl_INTTYPES_H): Move the #if checks into
127162         compile-time C checks, done at 'configure'-time.
127163         (gl_INTTYPES_CHECK_LONG_LONG_INT_CONDITION): New macro.
127164         * modules/inttypes (Makefile): Substitute the new symbols that
127165         gl_INTTYPES_H now generates.
127166         * lib/inttypes.in.h: Don't use constants wider than 'long' in #if.
127168 2007-11-12  Bruno Haible  <bruno@clisp.org>
127170         Tests for Unicode character classification functions.
127172         * modules/unictype/bidicategory-byname-tests: New file.
127173         * modules/unictype/bidicategory-name-tests: New file.
127174         * modules/unictype/bidicategory-of-tests: New file.
127175         * modules/unictype/bidicategory-test-tests: New file.
127176         * modules/unictype/block-list-tests: New file.
127177         * modules/unictype/block-of-tests: New file.
127178         * modules/unictype/block-test-tests: New file.
127179         * modules/unictype/category-C-tests: New file.
127180         * modules/unictype/category-Cc-tests: New file.
127181         * modules/unictype/category-Cf-tests: New file.
127182         * modules/unictype/category-Cn-tests: New file.
127183         * modules/unictype/category-Co-tests: New file.
127184         * modules/unictype/category-Cs-tests: New file.
127185         * modules/unictype/category-L-tests: New file.
127186         * modules/unictype/category-Ll-tests: New file.
127187         * modules/unictype/category-Lm-tests: New file.
127188         * modules/unictype/category-Lo-tests: New file.
127189         * modules/unictype/category-Lt-tests: New file.
127190         * modules/unictype/category-Lu-tests: New file.
127191         * modules/unictype/category-M-tests: New file.
127192         * modules/unictype/category-Mc-tests: New file.
127193         * modules/unictype/category-Me-tests: New file.
127194         * modules/unictype/category-Mn-tests: New file.
127195         * modules/unictype/category-N-tests: New file.
127196         * modules/unictype/category-Nd-tests: New file.
127197         * modules/unictype/category-Nl-tests: New file.
127198         * modules/unictype/category-No-tests: New file.
127199         * modules/unictype/category-P-tests: New file.
127200         * modules/unictype/category-Pc-tests: New file.
127201         * modules/unictype/category-Pd-tests: New file.
127202         * modules/unictype/category-Pe-tests: New file.
127203         * modules/unictype/category-Pf-tests: New file.
127204         * modules/unictype/category-Pi-tests: New file.
127205         * modules/unictype/category-Po-tests: New file.
127206         * modules/unictype/category-Ps-tests: New file.
127207         * modules/unictype/category-S-tests: New file.
127208         * modules/unictype/category-Sc-tests: New file.
127209         * modules/unictype/category-Sk-tests: New file.
127210         * modules/unictype/category-Sm-tests: New file.
127211         * modules/unictype/category-So-tests: New file.
127212         * modules/unictype/category-Z-tests: New file.
127213         * modules/unictype/category-Zl-tests: New file.
127214         * modules/unictype/category-Zp-tests: New file.
127215         * modules/unictype/category-Zs-tests: New file.
127216         * modules/unictype/category-and-not-tests: New file.
127217         * modules/unictype/category-and-tests: New file.
127218         * modules/unictype/category-byname-tests: New file.
127219         * modules/unictype/category-name-tests: New file.
127220         * modules/unictype/category-none-tests: New file.
127221         * modules/unictype/category-of-tests: New file.
127222         * modules/unictype/category-or-tests: New file.
127223         * modules/unictype/category-test-withtable-tests: New file.
127224         * modules/unictype/combining-class-tests: New file.
127225         * modules/unictype/ctype-alnum-tests: New file.
127226         * modules/unictype/ctype-alpha-tests: New file.
127227         * modules/unictype/ctype-blank-tests: New file.
127228         * modules/unictype/ctype-cntrl-tests: New file.
127229         * modules/unictype/ctype-digit-tests: New file.
127230         * modules/unictype/ctype-graph-tests: New file.
127231         * modules/unictype/ctype-lower-tests: New file.
127232         * modules/unictype/ctype-print-tests: New file.
127233         * modules/unictype/ctype-punct-tests: New file.
127234         * modules/unictype/ctype-space-tests: New file.
127235         * modules/unictype/ctype-upper-tests: New file.
127236         * modules/unictype/ctype-xdigit-tests: New file.
127237         * modules/unictype/decimal-digit-tests: New file.
127238         * modules/unictype/digit-tests: New file.
127239         * modules/unictype/mirror-tests: New file.
127240         * modules/unictype/numeric-tests: New file.
127241         * modules/unictype/property-alphabetic-tests: New file.
127242         * modules/unictype/property-ascii-hex-digit-tests: New file.
127243         * modules/unictype/property-bidi-arabic-digit-tests: New file.
127244         * modules/unictype/property-bidi-arabic-right-to-left-tests: New file.
127245         * modules/unictype/property-bidi-block-separator-tests: New file.
127246         * modules/unictype/property-bidi-boundary-neutral-tests: New file.
127247         * modules/unictype/property-bidi-common-separator-tests: New file.
127248         * modules/unictype/property-bidi-control-tests: New file.
127249         * modules/unictype/property-bidi-embedding-or-override-tests: New file.
127250         * modules/unictype/property-bidi-eur-num-separator-tests: New file.
127251         * modules/unictype/property-bidi-eur-num-terminator-tests: New file.
127252         * modules/unictype/property-bidi-european-digit-tests: New file.
127253         * modules/unictype/property-bidi-hebrew-right-to-left-tests: New file.
127254         * modules/unictype/property-bidi-left-to-right-tests: New file.
127255         * modules/unictype/property-bidi-non-spacing-mark-tests: New file.
127256         * modules/unictype/property-bidi-other-neutral-tests: New file.
127257         * modules/unictype/property-bidi-pdf-tests: New file.
127258         * modules/unictype/property-bidi-segment-separator-tests: New file.
127259         * modules/unictype/property-bidi-whitespace-tests: New file.
127260         * modules/unictype/property-byname-tests: New file.
127261         * modules/unictype/property-combining-tests: New file.
127262         * modules/unictype/property-composite-tests: New file.
127263         * modules/unictype/property-currency-symbol-tests: New file.
127264         * modules/unictype/property-dash-tests: New file.
127265         * modules/unictype/property-decimal-digit-tests: New file.
127266         * modules/unictype/property-default-ignorable-code-point-tests: New file.
127267         * modules/unictype/property-deprecated-tests: New file.
127268         * modules/unictype/property-diacritic-tests: New file.
127269         * modules/unictype/property-extender-tests: New file.
127270         * modules/unictype/property-format-control-tests: New file.
127271         * modules/unictype/property-grapheme-base-tests: New file.
127272         * modules/unictype/property-grapheme-extend-tests: New file.
127273         * modules/unictype/property-grapheme-link-tests: New file.
127274         * modules/unictype/property-hex-digit-tests: New file.
127275         * modules/unictype/property-hyphen-tests: New file.
127276         * modules/unictype/property-id-continue-tests: New file.
127277         * modules/unictype/property-id-start-tests: New file.
127278         * modules/unictype/property-ideographic-tests: New file.
127279         * modules/unictype/property-ids-binary-operator-tests: New file.
127280         * modules/unictype/property-ids-trinary-operator-tests: New file.
127281         * modules/unictype/property-ignorable-control-tests: New file.
127282         * modules/unictype/property-iso-control-tests: New file.
127283         * modules/unictype/property-join-control-tests: New file.
127284         * modules/unictype/property-left-of-pair-tests: New file.
127285         * modules/unictype/property-line-separator-tests: New file.
127286         * modules/unictype/property-logical-order-exception-tests: New file.
127287         * modules/unictype/property-lowercase-tests: New file.
127288         * modules/unictype/property-math-tests: New file.
127289         * modules/unictype/property-non-break-tests: New file.
127290         * modules/unictype/property-not-a-character-tests: New file.
127291         * modules/unictype/property-numeric-tests: New file.
127292         * modules/unictype/property-other-alphabetic-tests: New file.
127293         * modules/unictype/property-other-default-ignorable-code-point-tests: New file.
127294         * modules/unictype/property-other-grapheme-extend-tests: New file.
127295         * modules/unictype/property-other-id-continue-tests: New file.
127296         * modules/unictype/property-other-id-start-tests: New file.
127297         * modules/unictype/property-other-lowercase-tests: New file.
127298         * modules/unictype/property-other-math-tests: New file.
127299         * modules/unictype/property-other-uppercase-tests: New file.
127300         * modules/unictype/property-paired-punctuation-tests: New file.
127301         * modules/unictype/property-paragraph-separator-tests: New file.
127302         * modules/unictype/property-pattern-syntax-tests: New file.
127303         * modules/unictype/property-pattern-white-space-tests: New file.
127304         * modules/unictype/property-private-use-tests: New file.
127305         * modules/unictype/property-punctuation-tests: New file.
127306         * modules/unictype/property-quotation-mark-tests: New file.
127307         * modules/unictype/property-radical-tests: New file.
127308         * modules/unictype/property-sentence-terminal-tests: New file.
127309         * modules/unictype/property-soft-dotted-tests: New file.
127310         * modules/unictype/property-space-tests: New file.
127311         * modules/unictype/property-terminal-punctuation-tests: New file.
127312         * modules/unictype/property-test-tests: New file.
127313         * modules/unictype/property-titlecase-tests: New file.
127314         * modules/unictype/property-unassigned-code-value-tests: New file.
127315         * modules/unictype/property-unified-ideograph-tests: New file.
127316         * modules/unictype/property-uppercase-tests: New file.
127317         * modules/unictype/property-variation-selector-tests: New file.
127318         * modules/unictype/property-white-space-tests: New file.
127319         * modules/unictype/property-xid-continue-tests: New file.
127320         * modules/unictype/property-xid-start-tests: New file.
127321         * modules/unictype/property-zero-width-tests: New file.
127322         * modules/unictype/scripts-tests: New file.
127323         * modules/unictype/syntax-c-ident-tests: New file.
127324         * modules/unictype/syntax-c-whitespace-tests: New file.
127325         * modules/unictype/syntax-java-ident-tests: New file.
127326         * modules/unictype/syntax-java-whitespace-tests: New file.
127327         * tests/unictype/test-bidi_byname.c: New file.
127328         * tests/unictype/test-bidi_name.c: New file.
127329         * tests/unictype/test-bidi_of.c: New file.
127330         * tests/unictype/test-bidi_test.c: New file.
127331         * tests/unictype/test-block_list.c: New file.
127332         * tests/unictype/test-block_of.c: New file.
127333         * tests/unictype/test-block_test.c: New file.
127334         * tests/unictype/test-categ_and.c: New file.
127335         * tests/unictype/test-categ_and_not.c: New file.
127336         * tests/unictype/test-categ_byname.c: New file.
127337         * tests/unictype/test-categ_name.c: New file.
127338         * tests/unictype/test-categ_none.c: New file.
127339         * tests/unictype/test-categ_of.c: New file.
127340         * tests/unictype/test-categ_or.c: New file.
127341         * tests/unictype/test-categ_test_withtable.c: New file.
127342         * tests/unictype/test-combining.c: New file.
127343         * tests/unictype/test-decdigit.c: New file.
127344         * tests/unictype/test-digit.c: New file.
127345         * tests/unictype/test-mirror.c: New file.
127346         * tests/unictype/test-numeric.c: New file.
127347         * tests/unictype/test-pr_byname.c: New file.
127348         * tests/unictype/test-pr_test.c: New file.
127349         * tests/unictype/test-predicate-part1.h: New file.
127350         * tests/unictype/test-predicate-part2.h: New file.
127351         * tests/unictype/test-scripts.c: New file.
127352         * tests/unictype/test-sy_c_ident.c: New file.
127353         * tests/unictype/test-sy_java_ident.c: New file.
127355         * tests/unictype/test-categ_C.c: New file, generated by gen-ctype.c
127356         for Unicode 5.0.0.
127357         * tests/unictype/test-categ_Cc.c: Likewise.
127358         * tests/unictype/test-categ_Cf.c: Likewise.
127359         * tests/unictype/test-categ_Cn.c: Likewise.
127360         * tests/unictype/test-categ_Co.c: Likewise.
127361         * tests/unictype/test-categ_Cs.c: Likewise.
127362         * tests/unictype/test-categ_L.c: Likewise.
127363         * tests/unictype/test-categ_Ll.c: Likewise.
127364         * tests/unictype/test-categ_Lm.c: Likewise.
127365         * tests/unictype/test-categ_Lo.c: Likewise.
127366         * tests/unictype/test-categ_Lt.c: Likewise.
127367         * tests/unictype/test-categ_Lu.c: Likewise.
127368         * tests/unictype/test-categ_M.c: Likewise.
127369         * tests/unictype/test-categ_Mc.c: Likewise.
127370         * tests/unictype/test-categ_Me.c: Likewise.
127371         * tests/unictype/test-categ_Mn.c: Likewise.
127372         * tests/unictype/test-categ_N.c: Likewise.
127373         * tests/unictype/test-categ_Nd.c: Likewise.
127374         * tests/unictype/test-categ_Nl.c: Likewise.
127375         * tests/unictype/test-categ_No.c: Likewise.
127376         * tests/unictype/test-categ_P.c: Likewise.
127377         * tests/unictype/test-categ_Pc.c: Likewise.
127378         * tests/unictype/test-categ_Pd.c: Likewise.
127379         * tests/unictype/test-categ_Pe.c: Likewise.
127380         * tests/unictype/test-categ_Pf.c: Likewise.
127381         * tests/unictype/test-categ_Pi.c: Likewise.
127382         * tests/unictype/test-categ_Po.c: Likewise.
127383         * tests/unictype/test-categ_Ps.c: Likewise.
127384         * tests/unictype/test-categ_S.c: Likewise.
127385         * tests/unictype/test-categ_Sc.c: Likewise.
127386         * tests/unictype/test-categ_Sk.c: Likewise.
127387         * tests/unictype/test-categ_Sm.c: Likewise.
127388         * tests/unictype/test-categ_So.c: Likewise.
127389         * tests/unictype/test-categ_Z.c: Likewise.
127390         * tests/unictype/test-categ_Zl.c: Likewise.
127391         * tests/unictype/test-categ_Zp.c: Likewise.
127392         * tests/unictype/test-categ_Zs.c: Likewise.
127393         * tests/unictype/test-ctype_alnum.c: Likewise.
127394         * tests/unictype/test-ctype_alpha.c: Likewise.
127395         * tests/unictype/test-ctype_blank.c: Likewise.
127396         * tests/unictype/test-ctype_cntrl.c: Likewise.
127397         * tests/unictype/test-ctype_digit.c: Likewise.
127398         * tests/unictype/test-ctype_graph.c: Likewise.
127399         * tests/unictype/test-ctype_lower.c: Likewise.
127400         * tests/unictype/test-ctype_print.c: Likewise.
127401         * tests/unictype/test-ctype_punct.c: Likewise.
127402         * tests/unictype/test-ctype_space.c: Likewise.
127403         * tests/unictype/test-ctype_upper.c: Likewise.
127404         * tests/unictype/test-ctype_xdigit.c: Likewise.
127405         * tests/unictype/test-decdigit.h: Likewise.
127406         * tests/unictype/test-digit.h: Likewise.
127407         * tests/unictype/test-numeric.h: Likewise.
127408         * tests/unictype/test-pr_alphabetic.c: Likewise.
127409         * tests/unictype/test-pr_ascii_hex_digit.c: Likewise.
127410         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
127411         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Likewise.
127412         * tests/unictype/test-pr_bidi_block_separator.c: Likewise.
127413         * tests/unictype/test-pr_bidi_boundary_neutral.c: Likewise.
127414         * tests/unictype/test-pr_bidi_common_separator.c: Likewise.
127415         * tests/unictype/test-pr_bidi_control.c: Likewise.
127416         * tests/unictype/test-pr_bidi_embedding_or_override.c: Likewise.
127417         * tests/unictype/test-pr_bidi_eur_num_separator.c: Likewise.
127418         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
127419         * tests/unictype/test-pr_bidi_european_digit.c: Likewise.
127420         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
127421         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
127422         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
127423         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
127424         * tests/unictype/test-pr_bidi_pdf.c: Likewise.
127425         * tests/unictype/test-pr_bidi_segment_separator.c: Likewise.
127426         * tests/unictype/test-pr_bidi_whitespace.c: Likewise.
127427         * tests/unictype/test-pr_combining.c: Likewise.
127428         * tests/unictype/test-pr_composite.c: Likewise.
127429         * tests/unictype/test-pr_currency_symbol.c: Likewise.
127430         * tests/unictype/test-pr_dash.c: Likewise.
127431         * tests/unictype/test-pr_decimal_digit.c: Likewise.
127432         * tests/unictype/test-pr_default_ignorable_code_point.c: Likewise.
127433         * tests/unictype/test-pr_deprecated.c: Likewise.
127434         * tests/unictype/test-pr_diacritic.c: Likewise.
127435         * tests/unictype/test-pr_extender.c: Likewise.
127436         * tests/unictype/test-pr_format_control.c: Likewise.
127437         * tests/unictype/test-pr_grapheme_base.c: Likewise.
127438         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
127439         * tests/unictype/test-pr_grapheme_link.c: Likewise.
127440         * tests/unictype/test-pr_hex_digit.c: Likewise.
127441         * tests/unictype/test-pr_hyphen.c: Likewise.
127442         * tests/unictype/test-pr_id_continue.c: Likewise.
127443         * tests/unictype/test-pr_id_start.c: Likewise.
127444         * tests/unictype/test-pr_ideographic.c: Likewise.
127445         * tests/unictype/test-pr_ids_binary_operator.c: Likewise.
127446         * tests/unictype/test-pr_ids_trinary_operator.c: Likewise.
127447         * tests/unictype/test-pr_ignorable_control.c: Likewise.
127448         * tests/unictype/test-pr_iso_control.c: Likewise.
127449         * tests/unictype/test-pr_join_control.c: Likewise.
127450         * tests/unictype/test-pr_left_of_pair.c: Likewise.
127451         * tests/unictype/test-pr_line_separator.c: Likewise.
127452         * tests/unictype/test-pr_logical_order_exception.c: Likewise.
127453         * tests/unictype/test-pr_lowercase.c: Likewise.
127454         * tests/unictype/test-pr_math.c: Likewise.
127455         * tests/unictype/test-pr_non_break.c: Likewise.
127456         * tests/unictype/test-pr_not_a_character.c: Likewise.
127457         * tests/unictype/test-pr_numeric.c: Likewise.
127458         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
127459         * tests/unictype/test-pr_other_default_ignorable_code_point.c: Likewise.
127460         * tests/unictype/test-pr_other_grapheme_extend.c: Likewise.
127461         * tests/unictype/test-pr_other_id_continue.c: Likewise.
127462         * tests/unictype/test-pr_other_id_start.c: Likewise.
127463         * tests/unictype/test-pr_other_lowercase.c: Likewise.
127464         * tests/unictype/test-pr_other_math.c: Likewise.
127465         * tests/unictype/test-pr_other_uppercase.c: Likewise.
127466         * tests/unictype/test-pr_paired_punctuation.c: Likewise.
127467         * tests/unictype/test-pr_paragraph_separator.c: Likewise.
127468         * tests/unictype/test-pr_pattern_syntax.c: Likewise.
127469         * tests/unictype/test-pr_pattern_white_space.c: Likewise.
127470         * tests/unictype/test-pr_private_use.c: Likewise.
127471         * tests/unictype/test-pr_punctuation.c: Likewise.
127472         * tests/unictype/test-pr_quotation_mark.c: Likewise.
127473         * tests/unictype/test-pr_radical.c: Likewise.
127474         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
127475         * tests/unictype/test-pr_soft_dotted.c: Likewise.
127476         * tests/unictype/test-pr_space.c: Likewise.
127477         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
127478         * tests/unictype/test-pr_titlecase.c: Likewise.
127479         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
127480         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
127481         * tests/unictype/test-pr_uppercase.c: Likewise.
127482         * tests/unictype/test-pr_variation_selector.c: Likewise.
127483         * tests/unictype/test-pr_white_space.c: Likewise.
127484         * tests/unictype/test-pr_xid_continue.c: Likewise.
127485         * tests/unictype/test-pr_xid_start.c: Likewise.
127486         * tests/unictype/test-pr_zero_width.c: Likewise.
127487         * tests/unictype/test-sy_c_whitespace.c: Likewise.
127488         * tests/unictype/test-sy_java_whitespace.c: Likewise.
127490 2007-11-12  Bruno Haible  <bruno@clisp.org>
127492         Unicode character classification functions.
127493         * lib/unictype.h: New file.
127494         * modules/unictype/base: New file.
127495         * modules/unictype/category-L: New file.
127496         * modules/unictype/category-Lu: New file.
127497         * modules/unictype/category-Ll: New file.
127498         * modules/unictype/category-Lt: New file.
127499         * modules/unictype/category-Lm: New file.
127500         * modules/unictype/category-Lo: New file.
127501         * modules/unictype/category-M: New file.
127502         * modules/unictype/category-Mn: New file.
127503         * modules/unictype/category-Mc: New file.
127504         * modules/unictype/category-Me: New file.
127505         * modules/unictype/category-N: New file.
127506         * modules/unictype/category-Nd: New file.
127507         * modules/unictype/category-Nl: New file.
127508         * modules/unictype/category-No: New file.
127509         * modules/unictype/category-P: New file.
127510         * modules/unictype/category-Pc: New file.
127511         * modules/unictype/category-Pd: New file.
127512         * modules/unictype/category-Ps: New file.
127513         * modules/unictype/category-Pe: New file.
127514         * modules/unictype/category-Pi: New file.
127515         * modules/unictype/category-Pf: New file.
127516         * modules/unictype/category-Po: New file.
127517         * modules/unictype/category-S: New file.
127518         * modules/unictype/category-Sm: New file.
127519         * modules/unictype/category-Sc: New file.
127520         * modules/unictype/category-Sk: New file.
127521         * modules/unictype/category-So: New file.
127522         * modules/unictype/category-Z: New file.
127523         * modules/unictype/category-Zs: New file.
127524         * modules/unictype/category-Zl: New file.
127525         * modules/unictype/category-Zp: New file.
127526         * modules/unictype/category-C: New file.
127527         * modules/unictype/category-Cc: New file.
127528         * modules/unictype/category-Cf: New file.
127529         * modules/unictype/category-Cs: New file.
127530         * modules/unictype/category-Co: New file.
127531         * modules/unictype/category-Cn: New file.
127532         * modules/unictype/category-or: New file.
127533         * modules/unictype/category-of: New file.
127534         * modules/unictype/category-test: New file.
127535         * modules/unictype/category-test-withtable: New file.
127536         * modules/unictype/category-byname: New file.
127537         * modules/unictype/category-none: New file.
127538         * modules/unictype/category-and: New file.
127539         * modules/unictype/category-and-not: New file.
127540         * modules/unictype/category-name: New file.
127541         * modules/unictype/combining-class: New file.
127542         * modules/unictype/category-all: New file.
127543         * modules/unictype/bidicategory-all: New file.
127544         * modules/unictype/bidicategory-byname: New file.
127545         * modules/unictype/bidicategory-name: New file.
127546         * modules/unictype/bidicategory-of: New file.
127547         * modules/unictype/bidicategory-test: New file.
127548         * modules/unictype/decimal-digit: New file.
127549         * modules/unictype/digit: New file.
127550         * modules/unictype/numeric: New file.
127551         * modules/unictype/mirror: New file.
127552         * modules/unictype/property-white-space: New file.
127553         * modules/unictype/property-alphabetic: New file.
127554         * modules/unictype/property-other-alphabetic: New file.
127555         * modules/unictype/property-not-a-character: New file.
127556         * modules/unictype/property-default-ignorable-code-point: New file.
127557         * modules/unictype/property-other-default-ignorable-code-point: New
127558         file.
127559         * modules/unictype/property-deprecated: New file.
127560         * modules/unictype/property-logical-order-exception: New file.
127561         * modules/unictype/property-variation-selector: New file.
127562         * modules/unictype/property-private-use: New file.
127563         * modules/unictype/property-unassigned-code-value: New file.
127564         * modules/unictype/property-uppercase: New file.
127565         * modules/unictype/property-other-uppercase: New file.
127566         * modules/unictype/property-lowercase: New file.
127567         * modules/unictype/property-other-lowercase: New file.
127568         * modules/unictype/property-titlecase: New file.
127569         * modules/unictype/property-soft-dotted: New file.
127570         * modules/unictype/property-id-start: New file.
127571         * modules/unictype/property-other-id-start: New file.
127572         * modules/unictype/property-id-continue: New file.
127573         * modules/unictype/property-other-id-continue: New file.
127574         * modules/unictype/property-xid-start: New file.
127575         * modules/unictype/property-xid-continue: New file.
127576         * modules/unictype/property-pattern-white-space: New file.
127577         * modules/unictype/property-pattern-syntax: New file.
127578         * modules/unictype/property-join-control: New file.
127579         * modules/unictype/property-grapheme-base: New file.
127580         * modules/unictype/property-grapheme-extend: New file.
127581         * modules/unictype/property-other-grapheme-extend: New file.
127582         * modules/unictype/property-grapheme-link: New file.
127583         * modules/unictype/property-bidi-control: New file.
127584         * modules/unictype/property-bidi-left-to-right: New file.
127585         * modules/unictype/property-bidi-hebrew-right-to-left: New file.
127586         * modules/unictype/property-bidi-arabic-right-to-left: New file.
127587         * modules/unictype/property-bidi-european-digit: New file.
127588         * modules/unictype/property-bidi-eur-num-separator: New file.
127589         * modules/unictype/property-bidi-eur-num-terminator: New file.
127590         * modules/unictype/property-bidi-arabic-digit: New file.
127591         * modules/unictype/property-bidi-common-separator: New file.
127592         * modules/unictype/property-bidi-block-separator: New file.
127593         * modules/unictype/property-bidi-segment-separator: New file.
127594         * modules/unictype/property-bidi-whitespace: New file.
127595         * modules/unictype/property-bidi-non-spacing-mark: New file.
127596         * modules/unictype/property-bidi-boundary-neutral: New file.
127597         * modules/unictype/property-bidi-pdf: New file.
127598         * modules/unictype/property-bidi-embedding-or-override: New file.
127599         * modules/unictype/property-bidi-other-neutral: New file.
127600         * modules/unictype/property-hex-digit: New file.
127601         * modules/unictype/property-ascii-hex-digit: New file.
127602         * modules/unictype/property-ideographic: New file.
127603         * modules/unictype/property-unified-ideograph: New file.
127604         * modules/unictype/property-radical: New file.
127605         * modules/unictype/property-ids-binary-operator: New file.
127606         * modules/unictype/property-ids-trinary-operator: New file.
127607         * modules/unictype/property-zero-width: New file.
127608         * modules/unictype/property-space: New file.
127609         * modules/unictype/property-non-break: New file.
127610         * modules/unictype/property-iso-control: New file.
127611         * modules/unictype/property-format-control: New file.
127612         * modules/unictype/property-dash: New file.
127613         * modules/unictype/property-hyphen: New file.
127614         * modules/unictype/property-punctuation: New file.
127615         * modules/unictype/property-line-separator: New file.
127616         * modules/unictype/property-paragraph-separator: New file.
127617         * modules/unictype/property-quotation-mark: New file.
127618         * modules/unictype/property-sentence-terminal: New file.
127619         * modules/unictype/property-terminal-punctuation: New file.
127620         * modules/unictype/property-currency-symbol: New file.
127621         * modules/unictype/property-math: New file.
127622         * modules/unictype/property-other-math: New file.
127623         * modules/unictype/property-paired-punctuation: New file.
127624         * modules/unictype/property-left-of-pair: New file.
127625         * modules/unictype/property-combining: New file.
127626         * modules/unictype/property-composite: New file.
127627         * modules/unictype/property-decimal-digit: New file.
127628         * modules/unictype/property-numeric: New file.
127629         * modules/unictype/property-diacritic: New file.
127630         * modules/unictype/property-extender: New file.
127631         * modules/unictype/property-ignorable-control: New file.
127632         * modules/unictype/property-test: New file.
127633         * modules/unictype/property-byname: New file.
127634         * modules/unictype/property-all: New file.
127635         * modules/unictype/scripts: New file.
127636         * modules/unictype/scripts-all: New file.
127637         * modules/unictype/block-of: New file.
127638         * modules/unictype/block-test: New file.
127639         * modules/unictype/block-list: New file.
127640         * modules/unictype/block-all: New file.
127641         * modules/unictype/syntax-c-whitespace: New file.
127642         * modules/unictype/syntax-java-whitespace: New file.
127643         * modules/unictype/syntax-c-ident: New file.
127644         * modules/unictype/syntax-java-ident: New file.
127645         * modules/unictype/ctype-alnum: New file.
127646         * modules/unictype/ctype-alpha: New file.
127647         * modules/unictype/ctype-cntrl: New file.
127648         * modules/unictype/ctype-digit: New file.
127649         * modules/unictype/ctype-graph: New file.
127650         * modules/unictype/ctype-lower: New file.
127651         * modules/unictype/ctype-print: New file.
127652         * modules/unictype/ctype-punct: New file.
127653         * modules/unictype/ctype-space: New file.
127654         * modules/unictype/ctype-upper: New file.
127655         * modules/unictype/ctype-xdigit: New file.
127656         * modules/unictype/ctype-blank: New file.
127657         * lib/unictype/bidi_byname.c: New file.
127658         * lib/unictype/bidi_name.c: New file.
127659         * lib/unictype/bidi_of.c: New file.
127660         * lib/unictype/bidi_test.c: New file.
127661         * lib/unictype/bitmap.h: New file.
127662         * lib/unictype/block_test.c: New file.
127663         * lib/unictype/blocks.c: New file.
127664         * lib/unictype/categ_C.c: New file.
127665         * lib/unictype/categ_Cc.c: New file.
127666         * lib/unictype/categ_Cf.c: New file.
127667         * lib/unictype/categ_Cn.c: New file.
127668         * lib/unictype/categ_Co.c: New file.
127669         * lib/unictype/categ_Cs.c: New file.
127670         * lib/unictype/categ_L.c: New file.
127671         * lib/unictype/categ_Ll.c: New file.
127672         * lib/unictype/categ_Lm.c: New file.
127673         * lib/unictype/categ_Lo.c: New file.
127674         * lib/unictype/categ_Lt.c: New file.
127675         * lib/unictype/categ_Lu.c: New file.
127676         * lib/unictype/categ_M.c: New file.
127677         * lib/unictype/categ_Mc.c: New file.
127678         * lib/unictype/categ_Me.c: New file.
127679         * lib/unictype/categ_Mn.c: New file.
127680         * lib/unictype/categ_N.c: New file.
127681         * lib/unictype/categ_Nd.c: New file.
127682         * lib/unictype/categ_Nl.c: New file.
127683         * lib/unictype/categ_No.c: New file.
127684         * lib/unictype/categ_P.c: New file.
127685         * lib/unictype/categ_Pc.c: New file.
127686         * lib/unictype/categ_Pd.c: New file.
127687         * lib/unictype/categ_Pe.c: New file.
127688         * lib/unictype/categ_Pf.c: New file.
127689         * lib/unictype/categ_Pi.c: New file.
127690         * lib/unictype/categ_Po.c: New file.
127691         * lib/unictype/categ_Ps.c: New file.
127692         * lib/unictype/categ_S.c: New file.
127693         * lib/unictype/categ_Sc.c: New file.
127694         * lib/unictype/categ_Sk.c: New file.
127695         * lib/unictype/categ_Sm.c: New file.
127696         * lib/unictype/categ_So.c: New file.
127697         * lib/unictype/categ_Z.c: New file.
127698         * lib/unictype/categ_Zl.c: New file.
127699         * lib/unictype/categ_Zp.c: New file.
127700         * lib/unictype/categ_Zs.c: New file.
127701         * lib/unictype/categ_and.c: New file.
127702         * lib/unictype/categ_and_not.c: New file.
127703         * lib/unictype/categ_byname.c: New file.
127704         * lib/unictype/categ_name.c: New file.
127705         * lib/unictype/categ_none.c: New file.
127706         * lib/unictype/categ_of.c: New file.
127707         * lib/unictype/categ_or.c: New file.
127708         * lib/unictype/categ_test.c: New file.
127709         * lib/unictype/combining.c: New file.
127710         * lib/unictype/ctype_alnum.c: New file.
127711         * lib/unictype/ctype_alpha.c: New file.
127712         * lib/unictype/ctype_blank.c: New file.
127713         * lib/unictype/ctype_cntrl.c: New file.
127714         * lib/unictype/ctype_digit.c: New file.
127715         * lib/unictype/ctype_graph.c: New file.
127716         * lib/unictype/ctype_lower.c: New file.
127717         * lib/unictype/ctype_print.c: New file.
127718         * lib/unictype/ctype_punct.c: New file.
127719         * lib/unictype/ctype_space.c: New file.
127720         * lib/unictype/ctype_upper.c: New file.
127721         * lib/unictype/ctype_xdigit.c: New file.
127722         * lib/unictype/decdigit.c: New file.
127723         * lib/unictype/digit.c: New file.
127724         * lib/unictype/identsyntaxmap.h: New file.
127725         * lib/unictype/mirror.c: New file.
127726         * lib/unictype/numeric.c: New file.
127727         * lib/unictype/pr_alphabetic.c: New file.
127728         * lib/unictype/pr_ascii_hex_digit.c: New file.
127729         * lib/unictype/pr_bidi_arabic_digit.c: New file.
127730         * lib/unictype/pr_bidi_arabic_right_to_left.c: New file.
127731         * lib/unictype/pr_bidi_block_separator.c: New file.
127732         * lib/unictype/pr_bidi_boundary_neutral.c: New file.
127733         * lib/unictype/pr_bidi_common_separator.c: New file.
127734         * lib/unictype/pr_bidi_control.c: New file.
127735         * lib/unictype/pr_bidi_embedding_or_override.c: New file.
127736         * lib/unictype/pr_bidi_eur_num_separator.c: New file.
127737         * lib/unictype/pr_bidi_eur_num_terminator.c: New file.
127738         * lib/unictype/pr_bidi_european_digit.c: New file.
127739         * lib/unictype/pr_bidi_hebrew_right_to_left.c: New file.
127740         * lib/unictype/pr_bidi_left_to_right.c: New file.
127741         * lib/unictype/pr_bidi_non_spacing_mark.c: New file.
127742         * lib/unictype/pr_bidi_other_neutral.c: New file.
127743         * lib/unictype/pr_bidi_pdf.c: New file.
127744         * lib/unictype/pr_bidi_segment_separator.c: New file.
127745         * lib/unictype/pr_bidi_whitespace.c: New file.
127746         * lib/unictype/pr_byname.c: New file.
127747         * lib/unictype/pr_byname.gperf: New file.
127748         * lib/unictype/pr_combining.c: New file.
127749         * lib/unictype/pr_composite.c: New file.
127750         * lib/unictype/pr_currency_symbol.c: New file.
127751         * lib/unictype/pr_dash.c: New file.
127752         * lib/unictype/pr_decimal_digit.c: New file.
127753         * lib/unictype/pr_default_ignorable_code_point.c: New file.
127754         * lib/unictype/pr_deprecated.c: New file.
127755         * lib/unictype/pr_diacritic.c: New file.
127756         * lib/unictype/pr_extender.c: New file.
127757         * lib/unictype/pr_format_control.c: New file.
127758         * lib/unictype/pr_grapheme_base.c: New file.
127759         * lib/unictype/pr_grapheme_extend.c: New file.
127760         * lib/unictype/pr_grapheme_link.c: New file.
127761         * lib/unictype/pr_hex_digit.c: New file.
127762         * lib/unictype/pr_hyphen.c: New file.
127763         * lib/unictype/pr_id_continue.c: New file.
127764         * lib/unictype/pr_id_start.c: New file.
127765         * lib/unictype/pr_ideographic.c: New file.
127766         * lib/unictype/pr_ids_binary_operator.c: New file.
127767         * lib/unictype/pr_ids_trinary_operator.c: New file.
127768         * lib/unictype/pr_ignorable_control.c: New file.
127769         * lib/unictype/pr_iso_control.c: New file.
127770         * lib/unictype/pr_join_control.c: New file.
127771         * lib/unictype/pr_left_of_pair.c: New file.
127772         * lib/unictype/pr_line_separator.c: New file.
127773         * lib/unictype/pr_logical_order_exception.c: New file.
127774         * lib/unictype/pr_lowercase.c: New file.
127775         * lib/unictype/pr_math.c: New file.
127776         * lib/unictype/pr_non_break.c: New file.
127777         * lib/unictype/pr_not_a_character.c: New file.
127778         * lib/unictype/pr_numeric.c: New file.
127779         * lib/unictype/pr_other_alphabetic.c: New file.
127780         * lib/unictype/pr_other_default_ignorable_code_point.c: New file.
127781         * lib/unictype/pr_other_grapheme_extend.c: New file.
127782         * lib/unictype/pr_other_id_continue.c: New file.
127783         * lib/unictype/pr_other_id_start.c: New file.
127784         * lib/unictype/pr_other_lowercase.c: New file.
127785         * lib/unictype/pr_other_math.c: New file.
127786         * lib/unictype/pr_other_uppercase.c: New file.
127787         * lib/unictype/pr_paired_punctuation.c: New file.
127788         * lib/unictype/pr_paragraph_separator.c: New file.
127789         * lib/unictype/pr_pattern_syntax.c: New file.
127790         * lib/unictype/pr_pattern_white_space.c: New file.
127791         * lib/unictype/pr_private_use.c: New file.
127792         * lib/unictype/pr_punctuation.c: New file.
127793         * lib/unictype/pr_quotation_mark.c: New file.
127794         * lib/unictype/pr_radical.c: New file.
127795         * lib/unictype/pr_sentence_terminal.c: New file.
127796         * lib/unictype/pr_soft_dotted.c: New file.
127797         * lib/unictype/pr_space.c: New file.
127798         * lib/unictype/pr_terminal_punctuation.c: New file.
127799         * lib/unictype/pr_test.c: New file.
127800         * lib/unictype/pr_titlecase.c: New file.
127801         * lib/unictype/pr_unassigned_code_value.c: New file.
127802         * lib/unictype/pr_unified_ideograph.c: New file.
127803         * lib/unictype/pr_uppercase.c: New file.
127804         * lib/unictype/pr_variation_selector.c: New file.
127805         * lib/unictype/pr_white_space.c: New file.
127806         * lib/unictype/pr_xid_continue.c: New file.
127807         * lib/unictype/pr_xid_start.c: New file.
127808         * lib/unictype/pr_zero_width.c: New file.
127809         * lib/unictype/scripts.c: New file.
127810         * lib/unictype/sy_c_ident.c: New file.
127811         * lib/unictype/sy_c_whitespace.c: New file.
127812         * lib/unictype/sy_java_ident.c: New file.
127813         * lib/unictype/sy_java_whitespace.c: New file.
127815         * lib/unictype/bidi_of.h: New file, generated by gen-ctype.c for
127816         Unicode 5.0.0.
127817         * lib/unictype/blocks.h: Likewise.
127818         * lib/unictype/categ_C.h: Likewise.
127819         * lib/unictype/categ_Cc.h: Likewise.
127820         * lib/unictype/categ_Cf.h: Likewise.
127821         * lib/unictype/categ_Cn.h: Likewise.
127822         * lib/unictype/categ_Co.h: Likewise.
127823         * lib/unictype/categ_Cs.h: Likewise.
127824         * lib/unictype/categ_L.h: Likewise.
127825         * lib/unictype/categ_Ll.h: Likewise.
127826         * lib/unictype/categ_Lm.h: Likewise.
127827         * lib/unictype/categ_Lo.h: Likewise.
127828         * lib/unictype/categ_Lt.h: Likewise.
127829         * lib/unictype/categ_Lu.h: Likewise.
127830         * lib/unictype/categ_M.h: Likewise.
127831         * lib/unictype/categ_Mc.h: Likewise.
127832         * lib/unictype/categ_Me.h: Likewise.
127833         * lib/unictype/categ_Mn.h: Likewise.
127834         * lib/unictype/categ_N.h: Likewise.
127835         * lib/unictype/categ_Nd.h: Likewise.
127836         * lib/unictype/categ_Nl.h: Likewise.
127837         * lib/unictype/categ_No.h: Likewise.
127838         * lib/unictype/categ_P.h: Likewise.
127839         * lib/unictype/categ_Pc.h: Likewise.
127840         * lib/unictype/categ_Pd.h: Likewise.
127841         * lib/unictype/categ_Pe.h: Likewise.
127842         * lib/unictype/categ_Pf.h: Likewise.
127843         * lib/unictype/categ_Pi.h: Likewise.
127844         * lib/unictype/categ_Po.h: Likewise.
127845         * lib/unictype/categ_Ps.h: Likewise.
127846         * lib/unictype/categ_S.h: Likewise.
127847         * lib/unictype/categ_Sc.h: Likewise.
127848         * lib/unictype/categ_Sk.h: Likewise.
127849         * lib/unictype/categ_Sm.h: Likewise.
127850         * lib/unictype/categ_So.h: Likewise.
127851         * lib/unictype/categ_Z.h: Likewise.
127852         * lib/unictype/categ_Zl.h: Likewise.
127853         * lib/unictype/categ_Zp.h: Likewise.
127854         * lib/unictype/categ_Zs.h: Likewise.
127855         * lib/unictype/categ_of.h: Likewise.
127856         * lib/unictype/combining.h: Likewise.
127857         * lib/unictype/ctype_alnum.h: Likewise.
127858         * lib/unictype/ctype_alpha.h: Likewise.
127859         * lib/unictype/ctype_blank.h: Likewise.
127860         * lib/unictype/ctype_cntrl.h: Likewise.
127861         * lib/unictype/ctype_digit.h: Likewise.
127862         * lib/unictype/ctype_graph.h: Likewise.
127863         * lib/unictype/ctype_lower.h: Likewise.
127864         * lib/unictype/ctype_print.h: Likewise.
127865         * lib/unictype/ctype_punct.h: Likewise.
127866         * lib/unictype/ctype_space.h: Likewise.
127867         * lib/unictype/ctype_upper.h: Likewise.
127868         * lib/unictype/ctype_xdigit.h: Likewise.
127869         * lib/unictype/decdigit.h: Likewise.
127870         * lib/unictype/digit.h: Likewise.
127871         * lib/unictype/mirror.h: Likewise.
127872         * lib/unictype/numeric.h: Likewise.
127873         * lib/unictype/pr_alphabetic.h: Likewise.
127874         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
127875         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
127876         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
127877         * lib/unictype/pr_bidi_block_separator.h: Likewise.
127878         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
127879         * lib/unictype/pr_bidi_common_separator.h: Likewise.
127880         * lib/unictype/pr_bidi_control.h: Likewise.
127881         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
127882         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
127883         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
127884         * lib/unictype/pr_bidi_european_digit.h: Likewise.
127885         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
127886         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
127887         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
127888         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
127889         * lib/unictype/pr_bidi_pdf.h: Likewise.
127890         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
127891         * lib/unictype/pr_bidi_whitespace.h: Likewise.
127892         * lib/unictype/pr_combining.h: Likewise.
127893         * lib/unictype/pr_composite.h: Likewise.
127894         * lib/unictype/pr_currency_symbol.h: Likewise.
127895         * lib/unictype/pr_dash.h: Likewise.
127896         * lib/unictype/pr_decimal_digit.h: Likewise.
127897         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
127898         * lib/unictype/pr_deprecated.h: Likewise.
127899         * lib/unictype/pr_diacritic.h: Likewise.
127900         * lib/unictype/pr_extender.h: Likewise.
127901         * lib/unictype/pr_format_control.h: Likewise.
127902         * lib/unictype/pr_grapheme_base.h: Likewise.
127903         * lib/unictype/pr_grapheme_extend.h: Likewise.
127904         * lib/unictype/pr_grapheme_link.h: Likewise.
127905         * lib/unictype/pr_hex_digit.h: Likewise.
127906         * lib/unictype/pr_hyphen.h: Likewise.
127907         * lib/unictype/pr_id_continue.h: Likewise.
127908         * lib/unictype/pr_id_start.h: Likewise.
127909         * lib/unictype/pr_ideographic.h: Likewise.
127910         * lib/unictype/pr_ids_binary_operator.h: Likewise.
127911         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
127912         * lib/unictype/pr_ignorable_control.h: Likewise.
127913         * lib/unictype/pr_iso_control.h: Likewise.
127914         * lib/unictype/pr_join_control.h: Likewise.
127915         * lib/unictype/pr_left_of_pair.h: Likewise.
127916         * lib/unictype/pr_line_separator.h: Likewise.
127917         * lib/unictype/pr_logical_order_exception.h: Likewise.
127918         * lib/unictype/pr_lowercase.h: Likewise.
127919         * lib/unictype/pr_math.h: Likewise.
127920         * lib/unictype/pr_non_break.h: Likewise.
127921         * lib/unictype/pr_not_a_character.h: Likewise.
127922         * lib/unictype/pr_numeric.h: Likewise.
127923         * lib/unictype/pr_other_alphabetic.h: Likewise.
127924         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
127925         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
127926         * lib/unictype/pr_other_id_continue.h: Likewise.
127927         * lib/unictype/pr_other_id_start.h: Likewise.
127928         * lib/unictype/pr_other_lowercase.h: Likewise.
127929         * lib/unictype/pr_other_math.h: Likewise.
127930         * lib/unictype/pr_other_uppercase.h: Likewise.
127931         * lib/unictype/pr_paired_punctuation.h: Likewise.
127932         * lib/unictype/pr_paragraph_separator.h: Likewise.
127933         * lib/unictype/pr_pattern_syntax.h: Likewise.
127934         * lib/unictype/pr_pattern_white_space.h: Likewise.
127935         * lib/unictype/pr_private_use.h: Likewise.
127936         * lib/unictype/pr_punctuation.h: Likewise.
127937         * lib/unictype/pr_quotation_mark.h: Likewise.
127938         * lib/unictype/pr_radical.h: Likewise.
127939         * lib/unictype/pr_sentence_terminal.h: Likewise.
127940         * lib/unictype/pr_soft_dotted.h: Likewise.
127941         * lib/unictype/pr_space.h: Likewise.
127942         * lib/unictype/pr_terminal_punctuation.h: Likewise.
127943         * lib/unictype/pr_titlecase.h: Likewise.
127944         * lib/unictype/pr_unassigned_code_value.h: Likewise.
127945         * lib/unictype/pr_unified_ideograph.h: Likewise.
127946         * lib/unictype/pr_uppercase.h: Likewise.
127947         * lib/unictype/pr_variation_selector.h: Likewise.
127948         * lib/unictype/pr_white_space.h: Likewise.
127949         * lib/unictype/pr_xid_continue.h: Likewise.
127950         * lib/unictype/pr_xid_start.h: Likewise.
127951         * lib/unictype/pr_zero_width.h: Likewise.
127952         * lib/unictype/scripts.h: Likewise.
127953         * lib/unictype/scripts_byname.gperf: Likewise.
127954         * lib/unictype/sy_c_ident.h: Likewise.
127955         * lib/unictype/sy_c_whitespace.h: Likewise.
127956         * lib/unictype/sy_java_ident.h: Likewise.
127957         * lib/unictype/sy_java_whitespace.h: Likewise.
127959         * lib/unictype/Makefile: New file.
127960         * lib/unictype/gen-ctype.c: New file, based on gen-unicode-ctype.c in
127961         glibc.
127962         * lib/unictype/3level.h: New file, copied from glibc.
127963         * lib/unictype/3levelbit.h: New file.
127965 2007-11-11  Bruno Haible  <bruno@clisp.org>
127967         * modules/gperf: New file.
127968         * modules/iconv_open (Depends-on): Add it.
127969         (Makefile.am): Remove the GPERF definition.
127971 2007-11-11  Bruno Haible  <bruno@clisp.org>
127973         * m4/round.m4 (gl_FUNC_ROUND): Test against NetBSD 3.0 bug.
127974         * doc/functions/round.texi: Mention the NetBSD 3.0 bug.
127976 2007-11-11  Bruno Haible  <bruno@clisp.org>
127978         * tests/test-argmatch.c (ARGMATCH_DIE): Undefine.
127979         (usage): Remove function.
127981 2007-11-11  Bruno Haible  <bruno@clisp.org>
127983         * m4/roundf.m4 (gl_FUNC_ROUNDF): Use gl_FUNC_FLOORF_LIBS and
127984         gl_FUNC_CEILF_LIBS.
127985         * m4/round.m4 (gl_FUNC_ROUND): Use gl_FUNC_FLOOR_LIBS and
127986         gl_FUNC_CEIL_LIBS.
127987         * m4/roundl.m4 (gl_FUNC_ROUNDL): Use gl_FUNC_FLOORL_LIBS and
127988         gl_FUNC_CEILL_LIBS.
127989         * modules/roundf (Files): Add m4/floorf.m4, m4/ceilf.m4.
127990         * modules/round (Files): Add m4/floor.m4, m4/ceil.m4.
127991         * modules/roundl (Files): Add m4/floorl.m4, m4/ceill.m4.
127993 2007-11-11  Bruno Haible  <bruno@clisp.org>
127995         * m4/roundf.m4 (gl_FUNC_ROUNDF): Handle the case that floorf and
127996         roundf were declared but do not exist on functions.
127997         * m4/roundl.m4 (gl_FUNC_ROUNDL): Handle the case that floorl and
127998         roundl were declared but do not exist on functions.
127999         * lib/round.c (HAVE_FLOOR_AND_CEIL): Use HAVE_FLOORF_AND_CEILF and
128000         HAVE_FLOORL_AND_CEILL, respectively.
128001         Needed for Sun C on Solaris 10.
128003 2007-11-11  Bruno Haible  <bruno@clisp.org>
128005         * m4/roundf.m4 (gl_FUNC_ROUNDF): Set REPLACE_ROUNDF instead of
128006         HAVE_DECL_ROUNDF. Remove redundant AC_SUBST.
128007         * m4/round.m4 (gl_FUNC_ROUND): Set REPLACE_ROUND instead of
128008         HAVE_DECL_ROUND. Remove redundant AC_SUBST.
128009         * m4/roundl.m4 (gl_FUNC_ROUNDL): Set REPLACE_ROUNDL instead of
128010         HAVE_DECL_ROUNDL. Remove redundant AC_SUBST.
128011         * lib/math.in.h (roundf): Use REPLACE_ROUNDF instead of
128012         HAVE_DECL_ROUNDF.
128013         (round): Use REPLACE_ROUND instead of HAVE_DECL_ROUND.
128014         (roundl): Use REPLACE_ROUNDL instead of HAVE_DECL_ROUNDL.
128015         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_ROUND* instead
128016         of HAVE_DECL_ROUND*.
128017         * modules/math (Makefile.am): Update.
128019 2007-11-10  Bruno Haible  <bruno@clisp.org>
128021         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Use same check for
128022         ptrdiff_t as m4/intl.m4.
128024 2007-11-10  Jim Meyering  <meyering@redhat.com>
128026         Avoid link failure for the argmatch test.
128027         * tests/test-argmatch.c (usage): Define function to avoid a link
128028         failure: argmatch_die requires a usage function.
128030 2007-11-09  Bruno Haible  <bruno@clisp.org>
128032         * doc/functions/snprintf.texi: Mention BeOS deficiency.
128033         * doc/functions/vsnprintf.texi: Likewise.
128034         * lib/vasnprintf.c (VASNPRINTF): Ensure that we never call snprintf
128035         with a size argument < 2.
128037 2007-11-09  Bruno Haible  <bruno@clisp.org>
128039         * lib/vasnprintf.c (VASNPRINTF): Increase reallocation of snprintf
128040         buffer. Fixes an inefficiency introduced on 2007-11-03.
128042 2007-11-09  Bruno Haible  <bruno@clisp.org>
128044         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8) [BeOS]: Make this test return
128045         none instead of tr_TR. Fixes a failure of test-c-strcasecmp.c.
128047 2007-11-08  Jim Meyering  <meyering@redhat.com>
128049         Change cache variable name prefix "jm_" to "gl_" everywhere.
128050         * m4/d-type.m4, m4/jm-winsz1.m4, m4/jm-winsz2.m4, m4/link-follow.m4:
128051         * m4/putenv.m4, m4/strtoimax.m4, m4/strtoumax.m4, m4/unlink-busy.m4:
128052         * m4/uptime.m4: s/gl_/jm_/
128054 2007-11-07  Bruno Haible  <bruno@clisp.org>
128056         Update to GNU gettext 0.17.
128057         * m4/intl.m4: Update to GNU gettext 0.17.
128058         * m4/po.m4: Likewise.
128059         * modules/gettext (Files): Remove m4/ulonglong.m4.
128060         (configure.ac): Require gettext infrastructure from version 0.17.
128062 2007-11-06  Bruno Haible  <bruno@clisp.org>
128064         * lib/fbufmode.c (fbufmode) [QNX]: Use numerical values for flags; the
128065         symbolic values are not defined in a public header.
128066         * lib/freadable.c (freadable) [QNX]: Likewise.
128067         * lib/freadahead.c (freadahead) [QNX]: Likewise.
128068         * lib/freading.c (freading) [QNX]: Likewise.
128069         * lib/fseterr.c (fseterr) [QNX]: Likewise.
128070         * lib/fwritable.c (fwritable) [QNX]: Likewise.
128071         * lib/fwriting.c (fwriting) [QNX]: Likewise.
128072         * lib/fpurge.c (fpurge) [QNX]: Likewise. Add a return statement.
128073         Reported by Alain Magloire.
128075         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for QNX.
128077 2007-11-05  Bruno Haible  <bruno@clisp.org>
128079         * lib/vasnprintf.c (VASNPRINTF): Expand the NEED_PRINTF_DIRECTIVE_A
128080         code when NEED_PRINTF_LONG_DOUBLE or NEED_PRINTF_DOUBLE is set.
128081         Needed on Cygwin, where !NEED_PRINTF_DIRECTIVE_A && NEED_PRINTF_DOUBLE.
128082         Reported by Eric Blake.
128084 2007-10-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128085             Bruno Haible  <bruno@clisp.org>
128087         * modules/malloc (configure.ac): Define GNULIB_MALLOC_GNU always.
128088         * modules/realloc (configure.ac): Define GNULIB_REALLOC_GNU always.
128089         * lib/realloc.c (SYSTEM_MALLOC_GLIBC_COMPATIBLE): New macro.
128090         (malloc): Undefine also before including <stdlib.h>.
128091         (rpl_realloc): Turn malloc(0) into malloc(1) if necessary.
128092         Needed on OSF/1 4.0.
128094 2007-11-05  Jim Meyering  <meyering@redhat.com>
128096         git-version-gen: sync from coreutils.
128097         * build-aux/git-version-gen: Add comments.
128098         Change the first '-' to '.' in the snapshot version string,
128099         e.g., 6.9-377-08144 -> 6.9.377-08144
128100         Remove first parameter.
128101         Don't declare a version "-dirty" merely because a time
128102         stamp has changed.
128104 2007-11-04  Bruno Haible  <bruno@clisp.org>
128106         * lib/lock.h: Protect all macro definitions containing an 'if'
128107         statement through a "do { ... } while (0)".
128108         * lib/tls.h: Likewise.
128110 2007-11-04  Bruno Haible  <bruno@clisp.org>
128112         * lib/vasnprintf.c (DCHAR_IS_TCHAR, DCHAR_CPY): Undefine at the end.
128114 2007-11-04  Bruno Haible  <bruno@clisp.org>
128116         * m4/printf.m4 (gl_PRINTF_ENOMEM): Use GL_NOCRASH.
128117         * modules/fprintf-posix (Depends-on): Add nocrash.
128118         * modules/snprintf-posix (Depends-on): Likewise.
128119         * modules/sprintf-posix (Depends-on): Likewise.
128120         * modules/vasnprintf-posix (Depends-on): Likewise.
128121         * modules/vasprintf-posix (Depends-on): Likewise.
128122         * modules/vfprintf-posix (Depends-on): Likewise.
128123         * modules/vsnprintf-posix (Depends-on): Likewise.
128124         * modules/vsprintf-posix (Depends-on): Likewise.
128125         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
128126         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
128127         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
128128         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
128129         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
128130         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
128131         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
128133 2007-11-04  Bruno Haible  <bruno@clisp.org>
128135         * modules/nocrash: New file.
128136         * m4/nocrash.m4: New file, taken from GNU clisp. Code taken from
128137         GNU libsigsegv, with permission of GNU libsigsegv's copyright holders.
128139 2007-11-04  Bruno Haible  <bruno@clisp.org>
128141         * tests/test-vasnprintf-posix.c (test_function): Add some tests of
128142         precision handling.
128143         * tests/test-vasprintf-posix.c (test_function): Likewise.
128144         * tests/test-snprintf-posix.h (test_function): Likewise.
128145         * tests/test-sprintf-posix.h (test_function): Likewise.
128147         Fix *printf behaviour for large precisions on mingw and BeOS.
128148         * m4/printf.m4 (gl_PRINTF_PRECISION): New macro.
128149         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_UNBOUNDED_PRECISION.
128150         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_PRECISION): New macro.
128151         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
128152         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
128153         gl_PRINTF_PRECISION and test its result. Invoke
128154         gl_PREREQ_VASNPRINTF_PRECISION.
128155         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
128156         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
128157         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
128158         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
128159         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
128160         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
128161         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
128162         * doc/functions/fprintf.texi: Update.
128163         * doc/functions/printf.texi: Update.
128164         * doc/functions/snprintf.texi: Update.
128165         * doc/functions/sprintf.texi: Update.
128166         * doc/functions/vfprintf.texi: Update.
128167         * doc/functions/vprintf.texi: Update.
128168         * doc/functions/vsnprintf.texi: Update.
128169         * doc/functions/vsprintf.texi: Update.
128171 2007-11-04  Bruno Haible  <bruno@clisp.org>
128173         * lib/vasnprintf.c (scale10_round_decimal_decoded): Fix shift loop.
128175 2007-11-04  Bruno Haible  <bruno@clisp.org>
128177         * modules/relocatable-prog (Files): Add m4/lib-ld.m4.
128178         Reported by Sylvain Beucler <beuc@gnu.org>.
128180 2007-11-03  Bruno Haible  <bruno@clisp.org>
128182         * tests/test-fprintf-posix2.sh: New file.
128183         * tests/test-fprintf-posix2.c: New file.
128184         * modules/fprintf-posix-tests (Files): Add them.
128185         (TESTS): Add test-fprintf-posix2.sh.
128186         (configure.ac): Check for getrlimit and setrlimit.
128187         (check_PROGRAMS): Add test-fprintf-posix2.
128189         * tests/test-printf-posix2.sh: New file.
128190         * tests/test-printf-posix2.c: New file.
128191         * modules/printf-posix-tests (Files): Add them.
128192         (TESTS): Add test-printf-posix2.sh.
128193         (configure.ac): Check for getrlimit and setrlimit.
128194         (check_PROGRAMS): Add test-printf-posix2.
128196         Fix *printf behaviour in out-of-memory situations on MacOS X and *BSD.
128197         * m4/printf.m4 (gl_PRINTF_ENOMEM): New macro.
128198         * lib/vasnprintf.c: Implement NEED_PRINTF_DOUBLE.
128199         (decode_double): New function, copied from decode_long_double.
128200         (scale10_round_decimal_decoded): New function, extracted from
128201         scale10_round_decimal_long_double.
128202         (scale10_round_decimal_long_double): Use it.
128203         (scale10_round_decimal_double): New function.
128204         (floorlog10): New function.
128205         (VASNPRINTF): Handle NEED_PRINTF_DOUBLE case.
128206         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_ENOMEM): New macro.
128207         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
128208         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
128209         gl_PRINTF_ENOMEM and test its result. Invoke
128210         gl_PREREQ_VASNPRINTF_ENOMEM.
128211         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
128212         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
128213         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
128214         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
128215         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
128216         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
128217         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
128218         * modules/fprintf-posix (Depends-on): Add frexp-nolibm.
128219         * modules/snprintf-posix (Depends-on): Likewise.
128220         * modules/sprintf-posix (Depends-on): Likewise.
128221         * modules/vasnprintf-posix (Depends-on): Likewise.
128222         * modules/vasprintf-posix (Depends-on): Likewise.
128223         * modules/vfprintf-posix (Depends-on): Likewise.
128224         * modules/vsnprintf-posix (Depends-on): Likewise.
128225         * modules/vsprintf-posix (Depends-on): Likewise.
128226         * doc/functions/fprintf.texi: Update.
128227         * doc/functions/printf.texi: Update.
128228         * doc/functions/snprintf.texi: Update.
128229         * doc/functions/sprintf.texi: Update.
128230         * doc/functions/vfprintf.texi: Update.
128231         * doc/functions/vprintf.texi: Update.
128232         * doc/functions/vsnprintf.texi: Update.
128233         * doc/functions/vsprintf.texi: Update.
128235 2007-11-03  Bruno Haible  <bruno@clisp.org>
128237         * modules/frexp-nolibm-tests: New file.
128239         * modules/frexp-nolibm: New file.
128240         * m4/frexp.m4 (gl_FUNC_FREXP_NO_LIBM): New macro.
128242 2007-11-03  Bruno Haible  <bruno@clisp.org>
128244         * lib/vasnprintf.c (VASNPRINTF): Don't assume that snprintf's return
128245         value is C99 compliant.
128246         Needed for OSF/1 5.1.
128248 2007-11-03  Bruno Haible  <bruno@clisp.org>
128250         Fix out-of-memory handling of vasnprintf.
128251         * lib/printf-parse.c: Include <errno.h>.
128252         (PRINTF_PARSE): When failing, set errno to EINVAL or ENOMEM.
128253         * lib/vasnprintf.c (VASNPRINTF): When PRINTF_PARSE fails, assume errno
128254         is already set.
128256 2007-11-02  Eric Blake  <ebb9@byu.net>
128258         Fix tests on cygwin.
128259         * modules/xprintf-posix-tests (Makefile.am): Link against -lintl.
128261 2007-11-01  Bruno Haible  <bruno@clisp.org>
128263         * lib/stdlib.in.h (putenv): Remove the "not POSIX compliant everywhere"
128264         warning.
128265         * doc/functions/putenv.texi: Clarify that the 'putenv' module is not
128266         needed for POSIX compatibility.
128268 2007-11-01  Paul Eggert  <eggert@cs.ucla.edu>
128270         * m4/putenv.m4 (gl_FUNC_PUTENV): Also mention that we're checking
128271         for compatibility with GNU.
128273 2007-11-01  Bruno Haible  <bruno@clisp.org>
128275         * lib/putenv.c: Include <stdlib.h>. Remove rpl_putenv declaration.
128276         (putenv): Renamed from rpl_putenv. Change argument type from
128277         'const char *' to 'char *'.
128278         * m4/putenv.m4 (gl_FUNC_PUTENV): Require gl_STDLIB_H_DEFAULTS. Instead
128279         of defining putenv in config.h, just set REPLACE_PUTENV.
128280         * modules/putenv (Depends-on): Add stdlib.
128281         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
128282         (Include): Use <stdlib.h>.
128283         * lib/stdlib.in.h (putenv): New declaration.
128284         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_PUTENV and
128285         REPLACE_PUTENV.
128286         * modules/stdlib (Makefile.am): Substitute GNULIB_PUTENV and
128287         REPLACE_PUTENV.
128288         Needed for MacOS X 10.5.0.
128289         Reported by Peter O'Gorman <peter@pogma.com>.
128291 2007-11-01  Jim Meyering  <meyering@redhat.com>
128293         Treat an empty date string exactly like "0".
128294         * lib/getdate.y (get_date): Once any isspace or TZ= prefix is consumed,
128295         if the remaining date string (to be parsed) is empty, use "0".
128296         Reported by Mischa Molhoek and discussed in this thread:
128297         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/11726>.
128299 2007-10-31  Bruno Haible  <bruno@clisp.org>
128301         * m4/intmax_t.m4 (gl_AC_TYPE_INTMAX_T, gt_AC_TYPE_INTMAX_T): Use
128302         AC_TYPE_LONG_LONG_INT instead of gl_AC_TYPE_LONG_LONG.
128303         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Use
128304         AC_TYPE_UNSIGNED_LONG_LONG_INT instead of gl_AC_TYPE_UNSIGNED_LONG_LONG.
128305         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Remove macro.
128306         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG): Remove macro.
128308 2007-10-31  Bruno Haible  <bruno@clisp.org>
128310         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): New macro, extracted
128311         from AC_TYPE_LONG_LONG_INT and AC_TYPE_UNSIGNED_LONG_LONG_INT.
128312         (AC_TYPE_LONG_LONG_INT): Use it.
128313         (AC_TYPE_UNSIGNED_LONG_LONG_INT): Moved here from m4/ulonglong.m4. Use
128314         it as well.
128315         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Remove macro; moved
128316         to m4/longlong.m4.
128317         * modules/stdint (Files): Remove m4/ulonglong.m4.
128318         * modules/strtoull (Files): Use m4/longlong.m4 instead of
128319         m4/ulonglong.m4.
128320         * modules/strtoumax (Files): Likewise.
128322 2007-10-30  Bruno Haible  <bruno@clisp.org>
128324         * modules/xvasprintf-posix: New file.
128325         Suggested by Eric Blake.
128327 2007-10-30  Bruno Haible  <bruno@clisp.org>
128329         * modules/xprintf-posix-tests: New file.
128330         * tests/test-xprintf-posix.sh: New file.
128331         * tests/test-xprintf-posix.c: New file.
128332         * tests/test-xfprintf-posix.c: New file.
128334         * modules/xprintf-posix: New file.
128336 2007-10-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128338         * modules/fbufmode-tests (MOSTLYCLEANFILES): Remove temp files.
128339         * modules/freadable-tests (MOSTLYCLEANFILES): Likewise.
128340         * modules/fwritable-tests (MOSTLYCLEANFILES): Likewise.
128342 2007-10-29  Bruno Haible  <bruno@clisp.org>
128344         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Rename the cache variable to
128345         contain the special marker '_cv_'.
128346         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
128347         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
128348         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
128349         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Likewise.
128350         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
128351         Reported by Ralf Wildenhues.
128353 2007-10-29  Bruno Haible  <bruno@clisp.org>
128355         * gnulib-tool (func_import): When --lgpl is not specified, set
128356         sed_transform_lib_file to convert LGPL and GPLv2+ copyright headers to
128357         GPLv3.
128358         Reported by Simon Josefsson.
128360 2007-10-28  Bruno Haible  <bruno@clisp.org>
128362         * lib/math.in.h: Test REPLACE_ISFINITE instead of HAVE_DECL_ISFINITE.
128363         * m4/isfinite.m4 (gl_ISFINITE): Initialize REPLACE_ISFINITE instead of
128364         HAVE_DECL_ISFINITE.
128365         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
128366         * modules/math (Makefile.am): Substitute REPLACE_ISFINITE instead of
128367         HAVE_DECL_ISFINITE.
128369 2007-10-28  Bruno Haible  <bruno@clisp.org>
128371         * lib/stdint.in.h (_STDINT_MAX): Subtract 1 from an unused signed
128372         integer shift in the signed case. Fixes warnings with OSF/1 5.1 cc.
128374 2007-10-28  Bruno Haible  <bruno@clisp.org>
128376         Fix link errors with Sun C 5.0 on Solaris 10.
128377         * m4/floorf.m4 (gl_FUNC_FLOORF): Consider also the case that the
128378         function is declared but not present in the compiler's libm.
128379         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
128380         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
128381         * m4/ceill.m4 (gl_FUNC_CEILL: Likewise.
128382         * lib/math.in.h: Test REPLACE_CEILF instead of HAVE_DECL_CEILF.
128383         Test REPLACE_CEILL instead of HAVE_DECL_CEILL.
128384         Test REPLACE_FLOORF instead of HAVE_DECL_FLOORF.
128385         Test REPLACE_FLOORL instead of HAVE_DECL_FLOORL.
128386         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
128387         * modules/math (Makefile.am): Substitute REPLACE_CEILF instead of
128388         HAVE_DECL_CEILF, REPLACE_CEILL instead of HAVE_DECL_CEILL,
128389         REPLACE_FLOORF instead of HAVE_DECL_FLOORF, REPLACE_FLOORL instead of
128390         HAVE_DECL_FLOORL.
128392 2007-10-28  Bruno Haible  <bruno@clisp.org>
128394         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): New macro, extracted from
128395         gl_FUNC_FLOORL. Cache the result.
128396         (gl_FUNC_FLOORL): Use it.
128397         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): New macro, extracted from
128398         gl_FUNC_CEILL. Cache the result.
128399         (gl_FUNC_CEILL): Use it.
128401         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): New macro, extracted from
128402         gl_FUNC_FLOOR. Cache the result.
128403         (gl_FUNC_FLOOR): Use it.
128404         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): New macro, extracted from
128405         gl_FUNC_CEIL. Cache the result.
128406         (gl_FUNC_CEIL): Use it.
128408         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): New macro, extracted from
128409         gl_FUNC_FLOORF. Cache the result.
128410         (gl_FUNC_FLOORF): Use it.
128411         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): New macro, extracted from
128412         gl_FUNC_CEILF. Cache the result.
128413         (gl_FUNC_CEILF): Use it.
128415 2007-10-28  Bruno Haible  <bruno@clisp.org>
128417         * gnulib-tool: Allow specifying the LGPL version number through
128418         --lgpl=2 or --lgpl=3.
128419         (func_usage): Document --lgpl with argument.
128420         Handle --lgpl=... arguments.
128421         (func_import): Recognize also gl_LGPL calls with an argument. When
128422         --lgpl=2 is used and the module's license is just LGPL, report an
128423         error. Set sed_transform_lib_file according to the lgpl variable. In
128424         the generated files, use --lgpl or gl_LGPL invocations with argument,
128425         if necessary.
128426         * doc/gnulib-intro.texi (Copyright): Explain how to get modules under
128427         an LGPv2+ license.
128428         * doc/gnulib-tool.texi (Modified imports): Update explanation of
128429         gl_LGPL macro.
128431 2007-10-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128432             Bruno Haible  <bruno@clisp.org>
128434         * lib/unistr.h (u8_uctomb_aux): Declare also if !HAVE_INLINE.
128435         (u16_uctomb_aux): Likewise.
128436         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Define also if
128437         !HAVE_INLINE.
128438         * lib/unistr/u16-uctomb-aux.c (u16_uctomb_aux): Likewise
128440 2007-10-28  Bruno Haible  <bruno@clisp.org>
128442         * modules/error: Add a notice recommending to change XGETTEXT_OPTIONS.
128443         Invoke AM_GETTEXT_OPTION if it exists.
128444         * modules/vasprintf: Likewise.
128445         * modules/verror: Likewise.
128446         * modules/xprintf: Likewise.
128447         * modules/xvasprintf: Likewise.
128449 2007-10-27  Ben Pfaff  <blp@gnu.org>
128451         * lib/math.in.h: Define isfinite macro and prototypes for
128452         gl_isfinitef, gl_isfinited, gl_isfinitel if we are providing
128453         implementations.
128454         * m4/math_h.m4: New substitutions for isfinite module.
128455         * lib/isfinite.c: New file.
128456         * m4/isfinite.m4: New file.
128457         * modules/math: Replace isfinite-related @VARS@ in math.in.h.
128458         * modules/isfinite: New file.
128459         * modules/isfinite-tests: New file.
128460         * tests/tests-isfinite.c: New file.
128461         * doc/functions/isfinite.texi: Mention isfinite module.
128462         * MODULES.html.sh: Mention new module.
128464 2007-10-27  Ben Pfaff  <blp@gnu.org>
128466         Ralf Wildenhues reported that Tru64 4.0D declares the round
128467         functions but does not have definitions.
128468         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): If the target function
128469         cannot be found in any library, set the output variable to
128470         "missing" instead of "".
128471         * m4/round.m4: Also use our substitute if we cannot find round in
128472         any library, even if it is declared.
128473         * m4/roundf.m4: Likewise for roundf.
128474         * m4/roundl.m4: Likewise for roundl.
128475         * lib/math.in.h: Undefine roundf, round, roundl before defining
128476         their replacements, to allow for hypothetical systems where these
128477         may be defined as macros but not available in libraries.
128479 2007-10-27  Bruno Haible  <bruno@clisp.org>
128481         * doc/gnulib.texi: Invoke @firstparagraphindent.
128482         * doc/gnulib-tool.texi (Simple update): Mention possible incompatible
128483         changes in gnulib.
128484         (Source changes): New section.
128486 2007-10-26  Bruno Haible  <bruno@clisp.org>
128488         * m4/gnulib-common.m4 (AC_C_RESTRICT): New overriding definition,
128489         borrowed from autoconf.
128491 2007-10-26  Bruno Haible  <bruno@clisp.org>
128493         * lib/strerror.c (rpl_strerror): Return "Unknown error ..." also if
128494         strerror returned the empty string. Needed on HP-UX 11.00.
128496 2007-10-24  Micah Cowan  <micah@cowan.name>
128498         Remove vestiges of cvs-gnulib-checkout process.  Now we use git.
128499         * build-aux/bootstrap: Remove support for now-unnecessary option,
128500         --cvs-user, and envvars CVS_USER, CVS_RSH.
128502 2007-10-24  Jim Meyering  <meyering@redhat.com>
128504         Avoid diagnostics from sha1sum when there is no cached checksum.
128505         * build-aux/bootstrap (update_po_files): Skip the sha1sum check
128506         if the po.s1 file hasn't been created yet.
128508         * build-aux/bootstrap: Sync from coreutils:
128509         2007-10-24  Jim Meyering  <meyering@redhat.com>
128510         Get gnulib from the git repository, not from an obsolete cvs one.
128511         * build-aux/bootstrap: Suggestion from Micah Cowan.
128512         2007-10-04  Jim Meyering  <jim@meyering.net>
128513         * build-aux/bootstrap (slurp): Adapt to _.h -> .in.h name change.
128514         (update_po_files): Work also when there are no .po files in po/.
128516 2007-10-24  Paul Eggert  <eggert@cs.ucla.edu>
128518         * README: Append ".git" to git and cg examples.
128519         Problem reported by Benoit Sigoure.
128521 2007-10-23  Micah Cowan  <micah@cowan.name>
128523         * users.txt: Add wget.
128525 2007-10-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128527         Fix linking of some unistdio tests on FreeBSD.
128528         * modules/unistdio/u16-vsnprintf-tests
128529         (test_u16_vsprintf1_LDADD): Add @LIBINTL@.
128530         * modules/unistdio/u16-vsprintf-tests
128531         (test_u16_vsnprintf1_LDADD): Likewise.
128532         * modules/unistdio/u32-vsnprintf-tests
128533         (test_u32_vsnprintf1_LDADD): Likewise.
128534         * modules/unistdio/u32-vsprintf-tests
128535         (test_u32_vsprintf1_LDADD): Likewise.
128536         * modules/unistdio/u8-vsnprintf-tests
128537         (test_u8_vsnprintf1_LDADD): Likewise.
128538         * modules/unistdio/u8-vsprintf-tests
128539         (test_u8_vsprintf1_LDADD): Likewise.
128540         * modules/unistdio/ulc-vsnprintf-tests
128541         (test_ulc_vsnprintf1_LDADD): Likewise.
128542         * modules/unistdio/ulc-vsprintf-tests
128543         (test_ulc_vsprintf1_LDADD): Likewise.
128545         Fix linking of some uniconv tests on FreeBSD.
128546         * modules/uniconv/u16-conv-from-enc-tests
128547         (test_u16_conv_from_enc_LDADD): Link $(LDADD) before @LIBICONV@.
128548         * modules/uniconv/u16-conv-to-enc-tests
128549         (test_u16_conv_to_enc_LDADD): Likewise.
128550         * modules/uniconv/u16-strconv-from-enc-tests
128551         (test_u16_strconv_from_enc_LDADD): Likewise.
128552         * modules/uniconv/u16-strconv-to-enc-tests
128553         (test_u16_strconv_to_enc_LDADD): Likewise.
128554         * modules/uniconv/u32-conv-from-enc-tests
128555         (test_u32_conv_from_enc_LDADD): Likewise.
128556         * modules/uniconv/u32-conv-to-enc-tests
128557         (test_u32_conv_to_enc_LDADD): Likewise.
128558         * modules/uniconv/u32-strconv-from-enc-tests
128559         (test_u32_strconv_from_enc_LDADD): Likewise.
128560         * modules/uniconv/u32-strconv-to-enc-tests
128561         (test_u32_strconv_to_enc_LDADD): Likewise.
128562         * modules/uniconv/u8-conv-from-enc-tests
128563         (test_u8_conv_from_enc_LDADD): Likewise.
128564         * modules/uniconv/u8-conv-to-enc-tests
128565         (test_u8_conv_to_enc_LDADD): Likewise.
128566         * modules/uniconv/u8-strconv-from-enc-tests
128567         (test_u8_strconv_from_enc_LDADD): Likewise.
128568         * modules/uniconv/u8-strconv-to-enc-tests
128569         (test_u8_strconv_to_enc_LDADD): Likewise.
128571 2007-10-22  Bruno Haible  <bruno@clisp.org>
128573         * lib/stdint.in.h: Add check that intmax_t and uintmax_t have the same
128574         size.
128576 2007-10-22  Eric Blake  <ebb9@byu.net>
128578         Tweak x*printf documentation.
128579         * lib/xprintf.c (xprintf, xvprintf, xfprintf, xvfprintf): Adjust
128580         variable name and comments.
128581         Suggested by Bruno Haible.
128583 2007-10-22  Bruno Haible  <bruno@clisp.org>
128585         * lib/acl.c (copy_acl): Fix file name in comment.
128587 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
128589         Fix Tru64 problem with stdbool.h.
128590         * lib/stdbool.in.h (false, true):
128591         [! (defined __cplusplus || defined __BEOS__) && !defined __GNUC__]:
128592         Don't declare as an enum in this situation; it runs afoul of Tru64.
128593         Problem reported by Steven M. Schweda in
128594         <http://lists.gnu.org/r/bug-autoconf/2007-10/msg00019.html>.
128596 2007-10-22  Eric Blake  <ebb9@byu.net>
128598         Also wrap vf?printf.
128599         * lib/xprintf.h (xvprintf, xvfprintf): New declarations.
128600         * lib/xprintf.c (xprintf, xfprintf): Work for C89.
128601         (xvprintf, xvfprintf): New functions.
128603 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128605         * modules/fstrcmp-tests (test_fstrcmp_LDADD): New, add
128606         @LIBINTL@ for FreeBSD 6.2, $(LIBTHREAD) for AIX 4.3.3.
128608         * lib/uniconv/u16-conv-to-enc.c (U_MBLEN): Define.
128609         * lib/uniconv/u32-conv-to-enc.c (U_MBLEN): Likewise.
128611 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
128613         * lib/acl.c (copy_acl): Adjust to IRIX 6.5.  Problem reported
128614         by Bruno Haible.
128616 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128618         * lib/getloadavg.c
128619         [defined (__osf__) && (defined (__alpha) || defined (__alpha__)]:
128620         Undef `sys' after including sys/table.h, for Tru64 4.0D.
128622         * tests/test-i-ring.c: Work for C89.
128624 2007-10-22  Bruno Haible  <bruno@clisp.org>
128626         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Use -1ull, not
128627         -1u, in preprocessor expression, so that we don't test for the bug
128628         in HP-UX 11.00 cpp.  Testing for this bug caused problems; see
128629         <http://lists.gnu.org/r/bug-gnulib/2007-10/msg00329.html>.
128631 2007-10-22  Eric Blake  <ebb9@byu.net>
128633         * tests/test-yesno.sh: Silence stderr during test.
128635 2007-10-22  Simon Josefsson  <simon@josefsson.org>
128637         * modules/crypto/gc-camellia: New file.
128639         * m4/gc-camellia.m4: New file.
128641         * lib/gc-libgcrypt.c (gc_cipher_open): Support Camellia.
128643         * lib/gc.h (enum Gc_cipher): Add GC_CAMELLIA128, GC_CAMELLIA256.
128645 2007-10-22  Simon Josefsson  <simon@josefsson.org>
128647         * build-aux/maint.mk (gzip_rsyncable): Don't fail if gzip sends
128648         --help to stdout.  Reported by sms@antinode.org (Steven
128649         M. Schweda).
128651 2007-10-22  Simon Josefsson  <simon@josefsson.org>
128653         * users.txt: Fix link to libksba.
128655 2007-10-21  Ben Pfaff  <blp@gnu.org>
128657         * modules/roundf-tests: Add dependency on floorf, ceilf to allow
128658         round.c roundf implementation that depends on floorf and ceilf to
128659         be tested unconditionally.
128661 2007-10-21  Ben Pfaff  <blp@gnu.org>
128663         * m4/check-libm-func.m4: Removed.
128664         * m4/check-math-lib.m4: New file.
128665         * m4/round.m4: Rewrite to use gl_CHECK_MATH_LIB.
128666         * m4/roundf.m4: Ditto, and fix lack of HAVE_DECL_ROUNDF
128667         definition and lack of AC_LIBOBJ([roundf]).
128668         * m4/roundl.m4: Ditto, and similarly for roundl.
128669         * modules/round: Reference new m4 file.
128670         * modules/roundf: Ditto.
128671         * modules/roundl: Ditto.
128672         * tests/test-round2.c (main): Use ROUND instead of round.
128673         Bug report from Bruno Haible.
128675 2007-10-21  Bruno Haible  <bruno@clisp.org>
128677         * lib/printf-parse.c: Don't assume <stdint.h> exists in IN_LIBASPRINTF
128678         context.
128680 2007-10-21  Bruno Haible  <bruno@clisp.org>
128682         * tests/test-wcwidth.c (main): Allow negative result for some control
128683         characters.
128685         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check also the width of U+200B.
128686         Needed on OSF/1 5.1.
128688 2007-10-21  Bruno Haible  <bruno@clisp.org>
128690         * tests/test-floorf1.c: Include isnanf.h.
128691         (main): Use isnanf() instead of isnan().
128692         * tests/test-ceilf1.c: Include isnanf.h.
128693         (main): Use isnanf() instead of isnan().
128694         * tests/test-truncf1.c: Include isnanf.h.
128695         (main): Use isnanf() instead of isnan().
128696         * tests/test-roundf1.c: Include isnanf.h.
128697         (main): Use isnanf() instead of isnan().
128699 2007-10-21  Eric Blake  <ebb9@byu.net>
128701         * users.txt: Update URL for m4.
128703 2007-10-21  Bruno Haible  <bruno@clisp.org>
128705         * users.txt: Add clisp. Update URLs to Simon Josefsson's projects.
128707 2007-10-21  Bruno Haible  <bruno@clisp.org>
128709         * gnulib-tool (func_create_megatestdir): Determine the cvsdate from
128710         Git's management files if the CVS files are not present.
128712 2007-10-20  Bruno Haible  <bruno@clisp.org>
128714         * lib/count-one-bits.h (COUNT_ONE_BITS): Use the builtin also for
128715         gcc-3.4.x.
128717 2007-10-20  Ben Pfaff  <blp@gnu.org>
128719         * lib/math.in.h: Declare round, roundf, roundl if we are providing
128720         implementations.
128721         * m4/math_h.m4: New substitutions for round, roundf, roundl modules.
128722         * lib/round.c: New file.
128723         * lib/roundf.c: New file.
128724         * lib/roundl.c: New file.
128725         * m4/round.m4: New file.
128726         * m4/roundf.m4: New file.
128727         * m4/roundl.m4: New file.
128728         * m4/check-libm-func-m4: New file.
128729         * modules/math: Replace round, roundf, roundl related @VARS@ in
128730         math.in.h.
128731         * modules/round: New file.
128732         * modules/round-tests: New file.
128733         * modules/roundf: New file.
128734         * modules/roundf-tests: New file.
128735         * modules/roundl: New file.
128736         * modules/roundl-tests: New file.
128737         * tests/test-round1.c: New file.
128738         * tests/test-round2.c: New file.
128739         * tests/test-roundf1.c: New file.
128740         * tests/test-roundf2.c: New file.
128741         * tests/test-roundl.c: New file.
128742         * doc/functions/round.texi: Mention round module.
128743         * doc/functions/roundf.texi: Mention roundf module.
128744         * doc/functions/roundl.texi: Mention roundl module.
128745         * MODULES.html.sh: Mention new modules.
128746         Thanks to Bruno Haible for suggestions.
128748 2007-10-20  Jim Meyering  <meyering@redhat.com>
128750         * lib/xprintf.c: Include <config.h> unconditionally.
128752         Change xprintf's license to GPL.
128753         * modules/xprintf (License): s/LGPL/GPL/, since this module
128754         depends on modules (exit and exitfail) which are GPL.
128755         Suggestion from Bruno Haible.
128757         xprintf fixes.
128758         * lib/xprintf.c (xprintf, xfprintf): Use va_end.
128759         Use a clearer diagnostic.
128760         Patch from Bruno Haible.
128762 2007-10-20  Bruno Haible  <bruno@clisp.org>
128764         * lib/vasnprintf.c (VASNPRINTF): Don't report overflow if the available
128765         length is INT_MAX and sizeof (DCHAR_T) > sizeof (TCHAR_T).
128766         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
128768 2007-10-20  Bruno Haible  <bruno@clisp.org>
128770         * tests/test-floorf2.c (correct_result_p): Don't rely on excess
128771         precision in the comparison result > x - 1 or similar.
128772         * tests/test-ceilf2.c (correct_result_p): Likewise.
128773         * tests/test-truncf2.c (correct_result_p): Likewise.
128774         * tests/test-trunc2.c (correct_result_p): Likewise.
128775         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
128777 2007-10-20  Bruno Haible  <bruno@clisp.org>
128779         * modules/ceil: New file.
128780         * m4/ceil.m4: New file.
128781         * doc/functions/ceil.texi: Mention the 'ceil' module.
128783 2007-10-20  Bruno Haible  <bruno@clisp.org>
128785         * modules/floor: New file.
128786         * m4/floor.m4: New file.
128787         * doc/functions/floor.texi: Mention the 'floor' module.
128789 2007-10-20  Bruno Haible  <bruno@clisp.org>
128791         * modules/ceilf-tests (Depends-on): Add fprintf-posix. Needed for use
128792         of %a.
128793         * modules/floorf-tests (Depends-on): Likewise.
128794         * modules/truncf-tests (Depends-on): Likewise.
128795         * modules/trunc-tests (Depends-on): Likewise.
128796         Reported by Ben Pfaff.
128798 2007-10-19  Jim Meyering  <meyering@redhat.com>
128800         * lib/xprintf.c (xprintf, xfprintf): Test err < 0, not just "err".
128801         Don't bother testing specific errno values.  Just test ferror.
128803         New module: xprintf
128804         * modules/xprintf, lib/xprintf.c, lib/xprintf.h: New files.
128806 2007-10-19  Bruno Haible  <bruno@clisp.org>
128808         * modules/csharpexec (Makefile.am): Use @FOO@ syntax instead of $(FOO)
128809         syntax.
128810         * modules/javaexec (Makefile.am): Likewise.
128811         * modules/relocatable-prog (Makefile.am): Likewise.
128812         Suggested by Jim Meyering.
128814 2007-10-18  Bruno Haible  <bruno@clisp.org>
128816         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on glibc >= 2.3 systems.
128817         Reported by Jim Meyering.
128819 2007-10-18  Eric Blake  <ebb9@byu.net>
128821         * modules/filenamecat-tests (Makefile.am): Link against -lintl.
128823 2007-10-18  Bruno Haible  <bruno@clisp.org>
128825         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N, gl_SNPRINTF_DIRECTIVE_N): Put
128826         the format string into writable memory. Needed in Fortify conditions.
128828 2007-10-18  Colin Watson  <cjwatson@debian.org>  (tiny change)
128829             Bruno Haible  <bruno@clisp.org>
128831         * lib/trim.c: Include config.h unconditionally. Include trim.h always.
128832         Include ctype.h always. Include stdlib.h, not mbuiter.h, for MB_CUR_MAX.
128833         * modules/trim (Depends-on): Add mbchar.
128834         (configure.ac): Add gl_FUNC_MBRTOWC.
128835         (Makefile.am): Augment lib_SOURCES.
128837 2007-10-17  Paul Eggert  <eggert@cs.ucla.edu>
128839         Modify glob.c to use fstatat and dirfd, to simplify it.
128840         Suggested by Eric Blake.
128841         * lib/glob.c (__fxstatat64) [!_LIBC]: New macro.
128842         Don't include <stdbool.h>; not used.
128843         (link_exists2_p, glob_in_dir) [!_LIBC]: No longer a special case.
128844         (link_exists_p): Simplify implementation, since we can now assume
128845         dirfd and fstatat.
128846         * modules/glob (Depends-on): Add dirfd, openat.  Remove stdbool.
128848 2007-10-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128850         * gnulib-tool (func_get_dependencies): Fix sed script to
128851         match only tests.
128853 2007-10-17  Bruno Haible  <bruno@clisp.org>
128855         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): On Cygwin, don't
128856         allow locale names without encoding suffix.
128857         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
128858         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
128860 2007-10-16  Bruno Haible  <bruno@clisp.org>
128862         * lib/getcwd.c (__getcwd): Define with explicit rpl_ prefix.
128863         * lib/getgroups.c (getgroups): Likewise.
128864         * lib/gettimeofday.c (localtime, gmtime, tzset): Likewise.
128866 2007-10-16  Bruno Haible  <bruno@clisp.org>
128868         * modules/absolute-header (License): Change from LGPL to LGPLv2+.
128869         * modules/malloc-posix (License): Likewise.
128870         * modules/realloc-posix (License): Likewise.
128871         * modules/calloc-posix (License): Likewise.
128872         * modules/intprops (License): Change from GPL to LGPL, with
128873         Paul Eggert's approval.
128875 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
128877         Merge glibc changes into lib/glob.c.
128879         * lib/glob.c (glob_in_dir): Sync with glibc/posix/glob.c, dated
128880         2007-10-15 04:59:03 UTC.  Here are the changes:
128882         2007-10-14  Ulrich Drepper  <drepper@redhat.com>
128884         * lib/glob.c: Reimplement link_exists_p to use fstatat64.
128886         * lib/glob.c: Add some branch prediction throughout.
128888         2007-10-07  Ulrich Drepper  <drepper@redhat.com>
128890         [BZ #5103]
128891         * lib/glob.c (glob): Recognize patterns starting \/.
128893         2007-02-14  Jakub Jelinek  <jakub@redhat.com>
128895         [BZ #3996]
128896         * lib/glob.c (attribute_hidden): Define if not defined.
128897         (glob): Unescape dirname, filename or username when needed and not
128898         GLOB_NOESCAPE.  Handle \/ correctly.  Handle GLOB_MARK if filename
128899         is NULL.  Handle unescaped [ in pattern without closing ].
128900         Don't pass GLOB_CHECK down to recursive glob for directories.
128901         (__glob_pattern_type): New function.
128902         (__glob_pattern_p): Implement using __glob_pattern_type.
128903         (glob_in_dir): Handle GLOB_NOCHECK patterns containing no meta
128904         characters and backslashes if not GLOB_NOESCAPE or unterminated [.
128905         Remove unreachable code.
128907         2006-09-30  Ulrich Drepper  <drepper@redhat.com>
128909         * lib/glob.c (glob_in_dir): Add some comments and asserts to
128910         explain why there are no leaks.
128912         2006-09-25  Jakub Jelinek  <jakub@redhat.com>
128914         [BZ #3253]
128915         * lib/glob.c (glob_in_dir): Don't alloca one struct globlink at a
128916         time, rather allocate increasingly bigger arrays of pointers, if
128917         possible with alloca, if too large with malloc.
128919 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
128921         Check for 64-bit int errors in HP-UX 10.20 preprocessor.
128922         Problem reported by H.Merijn Brand in
128923         <http://lists.gnu.org/r/bug-tar/2007-10/msg00018.html>.
128924         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Check preprocessor too.
128925         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
128927 2007-10-15  Bruno Haible  <bruno@clisp.org>
128929         * lib/fchdir.c (close, open, closedir, opendir, dup, dup2): Define
128930         with explicit rpl_ prefix.
128931         * lib/fopen.c (fopen): Likewise.
128932         * lib/freopen.c (freopen): Likewise.
128933         * lib/iconv.c (iconv): Likewise.
128934         * lib/iconv_close.c (iconv_close): Likewise.
128936 2007-10-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
128938         * m4/iconv_open (gl_FUNC_ICONV_OPEN_UTF): Fix cache variable name.
128940 2007-10-15  Bruno Haible  <bruno@clisp.org>
128942         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Use
128943         <stddef.h> instead of <stdlib.h> since we only need NULL.
128944         Reported by Ben Pfaff <blp@cs.stanford.edu>.
128946 2007-10-15  Bruno Haible  <bruno@clisp.org>
128948         * doc/gnulib-tool.texi (Initial import): Swap order of -I directives.
128949         Replace paragraph talking about LIBOBJS.
128950         Reported by Colin Watson <cjwatson@debian.org>.
128952 2007-10-15  Bruno Haible  <bruno@clisp.org>
128954         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Include
128955         <stdlib.h> before using NULL.
128957 2007-10-15  Simon Josefsson  <simon@josefsson.org>
128959         * m4/getaddrinfo.m4: Use NULL rather than 0 for pointers.
128960         Reported by Albert Chin <china@thewrittenword.com>.
128962 2007-10-14  Bruno Haible  <bruno@clisp.org>
128964         * modules/iconv_open-utf-tests: New file.
128965         * tests/test-iconv-utf.c: New file.
128967         Enhance iconv_open to support UTF-16BE, UTF-16LE, UTF-32BE, UTF-32LE.
128968         * modules/iconv_open-utf: New file.
128969         * lib/iconv.in.h (_ICONV_UTF8_UTF*, _ICONV_UTF*_UTF8): New macros.
128970         (iconv, iconv_close): New declarations.
128971         * lib/iconv_open.c: Include c-strcase.h. Don't require ICONV_FLAVOR to
128972         be defined.
128973         (iconv_open): Add special handling of conversion between UTF-8 and
128974         UTF-{16,32}{BE,LE}.
128975         * lib/iconv.c: New file, incorporating code from GNU libiconv 1.11.
128976         * lib/iconv_close.c: New file.
128977         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): New macro, extracted from
128978         gl_FUNC_ICONV_OPEN.
128979         (gl_FUNC_ICONV_OPEN): Use it.
128980         (gl_FUNC_ICONV_OPEN_UTF): New macro.
128981         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Initialize also REPLACE_ICONV
128982         and REPLACE_ICONV_UTF.
128983         * modules/iconv_open (Depends-on): Add c-strcase.
128984         (Makefile.am): Substitute also REPLACE_ICONV, REPLACE_ICONV_UTF,
128985         ICONV_CONST.
128986         * doc/functions/iconv_open.texi: Mention the iconv_open-utf module.
128988 2007-10-13  Albert Chin  <china@thewrittenword.com>
128989             Bruno Haible  <bruno@clisp.org>
128991         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Perform the test for getaddrinfo
128992         through a link check that includes <netdb.h>. Needed for OSF/1 5.1.
128994 2007-10-13  Bruno Haible  <bruno@clisp.org>
128996         * lib/argp-fmtstream.h (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is
128997         defined, use the ISO C99 inline semantics.
128998         * lib/argp.h (ARGP_EI): Likewise.
129000 2007-10-13  Bruno Haible  <bruno@clisp.org>
129002         Handle 'inline' change in gcc 4.3.0.
129003         * lib/argp-fmtstream.h (argp_fmtstream_putc, argp_fmtstream_puts,
129004         argp_fmtstream_write, argp_fmtstream_set_lmargin,
129005         argp_fmtstream_set_rmargin, argp_fmtstream_set_wmargin,
129006         argp_fmtstream_point): Disable 'extern' declaration if the function
129007         definition is going to be provided inline.
129008         (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is defined, use the GNU C inline
129009         semantics, not the ISO C99 inline semantics.
129010         * lib/argp.h (argp_usage, _option_is_short, _option_is_end): Disable
129011         'extern' declaration if the function definition is going to be provided
129012         inline.
129013         (ARGP_EI): Don't assume GNU C. If __GNUC_STDC_INLINE__ is defined, use
129014         the GNU C inline semantics, not the ISO C99 inline semantics. With
129015         GCC 4.2, avoid a warning.
129017 2007-10-13  Bruno Haible  <bruno@clisp.org>
129019         * lib/freading.h (freading): Enable the use of __freading for
129020         glibc >= 2.7.
129021         * lib/freading.c (freading): Likewise.
129023 2007-10-12  Paul Eggert  <eggert@cs.ucla.edu>
129025         * lib/argp-fmtstream.h (ARGP_FS_EI): Work around GCC 4.2.1 diagnostic
129026         "warning: C99 inline functions are not supported; using GNU89".
129028 2007-10-12  Bruno Haible  <bruno@clisp.org>
129030         * lib/ceil.c (FUNC): Avoid rounding errors for values near a power
129031         of 2.
129032         * tests/test-ceilf2.c: New file.
129033         * modules/ceilf-tests: (Files, Depends-on, Makefile.am): Add new test.
129035         * tests/test-ceilf1.c: Renamed from tests/test-ceilf.c.
129036         * modules/ceilf-tests: Update.
129038 2007-10-12  Bruno Haible  <bruno@clisp.org>
129040         * lib/floor.c (FUNC): Avoid rounding errors for values near a power
129041         of 2.
129042         * tests/test-floorf2.c: New file.
129043         * modules/floorf-tests: (Files, Depends-on, Makefile.am): Add new test.
129045         * tests/test-floorf1.c: Renamed from tests/test-floorf.c.
129046         * modules/floorf-tests: Update.
129048 2007-10-12  Bruno Haible  <bruno@clisp.org>
129050         * tests/test-trunc2.c: New file.
129051         * modules/trunc-tests: (Files, Depends-on, Makefile.am): Add new test.
129053         * tests/test-trunc1.c: Renamed from tests/test-trunc.c.
129054         * modules/trunc-tests: Update.
129056 2007-10-12  Bruno Haible  <bruno@clisp.org>
129058         * lib/trunc.c (FUNC): Avoid rounding errors for values near a power
129059         of 2.
129060         * tests/test-truncf2.c: New file.
129061         * modules/truncf-tests: (Files, Depends-on, Makefile.am): Add new test.
129063         * tests/test-truncf1.c: Renamed from tests/test-truncf.c.
129064         * modules/truncf-tests: Update.
129066 2007-10-11  Eric Blake  <ebb9@byu.net>
129068         Don't claim strerror is broken on Interix.
129069         * doc/functions/strerror.texi (strerror): Known broken systems are
129070         now Solaris 8, and not Interix.
129071         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): No longer filter out
129072         Interix on cross-compile.
129073         Reported by Martin Koeppe in
129074         http://lists.gnu.org/r/bug-gnulib/2007-10/msg00005.html.
129076 2007-10-11  Bruno Haible  <bruno@clisp.org>
129078         * modules/i-ring-tests: New file.
129079         * tests/test-i-ring.c: Renamed from lib/i-ring-test.c. Use ASSERT
129080         instead of assert.
129082 2007-10-11  Bruno Haible  <bruno@clisp.org>
129084         * modules/filenamecat-tests: New file.
129085         * tests/test-filenamecat.c: New file, extracted from lib/filenamecat.c.
129086         * lib/filenamecat.c: Remove test code.
129088 2007-10-11  Paul Eggert  <eggert@cs.ucla.edu>
129090         Simplify and modernize strerror substitute, partly to fix Solaris 8 bug.
129092         * lib/strerror.c: Include <string.h> always, to test interface,
129093         and to remove the need for the dummy.
129094         Include intprops.h to compute width instead of doing it ourselves
129095         and missing a CHAR_BIT declaration, which broke tar 1.19 on Solaris 8.
129096         (strerror): Define it to return NULL if there's no system strerror.
129097         (rpl_strerror): Use INT_STRLEN_BOUND to compute bound.
129098         Omit !HAVE_STRERROR code.  We don't need to worry about supporting
129099         ancient pre-strerror Unix systems well any more.  Saying "unknown
129100         system error" is enough.
129101         * lib/string.in.h (strerror): Simplify the ifdef to reflect the
129102         simpler strerror.c implementation.
129103         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE, gl_PREREQ_STDERROR):
129104         Simplify the tests to reflect the simpler strerror implementation.
129105         * modules/strerror (Depends-on): Add intprops.
129107 2007-10-09  Eric Blake  <ebb9@byu.net>
129109         Silence test-fpending.
129110         * modules/fpending-tests (Files): Add wrapper script.
129111         * tests/test-fpending.sh: New file.
129113 2007-10-09  Bruno Haible  <bruno@clisp.org>
129115         * MODULES.html.sh (func_module): Don't create a hyperlink for
129116         function names like 'printf_frexp'.
129117         (Misc): Add crc, memxor.
129118         (Characteristics of floating types): New section.
129119         (Mathematics): Add ceilf, ceill, floorf, floorl, frexpl-nolibm,
129120         isnanf-nolibm, signbit, trunc, truncf, truncl.
129121         (Enhancements for ISO C 99 functions): New subsection Input/output.
129122         (Support for systems lacking POSIX:2001): Add arpa_inet, calloc-posix,
129123         fcntl, fopen, freopen, fseek, fseeko, ftell, ftello, iconv_open,
129124         locale, malloc-posix, netinet_in, open, realloc-posix, signal, sleep.
129125         (Compatibility checks for POSIX:2001 functions): Add clock-time.
129126         (Enhancements for POSIX:2001 functions): Add chdir-long.
129127         (File system functions): Add areadlink, chdir-safer, read-file.
129128         Remove cycle-check.
129129         (File system as inode set): New section.
129130         (Date and time): Add gethrxtime.
129131         (Multithreading): Add openmp.
129132         (Internationalization functions): Add localename.
129133         (Unicode string functions): Add unistr/u*-mbsnlen.
129134         (Support for maintaining and releasing projects): Add git-version-gen.
129135         (Lone files): Remove directories.
129137 2007-10-08  Ben Pfaff  <blp@gnu.org>
129139         * lib/xmalloca.h: Fix typo in comment.
129141 2007-10-08  Paul Eggert  <eggert@cs.ucla.edu>
129143         * lib/xnanosleep.c (xnanosleep): Don't assume GCC 4.3.0 behavior
129144         when avoiding problems with integer overflow.  Use a portable test
129145         instead.
129147 2007-10-08  Simon Josefsson  <simon@josefsson.org>
129149         * modules/dummy (License): Change to LGPLv2+.
129150         * modules/float (License): Likewise
129151         * modules/realloc (License): Likewise
129152         * modules/stdlib (License): Likewise
129154 2007-10-07  Bruno Haible  <bruno@clisp.org>
129156         * trunc.c (TWO_MANT_DIG): Change type to DOUBLE.
129157         * floor.c (TWO_MANT_DIG): Likewise.
129158         * ceil.c (TWO_MANT_DIG): Likewise.
129159         Reported by Ben Pfaff.
129161 2007-10-07  Bruno Haible  <bruno@clisp.org>
129163         Avoid gcc warnings "declaration of 'exp' shadows a global declaration".
129164         * lib/math.in.h (frexp, frexpl): Change parameter name to 'expptr'.
129165         * lib/frexp.c (FUNC): Likewise.
129166         * lib/printf-frexp.h (printf_frexp): Likewise.
129167         * lib/printf-frexpl.h (printf_frexpl): Likewise.
129168         * lib/printf-frexp.c (FUNC): Likewise.
129169         Suggested by Jim Meyering.
129171 2007-10-07  Jim Meyering  <meyering@redhat.com>
129173         Make xnanosleep's integer overflow test more robust.
129174         * lib/xnanosleep.c (xnanosleep): Declare a temporary to be "volatile",
129175         so that gcc-4.3.0 doesn't optimize away this test for overflow.
129177 2007-10-07  Bruno Haible  <bruno@clisp.org>
129179         * NEWS: Mention the license change.
129181         * doc/gnulib-intro.texi (Copyright): Update the meaning of the license
129182         abbreviations in the modules files.
129184         Change copyright notice from GPLv2+ to GPLv3+.
129185         * README: Change copyright notice.
129186         * MODULES.html.sh: Likewise.
129187         * build-aux/bootstrap.conf: Likewise.
129188         * build-aux/config.libpath: Likewise.
129189         * build-aux/csharpcomp.sh.in: Likewise.
129190         * build-aux/csharpexec.sh.in: Likewise.
129191         * build-aux/install-reloc: Likewise.
129192         * build-aux/javacomp.sh.in: Likewise.
129193         * build-aux/javaexec.sh.in: Likewise.
129194         * build-aux/ldd.sh.in: Likewise.
129195         * build-aux/reloc-ldflags: Likewise.
129196         * build-aux/relocatable.sh.in: Likewise.
129197         * build-aux/x-to-1.in: Likewise.
129198         * check-module: Likewise.
129199         * config/srclistvars.sh: Likewise.
129200         * gnulib-tool: Likewise.
129201         * lib/acl-internal.h: Likewise.
129202         * lib/acl.c: Likewise.
129203         * lib/acl.h: Likewise.
129204         * lib/acl_entries.c: Likewise.
129205         * lib/areadlink-with-size.c: Likewise.
129206         * lib/areadlink.c: Likewise.
129207         * lib/areadlink.h: Likewise.
129208         * lib/argmatch.c: Likewise.
129209         * lib/argmatch.h: Likewise.
129210         * lib/argp-ba.c: Likewise.
129211         * lib/argp-eexst.c: Likewise.
129212         * lib/argp-fmtstream.c: Likewise.
129213         * lib/argp-fmtstream.h: Likewise.
129214         * lib/argp-fs-xinl.c: Likewise.
129215         * lib/argp-help.c: Likewise.
129216         * lib/argp-namefrob.h: Likewise.
129217         * lib/argp-parse.c: Likewise.
129218         * lib/argp-pin.c: Likewise.
129219         * lib/argp-pv.c: Likewise.
129220         * lib/argp-pvh.c: Likewise.
129221         * lib/argp-xinl.c: Likewise.
129222         * lib/argp.h: Likewise.
129223         * lib/at-func.c: Likewise.
129224         * lib/atanl.c: Likewise.
129225         * lib/backupfile.c: Likewise.
129226         * lib/backupfile.h: Likewise.
129227         * lib/basename.c: Likewise.
129228         * lib/binary-io.h: Likewise.
129229         * lib/byteswap.in.h: Likewise.
129230         * lib/c-stack.c: Likewise.
129231         * lib/c-stack.h: Likewise.
129232         * lib/c-strcasestr.c: Likewise.
129233         * lib/c-strcasestr.h: Likewise.
129234         * lib/c-strstr.c: Likewise.
129235         * lib/c-strstr.h: Likewise.
129236         * lib/c-strtod.c: Likewise.
129237         * lib/calloc.c: Likewise.
129238         * lib/canon-host.c: Likewise.
129239         * lib/canon-host.h: Likewise.
129240         * lib/canonicalize-lgpl.c: Likewise.
129241         * lib/canonicalize.c: Likewise.
129242         * lib/canonicalize.h: Likewise.
129243         * lib/ceil.c: Likewise.
129244         * lib/ceilf.c: Likewise.
129245         * lib/ceill.c: Likewise.
129246         * lib/chdir-long.c: Likewise.
129247         * lib/chdir-long.h: Likewise.
129248         * lib/chdir-safer.c: Likewise.
129249         * lib/chdir-safer.h: Likewise.
129250         * lib/chown.c: Likewise.
129251         * lib/classpath.c: Likewise.
129252         * lib/classpath.h: Likewise.
129253         * lib/clean-temp.c: Likewise.
129254         * lib/clean-temp.h: Likewise.
129255         * lib/cloexec.c: Likewise.
129256         * lib/close-stream.c: Likewise.
129257         * lib/closein.c: Likewise.
129258         * lib/closein.h: Likewise.
129259         * lib/closeout.c: Likewise.
129260         * lib/closeout.h: Likewise.
129261         * lib/concat-filename.c: Likewise.
129262         * lib/copy-file.c: Likewise.
129263         * lib/copy-file.h: Likewise.
129264         * lib/count-one-bits.h: Likewise.
129265         * lib/crc.c: Likewise.
129266         * lib/crc.h: Likewise.
129267         * lib/creat-safer.c: Likewise.
129268         * lib/csharpcomp.c: Likewise.
129269         * lib/csharpcomp.h: Likewise.
129270         * lib/csharpexec.c: Likewise.
129271         * lib/csharpexec.h: Likewise.
129272         * lib/cycle-check.c: Likewise.
129273         * lib/cycle-check.h: Likewise.
129274         * lib/diacrit.c: Likewise.
129275         * lib/diacrit.h: Likewise.
129276         * lib/diffseq.h: Likewise.
129277         * lib/dirchownmod.c: Likewise.
129278         * lib/dirent.in.h: Likewise.
129279         * lib/dirfd.c: Likewise.
129280         * lib/dirfd.h: Likewise.
129281         * lib/dirname.c: Likewise.
129282         * lib/dirname.h: Likewise.
129283         * lib/dummy.c: Likewise.
129284         * lib/dup-safer.c: Likewise.
129285         * lib/dup2.c: Likewise.
129286         * lib/eealloc.h: Likewise.
129287         * lib/error.c: Likewise.
129288         * lib/error.h: Likewise.
129289         * lib/euidaccess.c: Likewise.
129290         * lib/exclude.c: Likewise.
129291         * lib/exclude.h: Likewise.
129292         * lib/execute.c: Likewise.
129293         * lib/execute.h: Likewise.
129294         * lib/exitfail.c: Likewise.
129295         * lib/exitfail.h: Likewise.
129296         * lib/expl.c: Likewise.
129297         * lib/fatal-signal.c: Likewise.
129298         * lib/fatal-signal.h: Likewise.
129299         * lib/fbufmode.c: Likewise.
129300         * lib/fbufmode.h: Likewise.
129301         * lib/fchdir.c: Likewise.
129302         * lib/fchmodat.c: Likewise.
129303         * lib/fchownat.c: Likewise.
129304         * lib/fcntl--.h: Likewise.
129305         * lib/fcntl-safer.h: Likewise.
129306         * lib/fcntl.in.h: Likewise.
129307         * lib/fd-safer.c: Likewise.
129308         * lib/fflush.c: Likewise.
129309         * lib/file-has-acl.c: Likewise.
129310         * lib/file-set.c: Likewise.
129311         * lib/file-type.c: Likewise.
129312         * lib/file-type.h: Likewise.
129313         * lib/fileblocks.c: Likewise.
129314         * lib/filemode.c: Likewise.
129315         * lib/filemode.h: Likewise.
129316         * lib/filename.h: Likewise.
129317         * lib/filenamecat.c: Likewise.
129318         * lib/filenamecat.h: Likewise.
129319         * lib/findprog.c: Likewise.
129320         * lib/findprog.h: Likewise.
129321         * lib/float.in.h: Likewise.
129322         * lib/floor.c: Likewise.
129323         * lib/floorf.c: Likewise.
129324         * lib/floorl.c: Likewise.
129325         * lib/fopen-safer.c: Likewise.
129326         * lib/fopen.c: Likewise.
129327         * lib/fpending.c: Likewise.
129328         * lib/fpending.h: Likewise.
129329         * lib/fprintf.c: Likewise.
129330         * lib/fprintftime.h: Likewise.
129331         * lib/fpucw.h: Likewise.
129332         * lib/fpurge.c: Likewise.
129333         * lib/fpurge.h: Likewise.
129334         * lib/freadable.c: Likewise.
129335         * lib/freadable.h: Likewise.
129336         * lib/freadahead.c: Likewise.
129337         * lib/freadahead.h: Likewise.
129338         * lib/freading.c: Likewise.
129339         * lib/freading.h: Likewise.
129340         * lib/free.c: Likewise.
129341         * lib/freopen.c: Likewise.
129342         * lib/frexp.c: Likewise.
129343         * lib/frexpl.c: Likewise.
129344         * lib/fseek.c: Likewise.
129345         * lib/fseterr.c: Likewise.
129346         * lib/fseterr.h: Likewise.
129347         * lib/fstatat.c: Likewise.
129348         * lib/fstrcmp.c: Likewise.
129349         * lib/fstrcmp.h: Likewise.
129350         * lib/fsusage.c: Likewise.
129351         * lib/fsusage.h: Likewise.
129352         * lib/ftell.c: Likewise.
129353         * lib/ftello.c: Likewise.
129354         * lib/fts-cycle.c: Likewise.
129355         * lib/fts.c: Likewise.
129356         * lib/fts_.h: Likewise.
129357         * lib/full-read.c: Likewise.
129358         * lib/full-read.h: Likewise.
129359         * lib/full-write.c: Likewise.
129360         * lib/full-write.h: Likewise.
129361         * lib/fwritable.c: Likewise.
129362         * lib/fwritable.h: Likewise.
129363         * lib/fwriteerror.c: Likewise.
129364         * lib/fwriteerror.h: Likewise.
129365         * lib/fwriting.c: Likewise.
129366         * lib/fwriting.h: Likewise.
129367         * lib/gcd.c: Likewise.
129368         * lib/gcd.h: Likewise.
129369         * lib/getcwd.c: Likewise.
129370         * lib/getdate.h: Likewise.
129371         * lib/getdate.y: Likewise.
129372         * lib/getdomainname.c: Likewise.
129373         * lib/getdomainname.h: Likewise.
129374         * lib/getgroups.c: Likewise.
129375         * lib/gethostname.c: Likewise.
129376         * lib/gethrxtime.c: Likewise.
129377         * lib/gethrxtime.h: Likewise.
129378         * lib/getloadavg.c: Likewise.
129379         * lib/getndelim2.c: Likewise.
129380         * lib/getndelim2.h: Likewise.
129381         * lib/getnline.c: Likewise.
129382         * lib/getnline.h: Likewise.
129383         * lib/getopt.c: Likewise.
129384         * lib/getopt.in.h: Likewise.
129385         * lib/getopt1.c: Likewise.
129386         * lib/getopt_int.h: Likewise.
129387         * lib/getpagesize.h: Likewise.
129388         * lib/getsubopt.c: Likewise.
129389         * lib/gettime.c: Likewise.
129390         * lib/getugroups.c: Likewise.
129391         * lib/getugroups.h: Likewise.
129392         * lib/getusershell.c: Likewise.
129393         * lib/gl_anyavltree_list1.h: Likewise.
129394         * lib/gl_anyavltree_list2.h: Likewise.
129395         * lib/gl_anyhash_list1.h: Likewise.
129396         * lib/gl_anyhash_list2.h: Likewise.
129397         * lib/gl_anylinked_list1.h: Likewise.
129398         * lib/gl_anylinked_list2.h: Likewise.
129399         * lib/gl_anyrbtree_list1.h: Likewise.
129400         * lib/gl_anyrbtree_list2.h: Likewise.
129401         * lib/gl_anytree_list1.h: Likewise.
129402         * lib/gl_anytree_list2.h: Likewise.
129403         * lib/gl_anytree_oset.h: Likewise.
129404         * lib/gl_anytreehash_list1.h: Likewise.
129405         * lib/gl_anytreehash_list2.h: Likewise.
129406         * lib/gl_array_list.c: Likewise.
129407         * lib/gl_array_list.h: Likewise.
129408         * lib/gl_array_oset.c: Likewise.
129409         * lib/gl_array_oset.h: Likewise.
129410         * lib/gl_avltree_list.c: Likewise.
129411         * lib/gl_avltree_list.h: Likewise.
129412         * lib/gl_avltree_oset.c: Likewise.
129413         * lib/gl_avltree_oset.h: Likewise.
129414         * lib/gl_avltreehash_list.c: Likewise.
129415         * lib/gl_avltreehash_list.h: Likewise.
129416         * lib/gl_carray_list.c: Likewise.
129417         * lib/gl_carray_list.h: Likewise.
129418         * lib/gl_linked_list.c: Likewise.
129419         * lib/gl_linked_list.h: Likewise.
129420         * lib/gl_linkedhash_list.c: Likewise.
129421         * lib/gl_linkedhash_list.h: Likewise.
129422         * lib/gl_list.c: Likewise.
129423         * lib/gl_list.h: Likewise.
129424         * lib/gl_oset.c: Likewise.
129425         * lib/gl_oset.h: Likewise.
129426         * lib/gl_rbtree_list.c: Likewise.
129427         * lib/gl_rbtree_list.h: Likewise.
129428         * lib/gl_rbtree_oset.c: Likewise.
129429         * lib/gl_rbtree_oset.h: Likewise.
129430         * lib/gl_rbtreehash_list.c: Likewise.
129431         * lib/gl_rbtreehash_list.h: Likewise.
129432         * lib/gl_sublist.c: Likewise.
129433         * lib/gl_sublist.h: Likewise.
129434         * lib/group-member.c: Likewise.
129435         * lib/group-member.h: Likewise.
129436         * lib/hard-locale.c: Likewise.
129437         * lib/hard-locale.h: Likewise.
129438         * lib/hash-pjw.c: Likewise.
129439         * lib/hash-pjw.h: Likewise.
129440         * lib/hash-triple.c: Likewise.
129441         * lib/hash.c: Likewise.
129442         * lib/hash.h: Likewise.
129443         * lib/human.c: Likewise.
129444         * lib/human.h: Likewise.
129445         * lib/i-ring.c: Likewise.
129446         * lib/i-ring.h: Likewise.
129447         * lib/idcache.c: Likewise.
129448         * lib/imaxabs.c: Likewise.
129449         * lib/imaxdiv.c: Likewise.
129450         * lib/inet_pton.c: Likewise.
129451         * lib/inet_pton.h: Likewise.
129452         * lib/intprops.h: Likewise.
129453         * lib/inttostr.c: Likewise.
129454         * lib/inttostr.h: Likewise.
129455         * lib/inttypes.in.h: Likewise.
129456         * lib/isapipe.c: Likewise.
129457         * lib/isdir.c: Likewise.
129458         * lib/isnan.c: Likewise.
129459         * lib/isnan.h: Likewise.
129460         * lib/isnanf.c: Likewise.
129461         * lib/isnanf.h: Likewise.
129462         * lib/isnanl-nolibm.h: Likewise.
129463         * lib/isnanl.c: Likewise.
129464         * lib/isnanl.h: Likewise.
129465         * lib/javacomp.c: Likewise.
129466         * lib/javacomp.h: Likewise.
129467         * lib/javaexec.c: Likewise.
129468         * lib/javaexec.h: Likewise.
129469         * lib/javaversion.c: Likewise.
129470         * lib/javaversion.h: Likewise.
129471         * lib/javaversion.java: Likewise.
129472         * lib/lbrkprop.h: Likewise.
129473         * lib/lchmod.h: Likewise.
129474         * lib/lchown.c: Likewise.
129475         * lib/ldexpl.c: Likewise.
129476         * lib/linebreak.c: Likewise.
129477         * lib/linebreak.h: Likewise.
129478         * lib/linebuffer.c: Likewise.
129479         * lib/linebuffer.h: Likewise.
129480         * lib/locale.in.h: Likewise.
129481         * lib/logl.c: Likewise.
129482         * lib/long-options.c: Likewise.
129483         * lib/long-options.h: Likewise.
129484         * lib/lstat.c: Likewise.
129485         * lib/lstat.h: Likewise.
129486         * lib/math.in.h: Likewise.
129487         * lib/mbchar.c: Likewise.
129488         * lib/mbchar.h: Likewise.
129489         * lib/mbfile.h: Likewise.
129490         * lib/mbiter.h: Likewise.
129491         * lib/mbscasecmp.c: Likewise.
129492         * lib/mbscasestr.c: Likewise.
129493         * lib/mbschr.c: Likewise.
129494         * lib/mbscspn.c: Likewise.
129495         * lib/mbslen.c: Likewise.
129496         * lib/mbsncasecmp.c: Likewise.
129497         * lib/mbsnlen.c: Likewise.
129498         * lib/mbspbrk.c: Likewise.
129499         * lib/mbspcasecmp.c: Likewise.
129500         * lib/mbsrchr.c: Likewise.
129501         * lib/mbssep.c: Likewise.
129502         * lib/mbsspn.c: Likewise.
129503         * lib/mbsstr.c: Likewise.
129504         * lib/mbstok_r.c: Likewise.
129505         * lib/mbswidth.c: Likewise.
129506         * lib/mbswidth.h: Likewise.
129507         * lib/mbuiter.h: Likewise.
129508         * lib/memcasecmp.c: Likewise.
129509         * lib/memcasecmp.h: Likewise.
129510         * lib/memchr.c: Likewise.
129511         * lib/memcmp.c: Likewise.
129512         * lib/memcoll.c: Likewise.
129513         * lib/memcoll.h: Likewise.
129514         * lib/memcpy.c: Likewise.
129515         * lib/memrchr.c: Likewise.
129516         * lib/mkancesdirs.c: Likewise.
129517         * lib/mkdir-p.c: Likewise.
129518         * lib/mkdir-p.h: Likewise.
129519         * lib/mkdir.c: Likewise.
129520         * lib/mkdirat.c: Likewise.
129521         * lib/mkdtemp.c: Likewise.
129522         * lib/mkstemp-safer.c: Likewise.
129523         * lib/mkstemp.c: Likewise.
129524         * lib/modechange.c: Likewise.
129525         * lib/modechange.h: Likewise.
129526         * lib/mountlist.c: Likewise.
129527         * lib/mountlist.h: Likewise.
129528         * lib/mpsort.c: Likewise.
129529         * lib/nanosleep.c: Likewise.
129530         * lib/obstack.c: Likewise.
129531         * lib/obstack.h: Likewise.
129532         * lib/open-safer.c: Likewise.
129533         * lib/open.c: Likewise.
129534         * lib/openat-die.c: Likewise.
129535         * lib/openat-priv.h: Likewise.
129536         * lib/openat-proc.c: Likewise.
129537         * lib/openat.c: Likewise.
129538         * lib/openat.h: Likewise.
129539         * lib/pagealign_alloc.c: Likewise.
129540         * lib/pagealign_alloc.h: Likewise.
129541         * lib/physmem.c: Likewise.
129542         * lib/physmem.h: Likewise.
129543         * lib/pipe-safer.c: Likewise.
129544         * lib/pipe.c: Likewise.
129545         * lib/pipe.h: Likewise.
129546         * lib/posixtm.c: Likewise.
129547         * lib/posixtm.h: Likewise.
129548         * lib/posixver.c: Likewise.
129549         * lib/printf-frexp.c: Likewise.
129550         * lib/printf-frexp.h: Likewise.
129551         * lib/printf-frexpl.c: Likewise.
129552         * lib/printf-frexpl.h: Likewise.
129553         * lib/printf.c: Likewise.
129554         * lib/progname.c: Likewise.
129555         * lib/progname.h: Likewise.
129556         * lib/progreloc.c: Likewise.
129557         * lib/putenv.c: Likewise.
129558         * lib/quote.c: Likewise.
129559         * lib/quote.h: Likewise.
129560         * lib/quotearg.c: Likewise.
129561         * lib/quotearg.h: Likewise.
129562         * lib/raise.c: Likewise.
129563         * lib/readline.c: Likewise.
129564         * lib/readline.h: Likewise.
129565         * lib/readlink.c: Likewise.
129566         * lib/readtokens.c: Likewise.
129567         * lib/readtokens.h: Likewise.
129568         * lib/readtokens0.c: Likewise.
129569         * lib/readtokens0.h: Likewise.
129570         * lib/readutmp.c: Likewise.
129571         * lib/readutmp.h: Likewise.
129572         * lib/realloc.c: Likewise.
129573         * lib/relocwrapper.c: Likewise.
129574         * lib/rename-dest-slash.c: Likewise.
129575         * lib/rename.c: Likewise.
129576         * lib/rmdir.c: Likewise.
129577         * lib/rpmatch.c: Likewise.
129578         * lib/safe-read.c: Likewise.
129579         * lib/safe-read.h: Likewise.
129580         * lib/safe-write.c: Likewise.
129581         * lib/safe-write.h: Likewise.
129582         * lib/same-inode.h: Likewise.
129583         * lib/same.c: Likewise.
129584         * lib/same.h: Likewise.
129585         * lib/save-cwd.c: Likewise.
129586         * lib/save-cwd.h: Likewise.
129587         * lib/savedir.c: Likewise.
129588         * lib/savedir.h: Likewise.
129589         * lib/savewd.c: Likewise.
129590         * lib/savewd.h: Likewise.
129591         * lib/search.in.h: Likewise.
129592         * lib/setenv.c: Likewise.
129593         * lib/setenv.h: Likewise.
129594         * lib/settime.c: Likewise.
129595         * lib/sh-quote.c: Likewise.
129596         * lib/sh-quote.h: Likewise.
129597         * lib/sig2str.c: Likewise.
129598         * lib/sig2str.h: Likewise.
129599         * lib/signal.in.h: Likewise.
129600         * lib/signbitd.c: Likewise.
129601         * lib/signbitf.c: Likewise.
129602         * lib/signbitl.c: Likewise.
129603         * lib/sigprocmask.c: Likewise.
129604         * lib/sincosl.c: Likewise.
129605         * lib/sleep.c: Likewise.
129606         * lib/sprintf.c: Likewise.
129607         * lib/sqrtl.c: Likewise.
129608         * lib/stat-time.h: Likewise.
129609         * lib/stdio--.h: Likewise.
129610         * lib/stdio-safer.h: Likewise.
129611         * lib/stdlib--.h: Likewise.
129612         * lib/stdlib-safer.h: Likewise.
129613         * lib/stdlib.in.h: Likewise.
129614         * lib/stpcpy.c: Likewise.
129615         * lib/stpncpy.c: Likewise.
129616         * lib/strchrnul.c: Likewise.
129617         * lib/strcspn.c: Likewise.
129618         * lib/strerror.c: Likewise.
129619         * lib/strftime.c: Likewise.
129620         * lib/strftime.h: Likewise.
129621         * lib/striconveh.c: Likewise.
129622         * lib/striconveh.h: Likewise.
129623         * lib/striconveha.c: Likewise.
129624         * lib/striconveha.h: Likewise.
129625         * lib/stripslash.c: Likewise.
129626         * lib/strnlen1.c: Likewise.
129627         * lib/strnlen1.h: Likewise.
129628         * lib/strtod.c: Likewise.
129629         * lib/strtoimax.c: Likewise.
129630         * lib/strtok_r.c: Likewise.
129631         * lib/strtol.c: Likewise.
129632         * lib/strtoll.c: Likewise.
129633         * lib/strtoul.c: Likewise.
129634         * lib/strtoull.c: Likewise.
129635         * lib/sysexits.in.h: Likewise.
129636         * lib/tempname.c: Likewise.
129637         * lib/tempname.h: Likewise.
129638         * lib/timespec.h: Likewise.
129639         * lib/tls.c: Likewise.
129640         * lib/tls.h: Likewise.
129641         * lib/tmpdir.c: Likewise.
129642         * lib/tmpdir.h: Likewise.
129643         * lib/tmpfile-safer.c: Likewise.
129644         * lib/tmpfile.c: Likewise.
129645         * lib/trigl.c: Likewise.
129646         * lib/trigl.h: Likewise.
129647         * lib/trim.c: Likewise.
129648         * lib/trim.h: Likewise.
129649         * lib/trunc.c: Likewise.
129650         * lib/truncf.c: Likewise.
129651         * lib/truncl.c: Likewise.
129652         * lib/tsearch.c: Likewise.
129653         * lib/unicodeio.c: Likewise.
129654         * lib/unicodeio.h: Likewise.
129655         * lib/unistd--.h: Likewise.
129656         * lib/unistd-safer.h: Likewise.
129657         * lib/unistdio/ulc-fprintf.c: Likewise.
129658         * lib/unistdio/ulc-vfprintf.c: Likewise.
129659         * lib/unlinkdir.c: Likewise.
129660         * lib/unlinkdir.h: Likewise.
129661         * lib/unlocked-io.h: Likewise.
129662         * lib/unsetenv.c: Likewise.
129663         * lib/userspec.c: Likewise.
129664         * lib/utime.c: Likewise.
129665         * lib/utimecmp.c: Likewise.
129666         * lib/utimecmp.h: Likewise.
129667         * lib/utimens.c: Likewise.
129668         * lib/verify.h: Likewise.
129669         * lib/verror.c: Likewise.
129670         * lib/verror.h: Likewise.
129671         * lib/version-etc-fsf.c: Likewise.
129672         * lib/version-etc.c: Likewise.
129673         * lib/version-etc.h: Likewise.
129674         * lib/vfprintf.c: Likewise.
129675         * lib/vprintf.c: Likewise.
129676         * lib/vsprintf.c: Likewise.
129677         * lib/w32spawn.h: Likewise.
129678         * lib/wait-process.c: Likewise.
129679         * lib/wait-process.h: Likewise.
129680         * lib/wcwidth.c: Likewise.
129681         * lib/write-any-file.c: Likewise.
129682         * lib/xalloc-die.c: Likewise.
129683         * lib/xalloc.h: Likewise.
129684         * lib/xasprintf.c: Likewise.
129685         * lib/xgetcwd.c: Likewise.
129686         * lib/xgetcwd.h: Likewise.
129687         * lib/xgetdomainname.c: Likewise.
129688         * lib/xgetdomainname.h: Likewise.
129689         * lib/xgethostname.c: Likewise.
129690         * lib/xmalloc.c: Likewise.
129691         * lib/xmalloca.c: Likewise.
129692         * lib/xmalloca.h: Likewise.
129693         * lib/xmemcoll.c: Likewise.
129694         * lib/xnanosleep.c: Likewise.
129695         * lib/xreadlink.c: Likewise.
129696         * lib/xreadlink.h: Likewise.
129697         * lib/xsetenv.c: Likewise.
129698         * lib/xsetenv.h: Likewise.
129699         * lib/xstriconv.c: Likewise.
129700         * lib/xstriconv.h: Likewise.
129701         * lib/xstrndup.c: Likewise.
129702         * lib/xstrndup.h: Likewise.
129703         * lib/xstrtod.c: Likewise.
129704         * lib/xstrtod.h: Likewise.
129705         * lib/xstrtol-error.c: Likewise.
129706         * lib/xstrtol.c: Likewise.
129707         * lib/xstrtol.h: Likewise.
129708         * lib/xtime.h: Likewise.
129709         * lib/xvasprintf.c: Likewise.
129710         * lib/xvasprintf.h: Likewise.
129711         * lib/yesno.c: Likewise.
129712         * lib/yesno.h: Likewise.
129713         * posix-modules: Likewise.
129714         * tests/test-alloca-opt.c: Likewise.
129715         * tests/test-arcfour.c: Likewise.
129716         * tests/test-arctwo.c: Likewise.
129717         * tests/test-argmatch.c: Likewise.
129718         * tests/test-argp-2.sh: Likewise.
129719         * tests/test-argp.c: Likewise.
129720         * tests/test-arpa_inet.c: Likewise.
129721         * tests/test-array_list.c: Likewise.
129722         * tests/test-array_oset.c: Likewise.
129723         * tests/test-atexit.c: Likewise.
129724         * tests/test-avltree_list.c: Likewise.
129725         * tests/test-avltree_oset.c: Likewise.
129726         * tests/test-avltreehash_list.c: Likewise.
129727         * tests/test-base64.c: Likewise.
129728         * tests/test-binary-io.c: Likewise.
129729         * tests/test-byteswap.c: Likewise.
129730         * tests/test-c-ctype.c: Likewise.
129731         * tests/test-c-strcasecmp.c: Likewise.
129732         * tests/test-c-strcasestr.c: Likewise.
129733         * tests/test-c-strncasecmp.c: Likewise.
129734         * tests/test-c-strstr.c: Likewise.
129735         * tests/test-canonicalize-lgpl.c: Likewise.
129736         * tests/test-canonicalize.c: Likewise.
129737         * tests/test-carray_list.c: Likewise.
129738         * tests/test-ceilf.c: Likewise.
129739         * tests/test-ceill.c: Likewise.
129740         * tests/test-count-one-bits.c: Likewise.
129741         * tests/test-crc.c: Likewise.
129742         * tests/test-dirname.c: Likewise.
129743         * tests/test-fbufmode.c: Likewise.
129744         * tests/test-fcntl.c: Likewise.
129745         * tests/test-fflush.c: Likewise.
129746         * tests/test-floorf.c: Likewise.
129747         * tests/test-floorl.c: Likewise.
129748         * tests/test-fopen.c: Likewise.
129749         * tests/test-fprintf-posix.c: Likewise.
129750         * tests/test-fprintf-posix.h: Likewise.
129751         * tests/test-fpurge.c: Likewise.
129752         * tests/test-freadable.c: Likewise.
129753         * tests/test-freadahead.c: Likewise.
129754         * tests/test-freading.c: Likewise.
129755         * tests/test-freopen.c: Likewise.
129756         * tests/test-frexp.c: Likewise.
129757         * tests/test-frexpl.c: Likewise.
129758         * tests/test-fseek.c: Likewise.
129759         * tests/test-fseeko.c: Likewise.
129760         * tests/test-fseterr.c: Likewise.
129761         * tests/test-fstrcmp.c: Likewise.
129762         * tests/test-ftell.c: Likewise.
129763         * tests/test-ftello.c: Likewise.
129764         * tests/test-fwritable.c: Likewise.
129765         * tests/test-fwriting.c: Likewise.
129766         * tests/test-getaddrinfo.c: Likewise.
129767         * tests/test-getpass.c: Likewise.
129768         * tests/test-gettimeofday.c: Likewise.
129769         * tests/test-hmac-md5.c: Likewise.
129770         * tests/test-hmac-sha1.c: Likewise.
129771         * tests/test-iconv.c: Likewise.
129772         * tests/test-iconvme.c: Likewise.
129773         * tests/test-inttypes.c: Likewise.
129774         * tests/test-isnan.c: Likewise.
129775         * tests/test-isnanf.c: Likewise.
129776         * tests/test-isnanl-nolibm.c: Likewise.
129777         * tests/test-isnanl.c: Likewise.
129778         * tests/test-isnanl.h: Likewise.
129779         * tests/test-ldexpl.c: Likewise.
129780         * tests/test-linked_list.c: Likewise.
129781         * tests/test-linkedhash_list.c: Likewise.
129782         * tests/test-locale.c: Likewise.
129783         * tests/test-localename.c: Likewise.
129784         * tests/test-lock.c: Likewise.
129785         * tests/test-lseek.c: Likewise.
129786         * tests/test-malloca.c: Likewise.
129787         * tests/test-math.c: Likewise.
129788         * tests/test-mbscasecmp.c: Likewise.
129789         * tests/test-mbscasestr1.c: Likewise.
129790         * tests/test-mbscasestr2.c: Likewise.
129791         * tests/test-mbscasestr3.c: Likewise.
129792         * tests/test-mbscasestr4.c: Likewise.
129793         * tests/test-mbschr.c: Likewise.
129794         * tests/test-mbscspn.c: Likewise.
129795         * tests/test-mbsncasecmp.c: Likewise.
129796         * tests/test-mbspbrk.c: Likewise.
129797         * tests/test-mbspcasecmp.c: Likewise.
129798         * tests/test-mbsrchr.c: Likewise.
129799         * tests/test-mbsspn.c: Likewise.
129800         * tests/test-mbsstr1.c: Likewise.
129801         * tests/test-mbsstr2.c: Likewise.
129802         * tests/test-mbsstr3.c: Likewise.
129803         * tests/test-md5.c: Likewise.
129804         * tests/test-memmem.c: Likewise.
129805         * tests/test-netinet_in.c: Likewise.
129806         * tests/test-open.c: Likewise.
129807         * tests/test-printf-frexp.c: Likewise.
129808         * tests/test-printf-frexpl.c: Likewise.
129809         * tests/test-printf-posix.c: Likewise.
129810         * tests/test-printf-posix.h: Likewise.
129811         * tests/test-rbtree_list.c: Likewise.
129812         * tests/test-rbtree_oset.c: Likewise.
129813         * tests/test-rbtreehash_list.c: Likewise.
129814         * tests/test-read-file.c: Likewise.
129815         * tests/test-rijndael.c: Likewise.
129816         * tests/test-search.c: Likewise.
129817         * tests/test-signbit.c: Likewise.
129818         * tests/test-sleep.c: Likewise.
129819         * tests/test-snprintf-posix.c: Likewise.
129820         * tests/test-snprintf-posix.h: Likewise.
129821         * tests/test-snprintf.c: Likewise.
129822         * tests/test-sprintf-posix.c: Likewise.
129823         * tests/test-sprintf-posix.h: Likewise.
129824         * tests/test-stat-time.c: Likewise.
129825         * tests/test-stdbool.c: Likewise.
129826         * tests/test-stdint.c: Likewise.
129827         * tests/test-stdio.c: Likewise.
129828         * tests/test-stdlib.c: Likewise.
129829         * tests/test-stpncpy.c: Likewise.
129830         * tests/test-strcasestr.c: Likewise.
129831         * tests/test-striconv.c: Likewise.
129832         * tests/test-striconveh.c: Likewise.
129833         * tests/test-striconveha.c: Likewise.
129834         * tests/test-string.c: Likewise.
129835         * tests/test-sys_select.c: Likewise.
129836         * tests/test-sys_socket.c: Likewise.
129837         * tests/test-sys_stat.c: Likewise.
129838         * tests/test-sys_time.c: Likewise.
129839         * tests/test-sysexits.c: Likewise.
129840         * tests/test-time.c: Likewise.
129841         * tests/test-tls.c: Likewise.
129842         * tests/test-trunc.c: Likewise.
129843         * tests/test-truncf.c: Likewise.
129844         * tests/test-truncl.c: Likewise.
129845         * tests/test-unistd.c: Likewise.
129846         * tests/test-vasnprintf-posix.c: Likewise.
129847         * tests/test-vasnprintf-posix2.c: Likewise.
129848         * tests/test-vasnprintf.c: Likewise.
129849         * tests/test-vasprintf-posix.c: Likewise.
129850         * tests/test-vasprintf.c: Likewise.
129851         * tests/test-verify.c: Likewise.
129852         * tests/test-vfprintf-posix.c: Likewise.
129853         * tests/test-vprintf-posix.c: Likewise.
129854         * tests/test-vsnprintf-posix.c: Likewise.
129855         * tests/test-vsnprintf.c: Likewise.
129856         * tests/test-vsprintf-posix.c: Likewise.
129857         * tests/test-wchar.c: Likewise.
129858         * tests/test-wctype.c: Likewise.
129859         * tests/test-wcwidth.c: Likewise.
129860         * tests/test-xstrtol.c: Likewise.
129861         * tests/test-xvasprintf.c: Likewise.
129862         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
129863         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
129864         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
129865         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
129866         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
129867         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
129868         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
129869         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
129870         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
129871         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
129872         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
129873         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
129874         * tests/uniname/test-uninames.c: Likewise.
129875         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
129876         * tests/unistdio/test-u16-asnprintf1.h: Likewise.
129877         * tests/unistdio/test-u16-printf1.h: Likewise.
129878         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
129879         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
129880         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
129881         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
129882         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
129883         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
129884         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
129885         * tests/unistdio/test-u32-asnprintf1.h: Likewise.
129886         * tests/unistdio/test-u32-printf1.h: Likewise.
129887         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
129888         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
129889         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
129890         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
129891         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
129892         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
129893         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
129894         * tests/unistdio/test-u8-asnprintf1.h: Likewise.
129895         * tests/unistdio/test-u8-printf1.h: Likewise.
129896         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
129897         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
129898         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
129899         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
129900         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
129901         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
129902         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
129903         * tests/unistdio/test-ulc-asnprintf1.h: Likewise.
129904         * tests/unistdio/test-ulc-printf1.h: Likewise.
129905         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
129906         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
129907         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
129908         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
129909         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
129910         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
129911         * tests/uniwidth/test-u16-strwidth.c: Likewise.
129912         * tests/uniwidth/test-u16-width.c: Likewise.
129913         * tests/uniwidth/test-u32-strwidth.c: Likewise.
129914         * tests/uniwidth/test-u32-width.c: Likewise.
129915         * tests/uniwidth/test-u8-strwidth.c: Likewise.
129916         * tests/uniwidth/test-u8-width.c: Likewise.
129917         * tests/uniwidth/test-uc_width.c: Likewise.
129918         * config/srclist-update: Likewise.
129919         (fixlicense): Update to GPLv3+.
129921         Change copyright notice from LGPLv2.1+ to LGPLv3+.
129922         * tests/test-tsearch.c: Change copyright notice.
129924         Change copyright notice from LGPLv2.0+ to LGPLv3+.
129925         * lib/c-strcaseeq.h: Change copyright notice.
129926         * lib/streq.h: Likewise.
129927         * lib/uniconv.h: Likewise.
129928         * lib/uniconv/u-conv-from-enc.h: Likewise.
129929         * lib/uniconv/u-conv-to-enc.h: Likewise.
129930         * lib/uniconv/u-strconv-from-enc.h: Likewise.
129931         * lib/uniconv/u-strconv-to-enc.h: Likewise.
129932         * lib/uniconv/u16-conv-from-enc.c: Likewise.
129933         * lib/uniconv/u16-conv-to-enc.c: Likewise.
129934         * lib/uniconv/u16-strconv-from-enc.c: Likewise.
129935         * lib/uniconv/u16-strconv-from-locale.c: Likewise.
129936         * lib/uniconv/u16-strconv-to-enc.c: Likewise.
129937         * lib/uniconv/u16-strconv-to-locale.c: Likewise.
129938         * lib/uniconv/u32-conv-from-enc.c: Likewise.
129939         * lib/uniconv/u32-conv-to-enc.c: Likewise.
129940         * lib/uniconv/u32-strconv-from-enc.c: Likewise.
129941         * lib/uniconv/u32-strconv-from-locale.c: Likewise.
129942         * lib/uniconv/u32-strconv-to-enc.c: Likewise.
129943         * lib/uniconv/u32-strconv-to-locale.c: Likewise.
129944         * lib/uniconv/u8-conv-from-enc.c: Likewise.
129945         * lib/uniconv/u8-conv-to-enc.c: Likewise.
129946         * lib/uniconv/u8-strconv-from-enc.c: Likewise.
129947         * lib/uniconv/u8-strconv-from-locale.c: Likewise.
129948         * lib/uniconv/u8-strconv-to-enc.c: Likewise.
129949         * lib/uniconv/u8-strconv-to-locale.c: Likewise.
129950         * lib/uniname.h: Likewise.
129951         * lib/uniname/uniname.c: Likewise.
129952         * lib/unistdio.h: Likewise.
129953         * lib/unistdio/u-asnprintf.h: Likewise.
129954         * lib/unistdio/u-asprintf.h: Likewise.
129955         * lib/unistdio/u-printf-args.c: Likewise.
129956         * lib/unistdio/u-printf-args.h: Likewise.
129957         * lib/unistdio/u-printf-parse.h: Likewise.
129958         * lib/unistdio/u-snprintf.h: Likewise.
129959         * lib/unistdio/u-sprintf.h: Likewise.
129960         * lib/unistdio/u-vasprintf.h: Likewise.
129961         * lib/unistdio/u-vsnprintf.h: Likewise.
129962         * lib/unistdio/u-vsprintf.h: Likewise.
129963         * lib/unistdio/u16-asnprintf.c: Likewise.
129964         * lib/unistdio/u16-asprintf.c: Likewise.
129965         * lib/unistdio/u16-printf-parse.c: Likewise.
129966         * lib/unistdio/u16-snprintf.c: Likewise.
129967         * lib/unistdio/u16-sprintf.c: Likewise.
129968         * lib/unistdio/u16-u16-asnprintf.c: Likewise.
129969         * lib/unistdio/u16-u16-asprintf.c: Likewise.
129970         * lib/unistdio/u16-u16-snprintf.c: Likewise.
129971         * lib/unistdio/u16-u16-sprintf.c: Likewise.
129972         * lib/unistdio/u16-u16-vasnprintf.c: Likewise.
129973         * lib/unistdio/u16-u16-vasprintf.c: Likewise.
129974         * lib/unistdio/u16-u16-vsnprintf.c: Likewise.
129975         * lib/unistdio/u16-u16-vsprintf.c: Likewise.
129976         * lib/unistdio/u16-vasnprintf.c: Likewise.
129977         * lib/unistdio/u16-vasprintf.c: Likewise.
129978         * lib/unistdio/u16-vsnprintf.c: Likewise.
129979         * lib/unistdio/u16-vsprintf.c: Likewise.
129980         * lib/unistdio/u32-asnprintf.c: Likewise.
129981         * lib/unistdio/u32-asprintf.c: Likewise.
129982         * lib/unistdio/u32-printf-parse.c: Likewise.
129983         * lib/unistdio/u32-snprintf.c: Likewise.
129984         * lib/unistdio/u32-sprintf.c: Likewise.
129985         * lib/unistdio/u32-u32-asnprintf.c: Likewise.
129986         * lib/unistdio/u32-u32-asprintf.c: Likewise.
129987         * lib/unistdio/u32-u32-snprintf.c: Likewise.
129988         * lib/unistdio/u32-u32-sprintf.c: Likewise.
129989         * lib/unistdio/u32-u32-vasnprintf.c: Likewise.
129990         * lib/unistdio/u32-u32-vasprintf.c: Likewise.
129991         * lib/unistdio/u32-u32-vsnprintf.c: Likewise.
129992         * lib/unistdio/u32-u32-vsprintf.c: Likewise.
129993         * lib/unistdio/u32-vasnprintf.c: Likewise.
129994         * lib/unistdio/u32-vasprintf.c: Likewise.
129995         * lib/unistdio/u32-vsnprintf.c: Likewise.
129996         * lib/unistdio/u32-vsprintf.c: Likewise.
129997         * lib/unistdio/u8-asnprintf.c: Likewise.
129998         * lib/unistdio/u8-asprintf.c: Likewise.
129999         * lib/unistdio/u8-printf-parse.c: Likewise.
130000         * lib/unistdio/u8-snprintf.c: Likewise.
130001         * lib/unistdio/u8-sprintf.c: Likewise.
130002         * lib/unistdio/u8-u8-asnprintf.c: Likewise.
130003         * lib/unistdio/u8-u8-asprintf.c: Likewise.
130004         * lib/unistdio/u8-u8-snprintf.c: Likewise.
130005         * lib/unistdio/u8-u8-sprintf.c: Likewise.
130006         * lib/unistdio/u8-u8-vasnprintf.c: Likewise.
130007         * lib/unistdio/u8-u8-vasprintf.c: Likewise.
130008         * lib/unistdio/u8-u8-vsnprintf.c: Likewise.
130009         * lib/unistdio/u8-u8-vsprintf.c: Likewise.
130010         * lib/unistdio/u8-vasnprintf.c: Likewise.
130011         * lib/unistdio/u8-vasprintf.c: Likewise.
130012         * lib/unistdio/u8-vsnprintf.c: Likewise.
130013         * lib/unistdio/u8-vsprintf.c: Likewise.
130014         * lib/unistdio/ulc-asnprintf.c: Likewise.
130015         * lib/unistdio/ulc-asprintf.c: Likewise.
130016         * lib/unistdio/ulc-printf-parse.c: Likewise.
130017         * lib/unistdio/ulc-snprintf.c: Likewise.
130018         * lib/unistdio/ulc-sprintf.c: Likewise.
130019         * lib/unistdio/ulc-vasnprintf.c: Likewise.
130020         * lib/unistdio/ulc-vasprintf.c: Likewise.
130021         * lib/unistdio/ulc-vsnprintf.c: Likewise.
130022         * lib/unistdio/ulc-vsprintf.c: Likewise.
130023         * lib/unistr.h: Likewise.
130024         * lib/unistr/u-cpy-alloc.h: Likewise.
130025         * lib/unistr/u-cpy.h: Likewise.
130026         * lib/unistr/u-endswith.h: Likewise.
130027         * lib/unistr/u-move.h: Likewise.
130028         * lib/unistr/u-set.h: Likewise.
130029         * lib/unistr/u-startswith.h: Likewise.
130030         * lib/unistr/u-stpcpy.h: Likewise.
130031         * lib/unistr/u-stpncpy.h: Likewise.
130032         * lib/unistr/u-strcat.h: Likewise.
130033         * lib/unistr/u-strcpy.h: Likewise.
130034         * lib/unistr/u-strcspn.h: Likewise.
130035         * lib/unistr/u-strdup.h: Likewise.
130036         * lib/unistr/u-strlen.h: Likewise.
130037         * lib/unistr/u-strncat.h: Likewise.
130038         * lib/unistr/u-strncpy.h: Likewise.
130039         * lib/unistr/u-strnlen.h: Likewise.
130040         * lib/unistr/u-strpbrk.h: Likewise.
130041         * lib/unistr/u-strspn.h: Likewise.
130042         * lib/unistr/u-strstr.h: Likewise.
130043         * lib/unistr/u-strtok.h: Likewise.
130044         * lib/unistr/u16-check.c: Likewise.
130045         * lib/unistr/u16-chr.c: Likewise.
130046         * lib/unistr/u16-cmp.c: Likewise.
130047         * lib/unistr/u16-cpy-alloc.c: Likewise.
130048         * lib/unistr/u16-cpy.c: Likewise.
130049         * lib/unistr/u16-endswith.c: Likewise.
130050         * lib/unistr/u16-mblen.c: Likewise.
130051         * lib/unistr/u16-mbsnlen.c: Likewise.
130052         * lib/unistr/u16-mbtouc-aux.c: Likewise.
130053         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
130054         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
130055         * lib/unistr/u16-mbtouc.c: Likewise.
130056         * lib/unistr/u16-mbtoucr.c: Likewise.
130057         * lib/unistr/u16-move.c: Likewise.
130058         * lib/unistr/u16-next.c: Likewise.
130059         * lib/unistr/u16-prev.c: Likewise.
130060         * lib/unistr/u16-set.c: Likewise.
130061         * lib/unistr/u16-startswith.c: Likewise.
130062         * lib/unistr/u16-stpcpy.c: Likewise.
130063         * lib/unistr/u16-stpncpy.c: Likewise.
130064         * lib/unistr/u16-strcat.c: Likewise.
130065         * lib/unistr/u16-strchr.c: Likewise.
130066         * lib/unistr/u16-strcmp.c: Likewise.
130067         * lib/unistr/u16-strcpy.c: Likewise.
130068         * lib/unistr/u16-strcspn.c: Likewise.
130069         * lib/unistr/u16-strdup.c: Likewise.
130070         * lib/unistr/u16-strlen.c: Likewise.
130071         * lib/unistr/u16-strmblen.c: Likewise.
130072         * lib/unistr/u16-strmbtouc.c: Likewise.
130073         * lib/unistr/u16-strncat.c: Likewise.
130074         * lib/unistr/u16-strncmp.c: Likewise.
130075         * lib/unistr/u16-strncpy.c: Likewise.
130076         * lib/unistr/u16-strnlen.c: Likewise.
130077         * lib/unistr/u16-strpbrk.c: Likewise.
130078         * lib/unistr/u16-strrchr.c: Likewise.
130079         * lib/unistr/u16-strspn.c: Likewise.
130080         * lib/unistr/u16-strstr.c: Likewise.
130081         * lib/unistr/u16-strtok.c: Likewise.
130082         * lib/unistr/u16-to-u32.c: Likewise.
130083         * lib/unistr/u16-to-u8.c: Likewise.
130084         * lib/unistr/u16-uctomb-aux.c: Likewise.
130085         * lib/unistr/u16-uctomb.c: Likewise.
130086         * lib/unistr/u32-check.c: Likewise.
130087         * lib/unistr/u32-chr.c: Likewise.
130088         * lib/unistr/u32-cmp.c: Likewise.
130089         * lib/unistr/u32-cpy-alloc.c: Likewise.
130090         * lib/unistr/u32-cpy.c: Likewise.
130091         * lib/unistr/u32-endswith.c: Likewise.
130092         * lib/unistr/u32-mblen.c: Likewise.
130093         * lib/unistr/u32-mbsnlen.c: Likewise.
130094         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
130095         * lib/unistr/u32-mbtouc.c: Likewise.
130096         * lib/unistr/u32-mbtoucr.c: Likewise.
130097         * lib/unistr/u32-move.c: Likewise.
130098         * lib/unistr/u32-next.c: Likewise.
130099         * lib/unistr/u32-prev.c: Likewise.
130100         * lib/unistr/u32-set.c: Likewise.
130101         * lib/unistr/u32-startswith.c: Likewise.
130102         * lib/unistr/u32-stpcpy.c: Likewise.
130103         * lib/unistr/u32-stpncpy.c: Likewise.
130104         * lib/unistr/u32-strcat.c: Likewise.
130105         * lib/unistr/u32-strchr.c: Likewise.
130106         * lib/unistr/u32-strcmp.c: Likewise.
130107         * lib/unistr/u32-strcpy.c: Likewise.
130108         * lib/unistr/u32-strcspn.c: Likewise.
130109         * lib/unistr/u32-strdup.c: Likewise.
130110         * lib/unistr/u32-strlen.c: Likewise.
130111         * lib/unistr/u32-strmblen.c: Likewise.
130112         * lib/unistr/u32-strmbtouc.c: Likewise.
130113         * lib/unistr/u32-strncat.c: Likewise.
130114         * lib/unistr/u32-strncmp.c: Likewise.
130115         * lib/unistr/u32-strncpy.c: Likewise.
130116         * lib/unistr/u32-strnlen.c: Likewise.
130117         * lib/unistr/u32-strpbrk.c: Likewise.
130118         * lib/unistr/u32-strrchr.c: Likewise.
130119         * lib/unistr/u32-strspn.c: Likewise.
130120         * lib/unistr/u32-strstr.c: Likewise.
130121         * lib/unistr/u32-strtok.c: Likewise.
130122         * lib/unistr/u32-to-u16.c: Likewise.
130123         * lib/unistr/u32-to-u8.c: Likewise.
130124         * lib/unistr/u32-uctomb.c: Likewise.
130125         * lib/unistr/u8-check.c: Likewise.
130126         * lib/unistr/u8-chr.c: Likewise.
130127         * lib/unistr/u8-cmp.c: Likewise.
130128         * lib/unistr/u8-cpy-alloc.c: Likewise.
130129         * lib/unistr/u8-cpy.c: Likewise.
130130         * lib/unistr/u8-endswith.c: Likewise.
130131         * lib/unistr/u8-mblen.c: Likewise.
130132         * lib/unistr/u8-mbsnlen.c: Likewise.
130133         * lib/unistr/u8-mbtouc-aux.c: Likewise.
130134         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
130135         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
130136         * lib/unistr/u8-mbtouc.c: Likewise.
130137         * lib/unistr/u8-mbtoucr.c: Likewise.
130138         * lib/unistr/u8-move.c: Likewise.
130139         * lib/unistr/u8-next.c: Likewise.
130140         * lib/unistr/u8-prev.c: Likewise.
130141         * lib/unistr/u8-set.c: Likewise.
130142         * lib/unistr/u8-startswith.c: Likewise.
130143         * lib/unistr/u8-stpcpy.c: Likewise.
130144         * lib/unistr/u8-stpncpy.c: Likewise.
130145         * lib/unistr/u8-strcat.c: Likewise.
130146         * lib/unistr/u8-strchr.c: Likewise.
130147         * lib/unistr/u8-strcmp.c: Likewise.
130148         * lib/unistr/u8-strcpy.c: Likewise.
130149         * lib/unistr/u8-strcspn.c: Likewise.
130150         * lib/unistr/u8-strdup.c: Likewise.
130151         * lib/unistr/u8-strlen.c: Likewise.
130152         * lib/unistr/u8-strmblen.c: Likewise.
130153         * lib/unistr/u8-strmbtouc.c: Likewise.
130154         * lib/unistr/u8-strncat.c: Likewise.
130155         * lib/unistr/u8-strncmp.c: Likewise.
130156         * lib/unistr/u8-strncpy.c: Likewise.
130157         * lib/unistr/u8-strnlen.c: Likewise.
130158         * lib/unistr/u8-strpbrk.c: Likewise.
130159         * lib/unistr/u8-strrchr.c: Likewise.
130160         * lib/unistr/u8-strspn.c: Likewise.
130161         * lib/unistr/u8-strstr.c: Likewise.
130162         * lib/unistr/u8-strtok.c: Likewise.
130163         * lib/unistr/u8-to-u16.c: Likewise.
130164         * lib/unistr/u8-to-u32.c: Likewise.
130165         * lib/unistr/u8-uctomb-aux.c: Likewise.
130166         * lib/unistr/u8-uctomb.c: Likewise.
130167         * lib/unitypes.h: Likewise.
130168         * lib/uniwidth.h: Likewise.
130169         * lib/uniwidth/cjk.h: Likewise.
130170         * lib/uniwidth/u16-strwidth.c: Likewise.
130171         * lib/uniwidth/u16-width.c: Likewise.
130172         * lib/uniwidth/u32-strwidth.c: Likewise.
130173         * lib/uniwidth/u32-width.c: Likewise.
130174         * lib/uniwidth/u8-strwidth.c: Likewise.
130175         * lib/uniwidth/u8-width.c: Likewise.
130176         * lib/uniwidth/width.c: Likewise.
130178 2007-10-07  Bruno Haible  <bruno@clisp.org>
130180         * lib/inttypes.in.h: Change copyright notice from LGPL to GPL.
130181         The file is still under LGPL (see modules/inttypes).
130183 2007-10-06  Bruno Haible  <bruno@clisp.org>
130185         * modules/trunc (Dependencies): Add 'extensions'.
130186         * m4/trunc.m4 (gl_FUNC_TRUNC): Require gl_USE_SYSTEM_EXTENSIONS.
130187         Reported by Ben Pfaff <blp@gnu.org>.
130189 2007-10-06  Bruno Haible  <bruno@clisp.org>
130191         * modules/freopen-tests: New file.
130192         * tests/test-freopen.c: New file.
130194         * modules/fopen-tests: New file.
130195         * tests/test-fopen.c: New file.
130197         * modules/fopen: New file.
130198         * lib/fopen.c: New file.
130199         * m4/fopen.m4: New file.
130200         * modules/freopen: New file.
130201         * lib/freopen.c: New file.
130202         * m4/freopen.m4: New file.
130203         * lib/stdio.in.h (fopen, freopen): New declarations.
130204         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize also GNULIB_FOPEN,
130205         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
130206         * modules/stdio (Makefile.am): Substitute also GNULIB_FOPEN,
130207         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
130208         * doc/functions/fopen.texi: Mention the 'fopen' module.
130209         * doc/functions/freopen.texi: Mention the 'freopen' module.
130211 2007-10-06  Bruno Haible  <bruno@clisp.org>
130213         * modules/open-tests: New file.
130214         * tests/test-open.c: New file.
130216         * modules/open: New file.
130217         * lib/open.c: New file.
130218         * m4/open.m4: New file.
130219         * lib/fchdir.c (open): If the gnulib module 'open' is used, do what
130220         lib/open.c does.
130221         * lib/fcntl.in.h (open): Declare also if replaced by the 'open' module.
130222         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR, gl_FCNTL_H_DEFAULTS): New
130223         macros.
130224         (gl_FCNTL_H): Require gl_FCNTL_H_DEFAULTS.
130225         * modules/fcntl (Makefile.am): Also substitute GNULIB_OPEN and
130226         REPLACE_OPEN.
130227         * doc/functions/open.texi: Mention the 'open' module.
130229 2007-10-04  Bruno Haible  <bruno@clisp.org>
130231         * modules/ceill-tests: New file.
130232         * tests/test-ceill.c: New file.
130234         * modules/ceill: New file.
130235         * lib/ceill.c: Replace entire file.
130236         * m4/ceill.m4: New file.
130237         * lib/math.in.h (ceill): Replace declaration.
130238         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILL.
130239         * modules/math (Makefile.am): Substitute also GNULIB_CEILL.
130240         * doc/functions/ceill.texi: Mention the 'ceill' module.
130241         * modules/mathl (Files): Remove lib/ceill.c.
130242         (Depends-on): Add ceill.
130244 2007-10-04  Bruno Haible  <bruno@clisp.org>
130246         * modules/ceilf-tests: New file.
130247         * tests/test-ceilf.c: New file.
130249         * modules/ceilf: New file.
130250         * lib/ceil.c: New file.
130251         * lib/ceilf.c: New file.
130252         * m4/ceilf.m4: New file.
130253         * lib/math.in.h (ceilf): New declaration.
130254         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILF and
130255         HAVE_DECL_CEILF.
130256         * modules/math (Makefile.am): Substitute also GNULIB_CEILF and
130257         HAVE_DECL_CEILF.
130258         * doc/functions/ceilf.texi: Mention the 'ceilf' module.
130260 2007-10-04  Bruno Haible  <bruno@clisp.org>
130262         * modules/floorl-tests: New file.
130263         * tests/test-floorl.c: New file.
130265         * modules/floorl: New file.
130266         * lib/floorl.c: Replace entire file.
130267         * m4/floorl.m4: New file.
130268         * lib/math.in.h (floorl): Replace declaration.
130269         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORL.
130270         * modules/math (Makefile.am): Substitute also GNULIB_FLOORL.
130271         * doc/functions/floorl.texi: Mention the 'floorl' module.
130272         * modules/mathl (Files): Remove lib/floorl.c.
130273         (Depends-on): Add floorl.
130275 2007-10-04  Bruno Haible  <bruno@clisp.org>
130277         * modules/floorf-tests: New file.
130278         * tests/test-floorf.c: New file.
130280         * modules/floorf: New file.
130281         * lib/floor.c: New file.
130282         * lib/floorf.c: New file.
130283         * m4/floorf.m4: New file.
130284         * lib/math.in.h (floorf): New declaration.
130285         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORF and
130286         HAVE_DECL_FLOORF.
130287         * modules/math (Makefile.am): Substitute also GNULIB_FLOORF and
130288         HAVE_DECL_FLOORF.
130289         * doc/functions/floorf.texi: Mention the 'floorf' module.
130291 2007-10-04  Benoit Sigoure  <tsuna@lrde.epita.fr>
130292             Bruno Haible  <bruno@clisp.org>
130294         Advertise for the Git server instead of the CVS server.
130295         * doc/gnulib-intro.texi (Steady Development): Mention the Git
130296         repository instead of the CVS one.
130297         * doc/gnulib-tool.texi (VCS Issues): Renamed from "CVS Issues". Talk
130298         about all VCS systems generically.
130299         * doc/gnulib.texi (Introduction): Capitalize `Git'.
130301 2007-10-04  Bruno Haible  <bruno@clisp.org>
130303         * doc/gnulib.texi (Function Substitutes): Explain what an absent module
130304         means.
130305         Reported by Benoît Sigoure <tsuna@lrde.epita.fr>.
130307 2007-10-04  Bruno Haible  <bruno@clisp.org>
130309         * modules/truncl-tests: New file.
130310         * tests/test-truncl.c: New file.
130312         * modules/truncl: New file.
130313         * lib/truncl.c: New file.
130314         * m4/truncl.m4: New file.
130315         * lib/math.in.h (truncl): New declaration.
130316         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCL and
130317         HAVE_DECL_TRUNCL.
130318         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCL and
130319         HAVE_DECL_TRUNCL.
130320         * doc/functions/truncl.texi: Mention the 'truncl' module.
130322 2007-10-04  Bruno Haible  <bruno@clisp.org>
130324         * modules/truncf-tests: New file.
130325         * tests/test-truncf.c: New file.
130327         * modules/truncf: New file.
130328         * lib/trunc.c: Make paramerizable through USE_* macros.
130329         * lib/truncf.c: New file.
130330         * m4/truncf.m4: New file.
130331         * lib/math.in.h (truncf): New declaration.
130332         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCF and
130333         HAVE_DECL_TRUNCF.
130334         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCF and
130335         HAVE_DECL_TRUNCF.
130336         * doc/functions/truncf.texi: Mention the 'truncf' module.
130338 2007-10-03  Bruno Haible  <bruno@clisp.org>
130340         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
130341         augmentation also for tests modules.
130342         * modules/argp-tests (Makefile.am): Remove EXTRA_DIST augmentation.
130343         * modules/atexit-tests (Makefile.am): Likewise.
130344         * modules/binary-io-tests (Makefile.am): Likewise.
130345         * modules/c-strcase-tests (Makefile.am): Likewise.
130346         * modules/canonicalize-lgpl-tests (Makefile.am): Likewise.
130347         * modules/canonicalize-tests (Makefile.am): Likewise.
130348         * modules/closein-tests (Makefile.am): Likewise.
130349         * modules/fprintf-posix-tests (Makefile.am): Likewise.
130350         * modules/freadahead-tests (Makefile.am): Likewise.
130351         * modules/fseek-tests (Makefile.am): Likewise.
130352         * modules/fseeko-tests (Makefile.am): Likewise.
130353         * modules/ftell-tests (Makefile.am): Likewise.
130354         * modules/ftello-tests (Makefile.am): Likewise.
130355         * modules/isnanl-nolibm-tests (Makefile.am): Likewise.
130356         * modules/isnanl-tests (Makefile.am): Likewise.
130357         * modules/lseek-tests (Makefile.am): Likewise.
130358         * modules/mbscasecmp-tests (Makefile.am): Likewise.
130359         * modules/mbscasestr-tests (Makefile.am): Likewise.
130360         * modules/mbschr-tests (Makefile.am): Likewise.
130361         * modules/mbscspn-tests (Makefile.am): Likewise.
130362         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
130363         * modules/mbspbrk-tests (Makefile.am): Likewise.
130364         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
130365         * modules/mbsrchr-tests (Makefile.am): Likewise.
130366         * modules/mbsspn-tests (Makefile.am): Likewise.
130367         * modules/mbsstr-tests (Makefile.am): Likewise.
130368         * modules/printf-posix-tests (Makefile.am): Likewise.
130369         * modules/snprintf-posix-tests (Makefile.am): Likewise.
130370         * modules/sprintf-posix-tests (Makefile.am): Likewise.
130371         * modules/tsearch-tests (Makefile.am): Likewise.
130372         * modules/uniname/uniname-tests (Makefile.am): Likewise.
130373         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
130374         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
130375         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
130376         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
130377         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
130378         * modules/vfprintf-posix-tests (Makefile.am): Likewise.
130379         * modules/vprintf-posix-tests (Makefile.am): Likewise.
130380         * modules/vsnprintf-posix-tests (Makefile.am): Likewise.
130381         * modules/vsprintf-posix-tests (Makefile.am): Likewise.
130382         * modules/xstrtoimax-tests (Makefile.am): Likewise.
130383         * modules/xstrtol-tests (Makefile.am): Likewise.
130384         * modules/xstrtoumax-tests (Makefile.am): Likewise.
130385         * modules/yesno-tests (Makefile.am): Likewise.
130387 2007-10-03  Bruno Haible  <bruno@clisp.org>
130389         * modules/trunc-tests: New file.
130390         * tests/test-trunc.c: New file.
130392         * modules/trunc: New file.
130393         * lib/trunc.c: New file.
130394         * m4/trunc.m4: New file.
130395         * lib/math.in.h (trunc): New declaration.
130396         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNC and
130397         HAVE_DECL_TRUNC.
130398         * modules/math (Makefile.am): Substitute also GNULIB_TRUNC and
130399         HAVE_DECL_TRUNC.
130400         * doc/functions/trunc.texi: Mention the 'trunc' module.
130402 2007-10-03  Bruno Haible  <bruno@clisp.org>
130404         * tests/test-fpending.c: New file, mostly copied
130405         from coreutils/lib/t-fpending.c.
130406         * modules/fpending-tests: New file.
130408 2007-10-03  Bruno Haible  <bruno@clisp.org>
130410         Port the stdio extensions to QNX (untested).
130411         * lib/fseterr.c (fseterr): Add support for QNX.
130412         * lib/fbufmode.c (fbufmode): Likewise.
130413         * lib/freadable.c (freadable): Likewise.
130414         * lib/fwritable.c (fwritable): Likewise.
130415         * lib/freading.c (freading): Likewise.
130416         * lib/fwriting.c (fwriting): Likewise.
130417         * lib/freadahead.c (freadahed): Likewise.
130418         * lib/fpurge.c (fpurge): Likewise.
130419         * lib/fseeko.c (rpl_fseeko): Likewise.
130421 2007-10-03  Bruno Haible  <bruno@clisp.org>
130422             Jim Meyering  <jim@meyering.net>
130423             Eric Blake  <ebb9@byu.net>
130425         * doc/relocatable.texi: Use @command instead of @program.
130427 2007-10-02  Jim Meyering  <jim@meyering.net>
130429         Perform one more "_.h" -> ".in.h" substitution.
130430         * modules/unistd (Makefile.am) [unistd.h]: Use unistd.h.in
130431         instead of unistd_.h here, too.
130433 2007-10-01  Bruno Haible  <bruno@clisp.org>
130435         * gnulib-tool (func_emit_initmacro_done): Special case for alloca.c.
130436         Needed for the alloca-opt module.
130438 2007-09-30  Bruno Haible  <bruno@clisp.org>
130440         * lib/alloca.in.h: Renamed from lib/alloca_.h.
130441         * modules/alloca-opt (Files, Makefile.am): Use alloca.in.h instead of
130442         alloca_.h.
130443         * lib/argz.in.h: Renamed from lib/argz_.h.
130444         * modules/argz (Files, Makefile.am): Use argz.in.h instead of argz_.h.
130445         * lib/byteswap.in.h: Renamed from lib/byteswap_.h.
130446         * modules/byteswap (Files, Makefile.am): Use byteswap.in.h instead of
130447         byteswap_.h.
130448         * lib/dirent.in.h: Renamed from lib/dirent_.h.
130449         * modules/fchdir (Files, Makefile.am): Use dirent.in.h instead of
130450         dirent_.h.
130451         * lib/fcntl.in.h: Renamed from lib/fcntl_.h.
130452         * modules/fcntl (Files, Makefile.am): Use fcntl.in.h instead of
130453         fcntl_.h.
130454         * lib/float.in.h: Renamed from lib/float_.h.
130455         * modules/float (Files, Makefile.am): Use float.in.h instead of
130456         float_.h.
130457         * lib/fnmatch.in.h: Renamed from lib/fnmatch_.h.
130458         * modules/fnmatch (Files, Makefile.am): Use fnmatch.in.h instead of
130459         fnmatch_.h.
130460         * lib/getopt.in.h: Renamed from lib/getopt_.h.
130461         * modules/getopt (Files, Makefile.am): Use getopt.in.h instead of
130462         getopt_.h.
130463         * lib/glob.in.h: Renamed from lib/glob_.h.
130464         * modules/glob (Files, Makefile.am): Use glob.in.h instead of glob_.h.
130465         * lib/iconv.in.h: Renamed from lib/iconv_.h.
130466         * modules/iconv_open (Files, Makefile.am): Use iconv.in.h instead of
130467         iconv_.h.
130468         * lib/inttypes.in.h: Renamed from lib/inttypes_.h.
130469         * modules/inttypes (Files, Makefile.am): Use inttypes.in.h instead of
130470         inttypes_.h.
130471         * lib/locale.in.h: Renamed from lib/locale_.h.
130472         * modules/locale (Files, Makefile.am): Use locale.in.h instead of
130473         locale_.h.
130474         * lib/math.in.h: Renamed from lib/math_.h.
130475         * modules/math (Files, Makefile.am): Use math.in.h instead of math_.h.
130476         * lib/netinet_in.in.h: Renamed from lib/netinet_in_.h.
130477         * modules/netinet_in (Files, Makefile.am): Use netinet_in.in.h instead
130478         of netinet_in_.h. Add dependency.
130479         * lib/poll.in.h: Renamed from lib/poll_.h.
130480         * modules/poll (Files, Makefile.am): Use poll.in.h instead of poll_.h.
130481         * lib/search.in.h: Renamed from lib/search_.h.
130482         * modules/search (Files, Makefile.am): Use search.in.h instead of
130483         search_.h.
130484         * lib/signal.in.h: Renamed from lib/signal_.h.
130485         * modules/signal (Files, Makefile.am): Use signal.in.h instead of
130486         _signal.h.
130487         * lib/stdbool.in.h: Renamed from lib/stdbool_.h.
130488         * modules/stdbool (Files, Makefile.am): Use stdbool.in.h instead of
130489         stdbool_.h.
130490         * lib/stdint.in.h: Renamed from lib/stdint_.h.
130491         * modules/stdint (Files, Makefile.am): Use stdint.in.h instead of
130492         stdint_.h.
130493         * lib/stdio.in.h: Renamed from lib/stdio_.h.
130494         * modules/stdio (Files, Makefile.am): Use stdio.in.h instead of
130495         stdio_.h.
130496         * lib/stdlib.in.h: Renamed from lib/stdlib_.h.
130497         * modules/stdlib (Files, Makefile.am): Use stdlib.in.h instead of
130498         stdlib_.h.
130499         * lib/string.in.h: Renamed from lib/string_.h.
130500         * modules/string (Files, Makefile.am): Use string.in.h instead of
130501         string_.h.
130502         * doc/gnulib-tool.texi (Initial import): Update.
130503         * lib/sys_select.in.h: Renamed from lib/sys_select_.h.
130504         * modules/sys_select (Files, Makefile.am): Use sys_select.in.h instead
130505         of sys_select_.h. Add dependency.
130506         * lib/sys_socket.in.h: Renamed from lib/sys_socket_.h.
130507         * modules/sys_socket (Files, Makefile.am): Use sys_socket.in.h instead
130508         of sys_socket_.h.
130509         * lib/sys_stat.in.h: Renamed from lib/sys_stat_.h.
130510         * modules/sys_stat (Files, Makefile.am): Use sys_stat.in.h instead of
130511         sys_stat_.h.
130512         * lib/sys_time.in.h: Renamed from lib/sys_time_.h.
130513         * modules/sys_time (Files, Makefile.am): Use sys_time.in.h instead of
130514         sys_time_.h.
130515         * lib/sysexits.in.h: Renamed from lib/sysexits_.h.
130516         * modules/sysexits (Files, Makefile.am): Use sysexits.in.h instead of
130517         sysexits_.h.
130518         * lib/time.in.h: Renamed from lib/time_.h.
130519         * modules/time (Files, Makefile.am): Use time.in.h instead of time_.h.
130520         * lib/unistd.in.h: Renamed from lib/unistd_.h.
130521         * modules/unistd (Files, Makefile.am): Use unistd.in.h instead of
130522         unistd_.h.
130523         * lib/wchar.in.h: Renamed from lib/wchar_.h.
130524         * modules/wchar (Files, Makefile.am): Use wchar.in.h instead of
130525         wchar_.h.
130526         * lib/wctype.in.h: Renamed from lib/wctype_.h.
130527         * modules/wctype (Files, Makefile.am): Use wctype.in.h instead of
130528         wctype_.h.
130529         * build-aux/bootstrap (slurp): Update.
130530         * lib/.cppi-disable: Update.
130532 2007-09-30  Bruno Haible  <bruno@clisp.org>
130534         * tests/test-getaddrinfo.c (AF_UNSPEC): Provide a fallback definition.
130535         Needed on BeOS.
130537 2007-09-30  Bruno Haible  <bruno@clisp.org>
130539         * modules/dirname-tests (check_PROGRAMS): Renamed from noinst_PROGRAMS.
130541 2007-09-29  Bruno Haible  <bruno@clisp.org>
130543         * lib/stdio_.h (getdelim, getline): Add identifiers. Doc tweak.
130545 2007-09-29  Bruno Haible  <bruno@clisp.org>
130547         * lib/xreadlink.c (xreadlink): Simplify to a wrapper around areadlink.
130548         * modules/xreadlink (Depends-on): Add areadlink, remove readlink etc.
130549         * build-aux/install-reloc: Compile also areadlink.c.
130550         * modules/relocatable-prog-wrapper (Files): Add lib/areadlink.[hc].
130552 2007-09-29  Bruno Haible  <bruno@clisp.org>
130554         * gnulib-tool (func_emit_initmacro_done): Indentation.
130556 2007-09-29  Bruno Haible  <bruno@clisp.org>
130558         * README: Add CVS checkout update instructions.
130559         Info from Bob Proulx <bob@proulx.com>.
130561 2007-09-28  Eric Blake  <ebb9@byu.net>
130563         Provide move-if-change.
130564         * build-aux/move-if-change: New file, based on best practice
130565         rather than any canonical upstream location.
130567 2007-09-28  Jim Meyering  <jim@meyering.net>
130569         Fix canonicalize loop-detection corner case.
130570         Do not attempt to stat the symlink values stored via seen_triple.
130571         Without this, coreutils' tests/misc/readlink-fp-loop test would fail
130572         on linux-2.6.18, (but not 2.6.22).
130573         * lib/canonicalize.c (seen_triple): Use triple_compare_ino_str, not
130574         triple_compare.  The former compares dev,ino,filename, while the latter
130575         would actually stat dirname(filename) when dev and ino were equal.
130576         * lib/hash-triple.c: Install <string.h>.
130577         (STREQ): Define.
130578         (triple_compare_ino_str): New function.
130579         * lib/hash-triple.h (triple_compare_ino_str): Declare it.
130581 2007-09-28  Eric Blake  <ebb9@byu.net>
130583         Enforce that AC_REPLACE_FUNCS files exist.
130584         * gnulib-tool (func_emit_initmacro_done): Make AC_LIBSOURCES
130585         override check for typos.
130587         Fix test-closein on Solaris 10.
130588         * tests/test-closein.c (main): Don't assume stdin can be inherited
130589         closed on all systems.
130590         * tests/test-closein.sh: Likewise.
130591         Reported by Piotr Tarnowski.
130593 2007-09-28  Jim Meyering  <jim@meyering.net>
130595         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Fix typo in comment.
130597 2007-09-27  Jim Meyering  <jim@meyering.net>
130599         canonicalize: Avoid a false-positive cycle failure.
130600         * modules/canonicalize (Depends-on): Add file-set and hash-triple.
130601         Sort.  Remove cycle-check.
130602         * lib/canonicalize.c: Include file-set.h and hash-triple.h,
130603         not cycle-check.h.
130604         (seen_triple): New function.
130605         (canonicalize_filename_mode): Use it instead of cycle-check.
130606         * tests/test-canonicalize.c: Add a test for this bug.
130607         * tests/test-canonicalize.sh: Set up and run the test.
130609         New module, file-set, from coreutils.
130610         * modules/file-set: Define it.
130611         * lib/file-set.c, lib/file-set.h: Implement.
130613         New module, hash-triple, from coreutils.
130614         * modules/hash-triple: Define it.
130615         * lib/hash-triple.c, lib/hash-triple.h: Implement.
130617 2007-09-25  Eric Blake  <ebb9@byu.net>
130619         Fix strerror on Interix.
130620         * lib/string_.h (strerror): Declare replacement.
130621         * doc/functions/strerror.texi (strerror): Document the Interix
130622         shortcoming.
130623         * modules/string (Makefile.am): Support new hooks.
130624         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Add new hooks.
130625         * m4/strerror.m4 (gl_FUNC_STRERROR): Defer to
130626         gl_FUNC_STRERROR_SEPARATE.
130627         (gl_FUNC_STRERROR_SEPARATE): Check for Interix bug.
130628         * lib/strerror.c (rpl_strerror): Provide replacement.
130629         * modules/strerror (Depends-on): Add string.
130630         (configure.ac): Detect use of module.
130631         * tests/test-strerror.c: New file.
130632         * modules/strerror-tests: New test module.
130633         * modules/argp (Depends-on): Add strerror.
130634         * modules/error (Depends-on): Likewise.
130635         Reported by Martin Koeppe.
130637 2007-09-24  Bruno Haible  <bruno@clisp.org>
130639         * README: Update git instructions.
130641 2007-09-24  Eric Blake  <ebb9@byu.net>
130643         Revert fpending breakage from 2007-09-08.
130644         * m4/fpending.m4 (gl_FUNC_FPENDING): Don't require existence of
130645         __fpending.c.
130647 2007-09-24  Jim Meyering  <jim@meyering.net>
130649         filenamecat.c: Add a test.
130650         * lib/filenamecat.c (main) [TEST_FILE_NAME_CONCAT]: Add a test
130651         showing how the function works when DIR is the empty string.
130653 2007-09-21  Simon Josefsson  <simon@josefsson.org>
130655         * tests/test-canonicalize.sh: Turn on executable bit.
130657 2007-09-19  Eric Blake  <ebb9@byu.net>
130659         * README: Update CVS instructions.
130661 2007-09-18  Bruno Haible  <bruno@clisp.org>
130663         * modules/areadlink: New file.
130664         * lib/areadlink.h (areadlink): New declaration.
130665         * lib/areadlink.c: New file, based on lib/xreadlink.c.
130667 2007-09-17  Jim Meyering  <jim@meyering.net>
130669         * lib/savewd.c (ESTALE) [!defined]: Define.
130670         Reported to be required on Interix by Martin Koeppe.
130672 2007-09-17  Bruno Haible  <bruno@clisp.org>
130674         * gnulib-tool (func_version): Use $version.
130676 2007-09-16  Bruno Haible  <bruno@clisp.org>
130678         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE, gl_PRINTF_INFINITE,
130679         gl_PRINTF_INFINITE_LONG_DOUBLE): Increase buf's size from 100 to 10000.
130680         Needed on glibc-2.6.1 with -fstack-protector -D_FORTIFY_SOURCE=2.
130681         Reported by Greg Schafer <gschafer@zip.com.au>.
130683 2007-09-15  Bruno Haible  <bruno@clisp.org>
130685         * gnulib-tool (sed): Try a little harder to make bash understand the
130686         alias.
130687         Reported by Bruce Korb <bruce.korb@gmail.com>.
130689 2007-09-13  Eric Blake  <ebb9@byu.net>
130691         * ChangeLog: Remove conflict markers.
130693 2007-09-13  Simon Josefsson  <simon@josefsson.org>
130695         * lib/gc-gnulib.c (gc_hash_open): Catch NULL calloc return value.
130696         Reported by Bruno Haible <bruno@clisp.org>.
130698 2007-09-12  Bruno Haible  <bruno@clisp.org>
130700         * m4/lock.m4: Don't provide an AC_USE_SYSTEM_EXTENSIONS definition.
130701         (gl_LOCK_EARLY_BODY): Use AC_GNU_SOURCE when AC_USE_SYSTEM_EXTENSIONS
130702         is not defined.
130704 2007-09-12  Eric Blake  <ebb9@byu.net>
130706         Track CVS Autoconf on AC_USE_SYSTEM_EXTENSIONS.
130707         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Update to CVS
130708         Autoconf definition.
130709         * modules/euidaccess (Depends-on): Add extensions, for
130710         AC_USE_SYSTEM_EXTENSIONS with autoconf <= 2.59.
130711         * modules/fnmatch (Depends-on): Likewise.
130712         * modules/getaddrinfo (Depends-on): Likewise.
130713         * modules/getdelim (Depends-on): Likewise.
130714         * modules/getline (Depends-on): Likewise.
130715         * modules/getsubopt (Depends-on): Likewise.
130716         * modules/gettext (Depends-on): Likewise.
130717         * modules/group-member (Depends-on): Likewise.
130718         * modules/mbchar (Depends-on): Likewise.
130719         * modules/memmem (Depends-on): Likewise.
130720         * modules/mempcpy (Depends-on): Likewise.
130721         * modules/memrchr (Depends-on): Likewise.
130722         * modules/pagealign_alloc (Depends-on): Likewise.
130723         * modules/readutmp (Depends-on): Likewise.
130724         * modules/stpcpy (Depends-on): Likewise.
130725         * modules/stpncpy (Depends-on): Likewise.
130726         * modules/strchrnul (Depends-on): Likewise.
130727         * modules/strndup (Depends-on): Likewise.
130728         * modules/strsep (Depends-on): Likewise.
130729         * modules/strverscmp (Depends-on): Likewise.
130730         * modules/vasprintf (Depends-on): Likewise.
130731         * modules/wcwidth (Depends-on): Likewise.
130732         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): AC_GNU_SOURCE will be
130733         obsolete in Autoconf 2.62; use AC_USE_SYSTEM_EXTENSIONS instead.
130734         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_GNU): Likewise.
130735         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDR_INFO): Likewise.
130736         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
130737         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
130738         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Likewise.
130739         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
130740         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Likewise.
130741         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
130742         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
130743         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
130744         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
130745         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
130746         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC): Likewise.
130747         * m4/readutmp.m4 (gl_READUTMP): Likewise.
130748         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
130749         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
130750         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
130751         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
130752         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
130753         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
130754         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
130755         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Likewise.
130756         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): Likewise.
130757         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
130758         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Likewise, but provide fallback,
130759         so that lock.m4 can be used in gettext without extensions module.
130761 2007-09-11  Bruno Haible  <bruno@clisp.org>
130763         * m4/isc-posix.m4: Remove file.
130764         Suggested by Eric Blake.
130766 2007-09-11  Eric Blake  <ebb9@byu.net>
130768         * ChangeLog: Restore lines accidentally truncated 2007-04-06.
130770 2007-09-10  Bruno Haible  <bruno@clisp.org>
130772         * posix-modules: Fix typo in error message.
130773         Reported by Matt <mkraai@beckman.com>.
130775 2007-09-09  Bruno Haible  <bruno@clisp.org>
130777         * doc/functions/getdelim.texi: Update list of platforms lacking the
130778         function.
130779         * doc/functions/getline.texi: Likewise.
130781 2007-09-09  Jim Meyering  <jim@meyering.net>
130783         * lib/hash.c (hash_initialize): Detect calloc failure.
130784         Reported by Bruno Haible.
130786 2007-09-09  Bruno Haible  <bruno@clisp.org>
130788         * lib/canonicalize-lgpl.c (__realpath): Set errno to ENOMEM when
130789         malloc or realloc fails.
130791 2007-09-09  Bruno Haible  <bruno@clisp.org>
130793         * modules/getcwd (Depends-on): Add malloc-posix.
130794         * modules/glob (Depends-on): Likewise.
130795         * modules/putenv (Depends-on): Likewise.
130796         * modules/strdup (Depends-on): Likewise.
130797         * modules/getdelim (Depends-on): Add realloc-posix.
130798         * modules/read-file (Depends-on): Likewise.
130800 2007-09-09  Bruno Haible  <bruno@clisp.org>
130802         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): New macro.
130803         (gl_FUNC_MALLOC_POSIX): Require it.
130804         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
130805         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Likewise.
130806         * modules/realloc (Files): Add m4/malloc.m4.
130807         * modules/calloc (Files): Likewise.
130809 2007-09-09  Bruno Haible  <bruno@clisp.org>
130811         * modules/malloc-posix: New file.
130812         * modules/malloc (Depends-on): Add malloc-posix.
130813         * lib/malloc.c: Include errno.h.
130814         (rpl_malloc): Merge the requirements of a glibc-compatible malloc
130815         and a POSIX-compatible malloc into a single function. Set ENOMEM
130816         when returning NULL.
130817         * m4/malloc.m4: New file.
130818         * doc/functions/malloc.texi: Mention the malloc-posix module.
130819         * lib/stdlib_.h (malloc): New declaration.
130820         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
130821         GNULIB_MALLOC_POSIX and HAVE_MALLOC_POSIX.
130822         * modules/stdlib (stdlib.h): Substitute also GNULIB_MALLOC_POSIX
130823         and HAVE_MALLOC_POSIX.
130825 2007-09-09  Bruno Haible  <bruno@clisp.org>
130827         * modules/realloc-posix: New file.
130828         * modules/realloc (Depends-on): Add realloc-posix.
130829         * lib/realloc.c: Include errno.h.
130830         (rpl_realloc): Merge the requirements of a glibc-compatible realloc
130831         and a POSIX-compatible realloc into a single function. Set ENOMEM
130832         when returning NULL.
130833         * m4/realloc.m4: New file.
130834         * doc/functions/realloc.texi: Mention the realloc-posix module.
130835         * lib/stdlib_.h (realloc): New declaration.
130836         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
130837         GNULIB_REALLOC_POSIX and HAVE_REALLOC_POSIX.
130838         * modules/stdlib (stdlib.h): Substitute also GNULIB_REALLOC_POSIX
130839         and HAVE_REALLOC_POSIX.
130841 2007-09-09  Bruno Haible  <bruno@clisp.org>
130843         * modules/calloc-posix: New file.
130844         * modules/calloc (Depends-on): Add calloc-posix.
130845         * lib/calloc.c: Include errno.h.
130846         (rpl_calloc): Merge the requirements of a glibc-compatible calloc
130847         and a POSIX-compatible calloc into a single function. Set ENOMEM
130848         when returning NULL.
130849         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): New macro.
130850         * doc/functions/calloc.texi: Mention the calloc-posix module.
130851         * lib/stdlib_.h (calloc): New declaration.
130852         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
130853         GNULIB_CALLOC_POSIX and HAVE_CALLOC_POSIX.
130854         * modules/stdlib (stdlib.h): Substitute also GNULIB_CALLOC_POSIX
130855         and HAVE_CALLOC_POSIX.
130857 2007-09-09  Bruno Haible  <bruno@clisp.org>
130859         Allow for modules to show an arbitrary notice.
130860         * modules/TEMPLATE-EXTENDED: Add 'Notice' field.
130861         * gnulib-tool: New option --extract-notice.
130862         (func_usage): Document it.
130863         (sed_extract_prog): Update.
130864         (func_get_notice): New function.
130865         (func_modules_notice): New function.
130866         (func_import, func_create_testdir): Invoke it.
130867         Suggested by Jim Meyering.
130869 2007-09-09  Bruno Haible  <bruno@clisp.org>
130871         * gnulib-tool: New options --verbose, --quiet.
130872         (func_usage): Document them.
130873         (verbose): New variable.
130874         (func_execute_command): New function.
130875         (func_import): Don't show the module list and the file list if
130876         $verbose < 0.
130877         (func_create_testdir): Likewise. Use func_execute_command.
130878         (func_create_megatestdir): Use func_execute_command.
130880 2007-09-08  Bruno Haible  <bruno@clisp.org>
130882         * gnulib-tool (func_import): Prefer rsync over wget when available,
130883         for fetching the PO files.
130885 2007-09-08  Bruno Haible  <bruno@clisp.org>
130887         * posix-modules: New file. Portions copied from gnulib-tool.
130888         * doc/gnulib.texi (POSIX Substitutes Library): New chapter.
130890 2007-09-08  Jim Meyering  <jim@meyering.net>
130892         Rename __fpending.c -> fpending.c and __fpending.h -> fpending.h
130893         * lib/fpending.h: Rename from __fpending.h.
130894         * lib/fpending.c: Rename from __fpending.c.
130895         Include "fpending.h", not "__fpending.h".
130896         * lib/__fpending.h, lib/__fpending.c: Remove files.
130897         * modules/fpending (Files): Reflect new file names.
130898         * lib/close-stream.c: Include "fpending.h", not "__fpending.h".
130900 2007-09-08  Bruno Haible  <bruno@clisp.org>
130902         * m4/inttypes-h.m4: Remove stub file.
130904 2007-09-07  Simon Josefsson  <simon@josefsson.org>
130906         * doc/headers/stdint.texi: Discuss #include_next issue.
130908 2007-09-06  Paul Eggert  <eggert@cs.ucla.edu>
130910         * build-aux/bootstrap: Remove obsolete comment about wget --help.
130912 2007-09-06  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
130914         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Fix misspelling
130915         in variable name.
130917 2007-09-03  Jim Meyering  <jim@meyering.net>
130919         New module: git-version-gen.
130920         * modules/git-version-gen: New file.
130922         Import changes from coreutils for bootstrap script.
130924         * build-aux/bootstrap (WGET_COMMAND): Remove code to set this variable.
130926         bootstrap: uses rsync to download the .po files
130927         * build-aux/bootstrap (po_download_command_format): New global.
130928         (download_po_files): Use rsync.
130929         (update_po_files): Don't remove .po files after download,
130930         so future rsync runs can take advantage of the copies.
130932         * build-aux/bootstrap (gnulib_tool): Make sha1sum check quietly.
130934         Solve the unnecessary-.po-file-regeneration problem once and for all.
130935         * build-aux/bootstrap (download_po_files): New function, renamed from
130936         get_translations.  Now, downloads, but doesn't update LINGUAS.
130937         (update_po_files): New function.
130939         bootstrap: Ignore more.
130940         * build-aux/bootstrap (symlink_to_dir): Add a directory name like
130941         uniwidth to e.g., lib/.gitignore.
130942         (slurp): Handle the sys_stat_.h -> sys mapping, too.
130944         * build-aux/bootstrap: New setting: vc_ignore.
130945         (insert_sorted_if_absent): Create $file if absent.
130946         Adapt to new, possibly empty, list: $vc_ignore.
130948         bootstrap: generate more ignorable names
130949         * build-aux/bootstrap (slurp): When generating ignorable names,
130950         also map .sin to .sed, .gperf to .c, and .y to .c.
130952 2007-09-03  Jim Meyering  <jim@meyering.net>
130954         * build-aux/git-version-gen: New file, from coreutils.  For details, see
130955         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=bfe49f506
130957 2007-09-02  Bruno Haible  <bruno@clisp.org>
130959         Fix mis-recognition of 'mcs' on QNX 6.
130960         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Test whether the "mcs --version"
130961         output contains the string "Mono".
130962         * lib/csharpcomp.c (compile_csharp_using_mono): Likewise.
130963         Reported by <kraai@ftbfs.org> at <https://savannah.gnu.org/bugs/?18337>.
130965 2007-09-01  Bruno Haible  <bruno@clisp.org>
130967         Fix collision between uniwidth/* and linebreak modules.
130968         * lib/linebreak.h (locale_charset, uc_width, u8_width, u16_width,
130969         u32_width): Remove declarations.
130970         * lib/linebreak.c: Include uniwidth.h, uniwidth/cjk.h, streq.h.
130971         (u32_mbtouc_unsafe, streq9, streq8, streq7, streq6, streq5, streq4,
130972         streq3, streq2, streq1, streq0): Remove functions.
130973         (STREQ): Remove macro.
130974         (is_cjk_encoding): Remove function.
130975         (nonspacing_table_data, nonspacing_table_ind): Remove constants.
130976         (uc_width, u8_width, u16_width, u32_width): Remove functions.
130977         * modules/linebreak (Depends-on): Add streq, uniwidth/width.
130978         * NEWS: Document the change.
130980 2007-09-01  Bruno Haible  <bruno@clisp.org>
130982         * lib/streq.h: Add double-inclusion guard.
130984 2007-09-01  Karl Berry  <karl@gnu.org>
130986         * MODULES.html.sh: Rename mreadlink_with_size to areadlink_with_size.
130988 2007-08-28  Jim Meyering  <jim@meyering.net>
130990         Rename mreadlink_with_size to areadlink_with_size.
130991         * NEWS: Document the change.
130992         * lib/mreadlink-with-size.c (mreadlink_with_size): Rename this to...
130993         * lib/areadlink-with-size.c (areadlink_with_size): ...this.
130994         * lib/mreadlink.h: Rename this to...
130995         * lib/areadlink.h: ...this.
130996         * modules/mreadlink-with-size: Rename this to...
130997         * modules/areadlink-with-size: ...this.
130998         * lib/canonicalize.c: Reflect the renaming.
130999         * modules/canonicalize: Likewise.
131001 2007-08-26  Bruno Haible  <bruno@clisp.org>
131003         * gnulib-tool (func_import): When deciding which files to remove,
131004         consider also dangling symbolic links.
131005         Reported by Eric Blake.
131007 2007-08-26  Bruno Haible  <bruno@clisp.org>
131009         * gnulib-tool (func_ln_if_changed): Use "test -h", not "test -L".
131011 2007-08-23  Simon Josefsson  <simon@josefsson.org>
131013         * lib/readline.c: Don't include getline.h, the prototype is now
131014         found in stdio.h.
131016 2007-08-23  Jim Meyering  <jim@meyering.net>
131018         Getdelim touchup.
131019         * lib/getdelim.c (getdelim): Don't bother to save/restore errno
131020         around the funlockfile call, since funlockfile never sets errno.
131021         Don't set errno upon failed realloc.
131023 2007-08-22  Eric Blake  <ebb9@byu.net>
131025         Getline touchups.
131026         * lib/getdelim.c (getdelim): Revert regression that required *n to
131027         be 0 when *lineptr is NULL.  Preserve errno across funlockfile.
131028         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Check for declaration of
131029         getdelim, rather than whether implementation is missing.
131030         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise for getline.
131031         * lib/stdio_.h (getline): Also declare if replacement is
131032         required.
131033         * doc/functions/getdelim.texi: New file.
131034         * doc/functions/getline.texi: Likewise.
131035         * doc/gnulib.texi (Function Substitutes): Add new files.
131036         Reported by Bruno Haible.
131038 2007-08-22  Ludovic Courtès  <ludo@gnu.org>
131040         * users.txt: Add Guile.
131042 2007-08-22  Eric Blake  <ebb9@byu.net>
131044         * tests/test-getdelim.c (main): Use remove, not unlink.
131045         * tests/test-getline.c (main): Likewise.
131047         Move getline and getdelim into stdio.h, per POSIX 200x.
131048         * modules/getline (Files): Remove getline.h.
131049         (Depends-on): Add stdio.
131050         (configure.ac): Add module indicator.
131051         * modules/getdelim (Files): Remove getdelim.h.
131052         (Depends-on): Add stdio.
131053         (configure.ac): Add module indicator.
131054         * modules/stdio (Makefile.am): Work with new indicators.
131055         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
131056         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Work with stdio needs.
131057         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
131058         * lib/getdelim.h: Delete.
131059         * lib/getline.h: Delete.
131060         * lib/stdio_.h (getdelim, getline): Declare.
131061         * modules/getdelim-tests: New module.
131062         * modules/getline-tests: Likewise.
131063         * tests/test-getdelim.c: New file.
131064         * tests/test-getline.c: Likewise.
131065         * NEWS: Document the change.
131066         * lib/getline.c: Update choice of header.
131067         * lib/csharpcomp.c: Likewise.
131068         * lib/getpass.c: Likewise.
131069         * lib/javacomp.c: Likewise.
131070         * lib/javaversion.c: Likewise.
131071         * lib/yesno.c: Likewise.
131072         * lib/getdelim.c: Likewise.
131073         (getdelim): Set errno on failure, and avoid memory leak.
131075 2007-08-19  Bruno Haible  <bruno@clisp.org>
131077         * modules/closein (Depends-on): Add freadahead.
131078         * lib/closein.c: Include freadahead.h.
131079         (close_stdin): Skip the fseeko and fflush calls if freadahead(stdin)
131080         is zero.
131082 2007-08-19  Bruno Haible  <bruno@clisp.org>
131084         * modules/freadahead-tests: New file.
131085         * tests/test-freadahead.sh: New file.
131086         * tests/test-freadahead.c: New file.
131088         * modules/freadahead: New file.
131089         * lib/freadahead.h: New file.
131090         * lib/freadahead.c: New file.
131091         * MODULES.html.sh (File stream based Input/Output): Add freadahead,
131092         fbufmode, fpurge, freadable, fwritable.
131094 2007-08-19  Eric Blake  <ebb9@byu.net>
131096         Test yesno in combination with closein.
131097         * lib/yesno.c (yesno): Document use of stdin.
131098         * modules/yesno-tests (Files): New module.
131099         * tests/test-yesno.c (main): New file.
131100         * tests/test-yesno.sh: Likewise.
131102 2007-08-19  Bruno Haible  <bruno@clisp.org>
131104         * lib/fbufmode.c (fbufmode): Add tentative support for Solaris/AMD64.
131105         * lib/fseeko.c (rpl_fseeko): Likewise.
131106         * lib/fseterr.c (fseterr): Likewise.
131108 2007-08-19  Bruno Haible  <bruno@clisp.org>
131110         * tests/test-lseek.c (main): Disable a test for BeOS.
131111         * doc/functions/lseek.texi: Document the BeOS bug.
131113 2007-08-19  Bruno Haible  <bruno@clisp.org>
131114             Eric Blake  <ebb9@byu.net>
131116         * lib/lseek.c: Include <sys/stat.h>.
131117         (rpl_lseek): Add workaround code also for Unix platforms.
131118         Needed for BeOS.
131119         * m4/lseek.m4 (gl_FUNC_LSEEK): When cross-compiling, fail on BeOS.
131120         * doc/functions/lseek.texi: Document BeOS definiency.
131122 2007-08-18  Bruno Haible  <bruno@clisp.org>
131124         * modules/fstrcmp-tests: New file.
131125         * tests/test-fstrcmp.c: New file.
131127 2007-08-18  Bruno Haible  <bruno@clisp.org>
131129         * modules/fstrcmp: New file, from GNU gettext with modifications.
131130         * lib/fstrcmp.h: New file, from GNU gettext.
131131         * lib/fstrcmp.c: New file, from GNU gettext.
131132         * MODULES.html.sh (String handling): Add fstrcmp.
131134 2007-08-18  Bruno Haible  <bruno@clisp.org>
131136         * lib/diffseq.h (struct context): Change type of 'heuristic' field to
131137         'bool'.
131138         (diag, compareseq): Remove const from the ctxt argument.
131139         (USE_HEURISTIC): Undefine at the end.
131141 2007-08-18  Jim Meyering  <jim@meyering.net>
131143         New file: lib/idcache.h
131144         * NEWS: Mention the addition.
131145         * modules/idcache (Files): Add lib/idcache.h
131146         * lib/idcache.c: Include "idcache.h".
131147         Don't include <sys/types.h>.
131148         Add a FIXME comment.
131149         Move file-scoped "static" declarations to the top.
131150         * lib/idcache.h: New file.  Include <sys/types.h> here, instead.
131152 2007-08-17  Bruno Haible  <bruno@clisp.org>
131153         and Paul Eggert  <eggert@cs.ucla.edu>
131155         * MODULES.html.sh: Add diffseq.
131156         * modules/diffseq: New file.
131157         * lib/diffseq.h: New file, from GNU gettext with a few minor changes,
131158         extracted from GNU gettext's fstrcmp.c and GNU diff's analyze.c.
131160 2007-08-15  Paul Eggert  <eggert@cs.ucla.edu>
131162         Import changes from coreutils for bootstrap script.
131164         2007-07-21  Paul Eggert  <eggert@cs.ucla.edu>
131166         * build-aux/bootstrap (slurp): Work even in environments where
131167         "ls" defaults to "ls -A".  Put in a FIXME, though, since the
131168         current code does not slurp files whose names start with ".", and
131169         this looks like it might be a troublesome area.
131171         2007-07-11  Jim Meyering  <jim@meyering.net>
131173         If there's a GPL vN copyright comment, require that N == 3.
131175         2007-07-08  Jim Meyering  <jim@meyering.net>
131177         Run the coreutils-specific code only if tests/Makefile.am.in exists.
131178         * build-aux/bootstrap (mam_template): Move definition out of loop.
131180         Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*.
131182         * build-aux/bootstrap (symlink_to_dir): Rename function from
131183         symlink_to_gnulib.  Add a directory parameter.  Update all
131184         callers.
131185         (cp_mark_as_generated): Also check for -- and link to -- files in
131186         gl/.
131188         2007-07-08  Jim Meyering  <jim@meyering.net>
131190         Adapt to deeper hierarchy in gnulib.
131191         * build-aux/bootstrap (symlink_to_dir): If the destination
131192         directory doesn't exist, create it. This is required at least for
131193         "lib/uniwidth/cjk.h".
131195         2007-05-15  Jim Meyering  <jim@meyering.net>
131197         * build-aux/bootstrap: Now that generated Makefile.am files
131198         are no longer under version control, they must be created at
131199         bootstrap time.
131201 2007-08-14  Ben Pfaff  <blp@gnu.org>
131203         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
131205 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
131207         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
131208         given the changes below.
131209         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
131210         even on hosts that have padding bits beyond the supported 64.
131212 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
131214         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
131215         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
131216         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
131217         depends on it.
131218         (xstrtol_error): Remove.
131219         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
131220         but with a different signature.
131221         (ATTRIBUTE_NORETURN, __attribute__): New macros.
131222         * lib/xstrtol-error.c: Include exitfail.h.
131223         (xstrtol_fatal): New function, with a different signature from the
131224         old xstrtol_error, so that the caller need not worry about passing
131225         in an exit status, or about storage management of the option argument.
131226         (xstrtol_error): Now a static function.  Redo signature to
131227         implement xstrtol_fatal.  Output the correct number of hyphens in
131228         front of the option so that the caller need not worry about
131229         storage management.
131230         (N_): New macro.
131231         (_): Remove; not used now.
131232         * modules/xstrtol: Depend on getopt.
131233         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
131234         of old STRTOL_FATAL_ERROR macro.
131235         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
131236         of test program.
131237         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
131238         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
131240 2007-08-08  Eric Blake  <ebb9@byu.net>
131242         * lib/xstrtol-error.c: Add missing include.
131244         Move xstrtol messages into gnulib domain, when --pobase is used.
131245         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
131246         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
131247         * modules/xstrtol (Files): Distribute new file.
131248         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
131249         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
131250         * tests/test-xstrtol.c: ...into new file.
131251         * tests/test-xstrtoul.c: Also test xstrtoul.
131252         * tests/test-xstrtoimax.c: Also test xstrtoimax.
131253         * tests/test-xstrtoumax.c: Also test xstrtoumax.
131254         * tests/test-xstrtol.sh: Drive the tests.
131255         * tests/test-xstrtoimax.sh: Likewise.
131256         * tests/test-xstrtoumax.sh: Likewise.
131257         * modules/xstrtol-tests: New module.
131258         * modules/xstrtoimax-tests: Likewise.
131259         * modules/xstrtoumax-tests: Likewise.
131261 2007-08-08  Jim Meyering  <jim@meyering.net>
131263         New function: mfile_name_concat.
131264         * lib/filenamecat.c (mfile_name_concat): New function, just like
131265         file_name_concat, but return NULL upon failure rather than exiting
131266         with a diagnostic.
131267         * lib/filenamecat.h: Declare it.
131269 2007-08-07  Bruno Haible  <bruno@clisp.org>
131271         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
131272         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
131273         warning from gcc.
131274         Reported by Eric Blake.
131276 2007-08-07  Simon Josefsson  <simon@josefsson.org>
131278         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
131279         * modules/crypto/arcfour (License): Likewise.
131280         * modules/crypto/des-tests (License): Likewise.
131281         * modules/crypto/gc-arctwo-tests (License): Likewise.
131282         * modules/crypto/gc-des-tests (License): Likewise.
131283         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
131284         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
131285         * modules/crypto/gc-md2-tests (License): Likewise.
131286         * modules/crypto/gc-md4-tests (License): Likewise.
131287         * modules/crypto/gc-md5-tests (License): Likewise.
131288         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
131289         * modules/crypto/gc-rijndael-tests (License): Likewise.
131290         * modules/crypto/gc-sha1-tests (License): Likewise.
131291         * modules/crypto/gc-tests (License): Likewise.
131292         * modules/crypto/hmac-md5 (License): Likewise.
131293         * modules/crypto/hmac-sha1 (License): Likewise.
131294         * modules/crypto/md2-tests (License): Likewise.
131295         * modules/crypto/md4-tests (License): Likewise.
131296         * modules/crypto/md5 (License): Likewise.
131297         * modules/crypto/rijndael (License): Likewise.
131298         * modules/crypto/sha1 (License): Likewise.
131299         * modules/memxor (License): Likewise.
131301 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
131302         and Bruno Haible  <bruno@clisp.org>
131304         * NEWS: Describe interface changes to human, xstrtol.
131305         * lib/human.h: Include <xstrtol.h>.
131306         (human_options): Return enum strtol_error, not int.  Remove
131307         bool arg; take int * instead.
131308         * lib/human.c: Don't include "gettext.h".
131309         (_): Remove; no longer used.
131310         Don't include <xstrtol.h>, since human.h does it.
131311         (human_options): Adjust to abovementioned interface changes.
131312         Do not report error to stderr; that's now the caller's
131313         responsibility.
131314         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
131315         interface change.
131316         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
131317         Str, Argument_type_string.  All uses changed.  Put " argument"
131318         in diagnostics to make them clearer.  Change wording of suffix
131319         message for clarity.
131320         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
131321         Argument_type_string.
131322         (STRTOL_FATAL_WARN): Remove; no longer used.
131323         * modules/human (Depends-on): Remove gettext-h.
131325 2007-08-06  Simon Josefsson  <simon@josefsson.org>
131327         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
131329 2007-07-31  Bruno Haible  <bruno@clisp.org>
131331         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
131332         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
131333         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
131335 2007-07-31  Bruno Haible  <bruno@clisp.org>
131337         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
131338         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
131340 2007-07-30  Bruno Haible  <bruno@clisp.org>
131342         * modules/base64 (License): Use the synonymous term "LGPLv2+".
131343         * modules/c-ctype (License): Likewise.
131344         * modules/c-strcase (License): Likewise.
131345         * modules/check-version (License): Likewise.
131346         * modules/iconv (License): Likewise.
131347         * modules/iconv_open (License): Likewise.
131348         * modules/read-file (License): Likewise.
131349         * modules/striconv (License): Likewise.
131350         * modules/strverscmp (License): Likewise.
131351         * modules/vasprintf (License): Likewise.
131352         * modules/crypto/des (License): Likewise.
131353         * modules/crypto/gc (License): Likewise.
131354         * modules/crypto/gc-arcfour (License): Likewise.
131355         * modules/crypto/gc-arctwo (License): Likewise.
131356         * modules/crypto/gc-des (License): Likewise.
131357         * modules/crypto/gc-hmac-md5 (License): Likewise.
131358         * modules/crypto/gc-hmac-sha1 (License): Likewise.
131359         * modules/crypto/gc-md2 (License): Likewise.
131360         * modules/crypto/gc-md4 (License): Likewise.
131361         * modules/crypto/gc-md5 (License): Likewise.
131362         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
131363         * modules/crypto/gc-random (License): Likewise.
131364         * modules/crypto/gc-rijndael (License): Likewise.
131365         * modules/crypto/gc-sha1 (License): Likewise.
131366         * modules/crypto/md2 (License): Likewise.
131367         * modules/crypto/md4 (License): Likewise.
131369 2007-07-30  Jim Meyering  <jim@meyering.net>
131371         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
131372         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
131373         it has valid stat data.  This bug would cause du not to count the
131374         sizes of inaccessible directories.
131375         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
131376         in <http://bugzilla.redhat.com/250077>.
131378 2007-07-25  Peter O'Gorman  <peter@pogma.com>
131379             Bruno Haible  <bruno@clisp.org>
131381         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
131382         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
131383         #include_next, gives a diagnostic about it, but reports no error in
131384         the exit code.
131385         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
131387 2007-07-24  Ben Pfaff  <blp@gnu.org>
131389         Improve name: "count-one-bits" is better than "popcount".
131390         * MODULES.html.sh: Update name.
131391         * lib/popcount.h: Renamed lib/count-one-bits.h.
131392         (popcount): Renamed count_one_bits.
131393         (popcountl): Renamed count_one_bits_l.
131394         (popcountll): Renamed count_one_bits_ll.
131395         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
131396         * modules/popcount: Renamed module/count-one-bits.
131397         * modules/popcount-tests: Renamed module/count-one-bits-tests.
131398         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
131400 2007-07-23  Ben Pfaff  <blp@gnu.org>
131402         * lib/popcount.h (popcount32): Reduce size of constants, to allow
131403         better code generation, and add U to large constants to avoid
131404         warnings, in non-GCC case.
131405         Suggested by Bruno Haible.
131407 2007-07-23  Ben Pfaff  <blp@gnu.org>
131409         * lib/popcount.h: Use verify_true instead of if...abort.
131410         * modules/popcount: Depend on verify module.
131411         Suggested by Jim Meyering.
131413 2007-07-23  Bruno Haible  <bruno@clisp.org>
131415         * gnulib-tool (func_import): Create a .cvsignore file also when the
131416         directory is not yet in CVS but the toplevel directory is. When
131417         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
131418         Reported by Karl Berry.
131420 2007-07-22  Ben Pfaff  <blp@gnu.org>
131422         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
131423         case.
131424         Suggested by Eric Blake.
131426 2007-07-22  Ben Pfaff  <blp@gnu.org>
131428         New module: popcount.
131429         * MODULES.html.sh: Add popcount.
131430         * modules/popcount: New file.
131431         * modules/popcount-tests: New file.
131432         * tests/test-popcount.c: New file.
131433         * lib/popcount.h: New file.
131434         * m4/popcount.m4: New file.
131436 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
131438         * build-aux/announce-gen: Update to GPLv3.
131440         * build-aux/config.guess: Update from config.
131442 2007-07-21  Bruno Haible  <bruno@clisp.org>
131444         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
131445         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
131447 2007-07-20  Jim Meyering  <jim@meyering.net>
131449         * check-module: Diagnose a self-dependency.
131451 2007-07-19  Bruno Haible  <bruno@clisp.org>
131453         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
131454         empty.
131455         Reported by Eric Blake.
131457 2007-07-18  Bruno Haible  <bruno@clisp.org>
131459         * gnulib-tool: New options --po-base, --po-domain.
131460         (func_usage): Document them.
131461         (pobase, po_domain): New variables.
131462         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
131463         DEFAULT_TEXT_DOMAIN.
131464         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
131465         (func_import): Consider pobase and po_domain. Create a po/ directory.
131466         (func_create_testdir): Set pobase and po_domain to empty.
131467         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
131468         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
131470 2007-07-18  Bruno Haible  <bruno@clisp.org>
131472         * gnulib-tool (func_get_automake_snippet): Synthesize also an
131473         EXTRA_DIST augmentation for files in build-aux/.
131475 2007-07-16  Bruno Haible  <bruno@clisp.org>
131477         * modules/lseek (License): Use the synonymous term "LGPLv2+".
131478         * modules/getdelim (License): Likewise.
131480 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
131482         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
131483         * modules/d-type (License): Likewise.
131484         * modules/extensions (License): Likewise.
131485         * modules/fnmatch (License): Likewise.
131486         * modules/fseeko (License): Likewise.
131487         * modules/getaddrinfo (License): Likewise.
131488         * modules/getline (License): Likewise.
131489         * modules/getlogin_r (License): Likewise.
131490         * modules/getpass (License): Likewise.
131491         * modules/gettimeofday (License): Likewise.
131492         * modules/glob (License): Likewise.
131493         * modules/inet_ntop (License): Likewise.
131494         * modules/malloc (License): Likewise.
131495         * modules/malloca (License): Likewise.
131496         * modules/memmem (License): Likewise.
131497         * modules/mempcpy (License): Likewise.
131498         * modules/memset (License): Likewise.
131499         * modules/minmax (License): Likewise.
131500         * modules/mktime (License): Likewise.
131501         * modules/netinet_in (License): Likewise.
131502         * modules/pathmax (License): Likewise.
131503         * modules/poll (License): Likewise.
131504         * modules/regex (License): Likewise.
131505         * modules/snprintf (License): Likewise.
131506         * modules/stdbool (License): Likewise.
131507         * modules/stdint (License): Likewise.
131508         * modules/stdio (License): Likewise.
131509         * modules/strcase (License): Likewise.
131510         * modules/strcasestr (License): Likewise.
131511         * modules/strdup (License): Likewise.
131512         * modules/string (License): Likewise.
131513         * modules/strndup (License): Likewise.
131514         * modules/strnlen (License): Likewise.
131515         * modules/strpbrk (License): Likewise.
131516         * modules/strptime (License): Likewise.
131517         * modules/strsep (License): Likewise.
131518         * modules/sys_select (License): Likewise.
131519         * modules/sys_socket (License): Likewise.
131520         * modules/sys_stat (License): Likewise.
131521         * modules/sys_time (License): Likewise.
131522         * modules/time (License): Likewise.
131523         * modules/time_r (License): Likewise.
131524         * modules/timegm (License): Likewise.
131525         * modules/unistd (License): Likewise.
131526         * modules/vsnprintf (License): Likewise.
131527         * modules/wctype (License): Likewise.
131529 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
131531         * modules/argz (License): LGPLv2+.
131533 2007-07-15  Karl Berry  <karl@gnu.org>
131535         * doc/gnulib.texi: revise node structure per new fdl.texi.
131537 2007-07-14  Bruno Haible  <bruno@clisp.org>
131539         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
131540         the output file.
131541         * lib/uniname/uninames.h: Regenerated.
131543 2007-07-14  Karl Berry  <karl@gnu.org>
131545         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
131546         omitting sectioning and index commands.
131548 2007-07-13  Bruno Haible  <bruno@clisp.org>
131550         New gnulib-tool option --more-symlinks.
131551         * gnulib-tool (func_usage): Document --more-symlinks.
131552         (do_copyrights): New variable.
131553         Recognize option --more-symlinks.
131554         (func_import): Don't add a copyright notice transform to
131555         sed_transform_lib_file if do_copyrights is empty.
131557 2007-07-13  Bruno Haible  <bruno@clisp.org>
131559         * lib/vasnprintf.c (decimal_point_char): Define also if
131560         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
131561         && !NEED_PRINTF_DIRECTIVE_A.
131562         Reported by Clemens Koller <clemens.koller@anagramm.de> via
131563         Gary V. Vaughan <gary@gnu.org>.
131565 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
131567         * lib/inttypes_.h: Undo previous change, since it was fixed
131568         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
131570 2007-07-13  Bruno Haible  <bruno@clisp.org>
131572         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
131573         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
131575 2007-07-13  Jim Meyering  <jim@meyering.net>
131577         df: Don't fail for Tru64's "file-on-file mount".
131578         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
131579         so we fall through and use statfs instead.  Details here:
131580         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
131581         Reported by Albert Chin.
131583 2007-07-13  Bruno Haible  <bruno@clisp.org>
131585         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
131586         * modules/configmake (License): Likewise.
131587         * modules/gettext (License): Likewise.
131588         * modules/gettext-h (License): Likewise.
131589         * modules/include_next (License): Likewise.
131590         * modules/link-warning (License): Likewise.
131591         * modules/localcharset (License): Likewise.
131592         * modules/localename (License): Likewise.
131593         * modules/lock (License): Likewise.
131594         * modules/relocatable-lib-lgpl (License): Likewise.
131595         * modules/size_max (License): Likewise.
131596         * modules/vasnprintf (License): Likewise.
131597         * modules/wchar (License): Likewise.
131598         * modules/xsize (License): Likewise.
131600 2007-07-13  Bruno Haible  <bruno@clisp.org>
131602         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
131603         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
131605 2007-07-12  Bruno Haible  <bruno@clisp.org>
131607         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
131608         in the modules files.
131610 2007-07-11  Karl Berry  <karl@gnu.org>
131612         * MODULES.html.sh (func_module): use
131613          sed -e '\|^'"${includefile}"'$|d'
131614          instead of /.../d, to avoid errors on $includefile's containing /.
131616 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
131618         * gnulib-tool (func_import): Avoid duplication of --avoid
131619         statements
131620         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
131621         names to `_' in variable names.
131623 2007-07-10  Eric Blake  <ebb9@byu.net>
131625         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
131626         * NEWS: Document this change.
131628 2007-07-08  Bruno Haible  <bruno@clisp.org>
131630         Update to Unicode 5.0.
131631         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
131632         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
131633         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
131634         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
131635         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
131636         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
131637         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
131638         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
131639         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
131640         U+10A3F, U+1D242..U+1D244.
131641         (nonspacing_table_ind): Update.
131642         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
131643         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
131645 2007-07-08  Bruno Haible  <bruno@clisp.org>
131647         Update to Unicode 5.0.
131648         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
131649         code transform. Extend the name index field of unicode_name_to_code and
131650         unicode_code_to_name from 16 to 24 bits.
131651         * lib/uniname/uniname.c (unicode_character_name,
131652         unicode_name_character): Add the range 0x12xxx to the code transform.
131653         * lib/uniname/uninames.h: Regenerated.
131654         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
131656 2007-07-07  Bruno Haible  <bruno@clisp.org>
131658         * modules/wcwidth-tests: New file.
131659         * tests/test-wcwidth.c: New file.
131661         Work around MacOS X wcwidth() bug.
131662         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
131663         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
131664         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
131665         original wcwidth in non-UTF-8 locales.
131666         * modules/wcwidth (Depends-on): Add localcharset, streq,
131667         uniwidth/width.
131668         * doc/functions/wcwidth.texi: Update.
131670 2007-07-07  Bruno Haible  <bruno@clisp.org>
131672         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
131673         (wcwidth): New declaration.
131674         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
131675         macros.
131676         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
131677         here. Prepare for creating <wchar.h> unconditionally.
131678         * modules/wchar (Depends-on): Add link-warning.
131679         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
131680         REPLACE_WCWIDTH, and GL_LINK_WARNING.
131681         * lib/wcwidth.h: Remove file.
131682         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
131683         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
131684         * modules/wcwidth (Files): Remove lib/wcwidth.h.
131685         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
131686         (Include): Replace wcwidth.h with <wchar.h>.
131687         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
131688         * lib/mbchar.h: Don't include wcwidth.h.
131689         * lib/mbswidth.c: Likewise.
131690         * NEWS: Mention the change.
131692 2007-07-07  Bruno Haible  <bruno@clisp.org>
131694         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
131695         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
131696         definition with an external declaration.
131697         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
131698         defined as a function. Remove AC_C_INLINE requirement.
131699         * modules/wcwidth (Files): Add lib/wcwidth.c.
131700         (Makefile.am): Remove redundant statement.
131702 2007-07-07  Bruno Haible  <bruno@clisp.org>
131704         * MODULES.html.sh (Unicode string functions): Add the new modules.
131706         * tests/uniwidth/test-u32-strwidth.c: New file.
131707         * modules/uniwidth/u32-strwidth-tests: New file.
131709         * lib/uniwidth/u32-strwidth.c: New file.
131710         * modules/uniwidth/u32-strwidth: New file.
131712         * tests/uniwidth/test-u16-strwidth.c: New file.
131713         * modules/uniwidth/u16-strwidth-tests: New file.
131715         * lib/uniwidth/u16-strwidth.c: New file.
131716         * modules/uniwidth/u16-strwidth: New file.
131718         * tests/uniwidth/test-u8-strwidth.c: New file.
131719         * modules/uniwidth/u8-strwidth-tests: New file.
131721         * lib/uniwidth/u8-strwidth.c: New file.
131722         * modules/uniwidth/u8-strwidth: New file.
131724         * tests/uniwidth/test-u32-width.c: New file.
131725         * modules/uniwidth/u32-width-tests: New file.
131727         * lib/uniwidth/u32-width.c: New file.
131728         * modules/uniwidth/u32-width: New file.
131730         * tests/uniwidth/test-u16-width.c: New file.
131731         * modules/uniwidth/u16-width-tests: New file.
131733         * lib/uniwidth/u16-width.c: New file.
131734         * modules/uniwidth/u16-width: New file.
131736         * tests/uniwidth/test-u8-width.c: New file.
131737         * modules/uniwidth/u8-width-tests: New file.
131739         * lib/uniwidth/u8-width.c: New file.
131740         * modules/uniwidth/u8-width: New file.
131742         * tests/uniwidth/test-uc_width.c: New file.
131743         * modules/uniwidth/width-tests: New file.
131745         * lib/uniwidth/width.c: New file, from GNU libiconv.
131746         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
131747         * modules/uniwidth/width: New file.
131749         * lib/uniwidth.h: New file, from GNU libiconv.
131750         * modules/uniwidth/base: New file.
131752 2007-07-07  Bruno Haible  <bruno@clisp.org>
131754         * lib/uniname.h: New file, from GNU gettext.
131755         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
131756         * lib/uniname/uninames.h: New file, from GNU gettext.
131757         * lib/uniname/uniname.c: New file, from GNU gettext.
131758         * tests/uniname/test-uninames.sh: New file.
131759         * tests/uniname/test-uninames.c: New file, from GNU gettext.
131760         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
131761         * modules/uniname/base: New file.
131762         * modules/uniname/uniname: New file.
131763         * modules/uniname/uniname-tests: New file.
131764         * MODULES.html.sh (Unicode string functions): Add the new modules.
131766 2007-07-06  Bruno Haible  <bruno@clisp.org>
131768         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
131770 2007-07-06  Bruno Haible  <bruno@clisp.org>
131772         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
131773         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
131774         includes <cygwin/sys_time.h> which includes <sys/select.h> which
131775         include <sys/time.h>.
131776         Reported by Eric Blake.
131778 2007-07-06  Eric Blake  <ebb9@byu.net>
131780         Fix testing canonicalize on cygwin.
131781         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
131782         Revert patch from 2007-06-19.
131783         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
131784         canonicalize module is also in use.
131785         * tests/test-canonicalize.c: New file.
131786         * tests/test-canonicalize.sh: Likewise.
131787         * modules/canonicalize-tests: Likewise.
131789 2007-07-06  Jim Meyering  <jim@meyering.net>
131791         * lib/getugroups.c (getugroups): Detect getgrent failure.
131792         Adjust comment to reflect reality: this function may return -1.
131794 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
131796         * build-aux/bootstrap (TP_URL,get_translations): Update to use
131797         the new TP address.
131798         (usage): Fix typo
131799         (gnulib_mk): New variable.
131801 2007-07-05  Jim Meyering  <jim@meyering.net>
131803         Don't let endgrent clobber errno, no matter how improbable.
131804         * lib/getugroups.c (getugroups): Save and restore errno around
131805         endgrent call.
131807         Close the group DB even when failing with 2^31 or more members.
131808         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
131810 2007-07-04  Jim Meyering  <jim@meyering.net>
131812         * lib/getugroups.h: New file.
131813         * lib/getugroups.c: Include "getugroups.h".
131814         Remove uses of "register" keyword.
131815         Move local variable, "cp", down into scope where used.
131816         Give "username" parameter the "const" attribute.
131817         * modules/getugroups (Files): Add lib/getugroups.h
131819 2007-07-04  Karl Berry  <karl@gnu.org>
131821         * MODULES.html.sh (func_all_modules): Complete rename of
131822         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
131824 2007-07-02  Bruno Haible  <bruno@clisp.org>
131826         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
131827         mode, when inttypes.h comes from gnulib.
131828         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
131830 2007-07-02  Simon Josefsson  <simon@josefsson.org>
131832         * NEWS: Mention lgpl module name change.
131834         * modules/lgpl-2.1: Renamed from lgpl.
131836         * NEWS: Mention gpl module name change.
131838         * modules/gpl-3.0: New file, based on gpl-2.0.
131840         * modules/gpl-2.0: Renamed from gpl.
131842         * modules/gpl: Fix filename, doc/gpl.texi is now found at
131843         doc/gpl-2.0.texi.
131845 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
131847         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
131848         #define __STDC_LIMIT_MACROS temporarily while including
131849         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
131850         Problem reported by Joel E. Denny in
131851         <http://lists.gnu.org/r/bug-gnulib/2007-07/msg00008.html>.
131853 2007-07-01  Bruno Haible  <bruno@clisp.org>
131855         * lib/unistdio.h: New file.
131856         * lib/unistdio/u-asnprintf.h: New file.
131857         * lib/unistdio/u-asprintf.h: New file.
131858         * lib/unistdio/u-printf-args.c: New file.
131859         * lib/unistdio/u-printf-args.h: New file.
131860         * lib/unistdio/u-printf-parse.h: New file.
131861         * lib/unistdio/u-snprintf.h: New file.
131862         * lib/unistdio/u-sprintf.h: New file.
131863         * lib/unistdio/u-vasprintf.h: New file.
131864         * lib/unistdio/u-vsnprintf.h: New file.
131865         * lib/unistdio/u-vsprintf.h: New file.
131866         * lib/unistdio/ulc-asnprintf.c: New file.
131867         * lib/unistdio/ulc-asprintf.c: New file.
131868         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
131869         * lib/unistdio/ulc-printf-parse.c: New file.
131870         * lib/unistdio/ulc-snprintf.c: New file.
131871         * lib/unistdio/ulc-sprintf.c: New file.
131872         * lib/unistdio/ulc-vasnprintf.c: New file.
131873         * lib/unistdio/ulc-vasprintf.c: New file.
131874         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
131875         * lib/unistdio/ulc-vsnprintf.c: New file.
131876         * lib/unistdio/ulc-vsprintf.c: New file.
131877         * lib/unistdio/u8-asnprintf.c: New file.
131878         * lib/unistdio/u8-asprintf.c: New file.
131879         * lib/unistdio/u8-printf-parse.c: New file.
131880         * lib/unistdio/u8-snprintf.c: New file.
131881         * lib/unistdio/u8-sprintf.c: New file.
131882         * lib/unistdio/u8-vasnprintf.c: New file.
131883         * lib/unistdio/u8-vasprintf.c: New file.
131884         * lib/unistdio/u8-vsnprintf.c: New file.
131885         * lib/unistdio/u8-vsprintf.c: New file.
131886         * lib/unistdio/u8-u8-asnprintf.c: New file.
131887         * lib/unistdio/u8-u8-asprintf.c: New file.
131888         * lib/unistdio/u8-u8-snprintf.c: New file.
131889         * lib/unistdio/u8-u8-sprintf.c: New file.
131890         * lib/unistdio/u8-u8-vasnprintf.c: New file.
131891         * lib/unistdio/u8-u8-vasprintf.c: New file.
131892         * lib/unistdio/u8-u8-vsnprintf.c: New file.
131893         * lib/unistdio/u8-u8-vsprintf.c: New file.
131894         * lib/unistdio/u16-asnprintf.c: New file.
131895         * lib/unistdio/u16-asprintf.c: New file.
131896         * lib/unistdio/u16-printf-parse.c: New file.
131897         * lib/unistdio/u16-snprintf.c: New file.
131898         * lib/unistdio/u16-sprintf.c: New file.
131899         * lib/unistdio/u16-vasnprintf.c: New file.
131900         * lib/unistdio/u16-vasprintf.c: New file.
131901         * lib/unistdio/u16-vsnprintf.c: New file.
131902         * lib/unistdio/u16-vsprintf.c: New file.
131903         * lib/unistdio/u16-u16-asnprintf.c: New file.
131904         * lib/unistdio/u16-u16-asprintf.c: New file.
131905         * lib/unistdio/u16-u16-snprintf.c: New file.
131906         * lib/unistdio/u16-u16-sprintf.c: New file.
131907         * lib/unistdio/u16-u16-vasnprintf.c: New file.
131908         * lib/unistdio/u16-u16-vasprintf.c: New file.
131909         * lib/unistdio/u16-u16-vsnprintf.c: New file.
131910         * lib/unistdio/u16-u16-vsprintf.c: New file.
131911         * lib/unistdio/u32-asnprintf.c: New file.
131912         * lib/unistdio/u32-asprintf.c: New file.
131913         * lib/unistdio/u32-printf-parse.c: New file.
131914         * lib/unistdio/u32-snprintf.c: New file.
131915         * lib/unistdio/u32-sprintf.c: New file.
131916         * lib/unistdio/u32-vasnprintf.c: New file.
131917         * lib/unistdio/u32-vasprintf.c: New file.
131918         * lib/unistdio/u32-vsnprintf.c: New file.
131919         * lib/unistdio/u32-vsprintf.c: New file.
131920         * lib/unistdio/u32-u32-asnprintf.c: New file.
131921         * lib/unistdio/u32-u32-asprintf.c: New file.
131922         * lib/unistdio/u32-u32-snprintf.c: New file.
131923         * lib/unistdio/u32-u32-sprintf.c: New file.
131924         * lib/unistdio/u32-u32-vasnprintf.c: New file.
131925         * lib/unistdio/u32-u32-vasprintf.c: New file.
131926         * lib/unistdio/u32-u32-vsnprintf.c: New file.
131927         * lib/unistdio/u32-u32-vsprintf.c: New file.
131928         * tests/unistdio/test-ulc-asnprintf1.c: New file.
131929         * tests/unistdio/test-ulc-asnprintf1.h: New file.
131930         * tests/unistdio/test-ulc-printf1.h: New file.
131931         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
131932         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
131933         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
131934         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
131935         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
131936         * tests/unistdio/test-ulc-vasprintf1.c: New file.
131937         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
131938         * tests/unistdio/test-ulc-vsprintf1.c: New file.
131939         * tests/unistdio/test-u8-asnprintf1.c: New file.
131940         * tests/unistdio/test-u8-asnprintf1.h: New file.
131941         * tests/unistdio/test-u8-printf1.h: New file.
131942         * tests/unistdio/test-u8-vasnprintf1.c: New file.
131943         * tests/unistdio/test-u8-vasnprintf2.c: New file.
131944         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
131945         * tests/unistdio/test-u8-vasnprintf3.c: New file.
131946         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
131947         * tests/unistdio/test-u8-vasprintf1.c: New file.
131948         * tests/unistdio/test-u8-vsnprintf1.c: New file.
131949         * tests/unistdio/test-u8-vsprintf1.c: New file.
131950         * tests/unistdio/test-u16-asnprintf1.c: New file.
131951         * tests/unistdio/test-u16-asnprintf1.h: New file.
131952         * tests/unistdio/test-u16-printf1.h: New file.
131953         * tests/unistdio/test-u16-vasnprintf1.c: New file.
131954         * tests/unistdio/test-u16-vasnprintf2.c: New file.
131955         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
131956         * tests/unistdio/test-u16-vasnprintf3.c: New file.
131957         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
131958         * tests/unistdio/test-u16-vasprintf1.c: New file.
131959         * tests/unistdio/test-u16-vsnprintf1.c: New file.
131960         * tests/unistdio/test-u16-vsprintf1.c: New file.
131961         * tests/unistdio/test-u32-asnprintf1.c: New file.
131962         * tests/unistdio/test-u32-asnprintf1.h: New file.
131963         * tests/unistdio/test-u32-printf1.h: New file.
131964         * tests/unistdio/test-u32-vasnprintf1.c: New file.
131965         * tests/unistdio/test-u32-vasnprintf2.c: New file.
131966         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
131967         * tests/unistdio/test-u32-vasnprintf3.c: New file.
131968         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
131969         * tests/unistdio/test-u32-vasprintf1.c: New file.
131970         * tests/unistdio/test-u32-vsnprintf1.c: New file.
131971         * tests/unistdio/test-u32-vsprintf1.c: New file.
131972         * modules/unistdio/base: New file.
131973         * modules/unistdio/u-printf-args: New file.
131974         * modules/unistdio/ulc-asnprintf: New file.
131975         * modules/unistdio/ulc-asprintf: New file.
131976         * modules/unistdio/ulc-fprintf: New file.
131977         * modules/unistdio/ulc-printf-parse: New file.
131978         * modules/unistdio/ulc-snprintf: New file.
131979         * modules/unistdio/ulc-sprintf: New file.
131980         * modules/unistdio/ulc-vasnprintf: New file.
131981         * modules/unistdio/ulc-vasprintf: New file.
131982         * modules/unistdio/ulc-vfprintf: New file.
131983         * modules/unistdio/ulc-vsnprintf: New file.
131984         * modules/unistdio/ulc-vsprintf: New file.
131985         * modules/unistdio/u8-asnprintf: New file.
131986         * modules/unistdio/u8-asprintf: New file.
131987         * modules/unistdio/u8-printf-parse: New file.
131988         * modules/unistdio/u8-snprintf: New file.
131989         * modules/unistdio/u8-sprintf: New file.
131990         * modules/unistdio/u8-vasnprintf: New file.
131991         * modules/unistdio/u8-vasprintf: New file.
131992         * modules/unistdio/u8-vsnprintf: New file.
131993         * modules/unistdio/u8-vsprintf: New file.
131994         * modules/unistdio/u8-u8-asnprintf: New file.
131995         * modules/unistdio/u8-u8-asprintf: New file.
131996         * modules/unistdio/u8-u8-snprintf: New file.
131997         * modules/unistdio/u8-u8-sprintf: New file.
131998         * modules/unistdio/u8-u8-vasnprintf: New file.
131999         * modules/unistdio/u8-u8-vasprintf: New file.
132000         * modules/unistdio/u8-u8-vsnprintf: New file.
132001         * modules/unistdio/u8-u8-vsprintf: New file.
132002         * modules/unistdio/u16-asnprintf: New file.
132003         * modules/unistdio/u16-asprintf: New file.
132004         * modules/unistdio/u16-printf-parse: New file.
132005         * modules/unistdio/u16-snprintf: New file.
132006         * modules/unistdio/u16-sprintf: New file.
132007         * modules/unistdio/u16-vasnprintf: New file.
132008         * modules/unistdio/u16-vasprintf: New file.
132009         * modules/unistdio/u16-vsnprintf: New file.
132010         * modules/unistdio/u16-vsprintf: New file.
132011         * modules/unistdio/u16-u16-asnprintf: New file.
132012         * modules/unistdio/u16-u16-asprintf: New file.
132013         * modules/unistdio/u16-u16-snprintf: New file.
132014         * modules/unistdio/u16-u16-sprintf: New file.
132015         * modules/unistdio/u16-u16-vasnprintf: New file.
132016         * modules/unistdio/u16-u16-vasprintf: New file.
132017         * modules/unistdio/u16-u16-vsnprintf: New file.
132018         * modules/unistdio/u16-u16-vsprintf: New file.
132019         * modules/unistdio/u32-asnprintf: New file.
132020         * modules/unistdio/u32-asprintf: New file.
132021         * modules/unistdio/u32-printf-parse: New file.
132022         * modules/unistdio/u32-snprintf: New file.
132023         * modules/unistdio/u32-sprintf: New file.
132024         * modules/unistdio/u32-vasnprintf: New file.
132025         * modules/unistdio/u32-vasprintf: New file.
132026         * modules/unistdio/u32-vsnprintf: New file.
132027         * modules/unistdio/u32-vsprintf: New file.
132028         * modules/unistdio/u32-u32-asnprintf: New file.
132029         * modules/unistdio/u32-u32-asprintf: New file.
132030         * modules/unistdio/u32-u32-snprintf: New file.
132031         * modules/unistdio/u32-u32-sprintf: New file.
132032         * modules/unistdio/u32-u32-vasnprintf: New file.
132033         * modules/unistdio/u32-u32-vasprintf: New file.
132034         * modules/unistdio/u32-u32-vsnprintf: New file.
132035         * modules/unistdio/u32-u32-vsprintf: New file.
132036         * modules/unistdio/ulc-asnprintf-tests: New file.
132037         * modules/unistdio/ulc-vasnprintf-tests: New file.
132038         * modules/unistdio/ulc-vasprintf-tests: New file.
132039         * modules/unistdio/ulc-vsnprintf-tests: New file.
132040         * modules/unistdio/ulc-vsprintf-tests: New file.
132041         * modules/unistdio/u8-asnprintf-tests: New file.
132042         * modules/unistdio/u8-vasnprintf-tests: New file.
132043         * modules/unistdio/u8-vasprintf-tests: New file.
132044         * modules/unistdio/u8-vsnprintf-tests: New file.
132045         * modules/unistdio/u8-vsprintf-tests: New file.
132046         * modules/unistdio/u16-asnprintf-tests: New file.
132047         * modules/unistdio/u16-vasnprintf-tests: New file.
132048         * modules/unistdio/u16-vasprintf-tests: New file.
132049         * modules/unistdio/u16-vsnprintf-tests: New file.
132050         * modules/unistdio/u16-vsprintf-tests: New file.
132051         * modules/unistdio/u32-asnprintf-tests: New file.
132052         * modules/unistdio/u32-vasnprintf-tests: New file.
132053         * modules/unistdio/u32-vasprintf-tests: New file.
132054         * modules/unistdio/u32-vsnprintf-tests: New file.
132055         * modules/unistdio/u32-vsprintf-tests: New file.
132056         * MODULES.html.sh (Unicode string functions): Add the new modules.
132058 2007-07-01  Bruno Haible  <bruno@clisp.org>
132060         * lib/sprintf.c (sprintf): Limit the available length estimation,
132061         to avoid address wraparound.
132062         * lib/vsprintf.c (vsprintf): Likewise.
132063         * modules/sprintf-posix (Dependencies): Add stdint.
132064         * modules/vsprintf-posix (Dependencies): Likewise.
132066 2007-07-01  Bruno Haible  <bruno@clisp.org>
132068         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
132069         Windows PATH as well. Conservative double-quoting. Comments.
132071 2007-07-01  Bruno Haible  <bruno@clisp.org>
132072             Eric Blake  <ebb9@byu.net>
132073             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
132075         * gnulib-tool (self_abspathname): Fix algorithm to cope with
132076         empty components in $PATH, denoting '.'.
132078 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
132080         * gnulib-tool: Fix indentation.
132081         (func_create_megatestdir): Likewise.
132082         Report by Bruno Haible.
132084 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
132086         Sync from Automake.
132087         * build-aux/gnupload: Fix shell portability issues with for loops.
132088         Report by Karl Berry.
132090 2007-06-29  Simon Josefsson  <simon@josefsson.org>
132092         * build-aux/maint.mk (POURL): Use translationproject.org.
132094 2007-06-27  Simon Josefsson  <simon@josefsson.org>
132095             Bruno Haible  <bruno@clisp.org>
132097         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
132098         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
132099         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
132100         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
132101         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
132103 2007-06-27  Bruno Haible  <bruno@clisp.org>
132105         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
132106         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
132108 2007-06-26  Karl Berry  <karl@gnu.org>
132110         * MODULES.html.sh: remove xreadlink-with-size.
132112 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
132114         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
132115         method that I hope also handles the double-include problem noted
132116         by Bruno Haible in
132117         <http://lists.gnu.org/r/bug-gnulib/2007-05/msg00186.html>.
132119 2007-06-23  Bruno Haible  <bruno@clisp.org>
132121         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
132122         Don't let the 'mostlyclean' target fail if the last subdirectory could
132123         not be removed.
132124         Reported by Karl Berry.
132126 2007-06-23  Bruno Haible  <bruno@clisp.org>
132128         * gnulib-tool (echo): Add a speedier workaround for ksh.
132129         * tests/test-echo.sh: Likewise.
132131 2007-06-23  Bruno Haible  <bruno@clisp.org>
132133         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
132134         * tests/test-echo.sh: Likewise.
132136 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
132138         * gnulib-tool (IFS): Initialize early, so we don't set it to
132139         empty later.
132140         (self_abspathname): Rewrite algorithm to set it, reindent.
132141         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
132142         (func_create_megatestdir): Merge some sed scripts.
132144 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
132146         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
132147         exposed by Sun Studio 11 cc on Solaris 8.
132149 2007-06-22  Bruno Haible  <bruno@clisp.org>
132151         * gnulib-tool (echo): Ensure the echo primitive does not interpret
132152         backslashes.
132153         * tests/test-echo.sh: New file.
132155 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
132157         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
132158         simplify `sed_replace_build_aux' scripts, they are portable but
132159         echoing them with `echo' is not.
132160         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
132162 2007-06-21  Karl Berry  <karl@gnu.org>
132164         * config/srclist.txt: guess we can't handle the licenses via
132165         srclist at the moment.
132167 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
132169         * MODULES.html.sh: Add include_next.
132170         * modules/include_next: New file.
132172 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
132174         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
132175         INCLUDE_NEXT.
132176         (gl_CHECK_NEXT_HEADERS): New macro.
132177         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
132178         the obsolescent gl_ABSOLUTE_HEADER.
132179         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
132180         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
132181         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
132182         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
132183         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
132184         * m4/math_h.m4 (gl_MATH_H): Likewise.
132185         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
132186         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
132187         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
132188         * m4/stdint.m4 (gl_STDINT_H): Likewise.
132189         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
132190         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
132191         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
132192         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
132193         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
132194         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
132195         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
132196         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
132197         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
132198         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
132199         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
132200         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
132201         * m4/inttypes.m4 (gl_INTTYPES_H): Define
132202         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
132203         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
132204         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
132205         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
132206         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
132207         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
132208         * lib/float_.h: Likewise.
132209         * lib/inttypes_.h: Likewise.
132210         * lib/math_.h: Likewise.
132211         * lib/search_.h: Likewise.
132212         * lib/signal_.h: Likewise.
132213         * lib/stdint_.h: Likewise.
132214         * lib/stdio_.h: Likewise.
132215         * lib/stdlib_.h: Likewise.
132216         * lib/string_.h: Likewise.
132217         * lib/sys_stat_.h: Likewise.
132218         * lib/sys_time_.h: Likewise.
132219         * lib/time_.h: Likewise.
132220         * lib/unistd_.h: Likewise.
132221         * lib/wchar_.h: Likewise.
132222         * lib/wctype_.h: Likewise.
132223         * lib/dirent_.h: Likewise.
132224         * lib/iconv_.h: Likewise.
132225         * lib/locale_.h: Likewise.
132226         * lib/netinet_in_.h: Likewise.
132227         * lib/sys_select_.h: Likewise.
132228         * lib/sys_socket_.h: Likewise.
132229         * lib/sysexits_.h: Likewise.
132230         * modules/fcntl (Depends-on): Depend on include_next, not
132231         absolute_header.
132232         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
132233         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
132234         * modules/fchdir: Likewise.
132235         * modules/float: Likewise.
132236         * modules/iconv_open: Likewise.
132237         * modules/inttypes: Likewise.
132238         * modules/locale: Likewise.
132239         * modules/math: Likewise.
132240         * modules/netinet_in: Likewise.
132241         * modules/search: Likewise.
132242         * modules/signal: Likewise.
132243         * modules/stdint: Likewise.
132244         * modules/stdio: Likewise.
132245         * modules/stdlib: Likewise.
132246         * modules/string: Likewise.
132247         * modules/sys_select: Likewise.
132248         * modules/sys_socket: Likewise.
132249         * modules/sys_stat: Likewise.
132250         * modules/sys_time: Likewise.
132251         * modules/sysexits: Likewise.
132252         * modules/time: Likewise.
132253         * modules/unistd: Likewise.
132254         * modules/wchar: Likewise.
132255         * modules/wctype: Likewise.
132256         * modules/sys_stat: Change maintainer to "all".
132257         * modules/unistd: Likewise.
132259 2007-06-20  Karl Berry  <karl@gnu.org>
132261         * config/srclist.txt: track www changes in license files.
132263 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
132265         * build-aux/bootstrap: Remove stray dot.
132266         Make sure build_aux settings are honored when linking
132267         gnulib_extra_files.
132269 2007-06-19  Eric Blake  <ebb9@byu.net>
132271         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
132272         Allow compilation on cygwin.
132274 2007-06-19  Jim Meyering  <jim@meyering.net>
132276         xreadlink-with-size: Remove module.  No longer used.
132277         Ex-callers now use xreadlink or mreadlink-with-size.
132278         * modules/xreadlink-with-size: Remove module.
132279         * lib/xreadlink-with-size.c: Remove file.
132280         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
132281         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
132282         just before the function definition *is* accurate.
132284         Eliminate one way canonicalize_filename_mode could exit.
132285         * lib/canonicalize.c (canonicalize_filename_mode):
132286         Use mreadlink_with_size, not xreadlink_with_size.
132288 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
132290         Detect porting problems to FreeBSD/arm, which has time_t wider than
132291         long int.  Original problem reported for GNU diff by Xin Li in
132292         <http://lists.gnu.org/r/bug-gnu-utils/2007-06/msg00091.html>.
132293         * modules/getdate (Depends-on): Add intprops, verify.
132294         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
132295         is an integer type no wider than long int.
132297 2007-06-18  Jim Meyering  <jim@meyering.net>
132299         New module: mreadlink-with-size.
132300         * MODULES.html.sh: Add mreadlink-with-size.
132301         * modules/mreadlink-with-size: New module
132302         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
132303         not xreadlink-with-size.
132304         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
132306 2007-06-16  Bruno Haible  <bruno@clisp.org>
132308         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
132309         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
132310         Reported by Gary V. Vaughan <gary@gnu.org>.
132312 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
132314         Revamp lchown so that it lives in unistd.h where it belongs.
132315         * lib/lchown.h: Remove.
132316         * lib/dirchownmod.c: Don't include lib/lchown.h.
132317         * lib/fchownat.c: Likewise.
132318         * lib/openat.c: Likewise.
132319         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
132320         does not follow symlinks.
132321         (EOPNOTSUPP): Define if not defined.
132322         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
132323         is defined to 0.
132324         (lchown): New decl.
132325         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
132326         Do not check for lchown decl.
132327         Set REPLACE_LCHOWN.
132328         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
132329         REPLACE_LCHOWN.
132330         * modules/chown: Make it clear it follows symlinks.
132331         * modules/lchown: Make it clear it doesn't follow symlinks.
132332         (Files): Remove lib/lchown.h
132333         (Depends-on): Add unistd.
132334         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
132335         (Include): Include <unistd.h>, not "lchown.h".
132336         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
132337         REPLACE_LCHOWN.
132339 2007-06-15  Jim Meyering  <jim@meyering.net>
132341         Change license (GPL to LGPL) of fsusage and dependents.
132342         * modules/fsusage (License): Change to LGPL.
132343         * modules/full-read (License): Likewise.
132344         * modules/full-write (License): Likewise.
132345         * modules/safe-read (License): Likewise.
132346         * modules/safe-write (License): Likewise.
132348 2007-06-14  Ben Pfaff  <blp@gnu.org>
132350         Missing part of allocsa -> malloca transition.
132351         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
132352         gl_MALLOCA.
132354 2007-06-12  Bruno Haible  <bruno@clisp.org>
132356         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
132357         to ia64, x86_64, i386.
132358         Reported by Eric Blake.
132360 2007-06-12  Bruno Haible  <bruno@clisp.org>
132362         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
132363         cross-compiling to x86_64.
132365 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
132367         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
132368         glitch reported by Ralf Wildenhues in
132369         <http://lists.gnu.org/r/bug-gnulib/2007-06/msg00114.html>.
132371         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
132372         Vin Shelton.
132374 2007-06-11  Bruno Haible  <bruno@clisp.org>
132376         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
132377         replacement string.
132378         Reported by Eric Blake.
132380 2007-06-10  Bruno Haible  <bruno@clisp.org>
132382         Prepare vasnprintf code for use with Unicode strings.
132383         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
132384         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
132385         TYPE_U32_STRING.
132386         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
132387         a_u32_string variants.
132388         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
132389         * lib/printf-args.c: Don't include config.h and the specification
132390         header if PRINTF_FETCHARGS is already defined.
132391         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
132392         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
132393         TYPE_U16_STRING, TYPE_U32_STRING.
132394         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
132395         u16_directive, u16_directives, u32_directive, u32_directives): New
132396         types.
132397         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
132398         New declarations.
132399         * lib/printf-parse.c: Don't include config.h and the specification
132400         header if PRINTF_PARSE is already defined. Eliminate the set of
132401         parameters for WIDE_CHAR_VERSION; the user of this file must provide
132402         them now. Include c-ctype.h.
132403         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
132404         directive and CHAR_T_ONLY_ASCII.
132405         * lib/vasnprintf.c: Don't include config.h and the specification header
132406         if VASNPRINTF is already defined.
132407         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
132408         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
132409         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
132410         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
132411         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
132412         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
132413         code accordingly.
132414         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
132415         pad_ourselves also in this case, with the 'c' and 's' directives, and
132416         with a different notion of "width".
132417         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
132419 2007-06-10  Bruno Haible  <bruno@clisp.org>
132421         * modules/unistr/u32-mbsnlen: New file.
132422         * lib/unistr/u32-mbsnlen.c: New file.
132424         * modules/unistr/u16-mbsnlen: New file.
132425         * lib/unistr/u16-mbsnlen.c: New file.
132427         * modules/unistr/u8-mbsnlen: New file.
132428         * lib/unistr/u8-mbsnlen.c: New file.
132430         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
132431         declarations.
132433 2007-06-10  Bruno Haible  <bruno@clisp.org>
132435         * lib/string_.h (mbsnlen): New declaration.
132436         * lib/mbsnlen.c: New file.
132437         * m4/mbsnlen.m4: New file.
132438         * modules/mbsnlen: New file.
132439         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
132440         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
132441         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
132443 2007-06-10  Bruno Haible  <bruno@clisp.org>
132445         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
132447 2007-06-10  Bruno Haible  <bruno@clisp.org>
132449         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
132450         * lib/mbuiter.h: Likewise.
132452 2007-06-10  Bruno Haible  <bruno@clisp.org>
132454         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
132455         declaration.
132457 2007-06-10  Karl Berry  <karl@gnu.org>
132459         * config/srclist.txt: remove gettext entries, Bruno prefers
132460         to update individually.
132462 2007-06-10  Bruno Haible  <bruno@clisp.org>
132464         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
132465         'maxlen'. Ensure only length + width bytes are allocated, not
132466         length + 1 + width.
132468 2007-06-09  Bruno Haible  <bruno@clisp.org>
132470         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
132471         (CHAR_T): Remove macro.
132472         (VASNPRINTF): Update.
132474 2007-06-09  Bruno Haible  <bruno@clisp.org>
132476         * MODULES.html.sh (Unicode string functions): Add the new modules.
132478         * modules/uniconv/u32-conv-to-enc: New file.
132479         * lib/uniconv/u32-conv-to-enc.c: New file.
132480         * modules/uniconv/u32-conv-to-enc-tests: New file.
132481         * tests/uniconv/test-u32-conv-to-enc.c: New file.
132483         * modules/uniconv/u16-conv-to-enc: New file.
132484         * lib/uniconv/u16-conv-to-enc.c: New file.
132485         * lib/uniconv/u-conv-to-enc.h: New file.
132486         * modules/uniconv/u16-conv-to-enc-tests: New file.
132487         * tests/uniconv/test-u16-conv-to-enc.c: New file.
132489         * modules/uniconv/u8-conv-to-enc: New file.
132490         * lib/uniconv/u8-conv-to-enc.c: New file.
132491         * modules/uniconv/u8-conv-to-enc-tests: New file.
132492         * tests/uniconv/test-u8-conv-to-enc.c: New file.
132494         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
132495         u32_conv_to_encoding): New declarations.
132497 2007-06-09  Bruno Haible  <bruno@clisp.org>
132499         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
132501 2007-06-09  Bruno Haible  <bruno@clisp.org>
132503         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
132504         * modules/malloca: Renamed from modules/allocsa, updated.
132505         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
132506         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
132507         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
132508         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
132509         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
132510         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
132511         * modules/xmalloca: Renamed from modules/xallocsa, updated.
132512         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
132513         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
132514         * modules/c-strcasestr (Depends-on): Update.
132515         * lib/c-strcasestr.c: Update.
132516         * modules/c-strstr (Depends-on): Update.
132517         * lib/c-strstr.c: Update.
132518         * modules/canonicalize-lgpl (Depends-on): Update.
132519         * lib/canonicalize-lgpl.c: Update.
132520         * modules/clean-temp (Depends-on): Update.
132521         * lib/clean-temp.c: Update.
132522         * modules/csharpcomp (Depends-on): Update.
132523         * lib/csharpcomp.c: Update.
132524         * modules/csharpexec (Depends-on): Update.
132525         * lib/csharpexec.c: Update.
132526         * modules/javacomp (Depends-on): Update.
132527         * lib/javacomp.c: Update.
132528         * modules/javaexec (Depends-on): Update.
132529         * lib/javaexec.c: Update.
132530         * modules/mbscasestr (Depends-on): Update.
132531         * lib/mbscasestr.c: Update.
132532         * modules/mbsstr (Depends-on): Update.
132533         * lib/mbsstr.c: Update.
132534         * modules/setenv (Depends-on): Update.
132535         * lib/setenv.c: Update.
132536         * modules/strcasestr (Depends-on): Update.
132537         * lib/strcasestr.c: Update.
132538         * modules/striconveha (Depends-on): Update.
132539         * lib/striconveha.c: Update.
132540         * modules/relocatable-prog-wrapper (Files): Update.
132541         * lib/relocwrapper.c: Update.
132542         * build-aux/install-reloc: Update.
132543         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
132545 2007-06-08  Bruno Haible  <bruno@clisp.org>
132547         Port to uClibc.
132548         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
132549         * lib/fpurge.c (fpurge): Likewise.
132550         * lib/freading.c (freading): Likewise.
132551         * lib/fseeko.c (rpl_fseeko): Likewise.
132552         * lib/fseterr.c (fseterr): Likewise.
132553         * lib/fwriting.c (fwriting): Likewise.
132554         * tests/test-fflush.c (main): Avoid a failure on uClibc.
132556 2007-06-08  Bruno Haible  <bruno@clisp.org>
132558         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
132559         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
132560         * modules/gettext (Files): Add m4/intlmacosx.m4.
132562 2007-06-07  Bruno Haible  <bruno@clisp.org>
132564         * modules/localename-tests: New file.
132565         * tests/test-localename.c: New file.
132567         New module 'localename'.
132568         * lib/localename.h: New file.
132569         * lib/localename.c: New file, from GNU gettext.
132570         * m4/localename.m4: New file.
132571         * modules/localename: New file.
132573 2007-06-07  Bruno Haible  <bruno@clisp.org>
132575         Work around the lack of <wchar.h> on some builds of uClibc.
132576         * doc/headers/wchar.texi: Update.
132577         * lib/wchar_.h: Include <wchar.h> only if it exists.
132578         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
132579         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
132580         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
132581         doesn't exist.
132582         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
132583         * modules/mbfile (Depends-on): Add wchar.
132584         * modules/mbiter (Depends-on): Likewise.
132585         * modules/mbuiter (Depends-on): Likewise.
132586         Reported by Simon Josefsson.
132588 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
132590         Work around problem reported by Steven M. Schweda in
132591         <http://lists.gnu.org/r/bug-tar/2007-06/msg00002.html>:
132592         Tru64 5.1B with the Compaq compiler environment installed declares
132593         an 'isblank' function but does not define it in the C library.
132594         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
132595         * lib/regex_internal.h (isblank): Likewise.
132596         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
132597         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
132599 2007-06-05  Bruno Haible  <bruno@clisp.org>
132601         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
132602         ia64.
132603         * modules/printf-safe: New file.
132604         * modules/fprintf-posix (Depends-on): Add printf-safe.
132605         * modules/printf-posix (Depends-on): Likewise.
132606         * modules/snprintf-posix (Depends-on): Likewise.
132607         * modules/sprintf-posix (Depends-on): Likewise.
132608         * modules/vasnprintf-posix (Depends-on): Likewise.
132609         * modules/vasprintf-posix (Depends-on): Likewise.
132610         * modules/vfprintf-posix (Depends-on): Likewise.
132611         * modules/vprintf-posix (Depends-on): Likewise.
132612         * modules/vsnprintf-posix (Depends-on): Likewise.
132613         * modules/vsprintf-posix (Depends-on): Likewise.
132614         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
132615         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
132616         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
132617         "no" on i386, x86_64, ia64.
132618         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
132619         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
132620         on i386, x86_64, ia64.
132621         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
132622         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
132623         on i386, x86_64, ia64.
132624         * tests/test-vasnprintf-posix.c: Include float.h.
132625         (LDBL80_WORDS): New macro.
132626         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
132627         on i386, x86_64, ia64.
132628         * tests/test-vasprintf-posix.c: Include float.h.
132629         (LDBL80_WORDS): New macro.
132630         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
132631         on i386, x86_64, ia64.
132632         * tests/test-snprintf-posix.c: Include float.h.
132633         * tests/test-sprintf-posix.c: Likewise.
132634         * tests/test-vsnprintf-posix.c: Likewise.
132635         * tests/test-vsprintf-posix.c: Likewise.
132637 2007-06-05  Bruno Haible  <bruno@clisp.org>
132639         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
132640         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
132641         non-IEEE numbers on i386, x86_64, ia64.
132642         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
132643         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
132644         * tests/test-isnanl.h: Include float.h.
132645         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
132647 2007-06-05  Bruno Haible  <bruno@clisp.org>
132649         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
132650         also the %a / %A. Handle the %a / %A code before this extra handling.
132652 2007-06-05  Bruno Haible  <bruno@clisp.org>
132654         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
132655         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
132657 2007-06-05  Bruno Haible  <bruno@clisp.org>
132659         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
132660         typo in variable name.
132662 2007-06-05  Eric Blake  <ebb9@byu.net>
132664         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
132665         Reported by Simon Josefsson.
132667 2007-06-04  Bruno Haible  <bruno@clisp.org>
132669         Avoid test failures on some PowerPC platforms.
132670         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
132671         Define differently for PowerPC.
132672         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
132673         Reported by Gary V. Vaughan <gary@gnu.org>.
132675 2007-06-02  Bruno Haible  <bruno@clisp.org>
132677         Fix test-stdint failure on FreeBSD/ia64.
132678         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
132679         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
132680         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
132681         * doc/headers/stdint.texi: Update.
132683 2007-06-01  Bruno Haible  <bruno@clisp.org>
132685         * tests/test-binary-io.c (main): Pass a third argument to open().
132686         Reported by Gary V. Vaughan <gary@gnu.org>.
132688 2007-06-01  Bruno Haible  <bruno@clisp.org>
132690         * doc/functions/frexpl.texi: Update for mingw.
132692 2007-06-01  Bruno Haible  <bruno@clisp.org>
132694         * tests/test-lseek.c (main): Disable test of errno for invalid third
132695         argument.
132696         * doc/functions/lseek.texi: Update.
132697         Reported by Gary V. Vaughan <gary@gnu.org>.
132699 2007-05-28  Bruno Haible  <bruno@clisp.org>
132701         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
132703 2007-05-31  Eric Blake  <ebb9@byu.net>
132705         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
132706         cross compiling.
132708 2007-05-30  Eric Blake  <ebb9@byu.net>
132709         and Bruno Haible  <bruno@clisp.org>
132711         Work around mingw test failures exposed by m4-1.4.9b.
132712         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
132713         * tests/test-unistd.c: Disable uid_t and git_t tests for the
132714         moment.
132716 2007-05-30  Bruno Haible  <bruno@clisp.org>
132718         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
132719         assuming that they are closed. Needed on HP-UX 11.
132721 2007-05-29  Bruno Haible  <bruno@clisp.org>
132723         Fix a problem with #include_next.
132724         * lib/dirent_.h: Split the double-inclusion guard.
132725         * lib/fcntl_.h: Likewise.
132726         * lib/float_.h: Likewise.
132727         * lib/iconv_.h: Likewise.
132728         * lib/inttypes_.h: Likewise.
132729         * lib/locale_.h: Likewise.
132730         * lib/math_.h: Likewise.
132731         * lib/netinet_in_.h: Likewise.
132732         * lib/search_.h: Likewise.
132733         * lib/signal_.h: Likewise.
132734         * lib/stdint_.h: Likewise.
132735         * lib/stdio_.h: Likewise.
132736         * lib/stdlib_.h: Likewise.
132737         * lib/string_.h: Likewise.
132738         * lib/sys_select_.h: Likewise.
132739         * lib/sys_socket_.h: Likewise.
132740         * lib/sys_stat_.h: Likewise.
132741         * lib/sys_time_.h: Likewise.
132742         * lib/sysexits_.h: Likewise.
132743         * lib/time_.h: Likewise.
132744         * lib/unistd_.h: Likewise.
132745         * lib/wchar_.h: Likewise.
132746         * lib/wctype_.h: Likewise.
132748 2007-05-29  Bruno Haible  <bruno@clisp.org>
132750         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
132751         for the moment.
132753 2007-05-29  Bruno Haible  <bruno@clisp.org>
132755         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
132756         invocation.
132757         Reported by Eric Blake.
132759 2007-05-29  Bruno Haible  <bruno@clisp.org>
132761         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
132762         compiling case.
132764 2007-05-29  Eric Blake  <ebb9@byu.net>
132765             Bruno Haible  <bruno@clisp.org>
132767         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
132768         cross compiles.
132770 2007-05-28  Eric Blake  <ebb9@byu.net>
132772         * modules/closein-tests (test_closein_LDADD): Support test on
132773         cygwin with libtool.
132775 2007-05-28  Bruno Haible  <bruno@clisp.org>
132777         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
132778         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
132779         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
132780         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
132781         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
132782         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
132783         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
132784         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
132785         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
132787 2007-05-28  Eric Blake  <ebb9@byu.net>
132789         Unconditionally include <config.h> in unit tests.
132790         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
132791         * tests/test-allocsa.c, tests/test-arcfour.c,
132792         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
132793         tests/test-array_list.c, tests/test-array_oset.c,
132794         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
132795         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
132796         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
132797         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
132798         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
132799         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
132800         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
132801         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
132802         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
132803         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
132804         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
132805         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
132806         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
132807         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
132808         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
132809         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
132810         test-md5.c, test-memmem.c, test-printf-posix.c,
132811         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
132812         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
132813         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
132814         test-strcasestr.c, test-striconv.c, test-striconveh.c,
132815         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
132816         test-vasnprintf-posix2.c, test-vasnprintf.c,
132817         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
132818         test-vfprintf-posix.c, test-vprintf-posix.c,
132819         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
132820         test-xvasprintf.c: Likewise.
132822 2007-05-28  Bruno Haible  <bruno@clisp.org>
132824         * gnulib-tool (func_import): Remember the --with-tests command-line
132825         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
132826         Reported by Eric Blake.
132828 2007-05-28  Bruno Haible  <bruno@clisp.org>
132830         * modules/ftell-tests: New file.
132831         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
132832         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
132834         * lib/ftell.c: New file.
132835         * modules/ftell: New file.
132836         * m4/ftell.m4: New file.
132837         * doc/functions/ftell.texi: Update.
132838         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
132839         REPLACE_FTELL.
132840         * lib/stdio_.h (rpl_ftell): New declaration.
132841         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
132842         REPLACE_FTELL.
132844 2007-05-28  Eric Blake  <ebb9@byu.net>
132846         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
132848 2007-05-28  Bruno Haible  <bruno@clisp.org>
132850         * modules/fseek-tests: New file.
132851         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
132852         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
132854         * lib/fseek.c: New file.
132855         * modules/fseek: New file.
132856         * m4/fseek.m4: New file.
132857         * doc/functions/fseek.texi: Update.
132858         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
132859         REPLACE_FSEEK.
132860         * lib/stdio_.h (rpl_fseek): New declaration.
132861         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
132862         REPLACE_FSEEK.
132864 2007-05-28  Bruno Haible  <bruno@clisp.org>
132866         * lib/stdio_.h (fflush): More comments.
132868 2007-05-28  Bruno Haible  <bruno@clisp.org>
132870         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
132871         runtime test.
132873 2007-05-28  Eric Blake  <ebb9@byu.net>
132875         Improve lseek module.
132876         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
132877         * lib/unistd_.h (lseek): Scale back link warning message.
132878         * tests/test-lseek.c: Beef up test.
132879         * tests/test-lseek.sh: Exercise more facets of lseek.
132880         Reported by Bruno Haible.
132882 2007-05-28  Bruno Haible  <bruno@clisp.org>
132884         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
132885         to define.
132887 2007-05-27  Bruno Haible  <bruno@clisp.org>
132889         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
132891 2007-05-27  Bruno Haible  <bruno@clisp.org>
132893         * modules/openmp: New file.
132894         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
132895         Noah Misch.
132897 2007-05-26  Bruno Haible  <bruno@clisp.org>
132899         * modules/chdir-long (Depends-on): Add fchdir.
132900         * modules/chdir-safer (Depends-on): Likewise.
132901         * modules/fts (Depends-on): Likewise.
132902         * modules/fts-lgpl (Depends-on): Likewise.
132903         * modules/openat (Depends-on): Likewise.
132904         * modules/savewd (Depends-on): Likewise.
132906 2007-05-24  Eric Blake  <ebb9@byu.net>
132908         Fix lseek on mingw.
132909         * modules/lseek: New module.
132910         * m4/lseek.m4: New file.
132911         * lib/lseek.c: New file.
132912         * modules/lseek-tests: New file.
132913         * tests/test-lseek.c: New file.
132914         * tests/test-lseek.sh: New file.
132915         * MODULES.html.sh: Document lseek module.
132916         * modules/fflush (Depends-on): Add lseek, fseeko.
132917         * modules/fseeko (Depends-on): Likewise.
132918         * modules/ftello (Depends-on): Likewise.
132919         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
132920         broken.
132921         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
132922         broken.
132923         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
132924         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
132925         * lib/ftello.c (rpl_ftello): Likewise.
132926         * tests/test-fseeko.c (main): Test this.
132927         * tests/test-fseeko.sh: Likewise.
132928         * tests/test-ftello.c (main): Likewise.
132929         * tests/test-ftello.sh: Likewise.
132930         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
132931         implies replacing fseek.
132932         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
132933         HAVE_FTELLO.
132934         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
132935         * modules/unistd (Makefile.am): Likewise.
132936         * lib/unistd_.h (lseek): Declare a replacement.
132937         * doc/functions/lseek.texi (lseek): Document this fix.
132938         * doc/functions/fseek.texi (fseek): Likewise.
132939         * doc/functions/ftell.texi (ftell): Likewise.
132941 2007-05-24  Bruno Haible  <bruno@clisp.org>
132943         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
132944         in the printed representation of a NaN.
132945         * tests/test-vasprintf-posix.c (test_function): Likewise.
132946         * tests/test-snprintf-posix.h (test_function): Likewise.
132947         * tests/test-sprintf-posix.h (test_function): Likewise.
132948         Reported by Eric Blake.
132950 2007-05-23  Eric Blake  <ebb9@byu.net>
132952         Fix fseeko/ftello on cygwin 1.5.24.
132953         * doc/functions/fseeko.texi (fseeko): Document the fix.
132954         * doc/functions/ftello.texi (ftello): Document the fix.
132955         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
132956         * doc/functions/stdout.text (stdout): New file.
132957         * doc/functions/stderr.text (stderr): New file.
132958         * doc/gnulib.texi (Function Substitutes): Use new files.
132959         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
132960         prior to 1.7.0.
132961         * tests/test-ftello.c (main): Likewise for ftello.
132962         * tests/test-fseeko.sh: New file.
132963         * tests/test-ftello.sh: New file.
132964         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
132965         with seekable stdin.
132966         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
132967         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
132968         (gl_REPLACE_FSEEKO): New macro.
132969         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
132970         * modules/fseeko (Files): Distribute fseeko.c.
132971         * modules/ftello (Files): Distribute ftello.c.
132972         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
132973         mode.
132974         * lib/ftello.c (rpl_ftello): New file.
132975         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
132976         fseeko, ftello.
132977         (gl_STDIN_LARGE_OFFSET): New macro.
132978         * modules/stdio (Makefile.am): Perform the replacement.
132979         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
132981 2007-05-23  Bruno Haible  <bruno@clisp.org>
132983         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
132984         GNULIB_POSIXCHECK is defined.
132986 2007-05-21  Bruno Haible  <bruno@clisp.org>
132988         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
132989         Check also the output for NaN arguments. When cross-compiling, guess
132990         no on IRIX.
132991         * lib/vasnprintf.c: Update comments.
132992         * tests/test-vasnprintf-posix.c (strisnan): New function.
132993         (test_function): Use it.
132994         * tests/test-vasprintf-posix.c (strisnan): New function.
132995         (test_function): Use it.
132996         * tests/test-snprintf-posix.h (strisnan): New function.
132997         (test_function): Use it.
132998         * tests/test-sprintf-posix.h (strisnan): New function.
132999         (test_function): Use it.
133000         Reported by Eric Blake.
133002 2007-05-20  Bruno Haible  <bruno@clisp.org>
133004         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
133005         numbers that fails on BeOS.
133006         * doc/functions/frexpl.texi: Update.
133008 2007-05-20  Jim Meyering  <jim@meyering.net>
133010         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
133011         forced upon us by glibc-2.6.
133013 2007-05-20  Bruno Haible  <bruno@clisp.org>
133015         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
133016         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
133017         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
133018         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
133019         NEED_PRINTF_INFINITE.
133020         (is_infinitel): New function.
133021         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
133022         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
133023         gl_PREREQ_VASNPRINTF_INFINITE.
133024         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
133025         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
133026         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
133027         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
133028         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
133029         gl_PREREQ_VASNPRINTF_INFINITE.
133030         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
133031         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
133032         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
133033         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
133034         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
133035         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
133036         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
133037         * doc/functions/fprintf.texi: Update.
133038         * doc/functions/printf.texi: Update.
133039         * doc/functions/snprintf.texi: Update.
133040         * doc/functions/sprintf.texi: Update.
133041         * doc/functions/vfprintf.texi: Update.
133042         * doc/functions/vprintf.texi: Update.
133043         * doc/functions/vsnprintf.texi: Update.
133044         * doc/functions/vsprintf.texi: Update.
133046 2007-05-20  Bruno Haible  <bruno@clisp.org>
133048         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
133049         was not found in libc.
133050         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
133052 2007-05-20  Bruno Haible  <bruno@clisp.org>
133054         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
133055         printed as "-nan" instead of "nan".
133056         * tests/test-vasprintf-posix.c (test_function): Likewise.
133057         * tests/test-snprintf-posix.h (test_function): Likewise.
133058         * tests/test-sprintf-posix.h (test_function): Likewise.
133059         Needed for HP-UX 11.
133061 2007-05-20  Jim Meyering  <jim@meyering.net>
133063         Fix buggy test for the fchownat-deref bug.
133064         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
133065         symlink required for the run-test.  Without it, this test would
133066         always declare that fchownat doesn't work, and client code would
133067         unnecessarily use the replacement function with fixed libc.
133068         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
133069         Reported by Greg Schafer.
133071 2007-05-19  Bruno Haible  <bruno@clisp.org>
133073         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
133074         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
133075         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
133076         Needed for IRIX 6.5 and Solaris 2.5.1.
133078 2007-05-19  Bruno Haible  <bruno@clisp.org>
133080         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
133081         (test_function): Skip tests involving -0.0 on platforms where
133082         -0.0 = 0.0.
133083         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
133084         (test_function): Skip tests involving -0.0 on platforms where
133085         -0.0 = 0.0.
133086         * tests/test-snprintf-posix.h (have_minus_zero): New function.
133087         (test_function): Skip tests involving -0.0 on platforms where
133088         -0.0 = 0.0.
133089         * tests/test-sprintf-posix.h (have_minus_zero): New function.
133090         (test_function): Skip tests involving -0.0 on platforms where
133091         -0.0 = 0.0.
133092         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
133093         tests.
133094         * tests/test-printf-posix.h (test_function): Likewise.
133095         * tests/test-printf-posix.output: Remove all -0.0 related results.
133096         Needed for IRIX 6.5.
133098 2007-05-19  Bruno Haible  <bruno@clisp.org>
133100         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
133101         printed as "nan0x7fffffff" instead of "nan".
133102         * tests/test-vasprintf-posix.c (test_function): Likewise.
133103         * tests/test-snprintf-posix.h (test_function): Likewise.
133104         * tests/test-sprintf-posix.h (test_function): Likewise.
133105         * tests/test-fprintf-posix.h (NaN): Remove macro.
133106         (test_function): Remove all NaN related tests.
133107         * tests/test-printf-posix.h (NaN): Remove macro.
133108         (test_function): Remove all NaN related tests.
133109         * tests/test-printf-posix.output: Remove all NaN related results.
133110         Needed for IRIX 6.5.
133112 2007-05-19  Bruno Haible  <bruno@clisp.org>
133114         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
133115         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
133117 2007-05-19  Bruno Haible  <bruno@clisp.org>
133119         * lib/float_.h: New file.
133120         * m4/float_h.m4: New file.
133121         * modules/float: New file.
133122         * modules/isnanl (Dependencies): Add float.
133123         * modules/isnanl-nolibm (Dependencies): Likewise.
133124         * modules/mathl (Dependencies): Likewise.
133125         * modules/printf-frexpl (Dependencies): Likewise.
133126         * modules/signbit (Dependencies): Likewise.
133127         * modules/vasnprintf (Dependencies): Likewise.
133128         * doc/headers/float.texi: Update.
133130 2007-05-19  Jim Meyering  <jim@meyering.net>
133132         * lib/utimens.c (gl_futimens): Rename from futimens,
133133         now that glibc-2.6 declares futimens.
133134         * lib/utimens.h: Likewise.
133136 2007-05-19  Bruno Haible  <bruno@clisp.org>
133138         Avoid test failures on mingw.
133139         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
133140         * tests/test-printf-posix.sh: Likewise.
133141         * tests/test-vfprintf-posix.sh: Likewise.
133142         * tests/test-vprintf-posix.sh: Likewise.
133144 2007-05-19  Bruno Haible  <bruno@clisp.org>
133146         Fix *printf result for NaN, Inf, -0.0 on mingw.
133147         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
133148         * lib/vasnprintf.c: Include math.h and isnan.h.
133149         (is_infinite_or_zero): New function.
133150         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
133151         values in the %f, %F, %e, %E, %g, %G directives.
133152         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
133153         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
133154         gl_PRINTF_INFINITE and test its result. Invoke
133155         gl_PREREQ_VASNPRINTF_INFINITE.
133156         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
133157         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
133158         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
133159         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
133160         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
133161         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
133162         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
133163         * doc/functions/fprintf.texi: Update.
133164         * doc/functions/printf.texi: Update.
133165         * doc/functions/snprintf.texi: Update.
133166         * doc/functions/sprintf.texi: Update.
133167         * doc/functions/vfprintf.texi: Update.
133168         * doc/functions/vprintf.texi: Update.
133169         * doc/functions/vsnprintf.texi: Update.
133170         * doc/functions/vsprintf.texi: Update.
133172 2007-05-19  Bruno Haible  <bruno@clisp.org>
133174         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
133175         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
133176         Instead of multiplying with 10^k, set extra_zeroes to k.
133177         (scale10_round_long_double): Remove function.
133179 2007-05-18  Bruno Haible  <bruno@clisp.org>
133181         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
133182         introduced on 2007-05-06.
133184 2007-05-18  Bruno Haible  <bruno@clisp.org>
133186         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
133187         %g directives.
133188         * tests/test-vasprintf-posix.c (test_function): Likewise.
133189         * tests/test-snprintf-posix.h (test_function): Likewise.
133190         * tests/test-sprintf-posix.h (test_function): Likewise.
133192 2007-05-18  Bruno Haible  <bruno@clisp.org>
133194         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
133195         (strmatch): New function.
133196         (test_function): Test the %f directive on numbers of various exponents.
133197         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
133198         (strmatch): New function.
133199         (test_function): Test the %f directive on numbers of various exponents.
133200         * tests/test-snprintf-posix.h (strmatch): New function.
133201         (test_function): Test the %f directive on numbers of various exponents.
133202         * tests/test-sprintf-posix.h (strmatch): New function.
133203         (test_function): Test the %f directive on numbers of various exponents.
133204         * tests/test-snprintf-posix.c (SIZEOF): New macro.
133205         * tests/test-sprintf-posix.c (SIZEOF): New macro.
133206         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
133207         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
133209 2007-05-18  Bruno Haible  <bruno@clisp.org>
133211         Add support for 'long double' number output.
133212         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
133213         * lib/vasnprintf.c: Include math.h and float+.h.
133214         (mp_limb_t): New type.
133215         (GMP_LIMB_BITS): New macro.
133216         (mp_twolimb_t): New type.
133217         (GMP_TWOLIMB_BITS): New macro.
133218         (mpn_t): New type.
133219         (multiply, divide, convert_to_decimal, decode_long_double,
133220         scale10_round_long_double, scale10_round_decimal_long_double,
133221         floorlog10l): New functions.
133222         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
133223         for the %f, %F, %e, %E, %g, %G directives.
133224         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
133225         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
133226         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
133227         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
133228         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
133229         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
133230         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
133231         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
133232         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
133233         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
133234         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
133235         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
133236         * modules/snprintf-posix (Depends-on): Likewise.
133237         * modules/sprintf-posix (Depends-on): Likewise.
133238         * modules/vasnprintf-posix (Depends-on): Likewise.
133239         * modules/vasprintf-posix (Depends-on): Likewise.
133240         * modules/vfprintf-posix (Depends-on): Likewise.
133241         * modules/vsnprintf-posix (Depends-on): Likewise.
133242         * modules/vsprintf-posix (Depends-on): Likewise.
133243         * modules/vasnprintf (Files): Add lib/float+.h.
133244         * doc/functions/fprintf.texi: Update.
133245         * doc/functions/printf.texi: Update.
133246         * doc/functions/snprintf.texi: Update.
133247         * doc/functions/sprintf.texi: Update.
133248         * doc/functions/vfprintf.texi: Update.
133249         * doc/functions/vprintf.texi: Update.
133250         * doc/functions/vsnprintf.texi: Update.
133251         * doc/functions/vsprintf.texi: Update.
133253 2007-05-18  Bruno Haible  <bruno@clisp.org>
133255         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
133257 2007-05-18  Bruno Haible  <bruno@clisp.org>
133259         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
133260         for printing 64-bit integers. Needed for mingw.
133262 2007-05-18  Bruno Haible  <bruno@clisp.org>
133264         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
133265         gl_FUNC_FREXPL_WORKS.
133266         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
133268 2007-05-18  Bruno Haible  <bruno@clisp.org>
133270         * modules/frexpl-nolibm-tests: New file.
133272         * modules/frexpl-nolibm: New file.
133273         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
133275 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
133277         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
133278         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
133279         GCC 4.2, which otherwise issues a lot of warnings.
133280         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
133281         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
133282         Likewise.
133283         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
133284         * modules/iconv_open (iconv.h): Likewise.
133285         * modules/locale (locale.h): Likewise.
133286         * modules/netinet_in (netinet/in.h): Likewise.
133287         * modules/sys_select (sys_select.h): Likewise.
133288         * modules/sys_socket (sys/socket.h): Likewise.
133289         * modules/sys_stat (sys/stat.h): Likewise.
133290         * modules/sysexits (sysexits.h): Likewise.
133291         * modules/unistd (unistd.h): Likewise.
133293 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133295         * modules/closein-tests (Makefile.am): Distribute
133296         `test-closein.sh'.
133298 2007-05-17  Bruno Haible  <bruno@clisp.org>
133300         * tests/test-printf-posix.output: Renamed from
133301         tests/test-fprintf-posix.out.
133302         * modules/fprintf-posix-tests: Update.
133303         * modules/printf-posix-tests: Update.
133304         * modules/vfprintf-posix-tests: Update.
133305         * modules/vprintf-posix-tests: Update.
133306         * tests/test-fprintf-posix.sh: Update.
133307         * tests/test-printf-posix.sh: Update.
133308         * tests/test-vfprintf-posix.sh: Update.
133309         * tests/test-vprintf-posix.sh: Update.
133310         Reported by Ralf Wildenhues.
133312 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
133314         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
133315         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
133316         GCC 4.2, which otherwise issues a lot of warnings.
133317         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
133318         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
133319         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
133320         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
133321         it should no longer be needed.
133322         * lib/string_.h: Likewise.
133323         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
133324         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
133325         * modules/inttypes (inttypes.h): Likewise.
133326         * modules/math (math.h): Likewise.
133327         * modules/search (search.h): Likewise.
133328         * modules/signal (signal.h): Likewise.
133329         * modules/stdint (stdint.h): Likewise.
133330         * modules/stdio (stdio.h): Likewise.
133331         * modules/stdlib (stdlib.h): Likewise.
133332         * modules/string (string.h): Likewise.
133333         * modules/sys_time (sys/time.h): Likewise.
133334         * modules/time (time.h): Likewise.
133335         * modules/wchar (wchar.h): Likewise.
133336         * modules/wctype (wtype.h): Likewise.
133338 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
133340         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
133342 2007-05-13  Bruno Haible  <bruno@clisp.org>
133344         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
133345         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
133346         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
133347         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
133348         (gl_PREREQ_STRTOK_R): Don't require it here.
133350 2007-05-13  Bruno Haible  <bruno@clisp.org>
133352         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
133353         when used in C++ mode.
133355 2007-05-12  Bruno Haible  <bruno@clisp.org>
133357         * lib/linebuffer.h: Tweak doc.
133358         * lib/linebuffer.c: Likewise.
133360 2007-05-12  James Youngman  <jay@gnu.org>
133362         * lib/linebuffer.c (readlinebuffer_delim): New function,
133363         like readlinebuffer, but use a caller-specified delimiter.
133364         (readlinebuffer): Just call readlinebuffer_delim with '\n'
133365         as the delimiter.
133366         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
133368 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
133370         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
133371         * modules/openat (Files): Remove openat-die.c.
133372         (Depends-on): Add openat-die.
133373         * modules/openat-die: New module.
133375 2007-05-06  Bruno Haible  <bruno@clisp.org>
133377         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
133378         Update with info about Cygwin.
133379         * doc/functions/fprintf.texi: Update.
133380         * doc/functions/printf.texi: Update.
133381         * doc/functions/snprintf.texi: Update.
133382         * doc/functions/sprintf.texi: Update.
133383         * doc/functions/vfprintf.texi: Update.
133384         * doc/functions/vprintf.texi: Update.
133385         * doc/functions/vsnprintf.texi: Update.
133386         * doc/functions/vsprintf.texi: Update.
133387         Reported by Eric Blake.
133389 2007-05-06  Bruno Haible  <bruno@clisp.org>
133391         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
133392         padding ourselves for the floating-point directives.
133393         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
133394         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
133395         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
133396         gl_PRINTF_FLAG_ZERO and test its result. Invoke
133397         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
133398         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
133399         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
133400         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
133401         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
133402         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
133403         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
133404         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
133405         * tests/test-snprintf-posix.h (test_function): Also check the width
133406         and some flags in the %f directive.
133407         * tests/test-sprintf-posix.h (test_function): Likewise.
133408         * tests/test-vasnprintf-posix.c (test_function): Likewise.
133409         * tests/test-vasprintf-posix.c (test_function): Likewise.
133410         * doc/functions/fprintf.texi: Update.
133411         * doc/functions/printf.texi: Update.
133412         * doc/functions/snprintf.texi: Update.
133413         * doc/functions/sprintf.texi: Update.
133414         * doc/functions/vfprintf.texi: Update.
133415         * doc/functions/vprintf.texi: Update.
133416         * doc/functions/vsnprintf.texi: Update.
133417         * doc/functions/vsprintf.texi: Update.
133419 2007-05-06  Bruno Haible  <bruno@clisp.org>
133421         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
133422         pass the ' flag character to sprintf or snprintf.
133423         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
133424         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
133425         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
133426         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
133427         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
133428         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
133429         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
133430         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
133431         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
133432         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
133433         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
133434         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
133435         * tests/test-snprintf-posix.h (test_function): Also check the grouping
133436         flag.
133437         * tests/test-sprintf-posix.h (test_function): Likewise.
133438         * tests/test-vasnprintf-posix.c (test_function): Likewise.
133439         * tests/test-vasprintf-posix.c (test_function): Likewise.
133440         * doc/functions/fprintf.texi: Update.
133441         * doc/functions/printf.texi: Update.
133442         * doc/functions/snprintf.texi: Update.
133443         * doc/functions/sprintf.texi: Update.
133444         * doc/functions/vfprintf.texi: Update.
133445         * doc/functions/vprintf.texi: Update.
133446         * doc/functions/vsnprintf.texi: Update.
133447         * doc/functions/vsprintf.texi: Update.
133449 2007-05-01  Bruno Haible  <bruno@clisp.org>
133451         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
133453 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
133455         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
133456         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
133458 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
133460         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
133461         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
133462         <http://lists.gnu.org/r/bug-gnulib/2007-05/msg00021.html>.
133464 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
133466         * lib/argp-help.c (struct hol_entry): New member `ord'.
133467         (HOL_ENTRY_PTRCMP): Use ord for comparison
133468         (hol_sort): Initialize ord.
133470 2007-05-01  Bruno Haible  <bruno@clisp.org>
133472         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
133473         Reported by Eric Blake.
133474         * doc/gnulib.texi (Function Substitutes): Update.
133476 2007-05-01  Bruno Haible  <bruno@clisp.org>
133478         * doc/functions.texi: Remove file, now redundant through
133479         doc/functions/*.texi.
133481 2007-05-01  Bruno Haible  <bruno@clisp.org>
133483         * modules/argp (Depends-on): Add sleep.
133485 2007-05-01  Bruno Haible  <bruno@clisp.org>
133487         * modules/sleep-tests: New file.
133488         * tests/test-sleep.c: New file.
133490         * modules/sleep: New file.
133491         * lib/sleep.c: New file.
133492         * m4/sleep.m4: New file.
133493         * lib/unistd_.h (sleep): New declaration.
133494         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
133495         HAVE_SLEEP.
133496         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
133497         * doc/functions/sleep.texi: Document the sleep module.
133499 2007-05-01  Bruno Haible  <bruno@clisp.org>
133501         * lib/sigprocmask.h: Remove file.
133502         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
133503         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
133504         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
133505         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
133506         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
133507         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
133508         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
133509         HAVE_SIGSET_T as a shell variable.
133510         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
133511         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
133512         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
133513         (Depends-on): Add signal. Remove verify.
133514         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
133515         (Include): Mention <signal.h> instead of sigprocmask.h.
133516         * NEWS: Mention the change.
133517         * lib/fatal-signal.c: Don't include sigprocmask.h.
133519 2007-05-01  Bruno Haible  <bruno@clisp.org>
133521         * modules/signal: New file.
133522         * lib/signal_.h: New file.
133523         * m4/signal_h.m4: New file.
133525 2007-05-01  Bruno Haible  <bruno@clisp.org>
133527         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
133528         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
133529         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
133530         HAVE_WCTYPE_CTMP_BUG into wctype.h.
133532 2007-05-01  Bruno Haible  <bruno@clisp.org>
133534         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
133535         configure time.
133536         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
133537         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
133538         * modules/sys_stat (Makefile.am): Substitute their values into
133539         sys/stat.h.
133541 2007-05-01  Bruno Haible  <bruno@clisp.org>
133543         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
133544         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
133545         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
133547 2007-05-01  Bruno Haible  <bruno@clisp.org>
133549         * doc/header/assert.texi: Undo last change: don't mention the gnulib
133550         'assert' module here.
133552 2007-05-01  Bruno Haible  <bruno@clisp.org>
133554         * doc/functions/*.texi: New files.
133555         * doc/functions/google-ranking.txt: New file.
133556         * doc/gnulib.texi (Function Substitutes): New chapter.
133557         (ctime, inet_ntoa): Remove sections.
133558         * doc/ctime.texi: Remove file.
133559         * doc/inet_ntoa.texi: Remove file.
133560         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
133561         dependencies.
133562         (%.info): New rule, specifying a --reference-limit.
133564 2007-05-01  Bruno Haible  <bruno@clisp.org>
133566         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
133568 2007-05-01  Bruno Haible  <bruno@clisp.org>
133570         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
133571         the portability of 'mkdir' to mingw systems.
133573 2007-05-01  Bruno Haible  <bruno@clisp.org>
133575         * doc/headers/google-ranking.txt: New file.
133577 2007-04-30  Eric Blake  <ebb9@byu.net>
133579         Prefer fseeko to fseek.
133580         * modules/getpass (Depends-on): Add fseeko.
133581         * lib/getpass.c (getpass): Use fseeko, not fseek.
133583 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
133585         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
133586         assumes the sorting is stable, while most qsort implementations
133587         are not.  Use argument addresses to ensure they never compare as
133588         equal.
133590         * tests/test-argp-2.sh (usage-indent test): Fix output
133591         (func_compare): Restore diff options
133592         * tests/test-argp.c: Restore #include "progname.h"
133594 2007-04-29  Bruno Haible  <bruno@clisp.org>
133596         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
133597         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
133598         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
133599         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
133600         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
133601         (configure.ac): Define CHECK_SNPRINTF_POSIX.
133602         (TESTS, check_PROGRAMS): Add test-snprintf.
133603         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
133604         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
133605         (TESTS, check_PROGRAMS): Add test-vsnprintf.
133606         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
133607         assertions that fail on HP-UX, OSF/1, or IRIX.
133608         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
133610 2007-04-29  Bruno Haible  <bruno@clisp.org>
133612         * MODULES.html.sh (posix_functions): Remove 'contents'.
133614 2007-04-29  Karl Berry  <karl@gnu.org>
133616         * config/srclist.txt (gendocs_template_min): new entry.
133618 2007-04-29  Bruno Haible  <bruno@clisp.org>
133620         Work around fpurge bug on BSD systems.
133621         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
133622         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
133623         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
133624         fpurge to rpl_fpurge if the system already has this function.
133625         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
133626         the case where the system already has this function. Correct invariants
133627         on BSD systems.
133628         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
133629         BSD systems.
133631 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
133633         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
133634         proposed by Sven Verdoolaege.
133636         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
133637         options.
133638         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
133639         (usage and help tests): Update
133641 2007-04-29  Bruno Haible  <bruno@clisp.org>
133643         * tests/test-fflush.c (main): Use a file of size 17, not 10.
133644         Print more information in case of failure. Disable a test on BeOS.
133646 2007-04-29  Bruno Haible  <bruno@clisp.org>
133648         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
133649         This helps debugging on systems on which no gdb is available.
133651 2007-04-29  Bruno Haible  <bruno@clisp.org>
133653         * lib/freading.h: Improve comments.
133654         * lib/fwriting.h: Likewise.
133655         * tests/test-freading.c (main): Don't check freading immediately after
133656         repositioning. Needed for glibc.
133658 2007-04-29  Bruno Haible  <bruno@clisp.org>
133660         * lib/freading.c (freading): Trivial simplification.
133662 2007-04-28  Bruno Haible  <bruno@clisp.org>
133664         * tests/test-fwriting.c (main): Also test the interaction between
133665         fflush and fwriting.
133666         * modules/fwriting-tests (Depends-on): Add fflush.
133668         * tests/test-freading.c (main): Also test the interaction between
133669         fflush and freading.
133670         * modules/freading-tests (Depends-on): Add fflush.
133672 2007-04-28  Bruno Haible  <bruno@clisp.org>
133674         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
133675         fseeko and ftello.
133676         Suggested by Eric Blake.
133678 2007-04-28  Jim Meyering  <jim@meyering.net>
133680         Avoid false-negative in gl_STDINT_H's C99 conformance test.
133681         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
133682         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
133684 2007-04-27  Eric Blake  <ebb9@byu.net>
133686         * doc/headers/assert.texi (assert.h): Document assert module use.
133688 2007-04-27  Bruno Haible  <bruno@clisp.org>
133690         * doc/headers/*.texi: New files.
133691         * doc/gnulib.texi (Header File Substitutes): New chapter.
133692         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
133693         dependencies.
133694         (standards.info ,standards.html, standards.dvi): Update dependencies.
133695         (mostlyclean, clean): New targets.
133697 2007-04-27  Bruno Haible  <bruno@clisp.org>
133699         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
133700         * modules/sysexits (Files, Makefile.am): Update.
133702         * lib/sys_socket_.h: Renamed from lib/socket_.h.
133703         * modules/sys_socket (Files, Makefile.am): Update.
133705         * lib/sys_stat_.h: Renamed from lib/stat_.h.
133706         * modules/sys_stat (Files, Makefile.am): Update.
133708 2007-04-27  Eric Blake  <ebb9@byu.net>
133710         * lib/freading.h: Improve comments.
133711         * lib/fwriting.h: Likewise.
133712         * lib/fflush.c: Likewise.
133714         Fix closein for mingw.
133715         * modules/closein-tests: Add tests for closein.
133716         * tests/test-closein.c: New file.
133717         * tests/test-closein.sh: Likewise.
133718         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
133719         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
133721 2007-04-27  Bruno Haible  <bruno@clisp.org>
133723         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
133724         version is < 6.
133725         * lib/math_.h [__DECC]: Likewise.
133726         * lib/stdio_.h [__DECC]: Likewise.
133727         * lib/stdlib_.h [__DECC]: Likewise.
133728         * lib/string_.h [__DECC]: Likewise.
133729         * lib/time_.h [__DECC]: Likewise.
133730         * lib/wchar_.h [__DECC]: Likewise.
133731         * lib/wctype_.h [__DECC]: Likewise.
133733 2007-04-27  Bruno Haible  <bruno@clisp.org>
133735         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
133737 2007-04-27  Bruno Haible  <bruno@clisp.org>
133739         * lib/fflush.c: Add comments.
133740         * modules/fpurge-tests (Depends-on): Add fflush.
133741         * modules/freadable-tests (Depends-on): Likewise.
133742         * modules/fwritable-tests (Depends-on): Likewise.
133744 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
133746         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
133747         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
133748         Report by Bruno Haible <bruno@clisp.org>.
133750 2007-04-26  Eric Blake  <ebb9@byu.net>
133752         Fix fflush on mingw.
133753         * modules/fflush (Depends-on): Add freading.
133754         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
133755         but unread data.
133757 2007-04-26  Eric Blake  <ebb9@byu.net>
133758         and Bruno Haible  <bruno@clisp.org>
133760         Implement freading and fwriting.
133761         * lib/freading.c: New file.
133762         * lib/freading.h: Likewise.
133763         * m4/freading.m4: Likewise.
133764         * modules/freading: Likewise.
133765         * modules/freading-tests: Likewise.
133766         * tests/test-freading.c: Likewise.
133767         * lib/fwriting.c: New file.
133768         * lib/fwriting.h: Likewise.
133769         * m4/fwriting.m4: Likewise.
133770         * modules/fwriting: Likewise.
133771         * modules/fwriting-tests: Likewise.
133772         * tests/test-fwriting.c: Likewise.
133773         * MODULES.html.sh (File stream based Input/Output): Mention them.
133775 2007-04-26  Bruno Haible  <bruno@clisp.org>
133777         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
133778         'long' when we assume it.
133779         Suggested by Eric Blake.
133781 2007-04-26  Bruno Haible  <bruno@clisp.org>
133783         Ensure fseeko, ftello are declared on glibc systems.
133784         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
133785         * modules/fseeko (configure.ac-early): Likewise.
133786         * modules/ftello (configure.ac-early): Likewise.
133787         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
133788         AC_FUNC_FSEEKO for this.
133789         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
133790         (gl_CHECK_FSEEKO): Remove macro.
133792 2007-04-26  Bruno Haible  <bruno@clisp.org>
133794         * tests/test-fflush.c (main): Also check the ftell result after
133795         fflush and fseek/fseeko.
133796         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
133797         file descriptor position cache in the stream.
133798         * lib/fseeko.c (rpl_fseeko): Likewise.
133800 2007-04-26  Bruno Haible  <bruno@clisp.org>
133802         * modules/fflush-tests (Depends-on): Add fseeko.
133804 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
133805             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
133807         * lib/argz_.h: ensure error_t definition is obtained in same
133808         mechanism system argz.h would have.
133809         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
133810         argz facilities are known bad.  Err on the side of caution if
133811         cross-compiling.
133813 2007-04-25  Eric Blake  <ebb9@byu.net>
133815         * lib/fpurge.c (includes): Use stdlib.h for free.
133816         * tests/test-fflush.c (main): Also test fflush-fseeko.
133818 2007-04-25  Bruno Haible  <bruno@clisp.org>
133820         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
133821         * lib/fseeko.c: New file.
133822         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
133823         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
133824         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
133825         gl_FUNC_FSEEKO.
133826         (gl_FUNC_FSEEKO): Invoke it.
133827         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
133828         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
133829         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
133831 2007-04-25  Bruno Haible  <bruno@clisp.org>
133833         * modules/fflush (Depends-on): Add ftello.
133835 2007-04-25  Bruno Haible  <bruno@clisp.org>
133837         * modules/ftello-tests: New file.
133838         * tests/test-ftello.c: New file.
133840         * modules/ftello: New file.
133841         * m4/ftello.m4: New file.
133842         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
133843         HAVE_FTELLO.
133844         * lib/stdio_.h (ftello): New declaration.
133845         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
133846         HAVE_FTELLO.
133848 2007-04-25  Bruno Haible  <bruno@clisp.org>
133850         * modules/fseeko-tests: New file.
133851         * tests/test-fseeko.c: New file.
133853         * modules/fseeko: New file.
133854         * m4/fseeko.m4: New file.
133855         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
133856         HAVE_FSEEKO.
133857         * lib/stdio_.h (fseeko): New declaration.
133858         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
133859         HAVE_FSEEKO.
133861 2007-04-25  Bruno Haible  <bruno@clisp.org>
133863         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
133865 2007-04-25  Bruno Haible  <bruno@clisp.org>
133867         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
133868         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
133869         * tests/test-unistd.c: Likewise.
133870         * tests/test-fcntl.c: Likewise.
133872 2007-04-23  Eric Blake  <ebb9@byu.net>
133874         * lib/fflush.c: Fix missing include.
133875         Reported by Bruno Haible.
133877 2007-04-23  Bruno Haible  <bruno@clisp.org>
133879         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
133880         Reported by Eric Blake.
133882 2007-04-23  Bruno Haible  <bruno@clisp.org>
133884         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
133886 2007-04-23  Bruno Haible  <bruno@clisp.org>
133888         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
133890 2007-04-23  Bruno Haible  <bruno@clisp.org>
133892         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
133893         Needed on HP-UX 11.
133895 2007-04-16  Eric Blake  <ebb9@byu.net>
133897         Make fflush rely on fpurge.
133898         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
133899         open coding all variants.
133900         * modules/fflush (Depends-on): Add fpurge and unistd.
133901         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
133902         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
133904         Fix --with-tests compilation on cygwin.
133905         * modules/argmatch-tests (Makefile.am): List gnulib library first
133906         in LDADD.
133907         * modules/argp-tests (Makefile.am): Likewise.
133908         * modules/array-list-tests (Makefile.am): Likewise.
133909         * modules/array-oset-tests (Makefile.am): Likewise.
133910         * modules/avltree-list-tests (Makefile.am): Likewise.
133911         * modules/avltree-oset-tests (Makefile.am): Likewise.
133912         * modules/avltreehash-list-tests (Makefile.am): Likewise.
133913         * modules/carray-list-tests (Makefile.am): Likewise.
133914         * modules/dirname-tests (Makefile.am): Likewise.
133915         * modules/frexp-tests (Makefile.am): Likewise.
133916         * modules/isnanl-tests (Makefile.am): Likewise.
133917         * modules/linked-list-tests (Makefile.am): Likewise.
133918         * modules/linkedhash-list-tests (Makefile.am): Likewise.
133919         * modules/lock-tests (Makefile.am): Likewise.
133920         * modules/rbtree-list-tests (Makefile.am): Likewise.
133921         * modules/rbtree-oset-tests (Makefile.am): Likewise.
133922         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
133923         * modules/tls-tests (Makefile.am): Likewise.
133924         * modules/tsearch-tests (Makefile.am): Likewise.
133925         * modules/xvasprintf-tests (Makefile.am): Likewise.
133927         Fix fpurge for cygwin.
133928         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
133929         value.
133930         * modules/fpurge-tests (Depends-on): Clean up trash.
133932 2007-04-16  Simon Josefsson  <simon@josefsson.org>
133934         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
133936         * m4/autobuild.m4: Re-indent.
133938 2007-04-13  Bruno Haible  <bruno@clisp.org>
133940         * modules/fpurge-tests: New file.
133941         * tests/test-fpurge.c: New file.
133943         * modules/fpurge: New file.
133944         * lib/fpurge.h: New file.
133945         * lib/fpurge.c: New file.
133946         * m4/fpurge.m4: New file.
133948 2007-04-13  Bruno Haible  <bruno@clisp.org>
133950         * modules/fbufmode-tests: New file.
133951         * tests/test-fbufmode.c: New file.
133953         * modules/fbufmode: New file.
133954         * lib/fbufmode.h: New file.
133955         * lib/fbufmode.c: New file.
133956         * m4/fbufmode.m4: New file.
133958 2007-04-13  Bruno Haible  <bruno@clisp.org>
133960         * modules/fwritable-tests: New file.
133961         * tests/test-fwritable.c: New file.
133963         * modules/fwritable: New file.
133964         * lib/fwritable.h: New file.
133965         * lib/fwritable.c: New file.
133966         * m4/fwritable.m4: New file.
133968 2007-04-13  Bruno Haible  <bruno@clisp.org>
133970         * modules/freadable-tests: New file.
133971         * tests/test-freadable.c: New file.
133973         * modules/freadable: New file.
133974         * lib/freadable.h: New file.
133975         * lib/freadable.c: New file.
133976         * m4/freadable.m4: New file.
133978 2007-04-13  Bruno Haible  <bruno@clisp.org>
133980         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
133981         MOSTLYCLEANFILES.
133983 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
133985         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
133986         gzip bootstrap.conf to avoid dragging in i18n machinery.
133987         (gnulib_tool_option): Use it.
133989 2007-04-13  Bruno Haible  <bruno@clisp.org>
133991         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
133992         %F directives.
133993         * tests/test-vasprintf-posix.c (test_function): Likewise.
133994         * tests/test-snprintf-posix.h (test_function): Likewise.
133995         * tests/test-sprintf-posix.h (test_function): Likewise.
133996         * tests/test-fprintf-posix.h (test_function): Likewise.
133997         * tests/test-printf-posix.h (test_function): Likewise.
133998         * tests/test-fprintf-posix.out: Likewise.
134000 2007-04-13  Bruno Haible  <bruno@clisp.org>
134002         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
134003         * modules/tls-tests (configure.ac): Likewise.
134004         Reported by Arto C. Nirkko <anirkko@insel.ch>.
134006 2007-04-13  Bruno Haible  <bruno@clisp.org>
134008         * lib/tls.c (glthread_tls_get): Fix return type.
134009         Patch by Arto C. Nirkko <anirkko@insel.ch>.
134011 2007-04-12  Eric Blake  <ebb9@byu.net>
134013         * modules/gettime (Depends-on): Remove gettime.
134014         Reported by Dmitry V. Levin.
134016 2007-04-12  Bruno Haible  <bruno@clisp.org>
134018         * modules/fflush (Include): Mention <stdio.h>.
134019         * modules/strtoimax (Include): Mention <inttypes.h>.
134020         * modules/strtoumax (Include): Likewise.
134022 2007-04-12  Eric Blake  <ebb9@byu.net>
134024         * .cvsignore: New file.
134025         * .gitignore: Likewise.
134027 2007-04-12  Bruno Haible  <bruno@clisp.org>
134029         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
134030         not before, since $(LDADD) often contains libgnu.a.
134031         * modules/striconv-tests (test_striconv_LDADD): Likewise.
134032         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
134033         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
134034         Needed on Cygwin.
134036 2007-04-12  Eric Blake  <ebb9@byu.net>
134038         Work around glibc's failure to flush stdin on fclose.
134039         * lib/closein.c (close_stdin): Flush stdin before closing.
134041         Work around glibc's failure to reset seekable stdin on exit.
134042         * modules/closein: New module.
134043         * lib/closein.c: New file.
134044         * lib/closein.h: Likewise.
134045         * m4/closein.m4: Likewise.
134046         * MODULES.html.sh (File stream based Input/Output): Document it.
134048 2007-04-12  Simon Josefsson  <simon@josefsson.org>
134050         * gnulib-tool: Rename generated 'autobuild' script to
134051         'do-autobuild' in --create-megatestdir output.
134053         * doc/gnulib.texi (Build robot for gnulib): Fix.
134055 2007-04-12  Simon Josefsson  <simon@josefsson.org>
134057         * modules/sysexits (Depends-on): Add absolute-header.
134059 2007-04-12  Eric Blake  <ebb9@byu.net>
134061         No need to preserve errno on success.
134062         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
134063         Reported by Bruno Haible.
134065 2007-04-12  Simon Josefsson  <simon@josefsson.org>
134067         * MODULES.html.sh (Support for maintaining and releasing
134068         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
134070 2007-04-12  Simon Josefsson  <simon@josefsson.org>
134072         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
134074 2007-04-12  Simon Josefsson  <simon@josefsson.org>
134076         * modules/autobuild: New module.
134078         * m4/autobuild.m4: New file.
134080 2007-04-11  Bruno Haible  <bruno@clisp.org>
134082         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
134083         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
134084         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
134085         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
134086         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
134087         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134088         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134089         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
134090         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134091         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134092         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
134093         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134094         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134095         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
134096         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134097         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134098         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
134099         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134100         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134101         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
134102         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134103         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134104         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
134105         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134106         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134107         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
134108         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
134109         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
134110         Reported by Eric Blake.
134112 2007-04-11  Bruno Haible  <bruno@clisp.org>
134114         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
134116 2007-04-10  Bruno Haible  <bruno@clisp.org>
134118         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
134119         for NaN and Infinity. Needed on FreeBSD 6.1.
134120         * tests/test-vasnprintf-posix.c (test_function): Undo last change
134121         regarding results for "%010a" of Infinity and NaN.
134122         * tests/test-vasprintf-posix.c (test_function): Likewise.
134123         * tests/test-snprintf-posix.h (test_function): Likewise.
134124         * tests/test-sprintf-posix.h (test_function): Likewise.
134125         * tests/test-fprintf-posix.h (test_function): Likewise.
134126         * tests/test-printf-posix.h (test_function): Likewise.
134127         * tests/test-fprintf-posix.out: Likewise.
134129 2007-04-10  Bruno Haible  <bruno@clisp.org>
134131         * modules/locale-tests: New file.
134132         * tests/test-locale.c: New file.
134134         * modules/locale: New file.
134135         * lib/locale_.h: New file.
134136         * m4/locale_h.m4: New file.
134138 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
134139             Bruno Haible  <bruno@clisp.org>
134141         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
134142         be determined, test for availability of the copysignf, copysign,
134143         copysignl functions.
134144         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
134145         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
134146         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
134148 2007-04-09  Eric Blake  <ebb9@byu.net>
134150         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
134151         * modules/stdio (Makefile.am): Support fflush.
134152         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
134153         * modules/fflush: New file.
134154         * lib/fflush.c: Likewise.
134155         * m4/fflush.m4: Likewise.
134156         * modules/fflush-tests: New test.
134157         * tests/test-fflush.c: Likewise.
134158         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
134160 2007-04-06  Bruno Haible  <bruno@clisp.org>
134162         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
134163         (VASNPRINTF): Use signbit for faster determination whether to print a
134164         minus sign.
134165         * modules/vasnprintf (Files): Remove lib/float+.h.
134166         * modules/fprintf-posix (Depends-on): Add signbit.
134167         * modules/snprintf-posix (Depends-on): Likewise.
134168         * modules/sprintf-posix (Depends-on): Likewise.
134169         * modules/vasnprintf-posix (Depends-on): Likewise.
134170         * modules/vasprintf-posix (Depends-on): Likewise.
134171         * modules/vfprintf-posix (Depends-on): Likewise.
134172         * modules/vsnprintf-posix (Depends-on): Likewise.
134173         * modules/vsprintf-posix (Depends-on): Likewise.
134175 2007-04-06  Bruno Haible  <bruno@clisp.org>
134177         * tests/test-frexp.c (main): Test also the sign bit of zero results.
134178         * tests/test-frexpl.c (main): Likewise.
134179         * tests/test-ldexpl.c (main): Likewise.
134180         * modules/frexp-tests (Depends-on): Add signbit.
134181         * modules/frexpl-tests (Depdends-on): Likewise.
134182         * modules/ldexpl-tests (Depdends-on): Likewise.
134184 2007-04-06  Bruno Haible  <bruno@clisp.org>
134186         * modules/signbit-tests: New file.
134187         * tests/test-signbit.c: New file.
134189         * modules/signbit: New file.
134190         * lib/signbitf.c: New file.
134191         * lib/signbitd.c: New file.
134192         * lib/signbitl.c: New file.
134193         * m4/signbit.m4: New file.
134194         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
134195         (signbit): New macro.
134196         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
134197         REPLACE_SIGNBIT.
134198         * modules/math (Makefile.am): Substitute also GNULIB_SIGNBIT and
134199         REPLACE_FREXPL into math.h.
134201 2007-04-06  Bruno Haible  <bruno@clisp.org>
134203         * modules/isnanf-nolibm-tests: New file.
134204         * tests/test-isnanf.c: New file.
134206         * modules/isnanf-nolibm: New file.
134207         * lib/isnanf.h: New file.
134208         * lib/isnanf.c: New file.
134209         * lib/isnan.c: Consider the USE_FLOAT macro.
134210         * m4/isnanf.m4: New file.
134212 2007-04-06  Bruno Haible  <bruno@clisp.org>
134214         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
134215         (Link): New section.
134217         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
134219 2007-04-06  Bruno Haible  <bruno@clisp.org>
134221         Assume the 'long double' type.
134222         * m4/longdouble.m4: Remove file.
134223         * config/srclist.txt: Don't mention longdouble.m4.
134224         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
134225         * lib/float+.h: Likewise.
134226         * lib/frexp.c: Likewise.
134227         * lib/printf-args.h: Likewise.
134228         * lib/printf-args.c: Likewise.
134229         * lib/printf-frexp.c: Likewise.
134230         * lib/printf-parse.c: Likewise.
134231         * lib/vasnprintf.c: Likewise.
134232         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
134233         * m4/intl.m4: Likewise.
134234         * m4/isnanl.m4: Likewise.
134235         * m4/printf.m4: Likewise.
134236         * m4/printf-frexpl.m4: Likewise.
134237         * m4/vasnprintf.m4: Likewise.
134238         * modules/allocsa (Files): Remove m4/longdouble.m4.
134239         * modules/gettext (Files): Likewise.
134240         * modules/relocatable-prog-wrapper (Files): Likewise.
134241         * modules/vasnprintf (Files): Likewise.
134242         * modules/isnanl (Files): Likewise.
134243         (Include): Simplify.
134244         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
134245         (Include): Simplify.
134246         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
134247         (Include): Simplify.
134248         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
134249         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
134250         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
134251         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
134252         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
134253         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
134254         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
134255         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
134256         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
134257         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
134258         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
134259         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
134260         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
134261         * tests/test-isnanl.c: Likewise.
134262         * tests/test-snprintf-posix.h: Likewise.
134263         * tests/test-sprintf-posix.h: Likewise.
134264         * tests/test-vasnprintf-posix.c: Likewise.
134265         * tests/test-vasnprintf-posix2.c: Likewise.
134266         * tests/test-vasprintf-posix.c: Likewise.
134268 2007-04-06  Bruno Haible  <bruno@clisp.org>
134270         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
134271         * lib/math_.h [__DECC]: Include the overridden include file through
134272         #include_next, outside the double-inclusion guard.
134273         * lib/stdio_.h [__DECC]: Likewise.
134274         * lib/stdlib_.h [__DECC]: Likewise.
134275         * lib/string_.h [__DECC]: Likewise.
134276         * lib/time_.h [__DECC]: Likewise.
134277         * lib/wchar_.h [__DECC]: Likewise.
134278         * lib/wctype_.h [__DECC]: Likewise.
134279         * lib/inttypes_.h [__DECC]: Likewise.
134280         Reported by Albert Chin <china@thewrittenword.com> in
134281         <http://lists.gnu.org/r/bug-gnulib/2007-04/msg00088.html>.
134283 2007-04-04  Eric Blake  <ebb9@byu.net>
134285         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
134286         1.5.x.
134288 2007-04-04  Bruno Haible  <bruno@clisp.org>
134290         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
134291         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
134293 2007-04-04  Bruno Haible  <bruno@clisp.org>
134295         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
134296         results for "%010a" of Infinity and NaN.
134297         * tests/test-vasprintf-posix.c (test_function): Likewise.
134298         * tests/test-snprintf-posix.h (test_function): Likewise.
134299         * tests/test-sprintf-posix.h (test_function): Likewise.
134300         * tests/test-fprintf-posix.h (test_function): Remove these tests.
134301         * tests/test-printf-posix.h (test_function): Likewise.
134302         * tests/test-fprintf-posix.out: Update.
134303         Needed for FreeBSD 6.1.
134305 2007-04-04  Bruno Haible  <bruno@clisp.org>
134307         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
134308         directly used by the gnulib modules nor by gnulib-tool.
134310 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
134312         * DEPENDENCIES: Give overall description of version dependency
134313         desirability.  Use more-typical names for apps.
134314         Add shell, coreutils, diffutils, grep, tar, gzip.
134316 2007-04-04  Simon Josefsson  <simon@josefsson.org>
134318         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
134320 2007-04-04  Karl Berry  <karl@gnu.org>
134322         * MODULES.html.sh (func_module): missing '.
134324 2007-04-03  Bruno Haible  <bruno@clisp.org>
134326         * modules/argmatch-tests (Makefile.am): New variable
134327         test_argmatch_LDADD.
134328         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
134329         * modules/array-list-tests (Makefile.am): New variable
134330         test_array_list_LDADD.
134331         * modules/array-oset-tests (Makefile.am): New variable
134332         test_array_oset_LDADD.
134333         * modules/avltree-list-tests (Makefile.am): New variable
134334         test_avltree_list_LDADD.
134335         * modules/avltree-oset-tests (Makefile.am): New variable
134336         test_avltree_oset_LDADD.
134337         * modules/avltreehash-list-tests (Makefile.am): New variable
134338         test_avltreehash_list_LDADD.
134339         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
134340         test_canonicalize_lgpl_LDADD.
134341         * modules/carray-list-tests (Makefile.am): New variable
134342         test_carray_list_LDADD.
134343         * modules/dirname-tests (Makefile.am): New variable
134344         test_dirname_LDADD.
134345         * modules/linked-list-tests (Makefile.am): New variable
134346         test_linked_list_LDADD.
134347         * modules/linkedhash-list-tests (Makefile.am): New variable
134348         test_linkedhash_list_LDADD.
134349         * modules/rbtree-list-tests (Makefile.am): New variable
134350         test_rbtree_list_LDADD.
134351         * modules/rbtree-oset-tests (Makefile.am): New variable
134352         test_rbtree_oset_LDADD.
134353         * modules/rbtreehash-list-tests (Makefile.am): New variable
134354         test_rbtreehash_list_LDADD.
134355         * modules/xvasprintf-tests (Makefile.am): New variable
134356         test_xvasprintf_LDADD.
134357         Reported by Eric Blake.
134359 2007-04-03  Eric Blake  <ebb9@byu.net>
134361         * DEPENDENCIES: Weaken m4 requirements.
134363 2007-04-03  Bruno Haible  <bruno@clisp.org>
134365         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
134366         * modules/isnanl-tests (configure.ac): Likewise.
134368 2007-04-03  Ben Pfaff  <blp@gnu.org>
134370         * modules/iconv_open: Add $(srcdir)/ to source directory
134371         references in Makefile fragments that call gperf, to fix VPATH
134372         builds.
134374 2007-04-03  Bruno Haible  <bruno@clisp.org>
134376         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
134377         * lib/ldexpl.c: Undo last change.
134379 2007-04-03  Bruno Haible  <bruno@clisp.org>
134381         * modules/printf-frexpl (Depends-on): Undo last change.
134382         (Files): Add m4/ldexpl.m4.
134384 2007-04-03  Bruno Haible  <bruno@clisp.org>
134386         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
134387         * modules/isnanl (Link): New section.
134389         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
134390         * modules/frexp (Link): New section.
134392         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
134393         * modules/frexpl (Link): New section.
134395         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
134396         * modules/ldexpl (Link): New section.
134398 2007-04-03  Bruno Haible  <bruno@clisp.org>
134400         * modules/TEMPLATE-EXTENDED: New file.
134401         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
134403 2007-04-03  Bruno Haible  <bruno@clisp.org>
134405         * DEPENDENCIES: New file.
134406         Suggested by Simon Josefsson.
134408 2007-04-03  Bruno Haible  <bruno@clisp.org>
134410         * doc/gnulib.texi: Escape @.
134412 2007-04-03  James Youngman  <jay@gnu.org>
134413         and Paul Eggert  <eggert@cs.ucla.edu>
134415         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
134416         birthtime on all systems that have birthtime, not just those which
134417         use st_birthtimensec rather than st_birthtim.  Putting zero in
134418         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
134419         that the birth time is not available for files on an NFS mount.
134421 2007-04-03  Simon Josefsson  <simon@josefsson.org>
134423         * modules/memxor: Move back from crypto/, suggested by Bruno.
134424         * modules/crypto/hmac-sha1: Fix memxor dependency.
134426         * modules/crypto/gc: Moved from ../.
134428 2007-04-02  Eric Blake  <ebb9@byu.net>
134430         * lib/ldexpl.c (includes): Avoid libm.
134432         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
134434 2007-04-02  Bruno Haible  <bruno@clisp.org>
134436         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
134437         on IRIX.
134439 2007-04-02  Bruno Haible  <bruno@clisp.org>
134441         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
134442         x86 or x86_64 platforms running MacOS X.
134443         Reported by Ryan Schmidt <@ryandesign.com>.
134445 2007-04-02  Bruno Haible  <bruno@clisp.org>
134447         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
134448         i386.
134450 2007-04-01  Simon Josefsson  <simon@josefsson.org>
134452         * modules/crypto/arcfour: Moved from ../.
134453         * modules/crypto/arcfour-tests: Moved from ../.
134454         * modules/crypto/arctwo: Moved from ../.
134455         * modules/crypto/arctwo-tests: Moved from ../.
134456         * modules/crypto/des: Moved from ../.
134457         * modules/crypto/des-tests: Moved from ../.
134458         * modules/crypto/gc-arcfour: Moved from ../.
134459         * modules/crypto/gc-arcfour-tests: Moved from ../.
134460         * modules/crypto/gc-arctwo: Moved from ../.
134461         * modules/crypto/gc-arctwo-tests: Moved from ../.
134462         * modules/crypto/gc-des: Moved from ../.
134463         * modules/crypto/gc-des-tests: Moved from ../.
134464         * modules/crypto/gc-hmac-md5: Moved from ../.
134465         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
134466         * modules/crypto/gc-hmac-sha1: Moved from ../.
134467         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
134468         * modules/crypto/gc-md2: Moved from ../.
134469         * modules/crypto/gc-md2-tests: Moved from ../.
134470         * modules/crypto/gc-md4: Moved from ../.
134471         * modules/crypto/gc-md4-tests: Moved from ../.
134472         * modules/crypto/gc-md5: Moved from ../.
134473         * modules/crypto/gc-md5-tests: Moved from ../.
134474         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
134475         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
134476         * modules/crypto/gc-random: Moved from ../.
134477         * modules/crypto/gc-rijndael: Moved from ../.
134478         * modules/crypto/gc-rijndael-tests: Moved from ../.
134479         * modules/crypto/gc-sha1: Moved from ../.
134480         * modules/crypto/gc-sha1-tests: Moved from ../.
134481         * modules/crypto/gc-tests: Moved from ../.
134482         * modules/crypto/hmac-md5: Moved from ../.
134483         * modules/crypto/hmac-md5-tests: Moved from ../.
134484         * modules/crypto/hmac-sha1: Moved from ../.
134485         * modules/crypto/hmac-sha1-tests: Moved from ../.
134486         * modules/crypto/md2: Moved from ../.
134487         * modules/crypto/md2-tests: Moved from ../.
134488         * modules/crypto/md4: Moved from ../.
134489         * modules/crypto/md4-tests: Moved from ../.
134490         * modules/crypto/md5: Moved from ../.
134491         * modules/crypto/md5-tests: Moved from ../.
134492         * modules/crypto/memxor: Moved from ../.
134493         * modules/crypto/rijndael: Moved from ../.
134494         * modules/crypto/rijndael-tests: Moved from ../.
134495         * modules/crypto/sha1: Moved from ../.
134497 2007-03-30  James Youngman  <jay@gnu.org>
134499         * tests/test-stat-time.c (prepare_test): use chmod() rather than
134500         rename() to change the ctime of a file (because ctime is unaffected
134501         by rename on jfs2 on AIX 5.1).
134502         (main): Start by doing cleanup, in case a previous run failed leaving
134503         test files behind.
134505 2007-03-31  Bruno Haible  <bruno@clisp.org>
134507         Support old proprietary implementations of iconv.
134508         * modules/iconv_open: New file.
134509         * lib/iconv_.h: New file.
134510         * m4/iconv_h.m4: New file.
134511         * lib/iconv_open.c: New file.
134512         * lib/iconv_open-aix.gperf: New file.
134513         * lib/iconv_open-hpux.gperf: New file.
134514         * lib/iconv_open-irix.gperf: New file.
134515         * lib/iconv_open-osf.gperf: New file.
134516         * m4/iconv_open.m4: New file.
134517         * modules/linebreak (Depends-on): Add iconv_open.
134518         * modules/striconv (Depends-on): Likewise.
134519         * modules/striconveh (Depends-on): Likewise.
134520         * modules/unicodeio (Depends-on): Likewise.
134521         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
134522         (iconv_t)(-1).
134523         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
134524         conversion if cd is (iconv_t)(-1).
134525         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
134526         is not possible.
134528 2007-03-31  Bruno Haible  <bruno@clisp.org>
134530         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
134531         work on Solaris either. Protect also second use of "autodetect_jp".
134533 2007-03-31  Bruno Haible  <bruno@clisp.org>
134535         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
134536         the function is not present.
134538 2007-03-31  Bruno Haible  <bruno@clisp.org>
134540         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
134541         the function is not present.
134543 2007-03-31  Bruno Haible  <bruno@clisp.org>
134545         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
134546         a bug in HP-UX iconv_open().
134548 2007-03-31  Bruno Haible  <bruno@clisp.org>
134550         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
134551         (Mathematics <math.h>): New section, add fpieee.
134552         (Input/output <stdio.h>): Add fseterr.
134553         (Mathematics <math.h>): New section, add printf-frexp.
134554         (Container data structures): Add sublist.
134555         (Core language properties): Add fpucw, inline.
134556         (Functions for greatest-width integer types <inttypes.h>): Add
134557         imaxabs, imaxdiv, inttypes.
134558         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
134559         isnanl-nolibm, ldexp.
134560         (Mathematics <math.h>): New section, add printf-frexpl.
134561         (Support for systems lacking POSIX:2001): Add fprintf-posix,
134562         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
134563         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
134564         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
134565         (Unicode string functions): Add unistr/u*-mbtoucr.
134566         (Java): Add javacomp-script, javaexec-script.
134567         (C#): Add csharpcomp-script, csharpexec-script.
134568         (Support for building libraries and executables): Add havelib,
134569         relocatable-*.
134570         (Support for maintaining and releasing projects): Renamed from
134571         'Support for maintaining and release projects'. Add announce-gen.
134573 2007-03-31  Bruno Haible  <bruno@clisp.org>
134575         * README: Talk primarily about git.
134576         (git and CVS): Renamed from CVS.
134577         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
134578         gnulib is available through git.
134579         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
134581 2007-03-30  Bruno Haible  <bruno@clisp.org>
134583         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
134584         * lib/poll_.h: Likewise.
134585         * lib/stat_.h: Likewise.
134586         * lib/sys_time_.h: Likewise.
134587         * lib/sysexit_.h: Likewise.
134588         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
134589         * lib/stdbool_.h: Likewise.
134590         * lib/byteswap_.h: Add double-inclusion guard.
134592 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
134594         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
134596 2007-03-30  Karl Berry  <karl@gnu.org>
134598         * config/srclist-update: double space after USA in the license
134599         substitution, since that's how it's usually (?) written.
134601 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
134603         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
134604         reported by Bruno Haible.
134606 2007-03-29  Bruno Haible  <bruno@clisp.org>
134608         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
134609         a bug in AIX iconv().
134611 2007-03-29  Bruno Haible  <bruno@clisp.org>
134613         * modules/ldexpl-tests: New file.
134614         * tests/test-ldexpl.c: New file.
134616 2007-03-29  Bruno Haible  <bruno@clisp.org>
134618         * lib/ldexpl.c: Include fpucw.h.
134619         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
134620         multiplication.
134621         * modules/ldexpl (Depends-on): Add fpucw.
134623 2007-03-29  Bruno Haible  <bruno@clisp.org>
134625         * modules/ldexpl: New file.
134626         * m4/ldexpl.m4: New file.
134627         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
134628         set.
134629         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
134630         REPLACE_LDEXPL.
134631         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
134632         REPLACE_LDEXPL.
134633         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
134634         gl_FUNC_LDEXPL_WORKS.
134635         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
134636         * modules/mathl (Files): Remove lib/ldexpl.c.
134637         (Depends-on): Add ldexpl.
134639 2007-03-29  Bruno Haible  <bruno@clisp.org>
134641         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
134643 2007-03-29  Bruno Haible  <bruno@clisp.org>
134645         * tests/test-striconveh.c (main): Don't assume that a direct conversion
134646         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
134647         and possibly also HP-UX.
134648         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
134649         work on AIX, IRIX, HP-UX, OSF/1.
134650         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
134651         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
134652         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
134653         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
134654         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
134655         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
134657 2007-03-29  Bruno Haible  <bruno@clisp.org>
134659         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
134661 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
134663         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
134664         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
134666 2007-03-29  Eric Blake  <ebb9@byu.net>
134668         * lib/acl-internal.h: Remove redundant include.
134669         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
134670         Cygwin when a file is locked.
134672 2007-03-29  Bruno Haible  <bruno@clisp.org>
134674         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
134675         file.
134676         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
134678 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
134680         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
134681         try to remove a parent directory if the child couldn't be removed
134682         (except for the first rmdir, which could fail because the child
134683         doesn't exist).  Problem reported by Jeff Blaine in
134684         <http://lists.gnu.org/r/bug-tar/2007-03/msg00014.html>.
134686 2007-03-28  Bruno Haible  <bruno@clisp.org>
134688         * lib/striconveh.c (utf8conv_carefully): New function.
134689         (mem_cd_iconveh_internal): Invoke it.
134691 2007-03-28  Bruno Haible  <bruno@clisp.org>
134693         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
134694         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
134695         input.
134696         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
134697         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
134698         unistr/u8-uctomb.
134700 2007-03-28  Bruno Haible  <bruno@clisp.org>
134702         * modules/unistr/u8-mbtoucr: New file.
134703         * lib/unistr/u8-mbtoucr.c: New file.
134704         * modules/unistr/u16-mbtoucr: New file.
134705         * lib/unistr/u16-mbtoucr.c: New file.
134706         * modules/unistr/u16-mbtoucr: New file.
134707         * lib/unistr/u16-mbtoucr.c: New file.
134708         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
134710 2007-03-27  Simon Josefsson  <simon@josefsson.org>
134711             Bruno Haible  <bruno@clisp.org>
134713         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
134714         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
134715         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
134717         * m4/stdio_h.m4: Add stubs for vasprintf too.
134719         * modules/stdio: Support vasprintf in sed command.
134721         * modules/vasprintf: Depend on stdio for prototypes.  Remove
134722         vasprintf.h.  Add stdio module indicator.
134724         * lib/stdio_.h: Declare asprintf and vasprintf, based on
134725         vasprintf.h.
134727         * lib/vasprintf.h: File removed.
134729         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
134730         * lib/vasprintf.c: Ditto.
134731         * lib/xvasprintf.c: Ditto.
134732         * tests/test-vasprintf-posix.c: Ditto.
134733         * tests/test-vasprintf.c: Ditto.
134735 2007-03-27  Bruno Haible  <bruno@clisp.org>
134737         Make vasnprintf multithread-safe.
134738         * lib/vasnprintf.c (decimal_point_char): New function.
134739         (VASNPRINTF): Use it.
134740         Suggested by Simon Josefsson.
134742 2007-03-27  Eric Blake  <ebb9@byu.net>
134744         Support sub-second birthtime on cygwin.
134745         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
134746         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
134747         (get_stat_birthtime): Also work with st_birthtim.
134749 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
134751         * lib/stat-time.h (USE_BIRTHTIME): Remove.
134752         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
134753         (get_stat_birthtime_ns): Do not try to use "spare" fields.
134754         (get_stat_birthtime_ns): Simplify compile-time tests.
134755         (get_stat_birthtime): Change the API to look like
134756         get_stat_mtime etc., except return a negative tv_nsec on error.
134757         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
134758         Don't check for "spare" fields.
134759         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
134760         or for struct stat.st_birthtime, as these tests aren't used.
134761         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
134763 2007-03-27  Bruno Haible  <bruno@clisp.org>
134765         * lib/stat-time.h: Include <sys/stat.h>.
134767 2007-03-27  James Youngman  <jay@gnu.org>
134769         * lib/stat-time.h (get_stat_birthtime): New function for
134770           retrieving st_birthtime as provided by UFS2 (hence *BSD).
134771         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
134772           and its variants.
134773         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
134774         * modules/stat-time-test: New file.
134775         * tests/test-stat-time.c: New test, devised by Bruno Haible.
134777 2007-03-26  Bruno Haible  <bruno@clisp.org>
134779         Better support of signalling NaNs.
134780         * lib/atanl.c: Include isnanl.h.
134781         (atanl): Perform test for NaN at the beginning of the function and
134782         through a call to isnanl.
134783         * lib/cosl.c: Include isnanl.h.
134784         (cosl): Perform test for NaN at the beginning of the function and
134785         through a call to isnanl.
134786         * lib/ldexpl.c: Include isnanl.h.
134787         (ldexpl): Perform test for NaN through a call to isnanl.
134788         * lib/logl.c: Include isnanl.h.
134789         (logl): Perform test for NaN at the beginning of the function and
134790         through a call to isnanl.
134791         * lib/sinl.c: Include isnanl.h.
134792         (sinl): Perform test for NaN at the beginning of the function and
134793         through a call to isnanl.
134794         * lib/sqrtl.c: Include isnanl.h.
134795         (sqrtl): Perform test for NaN at the beginning of the function and
134796         through a call to isnanl.
134797         * lib/tanl.c: Include isnanl.h.
134798         (tanl): Perform test for NaN at the beginning of the function and
134799         through a call to isnanl.
134800         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
134801         * modules/mathl (Depends-on): Add isnanl.
134803 2007-03-26  Eric Blake  <ebb9@byu.net>
134805         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
134806         regression in logic sense of previous patch.
134808 2007-03-26  Bruno Haible  <bruno@clisp.org>
134810         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
134811         unportable shell command "if ! ...".
134812         Reported by Ralf Wildenhues.
134814 2007-03-25  Bruno Haible  <bruno@clisp.org>
134816         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
134817         <sysexits.h> file, and only add EX_CONFIG.
134818         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
134819         absolute file name and whether it is sufficient. Substitute also
134820         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
134821         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
134822         ABSOLUTE_SYSEXITS_H into sysexits.h.
134824 2007-03-25  Bruno Haible  <bruno@clisp.org>
134826         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
134827         hints is NULL.
134829 2007-03-25  Bruno Haible  <bruno@clisp.org>
134831         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
134832         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
134834 2007-03-25  Bruno Haible  <bruno@clisp.org>
134836         * lib/vasnprintf.c: Include langinfo.h.
134837         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
134838         multithread-safe.
134839         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
134840         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
134841         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
134842         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
134843         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
134844         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
134845         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
134846         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
134847         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
134848         Reported by Simon Josefsson.
134850 2007-03-25  Bruno Haible  <bruno@clisp.org>
134852         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
134853         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
134854         * modules/vasnprintf (Depends-on): Add stdint.
134856 2007-03-25  Bruno Haible  <bruno@clisp.org>
134858         * modules/fpieee: New file.
134859         * m4/fpieee.m4: New file.
134860         * modules/isnan-nolibm (Depends-on): Add fpieee.
134861         * modules/isnanl-nolibm (Depends-on): Add fpieee.
134862         * modules/isnanl (Depends-on): Add fpieee.
134864 2007-03-25  Bruno Haible  <bruno@clisp.org>
134866         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
134868 2007-03-25  Bruno Haible  <bruno@clisp.org>
134870         Avoid test failures on IRIX 6.5.
134871         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
134872         (main): Use it.
134873         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
134874         macros.
134875         (main): Use them.
134877 2007-03-25  Bruno Haible  <bruno@clisp.org>
134879         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
134880         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
134881         exists but doesn't work.
134882         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
134883         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
134884         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
134885         * modules/math (Makefile.am): Substitute also REPLACE_FREXPL into
134886         math.h.
134888 2007-03-25  Bruno Haible  <bruno@clisp.org>
134890         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
134891         returns inf. Needed on IRIX 6.5.
134893 2007-03-25  Bruno Haible  <bruno@clisp.org>
134895         * tests/test-frexpl.c: Include isnanl-nolibm.h.
134896         (main): Use isnanl instead of x != x idiom.
134897         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
134899         * tests/test-frexp.c: Include isnan.h.
134900         (main): Use isnan instead of x != x idiom.
134901         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
134903 2007-03-25  Bruno Haible  <bruno@clisp.org>
134905         * tests/test-frexp.c (NaN): New function/macro.
134906         (main): Use it instead of 0.0 / 0.0.
134907         * tests/test-isnan.c (NaN): New function/macro.
134908         (main): Use it instead of 0.0 / 0.0.
134909         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
134910         (test_function): Use it instead of 0.0 / 0.0.
134911         * tests/test-vasprintf-posix.c (NaN): New function/macro.
134912         (test_function): Use it instead of 0.0 / 0.0.
134913         * tests/test-snprintf-posix.h (NaN): New function/macro.
134914         (test_function): Use it instead of 0.0 / 0.0.
134915         * tests/test-sprintf-posix.h (NaN): New function/macro.
134916         (test_function): Use it instead of 0.0 / 0.0.
134917         * tests/test-fprintf-posix.h (NaN): New function/macro.
134918         (test_function): Use it instead of 0.0 / 0.0.
134919         * tests/test-printf-posix.h (NaN): New function/macro.
134920         (test_function): Use it instead of 0.0 / 0.0.
134922         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
134924 2007-03-25  Bruno Haible  <bruno@clisp.org>
134926         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
134928 2007-03-25  Bruno Haible  <bruno@clisp.org>
134930         * lib/regexec.c (merge_state_with_log): Make static.
134932 2007-03-25  Bruno Haible  <bruno@clisp.org>
134934         * lib/trigl.c (kernel_rem_pio2): Make static.
134936 2007-03-25  Bruno Haible  <bruno@clisp.org>
134938         * lib/sincosl.c (sincosl_table): Make static.
134940 2007-03-25  Bruno Haible  <bruno@clisp.org>
134942         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
134943         if the compiler does not support C99.
134945 2007-03-25  Bruno Haible  <bruno@clisp.org>
134947         * modules/time (Makefile.am): Ensure all rule action lines start with a
134948         tab.
134950 2007-03-24  Bruno Haible  <bruno@clisp.org>
134952         * modules/tsearch-tests: New file.
134953         * tests/test-tsearch.sh: New file.
134954         * tests/test-tsearch.c: New file, mostly copied from glibc.
134956         * modules/search-tests: New file.
134957         * tests/test-search.c: New file.
134959         * modules/search: New file.
134960         * lib/search_.h: New file, incorporating lib/tsearch.h.
134961         * m4/search_h.m4: New file.
134962         * lib/tsearch.h: Remove file.
134963         * lib/tsearch.c: Include search.h instead of tsearch.h.
134964         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
134965         HAVE_TSEARCH.
134966         * modules/tsearch (Files): Remove lib/tsearch.h.
134967         (Depends-on): Add search.
134968         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
134969         (Include): Change tsearch.h into search.h.
134971 2007-03-24  Bruno Haible  <bruno@clisp.org>
134973         * modules/fpucw: New file.
134974         * lib/fpucw.h: New file.
134975         * lib/frexp.c: Include fpucw.h.
134976         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
134977         (FUNC): Use them.
134978         * lib/printf-frexp.c: Include fpucw.h.
134979         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
134980         (FUNC): Use them.
134981         * lib/vasnprintf.c: Include fpucw.h.
134982         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
134983         'long double' calculations.
134984         * tests/test-frexpl.c: Include fpucw.h.
134985         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
134986         * tests/test-printf-frexpl.c: Include fpucw.h.
134987         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
134988         * modules/frexpl (Depends-on): Add fpucw.
134989         * modules/printf-frexpl (Depends-on): Likewise.
134990         * modules/fprintf-posix (Depends-on): Likewise.
134991         * modules/snprintf-posix (Depends-on): Likewise.
134992         * modules/sprintf-posix (Depends-on): Likewise.
134993         * modules/vasnprintf-posix (Depends-on): Likewise.
134994         * modules/vasprintf-posix (Depends-on): Likewise.
134995         * modules/vfprintf-posix (Depends-on): Likewise.
134996         * modules/vsnprintf-posix (Depends-on): Likewise.
134997         * modules/vsprintf-posix (Depends-on): Likewise.
134998         * modules/frexpl-tests (Depends-on): Likewise.
134999         * modules/printf-frexpl-tests (Depends-on): Likewise.
135001 2007-03-24  Bruno Haible  <bruno@clisp.org>
135003         * lib/float+.h: New file.
135004         * lib/isnan.c: Include float+.h.
135005         (SIZE): New macro.
135006         (FUNC): Compare only SIZE bytes of the value.
135007         * lib/vasnprintf.c: Include float+.h.
135008         (VASNPRINTF): When comparing against +0.0L or +0.0, compare only
135009         SIZEOF_LDBL or SIZEOF_DBL bytes.
135010         * modules/isnan-nolibm (Files): Add lib/float+.h.
135011         * modules/isnanl-nolibm (Files): Add lib/float+.h.
135012         * modules/isnanl (Files): Add lib/float+.h.
135013         * modules/vasnprintf (Files): Add lib/float+.h.
135015 2007-03-24  Bruno Haible  <bruno@clisp.org>
135017         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
135018         include isnanl-nolibm.h.
135020 2007-03-24  Bruno Haible  <bruno@clisp.org>
135022         * tests/test-read-file.c (main): Don't produce spurious output for
135023         expected situations. Make the test fail if it encountered unexpected
135024         results.
135026 2007-03-24  Bruno Haible  <bruno@clisp.org>
135028         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
135029         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
135031 2007-03-24  Bruno Haible  <bruno@clisp.org>
135033         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
135035 2007-03-24  Bruno Haible  <bruno@clisp.org>
135037         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
135038         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
135040         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
135041         * modules/utf8-ucs4: Turn into a symbolic link to module
135042         unistr/u8-mbtouc.
135044         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
135045         utf8-ucs4-unsafe.
135046         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
135047         unistr/u8-mbtouc-unsafe.
135049         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
135050         * modules/utf16-ucs4: Turn into a symbolic link to module
135051         unistr/u16-mbtouc.
135053         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
135054         utf16-ucs4-unsafe.
135055         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
135056         unistr/u16-mbtouc-unsafe.
135058         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
135059         * modules/ucs4-utf8: Turn into a symbolic link to module
135060         unistr/u8-ubtomb.
135062         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
135063         * modules/ucs4-utf16: Turn into a symbolic link to module
135064         unistr/u16-ubtomb.
135066 2007-03-24  Bruno Haible  <bruno@clisp.org>
135068         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
135069         Enable the function only if HAVE_INLINE.
135070         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
135071         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
135072         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
135073         Enable the function only if HAVE_INLINE.
135074         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
135075         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
135076         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
135077         Enable the function only if HAVE_INLINE.
135078         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
135079         Enable the function only if HAVE_INLINE.
135080         * modules/utf8-ucs4: Update.
135081         * modules/utf8-ucs4-unsafe: Update.
135082         * modules/utf16-ucs4: Update.
135083         * modules/utf16-ucs4-unsafe: Update.
135084         * modules/ucs4-utf8: Update.
135085         * modules/ucs4-utf16: Update.
135087 2007-03-24  Bruno Haible  <bruno@clisp.org>
135089         * lib/utf8-ucs4.h: Remove file.
135090         * lib/utf8-ucs4-unsafe.h: Remove file.
135091         * lib/utf16-ucs4.h: Remove file.
135092         * lib/utf16-ucs4-unsafe.h: Remove file.
135093         * lib/ucs4-utf8.h: Remove file.
135094         * lib/ucs4-utf16.h: Remove file.
135095         * lib/unistr.h: Include their previous contents.
135096         * m4/utf-ucs4.m4: Remove file.
135097         * m4/ucs4-utf.m4: Remove file.
135098         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
135099         (Depends-on): Add unistr/base.
135100         (configure.ac): Remove gl_UTF_UCS4.
135101         (Makefile.am): Update.
135102         (Include): Change to unistr.h.
135103         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
135104         (Depends-on): Add unistr/base.
135105         (configure.ac): Remove gl_UTF_UCS4.
135106         (Makefile.am): Update.
135107         (Include): Change to unistr.h.
135108         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
135109         (Depends-on): Add unistr/base.
135110         (configure.ac): Remove gl_UTF_UCS4.
135111         (Makefile.am): Update.
135112         (Include): Change to unistr.h.
135113         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
135114         (Depends-on): Add unistr/base.
135115         (configure.ac): Remove gl_UTF_UCS4.
135116         (Makefile.am): Update.
135117         (Include): Change to unistr.h.
135118         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
135119         (Depends-on): Add unistr/base.
135120         (configure.ac): Remove gl_UCS4_UTF.
135121         (Makefile.am): Update.
135122         (Include): Change to unistr.h.
135123         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
135124         (Depends-on): Add unistr/base.
135125         (configure.ac): Remove gl_UCS4_UTF.
135126         (Makefile.am): Update.
135127         (Include): Change to unistr.h.
135128         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
135129         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
135130         utf8-ucs4-unsafe.h.
135131         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
135132         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
135133         utf16-ucs4-unsafe.h.
135134         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
135135         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
135136         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
135137         * lib/unistr/u8-strchr.c: Likewise.
135138         * lib/unistr/u8-strrchr.c: Likewise.
135139         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
135140         * lib/unistr/u16-strchr.c: Likewise.
135141         * lib/unistr/u16-strrchr.c: Likewise.
135142         * lib/striconveh.c: Update.
135143         * lib/linebreak.c: Update.
135145 2007-03-24  Bruno Haible  <bruno@clisp.org>
135147         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
135148         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
135150 2007-03-22  Bruno Haible  <bruno@clisp.org>
135152         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
135154 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
135156         * MODULES.html.sh (File system functions): New module write-any-file.
135157         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
135158         * m4/write-any-file.m4: New files.
135160 2007-03-23  Eric Blake  <ebb9@byu.net>
135162         * gnulib-tool: Rearrange space-tab sequences, since some editors
135163         like to eat them.
135165 2007-03-23  Eric Blake  <ebb9@byu.net>
135167         * lib/version-etc.c (version_etc_va): Update license wording to
135168         be more concise.  Recommended by Richard Stallman.
135170 2007-03-22  Bruno Haible  <bruno@clisp.org>
135172         * lib/poll.c (MSG_PEEK): New fallback definition.
135174 2007-03-22  Bruno Haible  <bruno@clisp.org>
135176         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
135177         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
135178         (main): Update.
135179         Fixes a compilation error on BeOS.
135181 2007-03-22  Bruno Haible  <bruno@clisp.org>
135183         * modules/frexpl-tests: New file.
135184         * tests/test-frexpl.c: New file.
135186         * modules/frexpl: New file.
135187         * m4/frexpl.m4: New file.
135188         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
135189         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
135190         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
135191         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
135192         (Depends-on): Add frexpl. Remove isnanl-nolibm.
135193         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
135195 2007-03-22  Bruno Haible  <bruno@clisp.org>
135197         * lib/frexpl.c: Share code with lib/frexp.c.
135198         * modules/mathl (Files): Add lib/frexp.c.
135199         (Depends-on): Add isnanl-nolibm.
135201 2007-03-22  Bruno Haible  <bruno@clisp.org>
135203         * modules/printf-frexp (Files): Add m4/frexp.m4.
135204         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
135205         only if the found frexp function actually works.
135207 2007-03-22  Bruno Haible  <bruno@clisp.org>
135209         * lib/frexp.c: Remove older implementation that uses divisions.
135211 2007-03-21  Bruno Haible  <bruno@clisp.org>
135213         * modules/frexp-tests: New file.
135214         * tests/test-frexp.c: New file.
135216         * modules/frexp: New file.
135217         * lib/frexp.c: New file.
135218         * m4/frexp.m4: New file.
135219         * lib/math_.h (frexp): New declaration.
135220         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
135221         REPLACE_FREXP.
135222         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
135224 2007-03-21  Bruno Haible  <bruno@clisp.org>
135226         * modules/isnanl-tests: New file.
135227         * tests/test-isnanl.c: New file.
135229         * modules/isnanl: New file.
135230         * lib/isnanl.h: New file.
135231         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
135232         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
135233         gl_FUNC_ISNANL_WORKS.
135234         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
135235         New macros.
135237 2007-03-21  Bruno Haible  <bruno@clisp.org>
135239         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
135240         lib/isnanl.h.
135241         (Include): Update.
135242         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
135243         * lib/vasnprintf.c: Update.
135244         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
135245         tests/test-isnanl.h, remove tests/test-isnanl.c.
135246         (Makefile.am): Update.
135247         * tests/test-isnanl-nolibm.c: New file.
135248         * tests/test-isnanl.h: New file.
135249         * tests/test-isnanl.c: Remove file.
135251 2007-03-21  Jim Meyering  <jim@meyering.net>
135253         When trying to open ".", treat ESTALE like EACCES.
135254         * lib/savewd.c (savewd_save): Resort to forking not just upon
135255         failure with EACCES, but also when errno is ESTALE.
135257 2007-03-20  Bruno Haible  <bruno@clisp.org>
135259         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
135260         Needed on AIX 5.1. Reported by Matthew Woehlke.
135262 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
135264         Suggestions by Bruno Haible:
135265         * lib/acl-internal.h: Include "gettext.h" rather than rolling
135266         our own.
135267         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
135268         * modules/acl (Depends-on): Add gettext.
135270 2007-03-19  Bruno Haible  <bruno@clisp.org>
135272         * modules/iconvme: Remove file.
135273         * lib/iconvme.h: Remove file.
135274         * lib/iconvme.c: Remove file.
135275         * m4/iconvme.m4: Remove file.
135277 2007-03-19  Bruno Haible  <bruno@clisp.org>
135279         * doc/relocatable-maint.texi: Break long shell script line.
135280         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
135282 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
135284         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
135285         handle file_has_acl.
135286         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
135287         * lib/acl.c: Move header inclusions and related macro defns into
135288         lib/acl-internal.h.
135289         (S_ISLNK): Remove defn, since that's now done for us.
135290         (file_has_acl): Move to lib/file-has-acl.c.
135291         Call acl_trivial if available.  This is the crucial part of the fix.
135292         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
135293         shared within the library.  Rewrite a bit, partly to make it compatible
135294         with the GNU coding style.
135295         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
135296         Remove unnecessary double-quotes.
135297         Don't test for acl_to_text; the build will catch that.
135298         Replace acl_entries if it doesn't exist and it is needed.
135299         Check for -lsec and acl_trivial (as used on Solaris 10).
135300         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
135301         lib/file-has-acl.c.
135302         (Depends-on): Add sys_stat, for S_ISLNK.
135304 2007-03-19  Ben Pfaff  <blp@gnu.org>
135306         * doc/gnulib.texi: Fix typos.
135307         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
135309 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
135311         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
135312         If size is zero here, buf must be zero.
135314 2007-03-19  Simon Josefsson  <simon@josefsson.org>
135316         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
135317         <bruno@clisp.org>.
135319 2007-03-18  Bruno Haible  <bruno@clisp.org>
135321         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
135322         Suggested by Eric Blake.
135324 2007-03-18  Ben Pfaff  <blp@gnu.org>
135326         * doc/relocatable.texi: Recommend using as prefix a directory
135327         that does not exist and will never be created.  Based on
135328         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
135329         and others.
135331 2007-03-17  Bruno Haible  <bruno@clisp.org>
135333         * lib/fchownat.c: Include lchown.h.
135335 2007-03-17  Bruno Haible  <bruno@clisp.org>
135337         Fix endless loop when the given allocated size was > INT_MAX.
135338         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
135339         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
135340         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
135341         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
135342         * lib/sprintf.c (sprintf): Likewise.
135344 2007-03-17  Bruno Haible  <bruno@clisp.org>
135346         * tests/test-argp-2.sh (func_compare): Output a context diff.
135348 2007-03-17  Bruno Haible  <bruno@clisp.org>
135350         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
135351         locale's decimal-point character.
135353 2007-03-17  Bruno Haible  <bruno@clisp.org>
135355         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
135356         before comparing it. Needed because on some platforms (e.g. x86) a
135357         'long double' occupies less bytes than sizeof (long double).
135359 2007-03-17  Bruno Haible  <bruno@clisp.org>
135361         * tests/test-crc.c (main): Make printf statements 64-bit clean.
135362         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
135363         * tests/test-getaddrinfo.c (simple): Likewise.
135364         * tests/test-read-file.c (main): Likewise.
135366 2007-03-17  Bruno Haible  <bruno@clisp.org>
135368         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
135370 2007-03-17  Bruno Haible  <bruno@clisp.org>
135372         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
135373         unused variable.
135375 2007-03-17  Bruno Haible  <bruno@clisp.org>
135377         * tests/test-c-strcasecmp.c: Include c-strcase.h.
135378         * tests/test-c-strncasecmp.c: Likewise.
135380 2007-03-17  Bruno Haible  <bruno@clisp.org>
135382         * modules/stdlib (Depends-on): Add unistd.
135383         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
135384         Needed for MacOS X 10.3.
135386 2007-03-17  Bruno Haible  <bruno@clisp.org>
135388         * lib/unistr/u-strdup.h: Include <stdlib.h>.
135390 2007-03-17  Bruno Haible  <bruno@clisp.org>
135392         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
135394 2007-03-17  Bruno Haible  <bruno@clisp.org>
135396         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
135397         to reflect files copied from gnulib (with or without modifications).
135398         Suggested by Jim Meyering.
135400 2007-03-17  Eric Blake  <ebb9@byu.net>
135402         * NEWS: Document stdlib change from 2007-02-18.
135404 2007-03-17  Jim Meyering  <jim@meyering.net>
135406         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
135407         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
135408         someone uses a name containing shell meta-characters.
135409         Reported by Alfred M. Szmidt.
135411         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
135413 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
135415         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
135416         and copy gettext configuration files only if configure.ac contains
135417         a use of AM_GNU_GETTEXT_VERSION.
135419 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
135421         * build-aux/bootstrap (gnulib_name): New variable.
135422         (gnulib_tool_options): Use it.
135424 2007-03-13  Simon Josefsson  <simon@josefsson.org>
135426         * tests/test-des.c: Use new namespace.
135428 2007-03-15  Bruno Haible  <bruno@clisp.org>
135430         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
135431         Reported by James Youngman <jay@gnu.org>.
135433 2007-03-15  Bruno Haible  <bruno@clisp.org>
135435         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
135436         declared prototype. Needed with cc on OSF/1 5.1.
135438 2007-03-15  Bruno Haible  <bruno@clisp.org>
135440         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
135441         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
135442         (struct gl_list_implementation): Add dispose_fn argument to the
135443         'create_empty', 'create' methods.
135444         (struct gl_list_impl_base): Add field 'dispose_fn'.
135445         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
135446         argument.
135447         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
135448         dispose_fn argument.
135449         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
135450         dispose_fn on the dropped values.
135451         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
135452         dispose_fn argument.
135453         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
135454         dropped values.
135455         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
135456         (gl_tree_remove_node): Call dispose_fn on the dropped value.
135457         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
135458         (gl_tree_remove_node): Call dispose_fn on the dropped value.
135459         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
135460         argument.
135461         (gl_tree_list_free): Call dispose_fn on the dropped values.
135462         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
135463         the dropped values.
135464         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
135465         Add dispose_fn argument.
135466         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
135467         Call dispose_fn on the dropped values.
135468         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
135469         Add dispose_fn argument.
135470         (gl_sublist_create): Initialize the 'dispose_fn' field.
135471         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
135472         * tests/test-array_list.c (main): Update.
135473         * tests/test-carray_list.c (main): Update.
135474         * tests/test-avltree_list.c (main): Update.
135475         * tests/test-rbtree_list.c (main): Update.
135476         * tests/test-avltreehash_list.c (main): Update.
135477         * tests/test-rbtreehash_list.c (main): Update.
135478         * tests/test-linked_list.c (main): Update.
135479         * tests/test-linkedhash_list.c (main): Update.
135480         * tests/test-array_oset.c (main): Update.
135482 2007-03-15  Bruno Haible  <bruno@clisp.org>
135484         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
135485         (gl_oset_create_empty): Add dispose_fn argument.
135486         (struct gl_oset_implementation): Add dispose_fn argument to
135487         'create_empty' method.
135488         (struct gl_oset_impl_base): Add dispose_fn field.
135489         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
135490         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
135491         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
135492         values.
135493         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
135494         (gl_tree_oset_free): Call dispose_fn on the dropped values.
135495         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
135496         dropped value.
135497         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
135498         dropped value.
135499         * tests/test-array_oset.c (main): Update.
135500         * tests/test-avltree_oset.c (main): Update.
135501         * tests/test-rbtree_oset.c (main): Update.
135502         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
135504 2007-03-13  Bruno Haible  <bruno@clisp.org>
135506         * tests/test-stdbool.c (i): Update after last patch.
135508 2007-03-12  Bruno Haible  <bruno@clisp.org>
135510         * lib/quotearg.c: Include <wctype.h> early, before the definition of
135511         the iswprint macro. Needed on Solaris 2.5.1.
135513 2007-03-12  Bruno Haible  <bruno@clisp.org>
135515         * tests/test-printf-frexp.c (main): Declare x as volatile.
135517 2007-03-12  Simon Josefsson  <simon@josefsson.org>
135519         * doc/gnulib.texi (Build robot for gnulib): New section.
135521 2007-03-12  Jim Meyering  <jim@meyering.net>
135523         * build-aux/bootstrap: New file.
135524         * build-aux/bootstrap.conf: New file, from coreutils.
135526 2007-03-11  Bruno Haible  <bruno@clisp.org>
135528         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
135530 2007-03-12  Simon Josefsson  <simon@josefsson.org>
135532         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
135533         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
135534         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
135536 2007-03-11  Bruno Haible  <bruno@clisp.org>
135538         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
135539         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
135541 2007-03-11  Bruno Haible  <bruno@clisp.org>
135543         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
135544         formula. Needed for SunPRO C 5.0.
135546 2007-03-11  Bruno Haible  <bruno@clisp.org>
135548         * modules/long-options (Depends-on): Add getopt.
135550 2007-03-11  Bruno Haible  <bruno@clisp.org>
135552         * modules/modechange (Depends-on): Add stdbool.
135554 2007-03-11  Bruno Haible  <bruno@clisp.org>
135556         * modules/i-ring (Depends-on): Add stdbool.
135558 2007-03-11  Bruno Haible  <bruno@clisp.org>
135560         * modules/gc-des (Depends-on): Add stdbool.
135562 2007-03-11  Bruno Haible  <bruno@clisp.org>
135564         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
135566 2007-03-11  Bruno Haible  <bruno@clisp.org>
135568         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
135570 2007-03-11  Bruno Haible  <bruno@clisp.org>
135572         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
135574 2007-03-11  Bruno Haible  <bruno@clisp.org>
135576         * lib/vasnprintf.c (sprintf): Undefine.
135578 2007-03-11  Bruno Haible  <bruno@clisp.org>
135580         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
135581         initializers in SunPRO C and Compaq C compilers.
135583 2007-03-11  Bruno Haible  <bruno@clisp.org>
135585         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
135586         decrementing code ANSI C compliant.
135588 2007-03-11  Bruno Haible  <bruno@clisp.org>
135590         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
135591         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
135593 2007-03-11  Bruno Haible  <bruno@clisp.org>
135595         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
135596         <stdbool.h> substitute doesn't pass.
135598 2007-03-11  Bruno Haible  <bruno@clisp.org>
135600         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
135602 2007-03-11  Bruno Haible  <bruno@clisp.org>
135604         * gnulib-tool (func_create_megatestdir): Create also an autobuild
135605         script, for submission to autobuild.josefsson.org.
135607 2007-03-10  Bruno Haible  <bruno@clisp.org>
135609         * modules/canonicalize-lgpl-tests: New file.
135610         * tests/test-canonicalize-lgpl.sh: New file.
135611         * tests/test-canonicalize-lgpl.c: New file.
135613         * modules/c-strcase-tests: New file.
135614         * tests/test-c-strcase.sh: New file.
135615         * tests/test-c-strcasecmp.c: New file.
135616         * tests/test-c-strncasecmp.c: New file.
135618         * modules/atexit-tests: New file.
135619         * tests/test-atexit.sh: New file.
135620         * tests/test-atexit.c: New file.
135622 2007-03-10  Bruno Haible  <bruno@clisp.org>
135624         * tests/test-binary-io.sh: Use temporary filenames that are not so
135625         likely to clash with those of other tests (in a parallel make).
135626         * tests/test-binary-io.c: Likewise.
135628 2007-03-10  Bruno Haible  <bruno@clisp.org>
135630         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
135631         fallback; use #error instead.
135632         Suggested by Simon Josefsson.
135634 2007-03-10  Bruno Haible  <bruno@clisp.org>
135636         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
135637         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
135638         first and the last.
135640 2007-03-10  Bruno Haible  <bruno@clisp.org>
135642         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
135644 2007-03-10  Bruno Haible  <bruno@clisp.org>
135646         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
135647         "make distcheck".
135648         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
135649         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
135650         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
135652 2007-03-10  Bruno Haible  <bruno@clisp.org>
135654         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
135655         variable.
135656         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
135657         variable.
135659 2007-03-09  Eric Blake  <ebb9@byu.net>
135660         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
135662         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
135663         types are not being provided by gnulib.
135664         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
135665         types are supported.
135667 2007-03-10  Bruno Haible  <bruno@clisp.org>
135669         * lib/stdio_.h (__attribute__): New macro.
135670         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
135671         vsprintf): Specify __attribute__ __format__ for GCC.
135672         Suggested by Eric Blake.
135674 2007-03-09  Bruno Haible  <bruno@clisp.org>
135676         * modules/printf-posix-tests: New file.
135677         * tests/test-printf-posix.sh: New file.
135678         * tests/test-printf-posix.c: New file.
135680         * modules/printf-posix: New file.
135681         * lib/printf.c: New file.
135682         * m4/printf-posix-rpl.m4: New file.
135683         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
135684         REPLACE_PRINTF.
135685         * lib/stdio_.h (printf): New declaration.
135686         (format, __format__, ____printf____, ____scanf____, ____strftime____,
135687         ____strfmon____): New macros.
135688         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
135689         REPLACE_PRINTF.
135691 2007-03-09  Bruno Haible  <bruno@clisp.org>
135693         * tests/test-vasnprintf-posix2.sh: New file.
135694         * tests/test-vasnprintf-posix2.c: New file.
135695         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
135696         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
135697         (Makefile.am): Activate test-vasnprintf-posix2.sh.
135699         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
135700         a locale dependent decimal point, rather than always '.'.
135702 2007-03-09  Eric Blake  <ebb9@byu.net>
135704         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
135705         spite of platforms like Tandem/NSK that define it to -1.
135707 2007-03-08  Bruno Haible  <bruno@clisp.org>
135709         * modules/vprintf-posix-tests: New file.
135710         * tests/test-vprintf-posix.sh: New file.
135711         * tests/test-vprintf-posix.c: New file.
135712         * tests/test-printf-posix.h: New file.
135714         * modules/vprintf-posix: New file.
135715         * lib/vprintf.c: New file.
135716         * m4/vprintf-posix.m4: New file.
135717         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
135718         REPLACE_VPRINTF.
135719         * lib/stdio_.h (vprintf): New declaration.
135720         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
135721         REPLACE_VPRINTF.
135723 2007-03-08  Bruno Haible  <bruno@clisp.org>
135725         * modules/fprintf-posix-tests: New file.
135726         * tests/test-fprintf-posix.sh: New file.
135727         * tests/test-fprintf-posix.c: New file.
135729         * modules/fprintf-posix: New file.
135730         * lib/fprintf.c: New file.
135731         * m4/fprintf-posix.m4: New file.
135732         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
135733         REPLACE_FPRINTF.
135734         * lib/stdio_.h (fprintf): New declaration.
135735         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
135736         REPLACE_FPRINTF.
135738 2007-03-08  Bruno Haible  <bruno@clisp.org>
135740         * modules/vfprintf-posix-tests: New file.
135741         * tests/test-vfprintf-posix.sh: New file.
135742         * tests/test-vfprintf-posix.c: New file.
135743         * tests/test-fprintf-posix.h: New file.
135744         * tests/test-fprintf-posix.out: New file.
135746         * modules/vfprintf-posix: New file.
135747         * lib/vfprintf.c: New file.
135748         * m4/vfprintf-posix.m4: New file.
135749         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
135750         REPLACE_VFPRINTF.
135751         * lib/stdio_.h (vfprintf): New declaration.
135752         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
135753         REPLACE_VFPRINTF.
135755 2007-03-08  Bruno Haible  <bruno@clisp.org>
135757         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
135759 2007-03-08  Bruno Haible  <bruno@clisp.org>
135761         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
135762         instead of 'expr' invocations.
135763         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
135764         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
135765         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
135766         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
135767         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
135768         Suggested by Paul Eggert.
135770 2007-03-08  Bruno Haible  <bruno@clisp.org>
135772         * modules/fseterr-tests: New file.
135773         * tests/test-fseterr.c: New file.
135775         * modules/fseterr: New file.
135776         * lib/fseterr.h: New file.
135777         * lib/fseterr.c: New file.
135779 2007-03-08  Bruno Haible  <bruno@clisp.org>
135781         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
135782         * lib/getopt_.h: Likewise.
135783         * lib/mbswidth.h: Likewise.
135784         * lib/setenv.h: Likewise.
135785         * lib/vasnprintf.h: Likewise.
135786         * lib/vasprintf.h: Likewise.
135787         * lib/verror.h: Likewise.
135788         * lib/xsetenv.h: Likewise.
135789         * lib/xvasprintf.h: Likewise.
135791 2007-03-08  Jim Meyering  <jim@meyering.net>
135793         * users.txt: Add parted.
135795         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
135797 2007-03-07  Bruno Haible  <bruno@clisp.org>
135799         * m4/printf.m4: Make the shell script snippets copy&pastable.
135801 2007-03-02  Bruno Haible  <bruno@clisp.org>
135803         * lib/netinet_in_.h: New file.
135804         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
135805         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
135806         * modules/netinet_in (Files): Add lib/netinet_in_.h.
135807         (Depends-on): Add absolute-header.
135808         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
135809         into netinet/in.h.
135811 2007-03-03  Bruno Haible  <bruno@clisp.org>
135813         * lib/sys_select_.h: New file.
135814         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
135815         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
135816         * modules/sys_select (Files): Add lib/sys_select_.h.
135817         (Depends-on): Add absolute-header.
135818         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
135819         into sys/select.h.
135821 2007-03-02  Bruno Haible  <bruno@clisp.org>
135823         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
135824         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
135825         values.
135826         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
135827         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
135828         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
135829         * modules/sys_socket (Depends-on): Add absolute-header.
135830         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
135831         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
135832         (Include): Remove requirement of inclusion of <sys/types.h>.
135834 2007-03-02  Bruno Haible  <bruno@clisp.org>
135836         * lib/byteswap_.h (bswap_32): Fix formula.
135838 2007-03-06  Bruno Haible  <bruno@clisp.org>
135840         * modules/sprintf-posix-tests: New file.
135841         * tests/test-sprintf-posix.c: New file.
135843         * modules/sprintf-posix: New file.
135844         * lib/sprintf.c: New file.
135845         * m4/sprintf-posix.m4: New file.
135846         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
135847         REPLACE_SPRINTF.
135848         * lib/stdio_.h (sprintf): New declaration.
135849         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
135850         REPLACE_SPRINTF.
135852 2007-03-06  Bruno Haible  <bruno@clisp.org>
135854         * modules/vsprintf-posix-tests: New file.
135855         * tests/test-vsprintf-posix.c: New file.
135856         * tests/test-sprintf-posix.h: New file.
135858         * modules/vsprintf-posix: New file.
135859         * lib/vsprintf.c: New file.
135860         * m4/vsprintf-posix.m4: New file.
135861         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
135862         REPLACE_VSPRINTF.
135863         * lib/stdio_.h (vsprintf): New declaration.
135864         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
135865         REPLACE_VSPRINTF.
135867 2007-03-06  Bruno Haible  <bruno@clisp.org>
135869         * modules/vsnprintf (Depend-on): Remove minmax.
135871 2007-03-06  Bruno Haible  <bruno@clisp.org>
135873         * modules/snprintf-posix-tests: New file.
135874         * tests/test-snprintf-posix.c: New file.
135876         * modules/snprintf-posix: New file.
135877         * m4/snprintf-posix.m4: New file.
135878         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
135879         gl_FUNC_SNPRINTF.
135880         (gl_FUNC_SNPRINTF): Invoke it.
135881         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
135882         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
135883         is set.
135884         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
135886 2007-03-06  Bruno Haible  <bruno@clisp.org>
135888         * modules/vsnprintf-posix-tests: New file.
135889         * tests/test-vsnprintf-posix.c: New file.
135890         * tests/test-snprintf-posix.h: New file.
135892         * modules/vsnprintf-posix: New file.
135893         * m4/vsnprintf-posix.m4: New file.
135894         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
135895         gl_FUNC_VSNPRINTF.
135896         (gl_FUNC_VSNPRINTF): Invoke it.
135897         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
135898         * lib/stdio_.h (vsnprintf): Define as a replacement if
135899         REPLACE_VSNPRINTF is set.
135900         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
135902 2007-03-06  Bruno Haible  <bruno@clisp.org>
135904         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
135905         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
135907 2007-03-06  Bruno Haible  <bruno@clisp.org>
135909         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
135910         (asinl): Declare also if HAVE_DECL_ASINL is set.
135911         (atanl): Declare also if HAVE_DECL_ATANL is set.
135912         (ceill): Declare also if HAVE_DECL_CEILL is set.
135913         (cosl): Declare also if HAVE_DECL_COSL is set.
135914         (expl): Declare also if HAVE_DECL_EXPL is set.
135915         (floorl): Declare also if HAVE_DECL_FLOORL is set.
135916         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
135917         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
135918         (logl): Declare also if HAVE_DECL_LOGL is set.
135919         (sinl): Declare also if HAVE_DECL_SINL is set.
135920         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
135921         (tanl): Declare also if HAVE_DECL_TANL is set.
135922         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
135923         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
135924         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
135925         declaration of frexpl, ldexpl.
135926         * modules/printf-frexpl (Depends-on): Add math.
135927         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
135929 2007-03-05  Bruno Haible  <bruno@clisp.org>
135931         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
135932         frexpl and ldexpl are declared.
135933         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
135935 2007-03-05  Bruno Haible  <bruno@clisp.org>
135937         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
135938         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
135940 2007-03-05  Bruno Haible  <bruno@clisp.org>
135942         * lib/stdio_.h: Include <stddef.h>.
135944 2007-03-05  Bruno Haible  <bruno@clisp.org>
135946         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
135948 2007-03-05  Bruno Haible  <bruno@clisp.org>
135950         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
135951         NetBSD 4, from Ralf Wildenhues.
135953 2007-03-04  Bruno Haible  <bruno@clisp.org>
135955         * lib/vasprintf.h: Update #if logic for the case when the functions
135956         exist but are overridden.
135958 2007-03-04  Bruno Haible  <bruno@clisp.org>
135960         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
135961         implementations: glibc-2.4 and MacOS X 10.3.
135962         * tests/test-vasnprintf-posix.c (test_function): Test also the case
135963         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
135964         * tests/test-vasprintf-posix.c (test_function): Likewise.
135966 2007-03-04  Bruno Haible  <bruno@clisp.org>
135968         * modules/vasprintf-posix-tests: New file.
135969         * tests/test-vasprintf-posix.c: New file.
135971         * modules/vasprintf-posix: New file.
135972         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
135973         defined.
135974         * m4/vasprintf-posix.m4: New file.
135975         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
135976         gl_FUNC_VASPRINTF.
135977         (gl_FUNC_VASPRINTF): Invoke it.
135978         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
135979         here.
135980         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
135982 2007-03-04  Bruno Haible  <bruno@clisp.org>
135984         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
135985         REPLACE_GETTIMEOFDAY.
135986         * modules/sys_time (Makefile.am): Likewise.
135987         * m4/sys_time_h.m4: Likewise.
135988         * m4/gettimeofday.m4: Likewise.
135990 2007-03-04  Bruno Haible  <bruno@clisp.org>
135992         * modules/vasnprintf-posix-tests: New file.
135993         * tests/test-vasnprintf-posix.c: New file.
135995         * modules/vasnprintf-posix: New file.
135996         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
135997         printf-frexpl.h.
135998         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
135999         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
136000         REPLACE_VASNPRINTF is defined.
136001         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
136002         gl_FUNC_VASNPRINTF.
136003         (gl_FUNC_VASNPRINTF): Invoke it.
136004         * m4/vasnprintf-posix.m4: New file.
136005         * m4/printf.m4: New file.
136007 2007-03-04  Bruno Haible  <bruno@clisp.org>
136009         Compile progreloc.c only if --enable-relocatable is specified.
136010         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
136011         if --enable-relocatable was specified.
136012         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
136013         lib_SOURCES.
136015 2007-03-04  Jim Meyering  <jim@meyering.net>
136017         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
136018         Use it consistently, rather than enumerating errno constants.
136020 2007-03-04  Bruno Haible  <bruno@clisp.org>
136022         * modules/xvasprintf-tests: New file.
136023         * tests/test-xvasprintf.c: New file.
136025         * modules/vasprintf-tests: New file.
136026         * tests/test-vasprintf.c: New file.
136028         * modules/vasnprintf-tests: New file.
136029         * tests/test-vasnprintf.c: New file.
136031         * modules/vsnprintf-tests: New file.
136032         * tests/test-vsnprintf.c: New file.
136034         * modules/snprintf-tests: New file.
136035         * tests/test-snprintf.c: New file.
136037 2007-03-04  Bruno Haible  <bruno@clisp.org>
136039         Compile relocatable.c only if --enable-relocatable is specified.
136040         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
136041         gl_RELOCATABLE_LIBRARY.
136042         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
136043         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
136044         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
136045         gl_RELOCATABLE_LIBRARY.
136046         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
136047         (Makefile.am): Remove lib_SOURCES.
136048         * modules/relocatable-lib-lgpl (configure.ac): Invoke
136049         gl_RELOCATABLE_LIBRARY.
136050         (Makefile.am): Remove lib_SOURCES.
136051         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
136052         always.
136053         * modules/relocatable-prog-wrapper (configure.ac): Invoke
136054         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
136056 2007-03-04  Bruno Haible  <bruno@clisp.org>
136058         * modules/argmatch-tests: New file.
136059         * tests/test-argmatch.c: New file.
136061         * tests/test-allocsa.c (main): Halve the number of loop runs.
136063         * modules/alloca-opt-tests: New file.
136064         * tests/test-alloca-opt.c: New file.
136066 2007-03-04  Jim Meyering  <jim@meyering.net>
136068         Work around difference between Linux ACLs and Solaris 10 ZFS.
136069         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
136070         for EINVAL.
136072 2007-03-03  Bruno Haible  <bruno@clisp.org>
136074         * modules/relocatable-prog (Depends-on): Add back progreloc's
136075         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
136077 2007-03-03  Bruno Haible  <bruno@clisp.org>
136079         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
136080         * modules/relocatable-lib: New file.
136082 2007-03-03  Bruno Haible  <bruno@clisp.org>
136084         * modules/relocatable-prog: Renamed from modules/relocatable.
136085         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
136087 2007-03-03  Bruno Haible  <bruno@clisp.org>
136089         * modules/relocatable-script (Files): Add doc/relocatable.texi,
136090         m4/relocatable-lib.m4.
136091         (Depends-on): Remove 'relocatable'.
136092         (configure.ac): Add gl_RELOCATABLE_NOP.
136094 2007-03-03  Bruno Haible  <bruno@clisp.org>
136096         * modules/relocatable-prog-wrapper: New file.
136097         * modules/relocatable (Depends-on): Add it. Remove all other
136098         dependencies except progname.
136099         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
136101         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
136102         (gl_FUNC_STRERROR): Nop.
136103         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
136105         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
136106         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
136108         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
136109         (gl_FUNC_READLINK): Update.
136111         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
136113 2007-03-03  Bruno Haible  <bruno@clisp.org>
136115         * lib/xreadlink.c: Include <unistd.h> unconditionally.
136116         * modules/xreadlink (Depends-on): Add unistd.
136117         * modules/xreadlink-with-size (Depends-on): Likewise.
136119 2007-03-03  Bruno Haible  <bruno@clisp.org>
136121         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
136122         extracted from gt_FUNC_SETENV.
136123         (gt_FUNC_SETENV): Remove macro.
136124         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
136125         remove gt_FUNC_SETENV.
136127 2007-03-03  Bruno Haible  <bruno@clisp.org>
136129         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
136130         ENABLE_RELOCATABLE here.
136131         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
136133 2007-03-03  Bruno Haible  <bruno@clisp.org>
136135         * modules/rbtreehash-list-tests (Depends-on): Add progname.
136136         * tests/test-rbtreehash_list.c: Include progname.h.
136137         (main): Call set_program_name.
136139         * modules/rbtree-oset-tests (Depends-on): Add progname.
136140         * tests/test-rbtree_oset.c: Include progname.h.
136141         (main): Call set_program_name.
136143         * modules/rbtree-list-tests (Depends-on): Add progname.
136144         * tests/test-rbtree_list.c: Include progname.h.
136145         (main): Call set_program_name.
136147         * modules/linked-list-tests (Depends-on): Add progname.
136148         * tests/test-linked_list.c: Include progname.h.
136149         (main): Call set_program_name.
136151 2007-03-03  Bruno Haible  <bruno@clisp.org>
136153         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
136154         All uses of __restrict changed to _Restrict_.
136155         * lib/glob_.h (__restrict): Remove macro.
136157 2007-03-02  Bruno Haible  <bruno@clisp.org>
136159         * modules/gettext (configure.ac): Require gettext infrastructure
136160         from version 0.16.1.
136162 2007-03-02  Bruno Haible  <bruno@clisp.org>
136164         * modules/linkedhash-list-tests (Depends-on): Add progname.
136165         * tests/test-linkedhash_list.c: Include progname.h.
136166         (main): Call set_program_name.
136168         * modules/carray-list-tests (Depends-on): Add progname.
136169         * tests/test-carray_list.c: Include progname.h.
136170         (main): Call set_program_name.
136172         * modules/avltreehash-list-tests (Depends-on): Add progname.
136173         * tests/test-avltreehash_list.c: Include progname.h.
136174         (main): Call set_program_name.
136176         * modules/avltree-oset-tests (Depends-on): Add progname.
136177         * tests/test-avltree_oset.c: Include progname.h.
136178         (main): Call set_program_name.
136180         * modules/avltree-list-tests (Depends-on): Add progname.
136181         * tests/test-avltree_list.c: Include progname.h.
136182         (main): Call set_program_name.
136184         * modules/array-oset-tests (Depends-on): Add progname.
136185         * tests/test-array_oset.c: Include progname.h.
136186         (main): Call set_program_name.
136188         * modules/array-list-tests (Depends-on): Add progname.
136189         * tests/test-array_list.c: Include progname.h.
136190         (main): Call set_program_name.
136192         * modules/argp-tests (Depends-on): Add progname.
136193         * tests/test-argp.c: Include argp.h first. Include progname.h.
136194         (main): Call set_program_name.
136196 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
136198         * doc/gnulib-tool.texi (Initial import): Reword description of
136199         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
136200         limited effect even if defined after the first system include.
136202 2007-03-01  Bruno Haible  <bruno@clisp.org>
136204         * build-aux/config.libpath: Update to libtool-1.5.22.
136205         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
136207 2007-03-01  Bruno Haible  <bruno@clisp.org>
136209         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
136210         foo_CFLAGS.
136211         Reported by Ralf Wildenhues.
136213 2007-03-01  Bruno Haible  <bruno@clisp.org>
136215         * build-aux/install-reloc: Remove object files left over by some
136216         compilers.
136217         Reported by Ralf Wildenhues.
136219 2007-03-01  Bruno Haible  <bruno@clisp.org>
136221         * build-aux/install-reloc: Break long lines.
136223 2007-03-01  Bruno Haible  <bruno@clisp.org>
136225         * doc/relocatable.texi: Document that it may not work on OpenBSD.
136226         Reported by Ralf Wildenhues.
136228 2007-03-01  Bruno Haible  <bruno@clisp.org>
136230         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
136231         include ordering constraints.
136233 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
136235         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
136236         <http://lists.gnu.org/r/bug-gnulib/2007-02/msg00136.html>.
136237         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
136238         as another example.
136239         * lib/time_.h: Fix misspelling.
136240         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
136241         Require gl_HEADER_TIME_H_DEFAULTS.
136242         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
136243         * m4/time_r.m4 (gl_TIME_R): Likewise.
136244         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
136246 2007-03-01  Bruno Haible  <bruno@clisp.org>
136248         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
136249         * m4/utimens.m4 (gl_UTIMENS): Likewise.
136251 2007-03-01  Jim Meyering  <jim@meyering.net>
136253         * modules/xreadlink (Maintainer): Add my name.
136254         * modules/xreadlink-with-size (Depends-on): Alphabetize.
136256 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
136257             Bruno Haible  <bruno@clisp.org>
136259         * build-aux/install-reloc: Compile also c-ctype.c.
136260         * build-aux/relocatable.sh.in: New file.
136261         * doc/relocatable.texi: New file.
136262         * doc/relocatable-maint.texi: New file.
136263         * doc/gnulib.texi: Include relocatable-maint.texi.
136264         * lib/progreloc.c: Include unistd.h unconditionally.
136265         * lib/relocwrapper.c: Include unistd.h unconditionally.
136266         Include c-ctype.h.
136267         (add_dotbin): Use c_tolower.
136268         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
136269         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
136270         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
136271         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
136272         to m4/relocatable-lib.m4.
136273         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
136274         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
136275         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
136276         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
136277         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
136278         * modules/relocatable: New file.
136279         * modules/relocatable-lib: New file.
136280         * modules/relocatable-script: New file.
136282 2007-02-28  Bruno Haible  <bruno@clisp.org>
136284         Import --enable-relocatable infrastructure.
136285         * build-aux/config.libpath: New file, from GNU gettext.
136286         * build-aux/install-reloc: New file, from GNU gettext.
136287         * build-aux/reloc-ldflags: New file, from GNU gettext.
136288         * lib/relocatable.h: New file, from GNU gettext.
136289         * lib/relocatable.c: New file, from GNU gettext.
136290         * lib/relocwrapper.c: New file, from GNU gettext.
136291         * m4/relocatable.m4: New file, from GNU gettext.
136293 2007-02-28  Bruno Haible  <bruno@clisp.org>
136295         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
136297         * modules/xreadlink: New file, from GNU gettext with modifications.
136298         * lib/xreadlink.c: New file, from GNU gettext.
136299         * lib/xreadlink.h: Add comments.
136300         (xreadlink): New declaration.
136302         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
136303         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
136304         lib/xreadlink-with-size.c.
136305         (configure.ac): Remove gl_XREADLINK invocation.
136306         (Makefile.am): Augment lib_SOURCES.
136307         * m4/xreadlink.m4: Remove file.
136308         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
136309         (xreadlink_with_size): Renamed from xreadink.
136310         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
136311         * modules/canonicalize (Depends-on): Replace xreadlink with
136312         xreadlink-with-size.
136313         * lib/canonicalize.c (canonicalize_filename_mode): Update.
136315 2007-02-25  Jim Meyering  <jim@meyering.net>
136317         * build-aux/announce-gen: When complaining about excess arguments,
136318         list them.
136320 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
136322         * README: Document signed integer overflow situation more
136323         accurately.
136325 2007-02-25  Bruno Haible  <bruno@clisp.org>
136327         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
136328         'a' or 'A' conversion.
136330 2007-02-25  Bruno Haible  <bruno@clisp.org>
136332         * modules/filename: Renamed from modules/pathname.
136333         (Files): Replace lib/pathname.h with lib/filename.h. Replace
136334         lib/concatpath.c with lib/concat-filename.c.
136335         (Makefile.am): Update.
136336         (Include): Replace pathname.h with filename.h.
136337         * lib/filename.h: Renamed from lib/pathname.h.
136338         (concatenated_filename): Renamed from concatenated_pathname.
136339         * lib/concat-filename.c: Renamed from lib/concatpath.c.
136340         (concatenated_filename): Renamed from concatenated_pathname.
136341         * lib/findprog.c: Include filename.h instead of pathname.h.
136342         (find_in_path): Update.
136343         * lib/javacomp.c: Include filename.h instead of pathname.h.
136344         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
136345         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
136346         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
136347         is_oldgcj_14_13_usable, is_javac_usable): Update.
136348         * lib/javaexec.c: Include filename.h instead of pathname.h.
136349         (execute_java_class): Update.
136350         * modules/findprog: Update.
136351         * modules/javacomp: Update.
136352         * modules/javaexec: Update.
136353         * MODULES.html.sh (File system functions): Add 'filename', remove
136354         'pathname'.
136356 2007-02-25  Bruno Haible  <bruno@clisp.org>
136358         * modules/printf-frexpl-tests: New file.
136359         * tests/test-printf-frexpl.c: New file.
136361         * modules/printf-frexpl: New file.
136362         * lib/printf-frexpl.h: New file.
136363         * lib/printf-frexpl.c: New file.
136364         * m4/printf-frexpl.m4: New file.
136366 2007-02-25  Bruno Haible  <bruno@clisp.org>
136368         * modules/printf-frexp-tests: New file.
136369         * tests/test-printf-frexp.c: New file.
136371         * modules/printf-frexp: New file.
136372         * lib/printf-frexp.h: New file.
136373         * lib/printf-frexp.c: New file.
136374         * m4/printf-frexp.m4: New file.
136376 2007-02-25  Bruno Haible  <bruno@clisp.org>
136378         Assume automake >= 1.10 for the tests.
136379         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
136380         * modules/arctwo-tests: Likewise.
136381         * modules/argp-tests: Likewise.
136382         * modules/avltree-list-tests: Likewise.
136383         * modules/avltree-oset-tests: Likewise.
136384         * modules/avltreehash-list-tests: Likewise.
136385         * modules/carray-list-tests: Likewise.
136386         * modules/crc-tests: Likewise.
136387         * modules/des-tests: Likewise.
136388         * modules/gc-arcfour-tests: Likewise.
136389         * modules/gc-arctwo-tests: Likewise.
136390         * modules/gc-des-tests: Likewise.
136391         * modules/gc-hmac-md5-tests: Likewise.
136392         * modules/gc-hmac-sha1-tests: Likewise.
136393         * modules/gc-md2-tests: Likewise.
136394         * modules/gc-md4-tests: Likewise.
136395         * modules/gc-md5-tests: Likewise.
136396         * modules/gc-pbkdf2-sha1-tests: Likewise.
136397         * modules/gc-rijndael-tests: Likewise.
136398         * modules/gc-sha1-tests: Likewise.
136399         * modules/gc-tests: Likewise.
136400         * modules/getaddrinfo-tests: Likewise.
136401         * modules/hmac-md5-tests: Likewise.
136402         * modules/hmac-sha1-tests: Likewise.
136403         * modules/linked-list-tests: Likewise.
136404         * modules/linkedhash-list-tests: Likewise.
136405         * modules/lock-tests: Likewise.
136406         * modules/md2-tests: Likewise.
136407         * modules/md4-tests: Likewise.
136408         * modules/md5-tests: Likewise.
136409         * modules/rbtree-list-tests: Likewise.
136410         * modules/rbtree-oset-tests: Likewise.
136411         * modules/rbtreehash-list-tests: Likewise.
136412         * modules/read-file-tests: Likewise.
136413         * modules/rijndael-tests: Likewise.
136414         * modules/stdint-tests: Likewise.
136415         * modules/tls-tests: Likewise.
136417 2007-02-24  Bruno Haible  <bruno@clisp.org>
136419         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
136420         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
136421         function; instead check whether isnan with a double argument links.
136422         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
136423         function; instead check whether isnan with a 'long double' argument
136424         links.
136425         Reported by Eric Blake <ebb9@byu.net>.
136427 2007-02-24  Bruno Haible  <bruno@clisp.org>
136429         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
136430         defined.
136431         * lib/isnanl.c: Remove all code. Just include isnan.c.
136432         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
136434 2007-02-25  Jim Meyering  <jim@meyering.net>
136436         Avoid conflicting types for 'unsetenv' on FreeBSD.
136437         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
136438         conflicting with FreeBSD's (5.0 and 6.1) function declaration
136439         in stdlib.h.
136441 2007-02-24  Bruno Haible  <bruno@clisp.org>
136443         * modules/isnanl-nolibm-tests: New file.
136444         * tests/test-isnanl.c: New file.
136446         * modules/isnanl-nolibm: New file.
136447         * lib/isnanl.h: New file.
136448         * lib/isnanl.c: New file.
136449         * m4/isnanl.m4: New file.
136451 2007-02-24  Bruno Haible  <bruno@clisp.org>
136453         * modules/isnan-nolibm-tests: New file.
136454         * tests/test-isnan.c: New file.
136456         * modules/isnan-nolibm: New file.
136457         * lib/isnan.h: New file.
136458         * lib/isnan.c: New file.
136459         * m4/isnan.m4: New file.
136461 2007-02-24  Bruno Haible  <bruno@clisp.org>
136463         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
136464         assume that an exponent fits in 20 bits.
136466 2007-02-24  Jim Meyering  <jim@meyering.net>
136468         * m4/regex.m4: Update the description of the configure-time option,
136469         --without-included-regex, to state accurately what the defaults are,
136470         and perhaps to give people an idea why using this option is risky.
136472 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
136474         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
136475         loops on small arguments.  This attempts to avoid the problem
136476         Bruno Haible reported for AIX 4.3.2 in
136477         <http://lists.gnu.org/r/bug-gnulib/2007-02/msg00309.html>.
136479 2007-02-23  Bruno Haible  <bruno@clisp.org>
136481         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
136482         Needed for help2man.
136484 2007-02-23  Karl Berry  <karl@gnu.org>
136486         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
136487         exists, foo.h should be cvs-ignored, not committed.
136489 2007-02-23  Eric Blake  <ebb9@byu.net>
136491         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
136492         * lib/stat-time.h (includes): Likewise.
136493         * lib/utimecmp.c (includes): Likewise.
136494         * lib/utimens.h (includes): Likewise.
136495         * lib/getdate.y (includes): Also include "timespec.h" for use
136496         internal to the module.
136497         * modules/utimens (Depends-on): Revert yesterday's patch.
136498         * modules/nanosleep (Depends-on): Add missing dependency.
136500 2007-02-22  Bruno Haible  <bruno@clisp.org>
136502         * lib/glob.c: Don't include getlogin_r.h.
136504 2007-02-22  Jim Meyering  <jim@meyering.net>
136506         * modules/utimens (Depends-on): Add timespec, required for
136507         utimens.h's inclusion of timespec.h.
136509 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
136511         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
136512         long unreadable paths in GNU/Linux.  Problem reported by Andreas
136513         Schwab in
136514         <http://lists.gnu.org/r/bug-gnulib/2007-02/msg00261.html>.
136515         I'll try to think of a better way to fix the Solaris problem.
136517         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
136518         like glibc; on Solaris 10, it fails with errno == EINVAL.
136519         POSIX says the behavior is unspecified if the first argument is NULL,
136520         so play it safe and never pass NULL to the system getcwd.
136522 2007-02-21  Jim Meyering  <jim@meyering.net>
136524         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
136525         of gettimeofday.  It would conflict with the one now always
136526         provided via sys_time_.h.  Reported by Matthew Woehlke, as
136527         an IRIX 6.5 build failure.
136529 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
136531         Minor fixups to port to Solaris 10 with Sun C 5.8.
136532         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
136533         * modules/getcwd (Depends-on): Add dirfd.
136534         * lib/putenv.c (putenv): #undef it.
136535         (rpl_putenv): New decl.
136536         (malloc, free): Include <stdlib.h> rather than prototyping separately.
136538 2007-02-20  Bruno Haible  <bruno@clisp.org>
136540         * modules/stdio-tests: New file.
136541         * tests/test-stdio.c: New file.
136543         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
136544         (Depends-on): Add stdio.
136545         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
136546         (Include): Use <stdio.h> instead of vsnprintf.h.
136547         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
136548         HAVE_DECL_VSNPRINTF.
136549         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
136551         * modules/snprintf (Files): Remove lib/snprintf.h.
136552         (Depends-on): Add stdio.
136553         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
136554         (Include): Use <stdio.h> instead of snprintf.h.
136555         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
136556         HAVE_DECL_SNPRINTF.
136557         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
136558         * lib/getaddrinfo.c: Likewise.
136560         * modules/stdio: New file.
136561         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
136562         * lib/snprintf.h: Remove file.
136563         * lib/vsnprintf.h: Remove file.
136564         * lib/.cppi-disable: Remove snprintf.h.
136565         * m4/stdio_h.m4: New file.
136566         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
136568 2007-02-20  Jim Meyering  <jim@meyering.net>
136570         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
136571         used by e.g., mingw.  From Bruno Haible.
136573 2007-02-19  Bruno Haible  <bruno@clisp.org>
136575         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
136576         warnings.
136577         Reported by Ben Pfaff <blp@cs.stanford.edu>.
136579 2007-02-19  Bruno Haible  <bruno@clisp.org>
136581         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
136582         from mingw users.
136584 2007-02-19  Bruno Haible  <bruno@clisp.org>
136586         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
136587         warnings.
136588         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
136590 2007-02-19  Jim Meyering  <jim@meyering.net>
136592         Don't use FD after a successful "fdopendir (fd)".
136593         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
136594         Reset it by calling dirfd on the just-obtained DIR*.
136596         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
136597         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
136599 2007-02-18  Bruno Haible  <bruno@clisp.org>
136601         * lib/readlink.c: Include <unistd.h>.
136602         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
136603         HAVE_READLINK.
136604         * modules/readlink (Depends-on): Add unistd.
136605         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
136606         (Include): Add <unistd.h>.
136608         * lib/getlogin_r.h: Remove file.
136609         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
136610         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
136611         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
136612         HAVE_DECL_GETLOGIN_R.
136613         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
136614         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
136615         (Include): Use <unistd.h> instead of getlogin_r.h.
136617         * lib/getcwd.h: Remove file.
136618         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
136619         * lib/xgetcwd.c: Likewise.
136620         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
136621         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
136622         * modules/getcwd (Files): Remove lib/getcwd.h.
136623         (Depends-on): Add unistd.
136624         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
136625         (Include): Use <unistd.h> instad of getcwd.h.
136627         * lib/ftruncate.c: Include <unistd.h> first.
136628         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
136629         Set HAVE_FTRUNCATE.
136630         * modules/ftruncate (Depends-on): Add unistd.
136631         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
136633         * lib/fchdir.c: Include <unistd.h> first.
136634         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
136635         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
136636         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
136637         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
136638         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
136640         * lib/dup2.c: Include <unistd.h> first.
136641         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
136642         HAVE_DUP2.
136643         * modules/dup2 (Depends-on): Add unistd.
136644         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
136646         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
136647         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
136648         REPLACE_CHOWN. Don't define chown as a macro here.
136649         * modules/chown (Depends-on): Add unistd.
136650         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
136652         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
136653         Add definition for GL_LINK_WARNING.
136654         (chown, dup2): New declarations.
136655         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
136656         link warning.
136657         (ftruncate): New declaration.
136658         (getcwd): New declaration, taken from old getcwd.h.
136659         (getlogin_r): New declaration, taken from old getlogin_r.h.
136660         (readlink): New declaration.
136661         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
136662         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
136663         (gl_PREREQ_UNISTD): Remove macro.
136664         (gl_UNISTD_MODULE_INDICATOR): New macro.
136665         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
136666         many new variables. Don't set UNISTD_H.
136667         * modules/unistd (Description): Change.
136668         (Depends-on): Add link-warning.
136669         (configure.ac): Update.
136670         (Makefile.am): Create unistd.h always. Substitute many new variables
136671         into it.
136673 2007-02-18  Bruno Haible  <bruno@clisp.org>
136675         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
136676         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
136677         HAVE_GETSUBOPT.
136678         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
136679         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
136680         * lib/getsubopt.h: Remove file.
136681         * modules/getsubopt (Files): Remove lib/getsubopt.h.
136682         (Depends-on): Add stdlib.
136683         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
136684         (Includes): Use <stdlib.h> instead of getsubopt.h.
136685         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
136686         Set HAVE_GETSUBOPT.
136687         * lib/getsubopt.c: Don't include getsubopt.h.
136689 2007-02-18  Bruno Haible  <bruno@clisp.org>
136691         * modules/fchdir (Depends-on): Add dup2.
136693 2007-02-18  Bruno Haible  <bruno@clisp.org>
136695         * lib/stdlib_.h: Handle glibc's special invocation convention
136696         specially.
136698 2007-02-18  Bruno Haible  <bruno@clisp.org>
136700         * modules/stdlib-tests: New file.
136701         * tests/test-stdlib.c: New file.
136703         * modules/mkstemp (Files): Remove lib/mkstemp.h.
136704         (Depends-on): Add stdlib.
136705         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
136706         (Includes): Use <stdlib.h> instead of mkstemp.h.
136707         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
136708         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
136709         * lib/mkstemp.c: Don't include mkstemp.h.
136710         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
136711         * lib/stdlib--.h: Don't include mkstemp.h.
136713         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
136714         (Depends-on): Add stdlib.
136715         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
136716         (Includes): Use <stdlib.h> instead of mkdtemp.h.
136717         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
136718         HAVE_MKDTEMP.
136719         * lib/mkdtemp.c: Don't include mkdtemp.h.
136720         * lib/clean-temp.c: Don't include mkdtemp.h.
136722         * modules/exit (Files): Remove lib/exit.h.
136723         (Depends-on): Add stdlib.
136724         (Makefile.am): Remove lib_SOURCES.
136725         (Include): Use <stdlib.h> instead of exit.h.
136726         * lib/argmatch.c: Don't include exit.h.
136727         * lib/execute.c: Likewise.
136728         * lib/pagealign_alloc.c: Likewise.
136729         * lib/pipe.c: Likewise.
136730         * lib/wait-process.c: Likewise.
136731         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
136732         * lib/exitfail.c: Likewise.
136733         * lib/savewd.c: Likewise.
136734         * lib/xsetenv.c: Likewise.
136736         * modules/stdlib: New file.
136737         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
136738         and extra comments about mkstemp().
136739         * lib/exit.h: Remove file.
136740         * lib/mkdtemp.h: Remove file.
136741         * lib/mkstemp.h: Remove file.
136742         * m4/stdlib_h.m4: New file.
136743         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
136745 2007-02-18  Bruno Haible  <bruno@clisp.org>
136747         * modules/math-tests: New file.
136748         * tests/test-math.c: New file.
136750         * modules/math: New file.
136751         * modules/mathl (Files): Remove lib/mathl.h.
136752         (Depends-on): Add math.
136753         (Makefile.am): Don't mention mathl.h.
136754         (Include): Use <math.h> instead of mathl.h.
136755         * lib/math_.h: New file.
136756         * lib/mathl.h: Remove file.
136757         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
136758         mathl.h.
136759         * lib/asinl.c: Likewise.
136760         * lib/atanl.c: Likewise.
136761         * lib/ceill.c: Likewise.
136762         * lib/cosl.c: Likewise.
136763         * lib/expl.c: Likewise.
136764         * lib/floorl.c: Likewise.
136765         * lib/frexpl.c: Likewise.
136766         * lib/ldexpl.c: Likewise.
136767         * lib/logl.c: Likewise.
136768         * lib/sincosl.c: Likewise.
136769         * lib/sinl.c: Likewise.
136770         * lib/sqrtl.c: Likewise.
136771         * lib/tanl.c: Likewise.
136772         * lib/trigl.c: Likewise.
136773         * m4/math_h.m4: New file.
136774         * MODULES.html.sh (Mathematics): Add math.
136776 2007-02-17  Bruno Haible  <bruno@clisp.org>
136778         * modules/wctype-tests: New file.
136779         * tests/test-wctype.c: New file.
136781         * modules/wchar-tests: New file.
136782         * tests/test-wchar.c: New file.
136784         * modules/unistd-tests: New file.
136785         * tests/test-unistd.c: New file.
136787         * modules/time-tests: New file.
136788         * tests/test-time.c: New file.
136790         * modules/sysexits-tests: New file.
136791         * tests/test-sysexits.c: New file.
136793         * modules/sys_time-tests: New file.
136794         * tests/test-sys_time.c: New file.
136796         * modules/sys_stat-tests: New file.
136797         * tests/test-sys_stat.c: New file.
136799         * modules/sys_socket-tests: New file.
136800         * tests/test-sys_socket.c: New file.
136802         * modules/sys_select-tests: New file.
136803         * tests/test-sys_select.c: New file.
136805         * modules/string-tests: New file.
136806         * tests/test-string.c: New file.
136808         * modules/stdbool-tests: New file.
136809         * tests/test-stdbool.c: New file.
136811         * modules/netinet_in-tests: New file.
136812         * tests/test-netinet_in.c: New file.
136814         * modules/inttypes-tests: New file.
136815         * tests/test-inttypes.c: New file.
136817         * modules/fcntl-tests: New file.
136818         * tests/test-fcntl.c: New file.
136820         * modules/byteswap-tests: New file.
136821         * tests/test-byteswap.c: New file.
136823         * modules/arpa_inet-tests: New file.
136824         * tests/test-arpa_inet.c: New file.
136826 2007-02-17  Bruno Haible  <bruno@clisp.org>
136828         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
136829         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
136830         if the corresponding module is not enabled. Emit link warnings if
136831         the function is used nevertheless.
136832         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
136833         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
136834         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
136835         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
136836         * modules/inttypes (Depends-on): Add link-warning.
136837         (Makefile.am): Copy the contents of build-aux/link-warning.h into
136838         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
136839         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
136840         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
136841         * modules/imaxdiv (configure.ac): Likewise.
136842         * modules/strtoimax (configure.ac): Likewise.
136843         * modules/strtoumax (configure.ac): Likewise.
136845 2007-02-17  Bruno Haible  <bruno@clisp.org>
136847         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
136848         gl_STRING_MODULE_INDICATOR_DEFAULTS.
136849         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
136850         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
136852 2007-02-17  Bruno Haible  <bruno@clisp.org>
136854         * modules/link-warning: New file.
136855         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
136856         * lib/string_.h (GL_LINK_WARNING): Remove definition.
136857         * modules/string (Depends-on): Add link-warning.
136858         (Makefile.am): Copy the contents of build-aux/link-warning.h into
136859         string.h.
136860         * MODULES.html.sh (Support for building libraries and executables): Add
136861         link-warning.
136863 2007-02-17  Bruno Haible  <bruno@clisp.org>
136865         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
136866         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
136867         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
136868         long lines.
136870 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
136871             Bruno Haible  <bruno@clisp.org>
136873         * modules/tmpfile: New file.
136874         * lib/tmpfile.c: New file.
136875         * m4/tmpfile.m4: New file.
136876         * MODULES.html.sh (func_all_modules): New section "Input/output".
136878 2007-02-15  Bruno Haible  <bruno@clisp.org>
136880         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
136881         (supports_delete_on_close): New function.
136882         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
136884 2007-02-14  Bruno Haible  <bruno@clisp.org>
136886         * modules/mbspcasecmp-tests: New file.
136887         * tests/test-mbspcasecmp.sh: New file.
136888         * tests/test-mbspcasecmp.c: New file.
136890         New module mbspcasecmp.
136891         * modules/mbspcasecmp: New file.
136892         * lib/mbspcasecmp.c: New file.
136893         * lib/string_.h (strncasecmp): Change warning message.
136894         (mbspcasecmp): New declaration.
136895         * m4/mbspcasecmp.m4: New file.
136896         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
136897         GNULIB_MBSPCASECMP.
136898         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
136899         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
136901 2007-02-14  Bruno Haible  <bruno@clisp.org>
136903         * modules/mbsncasecmp-tests: New file.
136904         * tests/test-mbsncasecmp.sh: New file.
136905         * tests/test-mbsncasecmp.c: New file.
136907         New module mbsncasecmp.
136908         * modules/mbsncasecmp: New file.
136909         * lib/mbsncasecmp.c: New file.
136910         * lib/string_.h (mbsncasecmp): New declaration.
136911         * m4/mbsncasecmp.m4: New file.
136912         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
136913         GNULIB_MBSNCASECMP.
136914         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
136915         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
136917 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
136919         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
136920         Verify that it doesn't overlap with our flags.
136921         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
136922         do not have the desired effect in multibyte locales; instead, use
136923         mbscasecmp.
136924         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
136925         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
136926         we don't require GNU fnmatch ourselves (if our users require it, they
136927         should do so explicitly).
136929         Fix regex code so it doesn't rely on strcasecmp.
136930         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
136931         Otherwise, include gnulib's langinfo.h.
136932         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
136933         undesirable behavior in non-C locales.  Instead, rely on localecharset.
136934         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
136935         * modules/regex (FILES): Remove m4/codeset.m4.
136936         (Depends-on): Add localcharset.  Remove strcase.
136938 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
136940         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
136941         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
136943 2007-02-13  Bruno Haible  <bruno@clisp.org>
136945         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
136946         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
136948 2007-02-12  Bruno Haible  <bruno@clisp.org>
136950         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
136951         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
136952         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
136953         time warning rather than a link error.
136955 2007-02-12  Bruno Haible  <bruno@clisp.org>
136957         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
136958         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
136959         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
136961 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
136963         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
136964         args, not 2.
136966 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
136968         New module 'time', so that apps can include <time.h> as per
136969         POSIX and GNU instead of separate include files like time_r.h
136970         and timegm.h.  This implementation tries out a simpler approach
136971         for replacing decls in standard include files (as compared to
136972         the string module), somewhat as an experiment.
136974         * config/srclist.txt: Comment out mktime.c for now.
136975         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
136976         since it doesn't apply any more.  Use generic wording instead.
136977         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
136978         'time'.
136979         * lib/time_.h, m4/time_h.m4, modules/time: New files.
136980         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
136981         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
136982         Don't include <sys/types.h>; no longer needed since we assume C89.
136983         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
136984         * lib/strftime.c: Likewise.
136985         * lib/time_r.c: Likewise.
136986         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
136987         * lib/nanosleep.c: Include <time.h> first, to check interface.
136988         * lib/strptime.c: Likewise.
136989         * lib/time_r.c: Likewise.
136990         * lib/timegm.c: Likewise.
136991         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
136992         needed.
136993         * lib/timegm.c: Don't include timegm.h; no longer needed.
136994         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
136995         time.h now handles any problems in that area.
136996         (struct timespec, nanosleep): Remove; time.h now arranges for these.
136997         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
136998         that time.h defines struct timespec.
136999         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
137000         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
137001         handles that.
137002         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
137003         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
137004         needed.  Set REPLACE_LOCALTIME.
137005         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
137006         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
137007         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
137008         nanosleep; time_h.m4 now does that.  Don't require
137009         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
137010         module handles this now.
137011         * modules/getdate (Depends-on): Remove timespec.  Add time.
137012         * modules/nanosleep (Depends-on): Likewise.
137013         * modules/stat-time (Depends-on): Likewise.
137014         * modules/nanosleep (Include): Include time.h, not timespec.h.
137015         * modules/strptime (Files): Remove lib/strptime.h.
137016         (Depends-on): Add extensions, time.
137017         (Include): Include time.h, not strptime.h.
137018         * modules/time_r (Files): Remove lib/time_r.h.
137019         (Depends-on): Add time.
137020         (Include): Include time.h, not time_r.h.
137021         * modules/timegm: Likewise.
137022         * modules/timespec (Description): Now does timespec-related decls
137023         of our own, instead of struct timespec itself.
137024         (Depends-on): Add time; remove extensions.
137025         (Maintainer): Add self.
137026         * modules/utimecmp (Depends-on): Add time; remove timespec.
137027         * modules/utimens (Depends-on): Likewise.
137028         * modules/xnanosleep (Depends-on): Likewise.
137030 2007-02-11  Bruno Haible  <bruno@clisp.org>
137032         * lib/c-strstr.c: Include allocsa.h.
137033         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
137034         * lib/c-strcasestr.c: Include allocsa.h.
137035         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
137036         * lib/strcasestr.c: Include allocsa.h.
137037         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
137038         * lib/mbsstr.c: Include allocsa.h.
137039         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
137040         allocsa/freesa instead of malloc/free.
137041         * lib/mbscasestr.c: Include allocsa.h.
137042         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
137043         allocsa/freesa instead of malloc/free.
137044         * modules/c-strstr (Depends-on): Add allocsa.
137045         * modules/c-strcasestr (Depends-on): Likewise.
137046         * modules/strcasestr (Depends-on): Likewise.
137047         * modules/mbsstr (Depends-on): Likewise.
137048         * modules/mbscasestr (Depends-on): Likewise.
137050 2007-02-11  Bruno Haible  <bruno@clisp.org>
137052         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
137054         * modules/mbsspn-tests: New file.
137055         * tests/test-mbsspn.sh: New file.
137056         * tests/test-mbsspn.c: New file.
137058 2007-02-11  Bruno Haible  <bruno@clisp.org>
137060         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
137062         * modules/mbspbrk-tests: New file.
137063         * tests/test-mbspbrk.sh: New file.
137064         * tests/test-mbspbrk.c: New file.
137066 2007-02-11  Bruno Haible  <bruno@clisp.org>
137068         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
137069         unneeded cast.
137071         * modules/mbscspn-tests: New file.
137072         * tests/test-mbscspn.sh: New file.
137073         * tests/test-mbscspn.c: New file.
137075 2007-02-11  Bruno Haible  <bruno@clisp.org>
137077         * modules/mbscasecmp-tests: New file.
137078         * tests/test-mbscasecmp.sh: New file.
137079         * tests/test-mbscasecmp.c: New file.
137081 2007-02-11  Bruno Haible  <bruno@clisp.org>
137083         Ensure O(n) worst-case complexity of mbscasestr.
137084         * lib/mbscasestr.c: Include stdbool.h.
137085         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
137086         functions.
137087         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
137088         the bookkeeping indicates that it's worth it.
137089         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
137091         * modules/mbscasestr-tests: New file.
137092         * tests/test-mbscasestr1.c: New file.
137093         * tests/test-mbscasestr2.sh: New file.
137094         * tests/test-mbscasestr2.c: New file.
137095         * tests/test-mbscasestr3.sh: New file.
137096         * tests/test-mbscasestr3.c: New file.
137097         * tests/test-mbscasestr4.sh: New file.
137098         * tests/test-mbscasestr4.c: New file.
137099         * m4/locale-tr.m4: New file.
137101 2007-02-11  Bruno Haible  <bruno@clisp.org>
137103         Ensure O(n) worst-case complexity of mbsstr.
137104         * lib/mbsstr.c: Include stdbool.h.
137105         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
137106         functions.
137107         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
137108         bookkeeping indicates that it's worth it.
137109         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
137111         * modules/mbsstr-tests: New file.
137112         * tests/test-mbsstr1.c: New file.
137113         * tests/test-mbsstr2.sh: New file.
137114         * tests/test-mbsstr2.c: New file.
137115         * tests/test-mbsstr3.sh: New file.
137116         * tests/test-mbsstr3.c: New file.
137117         * m4/locale-fr.m4: New file.
137119 2007-02-11  Bruno Haible  <bruno@clisp.org>
137121         * lib/mbsrchr.c (mbsrchr): Fix bug.
137123         * modules/mbsrchr-tests: New file.
137124         * tests/test-mbsrchr.sh: New file.
137125         * tests/test-mbsrchr.c: New file.
137127 2007-02-11  Bruno Haible  <bruno@clisp.org>
137129         * lib/mbschr.c (mbschr): Fix bug.
137131         * modules/mbschr-tests: New file.
137132         * tests/test-mbschr.sh: New file.
137133         * tests/test-mbschr.c: New file.
137134         * m4/locale-zh.m4: New file.
137136 2007-02-11  Bruno Haible  <bruno@clisp.org>
137138         Support for copying multibyte string iterators.
137139         * lib/mbiter.h: Include <string.h>.
137140         (mbiter_multi_copy): New function.
137141         (mbi_copy): New macro.
137142         * lib/mbuiter.h: Include <string.h>.
137143         (mbuiter_multi_copy): New function.
137144         (mbui_copy): New macro.
137146 2007-02-11  Bruno Haible  <bruno@clisp.org>
137148         New module mbslen.
137149         * modules/mbslen: New file.
137150         * lib/mbslen.c: New file.
137151         * lib/string_.h (mbslen): New declaration.
137152         * m4/mbslen.m4: New file.
137153         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137154         GNULIB_MBSLEN.
137155         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
137156         * MODULES.html.sh (Internationalization functions): Add mbslen.
137158 2007-02-11  Bruno Haible  <bruno@clisp.org>
137160         Ensure O(n) worst-case complexity of strcasestr substitute.
137161         * lib/strcasestr.c: Include stdbool.h.
137162         (knuth_morris_pratt): New function.
137163         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
137164         bookkeeping indicates that it's worth it.
137165         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
137167         * modules/strcasestr-tests: New file.
137168         * tests/test-strcasestr.c: New file.
137170 2007-02-11  Bruno Haible  <bruno@clisp.org>
137172         Ensure O(n) worst-case complexity of c_strcasestr.
137173         * lib/c-strcasestr.c: Include stdbool.h, string.h.
137174         (knuth_morris_pratt): New function.
137175         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
137176         the bookkeeping indicates that it's worth it.
137177         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
137179         * modules/c-strcasestr-tests: New file.
137180         * tests/test-c-strcasestr.c: New file.
137182 2007-02-11  Bruno Haible  <bruno@clisp.org>
137184         Ensure O(n) worst-case complexity of c_strstr.
137185         * lib/c-strstr.c: Include stdbool.h, string.h.
137186         (knuth_morris_pratt): New function.
137187         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
137188         bookkeeping indicates that it's worth it.
137189         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
137191         * lib/c-strstr.c: Complete rewrite for maintainability.
137193         * modules/c-strstr-tests: New file.
137194         * tests/test-c-strstr.c: New file.
137196 2007-02-11  Bruno Haible  <bruno@clisp.org>
137198         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
137199         5.2.1 and earlier, whereby \055 was treated just like the range
137200         delimiter '-'.
137201         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
137203 2007-02-08  Bruno Haible  <bruno@clisp.org>
137205         * modules/regex (Depends-on): Add stdbool.
137206         Reported by Dalibor Topic <robilad@kaffe.org>.
137208 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
137210         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
137211         Prefer returning from main to exiting from it.
137212         Remove unnecessary parens after sizeof.
137214 2007-02-05  Bruno Haible  <bruno@clisp.org>
137216         New module mbssep.
137217         * modules/mbssep: New file.
137218         * lib/mbssep.c: New file.
137219         * lib/string_.h (strsep): Add a conditional link warning.
137220         (mbssep): New declaration.
137221         * m4/mbssep.m4: New file.
137222         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137223         GNULIB_MBSSEP.
137224         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
137225         * MODULES.html.sh (Internationalization functions): Add mbssep.
137227 2007-02-05  Bruno Haible  <bruno@clisp.org>
137229         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
137230         Optimize search in case of 1 delimiter.
137232 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
137234         * lib/acl.h: Include sys/types.h before sys/acl.h.
137236 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
137238         Merge upstream fix for glibc bugzilla #3957:
137240         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
137242         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
137243         bit for RE_HAT_LISTS_NOT_NEWLINE.
137244         (build_charclass_op): Remove bogus comment.
137246 2007-02-05  Simon Josefsson  <simon@josefsson.org>
137248         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
137250 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
137252         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
137253         * lib/memmem.c [!defined _LIBC]: Include config.h.
137255 2007-02-04  Bruno Haible  <bruno@clisp.org>
137257         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
137258         warning message.
137260 2007-02-04  Bruno Haible  <bruno@clisp.org>
137262         New module mbstok_r.
137263         * modules/mbstok_r: New file.
137264         * lib/mbstok_r.c: New file.
137265         * lib/string_.h (strtok_r): Change argument names to match the
137266         comments. Add a conditional link warning.
137267         (mbstok_r): New declaration.
137268         * m4/mbstok_r.m4: New file.
137269         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137270         GNULIB_MBSTOK_R.
137271         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
137272         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
137274 2007-02-04  Bruno Haible  <bruno@clisp.org>
137276         New module mbsspn.
137277         * modules/mbsspn: New file.
137278         * lib/mbsspn.c: New file.
137279         * lib/string_.h (strspn): Add a conditional link warning.
137280         (mbsspn): New declaration.
137281         * m4/mbsspn.m4: New file.
137282         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137283         GNULIB_MBSSPN.
137284         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
137285         * MODULES.html.sh (Internationalization functions): Add mbsspn.
137287 2007-02-04  Bruno Haible  <bruno@clisp.org>
137289         New module mbspbrk.
137290         * modules/mbspbrk: New file.
137291         * lib/mbspbrk.c: New file.
137292         * lib/string_.h (strpbrk): Add a conditional link warning.
137293         (mbspbrk): New declaration.
137294         * m4/mbspbrk.m4: New file.
137295         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137296         GNULIB_MBSPBRK.
137297         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
137298         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
137300 2007-02-04  Bruno Haible  <bruno@clisp.org>
137302         New module mbscspn.
137303         * modules/mbscspn: New file.
137304         * lib/mbscspn.c: New file.
137305         * lib/string_.h (strcspn): Add a conditional link warning.
137306         (mbscspn): New declaration.
137307         * m4/mbscspn.m4: New file.
137308         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137309         GNULIB_MBSCSPN.
137310         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
137311         * MODULES.html.sh (Internationalization functions): Add mbscspn.
137313 2007-02-04  Bruno Haible  <bruno@clisp.org>
137315         New module mbscasestr, reduced goal of strcasestr.
137316         * modules/mbscasestr: New file.
137317         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
137318         (mbscasestr): Renamed from strcasestr.
137319         * lib/strcasestr.c: Don't include mbuiter.h.
137320         (strcasestr): Remove support for multibyte locales.
137321         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
137322         Change the conditional link warning.
137323         (mbscasestr): New declaration.
137324         * m4/mbscasestr.m4: New file.
137325         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
137326         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
137327         REPLACE_STRCASESTR.
137328         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
137329         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
137330         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
137331         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
137332         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
137333         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
137334         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
137335         (Depends-on): Remove mbuiter.
137336         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
137338 2007-02-04  Bruno Haible  <bruno@clisp.org>
137340         Simplify handling of strncasecmp.
137341         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
137342         the conditional link warning.
137343         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
137344         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
137345         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
137346         * modules/strcase (configure.ac): Don't invoke
137347         gl_STRING_MODULE_INDICATOR.
137348         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
137350 2007-02-04  Bruno Haible  <bruno@clisp.org>
137352         New module mbscasecmp, reduced goal of strcasecmp.
137353         * modules/mbscasecmp: New file.
137354         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
137355         (mbscasecmp): Renamed from strcasecmp.
137356         * lib/strcasecmp.c: Don't include mbuiter.h.
137357         (strcasecmp): Remove support for multibyte locales.
137358         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
137359         Change the conditional link warning.
137360         (mbscasecmp): New declaration.
137361         * m4/mbscasecmp.m4: New file.
137362         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
137363         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
137364         REPLACE_STRCASECMP.
137365         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
137366         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137367         GNULIB_MBSCASECMP.
137368         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
137369         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
137370         * modules/strcase (Files): Remove m4/mbrtowc.m4.
137371         (Depends-on): Remove mbuiter.
137372         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
137374 2007-02-04  Bruno Haible  <bruno@clisp.org>
137376         New module mbsstr. Remove module strstr.
137377         * modules/mbsstr: New file.
137378         * modules/strstr: Remove file.
137379         * lib/mbsstr.c: Renamed from lib/strstr.c.
137380         (mbsstr): Renamed from strstr.
137381         * lib/string_.h (strstr): Remove declaration. Change the conditional
137382         link warning.
137383         (mbsstr): New declaration.
137384         * m4/mbsstr.m4: New file.
137385         * m4/strstr.m4: Remove file.
137386         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
137387         REPLACE_STRSTR.
137388         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
137389         Don't initialize GNULIB_STRSTR.
137390         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
137391         substitute GNULIB_STRSTR and REPLACE_STRSTR.
137392         * MODULES.html.sh (Internationalization functions): Add mbsstr.
137393         (Support for systems lacking ANSI C 89): Remove strstr.
137395 2007-02-04  Bruno Haible  <bruno@clisp.org>
137397         New module mbsrchr.
137398         * modules/mbsrchr: New file.
137399         * lib/mbsrchr.c: New file.
137400         * lib/string_.h (strrchr): Add a conditional link warning.
137401         (mbsrchr): New declaration.
137402         * m4/mbsrchr.m4: New file.
137403         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137404         GNULIB_MBSRCHR.
137405         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
137406         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
137408 2007-02-04  Bruno Haible  <bruno@clisp.org>
137410         New module mbschr.
137411         * modules/mbschr: New file.
137412         * lib/mbschr.c: New file.
137413         * lib/string_.h (strchr): Add a conditional link warning.
137414         (mbschr): New declaration.
137415         * m4/mbschr.m4: New file.
137416         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
137417         GNULIB_MBSCHR.
137418         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
137419         * MODULES.html.sh (Internationalization functions): Add mbschr.
137421 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
137423         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
137425         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
137427 2007-02-04  Bruno Haible  <bruno@clisp.org>
137429         New module description section 'configure.ac-early'.
137430         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
137431         (func_get_autoconf_early_snippet): New function.
137432         (func_import, func_create_testdir): Use it. Remove special cases for
137433         modules 'extensions' and 'lock'.
137434         * modules/extensions (configure.ac-early): Require
137435         gl_USE_SYSTEM_EXTENSIONS.
137436         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
137438 2007-02-04  Bruno Haible  <bruno@clisp.org>
137440         Make use of gcj-4.3's -fsource and -ftarget option.
137441         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
137442         and if so try the options -fsource and -ftarget.
137443         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
137444         source_version, ftarget_option, target_version arguments.
137445         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
137446         (is_envjavac_oldgcj_14_14_usable): Renamed from
137447         is_envjavac_gcj_14_14_usable.
137448         (is_envjavac_oldgcj_14_13_usable): Renamed from
137449         is_envjavac_gcj_14_13_usable.
137450         (is_gcj_present): Update.
137451         (is_gcj_43, is_gcj43_usable): New functions.
137452         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
137453         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
137454         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
137455         try the options -fsource and -ftarget.
137457 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
137459         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
137460         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
137461         larger value.
137463 2007-02-03  Jim Meyering  <jim@meyering.net>
137465         Give tools a better chance to allocate space for very large buffers.
137466         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
137468         Make pwd and readlink work also when run with an unreadable parent dir
137469         on systems with openat support.
137470         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
137471         provided getcwd function, even when we have openat support.
137472         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
137474 2007-02-02  Bruno Haible  <bruno@clisp.org>
137476         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
137477         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
137478         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
137479         portability problems if one of these functions is only used on specific
137480         platforms.
137481         Reported by Paul Eggert.
137483 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
137485         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
137486         is causing more trouble than it's curing.
137487         * lib/regex_internal.h (__mempcpy): Remove.
137488         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
137489         (and make the code a tad smaller to boot).
137490         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
137492 2007-02-02  Jim Meyering  <jim@meyering.net>
137494         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
137495         section, not in the Makefile.am: one.
137497 2007-02-02  Eric Blake  <ebb9@byu.net>
137499         * lib/strchrnul.c: Always include config.h first.
137501         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
137502         gnulib strstr is not necessary here.
137504 2007-02-02  Simon Josefsson  <simon@josefsson.org>
137506         * m4/socklen.m4: Fix typo.
137508 2007-02-02  Eric Blake  <ebb9@byu.net>
137510         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
137511         * modules/netinet_in (Makefile.am): Likewise.
137513 2007-02-01  Bruno Haible  <bruno@clisp.org>
137515         * lib/string_.h (GL_LINK_WARNING): New macro.
137516         (strcasecmp, strstr, strcasestr): If provided by the system,
137517         conditionally define as a macro that leads to a warning instead of to
137518         an error.
137519         (strncasecmp): Conditionally define as a macro that leads to a warning.
137521 2007-02-01  Karl Berry  <karl@gnu.org>
137523         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
137525 2007-02-01  Bruno Haible  <bruno@clisp.org>
137527         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
137528         renamings.
137530 2007-02-01  Eric Blake  <ebb9@byu.net>
137532         * modules/regex (Depends-on): Revert dependence on mempcpy.
137533         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
137534         module's definition of mempcpy.
137535         Reported by Paul Eggert.
137537 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
137539         * lib/string_.h: If the gnulib module XYZ is not present, undefine
137540         the symbol XYZ before redefining it.  This fixes a problem with
137541         programs that don't use XYZ, when compiled on systems that define
137542         XYZ to something else.
137544 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
137546         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
137547         occurs when "mkdir -m foo" creates a setgid directory that is (1)
137548         writeable to group or other and (2) is intended to have a special
137549         mode bit that is set or cleared.  In such a case, the directory
137550         should be neither group- nor other-writeable until the special
137551         mode bits are right.
137553 2007-01-31  Eric Blake  <ebb9@byu.net>
137555         * modules/mountlist (Depends-on): Add strstr.
137557         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
137558         bug.
137559         * modules/string (Makefile.am): Remove redundant replacement.
137560         * modules/regex (Depends-on): Add mempcpy.
137562 2007-01-31  Bruno Haible  <bruno@clisp.org>
137564         New module description field 'Link'.
137565         * gnulib-tool (func_usage): Document --extract-link-directive.
137566         (sed_extract_prog): Recognize 'Link' directive.
137567         (func_get_link_directive): New function.
137568         (func_import): Show summary of link directives.
137569         Handle --extract-link-directive option.
137570         * modules/acl (Link): New section.
137571         * modules/clock-time (Link): New section.
137572         * modules/euidaccess (Link): New section.
137573         * modules/gettext (Link): New section.
137574         * modules/iconv (Link): New section.
137575         * modules/lock (Link): New section.
137576         * modules/nanosleep (Link): New section.
137577         * modules/readline (Link): New section.
137579 2007-01-27  Bruno Haible  <bruno@clisp.org>
137581         Enforce the use of gnulib modules for unportable <string.h> functions.
137582         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
137583         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
137584         (gl_HEADER_STRING_H_BODY): Require it.
137585         * lib/string_.h: If the gnulib module XYZ is not present, redefine
137586         the symbol XYZ to one that gives a link error.
137587         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
137588         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
137589         * modules/mempcpy (configure.ac): Likewise.
137590         * modules/memrchr (configure.ac): Likewise.
137591         * modules/stpcpy (configure.ac): Likewise.
137592         * modules/stpncpy (configure.ac): Likewise.
137593         * modules/strcase (configure.ac): Likewise.
137594         * modules/strcasestr (configure.ac): Likewise.
137595         * modules/strchrnul (configure.ac): Likewise.
137596         * modules/strdup (configure.ac): Likewise.
137597         * modules/strndup (configure.ac): Likewise.
137598         * modules/strnlen (configure.ac): Likewise.
137599         * modules/strpbrk (configure.ac): Likewise.
137600         * modules/strsep (configure.ac): Likewise.
137601         * modules/strstr (configure.ac): Likewise.
137602         * modules/strtok_r (configure.ac): Likewise.
137604 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
137606         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
137608 2007-01-30  Jim Meyering  <jim@meyering.net>
137610         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
137612 2007-01-29  Bruno Haible  <bruno@clisp.org>
137614         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
137615         * lib/execute.c: Likewise.
137616         * lib/pipe.c: Likewise.
137617         * lib/printf-args.h: Likewise.
137618         * lib/printf-args.c: Likewise.
137619         * lib/printf-parse.c: Likewise.
137620         * lib/vasnprintf.c: Likewise.
137622 2007-01-29  Eric Blake  <ebb9@byu.net>
137624         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
137625         declaration.
137627 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
137629         * lib/strptime.h (strptime): Use 'restrict' for args where
137630         POSIX requires this.
137631         * lib/strptime.c (strptime): Likewise.
137632         Change license notice from LGPL to GPL, since gnulib-tool will
137633         change this as needed.
137634         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
137635         defined.
137636         Include "strptime.h" first, to check interface.
137637         Do not #undef _LIBC and _NL_CURRENT.
137638         Do not include <stdlib.h>; no longer needed.
137639         Include "time_r.h" and declare ptime_locale_status
137640         only if _LIBC is not defined.
137641         (__P): Remove unused macro.
137642         (match_string): Bring back glibc version, but use it only if _LIBC
137643         is defined.
137644         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
137645         Remove unnecessary assertion and abort() call.
137646         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
137647         * m4/strptime.m4: Fix serial number comment.
137648         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
137649         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
137650         (Depends-on): Add time_r.
137652 2007-01-29  Bruno Haible  <bruno@clisp.org>
137654         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
137655         strptime.
137656         * modules/strptime (Depends-on): Add stdbool.
137657         * lib/strptime.h: Include <time.h> always. Add comments.
137659 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
137661         * modules/strptime: New file.
137662         * lib/strptime.h: New file.
137663         * lib/strptime.c: New file.
137664         * m4/strptime.m4: New file.
137666 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
137668         * MODULES.html.sh: New module mpsort.
137669         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
137671         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
137672         a circularity problem with HP-UX ia64 reported by Bob Proulx in
137673         <http://lists.gnu.org/r/bug-gnulib/2007-01/msg00394.html>.
137674         All uses changed.
137675         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
137676         All uses changed.
137677         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
137678         to _Restrict_.
137679         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
137680         the parameter matches the prototype.
137682 2007-01-28  Jim Meyering  <jim@meyering.net>
137684         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
137685         sys/time.h here, reverting that part of the previous patch:
137686         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
137688 2007-01-28  Bruno Haible  <bruno@clisp.org>
137690         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
137691         value of $(SYS_TIME_H).
137692         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
137693         remove it conditionally, too. [added by Jim Meyering]
137694         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
137695         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
137696         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
137697         GETTIMEOFDAY_REPLACEMENT to 1.
137699 2007-01-28  Bruno Haible  <bruno@clisp.org>
137701         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
137702         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
137703         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
137704         Set UNISTD_H instead of UNISTD_H2.
137705         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
137707 2007-01-28  Bruno Haible  <bruno@clisp.org>
137709         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
137710         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
137712 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
137714         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
137715         (func_create_testdir): Ensure C locale for `grep' and `tr'
137716         character ranges.
137717         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
137718         ACLOCAL_AMFLAGS parsing state machine.
137720 2007-01-27  Bruno Haible  <bruno@clisp.org>
137722         * modules/unistr/base: Update.
137724 2007-01-27  Bruno Haible  <bruno@clisp.org>
137726         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
137727         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
137728         * modules/unistr/u32-mbtouc-unsafe: Renamed from
137729         modules/unistr/u32-mbtouc.
137730         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
137731         * lib/unistr.h: Update.
137732         * lib/linebreak.c: Update.
137733         * modules/unistr/u32-mbtouc: Renamed from
137734         modules/unistr/u32-mbtouc-safe.
137735         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
137736         * lib/unistr.h: Update.
137737         * lib/unistr/u32-to-u8.c: Update.
137738         * lib/unistr/u32-to-u16.c: Update.
137740 2007-01-27  Bruno Haible  <bruno@clisp.org>
137742         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
137743         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
137744         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
137745         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
137746         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
137747         * modules/unistr/u16-mbtouc-unsafe: Renamed from
137748         modules/unistr/u16-mbtouc.
137749         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
137750         * lib/unistr.h: Update.
137751         * lib/linebreak.c: Update.
137752         * modules/linebreak: Update.
137753         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
137754         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
137755         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
137756         * modules/unistr/u16-mbtouc: Renamed from
137757         modules/unistr/u16-mbtouc-safe.
137758         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
137759         * lib/unistr.h: Update.
137760         * lib/unistr/u16-to-u8.c: Update.
137761         * modules/unistr/u16-to-u8: Update.
137762         * lib/unistr/u16-to-u32.c: Update.
137763         * modules/unistr/u16-to-u32: Update.
137765 2007-01-27  Bruno Haible  <bruno@clisp.org>
137767         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
137768         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
137769         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
137770         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
137771         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
137772         * modules/unistr/u8-mbtouc-unsafe: Renamed from
137773         modules/unistr/u8-mbtouc.
137774         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
137775         * lib/unistr.h: Update.
137776         * lib/striconveh.c: Update.
137777         * modules/striconveh: Update.
137778         * lib/linebreak.c: Update.
137779         * modules/linebreak: Update.
137780         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
137781         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
137782         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
137783         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
137784         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
137785         * lib/unistr.h: Update.
137786         * lib/striconveh.c: Update.
137787         * modules/striconveh: Update.
137788         * lib/unistr/u8-to-u16.c: Update.
137789         * modules/unistr/u8-to-u16: Update.
137790         * lib/unistr/u8-to-u32.c: Update.
137791         * modules/unistr/u8-to-u32: Update.
137793 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
137795         Sync from Libtool.
137796         * lib/argz.c: Do not include strings.h nor memory.h, include
137797         string.h unconditionally.  Patch by Simon Josefsson.
137799 2007-01-27  Bruno Haible  <bruno@clisp.org>
137801         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
137802         from gl_HEADER_STRING_H_BODY.
137803         (gl_HEADER_STRING_H_BODY): Require it.
137804         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
137805         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
137806         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
137807         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
137808         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
137809         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
137810         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
137811         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
137812         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
137813         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
137814         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
137815         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
137816         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
137817         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
137818         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
137820 2007-01-27  Bruno Haible  <bruno@clisp.org>
137822         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
137823         check_PROGRAMS into noinst_PROGRAMS.
137824         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
137825         check_PROGRAMS in this case.
137826         (func_import): Set for_test to false.
137827         (func_create_testdir): Set for_test to true.
137829 2007-01-27  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
137830             Bruno Haible  <bruno@clisp.org>
137832         * modules/strcasestr (Files): Remove lib/strcasestr.h.
137833         (Depends-on): Add string.
137834         (Includes): Use <string.h> instead of strcasestr.h.
137835         * modules/string (Makefile.am): Also substitute the value of
137836         REPLACE_STRCASESTR.
137837         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
137838         assume strcasestr is declared in <string.h> not <strings.h>. Also
137839         set REPLACE_STRCASESTR.
137840         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
137841         REPLACE_STRCASESTR.
137842         * lib/strcasestr.h: Remove file.
137843         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
137844         * lib/string_.h (strcasestr): New declaration.
137846 2007-01-27  Bruno Haible  <bruno@clisp.org>
137848         * lib/string_.h: Use 'extern'.
137850 2007-01-27  Jim Meyering  <jim@meyering.net>
137852         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
137853         of set-but-not-used local, "q".
137855         * lib/mempcpy.c: Include <config.h> before <string.h>.
137856         This fixes a compilation error on HP-UX, due to the system's
137857         "restrict"-using mempcpy prototype.
137859 2007-01-26  Bruno Haible  <bruno@clisp.org>
137861         Small optimization.
137862         * lib/javacomp.c: Include c-strstr.h.
137863          (is_envjavac_gcj): Use c_strstr instead of strstr.
137864         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
137866 2007-01-26  Bruno Haible  <bruno@clisp.org>
137868         * MODULES.html.sh (Unicode string functions): Add the new modules.
137870         * modules/uniconv/u32-strconv-to-locale: New file.
137871         * lib/uniconv/u32-strconv-to-locale.c: New file.
137873         * modules/uniconv/u16-strconv-to-locale: New file.
137874         * lib/uniconv/u16-strconv-to-locale.c: New file.
137876         * modules/uniconv/u8-strconv-to-locale: New file.
137877         * lib/uniconv/u8-strconv-to-locale.c: New file.
137879         * modules/uniconv/u32-strconv-from-locale: New file.
137880         * lib/uniconv/u32-strconv-from-locale.c: New file.
137882         * modules/uniconv/u16-strconv-from-locale: New file.
137883         * lib/uniconv/u16-strconv-from-locale.c: New file.
137885         * modules/uniconv/u8-strconv-from-locale: New file.
137886         * lib/uniconv/u8-strconv-from-locale.c: New file.
137888         * modules/uniconv/u32-strconv-to-enc: New file.
137889         * lib/uniconv/u32-strconv-to-enc.c: New file.
137890         * modules/uniconv/u32-strconv-to-enc-tests: New file.
137891         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
137893         * modules/uniconv/u16-strconv-to-enc: New file.
137894         * lib/uniconv/u16-strconv-to-enc.c: New file.
137895         * lib/uniconv/u-strconv-to-enc.h: New file.
137896         * modules/uniconv/u16-strconv-to-enc-tests: New file.
137897         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
137899         * modules/uniconv/u8-strconv-to-enc: New file.
137900         * lib/uniconv/u8-strconv-to-enc.c: New file.
137901         * modules/uniconv/u8-strconv-to-enc-tests: New file.
137902         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
137904         * modules/uniconv/u32-strconv-from-enc: New file.
137905         * lib/uniconv/u32-strconv-from-enc.c: New file.
137906         * modules/uniconv/u32-strconv-from-enc-tests: New file.
137907         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
137909         * modules/uniconv/u16-strconv-from-enc: New file.
137910         * lib/uniconv/u16-strconv-from-enc.c: New file.
137911         * modules/uniconv/u16-strconv-from-enc-tests: New file.
137912         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
137914         * modules/uniconv/u8-strconv-from-enc: New file.
137915         * lib/uniconv/u8-strconv-from-enc.c: New file.
137916         * lib/uniconv/u-strconv-from-enc.h: New file.
137917         * modules/uniconv/u8-strconv-from-enc-tests: New file.
137918         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
137920         * modules/uniconv/u32-conv-from-enc: New file.
137921         * lib/uniconv/u32-conv-from-enc.c: New file.
137922         * modules/uniconv/u32-conv-from-enc-tests: New file.
137923         * tests/uniconv/test-u32-conv-from-enc.c: New file.
137925         * modules/uniconv/u16-conv-from-enc: New file.
137926         * lib/uniconv/u16-conv-from-enc.c: New file.
137927         * lib/uniconv/u-conv-from-enc.h: New file.
137928         * modules/uniconv/u16-conv-from-enc-tests: New file.
137929         * tests/uniconv/test-u16-conv-from-enc.c: New file.
137931         * modules/uniconv/u8-conv-from-enc: New file.
137932         * lib/uniconv/u8-conv-from-enc.c: New file.
137933         * modules/uniconv/u8-conv-from-enc-tests: New file.
137934         * tests/uniconv/test-u8-conv-from-enc.c: New file.
137936         * modules/uniconv/base: New file.
137937         * lib/uniconv.h: New file.
137939 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
137941         * doc/gnulib-tool.texi (Initial import): Update to match current
137942         behavior with strdup module.
137943         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
137944         * lib/memmem.h: Remove; all uses removed.  This is now done
137945         by <string.h>.
137946         * lib/mempcpy.h: Likewise.
137947         * lib/memrchr.h: Likewise.
137948         * lib/stpcpy.h: Likewise.
137949         * lib/stpncpy.h: Likewise.
137950         * lib/strcase.h: Likewise.
137951         * lib/strchrnul.h: Likewise.
137952         * lib/strdup.h: Likewise.
137953         * lib/strndup.h: Likewise.
137954         * lib/strnlen.h: Likewise.
137955         * lib/strpbrk.h: Likewise.
137956         * lib/strsep.h: Likewise.
137957         * lib/strstr.h: Likewise.
137958         * lib/strtok_r.h: Likewise.
137959         * lib/string_.h: New file.
137960         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
137961         Rely on <string.h> instead.
137962         * lib/canon-host.c: Likewise.
137963         * lib/chdir-long.c: Likewise.
137964         * lib/concatpath.c: Likewise.
137965         * lib/exclude.c: Likewise.
137966         * lib/fchdir.c: Likewise.
137967         * lib/getaddrinfo.c: Likewise.
137968         * lib/getcwd.c: Likewise.
137969         * lib/getsubopt.c: Likewise.
137970         * lib/glob.c: Likewise.
137971         * lib/hard-locale.c: Likewise.
137972         * lib/iconvme.c: Likewise.
137973         * lib/javacomp.c: Likewise.
137974         * lib/mempcpy.c: Likewise.
137975         * lib/memrchr.c: Likewise.
137976         * lib/regex_internal.h: Likewise.
137977         * lib/stpncpy.c: Likewise.
137978         * lib/strcasecmp.c: Likewise.
137979         * lib/strchrnul.c: Likewise.
137980         * lib/strdup.c: Likewise.
137981         * lib/striconv.c: Likewise.
137982         * lib/striconveh.c: Likewise.
137983         * lib/striconveha.c: Likewise.
137984         * lib/strncasecmp.c: Likewise.
137985         * lib/strndup.c: Likewise.
137986         * lib/strnlen.c: Likewise.
137987         * lib/strsep.c: Likewise.
137988         * lib/strstr.c: Likewise.
137989         * lib/strtok_r.c: Likewise.
137990         * lib/userspec.c: Likewise.
137991         * lib/w32spawn.h: Likewise.
137992         * lib/xstrndup.c: Likewise.
137993         * lib/mountlist.c (strstr): Remove decl.
137994         * m4/string_h.m4: New file.
137995         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
137996         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
137997         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
137998         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
137999         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
138000         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
138001         Set REPLACE_STRCASECMP if necessary.
138002         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
138003         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
138004         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
138005         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
138006         HAVE_DECL_STRDUP if necessary.
138007         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
138008         since gl_FUNC_STRNDUP does that now.
138009         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
138010         Check for decl here...
138011         (gl_PREREQ_STRNLEN): ... not here.
138012         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
138013         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
138014         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
138015         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
138016         necessary.
138017         * modules/string: New file.
138018         * modules/memmem (Files): Remove special-purpose include file.
138019         (Depends-on): Add string.
138020         (Include): Include <string.h>, not the removed file.
138021         * modules/mempcpy: Likewise.
138022         * modules/memrchr: Likewise.
138023         * modules/stpcpy: Likewise.
138024         * modules/stpncpy: Likewise.
138025         * modules/strcase: Likewise.
138026         * modules/strchrnul: Likewise.
138027         * modules/strdup: Likewise.
138028         * modules/strndup: Likewise.
138029         * modules/strnlen: Likewise.
138030         * modules/strpbrk: Likewise.
138031         * modules/strsep: Likewise.
138032         * modules/strstr: Likewise.
138033         * modules/strtok_r: Likewise.
138034         * tests/test-dirname.c: Don't include "strdup.h", since
138035         <string.h> now suffices.
138036         * tests/test-memmem.c: Don't include "memmem.h", since
138037         <string.h> now suffices.
138039 2007-01-25  Bruno Haible  <bruno@clisp.org>
138041         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
138042         *resultp is 0.
138044         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
138045         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
138046         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
138047         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
138049         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
138050         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
138051         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
138052         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
138053         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
138054         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
138056 2007-01-24  Bruno Haible  <bruno@clisp.org>
138058         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
138059         <http://lists.gnu.org/r/bug-gnulib/2006-10/msg00279.html>.
138060         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
138061         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
138062         gl_FUNC_FTS_CORE.
138063         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
138064         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
138065         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
138066         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
138067         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
138068         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
138069         gl_FUNC_FCHOWNAT.
138070         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
138071         gl_FUNC_STRFTIME.
138072         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
138073         Reported by Ralf Wildenhues.
138075 2007-01-24  Bruno Haible  <bruno@clisp.org>
138077         Drop AC_REQUIRE calls that are redundant with the module dependencies.
138078         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
138079         gl_GETADDRINFO.
138080         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
138081         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
138082         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
138084 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
138086         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
138087         Don't use 'exit'; just return from 'main'.
138088         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
138090         * lib/fnmatch_.h: Readjust white space and comments to match
138091         glibc, to avoid spurious diffs.
138093 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
138095         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
138096         2004-12-01 change by Jakub Jelinek, since this code won't compile
138097         if !LIBC.  Problem reported by Bob Proulx.
138099 2007-01-23  Bruno Haible  <bruno@clisp.org>
138101         * lib/striconveh.c: Include c-strcaseeq.h.
138102         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
138103         * modules/striconveh (Depends-on): Add c-strcaseeq.
138105 2007-01-23  Bruno Haible  <bruno@clisp.org>
138107         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
138109         * modules/c-strcaseeq: New file.
138110         * lib/c-strcaseeq.h: New file.
138112         * modules/streq: New file.
138113         * lib/streq.h: New file.
138115 2007-01-23  Bruno Haible  <bruno@clisp.org>
138117         * modules/striconveha-tests: New file.
138118         * tests/test-striconveha.c: New file.
138120         * lib/striconveha.h: Include <stdbool.h>.
138121         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
138122         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
138123         (mem_iconveha_notranslit): Renamed from mem_iconveha.
138124         (mem_iconveha): New function.
138125         (str_iconveha_notranslit): Renamed from str_iconveha.
138126         (str_iconveha): New function.
138127         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
138128         c-strcase.
138130 2007-01-23  Bruno Haible  <bruno@clisp.org>
138132         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
138133         encodings without forgiving before trying any encoding with handler.
138134         (str_iconveha): Try all encodings without forgiving before trying any
138135         encoding with handler.
138137 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
138139         Import the following changes from libc.
138141         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
138143         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
138145         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
138147         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
138148         normal_bracket label.
138150         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
138152         [BZ #361]
138153         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
138154         to normal_bracket after fetching the next character.
138156 2007-01-22  Bruno Haible  <bruno@clisp.org>
138158         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
138159         argument.
138160         * lib/striconveh.c (iconv_carefully_1): New function.
138161         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
138162         argument.
138163         (str_cd_iconveh): Update.
138164         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
138165         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
138166         * tests/test-striconveh.c (MAGIC): New macro.
138167         (new_offsets): New function.
138168         (main): Test call with and without offsets.
138170 2007-01-22  Bruno Haible  <bruno@clisp.org>
138172         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
138173         * modules/sys_select (Makefile.am): Likewise.
138174         * modules/sys_socket (Makefile.am): Likewise.
138175         * modules/sys_time (Makefile.am): Likewise.
138177 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
138179         * modules/gettimeofday (License): Change from GPL to LGPL, since
138180         gettimeofday is a library function.
138182 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
138184         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
138186 2007-01-21  Bruno Haible  <bruno@clisp.org>
138188         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
138190 2007-01-21  Bruno Haible  <bruno@clisp.org>
138192         * modules/striconveha: New file.
138193         * lib/striconveha.h: New file.
138194         * lib/striconveha.c: New file.
138195         * MODULES.html.sh (Internationalization functions): Add striconveha.
138196         * lib/striconv.c (str_iconv): Optimize the case of an empty input
138197         string.
138198         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
138200 2007-01-21  Bruno Haible  <bruno@clisp.org>
138202         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
138203         * lib/striconveh.c (str_iconveh): Likewise.
138205 2007-01-21  Bruno Haible  <bruno@clisp.org>
138207         * lib/striconveh.h (mem_iconveh): New declaration.
138208         * lib/striconveh.c (mem_iconveh): New function.
138209         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
138211 2007-01-21  Bruno Haible  <bruno@clisp.org>
138213         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
138215         * lib/striconveh.h (mem_cd_iconveh): Change specification.
138216         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
138217         original result buffer.
138218         (str_cd_iconveh): Update.
138219         * tests/test-striconveh.c (main): Update.
138221         * lib/striconv.h (mem_cd_iconv): Change specification.
138222         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
138223         result buffer.
138224         (str_cd_iconv): Update.
138225         * tests/test-striconv.c (main): Update.
138227 2007-01-21  Bruno Haible  <bruno@clisp.org>
138229         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
138231 2007-01-20  Jim Meyering  <jim@meyering.net>
138233         * lib/userspec.c (parse_with_separator): If a user or group string
138234         starts with "+", skip the corresponding name-to-ID look-up, since
138235         such a look-up must fail: user and group names may not include "+".
138237 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
138239         * lib/poll.c: Include sys/time.h and time.h unconditionally,
138240         since we now assume the sys_time module.
138241         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
138242         check for sys/time.h; no longer needed.
138243         * modules/poll (Depends-on): Depend on sys_time.
138245 2007-01-18  Bruno Haible  <bruno@clisp.org>
138247         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
138248         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
138250         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
138251         gettimeofday.
138253         * tests/test-gettimeofday.c: Include <time.h>.
138254         (dummy): Remove variable.
138256         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
138257         gl_HEADER_SYS_TIME_H.
138258         (gl_HEADER_SYS_TIME_H): New macro.
138260         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
138261         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
138262         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
138263         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
138264         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
138265         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
138266         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
138267         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
138268         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
138269         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
138270         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
138272         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
138273         last change; it caused a compilation error when cross-compiling to
138274         Cygwin.
138276 2007-01-18  Jim Meyering  <jim@meyering.net>
138278         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
138279         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
138280         than the race-prone "test -d sys || mkdir sys".
138281         (configure.ac): Use AC_PROG_MKDIR_P.
138282         * modules/sys_select: Likewise.
138283         * modules/sys_socket: Likewise.
138284         * modules/sys_time: Likewise.
138286 2007-01-18  Eric Blake  <ebb9@byu.net>
138288         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
138289         replace gettimeofday.
138290         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
138291         name, to avoid infinite recursion.
138293 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
138295         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
138296         module sys_time.
138297         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
138298         assume timespec.h defines struct timeval.
138299         * lib/settime.c: Likewise.
138300         * lib/utimens.c: Likewise.
138301         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
138302         since we now assume the gettimeofday module.
138303         * lib/tempname.c (__gen_tempname): Likewise.
138304         * lib/gettimeofday.h: Remove.
138305         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
138306         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
138307         Include <time.h>, for 'time()'.
138308         (localtime_buffer_addr): Also use this workaround if
138309         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
138310         to simplify the uses.  All uses changed.
138311         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
138312         that #undef is inside {}, and 'const' follows type name consistently.
138313         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
138314         (gettimeofday): Do not use the maximum possible value for
138315         tv->tv_usec, since that might break usages other than ls.c.
138316         Instead, we'll leave ls.c alone.  This undoes today's patch
138317         by Bruno.  Add a compile-time warning for 1s-clock resolution;
138318         we've never observed the problem but might as well keep the
138319         canary.
138320         * lib/nanosleep.c: Include timespec.h first, for interface check.
138321         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
138322         now assume the sys_time module.
138323         * lib/tempname.c: Likewise.
138324         * lib/timespec.h: Likewise.
138325         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
138326         needed.
138327         * lib/strftime.c: Likewise.
138328         * lib/timespec.h: Likewise.
138329         * lib/posixtm.c: Include posixtm.h first, for interface check.
138330         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
138331         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
138332         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
138333         * lib/sys_time_.h: New file.
138334         * lib/timespec.h (struct timespec): Use long int, not long.
138335         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
138336         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
138337         Remove obsolescent call to AC_HEADER_TIME.
138338         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
138339         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
138340         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
138341         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
138342         Likewise.
138343         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
138344         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
138345         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
138346         into the sys_time module.  Check for gettimeofday just once.
138347         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
138348         for gettimeofday signature to just check the signature.  Merely
138349         compile it, since linking doesn't test signature.  Improve test for
138350         whether gettimeofday.o is actually needed.
138351         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
138352         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
138353         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
138354         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
138355         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
138356         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
138357         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
138358         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
138359         than worrying about sys/time.h.
138360         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
138361         Don't bother worrying about TIME_WITH_SYS_TIME.
138362         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
138363         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
138364         * m4/sys_time_h.m4: New file.
138365         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
138366         Don't include sys/time.h.  Return from main rather than exiting.
138367         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
138368         all uses changed.
138369         * modules/gethrxtime (Depends-on): Add sys_time.
138370         * modules/gettime (Depends-on): Likewise.
138371         * modules/gettimeofday (Depends-on): Likewise.
138372         * modules/nanosleep (Depends-on): Likewise.
138373         * modules/settime (Depends-on): Likewise.
138374         * modules/tempname (Depends-on): Likewise.
138375         * modules/utimens (Depends-on): Likewise.
138376         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
138377         (Include): Change back to <sys/time.h>.
138378         (Maintainer): Add self.
138379         * modules/sys_time: New file.
138380         * modules/tempname (Depends-on): Add gettimeofday.
138381         * tests/test-gettimeofday.c: Include <sys/time.h>
138382         rather than gettimeofday.h.
138384 2007-01-17  Bruno Haible  <bruno@clisp.org>
138386         * gnulib-tool (func_get_license): Revert last patch. Instead, let
138387         the license default to GPL.
138388         (func_create_testdir): Don't complain if a module is LGPL and its
138389         tests module depends on GPLed modules.
138391 2007-01-17  Bruno Haible  <bruno@clisp.org>
138393         * lib/gettimeofday.c (gettimeofday): Add code for the case
138394         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
138395         maximum possible value for tv->tv_usec, rather than the minimum one.
138397 2005-10-08  Martin Lambers  <marlam@marlam.de>
138398 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
138399 2007-01-16  Bruno Haible  <bruno@clisp.org>
138401         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
138402         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
138403         gl_FUNC_GETTIMEOFDAY.
138404         (Include): Add gettimeofday.h.
138405         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
138406         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
138407         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
138408         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
138409         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
138410         * lib/gettimeofday.h: New file.
138411         * lib/gettimeofday.c: Include <sys/timeb.h>.
138412         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
138413         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
138414         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
138415         fall back on time().
138417         * tests/test-gettimeofday.c: New file.
138418         * modules/gettimeofday-tests: New file.
138420 2007-01-16  Eric Blake  <ebb9@byu.net>
138422         * modules/fnmatch (Depends-on): Depend on wchar.
138423         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
138424         * m4/fnmatch.m4: Likewise.
138425         * modules/mbchar (Makefile.am): Assume <wchar.h>.
138426         * m4/mbchar.m4: Likewise.
138427         * modules/mbswidth (Depends-on): Depend on wchar.
138428         * lib/mbswidth.c: Assume <wchar.h>.
138429         * m4/mbswidth.m4: Likewise.
138430         * modules/quotearg (Depends-on): Depend on wchar.
138431         * lib/quotearg.c: Assume <wchar.h>.
138432         * m4/quotearg.m4: Likewise.
138433         * modules/regex (Depends-on): Depend on wchar.
138434         * lib/regex_internal.h: Assume <wchar.h>.
138435         * m4/regex.m4: Likewise.
138436         * modules/stdint (Depends-on): Depend on wchar.
138437         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
138438         * m4/stdint.m4: Likewise.
138439         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
138440         * modules/strftime (Depends-on): Depend on wchar.
138441         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
138442         * modules/strtol (Depends-on): Depend on wchar.
138443         * lib/strtol.c: Assume <wchar.h>.
138444         * modules/wcwidth (Depends-on): Depend on wchar.
138445         * lib/wcwidth.h: Assume <wchar.h>.
138446         * m4/wcwidth.m4: Likewise.
138448 2007-01-16  Bruno Haible  <bruno@clisp.org>
138450         * modules/csharpexec-script: New, created from...
138451         * modules/csharpexec: ... this.
138453 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
138455         * modules/javaexec-script: New, created from...
138456         * modules/javaexec: ... this.
138458 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
138460         * modules/poll (Dependencies): Add sys_select.
138462 2007-01-15  Jim Meyering  <jim@meyering.net>
138464         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
138465         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
138466         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
138467         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
138469 2007-01-15  Bruno Haible  <bruno@clisp.org>
138471         * modules/striconveh: New file.
138472         * lib/striconveh.h: New file.
138473         * lib/striconveh.c: New file.
138474         * MODULES.html.sh (Internationalization functions): Add striconveh.
138476         * modules/striconveh-tests: New file.
138477         * tests/test-striconveh.c: New file.
138479 2007-01-15  Bruno Haible  <bruno@clisp.org>
138481         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
138482         not from GNU libiconv or GNU libc.
138484 2007-01-15  Bruno Haible  <bruno@clisp.org>
138486         * doc/gnulib-intro.texi (Copyright): Explain the different license
138487         terms for module descriptions, autoconf macros, tests, documentation.
138489 2007-01-14  Bruno Haible  <bruno@clisp.org>
138491         * modules/striconv-tests: New file.
138492         * tests/test-striconv.c: New file.
138494 2007-01-14  Bruno Haible  <bruno@clisp.org>
138496         * modules/iconv-tests: New file.
138497         * tests/test-iconv.c: New file.
138499 2007-01-14  Bruno Haible  <bruno@clisp.org>
138501         * gnulib-tool (func_get_license): For test modules, use the license of
138502         the main module.
138504 2007-01-14  Bruno Haible  <bruno@clisp.org>
138506         * modules/iconv (Include): Clarify that <iconv.h> can only be included
138507         if iconv is found to exist.
138509 2007-01-14  Bruno Haible  <bruno@clisp.org>
138511         * modules/c-ctype-tests: New file.
138512         * tests/test-c-ctype.c: New file.
138514 2007-01-14  Bruno Haible  <bruno@clisp.org>
138516         * modules/binary-io-tests: New file.
138517         * tests/test-binary-io.sh: New file.
138518         * tests/test-binary-io.c: New file.
138520 2007-01-14  Bruno Haible  <bruno@clisp.org>
138522         * modules/array-oset-tests: New file.
138523         * tests/test-array_oset.c: New file.
138525 2007-01-14  Bruno Haible  <bruno@clisp.org>
138527         * modules/array-list-tests: New file.
138528         * tests/test-array_list.c: New file.
138530 2007-01-14  Bruno Haible  <bruno@clisp.org>
138532         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
138533         and make.
138534         Reported by Simon Josefsson in
138535         <http://lists.gnu.org/r/bug-gnulib/2007-01/msg00139.html>
138537 2007-01-14  Bruno Haible  <bruno@clisp.org>
138539         * modules/allocsa-tests: New file.
138540         * tests/test-allocsa.c: New file.
138542 2007-01-14  Bruno Haible  <bruno@clisp.org>
138544         * modules/fchdir (Depends-on): Add absolute-header.
138545         * modules/unistd (Depends-on): Likewise.
138547 2006-12-30  Bruno Haible  <bruno@clisp.org>
138549         * modules/fchdir: New file.
138550         * modules/unistd (Files): Add lib/unistd_.h.
138551         (Makefile.am): Generate unistd.h from unistd_.h.
138552         * lib/fchdir.c: New file.
138553         * lib/dirent_.h: New file.
138554         * lib/unistd_.h: New file.
138555         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
138556         * m4/fchdir.m4: New file.
138557         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
138558         (gl_HEADER_UNISTD): Invoke it.
138559         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
138560         function.
138561         * lib/backupfile.c (opendir, closedir): Undefine.
138562         * lib/chown.c (open, close): Undefine.
138563         * lib/clean-temp.c (open, close): Undefine.
138564         * lib/copy-file.c (open, close): Undefine.
138565         * lib/execute.c (open, close): Undefine.
138566         * lib/fsusage.c (open, close): Undefine.
138567         * lib/gc-gnulib.c (open, close): Undefine.
138568         * lib/getcwd.c (opendir, closedir): Undefine.
138569         * lib/glob.c (opendir, closedir): Undefine.
138570         * lib/javacomp.c (open, close): Undefine.
138571         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
138572         * lib/openat-proc.c (open, close): Undefine.
138573         * lib/pagealign_alloc.c (open, close): Undefine.
138574         * lib/pipe.c (open, close): Undefine.
138575         * lib/progreloc.c (open, close): Undefine.
138576         * lib/savedir.c (opendir, closedir): Undefine.
138577         * lib/utime.c (open, close): Undefine.
138578         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
138580 2007-01-10  Bruno Haible  <bruno@clisp.org>
138582         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
138584 2007-01-12  Eric Blake  <ebb9@byu.net>
138586         Provide a robust <wchar.h>.  Further simplifications are now
138587         possible in other modules, but not included here.
138588         * modules/wchar: New module.
138589         * m4/wchar.m4: New file.
138590         * lib/wchar_.h: Likewise.
138591         * modules/mbchar (Depends-on): Depend on wchar, as the first use
138592         of the new module.
138593         * MODULES.html.sh (Extended multibyte and wide character utilities):
138594         New section.
138596 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
138598         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
138599         to a reasonable default for memory allocation.
138600         (xreadlink): Don't allocate a huge buffer, to work around a buggy
138601         file system that reports garbage st_size values for symlinks.
138602         Problem reported by Liyang Hu.
138604 2007-01-11  Simon Josefsson  <simon@josefsson.org>
138606         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
138607         Emacs .#* auto-save files).
138609 2007-01-11  Bruno Haible  <bruno@clisp.org>
138611         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
138612         directory.
138614 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
138616         Use @...@ consistently in lib/wctype_.h.
138617         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
138618         on it being set to 1 or 0.
138619         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
138620         go back to AC_SUBSTing it.
138621         * modules/wctype (Makefile.am): Undo previous change.
138623 2007-01-10  Eric Blake  <ebb9@byu.net>
138625         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
138626         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
138627         * modules/wctype (Makefile.am): Likewise.
138628         Reported by Chris McGuire.
138630 2007-01-10  Jim Meyering  <jim@meyering.net>
138632         fts.c: a small readability/maintainability improvement
138633         * lib/fts.c (fts_read): Make this code slightly more readable and
138634         maintainable by hoisting the "sp->fts_cur = p" assignments to
138635         immediately follow the statements that set P.  Derived from
138636         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
138638 2007-01-10  Eric Blake  <ebb9@byu.net>
138640         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
138641         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
138642         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
138643         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
138644         Reported by Chris McGuire.
138646 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
138648         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
138649         in sed script.
138651 2007-01-09  Bruno Haible  <bruno@clisp.org>
138653         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
138654         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
138655         variables.
138656         (func_module): Use them.
138658 2007-01-09  Bruno Haible  <bruno@clisp.org>
138660         * modules/unistr/base: New file.
138661         * lib/unistr.h: New file.
138663         * modules/unistr/u8-to-u16: New file.
138664         * lib/unistr/u8-to-u16.c: New file.
138666         * modules/unistr/u8-to-u32: New file.
138667         * lib/unistr/u8-to-u32.c: New file.
138669         * modules/unistr/u16-to-u8: New file.
138670         * lib/unistr/u16-to-u8.c: New file.
138672         * modules/unistr/u16-to-u32: New file.
138673         * lib/unistr/u16-to-u32.c: New file.
138675         * modules/unistr/u32-to-u8: New file.
138676         * lib/unistr/u32-to-u8.c: New file.
138678         * modules/unistr/u32-to-u16: New file.
138679         * lib/unistr/u32-to-u16.c: New file.
138681         * modules/unistr/u8-check: New file.
138682         * modules/unistr/u16-check: New file.
138683         * modules/unistr/u32-check: New file.
138684         * lib/unistr/u8-check.c: New file.
138685         * lib/unistr/u16-check.c: New file.
138686         * lib/unistr/u32-check.c: New file.
138688         * modules/unistr/u8-chr: New file.
138689         * modules/unistr/u16-chr: New file.
138690         * modules/unistr/u32-chr: New file.
138691         * lib/unistr/u8-chr.c: New file.
138692         * lib/unistr/u16-chr.c: New file.
138693         * lib/unistr/u32-chr.c: New file.
138695         * modules/unistr/u8-cmp: New file.
138696         * modules/unistr/u16-cmp: New file.
138697         * modules/unistr/u32-cmp: New file.
138698         * lib/unistr/u8-cmp.c: New file.
138699         * lib/unistr/u16-cmp.c: New file.
138700         * lib/unistr/u32-cmp.c: New file.
138702         * modules/unistr/u8-cpy: New file.
138703         * modules/unistr/u16-cpy: New file.
138704         * modules/unistr/u32-cpy: New file.
138705         * lib/unistr/u8-cpy.c: New file.
138706         * lib/unistr/u16-cpy.c: New file.
138707         * lib/unistr/u32-cpy.c: New file.
138708         * lib/unistr/u-cpy.h: New file.
138710         * modules/unistr/u8-cpy-alloc: New file.
138711         * modules/unistr/u16-cpy-alloc: New file.
138712         * modules/unistr/u32-cpy-alloc: New file.
138713         * lib/unistr/u8-cpy-alloc.c: New file.
138714         * lib/unistr/u16-cpy-alloc.c: New file.
138715         * lib/unistr/u32-cpy-alloc.c: New file.
138716         * lib/unistr/u-cpy-alloc.h: New file.
138718         * modules/unistr/u8-endswith: New file.
138719         * modules/unistr/u16-endswith: New file.
138720         * modules/unistr/u32-endswith: New file.
138721         * lib/unistr/u8-endswith.c: New file.
138722         * lib/unistr/u16-endswith.c: New file.
138723         * lib/unistr/u32-endswith.c: New file.
138724         * lib/unistr/u-endswith.h: New file.
138726         * modules/unistr/u8-mblen: New file.
138727         * modules/unistr/u16-mblen: New file.
138728         * modules/unistr/u32-mblen: New file.
138729         * lib/unistr/u8-mblen.c: New file.
138730         * lib/unistr/u16-mblen.c: New file.
138731         * lib/unistr/u32-mblen.c: New file.
138733         * modules/unistr/u8-mbtouc: New file.
138734         * modules/unistr/u16-mbtouc: New file.
138735         * modules/unistr/u32-mbtouc: New file.
138736         * lib/unistr/u8-mbtouc.c: New file.
138737         * lib/unistr/u16-mbtouc.c: New file.
138738         * lib/unistr/u32-mbtouc.c: New file.
138740         * modules/unistr/u8-mbtouc-safe: New file.
138741         * modules/unistr/u16-mbtouc-safe: New file.
138742         * modules/unistr/u32-mbtouc-safe: New file.
138743         * lib/unistr/u8-mbtouc-safe.c: New file.
138744         * lib/unistr/u16-mbtouc-safe.c: New file.
138745         * lib/unistr/u32-mbtouc-safe.c: New file.
138747         * modules/unistr/u8-move: New file.
138748         * modules/unistr/u16-move: New file.
138749         * modules/unistr/u32-move: New file.
138750         * lib/unistr/u8-move.c: New file.
138751         * lib/unistr/u16-move.c: New file.
138752         * lib/unistr/u32-move.c: New file.
138753         * lib/unistr/u-move.h: New file.
138755         * modules/unistr/u8-next: New file.
138756         * modules/unistr/u16-next: New file.
138757         * modules/unistr/u32-next: New file.
138758         * lib/unistr/u8-next.c: New file.
138759         * lib/unistr/u16-next.c: New file.
138760         * lib/unistr/u32-next.c: New file.
138762         * modules/unistr/u8-prev: New file.
138763         * modules/unistr/u16-prev: New file.
138764         * modules/unistr/u32-prev: New file.
138765         * lib/unistr/u8-prev.c: New file.
138766         * lib/unistr/u16-prev.c: New file.
138767         * lib/unistr/u32-prev.c: New file.
138769         * modules/unistr/u8-set: New file.
138770         * modules/unistr/u16-set: New file.
138771         * modules/unistr/u32-set: New file.
138772         * lib/unistr/u8-set.c: New file.
138773         * lib/unistr/u16-set.c: New file.
138774         * lib/unistr/u32-set.c: New file.
138775         * lib/unistr/u-set.h: New file.
138777         * modules/unistr/u8-startswith: New file.
138778         * modules/unistr/u16-startswith: New file.
138779         * modules/unistr/u32-startswith: New file.
138780         * lib/unistr/u8-startswith.c: New file.
138781         * lib/unistr/u16-startswith.c: New file.
138782         * lib/unistr/u32-startswith.c: New file.
138783         * lib/unistr/u-startswith.h: New file.
138785         * modules/unistr/u8-stpcpy: New file.
138786         * modules/unistr/u16-stpcpy: New file.
138787         * modules/unistr/u32-stpcpy: New file.
138788         * lib/unistr/u8-stpcpy.c: New file.
138789         * lib/unistr/u16-stpcpy.c: New file.
138790         * lib/unistr/u32-stpcpy.c: New file.
138791         * lib/unistr/u-stpcpy.h: New file.
138793         * modules/unistr/u8-stpncpy: New file.
138794         * modules/unistr/u16-stpncpy: New file.
138795         * modules/unistr/u32-stpncpy: New file.
138796         * lib/unistr/u8-stpncpy.c: New file.
138797         * lib/unistr/u16-stpncpy.c: New file.
138798         * lib/unistr/u32-stpncpy.c: New file.
138799         * lib/unistr/u-stpncpy.h: New file.
138801         * modules/unistr/u8-strcat: New file.
138802         * modules/unistr/u16-strcat: New file.
138803         * modules/unistr/u32-strcat: New file.
138804         * lib/unistr/u8-strcat.c: New file.
138805         * lib/unistr/u16-strcat.c: New file.
138806         * lib/unistr/u32-strcat.c: New file.
138807         * lib/unistr/u-strcat.h: New file.
138809         * modules/unistr/u8-strchr: New file.
138810         * modules/unistr/u16-strchr: New file.
138811         * modules/unistr/u32-strchr: New file.
138812         * lib/unistr/u8-strchr.c: New file.
138813         * lib/unistr/u16-strchr.c: New file.
138814         * lib/unistr/u32-strchr.c: New file.
138816         * modules/unistr/u8-strcmp: New file.
138817         * modules/unistr/u16-strcmp: New file.
138818         * modules/unistr/u32-strcmp: New file.
138819         * lib/unistr/u8-strcmp.c: New file.
138820         * lib/unistr/u16-strcmp.c: New file.
138821         * lib/unistr/u32-strcmp.c: New file.
138823         * modules/unistr/u8-strcpy: New file.
138824         * modules/unistr/u16-strcpy: New file.
138825         * modules/unistr/u32-strcpy: New file.
138826         * lib/unistr/u8-strcpy.c: New file.
138827         * lib/unistr/u16-strcpy.c: New file.
138828         * lib/unistr/u32-strcpy.c: New file.
138829         * lib/unistr/u-strcpy.h: New file.
138831         * modules/unistr/u8-strcspn: New file.
138832         * modules/unistr/u16-strcspn: New file.
138833         * modules/unistr/u32-strcspn: New file.
138834         * lib/unistr/u8-strcspn.c: New file.
138835         * lib/unistr/u16-strcspn.c: New file.
138836         * lib/unistr/u32-strcspn.c: New file.
138837         * lib/unistr/u-strcspn.h: New file.
138839         * modules/unistr/u8-strdup: New file.
138840         * modules/unistr/u16-strdup: New file.
138841         * modules/unistr/u32-strdup: New file.
138842         * lib/unistr/u8-strdup.c: New file.
138843         * lib/unistr/u16-strdup.c: New file.
138844         * lib/unistr/u32-strdup.c: New file.
138845         * lib/unistr/u-strdup.h: New file.
138847         * modules/unistr/u8-strlen: New file.
138848         * modules/unistr/u16-strlen: New file.
138849         * modules/unistr/u32-strlen: New file.
138850         * lib/unistr/u8-strlen.c: New file.
138851         * lib/unistr/u16-strlen.c: New file.
138852         * lib/unistr/u32-strlen.c: New file.
138853         * lib/unistr/u-strlen.h: New file.
138855         * modules/unistr/u8-strmblen: New file.
138856         * modules/unistr/u16-strmblen: New file.
138857         * modules/unistr/u32-strmblen: New file.
138858         * lib/unistr/u8-strmblen.c: New file.
138859         * lib/unistr/u16-strmblen.c: New file.
138860         * lib/unistr/u32-strmblen.c: New file.
138862         * modules/unistr/u8-strmbtouc: New file.
138863         * modules/unistr/u16-strmbtouc: New file.
138864         * modules/unistr/u32-strmbtouc: New file.
138865         * lib/unistr/u8-strmbtouc.c: New file.
138866         * lib/unistr/u16-strmbtouc.c: New file.
138867         * lib/unistr/u32-strmbtouc.c: New file.
138869         * modules/unistr/u8-strncat: New file.
138870         * modules/unistr/u16-strncat: New file.
138871         * modules/unistr/u32-strncat: New file.
138872         * lib/unistr/u8-strncat.c: New file.
138873         * lib/unistr/u16-strncat.c: New file.
138874         * lib/unistr/u32-strncat.c: New file.
138875         * lib/unistr/u-strncat.h: New file.
138877         * modules/unistr/u8-strncmp: New file.
138878         * modules/unistr/u16-strncmp: New file.
138879         * modules/unistr/u32-strncmp: New file.
138880         * lib/unistr/u8-strncmp.c: New file.
138881         * lib/unistr/u16-strncmp.c: New file.
138882         * lib/unistr/u32-strncmp.c: New file.
138884         * modules/unistr/u8-strncpy: New file.
138885         * modules/unistr/u16-strncpy: New file.
138886         * modules/unistr/u32-strncpy: New file.
138887         * lib/unistr/u8-strncpy.c: New file.
138888         * lib/unistr/u16-strncpy.c: New file.
138889         * lib/unistr/u32-strncpy.c: New file.
138890         * lib/unistr/u-strncpy.h: New file.
138892         * modules/unistr/u8-strnlen: New file.
138893         * modules/unistr/u16-strnlen: New file.
138894         * modules/unistr/u32-strnlen: New file.
138895         * lib/unistr/u8-strnlen.c: New file.
138896         * lib/unistr/u16-strnlen.c: New file.
138897         * lib/unistr/u32-strnlen.c: New file.
138898         * lib/unistr/u-strnlen.h: New file.
138900         * modules/unistr/u8-strpbrk: New file.
138901         * modules/unistr/u16-strpbrk: New file.
138902         * modules/unistr/u32-strpbrk: New file.
138903         * lib/unistr/u8-strpbrk.c: New file.
138904         * lib/unistr/u16-strpbrk.c: New file.
138905         * lib/unistr/u32-strpbrk.c: New file.
138906         * lib/unistr/u-strpbrk.h: New file.
138908         * modules/unistr/u8-strrchr: New file.
138909         * modules/unistr/u16-strrchr: New file.
138910         * modules/unistr/u32-strrchr: New file.
138911         * lib/unistr/u8-strrchr.c: New file.
138912         * lib/unistr/u16-strrchr.c: New file.
138913         * lib/unistr/u32-strrchr.c: New file.
138915         * modules/unistr/u8-strspn: New file.
138916         * modules/unistr/u16-strspn: New file.
138917         * modules/unistr/u32-strspn: New file.
138918         * lib/unistr/u8-strspn.c: New file.
138919         * lib/unistr/u16-strspn.c: New file.
138920         * lib/unistr/u32-strspn.c: New file.
138921         * lib/unistr/u-strspn.h: New file.
138923         * modules/unistr/u8-strstr: New file.
138924         * modules/unistr/u16-strstr: New file.
138925         * modules/unistr/u32-strstr: New file.
138926         * lib/unistr/u8-strstr.c: New file.
138927         * lib/unistr/u16-strstr.c: New file.
138928         * lib/unistr/u32-strstr.c: New file.
138929         * lib/unistr/u-strstr.h: New file.
138931         * modules/unistr/u8-strtok: New file.
138932         * modules/unistr/u16-strtok: New file.
138933         * modules/unistr/u32-strtok: New file.
138934         * lib/unistr/u8-strtok.c: New file.
138935         * lib/unistr/u16-strtok.c: New file.
138936         * lib/unistr/u32-strtok.c: New file.
138937         * lib/unistr/u-strtok.h: New file.
138939         * modules/unistr/u8-uctomb: New file.
138940         * modules/unistr/u16-uctomb: New file.
138941         * modules/unistr/u32-uctomb: New file.
138942         * lib/unistr/u8-uctomb.c: New file.
138943         * lib/unistr/u16-uctomb.c: New file.
138944         * lib/unistr/u32-uctomb.c: New file.
138946         * MODULES.html.sh (Unicode string functions): Add the new modules.
138948 2007-01-08  Bruno Haible  <bruno@clisp.org>
138950         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
138951         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
138952         subdirectories.
138954 2007-01-08  Karl Berry  <karl@gnu.org>
138956         * doc/error.texi: mention that main() fns must set program_name
138957         when progname is used.
138959 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
138961         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
138962         WCTYPE_H is empty, for the benefit of builds from non-distclean
138963         directories.  Problem reported by Eric Blake in
138964         <http://lists.gnu.org/r/bug-gnulib/2007-01/msg00157.html>.
138966 2007-01-08  Bruno Haible  <bruno@clisp.org>
138968         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
138969         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
138970         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
138971         PROVIDE_CANONICALIZE_FILENAME_MODE.
138972         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
138974 2007-01-08  Bruno Haible  <bruno@clisp.org>
138976         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
138977         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
138978         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
138979         * lib/fts.c: Likewise.
138980         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
138982 2006-12-25  Bruno Haible  <bruno@clisp.org>
138984         * modules/utf8-ucs4-safe: New file.
138985         * lib/utf8-ucs4-safe.h: New file.
138986         * lib/unistr/utf8-ucs4-safe.c: New file.
138988         * modules/utf16-ucs4-safe: New file.
138989         * lib/utf16-ucs4-safe.h: New file.
138990         * lib/unistr/utf16-ucs4-safe.c: New file.
138992         * MODULES.html.sh (Unicode string functions): Add the new modules.
138994 2007-01-08  Bruno Haible  <bruno@clisp.org>
138996         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
138997         (Depends-on): Add unitypes.
138998         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
138999         (u8_mbtouc_aux): Move out to separate file.
139000         (u8_mbtouc): Use ucs4_t, uint8_t types.
139001         * lib/unistr/utf8-ucs4.c: New file.
139003         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
139004         (Depends-on): Add unitypes.
139005         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
139006         (u16_mbtouc_aux): Move out to separate file.
139007         (u16_mbtouc): Use ucs4_t, uint16_t types.
139008         * lib/unistr/utf16-ucs4.c: New file.
139010         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
139011         (Depends-on): Add unitypes.
139012         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
139013         (u8_uctomb_aux): Move out to separate file.
139014         (u8_uctomb): Use ucs4_t, uint8_t types.
139015         * lib/unistr/ucs4-utf8.c: New file.
139017         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
139018         (Depends-on): Add unitypes.
139019         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
139020         (u16_uctomb_aux): Move out to separate file.
139021         (u16_uctomb): Use ucs4_t, uint16_t types.
139022         * lib/unistr/ucs4-utf16.c: New file.
139024 2006-12-25  Bruno Haible  <bruno@clisp.org>
139026         * modules/unitypes: New file.
139027         * lib/unitypes.h: New file.
139028         * MODULES.html.sh (func_all_modules): New section "Unicode string
139029         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
139030         this section. Add unitypes.
139032 2007-01-08  Bruno Haible  <bruno@clisp.org>
139034         Avoid variable names that conflict with those from libtool.
139035         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
139036         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
139037         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
139038         library_names_spec to acl_library_names_spec, hardcode_* to
139039         acl_hardcode_*.
139040         Reported by Ralf Wildenhues.
139042 2007-01-08  Bruno Haible  <bruno@clisp.org>
139044         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
139045         definition.
139046         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
139047         definition.
139048         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
139049         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
139050         definition.
139051         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
139052         definition.
139053         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
139054         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
139055         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
139056         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
139057         definition.
139058         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
139059         definition.
139060         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
139061         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
139062         GC_USE_<algorithm>.
139063         * lib/gc-libgcrypt.c: Likewise.
139064         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
139065         * modules/gc-arctwo (configure.ac): Likewise.
139066         * modules/gc-des (configure.ac): Likewise.
139067         * modules/gc-hmac-md5 (configure.ac): Likewise.
139068         * modules/gc-hmac-sha1 (configure.ac): Likewise.
139069         * modules/gc-md2 (configure.ac): Likewise.
139070         * modules/gc-md4 (configure.ac): Likewise.
139071         * modules/gc-md5 (configure.ac): Likewise.
139072         * modules/gc-random (configure.ac): Likewise.
139073         * modules/gc-rijndael (configure.ac): Likewise.
139074         * modules/gc-sha1 (configure.ac): Likewise.
139076 2007-01-08  Bruno Haible  <bruno@clisp.org>
139078         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
139079         macro definition.
139080         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
139081         definition.
139082         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
139083         definition.
139084         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
139085         * modules/fcntl-safer (configure.ac): Likewise.
139086         * modules/fopen-safer (configure.ac): Likewise.
139087         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
139088         GNULIB_FWRITEERROR macro definition.
139090 2007-01-08  Bruno Haible  <bruno@clisp.org>
139092         * m4/gnulib-common.m4: New file.
139093         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
139094         (func_get_filelist): Add m4/gnulib-common.m4.
139096 2007-01-08  Bruno Haible  <bruno@clisp.org>
139098         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
139099         command.
139101 2007-01-08  Jim Meyering  <jim@meyering.net>
139103         Use a more robust test for a "can't happen" condition.
139104         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
139105         narrowed the st_size value.  Presuming the "can't happen" condition
139106         is true, that narrowing could conceivably convert an invalid st_size
139107         value into a valid one.  Instead, use a change based on Matthew
139108         Woehlke's original patch.
139110         Slight readability improvement: use an assert-like macro
139111         in place of literal "abort ()" uses.
139112         * lib/fts.c (fts_assert): Define.
139113         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
139114         Use this macro instead of a bare 'abort'.
139116 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
139118         Don't worry about using IRIX 5.3's wctype.h broken definitions;
139119         simply work around them.
139120         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
139121         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
139122         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
139123         declaring.
139124         Don't bother to define as macros, since the standard doesn't require it.
139125         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
139126         longer worry about IRIX 5.3.
139127         (HAVE_WCTYPE_CTMP_BUG): Remove.
139129 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
139131         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
139132         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
139133         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
139134         Problems reported by Georg Schwarz for IRIX 5.3.
139136         * gnulib-tool (autoconf_minversion): Take the maximum version number
139137         found, not the minimum.  Problem reported by James Youngman.
139139 2007-01-03  Karl Berry  <karl@gnu.org>
139141         * doc/error.texi: new file, explaining interaction with progname.
139142         * doc/gnulib.texi: include it.  Update copyright.
139144 2007-01-03  Simon Josefsson  <simon@josefsson.org>
139146         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
139147         AC_CANONICAL_HOST, to improve autobuild outputs.
139149 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
139150             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
139152         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
139153         sockets, server sockets, and other file descriptors.  Count errors
139154         to compute the return value.  Reorder the code a bit to be easier
139155         to follow.  Don't set event bits that were not requested (except
139156         POLLERR and POLLHUP).
139158 2007-01-01  Bruno Haible  <bruno@clisp.org>
139160         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
139162 2007-01-03  Jim Meyering  <jim@meyering.net>
139164         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
139166 2007-01-02  Bruno Haible  <bruno@clisp.org>
139168         * modules/settime (Include): Require timespec.h.
139169         * modules/nanosleep (Include): Likewise.
139171 2007-01-01  Bruno Haible  <bruno@clisp.org>
139173         * gnulib-tool (func_emit_copyright_notice): Bump year.
139174         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
139176 2007-01-01  Bruno Haible  <bruno@clisp.org>
139178         Improve support for OpenBSD.
139179         * build-aux/config.rpath (libname_spec): Export.
139180         (library_names_spec): New variable. Export.
139181         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
139182         library_names_spec from the config.rpath output. Locate shared library
139183         through the name pattern in library_names_spec.
139185 2007-01-01  Eric Blake  <ebb9@byu.net>
139187         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
139189 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
139191         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
139192         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
139193         assume the C locale, and avoid an "eval" that could cause trouble.
139194         Problem with SORT reported by Bob Proulx.
139196         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
139197         Define.  Trivial patch from Henning Nielsen Lund, originally
139198         sent to bug-grep@gnu.org today.
139200 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
139202         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
139203         struct stat.  Problem reported by Henning Nielsen Lund.
139204         * lib/acl.c: Include acl.h first, to check interface.  Don't
139205         bother to include sys/types.h and sys/stat.h again.
139207 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
139209         Import the following change from libc; problem reported by
139210         Sven Verdoolaege.
139212         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
139214         [BZ #1373]
139215         * lib/argp.h: Remove __NTH for __argp_usage inline function.
139217 2006-12-28  Jim Meyering  <jim@meyering.net>
139219         * build-aux/announce-gen: Do not assume that the package
139220         builds any of tar.gz, tar.bz2, and .xdelta files.
139221         Suggestion from Simon Josefsson.
139223 2006-12-28  Simon Josefsson  <simon@josefsson.org>
139225         * modules/announce-gen: New file.
139227 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
139229         * lib/mbchar.h: Just include <wctype.h>; the wctype module
139230         handles its gotchas now.
139231         * lib/mbswidth.c: Likewise.
139232         * lib/wcwidth.h: Likewise.
139233         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
139234         and iswcntrl; the wctype module does this stuff now.
139235         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
139236         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
139237         * modules/mbchar (Depends-on): Add wctype.
139238         * modules/mbswidth (Depends-on): Likewise.
139239         * modules/wcwidth (Depends-on): Likewise.
139241 2006-12-27  Eric Blake  <ebb9@byu.net>
139243         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
139244         module uses more than what <wctype.h> is required to provide.
139246 2006-12-26  Eric Blake  <ebb9@byu.net>
139248         * gnulib-tool (sed_extract_prog): Avoid space-tab.
139250 2006-12-26  Eric Blake  <ebb9@byu.net>
139252         * modules/absolute-header: New module.
139253         * modules/fcntl (Depends-on): Depend on it.
139254         * modules/inttypes (Depends-on): Likewise.
139255         * modules/stdint (Depends-on): Likewise.
139256         * modules/sys_stat (Depends-on): Likewise.
139257         * modules/wctype (Depends-on): Likewise.
139258         * MODULES.html.sh (Support for building libraries and
139259         executables): Document it.
139261 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
139263         * gnulib-tool (SED): Remove, undoing previous change.
139264         The problem was that it broke coreutils on Solaris, because
139265         "sed --posix" leaked into a makefile.
139266         (sed): New alias, if 'alias' and GNU sed.
139268 2006-12-24  Jim Meyering  <jim@meyering.net>
139270         Work around an fchownat bug in glibc-2.4:
139271         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
139272         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
139273         in spite of the -P option.
139274         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
139275         New macros.
139276         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
139277         * modules/openat (Files): Add lib/fchownat.c.
139278         * lib/openat.c (fchownat): Don't define here.  Move to...
139279         * lib/fchownat.c: ...this new file.
139281 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
139283         Fix bug reported by Bruno Haible in
139284         <http://lists.gnu.org/r/bug-gnulib/2006-12/msg00228.html>
139285         where quotearg.c didn't compile on Mac OS X 10.2 because it
139286         lacks <wchar.h> and wint_t.
139287         * lib/wctype_.h (__wctype_wint_t): New type.
139288         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
139289         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
139290         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
139291         Arg is now of type __wctype_wint_t, not wint_t.
139292         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
139293         substitute HAVE_WINT_T.
139294         * modules/wctype (Files): Add m4/wint_t.m4.
139295         (wctype.h): Substitute HAVE_WINT_T.
139297 2006-12-23  Bruno Haible  <bruno@clisp.org>
139299         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
139301 2006-12-23  Bruno Haible  <bruno@clisp.org>
139303         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
139304         S_ISLNK.
139305         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
139306         mingw.
139308 2006-12-22  Bruno Haible  <bruno@clisp.org>
139310         * lib/copy-file.c: Include acl.h.
139311         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
139312         Close the file descriptors only after being done with copy_acl.
139313         * modules/copy-file (Depends-on): Add acl.
139315 2006-12-22  Bruno Haible  <bruno@clisp.org>
139317         * gnulib-tool (SED): New variable.
139318         Use $SED instead of sed everywhere.
139320 2006-12-22  Bruno Haible  <bruno@clisp.org>
139322         * modules/no-c++: New file.
139323         * m4/no-c++.m4: New file.
139324         * MODULES.html.sh (Support for building libraries and executables):
139325         Add no-c++.
139327 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
139329         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
139330         Include <limits.h>, and use its INT_MAX to rewrite the
139331         j loop so that it does not overflow 'int'.  Problem reported by
139332         Ralf Wildenhues in
139333         <http://lists.gnu.org/r/bug-gnulib/2006-12/msg00084.html>.
139334         Play it safe by shifting left by 1 rather than multiplying by 2,
139335         as GCC is less likely to optimize this away when the value
139336         is signed (when it assumes overflow leads to undefined behavior).
139337         Also, don't assume time_t uses two's complement.
139339 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
139341         * MODULES.html.sh: New module wctype.
139342         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
139343         * lib/fnmatch.c: Don't bother to include <wchar.h> before
139344         <wctype.h>, since the new wctype module should fix this.
139345         * lib/quotearg.c: Include <wctype.h> unconditionally, since
139346         the wctype module should arrange for it.
139347         * lib/regex_internal.h: Likewise.
139348         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
139349         since the wctype module should handle this now.
139350         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
139351         * modules/fnmatch (Depends-on): Add wctype.
139352         * modules/quotearg (Depends-on): Likewise.
139353         * modules/regex (Depends-on): Likewise.
139355 2006-12-19  Bruno Haible  <bruno@clisp.org>
139357         * lib/strdup.h [C++]: Wrap definitions in extern "C".
139358         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
139360 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139362         * modules/savewd (Depends-on): Fix dependency on fcntl.
139364 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
139366         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
139367         conforms to C99, rather than relying on the user's environment
139368         setting of STDINT_H.
139370 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
139371         and Eric Blake  <ebb9@byu.net>
139373         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
139374         This is more consistent with the other defines here.
139375         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
139376         Port to z/OS.  Problem reported by Paul Gilmartin.
139377         Change local vars to use gl_ prefix rather than ac_.
139378         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
139379         with other defines.
139380         * modules/double-slash-root: New module.
139381         * modules/dirname (Files): Remove m4/double-slash-root.m4.
139382         (Depends-on): Add double-slash-root.
139383         * MODULES.html.sh (File system functions): Mention new module.
139385 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
139387         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
139388         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
139389         This is for the benefit of gzip, which doesn't do i18n.
139391 2006-12-12  Jim Meyering  <jim@meyering.net>
139393         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
139394         Reported by Andreas Schwab <schwab@suse.de>.
139396 2006-12-12  Bruno Haible  <bruno@clisp.org>
139398         Merge these changes.
139399         2006-09-05  Bruno Haible  <bruno@clisp.org>
139400         * lib/iconvme.c (iconv_string): No need to save and restore errno when
139401         iconv_alloc succeeded.
139402         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
139403         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
139404         test for " && dest " at the end - dest is always != NULL there. Call
139405         iconv with 4xNULL arguments initially, to reset the state. Call iconv
139406         with 2xNULL arguments, also to flush the state storage. Handle the
139407         IRIX iconv behaviour. Realloc the final result, to throw away unused
139408         memory.
139410 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
139412         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
139413         and fchmodat unconditionally, since glibc 2.4 has them.
139414         Problem reported by Arkadiusz Miskiewicz.
139416 2006-12-10  Bruno Haible  <bruno@clisp.org>
139418         * gnulib-tool (func_import): Show the include files only for those
139419         modules that are copied and specified.
139420         Reported by Karl Berry.
139422 2006-12-08  Jim Meyering  <jim@meyering.net>
139424         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
139425         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
139427         * build-aux/announce-gen: Add two new options, both optional:
139428         --bootstrap-tools=TOOL_LIST
139429               a comma-separated list of tools, e.g.,
139430               autoconf,automake,bison,gnulib
139431         --gnulib-snapshot-date=DATE
139432               if gnulib is in the bootstrap tool list,
139433               then report this as the snapshot date.
139434               If not specified, use the current date/time.
139435               If you specify a date here, be sure it's UTC.
139437 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139439         * tests/test-argp-2.sh: Fix test to match actual output.
139440         (func_compare): Fix sed script to be portable.
139442 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
139444         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
139445         workaround for this case.  It is not autoconfigured now; offhand
139446         it's hard to see how to autoconfigure it.
139448 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
139450         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
139451         a directory that is about to be chowned.  Such a directory's
139452         initial file permissions should permit the owner only and this
139453         should not be changed until after the chown, since the group and
139454         other bits would be incorrect if they granted permission before
139455         the chown.
139457         Fix porting problem for iswctype reported by Georg Schwarz in:
139458         http://lists.gnu.org/r/bug-coreutils/2006-12/msg00017.html
139459         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
139460         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
139461         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
139462         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
139464 2006-12-03  Jim Meyering  <jim@meyering.net>
139466         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
139467         p->fts_statp may not yet be defined.
139468         (fts_read): Instead, set it in the caller, once p->fts_statp is
139469         sure to be defined, and corresponds to a top-level directory.
139470         This bug made du -x fail.  Here's the coreutils test case:
139471         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
139472         Reported by Mike Frysinger.
139474 2006-12-01  Jim Meyering  <jim@meyering.net>
139476         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
139477         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
139478         Reported by Simon Josefsson.
139480 2006-11-30  Jim Meyering  <jim@meyering.net>
139482         * m4/warning.m4: Use the all-permissive copyright notice
139483         recommended by RMS (rather than LGPL).
139484         * m4/vararrays.m4: Likewise.
139485         * m4/flexmember.m4: Likewise.
139487 2006-11-29  Bruno Haible  <bruno@clisp.org>
139489         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
139490         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
139491         using +=.
139492         Reported by Simon Josefsson <simon@josefsson.org>.
139494 2006-11-28  James Youngman  <jay@gnu.org>
139496         * README: Advise users that they might find the bug-gnulib@gnu.org
139497         and autotools-announce@gnu.org mailing lists useful.
139499 2006-11-28  Bruno Haible  <bruno@clisp.org>
139501         * m4/ptrdiff_max.m4: Remove file.
139503 2006-11-21  Bruno Haible  <bruno@clisp.org>
139505         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
139506         _AC_COMPUTE_INT.
139507         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
139508         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
139509         _AC_COMPUTE_INT.
139510         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
139511         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
139512         _AC_COMPUTE_INT.
139513         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
139515 2006-11-28  Jim Meyering  <jim@meyering.net>
139517         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
139518         warning from "gcc -Wshadow" about shadowing the builtin.
139520 2006-11-27  Bruno Haible  <bruno@clisp.org>
139522         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
139523         _AC_COMPUTE_INT.
139524         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
139526 2006-11-27  Bruno Haible  <bruno@clisp.org>
139527             Paul Eggert  <eggert@cs.ucla.edu>
139529         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
139531 2006-11-26  Bruno Haible  <bruno@clisp.org>
139533         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
139534         noinst_LTLIBRARIES.
139536 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
139537             Bruno Haible  <bruno@clisp.org>
139539         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
139540         if compiling with "gcc -ansi".
139542 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
139544         Fix some incompatibilities with gcc -ansi -pedantic.
139545         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
139546         if compiling pedantically with GCC, unless it's C99 or later.
139547         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
139548         it mishandles gcc -ansi -pedantic as well.
139549         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
139550         if gcc -pedantic.
139551         * lib/regexec.c (check_node_accept_bytes): Don't use auto
139552         initializers for struct if -pedantic, unless it's C99 or later.
139554 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
139556         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
139557         Don't close an fd more than once. Identical atimes indicate
139558         success, not failure.
139560 2006-11-22  Robinson Mittmann  <bob@hoplon.com>  (tiny change)
139562         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
139564 2006-11-23  Jim Meyering  <jim@meyering.net>
139566         * build-aux/announce-gen: New file.  From coreutils.
139568 2006-11-22  Jim Meyering  <jim@meyering.net>
139570         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
139571         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
139572         (fts_read): Use a temporary to narrow the overused st_size member
139573         before using it in a switch statement.  Reported by Matthew Woehlke.
139575         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
139576         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
139578 2006-11-20  Bruno Haible  <bruno@clisp.org>
139580         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
139581         changequote instead of pairs of brackets.
139582         Reported by Andreas Schwab <schwab@suse.de>.
139584 2006-11-21  Jim Meyering  <jim@meyering.net>
139586         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
139587         so as to remain compatible with older compilers.
139588         Patch from Michael Deutschmann.
139590 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
139592         * MODULES.html.sh (File system functions): Add openat.
139594         * lib/openat.h (rpl_fstatat): New macro, if
139595         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
139596         (fstatat): Define to rpl_fstatat under the same conditions,
139597         unless COMPILING_FSTATAT.
139598         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
139599         seems to have the bug.
139600         * lib/fstatat.c: New file.
139601         * modules/openat (Files): Add it.
139603 2006-11-20  Bruno Haible  <bruno@clisp.org>
139605         * Makefile: New file.
139607 2006-11-20  Jim Meyering  <jim@meyering.net>
139609         The beginnings of syntax-related checks for gnulib.
139610         * lib/Makefile: New file.
139611         * lib/t-idcache: New script.  Ensure that the two halves of
139612         idcache.c stay in sync.
139614         * lib/idcache.c: Adjust comments in user- and group- portions to
139615         be more accurate, and to be consistent with one another.
139617 2006-11-20  Jim Meyering  <jim@meyering.net>
139619         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
139620         continue using the flexible array member (thus, this module performs
139621         half as many malloc calls), with the addition that...
139622         (getgroup, getuser): Consistently record a non-match via an empty
139623         "name" string, and map an empty string match to a NULL return value.
139624         * modules/idcache (Depends-on): Re-add flexmember.
139626         * lib/idcache.c (getuser): Remove all uses of the register keyword.
139627         (getuidbyname, getgroup, getgidbyname): Likewise.
139629         Use cleaner syntax: NULL rather than 0.
139630         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
139632 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
139634         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
139635         It mishandled the case where the group was missing.
139636         Problem reported by Greg Schafer.
139637         * modules/idcache: Likewise.
139639 2006-11-18  Jim Meyering  <jim@meyering.net>
139641         * check-module (%exempt_header): Add exception for some
139642         conditionally-included headers.
139644         * modules/i-ring (Depends-on): Add verify.
139645         (License): Change to LGPL.
139647 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
139649         * modules/getaddrinfo (Depends-on): Remove inttostr; add snprintf.
139650         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
139651         and inttostr.h.  Use snprintf rather than uinttostr, so that
139652         LGPLed code doesn't depend on GPLed.
139654 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
139656         * modules/inline (License): Change from GPL to LGPL.
139658 2006-11-17  Jim Meyering  <jim@meyering.net>
139660         * modules/d-type (License): Switch to LGPL.
139662 2006-11-15  Bruno Haible  <bruno@clisp.org>
139664         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
139666 2006-11-15  Eric Blake  <ebb9@byu.net>
139668         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
139669         the module dependency.
139671 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
139672             Bruno Haible  <bruno@clisp.org>
139674         * gnulib-tool (func_create_testdir): Add license consistency check.
139676 2006-11-15  Eric Blake  <ebb9@byu.net>
139678         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
139679         random "(cached)" in configure output.
139681 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139683         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
139684         test for conforming inttypes.h is both announced and cached.
139686         * MODULES.html.sh (seen_modules, seen_files): New variables.
139687         (func_module): Rewrite to use a few less gnulib-tool and sed
139688         invocations.  Avoid a couple of quadratic algorithms for ...
139689         (missed_modules, missed_files): ... these, with ...
139690         (func_append, func_tmpdir): ... these new functions, from
139691         gnulib-tool.  Analogously, install traps for cleanup.
139693         * tests/test-gc.c (main): Remove unused variables.
139694         * tests/test-read-file.c: Include stdlib.h, for 'free'.
139696 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
139698         * modules/inttostr (License): Change to LGPL.
139700 2006-11-14  Eric Blake  <ebb9@byu.net>
139702         * modules/tempname (License): Change to LGPL.
139704 2006-11-14  Eric Blake  <ebb9@byu.net>
139706         * doc/functions.texi (Function Portability): *printf functions on
139707         Cygwin now understand all POSIX size specifiers.
139709 2006-11-14  Bruno Haible  <bruno@clisp.org>
139711         * modules/c-ctype (License): Change to LGPL.
139713 2006-11-12  Bruno Haible  <bruno@clisp.org>
139715         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
139716         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
139717         for GNOME libraries, for which the include files are installed in
139718         subdirectories of $prefix/include.
139720 2006-11-12  Bruno Haible  <bruno@clisp.org>
139722         * m4/lib-link.m4: Require at least autoconf-2.54.
139723         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
139724         name to underscores for the --with option.
139726 2006-11-13  Bruno Haible  <bruno@clisp.org>
139728         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
139729         the tests directory.
139730         Reported by Ralf Wildenhues.
139732 2006-11-13  Bruno Haible  <bruno@clisp.org>
139734         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
139735         (func_emit_initmacro_end): Undo the override here.
139736         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
139737         Works around the famous automake error in coreutils.
139739 2006-11-13  Eric Blake  <ebb9@byu.net>
139741         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
139742         element, not its node.
139744 2006-11-12  Bruno Haible  <bruno@clisp.org>
139746         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
139747         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
139749 2006-11-12  Bruno Haible  <bruno@clisp.org>
139751         * gnulib-tool: New option --local-symlink.
139752         (func_usage): Document it.
139753         (lsymbolic): New variable.
139754         (func_import, func_create_testdir): If --symlink was not specified,
139755         test whether --local-symlink was specified and the file comes from
139756         the local_gnulib_dir.
139758 2006-11-12  Bruno Haible  <bruno@clisp.org>
139760         * gnulib-tool (func_ln): New function.
139761         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
139763 2006-11-12  Bruno Haible  <bruno@clisp.org>
139765         Finish support for source files in subdirectories.
139766         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
139767         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
139768         AUTOMAKE_OPTIONS.
139769         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
139771 2006-11-12  Bruno Haible  <bruno@clisp.org>
139773         * gnulib-tool (func_get_automake_snippet): Synthesize also an
139774         EXTRA_lib_SOURCES augmentation.
139775         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
139777 2006-11-12  Jim Meyering  <jim@meyering.net>
139779         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
139780         file descriptors.  This also averts a failure on systems with
139781         native openat support when a traversed directory lacks "x" access.
139782         * lib/fts_.h: Include "i-ring.h"
139783         (struct FTS) [fts_fd_ring]: New member.
139784         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
139785         (FCHDIR): Add parentheses.
139786         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
139787         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
139788         When descending, rather than simply closing the previous
139789         fts_cwd_fd value, push that file descriptor onto the ring.
139790         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
139791         (fts_open): Initialize the new fd_ring member.
139792         (fts_close): Clear the ring.
139793         (fts_safe_changedir): When possible, use our new fd_ring to skip
139794         the diropen and fstat and dev/ino comparison that would normally
139795         accompany a virtual `chdir ("..")'.
139797         * modules/fts (Depends-on): Add i-ring.
139798         * modules/i-ring: New module.
139799         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
139800         * m4/i-ring.m4: New file.
139802 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139804         * gnulib-tool (func_create_testdir): Fix replacement of
139805         `build-aux' in configure.ac.  Run autotools in gltests
139806         subdirectory.
139807         (func_create_testdir, func_create_megatestdir, test): There is
139808         no need for '--force' in most autotool invocations in a new
139809         tree.  Actually fail the whole test if any of the tools, or the
139810         configure or make stages fail.
139812         Sync from Automake.
139813         * build-aux/gnupload: Revert last change.  Add pointer to upload
139814         instructions of the GNU Maintenance Instructions.
139815         Suggestion by Karl Berry.
139817 2006-11-10  Jim Meyering  <jim@meyering.net>
139819         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
139821 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
139823         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
139824         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
139825         (bind_textdomain_codeset) [! ENABLE_NLS]:
139826         Evaluate all the arguments.  That way, callers get compatible behavior
139827         if the arguments have side effects.  Also, it avoids some GCC
139828         diagnostics in some cases; Joel E. Denny reported problems when Bison
139829         was configured with --enable-gcc-warnigs.
139831 2006-11-10  Jim Meyering  <jim@meyering.net>
139833         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
139834         relevant options in CFLAGS (like -O, -fno-inline) are taken into
139835         account.
139837 2006-11-10  Jim Meyering  <jim@meyering.net>
139839         * modules/inline: New file/module.
139840         * modules/xalloc (Files): Remove m4/inline.m4.
139841         (Depends-on): Add inline, instead.
139842         * modules/oset: Likewise.
139843         * modules/list: Likewise.
139845 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
139847         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
139848         Problem reported by Matthew Woehlke.
139850 2006-11-09  Bruno Haible  <bruno@clisp.org>
139852         * lib/tempname.c (gen_tempname): Remove variant that invokes
139853         __gen_tempname.
139854         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
139855         __gen_tempname.
139857 2006-11-08  Bruno Haible  <bruno@clisp.org>
139859         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
139860         to 'yes' instead of 'cross-compiling'.
139862 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
139864         * lib/quotearg.h (quotearg_free): New decl.
139865         * lib/quotearg.c (quotearg_free): New function.
139866         (slot0, nslots, slotvec0, slotvec):
139867         Now file-scope so that quotearg_free can get at them.
139869 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139871         Sync from Automake.
139872         * build-aux/gnupload: Add missing 'gnu' to example URL.
139873         Report by Karl Berry.
139875 2006-11-08  Bruno Haible  <bruno@clisp.org>
139877         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
139878         Suggested by Paul Eggert.
139880 2006-11-08  Jim Meyering  <jim@meyering.net>
139882         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
139883         It's already included if !_LIBC.
139884         (fts_safe_changedir): Add a comment.
139886 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
139888         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
139889         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
139890         Matthew Woehlke.
139892         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
139893         definitions up, to avoid colliding with change below.
139894         (static_inline) [HAVE_INLINE]: New macro.
139895         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
139896         Provide extern decls when !HAVE_INLINE.  Do not define unless
139897         static_inline is defined, either by us or by xmalloc.c.  Use
139898         static_inline rather than static inline.
139899         (XCALLOC): Optimize sizeof(T) = 1 case.
139900         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
139902 2006-11-07  Bruno Haible  <bruno@clisp.org>
139904         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
139905         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
139906         AC_C_INLINE.
139907         * modules/xalloc (Files): Add m4/inline.m4.
139909 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139911         * README: Fix typo.
139912         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
139913         (Miscellanous Notes): ...from this.
139915 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
139917         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
139918         Mention that offsetof should be used instead of sizeof.
139919         From Bruno Haible.
139921 2006-11-07  Bruno Haible  <bruno@clisp.org>
139923         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
139925 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
139927         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
139928         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
139929         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
139930         (gl_tree_add_before, gl_tree_add_after):
139931         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
139932         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
139933         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
139934         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
139935         (gl_linked_add_after, gl_linked_add_at): Likewise.
139936         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
139937         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
139938         (gl_tree_add_before, gl_tree_add_after): Likewise.
139939         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
139940         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
139941         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
139943 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
139945         * lib/gl_oset.h: Use C comment style, not C++ comment style.
139947 2006-11-06  Bruno Haible  <bruno@clisp.org>
139949         * m4/inline.m4: New file.
139950         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
139951         * modules/list (Files): Add m4/inline.m4.
139952         * modules/oset (Files): Likewise.
139954 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
139956         * lib/idcache.c: Include <stddef.h>, for offsetof.
139957         (struct userid.name): Change from char * to a flexible array member.
139958         All uses changed.
139959         * modules/idcache (Depends-on): Add flexmember.
139961         * MODULES.html.sh (Core language properties): New module flexmember.
139962         * modules/flexmember, m4/flexmember.m4: New files.
139964         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
139965         inline functions that are identical with the old xnmalloc_inline,
139966         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
139967         that we can avoid some unnecessary integer multiplications and
139968         divisions in the common case where the element size is known at
139969         compile time.
139970         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
139971         needed.
139972         (xnboundedmalloc): Remove.
139973         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
139974         arguments, for consistency with rest of this header.
139975         (xcharalloc): Rewrite using XNMALLOC.
139976         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
139977         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
139978         versions have been moved to lib/xalloc.h and renamed to be the
139979         non-*_inline versions.
139980         (xmalloc, xrealloc): Implement without reference to the xnmalloc
139981         and xnrealloc functions, since those functions are now inline and
139982         now call us.
139983         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
139984         renaming described above.
139985         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
139986         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
139987         captures the dependency in AC_C_INLINE.
139989         New module canonicalize-lgpl, proposed by Charles Wilson in
139990         <http://lists.gnu.org/r/bug-gnulib/2006-11/msg00020.html>
139991         with a few small changes afterwards.
139992         * MODULES.html.sh (File system functions): New module
139993         canonicalize-lgpl.
139994         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
139995         and canonicalize_file_name.
139996         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
139997         * modules/canonicalize-lgpl: New files.
139999 2006-11-05  Bruno Haible  <bruno@clisp.org>
140001         * gnulib-tool (func_import, func_create_testdir): Create directories
140002         also for files in subdirectories of lib/.
140004 2006-11-05  Bruno Haible  <bruno@clisp.org>
140006         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
140007         ANSI C compliant.
140009 2006-11-03  Bruno Haible  <bruno@clisp.org>
140011         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
140012         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
140013         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
140014         (xnboundedmalloc): New inline function.
140015         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
140016         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
140017         xmalloc.
140018         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
140019         xmalloc.
140020         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
140021         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
140022         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
140023         xmalloc.
140024         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
140025         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
140026         xmalloc.
140027         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
140028         gl_tree_add_after): Use XMALLOC instead of xmalloc.
140029         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
140030         xmalloc.
140031         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
140032         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
140033         gl_tree_add_after): Use XMALLOC instead of xmalloc.
140034         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
140035         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
140036         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
140037         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
140039 2006-11-03  Bruno Haible  <bruno@clisp.org>
140041         * lib/c-ctype.h [C++]: Define functions without name mangling.
140042         * lib/fwriteerror.h [C++]: Likewise.
140043         * lib/gcd.h [C++]: Likewise.
140044         * lib/linebreak.h [C++]: Likewise.
140046 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
140048         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
140049         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
140050         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
140051         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
140052         Check for functions and headers just once.
140053         Check for declaration of canonicalize_file_name.
140054         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
140056 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
140058         * gnulib-tool (func_import): Fix typo in actioncmd.
140060 2006-11-02  Bruno Haible  <bruno@clisp.org>
140062         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
140063         newline sequence in the Makefile.am snippet as a space, like "make"
140064         does.
140065         Reported by Roger Persson <perrog@gmail.com>.
140067 2006-11-01  Bruno Haible  <bruno@clisp.org>
140069         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
140070         already declared in <string.h>.
140071         * lib/strcase.h (strncasecmp): Don't declare it if yes.
140073 2006-11-01  Bruno Haible  <bruno@clisp.org>
140075         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
140076         * lib/strcase.h: Include <string.h>.
140077         (strcasecmp): Define to rpl_strcasecmp here.
140079 2006-11-01  Bruno Haible  <bruno@clisp.org>
140081         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
140083 2006-11-01  Eric Blake  <ebb9@byu.net>
140085         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
140087         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
140089 2006-10-29  Bruno Haible  <bruno@clisp.org>
140091         Make it compile in C++ mode.
140092         * lib/full-write.c (full_rw): Add a cast.
140094 2006-11-01  Bruno Haible  <bruno@clisp.org>
140096         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
140097         be POSIX compliant.
140098         Reported by Roger Persson <perrog@gmail.com>.
140100 2006-11-01  Eric Blake  <ebb9@byu.net>
140102         * lib/getopt_.h: Fix comments.
140104 2006-10-31  Eric Blake  <ebb9@byu.net>
140106         * modules/tmpdir (Depends-on): Add sys_stat.
140107         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
140108         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
140109         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
140110         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
140111         tempname.
140113 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
140115         Avoid some C++ diagnostics reported by Bruno Haible.
140116         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
140117         xmalloc.
140118         (quotearg_alloc): Use xcharalloc rather than xmalloc.
140119         (struct slotvec): Move to top level.
140120         (quotearg_n_options): Rewrite to avoid xmalloc.
140121         * lib/xalloc.h (xcharalloc): New function.
140122         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
140123         [defined __cplusplus]: Add function template that provides result
140124         type propagation.  This part of the change is from Bruno Haible.
140126 2006-10-29  Bruno Haible  <bruno@clisp.org>
140128         Make it compile in C++ mode.
140129         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
140130         * lib/strnlen1.c (strnlen1): Cast memchr result.
140131         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
140132         * lib/clean-temp.c (string_equals, string_hash): Add casts.
140133         (create_temp_dir): Rename local variable 'template'.
140134         (compile_csharp_using_sscli): Add cast.
140135         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
140136         * lib/findprog.c (find_in_path): Likewise.
140137         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
140138         * lib/wait-process.c (register_slave_subprocess): Likewise.
140140 2006-10-22  Bruno Haible  <bruno@clisp.org>
140142         * modules/tsearch: New file.
140143         * lib/tsearch.h: New file.
140144         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
140145         * m4/tsearch.m4: New file.
140146         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
140148 2006-10-29  Eric Blake  <ebb9@byu.net>
140150         * lib/arcfour.c: Assume config.h.
140151         * lib/arctwo.c: Likewise.
140152         * lib/base64.c: Likewise.
140153         * lib/check-version.c: Likewise.
140154         * lib/crc.c: Likewise.
140155         * lib/des.c: Likewise.
140156         * lib/gc-gnulib.c: Likewise.
140157         * lib/gc-libgcrypt.c: Likewise.
140158         * lib/gc-pbkdf2-sha1.c: Likewise.
140159         * lib/getaddrinfo.c: Likewise.
140160         * lib/getdelim.c: Likewise.
140161         * lib/getline.c: Likewise.
140162         * lib/hmac-md5.c: Likewise.
140163         * lib/hmac-sha1.c: Likewise.
140164         * lib/iconvme.c: Likewise.
140165         * lib/md2.c: Likewise.
140166         * lib/md4.c: Likewise.
140167         * lib/memxor.c: Likewise.
140168         * lib/read-file.c: Likewise.
140169         * lib/readline.c: Likewise.
140170         * lib/rijndael-alg-fst.c: Likewise.
140171         * lib/rijndael-api-fst.c: Likewise.
140172         * lib/xgetdomainname.c: Likewise.
140174 2006-10-28  Eric Blake  <ebb9@byu.net>
140176         * lib/xstrndup.c: Assume config.h.
140178 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
140180         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
140181         stat-macros.h is now for our own macros, whereas stat_h is for
140182         macros in the <sys/stat.h> name space.
140183         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
140184         (STAT_MACROS_H): Remove.
140185         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
140186         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
140187         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
140188         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
140189         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
140190         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
140191         Move these macros to ...
140192         * lib/stat_.h: here.  Don't include stat-macros.h.
140193         * lib/canonicalize.c: Don't include stat-macros.h.
140194         * lib/chown.c: Likewise.
140195         * lib/euidaccess.c: Likewise.
140196         * lib/file-type.c: Likewise.
140197         * lib/filemode.c: Likewise.
140198         * lib/glob.c: Likewise.
140199         * lib/isapipe.c: Likewise.
140200         * lib/lchown.c: Likewise.
140201         * lib/lstat.c: Likewise.
140202         * lib/mkdir-p.c: Likewise.
140203         * lib/rmdir.c: Likewise.
140204         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
140205         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
140206         unless mkdir isn't declared, to speed up 'configure'.
140207         Always create sys/stat.h, since it's unlikely any real sys/stat.h
140208         would define all the S_* symbols.
140209         * modules/canonicalize (Depends-on):
140210         Depend on sys_stat, not stat-macros.
140211         * modules/chown: Likewise.
140212         * modules/euidaccess: Likewise.
140213         * modules/filemode: Likewise.
140214         * modules/file-type: Likewise.
140215         * modules/glob: Likewise.
140216         * modules/isapipe: Likewise.
140217         * modules/lchown: Likewise.
140218         * modules/lstat: Likewise.
140219         * modules/mkancesdirs: Likewise.
140220         * modules/rmdir: Likewise.
140221         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
140222         * modules/modechange: Likewise.
140223         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
140224         (configure.ac): Remove gl_STAT_MACROS.
140225         * modules/sys_stat (Depends-on): Remove stat-macros.
140227 2006-10-27  Bruno Haible  <bruno@clisp.org>
140229         * m4/signed.m4: Remove file.
140230         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
140231         invocation.
140232         * modules/vasnprintf (Files): Remove m4/signed.m4.
140234 2006-10-27  Bruno Haible  <bruno@clisp.org>
140236         Update to GNU gettext 0.16.
140237         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
140238         m4/inttypes-h.m4, m4/signed.m4.
140239         * m4/gettext.m4: Update to GNU gettext 0.16.
140240         * m4/intl.m4: New file, from GNU gettext.
140241         * m4/intldir.m4: New file, from GNU gettext.
140242         * config/srclist.txt: Update
140244 2006-10-27  Eric Blake  <ebb9@byu.net>
140246         * MODULES.html.sh: Document tempname.
140247         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
140248         dependencies.
140249         (Files): Move lib/tempname.c...
140250         * modules/tempname: ...to this new module.
140251         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
140252         (gl_PREREQ_TEMPNAME): Move...
140253         * m4/tempname.m4: ...to this new file.
140254         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
140255         * modules/sys_stat (Depends-on): Add stat-macros.
140256         * lib/stat_.h (includes): Pick up stat macros.
140257         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
140258         if stat macros are broken.
140259         * lib/tempname.c (includes): No need to include "stat-macros.h".
140260         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
140261         (direxists, __path_search) [!_LIBC]: Don't compile these in
140262         gnulib; the tmpdir module covers that.
140263         * lib/tempname.h: New file.
140265 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
140267         * COPYING: Explain how gnulib-tool converts licence headers.
140268         Almost all wording by Eric Blake.
140270 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
140272         * lib/mbchar.h (is_basic_table): Make read-only.
140273         * lib/mbchar.c (is_basic_table): Likewise.
140274         Reported by John Darrington.
140276 2006-10-25  Bruno Haible  <bruno@clisp.org>
140278         * lib/progname.h (set_program_name): Undefine before defining.
140280 2006-10-25  Bruno Haible  <bruno@clisp.org>
140282         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
140283         false for non-gcc C++ compilers.
140284         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
140286 2006-10-24  Bruno Haible  <bruno@clisp.org>
140288         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
140289         iconv implementations like Irix iconv.
140291 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
140293         * modules/vararrays: New file.
140294         * m4/vararrays.m4: New file, taken from diffutils.
140295         * MODULES.html.sh: New module vararrays.
140297 2006-10-24  Karl Berry  <karl@gnu.org>
140299         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
140300         Don't call GNU Unix.
140302 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
140304         * users.txt: Add Libtool.
140306         Sync from Libtool:
140308         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
140310         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
140311         to gnulib's policy of including config.h unconditionally.
140313 2006-10-24  Bruno Haible  <bruno@clisp.org>
140315         * modules/wcwidth (Files): Add m4/wint_t.m4.
140316         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
140317         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
140319 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
140321         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
140322         to pacify GCC with some -W flags enabled.  Problem reported by
140323         Bruno Haible.
140325 2006-10-24  Jim Meyering  <jim@meyering.net>
140327         * MODULES.html.sh: Remove uinttostr.  It's not a module.
140328         Reported by Karl Berry.
140330 2006-10-23  Bruno Haible  <bruno@clisp.org>
140332         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
140334 2006-10-24  Bruno Haible  <bruno@clisp.org>
140336         * lib/gl_list.h: Use C comment style, not C++ comment style.
140338 2006-10-23  Eric Blake  <ebb9@byu.net>
140340         * lib/getaddrinfo.c (includes): Add missing include.
140342 2006-10-23  Bruno Haible  <bruno@clisp.org>
140343             Paul Eggert  <eggert@cs.ucla.edu>
140345         Ability to rename obstack_free.
140346         * lib/obstack.h (__obstack_free): New macro. Declare instead of
140347         obstack_free.
140348         (obstack_free): Invoke the __obstack_free macro.
140349         * lib/obstack.c (obstack_free): Use __obstack_free macro.
140351 2006-10-23  Bruno Haible  <bruno@clisp.org>
140352             Paul Eggert  <eggert@cs.ucla.edu>
140354         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
140355         __argc, __argv from the declaration. (They are defined as macros on
140356         mingw.)
140358 2006-10-22  Bruno Haible  <bruno@clisp.org>
140360         * doc/gnulib-intro.texi: New file.
140361         * doc/gnulib.texi: Include it.
140363 2006-10-21  Bruno Haible  <bruno@clisp.org>
140365         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
140366         "Introduction", "Miscellanous Notes", "Particular Modules".
140368 2006-10-21  Bruno Haible  <bruno@clisp.org>
140370         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
140371         Change mostlyclean-local rule to avoid sh syntax error from bash
140372         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
140374 2006-10-23  Jim Meyering  <jim@meyering.net>
140376         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
140377         in place of snprintf.
140379         * modules/inttostr (Files): Add lib/uinttostr.c.
140380         * lib/uinttostr.c (inttostr): New file/function.
140381         * lib/inttostr.h (uinttostr): Declare.
140382         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
140383         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
140384         Add uinttostr.
140385         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
140387 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
140389         * lib/canonicalize.c (ELOOP): Define if not already defined.
140390         Problem reported by Bruno Haible in
140391         <http://lists.gnu.org/r/bug-gnulib/2006-10/msg00282.html>.
140393 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
140395         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
140396         Problem reported by Perry Smith and Ville Laurikari.
140398         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
140399         uses.
140401 2006-10-19  Bruno Haible  <bruno@clisp.org>
140403         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
140404         for mingw.
140406 2006-10-19  Bruno Haible  <bruno@clisp.org>
140408         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
140409         Needed for mingw.
140411 2006-10-19  Bruno Haible  <bruno@clisp.org>
140413         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
140415 2006-10-19  Bruno Haible  <bruno@clisp.org>
140417         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
140418         it.
140420 2006-10-19  Bruno Haible  <bruno@clisp.org>
140422         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
140423         invocation.
140425 2006-10-19  Bruno Haible  <bruno@clisp.org>
140427         * gnulib-tool (func_create_testdir): Don't include ftruncate and
140428         mountlist by default.
140430 2006-10-16  Bruno Haible  <bruno@clisp.org>
140432         * lib/c-strstr.c: Include c-strstr.h.
140434 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
140436         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
140437         in a slash.
140439 2006-10-18  Bruno Haible  <bruno@clisp.org>
140441         * lib/lock.h [C++]: Wrap definitions in extern "C".
140443 2006-10-18  Bruno Haible  <bruno@clisp.org>
140445         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
140446         gl_LIBOBJS list.
140448 2006-10-18  Bruno Haible  <bruno@clisp.org>
140450         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
140452 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
140454         * lib/xstrtol.h: Include gettext.h.
140455         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
140456         Problem reported by Eric Blake.
140457         * modules/xstrtol (Depends-on): Add gettext-h.
140459 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
140461         * lib/strftime.c (advance): New macro.
140462         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
140463         incomplete type, so you can't add 0 to it.  Problem and patch
140464         reported by Eelco Dolstra for dietlibc.
140466 2006-10-18  Jim Meyering  <jim@meyering.net>
140468         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
140469         type for a local, and rename it: s/up/user_proc/.
140471 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
140473         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
140474         READ_UTMP_USER_PROCESS.
140475         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
140477 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
140479         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
140480         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
140482 2006-10-17  Eric Blake  <ebb9@byu.net>
140484         * lib/sigprocmask.c (sigprocmask): Fix typo.
140486         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
140488         * modules/clean-temp (Makefile.am): Don't add to make output...
140489         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
140490         config.h.
140492 2006-10-17  Bruno Haible  <bruno@clisp.org>
140494         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
140495         differently if DEFAULT_TEXT_DOMAIN is set.
140497 2006-10-16  Bruno Haible  <bruno@clisp.org>
140499         * lib/clean-temp.c: Include fwriteerror.h.
140501 2006-10-16  Bruno Haible  <bruno@clisp.org>
140503         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
140505 2006-10-16  Bruno Haible  <bruno@clisp.org>
140507         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
140508         * lib/sigprocmask.h: Include <sys/types.h>.
140509         (sigset_t): Use the system's definition if present.
140511 2006-10-17  Eric Blake  <ebb9@byu.net>
140513         * lib/xvasprintf.c (includes): Assume config.h.
140514         * lib/xasprintf.c (includes): Likewise.
140516 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
140518         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
140519         at least as wide as intmax_t.
140521 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
140523         (Imported from Automake.)
140524         * build-aux/gnupload: Update to version 1.1 of directive file.
140526 2006-10-16  Eric Blake  <ebb9@byu.net>
140528         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
140529         match Automake 1.10a.
140531 2006-10-14  Bruno Haible  <bruno@clisp.org>
140533         * modules/sigprocmask: New file.
140534         * lib/sigprocmask.h: New file.
140535         * lib/sigprocmask.c: New file.
140536         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
140537         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
140538         request sigprocmask.o.
140539         (gl_PREREQ_SIGPROCMASK): New macro.
140540         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
140541         (Depends-on): Add sigprocmask.
140542         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
140543         gt_SIGNALBLOCKING. Test for 'raise' only once.
140544         * lib/fatal-signal.c: Include sigprocmask.h.
140545         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
140546         unblock_fatal_signals): Define always.
140547         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
140548         sigprocmask.
140550 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
140552         Sync from Automake.
140553         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
140554         which incorrectly sets the mode of an existing destination
140555         directory.  In some cases the unpatched install-sh could do the
140556         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
140557         system.  We hope this is rare in practice, but it's clearly worth
140558         fixing.  Problem reported by Alex Unleashed in
140559         <http://lists.gnu.org/r/bug-autoconf/2006-10/msg00012.html>.
140560         Also, don't bother to check for -m bugs unless we're using -m;
140561         suggested by Stepan Kasal.
140563 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
140565         Sync from Automake.
140566         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
140567         `-c' flag, so they appear at the same position as in %FASTDEP%
140568         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
140569         which ignores unknown options only after the first non-option.
140570         Bug report against M4 by Nelson H. F. Beebe.
140572 2006-10-13  Jim Meyering  <jim@meyering.net>
140574         Fix a bug in yesterday's change.
140575         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
140576         p->fts_statp->st_dev would be used uninitialized.
140577         Ensures that we always call fts_stat on the very first entry.
140578         Miklos Szeredi reported that find -xdev stopped working.
140580 2006-10-12  Bruno Haible  <bruno@clisp.org>
140582         * gnulib-tool (func_get_automake_snippet): Append an automatically
140583         computed EXTRA_DIST augmentation.
140584         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
140585         * modules/alloca-opt (Makefile.am): Likewise.
140586         * modules/allocsa (Makefile.am): Likewise.
140587         * modules/arcfour (Makefile.am): Likewise.
140588         * modules/arctwo (Makefile.am): Likewise.
140589         * modules/argmatch (Makefile.am): Likewise.
140590         * modules/argz (Makefile.am): Likewise.
140591         * modules/atexit (Makefile.am): Likewise.
140592         * modules/backupfile (Makefile.am): Likewise.
140593         * modules/byteswap (Makefile.am): Likewise.
140594         * modules/c-strtod (Makefile.am): Likewise.
140595         * modules/c-strtold (Makefile.am): Likewise.
140596         * modules/calloc (Makefile.am): Likewise.
140597         * modules/canon-host (Makefile.am): Likewise.
140598         * modules/canonicalize (Makefile.am): Likewise.
140599         * modules/chdir-long (Makefile.am): Likewise.
140600         * modules/chdir-safer (Makefile.am): Likewise.
140601         * modules/check-version (Makefile.am): Likewise.
140602         * modules/chown (Makefile.am): Likewise.
140603         * modules/cloexec (Makefile.am): Likewise.
140604         * modules/close-stream (Makefile.am): Likewise.
140605         * modules/closeout (Makefile.am): Likewise.
140606         * modules/crc (Makefile.am): Likewise.
140607         * modules/csharpexec (Makefile.am): Likewise.
140608         * modules/cycle-check (Makefile.am): Likewise.
140609         * modules/des (Makefile.am): Likewise.
140610         * modules/dev-ino (Makefile.am): Likewise.
140611         * modules/dirfd (Makefile.am): Likewise.
140612         * modules/dirname (Makefile.am): Likewise.
140613         * modules/dup2 (Makefile.am): Likewise.
140614         * modules/eealloc (Makefile.am): Likewise.
140615         * modules/error (Makefile.am): Likewise.
140616         * modules/euidaccess (Makefile.am): Likewise.
140617         * modules/exclude (Makefile.am): Likewise.
140618         * modules/exitfail (Makefile.am): Likewise.
140619         * modules/fcntl-safer (Makefile.am): Likewise.
140620         * modules/fcntl (Makefile.am): Likewise.
140621         * modules/file-type (Makefile.am): Likewise.
140622         * modules/fileblocks (Makefile.am): Likewise.
140623         * modules/filemode (Makefile.am): Likewise.
140624         * modules/filenamecat (Makefile.am): Likewise.
140625         * modules/fnmatch (Makefile.am): Likewise.
140626         * modules/fopen-safer (Makefile.am): Likewise.
140627         * modules/fpending (Makefile.am): Likewise.
140628         * modules/fprintftime (Makefile.am): Likewise.
140629         * modules/free (Makefile.am): Likewise.
140630         * modules/fsusage (Makefile.am): Likewise.
140631         * modules/ftruncate (Makefile.am): Likewise.
140632         * modules/fts (Makefile.am): Likewise.
140633         * modules/gc-arcfour (Makefile.am): Likewise.
140634         * modules/gc-des (Makefile.am): Likewise.
140635         * modules/gc-hmac-md5 (Makefile.am): Likewise.
140636         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
140637         * modules/gc-md4 (Makefile.am): Likewise.
140638         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
140639         * modules/gc-sha1 (Makefile.am): Likewise.
140640         * modules/gc (Makefile.am): Likewise.
140641         * modules/getaddrinfo (Makefile.am): Likewise.
140642         * modules/getcwd (Makefile.am): Likewise.
140643         * modules/getdelim (Makefile.am): Likewise.
140644         * modules/getdomainname (Makefile.am): Likewise.
140645         * modules/getgroups (Makefile.am): Likewise.
140646         * modules/gethostname (Makefile.am): Likewise.
140647         * modules/gethrxtime (Makefile.am): Likewise.
140648         * modules/getline (Makefile.am): Likewise.
140649         * modules/getloadavg (Makefile.am): Likewise.
140650         * modules/getlogin_r (Makefile.am): Likewise.
140651         * modules/getndelim2 (Makefile.am): Likewise.
140652         * modules/getopt (Makefile.am): Likewise.
140653         * modules/getpagesize (Makefile.am): Likewise.
140654         * modules/getpass-gnu (Makefile.am): Likewise.
140655         * modules/getpass (Makefile.am): Likewise.
140656         * modules/getsubopt (Makefile.am): Likewise.
140657         * modules/gettime (Makefile.am): Likewise.
140658         * modules/gettimeofday (Makefile.am): Likewise.
140659         * modules/getugroups (Makefile.am): Likewise.
140660         * modules/getusershell (Makefile.am): Likewise.
140661         * modules/glob (Makefile.am): Likewise.
140662         * modules/group-member (Makefile.am): Likewise.
140663         * modules/hard-locale (Makefile.am): Likewise.
140664         * modules/hash (Makefile.am): Likewise.
140665         * modules/hmac-md5 (Makefile.am): Likewise.
140666         * modules/hmac-sha1 (Makefile.am): Likewise.
140667         * modules/human (Makefile.am): Likewise.
140668         * modules/idcache (Makefile.am): Likewise.
140669         * modules/imaxabs (Makefile.am): Likewise.
140670         * modules/imaxdiv (Makefile.am): Likewise.
140671         * modules/inet_ntop (Makefile.am): Likewise.
140672         * modules/inet_pton (Makefile.am): Likewise.
140673         * modules/intprops (Makefile.am): Likewise.
140674         * modules/inttostr (Makefile.am): Likewise.
140675         * modules/inttypes (Makefile.am): Likewise.
140676         * modules/isapipe (Makefile.am): Likewise.
140677         * modules/javaversion (Makefile.am): Likewise.
140678         * modules/lchmod (Makefile.am): Likewise.
140679         * modules/lchown (Makefile.am): Likewise.
140680         * modules/localcharset (Makefile.am): Likewise.
140681         * modules/long-options (Makefile.am): Likewise.
140682         * modules/lstat (Makefile.am): Likewise.
140683         * modules/malloc (Makefile.am): Likewise.
140684         * modules/mathl (Makefile.am): Likewise.
140685         * modules/mbchar (Makefile.am): Likewise.
140686         * modules/md2 (Makefile.am): Likewise.
140687         * modules/md4 (Makefile.am): Likewise.
140688         * modules/md5 (Makefile.am): Likewise.
140689         * modules/memcasecmp (Makefile.am): Likewise.
140690         * modules/memchr (Makefile.am): Likewise.
140691         * modules/memcmp (Makefile.am): Likewise.
140692         * modules/memcoll (Makefile.am): Likewise.
140693         * modules/memcpy (Makefile.am): Likewise.
140694         * modules/memmem (Makefile.am): Likewise.
140695         * modules/memmove (Makefile.am): Likewise.
140696         * modules/mempcpy (Makefile.am): Likewise.
140697         * modules/memrchr (Makefile.am): Likewise.
140698         * modules/memset (Makefile.am): Likewise.
140699         * modules/memxor (Makefile.am): Likewise.
140700         * modules/mkancesdirs (Makefile.am): Likewise.
140701         * modules/mkdir-p (Makefile.am): Likewise.
140702         * modules/mkdir (Makefile.am): Likewise.
140703         * modules/mkdtemp (Makefile.am): Likewise.
140704         * modules/mkstemp (Makefile.am): Likewise.
140705         * modules/mktime (Makefile.am): Likewise.
140706         * modules/modechange (Makefile.am): Likewise.
140707         * modules/mountlist (Makefile.am): Likewise.
140708         * modules/nanosleep (Makefile.am): Likewise.
140709         * modules/obstack (Makefile.am): Likewise.
140710         * modules/openat (Makefile.am): Likewise.
140711         * modules/pagealign_alloc (Makefile.am): Likewise.
140712         * modules/pathmax (Makefile.am): Likewise.
140713         * modules/physmem (Makefile.am): Likewise.
140714         * modules/poll (Makefile.am): Likewise.
140715         * modules/posixtm (Makefile.am): Likewise.
140716         * modules/posixver (Makefile.am): Likewise.
140717         * modules/putenv (Makefile.am): Likewise.
140718         * modules/quote (Makefile.am): Likewise.
140719         * modules/quotearg (Makefile.am): Likewise.
140720         * modules/raise (Makefile.am): Likewise.
140721         * modules/read-file (Makefile.am): Likewise.
140722         * modules/readline (Makefile.am): Likewise.
140723         * modules/readlink (Makefile.am): Likewise.
140724         * modules/readtokens (Makefile.am): Likewise.
140725         * modules/readutmp (Makefile.am): Likewise.
140726         * modules/realloc (Makefile.am): Likewise.
140727         * modules/regex (Makefile.am): Likewise.
140728         * modules/rename-dest-slash (Makefile.am): Likewise.
140729         * modules/rename (Makefile.am): Likewise.
140730         * modules/rijndael (Makefile.am): Likewise.
140731         * modules/rmdir (Makefile.am): Likewise.
140732         * modules/rpmatch (Makefile.am): Likewise.
140733         * modules/safe-read (Makefile.am): Likewise.
140734         * modules/safe-write (Makefile.am): Likewise.
140735         * modules/same-inode (Makefile.am): Likewise.
140736         * modules/same (Makefile.am): Likewise.
140737         * modules/save-cwd (Makefile.am): Likewise.
140738         * modules/savedir (Makefile.am): Likewise.
140739         * modules/setenv (Makefile.am): Likewise.
140740         * modules/settime (Makefile.am): Likewise.
140741         * modules/sha1 (Makefile.am): Likewise.
140742         * modules/sig2str (Makefile.am): Likewise.
140743         * modules/snprintf (Makefile.am): Likewise.
140744         * modules/stat-macros (Makefile.am): Likewise.
140745         * modules/stat-time (Makefile.am): Likewise.
140746         * modules/stdbool (Makefile.am): Likewise.
140747         * modules/stdint (Makefile.am): Likewise.
140748         * modules/stdlib-safer (Makefile.am): Likewise.
140749         * modules/stpcpy (Makefile.am): Likewise.
140750         * modules/stpncpy (Makefile.am): Likewise.
140751         * modules/strcase (Makefile.am): Likewise.
140752         * modules/strcasestr (Makefile.am): Likewise.
140753         * modules/strchrnul (Makefile.am): Likewise.
140754         * modules/strcspn (Makefile.am): Likewise.
140755         * modules/strdup (Makefile.am): Likewise.
140756         * modules/strerror (Makefile.am): Likewise.
140757         * modules/strftime (Makefile.am): Likewise.
140758         * modules/strndup (Makefile.am): Likewise.
140759         * modules/strnlen (Makefile.am): Likewise.
140760         * modules/strpbrk (Makefile.am): Likewise.
140761         * modules/strsep (Makefile.am): Likewise.
140762         * modules/strstr (Makefile.am): Likewise.
140763         * modules/strtod (Makefile.am): Likewise.
140764         * modules/strtoimax (Makefile.am): Likewise.
140765         * modules/strtok_r (Makefile.am): Likewise.
140766         * modules/strtol (Makefile.am): Likewise.
140767         * modules/strtoll (Makefile.am): Likewise.
140768         * modules/strtoul (Makefile.am): Likewise.
140769         * modules/strtoull (Makefile.am): Likewise.
140770         * modules/strtoumax (Makefile.am): Likewise.
140771         * modules/strverscmp (Makefile.am): Likewise.
140772         * modules/sys_socket (Makefile.am): Likewise.
140773         * modules/sys_stat (Makefile.am): Likewise.
140774         * modules/sysexits (Makefile.am): Likewise.
140775         * modules/time_r (Makefile.am): Likewise.
140776         * modules/timegm (Makefile.am): Likewise.
140777         * modules/timespec (Makefile.am): Likewise.
140778         * modules/tmpfile-safer (Makefile.am): Likewise.
140779         * modules/trim (Makefile.am): Likewise.
140780         * modules/unistd-safer (Makefile.am): Likewise.
140781         * modules/unlinkdir (Makefile.am): Likewise.
140782         * modules/unlocked-io (Makefile.am): Likewise.
140783         * modules/userspec (Makefile.am): Likewise.
140784         * modules/utime (Makefile.am): Likewise.
140785         * modules/utimecmp (Makefile.am): Likewise.
140786         * modules/utimens (Makefile.am): Likewise.
140787         * modules/vasnprintf (Makefile.am): Likewise.
140788         * modules/vasprintf (Makefile.am): Likewise.
140789         * modules/vsnprintf (Makefile.am): Likewise.
140790         * modules/xalloc (Makefile.am): Likewise.
140791         * modules/xgetcwd (Makefile.am): Likewise.
140792         * modules/xnanosleep (Makefile.am): Likewise.
140793         * modules/xreadlink (Makefile.am): Likewise.
140794         * modules/xstrtod (Makefile.am): Likewise.
140795         * modules/xstrtol (Makefile.am): Likewise.
140796         * modules/xstrtold (Makefile.am): Likewise.
140797         * modules/yesno (Makefile.am): Likewise.
140798         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
140800 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
140802         * modules/error (Makefile.am): Distribute files through
140803         EXTRA_DIST, not lib_SOURCES.
140805 2006-10-12  Eric Blake  <ebb9@byu.net>
140807         * modules/error (Makefile.am): Distribute files in /lib.
140808         * modules/obstack (Makefile.am): Likewise.
140810 2006-10-12  Bruno Haible  <bruno@clisp.org>
140812         * modules/acl (Makefile.am): Distribute all files in lib/ through
140813         EXTRA_DIST.
140814         * modules/arcfour (Makefile.am): Likewise.
140815         * modules/arctwo (Makefile.am): Likewise.
140816         * modules/argmatch (Makefile.am): Likewise.
140817         * modules/argz (Makefile.am): Likewise.
140818         * modules/atexit (Makefile.am): Likewise.
140819         * modules/backupfile (Makefile.am): Likewise.
140820         * modules/c-strtod (Makefile.am): Likewise.
140821         * modules/c-strtold (Makefile.am): Likewise.
140822         * modules/calloc (Makefile.am): Likewise.
140823         * modules/canon-host (Makefile.am): Likewise.
140824         * modules/canonicalize (Makefile.am): Likewise.
140825         * modules/chdir-long (Makefile.am): Likewise.
140826         * modules/chdir-safer (Makefile.am): Likewise.
140827         * modules/check-version (Makefile.am): Likewise.
140828         * modules/chown (Makefile.am): Likewise.
140829         * modules/cloexec (Makefile.am): Likewise.
140830         * modules/close-stream (Makefile.am): Likewise.
140831         * modules/closeout (Makefile.am): Likewise.
140832         * modules/crc (Makefile.am): Likewise.
140833         * modules/cycle-check (Makefile.am): Likewise.
140834         * modules/des (Makefile.am): Likewise.
140835         * modules/dirfd (Makefile.am): Likewise.
140836         * modules/dirname (Makefile.am): Likewise.
140837         * modules/dup2 (Makefile.am): Likewise.
140838         * modules/euidaccess (Makefile.am): Likewise.
140839         * modules/exclude (Makefile.am): Likewise.
140840         * modules/exitfail (Makefile.am): Likewise.
140841         * modules/fcntl-safer (Makefile.am): Likewise.
140842         * modules/file-type (Makefile.am): Likewise.
140843         * modules/fileblocks (Makefile.am): Likewise.
140844         * modules/filemode (Makefile.am): Likewise.
140845         * modules/filenamecat (Makefile.am): Likewise.
140846         * modules/fnmatch (Makefile.am): Likewise.
140847         * modules/fopen-safer (Makefile.am): Likewise.
140848         * modules/fpending (Makefile.am): Likewise.
140849         * modules/fprintftime (Makefile.am): Likewise.
140850         * modules/free (Makefile.am): Likewise.
140851         * modules/fsusage (Makefile.am): Likewise.
140852         * modules/ftruncate (Makefile.am): Likewise.
140853         * modules/fts (Makefile.am): Likewise.
140854         * modules/gc (Makefile.am): Likewise.
140855         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
140856         * modules/getaddrinfo (Makefile.am): Likewise.
140857         * modules/getcwd (Makefile.am): Likewise.
140858         * modules/getdelim (Makefile.am): Likewise.
140859         * modules/getdomainname (Makefile.am): Likewise.
140860         * modules/getgroups (Makefile.am): Likewise.
140861         * modules/gethostname (Makefile.am): Likewise.
140862         * modules/gethrxtime (Makefile.am): Likewise.
140863         * modules/getline (Makefile.am): Likewise.
140864         * modules/getloadavg (Makefile.am): Likewise.
140865         * modules/getlogin_r (Makefile.am): Likewise.
140866         * modules/getopt (Makefile.am): Likewise.
140867         * modules/getpass (Makefile.am): Likewise.
140868         * modules/getpass-gnu (Makefile.am): Likewise.
140869         * modules/getsubopt (Makefile.am): Likewise.
140870         * modules/gettime (Makefile.am): Likewise.
140871         * modules/gettimeofday (Makefile.am): Likewise.
140872         * modules/getugroups (Makefile.am): Likewise.
140873         * modules/getusershell (Makefile.am): Likewise.
140874         * modules/glob (Makefile.am): Likewise.
140875         * modules/group-member (Makefile.am): Likewise.
140876         * modules/hard-locale (Makefile.am): Likewise.
140877         * modules/hash (Makefile.am): Likewise.
140878         * modules/hmac-md5 (Makefile.am): Likewise.
140879         * modules/hmac-sha1 (Makefile.am): Likewise.
140880         * modules/human (Makefile.am): Likewise.
140881         * modules/idcache (Makefile.am): Likewise.
140882         * modules/imaxabs (Makefile.am): Likewise.
140883         * modules/imaxdiv (Makefile.am): Likewise.
140884         * modules/inet_ntop (Makefile.am): Likewise.
140885         * modules/inet_pton (Makefile.am): Likewise.
140886         * modules/inttostr (Makefile.am): Likewise.
140887         * modules/isapipe (Makefile.am): Likewise.
140888         * modules/lchown (Makefile.am): Likewise.
140889         * modules/long-options (Makefile.am): Likewise.
140890         * modules/lstat (Makefile.am): Likewise.
140891         * modules/malloc (Makefile.am): Likewise.
140892         * modules/mathl (Makefile.am): Likewise.
140893         * modules/mbchar (Makefile.am): Likewise.
140894         * modules/md2 (Makefile.am): Likewise.
140895         * modules/md4 (Makefile.am): Likewise.
140896         * modules/md5 (Makefile.am): Likewise.
140897         * modules/memcasecmp (Makefile.am): Likewise.
140898         * modules/memchr (Makefile.am): Likewise.
140899         * modules/memcmp (Makefile.am): Likewise.
140900         * modules/memcoll (Makefile.am): Likewise.
140901         * modules/memcpy (Makefile.am): Likewise.
140902         * modules/memmem (Makefile.am): Likewise.
140903         * modules/memmove (Makefile.am): Likewise.
140904         * modules/mempcpy (Makefile.am): Likewise.
140905         * modules/memrchr (Makefile.am): Likewise.
140906         * modules/memset (Makefile.am): Likewise.
140907         * modules/memxor (Makefile.am): Likewise.
140908         * modules/mkancesdirs (Makefile.am): Likewise.
140909         * modules/mkdir (Makefile.am): Likewise.
140910         * modules/mkdir-p (Makefile.am): Likewise.
140911         * modules/mkdtemp (Makefile.am): Likewise.
140912         * modules/mkstemp (Makefile.am): Likewise.
140913         * modules/mktime (Makefile.am): Likewise.
140914         * modules/modechange (Makefile.am): Likewise.
140915         * modules/mountlist (Makefile.am): Likewise.
140916         * modules/nanosleep (Makefile.am): Likewise.
140917         * modules/openat (Makefile.am): Likewise.
140918         * modules/pagealign_alloc (Makefile.am): Likewise.
140919         * modules/physmem (Makefile.am): Likewise.
140920         * modules/poll (Makefile.am): Likewise.
140921         * modules/posixtm (Makefile.am): Likewise.
140922         * modules/posixver (Makefile.am): Likewise.
140923         * modules/putenv (Makefile.am): Likewise.
140924         * modules/quote (Makefile.am): Likewise.
140925         * modules/quotearg (Makefile.am): Likewise.
140926         * modules/raise (Makefile.am): Likewise.
140927         * modules/read-file (Makefile.am): Likewise.
140928         * modules/readline (Makefile.am): Likewise.
140929         * modules/readlink (Makefile.am): Likewise.
140930         * modules/readtokens (Makefile.am): Likewise.
140931         * modules/readutmp (Makefile.am): Likewise.
140932         * modules/realloc (Makefile.am): Likewise.
140933         * modules/regex (Makefile.am): Likewise.
140934         * modules/rename (Makefile.am): Likewise.
140935         * modules/rename-dest-slash (Makefile.am): Likewise.
140936         * modules/rijndael (Makefile.am): Likewise.
140937         * modules/rmdir (Makefile.am): Likewise.
140938         * modules/rpmatch (Makefile.am): Likewise.
140939         * modules/safe-read (Makefile.am): Likewise.
140940         * modules/safe-write (Makefile.am): Likewise.
140941         * modules/same (Makefile.am): Likewise.
140942         * modules/save-cwd (Makefile.am): Likewise.
140943         * modules/savedir (Makefile.am): Likewise.
140944         * modules/setenv (Makefile.am): Likewise.
140945         * modules/settime (Makefile.am): Likewise.
140946         * modules/sha1 (Makefile.am): Likewise.
140947         * modules/sig2str (Makefile.am): Likewise.
140948         * modules/snprintf (Makefile.am): Likewise.
140949         * modules/stdlib-safer (Makefile.am): Likewise.
140950         * modules/stpcpy (Makefile.am): Likewise.
140951         * modules/stpncpy (Makefile.am): Likewise.
140952         * modules/strcase (Makefile.am): Likewise.
140953         * modules/strcasestr (Makefile.am): Likewise.
140954         * modules/strchrnul (Makefile.am): Likewise.
140955         * modules/strcspn (Makefile.am): Likewise.
140956         * modules/strdup (Makefile.am): Likewise.
140957         * modules/strerror (Makefile.am): Likewise.
140958         * modules/strftime (Makefile.am): Likewise.
140959         * modules/strndup (Makefile.am): Likewise.
140960         * modules/strnlen (Makefile.am): Likewise.
140961         * modules/strpbrk (Makefile.am): Likewise.
140962         * modules/strsep (Makefile.am): Likewise.
140963         * modules/strstr (Makefile.am): Likewise.
140964         * modules/strtod (Makefile.am): Likewise.
140965         * modules/strtoimax (Makefile.am): Likewise.
140966         * modules/strtok_r (Makefile.am): Likewise.
140967         * modules/strtol (Makefile.am): Likewise.
140968         * modules/strtoll (Makefile.am): Likewise.
140969         * modules/strtoul (Makefile.am): Likewise.
140970         * modules/strtoull (Makefile.am): Likewise.
140971         * modules/strtoumax (Makefile.am): Likewise.
140972         * modules/strverscmp (Makefile.am): Likewise.
140973         * modules/time_r (Makefile.am): Likewise.
140974         * modules/timegm (Makefile.am): Likewise.
140975         * modules/tmpfile-safer (Makefile.am): Likewise.
140976         * modules/unistd-safer (Makefile.am): Likewise.
140977         * modules/unlinkdir (Makefile.am): Likewise.
140978         * modules/userspec (Makefile.am): Likewise.
140979         * modules/utime (Makefile.am): Likewise.
140980         * modules/utimecmp (Makefile.am): Likewise.
140981         * modules/utimens (Makefile.am): Likewise.
140982         * modules/vasnprintf (Makefile.am): Likewise.
140983         * modules/vasprintf (Makefile.am): Likewise.
140984         * modules/vsnprintf (Makefile.am): Likewise.
140985         * modules/xalloc (Makefile.am): Likewise.
140986         * modules/xgetcwd (Makefile.am): Likewise.
140987         * modules/xnanosleep (Makefile.am): Likewise.
140988         * modules/xreadlink (Makefile.am): Likewise.
140989         * modules/xstrtod (Makefile.am): Likewise.
140990         * modules/xstrtol (Makefile.am): Likewise.
140991         * modules/xstrtold (Makefile.am): Likewise.
140992         * modules/yesno (Makefile.am): Likewise.
140994 2006-10-12  Jim Meyering  <jim@meyering.net>
140996         * m4/getloadavg.m4: Revert the change below.
140998         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
140999         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
141000         fail with a symlink, which is what coreutils' ./bootstrap now
141001         creates by default.
141003 2006-10-12  Bruno Haible  <bruno@clisp.org>
141005         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
141006         mingw.
141007         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
141008         MSVC and mingw explicitly.
141010 2006-10-11  Simon Josefsson  <jas@extundo.com>
141011             Bruno Haible  <bruno@clisp.org>
141013         Add support for multiple gnulib-tool invocations in the scope of a
141014         single configure.ac file.
141015         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
141016         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
141017         with the same contents as the _LIBADD variable.
141018         (func_emit_initmacro_start, func_emit_initmacro_end,
141019         func_emit_initmacro_done): New functions.
141020         (func_import, func_create_testdir): Invoke them. Allow the identifiers
141021         gl_LIBOBJS and gl_LTLIBOBJS.
141023 2006-10-11  Bruno Haible  <bruno@clisp.org>
141025         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
141026         (func_create_testdir): Don't create po/Makefile.am, don't invoke
141027         autoreconf. Instead, invoke autopoint explicitly but move back the
141028         *.m4 files from gnulib.
141030 2006-10-11  Bruno Haible  <bruno@clisp.org>
141032         * gnulib-tool (func_usage): Make module names after --create-testdir
141033         optional.
141034         (func_create_testdir): If no module was specified, use nearly all
141035         modules.
141037 2006-10-12  Jim Meyering  <jim@meyering.net>
141039         Big performance improvement for fts-based tools that use FTS_NOSTAT.
141040         Avoid spurious inode-mismatch problems on non-POSIX file systems.
141041         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
141042         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
141043         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
141044         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
141045         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
141046         (fts_set_stat_required): New function.
141047         (fts_open): Defer the calls to fts_stat, if possible or requested.
141048         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
141049         into fts_stat itself.
141050         (fts_read): Perform any required (deferred) fts_stat call.
141051         (fts_build): Likewise, for the directory we're about to open and read.
141052         In the readdir loop, carefully decide whether each entry will require
141053         an eventual call to fts_stat, using dirent.d_type info if available.
141054         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
141055         a command line argument into this function.  Update all callers.
141056         Map a return value of FTS_DOT to FTS_D for a command line argument.
141057         * modules/fts (Depends-on): Add d-type.  Alphabetize.
141058         Thanks to Miklos Szeredi for his tenacity and for the initial
141059         bug report about "find" failing on a FUSE-based file system.
141061         * lib/fts.c (fts_open): Use consistent indentation.
141063 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
141065         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
141066         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
141067         reported by Jim Meyering.  All uses of cache variables renamed
141068         to match Autoconf's.
141069         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
141070         the other one.
141072         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
141073         Fix misspelling in diagnostic.
141075 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
141077         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
141078         defined.  Problem reported by Matthew Woehlke.
141080         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
141081         Add support for Tandem NonStop R series.
141082         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
141083         Use new macro.
141085         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
141086         (has_trailing_slash): Omit size arg; all callers changed.
141087         Omit 'inline', since it doesn't help performance and we'd
141088         need to configure it.
141089         Don't count //, ///, etc. as having a trailing slash.
141090         As a side effect, this removes a C99ism reported by Matthew Woehlke.
141091         (rpl_rename_dest_slash): On failure, use rename's errno rather
141092         than (in some cases) an incorrect or junk errno.
141093         Simplify code by removing need to compute length; this does
141094         cause it to make two passes instead of one over the file name,
141095         but it's worth it.
141097         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
141098         change, since Autoconf's version may no longer be appropriate now
141099         that we are using CVS Autoconf's version.  Add support for Tandem.
141101 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
141102             Bruno Haible  <bruno@clisp.org>
141104         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
141105         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
141106         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
141107         gl_AC_TYPE_LONG_LONG.
141109         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
141110         instead of HAVE_LONG_LONG.
141111         * lib/printf-args.c (printf_fetchargs): Likewise.
141112         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
141113         * lib/vasnprintf.c (VASNPRINTF): Likewise.
141114         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
141115         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
141116         gl_AC_TYPE_LONG_LONG.
141118 2006-10-11  Bruno Haible  <bruno@clisp.org>
141120         * m4/longlong.m4: Add comments.
141121         * m4/ulonglong.m4: Likewise.
141123 2006-10-10  Bruno Haible  <bruno@clisp.org>
141125         Make it possible to #define stpcpy, strdup to aliases.
141126         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
141127         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
141129 2006-10-10  Bruno Haible  <bruno@clisp.org>
141131         Make it possible to #define gcd to an alias.
141132         * lib/gcd.c: Include config.h.
141134 2006-10-10  Bruno Haible  <bruno@clisp.org>
141136         Make it possible to #define c_isascii to an alias.
141137         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
141138         defined. Undefine the macros before defining them, to avoid gcc
141139         warnings.
141140         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
141141         define NO_C_CTYPE_MACROS early.
141143 2006-10-10  Bruno Haible  <bruno@clisp.org>
141145         Make it possible to #define set_program_name to an alias.
141146         * lib/progname.c: Don't undefine set_program_name; instead, undefine
141147         ENABLE_RELOCATABLE early.
141149 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
141151         Port to Tandem NSK OSS, which has 64-bit signed int but at most
141152         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
141153         http://lists.gnu.org/r/bug-coreutils/2006-10/msg00062.html
141154         More generally, don't assume that 64-bit signed int is available
141155         if unsigned int is, and vice versa.
141156         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
141157         unsigned symbols, not on their signed counterparts.
141158         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
141159         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
141160         (UINT64_C, UINTMAX_C):
141161         Likewise.
141162         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
141163         unsigned counterparts.
141164         (Have_long_long, Unsigned): New macros.
141165         (Int): Renamed from INT.
141166         (strtoimax): Use the new macros.
141167         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
141168         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
141169         * modules/inttypes (inttypes.h): Substitute
141170         HAVE_UNSIGNED_LONG_LONG_INT.
141171         * modules/stdint (stdint.h): Likewise.
141172         (Files): Add m4/ulonglong.m4.
141174 2006-10-10  Bruno Haible  <bruno@clisp.org>
141176         Fix a gcc -Wshadow warning.
141177         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
141178         to 'bucket'.
141179         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
141180         gl_linked_indexof_from_to): Likewise.
141181         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
141182         Likewise.
141183         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
141184         Likewise.
141185         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
141186         Reported by Eric Blake.
141188 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
141190         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
141191         for NetBSD.  Problem reported by Bruno Haible.
141193 2006-10-09  Jim Meyering  <jim@meyering.net>
141195         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
141196         Patch from Bruno Haible.
141198 2006-10-09  Jim Meyering  <jim@meyering.net>
141200         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
141201         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
141202         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
141204 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
141206         Don't include <config.h> twice; this doesn't work in some cases,
141207         e.g., when config.h has "#define intmax_t long long int" and
141208         we include <config.h>, <inttypes.h>, <config.h> in that order.
141209         Problem reported by Matthew Woehlke in:
141210         http://lists.gnu.org/r/bug-coreutils/2006-10/msg00073.html
141211         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
141212         * lib/fts-cycle.c: Don't include config.h.
141213         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
141214         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
141215         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
141216         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
141217         inttypes.h.
141218         * lib/xstrtoumax.c: Likewise.
141219         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
141220         __strtol and the like, so that this module is more like its siblings.
141221         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
141222         Remove; no longer needed now that we assume gnulib inttypes.h.
141224 2006-10-08  Bruno Haible  <bruno@clisp.org>
141226         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
141227         option.
141229 2006-10-07  Jim Meyering  <jim@meyering.net>
141231         * modules/inttypes (inttypes.h): Revert what seems to have been
141232         an inadvertent part of today's change: use "|", not "/" in the
141233         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
141235 2006-10-07  Bruno Haible  <bruno@clisp.org>
141237         * modules/sublist: New file.
141239 2006-10-07  Bruno Haible  <bruno@clisp.org>
141241         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
141242         * modules/argz (argz.h): Likewise.
141243         * modules/arpa_inet (arpa/inet.h): Likewise.
141244         * modules/byteswap (byteswap.h): Likewise.
141245         * modules/configmake (configmake.h): Likewise.
141246         * modules/fcntl (fcntl.h): Likewise.
141247         * modules/fnmatch (fnmatch.h): Likewise.
141248         * modules/getopt (getopt.h): Likewise.
141249         * modules/glob (glob.h): Likewise.
141250         * modules/inttypes (inttypes.h): Likewise.
141251         * modules/netinet_in (netinet/in.h): Likewise.
141252         * modules/poll (poll.h): Likewise.
141253         * modules/stdbool (stdbool.h): Likewise.
141254         * modules/stdint (stdint.h): Likewise.
141255         * modules/sys_select (sys/select.h): Likewise.
141256         * modules/sys_socket (sys/socket.h): Likewise.
141257         * modules/sys_stat (sys/stat.h): Likewise.
141258         * modules/sysexits (sysexits.h): Likewise.
141259         * modules/unistd (unistd.h): Likewise.
141260         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
141261         Add a "DO NOT EDIT" comment to the generated file.
141262         (func_import): Likewise for gnulib-comp.m4.
141264 2006-10-07  Bruno Haible  <bruno@clisp.org>
141266         * lib/gl_sublist.h: New file.
141267         * lib/gl_sublist.c: New file.
141269 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
141271         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
141272         name (relative to the original working directory) and the file
141273         name component (relative to the temporary working directory).  All
141274         callers changed.
141275         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
141276         * lib/mkdir-p.c (make_dir_parents): Likewise.
141277         * lib/mkdir-p.h (make_dir_parents): Likewise.
141279 2006-10-06  Eric Blake  <ebb9@byu.net>
141281         Define several macros for use by the clean-temp module.
141282         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
141283         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
141284         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
141286         * lib/clean-temp.h (close_stream_temp): New declaration.
141287         * lib/clean-temp.c (includes): Pull in headers according to what
141288         other modules are in use.
141289         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
141291 2006-10-06  Bruno Haible  <bruno@clisp.org>
141293         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
141294         instead of fopen, fwriteerror.
141296 2006-10-06  Bruno Haible  <bruno@clisp.org>
141298         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
141299         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
141300         int.
141301         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
141302         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
141303         Return an error indicator.
141304         Suggested by Eric Blake.
141306 2006-10-06  Bruno Haible  <bruno@clisp.org>
141308         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
141309         Reported by Eric Blake.
141311 2006-10-06  Bruno Haible  <bruno@clisp.org>
141313         * modules/closeout (Description): Mention stderr too.
141315 2006-10-06  Bruno Haible  <bruno@clisp.org>
141316         and Paul Eggert  <eggert@cs.ucla.edu>
141318         * lib/closeout.c (close_stdout): Also close stderr.
141319         * lib/closeout.h: Update comment.
141321 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
141323         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
141324         <http://lists.gnu.org/r/bug-coreutils/2006-10/msg00063.html>.
141325         * lib/dirchownmod.c: Include lchown.h.
141326         * lib/lchown.c: Don't include files that lchown.h now includes.
141327         Don't declare chown, since lchown.h now does that.
141328         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
141329         (lchown): Define to rpl_chown if lchown is declared but
141330         does not exist.  Declare using a prototype if lchown is not
141331         declared.  Add a copyright notice.
141332         * lib/mkstemp.h: Include <unistd.h>.
141333         * lib/openat.c: Include lchown.h.
141335         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
141336         we now test for that separately.
141337         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
141338         rather than O_NOFOLLOW, when testing whether it's possible to
141339         avoid a race condition reliably.
141340         * lib/savewd.c (savewd_chdir): Likewise.
141342         Remove macros that are no longer needed now that stdint.h is
141343         reliable.
141344         * lib/fsusage.c (UINTMAX_MAX): Remove.
141345         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
141346         * lib/utimecmp.c (SIZE_MAX): Remove.
141348         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
141350         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
141351         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
141352         O_NOATIME works.
141354 2006-10-05  Bruno Haible  <bruno@clisp.org>
141356         * lib/gl_list.h (gl_sortedlist_search_from_to,
141357         gl_sortedlist_indexof_from_to): New declarations.
141358         (gl_list_implementation): New fields sortedlist_search_from_to,
141359         sortedlist_indexof_from_to.
141360         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
141361         inline functions.
141362         * lib/gl_list.c (gl_sortedlist_search_from_to,
141363         gl_sortedlist_indexof_from_to): New functions.
141364         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
141365         function.
141366         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
141367         (gl_array_sortedlist_search_from_to): New function.
141368         (gl_array_list_implementation): Update.
141369         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
141370         function.
141371         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
141372         (gl_carray_sortedlist_search_from_to): New function.
141373         (gl_carray_list_implementation): Update.
141374         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
141375         gl_linked_sortedlist_indexof_from_to): New functions.
141376         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
141377         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
141378         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
141379         gl_tree_sortedlist_indexof_from_to): New functions.
141380         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
141381         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
141382         Update.
141383         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
141384         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
141385         Update.
141387 2006-10-05  Bruno Haible  <bruno@clisp.org>
141389         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
141390         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
141391         (struct gl_list_implementation): Add fields search_from_to,
141392         indexof_from_to. Remove fields search, indexof.
141393         (gl_list_search): Use the search_from_to method.
141394         (gl_list_search_from, gl_list_search_from_to): New functions.
141395         (gl_list_indexof): Use the indexof_from_to method.
141396         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
141397         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
141398         (gl_list_search_from, gl_list_search_from_to): New functions.
141399         (gl_list_indexof): Use the indexof_from_to method.
141400         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
141401         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
141402         gl_array_indexof. Add start_index, end_index arguments.
141403         (gl_array_search_from_to): Renamed from gl_array_search. Add
141404         start_index, end_index arguments.
141405         (gl_array_remove, gl_array_list_implementation): Update.
141406         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
141407         gl_carray_indexof. Add start_index, end_index arguments.
141408         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
141409         start_index, end_index arguments.
141410         (gl_carray_remove, gl_carray_list_implementation): Update.
141411         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
141412         gl_linked_search. Add start_index, end_index arguments.
141413         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
141414         start_index, end_index arguments.
141415         (gl_linked_remove): Update.
141416         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
141417         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
141418         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
141419         field to 'size_t'.
141420         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
141421         gl_tree_search. Add start_index, end_index arguments.
141422         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
141423         start_index, end_index arguments.
141424         (gl_tree_remove): Update.
141425         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
141426         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
141427         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
141428         function.
141429         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
141430         gl_tree_search. Add start_index, end_index arguments.
141431         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
141432         start_index, end_index arguments.
141433         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
141434         Update.
141435         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
141437 2006-10-05  Bruno Haible  <bruno@clisp.org>
141439         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
141441         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
141442         fwriteerror_temp): New declarations.
141443         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
141444         (descriptors): New variable.
141445         (cleanup): First, close the descriptors.
141446         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
141447         fclose_temp, fwriteerror_temp): New functions.
141449 2006-10-04  Jim Meyering  <jim@meyering.net>
141451         * lib/fts.c (fts_open): Tiny comment change.
141453 2006-10-04  Bruno Haible  <bruno@clisp.org>
141455         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
141456         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
141457         gl_LOCK_BODY.
141458         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
141459         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
141460         gl_LOCK_EARLY_BODY.
141461         (gl_LOCK): Require gl_LOCK_BODY.
141463 2006-10-04  Bruno Haible  <bruno@clisp.org>
141465         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
141466         (gl_oset_search_atleast): New declaration.
141467         (struct gl_oset_implementation): Add field 'search_atleast'.
141468         (gl_oset_search_atleast): New inline function.
141469         * lib/gl_oset.c (gl_oset_search_atleast): New function.
141470         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
141471         (gl_array_oset_implementation): Update.
141472         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
141473         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
141474         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
141476 2006-10-04  Bruno Haible  <bruno@clisp.org>
141478         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
141480 2006-10-03  Bruno Haible  <bruno@clisp.org>
141482         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
141483         from gl_avltreehash_list_implementation.
141485 2006-10-03  Bruno Haible  <bruno@clisp.org>
141487         * lib/gl_oset.c (gl_oset_add): Fix return type.
141489 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
141491         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
141493 2006-10-02  Eric Blake  <ebb9@byu.net>
141495         * modules/strnlen (Depends-on): Add extensions.
141497 2006-10-02  Eric Blake  <ebb9@byu.net>
141499         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
141500         definition in 2.60+.
141502 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
141504         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
141505         checks.
141507 2006-10-02  Bruno Haible  <bruno@clisp.org>
141509         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
141510         to the AUTOMAKE_OPTIONS.
141511         Reported by Jim Meyering.
141513 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
141515         Work around bug in Solaris 10 /proc file system:
141516         /proc/self/fd/NNN/.. isn't the parent directory of
141517         the directory whose file descriptor is NNN.  This needs to
141518         be worked around at run time, not compile time, since a
141519         program might be built on Solaris 8, where things work, and
141520         run on Solaris 10.
141521         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
141522         to use the following interface instead:
141523         (OPENAT_BUFFER_SIZE): New macro.
141524         (openat_proc_name): New function.
141525         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
141526         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
141527         Likewise.
141528         * lib/openat-proc.c: New file.
141529         * modules/openat (Files): Add lib/openat-proc.c.
141530         (Depends-on): Add same-inode, stdbool.
141531         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
141533 2006-09-29  Bruno Haible  <bruno@clisp.org>
141535         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
141536         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
141537         argument. Set stdout_closed before testing for ferror, not after.
141538         (fwriteerror, fwriteerror_no_ebadf): New functions.
141540 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141542         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
141544 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
141546         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
141547         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
141549 2006-09-28  Jim Meyering  <jim@meyering.net>
141551         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
141552         Include <unistd.h>.
141554 2006-09-28  Bruno Haible  <bruno@clisp.org>
141556         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
141557         * modules/linkedhash-list (Depends-on): Likewise.
141558         * modules/rbtreehash-list (Depends-on): Likewise.
141560 2006-09-28  Bruno Haible  <bruno@clisp.org>
141562         * lib/strndup.h: Simplify the redefinition of strndup.
141563         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
141564         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
141566 2006-09-28  Bruno Haible  <bruno@clisp.org>
141568         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
141569         * lib/gl_linkedhash_list.c: Likewise.
141570         * lib/gl_rbtreehash_list.c: Likewise.
141572 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
141574         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
141575         getaddrinfo.
141577         * lib/__fpending.h: Don't include <stdio_ext.h> unless
141578         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
141579         it causes <stdio_ext.h> to cause a compile-time error.
141580         Problem reported by Nelson H. F. Beebe.
141581         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
141582         of HAVE_DECL___PENDING.
141584         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
141585         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
141586         declaration.
141588 2006-09-27  Jim Meyering  <jim@meyering.net>
141590         This file could end up with a definition for a function
141591         named __strndup, rather than rpl_strndup on a system with
141592         incomplete weak_alias support.
141593         * lib/strndup.c (strndup): Rename from __strndup.
141594         Remove #defines that used to map __strndup to strndup.
141595         Don't use K&R prototypes.
141596         Remove LIBC-related code, since this file is not sync'd with glibc.
141597         * lib/strndup.h: Revamp, accordingly.
141598         * m4/strndup.m4: Modernize.
141600 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
141602         * modules/savewd (Depends-on): Add 'raise'.
141603         * lib/savewd.c: Include <signal.h>, for 'raise'.
141605 2006-09-26  Jim Meyering  <jim@meyering.net>
141607         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
141608         when we detect Darwin 8.7.0's acl_get_file bug.
141609         Rearrange to perform the new (below) run-test while $LIBS
141610         contains any acl-related library.  Set USE_ACL at the end.
141611         (gl_ACL_GET_FILE): New function.
141613 2006-09-26  Eric Blake  <ebb9@byu.net>
141615         * lib/verror.c: Include <config.h> unconditionally.
141617 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
141619         * modules/clock-time (Maintainer): Add self.
141620         * modules/getlogin_r (Depends-on): Add extensions.
141622 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141624         * modules/clock-time: New module.
141625         * modules/nanosleep (Depends-on): Add clock-time.
141626         * modules/gethrxtime (Depends-on): Likewise.
141627         * modules/gettime (Depends-on): Likewise.
141628         * modules/settime (Depends-on): Likewise.
141630         * modules/fts-lgpl: Depend on openat.
141631         * modules/mkancesdirs: Depend on savewd.
141632         * modules/mkdir-p: Likewise.
141634 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141636         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
141638         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
141639         `gl_have_arbitrary_file_name_length_limit' to
141640         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
141641         actually works between configure runs.
141643 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141644             Bruno Haible  <bruno@clisp.org>
141646         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
141648 2006-09-25  Jim Meyering  <jim@meyering.net>
141650         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
141651         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
141653 2006-09-25  Eric Blake  <ebb9@byu.net>
141655         * gnulib-tool (func_import, func_create_testdir): Fix typos in
141656         exec's in 2006-09-18 patch when shuffling fds.
141658 2006-09-25  Bruno Haible  <bruno@clisp.org>
141660         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
141661         Reported by Jim Meyering.
141663 2006-09-24  Jim Meyering  <jim@meyering.net>
141665         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
141666         compare a pointer against a literal "0".  That caused failures with
141667         at least HP-UX's hpcc.
141669 2006-09-22  Simon Josefsson  <jas@extundo.com>
141671         * modules/gc-sha1:
141672         * modules/gc-md4:
141673         * modules/gc-hmac-sha1:
141674         * modules/gc-hmac-md5:
141675         * modules/gc-des:
141676         * modules/gc-arcfour: Distribute more files.
141678 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141680         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
141681         (gl_linked_iterator_from_to): Initialize struct completely.
141682         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
141683         (gl_tree_iterator_from_to): Likewise
141684         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
141685         * lib/gl_array_list.c [lint] (gl_array_iterator)
141686         (gl_array_iterator_from_to): Likewise.
141687         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
141688         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
141689         (gl_carray_iterator_from_to): Likewise.
141691         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
141692         * lib/md4.c (md4_process_block): Remove unused variable.
141693         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
141694         parentheses for clarity.
141696 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141698         * modules/bison-i18n (Depends-on): Add gettext.
141700 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141702         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
141703         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
141704         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
141705         also add missing comma that caused broken test.
141706         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
141707         stdlib.h, for `abort'.
141708         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
141709         variables.
141710         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
141711         include unistd.h if present, for `rmdir'.
141712         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
141713         variables.
141714         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
141715         in the process include standard headers for prototypes.
141716         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
141717         gets declared on GNU/Linux.
141718         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
141719         unistd.h, for `rmdir'.
141720         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
141722         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
141723         always true.
141724         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
141726         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
141728 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141730         * gnulib-tool (func_version): Create output all at once.  This
141731         may help avoid triggering unnecessary SIGPIPEs, and at any
141732         rate it doesn't hurt.
141734 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141735             Bruno Haible  <bruno@clisp.org>
141737         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
141738         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
141739         * m4/signed.m4 (bh_C_SIGNED): Likewise.
141741         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
141742         (gl_FUNC_VASPRINTF): Invoke it.
141744 2006-09-22  Bruno Haible  <bruno@clisp.org>
141746         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
141747         getloadavg.c as first argument.
141749 2006-09-22  Bruno Haible  <bruno@clisp.org>
141751         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
141752         at the beginning of the gl_INIT macro.
141753         * modules/getloadavg (configure.ac): Pass $gl_source_base to
141754         gl_GETLOADAVG.
141756 2006-09-22  Bruno Haible  <bruno@clisp.org>
141758         * gnulib-tool (func_create_megatestdir): Don't include the config-h
141759         module.
141760         Suggested by Ralf Wildenhues.
141762 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
141764         Import this patch from libc:
141766         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
141768         * lib/regex_internal.c (re_string_reconstruct): Handle
141769         offset < pstr->valid_raw_len && pstr->offsets_needed case.
141770         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
141771         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
141772         re_string_context_at.
141774         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
141775         now requires it.
141776         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
141777         gl_REGEX now does it for us.
141778         (gl_REGEX): Add test taken from
141779         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
141781         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
141782         Check that large offsets work.  Modernize Autoconf usages.
141783         Prefer "yes" to mean a good thing rather than a bad.
141784         Don't put "#define mkstemp" in config.h, as this might interfere
141785         with standard system headers that "#define mkstemp mkstemp64".
141787         * modules/mkstemp (Depends-on): Add extensions, so that
141788         mkstemp is visible on some platforms.
141789         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
141790         (Include): Change to "mkstemp.h" from <stdlib.h>.
141791         (Files): Add mkstemp.h.
141793         * lib/mkstemp.h: New file, since some standard headers
141794         #define mkstemp.
141795         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
141796         Include "mkstemp.h".
141797         Make the _LIBC code resemble glibc original more,
141798         e.g., use K&R style.
141799         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
141800         (mkstemp): Remove, since mkstemp.h does this for us.
141801         * lib/stdlib--.h: Include mkstemp.h.
141803         Import this patch from libc:
141805         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
141807         * lib/tempname.c (__gen_tempname): Change attempts_min
141808         into a macro.  Use preprocessor to decide how to initialize
141809         attempts [Coverity CID 67].
141811 2006-09-20  Bruno Haible  <bruno@clisp.org>
141813         * lib/mkdtemp.c: Import from libc.
141814         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
141815                 * sysdeps/posix/tempname.c (__gen_tempname): Change
141816                 attempts_min into a macro.  Use preprocessor to decide how to
141817                 initialize attempts [Coverity CID 67].
141818         2001-11-27  Paul Eggert  <eggert@twinsun.com>
141819                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
141820                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
141822 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141824         * gnulib-tool (func_exit): New function, to allow to pass the
141825         exit status portably through the trap.  Use everywhere.
141826         (--help, --version): Signal a write error.
141827         (trap): catch SIGPIPE, for write errors.
141828         Exit at the end of the trap, with the correct exit status.
141830 2006-09-19  Karl Berry  <karl@gnu.org>
141832         * doc/gnulib.texi: note about the license texinfo files.
141834 2006-09-19  Eric Blake  <ebb9@byu.net>
141836         * gnulib-tool: Avoid space-tab.
141838 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
141840         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
141841         that prevented coreutils 6.1 from building.  Problem reported
141842         by Petter Reinholdtsen.
141844 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
141846         * gnulib-tool (avoidlist): Fix typo that broke options like
141847         --avoid=lock that are used by coreutils bootstrap.
141849 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
141851         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
141852         more systematically.
141854 2006-09-18  Jim Meyering  <jim@meyering.net>
141856         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
141858 2006-09-18  Bruno Haible  <bruno@clisp.org>
141860         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
141862 2006-09-18  Bruno Haible  <bruno@clisp.org>
141864         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
141865         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
141866         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
141867         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
141868         * m4/gettext.m4: Require autoconf >= 2.52.
141869         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
141870         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
141871         of gl_cv_header_inttypes_h.
141873 2006-09-18  Bruno Haible  <bruno@clisp.org>
141875         * lib/javaversion.c: Include configmake.h.
141877 2006-09-18  Bruno Haible  <bruno@clisp.org>
141879         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
141880         avoid that the while loops be executed in a subshell.
141882 2006-09-18  Bruno Haible  <bruno@clisp.org>
141884         * MODULES.html.sh (func_module): Break long lines.
141885         Suggested by Bruce Korb <bkorb@gnu.org>.
141887 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141889         Speed up by a factor of 1.12.
141890         * gnulib-tool (nl): New variable.
141891         (func_import): Rewrite include directive extraction to only read each
141892         directive once.
141894 2006-09-17  Bruno Haible  <bruno@clisp.org>
141896         * modules/javaversion (Makefile.am): Remove DEFS setting.
141897         (Depends-on): Add configmake, for PKGDATADIR definition.
141899 2006-09-17  Bruno Haible  <bruno@clisp.org>
141901         * gnulib-tool (func_create_testdir): Rewrite all files at once.
141903 2006-09-17  Bruno Haible  <bruno@clisp.org>
141905         * gnulib-tool (func_append): New function, stolen from libtool.m4.
141906         (func_modules_transitive_closure, func_modules_add_dummy,
141907         func_modules_to_filelist, func_import, func_create_testdir,
141908         func_create_megatestdir, ...): Use it wherever possible.
141909         Suggested by Ralf Wildenhues.
141911 2006-09-16  Karl Berry  <karl@gnu.org>
141913         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
141914         to avoid sectioning errors.
141915         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
141916         [ifinfo]: blank line after @center-ed titles.
141917         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
141918         Spell FSF address consistently with others.
141919         (These changes approved by rms.)
141921 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141923         Speed up by a factor of 1.61.
141924         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
141925         already checked module names again.
141927 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141929         Speed up by a factor of 1.13.
141930         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
141931         for new_files, and the input to func_add_or_update.
141933 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
141935         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
141936         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
141938 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
141940         * modules/mkancesdirs (Depends-on): Add fcntl.
141941         * modules/savewd: New file.
141942         * MODULES.html.sh (File system functions): Add savewd.
141944         * modules/configmake (Makefile.am): Add support for the
141945         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
141947 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
141949         * m4/savewd.m4: New file.
141951 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
141953         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
141954         (dirchownmod): New arg FD.  All callers changed.
141955         Use FD rather than opening the directory ourself, as opening is
141956         now the caller's responsibility.
141957         * lib/dirchownmod.h: Likewise.
141958         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
141959         hosts that require <sys/types.h> before <sys/stat.h>.  Include
141960         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
141961         (test_dir): Remove.
141962         (mkancesdirs): Return length of prefix of FILE that has already
141963         been made, or -2 if there is a child doing the work.  Redo
141964         algorithm so that it is O(N) rather than O(N**2).  Optimize away
141965         ".", and treat ".." specially since it might stray back into
141966         already-created areas.  Use a subprocess if necessary.  New arg
141967         WD; all users changed.  MAKE_DIR function should now return 1
141968         if it creates a directory that is not readable.  Return -2 if
141969         a child process is spun off.
141970         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
141971         Adjust signature to match code.
141972         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
141973         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
141974         all users changed.
141975         * lib/savewd.c, lib/savewd.h: New files.
141977 2006-09-15  Jim Meyering  <jim@meyering.net>
141979         * modules/rename-dest-slash: New module.
141980         * MODULES.html.sh (posix_compat): Add it here.
141982         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
141984 2006-09-15  Jim Meyering  <jim@meyering.net>
141986         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
141987         file.
141989         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
141991 2006-09-15  Jim Meyering  <jim@meyering.net>
141993         * lib/rename-dest-slash.c (has_trailing_slash): Use
141994         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
141995         (rpl_rename_dest_slash): Perform the cheaper trailing slash
141996         test before testing whether SRC is a directory.
141997         Suggestions from Bruno Haible.
141999         Avoid a warning about an unused variable.
142000         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
142001         into the #ifdef block where it's used.
142003         * lib/rename-dest-slash.c: New file.
142005 2006-09-14  Bruno Haible  <bruno@clisp.org>
142007         * lib/allocsa.c: Include <config.h> unconditionally.
142008         * lib/asnprintf.c: Likewise.
142009         * lib/asprintf.c: Likewise.
142010         * lib/c-strcasecmp.c: Likewise.
142011         * lib/c-strcasestr.c: Likewise.
142012         * lib/c-strncasecmp.c: Likewise.
142013         * lib/c-strstr.c: Likewise.
142014         * lib/classpath.c: Likewise.
142015         * lib/clean-temp.c: Likewise.
142016         * lib/concatpath.c: Likewise.
142017         * lib/copy-file.c: Likewise.
142018         * lib/csharpcomp.c: Likewise.
142019         * lib/csharpexec.c: Likewise.
142020         * lib/execute.c: Likewise.
142021         * lib/fatal-signal.c: Likewise.
142022         * lib/findprog.c: Likewise.
142023         * lib/fwriteerror.c: Likewise.
142024         * lib/gl_array_list.c: Likewise.
142025         * lib/gl_array_oset.c: Likewise.
142026         * lib/gl_avltree_list.c: Likewise.
142027         * lib/gl_avltree_oset.c: Likewise.
142028         * lib/gl_avltreehash_list.c: Likewise.
142029         * lib/gl_carray_list.c: Likewise.
142030         * lib/gl_linked_list.c: Likewise.
142031         * lib/gl_linkedhash_list.c: Likewise.
142032         * lib/gl_list.c: Likewise.
142033         * lib/gl_oset.c: Likewise.
142034         * lib/gl_rbtree_list.c: Likewise.
142035         * lib/gl_rbtree_oset.c: Likewise.
142036         * lib/gl_rbtreehash_list.c: Likewise.
142037         * lib/imaxabs.c: Likewise.
142038         * lib/imaxdiv.c: Likewise.
142039         * lib/javacomp.c: Likewise.
142040         * lib/javaexec.c: Likewise.
142041         * lib/javaversion.c: Likewise.
142042         * lib/linebreak.c: Likewise.
142043         * lib/localcharset.c: Likewise.
142044         * lib/lock.c: Likewise.
142045         * lib/mbchar.c: Likewise.
142046         * lib/mbswidth.c: Likewise.
142047         * lib/mkdtemp.c: Likewise.
142048         * lib/pipe.c: Likewise.
142049         * lib/printf-args.c: Likewise.
142050         * lib/printf-parse.c: Likewise.
142051         * lib/progname.c: Likewise.
142052         * lib/progreloc.c: Likewise.
142053         * lib/readlink.c: Likewise.
142054         * lib/sh-quote.c: Likewise.
142055         * lib/stpcpy.c: Likewise.
142056         * lib/stpncpy.c: Likewise.
142057         * lib/strcasecmp.c: Likewise.
142058         * lib/strcasestr.c: Likewise.
142059         * lib/strcspn.c: Likewise.
142060         * lib/striconv.c: Likewise.
142061         * lib/strncasecmp.c: Likewise.
142062         * lib/strnlen1.c: Likewise.
142063         * lib/strstr.c: Likewise.
142064         * lib/strtok_r.c: Likewise.
142065         * lib/tls.c: Likewise.
142066         * lib/tmpdir.c: Likewise.
142067         * lib/unicodeio.c: Likewise.
142068         * lib/unsetenv.c: Likewise.
142069         * lib/vasnprintf.c: Likewise.
142070         * lib/vasprintf.c: Likewise.
142071         * lib/wait-process.c: Likewise.
142072         * lib/xallocsa.c: Likewise.
142073         * lib/xsetenv.c: Likewise.
142074         * lib/xstriconv.c: Likewise.
142076 2006-09-13  Simon Josefsson  <jas@extundo.com>
142078         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
142079         that internally, suggested by Ralf Wildenhues
142080         <Ralf.Wildenhues@gmx.de>.
142082 2006-09-13  Simon Josefsson  <jas@extundo.com>
142084         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
142085         @LIBOBJS@.
142086         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
142088 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
142090         * lib/_fpending.c: Include <config.h> unconditionally, since we no
142091         longer worry about uses that don't define HAVE_CONFIG_H.
142092         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
142093         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
142094         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
142095         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
142096         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
142097         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
142098         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
142099         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
142100         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
142101         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
142102         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
142103         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
142104         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
142105         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
142106         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
142107         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
142108         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
142109         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
142110         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
142111         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
142112         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
142113         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
142114         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
142115         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
142116         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
142117         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
142118         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
142119         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
142120         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
142121         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
142122         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
142123         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
142124         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
142125         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
142126         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
142127         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
142128         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
142129         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
142130         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
142131         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
142132         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
142133         Likewise.
142135 2006-09-13  Eric Blake  <ebb9@byu.net>
142137         * lib/getopt.c: Fix typo in last commit.
142139 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
142141         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
142142         dgettext.
142144 2006-09-12  Jim Meyering  <jim@meyering.net>
142146         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
142147         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
142148         Reported by Nelson H. F. Beebe.
142150 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
142152         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
142153         program_invocation_name and program_invocation_short_name are
142154         initialized.
142155         * lib/argp-namefrob.h: Move declarations of program_invocation_name
142156         and program_invocation_short_name to argp.h, so they are visible
142157         to user programs.
142158         * lib/argp.h: Likewise
142160 2006-09-10  Bruno Haible  <bruno@clisp.org>
142162         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
142163         m4/inttypes_h.m4, m4/uintmax_t.m4.
142165 2006-09-10  Bruno Haible  <bruno@clisp.org>
142167         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
142168         gl_AC_TYPE_UINTMAX_T.
142170 2006-09-10  Bruno Haible  <bruno@clisp.org>
142172         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
142174 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
142176         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
142177         convention.  Text proposed by Bruno Haible.
142178         (struct argp_option): Document the use of N_() wrappers.
142180         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
142181         '\v', and translate the two parts separately, instead of feeding
142182         the whole string to gettext.  This allows to exclude
142183         '\v' from the strings visible to the translator by writing doc
142184         strings as N_("..") "\v" N_("..").
142186 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
142188         * config/srclist.txt: Undo latest change; the bug was fixed.
142190 2006-09-09  Bruno Haible  <bruno@clisp.org>
142192         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
142193         assignments if building a library without libtool.
142194         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
142195         in func_emit_lib_Makefile_am.
142196         (func_import): When building a static library libfoo.a, arrange to
142197         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
142198         (func_create_testdir): Likewise.
142199         * modules/gc (configure.ac, Makefile.am): If building statically,
142200         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
142201         * modules/iconvme (configure.ac, Makefile.am): Likewise.
142202         * modules/striconv (configure.ac, Makefile.am): Likewise.
142203         Based on a suggestion by Ralf Wildenhues.
142205 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
142207         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
142208         Check for unistd.h too, since Autoconf doesn't assume POSIX.
142209         Also:
142211         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
142212         Add year_2050_test to catch glibc bug 2821
142213         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
142215         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
142216         Prefer #ifdef to #if.
142218         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
142219         Return from 'main' instead of calling 'exit'.
142221 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
142223         * lib/mktime.c (guess_time_tm): Fix bug where mktime
142224         returned the maximum time_t value rather than (time_t) -1.
142225         Problem originally reported by William Bardwell
142226         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
142228         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
142229         Moved to here ...
142230         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
142231         ... from here.
142233 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
142235         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
142236         2821 is fixed.
142238 2006-09-08  Jim Meyering  <jim@meyering.net>
142240         Don't make generated files read-only.  That would bother too many
142241         people.  However, do retain the ability to work when targets are
142242         read-only: remove the destination and temporary files before writing
142243         them (when generated via sed or echo), or by using the -f option for
142244         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
142245         * modules/alloca-opt, modules/argz, modules/arpa_inet:
142246         * modules/byteswap, modules/configmake, modules/fcntl:
142247         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
142248         * modules/localcharset, modules/netinet_in, modules/poll:
142249         * modules/stdbool, modules/stdint, modules/sys_select:
142250         * modules/sys_socket, modules/sys_stat, modules/sysexits:
142252 2006-09-08  Jim Meyering  <jim@meyering.net>
142254         Avoid new build failure on FreeBSD 6.0.
142255         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
142256         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
142257         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
142259 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
142261         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
142263 2006-09-07  Jim Meyering  <jim@meyering.net>
142265         Fix global typo in last change: use chmod u-w, not chmod u-x.
142266         Spotted by Paul Eggert and Bruce Korb.
142267         * modules/alloca-opt, modules/argz, modules/arpa_inet:
142268         * modules/byteswap, modules/configmake, modules/fcntl:
142269         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
142270         * modules/localcharset, modules/netinet_in, modules/poll:
142271         * modules/stdbool, modules/stdint, modules/sys_select:
142272         * modules/sys_socket, modules/sys_stat, modules/sysexits:
142274 2006-09-06  Jim Meyering  <jim@meyering.net>
142276         Make generated files be read-only.
142277         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
142278         Ensure that each generated file is now read-only.
142279         * modules/argz: Likewise.
142280         * modules/arpa_inet: Likewise.
142281         * modules/byteswap: Likewise.
142282         * modules/configmake: Likewise.
142283         * modules/fcntl: Likewise.
142284         * modules/fnmatch: Likewise.
142285         * modules/getopt: Likewise.
142286         * modules/glob: Likewise.
142287         * modules/inttypes: Likewise.
142288         * modules/netinet_in: Likewise.
142289         * modules/poll: Likewise.
142290         * modules/stdbool: Likewise.
142291         * modules/stdint: Likewise.
142292         * modules/sys_select: Likewise.
142293         * modules/sys_socket: Likewise.
142294         * modules/sys_stat: Likewise.
142295         * modules/sysexits: Likewise.
142296         * modules/localcharset: Same as above, but continue using temporary
142297         file named "t-$@" (why different?) rather than the "$@-t" used
142298         everywhere else.
142300         * modules/sysexits (Makefile.am): Replace literal occurrences
142301         of "sysexit.h" more readable, and more consistent, "$@".
142303 2006-09-06  Bruno Haible  <bruno@clisp.org>
142305         * modules/striconv: New file.
142306         * modules/xstriconv: New file.
142307         * MODULES.html.sh (Internationalization functions): Add striconv,
142308         xstriconv.
142310 2006-09-06  Bruno Haible  <bruno@clisp.org>
142312         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
142313         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
142314         not using libtool correctly.
142316 2006-09-06  Bruno Haible  <bruno@clisp.org>
142318         * lib/striconv.h: New file.
142319         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
142320         iconvstring.c.
142321         * lib/xstriconv.h: New file.
142322         * lib/xstriconv.c: New file.
142324 2006-09-06  Bruno Haible  <bruno@clisp.org>
142326         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
142327         lib_..._LDFLAGS.
142329 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
142331         * lib/argz_.h: Sync from Libtool.
142333         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
142334                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
142336         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
142338 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
142340         * modules/trim: New file.
142342 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
142344         * lib/trim.h: New file.
142345         * lib/trim.c: New file.
142347 2006-09-05  Bruno Haible  <bruno@clisp.org>
142349         * MODULES.html.sh (String handling): Add trim.
142351 2006-09-04  Karl Berry  <karl@gnu.org>
142353         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
142354         until next release.
142356 2006-09-03  Bruno Haible  <bruno@clisp.org>
142358         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
142359         correctly.
142361 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
142363         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
142364         not gl_GETLOADAVG.  Omit unneeded semicolons.
142365         Problems reported by Ralf Wildenhues in
142366         <http://lists.gnu.org/r/bug-gnulib/2006-09/msg00000.html>.
142367         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
142368         at the end, which is the usual gnulib style.
142370         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
142371         of doing all the work ourselves.
142372         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
142373         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
142375 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
142377         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
142378         Problem reported by Ralf Wildenhues in
142379         <http://lists.gnu.org/r/bug-gnulib/2006-09/msg00000.html>.
142381         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
142382         HAVE_STRUCT_STATFS_F_FSTYPENAME.
142384 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
142386         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
142387         yesterday's patch by changing test -n to test -z.
142389 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
142391         * modules/getloadavg (Files): Add m4/getloadavg.m4.
142392         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
142393         the former is now obsolescent.
142395         * modules/chdir-long (Depends-on): Add fcntl.
142397 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
142399         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
142400         obsolescent, and programs should use gnulib instead.
142401         * m4/getloadavg.m4: New file, with contents taken from Autoconf
142402         but with prefixes changed.
142404 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
142406         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
142407         or stdbool.h, because they might not exist while configuring.
142409         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
142410         Don't include unistd.h or limits.h; not needed, since chdir-long.h
142411         does that for us.
142412         (O_DIRECTORY): Remove.
142414 2006-08-31  Eric Blake  <ebb9@byu.net>
142416         * gnulib-tool: Don't let emacs change spaces to TAB.
142418 2006-08-31  Bruno Haible  <bruno@clisp.org>
142420         * gnulib-tool: When calling func_import more than once, do it in a
142421         subshell.
142422         Reported by Eric Blake <ebb9@byu.net>.
142424 2006-08-31  Bruno Haible  <bruno@clisp.org>
142426         * gnulib-tool (nl): Remove variable.
142427         (sed_transform_lib_file): Use more robust test for config-h module.
142428         (func_import): Fix typo in 2006-08-25 patch.
142430 2006-08-31  Bruno Haible  <bruno@clisp.org>
142432         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
142433         specified, augment Makefile.am variables instead of assigning them.
142435 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
142437         Work around a bug in both the Linux and SunOS 64-bit kernels:
142438         nanosleep mishandles sleeps for longer than 2**31 seconds.
142439         Problem reported by Frank v Waveren in
142440         <http://lists.gnu.org/r/bug-coreutils/2006-08/msg00298.html>.
142441         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
142442         Check for nanosleep bug.
142443         (LIB_NANOSLEEP): Append clock_gettime library if needed.
142445 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
142447         Work around a bug in both the Linux and SunOS 64-bit kernels:
142448         nanosleep mishandles sleeps for longer than 2**31 seconds.
142449         Problem reported by Frank v Waveren in
142450         <http://lists.gnu.org/r/bug-coreutils/2006-08/msg00298.html>.
142451         * lib/nanosleep.c (BILLION): New constant.
142452         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
142453         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
142454         implementation.
142456 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
142458         * modules/nanosleep (Depends-on): Add gettime.
142460 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
142461         and Simon Josefsson  <jas@extundo.com>
142462         and Oskar Liljeblad  <oskar@osk.mine.nu>
142464         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
142465         * gnulib-tool (func_import): New license type 'unmodifiable license
142466         text'.
142467         * modules/fdl: Use it.  Longer description.
142468         * module/gpl, module/lgpl: New files.
142470 2006-08-30  Jim Meyering  <jim@meyering.net>
142472         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
142473         shadowing the parameter.
142475 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
142477         Sync from Libtool:
142479         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
142481         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
142482         sharing with gnulib.  Report by Eric Blake.
142484 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
142486         * modules/isapipe: New file.
142487         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
142489 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
142491         * modules/configmake (Makefile.am): Add a comment, and omit
142492         the CONFIGMAKE_ prefix from generated macro names.  Suggested
142493         by Bruno Haible.
142495 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
142497         * m4/isapipe.m4: New file.
142499 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
142501         * lib/isapipe.c, lib/isapipe.h: New files.
142503 2006-08-29  Jim Meyering  <jim@meyering.net>
142505         * modules/configmake (Makefile.am): Make configmake.h depend on
142506         Makefile.  Otherwise, a stale configmake.h could hang around.
142508 2006-08-29  Eric Blake  <ebb9@byu.net>
142510         * lib/error.c (error_at_line, print_errno_message): Match libc, after
142511         resolution of upstream bug 3044.
142513 2006-08-29  Bruno Haible  <bruno@clisp.org>
142515         * modules/localcharset (Depends-on): Add configmake.
142516         (Makefile.am): Remove setting of LIBDIR through DEFS.
142518 2006-08-29  Bruno Haible  <bruno@clisp.org>
142520         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
142521         defined.
142523 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
142525         * modules/fcntl: New file.
142526         * modules/chdir-safer (Depends-on): Add fcntl.
142527         * modules/fts: Likewise.
142528         * modules/mkdir-p: Likewise.
142530         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
142531         This undoes the most recent change, since we're now addressing the
142532         problem in a different way.
142534         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
142535         into output, since the output might be called Makefile.am even
142536         if $makefile_name is something different.
142537         (func_import): Use $makefile_am rather than
142538         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
142539         empty.
142541         * modules/inttypes (Files): Add m4/inttypes-h.m4.
142543 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
142545         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
142546         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
142547         recent change to stdint.m4, since we're now addressing the problem in a
142548         different way.
142550 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
142552         * m4/fcntl_h.m4: New file.
142554 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
142556         * lib/fcntl_.h: New file.
142557         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
142558         the fcntl module.
142559         * lib/dirchownmod.c: Likewise.
142560         * lib/fts.c: Likewise.
142562         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
142563         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
142564         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
142565         just before including <inttypes.h>, to avoid circular inclusion.
142567 2006-08-28  Jim Meyering  <jim@meyering.net>
142569         * doc/visibility.texi: Actually read and correct the grammar of the
142570         sentence affected by yesterday's change.
142572 2006-08-28  Eric Blake  <ebb9@byu.net>
142574         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
142575         needs wrapper.
142577 2006-08-28  Eric Blake  <ebb9@byu.net>
142579         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
142581 2006-08-28  Eric Blake  <ebb9@byu.net>
142583         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
142585 2006-08-28  Bruno Haible  <bruno@clisp.org>
142587         * modules/c-strstr: New file, from GNU gettext.
142588         * MODULES.html.sh (String handling): Add c-strstr.
142590 2006-08-28  Bruno Haible  <bruno@clisp.org>
142592         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
142593         macros.
142594         Reported by Eric Blake.
142596 2006-08-28  Bruno Haible  <bruno@clisp.org>
142598         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
142599         (VASNPRINTF): Return a string of length > INT_MAX without failing.
142600         * lib/vasprintf.c: Include errno.h, limits.h.
142601         (EOVERFLOW): New fallback definition.
142602         (vasprintf): Test here whether the string length is > INT_MAX.
142603         * lib/vsnprintf.c: Include errno.h, limits.h.
142604         (EOVERFLOW): New fallback definition.
142605         (vsnprintf): Fix bug when generated string was too long for the buffer.
142606         Test here whether the string length is > INT_MAX.
142608 2006-08-28  Bruno Haible  <bruno@clisp.org>
142610         * lib/inttypes_.h (SCNX*): Remove definitions.
142611         Reported by Eric Blake.
142613 2006-08-28  Bruno Haible  <bruno@clisp.org>
142615         * lib/c-strstr.h: New file, from GNU gettext.
142616         * lib/c-strstr.c: New file, from GNU gettext.
142618 2006-08-28  Bruno Haible  <bruno@clisp.org>
142620         * gnulib-tool: Reorder some statements.
142622 2006-08-28  Bruno Haible  <bruno@clisp.org>
142624         * gnulib-tool: New option --makefile-name.
142625         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
142626         $makefile_name.
142627         (func_import): Write $makefile_name to the cache file, and read it from
142628         there unless explicitly specified. Use $makefile_name as file name
142629         instead of Makefile.am. Adjust the recommendations accordingly.
142631 2006-08-28  Bruno Haible  <bruno@clisp.org>
142633         * gnulib-tool (func_verify_module): Check against misapplying patch.
142635 2006-08-28  Bruno Haible  <bruno@clisp.org>
142637         * gnulib-tool (func_relativize, func_relconcat): New functions.
142638         Give an error if --local-dir is given with --update.
142639         Remove trailing slashes from $local_gnulib_dir.
142640         (func_import): Store the relativized $local_gnulib_dir in
142641         gnulib-cache.m4, and read it from there if not specified explicitly.
142643 2006-08-28  Bruno Haible  <bruno@clisp.org>
142645         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
142646         is the current directory. Respect also $local_gnulib_dir.
142648 2006-08-28  Bruno Haible  <bruno@clisp.org>
142649             Simon Josefsson  <jas@extundo.com>
142651         BeOS portability.
142652         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
142654 2006-08-27  Jim Meyering  <jim@meyering.net>
142656         * doc/visibility.texi: Remove duplicate word: "pointer".
142658 2006-08-26  Bruno Haible  <bruno@clisp.org>
142660         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
142661         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
142662         (Makefile.am): Create inttypes.h from inttypes_.h.
142663         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
142665         * modules/imaxabs: New file.
142667         * modules/imaxdiv: New file.
142669 2006-08-26  Bruno Haible  <bruno@clisp.org>
142671         * m4/inttypes.m4: New file.
142672         * m4/_inttypes_h.m4: Remove file.
142673         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
142674         PRI_MACROS_BROKEN.
142675         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
142677         * m4/imaxabs.m4: New file.
142679         * m4/imaxdiv.m4: New file.
142681 2006-08-26  Bruno Haible  <bruno@clisp.org>
142683         * lib/inttypes_.h: New file.
142684         * lib/inttypes.h: Remove file.
142685         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
142687         * lib/imaxabs.c: New file.
142689         * lib/imaxdiv.c: New file.
142691 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
142693         New config-h module, so that "make" output needn't be cluttered
142694         by -DHAVE_CONFIG_H.
142695         * MODULES.html.sh (Support for building libraries and executables):
142696         Add config-h.
142697         * modules/config-h: New file.
142698         * gnulib-tool (nl, sed_transform_lib_file): New vars.
142699         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
142700         the config-h module is used.
142702         New configmake module, so that "make" output needn't be cluttered
142703         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
142704         * MODULES.html.sh (Support for building libraries and executables):
142705         Add configmake.
142706         * modules/configmake: New file.
142708 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
142710         * m4/config-h.m4: New file.
142712 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
142714         * config/srclist.txt: Add elisp-comp.
142716 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
142718         * MODULES.html.sh (Support for building libraries and executables):
142719         Add elisp-comp.
142720         * build-aux/elisp-comp: New file.
142721         * modules/elisp-comp: New file.
142723 2006-08-24  Bruno Haible  <bruno@clisp.org>
142725         * gnulib-tool (func_create_testdir): Use non-default values of
142726         sourcebase and m4base.
142728 2006-08-24  Bruno Haible  <bruno@clisp.org>
142730         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
142731         HTML structure.
142733 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
142735         * modules/openat (Depends-on): Add lchown.
142737 2006-08-23  Bruno Haible  <bruno@clisp.org>
142739         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
142740         of gl_LOCK_EARLY instead of gl_LOCK.
142742 2006-08-23  Bruno Haible  <bruno@clisp.org>
142744         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
142745         on OSF/1 to no.
142746         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
142748 2006-08-23  Bruno Haible  <bruno@clisp.org>
142750         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
142751         as unusable.
142753         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
142754         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
142755         (gl_LOCK): New macro.
142757 2006-08-22  Simon Josefsson  <jas@extundo.com>
142759         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
142760         to md5 module.
142762 2006-08-22  Simon Josefsson  <jas@extundo.com>
142764         * MODULES.html.sh: Add "Support for maintaining and release
142765         projects".
142767         * build-aux/gnupload: New file, from coreutils.
142769 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
142771         Avoid the need for AC_LIBSOURCES in m4 macros.
142772         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
142773         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
142774         * modules/check-version (EXTRA_DIST): Add check-version.h.
142775         * modules/crc (EXTRA_DIST): Add crc.h.
142776         * modules/des (EXTRA_DIST): Add des.h.
142777         * modules/gc (EXTRA_DIST): Add gc.h.
142778         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
142779         * modules/getline (EXTRA_DIST): Add getline.h.
142780         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
142781         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
142782         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
142783         * modules/md2 (EXTRA_DIST): Add md2.h.
142784         * modules/md4 (EXTRA_DIST): Add md4.h.
142785         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
142786         * modules/read-file (EXTRA_DIST): Add read-file.h.
142787         * modules/readline (EXTRA_DIST): Add readline.h.
142788         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
142789         rijndael-api-fst.h.
142791 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
142793         * m4/rijndael.m4 (gl_ARCFOUR):
142794         * m4/arctwo.m4 (gl_ARCTWO):
142795         * m4/check-version.m4 (gl_CHECK_VERSION):
142796         * m4/crc.m4 (gl_CRC):
142797         * m4/des.m4 (gl_DES):
142798         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
142799         * m4/gc.m4 (gl_GC):
142800         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
142801         * m4/getline.m4 (gl_FUNC_GETLINE):
142802         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
142803         * m4/hmac-md5.m4 (gl_HMAC_MD5):
142804         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
142805         * m4/md2.m4 (gl_MD2):
142806         * m4/md4.m4 (gl_MD4):
142807         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
142808         * m4/read-file.m4 (gl_FUNC_READ_FILE):
142809         * m4/readline.m4 (gl_FUNC_READLINE):
142810         * m4/rijndael.m4 (gl_RIJNDAEL):
142811         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
142812         to get the necessary .h files and whatnot.
142814 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
142816         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
142817         gnulib rather than the other way around.
142818         * config/srclistvars.sh (COREUTILS): Remove.
142820 2006-08-22  Jim Meyering  <jim@meyering.net>
142822         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
142824         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
142826 2006-08-22  Eric Blake  <ebb9@byu.net>
142828         * modules/regexprops-generic: New file.
142829         * MODULES.html.sh (Support for building documentation): List it.
142831 2006-08-22  Eric Blake  <ebb9@byu.net>
142833         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
142834         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
142835         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
142836         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
142838 2006-08-22  Bruno Haible  <bruno@clisp.org>
142840         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
142841         and lib_LTLIBRARIES like the other lib_* variables.
142843 2006-08-22  Bruno Haible  <bruno@clisp.org>
142845         * build-aux/x-to-1.in: New file, from GNU gettext.
142847 2006-08-22  Bruno Haible  <bruno@clisp.org>
142849         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
142850         <utmpx.h> exists.
142852 2006-08-22  Bruno Haible  <bruno@clisp.org>
142854         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
142855         <utmpx.h> exists.
142857 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
142859         BeOS portability.
142860         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
142861         exist.
142862         Problem reported by Bruno Haible.
142864 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
142866         Avoid the need for AC_LIBSOURCES in m4 macros.
142867         * modules/acl (EXTRA_DIST): Add acl.h.
142868         * modules/argmatch (Files): Add m4/argmatch.m4.
142869         (configure.ac): Add gl_ARGMATCH.
142870         (EXTRA_DIST): Renamed from lib_SOURCES, for
142871         consistency with the other modules.  Remove argmatch.c.
142872         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
142873         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
142874         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
142875         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
142876         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
142877         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
142878         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
142879         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
142880         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
142881         * modules/closeout (EXTRA_DIST): Add closeout.h.
142882         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
142883         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
142884         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
142885         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
142886         dirname.h; remove basename.c and stripslash.c.
142887         * modules/exclude (EXTRA_DIST): Add exclude.h.
142888         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
142889         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
142890         * modules/file-type (EXTRA_DIST): Add file-type.h.
142891         * modules/filemode (EXTRA_DIST): Add filemode.h.
142892         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
142893         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
142894         * modules/fpending (EXTRA_DIST): Add __fpending.h.
142895         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
142896         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
142897         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
142898         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
142899         * modules/getdate (EXTRA_DIST): Add getdate.c.
142900         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
142901         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
142902         * modules/getpass (EXTRA_DIST): Add getpass.h.
142903         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
142904         * modules/group-member (EXTRA_DIST): Add group-member.h.
142905         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
142906         * modules/hash (EXTRA_DIST): Add hash.h.
142907         * modules/human (EXTRA_DIST): Add human.h.
142908         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
142909         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
142910         * modules/lchown (EXTRA_DIST): Add lchown.h.
142911         * modules/long-options (EXTRA_DIST): Add long-options.h.
142912         * modules/lstat (EXTRA_DIST): Add lstat.h.
142913         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
142914         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
142915         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
142916         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
142917         * modules/memxor (EXTRA_DIST): Add memxor.h.
142918         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
142919         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
142920         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
142921         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
142922         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
142923         * modules/physmem (EXTRA_DIST): Add physmem.h.
142924         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
142925         * modules/posixver (EXTRA_DIST): Add posixver.h.
142926         * modules/quote (EXTRA_DIST): Add quote.h.
142927         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
142928         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
142929         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
142930         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
142931         regex_internal.h regexec.c.
142932         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
142933         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
142934         * modules/same (EXTRA_DIST): Add same.h.
142935         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
142936         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
142937         * modules/savedir (EXTRA_DIST): Add savedir.h.
142938         * modules/sha1 (EXTRA_DIST): Add sha1.h.
142939         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
142940         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
142941         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
142942         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
142943         * modules/strdup (EXTRA_DIST): Add strdup.h.
142944         * modules/strftime (EXTRA_DIST): Add strftime.h.
142945         * modules/strndup (EXTRA_DIST): Add strndup.h.
142946         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
142947         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
142948         * modules/time_r (EXTRA_DIST): Add time_r.h.
142949         * modules/timespec (EXTRA_DIST): Add timespec.h.
142950         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
142951         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
142952         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
142953         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
142954         * modules/userspec (EXTRA_DIST): Add userspec.h.
142955         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
142956         * modules/utimens (EXTRA_DIST): Add utimens.h.
142957         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
142958         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
142959         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
142960         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
142961         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
142962         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
142963         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
142964         * modules/yesno (EXTRA_DIST): Add yesno.h.
142966 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
142968         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
142970         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
142971         * m4/dev-ino.m4, same-inode.m4: Remove.
142973         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
142974         * m4/acl.m4 (AC_FUNC_ACL):
142975         * m4/backupfile.m4 (gl_BACKUPFILE):
142976         * m4/c-strtod.m4 (gl_C99_STRTOLD):
142977         * m4/canon-host.m4 (gl_CANON_HOST):
142978         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
142979         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
142980         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
142981         * m4/cloexec.m4 (gl_CLOEXEC):
142982         * m4/close-stream.m4 (gl_CLOSE_STREAM):
142983         * m4/closeout.m4 (gl_CLOSEOUT):
142984         * m4/dirfd.m4 (gl_FUNC_DIRFD):
142985         * m4/dirname.m4 (gl_DIRNAME):
142986         * m4/exclude.m4 (gl_EXCLUDE):
142987         * m4/exitfail.m4 (gl_EXITFAIL):
142988         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
142989         * m4/file-type.m4 (gl_FILE_TYPE):
142990         * m4/filemode.m4 (gl_FILEMODE):
142991         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
142992         * m4/fpending.m4 (gl_FUNC_FPENDING):
142993         * m4/fprintftime.m4 (gl_FPRINTFTIME):
142994         * m4/fts.m4 (gl_FUNC_FTS):
142995         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
142996         * m4/getdate.m4 (gl_GETDATE):
142997         * m4/gethrxtime.m4 (gl_GETHRXTIME):
142998         * m4/getpagesize.m4 (gl_GETPAGESIZE):
142999         * m4/getpass.m4 (gl_FUNC_GETPASS):
143000         * m4/gettime.m4 (gl_GETTIME):
143001         * m4/getugroups.m4 (gl_GETUGROUPS):
143002         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
143003         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
143004         * m4/hard-locale.m4 (gl_HARD_LOCALE):
143005         * m4/hash.m4 (gl_HASH):
143006         * m4/idcache.m4 (gl_IDCACHE):
143007         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
143008         * m4/lchown.m4 (gl_FUNC_LCHOWN):
143009         * m4/long-options.m4 (gl_LONG_OPTIONS):
143010         * m4/lstat.m4 (gl_FUNC_LSTAT):
143011         * m4/md5.m4 (gl_MD5):
143012         * m4/memcasecmp.m4 (gl_MEMCASECMP):
143013         * m4/memcoll.m4 (gl_MEMCOLL):
143014         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
143015         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
143016         * m4/memxor.m4 (gl_MEMXOR):
143017         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
143018         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
143019         * m4/modechange.m4 (gl_MODECHANGE):
143020         * m4/mountlist.m4 (gl_MOUNTLIST):
143021         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
143022         * m4/openat.m4 (gl_FUNC_OPENAT):
143023         * m4/pathmax.m4 (gl_PATHMAX):
143024         * m4/physmem.m4 (gl_PHYSMEM):
143025         * m4/posixtm.m4 (gl_POSIXTM):
143026         * m4/posixver.m4 (gl_POSIXVER):
143027         * m4/quote.m4 (gl_QUOTE):
143028         * m4/quotearg.m4 (gl_QUOTEARG):
143029         * m4/readtokens.m4 (gl_READTOKENS):
143030         * m4/readutmp.m4 (gl_READUTMP):
143031         * m4/regex.m4 (gl_REGEX):
143032         * m4/safe-read.m4 (gl_SAFE_READ):
143033         * m4/safe-write.m4 (gl_SAFE_WRITE):
143034         * m4/same.m4 (gl_SAME):
143035         * m4/save-cwd.m4 (gl_SAVE_CWD):
143036         * m4/savedir.m4 (gl_SAVEDIR):
143037         * m4/settime.m4 (gl_SETTIME):
143038         * m4/sha1.m4 (gl_SHA1):
143039         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
143040         * m4/stat-macros.m4 (gl_STAT_MACROS):
143041         * m4/stat-time.m4 (gl_STAT_TIME):
143042         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
143043         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
143044         * m4/strdup.m4 (gl_FUNC_STRDUP):
143045         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
143046         * m4/strndup.m4 (gl_FUNC_STRNDUP):
143047         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
143048         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
143049         * m4/time_r.m4 (gl_TIME_R):
143050         * m4/timespec.m4 (gl_TIMESPEC):
143051         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
143052         * m4/unlinkdir.m4 (gl_UNLINKDIR):
143053         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
143054         * m4/userspec.m4 (gl_USERSPEC):
143055         * m4/utimecmp.m4 (gl_UTIMECMP):
143056         * m4/utimens.m4 (gl_UTIMENS):
143057         * m4/xalloc.m4 (gl_XALLOC):
143058         * m4/xgetcwd.m4 (gl_XGETCWD):
143059         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
143060         * m4/xreadlink.m4 (gl_XREADLINK):
143061         * m4/xstrtod.m4 (gl_XSTRTOD):
143062         * m4/yesno.m4 (gl_YESNO):
143063         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
143064         to get the necessary .h files and whatnot.
143066 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
143067             Bruno Haible  <bruno@clisp.org>
143069         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
143070         /bin/sh understanding of '!' conditional negation.
143072 2006-08-21  Jim Meyering  <jim@meyering.net>
143074         * modules/openat (Depends-on): Really alphabetize.
143076         * modules/acl (Depends-on): Add error and quote.
143078         * check-module (find_included_lib_files): Add at-func.c to the
143079         ok-to-include-more-than-once white list.
143081         * modules/openat (Depends-on): Add lstat.  Alphabetize.
143083 2006-08-21  Bruno Haible  <bruno@clisp.org>
143085         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
143086         Emit a pkgdata_DATA variable only if some snippets add contents to it.
143087         Reported by Martin Lambers <marlam@marlam.de>.
143089 2006-08-21  Bruno Haible  <bruno@clisp.org>
143091         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
143092         specify an installation location, don't emit a noinst_LIBRARIES or
143093         noinst_LTLIBRARIES assignment.
143095 2006-08-21  Bruno Haible  <bruno@clisp.org>
143097         BeOS portability.
143098         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
143099         BeOS has mbrtowc() but no <wctype.h>.
143101 2006-08-21  Bruno Haible  <bruno@clisp.org>
143103         BeOS portability.
143104         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
143105         exist.
143107 2006-08-21  Bruno Haible  <bruno@clisp.org>
143109         BeOS portability.
143110         * lib/mbchar.h: Include <wctype.h> only if it exists.
143112 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
143114         Remove files that are no longer needed by their respective modules.
143115         * m4/obstack.m4: Remove.
143116         * m4/strerror_r.m4: Remove.
143117         * m4/uint32_t.m4: Remove.
143118         * m4/uintptr_t.m4: Remove.
143119         * m4/ullong_max.m4: Remove.
143120         * m4/xstrtoimax.m4: Remove.
143121         * m4/xstrtoumax.m4: Remove.
143123         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
143124         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
143125         dependencies now capture this.
143127         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
143128         Do not use AC_LIBSOURCES, since gnulib modules now do this.
143129         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
143130         * m4/human.m4 (gl_HUMAN): Likewise.
143131         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
143132         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
143134         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
143136         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
143137         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
143138         stdint.
143139         * m4/human.m4 (gl_HUMAN): Likewise.
143140         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
143141         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
143142         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
143143         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
143144         * m4/xstrtol (gl_XSTRTOL): Likewise.
143146         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
143147         AC_TYPE_LONG_LONG_INT.
143148         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
143149         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
143150         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
143151         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
143153         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
143154         on stdbool.
143156         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
143157         (gl_PREREQ_XSTRTOUL): Remove.
143159         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
143161         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
143162         mode.
143164 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
143166         Add and change modules to make it easier for coreutils to use
143167         gnulib-tool.
143168         * modules/backupfile (Files): Remove m4/d-ino.m4.
143169         (Depends-on): Add d-ino.
143170         * modules/cycle-check (Depends-on): Add stdint.
143171         (lib_SOURCES): Add cycle-check.h.
143172         * modules/d-ino: New module.
143173         * modules/d-type: New module.
143174         * modules/error (Files): Remove m4/strerror_r.m4.
143175         * modules/filemode (Files): Add m4/st_dm_mode.m4.
143176         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
143177         m4/inttypes_h.m4, m4/uintmax_t.m4.
143178         (Depends-on): Add stdint.
143179         (lib_SOURCES): Add fsusage.h.
143180         * modules/getcwd (Files): Remove d-ino.m4.
143181         (Depends-on): Add d-ino.
143182         * modules/getndelim2 (Depends-on): Add stdint.
143183         * modules/glob (Files): Remove m4/d-type.m4.
143184         (Depends-on): Add d-type.
143185         * modules/host-os: New module.
143186         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
143187         m4/inttypes_h.m4, m4/uintmax_t.m4.
143188         * Depends-on: Add stdint.
143189         (lib_SOURCES): Add human.h.
143190         * modules/inttostr (Files): Remove m4/intmax_t.m4,
143191         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
143192         m4/uintmax_t.m4, m4/ulonglong.m4.
143193         (Depends-on): Add stdint.
143194         (EXTRA_DIST): Add inttostr.h.
143195         * modules/lchmod: New module.
143196         * modules/link-follow: New module.
143197         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
143198         (Depends-on): Add lchmod.
143199         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
143200         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
143201         (Depends-on): Add stdint.
143202         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
143203         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
143204         (Depends-on): Add stdint.
143205         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
143206         * modules/perl: New module.
143207         * modules/regex (Depends-on): Add stdint.
143208         * modules/rmdir-errno: New module.
143209         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
143210         m4/intmax_t.m4.
143211         (Depends-on): Add stdint.
143212         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
143213         m4/uintmax_t.m4.
143214         (Depends-on): Add stdint.
143215         * modules/unlink-busy: New module.
143216         * modules/utimecmp (Depends-on): Add stdint.
143217         * modules/uptime: New module.
143218         * modules/winsz-ioctl: New module.
143219         * modules/winsz-termios: New module.
143220         * modules/xnanosleep (Depends-on): Add nanosleep.
143221         * modules/ullong_max: Remove.
143222         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
143223         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
143224         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
143225         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
143226         (Depends-on): Add inttypes.
143227         (lib_SOURCES): Add xstrtol.h.
143228         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
143229         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
143230         * MODULES.html.sh: Move 'assert' into the assert section.
143231         Move 'dummy' into the linking section.
143232         Remove ullong_max.
143233         Add section for compatibility checks for POSIX:2001 functions,
143234         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
143235         winsz-ioctl, and winsz-termios into it.
143236         Add lchmod.
143237         Add top-level Misc section and put host-os, perl, and uptime
143238         into it.
143240 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
143242         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
143243         now assume the stdint module.  Do not include inttypes.h.
143244         * lib/fsusage.h: Likewise.
143245         * lib/getndelim2.c: Likewise.
143246         * lib/human.h: Likewise.
143247         * lib/inttostr.h: Likewise.
143248         * lib/obstack.c: Likewise.
143249         * lib/regex_internal.h: Likewise.
143250         * lib/tempname.c: Likewise.
143251         * lib/utimecmp.c: Likewise.
143252         * lib/xstrtol.h: Likewise.
143254         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
143256         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
143257         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
143258         * lib/xtime.h: Likewise.
143260 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
143262         * modules/openat (Files): Add lib/fchmodat.c.
143263         Fixes problem reported by Jay Youngman.
143265 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
143267         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
143268         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
143270 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
143271             Bruno Haible  <bruno@clisp.org>
143273         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
143274         and is a script that invokes bison. Tighten the code. Add comments.
143276 2006-08-18  Jim Meyering  <jim@meyering.net>
143278         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
143279         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
143280         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
143281         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
143283 2006-08-18  Bruno Haible  <bruno@clisp.org>
143285         * modules/bison-i18n: New file.
143286         * MODULES.html.sh (Internationalization functions): Add it.
143288 2006-08-18  Bruno Haible  <bruno@clisp.org>
143290         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
143291         sys/statvfs.h. When getmntinfo was found, check its declaration and
143292         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
143294 2006-08-18  Bruno Haible  <bruno@clisp.org>
143296         * m4/bison-i18n.m4: New file, from bison.
143298 2006-08-18  Bruno Haible  <bruno@clisp.org>
143300         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
143301         (ME_DUMMY): Treat "kernfs" as a dummy.
143302         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
143304 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
143306         Update from coreutils.
143308         2006-08-15  Jim Meyering  <jim@meyering.net>
143310         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
143312         2006-01-17  Jim Meyering  <jim@meyering.net>
143314         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
143316         2006-01-11  Jim Meyering  <jim@meyering.net>
143318         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
143319         Check for the lchmod function.
143321 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
143323         Update from coreutils.
143325         * lib/__fpending.h: Add copyright notice.
143326         * lib/fprintftime.h: Likewise.
143327         * lib/savedir.c: Use (C) in copyright notice.
143328         * lib/savedir.h: Likewise.
143330         2006-08-15  Jim Meyering  <jim@meyering.net>
143332         * lib/at-func.c: New file, with the logic of all emulated at-functions.
143333         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
143334         in support of the EXPECTED_ERRNO macro.
143335         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
143336         definitions.  Instead, define the appropriate symbols and include
143337         "at-func.c".
143338         * lib/mkdirat.c (mkdirat): Likewise.
143339         * lib/fchmodat.c (fchmodat): Likewise.
143340         (ENOSYS): Remove definition.
143341         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
143342         it.  Don't include "unistd--.h" -- it wasn't ever used.
143344         2006-01-17  Jim Meyering  <jim@meyering.net>
143346         Rewrite fts.c not to change the current working directory,
143347         by using openat, fstatat, fdopendir, etc..
143349         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
143350         (HAVE_OPENAT_SUPPORT): Define.
143351         [_LIBC] (fchdir): Don't undef or define; no longer used.
143352         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
143353         Now, this `function' always succeeds, and consumes its file descriptor
143354         parameter -- so callers must not close such FDs.  Update callers.
143355         (diropen_fd, opendirat, cwd_advance_fd): New functions.
143356         (diropen): Add parameter, SP.  Adjust all callers.
143357         Implement using diropen_fd, rather than open.
143358         (fts_open): Initialize new member, fts_cwd_fd.
143359         Remove fts_rft-setting code.
143360         (fts_close): Close fts_cwd_fd, if necessary.
143361         (__opendir2): Define in terms of opendir or opendirat,
143362         depending on whether the FST_NOCHDIR flag is set.
143363         (fts_build): Since fts_safe_changedir consumes its FD, and since
143364         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
143365         and close the dup'd file descriptor upon failure.
143366         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
143367         (fts_safe_changedir): Tweak semantics to reflect that this function
143368         now calls cwd_advance_fd and hence consumes its FD argument.
143369         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
143370         [struct FTS] (fts_rft): Remove now-unused member.
143371         [struct FTS] (fts_cycle.state): Improve comment.
143373         * lib/openat.c (openat_needs_fchdir): New function.
143374         * lib/openat.h (openat_needs_fchdir): Declare it.
143376 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
143378         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
143379         Problem and fix reported by Pádraig Brady in
143380         <http://lists.gnu.org/r/bug-coreutils/2006-08/msg00099.html>.
143382 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
143384         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
143386 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
143388         * lib/memcoll.c (memcoll): Optimize for the common case where the
143389         arguments are bytewise equal.
143391 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
143393         * doc/regexprops-generic.texi: Add a copyright notice.
143395 2006-08-15  Bruno Haible  <bruno@clisp.org>
143397         * modules/tmpdir (License): Change to LGPL.
143399 2006-08-15  Bruno Haible  <bruno@clisp.org>
143401         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
143402         module.
143404 2006-08-14  Simon Josefsson  <jas@extundo.com>
143406         * config/srclist.txt: Add gnupload.
143408 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
143410         Change copyright notice from LGPL 2 to GPL 2, since that's the
143411         standard form used in the gnulib repository.
143412         * tests/test-lock.c: Likewise.
143413         * tests/test-stdint.c: Likewise.
143414         * tests/test-tls.c: Likewise.
143416         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
143417         prelude-manager.  User shorter URLs for GNU projects, without '?'.
143418         Add copyright notice.
143420         * check-module: Add copyright notice.  Output a copyright
143421         notice if "--version" is specified.
143422         * modules/COPYING: New file.
143423         * tests/test-getaddrinfo.c: Add copyright notice.
143424         * tests/test-verify.c: Likewise.
143426 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
143428         Change copyright notice from LGPL 2 to GPL 2, since that's the
143429         standard form used in the gnulib repository.
143430         * lib/lock.c: LGPL -> GPL.
143431         * lib/lock.h: Likewise.
143432         * lib/strnlen1.c: Likewise.
143433         * lib/strnlen1.h: Likewise.
143434         * lib/tls.c: Likewise.
143435         * lib/tls.h: Likewise.
143436         * lib/tmpdir.c: Likewise.
143438         * lib/TODO: Remove; this belongs only in coreutils.
143440 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
143442         Add copyright notices to long-enough files that lack them, since
143443         otherwise the files aren't clearly free.  Use the same notice that
143444         getdate.texi already uses.
143445         * doc/alloca-opt.texi: Add copyright notice.
143446         * doc/alloca.texi: Likewise.
143447         * doc/ctime.texi: Likewise.
143448         * doc/functions.texi: Likewise.
143449         * doc/gcd.texi: Likewise.
143450         * doc/gnulib-tool.texi: Likewise.
143451         * doc/inet_ntoa.texi: Likewise.
143452         * doc/visibility.texi: Likewise.
143454         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
143455         * doc/quote.texi: Add copyright notice.
143457         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
143458         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
143459         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
143460         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
143461         is now obsolete, and give a pointer to the Sun list.
143462         Add copyright notice.
143464 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
143466         * config/srclistvars.sh: Add copyright notice.
143468 2006-08-14  Eric Blake  <ebb9@byu.net>
143470         Import the following change from libc:
143472         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
143474         Upstream bug 2997.
143475         * lib/misc/error.c: Add space between program name and message if file
143476         name is missing.
143478 2006-08-12  Karl Berry  <karl@gnu.org>
143480         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
143481         remove, these originate in gnulib now.
143483 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143485         * doc/Makefile (standards.info standards.html standards.dvi):
143486         Also depend on make-stds.texi.
143488 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
143490         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
143491         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
143493         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
143494         in wchar_t.  Problem reported by Eric Blake.
143496         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
143497         LEN is smaller than SIZE.  Suggested by Bruno Haible.
143498         Also, help the compiler to keep LEN in a register.
143500 2006-08-11  Eric Blake  <ebb9@byu.net>
143502         * users.txt: Sort.  Add tar.
143504 2006-08-11  Bruno Haible  <bruno@clisp.org>
143506         * users.txt: New file.
143508 2006-08-11  Bruno Haible  <bruno@clisp.org>
143510         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
143511         before <wchar.h>. Needed for OSF/1 and BSD/OS.
143513 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
143515         * modules/snprintf (Depends-on): Remove minmax.
143516         (Maintainer): Add self and Bruno.
143518 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
143520         * lib/.cppi-disable: Add snprintf.h, socket_.h.
143521         * lib/snprintf.c: Include <errno.h> and <limits.h>.
143522         (EOVERFLOW): Define if the system does not.
143523         Do not include "minmax.h"; it wasn't used.
143524         (snprintf): Don't assume size_t promotes to an unsigned type.
143525         Fix bug when generated string was too long for the buffer: the
143526         buffer's contents are supposed to be the initial prefix of the
143527         output.  Don't assume vasnprintf returns EOVERFLOW if the size
143528         exceeds INT_MAX; do the check ourselves.
143530         Import the following changes from libc:
143532         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
143534         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
143535         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
143536         set wc to the byte which couldn't be converted.
143537         (re_string_reconstruct): Don't clear valid_raw_len before calling
143538         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
143539         tip_context using re_string_context_at.
143541         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
143543         * lib/posix/regex.h: g++ still cannot handled [restrict].
143545         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
143547         * lib/posix/regex.h: Remove special handling for VMS.
143549 2006-08-10  Jim Meyering  <jim@meyering.net>
143551         * modules/same-inode: New module.
143552         * modules/dev-ino: New module.
143553         * modules/cycle-check: Depend on these modules, rather than simply
143554         including their .h files.
143555         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
143556         required via m4/cycle-check.m4.
143557         * modules/same: Depend on new same-inode module, rather than
143558         including same-inode.h.
143559         * modules/chdir-safer: New file.
143561         * modules/chown (Depends-on): Add stat-macros.
143563 2006-08-10  Jim Meyering  <jim@meyering.net>
143565         * m4/cycle-check.m4: New file.
143566         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
143567         * m4/dev-ino.m4, m4/same-inode.m4: New files.
143569 2006-08-10  Eric Blake  <ebb9@byu.net>
143571         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
143572         in from original proposal.
143574 2006-08-10  Eric Blake  <ebb9@byu.net>
143575         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
143577         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
143578         namespace.
143580 2006-08-10  Bruno Haible  <bruno@clisp.org>
143582         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
143583         as well.
143585 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
143587         Sync from coreutils.
143589         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
143591         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
143592         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
143594 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
143596         * modules/restrict: Remove; no longer needed now that we assume
143597         Autoconf 2.59 or later.
143598         * MODULES.html.sh: Remove 'restrict'.
143599         * modules/argp (Depends-on): Remove 'restrict'.
143600         * modules/base64 (Depends-on): Likewise.
143601         * modules/gc (Depends-on): Likewise.
143602         * modules/getaddrinfo (Depends-on): Likewise.
143603         * modules/glob (Depends-on): Likewise.
143604         * modules/inet_ntop (Depends-on): Likewise.
143605         * modules/inet_pton (Depends-on): Likewise.
143606         * modules/memxor (Depends-on): Likewise.
143607         * modules/regex (Depends-on): Likewise.
143608         * modules/strtok_r (Depends-on): Likewise.
143609         * modules/time_r (Depends-on): Likewise.
143611 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
143613         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
143614         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
143615         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
143616         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
143617         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
143618         * m4/memxor.m4 (gl_MEMXOR): Likewise.
143619         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
143620         gl_C_RESTRICT replaced by AC_C_RESTRICT.
143622         Merge from coreutils.
143623         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
143624         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
143625         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
143626         * m4/time_r.m4 (gl_TIME_R): Likewise.
143628 2006-08-09  Karl Berry  <karl@gnu.org>
143630         * config/srclist.txt: no more gettext-tools, per Bruno.
143632 2006-08-08  Eric Blake  <ebb9@byu.net>
143634         * modules/verror: New module.
143635         * MODULES.html.sh: Document it.
143637 2006-08-08  Eric Blake  <ebb9@byu.net>
143639         * lib/verror.h, lib/verror.c: New files.
143641 2006-08-08  Eric Blake  <ebb9@byu.net>
143643         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
143644         verror_at_line output complies with GNU Coding Standards even when
143645         file is NULL.
143647 2006-08-07  Bruno Haible  <bruno@clisp.org>
143649         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
143650         versions of AIX.
143651         Reported by Ralf Wildenhues.
143653 2006-08-07  Bruno Haible  <bruno@clisp.org>
143655         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
143656         in an AC_DEFUN. Needed so that the autoconf snippets can use
143657         AC_REQUIRE.
143659 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
143661         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
143662         Initialize pkgdata_DATA.
143663         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
143664         overriding it.
143666 2006-08-06  Eric Blake  <ebb9@byu.net>
143668         * lib/error.h: Fold in some upstream changes from glibc.
143669         * lib/error.c: Likewise.
143671 2006-08-04  Bruno Haible  <bruno@clisp.org>
143673         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
143674         Make the mostlyclean-local rule depend on mostlyclean-generic.
143675         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
143677 2006-07-31  Bruno Haible  <bruno@clisp.org>
143679         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
143680         <stdlib.h>, <string.h>.
143682 2006-07-30  Bruno Haible  <bruno@clisp.org>
143684         * modules/readlink (License): Change to LGPL.
143686 2006-07-30  Bruno Haible  <bruno@clisp.org>
143688         * modules/javaversion (Makefile.am): Distribute javaversion.java and
143689         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
143690         set PKGDATADIR to point to it.
143692 2006-07-30  Bruno Haible  <bruno@clisp.org>
143694         * modules/csharpexec (configure.ac): Comment out macro invocation.
143695         * modules/javaexec (configure.ac): Likewise.
143696         * modules/javacomp-script (configure.ac): Likewise.
143698         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
143700 2006-07-30  Bruno Haible  <bruno@clisp.org>
143702         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
143703         linked-list.
143705 2006-07-30  Bruno Haible  <bruno@clisp.org>
143707         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
143709 2006-07-30  Bruno Haible  <bruno@clisp.org>
143711         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
143712         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
143713         get removed.
143715 2006-07-29  Bruno Haible  <bruno@clisp.org>
143717         Make it possible for gnulib-tool to work with locally modified or
143718         augmented gnulib repositories.
143719         * gnulib-tool (func_usage): Document --local-dir option.
143720         (local_gnulib_dir): New variable.
143721         Handle --local-dir option.
143722         (func_lookup_file): New function.
143723         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
143724         (func_get_description, func_get_filelist, func_get_description,
143725         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
143726         func_get_automake_snippet, func_get_include_directive,
143727         func_get_license, func_get_maintainer): Use func_lookup_file.
143728         (func_import, func_create_testdir): Use func_lookup_file.
143730 2006-07-29  Bruno Haible  <bruno@clisp.org>
143732         * modules/setenv (Depends-on): Add unistd.
143734 2006-07-29  Bruno Haible  <bruno@clisp.org>
143736         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
143738 2006-07-29  Bruno Haible  <bruno@clisp.org>
143740         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
143742 2006-07-29  Bruno Haible  <bruno@clisp.org>
143744         * gnulib-tool (import, update): If there is no Makefile.am, look at
143745         aclocal.m4, instead of bailing out.
143747 2006-07-29  Bruno Haible  <bruno@clisp.org>
143749         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
143750         Categorize the options by when they are useful.
143752 2006-07-29  Bruno Haible  <bruno@clisp.org>
143754         * gnulib-tool (func_usage): Document option --no-libtool.
143755         Handle option --no-libtool.
143756         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
143757         for changed semantics of $libtool variable.
143758         (func_import): Likewise. If libtool is not used, show this through
143759         an option --no-libtool.
143760         (func_create_testdir): Update.
143762 2006-07-29  Bruno Haible  <bruno@clisp.org>
143764         * gnulib-tool (func_import): Extend error message about missing
143765         --doc-base.
143767 2006-07-29  Bruno Haible  <bruno@clisp.org>
143769         * gnulib-tool (func_import): Don't create the $docbase directory if
143770         there is no file to store there.
143772 2006-07-29  Bruno Haible  <bruno@clisp.org>
143774         * gnulib-tool (autoconf_minversion): If a --dir option is given and
143775         relevant, look for configure.ac there, not in the current directory.
143776         Also use a simple search for AC_PREREQ, not "autoconf --trace".
143778 2006-07-29  Bruno Haible  <bruno@clisp.org>
143780         * gnulib-tool (SORT): New variable.
143781         (func_usage): Undocument --assume-autoconf option.
143782         Remove --assume-autoconf option handling.
143783         (autoconf_minversion): Determine from the contents of configure.ac.
143784         (func_import): Remove autoconf_minversion handling.
143785         Suggested by Eric Blake.
143787 2006-07-29  Bruno Haible  <bruno@clisp.org>
143789         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
143791 2006-07-29  Bruno Haible  <bruno@clisp.org>
143793         * config/srclist.txt (*setenv.[ch]): Remove rules.
143795 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
143797         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
143799 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
143801         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
143802         arpa/inet.h.
143804 2006-07-28  Simon Josefsson  <jas@extundo.com>
143806         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
143807         * modules/inet_pton (Depends-on): Likewise.
143809 2006-07-28  Simon Josefsson  <jas@extundo.com>
143811         * m4/netinet_in_h.m4: New file.
143813 2006-07-28  Simon Josefsson  <jas@extundo.com>
143815         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
143816         #include's.
143818 2006-07-28  Simon Josefsson  <jas@extundo.com>
143820         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
143821         #include's.
143823 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
143825         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
143826         setgid on directories only if they set these bits.
143827         * lib/modechange.h: Remove obsolete comment about masks.
143829 2006-07-28  Eric Blake  <ebb9@byu.net>
143831         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
143832         macro expansion.
143834 2006-07-28  Bruno Haible  <bruno@clisp.org>
143836         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
143838 2006-07-28  Bruno Haible  <bruno@clisp.org>
143840         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
143842 2006-07-28  Bruno Haible  <bruno@clisp.org>
143844         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
143845         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
143846         Define fallbacks.
143847         Avoids link error on FreeBSD 4.x.
143848         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
143850         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
143851         encoding.
143852         * lib/mbswidth.c (iswcntrl): Likewise.
143854 2006-07-27  Bruno Haible  <bruno@clisp.org>
143856         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
143857         test.
143859 2006-07-27  Bruno Haible  <bruno@clisp.org>
143861         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
143862         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
143863         defined.
143865 2006-07-26  Eric Blake  <ebb9@byu.net>
143867         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
143869 2006-07-26  Eric Blake  <ebb9@byu.net>
143871         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
143872         like mingw that lack mkstemp.
143873         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
143874         avoid compilation warning on mingw.
143876 2006-07-26  Bruno Haible  <bruno@clisp.org>
143878         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
143879         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
143880         INT_FAST*_MIN, INTPTR_MIN.
143882 2006-07-25  Bruno Haible  <bruno@clisp.org>
143884         * modules/version-etc (Depends-on): Add stdarg.
143886 2006-07-25  Bruno Haible  <bruno@clisp.org>
143888         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
143889         complex commands.
143891 2006-07-25  Bruno Haible  <bruno@clisp.org>
143893         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
143894         defined in <stdarg.h> or config.h.
143896 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
143898         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
143899         (gl_STDIO_SAFER): Remove.
143901 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
143903         * MODULES.html.sh (File stream based Input/Output):
143904         Add fopen-safer, tmpfile-safer; remove stdio-safer.
143905         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
143906         * modules/fopen-safer, modules/tmpfile-safer: New files.
143907         * modules/stdio-safer: Remove.
143909 2006-07-24  Bruno Haible  <bruno@clisp.org>
143911         * modules/tmpdir: New file.
143912         * MODULES.html.sh (File system functions): Add it.
143914 2006-07-24  Bruno Haible  <bruno@clisp.org>
143916         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
143917         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
143919 2006-07-24  Bruno Haible  <bruno@clisp.org>
143921         * modules/clean-temp: New file.
143923 2006-07-24  Bruno Haible  <bruno@clisp.org>
143925         * m4/tmpdir.m4: New file, from GNU gettext.
143927 2006-07-24  Bruno Haible  <bruno@clisp.org>
143929         * lib/tmpdir.h: New file, from GNU gettext.
143930         * lib/tmpdir.c: New file, from GNU gettext.
143932 2006-07-24  Bruno Haible  <bruno@clisp.org>
143934         * lib/clean-temp.h: New file, from GNU gettext.
143935         * lib/clean-temp.c: New file, from GNU gettext.
143937 2006-07-23  Eric Blake  <ebb9@byu.net>
143939         * modules/stdio-safer (Files): Add tmpfile-safer.c.
143940         (Depends-on): Add binary-io.
143942 2006-07-23  Eric Blake  <ebb9@byu.net>
143944         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
143946 2006-07-23  Eric Blake  <ebb9@byu.net>
143948         * lib/tmpfile-safer.c: New file.
143949         * lib/stdio-safer.h (fopen_safer): Add prototype.
143950         * lib/stdio--.h (tmpfile): Make safer.
143952 2006-07-23  Bruno Haible  <bruno@clisp.org>
143954         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
143955         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
143956         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
143957         gl_linked_remove_at): Use it.
143959 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
143960         and Simon Josefsson <jas@extundo.com>
143962         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
143964         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
143966 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
143968         * modules/close-stream: New file.
143969         * modules/closeout (Description): Make it clear that it exits
143970         with a diagnostic on error.
143971         (Depends-on): Add close-stream.  Remove fpending, stdbool.
143972         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
143974 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
143976         * m4/close-stream.m4: New file.
143978 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
143980         * lib/close-stream.c, lib/close-stream.h: New files.
143982 2006-07-22  Bruno Haible  <bruno@clisp.org>
143984         Merge from GNU gettext 0.15.
143986         2006-05-01  Bruno Haible  <bruno@clisp.org>
143988                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
143990         2006-07-22  Bruno Haible  <bruno@clisp.org>
143992                 * modules/javaversion: New file.
143993                 * MODULES.html.sh (Java): Add javaversion.
143995         2006-03-12  Bruno Haible  <bruno@clisp.org>
143997                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
143999         2005-12-04  Bruno Haible  <bruno@clisp.org>
144001                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
144002                 (untested).
144004         2006-06-21  Bruno Haible  <bruno@clisp.org>
144006                 Avoid warnings from recent versions of mcs.
144007                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
144008                 -o, -L, -r any more. Use options documented since mcs-1.0
144009                 instead. Similarly for -g.
144011         2005-12-04  Bruno Haible  <bruno@clisp.org>
144013                 * build-aux/csharpcomp.sh.in: Suffix for resources is
144014                 .resources, not .resource.
144016         2005-07-09  Bruno Haible  <bruno@clisp.org>
144018                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
144019                 add a .dll suffix.
144020                 Reported by Mark Junker <mjscod@gmx.de>.
144022         2006-07-22  Bruno Haible  <bruno@clisp.org>
144024                 * modules/gettext: Upgrade to gettext-0.15.
144025                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
144026                 m4/visibility.m4.
144027                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
144029 2006-07-22  Bruno Haible  <bruno@clisp.org>
144031         Merge from GNU gettext 0.15.
144033         2006-03-25  Bruno Haible  <bruno@clisp.org>
144035                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
144037         2006-07-21  Bruno Haible  <bruno@clisp.org>
144039                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
144040                 "1.1".
144042         2006-05-09  Bruno Haible  <bruno@clisp.org>
144044                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
144045                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
144046                 for the conftestver execution.
144048         2006-05-01  Bruno Haible  <bruno@clisp.org>
144050                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
144051                 optional target-version argument. Verify that the compiler
144052                 groks source of the specified source-version, or add -source
144053                 option as necessary. Verify that the compiler produces
144054                 bytecode in the specified target-version, or add -target and
144055                 -source options as necessary. Make the result of the test
144056                 available as variable CONF_JAVAC. Also log error output in
144057                 config.log.
144059         2006-03-11  Bruno Haible  <bruno@clisp.org>
144061                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
144063         2006-05-09  Bruno Haible  <bruno@clisp.org>
144065                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
144066                 CLASSPATH_SEPARATOR to a semicolon.
144068         2006-03-12  Bruno Haible  <bruno@clisp.org>
144070                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
144071                 available as variable CONF_JAVA, for subsequent autoconf
144072                 tests. Also log error output in config.log.
144074         2006-07-19  Bruno Haible  <bruno@clisp.org>
144076                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
144077                 that getline works on glibc2 systems. Needed to avoid trouble
144078                 in relocatable.c.
144079                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
144081         2005-12-04  Bruno Haible  <bruno@clisp.org>
144083                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
144084                 launcher (untested).
144086         2005-12-04  Bruno Haible  <bruno@clisp.org>
144088                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
144090         2006-07-22  Bruno Haible  <bruno@clisp.org>
144092                 * gettext.m4: Update from GNU gettext-0.15.
144093                 * nls.m4: Likewise.
144094                 * po.m4: Likewise.
144095                 * inttypes-pri.m4: Likewise.
144096                 * inttypes-h.m4: Renamed from inttypes.m4.
144097                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
144099 2006-07-22  Bruno Haible  <bruno@clisp.org>
144101         Merge from GNU gettext 0.15.
144103         2005-07-05  Bruno Haible  <bruno@clisp.org>
144105                 * printf-args.c (printf_fetchargs): Work around broken
144106                 definition of wint_t on mingw.
144108         2005-02-12  Bruno Haible  <bruno@clisp.org>
144110                 * xallocsa.h: Add extern "C" for C++.
144112         2006-05-17  Bruno Haible  <bruno@clisp.org>
144114                 Cygwin portability.
144115                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
144117         2006-04-30  Bruno Haible  <bruno@clisp.org>
144119                 * progreloc.c: Include <mach-o/dyld.h> if available.
144120                 (find_executable): Use _NSGetExecutablePath when possible.
144122         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
144124                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
144125                 function.
144127         2005-12-29  Bruno Haible  <bruno@clisp.org>
144129                 * progreloc.c (set_program_name_and_installdir): Fix
144130                 compilation error.
144132         2005-12-04  Bruno Haible  <bruno@clisp.org>
144134                 Cygwin portability.
144135                 * progreloc.c: Include <windows.h> also on Cygwin.
144136                 (find_executable): Add support for Cygwin.
144137                 (set_program_name_and_installdir): Handle also platforms with
144138                 nonempty EXEEXT.
144140         2006-07-11  Bruno Haible  <bruno@clisp.org>
144142                 * javacomp.c: Fix a comment.
144143                 Reported by Jim Meyering.
144145         2006-04-30  Bruno Haible  <bruno@clisp.org>
144147                 * javacomp.h (compile_java_class): Add source_version,
144148                 target_version arguments.
144149                 * javacomp.c: Rewritten to choose only a compiler that
144150                 respects the specified source_version and target_version.
144152         2006-06-27  Bruno Haible  <bruno@clisp.org>
144154                 Assume correct S_ISDIR macro.
144155                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
144157         2006-07-22  Bruno Haible  <bruno@clisp.org>
144159                 * javaversion.h: New file, from GNU gettext.
144160                 * javaversion.c: New file, from GNU gettext.
144161                 * javaversion.java: New file, from GNU gettext.
144162                 * javaversion.class: New file, from GNU gettext.
144164         2006-05-17  Bruno Haible  <bruno@clisp.org>
144166                 Cygwin portability.
144167                 * javaexec.c (execute_java_class): Test for jview program
144168                 also on Cygwin.
144170         2006-04-09  Bruno Haible  <bruno@clisp.org>
144172                 * fatal-signal.c: Don't include string.h.
144173                 (at_fatal_signal): Use a copying loop instead of memcpy.
144175         2005-12-04  Bruno Haible  <bruno@clisp.org>
144177                 * csharpexec.c: Add support for 'clix' launcher (untested).
144178                 (execute_csharp_using_sscli): New function.
144179                 (execute_csharp_program): Call it.
144181         2006-06-21  Bruno Haible  <bruno@clisp.org>
144183                 Avoid warnings from recent versions of mcs.
144184                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
144185                 -o, -L, -r any more. Use options documented since mcs-1.0
144186                 instead. Similarly for -g.
144188         2005-07-09  Bruno Haible  <bruno@clisp.org>
144190                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
144191                 add a .dll suffix.
144192                 Reported by Mark Junker <mjscod@gmx.de>.
144194         2006-06-17  Bruno Haible  <bruno@clisp.org>
144196                 * config.charset: Update for NetBSD 3.0.
144198         2006-05-17  Bruno Haible  <bruno@clisp.org>
144200                 Cygwin portability.
144201                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
144203         2006-05-16  Bruno Haible  <bruno@clisp.org>
144205                 * localcharset.c [CYGWIN]: Include <windows.h>.
144206                 (get_charset_aliases): For Cygwin, return the same CPxxx
144207                 aliases list as under WIN32.
144208                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
144209                 the environment variables. Fall back to GetACP().
144211         2006-04-05  Bruno Haible  <bruno@clisp.org>
144213                 * config.charset: Update Juan Manuel Guerrero's address.
144215         2005-02-12  Bruno Haible  <bruno@clisp.org>
144217                 * allocsa.h: Add extern "C" for C++.
144219         2005-02-10  Bruno Haible  <bruno@clisp.org>
144221                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
144222                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
144224         2006-07-22  Bruno Haible  <bruno@clisp.org>
144226                 * gettext.h: Update to GNU gettext-0.15.
144228 2006-07-22  Bruno Haible  <bruno@clisp.org>
144230         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
144231         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
144232         lib-prefix.m4, longdouble.m4, ssize_t.m4.
144234 2006-07-21  Eric Blake  <ebb9@byu.net>
144236         * modules/stdlib-safer: New file.
144237         * MODULES.html.sh (File stream based Input/Output): Add
144238         stdlib-safer.
144240 2006-07-21  Eric Blake  <ebb9@byu.net>
144242         * lib/stdlib-safer.h: New file from coreutils, required by
144243         stdlib--.h.
144245 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
144247         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
144249 2006-07-20  Bruno Haible  <bruno@clisp.org>
144251         * gnulib-tool: Recognize new option --assume-autoconf.
144252         (autoconf_minversion): New variable.
144253         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
144255 2006-07-20  Bruno Haible  <bruno@clisp.org>
144257         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
144259 2006-07-19  Derek R. Price  <derek@ximbiot.com>
144261         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
144262         Reindent and repaginate.
144264 2006-07-19  Derek Price  <derek@ximbiot.com>
144266         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
144267         Correct grammar.
144269 2006-07-17  Bruno Haible  <bruno@clisp.org>
144271         * modules/list: New file.
144272         * modules/array-list: New file.
144273         * modules/carray-list, modules/carray-list-tests: New files.
144274         * modules/linked-list, modules/linked-list-tests: New files.
144275         * modules/avltree-list, modules/avltree-list-tests: New files.
144276         * modules/rbtree-list, modules/rbtree-list-tests: New files.
144277         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
144278         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
144279         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
144280         * modules/oset: New file.
144281         * modules/array-oset: New file.
144282         * modules/avltree-oset, modules/avltree-oset-tests: New files.
144283         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
144284         * tests/test-carray_list.c: New file.
144285         * tests/test-linked_list.c: New file.
144286         * tests/test-avltree_list.c: New file.
144287         * tests/test-rbtree_list.c: New file.
144288         * tests/test-linkedhash_list.c: New file.
144289         * tests/test-avltreehash_list.c: New file.
144290         * tests/test-rbtreehash_list.c: New file.
144291         * tests/test-avltree_oset.c: New file.
144292         * tests/test-rbtree_oset.c: New file.
144293         * MODULES.html.sh (Container data structures): New section.
144295 2006-07-17  Bruno Haible  <bruno@clisp.org>
144297         * m4/gl_list.m4: New file.
144299 2006-07-17  Bruno Haible  <bruno@clisp.org>
144301         * lib/gl_list.h: New file.
144302         * lib/gl_list.c: New file.
144303         * lib/gl_array_list.h: New file.
144304         * lib/gl_array_list.c: New file.
144305         * lib/gl_carray_list.h: New file.
144306         * lib/gl_carray_list.c: New file.
144307         * lib/gl_linked_list.h: New file.
144308         * lib/gl_linked_list.c: New file.
144309         * lib/gl_anylinked_list1.h: New file.
144310         * lib/gl_anylinked_list2.h: New file.
144311         * lib/gl_avltree_list.h: New file.
144312         * lib/gl_avltree_list.c: New file.
144313         * lib/gl_anyavltree_list1.h: New file.
144314         * lib/gl_anyavltree_list2.h: New file.
144315         * lib/gl_rbtree_list.h: New file.
144316         * lib/gl_rbtree_list.c: New file.
144317         * lib/gl_anyrbtree_list1.h: New file.
144318         * lib/gl_anyrbtree_list2.h: New file.
144319         * lib/gl_anytree_list1.h: New file.
144320         * lib/gl_anytree_list2.h: New file.
144321         * lib/gl_linkedhash_list.h: New file.
144322         * lib/gl_linkedhash_list.c: New file.
144323         * lib/gl_anyhash_list1.h: New file.
144324         * lib/gl_anyhash_list2.h: New file.
144325         * lib/gl_avltreehash_list.h: New file.
144326         * lib/gl_avltreehash_list.c: New file.
144327         * lib/gl_rbtreehash_list.h: New file.
144328         * lib/gl_rbtreehash_list.c: New file.
144329         * lib/gl_anytreehash_list1.h: New file.
144330         * lib/gl_anytreehash_list2.h: New file.
144332         * lib/gl_oset.h: New file.
144333         * lib/gl_oset.c: New file.
144334         * lib/gl_array_oset.h: New file.
144335         * lib/gl_array_oset.c: New file.
144336         * lib/gl_avltree_oset.h: New file.
144337         * lib/gl_avltree_oset.c: New file.
144338         * lib/gl_rbtree_oset.h: New file.
144339         * lib/gl_rbtree_oset.c: New file.
144340         * lib/gl_anytree_oset.h: New file.
144342 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
144344         * m4/mkancesdirs.m4: New file.
144345         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
144346         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
144347         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
144348         it.
144350 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
144352         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
144353         * lib/mkancesdirs.h: New files.
144354         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
144355         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
144356         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
144357         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
144358         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
144359         callers changed.  Revamp internals significantly, by not
144360         attempting to create directories that are temporarily more
144361         permissive than the final results.  Do not attempt to use
144362         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
144363         This removes some race conditions, fixes some bugs, and simplifies
144364         things.  Use new dirchownmod function to do owner and mode changes.
144365         * lib/mkdir-p.h: Likewise.
144366         * lib/modechange.c (octal_to_mode): New function.
144367         (struct mode_change): New member mentioned.
144368         (make_node_op_equals): New arg mentioned.  All callers changed.
144369         (mode_compile): Keep track of which mode bits the user has explicitly
144370         mentioned.
144371         (mode_adjust): New arg DIR, so that we implement the X op correctly.
144372         New arg PMODE_BITS, to keep track of which mode bits the user
144373         mentioned; it treats S_ISUID and S_ISGID speciall.
144374         All callers changed.
144375         * lib/modechange.h: Likewise.
144377 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
144379         * MODULES.html.sh: Add mkancestors.
144380         * modules/mkancesdirs: New module.
144381         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
144382         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
144383         The chdir-safer and afs files are now orphans; I'll remove them
144384         unless someone speaks up.
144385         Add lib/dirchownmod.c, lib/dirchownmod.h.
144386         (Depends-on): Remove alloca, chown, save-cwd, dirname.
144387         Add lchown, mkancesdirs.
144388         (Maintainer): Add self.
144390 2006-07-15  Karl Berry  <karl@gnu.org>
144392         * gnulib-tool: help message wording/arrangement.
144394 2006-07-14  Simon Josefsson  <jas@extundo.com>
144396         * doc/gnulib.texi (Libtool and Windows): New section.
144398 2006-07-12  Simon Josefsson  <jas@extundo.com>
144400         * modules/gendocs (License): Fix license, approved by Karl.
144402 2006-07-12  Eric Blake  <ebb9@byu.net>
144404         * MODULES.html.sh: Add gendocs.
144406 2006-07-11  Eric Blake  <ebb9@byu.net>
144408         * modules/fdl: New module, to install doc/fdl.texi.
144409         * MODULES.html.sh: Add new section for documentation modules.
144410         * gnulib-tool: Avoid space-tab.
144411         (--doc-base): New option, to manage files from doc.
144413 2006-07-11  Eric Blake  <ebb9@byu.net>
144415         * m4/absolute-header.m4: Fix comments to match recent change.
144417 2006-07-11  Eric Blake  <ebb9@byu.net>
144419         * gnulib-tool: List --doc-base before --tests-base.
144421 2006-07-11  Derek R. Price  <derek@ximbiot.com>
144423         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
144425 2006-07-11  Bruno Haible  <bruno@clisp.org>
144427         * README: Mention where to put documentation.
144429 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
144431         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
144433 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
144435         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
144436         to stdint.m4.
144438 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
144440         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
144441         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
144442         "no/such/file/stdint.h" when there is no such file, so that
144443         the resulting C code can be parsed by dodgy compilers.
144444         Problems reported by Bob Proulx.
144446 2006-07-10  Derek R. Price  <derek@ximbiot.com>
144448         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
144449         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
144450         macros into the GNU _D_EXACT_NAMLEN.
144451         * lib/savedir.c:  Likewise.
144452         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
144454 2006-07-10  Derek R. Price  <derek@ximbiot.com>
144455         and Paul Eggert  <eggert@cs.ucla.edu>
144457         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
144458         * m4/savedir.m4:
144459         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
144460         macros into the GNU _D_EXACT_NAMLEN.
144462 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
144464         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
144465         around the absolute name, to work around a problem with the HP-UX
144466         11.23 native C compiler, reported by Bob Proulx.
144468 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
144470         * doc/maintain.texi, make-stds.texi: Sync from
144471         <http://savannah.gnu.org/projects/gnustandards>.
144473 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
144475         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
144477 2006-07-09  Jim Meyering  <jim@meyering.net>
144479         * m4/glob.m4: Remove a doubled word in a comment.
144481 2006-07-09  Jim Meyering  <jim@meyering.net>
144483         * lib/argp-pv.c: Remove a doubled word in a comment.
144484         * lib/check-version.c (check_version): Likewise.
144485         * lib/javacomp.c (compile_java_class): Likewise.
144487 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
144489         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
144490         for the benefit of people using Autoconf 2.60.  If you want to
144491         support older Autoconf versions you can copy m4/onceonly_2_57.m4
144492         (or m4/onceonly.m4, if pre-2.57) manually.
144494 2006-07-08  Jim Meyering  <jim@meyering.net>
144496         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
144497         comment.
144498         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
144499         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
144500         comment.
144502 2006-07-08  Jim Meyering  <jim@meyering.net>
144504         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
144506 2006-07-07  Simon Josefsson  <jas@extundo.com>
144508         * tests/test-crc.c: Change expected crc value, the test vector
144509         were probably computed using the old broken crc.c?
144511 2006-07-06  Simon Josefsson  <jas@extundo.com>
144513         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
144514         now the canonical place for the M4 file).
144516         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
144517         from the sys_socket dependency now.
144519         * modules/inet_pton (Files): Ditto.
144521         * modules/inet_ntop (Files): Ditto.
144523 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
144525         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
144526         not gl_PREREQ_GETUSERSHELL.
144528 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
144530         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
144531         with only one argument, for Autoconf 2.60.
144532         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
144533         expand to nothing, so add a shell command to avoid syntax error.
144534         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
144536 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
144538         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
144540 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
144542         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
144543         no longer needed.  Check for isblank decl.
144544         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
144545         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
144546         of existence.
144548 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
144550         * lib/getloadavg.c: Use __VMS, not VMS.
144551         * lib/getopt.c: Likewise.
144552         * lib/getpagesize.h: Likewise.
144553         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
144554         and probably does not work.
144556 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
144558         * lib/.cppi-disable: Add wcwidth.
144559         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
144560         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
144561         (ISGRAPH): Remove.  All uses changed to isgraph.
144562         (FOLD) [!defined _LIBC]: Remove special case.
144563         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
144564         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
144565         HAVE_ISBLANK.
144566         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
144567         case.
144569 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
144571         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
144572         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
144573         brackets.  Other minor changes to suppress some compiler
144574         warnings.
144576 2006-07-06  Derek R. Price  <derek@ximbiot.com>
144577         and Paul Eggert  <eggert@cs.ucla.edu>
144579         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
144580         of invoking obsolescent AC_HEADER_DIRENT macro.
144581         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
144582         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
144583         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
144584         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
144585         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
144586         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
144587         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
144588         * m4/readdir.m4: Remove; no longer needed.
144590 2006-07-06  Derek R. Price  <derek@ximbiot.com>
144591         and Paul Eggert  <eggert@cs.ucla.edu>
144593         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
144594         Don't worry about this obsolete case any more.
144595         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
144596         directories.
144597         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
144598         worry about this obsolete case any more.
144599         * lib/fts.c: Likewise.
144600         * lib/getcwd.c: Likewise.
144601         * lib/glob.h: Likewise.
144602         * lib/savedir.c: Likewise.
144604 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
144606         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
144607         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
144608         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
144609         needed.
144610         All uses removed.
144611         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
144612         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
144613         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
144614         needed.
144615         * m4/getdate.m4 (gl_GETDATE): Likewise.
144616         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
144617         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
144618         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
144619         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
144620         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
144621         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
144622         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
144623         needed.
144625 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
144627         * lib/memcasecmp.c: Include <limits.h>.
144628         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
144629         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
144630         Don't assume isdigit succeeds only on '0' through '9'.
144632 2006-07-05  Eric Blake  <ebb9@byu.net>
144634         * modules/getaddrinfo (Depends-on): Add snprintf.
144636 2006-07-05  Eric Blake  <ebb9@byu.net>
144638         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
144639         to avoid 'header present but could not be compiled' on cygwin.
144641 2006-07-05  Eric Blake  <ebb9@byu.net>
144643         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
144644         missing from netdb.h.
144645         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
144647 2006-07-05  Derek R. Price  <derek@ximbiot.com>
144649         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
144650         no longer needed.
144651         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
144652         * m4/getdate.m4 (gl_GETDATE): Likewise.
144653         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
144654         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
144655         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
144656         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
144657         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
144659 2006-07-05  Derek R. Price  <derek@ximbiot.com>
144661         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
144662         All uses of is_space replaced by isspace.
144663         * lib/exit.h: Don't talk about STDC_HEADERS.
144664         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
144665         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
144666         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
144667         replaced by isprint etc.
144668         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
144669         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
144670         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
144671         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
144672         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
144673         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
144675 2006-07-05  Bruno Haible  <bruno@clisp.org>
144677         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
144678         the function exists, before testing against AIX.
144679         Reported by Martin Lambers <marlam@marlam.de>.
144681 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
144683         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
144684         From Mark D. Baushke.
144686 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
144688         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
144689         to the absolute name, not just one, to bypass Sun C 5.8's
144690         "warning: #include of /usr/include/... may be non-portable".
144692 2006-07-04  Eric Blake  <ebb9@byu.net>
144694         * modules/dirname-tests: New test module.
144695         * tests/test-dirname.c: New file, replacing dirname.c
144696         TEST_DIRNAME section that was recently deleted.
144698 2006-07-04  Bruno Haible  <bruno@clisp.org>
144700         Assume ANSI C header files and <ctype.h> functions.
144701         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
144702         (mbsnwidth): Use isprint, iscntrl instead.
144704 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
144706         Merge from coreutils.
144707         * MODULES.html.sh: Add xstrtold.
144708         * modules/xstrtold: New file.
144709         * modules/cycle-check (Files): Add lib/same-inode.h.
144710         * modules/dirname (Files): Add m4/double-slash-root.m4.
144711         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
144712         * modules/mkdir-p (Files): Add lib/same-inode.h.
144713         * modules/same (Files): Add lib/same-inode.h.
144715 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
144717         * m4/absolute-header.m4: Renamed from full-header-path.m4.
144718         This is to keep the terminology clean; POSIX talks about
144719         "absolute pathnames", not "full pathnames", but the GNU
144720         Coding Standards say to use "path" for something else;
144721         so use "absolute" to keep both sides happy.
144722         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
144723         Set gl_absolute_header, not gl_full_header_path.
144724         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
144725         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
144726         All uses changed.
144728         Merge from coreutils.
144730         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
144732         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
144733         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
144734         want to require the building of c-strtod.o.
144735         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
144736         needs -lm directly.
144737         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
144739         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
144741         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
144742         --as-needed option if available.  Problem reported by Albert Chin in
144743         <http://lists.gnu.org/r/bug-gnulib/2006-06/msg00114.html>.
144744         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
144745         cc merely issues a bunch of annoying warnings for --as-needed
144746         (this problem was reported by Bob Proulx).  Also, try linking with
144747         -lm to detect a bug in binutils 2.16 (this problem was reported
144748         by Ralf Wildenhues).
144750         2006-06-18  Jim Meyering  <jim@meyering.net>
144752         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
144753         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
144754         macro.
144755         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
144756         also check for glibc-2.4's abort-inducing bug.
144758         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
144759         Low-probability clean-up should be to use rmdir to get rid of
144760         the just-created directory, not unlink.
144762         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
144763         configure fail, and request a bug report to inform us about it.
144764         Add a comment that, barring reports to the contrary, in 2007 we'll
144765         assume ftruncate is universally available.
144767         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
144769         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
144771         2006-03-12  Jim Meyering  <jim@meyering.net>
144773         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
144774         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
144775         * m4/same.m4 (gl_SAME): Likewise.
144776         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
144778         2006-03-11  Eric Blake  <ebb9@byu.net>
144780         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
144781         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
144782         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
144783         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
144785 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
144787         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
144788         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
144789         reported by Mark D. Baushke, one in
144790         <http://lists.gnu.org/r/bug-gnulib/2006-07/msg00015.html>.
144792         Merge from coreutils.
144794         * lib/.cppi-disable: Add stdint_.h.
144795         * lib/.cvsignore: Add stdint.h.
144797         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
144799         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
144800         both double and long double versions.
144801         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
144802         * lib/xstrtold.c: New file.
144803         * lib/xstrtod.h (xstrtold): New decl.
144805         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
144807         * lib/filemode.c (setst): Remove.
144808         (strmode): Rewrite to avoid setst.  This makes the code shorter,
144809         (arguably) clearer, and the generated code is a bit smaller on my
144810         Debian GNU/Linux stable x86 host.
144812         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
144814         * lib/filemode.c: Include "filemode.h" first, to test the interface.
144815         Assume that filemode.h includes sys/types.h and sys/stat.h.
144816         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
144817         (ftypelet): Reorder to put common cases first, for efficiency.
144818         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
144819         to do 'M'.
144820         (strmode): Renamed from mode_string, and now stores 12 bytes instead
144821         of 10, for compatibility with FreeBSD.  All callers changed.
144822         (filemodestring): Now stores 12 bytes instead of 10, and sets file
144823         types that can't be deduced solely from st_mode.  First arg is now a
144824         const pointer.
144825         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
144826         (strmode): Renamed from mode_string.
144827         (filemodestring): New decl.
144828         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
144829         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
144830         needed.
144831         (S_ISPORT, S_ISWHT): New macros, if not already defined.
144833         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
144835         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
144836         fsusage.h now does that.  Include fsusage.h first, to test interface.
144837         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
144838         at most one method (the old code could have generated decls that
144839         didn't conform to C89, not that this was ever exercised).
144840         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
144842         2006-03-19  Jim Meyering  <jim@meyering.net>
144844         Work even in a chroot where d_ino values for entries in "/"
144845         don't match the stat.st_ino values for the same names.
144846         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
144847         number, iterate through all entries again, using lstat instead.
144848         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
144849         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
144851         * lib/getcwd.c (__getcwd): Clarify a comment.
144852         Use memcpy in place of a call to strcpy.
144854         2006-03-12  Jim Meyering  <jim@meyering.net>
144856         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
144857         matches that of the current directory (which we're about to chdir ".."
144858         out of), then save the dev-ino of the parent, instead.
144860         * lib/same-inode.h (SAME_INODE): New file/macro.
144861         * lib/chdir-safer.c (SAME_INODE): Remove definition.
144862         Include "same-inode.h", instead.
144863         * lib/same.c: Likewise.
144864         * lib/cycle-check.h: Include "same-inode.h".
144865         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
144866         * lib/cycle-check.c (SAME_INODE): Remove definition.
144867         * lib/root-dev-ino.h: Include "same-inode.h".
144869         2006-03-11  Eric Blake  <ebb9@byu.net>
144871         * lib/same.c (same_name): s/base_name/last_component/
144872         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
144873         * lib/filenamecat.c (file_name_concat): Likewise.
144875         2006-03-11  Eric Blake  <ebb9@byu.net>,
144876                     Paul Eggert  <eggert@cs.ucla.edu>
144878         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
144879         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
144880         drive prefix.
144881         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
144882         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
144883         (last_component): New method.
144884         * lib/dirname.c (dir_len): Determine when drive letters need a
144885         subsequent slash.  Preserve // when it is special.
144886         (dir_name): Don't append dot when drive letter is absolute.
144887         [TEST_DIRNAME]: Move into a full-blown gnulib test.
144888         * lib/basename.c (base_name): New semantics - malloc the result.
144889         Preserve // when it is special.  Preserve relative files that look
144890         like drive letters.
144891         (base_len): Preserve // when it is special.
144892         (last_component): New method, similar to old base_name semantics.
144893         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
144894         base_name.  Strip redundant slashes from ///.
144896 2006-07-03  Jim Meyering  <jim@meyering.net>
144898         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
144899         macro is used before the first cycle_check call.
144901 2006-07-03  Eric Blake  <ebb9@byu.net>
144903         * modules/dirname (Depends-on): Add xstrndup.
144905 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
144907         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
144908         test cases, so that config.log is a bit easier to follow.
144910 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
144912         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
144913         both are 64 bits, since this seems to be the tradition, and this
144914         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
144915         we ever run into a host that prefers long long to long in this
144916         case, we'll need another configure-time test.  Problem reported by
144917         Jim Meyering.
144919 2006-07-02  Eric Blake  <ebb9@byu.net>
144921         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
144923 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
144925         * modules/inttypes (Depends-on): No longer depends on stdint.
144926         * modules/stdint (Description): Say more about assumptions.
144927         Say that the fast types might differ.  Say macros are used.
144928         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
144929         (Makefile.am): Revise list of substituted symbols to match
144930         new stdint.m4.
144931         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
144932         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
144933         * tests/test-stdint.c (verify_same_types)
144934         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
144935         the code conforms to C99/C89.
144936         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
144937         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
144939 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
144941         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
144942         but fix a bug, by requiring at least 64 bits.
144943         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
144944         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
144945         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
144946         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
144948         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
144949         changes.  Make 2.59 a prerequisite.  Check and substitute for
144950         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
144951         inttypes.h.  Do not use special include files; just use the
144952         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
144953         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
144954         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
144955         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
144956         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
144957         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
144958         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
144959         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
144960         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
144961         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
144962         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
144963         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
144964         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
144965         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
144966         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
144967         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
144968         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
144969         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
144970         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
144971         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
144972         WINT_MAX.  Check for C99 conformance more strictly, by detecting
144973         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
144974         not check for things that C99 does not require, e.g., int8_t.  If
144975         a test isn't needed unless <stdint.h> isn't working, and is
144976         unlikely to be needed for any other reason, then don't do it
144977         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
144978         size_t, since we assume C89 freestanding at least.  Do not check
144979         for sig_atomic_t, wchar_t, or wint_t, since the code now does
144980         the right thing even if the types are not defined.  Instead use:
144981         (gl_STDINT_TYPE_PROPERTIES): New macro.
144982         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
144983         testing whether <sys/types.h> clashes, as Autoconf does this for
144984         us now.  All uses removed.
144985         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
144986         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
144987         (gl_CHECK_TYPE_SAME):
144988         Remove; no longer needed.
144989         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
144990         exists, since we'll return 0 anyway in that case.
144991         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
144993 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
144995         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
144996         possible collision with system files.
144997         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
144998         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
144999         WCHAR_MIN and WCHAR_MAX in this case.
145000         (<stddef.h>): Do not include; no longer needed.
145001         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
145002         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
145003         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
145004         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
145005         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
145006         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
145007         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
145008         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
145009         !defined(__c99))]: Include in this case too, since it's harmless
145010         now.
145011         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
145012         dangerous to do so.
145013         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
145014         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
145015         (_STDINT_MIN, _STDINT_MAX): New macros.
145016         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
145017         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
145018         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
145019         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
145020         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
145021         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
145022         macros, not typedefs; this simplifies things quite a bit.
145023         Use long int for all types narrower than int64_t.
145024         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
145025         Define in terms of long long int or int64_t or long int,
145026         not int64_t or int32_t.  This saves some compile-time testing.
145027         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
145028         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
145029         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
145030         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
145031         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
145032         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
145033         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
145034         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
145035         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
145036         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
145037         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
145038         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
145039         undef any previous version and define our own version, for
145040         simplicity and consistency with the new macros for types.
145041         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
145042         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
145043         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
145044         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
145045         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
145046         @WINT_T_SUFFIX@ to keep things simple here.
145047         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
145048         Simplify by assuming typical 8/16/32/64 host, since we're
145049         already doing that elsewhere anyway.
145050         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
145051         and assume long long int is 64 bits if available.  This
145052         speeds up 'configure'.
145054 2006-07-01  Eric Blake  <ebb9@byu.net>
145056         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
145057         Reported by Andreas Buening.
145059 2006-07-01  Eric Blake  <ebb9@byu.net>
145061         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
145063 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
145065         * lib/getaddrinfo.c: fixed typo
145067 2006-06-29  Jim Meyering  <jim@meyering.net>
145069         * modules/strftime (Maintainer): Add my name, since with the
145070         FPRINTFTIME changes strftime.c has forked from glibc.
145072 2006-06-29  Eric Blake  <ebb9@byu.net>
145074         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
145076 2006-06-29  Eric Blake  <ebb9@byu.net>
145078         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
145080 2006-06-29  Eric Blake  <ebb9@byu.net>
145082         * lib/stat_.h: New file.
145084 2006-06-29  Eric Blake  <ebb9@byu.net>
145086         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
145087         unused static function.
145089 2006-06-29  Eric Blake  <ebb9@byu.net>
145091         * doc/functions.texi (Function Portability): Document missing lstat
145092         on mingw.
145094 2006-06-29  Eric Blake  <ebb9@byu.net>
145096         * MODULES.html.sh: Add sys_stat.
145097         * modules/sys_stat: New module.
145098         * modules/mkstemp (Depends-on): Add sys_stat.
145100 2006-06-29  Derek R. Price  <derek@ximbiot.com>
145102         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
145104 2006-06-29  Derek R. Price  <derek@ximbiot.com>
145106         * m4/c-bs-a.m4: Removed.
145108 2006-06-29  Derek R. Price  <derek@ximbiot.com>
145110         * lib/strftime.c: Assume strftime() exists.
145112 2006-06-29  Derek Price  <derek@ximbiot.com>
145114         * modules/c-bs-a: Removed - \a is C89.
145115         * MODULES.html.sh: Remove c-bs-a.
145117 2006-06-29  Bruno Haible  <bruno@clisp.org>
145119         * modules/wcwidth (License): Change to LGPL.
145121 2006-06-28  Simon Josefsson  <jas@extundo.com>
145123         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
145124         on _WIN32.
145126         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
145127         getnameinfo.
145129 2006-06-28  Simon Josefsson  <jas@extundo.com>
145131         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
145133 2006-06-28  Simon Josefsson  <jas@extundo.com>
145135         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
145136         functions there.  It will succeed on Windows XP, but on Windows
145137         2000 and (presumably) earlier, it will fail, and use the internal
145138         re-implementation.
145139         (use_win32_p): New function.
145140         (getaddrinfo): Use strtoul on servname, to support numeric ports.
145141         Support AI_NUMERICSERV to disable getservbyname.
145142         (getnameinfo): New function, only supports
145143         NI_NUMERICHOST|NI_NUMERICSERV for now.
145145         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
145146         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
145147         getnameinfo.
145149 2006-06-28  Eric Blake  <ebb9@byu.net>
145151         * modules/wcwidth: New file.
145152         * modules/mbchar (Depends-on): Add wcwidth.
145153         * modules/mbswidth (Depends-on): Add wcwidth.
145154         * MODULES.html.sh: Add wcwidth.
145156 2006-06-28  Eric Blake  <ebb9@byu.net>
145158         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
145159         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
145161 2006-06-28  Eric Blake  <ebb9@byu.net>
145163         * lib/xvasprintf.h: Fix comments.
145165 2006-06-28  Eric Blake  <ebb9@byu.net>
145167         * lib/mbchar.h (wcwidth): Include wcwidth.h.
145168         * lib/mbswidth.c (wcwidth): Move from here...
145169         * lib/wcwidth.h: ...to this new file.
145171 2006-06-28  Derek R. Price  <derek@ximbiot.com>
145173         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
145175         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
145176         it's obsolete.
145177         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
145179 2006-06-28  Derek R. Price  <derek@ximbiot.com>
145181         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
145182         Autoconf 2.60 says this stuff was obsolete.
145184 2006-06-28  Bruno Haible  <bruno@clisp.org>
145186         * modules/wcwidth (Files): Add m4/wchar_t.m4.
145188 2006-06-28  Bruno Haible  <bruno@clisp.org>
145190         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
145191         gt_TYPE_WCHAR_T.
145193 2006-06-28  Bruno Haible  <bruno@clisp.org>
145195         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
145196         declaration for wcwidth.
145197         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctype.h>.
145199 2006-06-28  Bruno Haible  <bruno@clisp.org>
145201         * lib/mkdtemp.c [MINGW]: Include <io.h>.
145202         (mkdir): Define using _mkdir.
145204 2006-06-28  Bruno Haible  <bruno@clisp.org>
145206         * lib/getaddrinfo.h: Fix POSIX URL.
145207         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
145208         _WIN32.
145209         (use_win32_p): Make static.
145210         (getaddrinfo): Reject service name if it is empty or does not consist
145211         solely of decimal digits, or if its value is > 65535.
145212         (getnameinfo): Remove useless casts.
145214 2006-06-27  Simon Josefsson  <jas@extundo.com>
145216         * modules/sys_select: New file, suggested by Bruno Haible, Paul
145217         Eggert and Martin Lambers.
145219 2006-06-27  Simon Josefsson  <jas@extundo.com>
145221         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
145222         Eggert and Martin Lambers.
145224 2006-06-27  Bruno Haible  <bruno@clisp.org>
145226         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
145227         result to 0, not to empty.
145228         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
145230 2006-06-27  Bruno Haible  <bruno@clisp.org>
145232         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
145234 2006-06-26  Simon Josefsson  <jas@extundo.com>
145236         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
145237         present.
145239 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
145241         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
145242         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
145243         <http://lists.gnu.org/r/bug-gnulib/2006-06/msg00181.html>.
145245 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
145247         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
145249 2006-06-26  Bruno Haible  <bruno@clisp.org>
145251         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
145253 2006-06-26  Bruno Haible  <bruno@clisp.org>
145255         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
145257 2006-06-26  Bruno Haible  <bruno@clisp.org>
145259         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
145260         SGI C compiler in pre-C99 mode.
145261         Suggested by Mark D. Baushke and Larry Jones.
145263 2006-06-26  Bruno Haible  <bruno@clisp.org>
145265         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
145266         WCHAR_MAX.
145267         Reported by Mark D. Baushke and Larry Jones.
145269 2006-06-26  Bruno Haible  <bruno@clisp.org>
145271         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
145272         in pre-C99 mode.
145273         Suggested by Mark D. Baushke and Larry Jones.
145275 2006-06-23  Simon Josefsson  <jas@extundo.com>
145276             Bruno Haible  <bruno@clisp.org>
145278         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
145279         Emit mostlyclean-local rule.
145280         (func_emit_tests_Makefile_am): Likewise.
145281         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
145283 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
145285         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
145287 2006-06-23  Bruno Haible  <bruno@clisp.org>
145289         * tests/test-stdint.c: Update to match ISO C 99 Technical
145290         Corrigendum 1.
145292 2006-06-23  Bruno Haible  <bruno@clisp.org>
145294         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
145296 2006-06-23  Bruno Haible  <bruno@clisp.org>
145298         * lib/stdint_.h: Treat IRIX like OpenBSD.
145300 2006-06-23  Bruno Haible  <bruno@clisp.org>
145302         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
145303         ISO C 99 Technical Corrigendum 1.
145305 2006-06-22  Simon Josefsson  <jas@extundo.com>
145307         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
145308         MinGW.
145310 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
145312         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
145313         needed.  Some compiler complained about some of them.  Problem reported
145314         by Larry Jones in
145315         <http://lists.gnu.org/r/bug-gnulib/2006-06/msg00172.html>.
145317 2006-06-21  Simon Josefsson  <jas@extundo.com>
145319         * tests/test-getaddrinfo.c: New file.
145321         * modules/getaddrinfo-tests: New file.
145323         * MODULES.html.sh: Add inet_pton.
145325         * modules/inet_pton: New file.
145327 2006-06-21  Simon Josefsson  <jas@extundo.com>
145329         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
145330         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
145331         of using the (limited) gnulib implementation on Windows XP.
145333         * m4/inet_pton.m4: New file.
145335 2006-06-21  Simon Josefsson  <jas@extundo.com>
145337         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
145338         variable.
145340         * lib/socket_.h: Don't define WINVER.
145342         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
145343         slightly modified to work in gnulib.
145345 2006-06-21  Simon Josefsson  <jas@extundo.com>
145347         * doc/gnulib.texi (Windows sockets): Add.
145349 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
145351         * lib/read-file.c (fread_file): Start with buffer allocation of
145352         0 bytes rather than 1 byte; this simplifies the code.
145353         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
145354         code to free buffer and save/restore errno.
145355         (internal_read_file): Remove unused local.
145357 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
145359         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
145360         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
145361         Problem reported by Denis Excoffier in
145362         <http://lists.gnu.org/r/bug-tar/2006-06/msg00023.html>.
145364 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
145366         * modules/sys_socket, modules/socklen: Include sys/types since
145367         FreeBSD 4.x's sys/socket.h needs it.
145369 2006-06-19  Simon Josefsson  <jas@extundo.com>
145371         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
145373 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
145375         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
145377 2006-06-19  Bruno Haible  <bruno@clisp.org>
145379         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
145380         and FULL_PATH_INTTYPES_H in angle brackets.
145381         Reported by Mark D. Baushke <mdb@gnu.org>.
145383 2006-06-17  Eric Blake  <ebb9@byu.net>
145385         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
145386         errno.
145388 2006-06-17  Bruno Haible  <bruno@clisp.org>
145390         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
145391         <sys/inttypes.h>.
145393 2006-06-17  Bruno Haible  <bruno@clisp.org>
145395         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
145396         whether errno is declared. Assume <errno.h> declares errno.
145398 2006-06-17  Bruno Haible  <bruno@clisp.org>
145400         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
145402 2006-06-17  Bruno Haible  <bruno@clisp.org>
145404         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
145405         problem on Solaris 2.5.1.
145407 2006-06-16  Eric Blake  <ebb9@byu.net>
145409         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
145410         * lib/unicodeio.c [!defined errno]: Likewise.
145411         * lib/strtol.c [!defined errno]: Likewise.
145412         * lib/strtod.c [!defined errno]: Likewise.
145414 2006-06-15  Eric Blake  <ebb9@byu.net>
145416         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
145418 2006-06-15  Eric Blake  <ebb9@byu.net>
145420         * config/srclist.txt (ssize_t.m4): Lose sync.
145422 2006-06-15  Bruno Haible  <bruno@clisp.org>
145424         * modules/stdint (Files): Include m4/full-header-path.m4,
145425         m4/size_max.m4, m4/wchar_t.m4.
145426         (Makefile.am): Many more substitutions.
145427         * modules/stdint-tests: New file.
145428         * tests/test-stdint.c: New file.
145430 2006-06-15  Bruno Haible  <bruno@clisp.org>
145432         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
145433         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
145434         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
145435         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
145436         gl_CHECK_TYPE_SAME): New macros.
145438 2006-06-15  Bruno Haible  <bruno@clisp.org>
145440         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
145442 2006-06-15  Bruno Haible  <bruno@clisp.org>
145444         * lib/stdint_.h: Rewritten to be fully auto-configured.
145445         Fixes bug on HP-UX/IA64.
145447 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
145449         * lib/getdate.y (__attribute__): Don't define if already defined.
145450         Problem reported by Larry Jones.
145451         * lib/utimens.c (__attribute__): Likewise.
145453 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
145455         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
145456         reported by Andreas Schwab.
145458 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
145459             Bruno Haible  <bruno@clisp.org>
145461         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
145462         check for the declaration of strnlen and a run test that exposes the
145463         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
145464         rpl_strndup.
145466 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
145467             Bruno Haible  <bruno@clisp.org>
145469         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
145471 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
145473         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
145474         compile test, for Tru64 4.0D.
145476 2006-05-28  Karl Berry  <karl@gnu.org>
145478         * config/srclist.txt (printf-args.c): lose sync.
145480 2006-05-26  Martin Lambers  <marlam@marlam.de>
145482         * lib/getpass.c: Updates the test for the native W32 API, and adds
145483         missing includes, thus fixing compilation warnings.
145485 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
145487         * lib/exclude.c (exclude_fnmatch): New function.
145488         (excluded_file_name): Call exclude_fnmatch.
145489         * lib/exclude.h (excluded_file_name): New prototype
145491 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
145493         * lib/tempname.c (small_open, large_open): New macros.
145494         (__open, __open64) [!_LIBC]: Remove.
145495         (__gen_tempname): Use small_open and large_open instead of __open
145496         and __open64.  This fixes a portability bug on HP-UX 11.11i
145497         reported by Simon Wing-Tang in
145498         <http://lists.gnu.org/r/bug-coreutils/2006-05/msg00114.html>.
145500 2006-05-24  Bruno Haible  <bruno@clisp.org>
145502         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
145503         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
145504         Reported by Thorsten Maerz <torte@netztorte.de> via
145505         Aaron Stone <aaron@serendipity.cx>.
145507 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
145509         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
145510         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
145511         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
145512         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
145513         not really conditional on the cache.
145514         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
145516 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
145518         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
145519         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
145520         (my_usleep): Don't mishandle maximum value.
145522 2006-05-19  Jim Meyering  <jim@meyering.net>
145524         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
145526 2006-05-17  Bruno Haible  <bruno@clisp.org>
145528         Cygwin portability.
145529         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
145531 2006-05-17  Bruno Haible  <bruno@clisp.org>
145533         * lib/stdint_.h: Fix recognition of Cygwin.
145535 2006-05-15  Bruno Haible  <bruno@clisp.org>
145537         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
145538         on libtool patch by Ralf Wildenhues.
145540 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
145542         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
145543         test for C99 conformance; (bool) 0.5 is an integer constant
145544         expression, but (bool) -0.5 is not.  Problem reported by Fedor
145545         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
145547 2006-05-11  Simon Josefsson  <jas@extundo.com>
145549         * m4/xvasprintf.m4: Fix obvious typo.
145551 2006-05-11  Jim Meyering  <jim@meyering.net>
145553         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
145554         James Lemley.
145556 2006-05-10  Simon Josefsson  <jas@extundo.com>
145558         * lib/md4.c: Typo fix, update copyright years.
145559         (K1, K2): Don't use L because it turn computations into 64-bit on
145560         64-bit platforms.
145562 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
145564         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
145565         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
145566         unwanted sign propagation, e.g., on hosts with 64-bit int.
145567         There still are some problems with reeelly weird theoretical hosts
145568         (e.g., 33-bit int) but it's not worth worrying about now.
145569         * lib/sha1.c (rol): Likewise.
145570         (K1, K2, K3, K4): Remove unnecessary L suffix.
145572 2006-05-10  Bruno Haible  <bruno@clisp.org>
145574         * lib/des.c: Cast to avoid warnings.
145576 2006-05-09  Bruno Haible  <bruno@clisp.org>
145578         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
145579         (Depends-on): Depend also on xsize, stdarg.
145580         (configure.ac): Add gl_XVASPRINTF.
145582 2006-05-09  Bruno Haible  <bruno@clisp.org>
145584         * m4/xvasprintf.m4: New file.
145586 2006-05-09  Bruno Haible  <bruno@clisp.org>
145588         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
145589         (EOVERFLOW): Define fallback value.
145590         (xstrcat): New function.
145591         (xvasprintf): Recognize the special case of a string concatenation.
145593 2006-05-08  Eric Blake  <ebb9@byu.net>
145595         * gnulib-tool (func_version): Base copyright year on CVS date.
145596         (func_emit_copyright_notice): New function.
145597         (func_emit_lib_Makefile_am): Use it.
145598         (func_emit_tests_Makefile_am): Likewise.
145599         (func_import): Likewise.
145601 2006-05-08  Bruno Haible  <bruno@clisp.org>
145603         * modules/stdarg: New file.
145604         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
145606 2006-05-08  Bruno Haible  <bruno@clisp.org>
145608         * m4/stdarg.m4: New file, from GNU gettext.
145610 2006-05-08  Bruno Haible  <bruno@clisp.org>
145612         * config/srclist.txt (build-aux/config.rpath): different from latest
145613         release.
145615 2006-05-08  Bruno Haible  <bruno@clisp.org>
145617         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
145619 2006-05-05  Jim Meyering  <jim@meyering.net>
145621         * m4/warning.m4: New file, derived from bison's file by the same name.
145623 2006-05-03  Bruno Haible  <bruno@clisp.org>
145625         * lib/stdint_.h: Shorter URL.
145626         * lib/inttypes.h: Likewise.
145628 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
145630         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
145632 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
145634         * lib/verify.h: Document the internals better.  Most of this change
145635         was written by Bruno Haible.
145637 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
145639         * doc/verify.texi: New file, partly based on a proposal by
145640         Bruno Haible.
145642 2006-05-02  Bruno Haible  <bruno@clisp.org>
145644         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
145645         test from here...
145646         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
145648 2006-04-29  Bruno Haible  <bruno@clisp.org>
145650         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
145651         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
145653 2006-04-29  Bruno Haible  <bruno@clisp.org>
145655         * gnulib-tool: Make --update option actually work.
145657 2006-04-29  Bruno Haible  <bruno@clisp.org>
145659         * doc/gcd.texi: New file.
145660         * doc/gnulib.texi: Include it.
145662 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
145664         * lib/getdate.y (get_date): When adding relative date, start with the
145665         initial time, not with the result of the first mktime call.
145667 2006-04-25  Bruno Haible  <bruno@clisp.org>
145669         * gnulib-tool (func_import): Output the include directives in three
145670         blocks, sorted separately.
145671         Reported by Ben Pfaff <blp@cs.stanford.edu>.
145673 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
145675         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
145676         to define main with arguments, for C++.  Reported by Eric Blake.
145677         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
145678         Prefer 'int main ()' to 'int main (void)', for C++.
145679         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
145680         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
145681         for 'main', for C99 and C++.
145683 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
145685         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
145686         Don't assume that exit status -1 is valid.
145687         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
145688         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
145689         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
145690         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
145691         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
145692         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
145693         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
145694         functions can be used without declaring them, or that you can
145695         exit with status -1.
145696         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
145698 2006-04-24  Karl Berry  <karl@gnu.org>
145700         * config/srclist.txt (longdouble.m4): sync lost.
145702 2006-04-24  Eric Blake  <ebb9@byu.net>
145704         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
145706 2006-04-24  Bruno Haible  <bruno@clisp.org>
145708         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
145709         poll() implementation in AIX.
145710         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
145712 2006-04-24  Bruno Haible  <bruno@clisp.org>
145714         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
145715         assigned exactly once.
145717 2006-04-23  Claudio Fontana  <claudio@gnu.org>
145718             Bruno Haible  <bruno@clisp.org>
145720         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
145721         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
145722         for AM_CPPFLAGS.
145724 2006-04-23  Bruno Haible  <bruno@clisp.org>
145726         * modules/copy-file: Depend on unistd.
145727         * modules/execute: Likewise.
145728         * modules/fatal-signal: Likewise.
145729         * modules/findprog: Likewise.
145730         * modules/mkdtemp : Likewise.
145731         * modules/pipe: Likewise.
145732         * modules/wait-process: Likewise.
145734 2006-04-23  Bruno Haible  <bruno@clisp.org>
145736         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
145737         condition was already detected.
145738         Reported by Ben Pfaff <blp@cs.stanford.edu>.
145740 2006-04-23  Bruno Haible  <bruno@clisp.org>
145742         * lib/copy-file.c: Include <unistd.h> unconditionally.
145743         * lib/execute.c: Likewise.
145744         * lib/fatal-signal.c: Likewise.
145745         * lib/findprog.c: Likewise.
145746         * lib/mkdtemp.c: Likewise.
145747         * lib/pipe.h: Likewise.
145748         * lib/pipe.c: Likewise.
145749         * lib/wait-process.h: Likewise.
145751 2006-04-23  Bruno Haible  <bruno@clisp.org>
145753         * gnulib-tool (func_usage): Fix --import description. Document
145754         --update.
145755         (func_import): Create temporary file in a temporary directory, if
145756         --dry-run is specified. Silence errors from 'grep' when there are no
145757         m4 files in $m4dir.
145758         (func_create_testdir): Silence errors from 'grep' when there are no
145759         m4 files in $m4dir.
145760         Reported by Karl Berry <karl@freefriends.org>.
145762 2006-04-20  Bruno Haible  <bruno@clisp.org>
145764         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
145765         one argument, so that the code will be portable to Autoconf 2.60.
145766         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
145767         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
145768         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
145770 2006-04-19  Derek Price  <derek@ximbiot.com>
145771             Eric Blake  <ebb9@byu.net>
145773         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
145774         rather than "/full/path.h".  Update comment to match.  Shorten &
145775         generalize m4_translit call via AS_TR_CPP.
145777 2006-04-19  Derek Price  <derek@ximbiot.com>
145778             Eric Blake  <ebb9@byu.net>
145780         * lib/inttypes.h: Correct grammar in comment.
145782 2006-04-18  Derek Price  <derek@ximbiot.com>
145783             Paul Eggert  <eggert@cs.ucla.edu>
145785         * modules/inttypes: New file.
145786         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
145788 2006-04-18  Derek Price  <derek@ximbiot.com>
145789             Paul Eggert  <eggert@cs.ucla.edu>
145791         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
145792         New files.
145794 2006-04-18  Derek Price  <derek@ximbiot.com>
145795             Paul Eggert  <eggert@cs.ucla.edu>
145797         * lib/inttypes.h: New file.
145798         * lib/strtoimax.c: Assume <inttypes.h>.
145800 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
145802         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
145803         isn't mounted.  Problem reported by Kir Kolyshkin.
145805 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
145807         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
145808         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
145809         Derek R. Price.
145810         * lib/regex.h (RE_DUP_MAX): Update comment to match current
145811         implementation.
145813 2006-04-12  Eric Blake  <ebb9@byu.net>
145815         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
145816         is now done automatically by the corresponding Autoconf macro.
145818 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
145820         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
145821         time_r.h.
145823 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
145825         Merge regex changes from libc, removing some of our
145826         POSIX-conformance changes that were rejected and redoing them in a
145827         less-intrusive way.
145829         * lib/regcomp.c (re_compile_internal, init_dfa):
145830         Length arg is now size_t, not Idx.  All uses changed.
145831         (peek_token): Forward decl now says internal_function.
145832         (__re_error_msgid, __re_error_msgid_idx):
145833         Now static rather than extern with attribute_hidden.
145834         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
145835         For some reason libc prefers K&R style defns for external functions.
145836         (regerror) [!defined _LIBC]: Likewise.
145837         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
145838         (seek_collating_symbol_entry, lookup_collation_sequence_value):
145839         (build_range_exp, build_collating_symbol):
145840         Use K&R-style defn.
145841         (re_compile_fastmap): Use '\0' to memset, not 0.
145842         (utf8_sb_map): Make the calculations more obvious.
145843         (init_dfa, parse_bracket_exp, build_charclass_op):
145844         Call calloc and cast result, as glibc does.
145845         (init_word_char, fetch_token, peek_token, peek_token_bracket):
145846         (build_range_exp, build_collating_symbol):
145847         Now internal functions.
145849         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
145851         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
145852         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
145853         Don't depend on VMS; depend on __VMS instead, for POSIX
145854         namespace cleanness.
145855         (regoff_t): Define to ssize_t, not long int.
145857         Remove the REG_ macros named below.  Instead, make the old names
145858         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
145859         __USE_GNU_REGEX.
145860         (REG_BACKSLASH_ESCAPE_IN_LISTS):
145861         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
145862         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
145863         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
145864         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
145865         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
145866         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
145867         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
145868         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
145869         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
145870         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
145871         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
145872         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
145873         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
145874         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
145875         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
145876         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
145877         (REG_NREGS):
145878         Remove.  All uses replaced by the old RE_* names.
145879         (RE_BACKSLASH_ESCAPE_IN_LISTS):
145880         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
145881         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
145882         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
145883         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
145884         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
145885         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
145886         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
145887         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
145888         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
145889         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
145890         Don't bother having these macros be independent of each others'
145891         values, since they no longer exist in the POSIX name space.
145893         Rename the following member names back to their old names,
145894         unless !__USE_GNU_REGEX.  All uses changed back.
145895         (buffer): Renamed from re_buffer.
145896         (allocated): Renamed from re_allocated.
145897         (used): Renamed from re_used.
145898         (syntax): Renamed from re_syntax.
145899         (fastmap): Renamed from re_fastmap.
145900         (translate): Renamed from re_translate.
145901         (can_be_null): Renamed from re_can_be_null.
145902         (regs_allocated): Renamed from re_regs_allocated.
145903         (fastmap_accurate): Renamed from re_fastmap_accurate.
145904         (no_sub): Renamed from re_no_sub.
145905         (not_bol): Renamed from re_not_bol.
145906         (not_eol): Renamed from re_not_eol.
145907         (newline_anchor): Renamed from re_newline_anchor.
145908         (num_regs): Renamed from rm_num_regs.
145909         (start): Renamed from rm_start.
145910         (end): Renamed from rm_end.
145912         (free_state): Move up a bit.
145914         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
145915         #define to be empty.
145916         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
145917         when that is what is intended.
145918         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
145919         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
145920         (MAX): New macro.
145921         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
145922         All uses changed back to re_malloc, etc.  It's now the caller's
145923         responsibility to check for overflow; all callers changed.
145924         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
145925         (re_x2nrealloc): Remove.
145926         (free_state): Remove decl.
145928         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
145929         (re_set_registers, re_exec):
145930         Use K&R-style defn.
145932         2006-01-31  Roland McGrath  <roland@redhat.com>
145934         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
145935         Reported by Mike Frysinger <vapier@gentoo.org>.
145937         2006-01-15  Andreas Jaeger  <aj@suse.de>
145939         [BZ #1950]
145940         * lib/regex_internal.c (re_string_reconstruct): Adjust for
145941         build_wcs_upper_buffer change.
145942         (build_wcs_upper_buffer): Change return type.
145944         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
145946         * lib/regex_internal.h: Include <stdint.h> if available.
145948         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
145950         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
145952         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
145954         * lib/regcomp.c: Adjust for changed secondary hash function.
145956         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
145958         * lib/regex.h: Pretty printing.
145959         Clean up namespace a bit.
145961         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
145963         * lib/regexec.c (update_cur_sifted_state, check_arrival,
145964         check_arrival_add_next_nodes): Avoid using uninitialized variable.
145966         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
145967                     Ulrich Drepper  <drepper@redhat.com>
145969         [BZ #1302]
145970         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
145971         changed.
145972         (bitset_word_t): Renamed from bitset_word.  All uses changed.
145974         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
145976         [BZ #281]
145977         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
145978         * lib/regcomp.c: Remove unnecessary uses of
145979         unsigned RE_TRANSLATE_TYPE.
145980         * lib/regex_internal.h: Likewise.
145981         * lib/regex_internal.c: Likewise.
145982         * lib/regexec.c: Likewise.
145983         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
145985         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
145987         * lib/regexec.c (find_recover_state): Remove unnecessary
145988         initialization.
145989         (transit_state_bkref): Make DFA a const pointer.
145990         (get_subexp): Likewise.
145991         (check_arrival): Likewise.
145992         (update_cur_sifted_state): Likewise.
145993         (re_search_internal): Likewise.
145994         (prune_impossible_nodes): Likewise.
145995         (acquire_init_state_context): Likewise.
145996         (proceed_next_node): Likewise.
145997         (set_regs): Likewise.
145998         (free_fail_stack_return): Likewise.
145999         (check_arrival_expand_ecl): Mark DFA parameter as const.
146000         (check_arrival_expand_ecl_sub): Likewise.
146001         (check_subexp_limits): Likewise.
146002         (sub_epsilon_src_nodes):  Likewise.
146003         (add_epsilon_src_nodes):  Likewise.
146004         (merge_state_array): Likewise.
146005         (update_regs): Likewise.
146006         (build_trtable): Likewise.
146007         (sift_states_backward): Mark MCTX parameter as const.
146008         (build_sifted_states): Likewise.
146009         (update_cur_sifted_state): Likewise.
146010         (sift_states_mkref): Likewise.
146011         (check_arrival_expand_ecl): Mark eclosure as const.
146012         (check_dst_limits_calc_pos_1): Likewise.
146013         * lib/regex_internal.h (re_match_context_t): Make dfa a const
146014         pointer.
146016         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
146018         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
146019         (transit_state_sb): Likewise.
146020         (transit_state_mb): Likewise.
146021         (sift_states_iter_mb): Likewise.
146022         (check_arrival_add_next_nodes): Likewise.
146023         (check_node_accept_bytes): Change first parameter to pointer-to-const.
146024         [_LIBC] (re_search_2_stub): Use mempcpy.
146026         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
146027         mbrtowc for very simple UTF-8 case.
146029         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
146030         a pointer-to-const.
146031         (re_acquire_state_context): Likewise.
146032         * lib/regex_internal.h: Adjust prototypes.
146034         * lib/regex.c: Prevent using C++ compilers.
146036         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
146037         (re_acquire_state_context): Likewise.
146039 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
146041         * modules/regex (Depends-on): Add ssize_t.
146043 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
146045         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
146046         translation table.
146048 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
146050         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
146052 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
146053             Bruno Haible  <bruno@clisp.org>
146055         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
146056         <sys/types.h> and <inttypes.h>.
146058 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
146060         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
146061         `__error_t_defined', so argp.h will not typedef the former.
146063 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
146065         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
146066         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
146067         glibc names.  Even if glibc is changed to conform to POSIX, the
146068         traditional names will be available anyway, since regex depends on
146069         the extensions module.  Also, fix a longstanding typo in the
146070         implementation of Spencer ERE test #75 from grep 2.3.  Problems
146071         reported by Emanuele Giaquinta.  Also, change sense of cached
146072         variable, so that the message makes sense.
146074 2006-03-24  Simon Josefsson  <jas@extundo.com>
146076         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
146077         including some doc fixes.
146078         (base64_encode_alloc): Fix +1 bug on allocation failures.
146080 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
146082         * lib/base64.c (base64_encode): Do not read past end of array with
146083         unsanitized input on systems with CHAR_BIT > 8.
146085 2006-03-24  Eric Blake  <ebb9@byu.net>
146087         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
146089 2006-03-22  Karl Berry  <karl@gnu.org>
146091         * config/srclist.txt (*setenv.[ch]): get from coreutils.
146092         * config/srclistvars.sh (COREUTILS): new var.
146094 2006-03-17  Jim Meyering  <jim@meyering.net>
146096         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
146097         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
146099 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
146101         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
146102         no longer needs it.  Instead, check that regoff_t is as least
146103         as wide as ptrdiff_t.
146105         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
146106         so that our regex.h stays compatible with the installed regex.
146107         This is helpful for installers who configure --without-included-regex.
146108         Problem reported by Emanuele Giaquinta.
146110 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
146112         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
146113         Typedef to long int, not to off_, as POSIX will likely change
146114         in that direction.
146116 2006-03-15  Eric Blake  <ebb9@byu.net>
146118         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
146120 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
146122         * lib/argp-help.c (validate_uparams): Fix typo
146123         * lib/argp-parse.c (argp_default_options): Consistently begin help
146124         messages with a lowercase letter.
146126 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
146128         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
146129         overrun buffers and shouldn't be used (much as gets shouldn't be
146130         used).
146131         * lib/time_r.c (asctime_r, ctime_r): Likewise.
146133 2006-03-08  Simon Josefsson  <jas@extundo.com>
146135         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
146136         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
146138 2006-03-08  Simon Josefsson  <jas@extundo.com>
146140         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
146141         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
146143 2006-03-08  Simon Josefsson  <jas@extundo.com>
146145         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
146146         signal that configure disabled the device.
146148 2006-03-08  Simon Josefsson  <jas@extundo.com>
146150         * build-aux/maint.mk: Fix refresh-po, to handle no translated
146151         languages.
146153 2006-03-07  Simon Josefsson  <jas@extundo.com>
146155         * modules/getopt (Depends-on): Add unistd.
146157         * modules/unistd: New file.
146159 2006-03-07  Simon Josefsson  <jas@extundo.com>
146161         * modules/gc-random: New file.
146163 2006-03-07  Simon Josefsson  <jas@extundo.com>
146165         * m4/unistd_h.m4: New file.
146167 2006-03-07  Simon Josefsson  <jas@extundo.com>
146169         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
146170         test to be side-effect free by storing the result in the cache
146171         variable gl_cv_lib_readline, and moving the assignment of
146172         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
146173         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
146175 2006-03-07  Simon Josefsson  <jas@extundo.com>
146177         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
146178         error on missing devices (the functions will return an error).
146180         * m4/gc.m4: Move random stuff to gc-random.m4
146182 2006-03-07  Simon Josefsson  <jas@extundo.com>
146184         * lib/unistd_.h: New file.
146186 2006-03-07  Simon Josefsson  <jas@extundo.com>
146188         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
146190 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
146192         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
146193         Problem reported by Juan Manuel Guerrero.
146195 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
146197         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
146198         the unistd module.
146199         * lib/getlogin_r.c: Likewise.
146200         * lib/getlogin_r.h: Likewise.
146201         * lib/glob.c: Likewise.
146202         * lib/pagealign_alloc.c: Likewise.
146203         * lib/unistd_.h: Remove; no longer needed.
146205 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
146207         * MODULES.html.sh (Support for systems lacking POSIX:2001):
146208         Add unistd.
146209         * modules/c-stack (Depends-on): Add unistd.
146210         * modules/getlogin_r: Likewise.
146211         * modules/glob: Likewise.
146212         * modules/pagealign_alloc: Likewise.
146213         * modules/unistd (Files): Remove lib/unistd_.h.
146214         (EXTRA_DIST): Remove.
146215         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
146216         need unistd_.h.
146217         (MOSTLYCLEANFILES): Remove unistd.h-t.
146219 2006-03-03  Simon Josefsson  <jas@extundo.com>
146221         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
146223 2006-03-03  Simon Josefsson  <jas@extundo.com>
146225         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
146226         libidn and bison.
146228 2006-03-03  Simon Josefsson  <jas@extundo.com>
146230         * build-aux/maint.mk: Add indent target.
146232 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
146234         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
146235         our replacement poll.h in any case, to avoid a differing
146236         declaration from a system header.  Seen on AIX.
146238 2006-03-01  Simon Josefsson  <jas@extundo.com>
146240         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
146241         <kasal@ucw.cz>.
146243 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
146245         * modules/gettime (Depends-on): Add extensions module.
146246         * modules/nanosleep (Depends-on): Likewise.
146247         * modules/settime (Depends-on): Likewise.
146249 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
146251         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
146252         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
146253         pedantically.
146254         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
146255         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
146257         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
146258         not "==".  Reported by Ralf Wildenhues.
146260 2006-03-01  Karl Berry  <karl@gnu.org>
146262         * doc/Copyright/request-*: new files, synced from gnuorg.
146264 2006-03-01  Karl Berry  <karl@gnu.org>
146266         * config/srclist.txt (Copyright/*): new entries.
146268 2006-02-28  Simon Josefsson  <jas@extundo.com>
146270         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
146272 2006-02-27  Simon Josefsson  <jas@extundo.com>
146274         * lib/base64.h: Indent #define's.  From Jim Meyering
146275         <jim@meyering.net>.
146277 2006-02-27  Jim Meyering  <jim@meyering.net>
146279         Revert the change of 2006-02-24, so these files can continue
146280         to be sync'd from gettext.
146281         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
146282         of `config.h'.
146284 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
146286         * modules/intprops: New file.
146287         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
146288         Add intprops.
146289         * modules/getloadavg (Files): Remove lib/intprops.h.
146290         (Depends-on): Add intprops.
146291         * modules/human: Likewise.
146292         * modules/inttostr: Likewise.
146293         * modules/openat: Likewise.
146294         * modules/sig2str: Likewise.
146295         * modules/userspec: Likewise.
146296         * modules/utimecmp: Likewise.
146297         * modules/xnanosleep: Likewise.
146298         * modules/xstrtol: Likewise.
146300 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
146302         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
146303         * modules/lock-tests (TESTS): Use $(EXEEXT).
146304         * modules/tls-tests: Likewise.
146305         * modules/argp-tests: Likewise.
146306         (check_PROGRAMS): New var, replacing...
146307         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
146309 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
146311         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
146312         `config.h'.
146314 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
146316         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
146318 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
146320         Sync from coreutils.
146321         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
146322         gl_CHDIR_SAFER.
146324 2006-02-22  Jim Meyering  <jim@meyering.net>
146326         Sync from coreutils.
146327         * m4/chdir-safer.m4: New file.
146329 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
146331         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
146332         AT_FDCWD exceeds INT_MAX.
146333         * lib/openat.h (AT_FDCWD): Likewise.
146335 2006-02-17  Eric Blake  <address@hidden>
146337         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
146339 2006-02-16  Simon Josefsson  <jas@extundo.com>
146341         * modules/getaddrinfo (Depends-on): Add sys_socket.
146343 2006-02-15  Simon Josefsson  <jas@extundo.com>
146345         * build-aux/maint.mk: Add dsyntax-check rule.
146347 2006-02-15  Eric Blake  <ebb9@byu.net>
146349         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
146350         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
146351         'present but cannot compile' warnings on cygwin.
146352         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
146353         use ws2tcpip.h if sys/socket.h works.
146354         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
146355         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
146357 2006-02-14  Simon Josefsson  <jas@extundo.com>
146359         * modules/maintainer-makefile (Files): Rename.
146361         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
146362         and (the local) Makefile.cfg to maint-cfg.mk.
146364         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
146365         to the latter.
146367         * modules/maintainer-makefile: New module.
146369         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
146370         severaly stripped to make it possible to build it up from scratch
146371         with reliable tests.
146373         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
146374         fixes to permit overriding the default actions when configure and
146375         makefile are not available.
146377 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
146379         Sync from coreutils.
146380         * modules/lstat (Depends-on): Don't depend on xalloc.
146381         (License): Change from GPL to LGPL, since this is now simply a
146382         replacement for a libc function.
146384 2006-02-14  Jim Meyering  <jim@meyering.net>
146386         Sync from coreutils.
146388         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
146389         failure on deficient systems, and simplify gnulib lgpl dependencies.
146390         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
146391         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
146393         * lib/xalloc-die.c: Remove unused definition of N_.
146395 2006-02-14  Jim Meyering  <jim@meyering.net>
146397         Sync from coreutils.
146398         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
146399         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
146400         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
146401         double-quote uses of that variable, to accommodate the rare case in
146402         which getmntent is available in none of the libraries checked.  This
146403         happens at least on FreeBSD 5.0.
146405 2006-02-13  Simon Josefsson  <jas@extundo.com>
146407         * gnulib-tool (Usage): Fix --import, from
146408         karl@freefriends.org (Karl Berry).
146410 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
146412         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
146414 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
146416         * lib/argp-namefrob.h: Restore changes accidentally lost during the
146417         "autoupdate" on 2005-12-12.
146419 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
146421         * modules/closeout (Depends-on): Remove atexit.
146423 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
146425         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
146426         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
146428 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
146430         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
146431         __EXTENSIONS__ if this causes compilation to fail.  Problem
146432         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
146433         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
146435 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
146437         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
146438         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
146439         <http://lists.gnu.org/r/bug-gnulib/2006-01/msg00074.html>.
146440         All uses changed.
146442 2006-01-26  Simon Josefsson  <jas@extundo.com>
146444         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
146445         prototype is visible on mingw32.
146447         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
146448         for mingw32.
146450         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
146451         mingw32).
146453 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
146455         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
146456         attempt to open for write; this always fails, at least on POSIX
146457         hosts.  This reinstates the 2006-01-09 change, which was
146458         inadvertently removed.
146460 2006-01-26  Bruno Haible  <bruno@clisp.org>
146462         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
146463         Reported by Paul Eggert.
146465 2006-01-26  Bruno Haible  <bruno@clisp.org>
146466             Paul Eggert  <eggert@cs.ucla.edu>
146468         * lib/stdbool_.h (_Bool)
146469         [(! (defined __cplusplus || defined __BEOS__)
146470           && !defined __GNUC__
146471           && !(defined __HP_cc || defined __xlc__
146472                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
146473                || defined __sgi))]:
146474         #define to signed char in these cases too; this simplifies
146475         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
146476         etc., separately) and makes it more conservative.
146478 2006-01-25  Simon Josefsson  <jas@extundo.com>
146480         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
146481         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
146482         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
146484 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
146486         * lib/argp-namefrob.h: Bugfix. Remove stray #
146488 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
146490         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
146491         so that we test the test.
146492         Check for yet another HP-UX cc bug involving *bool |= bool.
146494 2006-01-25  Karl Berry  <karl@gnu.org>
146496         * config/srclist.txt (vasnprintf.c): sync lost.
146498 2006-01-25  Jim Meyering  <jim@meyering.net>
146500         Sync from the stable (b5) branch of coreutils:
146502         * lib/fts.c (fts_children): Don't let close() clobber errno from
146503         failed fchdir().
146505         * lib/fts.c (fts_stat): When following a symlink-to-directory,
146506         don't necessarily interpret stat-fails+lstat-succeeds as indicating
146507         a dangling symlink.  That can also happen at least for ELOOP.
146508         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
146509         FYI, this bug predates the inclusion of fts.c in coreutils.
146511         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
146512         in their own block, so pre-c99 compilers don't object.
146514         Avoid the double-free (first in fts_read, second in fts_close) that
146515         would occur when an `active' directory is made inaccessible (e.g.,
146516         via chmod a-x) during a traversal.
146517         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
146518         before returning.  Reproduce this failure by
146519         mkdir -p a/b; cd a; chmod a-x . b
146520         Reported by Stavros Passas.
146522 2006-01-25  Jim Meyering  <jim@meyering.net>
146524         * lib/fileblocks.c: Remove more useless parentheses.
146525         * lib/readutmp.h: Likewise.
146527 2006-01-25  Bruno Haible  <bruno@clisp.org>
146529         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
146530         warnings.
146531         Reported by Paul Eggert.
146533 2006-01-25  Bruno Haible  <bruno@clisp.org>
146535         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
146536         rid of a trap command. For Solaris sh.
146537         Reported by Mark D. Baushke <mdb@gnu.org>.
146539 2006-01-24  Simon Josefsson  <jas@extundo.com>
146541         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
146542         Bruno.
146544 2006-01-24  Karl Berry  <karl@gnu.org>
146546         * config/srclist.txt (argp-namefrob.h): sync lost.
146548 2006-01-24  Jim Meyering  <jim@meyering.net>
146550         * modules/openat (Files): Add lib/intprops.h.
146551         From Mark D. Baushke.
146553 2006-01-24  Jim Meyering  <jim@meyering.net>
146555         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
146556         Reported by Mark D. Baushke.
146558 2006-01-24  Jim Meyering  <jim@meyering.net>
146560         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
146562 2006-01-24  Bruno Haible  <bruno@clisp.org>
146564         * modules/strnlen (Maintainer): Change from glibc to all.
146566 2006-01-24  Bruno Haible  <bruno@clisp.org>
146568         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
146569         Patch by Paul Eggert.
146571 2006-01-24  Bruno Haible  <bruno@clisp.org>
146573         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
146574         already has it.
146575         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
146576         2005-11-26.
146578         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
146579         'signed char' to avoid problems with the built-in _Bool type.
146580         Reported by Paul Eggert on 2005-11-26.
146582 2006-01-24  Bruno Haible  <bruno@clisp.org>
146584         * gnulib-tool (func_import): Avoid constructing complicated sed
146585         expressions inside backquote.
146586         Report and solution by Mark D. Baushke <mdb@gnu.org>.
146588 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
146590         These changes imported from libc.
146591         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
146592         test and two separate function calls.
146593         * lib/strndup.c (__strndup): Add libc_hidden_def.
146595 2006-01-23  Simon Josefsson  <jas@extundo.com>
146597         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
146598         Remove the test_*_SOURCES variable: automake infers it by default.
146599         * modules/tls-tests: Likewise.
146601 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
146603         Work around porting bugs reported by Dieter in
146604         <http://lists.gnu.org/r/bug-bison/2006-01/msg00049.html>.
146605         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
146606         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
146607         Include "getopt.h" first, to check interface.
146608         (getenv): Declare only if defined HAVE_DECL_GETENV &&
146609         !HAVE_DECL_GETENV.
146610         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
146611         (__strndup): Revert to K&R-style function dfns, the glibc style.
146612         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
146613         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
146614         Include strnlen.h first, to get prototype properly.
146615         (strnlen): Renamed from __strnlen.
146616         Remove weak alias.
146618 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
146620         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
146622 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
146624         * config/srclist.txt: Adjust to reflect glibc reorganization.
146625         This affects only comments.
146627 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
146629          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
146630          Reported by Bruce Korb <bkorb@gnu.org>.
146632 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
146634         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
146635         to pacify gcc -Wswitch-default.
146637 2006-01-22  Bruno Haible  <bruno@clisp.org>
146639         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
146640         temporary buffer for sprintf, take into account the precision also
146641         for 'd', 'i', 'u', 'o', 'x', 'X'.
146643 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
146645         * modules/argp-tests: New module
146646         * tests/test-argp.c: New file
146647         * tests/test-argp-2.sh: New file
146649 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
146651         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
146652         (__argp_base_name): Removed
146653         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
146654         typo.
146655         (__argp_base_name): Provide macro definition or extern declaration
146656         depending on the configuration
146658 2006-01-20  Simon Josefsson  <jas@extundo.com>
146660         * modules/inet_ntop (Depends-on): Depend on sys_socket.
146662 2006-01-20  Simon Josefsson  <jas@extundo.com>
146664         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
146666 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
146668         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
146669         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
146670         Suggested by Bruno Haible.
146672 2006-01-20  Karl Berry  <karl@gnu.org>
146674         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
146675         until changes propagate, I guess.
146677 2006-01-19  Simon Josefsson  <jas@extundo.com>
146679         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
146681 2006-01-19  Simon Josefsson  <jas@extundo.com>
146683         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
146685 2006-01-19  Simon Josefsson  <jas@extundo.com>
146687         * gnulib-tool: Set check_PROGRAMS.
146689         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
146690         modules/des-tests, modules/gc-arcfour-tests,
146691         modules/gc-arctwo-tests, modules/gc-des-tests,
146692         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
146693         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
146694         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
146695         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
146696         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
146697         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
146698         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
146699         test_*_SOURCES.
146701 2006-01-18  Simon Josefsson  <jas@extundo.com>
146703         * modules/socklen (Depends-on): Depend on sys_socket.
146705 2006-01-18  Simon Josefsson  <jas@extundo.com>
146707         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
146708         modules/des-tests, modules/gc-arcfour-tests,
146709         modules/gc-arctwo-tests, modules/gc-des-tests,
146710         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
146711         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
146712         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
146713         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
146714         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
146715         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
146716         $(EXEEXT) to automake TESTS variable, for mingw32.
146718 2006-01-17  Simon Josefsson  <jas@extundo.com>
146720         * modules/socklen (Include): Need sys/socket.h.
146722 2006-01-17  Bruno Haible  <bruno@clisp.org>
146724         * modules/ssize_t (Include): Add <sys/types.h>.
146726 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
146728         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
146729         it's not portable and it doesn't work with cross-compiles.
146730         Problem reported by Bruno Haible.  Fix missing-$ typo in
146731         'test "gl_cv_ignore_unused_libraries" ...' that prevented
146732         -zignore from being used with Sun's C compiler.
146734 2006-01-12  Simon Josefsson  <jas@extundo.com>
146736         * lib/base64.c: Fix warning, reported by Bruno Haible
146737         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
146739 2006-01-12  Bruno Haible  <bruno@clisp.org>
146741         * modules/ldd: New file.
146742         * build-aux/ldd.sh.in: New file.
146743         * MODULES.html.sh (Support for building libraries and executables): Add
146744         ldd.
146746 2006-01-12  Bruno Haible  <bruno@clisp.org>
146748         * m4/ldd.m4: New file.
146750 2006-01-12  Bruno Haible  <bruno@clisp.org>
146752         * gnulib-tool (func_import, func_create_testdir): Don't go into an
146753         endless loop while replacing $auxdir with build-aux.
146755 2006-01-11  Simon Josefsson  <jas@extundo.com>
146757         * lib/stdint_.h (SIZE_MAX): Add missing (.
146759 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
146761         Sync from coreutils.
146762         * lib/md5.c: Fix commentary typos.
146763         (alignof, UNALIGNED_P): No need for a GCC-specific version.
146764         * lib/md5.h (__attribute__): Remove; unused.
146765         * lib/sha1.c: Fix commentary to match md5 better.
146766         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
146767         so that we don't need to worry about alignment.  All uses changed.
146768         This merges the 2005-10-28 md5 change into sha1.
146770 2006-01-11  Jim Meyering  <jim@meyering.net>
146772         Sync from coreutils.
146773         * lib/md5.c (OP): Fix spacing.
146775 2006-01-11  Bruno Haible  <bruno@clisp.org>
146777         Ensure automatic ordering between gl_LOCK and gl_ARGP.
146778         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
146779         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
146781 2006-01-11  Bruno Haible  <bruno@clisp.org>
146783         Ensure automatic ordering between gl_LOCK and gl_ARGP.
146784         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
146785         the "early" section as well.
146787 2006-01-11  Bruno Haible  <bruno@clisp.org>
146789         Avoid "ar: no archive members specified" error on MacOS X.
146790         * gnulib-tool (func_modules_add_dummy): New function.
146791         (func_import, func_create_testdir): Invoke it.
146793 2006-01-11  Bruno Haible  <bruno@clisp.org>
146795         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
146796         with $auxdir in AC_CONFIG_FILES statements.
146798 2006-01-11  Bruno Haible  <bruno@clisp.org>
146800         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
146801         Initialize also noinst_HEADERS to empty.
146803 2006-01-11  Bruno Haible  <bruno@clisp.org>
146805         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
146806         variables.
146807         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
146808         autoreconf.
146810 2006-01-11  Bruno Haible  <bruno@clisp.org>
146812         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
146813         overridable by the user.
146814         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
146816 2006-01-10  Simon Josefsson  <jas@extundo.com>
146818         * modules/sys_socket: New file.
146820 2006-01-10  Simon Josefsson  <jas@extundo.com>
146822         * m4/sys_socket_h.m4: New file.
146824 2006-01-10  Simon Josefsson  <jas@extundo.com>
146826         * lib/socket_.h: New file.
146828 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
146830         * modules/readutmp (Maintainer): Add myself.
146832 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
146834         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
146835         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
146836         People who are still concerned with buggy memcmp implementations
146837         can invoke gl_FUNC_MEMCMP themselves.
146839 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
146841         * lib/regex_internal.h (BITSET_WORD_BITS):
146842         Work around a bug in 64-bit PGC (before version 6.1-2), where the
146843         preprocessor mishandles large unsigned values as if they were signed.
146844         Problem reported by Claudio Fontana in
146845         <http://lists.gnu.org/r/bug-gnulib/2005-12/msg00061.html>.
146847 2006-01-10  Jim Meyering  <jim@meyering.net>
146849         Avoid the double-free (first in fts_read, second in fts_close) that
146850         would occur when an `active' directory is made inaccessible (e.g.,
146851         via chmod a-x) during a traversal.
146852         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
146853         before returning.  Reproduce this failure by
146854         mkdir -p a/b; cd a; chmod a-x . b
146855         Reported by Stavros Passas.
146857         Sync from coreutils.
146858         * lib/sha1.c: Tweak grammar in a comment.
146860 2006-01-10  Jim Meyering  <jim@meyering.net>
146862         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
146863         Patch by Joerg Sonnenberger.
146865 2006-01-10  Bruno Haible  <bruno@clisp.org>
146867         * modules/readutmp: Depend on module free.
146868         * modules/strtok_r: Depend on module restrict.
146870 2006-01-10  Bruno Haible  <bruno@clisp.org>
146872         * modules/gettext (configure.ac): Add an invocation of
146873         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
146875 2006-01-10  Bruno Haible  <bruno@clisp.org>
146877         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
146878         Reported by Werner Lemberg <wl@gnu.org>.
146880 2006-01-10  Bruno Haible  <bruno@clisp.org>
146882         * lib/localcharset.c: Update from GNU gettext.
146884 2006-01-10  Bruno Haible  <bruno@clisp.org>
146886         * lib/argp.h (__const): Remove macro. Use const instead.
146887         * lib/argp-fmtstream.h (__const): Likewise.
146888         * lib/glob_.h (__const): Remove macro.
146889         * lib/glob-libc.h: Use const instead of __const.
146891 2006-01-10  Bruno Haible  <bruno@clisp.org>
146893         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
146894         variable.
146895         Needed to avoid an automake error regarding the 'gettext' module.
146897 2006-01-09  Simon Josefsson  <jas@extundo.com>
146899         * modules/inet_ntop (Depends-on): Add restrict.
146901 2006-01-09  Simon Josefsson  <jas@extundo.com>
146903         * modules/gc-rijndael-tests (License): Put under LGPL.
146905         * modules/gc-des-tests (License): Likewise.
146907         * modules/gc-arcfour-tests (License): Likewise.
146909         * modules/gc-arctwo-tests (License): Likewise.
146911         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
146913         * modules/gc-hmac-sha1-tests (Files): Likewise.
146915         * modules/gc-hmac-md5-tests (License): Likewise.
146917         * modules/gc-sha1-tests (License): Likewise.
146919         * modules/gc-md5-tests (License): Likewise.
146921         * modules/gc-md4-tests (License): Likewise.
146923         * modules/gc-md2-tests (License): Likewise.
146925         * modules/gc-tests (License): Likewise.
146927         * modules/des-tests (License): Likewise.
146929         * modules/md4-tests (License): Likewise.
146931         * modules/md2-tests (License): Likewise.
146933 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
146935         Sync from coreutils:
146937         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
146938         * modules/lib-ignore: New file.
146939         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
146940         chdir-safer.m4, lchmod.m4.
146941         * modules/openat: Add mkdirat.c, openat-priv.h.
146943 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
146945         Sync from coreutils.
146946         * m4/lib-ignore.m4: New file.
146947         * m4/lchmod.m4: New file.
146949 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
146951         Sync from coreutils.
146952         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
146953         for write access: POSIX says that must fail.
146954         * lib/fts.c (diropen): Likewise.
146955         * lib/save-cwd.c (save_cwd): Likewise.
146956         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
146957         well, for minor improvements on hosts that lack O_DIRECTORY.
146958         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
146959         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
146960         Fall back on chown if open failed with EACCES.
146962         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
146963         Report an error at compile-time if only a 1-second nominal clock
146964         resolution is found.
146966         * lib/lchmod.h: New file.
146967         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
146968         (make_dir_parents): Use lchown rather than chown, and
146969         lchmod rather than chmod.
146971         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
146972         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
146973         "proc" reported by n0dalus.
146975         * lib/mountlist.c: Include <limits.h>.
146976         (dev_from_mount_options)
146977         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
146978         New function.  It no longer assumes "dev=" has the System V meaning
146979         on Linux (since it doesn't).  It also parses "dev=" more carefully.
146980         (read_file_system_list)
146981         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
146982         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
146983         dev= in that case.
146985         * lib/posixtm.h (PDS_PRE_2000): New macro.
146986         * lib/posixtm.c (year): Arg is now syntax_bits rather than
146987         allow_century.  All usages changed.  Reject dates outside the range
146988         1969-1999 if PDS_PRE_2000 is used.
146990 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
146992         Sync from coreutils.
146993         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
146994         (Time of day items): Mention the possibility of leap seconds.
146995         Problem reported by Dr. David Alan Gilbert.
146997 2006-01-09  Jim Meyering  <jim@meyering.net>
146999         Sync from coreutils.
147001         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
147003         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
147005         * lib/modechange.c (mode_compile): Reject an invalid mode string
147006         that starts with an octal digit.  From Andreas Gruenbacher.
147008         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
147009         and dup to open_safer and dup_safer, respectively.
147010         (openat_permissive): Fix typo in comment.
147012         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
147013         "gettext.h"; either no longer needed or are guaranteed by openat.h.
147014         (_): Remove; no longer needed.
147015         (openat): Renamed from rpl_openat; no need for rpl_openat
147016         since openat.h renames openat for us.
147017         Replace most of the body with a call to openat_permissive,
147018         to avoid duplicate code.
147019         Port to (probably hypothetical) environments were mode_t is
147020         wider than int.
147021         (openat_permissive): Require mode arg, so that we can check
147022         types better.  Put it just after flags.  Change cwd failure
147023         indicator from pointer-to-bool to pointer-to-errno-value.
147024         All callers changed.
147025         Invoke openat_save_fail and/or openat_restore_fail if
147026         cwd_errno is null, so that openat can call us.
147027         (openat_permissive, fdopendir, fstatat, unlinkat):
147028         Simplify errno handling to avoid some duplicate code,
147029         as it's OK to set errno on success.
147030         * lib/openat.h: Revamp code so that function macros depend on
147031         __OPENAT_PREFIX only, not also on AT_FDCWD.
147032         (openat_ro): Remove.  Caller changed to use openat_permissive.
147033         (openat_permissive): Now a macro, if not a function.
147034         (openat_restore_fail, openat_save_fail): Now always functions,
147035         since mkdirat needs them even if __OPENAT_PREFIX is defined.
147037         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
147038         and openat.c.
147039         * lib/mkdirat.c: Include openat-priv.h.
147040         Remove definitions of macros defined therein.
147041         * lib/openat.c: Likewise.
147043         * lib/mkdirat.c (mkdirat): New file and function.
147044         * lib/openat.h (mkdirat): Declare.
147046         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
147048         * lib/openat.h (openat_permissive): Declare.
147049         (openat_ro): Define.
147051         * lib/openat.c (EXPECTED_ERRNO): New macro.
147052         (openat_permissive): New function -- used in remove.c rewrite.
147053         (all functions): Set errno just before returning, only if there
147054         was an actual failure.
147055         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
147057         Emulate openat-family functions using Linux's procfs, if possible.
147058         Idea and some code based on Ulrich Drepper's glibc changes.
147060         * lib/openat.c: (BUILD_PROC_NAME): New macro.
147061         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
147062         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
147063         before falling back on save_cwd and restore_cwd.
147064         (fdopendir, fstatat, unlinkat): Likewise.
147066         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
147067         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
147069         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
147070         as second argument to va_arg.  Otherwise, some versions of gcc
147071         warn that `if this code is reached, the program will abort'.
147073 2006-01-09  Jim Meyering  <jim@meyering.net>
147075         Sync from coreutils.
147076         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
147077         Require openat-priv.h.
147079 2006-01-09  Bruno Haible  <bruno@clisp.org>
147081         * modules/strnlen (Include): Use strnlen.h.
147083 2006-01-09  Bruno Haible  <bruno@clisp.org>
147085         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
147087 2006-01-09  Bruno Haible  <bruno@clisp.org>
147089         * lib/sysexit_.h (EX_OK): New macro.
147090         Suggested by Martin Lambers <marlam@marlam.de>.
147092 2006-01-09  Bruno Haible  <bruno@clisp.org>
147094         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
147095         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
147097 2006-01-09  Bruno Haible  <bruno@clisp.org>
147099         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
147100         numbers.
147102 2006-01-09  Bruno Haible  <bruno@clisp.org>
147104         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
147105         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
147106         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
147107         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
147109 2006-01-09  Bruno Haible  <bruno@clisp.org>
147111         * build-aux/javacomp.sh.in: New file, moved from lib/.
147112         * modules/javacomp-script (Files): Update.
147113         (configure.ac): Add AC_CONFIG_FILES invocation.
147114         (EXTRA_DIST): Remove variable.
147116         * build-aux/javaexec.sh.in: New file, moved from lib/.
147117         * modules/javaexec (Files): Update.
147118         (configure.ac): Add AC_CONFIG_FILES invocation.
147119         (EXTRA_DIST): Remove javaexec.sh.in.
147121         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
147122         * modules/csharpcomp-script (Files): Update.
147123         (configure.ac): Add AC_CONFIG_FILES invocation.
147124         (EXTRA_DIST): Remove variable.
147126         * build-aux/csharpexec.sh.in: New file, moved from lib/.
147127         * modules/csharpexec (Files): Update.
147128         (configure.ac): Add AC_CONFIG_FILES invocation.
147129         (EXTRA_DIST): Remove csharpexec.sh.in.
147131 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
147133         Sync from coreutils.
147135         Add POSIX ACL support
147136         * lib/acl.h (copy_acl, set_acl): Add declarations.
147137         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
147138         systems other than Linux.
147139         (chmod_or_fchmod): New function: use fchmod when possible,
147140         and chmod otherwise.
147141         (file_has_acl): Add a POSIX ACL implementation, with a
147142         Linux-specific subcase.
147143         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
147144         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
147145         acls are unsupported.
147146         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
147147         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
147148         are unsupported.
147150 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
147152         Sync from coreutils.
147153         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
147155 2006-01-07  Bruno Haible  <bruno@clisp.org>
147157         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
147158         gl_EARLY.
147160 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
147162         * lib/strftime.c (tzname): Don't declare if it is already #defined.
147163         Problem reported for Mingw by Mark Junker.
147165 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
147167         * README: Gnulib normally doesn't generate a tarball.
147169 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
147171         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
147172         long int, not int, for nanosecond counts, so that people who are
147173         used to POSIX struct timespec won't be surprised.  Reported by Jim
147174         Meyering.
147176 2005-12-28  Bruno Haible  <bruno@clisp.org>
147178         * build-aux/config.rpath: Update from GNU gettext.
147180 2005-12-16  Jim Meyering  <jim@meyering.net>
147182         * modules/fprintftime: New module.
147183         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
147185 2005-12-16  Jim Meyering  <jim@meyering.net>
147187         * m4/fprintftime.m4: New file.
147189 2005-12-16  Jim Meyering  <jim@meyering.net>
147191         * lib/fprintftime.c, lib/fprintftime.h: New files.
147193 2005-12-15  Simon Josefsson  <jas@extundo.com>
147195         * modules/socklen (configure.ac): Fix M4 macro name, to align with
147196         new m4/socklen.m4.
147198 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
147200         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
147201         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
147203 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
147205         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
147206         * lib/argp-help.c (fill_in_uparams): Check if the constructed
147207         struct uparams is valid. Fall back to the default values if it is
147208         not.
147210 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
147212         * modules/argp (Files): Add argp-pin.c
147213         (Depends-on): dirname
147214         (lib_SOURCES): Add argp-pin.c
147216 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
147218         * m4/argp.m4:  Check if program_invocation_name and
147219         program_invocation_short_name are declared and define appropriate
147220         macros if they are not.
147222 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
147224         * lib/argp-help.c (__argp_base_name): New function
147225         (__argp_short_program_name): Rewrite using __argp_base_name
147226         * lib/argp-namefrob.h: Define program_invocation_name and
147227         program_invocation_short_name if requested
147228         (__argp_base_name): Add prototype
147229         * lib/argp-parse.c (argp_def): Use gettext wrappers
147230         (argp_default_parser): Use __argp_base_name
147231         * lib/argp-pin.c: New file. Defines program_invocation_name and
147232         program_invocation_short_name on systems that lack them.
147234 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
147236         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
147237         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
147238         porting problem reported by Georg Schwarz in
147239         <http://lists.gnu.org/r/bug-coreutils/2005-12/msg00083.html>.
147241 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
147243         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
147244         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
147245         porting problem reported by Georg Schwarz in
147246         <http://lists.gnu.org/r/bug-coreutils/2005-12/msg00083.html>.
147248 2005-12-05  Bruno Haible  <bruno@clisp.org>
147250         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
147251         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
147252         Reported by Mark Junker <mjscod@gmx.de>.
147254 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
147256         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
147257         Use implementation from Albert Chin, with some
147258         comments/corrections by Stepan Kasal and myself.
147260 2005-12-02  Bruno Haible  <bruno@clisp.org>
147262         * gnulib-tool (func_import): Accept GPLed build tool modules when
147263         --lgpl is given.
147264         * modules/csharpcomp-script: New file.
147265         * modules/csharpcomp: Depend on it.
147266         * modules/javacomp-script: New file.
147267         * modules/javacomp: Depend on it.
147268         Suggested by Simon Josefsson.
147270 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
147272         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
147273         statement, to work around an HP-UX 10.20 compiler bug reported by
147274         Peter O'Gorman.
147276 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
147278         * modules/savedir (Depends-on): Add openat.
147280 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
147282         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
147283         (uintmax_t) [defined uintmax_t]: Do not declare.
147284         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
147285         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
147286         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
147287         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
147288         sake of portability to weird hosts that C allows (though we don't
147289         know of any practical examples).
147291         * lib/savedir.h (fdsavedir): New decl.
147292         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
147293         contains most of the former guts of savedir.
147294         (savedir): Use savedirstream.
147295         Include "openat.h".
147297 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
147299         * modules/obstack (Files): Add m4/ulonglong.m4.
147300         Problem reported by Davide Angelocola.
147302 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
147304         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
147305         coreutils no longer futzes with rounding modes.
147307 2005-11-14  Jim Meyering  <jim@meyering.net>
147309         * lib/mkstemp-safer.c: Include <config.h>, required for possible
147310         replacement of mkstemp.
147312 2005-11-10  Simon Josefsson  <jas@extundo.com>
147314         * lib/readline.c: Remove EOL.
147316 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
147318         * modules/gethrxtime (Depends-on): Add gettime.
147320 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
147322         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
147323         or gettimeofday; no longer needed.
147325 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
147327         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
147328         time business.
147329         (gethrxtime) [! (HAVE_NANOUPTIME
147330         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
147331         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
147332         our own approximation.
147334 2005-11-08  Eric Blake  <ebb9@byu.net>
147336         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
147338 2005-11-08  Eric Blake  <ebb9@byu.net>
147340         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
147342 2005-11-04  Bruno Haible  <bruno@clisp.org>
147344         * gnulib-tool: Implement --update mode.
147346 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
147348         Fix porting problem reported by Theodoros V. Kalamatianos.
147349         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
147350         Don't assume that futimes failing means we must fail.
147352 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
147354         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
147355         variables to suggest the intended function of the PATH_MAX check.
147357 2005-10-30  Kean Johnston  <jkj@sco.com>
147359         Trivial changes to support SCO systems.
147360         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
147361         as PATH_MAX.
147362         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
147363         where __ptr is null when no I/O is pending.
147365 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
147367         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
147368         leave errno alone.  Problem reported by Dmitry V. Levin.
147370 2005-10-28  Simon Josefsson  <jas@extundo.com>
147372         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
147373         Test more.
147375         * tests/test-gc-md2.c, tests/test-md2.c: New files.
147377         * modules/md2, modules/md2-tests: New files.
147379 2005-10-28  Simon Josefsson  <jas@extundo.com>
147381         * m4/inet_ntop.m4: More tests.
147383         * m4/gc-md2.m4, md2.m4: New file.
147385 2005-10-28  Simon Josefsson  <jas@extundo.com>
147387         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
147388         "restrict" keywords, as per POSIX.  Protect the function
147389         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
147390         Don't use K&R prototypes.  Check the sprintf return values.
147391         Re-define EAFNOSUPPORT if not present.  Indent.
147393         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
147394         suggested by Bruno Haible <bruno@clisp.org>.
147396         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
147398         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
147400         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
147401         libgcrypt).
147403         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
147405         * lib/md2.h, lib/md2.c: New files.
147407 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
147409         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
147410         errno alone.  Problem reported by Frederic Jolliton.
147412 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
147414         * modules/verify (License): Change from GPL to LGPL.  This is a
147415         tiny module and there are apparently near-equivalents that are
147416         under the BSD license.
147418 2005-10-24  Simon Josefsson  <jas@extundo.com>
147420         * modules/sha1: Relicense to LGPL.
147422 2005-10-24  Simon Josefsson  <jas@extundo.com>
147424         * lib/md4.h: Shrink buffer size, now that we changed the type.
147426 2005-10-23  Simon Josefsson  <jas@extundo.com>
147428         * gnulib-tool (func_import): Fix --tests-base.
147430 2005-10-22  Simon Josefsson  <jas@extundo.com>
147432         * modules/arcfour (Depends-on): Need stdint.
147434 2005-10-22  Simon Josefsson  <jas@extundo.com>
147436         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
147437         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
147439 2005-10-22  Simon Josefsson  <jas@extundo.com>
147441         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
147442         suggested by Bruno Haible <bruno@clisp.org>.
147444 2005-10-22  Simon Josefsson  <jas@extundo.com>
147446         * lib/crc.h: Include stddef.h, for size_t.
147448 2005-10-22  Simon Josefsson  <jas@extundo.com>
147450         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
147451         arcfour_context struct (simplify test vector testing in GNU
147452         Shishi).
147454 2005-10-21  Simon Josefsson  <jas@extundo.com>
147456         * modules/des, modules/des-tests: New files.
147458         * modules/gc-des, modules/gc-des-tests: New files.
147460         * tests/test-des.c, tests/test-gc-des.c: New file.
147462 2005-10-21  Simon Josefsson  <jas@extundo.com>
147464         * modules/arctwo, modules/arctwo-tests: New files.
147466         * tests/test-arctwo.c: New file.
147468         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
147470         * tests/test-gc-arctwo.c: New file.
147472 2005-10-21  Simon Josefsson  <jas@extundo.com>
147474         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
147475         Bruno Haible <bruno@clisp.org>.
147477         * m4/gc-des.m4: New file.
147479 2005-10-21  Simon Josefsson  <jas@extundo.com>
147481         * m4/arctwo.m4: New file.
147483         * m4/gc-arctwo.m4: New file.
147485 2005-10-21  Simon Josefsson  <jas@extundo.com>
147487         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
147488         block.
147490 2005-10-21  Simon Josefsson  <jas@extundo.com>
147492         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
147493         <bruno@clisp.org>.
147495         * lib/hmac-sha1.c (hmac_sha1): Likewise.
147497         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
147498         Bruno Haible <bruno@clisp.org>.
147500         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
147501         <bruno@clisp.org>.
147503 2005-10-21  Simon Josefsson  <jas@extundo.com>
147505         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
147507 2005-10-21  Simon Josefsson  <jas@extundo.com>
147509         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
147511 2005-10-21  Simon Josefsson  <jas@extundo.com>
147513         * lib/des.h, lib/des.c: New files.
147515         * lib/gc-gnulib.c: Support DES.c
147517 2005-10-21  Simon Josefsson  <jas@extundo.com>
147519         * lib/arctwo.h, lib/arctwo.c: New files.
147521         * lib/gc-gnulib.c: Support ARCTWO.
147523 2005-10-21  Simon Josefsson  <jas@extundo.com>
147525         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
147526         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
147528 2005-10-21  Simon Josefsson  <jas@extundo.com>
147530         * gnulib-tool (func_import, func_create_testdir): Define automake
147531         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
147532         Makefile.am snippet),
147533         suggested by Bruno Haible <bruno@clisp.org>.
147535         * modules/gc (Makefile.am): Use it.
147537 2005-10-21  Bruno Haible  <bruno@clisp.org>
147539         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
147540         patch.
147542 2005-10-19  Simon Josefsson  <jas@extundo.com>
147544         * tests/test-gc-rijndael.c: New file.
147546         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
147548 2005-10-19  Simon Josefsson  <jas@extundo.com>
147550         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
147551         interface too.
147553 2005-10-19  Simon Josefsson  <jas@extundo.com>
147555         * tests/test-gc-arcfour.c: New file.
147557         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
147559 2005-10-19  Simon Josefsson  <jas@extundo.com>
147561         * modules/gc-md4, modules/gc-md4-tests: New file.
147563         * tests/test-gc-md4.c: New file.
147565 2005-10-19  Simon Josefsson  <jas@extundo.com>
147567         * m4/gc-md4.m4: New file.
147569 2005-10-19  Simon Josefsson  <jas@extundo.com>
147571         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
147572         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
147573         <kasal@ucw.cz>.
147575 2005-10-19  Simon Josefsson  <jas@extundo.com>
147577         * m4/gc-arcfour.m4: New file.
147579         * m4/gc-rijndael.m4: New file.
147581 2005-10-19  Simon Josefsson  <jas@extundo.com>
147583         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
147585 2005-10-19  Simon Josefsson  <jas@extundo.com>
147587         * lib/gc-gnulib.c: Support ARCFOUR.
147589 2005-10-19  Simon Josefsson  <jas@extundo.com>
147591         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
147592         support.
147594         * lib/gc.h: Add ECB enum type.
147596         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
147598 2005-10-18  Simon Josefsson  <jas@extundo.com>
147600         * tests/test-md5.c: New file.
147602         * modules/md5-tests: New file.
147604 2005-10-18  Simon Josefsson  <jas@extundo.com>
147606         * tests/test-md4.c: New file.
147608         * modules/md4, modules/md4-tests: New files.
147610 2005-10-18  Simon Josefsson  <jas@extundo.com>
147612         * m4/md4.m4: New file.
147614 2005-10-18  Simon Josefsson  <jas@extundo.com>
147616         * lib/md4.h, lib/md4.c: New files, based on md5.?.
147618 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
147620         * gnulib-tool (func_create_testdir): Omit the second check whether
147621         BUILT_SOURCES in nonempty.
147623 2005-10-17  Simon Josefsson  <jas@extundo.com>
147625         * tests/test-rijndael.c: New file.
147627 2005-10-17  Simon Josefsson  <jas@extundo.com>
147629         * modules/sha1: Depend on stdint instead of md5.
147631         * modules/md5: Depend on stdint, remove uint32_t.
147633 2005-10-17  Simon Josefsson  <jas@extundo.com>
147635         * modules/gc-sha1-tests: New file.
147637         * tests/test-gc-sha1.c: New file.
147639 2005-10-17  Simon Josefsson  <jas@extundo.com>
147641         * m4/md5.m4: Remove call to uint32_t.m4.
147643 2005-10-17  Simon Josefsson  <jas@extundo.com>
147645         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
147647         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
147648         md5.h.
147650         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
147652         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
147654 2005-10-17  Simon Josefsson  <jas@extundo.com>
147656         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
147658 2005-10-17  Simon Josefsson  <jas@extundo.com>
147660         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
147662 2005-10-17  Simon Josefsson  <jas@extundo.com>
147664         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
147666         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
147668 2005-10-17  Bruno Haible  <bruno@clisp.org>
147670         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
147671         that it can also be used in a test.
147673 2005-10-16  Bruno Haible  <bruno@clisp.org>
147675         * gnulib-tool (func_emit_tests_Makefile_am): Also define
147676         TESTS_ENVIRONMENT, so that individual tests can augment it.
147678         * gnulib-tool (func_create_testdir): Use an intermediate target for
147679         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
147680         macros, like $(ALLOCA_H), which cannot be passed through the command
147681         line.
147683 2005-10-15  Simon Josefsson  <jas@extundo.com>
147685         * modules/rijndael-tests: New file.
147687         * modules/rijndael: New file.
147689 2005-10-15  Simon Josefsson  <jas@extundo.com>
147691         * m4/rijndael.m4: New file.
147693 2005-10-15  Simon Josefsson  <jas@extundo.com>
147695         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
147697         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
147699 2005-10-14  Simon Josefsson  <jas@extundo.com>
147701         * tests/test-arcfour.c: New file.
147703         * modules/arcfour, modules/arcfour-tests: New files.
147705 2005-10-14  Simon Josefsson  <jas@extundo.com>
147707         * m4/arcfour.m4: New file.
147709 2005-10-14  Simon Josefsson  <jas@extundo.com>
147711         * lib/arcfour.h, lib/arcfour.c: New files.
147713 2005-10-14  Roland McGrath  <roland@redhat.com>
147715         Import from libc.  [BZ #1331]
147716         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
147717         macro argument.
147718         Reported by Matej Vela <vela@debian.org>.
147720 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
147722         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
147723         include <wchar.h>; no longer needed.
147725 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
147727         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
147729 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
147730         and  Ulrich Drepper  <drepper@redhat.com>
147732         Import from libc.
147733         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
147734         instead of inline stream orientation test and two separate
147735         function calls.  Pay no attention to USE_IN_LIBIO.
147737 2005-10-13  Simon Josefsson  <jas@extundo.com>
147739         * modules/gc-hmac-md5-tests: New file.
147741         * tests/test-gc-hmac-sha1.c: New file.
147743         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
147745         * modules/gc-hmac-md5-tests: New file.
147747         * tests/test-gc-md5.c: New file.
147749         * modules/gc-md5-tests: New file.
147751 2005-10-13  Simon Josefsson  <jas@extundo.com>
147753         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
147754         Move memory allocation outside of loop.
147756 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
147758         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
147759         intermediate directory is in a read-only file system.  Problem
147760         reported by Eric Blake.
147762 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
147764         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
147766 2005-10-12  Simon Josefsson  <jas@extundo.com>
147768         * tests/test-hmac-sha1.c: New file.
147770         * modules/hmac-sha1-tests: New file.
147772         * modules/hmac-sha1: New file.
147774 2005-10-12  Simon Josefsson  <jas@extundo.com>
147776         * modules/gc-sha1: New file.
147778 2005-10-12  Simon Josefsson  <jas@extundo.com>
147780         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
147782         * tests/test-gc-pbkdf2-sha1.c: New file.
147784 2005-10-12  Simon Josefsson  <jas@extundo.com>
147786         * modules/gc-md5, modules/gc-hmac-md5: New files.
147788         * modules/gc (Files): Remove md5, memxor and hmac files.
147790 2005-10-12  Simon Josefsson  <jas@extundo.com>
147792         * m4/gc-pbkdf2-sha1.m4: New file.
147794         * m4/gc-hmac-sha1.m4: New file.
147796         * m4/gc-sha1: New file.
147798         * m4/hmac-sha1.m4: New file.
147800 2005-10-12  Simon Josefsson  <jas@extundo.com>
147802         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
147804         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
147806 2005-10-12  Simon Josefsson  <jas@extundo.com>
147808         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
147809         suggested by Bruno Haible <bruno@clisp.org>.
147811 2005-10-12  Simon Josefsson  <jas@extundo.com>
147813         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
147815 2005-10-12  Simon Josefsson  <jas@extundo.com>
147817         * lib/gc-pbkdf2-sha1.c: New file.
147819         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
147821 2005-10-12  Simon Josefsson  <jas@extundo.com>
147823         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
147825         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
147827 2005-10-12  Simon Josefsson  <jas@extundo.com>
147829         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
147830         GC_USE_HMAC_MD5, respectively.
147832         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
147833         (gc_md5): Fix typo.
147835         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
147837         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
147839         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
147841 2005-10-12  Bruno Haible  <bruno@clisp.org>
147843         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
147844         Reported by Stepan Kasal <kasal@ucw.cz>.
147846 2005-10-11  Simon Josefsson  <jas@extundo.com>
147848         * tests/test-crc.c: New file.
147850         * modules/crc, modules/crc-tests: New files.
147852 2005-10-11  Simon Josefsson  <jas@extundo.com>
147854         * m4/crc.m4: New file.
147856 2005-10-11  Simon Josefsson  <jas@extundo.com>
147858         * lib/gc.h: Add gc_hash and gc_hash_buffer.
147860         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
147862         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
147864 2005-10-11  Simon Josefsson  <jas@extundo.com>
147866         * lib/crc.h, lib/crc.c: New files.
147868         * lib/gc.h (gc_hash_buffer): Add doc.
147870 2005-10-11  Bruno Haible  <bruno@clisp.org>
147872         * modules/c-strcasestr: New file.
147873         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
147875 2005-10-11  Bruno Haible  <bruno@clisp.org>
147877         * modules/c-strcase: New file.
147878         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
147880 2005-10-11  Bruno Haible  <bruno@clisp.org>
147882         * lib/strcasecmp.c: Include limits.h.
147883         (strcasecmp): Avoid integer overflow on exotic platforms.
147884         * lib/strncasecmp.c: Include limits.h.
147885         (strncasecmp): Avoid integer overflow on exotic platforms.
147886         Reported by Paul Eggert.
147888 2005-10-11  Bruno Haible  <bruno@clisp.org>
147890         * lib/c-strcasestr.h: New file, from GNU gettext.
147891         * lib/c-strcasestr.c: New file, from GNU gettext.
147893 2005-10-11  Bruno Haible  <bruno@clisp.org>
147895         * lib/c-strcase.h: New file, from GNU gettext.
147896         * lib/c-strcasecmp.c: New file, from GNU gettext.
147897         * lib/c-strncasecmp.c: New file, from GNU gettext.
147899 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
147901         * modules/mempcpy (License): GPL -> LGPL.
147902         * modules/strchrnul (License): Likewise.
147903         * modules/sysexits (License): Likewise.
147905 2005-10-08  Simon Josefsson  <jas@extundo.com>
147907         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
147909 2005-10-07  Simon Josefsson  <jas@extundo.com>
147911         * m4/memxor.m4: Remove gl_C_RESTRICT call.
147913 2005-10-06  Simon Josefsson  <jas@extundo.com>
147915         * tests/test-hmac-md5.c: New file.
147917         * modules/hmac-md5-tests: New file.
147919         * modules/hmac-md5: New file.
147921 2005-10-06  Simon Josefsson  <jas@extundo.com>
147923         * m4/hmac-md5.m4: New file.
147925         * m4/memxor.m4: Require gl_C_RESTRICT.
147927 2005-10-06  Simon Josefsson  <jas@extundo.com>
147929         * lib/memxor.c (memxor): Avoid casts and warnings.
147931 2005-10-06  Simon Josefsson  <jas@extundo.com>
147933         * lib/hmac-md5.c: New file.
147935         * lib/hmac.h: New file.
147937 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
147939         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
147940         promotes to int, not unsigned int, to catch the AIX 5.3
147941         compiler bug.
147943 2005-10-05  Simon Josefsson  <jas@extundo.com>
147945         * modules/memxor: New file.
147947         * modules/iconv (Files): Move config.rpath to havelib, it is used
147948         there.
147950         * modules/havelib (Files): Add config.rpath.
147952 2005-10-05  Simon Josefsson  <jas@extundo.com>
147954         * m4/memxor.m4: New file.
147956 2005-10-05  Simon Josefsson  <jas@extundo.com>
147958         * lib/memxor.c (memxor): Fix compiler error.
147960         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
147961         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
147963         * lib/memxor.h, lib/memxor.c: New files.
147965         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
147966         we assume all systems have it, suggested by Jim Meyering
147967         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
147968         any systems lack sys/socket.h; mingw32 is known to lack it, but we
147969         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
147970         same reasons.
147972 2005-10-05  Simon Josefsson  <jas@extundo.com>
147974         * config/srclist.txt: Add glibc bug 1423 for md5.h.
147976 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
147978         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
147979         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
147980         needed, since the source code now assumes these .h files.
147982 2005-10-05  Derek Price  <derek@ximbiot.com>
147984         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
147986 2005-10-05  Bruno Haible  <bruno@clisp.org>
147988         * modules/stdint (License): Change to LGPL.
147990 2005-10-04  Simon Josefsson  <jas@extundo.com>
147992         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
147993         D. Baushke" <mdb@gnu.org>.
147995 2005-10-04  Bruno Haible  <bruno@clisp.org>
147997         * lib/verify.h (verify_true): Provide alternative definition for C++.
147999 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
148001         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
148002         (SSIZE_MAX): New macro, if not already defined.
148003         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
148004         than 2 GiB.
148006 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
148008         Sync from coreutils.
148009         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
148010         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
148011         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
148012         ULLONG_MAX doesn't work with 2.7.2.1.
148014 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
148016         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
148017         From Ben Pfaff.
148019         * modules/exclude (Depends-on): Depend on verify.
148020         * modules/strtoimax (Depends-on): Likewise.
148021         * modules/utimecmp (Depends-on): Likewise.
148023 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
148025         * lib/exclude.c: Include verify.h.
148026         (verify): Remove.  All callers changed to use verify.h's version.
148027         * lib/strtoimax.c: Likewise.
148028         * lib/utimecmp.c: Likewis.e
148030         Sync from coreutils.
148031         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
148032         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
148033         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
148034         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
148035         bother returning ENOSYS if settimeofday or stime fails; just let
148036         them return whatever errno they want to return.
148037         * lib/utimens.c: Include unistd.h, for dup2.
148038         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
148039         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
148041 2005-10-02  Jim Meyering  <jim@meyering.net>
148043         Sync from coreutils.
148044         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
148045         from glibc-2.2.5 that fails for read-only files.
148047 2005-10-02  Jim Meyering  <jim@meyering.net>
148049         Sync from coreutils.
148050         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
148051         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
148052         `#if HAVE_CONFIG_H'.
148053         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
148054         Remove AT_FDCWD test.
148055         Do not consume the fd unless successful.
148056         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
148057         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
148058         block, so that we don't even try to compile it if settimeofday is
148059         available.  This works around a compilation failure on OSF1 V5.1,
148060         due to stime requiring a `long int*' while tv_sec is `int'.
148062 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
148064         Sync from coreutils.
148065         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
148066         against `yes', rather than just testing for nonempty.
148068 2005-10-01  Simon Josefsson  <jas@extundo.com>
148070         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
148071         and Darwin.
148073         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
148074         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
148075         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
148076         freeaddrinfo and gai_strerror are declared by the POSIX headers.
148077         Check if struct addrinfo is declared.
148079 2005-10-01  Simon Josefsson  <jas@extundo.com>
148081         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
148082         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
148083         AI_* and EAI_* definitions.  Protect function declarations.
148085 2005-10-01  Jim Meyering  <jim@meyering.net>
148087         Sync from coreutils.
148089         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
148090         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
148091         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
148092         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
148093         in the inet and nsl libraries.  Required on Solaris 5.7.
148095 2005-10-01  Jim Meyering  <jim@meyering.net>
148097         Sync from coreutils.
148098         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
148099         in the inet and nsl libraries.  Required on Solaris 5.7.
148101 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
148103         * lib/getdelim.c (getdelim): Remove unused variables.
148105 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
148107         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
148108         so that the code works even with ancient cpp.  Portability problem
148109         with GCC 2.7.2.1 reported by Thomas M.Ott.
148111 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
148113         * modules/regex (Depends-on): Add strcase.
148115         * modules/gethostname (Licence): Change from GPL to LGPL, since
148116         gethostname.c is a trivial implementation of a standard library
148117         function.
148118         * modules/poll (License): Change from GPL to LGPL, since it's
148119         derived from LGPL code.
148121 2005-09-27  Jim Meyering  <jim@meyering.net>
148123         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
148124         HAVE_CONFIG_H.
148126         * lib/intprops.h (signed_type_or_expr__): Define.
148127         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
148128         for unsigned types.
148130 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
148132         * lib/verify.h (verify_expr): Remove, replacing with:
148133         (verify_true): New macro that returns true instead of void.
148134         (verify_type__): Remove.
148135         (verify): Use verify_true rather than verify_type__.
148137 2005-09-26  Bruno Haible  <bruno@clisp.org>
148139         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
148140         is necessary.
148141         (lib_SOURCES): Remove mbchar.c.
148142         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
148143         (Files): Add m4/mbrtowc.m4.
148144         * modules/mbiter: Likewise.
148145         * modules/mbuiter: Likewise.
148147 2005-09-26  Bruno Haible  <bruno@clisp.org>
148149         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
148150         compile mbchar.c if they are not both present.
148151         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
148152         * m4/mbiter.m4 (gl_MBITER): Likewise.
148153         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
148154         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
148155         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
148157 2005-09-25  Jim Meyering  <jim@meyering.net>
148159         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
148160         also uses socklen_t.
148162 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
148164         * lib/utimens.c (ENOSYS): Define if not already defined.
148165         (futimens): Support having a null PATH if the file descriptor
148166         is nonnegative.
148168         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
148169         Remove.
148170         (__attribute): Define to empty unless GCC 3.1 or later.
148171         This works around a core dump on OpenBSD 3.4, which has GCC
148172         2.95.3, which dumps core when given __attribute__(()).  It also
148173         simplifies other tests, since we really don't want to bother with
148174         worrying about which ancient version of GCC supported what.
148175         Original problem reported by Yoann Vandoorselaere, with part of
148176         the fix suggested by Derek Price.
148178 2005-09-24  Jim Meyering  <jim@meyering.net>
148180         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
148181         so we can once again use a positive bitfield width of 1 -- now we
148182         don't have to explain why we were using a bitfield width of 2.
148184 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
148186         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
148187         and similarly for the other external symbols.  Problem reported
148188         by James Gallager.
148190         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
148191         bug reported by Jim Meyering.
148193         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
148194         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
148195         not needed, since socklen is a prerequisite module.
148197 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
148199         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
148200         Problem reported by Eric Blake.
148201         (getaddrinfo): Initialize se so that it's not garbage.
148202         Redo internal storage allocation so that it doesn't make unportable
148203         assumptions about alignment.
148204         Fix a memory leak.
148206         * lib/utimens.c (futimens): Use futimesat if available.
148207         Prefer it to futimes since it doesn't have the futimes bug.
148209         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
148210         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
148211         Instead, declare a function that returns a pointer to an array,
148212         and use verify_type__ to declare the size of the array.
148213         Problem and germ of a solution reported by Bruno Haible.
148214         (verify_type__): Use 2, not 1, for bitfield size, to avoid
148215         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
148217 2005-09-23  Jim Meyering  <jim@meyering.net>
148219         Sync from coreutils.
148220         Correct build failure (socklen_t not defined) on at least
148221         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
148222         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
148224 2005-09-23  Jim Meyering  <jim@meyering.net>
148226         * modules/getaddrinfo (Depends-on): Add socklen.
148228 2005-09-23  Bruno Haible  <bruno@clisp.org>
148230         * tests/test-verify.c: New file.
148232 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
148234         Sync from coreutils.
148236         * modules/argmatch (Depends-on): Add verify.
148237         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
148238         unistd-safer.
148239         * modules/save-cwd (Depends-on): Likewise.
148241         * modules/openat (Files): Add lib/openat-die.c.
148242         (Depends-on): Remove error, exitfail.
148243         Add dirname.
148245         * modules/verify: New file.
148246         * MODULES.html.sh (Diagnostics <assert.h>): New section,
148247         with "verify" module.
148249 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
148251         Sync from coreutils.
148253         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
148254         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
148255         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
148256         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
148257         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
148258         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
148259         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
148260         Don't bother checking for string.h, stdlib.h, unistd.h.
148261         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
148262         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
148263         module's job.
148264         * m4/jm-macros.m4 (gl_MACROS): Likewise.
148265         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
148267         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
148268         (gl_GETDATE): Use it.
148270         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
148272 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
148274         Sync from coreutils.
148276         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
148277         stat-time.h.
148278         * lib/argmatch.h: Include verify.h
148279         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
148280         (ARGMATCH_ASSERT): Remove; unused.
148281         * lib/canonicalize.c: Assume STDC_HEADERS.
148282         * lib/exclude.c: Include "strcase.h".
148283         * lib/regex_internal.h [!defined _LIBC]: Likewise.
148284         * lib/getusershell.c: Include stdio--.h rather than stdio.h
148285         and stdio-safer.h.
148286         (getusershell): Call fopen, not fopen_safer.
148287         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
148288         Do not include unistd-safer.h.
148289         (save_cwd): Don't call fd_safer; no longer needed
148290         now that we include fcntl--.h.
148292         * lib/getdate.y (relative_time): New type.
148293         (RELATIVE_TIME_0): New constant.
148294         (parser_control): Use relative_time instead of doing it ourselves.
148295         (%union): Add new relative_time rel member.
148296         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
148297         Now typeless.
148298         (relunit, relunit_snumber): Now of type rel.
148299         (zone, rel, relunit, get_date): Adjust to above changes.
148301         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
148302         Do not include unistd-safer.h.
148303         (getloadavg): Don't call fd_safer; no longer needed
148304         now that we include fcntl--.h.
148306         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
148307         (make_dir_parents): Treat ENOSYS like EEXIST.
148309         Improve quality of diagnostics on restore_cwd failure.
148310         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
148311         (make_dir_parents): Last arg is now int * (for errno), not bool *.
148312         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
148313         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
148314         each time through the loop.  Do not diagnose restore_cwd failure;
148315         that is the caller's job (and perhaps the caller does not care).
148317         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
148318         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
148319         If the file already exists but is not a directory, don't bother
148320         to try to make its parents.
148321         Close potential file descriptor leak if we can't chdir("/") (!).
148322         Don't always return true if chdir($PWD) fails; return true only
148323         if the requested action was done successfully (except for the
148324         chdir($PWD)).
148325         Don't log final directory unless we actually made it.
148326         Refactor to avoid duplicate code to fix up permissions.
148327         Don't attempt to fix up parent permissions if chdir($PWD) fails.
148329         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
148330         to make it a bit faster and (I hope) clearer.
148331         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
148332         Fix bug in formats like %2N.
148334         * lib/verify.h: New file.
148336 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
148338         Sync from coreutils.
148339         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
148341 2005-09-22  Jim Meyering  <jim@meyering.net>
148343         Sync from coreutils.
148345         * m4/lstat.m4 (gl_FUNC_LSTAT):
148346         Use AC_LIBSOURCES to require lstat.c and lstat.h.
148347         Remove obsolete comment.
148348         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
148349         * m4/xstrtod.m4: Likewise.
148351         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
148353 2005-09-22  Jim Meyering  <jim@meyering.net>
148355         Sync from coreutils.
148357         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
148359         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
148360         the .tm_year member, since otherwise gcc-4.0 would now warn about
148361         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
148363         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
148364         order to avoid an unsuppressible warning from gcc on 64-bit systems.
148366         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
148367         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
148368         when run in a time zone for which daylight savings time is in effect
148369         for the starting date.
148371         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
148372         stop us from restricting permissions of just-created absolute-named
148373         directories.
148374         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
148375         to restore initial working directory.
148376         * lib/mkdir-p.c (make_dir_parents): New parameter:
148377         different_working_dir, to tell caller if/when we change the working
148378         directory and are unable to return to the initial one.
148379         * lib/mkdir-p.h (make_dir_parents): Update prototype.
148380         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
148381         `return false'.  This fixes a bug introduced on 2004-07-30.
148383         * lib/openat.c (fdopendir): Be sure to close the supplied
148384         file descriptor before returning.  This makes our replacement
148385         implementation a little closer to Solaris's, where fdopendir
148386         ties the file descriptor to the returned DIR* pointer.
148387         * lib/openat.c (unlinkat): New function.
148388         * lib/openat.h (unlinkat): Add prototype.
148389         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
148390         (openat_restore_fail): Rename from openat_restore_die.
148391         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
148393         Provide an alternative to exiting immediately upon save_cwd or
148394         restore_cwd failure.  Now, an application can arrange e.g.,
148395         to perform a longjump in that case.
148396         * lib/openat.c: Include dirname.h.
148397         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
148398         (rpl_openat, fdopendir, fstatat): Call openat_save_die
148399         and openat_restore_die rather than calling error directly.
148400         Don't include "error.h" or "exitfail.h"; they're no longer needed.
148402         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
148403         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
148404         define.
148406         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
148407         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
148408                             int utc, int nanoseconds);
148409         Background:
148410         date should not have to allocate a megabyte of virtual memory to
148411         handle a format argument like +%1048575T.  When implemented with
148412         strftime, it must allocate such a buffer, use strftime to fill it
148413         in, print it, then free it.
148414         With fprintftime, it simply prints everything and exits.
148415         With no need for memory allocation, that's one fewer way to fail.
148416         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
148417         optional field width, not before, so we accept %9:z, not %:9z.
148418         (my_strftime): Be sure to use L_('x') for literals.
148420         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
148421         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
148422         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
148423         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
148424         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
148425         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
148426         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
148427         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
148428         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
148429         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
148430         * lib/xgethostname.c, lib/xreadlink.c:
148431         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
148433         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
148434         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
148435         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
148436         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
148437         and don't include <sys/file.h>).
148439 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
148441         Sync from coreutils.
148443         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
148444         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
148445         [!LDAV_DONE]: Avoid unused variable warning.
148447 2005-09-21  Bruno Haible  <bruno@clisp.org>
148449         * lib/unicodeio.h (unicode_to_mb): New declaration.
148451 2005-09-20  Derek Price  <derek@ximbiot.com>
148453         * lib/getaddrinfo.c: Don't include <netdb.h> included from
148454         getaddrinfo.h.
148456 2005-09-20  Bruno Haible  <bruno@clisp.org>
148458         * gnulib-tool: Remove trailing slashes from the values specified for
148459         --source-base, --m4-base, --tests-base, --aux-dir.
148460         Suggested by Simon Josefsson <jas@extundo.com>.
148462 2005-09-20  Bruno Haible  <bruno@clisp.org>
148464         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
148465         func_modules_to_filelist, func_import, func_create_testdir): Make all
148466         sorting results locale-independent, so that gnulib-cache.m4 doesn't
148467         change when gnulib-tool is invoked in a different locale.
148469 2005-09-19  Simon Josefsson  <jas@extundo.com>
148471         * m4/socklen.m4: Fix typo.
148473 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
148475         Use a consistent style for including <config.h>.
148476         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
148477         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
148478         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
148479         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
148480         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
148481         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
148482         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
148483         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
148484         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
148485         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
148486         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
148487         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
148488         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
148489         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
148490         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
148491         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
148492         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
148493         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
148494         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
148495         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
148496         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
148497         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
148498         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
148499         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
148500         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
148501         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
148502         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
148503         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
148504         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
148505         lib/xstrtoumax.c, lib/yesno.c:
148506         Standardize inclusion of config.h.
148507         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
148508         lib/inttostr.h:  Removed inclusion of config.h from header files.
148509         * lib/inttostr.c:  Adjusted in-tree users.
148510         * lib/timespec.h: Remove superfluous warning to include config.h.
148511         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
148512         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
148513         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
148514         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
148515         config.h with HAVE_CONFIG_H.
148517 2005-09-19  Jim Meyering  <jim@meyering.net>
148519         * modules/pathmax (License): Change to LGPL.
148521 2005-09-19  Derek Price  <derek@ximbiot.com>
148523         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
148525 2005-09-19  Bruno Haible  <bruno@clisp.org>
148527         * gnulib-tool (import): Provide default for --tests-base.
148529 2005-09-19  Bruno Haible  <bruno@clisp.org>
148531         * doc/quote.texi: New file, extracted from gnulib.texi.
148532         * doc/ctime.texi: New file, extracted from gnulib.texi.
148533         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
148534         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
148535         * doc/gnulib.texi: Include them.
148537 2005-09-18  Bruno Haible  <bruno@clisp.org>
148539         Portability fix.
148540         * gnulib-tool (func_readlink): New function.
148541         (func_ln_if_changed): Use it.
148543 2005-09-18  Bruno Haible  <bruno@clisp.org>
148545         * gnulib-tool: Support --with-tests also with --import.
148546         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
148547         (func_import): Use variables $testsbase and $inctests. Emit a
148548         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
148549         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
148550         SUBDIRS += $testsdir.
148551         (func_create_testdir): Update.
148553 2005-09-18  Bruno Haible  <bruno@clisp.org>
148555         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
148556         instead of $dry_run.
148557         (func_cp_if_changed, func_mv_if_changed): Remove functions.
148558         (func_ln_if_changed): Don't handle dry-run here.
148559         (func_import): In dry-run mode, detect more precisely which actions
148560         would be performed, and don't use "...ing" verbs.
148562 2005-09-18  Bruno Haible  <bruno@clisp.org>
148564         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
148565         (func_import): Use join on two temporary files instead of three nested
148566         loops, in order to determine which files are new or old.
148568 2005-09-18  Bruno Haible  <bruno@clisp.org>
148570         * gnulib-tool (func_import): Comment out code that spits out the
148571         new files with --dry-run.
148573 2005-09-18  Bruno Haible  <bruno@clisp.org>
148575         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
148577 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
148579         * lib/stat-time.h: New file.
148580         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
148581         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
148582         in a different way.
148583         (timespec_cmp): New function.
148584         * lib/utimecmp.c: Include stat-time.h.
148585         (SYSCALL_RESOLUTION): Depend on whether various struct stat
148586         members exist, not on the obsolescent ST_MTIM_NSEC.
148587         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
148589 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
148591         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
148593 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
148595         * MODULES.html.sh (File system functions): Add stat-time.
148596         * modules/stat-time: New file.
148597         * modules/timespec (Files): Remove m4/st_mtim.m4; this
148598         is now done in a different way, by the stat-time module.
148599         * modules/utimecmp (Depends-on): Add stat-time.
148601 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
148603         * m4/st_mtim.m4: Remove.  Superseded by...
148604         * m4/stat-time.m4: New file.
148605         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
148606         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
148608 2005-09-15  Derek Price  <derek@ximbiot.com>
148610         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
148612 2005-09-15  Derek Price  <derek@ximbiot.com>
148614         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
148615         * lib/regex_internal.c: Ditto, using this...
148616         (__GNUC_PREREQ): ...new macro.
148617         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
148618         using...
148619         (__GNUC_PREREQ): ...this new macro.
148621         * lib/strstr.h: Include string.h. Define strstr as a macro here.
148623 2005-09-15  Derek Price  <derek@ximbiot.com>
148624             Paul Eggert  <eggert@cs.ucla.edu>
148626         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
148627         changes, consolidating in...
148628         * lib/regex_internal.h: ...this file.
148630 2005-09-13  Jim Meyering  <jim@meyering.net>
148632         * lib/canon-host.c: Filter through gnu indent and reword comments
148633         slightly.
148634         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
148636 2005-09-13  Derek Price  <derek@ximbiot.com>
148638         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
148639         failure.
148640         Reported by Jim Meyering  <jim@meyering.net>.
148642 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
148644         * lib/base64.c: Typo.
148645         (base64_encode): Put b64str in initialized data section.
148647 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
148649         Merge glibc and coreutils changes into gnulib, plus a few
148650         extra fixes.
148651         * lib/md5.c: Use #error rather than a string.
148652         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
148653         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
148654         (__attribute__): Define to empty for non recent-GCC.
148655         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
148656         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
148657         Renamed from their non-__ counterparts, with new macros replacing
148658         them if not _LIBC.  Add __THROW attribute.
148659         (rol): Remove.
148660         (struct md5_ctx): Align buffer if using GCC.
148661         * lib/sha1.h (struct sha1_ctx): Likewise.
148662         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
148663         The old name was backwards.
148664         (NOTSWAP): Remove; not used.
148665         (rol): New macro, moved here from md5.h.
148666         (sha1_process_block): Remove a FIXME that doesn't make sense.
148668 2005-09-12  Derek Price  <derek@ximbiot.com>
148670         Return usable errors from canon-host.
148671         * lib/canon-host.h: New file.
148672         * lib/canon-host.c (canon_host): Wrap...
148673         (canon_host_r): ...this new function, which now relies exclusively on
148674         getaddrinfo.
148675         (ch_strerror): New function.
148676         (last_cherror): New global.
148677         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
148678         interface.
148679         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
148680         void *.
148681         (freeaddrinfo): Free ai->ai_canonname when set.
148683 2005-09-12  Derek Price  <derek@ximbiot.com>
148685         Make canon-host require getaddrinfo.
148686         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
148687         AC_LIBSOURCE canon-host.h.  Call...
148688         (gl_PREREQ_CANON_HOST): ...this new function, which requires
148689         gl_GETADDRINFO.
148690         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
148692 2005-09-12  Derek Price  <derek@ximbiot.com>
148694         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
148695         LGPL.
148696         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
148698 2005-09-12  Derek Price  <derek@ximbiot.com>
148700         * lib/gai_strerror.c: Include config.h when available.  Include
148701         getaddrinfo.h before other headers to test interface.
148702         Reported by Larry Jones <lawrence.jones@ugs.com>.
148704 2005-09-12  Derek Price  <derek@ximbiot.com>
148705             Paul Eggert  <eggert@cs.ucla.edu>
148707         * modules/glob (Files): Add glob-libc.h.
148709 2005-09-12  Derek Price  <derek@ximbiot.com>
148710             Paul Eggert  <eggert@cs.ucla.edu>
148712         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
148713         glob_.h, glob-libc.h.
148714         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
148716 2005-09-12  Derek Price  <derek@ximbiot.com>
148717             Paul Eggert  <eggert@cs.ucla.edu>
148719         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
148720         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
148721         protecting things that should be done only in gnulib contexts.
148722         * lib/glob_.h: New file, containing only the glob things needed for
148723         gnulib.
148724         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
148725         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
148726         (glob, globfree, glob_pattern_p): Now defined simply in terms of
148727         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
148728         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
148729         and to respect the namespace rules better.
148731 2005-09-08  Simon Josefsson  <jas@extundo.com>
148733         * modules/socklen: New file.
148735 2005-09-08  Simon Josefsson  <jas@extundo.com>
148737         * m4/socklen.m4: New file.
148739 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
148741         * modules/utimens (Files): Add m4/utimbuf.m4, since
148742         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
148743         Reported by Sergey Poznyakoff.
148745 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
148747         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
148748         definitions, since that's the preferred style in glibc.
148749         Fix a minor spacing issue, and update copyright notice to match
148750         glibc's.
148752 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
148754         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
148756 2005-09-06  Simon Josefsson  <jas@extundo.com>
148758         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
148759         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
148761 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
148763         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
148764         warning.
148766 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
148768         * config/srclist.txt: Add glibc bug 1302.
148770 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
148772         Change bitset word type from unsigned int to unsigned long int,
148773         as this has better performance on typical 64-bit hosts.
148774         Port bitset code to hosts with unusual word sizes.
148775         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
148776         (build_collating_symbol):
148777         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
148778         argument is a bitset.  This is merely a style issue, but it makes
148779         it clearer that an entire array is expected.
148780         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
148781         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
148782         Port to the case where bitset_word is not the same as unsigned int.
148783         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
148784         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
148785         Likewise.
148786         * lib/regexec.c (check_dst_limits_calc_pos_1,
148787         check_subexp_matching_top):
148788         (build_trtable, group_nodes_into_DFAstates):
148789         Likewise.
148790         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
148791         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
148792         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
148793         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
148794         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
148795         * lib/regcomp.c (optimize_subexps, lower_subexp):
148796         Work even if bitset_word has holes in its bitwise representation.
148797         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
148798         * lib/regexec.c (check_dst_limits_calc_pos_1,
148799         check_subexp_matching_top):
148800         Likewise.
148801         * lib/regex_internal.c (re_string_reconstruct):
148802         Don't assume UCHAR_MAX == 255.
148803         * lib/regex_internal.h (bitset_set_all): Likewise.
148804         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
148805         All uses changed.
148806         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
148807         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
148808         All uses changed.
148809         (BITSET_WORD_MAX): New macro.
148810         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
148811         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
148812         (bitset_empty, bitset_copy):
148813         Prefer sizeof (bitset) to multiplying it out ourselves.
148814         (bitset_not_merge): Remove; unused.
148815         (bitset_contain): Return bool, not unsigned int with one bit on.
148816         All callers changed.
148817         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
148818         alignment than re_node_set; do this by defining a new internal
148819         type struct dests_alloc and using it to allocate memory.
148821 2005-09-05  Bruno Haible  <bruno@clisp.org>
148823         * gnulib-tool (func_import): Fix comparison in handling of symbolic
148824         links.
148826 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
148828         * modules/size_max (Makefile.am): Add size_max.h
148830 2005-09-04  Derek Price  <derek@ximbiot.com>
148832         * gnulib-tool (func_import): Fix reversed $symbolic logic.
148834 2005-09-03  Simon Josefsson  <jas@extundo.com>
148836         * gnulib-tool: Fix typo.
148838 2005-09-03  Simon Josefsson  <jas@extundo.com>
148840         * config/srclist.txt: Add glibc bug 1293.
148842 2005-09-03  Derek Price  <derek@ximbiot.com>
148844         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
148845         From Larry Jones <lawrence.jones@ugs.com>.
148847 2005-09-02  Simon Josefsson  <jas@extundo.com>
148849         * modules/socklen: New file.
148851 2005-09-02  Simon Josefsson  <jas@extundo.com>
148853         * modules/havelib: New module.
148855         * modules/gettext, modules/iconv, modules/lock, modules/readline:
148856         Use havelib.
148858 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
148860         Check for arithmetic overflow when calculating sizes, to prevent
148861         some buffer-overflow issues.  These patches are conservative, in the
148862         sense that when I couldn't determine whether an overflow was possible,
148863         I inserted a run-time check.
148864         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
148865         macros.
148866         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
148867         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
148868         (re_xnrealloc, re_x2nrealloc): New inline functions.
148869         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
148870         parse_bracket_exp):
148871         (build_equiv_class, build_charclass): Check for arithmetic overflow
148872         in size expression calculations.
148873         * lib/regex_internal.c (re_string_realloc_buffers):
148874         (build_wcs_upper_buffer, re_node_set_add_intersect):
148875         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
148876         (re_dfa_add_node, register_state): Likewise.
148877         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
148878         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
148879         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
148880         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
148882 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
148884         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
148885         m4/ulonglong.m4.  Problem reported by Martin Lambers.
148887 2005-09-02  Bruno Haible  <bruno@clisp.org>
148889         Support for lib vs. lib64 distinction on biarch platforms.
148890         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
148891         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
148892         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
148894 2005-09-02  Bruno Haible  <bruno@clisp.org>
148896         * gnulib-tool (import): In the other first-use case, provide defaults
148897         as well.
148899 2005-09-02  Bruno Haible  <bruno@clisp.org>
148901         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
148902         patches not yet found in the latest gettext release.
148904 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
148906         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
148907         to avoid a collision with bits/local_lim.h in glibc.
148908         All uses changed.  Problem reported by Dmitry V. Levin in
148909         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
148911         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
148912         bugs in int versus size_t comparisons.
148913         (re_string_context_at): Fix bug where the code assumed that
148914         Idx is signed.
148916         Use bool where appropriate.
148917         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
148918         All callers changed.
148919         (calc_eclosure_iter): Likewise, for ROOT arg.
148920         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
148921         (build_charclass_op): Likewise, for NON_MATCH arg.
148922         * lib/regex_internal.c (re_string_allocate, re_string_construct):
148923         (re_string_construct_common): Likewise, for ICASE arg.
148924         * lib/regexec.c (re_search_2_stub, re_search_stub):
148925         Likewise, for RET_LEN arg.
148926         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
148927         (set_regs): Likewise, for FL_BACKTRACK arg.
148928         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
148929         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
148930         (calc_eclosure_iter, parse_bracket_exp):
148931         Use bool for internal variables that are booleans.
148932         * lib/regexec.c (re_search_internal, check_matching,
148933         proceed_next_node):
148934         (set_regs, build_sifted_states, sift_states_bkref):
148935         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
148936         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
148937         (find_collation_sequence_value):
148938         Likewise.
148939         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
148940         (re_node_set_compare):
148941         Return bool, not int. All callers changed.
148942         * lib/regexec.c (check_halt_node_context, check_dst_limits):
148943         (build_trtable, check_node_accept): Likewise.
148944         * lib/regex_internal.h: Include stdbool.h.
148946         Fix bugs uncovered when converting to bool.
148947         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
148948         failure instead of charging ahead blindly.
148949         * lib/regex_internal.c (register_state): Likewise.
148950         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
148951         for freeing internal storage.
148952         (group_nodes_into_DFA_states): Use unsigned int, not int, for
148953         bitset pieces used as boolean, to avoid undefined behavior
148954         on hosts that do int overflow checking.
148956 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
148958         * config/srclist.txt: Add glibc bugs 1285-1287.
148960 2005-09-01  Jim Meyering  <jim@meyering.net>
148962         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
148963         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
148964         Require gl_STAT_MACROS, too.
148966 2005-09-01  Bruno Haible  <bruno@clisp.org>
148968         * gnulib-tool (import): In the first-use case, provide defaults.
148970 2005-09-01  Bruno Haible  <bruno@clisp.org>
148972         * gnulib-tool (func_import): Remove the .tmp files.
148974 2005-09-01  Bruno Haible  <bruno@clisp.org>
148976         * gnulib-tool (func_import): Fix handling of symbolic links.
148978 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
148980         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
148981         old glibc regex code mishandles strings longer than 2**31 bytes.
148982         This patch fixes this when the regex code is used in gnulib
148983         (i.e., outside glibc).
148985         This patch should not affect the use of the regex code inside
148986         glibc.  No doubt this problem also needs to be handled for glibc
148987         as well, but the result will be an incompatible change to the
148988         glibc ABI, and the old ABI will have to be supported too.  That
148989         can be the subject for another patch.
148991         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
148992         governing whether the rest of this patch is active.  By default,
148993         the macro is disabled and the patch has no effect.
148994         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
148995         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
148996         (struct re_pattern_buffer, re_search, re_search_2, re_match):
148997         (re_match_2, re_set_registers): Use the new types.
148998         * lib/regex_internal.h (Idx, re_hashval_t): New types.
148999         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
149000         New macros.
149001         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
149002         (re_string_context_at, bin_tree_t, re_dfastate_t):
149003         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
149004         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
149005         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
149006         (re_string_char_size_at, re_string_wchar_at):
149007         (re_string_elem_size_at):
149008         Use the new types and macros to port to 64-bit hosts.
149009         Use unsigned types for internal values, so that the code
149010         mostly works even for arrays larger than SSIZE_MAX.
149011         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
149012         (search_duplicated_node, calc_eclosure_iter, fetch_number):
149013         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
149014         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
149015         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
149016         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
149017         (calc_inveclosure, parse_dup_op, build_range_exp):
149018         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
149019         (fetch_number, create_token_tree, mark_opt_subexp):
149020         Likewise.
149021         * lib/regex_internal.c (re_string_construct_common,
149022         create_ci_newstate):
149023         (create_cd_newstate, re_string_allocate, re_string_construct):
149024         (re_string_realloc_buffers, build_wcs_upper_buffer):
149025         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
149026         (re_string_reconstruct, re_string_peek_byte_case):
149027         (re_string_fetch_byte_case, re_string_context_at):
149028         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
149029         (re_node_set_init_copy, re_node_set_add_intersect):
149030         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
149031         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
149032         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
149033         (re_acquire_state, re_acquire_state_context, register_state):
149034         Likewise.
149035         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
149036         search_cur_bkref_entry):
149037         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
149038         (re_search_internal, re_search_2_stub, re_search_stub)
149039         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
149040         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
149041         (update_cur_sifted_state, check_dst_limits):
149042         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
149043         (check_subexp_limits, sift_states_bkref, merge_state_array):
149044         (check_subexp_matching_top, get_subexp, get_subexp_sub):
149045         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
149046         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
149047         (expand_bkref_cache, check_node_accept_bytes):
149048         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
149049         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
149050         (acquire_init_state_context, check_halt_node_context):
149051         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
149052         (sift_states_backward, clean_state_log_if_needed):
149053         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
149054         (find_recover_state, transit_state_sb, transit_state_mb):
149055         (transit_state_bkref, build_trtable, match_ctx_clean):
149056         Likewise.
149057         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
149058         to work around an assumption that REG_MISSING is negative.
149060         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
149061         (seek_collating_symbol_entry) [defined _LIBC]:
149062         (lookup_collation_sequence_value) [defined _LIBC]:
149063         (build_range_exp, build_collating_symbol) [defined _LIBC]:
149064         Use prototypes rather than old-style function definitions.
149065         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
149066         (transit_state_sb) [0]:
149067         (find_collation_sequence_value) [defined _LIBC]: Likewise.
149069         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
149070         rm_eo.
149072         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
149073         (optimize_subexps, lower_subexp):
149074         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
149075         since the signed shift might overflow.  Use 1u<<31 instead.
149076         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
149077         Likewise.
149078         * lib/regexec.c (check_dst_limits_calc_pos_1,
149079         check_subexp_matching_top): Likewise.
149081         * lib/regcomp.c (optimize_subexps, lower_subexp):
149082         Use CHAR_BIT rather than 8, for clarity.
149083         * lib/regexec.c (check_dst_limits_calc_pos_1):
149084         (check_subexp_matching_top): Likewise.
149085         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
149086         have to worry about portability issues when shifting it left.
149087         Remove no-longer-needed test for table_size > 0.
149088         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
149089         in a word, as the resulting behavior is undefined.
149090         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
149091         in one case, a <= should have been an <, and in another case the
149092         whole test was missing.
149093         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
149094         the standard name CHAR_BIT.
149095         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
149096         this is not true on one's complement and signed-magnitude hosts.
149098         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
149099         next_last_offset.
149100         (struct re_dfa_t): Remove unused member states_alloc.
149101         * lib/regcomp.c (init_dfa): Don't initialize unused members.
149103 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
149105         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
149106         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
149107         and large-file glibc and in 32-bit large-file Solaris.
149109 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
149111         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
149112         lengths fit in regoff_t; this isn't true if regoff_t is the same
149113         width as size_t.
149114         * lib/regex.c (re_search_internal): 5th arg is LAST_START
149115         (= START + RANGE) instead of RANGE.  This avoids overflow
149116         problems when regoff_t is the same width as size_t.
149117         All callers changed.
149118         (re_search_2_stub): Check for overflow when adding the
149119         sizes of the two strings.
149120         (re_search_stub): Check for overflow when adding START
149121         to RANGE; if it occurs, substitute the extreme value.
149123 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
149125         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
149127 2005-08-31  Jim Meyering  <jim@meyering.net>
149129         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
149130         a pointer-to-const.
149131         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
149132         (register_state): Likewise.
149133         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
149134         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
149135         (group_nodes_into_DFAstates): Likewise.
149137 2005-08-31  Jim Meyering  <jim@meyering.net>
149139         * check-module: Add a FIXME comment.
149141 2005-08-31  Eric Blake  <ebb9@byu.net>
149143         * modules/unistd-safer (Files): Add unistd--.h.
149144         * modules/stdio-safer (Files): Add stdio--.h.
149146 2005-08-31  Derek Price  <derek@ximbiot.com>
149148         * lib/getdelim.c (getdelim): Return EOF on EOF.
149149         Reported by Larry Jones <lawrence.jones@ugs.com>.
149151 2005-08-31  Bruno Haible  <bruno@clisp.org>
149153         Avoid unnecessary diffs in the generated lib/Makefile.am.
149154         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
149155         the generated files.
149156         (func_import): Don't set cmd.
149158 2005-08-31  Bruno Haible  <bruno@clisp.org>
149160         * lib/strstr.c: Include <stddef.h>, for NULL.
149161         * lib/strcasestr.c: Likewise.
149162         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
149164 2005-08-31  Bruno Haible  <bruno@clisp.org>
149166         * gnulib-tool: New option --macro-prefix.
149167         (func_import): Use macro_prefix.
149168         (import): Handle option --macro-prefix.
149170 2005-08-31  Bruno Haible  <bruno@clisp.org>
149172         * gnulib-tool (import): Rename most ac_* variables to cached_*.
149173         Also use new variables cached_lgpl, cached_libtool.
149175 2005-08-31  Bruno Haible  <bruno@clisp.org>
149177         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
149178         always instantiating them.
149180 2005-08-31  Bruno Haible  <bruno@clisp.org>
149182         * gnulib-tool (func_import): Read the previous cached settings
149183         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
149184         earlier added by gnulib but are now dropped. Warn when a gnulib file
149185         overwrites a non-gnulib file.
149187 2005-08-31  Bruno Haible  <bruno@clisp.org>
149189         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
149190         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
149191         projects that don't keep autogenerated files in CVS. Put into
149192         actioncmd only the specified modules, not the transitive closure.
149194 2005-08-31  Bruno Haible  <bruno@clisp.org>
149196         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
149197         Create directories that shall be filled.
149198         (import): Don't look for gl_* macros in configure.ac. Recurse across
149199         all directories containing a gnulib-cache.m4 files, if meaningful.
149201 2005-08-31  Bruno Haible  <bruno@clisp.org>
149203         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
149204         (import): Set seen_libtool when we see gl_LIBTOOL.
149206 2005-08-31  Bruno Haible  <bruno@clisp.org>
149208         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
149209         declaration macro definitions from generated gnulib.m4.
149211 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
149213         * lib/iconvme.h: Add prototype for iconv_alloc.
149215 2005-08-29  Simon Josefsson  <jas@extundo.com>
149217         * lib/iconvme.c: Fix errno.
149219 2005-08-29  Bruno Haible  <bruno@clisp.org>
149221         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
149222         that it works when the directory contains spaces.
149224 2005-08-29  Bruno Haible  <bruno@clisp.org>
149226         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
149228 2005-08-29  Bruno Haible  <bruno@clisp.org>
149230         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
149231         Emit more advice.
149233 2005-08-29  Bruno Haible  <bruno@clisp.org>
149234         and Stepan Kasal  <kasal@ucw.cz>
149236         * check-module: If more parameters are given, check each of them
149237         separately; add more exceptions, as noted by Jim Meyering.
149238         (check_module): New procedure.
149239         (%exempt_header): Now contains all exceptions.
149241 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
149243         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
149245 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
149247         * lib/iconvme.c: Split iconv_string into iconv_alloc.
149249 2005-08-28  Bruno Haible  <bruno@clisp.org>
149251         * m4/gnulib-tool.m4: New file.
149253 2005-08-27  Jim Meyering  <jim@meyering.net>
149255         * modules/unistd-safer (Files): Add pipe-safer.c.
149256         * modules/fcntl-safer (Files): Add creat-safer.c.
149258 2005-08-27  Jim Meyering  <jim@meyering.net>
149260         * m4/stdlib-safer.m4: New file.  From coreutils.
149261         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
149262         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
149263         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
149264         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
149265         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
149267 2005-08-27  Jim Meyering  <jim@meyering.net>
149269         * lib/fopen-safer.c: Merge minor changes from coreutils.
149270         * lib/dup-safer.c: Likewise.
149271         * lib/fd-safer.c: Likewise.
149273         Merge from coreutils.
149274         * lib/stdio--.h: New file.
149275         * lib/stdlib--.h: New file.
149276         * lib/mkstemp-safer.c: New file.
149278         GNU tar needs these.
149279         * lib/pipe-safer.c: New file.
149280         * lib/creat-safer.c: New file.
149281         * lib/fcntl--.h (creat): Define to creat_safer.
149282         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
149283         * lib/unistd--.h (pipe): Define to pipe_safer.
149284         * lib/unistd-safer.h: Declare pipe_safer.
149286 2005-08-26  Simon Josefsson  <jas@extundo.com>
149288         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
149289         Haible <bruno@clisp.org>.
149291 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
149293         * lib/regex_internal.h: Remove all references to
149294         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
149295         or better.
149296         (bitset_not, bitset_merge, bitset_not_merge):
149297         (bitset_mask, re_string_allocate, re_string_construct):
149298         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
149299         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
149300         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
149301         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
149302         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
149303         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
149304         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
149305         (re_acquire_state_context):
149306         Remove unnecessary forward decls.
149307         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
149308         Put __attribute at function definition,
149309         now that the function decl has been removed.
149310         * lib/regex_internal.c (re_string_peek_byte_case):
149311         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
149312         Likewise.
149314 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
149316         * m4/regex.m4: Add AC_PREREQ(2.50).
149317         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
149319 2005-08-25  Simon Josefsson  <jas@extundo.com>
149321         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
149322         __fsetlocking.
149324 2005-08-25  Simon Josefsson  <jas@extundo.com>
149326         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
149327         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
149328         GLIBC specific code.
149330 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
149332         Make regex safe for g++.  This fixes one real bug (an "err"
149333         that should have been "*err").  g++ problem reported by
149334         Sam Steingold.
149335         * lib/regex_internal.h (re_calloc): New macro, consistent with
149336         re_malloc etc.  All callers of calloc changed to use re_calloc.
149337         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
149338         not int.  All callers changed.
149339         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
149340         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
149341         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
149342         (find_recover_state): Change "err" to "*err"; this fixes what
149343         appears to be a real bug.
149344         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
149345         versus int.
149347 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
149349         * modules/regex (Depends-on): Add malloc, since the code
149350         assumes that !malloc(0) means failure.
149352 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
149354         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
149356         alloca modernization/simplification for regex.
149357         * lib/regex.c: Remove portability cruft for alloca.  This no longer
149358         needs to be at the start of the file, and can be moved into
149359         regex_internal.h and simplified.
149360         * lib/regex_internal.h: Include <alloca.h>.
149361         (__libc_use_alloca) [!defined _LIBC]: New macro.
149362         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
149363         now works outside glibc.
149365 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
149367         * config/srclist.txt: Add glibc bugs 1241, 1245.
149369 2005-08-25  Jim Meyering  <jim@meyering.net>
149371         * lib/open-safer.c: Include <config.h>.
149372         Otherwise, we'd lose LARGEFILE support in any file using
149373         e.g. "fcntl--.h"
149375 2005-08-25  Bruno Haible  <bruno@clisp.org>
149377         * m4/minmax.m4: Require autoconf 2.52.
149378         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
149379         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
149380         alternatives of translit over the alphabet.
149381         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
149383 2005-08-24  Simon Josefsson  <jas@extundo.com>
149385         * tests/test-getpass.c: New file.
149387 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
149389         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
149390         for GNU regex features.
149392 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
149394         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
149395         * lib/regex.h (regerror): Likewise.
149397         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
149398         requires this.  (The code never needed it.)
149400         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
149401         All uses of recently-renamed identifiers changed to use the new,
149402         POSIX-compliant names.  The code will build and run just fine
149403         without these changes, but it's better to eat our own dog food
149404         and use the standard-conforming names.
149406         * lib/regex.h: Fix a multitude of POSIX name space violations.
149407         These changes have an effect only for programs that define
149408         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
149409         do not change anything for programs compiled in the normal way.
149410         Also, there is no effect on the ABI.
149412         (_REGEX_SOURCE): New macro.
149413         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
149414         defined and _GNU_SOURCE is not; this fixes a name space violation.
149416         Rename the following macros to obey POSIX requirements.
149417         The old names are still visible as macros if _REGEX_SOURCE is defined.
149418         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
149419         RE_BACKSLASH_ESCAPE_IN_LISTS.
149420         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
149421         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
149422         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
149423         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
149424         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
149425         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
149426         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
149427         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
149428         (REG_INTERVALS): renamed from RE_INTERVALS.
149429         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
149430         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
149431         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
149432         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
149433         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
149434         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
149435         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
149436         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
149437         RE_UNMATCHED_RIGHT_PAREN_ORD.
149438         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
149439         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
149440         (REG_DEBUG): renamed from RE_DEBUG.
149441         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
149442         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
149443         unusual, since we can't clash with the POSIX REG_ICASE.
149444         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
149445         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
149446         (REG_NO_SUB): renamed from RE_NO_SUB.
149447         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
149448         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
149449         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
149450         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
149451         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
149452         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
149453         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
149454         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
149455         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
149456         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
149457         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
149458         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
149459         RE_SYNTAX_POSIX_MINIMAL_BASIC.
149460         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
149461         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
149462         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
149463         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
149464         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
149465         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
149466         (REG_FIXED): Renamed from REGS_FIXED.
149467         (REG_NREGS): Renamed from RE_NREGS.
149469         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
149470         of other REG_* macros, since POSIX says the user is allowed to
149471         #undef these macros selectively.
149473         (reg_errcode_t): Update comment stating what other tables need
149474         to be consistent.
149476         Rename the following enum values to obey POSIX requirements.
149477         The old names are still visible as macros.
149478         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
149479         is not defined, since GNU is supposed to be a superset of POSIX as
149480         much as possible, and since we want reg_errcode_t to be a signed
149481         type for implementation consistency.
149482         (_REG_NOERROR): Renamed from REG_NOERROR.
149483         (_REG_NOMATCH): Renamed from REG_NOMATCH.
149484         (_REG_BADPAT): Renamed from REG_BADPAT.
149485         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
149486         (_REG_ECTYPE): Renamed from REG_ECTYPE.
149487         (_REG_EESCAPE): Renamed from REG_EESCAPE.
149488         (_REG_ESUBREG): Renamed from REG_ESUBREG.
149489         (_REG_EBRACK): Renamed from REG_EBRACK.
149490         (_REG_EPAREN): Renamed from REG_EPAREN.
149491         (_REG_EBRACE): Renamed from REG_EBRACE.
149492         (_REG_BADBR): Renamed from REG_BADBR.
149493         (_REG_ERANGE): Renamed from REG_ERANGE.
149494         (_REG_ESPACE): Renamed from REG_ESPACE.
149495         (_REG_BADRPT): Renamed from REG_BADRPT.
149496         (_REG_EEND): Renamed from REG_EEND.
149497         (_REG_ESIZE): Renamed from REG_ESIZE.
149498         (_REG_ERPAREN): Renamed from REG_ERPAREN.
149499         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
149500         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
149501         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
149502         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
149504         (_REG_RE_NAME, _REG_RM_NAME): New macros.
149505         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
149506         changed.  But support the old name if the new one is not defined
149507         and if _REGEX_SOURCE.
149509         Change the following member names in struct re_pattern_buffer.
149510         The old names are still supported if !_REGEX_SOURCE.
149511         The new names are always supported, regardless of _REGEX_SOURCE.
149512         (re_buffer): Renamed from buffer.
149513         (re_allocated): Renamed from allocated.
149514         (re_used): Renamed from used.
149515         (re_syntax): Renamed from syntax.
149516         (re_fastmap): Renamed from fastmap.
149517         (re_translate): Renamed from translate.
149518         (re_can_be_null): Renamed from can_be_null.
149519         (re_regs_allocated): Renamed from regs_allocated.
149520         (re_fastmap_accurate): Renamed from fastmap_accurate.
149521         (re_no_sub): Renamed from no_sub.
149522         (re_not_bol): Renamed from not_bol.
149523         (re_not_eol): Renamed from not_eol.
149524         (re_newline_anchor): Renamed from newline_anchor.
149526         Change the following member names in struct re_registers.
149527         The old names are still supported if !_REGEX_SOURCE.
149528         The new names are always supported, regardless of _REGEX_SOURCE.
149529         (rm_num_regs): Renamed from num_regs.
149530         (rm_start): Renamed from start.
149531         (rm_end): Renamed from end.
149533         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
149534         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
149535         Prepend __ to parameter names.
149537         Undo yesterday's changes.
149539 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
149541         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
149542         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
149543         lib/regex.c.
149545 2005-08-24  Jim Meyering  <jim@meyering.net>
149547         Sync from coreutils.
149548         * m4/fcntl-safer.m4: New file.
149550         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
149551         and object files for this module.
149553 2005-08-24  Jim Meyering  <jim@meyering.net>
149555         Sync from coreutils.
149556         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
149558 2005-08-24  Jim Meyering  <jim@meyering.net>
149560         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
149561         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
149563 2005-08-24  Jim Meyering  <jim@meyering.net>
149565         * modules/fcntl-safer: New module.
149566         * modules/fts (Depends-on): Add fcntl-safer.
149567         * MODULES.html.sh (File descriptor based Input/Output):
149568         Add fcntl-safer.
149570 2005-08-24  Bruno Haible  <bruno@clisp.org>
149572         Support for unit test modules.
149573         * modules/README: Mention tests modules.
149574         * modules/TEMPLATE-TESTS: New file.
149575         * gnulib-tool: New options --extract-tests-module, --with-tests and
149576         --tests-base (unused for the moment).
149577         (testsbase, inctests): New variables.
149578         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
149579         (func_verify_module): Exclude TEMPLATE-TESTS.
149580         (func_verify_nontests_module, func_verify_tests_module): New functions.
149581         (func_get_dependencies): Add implicit dependency for tests modules.
149582         (func_get_tests_module): New function.
149583         (func_modules_transitive_closure): When --with-tests was specified,
149584         include the unit tests as well, unless explicitly avoided.
149585         (func_emit_lib_Makefile_am): Ignore the tests modules here.
149586         (func_emit_tests_Makefile_am): New function.
149587         (func_create_testdir): When --with-tests was specified, emit a
149588         tests/ directory.
149589         * MODULES.html.sh (Future developments): Update.
149591 2005-08-24  Bruno Haible  <bruno@clisp.org>
149593         * modules/tls-tests: New file.
149594         * tests/test-tls.c: New file, from GNU gettext.
149596 2005-08-24  Bruno Haible  <bruno@clisp.org>
149598         * modules/lock-tests: New file.
149599         * tests/test-lock.c: New file, from GNU gettext.
149601 2005-08-24  Bruno Haible  <bruno@clisp.org>
149603         * lib/lock.h: Add multiple inclusion guard.
149604         * lib/tls.h: Add multiple inclusion guard.
149606 2005-08-24  Bruno Haible  <bruno@clisp.org>
149608         * gnulib-tool: Add support for the --aux-dir option to
149609         --create-testdir, --create-megatestdir, --test, --megatest.
149610         (func_create_testdir, func_create_megatestdir): Optionally emit a
149611         AC_CONFIG_AUX_DIR directive.
149612         (create-testdir, create-megatestdir, test, megatest): Provide a
149613         default value for $auxdir.
149615 2005-08-24  Bruno Haible  <bruno@clisp.org>
149617         * gnulib-tool (import): Use compound statement instead of subshell
149618         where possible.
149620 2005-08-24  Bruno Haible  <bruno@clisp.org>
149622         * gnulib-tool (import): Change --aux-dir default to "build-aux".
149624 2005-08-24  Bruno Haible  <bruno@clisp.org>
149626         * gnulib-tool (func_version): Update.
149628 2005-08-24  Bruno Haible  <bruno@clisp.org>
149630         * gnulib-tool (func_import, func_create_testdir,
149631         func_create_megatestdir): Quote all autoconf macro arguments.
149633 2005-08-24  Bruno Haible  <bruno@clisp.org>
149635         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
149636         option --force, because --force causes the aclocal.m4 of each
149637         subdirectory to be newer than the corresponding config.h.in.
149639 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
149641         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
149642         All contents moved to gl_REGEX.
149643         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
149644         assume that it does.
149646 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
149648         * lib/regex.h (REG_NOSYS)
149649         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
149650         Define, since POSIX requires it as of 2001.
149651         (_REG_ENOSYS)
149652         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
149653         New private symbol, used to keep the enum signed in all cases.
149654         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
149655         Youngman in
149656         <http://lists.gnu.org/r/bug-gnulib/2005-07/msg00132.html>.
149658         * lib/regex_internal.c (re_string_skip_chars, register_state):
149659         (calc_state_hash):
149660         Remove forward decls; no longer needed now that we use prototypes.
149661         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
149662         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
149663         (clean_state_log_if_needed): Likewise.
149665 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
149667         * config/srclist.txt: Add glibc bugs 1231-1233.
149669 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
149671         Fix problems reported by Sam Steingold in
149672         <http://lists.gnu.org/r/bug-gnulib/2005-08/msg00007.html>.
149673         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
149674         assumed that reg_errcode_t is a signed type, which is not
149675         necessarily true if _XOPEN_SOURCE is not defined.
149676         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
149677         since some compilers warn about it otherwise.
149679 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
149681         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
149682         (init_word_char, create_initial_state, duplicate_node_closure):
149683         (fetch_token, peek_token_bracket, build_range_exp):
149684         (build_collating_symbol): Remove forward decls; no longer needed
149685         now that we use prototypes.
149687         * lib/regcomp.c:
149688         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
149689         (re_compile_fastmap_iter, regcomp, regerror, regfree):
149690         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
149691         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
149692         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
149693         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
149694         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
149695         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
149696         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
149697         (build_range_exp, build_collating_symbol, parse_bracket_exp):
149698         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
149699         (build_charclass, build_charclass_op, fetch_number, create_tree):
149700         (create_token_tree, mark_opt_subexp, duplicate_tree):
149701         Use prototypes rather than old-style definitions.
149703         * lib/regex_internal.c:
149704         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
149705         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
149706         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
149707         (re_string_reconstruct, re_string_peek_byte_case):
149708         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
149709         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
149710         (re_node_set_init_copy, re_node_set_add_intersect):
149711         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
149712         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
149713         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
149714         (re_acquire_state, re_acquire_state_context, register_state):
149715         (create_ci_newstate, create_cd_newstate, free_state):
149716         Likewise.
149717         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
149718         re_search_2):
149719         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
149720         (re_search_internal, prune_impossible_nodes):
149721         (acquire_init_state_context, check_matching, static):
149722         (check_halt_node_context, check_halt_state_context, proceed_next_node):
149723         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
149724         (update_regs, sift_states_backward, build_sifted_states):
149725         (clean_state_log_if_needed, merge_state_array):
149726         (update_cur_sifted_state, add_epsilon_src_nodes):
149727         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
149728         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
149729         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
149730         (find_recover_state, check_subexp_matching_top, transit_state_mb):
149731         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
149732         (check_arrival, check_arrival_add_next_nodes):
149733         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
149734         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
149735         (check_node_accept_bytes, check_node_accept, extend_buffers):
149736         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
149737         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
149738         (sift_ctx_init):
149739         Likewise.
149741         * lib/regex_internal.h:
149742         (re_string_allocate, re_string_construct, re_string_reconstruct):
149743         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
149744         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
149745         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
149746         (re_string_context_at, re_string_peek_byte_case):
149747         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
149748         is defined, since we now use prototypes always.
149750         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
149751         C89 or better.  All uses removed.
149753 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
149755         * config/srclist.txt: Add glibc bugs 1220-1227.
149757 2005-08-20  Jim Meyering  <jim@meyering.net>
149759         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
149760         of unused local, dfa.
149762 2005-08-20  Bruno Haible  <bruno@clisp.org>
149764         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
149766 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
149768         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
149769         (re_node_set_insert_last, re_dfa_add_node):
149770         Rename local variables to avoid GCC shadowing warnings.
149772 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
149774         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
149775         [defined lint]: Suppress bogus uninitialized-variable warnings.
149777         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
149778         and let the caller return REG_ESPACE if out of space.  This
149779         removes an uninitialied-variable warning with GCC 4.0.1, and also
149780         avoids taking the address of a local variable.  All callers
149781         changed.
149783 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
149785         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
149786         $LIBCSRC/posix/regexec.c.
149787         Add glibc bug 1217 for regcomp.c.
149789 2005-08-19  Jim Meyering  <jim@meyering.net>
149791         * lib/regexec.c (proceed_next_node): Redo local variables to
149792         avoid GCC shadowing warnings.
149794 2005-08-18  Bruno Haible  <bruno@clisp.org>
149796         * lib/strstr.c (strstr): Fix return value in multibyte case.
149797         * lib/strcasestr.c (strcasestr): Likewise.
149799 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
149801         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
149803 2005-08-17  Jim Meyering  <jim@meyering.net>
149805         Make the %s format (seconds since the epoch) work for a negative
149806         number and when used with a zero-padded field width, e.g. %015s.
149808         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
149809         label so that it precedes the code to set `digits'.  Otherwise,
149810         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
149811         print `00-22'.  Now, it prints `-0022', as it should.
149813 2005-08-17  Bruno Haible  <bruno@clisp.org>
149815         * modules/strstr (Files): Add m4/mbrtowc.m4.
149816         (Depends-on): Add mbuiter.
149818 2005-08-17  Bruno Haible  <bruno@clisp.org>
149820         * modules/strcasestr: New file.
149821         * MODULES.html.sh (String handling, based on ANSI C 89): Add
149822         strcasestr.
149824 2005-08-17  Bruno Haible  <bruno@clisp.org>
149826         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
149828 2005-08-17  Bruno Haible  <bruno@clisp.org>
149830         * modules/mbuiter: New file.
149831         * MODULES.html.sh (Extended multibyte and wide character utilities):
149832         Add mbuiter.
149834 2005-08-17  Bruno Haible  <bruno@clisp.org>
149836         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
149837         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
149839 2005-08-17  Bruno Haible  <bruno@clisp.org>
149841         * m4/strcasestr.m4: New file.
149843 2005-08-17  Bruno Haible  <bruno@clisp.org>
149845         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
149846         * lib/strstr.c: Completely rewritten, with multibyte locale support.
149848 2005-08-17  Bruno Haible  <bruno@clisp.org>
149850         * lib/strcasestr.h: New file.
149851         * lib/strcasestr.c: New file.
149853 2005-08-17  Bruno Haible  <bruno@clisp.org>
149855         * lib/strcasecmp.c: Use mbuiter.h.
149857 2005-08-17  Bruno Haible  <bruno@clisp.org>
149859         * lib/mbuiter.h: New file.
149861 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
149863         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
149864         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
149865         and gl_GETOPT are both invoked via different paths (as happens
149866         with GNU tar CVS because it uses both argp and getopt), the former
149867         wins.
149869 2005-08-16  Bruno Haible  <bruno@clisp.org>
149871         * modules/tls: New file.
149872         * MODULES.html.sh (Multithreading): Add tls.
149874 2005-08-16  Bruno Haible  <bruno@clisp.org>
149876         * modules/strnlen1: New file.
149877         * MODULES.html.sh (String handling): Add strnlen1.
149879 2005-08-16  Bruno Haible  <bruno@clisp.org>
149881         * modules/strcase (Files): Add m4/mbrtowc.m4.
149882         (Depends-on): Add strnlen1, mbchar.
149884 2005-08-16  Bruno Haible  <bruno@clisp.org>
149886         * modules/mbiter: New file.
149887         * MODULES.html.sh (Extended multibyte and wide character utilities):
149888         Add mbiter.
149890 2005-08-16  Bruno Haible  <bruno@clisp.org>
149892         * modules/mbfile: New file.
149893         * MODULES.html.sh (Extended multibyte and wide character utilities):
149894         Add mbfile.
149896 2005-08-16  Bruno Haible  <bruno@clisp.org>
149898         * modules/mbchar: New file.
149899         * MODULES.html.sh (Extended multibyte and wide character utilities):
149900         New section.
149902 2005-08-16  Bruno Haible  <bruno@clisp.org>
149904         * m4/tls.m4: New file, from GNU gettext.
149906 2005-08-16  Bruno Haible  <bruno@clisp.org>
149908         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
149909         always.
149910         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
149912 2005-08-16  Bruno Haible  <bruno@clisp.org>
149914         * m4/mbiter.m4: New file.
149916 2005-08-16  Bruno Haible  <bruno@clisp.org>
149918         * m4/mbfile.m4: New file.
149920 2005-08-16  Bruno Haible  <bruno@clisp.org>
149922         * m4/mbchar.m4: New file.
149924 2005-08-16  Bruno Haible  <bruno@clisp.org>
149926         * lib/tls.h: New file, from GNU gettext.
149927         * lib/tls.c: New file, from GNU gettext.
149929 2005-08-16  Bruno Haible  <bruno@clisp.org>
149931         * lib/strnlen1.h: New file.
149932         * lib/strnlen1.c: New file.
149934 2005-08-16  Bruno Haible  <bruno@clisp.org>
149936         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
149937         (mbi_init): Update.
149938         (mbi_avail, mbi_advance): Let the iteration end before the terminating
149939         NUL byte, not after it.
149941 2005-08-16  Bruno Haible  <bruno@clisp.org>
149943         * lib/strcase.h (strcasecmp): Add note in comments.
149944         * lib/strncasecmp.c: Use code from strcasecmp.c.
149945         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
149946         (strcasecmp): Work correctly in multibyte locales.
149948 2005-08-16  Bruno Haible  <bruno@clisp.org>
149950         * lib/mbiter.h: New file.
149952 2005-08-16  Bruno Haible  <bruno@clisp.org>
149954         * lib/mbfile.h: New file.
149956 2005-08-16  Bruno Haible  <bruno@clisp.org>
149958         * lib/mbchar.h: New file.
149959         * lib/mbchar.c: New file.
149961 2005-08-16  Bruno Haible  <bruno@clisp.org>
149963         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
149964         the valid ones. Makes the comparison operations transitive:
149965         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
149966         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
149968 2005-08-15  Simon Josefsson  <jas@extundo.com>
149970         * modules/ssize_t (License): Change to 'unlimited'.
149972         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
149974 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
149976         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
149977         Add comments for each pending glibc patch.
149979 2005-08-15  Bruno Haible  <bruno@clisp.org>
149981         * lib/regex.h (__restrict_arr): Don't define to __restrict if
149982         __cplusplus is defined.
149984 2005-08-14  Jim Meyering  <jim@meyering.net>
149986         Sync from coreutils.
149988         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
149989         Use the hash-table-based cycle-detection code not just when
149990         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
149991         Reported by James Youngman in
149992         <http://lists.gnu.org/r/bug-gnulib/2005-08/msg00011.html>.
149993         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
149994         FTS_TIGHT_CYCLE_CHECK.
149995         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
149996         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
149997         once again.
149998         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
149999         * lib/fts.c (fd_safer): Remove decl.
150000         Include fcntl--.h rather than unistd-safer.h
150001         (fts_safe_changedir): Don't call fd_safer; no longer needed
150002         now that we include fcntl--.h.
150004 2005-08-12  Simon Josefsson  <jas@extundo.com>
150006         * modules/getndelim2: Use ssize_t module.
150007         * modules/getnline: Likewise.
150008         * modules/safe-read: Likewise.
150009         * modules/xreadlink: Likewise.
150011         * modules/ssize_t: New file.
150013 2005-08-12  Simon Josefsson  <jas@extundo.com>
150015         * m4/readline.m4: Look for termcap, curses or ncurses if required.
150017 2005-08-12  Simon Josefsson  <jas@extundo.com>
150019         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
150020         ssize_t.
150022 2005-08-12  Simon Josefsson  <jas@extundo.com>
150024         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
150025         readline, getdelim and check_version.
150026         (Support for systems lacking ISO C 99: Sizes of integer types):
150027         Add size_max.
150029 2005-08-12  Bruno Haible  <bruno@clisp.org>
150031         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
150033 2005-08-11  Simon Josefsson  <jas@extundo.com>
150035         * modules/readline: New file.
150037         * modules/strnlen (Files): Add strnlen.h.
150039 2005-08-11  Simon Josefsson  <jas@extundo.com>
150041         * m4/readline.m4: New file.
150043 2005-08-11  Simon Josefsson  <jas@extundo.com>
150045         * lib/readline.h, readline.c: New file.
150047 2005-08-11  Simon Josefsson  <jas@extundo.com>
150049         * doc/gnulib.texi (Initial import, Finishing touches): Mention
150050         gl_AVOID.
150052 2005-08-11  Bruno Haible  <bruno@clisp.org>
150054         * lib/strnlen.h (strnlen): Change parameter name to match comment.
150056 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
150058         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
150060 2005-08-10  Simon Josefsson  <jas@extundo.com>
150062         * tests/test-iconvme.c: New file.
150064 2005-08-10  Simon Josefsson  <jas@extundo.com>
150066         * m4/strnlen.m4: New file.
150068         * m4/strndup.m4: Don't check for strnlen declaration, done in
150069         strnlen.m4.
150071 2005-08-10  Simon Josefsson  <jas@extundo.com>
150073         * lib/strndup.c: Use strnlen.h.
150075         * lib/strnlen.h: New file.
150077 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
150079         * README: Typos.
150081 2005-08-02  Simon Josefsson  <jas@extundo.com>
150083         * modules/readline: New file.
150085 2005-08-02  Simon Josefsson  <jas@extundo.com>
150087         * modules/getdelim: New file.
150089         * modules/getline: Rewrite, don't use getndelim2.
150091 2005-08-02  Simon Josefsson  <jas@extundo.com>
150093         * m4/getline.m4: Separate out getdelim stuff into separate module.
150095         * m4/getdelim.m4: New file.
150097 2005-08-02  Simon Josefsson  <jas@extundo.com>
150099         * lib/getline.h, getline.c: Rewrite.
150101         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
150103 2005-07-31  Bruno Haible  <bruno@clisp.org>
150105         * lib/lock.h (gl_lock_initializer): New macro.
150106         (gl_lock_define_initialized): Use it.
150107         (gl_rwlock_initializer): New macro.
150108         (gl_rwlock_define_initialized): Use it.
150109         (gl_recursive_lock_initializer): New macro.
150110         (gl_recursive_lock_define_initialized): Use it.
150112 2005-07-30  Karl Berry  <karl@gnu.org>
150114         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
150115         Report from Ben Pfaff, regarding getopt.
150117 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
150119         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
150120         normal way.
150121         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
150122         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
150123         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
150124         (gl_GETOPT): Use the new macros.  Most of the implementation
150125         is moved to the new macros.  This is for programs like Emacs
150126         that don't want all the functionality of gl_GETOPT.
150128 2005-07-26  Bruno Haible  <bruno@clisp.org>
150130         * m4/lock.m4: Update from GNU gettext.
150132 2005-07-26  Bruno Haible  <bruno@clisp.org>
150134         * lib/lock.h: Update from GNU gettext.
150135         * lib/lock.c: Update from GNU gettext.
150137 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
150139         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
150140         obsolescent AC_TRY_RUN.  Include the default includes files, for
150141         'exit'.
150143 2005-07-24  Bruno Haible  <bruno@clisp.org>
150145         * modules/visibility: New file.
150146         * MODULES.html.sh (Misc): Add visibility.
150148 2005-07-24  Bruno Haible  <bruno@clisp.org>
150150         * m4/visibility.m4: New file.
150152 2005-07-24  Bruno Haible  <bruno@clisp.org>
150154         * doc/visibility.texi: New file.
150156 2005-07-22  Bruno Haible  <bruno@clisp.org>
150158         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
150159         $(ALLOCA_H), redundant through BUILT_SOURCES.
150160         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
150161         redundant through BUILT_SOURCES.
150162         * modules/byteswap (Makefile.am): Remove explicit dependency on
150163         $(BYTESWAP_H), redundant through BUILT_SOURCES.
150164         * modules/fnmatch (Makefile.am): Remove explicit dependency on
150165         $(FNMATCH_H), redundant through BUILT_SOURCES.
150166         * modules/getopt (Makefile.am): Remove explicit dependency on
150167         $(GETOPT_H), redundant through BUILT_SOURCES.
150168         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
150169         redundant through BUILT_SOURCES.
150170         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
150171         redundant through BUILT_SOURCES.
150172         * modules/stdbool (Makefile.am): Remove explicit dependency on
150173         $(STDBOOL_H), redundant through BUILT_SOURCES.
150174         * modules/stdint (Makefile.am): Remove explicit dependency on
150175         $(STDINT_H), redundant through BUILT_SOURCES.
150176         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
150177         Remove explicit dependency on $(SYSEXITS_H).
150178         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
150180 2005-07-18  Simon Josefsson  <jas@extundo.com>
150182         * lib/check-version.c (check_version): Accept identical versions too.
150184 2005-07-18  Bruno Haible  <bruno@clisp.org>
150186         * modules/lock: New file.
150187         * MODULES.html.sh (Multithreading): New section.
150189 2005-07-18  Bruno Haible  <bruno@clisp.org>
150191         * m4/lock.m4: New file, from GNU gettext.
150193 2005-07-18  Bruno Haible  <bruno@clisp.org>
150195         * lib/lock.h: New file, from GNU gettext.
150196         * lib/lock.c: New file, from GNU gettext.
150198 2005-07-18  Bruno Haible  <bruno@clisp.org>
150200         * lib/lock.h (gl_once_t): New type.
150201         (gl_once_define, gl_once): New macros.
150202         * lib/lock.c (fresh_once): New variable.
150203         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
150204         functions.
150206 2005-07-16  Simon Josefsson  <jas@extundo.com>
150208         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
150209         workaround, suggested by Bruno.
150211 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
150213         * modules/xalloc (Depends-on): Add xalloc-die.
150214         * modules/xvasprintf (Depends-on): Add xalloc-die.
150216 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
150218         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
150219         with a minor change.
150221 2005-07-15  Bruno Haible  <bruno@clisp.org>
150223         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
150224         When using lib/poll.c, define poll as rpl_poll.
150226 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
150228         * modules/argp (Depends-on): Remove unlocked-io.
150230 2005-07-14  Derek Price  <derek@ximbiot.com>
150232         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
150233         for glob symlink bug.
150235 2005-07-14  Bruno Haible  <bruno@clisp.org>
150237         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
150238         Instead, test for *_unlocked function declarations directly.
150240 2005-07-11  Simon Josefsson  <jas@extundo.com>
150242         * modules/size_max: New file.
150244         * modules/xsize: Depend on size_max module for size_max.m4.
150246 2005-07-11  Simon Josefsson  <jas@extundo.com>
150248         * lib/size_max.h: New file.
150250 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
150252         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
150253         copyright symbol and the year.
150254         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
150255         (version_etc_va): Use parameterized copyright notice.
150256         Reword to conform to the current GNU coding standards.
150258 2005-07-11  Karl Berry  <karl@gnu.org>
150260         * doc/gnulib.texi (Quoting): new node.
150261         (Initial import): more info, from Patrice.
150263 2005-07-11  Bruno Haible  <bruno@clisp.org>
150265         * gnulib-tool (func_usage): Document option --avoid.
150266         (Command line options): Handle --avoid.
150267         (func_acceptable): New function.
150268         (func_modules_transitive_closure): Use it.
150270 2005-07-11  Bruno Haible  <bruno@clisp.org>
150272         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
150273         Reported by Jim Meyering.
150275 2005-07-10  Bruno Haible  <bruno@clisp.org>
150277         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
150278         Needed when size_t is smaller than 'unsigned int'.
150279         Reported by Paul Eggert.
150281 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
150283         * modules/argp (Depends-on): Add unlocked-io
150285 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
150287         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
150288         block of defines.
150290 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
150292         * config/srclist.txt: Comment out regcomp.c, since we have a porting
150293         fix now.
150295 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
150296         and Paul Eggert  <eggert@cs.ucla.edu>
150298         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
150299         in wint_t, not wchar_t.  Remove now-unnecessary cast.
150301 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
150303         * modules/regex (Files): Add lib/regex_internal.c,
150304         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
150305         (Depends-on): Add extensions.
150306         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
150308 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
150310         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
150311         pathconf.
150312         * m4/same.m4 (gl_SAME): Likewise.
150313         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
150315         * m4/regex.m4: Adjust to new libc regex implementation.
150316         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
150317         all the .c and .h parts of (the new) regex.
150318         Quote the m4 stuff better.
150319         Check for RE_ICASE bug of old gnulib.
150320         Check for REG_STARTEND of recent libc.
150321         Rename local variables from jm_* to gl_*.
150322         Quote operand of "test -f".
150323         Say "recent enough" version of libc, not "version 2".
150324         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
150325         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
150326         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
150327         Remove check for btowc, isascii.
150328         Require AM_LANGINFO_CODESET.
150330 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
150332         * lib/regex.c, regex.h: Sync from libc.
150333         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
150334         * lib/regexec.c:
150335         New files, synced from libc, except that regex_internal.h
150336         currently has a small porting fix.
150338 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
150340         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
150341         regex_internal.c, regexec.c.
150342         Add regex_internal.h too, but as a comment, since the libc version
150343         is currently broken in gnulib mode.
150345 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
150347         Support programs like Emacs that use gnulib but not gettext.
150348         * MODULES.html.sh (Internationalization functions): Add gettext-h.
150349         * modules/gettext-h: New file.
150350         * modules/gettext (Files): Remove lib/gettext.h.
150351         (Depends-on): Add gettext-h.
150352         (Makefile.am): Remove lib_SOURCES.
150353         * modules/argmatch, modules/c-stack, modules/closeout:
150354         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
150355         * modules/execute, modules/file-type, modules/getaddrinfo:
150356         * modules/getopt, modules/human, modules/javacomp:
150357         * modules/javaexec, modules/mkdir-p, modules/obstack:
150358         * modules/openat, modules/pagealign_alloc, modules/pipe:
150359         * modules/quotearg, modules/regex, modules/rpmatch:
150360         * modules/unicodeio, modules/userspec, modules/version-etc:
150361         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
150362         * modules/xsetenv:
150363         Depend on gettext-h, not gettext.
150365 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
150367         * gnulib-tool (func_import): Add support for 'public domain' license.
150368         * modules/alloca, modules/atexit, modules/memmove:
150369         Now public domain, not GPL.
150370         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
150371         * modules/realloc, modules/strerror, modules/strtod:
150372         Now LGPL, not GPL.
150374 2005-07-05  Bruno Haible  <bruno@clisp.org>
150376         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
150377         autoconf CVS. Needed for mingw.
150379 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
150381         Remove the dependency of the strftime module on the tzset module.
150382         * modules/strftime (Depends-on): Remove dependency on tzset.
150384 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
150386         Remove the dependency of the strftime module on the tzset module.
150387         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
150388         gl_FUNC_TZSET_CLOBBER.
150390 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
150392         Remove the dependency of the strftime module on the tzset module.
150393         * lib/strftime.c (my_strftime)
150394         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
150395         Copy the input structure, to work around some of the bug with
150396         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
150397         Solaris releases, you should also use the tzset module, but we won't
150398         require it as a dependency any more since we don't want LGPLed code
150399         to depend on GPLed code.
150401 2005-07-02  Jim Meyering  <jim@meyering.net>
150403         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
150404         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
150405         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
150406         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
150408 2005-07-02  Jim Meyering  <jim@meyering.net>
150410         * lib/backupfile.c (backup_args): Change a `0' to NULL.
150412 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
150414         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
150415         declares only 'struct timespec;' (!).
150417 2005-07-01  Jim Meyering  <jim@meyering.net>
150419         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
150420         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
150421         * lib/save-cwd.c, tempname.c:
150422         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
150423         and don't include <sys/file.h>).
150425 2005-06-29  Jim Meyering  <jim@meyering.net>
150427         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
150428         type name.  Use the variable name instead.
150429         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
150430         Likewise.
150432 2005-06-28  Simon Josefsson  <jas@extundo.com>
150434         * modules/check-version (Files): Add check-version.m4.
150436 2005-06-28  Simon Josefsson  <jas@extundo.com>
150438         * m4/check-version.m4: New file, suggested by Jim Meyering
150439         <jim@meyering.net>.
150441 2005-06-28  Simon Josefsson  <jas@extundo.com>
150443         * lib/check-version.h, lib/check-version.c: New files.
150445 2005-06-28  Simon Josefsson  <jas@extundo.com>
150447         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
150448         collision with global variable.  Better indentation.  Don't
150449         increment buffer pointer beyond buffer end.  Based on comments
150450         from Paul Eggert <eggert@cs.ucla.edu>.
150452         * lib/base64.h: Indent.
150454 2005-06-28  Simon Josefsson  <jas@extundo.com>
150456         * doc/gnulib.texi (Library version handling): New section.
150458 2005-06-28  Jim Meyering  <jim@meyering.net>
150460         * check-module (find_included_lib_files): Hard-code another
150461         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
150462         but modules/fts-lgpl (correctly) does not list those files.
150464         * modules/canonicalize (Files): Add lib/pathmax.h.
150466 2005-06-25  Simon Josefsson  <jas@extundo.com>
150468         * modules/check-version: New file.
150470 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
150472         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
150473         initializer of struct addrinfo, as an indication that we don't
150474         care how many members the structure has.
150476 2005-06-24  Derek Price  <derek@ximbiot.com>
150477         and Bruno Haible  <bruno@clisp.org>
150479         Remove stat module & update lstat.
150480         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
150481         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
150482         * m4/stat.m4: Remove this file.
150484 2005-06-24  Derek Price  <derek@ximbiot.com>
150485         and Bruno Haible  <bruno@clisp.org>
150487         Remove stat module & update lstat.
150488         * lib/stat.c: Remove this file...
150489         (slash_aware_lstat): ...moving this content and its support...
150490         * lib/lstat.c (rpl_lstat): ...into here.
150491         * lib/lstat.h: New file.
150493 2005-06-24  Derek Price  <derek@ximbiot.com>
150494         and Bruno Haible  <bruno@clisp.org>
150496         Remove stat module & update lstat.
150497         * config/srclist.txt (libc sources): Remove stat.
150499 2005-06-24  Derek Price  <derek@ximbiot.com>
150500         and Bruno Haible  <bruno@clisp.org>
150502         Remove stat module & update lstat.
150503         * MODULES.html.sh (stat): Remove.
150504         * MODULES.html: Regenerated.
150505         * modules/lstat (Description): Correct function name.
150506         (Files): Add "lstat.h".
150507         (Depends-on): Remove stat, add xalloc, stat-macros.
150508         * modules/stat: Remove this file.
150509         (Include): Add "lstat.h", remove <sys/stat.h>.
150511 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
150513         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
150514         (ranged_convert): Don't save conversion in a temporary struct.
150515         This causes a warning with GCC 4.0.0, and anyway in the typical
150516         case it's not worth the extra 100 bytes or so of code.
150517         (ranged_convert, __mktime_internal): When calling a function via a
150518         pointer P, use P () rather than (*P) (), as we now assume C89 or
150519         better.
150521 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
150523         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
150524         "who -r" failed to give output.  Problem reported by Tim Waugh.
150526         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
150527         (xcalloc): Use it to avoid needless tests.
150528         Problem reported by Jim Meyering.
150530 2005-06-20  Derek Price  <derek@ximbiot.com>
150532         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
150533         unnecessary for Autoconfs > 2.59c.
150535 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
150537         * lib/argp.h (__option_is_short): Check upper limit of
150538         __key. Isprint() requires its argument to have the value
150539         of an unsigned char or EOF.
150541 2005-06-16  Jim Meyering  <jim@meyering.net>
150543         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
150544         when either N or S is zero.
150546 2005-06-16  Derek Price  <derek@ximbiot.com>
150548         * m4/bison.m4: Declare YACC & YFLAGS precious.
150550 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
150552         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
150553         multibyte string or pattern, fall back on unibyte matching.
150554         Problem reported by James Youngman.
150556 2005-06-08  Bruno Haible  <bruno@clisp.org>
150558         * modules/csharpcomp: New file.
150559         * MODULES.html.sh (C#): Add csharpcomp.
150561 2005-06-08  Bruno Haible  <bruno@clisp.org>
150563         * m4/csharpcomp.m4: New file, from GNU gettext.
150565 2005-06-08  Bruno Haible  <bruno@clisp.org>
150567         * lib/csharpcomp.h: New file, from GNU gettext.
150568         * lib/csharpcomp.c: New file, from GNU gettext.
150569         * lib/csharpcomp.sh.in: New file, from GNU gettext.
150571 2005-06-08  Bruno Haible  <bruno@clisp.org>
150573         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
150574         warning on mingw.
150576 2005-06-07  Derek Price  <derek@ximbiot.com>
150578         Sync from CVS.
150579         * lib/glob_.h: Indent nested #ifdef.
150581 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
150583         Sync from coreutils.
150584         Use "file name" when talking about file names, instead of "filename"
150585         or "path", as per the GNU coding standards.
150586         * lib/mkdir-p.c: Renamed from makepath.c.
150587         (make_dir_parents): Renamed from make_path.  All callers changed.
150588         * lib/mkdir-p.h: Likewise.  All includers changed.
150589         * lib/filenamecat.c: Renamed from path-concat.c.
150590         (file_name_concat): Renamed from path_concat.  All callers changed.
150591         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
150592         * lib/filenamecat.h: Likewise.  All includers changed.
150593         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
150594         in comments or local variable names.
150595         * lib/basename.c: Likewise.
150596         * lib/canonicalize.c, canonicalize.h: Likewise.
150597         * lib/dirname.c, dirname.h: Likewise.
150598         * lib/euidaccess.c: Likewise.
150599         * lib/exclude.c: Likewise
150600         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
150601         * lib/fsusage.c, fsuage.h: Likewise.
150602         * lib/fts.c, fts_.h: Likewise.
150603         * lib/getcwd.c: Likewise.
150604         * lib/getloadavg.c: Likewise.
150605         * lib/mkstemp.c: Likewise.
150606         * lib/mountlist.c, mountlist.h: Likewise.
150607         * lib/openat.c, openat.h: Likewise.
150608         * lib/readlink-stub.c: Likewise.
150609         * lib/readutmp.c, readutmp.h: Likewise.
150610         * lib/rename.c: Likewise.
150611         * lib/rmdir.c: Likewise.
150612         * lib/same.c: Likewise.
150613         * lib/savedir.c: Likewise.
150614         * lib/stripslash.c: Likewise.
150615         * lib/tempname.c: Likewise.
150616         * lib/xreadlink.c: Likewise.
150617         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
150618         All uses changed.
150619         * lib/exclude.h: Likewise.
150621         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
150622         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
150623         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
150624         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
150625         * lib/pathmax.h: Include <limits.h> unconditionally, since other
150626         files have been getting away with it for years (MORE/BSD 4.3
150627         is extinct now).
150628         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
150629         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
150631         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
150632         Define to 256, not 255, as per modern POSIX.
150634 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
150636         Sync from coreutils.
150637         Use "file name" when talking about file names, instead of "filename"
150638         or "path", as per the GNU coding standards.
150639         * MODULES.html.sh: mkdir-p renamed from makepath.
150640         filenamecat renamed from path-concat.
150641         * modules/filenamecat: Renamed from modules/path-concat.
150642         (Files): filenamecat.h and filenamecat.c renamed from
150643         path-concat.h and path-concat.c.
150644         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
150645         (Include): filenamecat.h, not path-concat.h.
150646         * modules/mkdir-p: Renamed from modules/makepath.
150647         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
150648         makepath.c.
150649         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
150650         (Include): mkdir-p.h, not makepath.h.
150652 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
150654         Sync from coreutils.
150655         * m4/mkdir-p.m4: Renamed from makepath.m4.
150656         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
150657         Rename files from makepath.c to mkdir-p.c, and from
150658         makepath.h to mkdir-p.h.
150659         * m4/filenamecat.m4: Renamed from path-concat.m4.
150660         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
150661         Rename files from path-concat.c to filenamecat.c,
150662         and from path-concat.h to filenamecat.h.
150663         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
150664         "file name" in local variables or comments.
150665         * m4/rename.m4: Likewise.
150667 2005-06-01  Bruno Haible  <bruno@clisp.org>
150669         * modules/csharpexec: New file.
150670         * MODULES.html.sh (C#): New section.
150672 2005-06-01  Bruno Haible  <bruno@clisp.org>
150674         * m4/csharp.m4: New file, from GNU gettext.
150675         * m4/csharpexec.m4: New file, from GNU gettext.
150677 2005-06-01  Bruno Haible  <bruno@clisp.org>
150679         * lib/csharpexec.h: New file, from GNU gettext.
150680         * lib/csharpexec.c: New file, from GNU gettext.
150681         * lib/csharpexec.sh.in: New file, from GNU gettext.
150683 2005-05-31  Derek Price  <derek@ximbiot.com>
150684             Paul Eggert  <eggert@cs.ucla.edu>
150686         Sync from cvs.
150687         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
150689 2005-05-31  Derek Price  <derek@ximbiot.com>
150690             Paul Eggert  <eggert@cs.ucla.edu>
150692         Sync from cvs.
150693         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
150695 2005-05-29  Derek Price  <derek@ximbiot.com>
150697         * config/srclist.txt (glob_.h, glob.c): Add these files.
150699 2005-05-29  Derek Price  <derek@ximbiot.com>
150701         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
150702         * modules/glob: New file.
150703         * modules/getlogin_r: Add link to POSIX spec in description.
150705 2005-05-29  Derek Price  <derek@ximbiot.com>
150706             Paul Eggert  <eggert@cs.ucla.edu>
150708         * m4/glob.m4: New file.
150710 2005-05-29  Derek Price  <derek@ximbiot.com>
150711             Paul Eggert  <eggert@cs.ucla.edu>
150713         * lib/glob_.h, lib/glob.c: New files.
150715 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
150717         * modules/fts (Files): Remove m4/inttypes-pri.m4.
150718         * modules/fts-lgpl (Depends-on): Remove gettext.
150720 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
150722         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
150723         and don't require gt_INTTYPES_PRI.
150725 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
150727         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
150729         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
150730         the configuration hassle isn't worth it.
150731         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
150732         (LONGEST_MODIFIER, PRIuMAX): Remove.
150734 2005-05-27  Bruno Haible  <bruno@clisp.org>
150736         * lib/getlogin_r.h: Remove second include of <stddef.h>.
150738 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
150740         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
150741         _POSIX_PTHREAD_SEMANTICS for Solaris.
150743 2005-05-25  Derek Price  <derek@ximbiot.com>
150745         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
150747 2005-05-25  Derek Price  <derek@ximbiot.com>
150748             Paul Eggert  <eggert@cs.ucla.edu>
150750         * modules/getlogin_r, m4/getlogin_r.m4: New files.
150751         * lib/getlogin_r.c, getlogin_r.h: New files.
150753 2005-05-25  Bruno Haible  <bruno@clisp.org>
150754             Derek Price  <derek@ximbiot.com>
150756         * lib/getlogin_r.h: Simplify API documentation.
150758 2005-05-23  Derek Price  <derek@ximbiot.com>
150760         * modules/minmax (Files): Add m4/minmax.m4.
150761         (configure.ac): Add gl_MINMAX.
150763 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
150765         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
150766         so that unistd-safer.h (GPL'ed code) need not be included.
150768 2005-05-22  Bruno Haible  <bruno@clisp.org>
150770         * m4/minmax.m4: New file.
150771         Based on a patch by Derek Price <derek@ximbiot.com>.
150773 2005-05-22  Bruno Haible  <bruno@clisp.org>
150775         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
150776         (INT64_MIN): Fix definition.
150777         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
150779         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
150780         NEED_SIGNED_INT_TYPES.
150782         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
150783         HAVE_SYSTEM_INTTYPES.
150785 2005-05-22  Bruno Haible  <bruno@clisp.org>
150787         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
150788         Also include <sys/param.h> if it defines MIN, MAX.
150789         Based on a patch by Derek Price <derek@ximbiot.com>.
150791 2005-05-21  Jim Meyering  <jim@meyering.net>
150793         * modules/fts (Files): Add m4/inttypes-pri.m4.
150794         (Depends-on): Add lstat and remove gettext.  Alphabetize.
150796 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
150798         New fts module.
150799         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
150800         (setup_dir, free_dir): New functions.
150801         (enter_dir, leave_dir): Define trivial
150802         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
150803         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
150804         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
150805         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
150806         Move to fts-cycle.c.
150807         (fts_open): Use setup_dir.
150808         (fts_close): Use free_dir.
150809         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
150810         This adds a label and some gotos, but the alternatives were messier.
150811         Check for memory allocation failure when entering a dir.
150812         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
150813         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
150814         (FTS): New member fts_cycle, that is a union that contains the
150815         old active_dir_ht and cycle_state.  All uses changed to mention
150816         fts_cycle.ht and fts_cycle.state.
150817         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
150818         fts.c, with the following changes:
150819         (setup_dir, free_dir): New functions.
150820         (enter_dir): Now returns bool.  Return true if successful, false
150821         if memory exhausted.  All callers changed.
150822         Do not bother partly cleaning up on
150823         memory allocation failure; that is free_dir's job.
150824         However, free ad if hash_insert fails, to avoid memory leak.
150825         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
150826         fts->fts_options to see which union member to use.
150828 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
150830         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
150831         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
150833 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
150835         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
150837 2005-05-20  Jim Meyering  <jim@meyering.net>
150839         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
150840         Now a macro, to pacify GCC.
150842 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
150844         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
150845         of -1.
150847 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
150849         * lib/chown.c (rpl_chown): Return -1 on failure.
150851 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
150853         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
150854         Don't check for stddef.h.
150855         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
150856         don't use its results.
150857         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
150858         since we include them unconditionally.  Don't require
150859         AM_STDBOOL_H, since stdbool is a prerequisite.
150860         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
150861         since we assume C89 or better.
150862         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
150863         as we don't use their results.
150864         Don't check for fchdir, memmove, memset, strrchr, as we use
150865         them unconditionally.
150866         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
150867         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
150869 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
150871         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
150872         Include <stddef.h> unconditionally, since we assume C89 now.
150873         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
150874         * lib/fts.c: Include fts_.h first, to check interface.
150875         Do not include intprops.h; no longer needed.
150876         Include cycle-check.h and hash.h, since fts_.h no longer does.
150877         Remove unnecessary casts of closedir to void.
150878         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
150879         decide whether to decrement nlinks.
150880         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
150881         (FTS): Use struct hash_table * instead of Hash_table, so that
150882         we no longer need to include hash.h here.
150884 2005-05-18  Jim Meyering  <jim@meyering.net>
150886         * modules/dirfd (License): Change to LGPL.  Most of the code
150887         is already in the public domain.
150889 2005-05-18  Jim Meyering  <jim@meyering.net>
150891         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
150892         Reported by Yoann Vandoorselaere.
150894 2005-05-17  Jim Meyering  <jim@meyering.net>
150896         * m4/fts.m4: New file, from coreutils.
150898 2005-05-17  Jim Meyering  <jim@meyering.net>
150900         * lib/fts.c, lib/fts_.h: New files, from coreutils.
150902 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
150904         Sync from coreutils.
150905         * m4/unlinkdir.m4: New file.
150907 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
150909         Sync from coreutils.
150910         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
150911         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
150912         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
150913         White space changes only.
150914         * lib/makepath.c (make_path): Port to hosts where leading "//" is
150915         special.
150916         * lib/yesno.c: Include getline.h, not ctype.h.
150917         (yesno): Don't remove leading white space; POSIX doesn't allow it.
150918         Use getline to remove arbitrary restriction on response length.
150920 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
150922         * config/srclist-update: Spell out "Street" in FSF postal
150923         mail address; this is the style the FSF seems to prefer.
150925         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
150926         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
150927         this updates FSF postal mail address.
150929         Sync from coreutils.
150930         * modules/unlinkdir: New file.
150931         * modules/yesno (Depends-on): Add getline.
150932         * MODULES.html.sh (File system functions): Add unlinkdir.
150934 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
150936         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
150937         lib/strsep.h:
150938         Change the initial comment to refer to GPL, not LGPL.
150939         gnulib-tool will change it to LGPL as needed.
150941         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
150942         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
150943         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
150944         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
150945         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
150946         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
150947         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
150948         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
150949         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
150950         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
150951         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
150952         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
150953         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
150954         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
150955         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
150956         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
150957         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
150958         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
150959         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
150960         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
150961         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
150962         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
150963         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
150964         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
150965         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
150966         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
150967         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
150968         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
150969         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
150970         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
150971         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
150972         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
150973         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
150974         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
150975         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
150976         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
150977         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
150978         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
150979         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
150980         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
150981         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
150982         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
150983         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
150984         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
150985         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
150986         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
150987         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
150988         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
150989         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
150990         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
150991         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
150992         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
150993         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
150994         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
150995         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
150996         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
150997         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
150998         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
150999         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
151000         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
151001         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
151002         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
151003         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
151004         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
151005         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
151006         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
151007         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
151008         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
151009         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
151010         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
151011         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
151012         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
151013         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
151014         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
151015         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
151016         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
151017         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
151018         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
151019         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
151020         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
151021         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
151022         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
151023         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
151024         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
151025         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
151026         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
151027         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
151028         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
151029         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
151030         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
151031         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
151032         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
151033         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
151034         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
151035         lib/yesno.c, lib/yesno.h:
151036         Update FSF postal mail address.
151038 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
151040         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
151041         tests/test-memmem.c, tests/test-stpncpy.c:
151042         Update FSF postal mail address.
151044 2005-05-13  Bruno Haible  <bruno@clisp.org>
151046         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
151047         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
151048         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
151049         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
151050         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
151051         Add support for 64-bit integers in the MSVC compiler.
151053 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
151055         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
151057 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
151059         * gnulib-tool (func_import): Sort and uniquify recommended includes.
151061 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
151063         * doc/getdate.texi (General date syntax): Don't say that date
151064         date --iso-8601=ns generates acceptable dates; it doesn't yet.
151065         Problem reported by Nic Ferrier.
151067 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
151069         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
151070         specified in ai_socktype. Fix invalid ai_protocol
151071         check. ai_protocol is usually set to 0 or depending on
151072         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
151073         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
151074         ai_socktype / ai_protocol in the returned addrinfo structure.
151076 2005-05-10  Simon Josefsson  <jas@extundo.com>
151078         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
151079         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
151081 2005-05-10  Karl Berry  <karl@gnu.org>
151083         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
151084         (from http://www.gnu.org/licenses).
151085         * doc/COPYING.LIB: also rename to COPYING.LESSER.
151086         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
151087         fdl.texi suffices.
151089 2005-05-10  Karl Berry  <karl@gnu.org>
151091         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
151092         (COPYING.DOC): remove.
151094         * config/srclist-update: new FSF address.
151096 2005-05-10  Derek Price  <derek@ximbiot.com>
151098         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
151099         possible.
151101 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
151102             Bruno Haible  <bruno@clisp.org>
151104         * modules/inet_ntop: New file.
151105         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
151106         inet_ntop.
151108 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
151109             Bruno Haible  <bruno@clisp.org>
151111         * m4/inet_ntop.m4: New file.
151113 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
151114             Bruno Haible  <bruno@clisp.org>
151116         * lib/inet_ntop.h: New file.
151117         * lib/inet_ntop.c: New file, from glibc with modifications.
151119 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
151121         * modules/time_r (License): Change to LGPL.
151122         * modules/extensions (License): Change to LGPL.  Actually,
151123         the license is more permissive than that, but currently gnulib-tool
151124         doesn't know how to handle more-permissive licenses.
151126         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
151127         Problem reported by Dave Love.
151129 2005-05-08  Jim Meyering  <jim@meyering.net>
151131         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
151132         blank.
151134 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
151136         * modules/argmatch (Depends-on): Add stdbool.
151137         * modules/backupfile (Depends-on): Likewise.
151138         * modules/chdir-long (Depends-on): Likewise.
151139         * modules/closeout (Depends-on): Likewise.
151140         * modules/cycle-check (Depends-on): Likewise.
151141         * modules/dirname (Depends-on): Likewise.
151142         * modules/fnmatch (Depends-on): Likewise.
151143         * modules/fsusage (Depends-on): Likewise.
151144         * modules/fwriteerror (Depends-on): Likewise.
151145         * modules/getcwd (Depends-on): Likewise.
151146         * modules/getloadavg (Depends-on): Likewise.
151147         * modules/hard-locale (Depends-on): Likewise.
151148         * modules/makepath (Depends-on): Likewise.
151149         * modules/mountlist (Depends-on): Likewise.
151150         * modules/nanosleep (Depends-on): Likewise.
151151         * modules/posixtm (Depends-on): Likewise.
151152         * modules/quotearg (Depends-on): Likewise.
151153         * modules/readtokens (Depends-on): Likewise.
151154         * modules/readtokens0 (Depends-on): Likewise.
151155         * modules/readutmp (Depends-on): Likewise.
151156         * modules/save-cwd (Depends-on): Likewise.
151157         * modules/strftime (Depends-on): Likewise.
151158         * modules/userspec (Depends-on): Likewise.
151159         * modules/utimecmp (Depends-on): Likewise.
151160         * modules/xgetcwd (Depends-on): Likewise.
151161         * modules/xnanosleep (Depends-on): Likewise.
151162         * modules/xstrtod (Depends-on): Likewise.
151163         * modules/yesno (Depends-on): Likewise.
151165 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
151167         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
151168         needless checks.
151170 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
151172         Merge from coreutils.  Among other things,
151173         add bulletproofing for cases where stdin, stdout, or stderr are closed.
151174         * lib/fd-safer.c: New file.
151175         * lib/fcntl-safer.h, open-safer.c: Remove.
151176         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
151177         * lib/dup-safer.c: Include unistd-safer.h first.
151178         Don't include errno.h.
151179         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
151180         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
151181         * lib/file-type.c: Rely on file-type.h change.
151182         * lib/getloadavg.c: Include unistd-safer.h.
151183         (getloadavg): Use safer open.
151184         * lib/getusershell.c: Include "stdio-safer.h".
151185         (getusershell): Use safer fopen.
151186         * lib/long-options.c (long_options): Use NULL rather than 0.
151187         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
151188         'free'.
151189         * lib/modechange.c: Likewise.
151190         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
151191         (MODE_DONE): New constant.
151192         (struct mode_change): Remove 'next' member.
151193         (make_node_op_equals): New function; like the old one of the
151194         same name, except it allocates an array.
151195         (mode_compile, mode_create_from_ref): Use it.
151196         (mode_compile): Allocate result as an array, not a linked list.
151197         Parse octal string ourself, so that we catch mistakes like "+0".
151198         (mode_adjust): Arg is an array, not a linked list.
151199         * lib/modechange.c: Include stat-macros.h, xalloc.h.
151200         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
151201         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
151202         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
151203         Remove.  This is now stat-macros.h's job.
151204         (talloc): Remove.  All callers replaced by xalloc, so that
151205         our invokers don't have to worry about reporting memory failures.
151206         (make_node_op_equals): Remove.
151207         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
151208         New constants.
151209         (struct mode_change): Moved here from modechange.h.
151210         (mode_append_entry): Remove.
151211         (mode_compile): Remove MASKED_OPS arg, since it encouraged
151212         apps to have incorrect behavior.  Use simpler algorithm for head
151213         and tail.  Don't futz with umask; that's now the job of mode_adjust.
151214         Detect more invalid usages rather than having somewhat-random behavior.
151215         Don't insert an "a=" action, as that leads to incorrect behavior.
151216         (mode_compile, mode_create_from_ref): Return NULL on error instead
151217         of an enum, since now there's only one way to have an error.  All
151218         callers changed.
151219         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
151220         at the correct time.  Simplify calculation of "+u" and its ilk.
151221         Don't mishandle "+X".
151222         (mode_free): Remove "register" and localize decls.
151223         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
151224         (struct mode_change): Move to modechange.c; callers don't
151225         need to see this stuff.
151226         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
151227         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
151228         (mode_change, mode_adjust): Reflect the new signatures noted above.
151229         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
151230         that might redefine system include files.
151231         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
151232         (my_usleep): Use NULL rather than (void *) 0.
151233         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
151234         Use siginterrupt to specify that system calls should be interrupted.
151235         (rpl_nanosleep): Move initialization of suspended closer to call of
151236         my_usleep.
151237         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
151238         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
151239         (desirable_utmp_entry): New function.
151240         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
151241         using x2nrealloc, to simplify logic.
151242         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
151243         size calculation.  Do not assume utmp file is a regular file.
151244         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
151245         (READ_UTMP_CHECK_PIDS): New constant.
151246         * lib/save-cwd.c: Include unistd-safer.h.
151247         (save_cwd): Use fd_safer.
151248         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
151249         [!_LIBC] Include "stat-macros.h" instead.
151250         * lib/unistd-safer.h (fd_safer): New decl.
151252 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
151254         * modules/getloadavg (Depends-on): Add unistd-safer.
151255         * modules/getusershell (Depends-on): Add stdio-safer.
151256         * modules/lstat (Depends-on): Remove xalloc.
151257         * modules/mkstemp (Depends-on): Add stat-macros.
151258         * modules/modechange (Depends-on): Remove xstrtol.
151259         Add stat-macros, xalloc.
151260         * modules/save-cwd (Depends-on): Add unistd-safer.
151261         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
151262         * modules/unistd-safer (Files): Add lib/fd-safer.c
151263         (Makefile.am): Remove lib_SOURCES.
151265         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
151266         Remove fcntl-safer; unistd-safer supersedes it.
151268 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
151270         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
151271         AC_HEADER_STAT.
151272         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
151273         (gl_PREREQ_CHOWN): Remove.
151274         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
151275         it.  Don't require AC_HEADER_STAT.
151276         (gl_PREREQ_LSTAT): Remove.
151277         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
151278         Don't require AC_HEADER_STAT.
151279         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
151280         (gl_PREREQ_RMDIR): Remove.
151281         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
151282         mention stat-macros.h or AC_HEADER_STAT, since we'll make
151283         the stat-macros module a prerequisite.
151284         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
151285         * m4/filemode.m4 (gl_FILEMODE): Likewise.
151286         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
151287         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
151288         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
151289         variable names.
151290         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
151291         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
151292         variable prefixes.
151293         * m4/fcntl-safer.m4: Remove.
151294         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
151295         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
151296         Invoke gl_PREREQ_FD_SAFER.
151297         (gl_PREREQ_FD_SAFER): New macro.
151298         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
151299         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
151300         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
151301         Remove duplicate call to AC_LIBOBJ(readutmp).
151302         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
151304         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
151305         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
151307 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
151309         * MODULES.html.sh (Misc): Add byteswap.
151311 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
151313         * modules/getcwd (Depends-on): Add extensions.
151314         * modules/openat (Depends-on): Likewise.
151316 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
151318         * modules/byteswap: New file.
151320 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
151322         * m4/byteswap.m4: New file.
151324 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
151326         * lib/byteswap_.h: New file.
151328 2005-04-25  Karl Berry  <karl@gnu.org>
151330         * m4/gettext.m4: Update from GNU gettext 0.14.4.
151332 2005-04-25  Albert Chin  <china@thewrittenword.com>
151334         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
151335         Toolkit C bug.
151337 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
151339         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
151340         (func_ln_if_changed): Remove forcibly for no error message
151341         in case file does not exist.
151343 2005-04-19  Simon Josefsson  <jas@extundo.com>
151345         * gnulib-tool (Options): Make --symlink mean --symbolic.
151347 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
151349         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
151351 2005-04-16  Simon Josefsson  <jas@extundo.com>
151353         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
151355 2005-04-15  Simon Josefsson  <jas@extundo.com>
151357         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
151359 2005-04-15  Simon Josefsson  <jas@extundo.com>
151361         * gnulib-tool: Rename --symlink to --symbolic.
151363 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
151365         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
151366         symbolic links to files instead of copying/moving.  Add --aux-dir,
151367         specifying directory relative --dir where auxiliary build tools
151368         are placed.
151370 2005-04-14  Bruno Haible  <bruno@clisp.org>
151372         * modules/allocsa (License): Change to LGPL.
151373         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
151375 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
151377         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
151378         that "UTC +1 second" continues to work.  Problem reported
151379         by Dmitry V. Levin.
151380         (relunit_snumber): New rule.
151381         (relunit): Use it.
151383 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
151385         * lib/getdate.y (universal_time_zone_table): New constant.
151386         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
151387         universal_time_zone_table.
151388         (lookup_zone): Prefer universal_time_zone_table to
151389         local_time_zone_table, so that "GMT" time stamps are allowed in
151390         London during the summer.  Problem reported by Ian Abbott.
151392 2005-04-12  Jim Meyering  <jim@meyering.net>
151394         * lib/human.c (humblock): Set *options even when returning due to
151395         xstrtoumax conversion failure.  Thanks to a used-uninitialized
151396         warning from gcc-4.
151398 2005-04-09  Jim Meyering  <jim@meyering.net>
151400         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
151401         -Wuninitialized: initialize tm0.tm_year.
151403 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
151405         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
151406         count, since there's no maximum.  All uses changed.
151407         Add member dsts_seen.
151408         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
151409         not being INT_MAX.
151410         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
151411         Use pc_rels_seen to decide whether a date is absolute.
151413         * lib/getdate.y (number): Don't overwrite year.
151414         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
151415         check.
151417 2005-04-02  Simon Josefsson  <jas@extundo.com>
151419         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
151420         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
151422 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
151424         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
151425         where no absolute path name can be longer than PATH_MAX.
151427 2005-03-27  Jim Meyering  <jim@meyering.net>
151429         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
151431 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
151433         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
151434         "one's complement" -> "ones' complement" in comment, as per Knuth.
151435         "value of type" -> "type or expression" in comment.
151436         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
151438 2005-03-26  Jim Meyering  <jim@meyering.net>
151440         Comment nits.
151441         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
151442         Correct typos: s/or/of/.
151444 2005-03-26  Jim Meyering  <jim@meyering.net>
151446         * modules/check-include-files: Move to ../ and rename to...
151447         * check-module: ...this.
151449 2005-03-25  Jim Meyering  <jim@meyering.net>
151451         * modules/xvasprintf (Files): Add xalloc.h.
151453 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
151455         * modules/gettext (Files): config/config.rpath ->
151456         build-aux/config.rpath
151457         * modules/iconv (Files): Likewise.
151458         Problem reported by Oskar Liljeblad.
151460 2005-03-23  Jim Meyering  <jim@meyering.net>
151462         * modules/check-include-files: New script to check for
151463         missing dependencies, multiple includes, etc.
151465         * modules/c-strtold (Depends-on): Add xalloc.
151466         * modules/c-strtod (Depends-on): Add xalloc.
151467         * modules/hash (Depends-on): Add xalloc.
151468         (Files): Remove lib/xalloc.h.
151470         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
151471         * modules/userspec (Files): Add lib/inttostr.h.
151473 2005-03-23  Jim Meyering  <jim@meyering.net>
151475         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
151477 2005-03-22  Jim Meyering  <jim@meyering.net>
151479         * modules/stat-macros: New module.
151480         * modules/canonicalize, modules/euidaccess, modules/file-type,
151481         * modules/filemode, modules/lchown, modules/makepath,
151482         * modules/rmdir, modules/stat: Depend on new stat-macros module
151483         rather than listing lib/stat-macros.h manually.
151484         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
151486 2005-03-22  Jim Meyering  <jim@meyering.net>
151488         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
151490 2005-03-22  Bruno Haible  <bruno@clisp.org>
151492         * config/srclist.txt: Replace target directory 'config' with
151493         'build-aux'.
151494         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
151495         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
151496         ../build-aux/.
151498 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
151500         * modules/chdir-long (Depends-on): Add mempcpy.
151502         * modules/acl, modules/backupfile, modules/c-strtod,
151503         modules/c-strtold, modules/canon-host, modules/canonicalize,
151504         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
151505         modules/exclude, modules/exitfail, modules/file-type,
151506         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
151507         modules/getdate, modules/getline, modules/getpagesize,
151508         modules/getpass, modules/getugroups, modules/group-member,
151509         modules/hard-locale, modules/hash, modules/human, modules/idcache,
151510         modules/inttostr, modules/long-options, modules/makepath,
151511         modules/md5, modules/memcasecmp, modules/memcoll,
151512         modules/modechange, modules/mountlist, modules/path-concat,
151513         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
151514         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
151515         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
151516         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
151517         modules/strftime, modules/strndup, modules/strverscmp,
151518         modules/timespec, modules/unlocked-io, modules/userspec,
151519         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
151520         modules/yesno:
151521         Remove lib_SOURCES line from Makefile.am section, as this is now
151522         done automatically by the corresponding Autoconf macro.
151524 2005-03-21  Jim Meyering  <jim@meyering.net>
151526         Changes imported from coreutils.
151528         * lib/cycle-check.c: Don't include xalloc.h.
151530         * lib/path-concat.c: Don't include assert.h.
151531         (path_concat): Remove assertion that would have triggered
151532         for ABASE starting with more than one slash.
151533         Reported by Andreas Schwab.
151535         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
151536         properly when ABASE is an absolute file name.
151537         Correct the description of this function.
151538         Include <assert.h>.
151539         Add an assertion and a test driver.
151540         This fixes a bug introduced on 2004-07-02.
151541         Andreas Schwab reported the resulting failure of cp --parents:
151542         http://lists.gnu.org/r/bug-coreutils/2005-01/msg00130.html
151544 2005-03-21  Jim Meyering  <jim@meyering.net>
151546         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
151547         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
151549 2005-03-21  Jim Meyering  <jim@meyering.net>
151550         and  Paul Eggert  <eggert@cs.ucla.edu>
151552         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
151553         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
151554         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
151555         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
151556         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
151557         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
151558         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
151559         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
151560         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
151561         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
151562         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
151563         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
151564         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
151565         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
151566         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
151567         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
151568         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
151569         for these modules.
151571 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
151573         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
151574         (which shouldn't happen), generate nothing instead of returning 0
151575         immediately, so that nstrftime (NULL, ...) doesn't return 0.
151577 2005-03-16  Bruno Haible  <bruno@clisp.org>
151579         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
151580         HAVE_LONGLONG_64BIT.
151582 2005-03-16  Bruno Haible  <bruno@clisp.org>
151584         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
151585         HAVE_LONGLONG_64BIT.
151587 2005-03-16  Bruno Haible  <bruno@clisp.org>
151589         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
151590         HAVE_LONGLONG_64BIT.
151592 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
151594         * lib/strftime.c (my_strftime): Prepend space to format so that we can
151595         reliably distinguish strftime failure from empty output on POSIX
151596         hosts.
151598 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
151600         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
151601         (iconv_string): Don't guess a size-zero buffer, as that might cause
151602         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
151603         result would be 'too large', where 'too large' is (heuristically)
151604         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
151605         overflow concerns.  This will prevent some unwanted malloc failures
151606         when the inputs are very large.
151608 2005-03-15  Karl Berry  <karl@gnu.org>
151610         * config/srclist.txt (config.rpath): from gettext.
151611         * config/config.rpath: update.
151613 2005-03-15  Bruno Haible  <bruno@clisp.org>
151615         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
151616         to 'negate'.
151618         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
151619         variable.
151621         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
151622         results.
151624 2005-03-14  Simon Josefsson  <jas@extundo.com>
151626         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
151627         <fx@gnu.org>.
151629 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
151631         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
151632         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
151633         intprops.h.
151634         * lib/strtol.c: Likewise.
151636 2005-03-14  Jim Meyering  <jim@meyering.net>
151638         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
151639         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
151640         to be nonzero so that we (and caller) can detect the difference
151641         between a valid zero-length expansion and an error return, even
151642         when the underlying strftime fails before writing anything into
151643         that location.
151645 2005-03-14  Bruno Haible  <bruno@clisp.org>
151647         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
151648         Update from GNU gettext 0.14.3.
151650 2005-03-10  Jim Meyering  <jim@meyering.net>
151652         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
151654 2005-03-10  Jim Meyering  <jim@meyering.net>
151656         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
151657         so that this module works on systems without fchdir.
151659 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
151661         Factor int-properties macros into a single file, except for
151662         glibc-related files.
151663         * lib/intprops.h: New file.
151664         * lib/getloadavg.c: Include it instead of limits.h.
151665         (INT_STRLEN_BOUND): Remove.
151666         * lib/human.c: Include intprops.h.
151667         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
151668         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
151669         302/1000.
151670         * lib/inttostr.h: Include intprops.h instead of limits.h.
151671         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
151672         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
151673         for consistency with intprops.h.
151674         (time_t_is_integer, twos_complement_arithmetic): Use them.
151675         * lib/sig2str.h: Include <signal.h>, intprops.h.
151676         (INT_STRLEN_BOUND): Remove.
151677         * lib/strftime.c (TYPE_SIGNED): Remove.
151678         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
151679         * lib/strtol.c: Adjust comments to match intprops.h.
151680         * lib/userspec.c: Include intprops.h.
151681         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
151682         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
151683         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
151684         instead of rolling our own expressions.
151685         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
151687         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
151688         instead of int.
151689         (my_strftime): Do not mishandle years close to INT_MAX, by doing
151690         the right thing even if adding 1900 would overflow.  Similarly
151691         for tm_mon + 1 and tm_yday + 1.
151692         Make %Y always equivalent to %C%y, and similarly for %G and %g.
151693         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
151694         (DO_SIGNED_NUMBER): New macro.
151695         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
151697 2005-03-07  Bruno Haible  <bruno@clisp.org>
151699         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
151701 2005-03-07  Bruno Haible  <bruno@clisp.org>
151703         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
151705 2005-03-04  Derek R. Price  <derek@ximbiot.com>
151707         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
151708         (func_import): Only replace files via --import when they have actually
151709         changed.
151711 2005-03-03  Derek R. Price  <derek@ximbiot.com>
151713         * m4/mmap-anon.m4: New file.
151714         * m4/pagealign_alloc.m4: New file.
151716 2005-03-03  Derek R. Price  <derek@ximbiot.com>
151717             Bruno Haible  <bruno@clisp.org>
151719         * modules/pagealign_alloc: New file.
151720         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
151722 2005-03-03  Derek R. Price  <derek@ximbiot.com>
151723             Bruno Haible  <bruno@clisp.org>
151725         * lib/pagealign_alloc.h: New file.
151726         * lib/pagealign_alloc.c: New file.
151728 2005-03-03  Bruno Haible  <bruno@clisp.org>
151730         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
151731         Use an all-permissive copyright notice, recommended by RMS.
151733 2005-03-02  Bruno Haible  <bruno@clisp.org>
151735         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
151736         of AIX, the replacement has to be done only after <string.h> is
151737         included, therefore not in config.h. stpncpy.h does the replacement,
151738         and stpncpy.c uses it.
151740 2005-03-02  Bruno Haible  <bruno@clisp.org>
151742         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
151743         stpncpy.c uses it.
151745 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
151747         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
151748         The workaround isn't strictly needed for POSIX conformance, and
151749         it's too much of a pain to configure and maintain.  We'll ask
151750         people to fix their kernels instead.
151751         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
151752         (NANOSLEEP_BUG_WORKAROUND): Remove.
151753         (xnanosleep): Remove the workaround.
151755 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
151757         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
151758         Reported by Derek Price.
151759         (Include): Add "timespec.h".
151761         * modules/xnanosleep (Depends-on): Remove gethrxtime.
151763 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
151765         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
151766         to detect nanosleep bug.
151768 2005-03-01  Bruno Haible  <bruno@clisp.org>
151770         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
151772 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
151774         * modules/gethrxtime: New file.
151775         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
151776         (Depends-on): Add gethrxtime.
151777         (configure.ac): Add gl_XNANOSLEEP.
151778         (Makefile.am): Remove lib_SOURCES line.
151780 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
151782         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
151783         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
151785 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
151787         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
151788         * lib/timespec.h (gettime): Return void, since it always
151789         succeeds now.  All uses changed.
151790         * lib/gettime.c (gettime): Likewise.
151791         [HAVE_NANOTIME]: Prefer nanotime.
151792         Assume gettimeofday succeeds, as POSIX requires.
151793         Assime time () succeeds, since other code already does.
151794         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
151795         (timespec_subtract): Remove.
151796         (NANOSLEEP_BUG_WORKAROUND): New constant.
151797         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
151798         things considerably.  Use it only on GNU/Linux hosts, since the
151799         workaround shouldn't be needed elsewhere.
151801 2005-02-24  Bruno Haible  <bruno@clisp.org>
151803         * modules/gettext (Files): Add m4/glibc2.m4.
151805 2005-02-24  Bruno Haible  <bruno@clisp.org>
151807         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
151808         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
151809         * m4/progtest.m4:
151810         Update from GNU gettext 0.14.2.
151811         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
151813 2005-02-24  Bruno Haible  <bruno@clisp.org>
151815         * lib/localcharset.c: Update from GNU gettext 0.14.2.
151816         * lib/config.charset: Update from GNU gettext 0.14.2.
151818 2005-02-24  Bruno Haible  <bruno@clisp.org>
151820         * lib/gettext.h: Update from GNU gettext 0.14.2.
151822 2005-02-23  Simon Josefsson  <jas@extundo.com>
151824         * m4/iconvme.m4: New file.
151826 2005-02-23  Jim Meyering  <jim@meyering.net>
151828         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
151829         change.
151830         Thanks to Bruno Haible for catching it.
151832 2005-02-22  Simon Josefsson  <jas@extundo.com>
151834         * modules/iconvme: New file.
151836         * MODULES.html.sh: Add iconvme.
151838 2005-02-22  Simon Josefsson  <jas@extundo.com>
151840         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
151842 2005-02-22  Simon Josefsson  <jas@extundo.com>
151844         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
151846 2005-02-22  Jim Meyering  <jim@meyering.net>
151848         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
151849         s/ifndef/ifdef/.
151851 2005-02-20  Neil Conway  <neilc@samurai.com>
151853         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
151854         returned by OSX/Darwin if the specified buffer is not large
151855         enough for the hostname.
151857 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
151859         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
151860         pass it to _help, otherwise the latter coredumps trying to
151861         dereference state.root_argp.
151863 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
151865         * modules/chdir-long (Depends-on): Add memrchr.
151866         * modules/memrchr (Files): Add lib/memrchr.h.
151867         (Include): "memrchr.h".
151869 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
151871         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
151873 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
151875         * lib/memrchr.h: New file.
151876         * lib/chdir-long.c: Include it.
151877         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
151878         Don't bother including stddef.h.
151880 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
151882         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
151883         inclusion.
151884         Include <sys/types.h>, for dev_t.
151885         (ME_DUMMY, ME_REMOTE): Move from here....
151886         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
151887         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
151888         Dmitry V. Levin.
151889         Include mountlist.h first, to test the interface.
151891 2005-01-29  Bruno Haible  <bruno@clisp.org>
151893         * lib/progname.c (program_name): Initialize.
151894         Needed when linking statically on MacOS X.
151896 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
151898         Sync from coreutils.
151899         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
151900         (Depends-on): Add c-strtod.
151901         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
151903 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
151905         Sync from coreutils.
151906         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
151908         Remove files that are specific to coreutils.
151909         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
151911 2005-01-28  Bruno Haible  <bruno@clisp.org>
151913         * modules/javacomp: New file.
151914         * MODULES.html.sh (Java): Add javacomp.
151916 2005-01-28  Bruno Haible  <bruno@clisp.org>
151918         * m4/javacomp.m4: New file, from GNU gettext.
151920 2005-01-28  Bruno Haible  <bruno@clisp.org>
151922         * lib/javacomp.sh.in: New file, from GNU gettext.
151923         * lib/javacomp.h: New file, from GNU gettext.
151924         * lib/javacomp.c: New file, from GNU gettext.
151926 2005-01-26  Simon Josefsson  <jas@extundo.com>
151928         * lib/gai_strerror.c: Use GPL in header.
151930 2005-01-26  Bruno Haible  <bruno@clisp.org>
151932         * modules/javaexec: New file.
151933         * MODULES.html.sh (Java): Add javaexec.
151935 2005-01-26  Bruno Haible  <bruno@clisp.org>
151937         * m4/javaexec.m4: New file, from GNU gettext.
151939 2005-01-26  Bruno Haible  <bruno@clisp.org>
151941         * lib/javaexec.sh.in: New file, from GNU gettext.
151942         * lib/javaexec.h: New file, from GNU gettext.
151943         * lib/javaexec.c: New file, from GNU gettext.
151945 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
151947         * modules/lchown (Depends-on): Remove lchown.h
151949 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
151951         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
151952         must be defined if the header file was not found, in order
151953         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
151955 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
151957         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
151958         initializers for struct pentry_state.
151959         (__argp_error): Check return value of __asprintf
151960         (__argp_failure): Translate error message
151962         * lib/argp-parse.c: Removed braces around the expansion of N_()
151964 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
151966         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
151967         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
151968         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
151969         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
151970         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
151971         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
151972         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
151973         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
151974         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
151975         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
151976         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
151977         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
151978         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
151979         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
151980         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
151981         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
151982         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
151983         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
151984         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
151985         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
151986         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
151987         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
151988         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
151989         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
151990         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
151991         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
151992         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
151993         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
151994         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
151995         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
151996         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
151997         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
151998         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
151999         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
152000         xstrtol.m4, xstrtoumax.m4, yesno.m4:
152001         Use an all-permissive copyright notice, recommended by RMS.
152003 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
152005         * modules/chdir-long (Depends-on): Remove mempcpy.
152007 2005-01-21  Jim Meyering  <jim@meyering.net>
152009         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
152010         same value as for Solaris 9.
152012         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
152013         component length.  This included changing the parameter to be
152014         of type `char *' rather than `char const *'.
152015         * lib/chdir-long.h (chdir_long): Update prototype.
152017         * lib/openat.c (fdopendir, fstatat): New functions.
152018         * lib/openat.h: Include headers required for use of DIR and struct
152019         stat.
152020         [AT_SYMLINK_NOFOLLOW]: Define.
152021         (fdopendir, fstatat): Add prototypes.
152023 2005-01-21  Bruno Haible  <bruno@clisp.org>
152025         * modules/classpath: New file.
152026         * MODULES.html.sh (Java): Add classpath.
152028 2005-01-21  Bruno Haible  <bruno@clisp.org>
152030         * lib/classpath.h: New file, from GNU gettext.
152031         * lib/classpath.c: New file, from GNU gettext.
152033 2005-01-20  Simon Josefsson  <jas@extundo.com>
152035         * modules/version-etc-fsf: New file.
152037 2005-01-20  Simon Josefsson  <jas@extundo.com>
152039         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
152040         * lib/version-etc.c: Remove version_etc_copyright.
152041         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
152042         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
152044 2005-01-20  Simon Josefsson  <jas@extundo.com>
152046         * lib/base64.h (isbase64): Add.
152048         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
152049         using a unsigned prototype, don't inline.
152050         (base64_decode): Use it.
152052 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
152054         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
152055         it.
152057 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
152059         * lib/save-cwd.c (save_cwd): Remove code to support the case
152060         where fchdir is missing or flaky.
152062 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
152064         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
152066 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
152068         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
152069         AC_LIBSOURCES now does this.
152070         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
152071         with new ullong_max module.
152073 2005-01-19  Bruno Haible  <bruno@clisp.org>
152075         * modules/sh-quote: New file.
152076         * MODULES.html.sh (Executing programs): Add sh-quote.
152078 2005-01-19  Bruno Haible  <bruno@clisp.org>
152080         * lib/sh-quote.h: New file, from GNU gettext.
152081         * lib/sh-quote.c: New file, from GNU gettext.
152083 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
152085         Merge from coreutils.
152086         * m4/ullong_max.m4: New file.
152087         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
152088         (gl_MACROS): Assume localeconv exists.
152090 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
152092         Merge changes from coreutils, as described below in several
152093         changelogs dated today.
152095         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
152096         (O_DIRECTORY): Remove; not needed here, since "." must be
152097         a directory.  All uses removed.
152098         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
152099         universal on Suns, and we also need to test for IRIX.
152100         Revamp code to use 'if' rather than '#if'.
152101         Avoid unnecessary comparison of cwd->desc to 0.
152103         * lib/utimens.c (futimens): Robustify the previous patch, by checking
152104         for known valid error numbers rather than observed invalid ones.
152106 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
152108         * modules/ullong_max: New file.
152110         * modules/chdir-long, modules/openat: New files.
152111         * modules/save-cwd (Depends-on): Depend on chdir-long.
152112         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
152114 2005-01-18  Jim Meyering  <jim@meyering.net>
152116         Merge from coreutils.
152117         * m4/chdir-long.m4, m4/openat.m4: New files.
152118         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
152119         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
152120         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
152121         is sane and DOES follow symlinks.  Besides, testing 20 different
152122         systems found no broken chown implementations.
152123         Prompted by a change in rsync's copy of this macro.
152124         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
152126         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
152128         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
152129         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
152130         NULL-means-set-to-current-time semantics.
152131         Remove temporary file immediately, rather than waiting
152132         for configure's at-exit trap code to do it.
152134 2005-01-18  Jim Meyering  <jim@meyering.net>
152136         * lib/version-etc.c (version_etc_copyright): Update copyright date.
152138         * lib/utimens.c (futimens): Account for the fact that futimes
152139         can also fail with errno == ENOSYS or errno == ENOENT.
152140         Patch from Dmitry V. Levin.
152142         Change the name of the robust chdir function from chdir to chdir_long.
152143         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
152144         (restore_cwd): Use chdir_long, not chdir.
152145         * lib/chdir-long.c: Renamed from chdir.c.
152146         * lib/chdir-long.h: Renamed from chdir.h.
152147         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
152148         Hurd.
152150 2005-01-18  Bruno Haible  <bruno@clisp.org>
152152         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
152153         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
152154         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
152155         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
152156         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
152157         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
152158         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
152159         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
152160         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
152161         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
152162         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
152163         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
152164         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
152165         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
152166         Use an all-permissive copyright notice, recommended by RMS.
152168 2005-01-18  Bob Proulx  <bob@proulx.com>
152170         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
152171         simplify offsetof() macro construct to avoid compile failure with
152172         native HP-UX 11.0 ANSI C compiler.
152174 2005-01-17  Bruno Haible  <bruno@clisp.org>
152176         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
152177         redundant because stpncpy.m4 takes care of it.
152179 2005-01-17  Bruno Haible  <bruno@clisp.org>
152181         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
152183 2005-01-17  Bruno Haible  <bruno@clisp.org>
152185         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
152186         used.
152188 2005-01-17  Bruno Haible  <bruno@clisp.org>
152190         * lib/fwriteerror.h (fwriteerror): Change specification to include
152191         fclose.
152192         * lib/fwriteerror.c: Include <stdbool.h>.
152193         (fwriteerror): At the end, close the file stream. Record whether
152194         stdout was already closed.
152196 2005-01-17  Bruno Haible  <bruno@clisp.org>
152198         * lib/execute.c (environ): Declare if needed.
152199         * lib/pipe.c (environ): Likewise.
152200         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
152202 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
152204         * modules/argp: Depend on vsnprintf
152206 2005-01-10  Jim Meyering  <jim@meyering.net>
152208         * modules/closeout (Depends-on): Add atexit.
152210 2005-01-06  Bruno Haible  <bruno@clisp.org>
152212         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
152214 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
152216         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
152217         definitions to be after all include files, to avoid collisions.
152218         Problem reported by Bob Proulx.
152220 2005-01-04  Jim Meyering  <jim@meyering.net>
152222         Changes imported from coreutils.
152223         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
152224         as the mkstemp template, use a temporary directory and an
152225         8.3-friendly template to avoid trouble on systems like DJGPP.
152226         Reported by Juan M. Guerrero via Stepan Kasal.
152227         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
152228         close. Remove the temporary directory right away, rather than waiting
152229         for configure's at-exit trap code to do it.
152230         Suggestion from Stepan Kasal.
152232 2005-01-01  Simon Josefsson  <jas@extundo.com>
152234         * gnulib-tool: Print #include directives when --import'ing.
152236 2004-12-28  Simon Josefsson  <jas@extundo.com>
152238         * tests/test-base64.c: Include required header files.  Remove
152239         unused variables.
152241 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
152243         * modules/error (Depends-on): Remove gettext.
152245 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
152247         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
152248         not needed.  This removes a dependency on the gettext module.
152249         [defined _LIBC]: Do not include <libintl.h>; not needed.
152251 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
152253         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
152254         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
152256 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
152258         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
152259         HAVE_DECL_STRTOLD.
152261 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
152263         * modules/getdate (Depends-on): Remove alloca-opt.
152265 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
152267         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
152269 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
152271         * lib/argp-parse.c: Include <stddef.h>.
152272         (alignof, alignto): New macros.
152273         (parser_init): Don't assume that void * is aligned sufficiently
152274         for struct option.
152276         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
152277         need to extend the stack.
152278         (YYINITDEPTH): New macro, so that the initial stack isn't overly
152279         large.
152281 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
152283         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
152285 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
152287         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
152288         (2004-10-24) change.  Apparently this was a false alarm.
152290         * modules/getdate: Depend on alloca-opt, not alloca.
152292 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
152294         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
152295         Remove now-obsolete comment about AIX.
152296         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
152297         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
152298         (YYMAXDEPTH): New macro.
152300 2004-12-18  Simon Josefsson  <jas@extundo.com>
152302         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
152304 2004-12-18  Bruno Haible  <bruno@clisp.org>
152306         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
152308 2004-12-18  Bruno Haible  <bruno@clisp.org>
152310         * lib/fatal-signal.c (fatal_signals): Make non-const.
152311         (init_fatal_signals): New function.
152312         (uninstall_handlers, install_handlers): Ignore signals that were set to
152313         SIG_IGN.
152314         (at_fatal_signal): Call init_fatal_signals.
152315         (init_fatal_signal_set): Likewise. Ignore signals that were set to
152316         SIG_IGN.
152317         Reported by Paul Eggert.
152319 2004-12-18  Bruno Haible  <bruno@clisp.org>
152321         * doc/alloca.texi: New file.
152322         * doc/alloca-opt.texi: New file.
152324 2004-12-17  Jim Meyering  <jim@meyering.net>
152326         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
152327         Otherwise, install-sh could exit with improper exit status when
152328         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
152330 2004-12-16  Simon Josefsson  <jas@extundo.com>
152332         * tests/test-base64.c: Add license.
152334 2004-12-15  Stepan Kasal  <address@hidden>
152336         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
152338 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
152340         * modules/getcwd (Files): Add m4/d-ino.m4.
152341         Suggested by Mark D. Baushke.
152343 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
152345         * lib/getdate.y (textint): New member "negative".
152346         (time_zone_hhmm): New function.
152347         Expect 14 shift-reduce conflicts, not 13.
152348         (o_colon_minutes): New rule.
152349         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
152350         (yylex): Set the "negative" member of signed numbers.
152352 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
152354         * doc/getdate.texi (Time of day items, Time zone items):
152355         Describe new formats +00:00, UTC+00:00.
152357 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
152359         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
152360         spurious "-l"s.  Problem reported by Stepan Kasal.
152362 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
152364         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
152365         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
152367 2004-12-04  Simon Josefsson  <jas@extundo.com>
152369         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
152370         Vandoorselaere <yoann@prelude-ids.org>.
152372 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
152374         Changes imported from coreutils.
152375         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
152376         exist.
152377         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
152379 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
152381         Changes imported from coreutils.
152382         * lib/hard-locale.c: Assume <locale.h> exists.
152383         Include "strdup.h".
152384         (GLIBC_VERSION): New macro.
152385         (hard_locale): Assume setlocale exists.
152386         Rewrite to avoid #ifdef.
152387         Use strdup rather than malloc + strcpy.
152388         * lib/human.c: Assume <locale.h> exists.
152389         (human_readable): Assume localeconv exists.
152391 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
152393         * modules/hard-locale (Depends-on): Add strdup.
152395 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
152397         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
152398         convert T2, not T.  (Imported from libc.)
152400 2004-11-30  Simon Josefsson  <jas@extundo.com>
152402         * modules/restrict (License): Change to LGPL.
152404 2004-11-30  Simon Josefsson  <jas@extundo.com>
152406         * m4/restrict.m4: Add copyright and copying conditions.
152408 2004-11-30  Simon Josefsson  <jas@extundo.com>
152410         * m4/base64.m4: New file.
152412 2004-11-30  Simon Josefsson  <jas@extundo.com>
152414         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
152415         base64.
152417         * tests/test-base64.c: New file.
152419         * modules/base64: New file.
152421 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
152423         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
152424         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
152426         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
152428 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
152430         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
152431         (__getcwd.c): Don't restore errno; glibc doesn't.
152432         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
152433         first, falling back to our code only if its results look suspicious.
152434         Ensure that the resulting buffer is only as large as necessary.
152436         * lib/readutmp.c: Include readutmp.h first.
152437         Include <errno.h>, since readutmp.h no longer does that.
152438         * lib/readutmp.h: Don't include <errno.h>,
152439         <sys/param.h>, <time.h>; not needed to establish interface.
152440         (errno): Remove decl.
152441         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
152442         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
152443         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
152445 2004-11-28  Simon Josefsson  <jas@extundo.com>
152447         * lib/base64.h, base64.c: New file.
152449 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
152451         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
152453 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
152455         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
152456         (Depends-on): Remove pathmax, same.  Add mempcpy.
152457         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
152458         (Makefile.am): Append getcwd.h to lib_SOURCES.
152459         (Include): Add getcwd.h.
152460         (Maintainer): Change from Jim Meyering to "all, glibc",
152461         since getdate now uses intended-for-glibc code.
152462         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
152463         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
152465 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
152467         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
152468         HP's ANSI C compiler.
152469         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
152470         Declaring int functions causes warnings on some modern systems and
152471         shouldn't be needed to compile on ancient ones.
152472         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
152473         defined.
152475         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
152476         with the following changes.
152477         (__set_errno): Parenthesize properly.
152478         Include <stdbool.h>.
152479         (MIN, MAX, MATCHING_INO): New macros.
152480         (__getcwd): Define with prototype, not K&R form.
152481         Use heuristics to allocate default buffer on stack if possible.
152482         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
152483         behavior, and to avoid the PATH_MAX limit when computing
152484         ../../../../...
152485         Use MATCHING_INO to compare inode number to file.
152486         Check for arithmetic overflow in size calculations.
152487         Fix bug in reallocation of dot array that caused getcwd to fail
152488         on directories nested deeper than 75.
152489         Be more careful about saving errno on error.
152490         Do not use realloc; use only free+malloc, as this is a bit
152491         more flexible and avoids a needless copy operation.
152492         Do not inspect st_dev and st_ino for symbolic links; POSIX
152493         doesn't specify the latter.
152494         Check for closedir errors.
152495         Avoid needless casts.
152496         Use "#ifdef weak_alias" around weak_alias, to be like other
152497         glibc code.
152498         The following changes to getcwd.c have effect only when used in
152499         gnulib; they have no effect inside glibc proper.
152500         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
152501         as alloca isn't used.
152502         (alloca, __alloca): Likewise.
152503         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
152504         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
152505         unconditionally, as gnulib assumes C89 or better.
152506         Do not include <sys/param.h>.
152507         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
152508         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
152509         better.
152510         (NULL) [!defined NULL]: Remove; we assume C89 or better.
152511         Include <dirent.h> in a way that is compatible with modern Autoconf.
152512         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
152513         New macros, if not already defined.
152514         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
152515         Use "_LIBC", not "defined _LIBC", for consistency.
152516         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
152517         a mempcpy module.
152518         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
152519         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
152520         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
152521         credit only to Jim Meyering and adjust the copyright dates.
152522         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
152523         <stdlib.h>, <unistd.h>, "pathmax.h".
152524         Instead, include "xgetcwd.h" (first) and "getcwd.h".
152525         (INITIAL_BUFFER_SIZE): Remove.
152526         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
152528 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
152530         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
152531         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
152532         Use the _ONCE methods, for efficiency.
152533         Check for fcntl.h.  In test program, include <errno.h>
152534         and <fcntl.h> if available.  Remove old K&R cruft from
152535         test program.  Check for common errors in GNU/Linux,
152536         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
152537         don't do AC_LIBOBJ, as that's getcwd.m4's job.
152538         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
152539         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
152540         name accordingly.
152541         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
152542         accommodate new getcwd.c.
152543         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
152544         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
152545         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
152546         that's all we need now.
152548 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
152550         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
152551         argp-parse.c depends on getopt internals, that means we should
152552         always use our getopt, to be on the safe side.
152553         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
152554         order not to spoil the result of an eventual previous invocation
152555         of gl_GETOPT_SUBSTITUTE.
152557 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
152559         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
152560         redefinition warnings. To avoid them, include the defines
152561         in `#if !defined __need_getopt ... #endif'. The only place
152562         where __getopt_argv_const is used is in definitions
152563         of getopt_long and getopt_long_only below, which are as well
152564         protected by `#ifndef __need_getopt'.
152565         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
152566         __need_getopt after including <stdio.h> and <unistd.h> These
152567         headers might have defined it.
152569 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
152571         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
152573 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
152575         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
152576         (futimens): New function, which uses futimes if available.
152577         (futimens, utimens): Support timespec==NULL, with same semantics
152578         as utime and utimens.
152579         * lib/utimens.h (futimens): New decl.
152581 2004-11-23  Jim Meyering  <jim@meyering.net>
152583         * lib/getopt_.h: Remove trailing blanks.
152585 2004-11-23  Jim Meyering  <jim@meyering.net>
152587         * lib/__fpending.c: Add comment.
152589 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
152591         * modules/canonicalize (Depends-on): Add xreadlink.
152592         Problem reported by James Youngman.
152594 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
152596         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
152597         New macros.
152598         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
152599         optopt): Use them instead of invoking ## directly; otherwise, the
152600         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
152602 2004-11-19  Bruno Haible  <bruno@clisp.org>
152604         * lib/strtok_r.c: Move comments from here...
152605         * lib/strtok_r.h: ... to here.
152607 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
152609         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
152610         implementations that mishandle size_t overflow.
152612 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
152614         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
152615         might fail.  Problem reported by Yoann Vandoorselaere.
152616         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
152617         implementations that mishandle size_t overflow.
152619 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
152621         * modules/canon-host (Depends-on): Add strdup.
152623 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
152625         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
152627 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
152629         * lib/canon-host.c: Include "strdup.h".
152630         (canon_host): Use getaddrinfo if available, so that IPv6 works.
152631         Use strdup instead of malloc/strcpy to duplicate strings.
152633         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
152634         (human_space_before_unit): New constant.
152635         * lib/human.c (human_readable): Support it.
152637         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
152638         (xgetcwd): Set errno correctly when failing.
152639         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
152640         the failure is actually due to a PATH_MAX problem.
152642         Further getopt changes to make it more likely that glibc will
152643         buy the changes back.
152644         * lib/getopt.c (POSIXLY_CORRECT): New constant.
152645         (getopt): Use it, so to preserve glibc semantic
152646         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
152647         when compiling for libc.
152648         * lib/getopt_.h (__getopt_argv_const): Bring it back.
152649         (getopt_long, getopt_long_only): Use it.
152651         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
152652         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
152653         (getopt): Argv is now char * const *, as per standard.
152654         (_getopt_internal_r, _getopt_internal): Argv is now char **,
152655         not char *__getopt_argv_const *.
152656         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
152657         _getopt_long_only_r): Likewise.
152658         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
152659         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
152660         _getopt_long_r, _getopt_long_only_r): Likewise.
152661         * lib/getopt_.h (__getopt_argv_const): Remove.
152662         (getopt): Argv is now char * const *, as per standard.
152664         * lib/getdate.y (tORDINAL): New token.
152665         (day, relunit): Allow it for relative times.
152666         (relative_time_table): Use tORDINAL for ordinals.
152668 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
152670         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
152671         Document that "second" isn't allowed as an ordinal number.
152673 2004-11-16  Jim Meyering  <jim@meyering.net>
152675         * modules/closeout (Depends-on): Add fpending.
152677 2004-11-15  Jim Meyering  <jim@meyering.net>
152679         * lib/closeout.c: Include "__fpending.h" once again.
152680         Include <stdbool.h>.
152681         (close_stdout): Don't fail just because stdout was closed initially,
152682         since some programs don't write to stdout in the normal course of
152683         operation (other than --version and --help), and we don't want this
152684         function to make e.g. `touch file >&-' fail.
152685         But do fail if it was closed and someone has tried to write to it.
152686         E.g., `printf foo >&-' must fail.
152688 2004-11-13  Jim Meyering  <jim@meyering.net>
152690         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
152692 2004-11-12  Simon Josefsson  <jas@extundo.com>
152694         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
152695         small doc fix is still pending.
152697 2004-11-11  Simon Josefsson  <jas@extundo.com>
152699         * modules/strtok_r: New file.
152701         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
152702         strtok_r.
152704 2004-11-11  Simon Josefsson  <jas@extundo.com>
152706         * m4/strtok_r.m4: New file.
152708         * m4/getopt.m4: Replace opterr.
152710 2004-11-11  Simon Josefsson  <jas@extundo.com>
152712         * lib/strtok_r.h, strtok_r.c: New file.
152714 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
152716         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
152717         of replacing opterr, getopt, etc.  This should handle the
152718         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
152720 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
152722         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
152723         we can stop lying to compilers about the constness of argv when we
152724         are compiled outside glibc.
152725         (getopt, getopt_long, getopt_long_only): Use it.
152726         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
152727         _getopt_internal, getopt): Likewise.
152728         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
152729         _getopt_long_only_r): Likewise.
152730         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
152731         _getopt_long_r, _getopt_long_only_r): Likewise.
152733         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
152734         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
152735         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
152736         the other external symbols.
152737         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
152738         declaration, since the above renaming now works around collisions.
152740 2004-11-11  Jim Meyering  <jim@meyering.net>
152742         * lib/linebreak.c: Remove trailing blanks.
152743         * lib/alloca_.h: Likewise.
152744         * lib/acosl.c: Likewise.
152745         * lib/euidaccess.c: Likewise.
152746         * lib/allocsa.h: Likewise.
152748 2004-11-10  Simon Josefsson  <jas@extundo.com>
152750         * m4/getaddrinfo.m4: New file.
152752 2004-11-10  Simon Josefsson  <jas@extundo.com>
152754         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
152756 2004-11-10  Simon Josefsson  <jas@extundo.com>
152758         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
152759         getaddrinfo.
152761         * modules/getaddrinfo: New file.
152763 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
152765         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
152767 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
152769         * lib/mktime.c (SHR): New macro, which is a portable
152770         substitute for >> that should work even on Crays.
152771         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
152772         Problem reported by Mark D. Baushke in
152773         <http://lists.gnu.org/r/bug-gnulib/2004-11/msg00071.html>.
152774         * lib/getdate.y (SHR): Likewise.
152775         (tm_diff): Use it.
152776         * lib/strftime.c (SHR): Likewise.
152777         (tm_diff): Use it.
152778         * lib/quotearg.c (struct quoting_options): Use unsigned int for
152779         quote_these_too, so that right shifts are well defined.  All uses
152780         changed.
152782 2004-11-10  Jim Meyering  <jim@meyering.net>
152784         Ensure that no close failure goes unreported.
152785         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
152786         return early when it seems there's nothing to flush.
152787         Don't include __fpending.h.
152789 2004-11-10  Jim Meyering  <jim@meyering.net>
152791         * modules/closeout (Depends-on): Remove fpending.
152793 2004-11-10  Jim Meyering  <jim@meyering.net>
152795         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
152797 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
152799         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
152800         gl_FUNC_STRFTIME.
152801         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
152802         and AC_REQUIRE when possible, to avoid duplicate checks.
152803         Check for <wchar.h>.
152805 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
152807         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
152809 2004-11-09  Bruno Haible  <bruno@clisp.org>
152811         * m4/sockpfaf.m4: New file.
152813 2004-11-05  Bruno Haible  <bruno@clisp.org>
152815         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
152816         Reported by Mark D. Baushke <mdb@cvshome.org>.
152818 2004-11-04  Bruno Haible  <bruno@clisp.org>
152820         2004-09-11  Bruno Haible  <bruno@clisp.org>
152821                 * allocsa.valgrind: New file.
152822         2004-02-06  Bruno Haible  <bruno@clisp.org>
152823                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
152824                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
152825                 Reported by Christopher Seip <chris.seip@hp.com>.
152827 2004-11-04  Bruno Haible  <bruno@clisp.org>
152829         * modules/allocsa (Files): Add lib/allocsa.valgrind.
152830         (Makefile.am): Distribute it.
152832 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
152834         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
152835         with errno == ERANGE if the buffer is too small.
152836         Problem reported by Mark D. Baushke.
152838 2004-11-03  Albert Chin  <china@thewrittenword.com>
152839             Paul Eggert  <eggert@cs.ucla.edu>
152841         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
152842         equivalent, substitute $ac_type for equivalent type rather than
152843         blindly using uint32_t *always* which won't work if uint32_t is not
152844         available.  Define _UINT32_T to work around typedef of uint32_t if
152845         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
152846         2.5.1.
152848 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
152850         * m4/jm-macros.m4: Sync from coreutils.
152851         (gl_MACROS): Check for mbrlen, for pathchk.
152852         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
152854 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
152856         * lib/xreadlink.c (MAXSIZE): New macro.
152857         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
152858         size does not exceed MAXSIZE.  Avoid cast.
152859         As suggested by Mark D. Baushke in
152860         <http://lists.gnu.org/r/bug-gnulib/2004-11/msg00009.html>,
152861         if readlink fails with buffer size just under MAXSIZE, try again
152862         with MAXSIZE.
152864 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
152866         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
152868 2004-11-02  Derek R. Price  <derek@ximbiot.com>
152869         and  Paul Eggert  <eggert@cs.ucla.edu>
152871         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
152872         (get_date): Overparenthesize to avoid GCC warning.
152874 2004-11-02  Bruno Haible  <bruno@clisp.org>
152876         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
152877         returns void.
152879 2004-11-02  Bruno Haible  <bruno@clisp.org>
152881         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
152882         function returns void.
152884 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
152886         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
152887         fflush_unlocked, flockfile, funlockfile, funlockfile,
152888         fputs_unlocked, putc_unlocked.
152890 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
152892         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
152893         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
152894         already declared.
152896 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
152898         * modules/getdate (Files): Add doc/getdate.texi.
152899         (Depends-on): Add setenv, xalloc.
152901 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
152903         * lib/getdate.y: Add support for TZ="foo" within a date string.
152904         Fix some bugs near time_t boundaries.  Reject dates with
152905         out-of-range components, e.g., "Sept 31".
152906         Include <stdlib.h>, "setenv.h", "xalloc.h".
152907         (ISDIGIT_LOCALE): Remove; unused.
152908         Note that the TZ and time functions used here are not reentrant.
152909         (mktime_ok, get_tz): New functions.
152910         (TZBUFSIZE): New constant.
152911         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
152912         This requires that we sometimes generate our own TZ="XXX..." setting.
152914 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
152916         * doc/getdate.texi: New file, from coreutils with modifications for
152917         the new TZ parsing.
152919 2004-10-27  Derek R. Price  <derek@ximbiot.com>
152921         * lib/mktime.c (not_equal_tm): Remove redundant check.
152923 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
152925         * modules/regex (lib_SOURCES): Add regex.c.
152926         Reported by James Youngman in
152927         <http://lists.gnu.org/r/bug-gnulib/2004-10/msg00199.html>.
152929 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
152931         * lib/getdate.y: Use Bison 1.875 features, and some minor
152932         code cleanups.  This change does not affect semantics.
152933         Don't include <stdlib.h>; no longer needed.
152934         Don't include unlocked-io.h; only the "#if TEST" code uses
152935         stdio, and performance isn't crucial there.
152936         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
152937         Bison 1.875 features as described below.
152938         All uses of "PC." replaced by "pc->".
152939         (YYSTYPE): Add a forward declaration.
152940         (yylex, yyerror): Use full prototypes in forward decls.
152941         Use "%pure-parser" rather than obsolescent "%pure_parser".
152942         Use %parse-param and %lex-param instead of obsolescent
152943         YYPARSE_PARAM and YYLEX_PARAM.
152944         (meridian_table, month_and_day_table, time_units_table,
152945         relative_time_table, time_zone_table, military_table,
152946         lookup_zone, lookup_word, get_date):
152947         Use NULL instead of 0 where appropriate.
152948         (to_hour): Avoid abort (), to avoid a dependency on
152949         stdlib.h.
152950         (yyerror, yylex): Now accepts parser_control * arg.
152951         (main) [TEST]: Use '\0' rather than 0 for char.
152953 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
152955         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
152957 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
152959         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
152960         It's now the caller's responsibility to handle the case where
152961         !HAVE_GETPAGESIZE && !defined getpagesize.
152963         * lib/mktime.c (leapyear): Arg is long int, not int.
152965 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
152967         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
152969 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
152971         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
152972         missing.  Problem reported by James Youngman.
152974 2004-10-16  Simon Josefsson  <jas@extundo.com>
152976         * gnulib-tool: Fix comments.  Fix parse problem.
152977         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
152979 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
152981         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
152982         implementation of getopt_long.  Problem reported by Alexander Taler in:
152983         http://lists.gnu.org/r/bug-gnulib/2004-10/msg00103.html
152985 2004-10-15  Bruno Haible  <bruno@clisp.org>
152987         * gnulib-tool: Untabify. Initialize supplied_libname.
152988         (func_usage): More homogenous output.
152989         (func_modules_transitive_closure, func_modules_to_filelist,
152990         func_emit_lib_Makefile_am): New functions.
152991         (func_import): New function, extracted from big case statement. Use
152992         func_get_license, func_modules_transitive_closure,
152993         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
152994         opt_lgpl. Don't use test -a, as it's not portable.
152995         (func_create_testdir): Use func_modules_transitive_closure,
152996         func_modules_to_filelist, func_emit_lib_Makefile_am.
152998 2004-10-15  Bruno Haible  <bruno@clisp.org>
153000         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
153002 2004-10-15  Bruno Haible  <bruno@clisp.org>
153004         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
153005         the portions belonging to each module.
153006         Suggested by Derek Robert Price <derek@ximbiot.com>.
153008 2004-10-12  Simon Josefsson  <jas@extundo.com>
153010         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
153011         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
153012         to real functions.
153014 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
153016         * modules/vsnprintf: New file.
153018 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
153020         * m4/vsnprintf.m4: New file.
153022 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
153024         * lib/vsnprintf.h: New file.
153025         * lib/vsnprintf.c: New file.
153027 2004-10-11  Bruno Haible  <bruno@clisp.org>
153029         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
153030         vsnprintf.
153032 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
153034         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
153036 2004-10-07  Bruno Haible  <bruno@clisp.org>
153038         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
153039         fits into the provided buffer.
153041 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
153043         * lib/diacrit.c, diacrit.h: Add GPL notice.
153045         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
153046         notice.
153047         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
153048         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
153049         This avoids a potential constant-folding bug.
153051 2004-10-05  Bruno Haible  <bruno@clisp.org>
153053         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
153054         for the declaration of strsep.
153056 2004-10-05  Bruno Haible  <bruno@clisp.org>
153058         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
153060 2004-10-04  Simon Josefsson  <jas@extundo.com>
153062         * modules/memmem: New file.
153063         * tests/test-memmem.c: New file.
153064         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
153066 2004-10-04  Simon Josefsson  <jas@extundo.com>
153068         * m4/memmem.m4: New file.
153070 2004-10-04  Simon Josefsson  <jas@extundo.com>
153072         * lib/memmem.h: New file.
153073         * lib/memmem.c: New file, taken from glibc.
153075 2004-10-04  Simon Josefsson  <jas@extundo.com>
153077         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
153078         '#ifdef USE_UNLOCKED_IO'.
153080 2004-10-04  Simon Josefsson  <jas@extundo.com>
153082         * config/srclist.txt: Add memmem from glibc.
153084 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
153086         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
153088         * modules/argmatch, modules/argp, modules/closeout, modules/error,
153089         modules/exclude, modules/getdate, modules/getline,
153090         modules/getndelim2, modules/getpass, modules/getpass-gnu,
153091         modules/getusershell, modules/linebuffer, modules/md5,
153092         modules/mountlist, modules/posixtm, modules/readtokens,
153093         modules/readutmp, modules/regex, modules/sha1,
153094         modules/version-etc, modules/yesno:
153095         Remove dependency on unlocked-io.
153097 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
153099         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
153101         * m4/unlocked-io.m4: Add copyright notice.
153102         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
153104 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
153106         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
153107         * lib/xmalloc.c (xmemdup): Likewise.
153108         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
153109         XFREE): Remove these long-obsolescent macros.
153110         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
153111         * lib/xstrdup.c: Remove.
153113         * lib/regex.c (re_comp): Cast gettext return value to char *,
153114         Problem reported by Martin Neitzel via Mark D. Baushke.
153116 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
153118         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
153119         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
153120         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
153121         regex.c, sha1.c, version-etc.c, yesno.c:
153122         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
153123         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
153124         the includer's responsibility.
153126         Sync from coreutils.
153128         * lib/modechange.c (mode_compile): Don't decrement a pointer that
153129         points to the start of a string, as the C Standard says the
153130         resulting behavior is undefined.
153132         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
153133         simple -> simple_backups, numbered_existing ->
153134         numbered_existing_backups, numbered -> numbered_backups
153135         to avoid shadowing problems.  All uses changed.
153136         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
153137         * lib/backupfile.c (check_extension, numbered_backup):
153138         Rename locals to avoid shadowing 'basename'.
153139         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
153140         once.
153142         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
153143         * lib/.cvsignore: Add getopt.h.
153145 2004-10-04  Bruno Haible  <bruno@clisp.org>
153147         * modules/README: New file.
153148         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
153149         not a module.
153151 2004-10-02  Jim Meyering  <jim@meyering.net>
153153         * lib/dirfd.h, getpagesize.h: Add copyright notice.
153155 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
153157         * modules/strsep: New file.
153159 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
153161         * m4/strsep.m4: New file.
153163 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
153165         * lib/strsep.h: New file.
153166         * lib/strsep.c: New file.
153168 2004-10-01  Simon Josefsson  <jas@extundo.com>
153170         * lib/snprintf.c (snprintf): Handle size==0.
153172 2004-10-01  Simon Josefsson  <jas@extundo.com>
153173             Bruno Haible  <bruno@clisp.org>
153175         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
153176         (snprintf): Declare 'args'.
153178 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
153180         * lib/snprintf.c: Remove comments as to why each header is needed.
153182 2004-10-01  Bruno Haible  <bruno@clisp.org>
153184         * MODULES.html.sh: Add strsep.
153186 2004-09-30  Simon Josefsson  <jas@extundo.com>
153188         * modules/snprintf: New file.
153190 2004-09-30  Simon Josefsson  <jas@extundo.com>
153192         * m4/snprintf.m4: New file.
153194 2004-09-30  Simon Josefsson  <jas@extundo.com>
153196         * lib/snprintf.h, lib/snprintf.c: New files.
153198 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
153200         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
153201         (hol_entry_help): Never translate an empty string.
153202         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
153203         * lib/argp.h (OPTION_NO_TRANS): New option.
153205 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
153207         * modules/argp (Maintainer): Replace Simon Josefsson
153208         by Sergey Poznyakoff.
153210 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
153212         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
153213         changes merged back into glibc.
153215 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
153217         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
153219 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
153221         * lib/xvasprintf.c: Include xalloc.h.
153222         (xvasprintf): Use xalloc_die, not xmalloc_die.
153224 2004-09-29  Bruno Haible  <bruno@clisp.org>
153226         * modules/alloca-opt: New file, derived from modules/alloca.
153227         * modules/allocsa: Depend on alloca-opt instead of alloca.
153228         * modules/setenv: Likewise.
153229         * modules/vasnprintf: Likewise.
153230         * MODULES.html.sh: Add alloca-opt.
153232 2004-09-28  Simon Josefsson  <jas@extundo.com>
153234         * gnulib-tool: New parameter --lgpl, to asseert that modules are
153235         LGPL, and to replace license template from GPL to LGPL.
153237 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
153239         * modules/dummy: Change license to LGPL.
153241 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
153243         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
153245 2004-09-24  Simon Josefsson  <jas@extundo.com>
153247         * modules/minmax (License): Change from GPL to LGPL.
153249 2004-09-23  Simon Josefsson  <jas@extundo.com>
153251         * gnulib-tool (--import): Typo.
153253 2004-09-23  Simon Josefsson  <jas@extundo.com>
153255         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
153257 2004-09-22  Bruno Haible  <bruno@clisp.org>
153259         * modules/*: Add 'License' field.
153260         * gnulib-tool: Accept --extract-license option.
153261         (func_get_license): New function.
153263 2004-09-21  Bruno Haible  <bruno@clisp.org>
153265         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
153266         Reported by Simon Josefsson.
153268 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
153270         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
153271         gl_AC_TYPE_LONG_LONG.
153273 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
153275         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
153277 2004-09-18  Simon Josefsson  <jas@extundo.com>
153278         and  Paul Eggert  <eggert@cs.ucla.edu>
153280         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
153281         calls with autoreconf.  Define GL_LIB.
153283 2004-09-14  Karl Berry  <karl@gnu.org>
153285         * config/srclist.txt: unsync setenv.c, sigh.
153287 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
153289         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
153290         Problem reported by Bruno Haible in:
153291         http://lists.gnu.org/r/bug-tar/2004-09/msg00023.html
153293 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
153295         * config/srclist.txt: Comment out argp-pvh.c.
153297 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
153299         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
153300         in case some system header has #define'd it.  Problem reported by
153301         Soeren D. Schulze in
153302         <http://lists.gnu.org/r/bug-gnulib/2004-09/msg00017.html>.
153304 2004-09-09  Karl Berry  <karl@gnu.org>
153306         * regex.[ch]: delete from the root.  These were supposed to be
153307                 synced with emacs cvs, but this has not happened for about
153308                 a year, and anyway nothing else uses emacs regex.[ch].
153309                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
153310                 lib/regex[.ch] is untouched.
153312 2004-09-09  Bruno Haible  <bruno@clisp.org>
153314         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
153316 2004-09-09  Bruno Haible  <bruno@clisp.org>
153318         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
153319         modifications.
153320         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
153322 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
153324         * modules/xvasprintf: New file.
153325         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
153327 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
153329         * lib/xvasprintf.h: New file.
153330         * lib/xvasprintf.c: New file.
153331         * lib/xasprintf.c: New file.
153333 2004-09-08  Bruno Haible  <bruno@clisp.org>
153335         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
153337 2004-09-08  Bruno Haible  <bruno@clisp.org>
153339         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
153340         length is > INT_MAX.
153341         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
153342         more.
153344 2004-09-08  Bruno Haible  <bruno@clisp.org>
153346         * lib/stdint_.h: New file, taken from GNU clisp.
153348 2004-09-08  Bruno Haible  <bruno@clisp.org>
153349             Oskar Liljeblad  <oskar@osk.mine.nu>
153351         * modules/stdint: New file.
153352         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
153354 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
153356         Import from coreutils.
153357         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
153358         strings on unbounded length.  alloca's performance benefits aren't
153359         that important here.
153360         (V_STRDUP): Remove.
153361         (parse_with_separator): New function, with most of the internals
153362         of the old parse_user_spec.  Allow user to omit both user and group,
153363         for compatibility with FreeBSD.
153364         Clone only the user name, not the entire spec.
153365         Do not set *uid, *gid unless entirely successful.
153366         Avoid memory leak in some failing cases.
153367         Fix regression for USER.GROUP reported by Dmitry V. Levin in
153368         <http://lists.gnu.org/r/bug-coreutils/2004-08/msg00102.html>
153369         (parse_user_spec): Rewrite to use parse_with_separator.
153371 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
153373         * modules/userspec: Don't depend on alloca.
153375 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
153377         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
153379 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
153381         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
153382         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
153383         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
153385 2004-08-16  Simon Josefsson  <jas@extundo.com>
153387         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
153388         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
153389         Add --dry-run for --import.
153390         Let user provided command line parameters override configure.ac
153391         settings.
153393 2004-08-12  Simon Josefsson  <jas@extundo.com>
153395         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
153396         as discussed with Paul Eggert in threads rooted at
153397         <http://lists.gnu.org/r/bug-gnulib/2004-06/msg00039.html>
153398         and
153399         <http://lists.gnu.org/r/bug-gnulib/2004-07/msg00001.html>.
153400         Before, the test was empty, and relied on ELIDE_CODE in source
153401         code.)
153402         (gl_PREREQ_GETOPT): New macro.
153403         (gl_GETOPT): Use them.
153405 2004-08-12  Simon Josefsson  <jas@extundo.com>
153407         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
153408         * lib/getopt_.h: Renamed from getopt.h.
153410 2004-08-12  Simon Josefsson  <jas@extundo.com>
153412         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
153413         Change default library name from libfoo to libgnu.
153414         Now, if you have a configure.ac that says:
153415                 gl_SOURCE_BASE(gl)
153416                 gl_M4_BASE(gl/m4)
153417                 gl_MODULES(error getopt etcetera)
153418                 gl_INIT
153419         you can import all you need by running:
153420                 ../gnulib/gnulib-tool --import
153422         * modules/getopt (Files): Rename getopt.h to getopt_.h.
153423         (Makefile.am): Rewrite, use logic from argz.
153424         (Include): Use <getopt.h> instead of "getopt.h".
153426 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
153428         * modules/argp (Files): Add m4/unlocked-io.m4.
153429         (Depends-on): Add extensions.
153431 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
153433         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
153434         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
153435         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
153436         Check for program_invocation_name, program_invocation_short_name,
153437         flockfile, funlockfile, features.h, _getopt_long_only_r.
153439 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
153441         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
153442         its complicated substitute.
153443         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
153444         and program_invocation_name.
153445         (__argp_basename) [!_LIBC]: Remove; the only use was
153446         replaced by its body.
153447         (__argp_short_program_name): Change condition from
153448         !defined __argp_short_program_name to
153449         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
153450         to match argp-namefrob.h.
153451         (__argp_failure): Don't assume strerror_r returns char *.
153452         * lib/argp-parse.c (N_): Define unconditionally.
153453         (argp_default_options): Fill out initializers with 0 to avoid
153454         gcc warnings.
153456 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
153458         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
153459         getopt1.c.
153461 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
153463         Merge from coreutils.
153465         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
153467         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
153468         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
153470 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
153472         Merge from coreutils.
153474         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
153475         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
153476         for Reliant Unix 5.43.
153478         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
153479         (union fooround): Use uintmax_t, not long int.
153480         The rest is a merge from libc:
153481         [defined _LIBC]: Include <shlib-compat.h>.
153482         (_obstack) [defined _LIBC]: Remove after 2.3.4.
153484         * lib/settime.c (settime): Recode to avoid warning with
153485         Sun Forte C 6U2.
153487         * lib/strverscmp.c: Convert to UTF-8.
153489 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
153491         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
153492         m4/uintmax_t.m4.
153494 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
153496         * modules/xalloc-die: New file.
153497         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
153499         * modules/md5 (Files): Add m4/uint32_t.m4.
153500         * modules/sha1: Renamed from modules/sha.
153501         (Files):
153502         Rename lib/sha.h to lib/sha1.h.
153503         Rename lib/sha.c to lib/sha1.c.
153504         Rename m4/sha.m4 to m4/sha1.m4.
153505         (lib_SOURCES): Likewise.
153506         (configure.ac): Rename gl_SHA to gl_SHA1.
153507         (Include): sha.h -> sha1.h.
153509 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
153511         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
153512         * m4/sha1.m4: Renamed from sha.m4.
153513         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
153515 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
153517         * lib/obstack.h (obstack_empty_p):
153518         Don't assume that chunk->contents is suitably aligned.
153519         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
153520         Likewise. Problem reported by Benno in
153521         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
153523         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
153524         readable.  This could be improved further but it'd take some work.
153526 2004-08-08  Simon Josefsson  <jas@extundo.com>
153528         * modules/xgethostname (Depends-on): Remove exit and error (not
153529         used).
153531         * modules/getpass-gnu: Add getpass.h.
153532         (Depends-on): Add stdbool.
153533         * modules/getpass: Add getpass.h.
153535 2004-08-08  Simon Josefsson  <jas@extundo.com>
153537         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
153538         Check getpass declaration.
153540 2004-08-08  Simon Josefsson  <jas@extundo.com>
153542         * lib/xgethostname.c: Don't include error.h (not used).
153544         * lib/getpass.h: Add.
153545         * lib/getpass.c: Include getpass.h first.
153547 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
153549         * lib/xalloc-die.c: New file.
153550         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
153551         All uses removed.
153552         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
153553         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
153554         xalloc-die.c.
153555         (_, N_, xalloc_die): Move to xalloc-die.c.
153556         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
153557         so that we needn't mess with xalloc_msg_memory_exhausted.
153559         * lib/sha1.h: Renamed from sha.h.
153560         (SHA1_H): Renamed from _SHA_H.
153561         (sha1_ctx): Renamed from sha_ctx.
153562         (sha1_init_ctx): Renamed from sha_init_ctx.
153563         (sha1_process_block): Renamed from sha_process_block.
153564         (sha1_process_bytes): Renamed from sha_process_bytes.
153565         (sha1_finish_ctx): Renamed from sha_finish_ctx.
153566         (sha1_read_ctx): Renamed from sha_read_ctx.
153567         (sha1_stream): Renamed from sha_stream.
153568         (sha1_buffer): Renamed from sha_buffer.
153569         * lib/sha1.c: Likewise; renamed from sha.c.
153570         Do not include <sys/types.h>.
153571         Include <stddef.h> rather than <stdlib.h>.
153573 2004-08-08  Bruno Haible  <bruno@clisp.org>
153575         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
153576         FILESYSTEM_PREFIX_LEN.
153577         * lib/progreloc.c: Likewise.
153578         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
153580 2004-08-06  Simon Josefsson  <jas@extundo.com>
153582         * modules/progname (Depends-on): Don't depend on stdbool.
153584 2004-08-06  Simon Josefsson  <jas@extundo.com>
153586         * modules/getsubopt: New file.
153587         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
153588         getsubopt.
153590 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
153592         More merge from coreutils.
153594         * m4/utimens.m4, m4/utimecmp.m4: New files.
153595         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
153596         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
153597         prereq.m4, sha.m4: Import changes from coreutils.
153599 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
153601         More merge from coreutils.
153602         * modules/raise, modules/readtokens0, modules/utimens:
153603         * modules/utimecmp, module/xnanosleep: New files.
153604         * modules/strftime: Add lib/strftime.h.
153605         Change include from <time.h> to "strftime.h".
153606         * modules/yesno: Add lib/yesno.h.
153607         * modules/backupfile: Remove lib/addext.c.
153608         * modules/euidaccess: Add stat-macros.h.
153609         * modules/canonicalize, modules/euidaccess,
153610         modules/filemode, modules/lchown, modules/makepath,
153611         modules/rmdir, modules/stat: Likewise.
153613 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
153615         Merge from tar.
153616         * lib/argp-help.c (make_hol, hol_append): Don't assume that
153617         SIZE_MAX is a valid preprocessor constant.
153618         (__argp_basename): Change from "#ifndef _LIBC"
153619         to "#ifndef __argp_short_program_name", so that
153620         we don't compile these functions for tar.
153622         More merges from coreutils.
153623         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
153624         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
153625         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
153626         * lib/addext.c: Remove; no longer needed.
153627         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
153628         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
153629         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
153630         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
153631         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
153632         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
153633         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
153634         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
153635         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
153636         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
153637         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
153638         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
153639         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
153640         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
153641         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
153642         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
153643         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
153644         Import changes from coreutils.
153646 2004-08-05  Simon Josefsson  <jas@extundo.com>
153648         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
153650 2004-08-05  Simon Josefsson  <jas@extundo.com>
153652         * m4/getsubopt.m4: New file.
153654 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
153656         Merge from coreutils.
153658         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
153659         * m4/getcwd-path-max.m4: New files.
153661         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
153662         FILESYSTEM_PREFIX_LEN ->
153663         FILE_SYSTEM_PREFIX_LEN.
153664         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
153665         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
153666         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
153667         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
153669         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
153670         prerequisite modules now handle the DOS stuff.
153671         Don't check for unistd.h.
153673 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
153675         Merge from coreutils.
153677         * lib/.gdb-history: Remove; this doesn't belong here.
153679         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
153680         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
153681         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
153682         * lib/getcwd.c: New files.
153684         * lib/dirname.h: Include <stdbool.h>.
153685         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
153686         for consistency with POSIX terminology.  All uses changed.
153687         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
153688         (strip_trailing_slashes): Use bool for booleans.
153689         * lib/stripslash.c (strip_trailing_slashes): Likewise.
153691         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
153692         sometimes returns a positive errno value even when it succeeds.
153693         (print_errno_message) [!LIBC]: Fall back on strerror if
153694         __strerror_r fails.
153696         * lib/path-concat.c (mempcpy): Don't define if a system header defines
153697         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
153698         (longest_relative_suffix): New function.
153699         (path_concat): Use it.  Assume first argument is not NULL.
153700         Port to DOS.  Omit redundant separators.
153701         Report an error instead of returning NULL.
153702         Use mempcpy instead of memcpy.
153703         (xpath_concat): Remove: not declared or used.
153705         * lib/same.h: Include <stdbool.h>
153706         (same_name): Return bool, not int.
153707         * lib/same.c (same_name): Likewise.
153708         (errno): Don't declare; we assume C89 or better now.
153710         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
153711         if not already defined.
153713         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
153714         * lib/dup-safer.c (errno): Likewise.
153716 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
153718         Merge from coreutils.
153719         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
153720         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
153721         * modules/path-concat: Don't depend on strdup.
153723 2004-08-03  Simon Josefsson  <jas@extundo.com>
153725         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
153726         * lib/progname.h: Don't include stdbool.h.
153728 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
153730         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
153731         * MODULES.html.sh (func_all_modules): Remove fatal.
153733 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
153735         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
153737 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
153739         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
153740         working.
153742 2004-08-02  Simon Josefsson  <jas@extundo.com>
153744         * lib/getsubopt.h: New file, with comments from Bruno Haible.
153745         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
153746         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
153748 2004-08-01  Simon Josefsson  <jas@extundo.com>
153750         * lib/xgetdomainname.c: Include stdlib.h, for free().
153752 2004-07-19  Bruno Haible  <bruno@clisp.org>
153754         * MODULES.html.sh (func_all_modules): Add dummy.
153756 2004-07-16  Simon Josefsson  <jas@extundo.com>
153758         * modules/dummy: New file.
153760 2004-07-16  Simon Josefsson  <jas@extundo.com>
153762         * lib/dummy.c: New file.
153764 2004-07-16  Bruno Haible  <bruno@clisp.org>
153766         * lib/backupfile.h: Add extern "C" for C++.
153767         * lib/closeout.h: Likewise.
153768         * lib/copy-file.h: Likewise.
153769         * lib/findprog.h: Likewise.
153770         * lib/full-write.h: Likewise.
153771         * lib/pathname.h: Likewise.
153772         * lib/progname.h: Likewise.
153773         * lib/stpcpy.h: Likewise.
153774         * lib/stpncpy.h: Likewise.
153775         * lib/strcase.h: Likewise.
153776         * lib/strstr.h: Likewise.
153777         * lib/xalloc.h: Likewise.
153779         * lib/mbswidth.h: Add extern "C" for C++.
153780         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
153782 2004-07-13  Robert Millan  <robertmh@gnu.org>
153784         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
153786 2004-07-09  Simon Josefsson  <jas@extundo.com>
153788         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
153789         failed without this.)
153791 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
153793         * modules/chown (Files): Add lib/fchown-stub.c, since
153794         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
153796 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
153798         * lib/fchown-stub.c: New file.
153800 2004-06-24  Jim Meyering  <jim@meyering.net>
153802         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
153804 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
153806         * modules/argz: Omit "#include".
153808         * MODULES.html.sh (func_all_modules): Add calloc, to match
153809         2004-06-01 addition of calloc module.
153811 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
153813         * m4/argz.m4: New file, which is autoupdated from libtool.
153815 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
153817         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
153818         libtool.
153820 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
153822         * config/srclist-update: Don't insist on "USA." before the
153823         close-comment, as libtool omits the period and puts the */ on a
153824         separate line.
153825         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
153826         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
153828 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
153830         * modules/argz: New file.
153831         * MODULES.html.sh (func_all_modules): Add argz.
153833 2004-06-12  Jim Meyering  <jim@meyering.net>
153834         and  Paul Eggert  <eggert@cs.ucla.edu>
153836         * modules/hash (Files): Add lib/xalloc.h.
153837         * modules/pipe (Depends-on): Add wait-process.
153838         * modules/stat (Depends-on): Add xalloc.
153839         * modules/userspec (Files): Add lib/userspec.h.
153840         * modules/xstrtol (Depends-on): Add error.
153842 2004-06-10  Jim Meyering  <jim@meyering.net>
153844         * lib/calloc.c: New file.
153846 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
153848         * lib/getdate.y (yylex): Allow space between sign and number.
153849         Problem reported by Dan Jacobson.
153851 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
153853         Merge from coreutils CVS.
153855         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
153856         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
153857         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
153858         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
153859         xstrtol.m4: Fix copyright date and/or serial number.
153861         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
153862         See if we need an fchown replacement.
153863         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
153864         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
153865         and use the replacement function if we detect either defect.
153867         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
153868         gl_UTIMECMP.
153870 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
153871         and  Jim Meyering  <jim@meyering.net>
153873         Merge from coreutils CVS.
153875         * lib/stat-macros.h: New file, with contents from file-type.h
153876         and coreutils' system.h.
153877         * lib/file-type.c: Include "stat-macros.h".
153878         * lib/file-type.h (file_type): Move all macro definitions to new file,
153879         stat-macros.h.
153880         * modules/file-type: Add lib/stat-macros.h.
153882         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
153883         Wrap old code with this conditional.
153884         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
153885         function that does not dereference symlinks.
153886         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
153888         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
153889         dependency problems.
153890         (xreadlink): Accept new arg SIZE, for efficiency.
153891         All decls and uses changed.
153892         * lib/xreadlink.h: Include <stddef.h>, for size_t.
153894         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
153895         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
153897         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
153898         sysexits.h.
153900 2004-06-01  Jim Meyering  <jim@meyering.net>
153902         * m4/calloc.m4: New file.
153903         * modules/calloc: New file.
153905 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
153907         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
153908         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
153909         Also, fix a typo in a diagnostic.
153911 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
153913         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
153914         or AC_FUNC_REALLOC.
153916 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
153918         * modules/hash (Depends-on): Remove malloc, realloc.
153919         * modules/xalloc (Depends-on): Likewise.
153921         * README: Mention that the 'free' module works around the
153922         problem with 'free (0)'.
153923         Mention LIA-1 and C99.
153924         Add a copyright notice.
153926         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
153927         macros to be defined.
153928         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
153929         the allocator returns NULL because the requested size is zero.
153931 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
153933         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
153934         var.  Add comment explaining why libc still defines it.  This
153935         merges the following patch from glibc:
153936         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
153938 2004-05-20  Andreas Schwab  <schwab@suse.de>
153940         * m4/free.m4: Replace free if it not known to work, not the other
153941         way round.
153943 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
153945         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
153946         present in glibc since revision 1.1 of this file.
153947         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
153948         obstack_alignment_mask, obstack_alloc, obstack_base,
153949         obstack_blank, obstack_blank_fast, obstack_chunk_size,
153950         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
153951         obstack_grow0, obstack_init, obstack_int_grow,
153952         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
153953         obstack_next_free, obstack_object_size, obstack_ptr_grow,
153954         obstack_ptr_grow_fast, obstack_room): Remove declarations of
153955         nonexistent functions.
153957 2004-05-18  Karl Berry  <karl@gnu.org>
153959         * config/srclist.txt: break link for vasnprintf.c.
153961 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
153963         Port obstack to the AS/400, where pointers are 16 bytes wide and
153964         you cannot cast an integer to a valid pointer.  This patch is
153965         currently waiting to be integrated into glibc; see
153966         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
153968         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
153969         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
153970         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
153971         (struct obstack): temp member is now a union of a pointer and
153972         an integer, instead of an integer.  All integer uses changed.
153973         This does not affect the physical layout of struct obstack,
153974         except on hosts (like the AS/400) where the size or alignment of
153975         void * is greater than that of ptrdiff_t.
153976         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
153977         __STDC__)]: Store temporary in pointer member of union, not
153978         integer member.
153979         * lib/obstack.c: Include <stddef.h>, for offsetof.
153980         (struct fooalign): Remove; it doesn't need a name.
153981         (union fooround): Change double to long double, and add void *.
153982         (DEFAULT_ALIGNMENT): Use offsetof to compute.
153983         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
153984         not a macro.  Hence the values are always int; so remove all
153985         casts-to-int in uses.
153987 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
153989         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
153990         we can get this patch merged into glibc.
153992 2004-05-17  Derek R. Price  <derek@ximbiot.com>
153993             Paul Eggert  <eggert@cs.ucla.edu>
153995         * m4/argp: Depend on alloca.
153997 2004-05-17  Derek R. Price  <derek@ximbiot.com>
153998             Paul Eggert  <eggert@cs.ucla.edu>
154000         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
154001         freecoding.
154003 2004-05-17  Bruno Haible  <bruno@clisp.org>
154005         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
154006         precision that consists of a '.' followed by an empty digit string.
154007         Patch by Tor Lillqvist <tml@iki.fi>.
154009 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
154011         * modules/getdate: Depend on alloca.
154012         * modules/setenv: Likewise.
154014 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
154016         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
154017         for backward compatibility with older code.  We need our own
154018         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
154019         it under some other name, and our alloca.h will define it.
154021 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
154022             Derek Price  <derek@ximbiot.com>
154024         * lib/alloca.c: Include <alloca.h>, to get our interface.
154025         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
154026         include <alloca.h> first.  Use C89 prototype for alloca; this
154027         requires including <stddef.h> for size_t.  Use extern "C" if C++.
154028         Use #elif for simplicity, since we can assume C89 now.
154029         Don't try to source the system alloca.h since it will not be found
154030         and to prevent recursively including its replacement.
154031         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
154032         * lib/regex.c: Likewise.
154034 2004-05-16  Derek Price  <derek@ximbiot.com>
154035             Paul Eggert  <eggert@cs.ucla.edu>
154037         getline cleanup.  This changes the getndelim2 API: both order of
154038         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
154039         no delimiter).
154041         * lib/getline.c: Don't include stddef.h or stdio.h, since our
154042         interface does that.
154043         (getline): Always use getdelim, so that we don't have two
154044         copies of this code.
154045         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
154046         if available.
154047         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
154048         (GETNDELIM2_MAXIMUM): New macro.
154049         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
154050         instead of the old practice of delim2==0.  All callers changed.
154051         Return -1 on overflow, instead of returning junk.
154052         Do not set *linesize unless allocation succeeds.
154053         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
154054         that we include sys/types.h.
154055         * lib/getnline.h: Likewise.
154056         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
154057         (getndelim2): Reorder arguments.
154058         * lib/getnline.c (getnline, getndelim):
154059         Don't discard the NMAX argument.
154060         (getnline): Invoke getndelim, to avoid code duplication.
154061         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
154062         of (size_t) -1 by callers of the getnline family.
154064 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
154066         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
154067         Check for gettimeofday.
154068         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
154069         Check for settimeofday, stime.
154071 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
154073         * lib/nanosleep.c (suspended): Change its type from int to
154074         sig_atomic_t volatile.
154075         (first_call): Make it private to rpl_nanosleep, and have it
154076         be zero initially as that's a bit faster.
154077         (my_usleep): Round up fractional times instead of truncating them,
154078         as this is the usual meaning for 'sleep'.
154080         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
154081         doesn't work.
154082         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
154083         (ENOSYS): Define if not defined.
154084         (settime): Fall back on stime if it exists and settimeofday fails.
154085         But don't bother with fallbacks if a method fails with errno == EPERM.
154087 2004-05-11  Jim Meyering  <jim@meyering.net>
154089         Prior to this change, the save_cwd caller required read access to the
154090         current directory on most systems (ones with the fchdir function).
154092         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
154093         fails, try write-only, and finally, resort to using xgetcwd.
154095 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
154097         * lib/obstack.c, obstack.h: Import changes from libc.
154099 2004-05-04  Derek Price  <derek@ximbiot.com>
154101         * modules/argp: Remove dependency on alloca.
154103 2004-04-28  Bruno Haible  <bruno@clisp.org>
154105         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
154106         also implicitly appends .exe to executables.
154107         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
154108         accepts Windows pathnames.
154109         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
154110         Treat Cygwin like Windows, since it now accepts Windows pathnames.
154111         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
154112         Treat Cygwin like Windows, since it now accepts Windows pathnames.
154113         Reported by Derek Robert Price <derek@ximbiot.com>.
154115 2004-04-27  Derek Price  <derek@ximbiot.com>
154117         * m4/dos.m4 (gl_AC_DOS): Add Cygwin to list of Windows/DOS
154118         environments that accept backslashes and drive letters in paths.
154120 2004-04-21  Karl Berry  <karl@gnu.org>
154122         * config/srclist.txt (localcharset.c): break sync.
154124 2004-04-20  Paul Eggert  <eggert@twinsun.com>
154126         * m4/host-os.m4: Add a copyright notice.
154128 2004-04-20  Jim Meyering  <jim@meyering.net>
154130         * modules/dirfd: Change UTILS_ macro name prefix to gl_.
154131         * modules/mkstemp: Likewise.
154132         * modules/mkdir: Likewise.
154134         Change UTILS_ to gl_ in AC_DEFINE'd names.
154135         Change utils_- and jm_-prefixed variables, too.
154136         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
154137         UTILS_FUNC_MKDIR_TRAILING_SLASH.
154138         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
154140         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
154141         Don't emit trailing blanks.
154142         Also rename jm_-prefixed variables to have gl_ prefix.
154144         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
154145         Also rename jm_-prefixed variables to have gl_ prefix.
154147         * m4/jm-macros.m4: Reflect the renamings.
154148         * m4/prereq.m4: Likewise.
154150 2004-04-20  Jim Meyering  <jim@meyering.net>
154152         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
154153         memory.
154155 2004-04-20  Jim Meyering  <jim@meyering.net>
154156             Bruno Haible  <bruno@clisp.org>
154158         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
154159         memory when realloc fails.
154161 2004-04-19  Jim Meyering  <jim@meyering.net>
154163         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
154164         now that readutmp.c may call `free (0)'.
154166 2004-04-19  Bruno Haible  <bruno@clisp.org>
154168         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
154169         * m4/inttypes_h.m4: Likewise.
154170         * m4/stdint_h.m4: Likewise.
154171         * m4/intmax_t.m4: Likewise.
154172         * m4/uintmax_t.m4: Likewise.
154174 2004-04-18  Jim Meyering  <jim@meyering.net>
154176         * m4/prereq.m4: Don't forbid jm_ prefix.
154178         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
154179         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
154180         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
154181         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
154182         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
154183         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
154184         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
154185         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
154186         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
154187         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
154188         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
154189         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
154190         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
154191         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
154192         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
154193         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
154194         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
154195         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
154196         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
154198 2004-04-18  Jim Meyering  <jim@meyering.net>
154200         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
154201         failure, don't leak memory and do call END_UTMP_ENT.
154203 2004-04-18  Jim Meyering  <jim@meyering.net>
154205         Change jm_ to gl_ in AC_DEFINE'd names.
154206         * modules/assert, modules/chown, modules/fpending:
154207         * modules/ftruncate, modules/getgroups, modules/group-member:
154208         * modules/lchown, modules/lstat, modules/memcmp:
154209         * modules/nanosleep, modules/putenv, modules/stat:
154210         * modules/strftime, modules/unlocked-io, modules/utime:
154211         * modules/xstrtoimax, modules/xstrtoumax:
154213 2004-04-16  Jim Meyering  <jim@meyering.net>
154215         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
154216         coreutils' stat program.
154217         (gl_PREREQ): Don't require jm_PREREQ_STAT.
154219 2004-04-12  Paul Eggert  <eggert@twinsun.com>
154221         * config/srclist.txt: Restore setenv.c, unsetenv.c from gettext.
154222         Add intmax.m4, printf-posix.m4, sig_atomic_t.m4,
154223         signalblocking.m4, ssize_t.m4.
154224         * lib/unsetenv.c: Regenerate: this subtracts 1 from the
154225         copyright year (!).
154226         * m4/printf-posix.m4: Regenerate.
154228         * modules/inttostr (EXTRA_DIST): Move inttostr.c here....
154229         (lib_SOURCES): from here.
154230         * modules/getopt (lib_SOURCES): Add getopt_int.h.
154232 2004-04-12  Jim Meyering  <jim@meyering.net>
154234         * MODULES.html.sh (func_all_modules): Add cloexec, inttostr, free,
154235         tzset.
154237 2004-04-11  Paul Eggert  <eggert@twinsun.com>
154239         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
154240         C89.
154241         (CHAR_BIT): Remove, since we assume C89.
154242         Include <stdint.h> if available, as per current Autoconf CVS advice.
154244 2004-03-31  Jim Meyering  <jim@meyering.net>
154246         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
154247         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
154248         * m4/xalloc.m4: Likewise.
154250 2004-03-30  Paul Eggert  <eggert@twinsun.com>
154252         Merge from coreutils.
154254         * m4/inttostr.m4: New file.
154255         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
154256         Require AM_STDBOOL_H and gl_TIMESPEC instead.
154257         Require gl_CLOCK_TIME.
154258         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
154260 2004-03-30  Paul Eggert  <eggert@twinsun.com>
154262         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
154263         not bool, to be more consistent with Unix conventions.
154264         Suggested by Bruno Haible.
154266         Merge from coreutils.
154268         * modules/inttostr: New file.
154269         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
154270         * lib/umaxtostr.c: New files.
154272         * modules/getdate: Depend on timespec, stdbool, gettime.
154273         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
154274         the usual <time.h> dance.
154275         (get_date): Change signature to support fractional time stamps.
154276         All callers changed.
154277         * lib/getdate.y: Include "getdate.h" first, as we can now
154278         assume C89 and don't need to worry about 'const'.
154279         Similarly, include "unlocked-io.h" near start, not in middle.
154280         Include <limits.h>.
154281         (textint.value): Use long int rather than int.
154282         (textint.digits): Use size_t rather than int.
154283         (BILLION, LOG10_BILLION): New constants.
154284         (parser_control): New member rel_ns.  Members day_ordinal,
154285         time_zone, month, day, hour, minutes, rel_year, rel_month,
154286         rel_day, rel_hour, rel_minutes, rel_seconds
154287         are now long int, not int.  Member seconds is now struct timespec,
154288         not int.  New member timespec_seen.  Members dates_seen, days_seen,
154289         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
154290         not int.
154291         (%union.intval): Now long int, not int.
154292         New member timespec.
154293         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
154294         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
154295         (spec): Now is a timespec or an item list.
154296         (timespec, items): New nonterminals.
154297         (time, rel, relunit, number, get_date):
154298         Add support for fractional seconds.
154299         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
154300         (gmtime, localtime, mktime): Remove decls; not needed with C89.
154301         (to_hour): First arg is now long int, not int.
154302         (to_year): Returns long int, not int.
154303         Don't treat year -70 like 70.
154304         (tm_diff): Returns long int, not int.
154305         (lookup_word): Use bool instead of int when appropriate.
154306         (yylex): Use size_t for count, not int.
154307         Detect overflow when parsing large integer constants.
154308         Add support for fractions.
154309         (get_date): Make pointers 'const' if possible.
154310         Use more-portable code to detect integer overflow.
154311         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
154312         Don't use ctime; it's not reliable if the year has >4 digits.
154314         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
154315         This is for compatibility with BSD.
154317         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
154318         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
154319         From coreutils' system.h.
154321         * lib/userspec.c: Don't include "posixver.h".
154322         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
154323         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
154324         compatible extension.  Simplify code by removing a boolean int
154325         that was always nonzero if a string was nonnull.
154327 2004-03-30  Jim Meyering  <jim@meyering.net>
154329         Merge from coreutils.
154331         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
154332         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
154333         on some systems one must include <grp.h> before it.
154334         Reported by Christian Krackowizer.
154336 2004-03-30  Jim Meyering  <jim@meyering.net>
154338         Merge from coreutils.
154340         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
154342         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
154343         an empty input stream.
154345         * lib/readtokens.c: Include <stdbool.h>.
154346         (readtoken): Use `size_t' rather than int/long.
154347         All callers adjusted.
154348         Use `bool' rather than `int' where appropriate.
154349         Use memset rather than an explicit loop.
154350         Use x2nrealloc rather than xrealloc.
154351         Allow the use of `\0' as a delimiter.
154352         (readtokens): Likewise.
154353         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
154355 2004-03-30  Jim Meyering  <jim@meyering.net>
154357         * modules/realloc (Files): Remove m4/realloc.m4.
154358         (configure.ac): Depend on AC_FUNC_REALLOC, rather than jm_FUNC_REALLOC.
154359         * modules/malloc (Files): Remove m4/malloc.m4.
154360         (configure.ac): Depend on AC_FUNC_MALLOC, rather than jm_FUNC_MALLOC.
154361         * m4/realloc.m4: Remove file, since now it does no more than
154362         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
154363         the `configure.ac' section of module/realloc.
154364         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
154366 2004-03-30  Bruno Haible  <bruno@clisp.org>
154368         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
154369         nonnull.
154371 2004-03-29  Paul Eggert  <eggert@twinsun.com>
154373         Merge changes to getloadavg.c from coreutils and Emacs.
154375         * modules/getloadvg: Depend on cloexec and xalloc.
154376         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
154377         Define to an expression, not to the empty string.
154378         Include cloexec.h and xalloc.h.
154379         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
154380         Use set_cloexec_flag rather than rolling our own.
154381         * lib/cloexec.c, lib/cloexec.h: New files.
154383 2004-03-29  Paul Eggert  <eggert@twinsun.com>
154385         * m4/cloexec.m4: New file.
154387 2004-03-18  Paul Eggert  <eggert@twinsun.com>
154389         * lib/getopt.h: Sync with libc CVS.
154391 2004-03-18  Paul Eggert  <eggert@twinsun.com>
154392             Bruno Haible  <bruno@clisp.org>
154394         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
154395         mbswidth.
154397 2004-03-18  Paul Eggert  <eggert@twinsun.com>
154398             Bruno Haible  <bruno@clisp.org>
154400         * lib/mbswidth.h: Include <wchar.h> only if
154401         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
154402         <wchar.h>.
154403         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
154405 2004-03-09  Paul Eggert  <eggert@twinsun.com>
154407         * modules/getopt: Add lib/getopt_int.h.
154408         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
154409         Sync with libc CVS.
154410         * lib/getopt_int.h: New file, also synced from libc.
154412 2004-03-09  Paul Eggert  <eggert@twinsun.com>
154414         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
154415         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
154416         Bring back getopt.c, getopt.h, getopt1.c.
154418 2004-03-07  Paul Eggert  <eggert@twinsun.com>
154420         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
154421         All uses changed.  Check for sa_sigaction member; this fixes
154422         a bug first reported by Jason Andrade in
154423         <http://mail.gnu.org/r/bug-textutils/2003-03/msg00027.html>.
154425 2004-03-07  Paul Eggert  <eggert@twinsun.com>
154427         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
154428         '#if' expressions.  Unlike the code it replaces, it does not
154429         depend on (defined _SC_PAGESIZE).  However, it does depend on
154430         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
154431         first reported by Jason Andrade in
154432         <http://mail.gnu.org/r/bug-textutils/2003-03/msg00027.html>.
154434 2004-02-25  Simon Josefsson  <jas@extundo.com>
154436         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
154438 2004-02-25  Simon Josefsson  <jas@extundo.com>
154440         * lib/strdup.h: New file.
154441         * lib/strdup.c: Include it.
154442         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
154443         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
154445 2004-02-23  Karl Berry  <karl@gnu.org>
154447         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
154448         (from fencepost.gnu.org:/gd/gnuorg).
154450 2004-02-23  Karl Berry  <karl@gnu.org>
154452         * config/srclistvars.sh (GNUORG) [karl]: redefine.
154453         * config/srclist.txt: add maintain/standards documents.
154455 2004-02-22  Bruno Haible  <bruno@clisp.org>
154457         * modules/xalloc: Remove dependency on stdbool.
154458         Reported by Derek Robert Price <derek@ximbiot.com>.
154460 2004-02-18  Bruno Haible  <bruno@clisp.org>
154462         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
154463         Reported by Derek Robert Price <derek@ximbiot.com>.
154465 2004-02-16  Karl Berry  <karl@gnu.org>
154467         * config/mkinstalldirs, install-sh: update from automake.
154469 2004-02-06  Karl Berry  <karl@gnu.org>
154471         * m4/po.m4: update from gettext 0.14.1.
154473 2004-02-06  Karl Berry  <karl@gnu.org>
154475         * lib/config.charset: update from gettext 0.14.1.
154477 2004-02-05  Paul Eggert  <eggert@twinsun.com>
154479         Add comments and code, prompted by suggestions from Bruno Haible
154480         for sh-quote.
154481         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
154482         describing the enum quoting_style values.
154483         * lib/quotearg.c (quotearg_alloc): New function.
154484         (quotearg_buffer_restyled): Treat lone { and } as special.
154485         Treat = as special.  Work around bug with older shells
154486         that "see" a '\' that is really the 2nd byte of a multibyte char.
154487         Quote empty string with shell_quoting_style.
154489 2004-02-03  Bruno Haible  <bruno@clisp.org>
154491         * modules/pipe: New file.
154492         * MODULES.html.sh (func_all_modules): Add pipe.
154493         * m4/pipe.m4: New file, from GNU gettext.
154495 2004-02-03  Bruno Haible  <bruno@clisp.org>
154497         * lib/pipe.h: New file, from GNU gettext.
154498         * lib/pipe.c: New file, from GNU gettext.
154500 2004-01-27  Bruno Haible  <bruno@clisp.org>
154502         * modules/execute: New file.
154503         * MODULES.html.sh (func_all_modules): Add execute.
154504         * m4/execute.m4: New file, from GNU gettext.
154506 2004-01-27  Bruno Haible  <bruno@clisp.org>
154508         * lib/execute.h: New file, from GNU gettext.
154509         * lib/execute.c: New file, from GNU gettext.
154510         * lib/w32spawn.h: New file, from GNU gettext.
154512 2004-01-24  Paul Eggert  <eggert@twinsun.com>
154514         Merge from diffutils.
154516         * lib/file-type.c (file_type): Add typed memory objects.
154517         * lib/file-type.h (S_TYPEISTMO): New macro.
154519         * lib/c-stack.h (c_stack_action): Remove argv argument.
154520         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
154521         (die): Don't calculate message unless segv_action returns.
154522         (get_stack_location, min_address_from_argv, max_address_from_argv,
154523         volatile stack_base, volatile_stack_size): Remove.
154524         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
154525         that every segmentation violation is a stack overflow.  (Ouch!)
154526         See Debian bug 136249 (still outstanding) for more info about why
154527         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
154529 2004-01-24  Paul Eggert  <eggert@twinsun.com>
154531         Exit-status fix from coreutils.
154533         Use exit_failure consistently in place of EXIT_FAILURE,
154534         so that program exit statuses are consistent on failure.
154536         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
154537         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
154538         * lib/argmatch.h: Comment fix to match the above.
154539         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
154540         Now a macro referring to exit_failure, instead of a separate
154541         variable.  Include "exitfail.h" to get it.
154542         * lib/xstrtol.h: Include "exitfail.h".
154543         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
154545         * lib/long-options.c (parse_long_options): Use prototype
154546         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
154547         for clarity.
154549 2004-01-23  Paul Eggert  <eggert@twinsun.com>
154551         * modules/argmatch, modules/obstack, modules/xstrtol:
154552         Depend on exitfail.
154554 2004-01-21  Jim Meyering  <jim@meyering.net>
154556         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
154557         so as not to conflict with a different-sized __mktime_internal
154558         function in GNU libc.
154559         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
154560         Problem building statically-linked `ls' reported by Michael Brunnbauer.
154562 2004-01-20  Karl Berry  <karl@gnu.org>
154564         * config/config.guess: update from config.
154566         * config/srclistvars.sh: GNUWWWLICENSES for karl.
154568 2004-01-20  Bruno Haible  <bruno@clisp.org>
154570         Safer stack allocation.
154571         * modules/setenv: Depend on allocsa instead of alloca.
154572         * lib/setenv.c: Include allocsa.h.
154573         (alloca): Remove fallback definition.
154574         (freea): Remove macro.
154575         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
154576         instead of freea.
154578 2004-01-20  Bruno Haible  <bruno@clisp.org>
154580         * m4/eealloc.m4: New file, from GNU gettext.
154582 2004-01-20  Bruno Haible  <bruno@clisp.org>
154584         * m4/allocsa.m4: New file, from GNU gettext.
154586 2004-01-20  Bruno Haible  <bruno@clisp.org>
154588         * modules/xallocsa: New file.
154589         * MODULES.html.sh (func_all_modules): Add xallocsa.
154590         * lib/xallocsa.h: New file, from GNU gettext.
154591         * lib/xallocsa.c: New file, from GNU gettext.
154593 2004-01-20  Bruno Haible  <bruno@clisp.org>
154595         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
154597 2004-01-20  Bruno Haible  <bruno@clisp.org>
154599         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
154600         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
154601         specially.
154603 2004-01-20  Bruno Haible  <bruno@clisp.org>
154605         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
154606         patch.
154608 2004-01-20  Bruno Haible  <bruno@clisp.org>
154610         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
154612 2004-01-20  Bruno Haible  <bruno@clisp.org>
154614         * modules/eealloc: New file.
154615         * MODULES.html.sh (func_all_modules): Add eealloc.
154616         * lib/eealloc.h: New file.
154618 2004-01-20  Bruno Haible  <bruno@clisp.org>
154620         * lib/binary-io.h: Avoid warnings on Cygwin.
154622 2004-01-20  Bruno Haible  <bruno@clisp.org>
154624         * modules/allocsa: New file.
154625         * MODULES.html.sh (func_all_modules): Add allocsa.
154626         * lib/allocsa.h: New file, from GNU gettext.
154627         * lib/allocsa.c: New file, from GNU gettext.
154629 2004-01-18  Karl Berry  <karl@gnu.org>
154631         * doc/gpl.texi, doc/lgpl.texi: new files.
154633 2004-01-18  Karl Berry  <karl@gnu.org>
154635         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
154636         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
154638 2004-01-18  Simon Josefsson  <jas@extundo.com>
154640         * modules/strdup (Files, Makefile.am): Add strdup.h.
154642 2004-01-15  Paul Eggert  <eggert@twinsun.com>
154644         * modules/poll: Add BUILT_SOURCES.
154645         Prefer "$@" to "poll.h" in rule for building poll.h.
154646         All this is for consistency with alloca and fnmatch.
154648         * modules/same: Depend on stdbool.
154650 2004-01-15  Paul Eggert  <eggert@twinsun.com>
154652         Merge from coreutils.
154654         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
154655         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
154656         (gl_DEFAULT_POSIX2_VERSION): Move
154657         the documentation from 'configure' into 'config.hin',
154658         so that 'configure --help' isn't burdened by it and
154659         we don't have to worry about its formatting there.
154660         Reword the documentation so that it's more succinct
154661         and can be run together into a single paragraph.
154662         * m4/same.m4 (gl_SAME): Check for pathconf.
154664 2004-01-15  Paul Eggert  <eggert@twinsun.com>
154666         Merge from coreutils.
154668         * lib/posixver.c: Include posixver.h.
154670         * lib/same.c: Include <stdbool.h>, <limits.h>.
154671         (_POSIX_NAME_MAX): Define if not defined.
154672         (MIN): New macro.
154673         (same_name): If file names are silently truncated, report
154674         that the file names are the same if they are the same after
154675         the silent truncation.
154677         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
154678         conversion function.
154679         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
154680         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
154681         longer needed.
154683 2004-01-15  Jim Meyering  <jim@meyering.net>
154685         Merge from coreutils.
154687         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
154688         if no library is required.
154689         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
154690         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
154691         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
154692         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
154693         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
154694         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
154695         value, $ac_cv_search_crypt, if it's "none required".
154696         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
154697         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
154698         not gl_FUNC_GETLOADAVG.
154699         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
154700         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
154702 2004-01-15  Jim Meyering  <jim@meyering.net>
154704         Merge from coreutils.
154706         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
154707         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
154708         http://mail.gnu.org/r/bug-coreutils/2003-11/msg00144.html
154710         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
154711         optional configure-time default.
154713         * lib/version-etc.c (version_etc_copyright): Update copyright date.
154715         * lib/xreadlink.c (xreadlink): Correct outdated comment.
154717 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
154719         Merge from coreutils.
154721         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
154722         value, $ac_cv_search_nanosleep, if it's "none required".
154724 2004-01-14  Paul Eggert  <eggert@twinsun.com>
154726         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
154727         with like-named macro in fnmatch.c.
154728         (EXT): Use an internal constant instead.
154730         Merge fnmatch patches from glibc.
154731         * lib/fnmatch.c (mbsinit): Remove define.
154732         Add libc_hidden_ver (__fnmatch, fnmatch).
154733         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
154734         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
154736 2004-01-14  Karl Berry  <karl@gnu.org>
154738         * config/install-sh: update from automake.
154740 2004-01-13  Karl Berry  <karl@gnu.org>
154742         * config/install-sh: update from automake.
154744 2004-01-09  Karl Berry  <karl@gnu.org>
154746         * config/install-sh: update from automake.
154748 2004-01-05  Karl Berry  <karl@gnu.org>
154750         * config/config.{sub,guess}: update from config.
154752 2003-12-31  Karl Berry  <karl@gnu.org>
154754         * config/depcomp: update from automake.
154756 2003-12-14  Karl Berry  <karl@gnu.org>
154758         * lib/config.charset: update from gettext-runtime.
154760 2003-12-03  Paul Eggert  <eggert@twinsun.com>
154762         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
154763         Bug reported by Alfred M. Szmidt.
154765 2003-12-03  Bruno Haible  <bruno@clisp.org>
154767         Upgrade from gettext-0.13.
154768         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
154769         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
154770         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
154771         * m4/gettext.m4: Upgrade from gettext-0.13.
154772         * m4/po.m4: Upgrade from gettext-0.13.
154773         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
154774         * m4/intmax.m4: New file, from gettext-0.13.
154775         * m4/printf-posix.m4: New file, from gettext-0.13.
154777 2003-11-29  Karl Berry  <karl@gnu.org>
154779         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
154781 2003-11-25  Paul Eggert  <eggert@twinsun.com>
154782             Bruno Haible  <bruno@clisp.org>
154784         * lib/printf-parse.h: Don't include sys/types.h.
154785         (ARG_NONE): New macro.
154786         (char_directive): Change type of *arg_index fields to size_t.
154787         * lib/printf-parse.c: Don't include sys/types.h.
154788         (SSIZE_MAX): Remove macro.
154789         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
154790         Remove unnecessary overflow check.
154791         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
154792         fields.
154794 2003-11-25  Bruno Haible  <bruno@clisp.org>
154796         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
154798 2003-11-25  Bruno Haible  <bruno@clisp.org>
154800         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
154801         gt_TYPE_SSIZE_T.
154803 2003-11-24  Paul Eggert  <eggert@twinsun.com>
154805         * modules/alloca: Remove dependency on xalloc.
154807 2003-11-24  Paul Eggert  <eggert@twinsun.com>
154809         * lib/alloca.c: Remove dependency on xalloc module.
154810         (xalloc_die): Remove.
154811         (memory_full) [!defined emacs]: New macro.
154812         [!defined emacs]: Don't include xalloc.h.
154813         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
154814         address arithmetic overflows.  Change datatypes a bit to avoid
154815         unnecessary casts.
154817 2003-11-22  Jim Meyering  <jim@meyering.net>
154819         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
154820         s/size/size_t/.
154822 2003-11-21  Karl Berry  <karl@gnu.org>
154824         * config/config.{sub,guess}: update from config.
154826 2003-11-18  Karl Berry  <karl@gnu.org>
154828         * config/config.{sub,guess}: update from config.
154830         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
154832 2003-11-17  Paul Eggert  <eggert@twinsun.com>
154834         * README: Mention that S+T cannot overflow if S is the size of
154835         an existing object and T is sufficiently small.
154837 2003-11-17  Jim Meyering  <jim@meyering.net>
154839         On systems without utime and without a utimes function capable of
154840         dealing with a NULL struct utimbuf* argument, this utime replacement
154841         could -- in unusual circumstances -- leak a file descriptor.
154842         * lib/utime.c: Include <unistd.h> and <errno.h>.
154843         (utime_null): Be sure to close `fd' and to preserve errno.
154844         Reported by Geoff Collyer via Arnold Robbins.
154846 2003-11-17  Bruno Haible  <bruno@clisp.org>
154848         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
154849         (Depends-on): Add xsize.
154851 2003-11-17  Bruno Haible  <bruno@clisp.org>
154853         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
154855 2003-11-17  Bruno Haible  <bruno@clisp.org>
154857         * lib/vasnprintf.c (alloca): Remove fallback definition.
154858         (freea): Remove definition.
154859         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
154860         Reported by Paul Eggert.
154862 2003-11-16  Paul Eggert  <eggert@twinsun.com>
154863             Bruno Haible  <bruno@clisp.org>
154865         Protect against address arithmetic overflow.
154866         * lib/printf-args.h: Include stddef.h.
154867         (arguments): Change type of field 'count' to size_t.
154868         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
154869         'unsigned int' where appropriate.
154870         * lib/printf-parse.h: Include sys/types.h.
154871         (char_directive): Change type of *arg_index fields to ssize_t.
154872         (char_directives): Change type of fields 'count', max_*_length to
154873         size_t.
154874         * lib/printf-parse.c: Include sys/types.h and xsize.h.
154875         (SSIZE_MAX): Define fallback value.
154876         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
154877         instead of 'int' where appropriate. Check a_allocated, d_allocated
154878         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
154879         * lib/vasnprintf.c: Include xsize.h.
154880         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
154881         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
154882         overflow. Avoid wraparound when converting a width or precision from
154883         decimal to binary.
154885 2003-11-16  Bruno Haible  <bruno@clisp.org>
154887         Update from GNU gettext.
154888         * lib/printf-parse.c: Generalize to it can be compiled for wide
154889         strings.
154890         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
154891         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
154892         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
154893         SNPRINTF): New macros.
154894         Don't include <alloca.h> if the file is used inside libintl.
154895         (local_wcslen): New function, for Solaris 2.5.1.
154896         (VASNPRINTF): Use it instead of wcslen.
154898 2003-11-16  Bruno Haible  <bruno@clisp.org>
154900         * lib/xsize.h (xmax): New function.
154901         (xsum, xsum3, xsum4): Declare as "pure" functions.
154903 2003-11-12  Paul Eggert  <eggert@twinsun.com>
154905         * modules/xalloc (Files): Undo latest change, since xalloc.h
154906         no longer needs SIZE_MAX or PTRDIFF_MAX.
154908 2003-11-12  Paul Eggert  <eggert@twinsun.com>
154910         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
154911         gl_PTRDIFF_MAX.
154913 2003-11-12  Paul Eggert  <eggert@twinsun.com>
154915         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
154916         "return", to pacify some unknown compiler.  Problem reported
154917         by Joerg Schilling.
154919 2003-11-12  Paul Eggert  <eggert@twinsun.com>
154921         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
154922         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
154923         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
154924         heuristic is just as accurate as far as we know, and it removes a
154925         dependency on size_max.m4 and ptrdiff_max.m4.
154927 2003-11-11  Bruno Haible  <bruno@clisp.org>
154929         * modules/xsize (Files): Add m4/size_max.m4.
154930         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
154932 2003-11-11  Bruno Haible  <bruno@clisp.org>
154934         * m4/size_max.m4: New file.
154935         * m4/ptrdiff_max.m4: New file.
154936         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
154937         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
154938         (gl_XALLOC): Invoke it.
154940 2003-11-11  Bruno Haible  <bruno@clisp.org>
154942         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
154943         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
154944         defined.
154946 2003-11-10  Paul Eggert  <eggert@twinsun.com>
154948         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
154949         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
154950         rejected some allocations of exactly SIZE_MAX - 2 bytes.
154951         From Bruno Haible.
154952         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
154953         not (size_t) -1, since it's defined here.
154955 2003-11-09  Karl Berry  <karl@gnu.org>
154957         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
154959 2003-11-06  Paul Eggert  <eggert@twinsun.com>
154961         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
154962         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
154963         Reject sizes of exactly SIZE_MAX bytes.
154964         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
154965         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
154967 2003-11-05  Bruno Haible  <bruno@clisp.org>
154969         * lib/xsize.h: Include limits.h, to avoid a possible collision with
154970         SIZE_MAX defined in <limits.h> on Solaris.
154972 2003-11-04  Jim Meyering  <jim@meyering.net>
154974         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
154975         variable names, rather than @VAR@.
154976         * modules/poll: Likewise.
154978 2003-11-04  Bruno Haible  <bruno@clisp.org>
154980         * modules/xsize: New file.
154981         * modules/linebreak: Depend on xsize.
154982         * MODULES.html.sh (func_all_modules): Add xsize.
154984 2003-11-04  Bruno Haible  <bruno@clisp.org>
154986         * m4/xsize.m4: New file.
154988 2003-11-04  Bruno Haible  <bruno@clisp.org>
154990         * lib/xsize.h: New file.
154991         * lib/linebreak.c: Include xsize.h.
154992         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
154993         argument for overflow.
154994         Suggested by Paul Eggert.
154996 2003-11-03  Karl Berry  <karl@gnu.org>
154998         * config/config.{guess,sub}: update from config.
155000 2003-11-03  Jim Meyering  <jim@meyering.net>
155002         * modules/userspec (lib_SOURCES): Add userspec.h.
155003         (Include): Add "userspec.h".
155004         Improve description.
155006 2003-11-03  Jim Meyering  <jim@meyering.net>
155008         * lib/userspec.c: Include "userspec.h".
155009         * lib/userspec.h: New file.
155011 2003-11-03  Bruno Haible  <bruno@clisp.org>
155013         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
155015 2003-11-03  Bruno Haible  <bruno@clisp.org>
155017         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
155018         available, to avoid (extremely rare) race condition.
155019         Suggested by Paul Eggert.
155021 2003-11-02  Karl Berry  <karl@gnu.org>
155023         * config/srclist.txt (vasprintf.c): sync broken, sigh.
155025 2003-10-31  Paul Eggert  <eggert@twinsun.com>
155027         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
155028         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
155029         (read_filesystem_list): Set and use me_type_malloced.
155030         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
155031         whatever the type happens to be), for brevity and consistency.
155032         Check for size calculation overflow on Alphas running OSF/1.
155034 2003-10-31  Jim Meyering  <jim@meyering.net>
155036         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
155038         * lib/linebuffer.c: Include <string.h> for declaration of memset.
155040 2003-10-30  Paul Eggert  <eggert@twinsun.com>
155041             Bruno Haible  <bruno@clisp.org>
155043         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
155044         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
155046 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
155048         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
155049         netbsd*-gnu*.  Suggested by Robert Millan.
155051 2003-10-29  Paul Eggert  <eggert@twinsun.com>
155053         * modules/group-member: Depend on stdbool.
155055 2003-10-29  Paul Eggert  <eggert@twinsun.com>
155057         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
155059 2003-10-29  Paul Eggert  <eggert@twinsun.com>
155061         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
155062         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
155063         after the 'gnu' in these cases.  This fixes some bugs in the
155064         previous change, and is based on suggestions by Robert Millan.
155066 2003-10-29  Paul Eggert  <eggert@twinsun.com>
155068         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
155069         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
155070         no longer needed.
155071         * lib/quotearg.c (quotearg_n_options): Use it.
155072         * lib/group-member.c: Include <stdbool.h>.
155073         (free_group_info): Arg is now const *; don't free arg.
155074         (get_group_info): Now returns bool and accepts struct group_info *,
155075         rather than returning a malloc'ed struct group_info *.
155076         All uses changed.  Check for overflow in internal size calculation.
155078         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
155079         rather than xmalloc/xrealloc.
155080         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
155081         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
155082         conformance bug: the old code used a pointer after freeing the
155083         storage that it addressed.
155084         * lib/hash.c (hash_initialize): Simplify the code by using
155085         xalloc_oversized rather than doing it by hand.
155086         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
155087         the buffer preserved.  Use free and xmalloc instead.
155088         * lib/quotearg.c (quotearg_n_options): Likewise.
155089         Use a simpler test for size overflow.  Don't use xalloc_oversized
155090         because unsigned int might be wider than size_t (!); this suggests
155091         that we should switch from unsigned int to size_t for slot numbers.
155093 2003-10-28  Paul Eggert  <eggert@twinsun.com>
155095         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
155096         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
155097         NetBSD kernels.  Requested by Richard Stallman.
155099 2003-10-27  Paul Eggert  <eggert@twinsun.com>
155101         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
155102         to allocate the returned structure.  Do not allocate a subarray,
155103         as x2nrealloc will do that.
155104         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
155105         instead of xnrealloc.
155106         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
155108 2003-10-27  Bruno Haible  <bruno@clisp.org>
155110         * lib/stdbool_.h: Better support for BeOS.
155112 2003-10-26  Paul Eggert  <eggert@twinsun.com>
155114         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
155115         now uses inline.
155117 2003-10-26  Paul Eggert  <eggert@twinsun.com>
155119         * lib/xalloc.h (xalloc_oversized): New static inline function, for
155120         callers that want to do their own size-overflow checking.  Include
155121         <stdbool.h>, since xalloc_oversized returns bool.
155122         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
155123         to use xalloc_oversized.
155125         Add two functions x2realloc, x2nrealloc, for programs that grow
155126         arrays dynamically by doubling their sizes.
155127         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
155128         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
155129         New functions.
155131         Port to C99 semantics for 'inline' of external functions.
155132         Bug reported by Bruno Haible.
155133         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
155134         with the old contents of xnmalloc.
155135         (xnmalloc, xmalloc): Use it.
155136         (xnrealloc_inline): New static inline function,
155137         with the old contents of xnrealloc.
155138         (xnrealloc, xrealloc): Use it.
155140         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
155141         that.
155143 2003-10-26  Karl Berry  <karl@gnu.org>
155145         * config/srclist.txt (COPYING.DOC): no longer available from
155146         /gd/gnuorg; don't know where the ultimate source is.
155148 2003-10-25  Paul Eggert  <eggert@twinsun.com>
155150         Fix several address-calculation bugs in the hash modules,
155151         plus some minor code cleanup.
155153         * lib/hash.h: Include <stdbool.h>, for bool.
155154         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
155155         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
155156         hash_get_n_entries, hash_get_max_bucket_length,
155157         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
155158         hash_rehash): Use size_t rather than unsigned.
155159         * lib/hash.c (struct hash_table, hash_get_n_buckets,
155160         hash_get_n_buckets_used, hash_get_n_entries,
155161         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
155162         hash_get_entries, hash_do_for_each, hash_string, is_prime,
155163         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
155164         Likewise.
155165         (SIZE_MAX): Define if not defined.
155166         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
155167         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
155168         hash_print):
155169         Use const * when possible.
155170         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
155171         (check_tuning): Fix bug: if tuning parameters were very close to
155172         0 or 1, rounding errors could have caused subscript violations.
155173         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
155174         (hash_initialize): Add 'fail:' label
155175         to free table and return NULL, and use it to simplify code.
155176         Use calloc rather than clearing the storage ourself.
155177         (hash_initialize, hash_rehash): Check for arithmetic overflow in
155178         buffer size calculations.
155179         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
155180         Include <stddef.h>, for size_t.
155181         * lib/hash-pjw.c (hash_pjw): Likewise.
155182         Switch to method described by Bruno Haible.
155183         Include <limits.h>, for CHAR_BIT.
155184         (SIZE_BITS): New macro.
155186 2003-10-23  Paul Eggert  <eggert@twinsun.com>
155188         * m4/getline.m4 (AM_FUNC_GETLINE):
155189         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
155190         hosts.  Problem reported by Derek Robert Price in
155191         <http://mail.gnu.org/r/bug-gnulib/2003-10/msg00092.html>.
155192         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
155193         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
155195 2003-10-21  Paul Eggert  <eggert@twinsun.com>
155197         * lib/getndelim2.c (getndelim2): When size calculation overflows,
155198         ceiling the allocation at NMAX bytes rather than silently
155199         discarding input bytes before NMAX is reached.  This makes
155200         a difference only if NMAX exceeds SIZE_MAX / 2.
155202         * lib/obstack.c: Merge from glibc.
155203         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
155204         Add libc_hidden_def (_obstack_newchunk).
155205         (_obstack_free) [! defined _LIBC]: Remove.
155206         [defined _LIBC]: Make a strong alias from obstack_free, rather than
155207         a clone of the function body.
155208         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
155209         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
155211         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
155212         glibc.
155213         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
155214         arg to memcpy.
155216         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
155217         (obstack_ptr_grow_fast, obstack_int_grow_fast):
155218         Don't use lvalue casts, as GCC plans to remove support for them
155219         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
155220         was also present in the non-GCC version, indicating that this
155221         code had always been buggy and had never been widely used.
155222         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
155223         Use the fast variant of each macro, rather than copying the
155224         definiens of the fast variant; that way, we'll be more likely to
155225         catch future bugs in the fast variants.
155227 2003-10-20  Bruno Haible  <bruno@clisp.org>
155229         * modules/wait-process: New file.
155230         * MODULES.html.sh (func_all_modules): Add wait-process.
155232 2003-10-20  Bruno Haible  <bruno@clisp.org>
155234         * m4/wait-process.m4: New file.
155236 2003-10-20  Bruno Haible  <bruno@clisp.org>
155238         * lib/wait-process.h: New file, from GNU gettext.
155239         * lib/wait-process.c: New file, from GNU gettext.
155241 2003-10-19  Jim Meyering  <jim@meyering.net>
155243         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
155244         HPUX 10.20.
155246 2003-10-18  Karl Berry  <karl@gnu.org>
155248         * config/config.guess: update from config.
155250 2003-10-16  Paul Eggert  <eggert@twinsun.com>
155252         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
155253         (getgroups): First arg is int, not size_t.
155254         Don't let 'free' mangle errno.
155256 2003-10-16  Paul Eggert  <eggert@twinsun.com>
155258         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
155260 2003-10-16  Karl Berry  <karl@gnu.org>
155262         * config/config.{guess,sub}: update from config.
155264 2003-10-16  Jim Meyering  <jim@meyering.net>
155266         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
155267         memcpy.
155269 2003-10-15  Paul Eggert  <eggert@twinsun.com>
155271         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
155272         (SIZE_MAX): Remove.
155273         (new_exclude, add_exclude_file): Initial size no longer needs to
155274         be a power of 2.
155275         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
155276         our own address arithmetic overflow checking.
155278         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
155279         (fnmatch): Do not alloca more than 2000 wide characters;
155280         instead, use malloc for large buffers.
155281         Check for address arithmetic overflow, and return -1
155282         with errno set to ENOMEM in that case.
155283         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
155284         (NEW_PATTERN): Do not alloca more than 8000 bytes;
155285         instead, return -1.  Check for address arithmetic overflow.
155287 2003-10-14  Paul Eggert  <eggert@twinsun.com>
155289         Handle invalid suffixes and overflow independently, so that
155290         callers can treat them independently as needed.  Fix some bugs in
155291         suffix handling, e.g., "100k@" was not diagnosed as an invalid
155292         suffix for a human-readable blocksize.  The major caller-visible
155293         change is the addition of a new
155294         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
155295         that both overflow and suffix chars were found.
155297         * lib/human.c (humblock): Don't check separately for invalid suffix
155298         char; that is xstrtoumax's job (now that its bug is fixed).
155299         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
155300         INTMAX_MAX]: New macros.
155301         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
155302         TYPE_MAXIMUM): New macros.
155303         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
155304         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
155305         if overflow occurs, as it's what __strtol does and it's more useful
155306         in practice.
155307         (__xstrtol): If __strtol reports some error other than ERANGE,
155308         reflect it to the caller as LONGINT_INVALID.  If it reports
155309         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
155310         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
155311         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
155312         value.
155313         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
155314         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
155315         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
155316         [defined UINTMAX_MAX]: New macros.
155318 2003-10-14  Bruno Haible  <bruno@clisp.org>
155320         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
155322 2003-10-14  Bruno Haible  <bruno@clisp.org>
155324         * m4/sig_atomic_t: New file, from GNU gettext.
155325         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
155327 2003-10-14  Bruno Haible  <bruno@clisp.org>
155329         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
155330         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
155331         Also use volatile where needed.
155333 2003-10-12  Paul Eggert  <eggert@twinsun.com>
155335         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
155336         Change maintainer from Bruno Haible to 'all'.
155338 2003-10-12  Paul Eggert  <eggert@twinsun.com>
155340         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
155342 2003-10-12  Paul Eggert  <eggert@twinsun.com>
155344         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
155345         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
155346         and define in terms of the other primitives.
155347         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
155348         (SIZE_MAX): Define if not already defined.
155349         (array_size_overflow): New function.
155350         (xalloc_die): Abort instead of exiting if 'error' returns.
155351         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
155352         (xmalloc, xrealloc): Use them.
155353         (xcalloc): Check for address arithmetic overflow.
155354         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
155355         a bit faster than strcpy.
155357 2003-10-10  Simon Josefsson  <jas@extundo.com>
155359         * modules/argp (Depends-on): Add restrict and strcase.
155361 2003-10-10  Simon Josefsson  <jas@extundo.com>
155363         * m4/argp.m4: Add AC_C_INLINE.
155365 2003-10-08  Paul Eggert  <eggert@twinsun.com>
155367         Merge getpass from libc, plus a few fixes.
155369         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
155370         Include <stdbool.h>.
155371         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
155372         __fsetlocking to empty.
155373         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
155374         do include <bits/libc-lock.h>.
155375         Do not include <fcntl.h>; not needed.
155376         [_LIBC]: Include <wchar.h>.
155377         (NOTCANCEL_MODE): New macro.
155378         (flockfile, funlockfile) [_LIBC]: New macros.
155379         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
155380         [!_LIBC]: New macros.
155381         (call_fclose): New function.
155382         (getpass): Use it.  Save tty stream separately; this simplifies the
155383         code and makes it more reliable if stdin happens to equal stdout.
155384         Invoke __fsetlocking on tty.
155385         Handle thread cancellation if needed.
155386         Namespace cleanup (use __tcgetattr, __getline).
155387         Use bool for Booleans.
155388         [USE_IN_LIBIO]: Handle wide streams.
155389         [!_LIBC]: Unconditionally do the fseek, since we don't know what
155390         stream might go where.
155392         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
155393         doesn't have to include <stdio.h> before us.
155394         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
155395         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
155396         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
155397         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
155398         if not declared, so that we can use getpass.c code from libc without
155399         rewriting it.
155400         (flockfile, ftrylockfile, funlockfile): New macros.
155402 2003-10-08  Paul Eggert  <eggert@twinsun.com>
155404         * modules/getpass: Depend on stdbool.
155406 2003-10-08  Paul Eggert  <eggert@twinsun.com>
155408         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
155410 2003-10-07  Karl Berry  <karl@gnu.org>
155412         * config/config.{guess,sub}: update from config.
155414 2003-10-06  Jim Meyering  <jim@meyering.net>
155415             Bruno Haible  <bruno@clisp.org>
155417         This lets translators provide better translations for the
155418         "Written by ..." part of --version output.
155419         * lib/version-etc.h: Include stdarg.h.
155420         (version_etc_copyright): Declare as readonly.
155421         (version_etc): Make this function variadic with a NULL-terminated list
155422         of author name strings.
155423         (version_etc_va): New declaration.
155424         * lib/version-etc.c: Include stdarg.h, stdlib.h.
155425         (version_etc_copyright): Declare as readonly.
155426         (version_etc_va): New function. Provide a different translatable string
155427         for each possible number of authors < 10. Abbreviate when there are 10
155428         authors or more.
155429         (version_etc): Make this function variadic. Call version_etc_va.
155430         Suggestion from Gary V. Vaughan.
155432         * lib/long-options.h (parse_long_options): Change prototype: the
155433         authors string is moved to the end and becomes variadic.
155434         * lib/long-options.c: Include stdarg.h.
155435         (parse_long_options): Make this function variadic, too.
155436         Call version_etc_va, not version_etc.
155438 2003-10-06  Bruno Haible  <bruno@clisp.org>
155440         * modules/version-etc-2: Remove file.
155441         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
155443 2003-10-06  Bruno Haible  <bruno@clisp.org>
155445         * modules/fatal-signal: New file.
155446         * MODULES.html.sh (func_all_modules): Add fatal-signal.
155448 2003-10-06  Bruno Haible  <bruno@clisp.org>
155450         * m4/fatal-signal.m4: New file.
155451         * m4/signalblocking.m4: New file, from GNU gettext.
155453 2003-10-06  Bruno Haible  <bruno@clisp.org>
155455         * lib/version-etc-2.h: Remove file.
155456         * lib/version-etc-2.c: Remove file.
155458 2003-10-06  Bruno Haible  <bruno@clisp.org>
155460         * lib/fatal-signal.h: New file, from GNU gettext.
155461         * lib/fatal-signal.c: New file, from GNU gettext.
155463 2003-10-05  Paul Eggert  <eggert@twinsun.com>
155465         * README: Rework advice for preventing empty .o files.
155466         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
155467         not <sys/types.h>.
155469 2003-10-04  Karl Berry  <karl@gnu.org>
155471         * lib/argp*: update from libc.
155473 2003-10-04  Karl Berry  <karl@gnu.org>
155475         * config/config.{guess,sub}: update from config.
155477 2003-10-02  Bruno Haible  <bruno@clisp.org>
155479         * modules/lchown (Include): Add lchown.h.
155480         * modules/time_r (Include): Use "..." syntax.
155481         * modules/xgetdomainname (Include): Add xgetdomainname.h.
155483 2003-10-01  Simon Josefsson  <jas@extundo.com>
155485         * MODULES.html.sh (func_all_modules): Move gethostname from section
155486         'based on' to section 'lacking' POSIX:2001.
155488 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
155490         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
155491         to output mode on the same stream.
155493 2003-09-29  Paul Eggert  <eggert@twinsun.com>
155495         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
155496         Fix arg typo in previous patch.
155498 2003-09-28  Jim Meyering  <jim@meyering.net>
155500         * lib/error.c: Correct cpp indentation.
155502 2003-09-27  Paul Eggert  <eggert@twinsun.com>
155504         * modules/free: New file.
155506 2003-09-27  Paul Eggert  <eggert@twinsun.com>
155508         * m4/free.m4: New file.
155510 2003-09-27  Paul Eggert  <eggert@twinsun.com>
155512         * lib/minmax.h (MIN, MAX)
155513         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
155514         Omit the special code that used __typeof__, since we worry that
155515         it could be more trouble than it's worth.  See:
155516         http://mail.gnu.org/r/bug-gnulib/2003-01/msg00090.html
155517         http://mail.gnu.org/r/bug-gnulib/2003-01/msg00095.html
155519         * lib/free.c: New file.
155521 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
155523         Trivial fixes to Makefile.am parts of module listings.
155524         * modules/strstr: Append strstr.h to lib_SOURCES.
155525         * modules/strcase: Likewise, for strcase.h.
155527 2003-09-27  Karl Berry  <karl@gnu.org>
155529         * config/mkinstalldirs: update from automake.
155531 2003-09-26  Paul Eggert  <eggert@twinsun.com>
155533         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
155534         (error_tail): Do not loop, reallocating temporary buffer, since
155535         the output cannot contain more wide characters than the input
155536         contains bytes, the size must be big enough already.  This avoids
155537         one potential size overflow calculation.  Check for size overflow
155538         when calculating temporary buffer size.  Free temporary buffer
155539         when done, if it was allocated with malloc; this plugs a memory
155540         leak.  Remove casts from void * to pointers, that are no longer
155541         needed now that we're assuming C89 or better.
155543         Merge error changes from glibc.
155545         * lib/error.c, error.h: Update copyright notice header to match glibc.
155546         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
155547         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
155548         Disable cancellation while printing error.
155549         * lib/error.h: Prepend __ to parameter names.
155551 2003-09-26  Jim Meyering  <jim@meyering.net>
155553         * lib/error.c (error_tail): Move some declarations
155554         into inner scope where the local variables are used.
155556 2003-09-26  Bruno Haible  <bruno@clisp.org>
155558         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
155559         stpncpy().
155560         Don't define stpncpy through config.h; it's now done through stpncpy.h.
155562 2003-09-26  Bruno Haible  <bruno@clisp.org>
155564         * lib/stpncpy.h (gnu_stpncpy): New declaration.
155565         (stpncpy): Define as alias for gnu_stpncpy.
155566         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
155568 2003-09-25  Simon Josefsson  <jas@extundo.com>
155570         * lib/xgetdomainname.h: New file.
155571         * lib/xgetdomainname.c: New file.
155573 2003-09-25  Simon Josefsson  <jas@extundo.com>
155574             Bruno Haible  <bruno@clisp.org>
155576         * modules/getdomainname: New file.
155577         * modules/xgetdomainname: New file.
155578         * MODULES.html.sh (func_all_modules): Add getdomainname,
155579         xgetdomainname.
155581 2003-09-25  Simon Josefsson  <jas@extundo.com>
155582             Bruno Haible  <bruno@clisp.org>
155584         * m4/getdomainname.m4: New file.
155586 2003-09-25  Simon Josefsson  <jas@extundo.com>
155587             Bruno Haible  <bruno@clisp.org>
155589         * lib/getdomainname.h: New file.
155590         * lib/getdomainname.c: New file.
155592 2003-09-25  Karl Berry  <karl@gnu.org>
155594         * lib/argp-fmtstream.c, argp-help.c: update from libc.
155596 2003-09-25  Karl Berry  <karl@gnu.org>
155598         * config/install-sh: update from automake.
155600 2003-09-25  Bruno Haible  <bruno@clisp.org>
155602         * modules/version-etc-2: New file, from modules/version-etc with
155603         modifications.
155604         * MODULES.html.sh (func_all_modules): Add version-etc-2.
155606 2003-09-25  Bruno Haible  <bruno@clisp.org>
155608         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
155609         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
155611 2003-09-24  Simon Josefsson  <jas@extundo.com>
155613         * modules/xgethostname: Add xgethostname.h.
155615 2003-09-24  Paul Eggert  <eggert@twinsun.com>
155617         * lib/linebuffer.c (freebuffer): Don't free the argument, just
155618         the buffer associated with the argument.  Bug reported by
155619         Simon Josefsson.
155621 2003-09-24  Paul Eggert  <eggert@twinsun.com>
155623         * README: Document assumptions that 'int' is at least 32 bits
155624         wide, that integer arithmetic is 2's complement without overflow,
155625         that there are no holes in integer values, that adding sizes of
155626         two nonoverlapping objects can't overflow, and that all-bits-zero
155627         yields scalar zero.  Fix spelling and capitalization typos.
155629 2003-09-19  Karl Berry  <karl@gnu.org>
155631         * lib/argp.h: update from libc.
155633 2003-09-17  Paul Eggert  <eggert@twinsun.com>
155635         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
155636         to avoid spurious warnings like "AC_RUN_IFELSE was called before
155637         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
155639 2003-09-17  Paul Eggert  <eggert@twinsun.com>
155641         * gnulib-tool: Use "test -h", not "test -L", for portability
155642         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
155643         (tags_regexp): Remove, since \| doesn't conform to POSIX.
155644         (sed_extract_prog): Issue s commands one-by-one, rather than
155645         using \| in one s command.
155647 2003-09-16  Paul Eggert  <eggert@twinsun.com>
155649         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
155650         input error, instead of returning NULL the next time we are called
155651         (and therefore losing track of errno).
155653 2003-09-16  Bruno Haible  <bruno@clisp.org>
155655         * gnulib-tool (func_create_testdir): Warn about duplicated
155656         dependencies.
155658 2003-09-15  Paul Eggert  <eggert@twinsun.com>
155660         * modules/argmatch, modules/fatal, modules/obstack,
155661         modules/xalloc, modules/xgethostname: Sort dependencies by
155662         importance, not alphabetically.
155664 2003-09-15  Paul Eggert  <eggert@twinsun.com>
155666         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
155667         fails, so that the caller gets the proper errno.
155669         * lib/readutmp.c (read_utmp): Likewise.
155670         Check for fstat error.  Close stream and free storage
155671         when failing.
155673 2003-09-14  Karl Berry  <karl@gnu.org>
155675         * config/srclist.txt (strdup.c): disable for c89 changes.
155677 2003-09-14  Jim Meyering  <jim@meyering.net>
155679         * lib/getloadavg.c: Correct cpp indentation.
155680         * lib/strdup.c: Likewise.
155681         * lib/vasnprintf.c: Likewise.
155683 2003-09-14  Bruno Haible  <bruno@clisp.org>
155685         * modules/fwriteerror: New file.
155686         * MODULES.html.sh (func_all_modules): Add fwriteerror.
155688 2003-09-14  Bruno Haible  <bruno@clisp.org>
155690         * lib/fwriteerror.h: New file.
155691         * lib/fwriteerror.c: New file.
155693 2003-09-12  Paul Eggert  <eggert@twinsun.com>
155695         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
155696         modules/xgethostname, modules/xalloc: Depend on exit.
155698 2003-09-12  Paul Eggert  <eggert@twinsun.com>
155700         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
155702         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
155703         and AC_MINIX, too, so that their extensions are available.
155705         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
155706         This macro has been superseded by gl_BACKUPFILE.
155708         More patches to assume C89 or better.
155710         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
155712         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
155713         unconditionally.
155714         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
155715         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
155716         Include <string.h>, <stdlib.h> unconditionally.
155717         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
155718         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
155719         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
155720         headers or for string.h.
155721         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
155722         or strtoul.
155724         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
155725         headers.
155726         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
155727         * m4/userspec.m4 (gl_USERSPEC): Likewise.
155728         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
155729         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
155730         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
155731         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
155732         memcpy, memset.
155733         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
155734         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
155735         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
155736         strtol.
155737         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
155738         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
155739         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
155740         strtoul.
155742 2003-09-12  Paul Eggert  <eggert@twinsun.com>
155744         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
155745         * lib/obstack.c [!defined _LIBC]: Likewise.
155746         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
155747         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
155748         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
155750         More changes to assume C89 or better.
155752         * lib/error.c (error_tail): Assume vprintf.
155754         * lib/argmatch.c (getenv): Remove decl.
155755         * lib/progreloc.c (get_full_program_name): Define via prototype.
155756         * lib/setenv.c (clearenv): Likewise.
155757         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
155758         needed.
155759         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
155760         (malloc, memcpy): Remove decls.
155761         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
155762         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
155763         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
155764         (memcpy): Remove macro.
155765         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
155766         (__P): Remove.  All uses removed.
155767         (PTR): Remove.  All uses changed to void *.
155768         (CHAR_BIT, NULL): Remove.
155769         (spaces, zeros, memset_space, memset_zero)
155770         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
155771         Remove.
155772         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
155773         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
155774         Define with prototype.
155775         Remove now-unnecessary prototype decl.
155776         (extra_args_spec): Assume ANSI C.  All uses changed.
155777         (extra_args_spec_iso): Remove.
155778         (my_strftime, emacs_strftimeu): Define via prototype.
155779         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
155780         unconditionally.
155781         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
155782         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
155783         (strtoul, strtol): Remove decls.
155784         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
155785         LONG_MAX): Remove.
155786         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
155787         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
155788         (LOCALE_PARAM_PROTO): New macro.
155789         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
155790         (INTERNAL (strtol), strtol): Define with a prototype.
155791         (PARAMS): Remove.  All uses removed.
155792         * lib/tempname.c: Include <string.h> unconditionally.
155793         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
155794         * lib/xgethostname.c (main): Define with a prototype.
155795         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
155796         Include <stdlib.h> unconditionally.
155797         (calloc, malloc, realloc, free): Remove decls.
155798         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
155799         Include <stdlib.h> unconditionally.  Sort include file names.
155800         (strtod): Remove.
155801         (xstrtod): Define with a prototype.
155802         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
155803         (strtol, strtoul): Remove decls.
155805 2003-09-11  Paul Eggert  <eggert@twinsun.com>
155807         More patches to assume C89 or better.
155808         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
155809         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
155810         string.h, memchr, STDC_HEADERS.
155812 2003-09-11  Paul Eggert  <eggert@twinsun.com>
155814         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
155815         Include <stdlib.h>, <string.h> unconditionally.
155816         Remove now-unnecessary cast to char *.
155817         * lib/strnlen.c: Include <string.h> unconditionally.
155818         * lib/yesno.c (yesno): Define with a prototype.
155820 2003-09-11  Bruno Haible  <bruno@clisp.org>
155822         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
155824 2003-09-10  Jim Meyering  <jim@meyering.net>
155826         * lib/error.c: Correct indentation of cpp directives.
155828 2003-09-10  Bruno Haible  <bruno@clisp.org>
155830         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
155831         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
155832         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
155833         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
155834         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
155835         <stdlib.h> and <string.h> checks.
155836         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
155837         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
155839 2003-09-10  Bruno Haible  <bruno@clisp.org>
155841         * lib/strcspn.c: Include <string.h> unconditionally.
155842         * lib/strpbrk.c: Include <string.h> unconditionally.
155843         * lib/strstr.c: Include <string.h> unconditionally.
155844         * lib/unicodeio.c: Include <string.h> unconditionally.
155845         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
155846         * lib/unsetenv.c: Likewise.
155847         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
155848         * lib/yesno.c: Include <stdlib.h> unconditionally.
155849         (rpmatch): Add prototype.
155851 2003-09-09  Paul Eggert  <eggert@twinsun.com>
155853         More patches to assume C89 or better.
155854         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
155855         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
155856         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
155857         or for string.h.
155858         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
155859         stdlib.h.
155860         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
155861         C headers.
155862         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
155863         string.h.
155864         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
155865         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
155866         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
155867         or for string.h.
155868         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
155869         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
155870         C headers.
155871         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
155872         memcpy.
155873         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
155874         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
155875         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
155876         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
155877         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
155878         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
155879         string.h, free.
155880         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
155881         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
155882         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
155883         C headers, or for string.h.
155884         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
155885         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
155886         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
155887         headers, memory.h, stdlib.h, string.h, strings.h.
155888         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
155889         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
155890         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
155891         strchr.
155892         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
155893         headers, memory.h, string.h.
155894         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
155895         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
155896         free.
155897         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
155898         headers.
155899         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
155900         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
155901         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
155902         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
155903         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
155905 2003-09-09  Paul Eggert  <eggert@twinsun.com>
155907         More K&R removal.
155909         * lib/acosl.c (main): Use a prototype.
155910         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
155911         tanl.c: Likewise.
155913         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
155915         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
155916         (getopt, etopt_long, getopt_long_only, _getopt_internal)
155917         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
155918         with a prototype.
155919         * lib/getopt.c (const): Remove macro.
155920         Include <string.h> unconditionally.
155921         (my_index): Remove; all uses changed to strchr.
155922         (strlen): Remove decl.
155923         (exchange): Remove forward decl; no longer needed.
155924         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
155925         Define with prototype.
155926         * lib/getopt1.c (const): Remove macro.
155927         (getopt_long, getopt_long_only, main): Define with prototype.
155929         * lib/getugroups.c: Include <string.h> unconditionally.
155931         * lib/getusershell.c: Include <stdlib.h> unconditionally.
155932         (getusershell, setusershell, endusershell, readname, main):
155933         Define with prototypes.
155935         * lib/group-member.c: Include group-member.h first.
155936         Include <stdlib.h> unconditionally.
155938         * lib/hard-locale.c: Include hard-locale.h first.
155939         Include <stdlib.h>, <string.h> unconditionally.
155941         * lib/hash.c (free, malloc): Remove decls.
155942         Include <stdlib.h> unconditionally.
155944         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
155945         (getenv): Do not declare.
155947         * lib/idcache.c: Include <string.h> unconditionally.
155949         * lib/long-options.c: Include long-options.h first, to test interface.
155950         Include <stdlib.h> unconditionally.
155952         * lib/makepath.c: Include makepath.h first, to test interface.
155953         Include <stdlib.h> and <string.h> unconditionally.
155955         * lib/linebuffer.c: Include <stdlib.h>.
155956         (free): Remove decl.
155958         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
155959         stddef.h. rpl_malloc returns void *, not char *.
155960         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
155961         prototype.
155963         * lib/md5.h: Include <limits.h> unconditionally.
155964         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
155965         (__P): Remove; all uses removed.
155966         * lib/md5.c: Include "md5.h" first.
155967         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
155968         md5_buffer, md5_process_bytes, md5_process_block):
155969         Define with prototypes.
155970         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
155971         * lib/sha.c: Include "sha.h" first.
155972         Include <stdlib.h>, <string.h> unconditionally.
155974         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
155975         * lib/memcmp.c (__ptr_t): Likewise.
155976         * lib/memrchr.c (__ptr_t): Likewise.
155977         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
155978         Include <string.h> unconditionally.
155979         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
155980         * lib/memchr.c: Include <stdlib.h> unconditionally.
155981         * lib/memchr.c (LONG_MAX): Remove.
155982         * lib/memrchr.c (LONG_MAX): Likewise.
155983         * lib/memchr.c (__memchr): Define via a prototype.
155984         * lib/memrchr.c (__memrchr): Likewise.
155985         * lib/memcmp.c (__P): Remove, and remove all uses.
155986         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
155987         Remove forward decls; no longer needed.
155988         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
155989         Use types required by C89 in prototype.
155991         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
155992         * lib/savedir.c: Likewise.
155993         * lib/mkdir.c (free): Remove decl.
155994         * lib/rmdir.c (rmdir): Define with a prototype.
155995         * lib/savedir.c: Include savedir.h first, to test interface.
155997         * lib/mktime.c (STDC_HEADERS): Remove.
155998         Include <stdlib.h>, <string.h> unconditionally.
156000         * lib/modechange.c: Include <stdlib.h> unconditionally.
156001         (malloc): Remove decl.
156003         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
156004         (free): Remove decl.
156006         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
156007         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
156008         (This type really should be intptr_t, but that's a C99ism.)
156009         (_obstack_memcpy): Remove: all uses changed to memcpy.
156010         Include <string.h> unconditionally.
156011         (struct obstack): Assume __STDC__ for types of members
156012         chunkfun, freefun, extra_arg.
156013         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
156014         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
156015         obstack_begin, obstack_specify_allocation,
156016         obstack_specify_allocation_with_arg, obstack_chunkfun,
156017         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
156018         Remove unprototyped decls and the macros that use them.
156019         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
156020         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
156021         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
156022         (defined __STDC__ && __STDC__)]:
156023         Remove nonprototyped code.
156024         Include <stdlib.h> unconditionally.
156025         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
156026         _obstack_allocated_p, _obstack_free, obstack_free,
156027         _obstack_memory_used, print_and_abort):
156028         Define using prototypes.
156029         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
156030         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
156031         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
156032         obstack_next_free, obstack_object_size, obstack_room) [0]:
156033         Remove unused, unprototyped code.
156035         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
156037         * lib/physmem.c (physmem_total, physmem_available, main): Define
156038         with prototypes.
156040         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
156041         (main): Define with a prototype.
156043         * lib/posixver.c (getenv): Remove decl.
156045         * lib/putenv.c (malloc): Returns void *, not char *.
156046         Include <string.h> unconditionally.
156047         (strchr, memcpy, NULL): Do not define.
156049         * lib/readtokens.c: Include readtokens.h first, to test interface.
156050         Include <stdlib.h>, <string.h> unconditionally.
156051         (init_tokenbuffer): Define with a prototype.
156053         * lib/regex.c (PARAMS): Remove.  All uses removed.
156054         All uses of _RE_ARGS removed, too.
156055         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
156056         unconditionally.
156057         (bzero): Assume memset exists.
156058         (memcmp, memcpy, NULL): Remove.
156059         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
156060         char, or assignments to local vars of type signed char.
156061         (init_syntax_once, PREFIX(extract_number_and_incr),
156062         PREFIX(print_partial_compiled_pattern),
156063         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
156064         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
156065         PREFIX(regex_grow_registers), PREFIX(regex_compile),
156066         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
156067         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
156068         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
156069         wcs_compile_range, byte_compile_range, truncate_wchar,
156070         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
156071         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
156072         count_mbs_length, wcs_re_match_2_internal,
156073         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
156074         PREFIX(alt_match_null_string_p),
156075         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
156076         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
156077         regfree, PREFIX(extract_number)): Define with prototype.  Remove
156078         now-unnecessary declaration, if any.
156079         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
156080         regcomp, regexec):
156081         Remove now-unnecessary casts among pointer types.
156082         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
156084         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
156085         (free): Remove decl.
156087         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
156089         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
156090         (free): Remove decl.
156092         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
156093         * lib/xgetcwd.c: Likewise.
156095         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
156096         (free): Remove decl.
156098         * lib/strchrnul.c (strchrnul): Define with a prototype.
156099         Fix bug: c_in was not converted to char before searching.
156101         The following changes are not K&R related:
156103         * lib/group-member.h: Include <sys/types.h>, so that this file is
156104         self-contained.
156105         * lib/makepath.h: Likewise.
156107         * lib/getusershell.c (readname, default_index, line_size, readname):
156108         Use size_t, not int, for sizes.
156109         (readname): If the size overflows, report an error instead of
156110         looping forever.
156112 2003-09-09  Paul Eggert  <eggert@twinsun.com>
156114         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
156115         libc.
156117 2003-09-09  Paul Eggert  <eggert@twinsun.com>
156119         * README: New section: portability guidelines.
156121 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
156123         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
156124         C89 spec.
156126 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
156128         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
156130 2003-09-08  Paul Eggert  <eggert@twinsun.com>
156132         Assume C89 or better; remove K&R cruft.
156133         A few of these changes were first proposed by Derek Robert Price
156134         in <http://mail.gnu.org/r/bug-gnulib/2003-07/msg00105.html>.
156136         * lib/addext.c: Include <string.h> unconditionally.
156137         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
156138         Don't declare getenv or malloc.
156140         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
156141         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
156142         (NULL): Remove.
156143         (find_stack_direction, alloca): Use prototypes.
156145         * lib/atexit.c (atexit): Define using a prototype.
156147         * lib/basename.c, dirname.c, stripslash.c:
156148         Include <string.h> unconditionally.
156150         * lib/bcopy.c: Include <stddef.h>.
156151         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
156153         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
156155         * lib/error.h (error, error_at_line, error_print_progname)
156156         [! (defined (__STDC__) && __STDC__)]: Remove decls.
156157         * lib/error.c: Include error.h first, to check interface.
156158         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
156159         (VA_START): Remove; all uses changeed to va_start.
156160         (exit, strerror): Remove decls.
156161         (error_print_progname): Prototype uncondionally.
156162         Don't include <errno.h>; no longer needed.
156163         (private_strerror): Remove.
156164         (error_tail): Always define.
156165         (error, error_at_line): Assume C89 or better; always use prototypes.
156166         * lib/fatal.c: Include "fatal.h" first, to test interface.
156167         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
156168         (VA_START): Remove; all uses changed to va_start.
156169         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
156170         this case.
156171         (exit): Remove decl.
156172         (fatal): Prototype unconditionally.  Assume va_start works.
156173         Abort at end, to pacify gcc.
156175         * lib/euidaccess.c (main): Define with a prototype.
156177         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
156179         * lib/exitfail.c: Include <stdlib.h> unconditionally.
156181         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
156182         prototypes.
156183         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
156184         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
156185         (getenv): Remove decl.
156186         (fnmatch): Define using a prototype.
156187         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
156188         (FCT): Define using a prototype.
156190         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
156192         * lib/gethostname.c: Include <stddef.h>.
156193         (gethostname): Define with prototype.  Length is size_t, not int.
156195 2003-09-08  Paul Eggert  <eggert@twinsun.com>
156197         Assume C89 or better; remove K&R cruft.
156198         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
156199         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
156200         string.h, getenv, malloc.
156201         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
156202         headers.
156203         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
156204         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
156205         do not check for strerror.
156206         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
156207         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
156208         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
156209         do not check for doprnt or vprintf.
156210         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
156211         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
156213 2003-09-08  Paul Eggert  <eggert@twinsun.com>
156215         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
156216         getversion.c should have been removed then, but was accidentally
156217         preserved.
156219         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
156220         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
156222 2003-09-08  Karl Berry  <karl@gnu.org>
156224         * config/config.sub, config.guess, srclistvars.sh: update from savannah
156225                 config, forget about prep.
156227         * config/depcomp, missing: update from automake.
156229 2003-09-07  Paul Eggert  <eggert@twinsun.com>
156231         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
156232         <http://mail.gnu.org/r/bug-gnulib/2003-09/msg00028.html>.
156234 2003-09-07  Paul Eggert  <eggert@twinsun.com>
156236         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
156237         copy_tm_result.  Bug reported by Simon Josefsson in
156238         <http://mail.gnu.org/r/bug-gnulib/2003-09/msg00028.html>.
156240 2003-09-06  Paul Eggert  <eggert@twinsun.com>
156242         * m4/time_r.m4: New file.
156243         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
156244         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
156245         is. Check for timegm declaration.
156246         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
156247         Do not check for gmtime_r.
156248         Replace mktime if __mktime_internal does not exist and if mktime
156249         hasn't been replaced already.
156251 2003-09-06  Paul Eggert  <eggert@twinsun.com>
156253         * lib/time_r.c, lib/time_r.h: New files.
156255         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
156256         __localtime_r.
156257         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
156258         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
156260         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
156261         __gmtime_r.
156262         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
156263         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
156264         Include <time_r.h>.
156266         * lib/timegm.c: Switch to glibc implementation, with the following
156267         changes:
156268         [defined HAVE_CONFIG_H]: Include <config.h>.
156269         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
156270         (__mktime_internal) [!defined _LIBC]: New decl.
156271         (__gmtime_r) [!defined _LIBC]: New macro and function.
156272         (timegm): Use a prototype, since gnulib assumes C89.
156273         Do not bother declaring tmp to be const, as it's not really usefu.
156274         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
156275         (timegm): Declare only if HAVE_DECL_TIMEGM.
156277 2003-09-06  Paul Eggert  <eggert@twinsun.com>
156279         * MODULES.html.sh (func_all_modules): Add time_r.
156280         * modules/time_r: New file.
156281         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
156282         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
156284 2003-09-03  Paul Eggert  <eggert@twinsun.com>
156286         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
156287         Bug reported by Lute Kamstra in
156288         <http://mail.gnu.org/r/bug-gnulib/2003-09/msg00003.html>.
156290         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
156291         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
156292         course with correspondingly smaller numbers for tomorrow and
156293         yesterday.  From Tadayoshi Funaba.  Originally installed into
156294         sh-utils on 1999-08-07, but the patch got lost (I guess during the
156295         coreutils merge?).
156297 2003-08-31  Simon Josefsson  <jas@extundo.com>
156299         * modules/timegm: New file.
156300         * MODULES.html.sh (func_all_modules): Add timegm.
156302 2003-08-31  Simon Josefsson  <jas@extundo.com>
156304         * m4/timegm.m4: New file.
156306 2003-08-31  Simon Josefsson  <jas@extundo.com>
156308         * lib/timegm.h: New file.
156309         * lib/timegm.c: New file.  Based on
156310         wget-1.8.2/src/http.c:mktime_from_utc.
156312 2003-08-31  Karl Berry  <karl@gnu.org>
156314         * lib/argp.h: update from libc.
156316 2003-08-28  Bruno Haible  <bruno@clisp.org>
156318         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
156319         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
156320         followed by '#define fnmatch fnmatch_posix' gives an error.
156322 2003-08-28  Bruno Haible  <bruno@clisp.org>
156324         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
156325         warning on QNX, which defines O_BINARY to 000000.
156327 2003-08-27  Jim Meyering  <jim@meyering.net>
156329         * m4/mkstemp.m4: Require that the system mkstemp be able to create
156330         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
156331         would fail after 32.  Reported by Danny Levinson.  Details here:
156332         http://mail.gnu.org/r/bug-coreutils/2003-08/msg00124.html
156334 2003-08-24  Bruno Haible  <bruno@clisp.org>
156336         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
156337         MSVC7 <stdio.h> is included later.
156339 2003-08-22  Simon Josefsson  <jas@extundo.com>
156341         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
156343 2003-08-20  Karl Berry  <karl@gnu.org>
156345         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
156347 2003-08-20  Bruno Haible  <bruno@clisp.org>
156349         * modules/progname: New file.
156350         * MODULES.html.sh (func_all_modules): Add progname.
156352 2003-08-20  Bruno Haible  <bruno@clisp.org>
156354         * lib/progname.h: New file, from GNU gettext.
156355         * lib/progname.c: New file, from GNU gettext.
156356         * lib/progreloc.c: New file, from GNU gettext.
156358 2003-08-19  Jim Meyering  <jim@meyering.net>
156360         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
156361         http://mail.gnu.org/r/bug-gnulib/2003-08/msg00155.html
156363 2003-08-19  Bruno Haible  <bruno@clisp.org>
156365         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
156366         more.
156368 2003-08-19  Bruno Haible  <bruno@clisp.org>
156370         * lib/xstrdup.c: Assume <string.h> exists.
156372 2003-08-18  Paul Eggert  <eggert@twinsun.com>
156374         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
156375         in makefile rules.
156377 2003-08-18  Jim Meyering  <jim@meyering.net>
156379         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
156380         * m4/lib-ld.m4: Likewise.
156382 2003-08-18  Jim Meyering  <jim@meyering.net>
156384         * lib/setenv.h: Indent nested cpp directive.
156385         * lib/vasnprintf.c: Remove trailing blanks.
156387 2003-08-17  Simon Josefsson  <jas@extundo.com>
156389         * modules/xstrndup: New file.
156390         * MODULES.html.sh (func_all_modules): Add xstrndup.
156392 2003-08-17  Simon Josefsson  <jas@extundo.com>
156394         * modules/argp: Fix autoconf macro name. Add more dependencies.
156396 2003-08-17  Simon Josefsson  <jas@extundo.com>
156398         * m4/xstrndup.m4: New file.
156400 2003-08-17  Simon Josefsson  <jas@extundo.com>
156402         * m4/argp.m4: New file.
156404 2003-08-17  Simon Josefsson  <jas@extundo.com>
156405             Bruno Haible  <bruno@clisp.org>
156407         * lib/xstrndup.h: New file.
156408         * lib/xstrndup.c: New file.
156410 2003-08-17  Bruno Haible  <bruno@clisp.org>
156412         * modules/strndup (Files, Include): Add lib/strndup.h.
156414 2003-08-17  Bruno Haible  <bruno@clisp.org>
156416         * modules/euidaccess (Files): Add lib/euidaccess.h.
156418 2003-08-17  Bruno Haible  <bruno@clisp.org>
156420         * lib/strndup.h: New file.
156422 2003-08-17  Bruno Haible  <bruno@clisp.org>
156424         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
156425         like AC_GNU_SOURCE.
156426         * modules/extensions (configure.ac): Comment out the invocation of
156427         gl_USE_SYSTEM_EXTENSIONS.
156429 2003-08-16  Paul Eggert  <eggert@twinsun.com>
156431         Merges from coreutils, etc.
156432         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
156433         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
156434         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
156435         fixing a typo.
156436         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
156437         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
156439 2003-08-16  Paul Eggert  <eggert@twinsun.com>
156441         Document merge from coreutils.
156442         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
156443         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
156444         * modules/utime: Add m4/utimes-null.m4.
156446 2003-08-16  Paul Eggert  <eggert@twinsun.com>
156448         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
156449         space, undoing this 2003-08-12 change:
156450         <http://mail.gnu.org/r/bug-gnulib/2003-08/msg00080.html>
156452 2003-08-16  Paul Eggert  <eggert@twinsun.com>
156454         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
156455         strtoul.c from libc, undoing this 2003-08-12 change:
156456         <http://mail.gnu.org/r/bug-gnulib/2003-08/msg00080.html>
156458 2003-08-16  Jim Meyering  <jim@meyering.net>
156460         Merges from coreutils.
156461         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
156462         prefix.  Adjust cache variables similarly.  Create 500 rather than
156463         just 300 files, to exercise bug on Darwin6.5, too.
156464         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
156465         $missing_dir.
156466         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
156467         AM_SYS_POSIX_TERMIOS.
156468         Reported by mkc@mathdogs.com.
156469         Also change use of $am_cv_sys_posix_termios
156470         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
156471         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
156472         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
156473         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
156474         in /proc/mounts until it finds one with matching device number.  This
156475         is unnecessary when the FILE argument *is* a mount point.  No stat call
156476         is necessary in that case.  So, disable the statvfs-testing code on
156477         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
156478         as RedHat bug# 84846.
156479         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
156480         to 1MB, so as not to render systems with no stack size limit (e.g.,
156481         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
156482         Include <unistd.h>.  On some systems,
156483         it is required for the definition of _SC_PAGESIZE.
156485 2003-08-16  Jim Meyering  <jim@meyering.net>
156487         Merge from coreutils.
156488         * lib/xstrtoimax.c: #else #if -> #elif.
156489         * lib/xstrtoumax.c: Likewise.
156491 2003-08-16  Jim Meyering  <jim@meyering.net>
156493         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
156494         * m4/utimes.m4: Removed.
156495         * m4/utimes-null.m4: Renamed from utimes.m4.
156497         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
156498         to 1MB, so as not to render systems with no stack size limit (e.g.,
156499         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
156500         Include <unistd.h>.  On some systems,
156501         it is required for the definition of _SC_PAGESIZE.
156503 2003-08-16  Jim Meyering  <jim@meyering.net>
156504         and Paul Eggert  <eggert@cs.ucla.edu>
156506         Merges from coreutils, etc.
156508         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
156509         using the latest version from cvs.  This avoids problems with #line
156510         directives using a vendor (Sun) compiler.
156511         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
156512         Don't set GETGROUPS_LIB here; now it's
156513         done via getgroups.m4's wrapper function.
156514         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
156515         rather than just in sh-util/configure.in, so that the
156516         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
156517         same.
156518         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
156519         AC_FUNC_GETLOADAVG where to find getloadavg.c.
156520         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
156521         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
156522         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
156523         Remove code that is now done by the newly-required macros.
156524         Append $(EXEEXT) to DF_PROG.
156525         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
156526         Do not invoke or require the following here,
156527         since prereq.m4 or some gnulib .m4 now does this for us:
156528         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
156529         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
156530         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
156531         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
156532         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
156533         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
156534         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
156535         AC_FUNC_OBSTACK.
156536         Do not replace the following functions, as this is now the job
156537         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
156538         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
156539         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
156540         atexit getpass, strdup, getpagesize.
156541         Replace 'raise'.
156542         Do not check for the following functions, as this is now the job
156543         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
156544         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
156545         setregid.
156546         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
156547         Check for sys/sysctl.h.
156548         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
156549         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
156550         of checking for ssize_t ourselves.
156552         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
156553         Require every macro that gnulib/modules/* suggests for us.
156554         (jm_PREREQ_ADDEXT): New macro.
156555         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
156556         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
156558         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
156559         (gl_PHYSMEM): Use it.
156560         Also check for `table' function.
156561         Check for new headers and functions.
156562         Add check for sys/sysmp.h.
156563         With suggestions from Kaveh Ghazi.
156564         Ignore headers that are present but cannot be compiled.  This
156565         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
156566         C 5.4.
156568 2003-08-15  Paul Eggert  <eggert@twinsun.com>
156570         Document merge from coreutils.
156571         * modules/userspec: Depend on posixver.
156572         * modules/strftime: Depend on tzset.
156574 2003-08-15  Paul Eggert  <eggert@twinsun.com>
156576         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
156577         rather than tab, after '#' in shell-script copyright notices.
156578         Suggested by Bruno Haible.
156580 2003-08-15  Paul Eggert  <eggert@twinsun.com>
156582         * config/srclist-update: Use three spaces, rather than tab, after '#'
156583         in shell-script copyright notices.  Suggested by Bruno Haible.
156584         Remove unnecessary parenthesization in regular expression.
156586 2003-08-15  Jim Meyering  <jim@meyering.net>
156588         Merge from coreutils.
156589         * lib/xgethostname.c: Include <stdlib.h>.
156590         (xghostname): Don't exit for anything other than memory-related
156591         failure; just return NULL.
156592         * lib/userspec.c: Include "posixver.h".
156593         (parse_user_spec): Accept `.' as a separator only
156594         in pre-POSIX-200112 mode.
156595         * lib/strtoimax.c: Use #elif rather than #else #if.
156596         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
156597         Remove function, now that we can rely on a working tzset function.
156598         [!_LIBC]: Ensure that the required autoconf test has been run.
156599         [!defined _NL_CURRENT && HAVE_STRFTIME]:
156600         Use underlying_strftime for %r.
156601         * lib/sha.c: Merge in some clean-up and optimization changes from
156602         glibc.
156603         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
156604         Ensure that it is a multiple of 64.
156605         Rearrange loop exit tests so as to avoid performing an
156606         additional fread after encountering an error or EOF.
156607         * lib/realloc.c: Update copyright date.
156609 2003-08-15  Jim Meyering  <jim@meyering.net>
156610         and Paul Eggert  <eggert@twinsun.com>
156612         Merge from coreutils.
156613         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
156614         member but strut utmpx does not.  Needed for AIX 4.3.3.
156615         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
156617 2003-08-15  Jim Meyering  <jim@meyering.net>
156618         and Paul Eggert  <eggert@cs.ucla.edu>
156620         Merges from coreutils, etc.
156621         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
156622         Require gl_FUNC_TZSET_CLOBBER.
156623         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
156624         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
156625         members.
156627 2003-08-14  Paul Eggert  <eggert@twinsun.com>
156629         Help the merge from coreutils.
156630         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
156631         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
156632         * m4/tzset.m4: Use it too.
156634 2003-08-14  Paul Eggert  <eggert@twinsun.com>
156636         * modules/tzset: New file.
156638 2003-08-14  Jim Meyering  <jim@meyering.net>
156640         Merges from coreutils.
156641         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
156642         variable names, rather than @FNMATCH_H@.
156643         * modules/alloca: Likewise for $(ALLOCA_H).
156645         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
156646         the three copies of the literal target, `fnmatch.h'.
156647         * modules/alloca (alloca.h): Likewise.
156649 2003-08-14  Jim Meyering  <jim@meyering.net>
156651         Merge from coreutils.
156652         * m4/tzset.m4: New file.
156653         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
156654         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
156655         otherwise, AIX 5.1 systems would end up using the latter.
156656         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
156657         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
156658         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
156659         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
156661 2003-08-14  Jim Meyering  <jim@meyering.net>
156663         Merge from coreutils.
156664         * lib/obstack.h: Whitespace changes.
156665         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
156666         and xcalloc return values.
156667         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
156668         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
156669         hang on OSF/1 5.1 for DIR on both local and remote file systems.
156670         Reported by (and fix confirmed by) Nelson H. F. Beebe.
156671         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
156672         error from mntctl.
156673         Use mntctl's return value to drive the entry-processing loop, since
156674         we can't rely on the value of the vmt_length member in the last
156675         entry.  On some systems doing so could result in exhausting
156676         virtual memory.  Based in part on a patch from Mike Jetzer.
156678 2003-08-14  Jim Meyering  <jim@meyering.net>
156679         and Paul Eggert  <eggert@twinsun.com>
156681         Merges from coreutils, plus other fixes.
156682         * lib/physmem.c: Merge in portability changes from gcc/libiberty
156683         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
156684         for credits and details.  Thanks to Kaveh Ghazi for helping
156685         to keep these files in sync.
156686         (ARRAY_SIZE): Define it.
156687         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
156688         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
156689         (memcasecmp): Don't assume size_t fits in unsigned int.
156690         Remove casts and duplicate code.
156691         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
156692         (memcpy): Remove definition.
156693         Merge in some clean-up and optimization changes from glibc.
156694         [BLOCKSIZE]: Move definition to top of file.
156695         Ensure that it is a multiple of 64.
156696         Rearrange loop exit tests so as to avoid performing an
156697         additional fread after encountering an error or EOF.
156698         * lib/md5.h (md5_uintptr): Define.
156699         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
156700         return to the initial working directory.  Preserve errno
156701         for caller.
156702         * lib/idcache.c: Include "xalloc.h".
156703         (xmalloc, xrealloc): Remove decls.
156704         (getuser): Remove casts no longer required in C89.
156705         * lib/human.c: Include stdio.h, for sprintf.
156706         * lib/group-member.c: Include "xalloc.h".
156707         (xmalloc, xrealloc): Remove decls.
156708         (get_group_info): Remove casts no longer required in C89.
156709         * lib/getusershell.c (readname): Remove casts no longer required in
156710         C89.
156711         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
156712         * lib/getline.c: Whitespace fix, from coreutils.
156714 2003-08-13  Paul Eggert  <eggert@twinsun.com>
156716         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
156717         Check for isascii.
156719         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
156720         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
156721         Undo previous (whitespace-only) change.
156723 2003-08-13  Paul Eggert  <eggert@twinsun.com>
156725         * lib/exclude.c: Include <ctype.h>
156726         (IN_CTYPE_DOMAIN): New macro.
156727         (is_space): New fn.
156728         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
156729         and empty lines.
156731         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
156732         Undo previous (whitespace-only) change.
156734 2003-08-13  Paul Eggert  <eggert@twinsun.com>
156736         * config/srclist-update: Change update back to the old behavior,
156737         leaving whitespace alone.  Use one 'sed' command rather than a
156738         pipeline.
156739         (fixlicense): Now a variable, not a function.
156740         (remove_trailing_blanks): Remove.
156741         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
156742         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
156743         Undo previous (whitespace-only) change.
156745 2003-08-12  Paul Eggert  <eggert@twinsun.com>
156747         Merge from coreutils.
156748         * modules/euidaccess: Add lib_SOURCES, include for new
156749         file euidaccess.h
156751 2003-08-12  Paul Eggert  <eggert@twinsun.com>
156753         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
156754         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
156755         Normalize leading white space and remove trailing white space.
156757         Merge from coreutils
156758         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
156760         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
156761         0.12.1.  These files are now being upgraded automatically by
156762         ../config/srclist-update.
156764 2003-08-12  Paul Eggert  <eggert@twinsun.com>
156766         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
156767         Normalize leading white space and remove trailing white space.
156768         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
156769         notice, as per ../config/srclist-update.
156771         Merge from coreutils.
156772         * lib/euidaccess.h: New file.
156773         * lib/euidaccess.c: Include it.
156774         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
156775         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
156776         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
156778 2003-08-12  Paul Eggert  <eggert@twinsun.com>
156780         * config/srclist-update: Add copyright notice.
156781         (remove_id_lines, remove_trailing_blanks): New constants.
156782         (fixfile): Use them to normalize spacing a bit in copied files.
156783         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
156784         Normalize leading white space and remove trailing white space.
156786         * config/texinfo.tex: Sync with texinfo.
156788         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
156789         strtoul.c from libc, to merge coreutils whitespace changes.
156791         * config/srclist.txt: Get the following m4 files from gettext:
156792         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
156793         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
156794         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
156795         wint_t.m4.
156797 2003-08-12  Karl Berry  <karl@gnu.org>
156799         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
156800         been made.
156802 2003-08-11  Paul Eggert  <eggert@twinsun.com>
156804         * modules/gnu-source, m4/gnu-source.m4:
156805         Remove; we're assuming Autoconf 2.54 or later now.
156806         Suggested by Bruno Haible.
156807         * MODULES.html.sh (func_all_modules): Remove gnu-source.
156809 2003-08-11  Bruno Haible  <bruno@clisp.org>
156811         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
156813 2003-08-11  Bruno Haible  <bruno@clisp.org>
156815         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
156816         (vasnprintf): Use it instead of wcslen.
156818 2003-08-11  Bruno Haible  <bruno@clisp.org>
156820         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
156821         value to ensure that _Bool promotes to int. Use #define for _Bool when
156822         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
156824 2003-08-10  Karl Berry  <karl@gnu.org>
156826         * lib/regex.h: update from libc (whitespace fix).
156828 2003-08-09  Paul Eggert  <eggert@twinsun.com>
156830         Merge some files from coreutils.  These changes were
156831         originally made by Jim Meyering.
156832         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
156833         many older Unixes require this.
156834         * lib/alloca.c (alloca): Remove cast to argument of free;
156835         no longer needed in C89.
156836         * lib/alloca_.h, regex.h: Fix white space to match
156837         what GNU indent does.
156839 2003-08-09  Paul Eggert  <eggert@twinsun.com>
156841         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
156842         apparently Emacs's Unicode mode got confused before my 2003-08-05
156843         checkin.
156845 2003-08-08  Paul Eggert  <eggert@twinsun.com>
156847         * m4/extensions.m4: New file.
156848         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
156849         Require gl_USE_SYSTEM_EXTENSIONS.
156850         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
156851         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
156853 2003-08-08  Paul Eggert  <eggert@twinsun.com>
156855         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
156856         * modules/extensions, modules/gnu-source: New files.
156857         * modules/timespec, modules/unlocked-io: Depend on extensions.
156859 2003-08-07  Paul Eggert  <eggert@twinsun.com>
156861         * modules/restrict: New file.
156862         * MODULES.html.sh (func_all_modules): Add restrict.
156863         * modules/regex: Depend on restrict.
156865 2003-08-07  Paul Eggert  <eggert@twinsun.com>
156867         * m4/restrict.m4: New file.
156868         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
156870 2003-08-07  Bruno Haible  <bruno@clisp.org>
156872         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
156873         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
156875 2003-08-07  Bruno Haible  <bruno@clisp.org>
156877         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
156878         makes the module 'getndelim2' compatible with the module 'getline'.
156880 2003-08-05  Paul Eggert  <eggert@twinsun.com>
156882         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
156883         byte with "\201" to avoid glitches when editing that source file
156884         with multi-gnome-terminal.
156886 2003-08-05  Paul Eggert  <eggert@twinsun.com>
156888         * lib/bumpalloc.h: Remove.
156890 2003-08-05  Paul Eggert  <eggert@twinsun.com>
156892         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
156893         * modules/bumpalloc: Remove.
156895 2003-08-04  Paul Eggert  <eggert@twinsun.com>
156897         * lib/getloadavg.c: Change copyright notice and spacing to conform to
156898         GNU coding style.
156900         Merge from coreutils.
156901         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
156902         1. From glibc.
156903         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
156904         from Karl Berry, implemented by Jim Meyering.
156905         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
156906         from Dmitry V. Levin.
156907         Remove anachronistic cast of xrealloc.
156908         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
156909         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
156910         type. Otherwise, it wouldn't compile with at least /bin/cc on
156911         ymp-cray-unicos9.0.2.X.
156912         Combine two mostly-identical uses of alloca into one.
156913         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
156915 2003-08-04  Dave Love  <d.love@dl.ac.uk>
156917         [From Emacs.]
156919         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
156920         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
156921         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
156922         obsolete NLIST_NAME_UNION.
156923         [__GNU__]: Undef BSD and FSCALE.
156924         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
156926 2003-08-03  Paul Eggert  <eggert@twinsun.com>
156928         * lib/stdbool_.h (_Bool): Make it signed char, instead of
156929         an enum type, so that it's guaranteed to promote to int.  See:
156930         <http://mail.gnu.org/r/bug-gnulib/2003-07/msg00124.html>
156932 2003-08-03  Karl Berry  <karl@gnu.org>
156934         * config/depcomp: update from automake.
156936 2003-07-31  Paul Eggert  <eggert@twinsun.com>
156938         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
156939         (strerror): Don't assume that a printable int fits in 14 bytes.
156941 2003-07-31  Bruno Haible  <bruno@clisp.org>
156943         * modules/getpass-gnu: New file.
156944         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
156946 2003-07-31  Bruno Haible  <bruno@clisp.org>
156948         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
156950 2003-07-24  Karl Berry  <karl@gnu.org>
156952         * config/missing: update from automake.
156954 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
156955             Bruno Haible  <bruno@clisp.org>
156957         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
156958         * lib/getline.c (getline, getdelim): Likewise.
156959         Remove _GNU_SOURCE define; now it's defined in config.h through
156960         m4/getline.m4.
156962 2003-07-23  Karl Berry  <karl@gnu.org>
156964         * config/config.sub: update from prep.
156966 2003-07-22  Paul Eggert  <eggert@twinsun.com>
156968         * modules/xalloc (Depends-on): Add exitfail.
156969         * modules/xmemcoll: Likewise.
156971 2003-07-22  Paul Eggert  <eggert@twinsun.com>
156973         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
156974         over-parenthesization in macros.
156976         Sync with coreutils.
156978         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
156979         required by C99.
156981         Use `exit_failure' for xalloc and xmemcoll instead of their own
156982         private exit-failure variables.
156983         * lib/xalloc.h (xalloc_exit_failure): Remove.
156984         * lib/xmalloc.c: Likewise.  Include exitfail.h.
156985         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
156986         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
156987         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
156988         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
156990 2003-07-20  Jim Meyering  <jim@meyering.net>
156992         * modules/closeout (Depends-on): Add exitfail.
156993         Suggestion from Bruno Haible.
156995 2003-07-19  Karl Berry  <karl@gnu.org>
156997         * config/config.sub: update from prep.
156999 2003-07-18  Paul Eggert  <eggert@twinsun.com>
157001         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
157002         Remove.
157003         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
157004         to test that it can stand by itself.  Include "exitfail.h".
157005         Clients should set exit_failure instead.
157006         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
157008 2003-07-18  Bruno Haible  <bruno@clisp.org>
157010         * modules/getndelim2: New file.
157011         * modules/getline: Share files with module getndelim2.
157012         * modules/getnline: Depend on getndelim2 instead of sharing files with
157013         it. Add getnline.c to lib_SOURCES.
157014         * MODULES.html.sh (func_all_modules): Add getndelim2.
157016 2003-07-18  Bruno Haible  <bruno@clisp.org>
157018         * m4/getndelim2.m4: New file.
157019         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
157020         invoke gl_PREREQ_GETNDELIM2.
157021         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
157022         gl_PREREQ_GETNDELIM2.
157023         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
157024         gl_GETNDELIM2.
157026 2003-07-18  Bruno Haible  <bruno@clisp.org>
157028         * lib/getndelim2.h: New file.
157029         * lib/getndelim2.c: Make into a module of its own. Include config.h,
157030         getndelim2.h.
157031         (getndelim2): Make non-static. Change return type to ssize_t.
157032         * lib/getline.h: Change argument names.
157033         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
157034         * lib/getnline.c: Include getndelim2.h.
157036 2003-07-18  Andreas Schwab  <schwab@suse.de>
157038         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
157040 2003-07-17  Karl Berry  <karl@gnu.org>
157042         * config/config.sub: update from prep.
157044 2003-07-17  Bruno Haible  <bruno@clisp.org>
157046         * modules/getnline: New file.
157047         * modules/getline: Add lib/getndelim2.c to source file list.
157048         * MODULES.html.sh (func_all_modules): Add getnline.
157050 2003-07-17  Bruno Haible  <bruno@clisp.org>
157052         * m4/getnline.m4: New file.
157054 2003-07-17  Bruno Haible  <bruno@clisp.org>
157056         * m4/Makefile.am.in: Remove file.
157057         * m4/Makefile.am: Remove file.
157058         * m4/Makefile.in: Remove file.
157060 2003-07-17  Bruno Haible  <bruno@clisp.org>
157062         * lib/getnline.h: New file.
157063         * lib/getnline.c: New file.
157064         * lib/getndelim2.c: New file, extracted from getline.c.
157065         (getndelim2): Renamed from getdelim2, with added nmax argument.
157066         * lib/getline.c: Include getndelim2.c.
157067         (getdelim2): Moved out to getndelim2.c.
157068         (getline, getdelim): Update.
157070 2003-07-17  Bruno Haible  <bruno@clisp.org>
157072         * lib/Makefile.am: Remove file.
157073         * lib/Makefile.in: Remove file.
157075 2003-07-17  Bruno Haible  <bruno@clisp.org>
157077         * configure.in: Remove file.
157078         * Makefile.in: Remove file.
157080 2003-07-17  Bruno Haible  <bruno@clisp.org>
157082         * MODULES.html.sh: Put the </BODY> right before </HTML>.
157084 2003-07-16  Karl Berry  <karl@gnu.org>
157086         * config/srclist-update: was running fixlicense twice, which caused
157087                 texinfo.tex to be nullified for some reason.  Simplify,
157088                 $gplsrc is no longer needed as far as I can see?
157090 2003-07-16  Jim Meyering  <jim@meyering.net>
157092         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
157094 2003-07-15  Paul Eggert  <eggert@twinsun.com>
157096         * config/srclist.txt: Get the following files from gettext-runtime/intl
157097         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
157098         ref-del.sin.  From Bruno Haible.
157099         * config/srclist-update (fixfile): Change grep pattern again, since the
157100         previous fix didn't work (there was another trailing $).  Use
157101         '[$]' to escape the $s.
157103 2003-07-15  Karl Berry  <karl@gnu.org>
157105         * lib/vasnprintf.c: update from gettext.
157107 2003-07-15  Karl Berry  <karl@gnu.org>
157109         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
157110         gets expanded when surrounded by '$'.
157112 2003-07-15  Jim Meyering  <jim@meyering.net>
157114         * modules/save-cwd: Don't depend on error.  From Derek Price.
157116 2003-07-15  Jim Meyering  <jim@meyering.net>
157118         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
157120 2003-07-14  Simon Josefsson  <jas@extundo.com>
157122         * modules/mempcpy: New file.
157123         * MODULES.html.sh (func_all_modules): Add mempcpy.
157125 2003-07-14  Simon Josefsson  <jas@extundo.com>
157127         * m4/mempcpy.m4: New file.
157129 2003-07-14  Simon Josefsson  <jas@extundo.com>
157131         * lib/mempcpy.h: New file.
157132         * lib/mempcpy.c: New file.
157134 2003-07-14  Paul Eggert  <eggert@twinsun.com>
157136         * modules/getdate, modules/posixtm: Depend on mktime.
157138 2003-07-14  Paul Eggert  <eggert@twinsun.com>
157140         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
157141         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
157142         unicodeio.c, unicodeio.h, unlocked-io.h:
157143         Switch from LGPL to GPL.
157145 2003-07-14  Paul Eggert  <eggert@twinsun.com>
157147         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
157148         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
157149         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
157150         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
157151         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
157152         updated automatically by ../config/srclist-update.  This changes
157153         their license from LPGL to GPL.
157155 2003-07-14  Paul Eggert  <eggert@twinsun.com>
157157         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
157158         assumed to refer to the root of the most recent stable gettext version.
157159         * config/srclistvars.sh: Add defaults for eggert.
157160         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
157161         Match "This program" as well as "The program".  This is needed
157162         for gettext.
157164 2003-07-14  Jim Meyering  <jim@meyering.net>
157166         Don't emit diagnostics.  Let callers do that.
157167         * lib/save-cwd.c: Don't include "error.h".
157168         (save_cwd): Don't call error.  Ensure that errno is valid
157169         when returning nonzero.
157171         * lib/save-cwd.h (restore_cwd): Update prototype.
157172         * lib/save-cwd.c (restore_cwd): Remove two parameters.
157173         Simplify.  Don't call error upon failure.  Let callers do that.
157174         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
157175         when auditing is enabled.  But don't bother updating the #if.
157177 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
157179         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
157180         it breaks C++ compilation.
157181         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
157183 2003-07-10  Simon Josefsson  <jas@extundo.com>
157185         * modules/strchrnul (Makefile.am): Add strchrnul.h.
157187 2003-07-10  Jim Meyering  <jim@meyering.net>
157189         * m4/clock_time.m4: Remove trailing blank.
157190         * m4/intmax_t.m4: Likewise.
157192 2003-07-10  Jim Meyering  <jim@meyering.net>
157194         * lib/vasnprintf.c: Remove trailing blanks.
157195         Make cpp indentation consistent.
157197 2003-07-09  Paul Eggert  <eggert@twinsun.com>
157199         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
157200         posixver.c, strftime.c, strnlen.c, strverscmp.c:
157201         Switch from LGPL to GPL.
157203 2003-07-09  Paul Eggert  <eggert@twinsun.com>
157205         * config/srclist.txt: Sort sublists.  Add
157206         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
157207         that differ from gnulib for one reason or another; we'd like this list
157208         to be smaller but for now let's document what we have.
157210 2003-07-08  Paul Eggert  <eggert@twinsun.com>
157212         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
157213         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
157214         and sweeter "eval x=$x".
157215         * config/srclist.txt: Get lib/argp* from glibc.
157217 2003-07-07  Paul Eggert  <eggert@twinsun.com>
157219         * lib/mktime.c: Fix some boundary cases and remove need for floating
157220         point.
157222         Issue a compile-time diagnostic if time_t is floating point, or if
157223         two's complement arithmetic is not in effect, or if arithmetic
157224         right shift does not propagate the sign.  These assumptions were
157225         all in the original code but they weren't checked.
157227         (TIME_T_MIDPOINT, verify): New macros.
157228         (__isleap): Remove; it has integer overflow problems.
157229         (leapyear): New function, without those problems.
157230         (ydhms_tm_diff): Remove; splitting into two parts.
157231         (ydhms_diff): New function, containing the arithmetic part of
157232         the old ydhms_tm_diff function.  Issue a compile-time
157233         diagnostic if we are not using C99 integer division.
157234         Avoid casts when possible.
157235         (guess_time_tm): New function, containing the checking part of
157236         the old ydhms_tm_diff function.  Return the new value, rather than
157237         the difference between it and the old.  Accept a new argument T
157238         so that *T specifies the old value.  Check for overflow in the result.
157240         (__mktime_internal): Use a time_t offset, not a long int offset.
157241         This undoes the 2003-06-04 change, which is no longer needed now
157242         that we have better overflow checking.
157243         (localtime_offset): Likewise.
157245         (__mktime_internal): Avoid harmful overflow on hosts where time_t
157246         and long are 64-bit but int is only 32-bit.
157247         (ydhms_diff): Use long int to store year1 and yday1.
157248         Issue a compile-time diagnostic if long int is not wide enough.
157250         (__mktime_internal): Use long int to store adjusted year and yday.
157251         Use plain C rather than preprocessor commands, if that doesn't
157252         affect efficiency.
157253         Check for overflow (and try to repair) after each probe
157254         rather than checking only at the very end.  This avoids some bugs
157255         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
157256         does not equal GMT offset at maximum time).
157257         Use integer to check for overflow rather than floating point; this
157258         is more portable to non-IEEE hosts, and is a tad faster.
157259         When we detect that we are oscillating between two values,
157260         don't check whether tm_isdst has the requested value, since
157261         we already know the answer.  When tm_isdst has the wrong value,
157262         use a different heuristic to find the right one, based on the
157263         extreme values actually observed in practice in tz2003a,
157264         rather than the (overly optimistic) "previous 3 calendar quarters".
157266         (not_equal_tm, print_tm, check_result): Use "const T" rather than
157267         "T const" to accommodate glibc style.
157268         (check_result): Use less-confusing report format.  "long" -> "long int.
157269         (main): Likewise.
157270         Don't loop if the iteration overflows time_t.
157271         Allow a negative step in the iteration.
157273 2003-07-06  Karl Berry  <karl@gnu.org>
157275         * config/depcomp: update from automake.
157276         * config/config.sub: update from prep.
157278 2003-07-03  Karl Berry  <karl@gnu.org>
157280         * config/config.guess: update from prep.
157282 2003-07-01  Paul Eggert  <eggert@twinsun.com>
157284         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
157285         xreadlink.c now includes it unconditionally.
157287 2003-07-01  Paul Eggert  <eggert@twinsun.com>
157289         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
157290         having it depend on HAVE_SYS_TYPES_H.
157292 2003-07-01  Bruno Haible  <bruno@clisp.org>
157294         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
157295         <sys/types.h> should be sufficient.
157296         Reported by Paul Eggert.
157298 2003-06-26  Karl Berry  <karl@gnu.org>
157300         * config/depcomp: update from automake.
157302 2003-06-26  Bruno Haible  <bruno@clisp.org>
157304         * modules/human: Depend on module stdbool.
157306 2003-06-25  Bruno Haible  <bruno@clisp.org>
157308         * modules/readlink: New file.
157309         * modules/xreadlink: Depend on it.
157310         * MODULES.html.sh (func_all_modules): Add readlink.
157312 2003-06-25  Bruno Haible  <bruno@clisp.org>
157314         * m4/readlink.m4: New file.
157316 2003-06-25  Bruno Haible  <bruno@clisp.org>
157318         * lib/readlink.c: New file.
157320 2003-06-22  Karl Berry  <karl@gnu.org>
157322         * config/srclist.txt: update mkinstalldirs from automake.
157323         * config/mkinstalldirs: update.
157325 2003-06-22  Bruno Haible  <bruno@clisp.org>
157327         Portability to mingw32.
157328         * m4/ssize_t.m4: New file, from GNU gettext.
157329         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
157330         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
157332 2003-06-22  Bruno Haible  <bruno@clisp.org>
157334         * modules/safe-read: Add m4/ssize_t.m4.
157335         * modules/xreadlink: Add m4/ssize_t.m4.
157337 2003-06-20  Bruno Haible  <bruno@clisp.org>
157339         Assume C89, so PARAMS isn't needed.
157340         * lib/unicodeio.h (PARAMS): Remove.
157341         * lib/unicodeio.c: Don't use PARAMS.
157343 2003-06-18  Karl Berry  <karl@gnu.org>
157345         * config/config.{guess,sub}: update from prep.
157347 2003-06-18  Jim Meyering  <jim@meyering.net>
157349         Merge changes from coreutils.
157350         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
157351         Remove explicit declarations of xmalloc and realloc.
157352         Include xalloc.h.
157353         (read_utmp): Remove anachronistic cast of xmalloc.
157355 2003-06-17  Paul Eggert  <eggert@twinsun.com>
157357         Assume C89, so PARAMS isn't needed.
157358         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
157359         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
157360         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
157361         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
157362         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
157363         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
157364         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
157365         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
157366         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
157367         lib/xstrtod.h, lib/xstrtol.h: Likewise.
157368         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
157369         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
157370         no longer needed. Anyway, config.h should always be included before any
157371         other file.
157373 2003-06-11  Simon Josefsson  <jas@extundo.com>
157375         * modules/sysexits: New file.
157376         * MODULES.html.sh (func_all_modules): Add sysexits.
157378 2003-06-11  Simon Josefsson  <jas@extundo.com>
157380         * lib/sysexit_.h: New file.
157382 2003-06-11  Derek Price  <derek@ximbiot.com>
157384         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
157385         necessary.
157387 2003-06-11  Bruno Haible  <bruno@clisp.org>
157389         * m4/sysexits.m4: New file.
157391 2003-06-10  Simon Josefsson  <jas@extundo.com>
157393         * lib/argp.h: New file, from glibc.
157394         * lib/argp-ba.c: New file, from glibc.
157395         * lib/argp-eexst.c: New file, from glibc.
157396         * lib/argp-fmtstream.c: New file, from glibc.
157397         * lib/argp-fmtstream.h: New file, from glibc.
157398         * lib/argp-fs-xinl.c: New file, from glibc.
157399         * lib/argp-help.c: New file, from glibc.
157400         * lib/argp-namefrob.h: New file, from glibc.
157401         * lib/argp-parse.c: New file, from glibc.
157402         * lib/argp-pv.c: New file, from glibc.
157403         * lib/argp-pvh.c: New file, from glibc.
157404         * lib/argp-xinl.c: New file, from glibc.
157406 2003-06-10  Simon Josefsson  <jas@extundo.com>
157408         * modules/strchrnul: New file.
157410 2003-06-10  Simon Josefsson  <jas@extundo.com>
157412         * modules/argp: New file.
157414 2003-06-10  Simon Josefsson  <jas@extundo.com>
157416         * m4/strchrnul.m4: New file.
157418 2003-06-10  Simon Josefsson  <jas@extundo.com>
157420         * lib/strchrnul.h: New file.
157421         * lib/strchrnul.c: New file.
157423 2003-06-10  Bruno Haible  <bruno@clisp.org>
157425         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
157427 2003-06-07  Karl Berry  <karl@gnu.org>
157429         * config/config.{guess,sub}: update from prep.
157431 2003-06-07  Jim Meyering  <jim@meyering.net>
157433         * modules/strtod: Use $(...) notation, not @...@ for
157434         AC_REPLACE'd variables.
157435         * modules/localcharset: Likewise.
157437 2003-06-07  Jim Meyering  <jim@meyering.net>
157439         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
157440         in place of my name in the copyright comment.
157441         Remove definition and uses of __P.
157443         From coreutils.
157444         * lib/stat.c: Don't declare xmalloc explicitly.
157445         Instead, include "xalloc.h".
157446         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
157447         xrealloc, and xcalloc return values.
157448         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
157449         Improve comment.
157450         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
157452 2003-06-07  Bruno Haible  <bruno@clisp.org>
157454         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
157455         avoid AC_CONFIG_LINKS.
157456         * modules/fnmatch (Makefile.am): Use explicit creation rule for
157457         fnmatch.h, to avoid AC_CONFIG_LINKS.
157458         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
157460 2003-06-07  Bruno Haible  <bruno@clisp.org>
157462         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
157463         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
157464         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
157465         directory.
157466         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
157467         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
157468         directory.
157470 2003-06-06  Jim Meyering  <jim@meyering.net>
157472         Merge from coreutils.
157473         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
157474         Consolidate declarations and initializations of *_base* locals.
157476         Merge from coreutils.
157477         This avoids a core dump on systems without GNU putenv,
157478         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
157479         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
157480         (unsetenv): New static function, from GNU libc.
157481         (rpl_putenv): Use it.
157483         * lib/modechange.c: Remove trailing blanks.
157485         Merge from coreutils.
157486         * lib/fsusage.c: Remove declaration of statfs.
157487         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
157489         * lib/posixtm.c: Include <stdbool.h> unconditionally.
157491 2003-06-06  Jim Meyering  <jim@meyering.net>
157493         * lib/stdbool_.h: Renamed from stdbool.h.in.
157495 2003-06-06  Jim Meyering  <jim@meyering.net>
157496             Bruno Haible  <bruno@clisp.org>
157498         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
157499         Adjust Makefile.am snippet not to redirect directly to target.
157500         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
157502 2003-06-05  Paul Eggert  <eggert@twinsun.com>
157504         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
157505         mismatch, look in future quarters as well as past.  This fixes a
157506         bug when processing fall-backwards gaps immediately after a long
157507         period of daylight-saving time.
157509         * lib/mktime.c: Assume freestanding C89 or better.
157510         (HAVE_LIMITS_H): Remove.  Assume it's 1.
157511         (__P): Remove; not used.
157512         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
157513         (mktime, not_equal_tm, print_tm, check_result,
157514         main): Use prototypes.  Use const * where appropriate.
157515         (main): Fix typo in testing code that uncovered by above changes.
157516         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
157518 2003-06-04  Paul Eggert  <eggert@twinsun.com>
157520         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
157521         locale.h, localeconv.  This merges changes from coreutils.
157523         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
157524         It can be removed after the next Autoconf is released.
157525         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
157526         needed.
157528 2003-06-04  Paul Eggert  <eggert@twinsun.com>
157530         * lib/mktime.c: Fix Debian bug 177940
157531         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
157532         (localtime_offset): Now long int, not time_t, because we want it
157533         to be guaranteed to be signed.  All uses changed.
157534         (__mktime_internal): If overflow would occur when adding offset,
157535         don't add it.
157537         Merge 'human' changes from coreutils.  Rewrite to support
157538         locale-specific notations like thousands separators.
157539         * lib/human.c: Simplify authorship notice.
157540         Include human.h immediately after config.h.
157541         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
157542         <limits.h>: Do not include, since human.h does.
157543         (SIZE_MAX, UINTMAX_MAX): New macros.
157544         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
157545         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
157546         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
157547         (power_letter): Renamed from suffixes.
157548         (generate_suffix_backwards): Remove.
157549         (adjust_value): Now takes int style (because of human.h changes)
157550         and long double value (for greater precision on some platforms).
157551         (group_number): New function.
157552         (human_readable): Use it.  Use integer options, not enum.
157553         Put the options before the sizes in the arg list.
157554         Support all the new options.
157555         The old human_readable function has been removed;
157556         use inttostr.h instead.
157557         (human_readable, default_block_size, humblock):
157558         Use uintmax_t, not int, for block sizes.
157559         (human_readable_inexact, block_size_types): Remove.
157560         (block_size_opts): New constant.
157561         (human_options): Renamed from human_block_size, with new signature
157562         that allows block sizes up to UINTMAX_MAX.  All callers changed.
157563         * lib/human.h: Add copyright and authorship notice.
157564         Include <limits.h> and <stdbool.h> unconditionally.
157565         (PARAMS): Remove.  All uses removed.
157566         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
157567         (enum human_inexact_style): Remove tag; now a nameless enum.
157568         (human_floor, human_ceiling, human_round_to_even): Now have
157569         values 2, 0, 1 rather than -1, 1, 0.
157570         (human_group_digits, human_suppress_point_zero, human_autoscale,
157571         human_base_1024, human_SI, human_B): New constants.
157572         (human_readable_inexact, human_block_size): Remove.
157573         (human_readable): Size args are now uintmax_t, not int.
157574         (human_options): New decl.
157576         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
157577         unnecessary now that we assume C89 or better.  This change
157578         imported from coreutils.
157580         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
157581         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
157582         in the 2003-05-30 sync from glibc.
157584         .h files should stand alone, but we shouldn't include <sys/types.h>
157585         if we can get away with just <stddef.h>.
157587         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
157588         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
157589         rather than <sys/types.h>, as we merely need size_t.
157590         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
157591         to get size_t.
157592         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
157593         Include <stdio.h>, to get FILE.
157594         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
157595         memcasecmp.h has included <stddef.h> and all we need is size_t.
157596         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
157597         our interface, instead of including <sys/types.h>
157599 2003-06-04  Paul Eggert  <eggert@twinsun.com>
157601         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
157602         now, as glibc mktime is buggy on non-glibc systems.
157604 2003-06-03  Karl Berry  <karl@gnu.org>
157606         * config/config.sub: update from prep.
157608 2003-06-02  Paul Eggert  <eggert@twinsun.com>
157610         [from coreutils]
157611         Fix some minor time-related bugs with POSIX time arguments.
157612         Some valid time stamps were being rejected (notably -1, and
157613         time stamps before 1900 on 64-bit hosts).  And some invalid
157614         time stamps were being accepted, e.g. September 31.
157616         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
157617         that we can return (time_t) -1 successfully.
157618         * lib/posixtm.c: Likewise.
157619         [HAVE_STDBOOL_H]: Include <stdbool.h>.
157620         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
157621         (t): Remove static var.
157622         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
157623         of static var.  All uses changed.
157624         (year): Do not reject years before 1900; they can occur with
157625         64-bit time_t.
157626         (posix_time_parse): Do not check for out-of-range components;
157627         that is now the caller's responsibility, since our checks were
157628         only approximations.
157629         (posixtime): Use mktime to check for out-of-range components,
157630         since it knows them exactly.
157631         If mktime returns (time_t) -1, check whether an error actually occurred
157632         by invoking localtime on -1.
157633         (main) [TEST_POSIXTIME]: Check for input data errors, and report
157634         posixtime failures better.
157635         Improve the test data (in comments only).
157637 2003-06-02  Karl Berry  <karl@gnu.org>
157639         * config/mkinstalldirs (version): new variable.
157640         (--version): new option.
157641         (usage): improve message.
157643 2003-05-30  Karl Berry  <karl@gnu.org>
157645         * lib/mktime.c: update from libc.
157647 2003-05-30  Bruno Haible  <bruno@clisp.org>
157649         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
157650         * config/config.rpath: Upgrade to gettext-0.12.1.
157652 2003-05-30  Bruno Haible  <bruno@clisp.org>
157654         * m4/gettext.m4: Upgrade to gettext-0.12.1.
157655         * m4/nls.m4: New file, from gettext-0.12.1.
157656         * m4/po.m4: New file, from gettext-0.12.1.
157657         * m4/progtest.m4: Upgrade to gettext-0.12.1.
157659 2003-05-30  Bruno Haible  <bruno@clisp.org>
157661         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
157662         * lib/localcharset.h: Likewise.
157663         * lib/localcharset.c: Likewise.
157665 2003-05-29  Karl Berry  <karl@gnu.org>
157667         * config/config.rpath: update from gettext.
157669 2003-05-28  Paul Eggert  <eggert@twinsun.com>
157671         Assume the headers required for C89 freestanding compilers.
157672         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
157673         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
157674         * m4/human.m4 (gl_HUMAN): Likewise.
157675         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
157676         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
157677         * m4/userspec.m4 (gl_USERSPEC): Likewise.
157678         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
157679         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
157680         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
157682 2003-05-28  Paul Eggert  <eggert@twinsun.com>
157684         Assume the headers required for C89 freestanding compilers.
157685         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
157686         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
157687         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
157688         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
157689         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
157690         define, since <limits.h> is guaranteed to do that.
157691         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
157692         * lib/exclude.c: Include <stdbool.h> unconditionally.
157693         * lib/tempname.c: Include <stddef.h> unconditionally.
157694         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
157695         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
157696         <stddef.h> does that.
157697         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
157698         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
157699         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
157700         needed.
157701         * lib/xstrtol.c: Likewise.
157702         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
157703         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
157705         * lib/addext.c (addext): Use assignment rather than cast, to avoid
157706         warnings on some platforms.
157708         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
157709         arbitrarily.
157711 2003-05-26  Jim Meyering  <jim@meyering.net>
157713         Merge in a change from coreutils:
157714         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
157715         that is guaranteed to be `no'.  Use `no_such_member' to indicate
157716         that condition, rather than `-1' which is slightly misleading.
157717         Change the name of the cache variable to have the gl_ prefix.
157718         Prompted by a patch from Richard Dawe for DJGPP.
157720 2003-05-24  Karl Berry  <karl@gnu.org>
157722         * config/config.guess: update from prep.
157724 2003-05-22  Karl Berry  <karl@gnu.org>
157726         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
157728 2003-05-20  Karl Berry  <karl@gnu.org>
157730         * config/config.guess: update from prep.
157732 2003-05-18  Karl Berry  <karl@gnu.org>
157734         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
157735         might actually be set by the user.
157737         * config/depcomp, install-sh, mdate-sh: update from automake.
157739 2003-05-17  Bruno Haible  <bruno@clisp.org>
157741         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
157742         invalid expansion for AC_EGREP_CPP.
157743         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
157744         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
157745         Suggested by Akim Demaille <akim@epita.fr> in
157746         http://mail.gnu.org/r/bug-autoconf/2003-05/threads.html
157748 2003-05-12  Jim Meyering  <jim@meyering.net>
157750         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
157751         the space-padded-by-default conversion specifiers, %e, %k, %l.
157753 2003-05-12  Bruno Haible  <bruno@clisp.org>
157755         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
157756         the string is longer than 4 KB.
157758 2003-05-11  Karl Berry  <karl@gnu.org>
157760         * config/config.{guess,sub}: update from prep.
157762 2003-05-09  Bruno Haible  <bruno@clisp.org>
157764         * modules/error: Add m4/strerror_r.m4 to file list.
157766 2003-05-03  Bruno Haible  <bruno@clisp.org>
157768         Upgrade to Unicode-4.0.
157769         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
157770         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
157771         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
157772         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
157773         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
157774         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
157775         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
157776         Change width of U+E0100..U+E01EF from 1 to 0.
157778 2003-04-25  Jim Meyering  <jim@meyering.net>
157780         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
157781         of type size_t, not int.
157783 2003-04-25  Bruno Haible  <bruno@clisp.org>
157785         * lib/copy-file.c: Include <stddef.h>, for size_t.
157787 2003-04-21  Paul Eggert  <eggert@twinsun.com>
157789         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
157790         code which expansion is under static control.  Patch imported from
157791         Akim Demaille's patch to Bison; see
157792         <http://mail.gnu.org/r/bison-patches/2003-03/msg00057.html>.
157794 2003-04-14  Bruno Haible  <bruno@clisp.org>
157796         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
157798 2003-04-11  Jim Meyering  <jim@meyering.net>
157800         Merge changes from Coreutils.
157802         2003-03-22  Jim Meyering  <jim@meyering.net>
157804         * lib/strftime.c (widen): Cast alloca return value to proper type.
157806         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
157808         From GNU libc.
157809         * lib/strftime.c (my_strftime): Handle very large width
157810         specifications for numeric values correctly.  Improve checks for
157811         overflow.
157813         2003-01-19  Jim Meyering  <jim@meyering.net>
157815         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
157816         definitions.
157817         (nl_get_alt_digit) [! defined my_strftime]: Define.
157818         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
157819         _nl_get_alt_digit and _nl_get_walt_digit.
157821         * lib/strftime.c (my_strftime): Merge in locale-related changes from
157822         libc. These changes have no effect outside of _LIBC.
157824 2003-04-10  Bruno Haible  <bruno@clisp.org>
157826         * modules/findprog: New file.
157827         * MODULES.html.sh (func_all_modules): Add it.
157829 2003-04-10  Bruno Haible  <bruno@clisp.org>
157831         * m4/findprog.m4: New file.
157832         * m4/eaccess.m4: New file.
157834 2003-04-10  Bruno Haible  <bruno@clisp.org>
157836         * lib/findprog.h: New file, from GNU gettext.
157837         * lib/findprog.c: New file, from GNU gettext.
157839 2003-04-05  Jim Meyering  <jim@meyering.net>
157841         Merge changes from Coreutils.
157843         * lib/exclude.h (PARAMS): Remove definition and uses.
157844         * lib/exclude.c: Remove uses of `PARAMS'.
157846         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
157847         Add test-cases for DOS filenames. Declare program_name.
157848         (main): Set up program_name.  Patch by Rich Dawe.
157850         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
157851         error from mntctl.
157852         Use mntctl's return value to drive the entry-processing loop, since
157853         we can't rely on the value of the vmt_length member in the last
157854         entry.  On some systems doing so could result in exhausting
157855         virtual memory.  Based in part on a patch from Mike Jetzer.
157857 2003-04-04  Bruno Haible  <bruno@clisp.org>
157859         * modules/linebreak: New file.
157860         * MODULES.html.sh (func_all_modules): Add it.
157862 2003-04-04  Bruno Haible  <bruno@clisp.org>
157864         * m4/linebreak.m4: New file.
157866 2003-04-04  Bruno Haible  <bruno@clisp.org>
157868         * lib/linebreak.h: New file, from GNU gettext.
157869         * lib/linebreak.c: New file, from GNU gettext with slight
157870         modifications.
157871         * lib/lbrkprop.h: New file, from GNU gettext.
157873 2003-04-03  Bruno Haible  <bruno@clisp.org>
157875         * modules/utf8-ucs4: New file.
157876         * modules/utf16-ucs4: New file.
157877         * modules/ucs4-utf8: New file.
157878         * modules/ucs4-utf16: New file.
157879         * MODULES.html.sh (func_all_modules): Add them.
157881 2003-04-03  Bruno Haible  <bruno@clisp.org>
157883         * m4/utf-ucs4.m4: New file.
157884         * m4/ucs4-utf.m4: New file.
157886 2003-04-03  Bruno Haible  <bruno@clisp.org>
157888         * lib/utf8-ucs4.h: New file, from GNU gettext.
157889         * lib/utf16-ucs4.h: New file, from GNU gettext.
157890         * lib/ucs4-utf8.h: New file, from GNU gettext.
157891         * lib/ucs4-utf16.h: New file, from GNU gettext.
157893 2003-04-02  Bruno Haible  <bruno@clisp.org>
157895         * modules/binary-io: New file.
157896         * MODULES.html.sh (func_all_modules): Add it.
157898 2003-04-02  Bruno Haible  <bruno@clisp.org>
157900         * lib/binary-io.h: New file, from GNU gettext.
157902 2003-04-01  Bruno Haible  <bruno@clisp.org>
157904         * modules/pathname: New file.
157905         * MODULES.html.sh (func_all_modules): Add it.
157907 2003-04-01  Bruno Haible  <bruno@clisp.org>
157909         * lib/pathname.h: New file, from GNU gettext.
157910         * lib/concatpath.c: New file, from GNU gettext.
157912 2003-03-30  Bruno Haible  <bruno@clisp.org>
157914         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
157916 2003-03-30  Bruno Haible  <bruno@clisp.org>
157918         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
157919         function chown() doesn't exist.
157921 2003-03-28  Bruno Haible  <bruno@clisp.org>
157923         * modules/copy-file: New file.
157924         * MODULES.html.sh (func_all_modules): Add it.
157926 2003-03-28  Bruno Haible  <bruno@clisp.org>
157928         * m4/copy-file.m4: New file.
157930 2003-03-28  Bruno Haible  <bruno@clisp.org>
157932         * lib/copy-file.h: New file, from GNU gettext.
157933         * lib/copy-file.c: New file, from GNU gettext.
157935 2003-03-18  Jim Meyering  <jim@meyering.net>
157937         * lib/quote.c (quote_n): Fix typo in comment.
157939 2003-03-18  Bruno Haible  <bruno@clisp.org>
157941         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
157942         checking.
157943         * m4/onceonly_2_57.m4: Likewise.
157945 2003-03-17  Bruno Haible  <bruno@clisp.org>
157947         * m4/onceonly.m4: Require autoconf 2.54 or newer.
157948         (m4_quote): Remove macro.
157949         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
157951 2003-03-14  Jim Meyering  <jim@meyering.net>
157953         Merge changes from Coreutils.
157954         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
157955         to be const, in order to avoid warnings.
157956         (obstack_room): Likewise.
157957         (obstack_empty_p): Likewise.
157959 2003-03-14  Bruno Haible  <bruno@clisp.org>
157961         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
157962         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
157964 2003-03-13  Paul Eggert  <eggert@twinsun.com>
157966         Merge changes from Bison.
157967         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
157968         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
157969         when compiling Bison 1.875's `bitset bset = obstack_alloc
157970         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
157971         * lib/hash.c: Include <stdbool.h> unconditionally.
157973 2003-03-13  Paul Eggert  <eggert@twinsun.com>
157975         * m4/onceonly.m4 (m4_quote): New macro.
157976         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
157977         Quote AC_FOREACH variable-expansions properly.
157979 2003-03-13  Paul Eggert  <eggert@twinsun.com>
157981         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
157983 2003-03-09  Paul Eggert  <eggert@twinsun.com>
157985         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
157986         Reported by Bruce Becker; see:
157987         http://mail.gnu.org/r/bug-bison/2003-03/msg00017.html
157989 2003-03-03  Paul Eggert  <eggert@twinsun.com>
157990             Bruno Haible  <bruno@clisp.org>
157992         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
157993         Reported by John Hughes, see
157994         http://mail.gnu.org/r/bug-bison/2003-02/msg00030.html
157996 2003-02-20  Bruno Haible  <bruno@clisp.org>
157998         * MODULES.html.sh (func_all_modules): Add poll.
158000 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
158002         * modules/poll: New file.
158004 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
158006         * lib/poll_.h: New file.
158007         * lib/poll.c: New file.
158009 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
158011         * m4/poll.m4: New file.
158013 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
158015         * modules/mathl: New file.
158017 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
158019         * lib/mathl.h: New file.
158020         * lib/acosl.c: New file.
158021         * lib/asinl.c: New file.
158022         * lib/atanl.c: New file.
158023         * lib/ceill.c: New file.
158024         * lib/cosl.c: New file.
158025         * lib/expl.c: New file.
158026         * lib/floorl.c: New file.
158027         * lib/frexpl.c: New file.
158028         * lib/ldexpl.c: New file.
158029         * lib/logl.c: New file.
158030         * lib/sincosl.c: New file.
158031         * lib/sinl.c: New file.
158032         * lib/sqrtl.c: New file.
158033         * lib/tanl.c: New file.
158034         * lib/trigl.c: New file.
158035         * lib/trigl.h: New file.
158037 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
158039         * m4/mathl.m4: New file.
158041 2003-02-18  Bruno Haible  <bruno@clisp.org>
158043         * MODULES.html.sh (func_all_modules): Add mathl.
158045 2003-02-17  Bruno Haible  <bruno@clisp.org>
158047         * modules/mkdtemp: New module.
158048         * MODULES.html.sh (func_all_modules): Add it.
158050 2003-02-17  Bruno Haible  <bruno@clisp.org>
158052         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
158054 2003-02-17  Bruno Haible  <bruno@clisp.org>
158056         * lib/mkdtemp.h: New file, from GNU gettext.
158057         * lib/mkdtemp.c: New file, from GNU gettext.
158059 2003-02-02  Jim Meyering  <jim@meyering.net>
158061         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
158062         e.g. glibc-2.2.93.
158064 2003-01-31  Bruno Haible  <bruno@clisp.org>
158066         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
158067         'rpl_rename'.
158068         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
158069         'rpl_strnlen'.
158070         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
158071         'rpl_strtod'.
158072         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
158073         'rpl_utime'.
158075 2003-01-31  Bruno Haible  <bruno@clisp.org>
158077         * lib/rename.c: #undef rename before defining rpl_rename.
158078         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
158080 2003-01-30  Bruno Haible  <bruno@clisp.org>
158082         * modules/vasnprintf, modules/vasprintf: New modules.
158083         * MODULES.html.sh (func_all_modules): Add them.
158085 2003-01-30  Bruno Haible  <bruno@clisp.org>
158087         * m4/signed.m4: New file, from GNU gettext.
158088         * m4/longdouble.m4: New file, from GNU gettext.
158089         * m4/wchar_t.m4: New file, from GNU gettext.
158090         * m4/wint_t.m4: New file, from GNU gettext.
158091         * m4/vasnprintf.m4: New file.
158092         * m4/vasprintf.m4: New file.
158094 2003-01-30  Bruno Haible  <bruno@clisp.org>
158096         * lib/printf-args.h: New file, from GNU gettext.
158097         * lib/printf-args.c: New file, from GNU gettext.
158098         * lib/printf-parse.h: New file, from GNU gettext.
158099         * lib/printf-parse.c: New file, from GNU gettext.
158100         * lib/vasnprintf.h: New file, from GNU gettext.
158101         * lib/vasnprintf.c: New file, from GNU gettext.
158102         * lib/asnprintf.c: New file, from GNU gettext.
158103         * lib/vasprintf.h: New file, from GNU gettext with modifications.
158104         * lib/vasprintf.c: New file, from GNU gettext.
158105         * lib/asprintf.c: New file, from GNU gettext.
158107 2003-01-29  Bruno Haible  <bruno@clisp.org>
158109         * modules/stpncpy: New module.
158110         * MODULES.html.sh (func_all_modules): Add it.
158112 2003-01-29  Bruno Haible  <bruno@clisp.org>
158114         * m4/stpncpy.m4: New file.
158116 2003-01-29  Bruno Haible  <bruno@clisp.org>
158118         * lib/stpncpy.h: New file, from GNU gettext with modifications.
158119         * lib/stpncpy.c: New file, from GNU gettext with modifications.
158121 2003-01-28  Bruno Haible  <bruno@clisp.org>
158123         * modules/c-ctype: New module.
158124         * MODULES.html.sh (func_all_modules): Add it.
158126 2003-01-28  Bruno Haible  <bruno@clisp.org>
158128         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
158129         Paul Eggert.
158130         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
158131         Paul Eggert.
158133 2003-01-27  Bruno Haible  <bruno@clisp.org>
158135         * modules/xsetenv: New module.
158136         * MODULES.html.sh (func_all_modules): Add it.
158138 2003-01-27  Bruno Haible  <bruno@clisp.org>
158140         * lib/xsetenv.h: New file, from GNU gettext.
158141         * lib/xsetenv.c: New file, from GNU gettext.
158143 2003-01-23  Jim Meyering  <jim@meyering.net>
158145         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
158146         from working on systems without dirfd (at least Irix and OSF1/Tru64).
158148 2003-01-23  Bruno Haible  <bruno@clisp.org>
158150         * modules/minmax: New module.
158151         * MODULES.html.sh (func_all_modules): Add it.
158153 2003-01-23  Bruno Haible  <bruno@clisp.org>
158155         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
158156         Eggert.
158158 2003-01-22  Bruno Haible  <bruno@clisp.org>
158160         * modules/exit: New module.
158161         * MODULES.html.sh (func_all_modules): Add it.
158163 2003-01-22  Bruno Haible  <bruno@clisp.org>
158165         * lib/exit.h: New file, from GNU gettext.
158167 2003-01-19  Bruno Haible  <bruno@clisp.org>
158169         * gnulib-tool: Recognize option --extract-maintainer.
158170         (func_get_maintainer): New function.
158171         * modules/*: Add Maintainer entry.
158173 2003-01-16  Jim Meyering  <jim@meyering.net>
158175         * m4/regex.m4: The `regex' struct is both input and output.
158176         Initialize it before each use.  Patch by Tim Waugh.
158178 2003-01-16  Bruno Haible  <bruno@clisp.org>
158180         * MODULES.html.sh: Add a table of contents. Add the module name as
158181         leftmost column. Add hyperlinks.
158183 2003-01-15  Bruno Haible  <bruno@clisp.org>
158185         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
158187 2003-01-15  Bruno Haible  <bruno@clisp.org>
158189         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
158190         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
158191         suffix.
158193 2003-01-15  Bruno Haible  <bruno@clisp.org>
158195         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
158197 2003-01-15  Bruno Haible  <bruno@clisp.org>
158199         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
158200         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
158202 2003-01-14  Jim Meyering  <jim@meyering.net>
158204         * lib/same.c (same_name): Tweak a comment.
158206 2003-01-14  Bruno Haible  <bruno@clisp.org>
158208         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
158209         when a string comparison is sufficient.
158211 2003-01-14  Bruno Haible  <bruno@clisp.org>
158213         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
158214         'unsigned int'.
158216 2003-01-14  Bruno Haible  <bruno@clisp.org>
158218         * lib/hash-pjw.c: Add comment about low quality of this function.
158220 2003-01-13  Bruno Haible  <bruno@clisp.org>
158222         * modules/stpcpy: Distribute lib/stpcpy.h.
158223         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
158225 2003-01-13  Bruno Haible  <bruno@clisp.org>
158227         * modules/*: Add a description.
158228         * modules/strpbrk: Fix Makefile.am snippet.
158229         * modules/strtoimax: Fix dependencies.
158230         * modules/strtoumax: Likewise.
158232 2003-01-13  Bruno Haible  <bruno@clisp.org>
158234         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
158235         * modules/alloca (Makefile.am): All object files depend on alloca.h.
158236         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
158238 2003-01-13  Bruno Haible  <bruno@clisp.org>
158240         * gnulib-tool (func_create_testdir): Store config/* files in the main
158241         directory.
158242         * config.rpath: Move to ...
158243         * config/config.rpath: ... here.
158244         * modules/gettext: Contains config/config.rpath, not config.rpath.
158245         * modules/iconv: Likewise.
158247 2003-01-12  Paul Eggert  <eggert@twinsun.com>
158249         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
158250         to avoid collisions with libcurses and libreadline.
158252         * m4/getstr.m4: Remove.
158253         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
158255 2003-01-12  Paul Eggert  <eggert@twinsun.com>
158257         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
158258         to avoid collisions with libcurses and libreadline.
158260         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
158261         * lib/getstr.h, getstr.c: Remove.
158262         * lib/getline.c: Include "getline.h", to check interface.
158263         Move body of old getstr.c here: this defines MIN_CHUNK and
158264         declares getdelim2, which is renamed from getstr.
158265         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
158267         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
158268         All uses changed.
158269         * lib/linebuffer.h: Likewise.
158270         (readline): Remove backward-compatibility macro.
158272 2003-01-12  Paul Eggert  <eggert@twinsun.com>
158274         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
158275         to avoid collisions with libcurses and libreadline.
158276         * getstr: Remove.
158277         * MODULES.html.sh: Remove getstr.
158278         * modules/getline: Depend on unlocked-io, not getstr.
158280 2003-01-12  Jim Meyering  <jim@meyering.net>
158282         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
158284 2003-01-10  Bruno Haible  <bruno@clisp.org>
158286         * modules/alloca: Change Makefile.am requirements. Simplify Include
158287         requirements. Add lib/alloca_.h to file list.
158289 2003-01-10  Bruno Haible  <bruno@clisp.org>
158291         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
158293 2003-01-10  Bruno Haible  <bruno@clisp.org>
158295         * lib/alloca_.h: New file.
158296         * lib/getdate.y: Unconditionally include alloca.h.
158297         * lib/makepath.c: Likewise.
158298         * lib/setenv.c: Likewise.
158299         * lib/userspec.c: Likewise.
158301 2003-01-09  Karl Berry  <karl@gnu.org>
158303         * MODULES.html.sh: include `dirname $0` in PATH, to find
158304         gnulib-tool.
158306 2003-01-09  Bruno Haible  <bruno@clisp.org>
158308         * modules/stdbool: Change configure.ac, Makefile.am requirements.
158309         Simplify Include requirements. Add lib/stdbool.h.in to file list.
158311 2003-01-09  Bruno Haible  <bruno@clisp.org>
158313         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
158315 2003-01-09  Bruno Haible  <bruno@clisp.org>
158317         * lib/stdbool.h.in: New file.
158319 2003-01-09  Bruno Haible  <bruno@clisp.org>
158321         * gnulib-tool (func_all_modules): Ignore files ending in ~.
158322         * MODULES.html.sh: Likewise.
158324 2003-01-08  Jim Meyering  <jim@meyering.net>
158326         * lib/full-write.c: Undefine and define-away `const' after inclusion
158327         of errno.h, not before.  Suggestion from Bruno Haible.
158329 2003-01-08  Bruno Haible  <bruno@clisp.org>
158331         * modules/full-read: Depend on full-write.
158333 2003-01-08  Bruno Haible  <bruno@clisp.org>
158335         * lib/safe-read.c: Include specification header first, to ensure its
158336         selfcontainedness.
158337         * lib/full-write.c: Likewise.
158339 2003-01-07  Jim Meyering  <jim@meyering.net>
158341         * lib/full-write.c: Rework so that it may serve to define full_read,
158342         too.
158343         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
158345 2003-01-07  Bruno Haible  <bruno@clisp.org>
158347         * lib/strtoimax.c: Include <stdint.h> as an alternative to
158348         <inttypes.h>.
158349         * lib/xstrtol.h: Likewise.
158350         * lib/xstrtoimax.c: Likewise.
158351         * lib/xstrtoumax.c: Likewise.
158352         * lib/human.h: Likewise.
158354         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
158355         on systems that have <inttypes.h> but not <stdint.h>.
158357 2003-01-07  Bruno Haible  <bruno@clisp.org>
158359         * MODULES.html.sh: Add copyright notice.
158360         (missed_files): Omit CVS directory entries.
158361         (func_module): Make it work with sed-3.02.
158362         * MODULES.txt: Remove file.
158364 2003-01-06  Jim Meyering  <jim@meyering.net>
158366         * lib/version-etc.c: Update year in translatable copyright string.
158368 2003-01-03  Karl Berry  <karl@gnu.org>
158370         * config/config.{guess,sub}: update from prep.
158372 2003-01-02  Karl Berry  <karl@gnu.org>
158374         * doc/COPYING.DOC: belatedly updated to 1.2.
158376 2003-01-01  Karl Berry  <karl@gnu.org>
158378         * gnulib-tool (func_verify_module): report module name $module in
158379         error message, not $1.
158380         * gnulib-tool (create-testdir): don't complain if destdir couldn't
158381         be created, only if it doesn't exist.
158382         * gnulib-tool (last_checkin_date): don't expand the $Date here.
158384 2002-12-31  Paul Eggert  <eggert@twinsun.com>
158386         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
158388 2002-12-31  Paul Eggert  <eggert@twinsun.com>
158390         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
158391         memcmp if strcoll doesn't work.
158393 2002-12-31  Bruno Haible  <bruno@clisp.org>
158395         * lib/utime.c (utime_null): No need to call ftruncate if the file was
158396         nonempty.
158398 2002-12-31  Bruno Haible  <bruno@clisp.org>
158400         * lib/memcoll.c (STRCOLL): New macro.
158401         (memcoll): Use it.
158403 2002-12-31  Bruno Haible  <bruno@clisp.org>
158405         * lib/localcharset.h: New file.
158406         * lib/localcharset.c: Include it.
158407         * lib/unicodeio.c: Likewise.
158409 2002-12-31  Bruno Haible  <bruno@clisp.org>
158411         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
158412         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
158414 2002-12-31  Bruno Haible  <bruno@clisp.org>
158416         * lib/getline.h: Include <stddef.h>, for size_t.
158418         * lib/unicodeio.h: Include <stddef.h>, for size_t.
158419         * lib/unicodeio.c: Don't include <stddef.h>.
158421 2002-12-31  Bruno Haible  <bruno@clisp.org>
158423         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
158424         HAVE_TM_ZONE.
158426 2002-12-24  Karl Berry  <karl@gnu.org>
158428         * config/config.guess: update from prep.
158430 2002-12-24  Bruno Haible  <bruno@clisp.org>
158432         General infrasructure.
158433         * m4/README: Rewritten.
158434         * m4/onceonly.m4: New file.
158435         * m4/onceonly_2_57.m4: New file.
158437         Module atexit.
158438         * m4/atexit.m4: New file.
158440         Module strtod.
158441         * m4/strtod.m4: New file.
158443         Module strtol.
158444         * m4/strtol.m4: New file.
158446         Module strtoul.
158447         * m4/strtoul.m4: New file.
158449         Module memchr.
158450         * m4/memchr.m4: New file.
158452         Module memcmp.
158453         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
158454         (jm_FUNC_MEMCMP): Invoke it.
158456         Module memcpy.
158457         * m4/memcpy.m4: New file.
158459         Module memmove.
158460         * m4/memmove.m4: New file.
158462         Module memset.
158463         * m4/memset.m4: New file.
158465         Module strcspn.
158466         * m4/strcspn.m4: New file.
158468         Module strpbrk.
158469         * m4/strpbrk.m4: New file.
158471         Module strstr.
158472         * m4/strstr.m4: New file.
158474         Module strerror.
158475         * m4/strerror.m4: New file.
158477         Module mktime.
158478         * m4/mktime.m4: Renamed from jm-mktime.m4.
158479         (gl_PREREQ_MKTIME): New macro.
158480         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
158482         Module malloc.
158483         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
158484         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
158485         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
158487         Module realloc.
158488         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
158489         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
158490         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
158492         Module strftime.
158493         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
158494         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
158495         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
158496         gl_TM_GMTOFF.
158497         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
158499         Module xalloc.
158500         * m4/xalloc.m4: New file.
158502         Module alloca.
158503         * m4/alloca.m4: New file.
158505         Module putenv.
158506         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
158507         (jm_FUNC_PUTENV): Invoke it.
158509         Module setenv.
158510         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
158511         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
158512         when invoked twice.
158513         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
158514         gt_FUNC_SETENV.
158516         Module memrchr.
158517         * m4/memrchr.m4: New file.
158519         Module stpcpy.
158520         * m4/stpcpy.m4: New file.
158522         Module strcase.
158523         * m4/strcase.m4: New file.
158525         Module strdup.
158526         * m4/strdup.m4: New file.
158528         Module strnlen.
158529         * m4/strnlen.m4: New file.
158531         Module strndup.
158532         * m4/strndup.m4: New file.
158534         Module xstrtod.
158535         * m4/xstrtod.m4: New file.
158537         Module xstrtol.
158538         * m4/xstrtol.m4: New file.
158540         Module getdate.
158541         * m4/getdate.m4: New file.
158543         Module unlocked-io.
158544         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
158545         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
158546         * m4/jm-glibc-io.m4n: Remove file.
158548         Module long-options.
158549         * m4/long-options.m4: New file.
158551         Module md5.
158552         * m4/md5.m4: New file.
158554         Module sha.
158555         * m4/sha.m4: New file.
158557         Module getstr.
158558         * m4/getstr.m4: New file.
158560         Module getline.
158561         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
158562         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
158563         <sys/types.h>, for size_t. Use the function name gnu_getline, not
158564         simply getline. Infoke gl_PREREQ_GETLINE.
158566         Module obstack.
158567         * m4/obstack.m4: New file.
158569         Module hash.
158570         * m4/hash.m4: New file.
158572         Module readtokens.
158573         * m4/readtokens.m4: New file.
158575         Module strverscmp.
158576         * m4/strverscmp.m4: New file.
158578         Module stdbool.
158579         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
158580         OSF/1.
158582         Module strtoll.
158583         * m4/strtoll.m4: New file.
158585         Module strtoull.
158586         * m4/strtoull.m4: New file.
158588         Module strtoimax.
158589         * m4/strtoimax.m4: New file.
158591         Module strtoumax.
158592         * m4/strtoumax.m4: New file.
158594         Module xstrtoimax.
158595         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
158596         jm_AC_PREREQ_XSTRTOIMAX.
158597         Moved the strtol prerequisites to strtol.m4.
158598         Moved the strtoll prerequisites to strtoll.m4.
158599         Moved the strtoimax prerequisites to strtoimax.m4.
158601         Module xstrtoumax.
158602         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
158603         jm_AC_PREREQ_XSTRTOUMAX.
158604         Moved the strtoul prerequisites to strtoul.m4.
158605         Moved the strtoull prerequisites to strtoull.m4.
158606         Moved the strtoumax prerequisites to strtoumax.m4.
158608         Module chown.
158609         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
158610         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
158612         Module dup2.
158613         * m4/dup2.m4: New file.
158615         Module ftruncate.
158616         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
158617         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
158619         Module getgroups.
158620         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
158621         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
158623         Module gettimeofday.
158624         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
158625         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
158626         gl_PREREQ_GETTIMEOFDAY.
158628         Module mkdir.
158629         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
158630         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
158632         Module mkstemp.
158633         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
158634         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
158635         jm_AC_TYPE_UINTMAX_T.
158636         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
158638         Module stat.
158639         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
158640         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
158642         Module lstat.
158643         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
158644         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
158646         Module timespec.
158647         * m4/timespec.m4 (gl_TIMESPEC): New macro.
158648         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
158649         * m4/st_mtim.m4: Indentation.
158651         Module nanosleep.
158652         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
158653         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
158654         gl_PREREQ_NANOSLEEP.
158656         Module regex.
158657         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
158658         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
158659         (gl_REGEX): New macro.
158661         Module rename.
158662         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
158663         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
158665         Module rmdir.
158666         * m4/rmdir.m4: New file.
158668         Module utime.
158669         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
158670         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
158671         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
158673         Module dirname.
158674         * m4/dirname.m4: New file.
158676         Module getopt.
158677         * m4/getopt.m4: New file.
158679         Module unistd-safer.
158680         * m4/unistd-safer.m4: New file.
158682         Module fnmatch.
158683         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
158684         declaration.
158685         (gl_PREREQ_FNMATCH_EXTRA): New macro.
158686         (gl_FUNC_FNMATCH_POSIX): New macro.
158687         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
158688         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
158689         simply fnmatch.
158691         Module exclude.
158692         * m4/exclude.m4: New file.
158694         Module human.
158695         * m4/human.m4: New file.
158697         Module acl.
158698         * m4/acl.m4: Nop.
158700         Module backupfile.
158701         * m4/backupfile.m4: New file.
158702         * m4/d-ino.m4: Indentation.
158704         Module fsusage.
158705         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
158706         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
158707         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
158709         Module dirfd.
158710         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
158711         requirements.
158713         Module euidaccess.
158714         * m4/euidaccess.m4: New file.
158716         Module file-type.
158717         * m4/file-type.m4: New file.
158719         Module fileblocks.
158720         * m4/fileblocks.m4: New file.
158722         Module filemode.
158723         * m4/filemode.m4: New file.
158725         Module isdir.
158726         * m4/isdir.m4: New file.
158728         Module lchown.
158729         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
158730         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
158732         Module makepath.
158733         * m4/makepath.m4: New file.
158735         Module modechange.
158736         * m4/modechange.m4: New file.
158738         Module mountlist.
158739         * m4/mountlist.m4: New file.
158740         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
158741         Indentation.
158743         Module path-concat.
158744         * m4/path-concat.m4: New file.
158746         Module pathmax.
158747         * m4/pathmax.m4: New file.
158749         Module same.
158750         * m4/same.m4: New file.
158752         Module save-cwd.
158753         * m4/save-cwd.m4: New file.
158755         Module savedir.
158756         * m4/savedir.m4: New file.
158758         Module xgetcwd.
158759         * m4/xgetcwd.m4: New file.
158760         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
158762         Module xreadlink.
158763         * m4/xreadlink.m4: New file.
158765         Module safe-read.
158766         * m4/safe-read.m4: New file.
158768         Module safe-write.
158769         * m4/safe-write.m4: New file.
158771         Module closeout.
158772         * m4/closeout.m4: New file.
158774         Module stdio-safer.
158775         * m4/stdio-safer.m4: New file.
158777         Module getpass.
158778         * m4/getpass.m4: New file.
158780         Module getugroups.
158781         * m4/getugroups.m4: New file.
158783         Module group-member.
158784         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
158785         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
158787         Module idcache.
158788         * m4/idcache.m4: New file.
158790         Module userspec.
158791         * m4/userspec.m4: New file.
158793         Module gettime.
158794         * m4/clock_time.m4: New file.
158795         * m4/gettime.m4: New file.
158797         Module settime.
158798         * m4/settime.m4: New file.
158800         Module posixtm.
158801         * m4/posixtm.m4: New file.
158803         Module gethostname.
158804         * m4/gethostname.m4: New file.
158806         Module canon-host.
158807         * m4/canon-host.m4: New file.
158809         Module gettext.
158810         * m4/codeset.m4: New file, from gettext-0.11.5.
158811         * m4/gettext.m4: New file, from gettext-0.11.5.
158812         * m4/glibc21.m4: New file, from gettext-0.11.5.
158813         * m4/iconv.m4: New file, from gettext-0.11.5.
158814         * m4/intdiv0.m4: New file, from gettext-0.11.5.
158815         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
158816         * m4/inttypes.m4: New file, from gettext-0.11.5.
158817         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
158818         * m4/isc-posix.m4: New file, from gettext-0.11.5.
158819         * m4/lcmessage.m4: New file, from gettext-0.11.5.
158820         * m4/lib-ld.m4: New file, from gettext-0.11.5.
158821         * m4/lib-link.m4: New file, from gettext-0.11.5.
158822         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
158823         * m4/progtest.m4: New file, from gettext-0.11.5.
158824         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
158825         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
158826         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
158828         Module localcharset.
158829         * m4/localcharset.m4: New file.
158831         Module hard-locale.
158832         * m4/hard-locale.m4: New file.
158834         Module mbswidth.
158835         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
158836         onceonly macros.
158837         * m4/mbrtowc.m4: Add comment.
158839         Module memcasecmp.
158840         * m4/memcasecmp.m4: New file.
158842         Module memcoll.
158843         * m4/memcoll.m4: New file.
158845         Module unicodeio.
158846         * m4/unicodeio.m4: New file.
158848         Module rpmatch.
158849         * m4/rpmatch.m4: New file.
158851         Module yesno.
158852         * m4/yesno.m4: New file.
158854         Module exitfail.
158855         * m4/exitfail.m4: New file.
158857         Module c-stack.
158858         * m4/c-stack.m4 (gl_C_STACK): New macro.
158859         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
158861         Module error.
158862         * m4/error.m4 (gl_ERROR): New macro.
158863         (jm_PREREQ_ERROR): Use onceonly macros.
158865         Module fatal.
158866         * m4/fatal.m4: New file.
158868         Module getloadavg.
158869         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
158870         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
158872         Module getpagesize.
158873         * m4/getpagesize.m4: New file.
158875         Module getusershell.
158876         * m4/getusershell.m4: New file.
158878         Module physmem.
158879         * m4/physmem.m4: New file.
158881         Module posixver.
158882         * m4/posixver.m4: New file.
158884         Module quotearg.
158885         * m4/quotearg.m4: New file.
158887         Module quote.
158888         * m4/quote.m4: New file.
158890         Module readutmp.
158891         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
158893         Module sig2str.
158894         * m4/sig2str.m4: New file.
158896         Other.
158897         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
158898         ulonglong.m4.
158899         * m4/intmax_t.m4: New file.
158900         * m4/d-type.m4: Indentation.
158901         * m4/jm-macros.m4: Update.
158902         * m4/prereq.m4 (jm_PREREQ): Update.
158903         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
158904         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
158905         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
158906         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
158907         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
158908         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
158909         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
158910         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
158911         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
158912         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
158913         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
158914         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
158915         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
158916         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
158917         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
158918         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
158919         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
158920         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
158921         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
158923 2002-12-24  Bruno Haible  <bruno@clisp.org>
158925         * MODULES.txt: Update according to m4/ changes.
158927         Module gettext.
158928         * config.rpath: New file, from gettext-0.11.5.
158930         * modules/*: New module descriptions.
158931         * gnulib-tool: New file.
158932         * MODULES.html.sh: New file.
158934 2002-12-21  Karl Berry  <karl@gnu.org>
158936         * doc/fdl.texi: update to version 1.2.
158938 2002-12-19  Karl Berry  <karl@gnu.org>
158940         * config/config.guess: update from prep.
158942 2002-12-18  Bruno Haible  <bruno@clisp.org>
158944         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
158945         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
158947 2002-12-17  Bruno Haible  <bruno@clisp.org>
158949         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
158950         stdlib.h, string.h.
158952 2002-12-17  Bruno Haible  <bruno@clisp.org>
158954         * lib/canon-host.c (strdup): Remove unused declaration.
158956         * lib/fsusage.c: Include full_read.h.
158957         (get_fs_usage): Use full_read instead of safe_read.
158959         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
158961 2002-12-12  Karl Berry  <karl@gnu.org>
158963         * config/config.guess: update from prep.
158965 2002-12-11  Bruno Haible  <bruno@clisp.org>
158967         * m4/setenv.m4: New file, from gettext-0.11.5.
158969 2002-12-11  Bruno Haible  <bruno@clisp.org>
158971         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
158972         not unsetenv().
158973         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
158974         modifications:
158976         2002-12-11  Bruno Haible  <bruno@clisp.org>
158978                 * setenv.c (alloca): Fall back to malloc.
158979                 (freea): New macro.
158980                 (setenv): Use freea() to free memory allocated with alloca().
158982         2002-11-13  Bruno Haible  <bruno@clisp.org>
158984                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
158985                 function declarations.
158986                 * unsetenv.c (unsetenv): Likewise.
158988         2002-03-04  Bruno Haible  <bruno@clisp.org>
158990                 Portability to AIX 4.3.3.
158991                 * unsetenv.c: New file, extracted from setenv.c.
158992                 * setenv.c: Move the unsetenv() function to unsetenv.c.
158994         2001-12-20  Bruno Haible  <bruno@clisp.org>
158996                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
158997                 use malloc instead. For SunOS 4.
158999         2001-12-11  Bruno Haible  <bruno@clisp.org>
159001                 * setenv.c: Declare alloca.
159002                 (compar_fn_t): New typedef.
159003                 (KNOWN_VALUE, STORE_VALUE): Use it.
159005         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
159006         setenv.h.
159008 2002-12-10  Paul Eggert  <eggert@twinsun.com>
159010         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
159011         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
159012         Choose values that are less likely to collide with system fnmatch
159013         options.
159014         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
159015         defined (e.g., a pure POSIX system).
159016         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
159017         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
159019 2002-12-06  Paul Eggert  <eggert@twinsun.com>
159021         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
159022         a pain in practice to deal with generated m4 files.  This change
159023         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
159025         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
159026         and jm-glibc-io.m4, as they are no longer a special case.
159027         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
159028         kludge and the auto-generation stuff.  Check only whether the
159029         functions are declared, not whether they exist, since older hosts
159030         that don't declare the functions can't use the optimization anyway.
159032 2002-12-06  Jim Meyering  <jim@meyering.net>
159034         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
159036         Merge in changes from libc's misc/error.c, in preparation
159037         for the merge of gnulib's changes back into libc.
159039         * lib/error.c (_): Define only if not already defined.
159040         Move definition to follow all #include directives.
159041         Include unlocked-io.h only if !_LIBC.
159042         [_LIBC]: Include <libio/libioP.h>.
159043         [USE_IN_LIBIO]: Include <libio/iolibio.h>
159044         (fflush): Tweak definition to use INTUSE.
159045         (putc): Define.
159047 2002-12-05  Paul Eggert  <eggert@twinsun.com>
159049         * lib/alloca.c [defined emacs]: Include "lisp.h".
159050         (xalloc_die) [defined emacs]: New macro.
159051         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
159052         [! defined emacs]: Include <xalloc.h>.
159053         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
159054         (pointer): Typedef to POINTER_TYPE *.
159055         (malloc): Remove decl; we now always use xmalloc.
159056         (alloca): Use old-style definition, since Emacs needs this.
159057         Check for arithmetic overflow when computing combined size.
159059 2002-12-04  Paul Eggert  <eggert@twinsun.com>
159061         Do not generate unlocked-io.h automatically, since it's easier to
159062         maintain it by hand.
159064         * lib/unlocked-io.h: New file, from GNU diffutils,
159065         but with proper copyright notice and attribution.
159066         * lib/gen-uio: Remove.
159067         * lib/Makefile.am: Add copyright notice.
159068         (libfetish_a_SOURCES): Add unlocked-io.h.
159069         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
159070         (DISTCLEANFILES, io_functions): Remove macros.
159071         (EXTRA_DIST): Remove gen_uio.
159072         (unlocked-io.h): Remove rule.
159074 2002-12-04  Jim Meyering  <jim@meyering.net>
159076         Reflect the fact that stat.c and lstat.c are no longer generated.
159077         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
159078         (DISTCLEANFILES): Likewise.
159079         (EXTRA_DIST): Likewise.
159080         (all_local): Don't depend on stat.c or lstat.c.
159081         (stat.c, lstat.c): Remove rules.
159082         (EXTRA_DIST): Remove xstat.in.
159084         * lib/xstat.in: Remove file.  Contents moved into stat.c.
159085         * lib/stat.c: New file.  Contents mostly from xstat.in.
159086         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
159087         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
159089         * lib/safe-read.c: Rework so that it may serve to define safe_write,
159090         too.
159091         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
159093 2002-12-03  Jim Meyering  <jim@meyering.net>
159095         * lib/safe-read.c, safe-write.c: Change variable names and comments,
159096         but not semantics, to minimize the differences between these two files.
159097         (safe_read): Change comment to mention SAFE_READ_ERROR.
159099         * lib/safe-read.c (IS_EINTR): Define.
159100         (safe_read): Use IS_EINTR in place of in-function cpp directives.
159102 2002-12-02  Jim Meyering  <jim@meyering.net>
159104         * lib/safe-read.c (EINTR): Define.
159105         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
159106         (INT_MAX): Provide fallback.
159107         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
159109         * lib/safe-read.h (SAFE_READ_ERROR): Define.
159111 2002-12-02  Bruno Haible  <bruno@clisp.org>
159113         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
159114         Define, taken from safe-read.c.
159115         (INT_MAX): Provide fallback.
159116         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
159117         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
159119         * lib/safe-read.c (EINTR): Remove definition.
159120         (safe_read): Don't use EINTR if it is absent.
159122 2002-12-01  Jim Meyering  <jim@meyering.net>
159124         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
159125         zero.
159126         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
159128 2002-11-27  Paul Eggert  <eggert@twinsun.com>
159130         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
159131         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
159132         with `if (! (value < limit)) abort ();', for readability.
159134 2002-11-26  Karl Berry  <karl@gnu.org>
159136         * lib/strdup.c: copy from libc again, with jim's ok.
159137         * lib/.cppi-disable: re-add strdup.c
159139 2002-11-25  Karl Berry  <karl@gnu.org>
159141         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
159142         instead of "strtol.c".
159144 2002-11-25  Karl Berry  <karl@gnu.org>
159146         * config/install-sh: update from automake for variable quoting, $0 in
159147         error msgs, etc.
159149         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
159150         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
159151         entry.
159153 2002-11-25  Jim Meyering  <jim@meyering.net>
159155         * lib/mktime.c: Sync from libc, now that it has the latest fix.
159157 2002-11-24  Karl Berry  <karl@gnu.org>
159159         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
159160         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
159162 2002-11-24  Jim Meyering  <jim@meyering.net>
159164         Update from coreutils:
159166         * lib/mktime.c: Merge in changes from libc.
159168         Avoid a link-time failure on some Linux systems.
159169         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
159170         (otherwise).
159171         (__mon_yday): Declare with the STATIC attribute.
159172         (__mktime_internal): Likewise.
159173         Based on a report from Greg Schafer.
159175 2002-11-23  Jim Meyering  <jim@meyering.net>
159177         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
159178         Use `unsigned', not `int', as type of index.
159180         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
159182         * lib/fsusage.c: Remove unneeded parentheses around operands of
159183         `defined'.
159185 2002-11-22  Paul Eggert  <eggert@twinsun.com>
159187         * lib/quotearg.h: Allow multiple inclusion by surrounding with
159188         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
159189         so that we can be included first.
159190         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
159191         * lib/quotearg.c: Include quotearg.h immediately after config.h.
159192         No need to include stddef.h or sys/types.h any more.
159193         Surround local include files with "", not "<>".
159194         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
159195         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
159196         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
159197         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
159198         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
159199         (ISPRINT): Remove; no longer needed now that we assume C89.
159201         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
159202         Preserve errno.
159204         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
159205         quotearg_char): Use SIZE_MAX rather than
159206         (size_t) -1 when we are talking about "infinity".
159208         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
159210 2002-11-22  Paul Eggert  <eggert@twinsun.com>
159212         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
159213         hint that one should use `if (! x) abort ();' rather than `assert
159214         (x);', and anyway it's one less thing to worry about configuring.
159215         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
159216         hash_rehash, hash_insert): Use abort rather than assert.
159218 2002-11-22  Bruno Haible  <bruno@clisp.org>
159220         * lib/safe-read.h: Assume C89. Add comments.
159221         (safe_read): Change return type to size_t.
159222         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
159223         byte counts > SSIZE_MAX correctly.
159224         * lib/safe-write.h: New file.
159225         * lib/safe-write.c: New file.
159226         * lib/full-read.h: New file.
159227         * lib/full-read.c: New file.
159228         * lib/full-write.h: Assume C89. Add comments.
159229         * lib/full-write.c: Include safe-write.h.
159230         (full_write): Rewritten to use safe_write.
159231         Suggested by Jim Meyering and Paul Eggert.
159233 2002-11-21  Jim Meyering  <jim@meyering.net>
159235         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
159237         Merge in changes from the coreutils.
159239         2002-09-25  Paul Eggert  <eggert@twinsun.com>
159240         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
159241         <stdint.h>.
159242         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
159243         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
159244         int.  Work more efficiently if X is the same width as uintmax_t.
159245         Do not compare X to -1, to avoid bogus compiler warning.
159246         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
159247         Don't assume that f_frsize and f_bsize are the same type.
159249         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
159250         warning on FreeBSD.
159252         * lib/makepath.c (make_path): Restore umask *before* creating the final
159253         component.
159254         (make_path): Minor reformatting.
159256         * lib/xmalloc.c: Adjust to work with new autoconf macros,
159257         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
159258         HAVE_MALLOC/HAVE_REALLOC.
159260         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
159261         dummy ones.  At least on GNU/Linux systems, `auto' means something
159262         else.
159263         From Michael Stone.
159265 2002-11-21  Bruno Haible  <bruno@clisp.org>
159267         Remove case insensitive option matching.
159268         * lib/argmatch.h (argcasematch): Remove declaration.
159269         (ARGCASEMATCH): Remove macro.
159270         (__xargmatch_internal): Remove case_sensitive argument.
159271         (XARGMATCH): Update.
159272         (XARGCASEMATCH): Remove macro.
159273         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
159274         case_sensitive argument.
159275         (argcasematch): Remove function.
159276         (__xargmatch_internal): Remove case_sensitive argument.
159277         (main): Use XARGMATCH instead of XARGCASEMATCH.
159279         * lib/xmalloc.c: Change compile-time error message. Add comment about
159280         required autoconf version.
159282 2002-11-20  Paul Eggert  <eggert@twinsun.com>
159284         Merge argmatch cleanups from Bison.  Assume C89.
159286         * lib/argmatch.c: Include config.h here, not in argmatch.h.
159287         Include stdlib.h, for EXIT_FAILURE.
159288         Always include <string.h>, since we assume C89.
159289         (EXIT_FAILURE): Remove pre-C89 bug workaround.
159290         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
159291         Include <stddef.h> instead, since it's all we need for size_t.
159292         (PARAMS): Remove.  All uses removed.
159293         (ARRAY_CARDINALITY): Do not bother to #undef.
159294         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
159295         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
159296         Remove unnecessary parentheses.
159297         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
159298         Insert necessary parentheses.
159299         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
159300         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
159302 2002-11-19  Bruno Haible  <bruno@clisp.org>
159304         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
159305         * lib/mbswidth.h: Include <stddef.h>, for size_t.
159307         * lib/mbswidth.h (PARAMS): Remove macro.
159308         (mbswidth, mbsnwidth): Use ANSI C function declarations.
159309         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
159311         * lib/gcd.h (PARAMS): Remove macro.
159312         (gcd): Use ANSI C function declarations.
159313         * lib/gcd.c (gcd): Likewise.
159315 2002-11-15  Bruno Haible  <bruno@clisp.org>
159317         * lib/strcspn.c: Include <stddef.h>.
159318         (strcspn): Use ANSI C function declaration. Change return type to
159319         size_t. Use NULL.
159320         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
159321         (strpbrk): Use NULL.
159322         * lib/strpbrk.h (PARAMS): Remove macro.
159323         (strpbrk): Use ANSI C function declaration.
159324         * lib/strstr.c: Don't include <sys/types.h>.
159325         * lib/strstr.h (PARAMS): Remove macro.
159326         (strstr): Use ANSI C function declarations.
159328 2002-11-14  Karl Berry  <karl@gnu.org>
159330         * config/mkinstalldirs: `do' on separate line, instead of
159331         `for var; do'.
159333 2002-11-06  Bruno Haible  <bruno@clisp.org>
159335         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
159336         * lib/gcd.c (gcd): Likewise.
159338 2002-11-05  Bruno Haible  <bruno@clisp.org>
159340         * lib/gcd.h: New file, from gettext-0.11.5.
159341         * lib/gcd.c: New file, from gettext-0.11.5.
159343 2002-11-05  Bruno Haible  <bruno@clisp.org>
159345         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
159346         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
159347         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
159348         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
159350         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
159351         <libintl.h>.
159352         * lib/makepath.c: Include gettext.h instead of <locale.h> and
159353         <libintl.h>.
159355         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
159356         * lib/human.c: Include gettext.h instead of <libintl.h>.
159357         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
159358         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
159359         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
159360         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
159361         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
159362         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
159363         (textdomain): Remove definition.
159364         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
159366         * lib/long-options.c: Remove include of <libintl.h> and definition of
159367         _.
159368         * lib/same.c: Remove include of <libintl.h> and definition of _.
159370 2002-11-04  Owen Taylor  <otaylor@redhat.com>
159372         * lib/config.charset: A few additions for Solaris.
159374 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
159376         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
159377         * lib/localcharset.c (locale_charset): Declare as extern "C".
159379 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
159381         * lib/config.charset: msdos in uk_UA uses CP1125.
159383 2002-11-04  Bruno Haible  <bruno@clisp.org>
159385         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
159386         * lib/strcase.h: New file, from GNU gettext-0.11.5.
159387         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
159388         * lib/strstr.h: New file, from GNU gettext-0.11.5.
159389         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
159391 2002-11-04  Bruno Haible  <bruno@clisp.org>
159393         * lib/localcharset.c (locale_charset): Don't return an empty string.
159395 2002-11-04  Bruno Haible  <bruno@clisp.org>
159397         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
159398         aliases.
159400 2002-11-04  Bruno Haible  <bruno@clisp.org>
159402         * lib/config.charset: Update for newest glibc. Add canonical names
159403         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
159405 2002-11-04  Bruno Haible  <bruno@clisp.org>
159407         * lib/config.charset: Add support for NetBSD.
159409 2002-11-04  Bruno Haible  <bruno@clisp.org>
159411         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
159413 2002-11-01  Bruno Haible  <bruno@clisp.org>
159415         * configure.in: Add AC_CONFIG_AUX_DIR call.
159416         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
159417         test/Makefile.
159418         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
159420 2002-09-28  Karl Berry  <karl@gnu.org>
159422         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
159423         installed automake until the next release, since changes have been
159424         made.
159426 2002-09-25  Karl Berry  <karl@gnu.org>
159428         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
159429         * lib/getopt*: copy from libc/posix.
159430         * lib/gettext.h: copy from gettext.
159431         * lib/.cppi-disable: add strdup.c, gettext.h.
159433 2002-09-25  Karl Berry  <karl@gnu.org>
159435         * config/srclist.txt: enable gettext.h check.
159436         * config/config.{guess,sub}: update from prep.
159437         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
159438                 from automake 1.6.3.
159439         See srclist*.
159441 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
159443         * regex.c (PATFETCH): Remove the translating fetch.
159444         (PATFETCH_RAW): Rename to PATFETCH.
159445         (set_image_of_range): New fun.
159446         (SET_RANGE_TABLE_WORK_AREA): Use it.
159447         (regex_compile): Don't translate the pattern chars so eagerly.
159448         Only do it when inserting an `exactn' bytecode or when handling
159449         a char-range.
159450         (mutually_exclusive_p): Avoid empty statement.
159452 2002-07-06  Jim Meyering  <meyering@lucent.com>
159454         * m4/README: Don't mention Makefile.am.in.
159455         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
159457 2002-07-01  Jim Meyering  <meyering@lucent.com>
159459         * lib/c-stack.c: Include sys/time.h.
159460         From Volker Borchert.
159462 2002-06-26  Paul Eggert  <eggert@twinsun.com>
159464         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
159466 2002-06-26  Paul Eggert  <eggert@twinsun.com>
159468         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
159469         New macro.  Use it uniformly instead of
159470         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
159471         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
159472         reported by Vin Shelton.
159474 2002-06-22  Paul Eggert  <eggert@twinsun.com>
159476         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
159477         Do not assume SA_SIGINFO behavior.
159478         Bug reported by Jim Meyering on NetBSD 1.5.2.
159480 2002-06-22  Jim Meyering  <meyering@lucent.com>
159482         * m4/c-stack.m4: New file, from diffutils-2.8.2.
159483         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
159485         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
159486         now that configure.ac uses AC_GNU_SOURCE.
159487         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
159488         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
159490         Update to latest tools.  Suggestions from Paul Eggert.
159491         * m4/stdbool.m4: New file, from diffutils-2.8.2.
159492         * m4/gnu-source.m4: Update from diffutils-2.8.2.
159493         * m4/fnmatch.m4: Likewise.
159494         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
159495         to AC_HEADER_STDBOOL
159497 2002-06-22  Jim Meyering  <meyering@lucent.com>
159499         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
159500         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
159502 2002-06-22  Jim Meyering  <meyering@lucent.com>
159504         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
159506         * lib/exitfail.c, exitfail.h: Likewise.
159507         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
159509         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
159510         of fnmatch.h.
159511         (EXTRA_DIST): Add fnmatch_loop.c.
159512         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
159514         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
159515         * lib/fnmatch.c: Update from diffutils-2.8.2.
159516         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
159517         * lib/fnmatch.h: Remove file.
159519 2002-06-21  Jim Meyering  <meyering@lucent.com>
159521         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
159522         * m4/mbrtowc.m4: Likewise.
159524         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
159525         * m4/mbswidth.m4: Reflect name change:
159526         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
159527         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
159529         * m4/lib-link.m4: Update from gettext-0.11.2.
159530         * m4/gettext.m4: Likewise.
159532         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
159533         From Alfred M. Szmidt.
159535 2002-06-18  Paul Eggert  <eggert@twinsun.com>
159537         * lib/file-type.h: Report an error if neither S_ISREG nor
159538         S_IFREG is defined, instead of using a test specific to glibc
159539         2.2.  This should be safe, since POSIX requires S_ISREG and
159540         Unix Version 7 had S_IFREG.  We don't need to check for
159541         <sys/types.h> since we don't use any symbols that it defines.
159543 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
159545         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
159546         $@-t, so that each temporary file name is unique and valid in the first
159547         8 characters, for operation under DOS.
159549 2002-06-15  Paul Eggert  <eggert@twinsun.com>
159551         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
159553 2002-06-15  Jim Meyering  <meyering@lucent.com>
159555         Work even with DJGPP 2.03, which lacks support for symlinks.
159556         From Richard Dawe.
159557         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
159558         is defined.
159559         * lib/lchown.c (S_ISLNK): Likewise.
159561 2002-06-15  Jim Meyering  <meyering@lucent.com>
159563         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
159564         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
159565         have been included before this file.
159567 2002-06-14  Jim Meyering  <meyering@lucent.com>
159569         * lib/file-type.h: Use the version from diffutils-2.8.2.
159570         * lib/file-type.c: Likewise.
159572 2002-06-07  Jim Meyering  <meyering@lucent.com>
159574         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
159575         They're needed at least for NetBSD 1.5.2.
159576         ($statxfs_includes): Include those same headers.
159577         ($statxfs_includes): Include sys/vfs.h if available.
159578         ($statxfs_includes): Likewise for sys/statvfs.h.
159579         Check for the following members in both structs statfs and statvfs:
159580         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
159582 2002-06-01  Jim Meyering  <meyering@lucent.com>
159584         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
159585         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
159587 2002-05-28  Jim Meyering  <meyering@lucent.com>
159589         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
159590         Reported by Volker Borchert.
159592 2002-05-27  Jim Meyering  <meyering@lucent.com>
159594         Fix a problem seen only on nonconforming systems whereby ls.c's
159595         use of localtime, and then of gettimeofday would cause trouble:
159596         the localtime call used to initialize rpl_gettimeofday's save
159597         mechanism would clobber ls's current local time information so
159598         that in any long listing the first file would always be listed
159599         with date 1970-01-01.  Analysis by Volker Borchert.
159601         * lib/gettimeofday.c (localtime): Undefine.
159602         (rpl_localtime): New function.
159604 2002-05-27  Jim Meyering  <meyering@lucent.com>
159606         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
159607         localtime.
159609         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
159610         use the replacement function; it wouldn't resolve at link time.
159611         Reported by Volker Borchert.
159613 2002-05-22  Jim Meyering  <meyering@lucent.com>
159615         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
159616         file-type.h.
159617         * lib/file-type.h: New file.
159618         * lib/file-type.c (file_type): New file/function.  Extracted from
159619         diffutils.
159621 2002-04-30  Jim Meyering  <meyering@lucent.com>
159623         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
159625 2002-04-29  Paul Eggert  <eggert@twinsun.com>
159627         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
159629 2002-04-29  Paul Eggert  <eggert@twinsun.com>
159631         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
159632         Do not check for alloca.h (no longer used) or stdbool.h (was never
159633         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
159635 2002-04-29  Paul Eggert  <eggert@twinsun.com>
159637         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
159639 2002-04-29  Jim Meyering  <meyering@lucent.com>
159641         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
159642         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
159643         Use AC_FUNC_STRNLEN here instead.
159645         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
159646         With autoconf-2.53a, it's part of AC_PROG_CC.
159648 2002-04-28  Paul Eggert  <eggert@twinsun.com>
159650         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
159651         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
159653 2002-04-28  Paul Eggert  <eggert@twinsun.com>
159655         * lib/sig2str.h, lib/sig2str.c: New files.
159656         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
159658 2002-04-28  Paul Eggert  <eggert@twinsun.com>
159660         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
159661         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
159662         of 127, since 64 is the largest conceivable number for ancient
159663         nonstandard hosts.
159664         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
159666 2002-04-28  Jim Meyering  <meyering@lucent.com>
159668         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
159670 2002-04-24  Jim Meyering  <meyering@lucent.com>
159672         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
159673         (jm_PREREQ): Use it.
159675         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
159676         mach/mach.h fcntl.h.
159677         Check for this function: setlocale.
159679 2002-04-24  Jim Meyering  <meyering@lucent.com>
159681         * lib/gettext.h: New file, from Gettext.
159682         * lib/Makefile.am (INCLUDES): Remove -I../intl.
159683         (libfetish_a_SOURCES): Add gettext.h.
159685 2002-04-16  Jim Meyering  <meyering@lucent.com>
159687         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
159688         ut_pid, ut_id, ut_exit.
159690 2002-04-16  Jim Meyering  <meyering@lucent.com>
159692         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
159693         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
159694         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
159696 2002-04-12  Jim Meyering  <meyering@lucent.com>
159698         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
159699         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
159700         existence of the getmntinfo function.  Needed for Darwin 5.3.
159702         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
159703         This is necessary at least on Darwin 5.3.
159705         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
159706         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
159707         strnlen.o in the library, and that makes some versions of ranlib
159708         object.
159710 2002-04-12  Jim Meyering  <meyering@lucent.com>
159712         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
159714 2002-04-09  Jim Meyering  <meyering@lucent.com>
159716         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
159717         to be more precise.  Rather than saying we're checking whether the
159718         function `works', say what we're testing.
159719         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
159720         Reported by Bruno Haible.
159722 2002-03-10  Jim Meyering  <meyering@lucent.com>
159724         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
159725         Suggestion from Santiago Vila.
159727 2002-03-08  Jim Meyering  <meyering@lucent.com>
159729         * lib/rename.c: Mention that this wrapper is needed also on
159730         mips-dec-ultrix4.4 systems.
159732 2002-03-02  Jim Meyering  <meyering@lucent.com>
159734         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
159735         not HAVE_CLOCK_SETTIME.
159737 2002-02-27  Paul Eggert  <eggert@twinsun.com>
159739         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
159740         Check for clock_settime.
159742 2002-02-27  Paul Eggert  <eggert@twinsun.com>
159744         * lib/nanosleep.h: Rename to....
159745         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
159747         * lib/gettime.c: New file.
159748         * lib/settime.c: New file.
159749         * lib/stime.c: Remove.
159751         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
159752         timespec.h.  Remove nanosleep.h.
159754 2002-02-25  Paul Eggert  <eggert@twinsun.com>
159756         * m4/acl.m4: New file.
159757         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
159758         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
159760 2002-02-25  Paul Eggert  <eggert@twinsun.com>
159762         * lib/acl.c, lib/acl.h: New files.
159763         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
159765 2002-02-24  Jim Meyering  <meyering@lucent.com>
159767         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
159768         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
159769         cause trouble.  Reported by Nelson Beebe.
159771 2002-02-23  Paul Eggert  <eggert@twinsun.com>
159773         * lib/path-concat.c (xpath_concat): Reorder code to pacify
159774         compilers that don't know that xalloc_die never returns.
159776 2002-02-20  Jim Meyering  <meyering@lucent.com>
159778         * lib/getdate.c: Regenerate using bison-1.33.
159780 2002-02-17  Jim Meyering  <meyering@lucent.com>
159782         * config/config.guess (main): Don't use `head -1'; it's no longer
159783         portable. Use `sed 1q' instead.
159785 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
159787         * m4/codeset.m4: Upgrade to gettext-0.11.
159788         * m4/gettext.m4: Upgrade to gettext-0.11.
159789         * m4/glibc21.m4: Upgrade to gettext-0.11.
159790         * m4/iconv.m4: Upgrade to gettext-0.11.
159791         * m4/isc-posix.m4: Upgrade to gettext-0.11.
159792         * m4/lcmessage.m4: Upgrade to gettext-0.11.
159793         * m4/lib-ld.m4: New file, from gettext-0.11.
159794         * m4/lib-link.m4: New file, from gettext-0.11.
159795         * m4/lib-prefix.m4: New file, from gettext-0.11.
159796         * m4/progtest.m4: Upgrade to gettext-0.11.
159798 2002-02-15  Paul Eggert  <eggert@twinsun.com>
159800         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
159801         (jm_PREREQ): Use it.
159803 2002-02-15  Paul Eggert  <eggert@twinsun.com>
159805         * lib/posixver.c, lib/posixver.h: New files.
159806         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
159808 2002-02-02  Paul Eggert  <eggert@twinsun.com>
159809             Bruno Haible  <bruno@clisp.org>
159811         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
159812         (fwrite_success_callback): New declaration.
159813         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
159814         print_unicode_char. Call failure callback instead of error.
159815         (fwrite_success_callback): New function.
159816         (exit_failure_callback): New function.
159817         (fallback_failure_callback): New function.
159818         (print_unicode_char): Call unicode_to_mb.
159820 2002-01-26  Jim Meyering  <meyering@lucent.com>
159822         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
159823         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
159825 2002-01-26  Jim Meyering  <meyering@lucent.com>
159827         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
159829 2002-01-22  Paul Eggert  <eggert@twinsun.com>
159831         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
159833 2002-01-22  Jim Meyering  <meyering@lucent.com>
159835         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
159836         Otherwise, some versions of automake would omit the rule that makes
159837         Makefile from Makefile.in.
159839 2002-01-21  Paul Eggert  <eggert@twinsun.com>
159841         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
159842         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
159843         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
159844         (memcoll): Set errno to zero if there is no error.
159846         * lib/quotearg.c (quotearg_buffer_restyled):
159847         Fix bug with quoting buffers containing NUL when backslashing escapes.
159848         This bug was exposed by the other changes in this patch.
159849         (quotearg_n_options): New arg ARGSIZE.
159850         All callers changed.
159851         (quoting_options_from_style): New function.
159852         (quotearg_n_style): Use it.
159853         (quotearg_n_style_mem): New function.
159855         * lib/quotearg.h (quotearg_n_style_mem): New function.
159857 2002-01-19  Jim Meyering  <meyering@lucent.com>
159859         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
159860         Remove useless quotes: DF_PROG="df".
159861         * m4/strnlen.m4: New file.
159863 2002-01-16  Paul Eggert  <eggert@twinsun.com>
159865         * lib/backupfile.c (ISDIGIT): Comment fix.
159866         * lib/getdate.y (ISDIGIT): Likewise.
159867         * lib/posixtm.c (ISDIGIT, year): Likewise.
159868         * lib/strverscmp.c (ISDIGIT): Likewise.
159869         * lib/userspec.c (ISDIGIT): Likewise.
159871 2002-01-16  Jim Meyering  <meyering@lucent.com>
159873         * lib/getdate.y: Add three semicolons, each just before a closing
159874         brace. Bison (as of version 1.31) no longer papers over that mistake.
159876 2002-01-05  Jim Meyering  <meyering@lucent.com>
159878         * lib/version-etc.c (version_etc_copyright): Update copyright year.
159880 2001-12-19  Paul Eggert  <eggert@twinsun.com>
159882         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
159883         not silently exit merely because the output buffer happens to
159884         have nothing pending.
159886 2001-12-18  Paul Eggert  <eggert@twinsun.com>
159888         See the big note in ../ChangeLog.
159889         * lib/human.c (suffixes): Prefer K to k for 1024.
159890         (generate_suffix_backwards): New function.
159891         (human_readable_inexact): Use it.
159892         * lib/xstrtol.c (__xstrtol): If there is no number but there
159893         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
159894         Accept 'K' as well as 'k'.
159896 2001-12-15  Jim Meyering  <meyering@lucent.com>
159898         * lib/regex.h (__restrict_arr): Update from libc.
159900         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
159901         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
159902         (STREQ): Define.
159904 2001-12-14  Jim Meyering  <meyering@lucent.com>
159906         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
159907         Suggestion from Bruno Haible.
159909 2001-12-10  Jim Meyering  <meyering@lucent.com>
159911         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
159912         xrealloc, Instead, include "xalloc.h".
159913         (initbuffer): Don't cast xmalloc return value to char*.
159914         (readline): Reword comment.
159915         Don't cast xrealloc return value to char*
159916         Return NULL, not 0.
159918 2001-12-09  Jim Meyering  <meyering@lucent.com>
159920         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
159921         about `signed and unsigned type in conditional expression'.
159922         * lib/posixtm.c (posix_time_parse): Likewise.
159924         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
159926         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
159927         to avoid a pedantic warning.
159929         * lib/getstr.c: Don't include assert.h.
159930         (getstr): Remove warning-evoking assertions.
159931         Return -1 if offset parameter is out of bounds.
159932         Change the type of a local from int to size_t.
159934         * lib/strftime.c (my_strftime_localtime_r): Include this function
159935         definition in the `#if ! HAVE_TM_GMTOFF' block.
159937         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
159938         Include xalloc.h instead.
159940 2001-12-02  Jim Meyering  <meyering@lucent.com>
159942         * lib/tempname.c: Don't declare getenv, thus reverting the change of
159943         2001-11-18.  It's no longer necessary, now that stdlib.h is always
159944         included.
159946         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
159947         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
159949 2001-11-30  Akim Demaille  <akim@epita.fr>
159951         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
159952         before being defined.
159954 2001-11-27  Paul Eggert  <eggert@twinsun.com>
159956         * lib/quotearg.h (quotearg_n, quotearg_n_style):
159957         First arg is int, not unsigned.
159958         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
159959         (SIZE_MAX, UINT_MAX): New macros.
159960         (quotearg_n_options): Abort if N is negative.
159961         Avoid overflow check on hosts where size_t is 64 bits and int
159962         is 32 bits, as overflow is impossible there.
159963         Fix off-by-one typo that caused unnecessary reallocation.
159965 2001-11-27  Jim Meyering  <meyering@lucent.com>
159967         * lib/tempname.c: Merge with version from libc.
159968         * lib/regex.c: Likewise.
159970         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
159971         systems for which STDC_HEADERS is 0, it was not included, resulting in
159972         a warning about an integer-to-pointer conversion problem with getenv.
159973         Reported by Volker Borchert.
159975 2001-11-26  Jim Meyering  <meyering@lucent.com>
159977         * lib/gtod.h: Remove file.
159978         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
159979         * lib/gettimeofday.c: Don't include gtod.h.
159980         (GTOD_init): Remove function.
159981         (rpl_gettimeofday): Do its job here instead, rather than aborting.
159982         Suggestion from Volker Borchert.
159984 2001-11-23  Jim Meyering  <meyering@lucent.com>
159986         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
159987         it.
159988         * lib/hash.c (struct hash_table): Define it here instead.
159990 2001-11-22  Jim Meyering  <meyering@lucent.com>
159992         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
159994 2001-11-20  Jim Meyering  <meyering@lucent.com>
159996         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
159997         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
159999 2001-11-19  Jim Meyering  <meyering@lucent.com>
160001         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
160002         directory.  Use "conftestXXXXXX" as the template.
160003         Suggestion from Paul Eggert.
160005         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
160006         immediately, so the test doesn't mistakenly hit the max-open-files
160007         limit.
160009 2001-11-18  Paul Eggert  <eggert@twinsun.com>
160011         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
160012         (TEMPORARIES): New macro.
160013         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
160014         removes an artificial limitation (e.g. HP-UX 10.20, where
160015         TMP_MAX is 17576).
160017 2001-11-18  Jim Meyering  <meyering@lucent.com>
160019         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
160021 2001-11-18  Jim Meyering  <meyering@lucent.com>
160023         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
160024         on SunOS 4.
160026         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
160027         files will be created before anything else.
160029 2001-11-17  Paul Eggert  <eggert@twinsun.com>
160031         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
160032         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
160034 2001-11-17  Jim Meyering  <meyering@lucent.com>
160036         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
160037         Prompted by a report from Bob Proulx.
160039         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
160040         Instead, require UTILS_FUNC_MKSTEMP.
160042 2001-11-17  Jim Meyering  <meyering@lucent.com>
160044         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
160045         Now, that's done as part of AC_FUNC_STRTOD.
160047 2001-11-17  Jim Meyering  <meyering@lucent.com>
160049         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
160050         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
160051         rather than group writable.  Patch by Juan F. Codagnone.
160053         * lib/readtokens.c: Remove explicit declarations of xmalloc and
160054         xrealloc, Instead, include "xalloc.h".
160056         * lib/mountlist.c: Include unlocked-io.h after all system headers.
160057         Remove explicit declarations of xmalloc, xrealloc,
160058         and xstrdup.  Instead, include "xalloc.h".
160060         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
160061         unlocked-io.h.
160062         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
160063         Likewise.
160064         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
160066         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
160067         Reported by Padraig Brady.
160069         * lib/mkstemp.c: #undef mkstemp.
160070         Include config.h.
160071         (rpl_mkstemp): Rename from mkstemp.
160072         Protoize.
160074 2001-11-16  Jim Meyering  <meyering@lucent.com>
160076         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
160077         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
160078         determine the amount of total physical memory, use pstat_getstatic.
160079         HPUX-11 doesn't define _SC_PHYS_PAGES.
160080         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
160081         If sysconf couldn't be used to determine the amount of available
160082         physical memory, use both pstat_getstatic and pstat_getdynamic.
160083         Based on a patch from Bob Proulx.
160085 2001-11-10  Jim Meyering  <meyering@lucent.com>
160087         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
160088         (jm_PREREQ): Use it.
160090 2001-11-09  Jim Meyering  <meyering@lucent.com>
160092         * m4/jm-macros.m4: Require autoconf-2.52f.
160093         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
160094         Use these AC_-prefixed names, not the AM_-prefixed ones.
160096         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
160098 2001-11-05  Jim Meyering  <meyering@lucent.com>
160100         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
160102 2001-11-04  Jim Meyering  <meyering@lucent.com>
160104         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
160105         $DEFS.
160107 2001-11-03  Jim Meyering  <meyering@lucent.com>
160109         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
160110         of AC_DEFUN.
160112         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
160113         know the name of the variable in the macro definition.
160115 2001-11-03  Jim Meyering  <meyering@lucent.com>
160117         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
160118         in argmatch_to_argument call.
160120         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
160121         argument.
160123         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
160124         e.g., a fault due to an attempt to free a NULL pointer.
160126 2001-11-01  Jim Meyering  <meyering@lucent.com>
160128         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
160129         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
160131 2001-11-01  Jim Meyering  <meyering@lucent.com>
160133         * lib/dirfd.c, lib/dirfd.h: New files.
160134         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
160136         * lib/hash.c (hash_print) [TESTING]: Clean up.
160138 2001-10-22  Paul Eggert  <eggert@twinsun.com>
160140         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
160141         to avoid a warning if -Wall.
160143 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
160145         * README: New file
160146         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
160147         (per RMS's instructions, this is now the canonical source)
160148         * lgpl/, gpl/: New directories.
160150 2001-10-21  Paul Eggert  <eggert@twinsun.com>
160152         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
160154 2001-10-21  Jim Meyering  <meyering@lucent.com>
160156         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
160157         this code would end up calling gettext even in packages built
160158         with --disable-nls.
160159         * lib/getopt.c (_): Likewise.
160160         * lib/regex.c (_): Likewise.
160162 2001-10-20  Paul Eggert  <eggert@twinsun.com>
160164         * m4/error.m4 (jm_PREREQ_ERROR):
160165         Do not invoke AC_CHECK_FUNCS with strerror_r, as
160166         AC_FUNC_STRERROR_R does that.
160167         Check for strerror declaration.
160169         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
160170         are supposed to have them these days.
160171         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
160172         Merge changes from latest Autoconf CVS.
160173         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
160174         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
160175         POSIX decided to standardize on the int flavor of strerror_r.
160177 2001-10-20  Paul Eggert  <eggert@twinsun.com>
160179         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
160180         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
160181         Use strerror_r that is only a macro, even if it is not a function.
160182         (strerror): Check for HAVE_DECL_STRERROR before declaring.
160183         (private_strerror): Use prototypes, not old-style function definition.
160184         (print_errno_message): New function.
160185         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
160186         char*-flavored one.
160187         (error_tail, error, error_at_line): Use it.
160189 2001-10-11  Jim Meyering  <meyering@lucent.com>
160191         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
160192         and quote_n (1, ... to avoid clobbering a buffer.
160194 2001-10-05  Jim Meyering  <meyering@lucent.com>
160196         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
160197         hash-pjw.h.
160198         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
160199         * lib/hash-pjw.h: New file.
160201 2001-09-30  Jim Meyering  <meyering@lucent.com>
160203         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
160204         `struct fsstat' has the `f_fstypename' member.
160205         Use that to define FS_TYPE, which is now used to make
160206         the getfsstat link test tighter.
160208 2001-09-30  Jim Meyering  <meyering@lucent.com>
160210         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
160211         Include <sys/ucred.h>, for Apple Darwin.
160212         Include sys/mount.h and sys/fs_types.h only if available.
160213         (FS_TYPE): Define.
160214         (read_filesystem_list): Use FS_TYPE.
160216 2001-09-29  Paul Eggert  <eggert@twinsun.com>
160218         * lib/exclude.c (excluded_filename): 0 -> false, since it's
160219         a boolean context.
160221 2001-09-29  Jim Meyering  <meyering@lucent.com>
160223         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
160224         [one-argument getmntent function]): Include stdio.h before mntent.h.
160225         SunOS 4.1.x needs it for the declaration of `FILE'.
160226         Patch by Volker Borchert.
160228         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
160229         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
160230         sys/fs_types.h, and make the link-test for getfsstat guard #include
160231         directives with appropriate #if HAVE_*_H tests so that we can
160232         detect getfsstat on Apple Darwin1.3.7 systems.
160233         Reported by Nelson Beebe.
160234         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
160236 2001-09-28  Paul Eggert  <eggert@twinsun.com>
160238         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
160239         #defines strtoimax.  Also treat the other strto* functions
160240         like strtoimax.
160242         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
160243         Check for strtoul and strtoumax,
160244         as those declarations are made even in the signed case.
160245         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
160246         Likewise, for strtol and strtoimax.
160248 2001-09-28  Paul Eggert  <eggert@twinsun.com>
160250         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
160251         #defines strtoimax.  Also treat the other strto* functions
160252         like strtoimax.
160254         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
160255         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
160256         (strtoimax, strtoumax): Do not declare if already defined as a macro.
160258 2001-09-26  Jim Meyering  <meyering@lucent.com>
160260         Most macros in unlocked-io.h had the wrong number of arguments.
160261         * lib/gen-uio: New script.
160262         (USE_UNLOCKED_IO): Define to 1 if not already defined.
160263         * lib/unlocked-io.hin: Remove file.
160264         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
160265         rather than trying to embed it here.
160266         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
160267         Reported by Padraig Brady.
160269 2001-09-25  Volker Borchert  <bt@teknon.de>
160271         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
160272         `result'.
160274 2001-09-24  Jim Meyering  <meyering@lucent.com>
160276         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
160278 2001-09-23  Jim Meyering  <meyering@lucent.com>
160280         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
160281         instead of the mere test for existence of mntent.h.  The latter
160282         would get a false-positive on AIX 3.4 systems.
160283         In the outer getmntent if-block, don't die if neither of the getmntent
160284         tests succeeds.  Instead, just fall through and continue with the
160285         remaining tests.
160287 2001-09-23  Jim Meyering  <meyering@lucent.com>
160289         * lib/mountlist.c: Remove useless parentheses in #if directives.
160290         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
160291         the deprecated MOUNTED symbol is no longer defined in mntent.h.
160293 2001-09-22  Jim Meyering  <meyering@lucent.com>
160295         * m4/gettext.m4: New file.  From gettext.
160296         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
160297         * m4/progtest.m4: Likewise
160298         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
160299         * m4/glibc21.m4: Likewise.
160301         * m4/libintl.m4: Remove.  No longer used.
160303 2001-09-22  Jim Meyering  <meyering@lucent.com>
160305         * lib/localcharset.c: Update from latest gettext.
160306         * lib/config.charset: Likewise.
160308 2001-09-20  Jim Meyering  <meyering@lucent.com>
160310         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
160311         strtoimax.
160312         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
160313         strtoumax.
160315 2001-09-20  Jim Meyering  <meyering@lucent.com>
160317         * lib/xstrtol.c (strtoimax): Guard declaration with
160318         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
160319         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
160320         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
160321         (strtoumax): Likewise, for completeness (it wasn't necessary).
160323 2001-09-17  Paul Eggert  <eggert@twinsun.com>
160325         * lib/strtoimax.c (HAVE_LONG_LONG):
160326         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
160327         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
160328         to work around bug in IBM C compiler.
160330 2001-09-17  Jim Meyering  <meyering@lucent.com>
160332         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
160333         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
160334         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
160335         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
160336         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
160337         whenever the right hand side need not be expanded by the shell.
160339 2001-09-16  Paul Eggert  <eggert@twinsun.com>
160341         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
160342         library.  It's not correct, as some older glibcs are buggy.
160343         fnmatch wasn't fixed until glibc 2.2.
160345         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
160346         special shell magic here.
160348 2001-09-16  Jim Meyering  <meyering@lucent.com>
160350         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
160351         * m4/jm-macros.m4: Require it.
160353 2001-09-16  Jim Meyering  <meyering@lucent.com>
160355         * lib/mkdir.c: New file.
160357 2001-09-15  Jim Meyering  <meyering@lucent.com>
160359         * m4/jm-macros.m4: Check for help2man.
160361 2001-09-11  Jim Meyering  <meyering@lucent.com>
160363         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
160364         The body, by Paul Eggert, was moved here from configure.in.
160365         * m4/jm-macros.m4: Require UTILS_HOST_OS.
160367 2001-09-04  Paul Eggert  <eggert@twinsun.com>
160369         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
160370         (jm_PREREQ): Use it.
160372 2001-09-04  Paul Eggert  <eggert@twinsun.com>
160374         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
160375         Use ssize_t, not int, to store result of readlink.
160376         Check for ssize_t overflow as well as size_t overflow,
160377         as POSIX says the result of readlink is implementation-defined
160378         when ssize_t overflows.
160379         Remove unnecessary cast to char*.
160380         Use free+malloc instead of realloc, as the storage doesn't need
160381         to be preserved and it's clearer and can be more efficient that way.
160382         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
160383         * lib/xreadlink.h (xreadlink): Update prototype.
160385 2001-09-04  Paul Eggert  <eggert@twinsun.com>
160387         * lib/xgetcwd.c: Revert some of the previous change; intead,
160388         fix the HAVE_GETCWD_NULL code to behave more like the
160389         !HAVE_GETCWD_NULL code used to.
160391         Include "xalloc.h".
160392         (xgetcwd): Do not return NULL when memory is exhausted; instead,
160393         invoke xalloc_die.
160395 2001-09-03  Paul Eggert  <eggert@twinsun.com>
160397         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
160398         sys/param.h, as pathmax.h includes them.
160400 2001-09-03  Paul Eggert  <eggert@twinsun.com>
160402         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
160403         (jm_PREREQ_XGETCWD): New macro.
160405         * m4/getcwd.m4: New file.
160407 2001-09-03  Paul Eggert  <eggert@twinsun.com>
160409         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
160410         like the HAVE_GETCWD_NULL code.
160411         Include pathmax.h if not HAVE_GETCWD.
160412         Do not include xalloc.h.
160413         (INITIAL_BUFFER_SIZE): New symbol.
160414         Do not use xmalloc / xrealloc, since the caller is responsible for
160415         handling errors.  Preserve errno around `free' during failure.
160416         Do not overrun buffer when using getwd.
160418 2001-09-03  Paul Eggert  <eggert@twinsun.com>
160420         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
160421         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
160422         getcwd (NULL, 0).
160424 2001-09-03  Paul Eggert  <eggert@twinsun.com>
160426         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
160427         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
160428         spotted by Jim Meyering.
160430 2001-09-03  Jim Meyering  <meyering@lucent.com>
160432         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
160433         failure.
160435 2001-09-02  Jim Meyering  <meyering@lucent.com>
160437         * lib/error.c: Update from GNU libc.
160439 2001-09-01  Jim Meyering  <meyering@lucent.com>
160441         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
160442         Used by df.
160444 2001-09-01  Jim Meyering  <meyering@lucent.com>
160446         * lib/xreadlink.c: New file.
160447         * lib/xreadlink.h: New file.
160448         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
160449         xreadlink.h.
160451         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
160452         doesn't conflict with sparc Solaris 7's definition in
160453         /usr/include/sys/int_types.h.
160455         * lib/exclude.c: Use `""', not `<>' to #include non-system header
160456         files.
160457         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
160458         and strncasecmp as r-values.  Unixware didn't have declarations.
160460 2001-08-31  Paul Eggert  <eggert@twinsun.com>
160462         * lib/xstrtol.h: Add copyright notice.
160463         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
160464         LONGINT_INVALID_SUFFIX_CHAR.
160466 2001-08-31  Paul Eggert  <eggert@twinsun.com>
160468         * lib/xstrtol.c (strtoimax): New decl.
160470 2001-08-31  Paul Eggert  <eggert@twinsun.com>
160472         * lib/xgetcwd.c: Don't include pathmax.h.
160473         Include stdlib.h and unistd.h if available.
160474         Include xalloc.h.
160475         (xmalloc, xstrdup, free): Remove decls.
160476         (xgetcwd): Don't assume sizes fit in unsigned.
160477         Check for overflow when computing sizes.
160478         Simplify reallocation code.
160480 2001-08-31  Paul Eggert  <eggert@twinsun.com>
160482         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
160483         a directory's st_size can have an arbitrary value, so the old
160484         usage could waste an arbitrary amount of memory.  All uses
160485         changed.
160486         * lib/savedir.h: Update prototype.
160488 2001-08-31  Paul Eggert  <eggert@twinsun.com>
160490         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
160492         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
160493         old strtoimax.c.
160495         Also, make the following further changes to make this file's
160496         configuration more similar to that of strtol.c:
160497         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
160498         (strtoumax, uintmax_t, strtoull, strtol): Remove.
160499         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
160500         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
160501         changed to signed values.
160503         And make the following changes as well:
160504         Fix copyright notice, as 1999 was missing.
160505         (verify): New macro.
160506         (strtoimax): Check sizes at compile-time, not run-time.
160507         Prefer strtol to strtoll if both work.
160508         (main): Remove; it was not that useful and was a pain to maintain.
160510         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
160512 2001-08-31  Jim Meyering  <meyering@lucent.com>
160514         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
160515         Use an initial, malloc'd, buffer of length 128 rather than
160516         a statically allocated one of length 1024.
160518 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160520         Simplify code, partly by assuming autoconf 2.52 semantics.
160522         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
160524         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
160525         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
160526         All uses removed.
160527         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
160528         Move AC_REQUIRE to next-to-top level, to avoid confusion.
160529         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
160530         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
160531         jm_AC_HEADER_INTTYPES_H.
160532         * m4/jm-macros.m4 (jm_MACROS): Likewise.
160534         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
160536         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
160537         Quote first arg of AC_DEFUN.
160538         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
160539         since they are needed to parse the include file even if we need
160540         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
160541         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
160542         but with opposite signedness.
160544 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160546         Merge 'exclude' changes from tar 1.13.22.
160547         This fixes one or two unlikely storage allocation overflow bugs,
160548         but doesn't change user-visible behavior otherwise.
160550 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160552         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
160553         (jm_PREREQ_EXCLUDE): New macro.
160555 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160557         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
160558         tm to be declared.
160560 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160562         * lib/hash.c: Remove '2001' from copyright notice.
160564 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160566         * lib/full-write.h: New file.
160567         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
160568         * lib/full-write.c: Correct credits, as cccp.c no longer
160569         exists and anyway it was so heavily changed from the old cccp
160570         code as to be unrecognizable.  Include full-write.h.
160571         (full_write): Return size_t, with short writes meaning failure.
160572         All callers changed.  This fixes a bug with large buffers
160573         on 64-bit hosts.
160574         * lib/utime.c: Include full-write.h.
160576 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160578         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
160579         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
160580         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
160581         Include if available.
160582         (<xalloc.h>): Include
160583         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
160584         (verify): New macro.  Use it to verify that EXCLUDE macros do not
160585         collide with FNM macros.
160586         (struct patopts): New struct.
160587         (struct exclude): Use it, as exclude patterns now come with options.
160588         (new_exclude): Support above changes.
160589         (new_exclude, add_exclude_file):
160590         Initial size must now be a power of two to simplify overflow checking.
160591         (free_exclude, fnmatch_no_wildcards): New function.
160592         (excluded_filename): No longer requires options arg, as the options
160593         are determined by add_exclude.  Now returns bool, not int.
160594         (excluded_filename, add_exclude):
160595         Add support for the fancy new exclusion options.
160596         (add_exclude, add_exclude_file): Now takes int options arg.
160597         Check for arithmetic overflow when computing sizes.
160598         (add_exclude_file): xrealloc might modify errno, so don't
160599         realloc until after errno might be used.
160601         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
160602         New macros.
160603         (free_exclude): New decl.
160604         (add_exclude, add_exclude_file): Now takes int options arg.
160605         (excluded_filename): No longer requires options arg, as the options
160606         are determined by add_exclude.  Now returns bool, not int.
160608 2001-08-30  Paul Eggert  <eggert@twinsun.com>
160610         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
160612 2001-08-27  Jim Meyering  <meyering@lucent.com>
160614         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
160616         * lib/version-etc.c (N_): Remove definition.
160617         Revert most of last change.
160618         Instead, simply don't mark the `Copyright...' string for translation.
160619         Based on advice from Paul Eggert.
160621         * lib/strtoxmax.c: Tweak comment.
160623 2001-08-26  Jim Meyering  <meyering@lucent.com>
160625         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
160627         * m4/xstrtoimax.m4: New file.
160628         * m4/xstrtoumax.m4: Add comments explaining why we
160629         AC_REPLACE_FUNCS(strtol).
160631 2001-08-26  Jim Meyering  <meyering@lucent.com>
160633         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
160634         of copyright with `%s' so translators don't get an untranslated
160635         message in 2002.
160636         (COPYRIGHT_YEAR): Define.
160637         (version_etc): Use fprintf rather than fputs.
160638         Suggestion from Ulrich Drepper.
160640         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
160642         * lib/strtoll.c: New file, from GNU libc.
160643         * lib/xstrtoimax.c: New file.
160645         * lib/xstrtol.h: Add xstrtoimax.
160646         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
160647         * lib/strtoimax.c: New file.  Likewise, but first define
160648         STRTOUXMAX_SIGNED.
160650         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
160651         ...
160652         * lib/strtoxmax.c: ... then renamed to this.
160654 2001-08-18  Paul Eggert  <eggert@twinsun.com>
160656         * m4/inttypes.m4: Add AC_PREREQ(2.13).
160657         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
160658         (jm_AC_TYPE_INTMAX_T): New macro.
160659         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
160661         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
160663         * m4/longlong.m4: Renamed from ulonglong.m4.
160664         * m4/inttypes.m4: Renamed from inttypes_h.m4.
160665         * m4/uintmax_t.m4: Removed.
160667 2001-08-13  Paul Eggert  <eggert@twinsun.com>
160669         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
160670         Port to Solaris 8, where 'sed' requires a space after the 'r'
160671         command, and where sh dislikes "$/".  Clean up the spacing a bit.
160672         Redirect output to $tmp just once.
160674 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
160676         * lib/addext.c (<errno.h>): Include.
160677         (errno): Declare if not defined.
160678         (addext): Work correctly when pathconf returns -1 and leaves
160679         errno alone because there is no limit.  Also, work even if
160680         pathconf returns a value greater than SIZE_MAX.
160682 2001-08-12  Jim Meyering  <meyering@lucent.com>
160684         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
160685         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
160686         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
160687         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
160688         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
160689         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
160690         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
160691         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
160692         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
160693         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
160694         utime.m4, utimes.m4, xstrtoumax.m4:
160695         Quote the first argument in each use of AC_DEFUN.
160697 2001-08-12  Jim Meyering  <meyering@lucent.com>
160699         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
160700         Simply `return getcwd (NULL, 0);'.
160701         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
160702         Use 1300 as initial value for length, not PATH_MAX.
160704         * lib/pathmax.h: Clean up cpp syntax.
160706 2001-08-12  Jim Meyering  <meyering@lucent.com>
160708         * lib/gettimeofday.c: New file.
160709         * lib/gtod.h: New file.
160710         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
160712 2001-08-05  Jim Meyering  <meyering@lucent.com>
160714         * m4/jm-macros.m4: Require autoconf-2.52.
160716 2001-08-04  Jim Meyering  <meyering@lucent.com>
160718         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
160719         stmt, to get in sync with glibc.
160721 2001-08-03  Paul Eggert  <eggert@twinsun.com>
160723         The following changes are from gettext 0.10.39 as maintained by
160724         Bruno Haible.
160726         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
160727         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
160728         with inverted sense.  All uses changed.
160730         * lib/mbswidth.c: Don't include <limits.h>.
160731         Include <stdlib.h> and <string.h> unconditionally.
160732         (iswcntrl, mbsinit, ISCNTRL): New macros.
160733         (mbsnwidth): Use K&R style function declarations.
160734         Don't bother checking for MB_LEN_MAX == 1, since the compiler
160735         can optimize it when MB_CUR_MAX == 1.
160736         The width of control characters is zero, not 1.
160738 2001-08-03  Paul Eggert  <eggert@twinsun.com>
160740         The following changes are from gettext 0.10.39 as maintained by
160741         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
160743         * m4/codeset.m4: Upgrade to serial AM1.
160744         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
160745         all uses changed.  Quote first arg of AC_DEFUN.
160746         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
160748         * m4/iconv.m4: Upgrade to serial AM2.
160749         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
160750         Add --with-libconv-prefix.
160751         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
160752         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
160753         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
160754         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
160755         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
160757         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
160758         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
160759         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
160760         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
160761         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
160762         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
160763         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
160764         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
160765         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
160767         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
160768         string.h any more.
160770         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
160771         not the default value.
160773         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
160774         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
160775         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
160776         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
160777         Also check for iswcntrl, used for wcwidth fallback.
160778         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
160779         to Autoconf 2.13.
160781 2001-08-03  Jim Meyering  <meyering@lucent.com>
160783         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
160784         as it was in the original.  Reported by Paul Eggert.
160786 2001-07-16  Jim Meyering  <meyering@lucent.com>
160788         * m4/gettimeofday.m4: New file.
160789         Prompted by a report from Bernhard Baehr.
160791 2001-07-15  Jim Meyering  <meyering@lucent.com>
160793         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
160794         stuff. Now it's in ../Makefile.cfg.
160796 2001-07-15  Jim Meyering  <meyering@lucent.com>
160798         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
160799         (BUILT_SOURCES): Add unlocked-io.h.
160800         (io_functions): Define.
160801         (unlocked-io.h): New rule.
160802         (DISTCLEANFILES): Add unlocked-io.h.
160803         (all-local): Depend on unlocked-io.h, to ensure it is created.
160805         * lib/unlocked-io.hin: New file
160807         * lib/regex.c: Update from glibc.
160809 2001-07-05  Jim Meyering  <meyering@lucent.com>
160811         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
160812         recommendation.
160813         (libfetish_a_SOURCES): Put all .h files here instead.
160814         Remove a thus-exposed (better checks in automake) duplicate and
160815         two unnecessary .h files.
160817 2001-07-04  Jim Meyering  <meyering@lucent.com>
160819         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
160820         that generates jm-glibc-io.m4 so that it doesn't trigger any make
160821         distcheck failure.
160823 2001-07-02  Jim Meyering  <meyering@lucent.com>
160825         The following changes were prompted by suggestions from Bruno Haible.
160827         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
160828         is now generated.
160829         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
160830         definition of EXTRA_DIST.
160831         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
160832         ensure that the generated file is created/updated whenever the list
160833         of $(unlocked_functions) is changed.
160834         (jm-glibc-io.m4): New rule.
160835         (unlocked-io.h): New rule -- currently unused.
160837 2001-06-24  Jim Meyering  <meyering@lucent.com>
160839         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
160840         unmatched right bracket, rather than kludging it with an extra,
160841         falsely-matching quote in a comment.  Patch by Akim Demaille.
160843 2001-06-11  Jim Meyering  <meyering@lucent.com>
160845         * lib/regex.c: Update from GNU libc.
160847 2001-05-27  Jim Meyering  <meyering@lucent.com>
160849         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
160850         Check for ut_type in struct utmp.
160852 2001-05-27  Jim Meyering  <meyering@lucent.com>
160854         * lib/readutmp.h (UT_TYPE): Define.
160856 2001-05-24  Jim Meyering  <meyering@lucent.com>
160858         * lib/argmatch.c: Include "quote.h".
160859         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
160860         quote function.  Reported by Göran Uddeborg.
160862 2001-05-22  Jim Meyering  <meyering@lucent.com>
160864         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
160865         now that we use the package-supplied version unconditionally.
160866         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
160868 2001-05-21  Jim Meyering  <meyering@lucent.com>
160870         * m4/regex.m4: Change a couple backticks to single quotes to avoid
160871         shell syntax errors.
160873 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
160875         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
160877 2001-05-20  Paul Eggert  <eggert@twinsun.com>
160879         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
160880         Don't bother to check library strftime, since
160881         we'll be using our own my_strftime function anyway.
160882         Define my_strftime instead of strftime.
160884 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
160886         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
160887         which is not yet declared.
160889 2001-05-15  Jim Meyering  <meyering@lucent.com>
160891         * m4/regex.m4: Use proper quoting so brackets appear in the test
160892         program.
160893         Reported by, and with help from, Bruno Haible.
160895 2001-05-13  Jim Meyering  <meyering@lucent.com>
160897         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
160898         undefined.
160900 2001-05-11  Paul Eggert  <eggert@twinsun.com>
160902         dirname code cleanup.  base_name now behaves more compatibly
160903         with POSIX basename when given file names that have trailing
160904         slashes, and similarly for dir_name.  Add new primitives
160905         base_len and dir_len.  Put the directory-name-related decls
160906         into dirname.h.
160908         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
160909         * lib/backupfile.c (base_name): Likewise.
160910         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
160911         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
160912         * lib/makepath.c (strip_trailing_slashes): Likewise.
160913         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
160914         ISSLASH): Likewise.
160915         * lib/rename.c (strip_trailing_slashes): Likewise.
160916         * lib/same.c (base_name): Likewise.
160917         * lib/stripslash.c (ISSLASH): Likewise.
160919         * lib/addext.c: Include <dirname.h> after size_t is defined.
160920         * lib/backupfile.c: Likewise.
160922         * lib/addext.c (addext): Use base_len to trim redundant
160923         trailing slashes instead of doing it ourselves.
160924         But do not trim the last slash if it is not redundant.
160926         * lib/backupfile.c (find_backup_file_name,
160927         max_backup_version): Use base_len instead of rolling it ourselves.
160928         Handle the case of "" and (on DOS) "C:" correctly.
160930         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
160931         needed. Include <string.h>, <dirname.h>.
160932         (base_name): Allow file names ending in slashes, other than names
160933         that are all slashes.  In this case, return the basename followed
160934         by the slashes.  This is more general, and can be used in places
160935         where the original base_name purposely had an assertion failure.
160936         (base_len): New function.
160938         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
160939         Do not include <assert.h>; no longer needed.
160940         Include xalloc.h.
160941         (memrchr): Remove decl.
160942         (dir_name_r): Remove.
160943         (dir_len): Renamed from dirlen.  All callers changed.
160944         Rewrite in terms of base_name, for simplicity and consistency.
160945         (dir_name): Never return NULL.  All callers changed.
160946         Do not include <stdlib.h> in test program; no longer needed.
160947         return 0; is fine for test program.
160949         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
160950         New macros.
160951         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
160953         * lib/path-concat.c (path_concat): Use base_len to compute
160954         base length, not strlen; this means we cannot rely on memcpy
160955         to null-terminate.
160957         * lib/same.c (STREQ): Remove.
160958         (same_name): Handle the case where the basename ends in trailing '/'.
160960         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
160961         a slash was stripped.  Do not strip the last slash after a
160962         file system prefix.
160964 2001-05-11  Paul Eggert  <eggert@twinsun.com>
160966         * lib/Makefile.am (libfetish_a_SOURCES):
160967         Add strftime.c, since we now compile it on all hosts.
160969         * lib/strftime.c (my_strftime):
160970         Define to nstrftime if emacs, but only if my_strftime is not defined.
160971         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
160972         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
160973         Add one more extra argument: a nanoseconds value.
160974         All uses changed.
160975         (ns): New macro.
160976         (my_strftime function): Add %N format.
160977         (emacs_strftimeu): Renamed from emacs_strftime,
160978         with extra ut argument.
160980 2001-05-09  Paul Eggert  <eggert@twinsun.com>
160982         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
160984 2001-04-21  Jim Meyering  <meyering@lucent.com>
160986         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
160987         doesn't interfere.
160989 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
160991         * m4/ftruncate.m4: Check for chsize.
160992         Link with ftruncate.o unconditionally if ftruncate is missing.
160993         This was required when cross-compiling to i586-mingw32msvc.
160995 2001-04-08  Jim Meyering  <meyering@lucent.com>
160997         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
160998         recomputed; that's necessary when the offset spans a DST transition.
160999         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
161001 2001-04-02  Jim Meyering  <meyering@lucent.com>
161003         * lib/regex.h, regex.c: Update from GNU libc.
161005 2001-03-24  Jim Meyering  <meyering@lucent.com>
161007         * m4/jm-macros.m4: Require autoconf-2.49d.
161009 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
161011         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
161013 2001-03-19  Paul Eggert  <eggert@twinsun.com>
161015         * lib/version-etc.c (version_etc_copyright): Update to 2001.
161017 2001-03-17  Jim Meyering  <meyering@lucent.com>
161019         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
161020         now that the version in autoconf is equivalent.
161021         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
161023         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
161024         Suggestion from Akim Demaille.
161026         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
161027         (jm_PREREQ_TEMPNAME): New function.
161029 2001-03-16  Paul Eggert  <eggert@twinsun.com>
161031         * lib/tempname.c (uint64_t): Define to uintmax_t if
161032         not defined, and if UINT64_MAX is not defined.
161033         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
161034         Reported by John David Anglin.
161036 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
161038         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
161039         resolve alias if codeset is empty.
161040         * lib/config.charset (BeOS): Use wildcard syntax.
161042 2001-03-13  Jim Meyering  <meyering@lucent.com>
161044         * lib/path-concat.c (path_concat)
161045         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
161046         concatenating e.g., `C:' and `foo'.
161047         From Bruno Haible.
161049 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
161051         * lib/localcharset.c (locale_charset): Don't use
161052         setlocale(LC_CTYPE,NULL). Don't return NULL.
161053         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
161055 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
161057         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
161058         support for DOS/DJGPP.
161060 2001-03-01  Paul Eggert  <eggert@twinsun.com>
161062         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
161063         lacks mkstemp.  Compile our own tempname.c if we compile our own
161064         mkstemp.c, as mkstemp relies on tempname.
161066 2001-03-01  Jim Meyering  <meyering@lucent.com>
161068         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
161069         AH_VERBATIM really does output its argument verbatim.
161071 2001-02-28  Paul Eggert  <eggert@twinsun.com>
161073         * lib/Makefile.am (libfetish_a_SOURCES):
161074         Add dup-safer.c, fopen-safer.c.
161075         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
161077         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
161078         * lib/unistd-safer.h: New files.
161080 2001-02-25  Paul Eggert  <eggert@twinsun.com>
161082         The mkstemp replacement is taken from glibc 2.2.2, with some
161083         portability fixes for use outside glibc, as follows:
161085         * lib/tempname.c (struct_stat64): New macro.
161086         (direxists, __gen_tempname): Use it.
161087         This avoids a portability problem with Solaris 8.
161089         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
161090         (<stddef.h>, <stdint.h>, <string.h>):
161091         Include only if STDC_HEADERS || _LIBC.
161092         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
161093         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
161094         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
161095         (__set_errno): Define this macro if <errno.h> doesn't.
161096         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
161097         Define these macros if <stdio.h> doesn't.
161098         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
161099         Define these macros if <sys/stat.h>
161100         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
161101         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
161102         __xstat64): Define if not _LIBC.
161103         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
161104         (__gen_tempname): Invoke gettimeofday only if
161105         HAVE_GETTIMEOFDAY || _LIBC;
161106         otherwise, fall back on plain "time".
161107         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
161109         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
161111         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
161113 2001-02-18  Paul Eggert  <eggert@twinsun.com>
161115         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
161117 2001-02-17  Paul Eggert  <eggert@twinsun.com>
161119         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
161120         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
161121         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
161122         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
161124 2001-02-17  Paul Eggert  <eggert@twinsun.com>
161126         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
161127         Remove workaround macros for hosts that have mbrtowc but not
161128         mbstate_t, as we now insist on proper declarations for both
161129         before using mbrtowc.
161131 2001-02-17  Jim Meyering  <meyering@lucent.com>
161133         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
161134         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
161135         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
161136         UnixWare 7.1.1.
161138         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
161139         rather than AC_CACHE_VAL.
161141 2001-02-17  Jim Meyering  <meyering@lucent.com>
161143         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
161144         around included file name.
161146         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
161148         * lib/strftime.c: Update from GNU libc (the only changes were to
161149         comments).
161151 2001-02-17  Jim Meyering  <meyering@lucent.com>
161153         * lib/regex.c: Update from libc.
161155 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
161157         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
161158         clash.
161160 2001-02-16  Paul Eggert  <eggert@twinsun.com>
161162         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
161163         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
161164         Reported by Mark Hounschell via Paul Eggert.
161166 2001-02-07  Jim Meyering  <meyering@lucent.com>
161168         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
161170 2001-02-05  Jim Meyering  <meyering@lucent.com>
161172         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
161173         it includes the patch required for `large file' support with at least
161174         HP-UX's 10.20 /bin/cc.
161176 2001-02-03  Jim Meyering  <meyering@lucent.com>
161178         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
161179         AS_IF, now that it works once again (mysteriously).
161180         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
161182 2001-01-30  Jim Meyering  <meyering@lucent.com>
161184         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
161185         * m4/chown.m4: Rename conftestchown to conftest.chown.
161186         * m4/rename.m4: s/conftestdir/conftest.d1/ and
161187         s/conftestdir2/conftest.d2/.
161188         * m4/utimes.m4: s/conftestdata/conftest.data/
161189         Inspired by Pavel Roskin's change in autoconf.
161191 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
161193         * lib/config.charset: Update for FreeBSD 4.2.
161195 2001-01-27  Jim Meyering  <meyering@lucent.com>
161197         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
161198         a use of AS_IF.
161199         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
161201 2001-01-26  Jim Meyering  <meyering@lucent.com>
161203         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
161204         quotearg.c includes it.
161206 2001-01-26  Jim Meyering  <meyering@lucent.com>
161208         * lib/quotearg.c: Include stddef.h.
161209         * lib/quote.c: Include stddef.h.
161210         Reported by Axel Kittenberger.
161212         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
161213         line in double quotes so that it evokes a better diagnostic.
161214         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
161215         Reported by Axel Kittenberger.
161217 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
161219         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
161220         as if it was a `charset'.
161222 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
161224         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
161225         has const.
161227 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
161229         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
161230         to avoid a warning.  Add back 'const' to inptr.
161232 2001-01-20  Jim Meyering  <meyering@lucent.com>
161234         Be sure that headers are checked before used in code compiled
161235         for the type checks.
161236         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
161237         In place of that, invoke jm_CHECK_ALL_TYPES.
161238         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
161239         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
161240         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
161241         The check for ssize_t was mistakenly run before the test for unistd.h.
161243         The configure-time check for stdbool.h was missing.
161244         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
161245         (jm_PREREQ_HASH): New function.
161247 2001-01-17  Jim Meyering  <meyering@lucent.com>
161249         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
161250         for autoconf-2.49c.
161251         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
161253 2001-01-16  Jim Meyering  <meyering@lucent.com>
161255         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
161256         From Bruno Haible.
161258 2001-01-14  Jim Meyering  <meyering@lucent.com>
161260         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
161261         foo and bar.  Create conftestdir/ in the script, not in the C code.
161262         Remove directories in the script, not in the C code.
161263         Remove conftestdir{,2} before trying to create the directory.
161264         Make the entire configure script fail if the mkdir fails.
161266 2001-01-14  Jim Meyering  <meyering@lucent.com>
161268         * lib/rename.c: New file.  From Volker Borchert.
161269         Include stdlib.h, string.h or strings.h, and xalloc.h.
161270         Use strip_trailing_slashes rather than open-coding it.
161272 2001-01-03  Paul Eggert  <eggert@twinsun.com>
161274         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
161276 2001-01-03  Jim Meyering  <meyering@lucent.com>
161278         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
161279         of local `inptr' to avoid warning with some system declarations of
161280         iconv.
161282 2001-01-02  Volker Borchert  <bt@teknon.de>
161284         * m4/rename.m4: New file.
161285         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
161287 2001-01-01  Jim Meyering  <meyering@lucent.com>
161289         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
161290         even on systems with utmpx.h.  It's necessary for the declaration of
161291         utmp's ut_user member.  Reported by Andreas Jaeger.
161293         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
161294         available. They are required for the declarations of getgrgid and
161295         getpwuid resp.
161296         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
161297         Reported by Andreas Jaeger.
161299 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
161301         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
161302         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
161303         so `make install' also works in VPATH builds.
161305 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
161307         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
161308         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
161309         can be used in subdirectories.
161311 2000-12-29  Paul Eggert  <eggert@twinsun.com>
161313         * lib/modechange.c: Do not assume that mode_t uses the
161314         traditional octal encoding.  E.g. "chmod 1 FOO" should set
161315         the other-execute bit of FOO even if S_IXOTH != 1.
161317         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
161318         WOTH, XOTH, ALLM): New macros.
161319         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
161320          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
161321         Use them.
161322         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
161323         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
161324         (mode_compile):
161325         No need to use uintmax_t; unsigned long is long enough.
161326         Don't bother to get suffix since we don't use it.
161328 2000-12-26  Jim Meyering  <meyering@lucent.com>
161330         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
161331         better with autoheader.
161333 2000-12-24  Jim Meyering  <meyering@lucent.com>
161335         * lib/hash.c (is_prime): Return explicit boolean values.
161336         (hash_get_first): Return NULL to appease Irix5.6's 89.
161337         Reported by Nelson Beebe.
161339 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
161341         * lib/localcharset.c (locale_charset): Add support for Win32.
161343 2000-12-18  Paul Eggert  <eggert@twinsun.com>
161345         * lib/physmem.h, lib/physmem.c: New files.
161347         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
161348         (noinst_HEADERS): Add physmem.h.
161350         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
161351         't' for compatibility with Solaris 8 sort.
161353 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
161355         * lib/config.charset: Add support for BeOS.
161357 2000-12-17  Jim Meyering  <meyering@lucent.com>
161359         * m4/dos.m4 (jm_AC_DOS): New file and macro.
161360         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
161362 2000-12-16  Jim Meyering  <meyering@lucent.com>
161364         This bug had a serious impact on chown: `chown N:M FILE' (for integer
161365         N and M) would have treated it like `chown N:N FILE'.
161367         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
161369 2000-12-16  Jim Meyering  <meyering@lucent.com>
161371         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
161372         SHELLS_FILE to a file name that's useful on djgpp systems.
161373         Include stdlib.h.
161374         (ADDITIONAL_DEFAULT_SHELLS): Define.
161375         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
161376         Based mostly on a patch from Prashant TR.
161378 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
161380         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
161381         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
161382         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
161384 2000-12-08  Andreas Schwab  <schwab@suse.de>
161386         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
161387         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
161389 2000-12-07  Jim Meyering  <meyering@lucent.com>
161391         * lib/stripslash.c (ISSLASH): Define.
161392         (strip_trailing_slashes): Use ISSLASH rather than comparing against
161393         `/'.
161394         From Prashant TR.
161396         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
161397         (dir_name_r): Declare this function as static.
161398         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
161399         manifest itself on a name containing a mix of slashes and
161400         backslashes.
161401         Make this function work with names starting with a DOS-style
161402         drive letter and colon prefix.
161403         (dir_name): Append `.' if necessary.
161404         Based mostly on patches from Prashant TR and Eli Zaretskii.
161406         * lib/dirname.h (dir_name_r): Remove prototype.
161408 2000-12-06  Paul Eggert  <eggert@twinsun.com>
161410         * m4/off_t-format.m4: Remove this file.
161411         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
161413 2000-12-06  Jim Meyering  <meyering@lucent.com>
161415         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
161416         replacement strtoull, we may well need the replacement strtoul, too.
161417         Check for declarations of strtoul and strtoull.
161418         Check for strtol.  Mainly as a cue to cause automake to include
161419         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
161420         Check for limits.h -- strtol.c needs it.
161422 2000-12-05  Jim Meyering  <meyering@lucent.com>
161424         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
161426 2000-12-04  Jim Meyering  <meyering@lucent.com>
161428         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
161429         Also include memory.h, stdlib.h, unistd.h if appropriate.
161430         Reported by Andreas Jaeger (conflicting declaration of malloc).
161432 2000-12-02  Jim Meyering  <meyering@lucent.com>
161434         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
161435         * m4/jm-macros.m4 (jm_MACROS): require it.
161437 2000-12-02  Jim Meyering  <meyering@lucent.com>
161439         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
161441 2000-12-01  Paul Eggert  <eggert@twinsun.com>
161443         * lib/memrchr.c: Include <config.h> before any system include file.
161445 2000-11-30  Jim Meyering  <meyering@lucent.com>
161447         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
161449 2000-11-30  Jim Meyering  <meyering@lucent.com>
161451         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
161453 2000-11-29  Paul Eggert  <eggert@twinsun.com>
161455         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
161457 2000-11-26  Jim Meyering  <meyering@lucent.com>
161459         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
161461 2000-11-22  Paul Eggert  <eggert@twinsun.com>
161463         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
161464         size of (size_t) -1; it's not portable.
161466 2000-11-17  Jim Meyering  <meyering@lucent.com>
161468         * lib/strstr.c: Update from GNU libc.
161470 2000-11-17  Akim Demaille  <akim@epita.fr>
161472         * lib/obstack.h: Formatting changes.
161473         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
161474         prevent type checking.
161475         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
161476         cast the value to (void *): assigning a `foo *' to a `void *'
161477         variable is valid.
161478         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
161480 2000-11-16  Jim Meyering  <meyering@lucent.com>
161482         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
161484 2000-11-11  Jim Meyering  <meyering@lucent.com>
161486         * lib/error.c: Add a couple #includes, merging from GNU libc version.
161488 2000-11-10  Jim Meyering  <meyering@lucent.com>
161490         * lib/obstack.h: Update from GNU libc.
161491         * lib/obstack.c: Likewise.
161493 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
161495         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
161497 2000-11-06  Paul Eggert  <eggert@twinsun.com>
161499         * lib/getusershell.c (setusershell): Use rewind rather than
161500         fseek/fseeko, to avoid configuration hassles with fseeko.
161501         Don't bother opening SHELLS_FILE if shellstream is NULL;
161502         it's not necessary.
161504 2000-11-05  Jim Meyering  <meyering@lucent.com>
161506         * lib/makepath.h (make_dir): Declare.
161507         * lib/makepath.c (make_dir): Remove `static' attribute.
161508         Tweak a comment.
161510 2000-11-04  Jim Meyering  <meyering@lucent.com>
161512         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
161514 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
161516         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
161517         last one in a bucket, advance to the next bucket.
161519 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
161521         * lib/fnmatch.c: Do not comment out all the code if we are using
161522         the GNU C library, because in some cases we are replacing buggy
161523         code in the GNU C library itself.
161525 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
161527         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
161528         (regex_compile): Catch bogus \(\1\).
161530 2000-10-30  Paul Eggert  <eggert@twinsun.com>
161532         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
161533         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
161534         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
161536 2000-10-30  Paul Eggert  <eggert@twinsun.com>
161538         * lib/error.h, getline.h, modechange.h:
161539         Remove "2000" from Copyright line, as the file hasn't been
161540         changed this year other than in the copyright notice.
161542         * lib/xalloc.h: Add "2000" to Copyright line, as this file
161543         was changed this year.
161545 2000-10-29  Jim Meyering  <meyering@lucent.com>
161547         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
161548         renaming.
161549         * m4/ls-mntd-fs.m4: Likewise
161551 2000-10-29  Jim Meyering  <meyering@lucent.com>
161553         * lib/xstat.in: Fix grammar in comment.
161555 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
161557         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
161558         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
161559         doesn't define __restrict_arr.
161561 2000-10-28  Jim Meyering  <meyering@lucent.com>
161563         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
161564         (jm_PREREQ_MEMCHR): New function.
161566 2000-10-28  Jim Meyering  <meyering@lucent.com>
161568         * lib/memchr.c: Update from libc.
161569         Adjust for portability:
161570         [HAVE_STDLIB_H]: Include stdlib.h.
161571         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
161572         Undef __memchr, too.
161573         [!weak_alias]: Define __memchr to memchr.
161575         * lib/regex.c: Update from libc.
161576         * lib/regex.h: Likewise.
161577         * lib/getopt1.c: Likewise.
161578         * lib/memcmp.c: Likewise.
161580         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
161581         Avoid using fseek, when possible -- it's broken by design.
161582         Patch by Ulrich Drepper.
161584 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
161586         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
161587         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
161588         Giving in to popular pressure to shut up the compiler with casts.
161590 2000-10-26  Jim Meyering  <meyering@lucent.com>
161592         * lib/strftime.c: Update from libc.
161594 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
161596         * regex.c: More `unsigned char' -> `re_char' changes.
161597         Also change several `int' into `re_wchar_t'.
161598         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
161599         (PUSH_FAILURE_POINTER): Don't cast any more.
161600         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
161601         We want GCC to complain, since this piece of code makes
161602         re_match non-reentrant, which *should* be fixed.
161603         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
161604         (EXTEND_BUFFER): Use RETALLOC.
161605         (SET_LIST_BIT): Don't cast.
161606         (re_wchar_t): New type.
161607         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
161608         that those two functions will always properly return.
161609         (IMMEDIATE_QUIT_CHECK): Cast to void.
161610         (analyse_first): Use recursion rather than an explicit stack.
161611         (re_compile_fastmap): Can't fail anymore.
161612         (re_search_2): Don't check re_compile_fastmap for failure.
161613         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
161614         Now also sets the new value (passed in a new argument).
161615         (re_match_2_internal): Use it.
161616         Also, use a new var `reg' of type size_t when looping through regs
161617         rather than reuse the inappropriate `mcnt'.
161619 2000-10-25  Jim Meyering  <meyering@lucent.com>
161621         * lib/obstack.c: Update from libc.
161623 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
161625         * regex.c (regex_compile): Change the way of handling a range from
161626         a char less than 256 to a char not less than 256.
161628 2000-10-24  Andrew Innes  <andrewi@gnu.org>
161630         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
161631         NT-Emacs only.
161632         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
161633         so that re_search functions only quit when callers expect them to.
161635 2000-10-23  Jim Meyering  <meyering@lucent.com>
161637         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
161638         wrong.  That set_locale call must not have any side effects.
161639         From Paul Eggert.
161641 2000-10-22  Jim Meyering  <meyering@lucent.com>
161643         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
161644         [CYCLIC]: Remove now-unused definition.
161646         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
161647         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
161648         Suggestion from Ulrich Drepper.
161650 2000-10-21  Jim Meyering  <meyering@lucent.com>
161652         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
161653         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
161654         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
161656 2000-10-21  Jim Meyering  <meyering@lucent.com>
161658         * lib/dirname.c (memrchr): Declare if necessary.
161659         (dir_name): Remove the restriction that there be no
161660         trailing slashes.  Now, this code skips past them, effectively
161661         ignoring them.
161662         [TEST_DIRNAME] (main): New unit tests.
161664         * lib/memrchr.c: New file from GNU libc.
161665         Undef __memrchr, too.
161666         [!weak_alias]: Define __memrchr to memrchr.
161667         Guard weak_alias use with `#ifdef weak_alias'.
161669 2000-10-21  Jim Meyering  <meyering@lucent.com>
161671         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
161672         (dir_name): Use dir_name_r.
161673         * lib/dirname.h (dir_name_r): Declare it.
161675 2000-10-17  Jim Meyering  <meyering@lucent.com>
161677         * lib/quote.h (PARAMS): Define and use.
161678         Reported by Akim Demaille.
161680         * lib/getopt.c: Update from libc.
161682 2000-10-16  Jim Meyering  <meyering@lucent.com>
161684         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
161685         setlocale.
161686         From Jan Fedak.
161688 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
161690         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
161692 2000-09-25  Jim Meyering  <meyering@lucent.com>
161694         * lib/md5.h (rol): Define (from GnuPG).
161696         * lib/sha.c: Give credit (GnuPG) where due.
161697         (M): Use rol rather than open-coding it.
161698         Add a FIXME comment.
161700 2000-09-21  Jim Meyering  <meyering@lucent.com>
161702         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
161703         Reported by Michael Stone.
161705 2000-09-20  Jim Meyering  <meyering@lucent.com>
161707         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
161708         (noinst_HEADERS): Add sha.h.
161709         Based on code from Scott G. Miller and from GnuPG.
161711 2000-09-18  Jim Meyering  <meyering@lucent.com>
161713         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
161714         LIBS. Otherwise, everyone ends up linking with -lelf for some
161715         configurations.
161716         Reported by Mike Stone.
161718 2000-09-15  Jim Meyering  <meyering@lucent.com>
161720         * lib/regex.c: Update from libc.
161722 2000-09-10  Jim Meyering  <meyering@lucent.com>
161724         * lib/getopt.c (_getopt_internal): Update from glibc.
161726 2000-09-09  Jim Meyering  <meyering@lucent.com>
161728         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
161729         think it should be used as a general replacement for isascii.
161730         * lib/fnmatch.c: Likewise.
161731         * lib/mbswidth.c: Likewise
161732         * lib/regex.c: Likewise.
161734         Don't use atoi.
161735         * lib/userspec.c: Include sys/param.h and limits.h.
161736         Include xstrtol.h.
161737         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
161738         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
161739         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
161740         UID, GID.  Check range.
161742 2000-09-06  Jim Meyering  <meyering@lucent.com>
161744         * lib/getopt.c (_getopt_internal): Update from glibc.
161746 2000-08-30  Jim Meyering  <meyering@lucent.com>
161748         * lib/strftime.c: Merge in changes from GNU libc.
161750 2000-08-26  Jim Meyering  <meyering@lucent.com>
161752         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
161753         * m4/fpending.m4: New file.
161755 2000-08-26  Jim Meyering  <meyering@lucent.com>
161757         * lib/closeout.c: Include "__fpending.h".
161758         (close_stdout_status): Return right away if there's nothing to flush.
161760         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
161761         * lib/__fpending.c: New file.
161762         * lib/__fpending.h: New file.
161764 2000-08-20  Jim Meyering  <meyering@lucent.com>
161766         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
161767         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
161768         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
161770 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
161772         Improve fileutils installation on systems where running
161773         programs (like install) can't be unlinked.
161774         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
161775         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
161777 2000-08-07  Paul Eggert  <eggert@twinsun.com>
161779         Standardize on "memory exhausted" instead of "Memory exhausted"
161780         or "virtual memory exhausted".
161781         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
161782         "virtual memory exhausted".
161783         * lib/same.c (same_name): Invoke xalloc_die instead of printing
161784         our own message.
161785         * lib/userspec.c (parse_user_spec): Likewise.
161786         * lib/bumpalloc.h: comment fix
161787         * lib/same.c, userspec.c: Include xalloc.h.
161789         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
161790         not char *const and pointing to a constant array.
161791         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
161792         (xrealloc): Comment fix.
161794         * lib/userspec.c (parse_user_spec):
161795         Don't translate a message until just before returning,
161796         to avoid unnecessary translation.
161798 2000-08-07  Jim Meyering  <meyering@lucent.com>
161800         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
161801         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
161802         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
161803         getgroups.c, gethostname.c, getopt.h, group-member.c,
161804         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
161805         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
161806         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
161807         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
161808         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
161809         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
161810         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
161811         yesno.c: Back out Copyright date changes for each file with no change
161812         this year.  This eases coordination with other programs using the same
161813         source code modules.  From Paul Eggert.
161815 2000-08-06  Paul Eggert  <eggert@twinsun.com>
161817         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
161818         not char, for compatibility with glibc 2.1.3 strftime.c.
161820 2000-08-03  Greg McGary  <greg@mcgary.org>
161822         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
161823         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
161824         (EXTEND_BUFFER): Use them.
161826 2000-08-01  Jim Meyering  <meyering@lucent.com>
161828         * lib/dirname.c (ISSLASH): Define.
161829         (BACKSLASH_IS_PATH_SEPARATOR): Define.
161830         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
161831         both `\' and `/' may be use as path separators.
161832         Based on a patch from Prashant TR.
161834 2000-07-31  Paul Eggert  <eggert@twinsun.com>
161836         * lib/quotearg.c (quotearg_n_options): Don't make the initial
161837         slot vector a constant, since it might get modified.
161839 2000-07-31  Jim Meyering  <meyering@lucent.com>
161841         * lib/xmalloc.c: Use `virtual memory exhausted', not
161842         `Memory exhausted'.
161843         * lib/obstack.c (print_and_abort): Likewise.
161845 2000-07-30  Paul Eggert  <eggert@twinsun.com>
161847         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
161848         buffer, so that the caller can always quote one small
161849         component of a "memory exhausted" message in slot 0.
161850         From a suggestion by Jim Meyering.
161852 2000-07-30  Jim Meyering  <meyering@lucent.com>
161854         * lib/makepath.c (make_path): Quote the other instance, too.
161856         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
161857         (STATIC_BUF_SIZE): Define.
161858         (quotearg_n_options): Use only statically allocated storage when
161859         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
161860         than STATIC_BUF_SIZE.
161862 2000-07-29  Jim Meyering  <meyering@lucent.com>
161864         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
161865         * lib/dirname.c (dir_name): Likewise.
161867         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
161868         `/'.
161870         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
161871         (dir_name): Assert that there are no trailing slashes.
161873 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
161875         * lib/mbswidth.h (mbswidth): Add a flags argument.
161876         (mbswidth): New declaration.
161877         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
161878         * lib/mbswidth.c (mbswidth): Add a flags argument.
161879         (mbsnwidth): New function.
161881 2000-07-24  Jim Meyering  <meyering@lucent.com>
161883         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
161885 2000-07-23  Paul Eggert  <eggert@twinsun.com>
161887         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
161889 2000-07-23  Paul Eggert  <eggert@twinsun.com>
161891         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
161892         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
161893         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
161894         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
161895         invoke multibyte primitives.
161897 2000-07-23  Paul Eggert  <eggert@twinsun.com>
161899         * lib/quotearg.c:
161900         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
161901         so that mbstate_t is always defined.
161903         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
161904         be 1 in at least one GCC installation, and this configuration
161905         error is likely to be common.  Ignoring MB_LEN_MAX hurts
161906         performance on hosts that have mbrtowc but have only unibyte
161907         locales, but I assume these hosts are rare.
161909 2000-07-23  Paul Eggert  <eggert@twinsun.com>
161911         * lib/mbswidth.c (_XOPEN_SOURCE):
161912         Don't define; this causes problems on Solaris 7.
161913         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
161915 2000-07-23  Jim Meyering  <meyering@lucent.com>
161917         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
161918         too: getgrgid, getpwuid, getuid.
161920 2000-07-23  Jim Meyering  <meyering@lucent.com>
161922         * lib/basename.c (base_name): Add an assertion.
161924 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
161926         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
161927         shadow its mbsinit function.
161929 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
161931         * lib/mbswidth.h: New file.
161932         * lib/mbswidth.c: New file.
161933         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
161934         (noinst_HEADERS): Add mbswidth.h.
161936 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
161938         * lib/config.charset: Add support for FreeBSD. Improve support for
161939         HP-UX and IRIX 6.
161941 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
161943         * m4/mbswidth.m4: New file.
161944         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
161946 2000-07-15  Jim Meyering  <meyering@lucent.com>
161948         * lib/makepath.c: Include quote.h.
161949         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
161950         corresponding argument in a `quote (...)' call.
161951         Give better diagnostics.
161953         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
161954         (noinst_HEADERS): Add quote.h.
161956         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
161957         from tar's src/misc.c.
161958         * lib/quote.h: New file.  Prototypes for same.
161960 2000-07-14  Paul Eggert  <eggert@twinsun.com>
161962         From a suggestion by Bruno Haible.
161963         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
161964         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
161965         to decide whether to define the BeOS workaround macro;
161966         this adjusts to the change to AC_MBSTATE_T.
161968 2000-07-14  Jim Meyering  <meyering@lucent.com>
161970         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
161971         jm_AC_TYPE_UINTMAX_T.
161973 2000-07-13  Paul Eggert  <eggert@twinsun.com>
161975         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
161977         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
161978         quotearg_buffer_restyled): Add support for
161979         clocale_quoting_style.  Undo previous change to
161980         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
161981         and "{RIGHT QUOTATION MARK}" msgids.
161983 2000-07-10  Paul Eggert  <eggert@twinsun.com>
161985         From a suggestion by Bruno Haible.
161986         * m4/mbstate_t.m4 (AC_MBSTATE_T):
161987         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
161988         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
161989         and mbstate_t, to a single-part test that simply defines mbstate_t.
161990         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
161991         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
161993 2000-07-10  Jim Meyering  <meyering@lucent.com>
161995         * m4/strerror_r.m4: Mirror the correction made in autoconf.
161997         * m4/gnu-source.m4: Output to confdefs.h directly.
161998         Suggestion from Akim Demaille.
162000 2000-07-09  Paul Eggert  <eggert@twinsun.com>
162002         The old behavior of quoting `like this' doesn't look good with
162003         newer, ISO-style fonts.  See:
162004         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
162006         Instead, quote "like this" by default.  Let the translator
162007         tailor the locale-specific quoting behavior by providing
162008         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
162010         * lib/quotearg.c (N_): New macro.
162011         (gettext_default): New function.
162012         (quotearg_buffer_restyled): Use
162013         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
162014         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
162016 2000-07-09  Jim Meyering  <meyering@lucent.com>
162018         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
162019         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
162021         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
162022         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
162024 2000-07-09  Jim Meyering  <meyering@lucent.com>
162026         * lib/Most files: Update copyright dates to include 2000.
162028 2000-07-08  Jim Meyering  <meyering@lucent.com>
162030         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
162031         if not defined.
162032         (xgethostname): Remove now-unnecessary #ifdef.
162033         Move declaration of `err' into loop where it's used.
162035 2000-07-05  Paul Eggert  <eggert@twinsun.com>
162036         and Bruno Haible  <haible@clisp.cons.org>
162038         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
162039         only if the test for an object-type mbstate_t fails.  This
162040         prevents us from mistakenly reporting that mbstate_t is a
162041         system object type after we "#define mbstate_t int" to work
162042         around its lack.
162044 2000-07-05  Paul Eggert  <eggert@twinsun.com>
162045         and Bruno Haible  <haible@clisp.cons.org>
162047         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
162049 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
162051         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
162052         to strerror_r.
162053         Include <ctype.h> for use of isalpha.
162055 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
162057         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
162058         by allocating a larger buffer. Test the gethostname return value for
162059         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
162060         returns an error and ENAMETOOLONG isn't defined.
162062 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
162064         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
162065         dimension.
162067 2000-07-04  Jim Meyering  <meyering@lucent.com>
162069         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
162070         of the deprecated AC_CHECKING.
162072 2000-07-04  Jim Meyering  <meyering@lucent.com>
162074         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
162075         Reported by Bruno Haible.
162077 2000-07-04  Jim Meyering  <meyering@lucent.com>
162079         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
162080         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
162081         lacks mbrtowc.
162083 2000-07-03  Paul Eggert  <eggert@twinsun.com>
162085         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
162086         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
162088 2000-07-03  Paul Eggert  <eggert@twinsun.com>
162089         and Bruno Haible  <haible@clisp.cons.org>
162091         * lib/quotearg.c (mbrtowc):
162092         Assign to *pwc, and return 1 only if result is nonzero.
162093         (iswprint): Use ISPRINT when substituting our own mbrtowc.
162095 2000-07-03  Jim Meyering  <meyering@lucent.com>
162097         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
162099 2000-07-03  Jim Meyering  <meyering@lucent.com>
162101         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
162102         This is necessary to get a definition of e.g., UTMP_FILE on
162103         HP-UX 10.20.
162104         From Bob Proulx.
162106 2000-07-02  Jim Meyering  <meyering@lucent.com>
162108         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
162110         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
162111         AC_LIBOBJ(function_name).
162112         * m4/chown.m4: Likewise.
162113         * m4/fnmatch.m4: Likewise.
162114         * m4/ftruncate.m4: Likewise.
162115         * m4/getgroups.m4: Likewise.
162116         * m4/getline.m4: Likewise.
162117         * m4/group-member.m4: Likewise.
162118         * m4/jm-macros.m4: Likewise.
162119         * m4/lstat.m4: Likewise.
162120         * m4/malloc.m4: Likewise.
162121         * m4/memcmp.m4: Likewise.
162122         * m4/nanosleep.m4: Likewise.
162123         * m4/putenv.m4: Likewise.
162124         * m4/realloc.m4: Likewise.
162125         * m4/regex.m4: Likewise.
162126         * m4/stat.m4: Likewise.
162127         * m4/strftime.m4: Likewise.
162129 2000-07-02  Jim Meyering  <meyering@lucent.com>
162131         * lib/quotearg.c (mbstate_t): Don't define here.
162133 2000-07-02  Jim Meyering  <meyering@lucent.com>
162135         * lib/nanosleep.c (SIGCONT): Define if not already defined.
162137 2000-07-01  Jim Meyering  <meyering@lucent.com>
162139         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
162141 2000-07-01  Jim Meyering  <meyering@lucent.com>
162143         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
162144         problem.
162146 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
162148         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
162149         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
162151 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
162153         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
162154         per change in ../m4/ls-mntd-fs.m4.
162155         (read_filesystem_list): Ignore symbolic links.
162157 2000-06-29  Jim Meyering  <meyering@lucent.com>
162159         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
162160         for declaration of strcmp.
162162         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
162164         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
162165         Avoid warning by casting result to `char *' to remove `const'.
162167 2000-06-28  Jim Meyering  <meyering@lucent.com>
162169         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
162170         included by quotearg.c, for which we perform this test.  From
162171         Bruno Haible.
162173 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
162175         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
162176         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
162177         <utmpx.h> exists, put readutmp.o into LIBOBJS.
162179 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
162181         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
162183 2000-06-26  Paul Eggert  <eggert@twinsun.com>
162185         savedir now sets errno on failure and invokes xmalloc to get memory.
162186         Fix a couple of other minor bugs while we're at it.
162188         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
162189         (NAMLEN): Remove macro.
162190         (malloc, realloc): Remove decls.
162191         (stpcpy): Likewise.
162192         ("xalloc.h"): Include.
162193         (NAME_SIZE_DEFAULT): New macro.
162194         (savedir): Use xmalloc / xrealloc to allocate memory.
162195         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
162196         Skip "" directory entries.
162197         Use strlen to calculate directory entry length, since the old method
162198         is rarely used these days and isn't worth supporting.
162199         Don't use a pointer after freeing it.
162200         Check for integer overflow when calculating allocation size.
162201         Use memcpy to copy entries, instead of stpcpy.
162202         Set errno properly when returning NULL.
162203         Check for readdir error.
162205 2000-06-26  Jim Meyering  <meyering@lucent.com>
162207         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
162209 2000-06-25  Jim Meyering  <meyering@lucent.com>
162211         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
162212         Linux header bug when _XOPEN_SOURCE is defined to 500.
162214 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
162216         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
162217         deficiency.
162219 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
162221         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
162222         Include xalloc.h.
162223         Don't include <stdlib.h>.  Don't declare malloc, realloc.
162225 2000-06-24  Jim Meyering  <meyering@lucent.com>
162227         * m4/strerror_r.m4: Revive this file -- to try out an experimental
162228         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
162229         for which strerror does return char*, but which lacks a conveniently
162230         accessible declaration of the function.  If the compile-test says
162231         strerror_r doesn't work, then resort to a `run'-test that works on
162232         BeOS and segfaults on DEC Unix.
162234 2000-06-24  Jim Meyering  <meyering@lucent.com>
162236         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
162238 2000-06-23  Paul Eggert  <eggert@twinsun.com>
162240         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
162241         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
162243 2000-06-23  Paul Eggert  <eggert@twinsun.com>
162245         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
162246         (mbrtowc, mbstate_t): Define substitutes if
162247         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
162248         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
162249         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
162251 2000-06-23  Jim Meyering  <meyering@lucent.com>
162253         * m4/afs.m4: Add missing AC_MSG_RESULT.
162254         Reported by Bruno Haible.
162256         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
162257         Suggestion from Bruno Haible.
162259 2000-06-23  Jim Meyering  <meyering@lucent.com>
162261         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
162263 2000-06-21  Jim Meyering  <meyering@lucent.com>
162265         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
162267 2000-06-21  Jim Meyering  <meyering@lucent.com>
162269         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
162270         (noinst_HEADERS): Add getstr.h.
162272         * lib/getline.c (getstr): Move into a separate file.
162273         * lib/getstr.c (getstr): New file, extracted from getline.c, with
162274         the following changes: new parameter, delim2; both delim[12]
162275         parameters have type `int', not `char'.  The latter would lose
162276         with 8-bit delimiters.
162277         * lib/getstr.h: New file.
162279 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
162281         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
162282         than 1024, return a memory chunk of least possible size, instead
162283         of size PATH_MAX + 2. In the loop, increment the size proportionally.
162284         Use free/xmalloc instead of xrealloc to avoid copying for very long
162285         paths.
162287 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
162289         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
162290         the empty string.
162292 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
162294         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
162295         address, not strdup.  Include <stdlib.h> and don't declare free().
162297 2000-06-19  Jim Meyering  <meyering@lucent.com>
162299         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
162301 2000-06-18  Jim Meyering  <meyering@lucent.com>
162303         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
162305         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
162306         `checking whether...' message to be consistent with that of the
162307         lstat test.
162309 2000-06-18  Jim Meyering  <meyering@lucent.com>
162311         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
162312         Besides, these days every porting target provides a mkdir function.
162314         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
162315         needed. (this snippet comes from src/system.h).
162317 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
162319         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
162321 2000-06-15  Paul Eggert  <eggert@twinsun.com>
162323         * lib/human.c (adjust_value): New function.
162324         (human_readable_inexact): Apply rounding style even when
162325         printing approximate values.
162327 2000-06-14  Paul Eggert  <eggert@twinsun.com>
162329         * lib/human.c (human_readable_inexact): Allow an input block
162330         size that is not a multiple of the output block size, and vice versa.
162331         Reported by Piergiorgio Sartor.
162333 2000-06-14  Paul Eggert  <eggert@twinsun.com>
162335         * lib/getdate.y (get_date): Apply relative times after time
162336         zone indicator, not before.  Reported by Todd A. Jacobs.
162338 2000-06-13  Jim Meyering  <meyering@lucent.com>
162340         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
162342         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
162344 2000-06-12  Paul Eggert  <eggert@twinsun.com>
162346         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
162348 2000-06-12  Jim Meyering  <meyering@lucent.com>
162350         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
162351         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
162352         optional argument.
162353         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
162354         the optional argument, `lib'.
162356 2000-06-08  Jim Meyering  <meyering@lucent.com>
162358         * m4/largefile.m4: Remove file (now that it's part of autoconf).
162360 2000-06-04  Paul Eggert  <eggert@twinsun.com>
162362         Rewrite largefile configuration so that we don't need to run
162363         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
162364         AC_CANONICAL_HOST in configure.in -- jmm]
162366         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
162367         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
162368         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
162369         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
162370         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
162371         All uses changed.
162372         Instead of inspecting the output of getconf, try to compile the
162373         test program without and with the macro definition.
162374         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
162375         for getconf.  Instead, check for the needed flags by compiling
162376         test programs.
162378 2000-06-04  Paul Eggert  <eggert@twinsun.com>
162380         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
162382 2000-06-04  Jim Meyering  <meyering@lucent.com>
162384         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
162385         SunOS 4.1.4 for which gid_t is an unsigned type.
162387 2000-06-03  Jim Meyering  <meyering@lucent.com>
162389         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
162390         now that autoconf requires that.
162392         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
162393         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
162394         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
162396 2000-06-03  Jim Meyering  <meyering@lucent.com>
162398         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
162400 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
162402         * m4/glibc21.m4: New file.
162403         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
162405 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
162407         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
162408         newer, don't install charset.alias.
162409         * lib/config.charset: Change the Linux/glibc rules so they become empty
162410         on glibc-2.1 or newer.
162412 2000-06-02  Jim Meyering  <meyering@lucent.com>
162414         * lib/mountlist.c: Back out last change.  Instead, do this...
162415         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
162416         me_dummy member using the same `ignore'-testing code.
162417         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
162418         fs_type strings.
162419         From Mark D. Roth.
162421 2000-05-29  Jim Meyering  <meyering@lucent.com>
162423         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
162424         mounts with the `ignore' attribute.  Based on a patch from
162425         Mark D. Roth.
162427 2000-05-28  Jim Meyering  <meyering@lucent.com>
162429         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
162430         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
162431         * m4/stat.m4: Likewise.
162432         * m4/lstat.m4: Likewise.
162433         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
162435         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
162436         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
162438 2000-05-26  Jim Meyering  <meyering@lucent.com>
162440         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
162442 2000-05-24  Jim Meyering  <meyering@lucent.com>
162444         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
162445         autoconf requires that.
162446         * m4/lib-check.m4: Likewise.
162447         * m4/jm-macros.m4: Likewise.
162448         * m4/strftime.m4: Likewise.
162450         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
162451         AC_CHECK_DECLS, now that autoconf requires that.
162453 2000-05-22  Jim Meyering  <meyering@lucent.com>
162455         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
162456         * m4/lstat.m4: Likewise.
162458 2000-05-22  Jim Meyering  <meyering@lucent.com>
162460         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
162462 2000-05-20  Jim Meyering  <meyering@lucent.com>
162464         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
162465         (jm_PREREQ): Use it.
162467 2000-05-18  Jim Meyering  <meyering@lucent.com>
162469         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
162470         back, too, since it may have been modified by allocate_entry.
162471         (hash_delete): Rewrite to use neither the assignment operator
162472         nor the comma operator in an if-expression.
162474 2000-05-15  Paul Eggert  <eggert@twinsun.com>
162476         * lib/closeout.c:
162477         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
162478         Remove; no longer needed.
162479         "quotearg.h": Add include.
162480         (file_name): Do not bother to explicitly initialize to NULL; it's less
162481         efficient on some hosts.
162482         (close_stdout_status): Remove test as to whether stdout was already
162483         closed; it breaks for the case "echo x | sort >&-".
162484         Quote file name colons.
162485         Do not assume that _("write error") lacks format strings.
162487 2000-05-15  Jim Meyering  <meyering@lucent.com>
162489         * lib/version-etc.c (version_etc_copyright): Update the copyright
162490         string used in all --version output.
162492 2000-05-14  Jim Meyering  <meyering@lucent.com>
162494         * lib/closeout.c (close_stdout_set_file_name): New function.
162495         (close_stdout_status): Use new file-scoped global.
162496         Return right away if fstat says the stdout file descriptor is invalid.
162497         * lib/closeout.h (close_stdout_set_file_name): Declare.
162499 2000-05-10  Jim Meyering  <meyering@lucent.com>
162501         * lib/closeout.c [default_exit_status]: New file-scoped variable.
162502         (close_stdout_set_status): New function.
162503         * lib/closeout.h (close_stdout_set_status): Declare.
162505 2000-05-09  Jim Meyering  <meyering@lucent.com>
162507         * m4/gettext.m4: Rename this...
162508         * m4/libintl.m4: ...to this.
162510 2000-05-08  Jim Meyering  <meyering@lucent.com>
162512         * lib/long-options.c: Don't include closeout.h.
162513         (parse_long_options): Don't call close_stdout for --version.
162515 2000-05-06  Paul Eggert  <eggert@twinsun.com>
162517         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
162518         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
162519         2.1.3 bug.  This avoids a clash when files like regex.c define
162520         _GNU_SOURCE.
162522 2000-05-06  Jim Meyering  <meyering@lucent.com>
162524         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
162525         (AC_REPLACE_FUNCS): Add strnlen.
162527         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
162528         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
162530         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
162531         AC_SEARCH_LIBS call for nanosleep.
162532         (LIB_NANOSLEEP): Set and AC_SUBST.
162534 2000-05-06  Jim Meyering  <meyering@lucent.com>
162536         * lib/strnlen.c: Undefine __strnlen and strnlen.
162537         [!weak_alias]: Define __strnlen to strnlen.
162539         * lib/atexit.c: New file, from libiberty.
162541 2000-05-06  Jim Meyering  <meyering@lucent.com>
162543         * lib/closeout.c (close_stdout_status): Also check for errors on the
162544         stderr stream.
162546 2000-05-05  Jim Meyering  <meyering@lucent.com>
162548         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
162549         AC_SEARCH_LIBS call for clock_gettime.
162550         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
162552         * m4/search-libs.m4: Update from autoconf.
162554         su doesn't work on Solaris 2.6.
162555         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
162556         <shadow.h>.  Reported by Dragos Harabor.
162558 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
162560         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
162561         memcpy instead of xmalloc, xrealloc, path_concat.
162562         (locale_charset): Treat empty environment variables as absent.
162563         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
162565 2000-05-04  Jim Meyering  <meyering@lucent.com>
162567         * lib/getopt.c: Update from glibc.
162568         * lib/obstack.c: Likewise.
162569         * lib/obstack.h: Likewise.
162570         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
162571         file
162573         * lib/regex.h: Likewise.
162574         * lib/strndup.c: Likewise.
162575         * lib/strnlen.c: New file, from glibc.
162577 2000-05-03  Jim Meyering  <meyering@lucent.com>
162579         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
162581 2000-05-02  Paul Eggert  <eggert@twinsun.com>
162583         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
162584         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
162585         compile-time test, rather than inspecting host and OS, to
162586         decide whether to define _LARGEFILE_SOURCE.
162588 2000-05-01  Jim Meyering  <meyering@lucent.com>
162590         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
162592         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
162593         Based on a patch from Bruno Haible.
162595 2000-05-01  Jim Meyering  <meyering@lucent.com>
162597         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
162599 2000-04-29  Jim Meyering  <meyering@lucent.com>
162601         * lib/path-concat.c: Declare strdup only if it's not defined.
162602         * lib/canon-host.c: Likewise.
162604 2000-04-28  Jim Meyering  <meyering@lucent.com>
162606         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
162607         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
162608         is included first, then limits.h is included by locale.h by libintl.h.
162609         From John David Anglin.
162611 2000-04-25  Jim Meyering  <meyering@lucent.com>
162613         * lib/makepath.c (S_IRWXUGO): Define.
162614         (make_path): Always perform explicit chmod if MODE specifies any
162615         of the `special' permission bits.  Prompted by a bug report against
162616         install from Mate Wierdl and Joost van Baal.
162618 2000-04-18  Jim Meyering  <meyering@lucent.com>
162620         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
162621         (jm_PREREQ): Use it.
162623 2000-04-18  Jim Meyering  <meyering@lucent.com>
162625         * lib/README: New file.
162627         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
162628         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
162630 2000-04-17  Jim Meyering  <meyering@lucent.com>
162632         Get it right :-)
162633         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
162634         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
162635         Suggestion from Akim Demaille.
162637 2000-04-17  Jim Meyering  <meyering@lucent.com>
162639         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
162640         the definition of it to rpl_strftime also defined-away the system's
162641         declaration.
162643 2000-04-15  Jim Meyering  <meyering@lucent.com>
162645         Use `C' to denote so-called `contiguous' files, the same way
162646         that tar does.
162647         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
162648         (ftypelet): Use S_ISCTG.
162649         From Michael Deutschmann.
162651 2000-04-14  Jim Meyering  <meyering@lucent.com>
162653         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
162654         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
162655         clobbered.
162657 2000-04-14  Jim Meyering  <meyering@lucent.com>
162659         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
162661 2000-04-13  Jim Meyering  <meyering@lucent.com>
162663         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
162664         AH_VERBATIM to insert required #ifndef into config.h.in.
162665         Suggestion from Akim Demaille.
162667 2000-04-12  Jim Meyering  <meyering@lucent.com>
162669         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
162670         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
162671         Christian Krackowizer.
162673         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
162674         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
162675         (AC_SYS_LARGEFILE): Require.
162676         (AM_C_PROTOTYPES): Require.
162678 2000-04-08  Jim Meyering  <meyering@lucent.com>
162680         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
162681         names don't conflict.  Reported by Eli Zaretskii.
162683 2000-04-07  Jim Meyering  <meyering@lucent.com>
162685         * lib/putenv.c: Move inclusion of errno.h so it follows that of
162686         sys/types.h, to work around system header problems on AIX 3.2.5.
162687         From Bruno Haible.
162689 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
162691         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
162692         bug.  Deal with the different error behavior of Irix iconv.
162694 2000-04-05  Paul Eggert  <eggert@twinsun.com>
162696         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
162697         IRIX if the installer said otherwise.
162699 2000-04-05  Jim Meyering  <meyering@lucent.com>
162701         Portability tweaks required for ultrix4.3.
162702         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
162703         (jm_CHECK_DECLS): Add getutent to the list of functions.
162704         (_jm_DECL_HEADERS): Add utmpx.h.
162705         From John David Anglin.
162707         * m4/strftime.m4: Back out the 2000-04-02 change.
162708         Instead of that change, simply undefine putenv in the test program.
162710 2000-04-05  Jim Meyering  <meyering@lucent.com>
162712         Portability tweaks required for ultrix4.3.
162713         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
162714         getutent.
162715         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
162716         * lib/canon-host.c: Declare strdup.
162717         * lib/path-concat.c: Likewise.
162718         From John David Anglin.
162720 2000-04-04  Jim Meyering  <meyering@lucent.com>
162722         Be more DOS 8.3-friendly.
162723         * lib/ref-add.sin: Renamed from ref-add.sed.in.
162724         * lib/ref-del.sin: Renamed from ref-del.sed.in.
162725         * lib/Makefile.am: Reflect renaming.
162726         Reported by Eli Zaretskii.
162728         Use a temporary file name that won't clash with `charset.alias'
162729         in the DOS 8.3 name space.
162730         * lib/Makefile.am (charset_tmp): Define.
162731         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
162732         (uninstall-local): Likewise.
162733         Reported by Eli Zaretskii.
162735 2000-04-03  Jim Meyering  <meyering@lucent.com>
162737         * m4/gettext.m4: Fix typo in comment.
162739         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
162740         textutils/configure.in).  Suggestion from Paul Eggert.
162741         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
162743 2000-04-02  Paul Eggert  <eggert@twinsun.com>
162745         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
162746         variable in the shell rather than using putenv, which isn't
162747         portable.  This avoids the configure-time inter-test dependency
162748         on the potentially-renamed putenv function.
162750 2000-03-30  Paul Eggert  <eggert@twinsun.com>
162752         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
162753         before checking struct stat.st_blksize, so that
162754         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
162756 2000-03-29  Paul Eggert  <eggert@twinsun.com>
162758         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
162759         since strftime.c uses HAVE_STRFTIME to decide whether to use
162760         the underlying strftime.
162762 2000-03-29  Paul Eggert  <eggert@twinsun.com>
162764         * lib/time/strftime.c (my_strftime): Make sure we call the system
162765         strftime, not ourselves, when invoking the underlying strftime.
162767 2000-03-24  Jim Meyering  <meyering@lucent.com>
162769         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
162770         (charset_alias): Define.
162771         (install-exec-local): Factor out common code.
162772         (uninstall-local): Split lines longer than 80.
162773         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
162774         (SUFFIXES): Define.
162775         (.sed.in.sed): New rule.  Don't redirect directly to $@.
162776         (CLEANFILES): Add ref-add.sed and ref-del.sed.
162778 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
162780         * lib/config.charset: Output a line containing "Packages using this
162781         file".
162782         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
162783         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
162784         ref-del.sed): New rules.
162786 2000-03-17  Jim Meyering  <meyering@lucent.com>
162788         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
162789         Otherwise, include <strings.h>
162791 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
162793         * lib/unicodeio.c (utf8_wctomb): New function.
162794         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
162795         format instead of in UCS-4 with platform dependent endianness.
162797 2000-03-10  Jim Meyering  <meyering@lucent.com>
162799         * m4/lib-check.m4: Look for getspnam in -lgen, too.
162800         From Marco Franzen.
162802 2000-03-07  Paul Eggert  <eggert@twinsun.com>
162804         * lib/savedir.c (savedir): Work even if directory size is
162805         negative; this can happen with some screwy NFS configurations.
162807 2000-03-06  Jim Meyering  <meyering@lucent.com>
162809         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
162810         if it's NULL (because we ran out of memory).  From Bruno Haible.
162812 2000-03-05  Jim Meyering  <meyering@lucent.com>
162814         * lib/localcharset.c ("path-concat.h"): Include.
162815         (get_charset_aliases): Use path_concat instead of ANSI string
162816         concatenation.
162818         * lib/unicodeio.h (PARAMS): Define.
162819         Use it to guard prototype.
162821 2000-03-04  Jim Meyering  <meyering@lucent.com>
162823         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
162824         for lib/localcharset.c.
162826 2000-03-04  Jim Meyering  <meyering@lucent.com>
162828         * lib/Makefile.am (install-exec-local): Create $(libdir) before
162829         installing into it.
162830         (uninstall-local): Uncomment this rule so `make distcheck' works
162831         once again.
162833         * lib/unicodeio.c (<errno.h>): Include it.
162834         (errno): Declare if not defined.
162836         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
162838         * lib/config.charset: New version, incorporating remarks from a linux
162839         i18n mailing list.  From Bruno Haible.
162841 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
162843         * m4/codeset.m4: New file.
162844         * m4/iconv.m4: New file.
162845         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
162847 2000-03-03  Jim Meyering  <meyering@lucent.com>
162849         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
162851 2000-03-02  Jim Meyering  <meyering@lucent.com>
162853         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
162854         the messages come out on separate lines.
162856         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
162857         rather than jm_CHECK_DECLARATIONS.
162858         * m4/decl.m4: Remove now-unused file.
162860         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
162861         geteuid.
162863 2000-03-02  Jim Meyering  <meyering@lucent.com>
162865         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
162867 2000-03-01  Jim Meyering  <meyering@lucent.com>
162869         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
162870         * lib/unicodeio.c: Likewise.
162872 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
162874         * lib/config.charset: New file.
162875         * lib/localcharset.c: New file.
162876         * lib/unicodeio.h, lib/unicodeio.c: New files.
162877         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
162878         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
162879         (noinst_HEADERS): Add unicodeio.h.
162880         (all-local, install-exec-local, charset.alias): New targets.
162882 2000-02-28  Paul Eggert  <eggert@twinsun.com>
162884         * lib/quotearg.c (ALERT_CHAR): New macro.
162885         (quotearg_buffer_restyled): Use it.
162887 2000-02-27  Jim Meyering  <meyering@lucent.com>
162889         * m4/check-decl.m4: Add getenv to the list.
162891 2000-02-27  Jim Meyering  <meyering@lucent.com>
162893         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
162894         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
162896         * lib/backupfile.c: Guard inclusion of stdlib.h with
162897         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
162898         Declare malloc if needed.
162900         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
162901         `#ifndef HAVE_DECL..'
162902         now that autoconf always defines the HAVE_DECL_ symbols.
162903         * lib/human.c: Likewise.
162904         * lib/same.c: Likewise.
162905         * lib/strtoumax.c: Likewise.
162907         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
162908         declaration check was not run.
162909         * lib/hash.c: Likewise.
162910         * lib/human.c: Likewise.
162911         * lib/same.c: Likewise.
162912         * lib/strtoumax.c: Likewise.
162914         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
162915         `.', then first look up the entire `.'-containing string as a login
162916         name.
162918 2000-02-23  Jim Meyering  <meyering@lucent.com>
162920         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
162921         in place of my hack.
162923 2000-02-18  Paul Eggert  <eggert@twinsun.com>
162925         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
162926         (textint): New typedef.
162927         (parser_control): Member year changed from int to textint.
162928         All uses changed.
162929         (YYSTYPE): Removed; replaced by %union with int and textint members.
162930         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
162931         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
162932         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
162933         (tSNUMBER, tUNUMBER): Now of type <textintval>.
162934         (date, number, to_year): Use width of number in digits, not its value,
162935         to determine whether it's a 2-digit year, or a 2-digit time.
162936         (yylex): Store number of digits of numeric tokens.
162937         Reported by John Kendall.
162939         (parser_control): Changed from struct parser_control to typedef (for
162940         consistency).  All uses changed.
162942         (tID): Removed; not used.
162943         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
162945 2000-02-14  Paul Eggert  <eggert@twinsun.com>
162947         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
162948         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
162950 2000-02-12  Jim Meyering  <meyering@lucent.com>
162952         * lib/userspec.c (ISDIGIT): Define it.
162953         (isdigit): Remove definition.
162954         (is_number): Use ISDIGIT, not isdigit.
162955         <libintl.h>: Include.
162956         (_ and N_): Define.
162957         (parse_user_spec): Mark translatable strings.
162959 2000-02-10  Jim Meyering  <meyering@lucent.com>
162961         With these changes, nanosleep.[ch] are finally enough like the other
162962         lib/* replacement files to compile on a few more losing systems.
162964         * lib/nanosleep.h: Don't include config.h.
162965         Remove prototype from declaration of nanosleep.
162966         (PARAMS): Remove now-unneeded definition.
162967         * lib/nanosleep.c: #undef nanosleep.
162968         (rpl_nanosleep): Rename from nanosleep.
162970 2000-02-10  Jim Meyering  <meyering@lucent.com>
162972         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
162973         gnu_nanosleep to rpl_nanosleep.
162975 2000-02-09  Jim Meyering  <meyering@lucent.com>
162977         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
162978         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
162980 2000-02-08  Akim Demaille  <akim@epita.fr>
162982         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
162983         `[' and `]' and remove uses of `changequote'.
162984         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
162985         (AC_SYS_LARGEFILE): Likewise.
162986         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
162987         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
162988         of changequote.
162989         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
162990         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
162991         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
162992         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
162994 2000-02-05  Jim Meyering  <meyering@lucent.com>
162996         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
162997         Remove explicit use of AC_HEADER_TIME.  It is required by
162998         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
162999         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
163000         in autoconf whereby the expansion of the latter ended up preceding
163001         the expansion of its prerequisite, AC_HEADER_TIME.
163002         Reported by Volker Borchert.
163004 2000-02-03  Jim Meyering  <meyering@lucent.com>
163006         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
163008 2000-02-03  Jim Meyering  <meyering@lucent.com>
163010         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
163011         rather than with `#if HAVE_UTMPNAME'.
163013 2000-02-02  Jim Meyering  <meyering@lucent.com>
163015         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
163016         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
163017         Reported by Eli Zaretskii.
163019 2000-02-01  Jim Meyering  <meyering@lucent.com>
163021         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
163023 2000-01-31  Jim Meyering  <meyering@lucent.com>
163025         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
163026         functions.  Add the time.h and sys/time.h headers along with the
163027         AC_REQUIRE'ment of AC_HEADER_TIME.
163029 2000-01-31  Jim Meyering  <meyering@lucent.com>
163031         * lib/nanosleep.h (nanosleep): Guard declaration with
163032         `#if ! HAVE_DECL_NANOSLEEP'.
163033         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
163034         the declaration in that vendor's sys/timers.h.
163035         Reported by Christian Krackowizer.
163037         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
163038         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
163039         (ISPRINT): Likewise.
163040         Reported by Tom Tromey.
163042 2000-01-30  Jim Meyering  <meyering@lucent.com>
163044         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
163046         * m4/prereq.m4 (utmp_includes): Define.
163047         Check for ut_user and ut_name members in both struct utmpx
163048         and struct utmp.
163050 2000-01-30  Jim Meyering  <meyering@lucent.com>
163052         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
163053         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
163054         header files where only utmpx.ut_user is declared.
163056         * lib/readutmp.h (UT_USER): Define.
163058 2000-01-29  Jim Meyering  <meyering@lucent.com>
163060         * m4/lib-check.m4: New file containing library-related checks from
163061         fileutils and sh-utils (textutils had none).
163063 2000-01-28  Jim Meyering  <meyering@lucent.com>
163065         * m4/perl.m4: Change format of warning message to look more like that
163066         from the missing script.  Suggestion from François Pinard.
163068 2000-01-25  Jim Meyering  <meyering@lucent.com>
163070         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
163071         well as time.h in the compile check.
163072         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
163073         Fix typo in cross-compiling case: s/yes/no/.
163075 2000-01-23  Jim Meyering  <meyering@lucent.com>
163077         * m4/jm-macros.m4: Move df-related tests here from
163078         fileutils/configure.in
163080         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
163081         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
163083         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
163084         s/space/ac_fsusage_space/.
163085         (jm_FILE_SYSTEM_USAGE): Take two parameters.
163087         * m4/ftruncate.m4: New file (derived from part of
163088         fileutils/configure.in).
163089         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
163090         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
163092         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
163093         AC_SUBST these here, rather than just in sh-util/configure.in, so
163094         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
163095         all the same.
163096         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
163097         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
163098         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
163099         (AC_SUBST(POW_LIBM)): Likewise.
163100         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
163102 2000-01-23  Jim Meyering  <meyering@lucent.com>
163104         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
163105         obstack.c.
163107 2000-01-22  Jim Meyering  <meyering@lucent.com>
163109         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
163111         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
163113         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
163114         configure.in
163115         (AC_CHECK_HEADERS): Likewise for sh-utils.
163116         (AC_CHECK_HEADERS): Likewise for textutils.
163117         Merge the three lists of headers.
163119         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
163120         from fileutils' configure.in.
163122         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
163123         code. Moved tests into their own function (_jm_DECL_HEADERS) in
163124         check-decl.m4.
163126         * m4/check-decl.m4: Use #if rather than #ifdef.
163127         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
163128         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
163129         (_jm_DECL_HEADERS): Define new function.
163130         (jm_CHECK_DECLARATIONS): Require it.
163132 2000-01-22  Jim Meyering  <meyering@lucent.com>
163134         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
163135         [! HAVE_DECL_STRTOULL]: Declare strtoull.
163136         Required for some AIX systems.  Reported by Christian Krackowizer.
163137         [TESTING] (main): New function.
163139         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
163140         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
163141         letters.
163143         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
163144         iswprint.
163146         * lib/strverscmp.c (ISDIGIT): Define.
163147         (strverscmp): Use ISDIGIT, not isdigit.
163149 2000-01-19  Jim Meyering  <meyering@lucent.com>
163151         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
163152         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
163153         defines `struct timespec' in <sys/time.h>
163155         * m4/c-bs-a.m4: Remove uses of changequote altogether.
163156         Thanks to Akim for explaining.
163158 2000-01-17  Paul Eggert  <eggert@twinsun.com>
163160         * lib/nanosleep.c (nanosleep):
163161         Don't use SA_INTERRUPT to decide whether to call sigaction, as
163162         POSIX.1 doesn't require SA_INTERRUPT and some systems
163163         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
163164         it's been part of POSIX.1 since day 1 (in 1988).
163166 2000-01-17  Jim Meyering  <meyering@lucent.com>
163168         * lib/interlock: Remove unused file.  Reported by François Pinard.
163170 2000-01-16  Paul Eggert  <eggert@twinsun.com>
163172         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
163173         alert, backslash, formfeed, and vertical tab unnecessarily in
163174         shell quoting style.
163176 2000-01-16  Jim Meyering  <meyering@lucent.com>
163178         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
163179         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
163180         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
163181         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
163183 2000-01-16  Jim Meyering  <meyering@lucent.com>
163185         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
163186         because the latter didn't work.
163188 2000-01-15  Jim Meyering  <meyering@lucent.com>
163190         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
163191         (AC_REPLACE_FUNCS): Add memcpy and memset.
163192         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
163193         Add strpbrk.
163194         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
163196 2000-01-12  Jim Meyering  <meyering@lucent.com>
163198         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
163199         (jm_PREREQ): Use it.
163200         (jm_PREREQ_READUTMP): New macro.
163201         (jm_PREREQ): Use it.
163203 2000-01-11  Paul Eggert  <eggert@twinsun.com>
163205         Quote multibyte characters correctly.
163206         * m4/c-bs-a.m4: New file.
163207         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
163208         (jm_PREREQ): Use it.
163210 2000-01-11  Paul Eggert  <eggert@twinsun.com>
163212         * m4/uintmax_t.m4: Port to autoconf 2.13.
163214 2000-01-08  Jim Meyering  <meyering@ascend.com>
163216         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
163217         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
163219 2000-01-04  Jim Meyering  <meyering@ascend.com>
163221         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
163222         jm_STRUCT_DIRENT_D_TYPE.
163223         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
163224         jm_STRUCT_DIRENT_D_INO.
163225         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
163226         jm_STRUCT_UTIMBUF.
163227         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
163228         renamings.
163229         * m4/utime.m4: Likewise.
163231         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
163232         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
163234 2000-01-03  Paul Eggert  <eggert@twinsun.com>
163236         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
163237         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
163239 2000-01-02  Jim Meyering  <meyering@ascend.com>
163241         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
163242         remember if this is necessary.
163244 1999-12-26  Jim Meyering  <meyering@ascend.com>
163246         * m4/jm-macros.m4: Use it here.
163247         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
163249 1999-12-23  Jim Meyering  <meyering@ascend.com>
163251         * m4/jm-macros.m4: Check for clock_gettime (moved from
163252         fileutils/configure.in)
163253         Check for gettimeofday.
163255 1999-12-20  Jim Meyering  <meyering@ascend.com>
163257         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
163258         autoconf-2.14a-1999-12-20.
163260 1999-12-19  Jim Meyering  <meyering@ascend.com>
163262         * m4/lstat-slash.m4: New file.
163263         * m4/jm-macros.m4: Use the new macro:
163264         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
163266 1999-12-07  Jim Meyering  <meyering@ascend.com>
163268         * m4/perl.m4: Require that File::Compare be available, too.
163269         Too many systems seem to lack it.
163271         * m4/strftime.m4: Add checks for most of the cpp macros tested in
163272         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
163274 1999-11-18  Paul Eggert  <eggert@twinsun.com>
163276         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
163277         problem with the QNX 4.25 shell, which doesn't propagate exit
163278         status of failed commands inside shell assignments.
163280 1999-11-17  Jim Meyering  <meyering@ascend.com>
163282         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
163284 1999-11-07  Jim Meyering  <meyering@ascend.com>
163286         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
163288 1999-11-06  Jim Meyering  <meyering@ascend.com>
163290         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
163291         * m4/jm-macros.m4 (jm_MACROS): Use it here.
163293 1999-11-05  Jim Meyering  <meyering@ascend.com>
163295         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
163296         configure.in of textutils, fileutils, and sh-utils into this one
163297         (shared between those packages) file.
163298         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
163299         AC_STRUCT_ST_BLKSIZE.
163301 1999-11-03  Jim Meyering  <meyering@ascend.com>
163303         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
163304         of AC_CHECK_TYPE checks includes unistd.h.
163305         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
163306         Suggestion from Akim Demaille.
163308 1999-10-30  Jim Meyering  <meyering@ascend.com>
163310         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
163311         m4-quoted string.
163312         * m4/ls-mntd-fs.m4: Likewise.
163313         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
163314         * m4/jm-winsz1.m4: Likewise.
163316         * m4/const.m4: Remove file, since the fix made it into the experimental
163317         version of autoconf.
163318         * m4/mktime.m4: Likewise.
163320         * m4/check-type.m4: Remove file, now that the latest version of
163321         AC_CHECK_TYPE takes a third arg to specify additional #includes.
163323         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
163324         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
163325         AC_CHECK_TYPE.
163327 1999-10-04  Jim Meyering  <meyering@ascend.com>
163329         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
163331 1999-09-22  Paul Eggert  <eggert@twinsun.com>
163333         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
163334         2.95.1 bug with HP-UX 10.20.
163336 1999-09-17  Jim Meyering  <meyering@ascend.com>
163338         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
163339         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
163340         due to missing strdup (against sh-utils-2.0).
163342 1999-08-29  Jim Meyering  <meyering@ascend.com>
163344         * m4/jm-macros.m4: Require jm_BISON.
163345         * m4/bison.m4: New file.
163347 1999-08-17  Paul Eggert  <eggert@twinsun.com>
163349         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
163350         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
163352 1999-08-05  Jim Meyering  <meyering@ascend.com>
163354         * m4/getline.m4: Rename test file from conftestdata to conftest.data
163355         to avoid conflicts with `conftest' on 8+3 filesystems.
163356         Suggestion from Eli Zaretskii.
163358 1999-08-04  Jim Meyering  <meyering@ascend.com>
163360         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
163361         fileutils and sh-utils (textutils's getline test was inadequate).
163362         (AM_FUNC_GETLINE): Run this test.
163363         (AC_CHECK_FUNCS): Check for getdelim.
163364         Reported by Bob Proulx.
163366 1999-08-02  Jim Meyering  <meyering@ascend.com>
163368         * m4/jm-macros.m4: Add a comment.
163370 1999-08-01  Paul Eggert  <eggert@twinsun.com>
163372         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
163373         <inttypes.h> defines strtoumax as a macro (and not as a
163374         function).
163376 1999-08-01  Paul Eggert  <eggert@twinsun.com>
163378         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
163379         that we can shift, multiply and divide unsigned long long
163380         values; Ultrix cc can't do it.
163382 1999-08-01  Paul Eggert  <eggert@twinsun.com>
163384         * m4/mktime.m4: New file, which is a preview of what should appear
163385         in the next public autoconf release.
163387 1999-08-01  Paul Eggert  <eggert@twinsun.com>
163389         * m4/lfs.m4: Remove this file.
163390         * m4/largefile.m4: New file.  It contains the old contents of
163391         lfs.m4, except that all names with prefix AC_LFS have been
163392         changed to use the prefix AC_SYS_LARGEFILE instead, to be
163393         compatible with future autoconf versions.  Also, some minor m4
163394         quoting problems have been fixed.
163396 1999-08-01  Paul Eggert  <eggert@twinsun.com>
163398         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
163399         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
163400         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
163401         and simplify the shell code.
163403 1999-08-01  Jim Meyering  <meyering@ascend.com>
163405         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
163406         m4.
163408 1999-07-20  Jim Meyering  <meyering@ascend.com>
163410         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
163412 1999-07-15  Jim Meyering  <meyering@ascend.com>
163414         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
163416 1999-05-22  Jim Meyering  <meyering@ascend.com>
163418         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
163420 1999-05-20  Jim Meyering  <meyering@ascend.com>
163422         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
163423         Add a colon after each `then' in case $4 is empty.
163425 1999-05-16  Jim Meyering  <meyering@ascend.com>
163427         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
163429 1999-05-10  Jim Meyering  <meyering@ascend.com>
163431         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
163433         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
163434         AC_FUNC_MKTIME.
163436 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
163438         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
163440 1999-05-04  Paul Eggert  <eggert@twinsun.com>
163442         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
163443         not CPPFLAGS, so that linking works correctly in IRIX.
163445 1999-04-30  Paul Eggert  <eggert@twinsun.com>
163447         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
163449 1999-04-20  Paul Eggert  <eggert@twinsun.com>
163451         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
163452         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
163453         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
163454         jm_AC_TYPE_UNSIGNED_LONG_LONG.
163455         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
163457         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
163459 1999-04-20  Jim Meyering  <meyering@ascend.com>
163461         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
163462         AC_REPLACE xstroull if necessary.  From Paul Eggert.
163463         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
163465 1999-04-18  Jim Meyering  <meyering@ascend.com>
163467         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
163468         * m4/jm-macros.m4: Use it.
163470 1999-04-06  Jim Meyering  <meyering@ascend.com>
163472         * m4/strftime.m4: Remove test for %f.
163474 1999-03-29  Jim Meyering  <meyering@ascend.com>
163476         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
163477         superset of the AC_TYPE_* checks in the textutils, fileutils,
163478         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
163479         AC_TYPE_PID_T.
163481 1999-03-28  Jim Meyering  <meyering@ascend.com>
163483         * m4/jm-macros.m4: Define GNU_PACKAGE here.
163484         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
163485         replaced e.g., in the *.sh files of the sh-utils.
163487 1999-03-20  Jim Meyering  <meyering@ascend.com>
163489         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
163490         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
163491         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
163493 1999-03-19  Jim Meyering  <meyering@ascend.com>
163495         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
163497 1999-03-12  Jim Meyering  <meyering@ascend.com>
163499         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
163501 1999-03-07  Jim Meyering  <meyering@ascend.com>
163503         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
163504         declared.
163506 1999-02-17  Jim Meyering  <meyering@ascend.com>
163508         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
163509         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
163511 1999-02-07  Jim Meyering  <meyering@ascend.com>
163513         * m4/group-member.m4: New file -- extracted from sh-utils'
163514         configure.in.
163516         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
163517         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
163519 1999-02-06  Jim Meyering  <meyering@ascend.com>
163521         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
163522         * m4/fnmatch.m4: Likewise.
163523         * m4/getgroups.m4: Likewise.
163524         * m4/lstat.m4: Likewise.
163525         * m4/malloc.m4: Likewise.
163526         * m4/putenv.m4: Likewise.
163527         * m4/realloc.m4: Likewise.
163528         * m4/regex.m4: Likewise.
163529         * m4/stat.m4: Likewise.
163530         * m4/strftime.m4: Likewise.
163531         Suggestion from Alain Magloire.
163533         * m4/chown.m4: Use `.$ac_objext', not `.o'.
163534         * m4/fnmatch.m4: Likewise.
163535         * m4/getgroups.m4: Likewise.
163536         * m4/getline.m4: Likewise.
163537         * m4/lstat.m4: Likewise.
163538         * m4/malloc.m4: Likewise.
163539         * m4/memcmp.m4: Likewise.
163540         * m4/putenv.m4: Likewise.
163541         * m4/realloc.m4: Likewise.
163542         * m4/regex.m4: Likewise.
163543         * m4/stat.m4: Likewise.
163544         * m4/strftime.m4: Likewise.
163545         Suggestion from Alain Magloire.
163547         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
163548         an argument.
163550         * m4/regex.m4: Add a run-time Test for proper operation of
163551         re_compile_pattern.
163553 1999-01-31  Jim Meyering  <meyering@ascend.com>
163555         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
163557 1999-01-30  Jim Meyering  <meyering@ascend.com>
163559         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
163561         * m4/jm-mktime.m4: Make this a wrapper around the official
163562         AM_FUNC_MKTIME rather than my private copy, now that the official one
163563         is up to date.
163564         * m4/mktime.m4: Remove file.
163566         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
163567         * m4/uptime.m4: Likewise.
163568         * m4/uintmax_t.m4: Likewise.
163570 1999-01-28  Jim Meyering  <meyering@ascend.com>
163572         * m4/jm-macros.m4: Use jm_AFS.
163573         * m4/afs.m4: New file (from fileutils' configure.in).
163575         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
163576         * m4/chown.m4: Likewise.
163577         * m4/d-ino.m4: Likewise.
163578         * m4/d-type.m4: Likewise.
163579         * m4/fnmatch.m4: Likewise.
163580         * m4/getgroups.m4: Likewise.
163581         * m4/gettext.m4: Likewise.
163582         * m4/jm-mktime.m4: Likewise.
163583         * m4/jm-winsz2.m4: Likewise.
163584         * m4/lcmessage.m4: Likewise.
163585         * m4/ls-mntd-fs.m4: Likewise.
163586         * m4/malloc.m4: Likewise.
163587         * m4/memcmp.m4: Likewise.
163588         * m4/putenv.m4: Likewise.
163589         * m4/realloc.m4: Likewise.
163590         * m4/st_mtim.m4: Likewise.
163591         * m4/strftime.m4: Likewise.
163593 1999-01-16  Jim Meyering  <meyering@ascend.com>
163595         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
163596         (ARGMATCH_DIE_DECL): Define.
163598 1999-01-12  Jim Meyering  <meyering@ascend.com>
163600         * m4/Makefile.am.in: Rewrite to avoid using fmt.
163601         Reported by Lars Hecking.
163603 1999-01-10  Jim Meyering  <meyering@ascend.com>
163605         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
163606         gross kludge.
163607         * m4/inttypes_h.m4: Likewise.
163608         * m4/lstat.m4: Likewise.
163609         * m4/malloc.m4: Likewise.
163610         * m4/readdir.m4: Likewise.
163611         * m4/realloc.m4: Likewise.
163612         * m4/st_dm_mode.m4: Likewise.
163613         * m4/stat.m4: Likewise.
163614         * m4/utimbuf.m4: Likewise.
163615         * m4/utimes.m4: Likewise.
163617         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
163618         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
163619         comments in config.h.in are meaningful.
163621         * m4/jm-macros.m4: Require autoconf-2.13 here.
163623         * m4/regex.m4: By default, don't use the included regex.c on systems
163624         with glibc 2.  Suggestion from Uli Drepper.
163626 1999-01-02  Jim Meyering  <meyering@ascend.com>
163628         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
163630 1998-12-18  Jim Meyering  <meyering@ascend.com>
163632         * m4/Makefile.am.in (Makefile.am): Simplify rule.
163633         Based on a suggestion from Lars Hecking.
163635 1998-11-16  Paul Eggert  <eggert@twinsun.com>
163637         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
163639 1998-11-16  Jim Meyering  <meyering@ascend.com>
163641         * m4/lfs.m4: Double-quote the `uname...` expression.
163643 1998-11-14  Jim Meyering  <meyering@ascend.com>
163645         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
163646         * m4/stat.m4: Likewise.
163648 1998-11-03  Jim Meyering  <meyering@ascend.com>
163650         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
163651         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
163653 1998-10-18  Jim Meyering  <meyering@ascend.com>
163655         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
163657 1998-10-17  Jim Meyering  <meyering@ascend.com>
163659         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
163660         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
163661         calls for those previously hard-coded headers.  Instead, take a new
163662         parameter.
163663         (jm_CHECK_DECLARATIONS): Reflect interface change.
163664         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
163665         (jm_CHECK_DECL_LOCALTIME_R): New macro.
163667         * m4/mktime.m4: Test for spring-forward gap before long-running test.
163669 1998-10-14  Jim Meyering  <meyering@ascend.com>
163671         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
163672         instead of "TZ=America/Vancouver".  From Paul Eggert.
163674 1998-10-11  Jim Meyering  <meyering@ascend.com>
163676         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
163677         This adds a test for a recently added compatibility fix for mktime.c.
163678         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
163680 1998-09-27  Jim Meyering  <meyering@ascend.com>
163682         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
163684         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
163685         ../configure.in, including a change from Gordon Matzigkeit to allow
163686         cross-compiling for the Hurd.
163688         * m4/glibc.m4: New file/macro to test for the GNU C Library
163689         versions 1 and 2.  From Gordon Matzigkeit.
163690         Indent.
163692 1998-09-21  Jim Meyering  <meyering@ascend.com>
163694         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
163696 1998-08-18  Paul Eggert  <eggert@twinsun.com>
163698         Port nanosecond-resolution times to UnixWare 2.1.2 and
163699         pedantic Solaris 2.6.
163701         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
163702         AC_STRUCT_ST_MTIM.
163703         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
163704         Generate name of ns member, instead of just 1 or undef.
163705         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
163707 1998-08-15  Jim Meyering  <meyering@ascend.com>
163709         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
163710         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
163711         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
163712         instead of jm_TYPE_SSIZE_T.
163714 1998-08-12  Jim Meyering  <meyering@ascend.com>
163716         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
163718 1998-08-02  Jim Meyering  <meyering@ascend.com>
163720         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
163721         in acconfig.h manually.
163723 1998-07-31  Paul Eggert  <eggert@twinsun.com>
163725         * m4/st_mtim.m4: New file.
163727 1998-07-28  Jim Meyering  <meyering@ascend.com>
163729         * m4/utimes.m4: Undef stat.
163731 1998-07-25  Jim Meyering  <meyering@ascend.com>
163733         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
163734         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
163736 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
163738         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
163739         uid and gid actually remain unchanged.
163741 1998-07-07  Jim Meyering  <meyering@ascend.com>
163743         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
163745 1998-07-04  Jim Meyering  <meyering@ascend.com>
163747         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
163748         to prove that this macro can be used in packages without regex.c.
163750 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
163752         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
163753         is to be used.
163755 1998-07-03  Jim Meyering  <meyering@ascend.com>
163757         * m4/gettext.m4: Add -lintl if it's found to be necessary.
163759         * m4/gettext.m4: New file -- from gettext-0.10.35.
163760         * m4/lcmessage.m4: Likewise.
163761         * m4/progtest.m4: Likewise.
163763         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
163764         * m4/jm-macros.m4: Require the new macro.
163766 1998-06-29  Jim Meyering  <meyering@ascend.com>
163768         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
163769         for the definition of NGROUPS (used in a system header included
163770         by sys/mount.h).
163772 1998-06-28  Jim Meyering  <meyering@ascend.com>
163774         * m4/ls-mntd-fs.m4: New file.
163775         * m4/fstypename.m4: New file.
163777         * m4/jm-macros.m4: Require the new macro.
163778         * m4/jm-glibc-io.m4: New file.
163780 1998-05-19  Jim Meyering  <meyering@ascend.com>
163782         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
163783         * m4/lchown.m4: New file.
163785         * m4/Makefile.am.in: New file.
163786         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
163788 1998-05-14  Jim Meyering  <meyering@ascend.com>
163790         * m4/Makefile.am (EXTRA_DIST): Add them.
163791         * m4/jm-macros.m4: New file.
163792         * m4/utimbuf.m4: New file.
163794 1998-05-12  Jim Meyering  <meyering@ascend.com>
163796         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
163798 1998-05-11  Jim Meyering  <meyering@ascend.com>
163800         * m4/isc-posix.m4: New file.
163802 1998-05-10  Jim Meyering  <meyering@ascend.com>
163804         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
163806 1998-05-09  Jim Meyering  <meyering@ascend.com>
163808         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
163809         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
163810         with automake.
163812         * m4/ssize_t.m4: New file.
163813         * m4/mktime.m4: Remove file -- the new automake has this now.
163815 1998-04-26  Jim Meyering  <meyering@ascend.com>
163817         * m4/assert.m4: New file.
163818         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
163820 1998-04-05  Jim Meyering  <meyering@ascend.com>
163822         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
163823         (jm_PREREQ): Use it here.
163825 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
163827         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
163828         in acconfig.h.
163830 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
163832         * m4/prereq.m4: New file.
163833         * m4/error.m4: New file.
163834         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
163836 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
163838         * m4/getline.m4: Don't set am_cv_func_working_getline before the
163839         cache-check for the same variable -- that defeated the purpose of
163840         the test; the test program was never run.  This was a problem only
163841         on systems with losing getline functions -- HP-UX 10.20 is one.
163842         Reported by Bjorn Helgaas.
163844 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
163846         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
163848 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
163850         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
163852         * m4/const.m4: New file.  Use an initializer in this declaration
163853         typedef int charset[2]; const charset x;
163854         Reported by Bob Glickstein.
163856 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
163858         * m4/chown.m4: Fix reversed types on -1 args to chown.
163859         From Kaveh Ghazi.
163861 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
163863         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
163864         Add lseek and memchr.
163866         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
163867         T.E.Dickey <dickey@clark.net> said that some older preprocessors
163868         have a 20-character limit on names.
163870 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
163872         * m4/inttypes_h.m4: New file.
163873         * m4/uintmax_t.m4: New file.
163874         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
163877         -----
163879         Local Variables:
163880         coding: utf-8
163881         End:
163883         Copyright (C) 1997-2024 Free Software Foundation, Inc.
163885         Copying and distribution of this file, with or without
163886         modification, are permitted provided the copyright notice
163887         and this notice are preserved.